allow build settings to be overriden by adding mk/validate.mk
[ghc-hetmet.git] / driver / mangler / ghc-asm.lprl
index 0bda1bb..88766cb 100644 (file)
@@ -173,7 +173,13 @@ sub init_TARGET_STUFF {
     $T_X86_BADJMP   = '^\tjmp\s+[^\.\*]';
 
     $T_MOVE_DIRVS   = '^(\s*(\.(p2)?align\s.*|\.globl\s+\S+|\.text|\.data|\.section\s+.*|\.type\s+.*|\.size\s+\S+\s*,\s*\d+|\.ident.*|\.local.*)\n)';
-    $T_COPY_DIRVS   = '^\s*\.(globl|type|size|local)';
+    if ( $TargetPlatform =~ /solaris2/ ) {
+            # newer Solaris linkers are picky about .size information, so
+            # omit it (see #1421)
+            $T_COPY_DIRVS   = '^\s*\.(globl|local)';
+    } else {
+            $T_COPY_DIRVS   = '^\s*\.(globl|type|size|local)';
+    }
 
     $T_DOT_WORD            = '\.(long|value|word|byte|zero)';
     $T_DOT_GLOBAL   = '\.globl';
@@ -236,6 +242,8 @@ sub init_TARGET_STUFF {
        # where x is in the text section and y in the rodata section.
        # It works if y is in the text section, though.  This is probably
        # going to cause difficulties for PIC, I imagine.
+        #       
+        # See Note [x86-64-relative] in includes/InfoTables.h
     $T_HDR_relrodata= "\.text\n\t\.align 8\n";
 
     $T_HDR_closure  = "\.data\n\t\.align 8\n";