Browse Source

* compilation on x86-64 and i8086 fixed

git-svn-id: trunk@40275 -
florian 6 years ago
parent
commit
e157939b41
3 changed files with 7 additions and 2 deletions
  1. 3 1
      compiler/x86/agx86att.pas
  2. 2 1
      compiler/x86/cgx86.pas
  3. 2 0
      compiler/x86/nx86ld.pas

+ 3 - 1
compiler/x86/agx86att.pas

@@ -179,8 +179,10 @@ interface
                  owner.writer.AsmWrite('@GOT');
 {$endif x86_64}
                end;
+{$ifdef i386}
              addr_ntpoff:
                owner.writer.AsmWrite('@ntpoff');
+{$endif i386}
            end;
 
            if offset<0 then
@@ -227,7 +229,7 @@ interface
             else
               owner.writer.AsmWrite(gas_regname(o.reg));
           top_ref :
-            if o.ref^.refaddr in [addr_no,addr_pic,addr_pic_no_got,addr_ntpoff] then
+            if o.ref^.refaddr in [addr_no,addr_pic,addr_pic_no_got{$ifdef i386},addr_ntpoff{$endif i386}] then
               WriteReference(o.ref^)
             else
               begin

+ 2 - 1
compiler/x86/cgx86.pas

@@ -1108,6 +1108,7 @@ unit cgx86;
 
         with dirref do
           begin
+{$ifdef i386}
             if refaddr=addr_ntpoff then
               begin
                 { Convert thread local address to a process global addres
@@ -1138,7 +1139,7 @@ unit cgx86;
                     Internalerror(2018110403);
                 end;
               end;
-
+{$endif i386}
             if (base=NR_NO) and (index=NR_NO) then
               begin
                 if assigned(dirref.symbol) then

+ 2 - 0
compiler/x86/nx86ld.pas

@@ -87,6 +87,7 @@ implementation
 
         if (tf_section_threadvars in target_info.flags) then
           begin
+{$ifdef i386}
             case target_info.system of
               system_i386_linux,system_i386_android:
                 begin
@@ -99,6 +100,7 @@ implementation
                   end;
                 end;
             end;
+{$endif i386}
           end;
       end;