Browse Source

Handle asmextraopt in powerpc, mips and sparc assemblers

git-svn-id: trunk@26542 -
pierre 11 years ago
parent
commit
5e6669890a
3 changed files with 8 additions and 7 deletions
  1. 3 3
      compiler/mips/cpugas.pas
  2. 2 1
      compiler/powerpc/agppcvasm.pas
  3. 3 3
      compiler/sparc/cpugas.pas

+ 3 - 3
compiler/mips/cpugas.pas

@@ -42,7 +42,7 @@ unit cpugas;
       end;
       end;
 
 
     const
     const
-      use_std_regnames : boolean = 
+      use_std_regnames : boolean =
       {$ifndef USE_MIPS_GAS_REGS}
       {$ifndef USE_MIPS_GAS_REGS}
       true;
       true;
       {$else}
       {$else}
@@ -379,7 +379,7 @@ unit cpugas;
         id: as_gas;
         id: as_gas;
         idtxt: 'AS';
         idtxt: 'AS';
         asmbin: 'as';
         asmbin: 'as';
-        asmcmd: '$ABI $ARCH $NOWARN -EL $PIC -o $OBJ $ASM';
+        asmcmd: '$ABI $ARCH $NOWARN -EL $PIC -o $OBJ $EXTRAOPT $ASM';
         supported_targets: [system_mipsel_linux];
         supported_targets: [system_mipsel_linux];
         flags: [ af_needar, af_smartlink_sections];
         flags: [ af_needar, af_smartlink_sections];
         labelprefix: '.L';
         labelprefix: '.L';
@@ -391,7 +391,7 @@ unit cpugas;
         id: as_gas;
         id: as_gas;
         idtxt: 'AS';
         idtxt: 'AS';
         asmbin: 'as';
         asmbin: 'as';
-        asmcmd: '$ABI $ARCH $NOWARN -EB $PIC -o $OBJ $ASM';
+        asmcmd: '$ABI $ARCH $NOWARN -EB $PIC -o $OBJ $EXTRAOPT $ASM';
         supported_targets: [system_mipseb_linux];
         supported_targets: [system_mipseb_linux];
         flags: [ af_needar, af_smartlink_sections];
         flags: [ af_needar, af_smartlink_sections];
         labelprefix: '.L';
         labelprefix: '.L';

+ 2 - 1
compiler/powerpc/agppcvasm.pas

@@ -379,6 +379,7 @@ unit agppcvasm;
            Replace(result,'$ASM',maybequoted(Unix2AmigaPath(AsmFileName)));
            Replace(result,'$ASM',maybequoted(Unix2AmigaPath(AsmFileName)));
            Replace(result,'$OBJ',maybequoted(Unix2AmigaPath(ObjFileName)));
            Replace(result,'$OBJ',maybequoted(Unix2AmigaPath(ObjFileName)));
          end;
          end;
+        Replace(result,'$EXTRAOPT',asmextraopt);
       end;
       end;
 
 
 
 
@@ -394,7 +395,7 @@ unit agppcvasm;
 
 
          idtxt  : 'VASM';
          idtxt  : 'VASM';
          asmbin : 'fpcvasm';
          asmbin : 'fpcvasm';
-         asmcmd: '-quiet -Felf -o $OBJ $ASM';
+         asmcmd: '-quiet -Felf -o $OBJ $EXTRAOPT $ASM';
          supported_targets : [system_powerpc_morphos];
          supported_targets : [system_powerpc_morphos];
          flags : [af_needar,af_smartlink_sections];
          flags : [af_needar,af_smartlink_sections];
          labelprefix : '.L';
          labelprefix : '.L';

+ 3 - 3
compiler/sparc/cpugas.pas

@@ -224,9 +224,9 @@ implementation
            idtxt  : 'AS';
            idtxt  : 'AS';
            asmbin : 'as';
            asmbin : 'as';
 {$ifdef FPC_SPARC_V8_ONLY}
 {$ifdef FPC_SPARC_V8_ONLY}
-           asmcmd : '$PIC -o $OBJ $ASM';
+           asmcmd : '$PIC -o $OBJ $EXTRAOPT $ASM';
 {$else}
 {$else}
-           asmcmd : '$ARCH $PIC -o $OBJ $ASM';
+           asmcmd : '$ARCH $PIC -o $OBJ $EXTRAOPT $ASM';
 {$endif}
 {$endif}
            supported_targets : [system_sparc_solaris,system_sparc_linux,system_sparc_embedded];
            supported_targets : [system_sparc_solaris,system_sparc_linux,system_sparc_embedded];
            flags : [af_needar,af_smartlink_sections];
            flags : [af_needar,af_smartlink_sections];
@@ -240,7 +240,7 @@ implementation
            id     : as_ggas;
            id     : as_ggas;
            idtxt  : 'GAS';
            idtxt  : 'GAS';
            asmbin : 'gas';
            asmbin : 'gas';
-           asmcmd : '$ARCH $PIC -o $OBJ $ASM';
+           asmcmd : '$ARCH $PIC -o $OBJ $EXTRAOPT $ASM';
            supported_targets : [system_sparc_solaris,system_sparc_linux,system_sparc_embedded];
            supported_targets : [system_sparc_solaris,system_sparc_linux,system_sparc_embedded];
            flags : [af_needar,af_smartlink_sections];
            flags : [af_needar,af_smartlink_sections];
            labelprefix : '.L';
            labelprefix : '.L';