]> granicus.if.org Git - libvpx/commitdiff
x86inc.asm: fix symbol mangling and PIC handling on Win64/Mac64.
authorRonald S. Bultje <rbultje@google.com>
Mon, 18 Jun 2012 19:34:51 +0000 (12:34 -0700)
committerRonald S. Bultje <rbultje@google.com>
Mon, 18 Jun 2012 19:34:51 +0000 (12:34 -0700)
Change-Id: I97aa175346683184f9430d880593b291a563e04f

vpx_ports/x86inc.asm

index ed4eb82df28537f9242eb1aef8d4aaaa7e19f9d1..a7066b6dafbe28608cd610cfd35b351f9bc9e05b 100644 (file)
         %define WIN64  1
     %elifidn __OUTPUT_FORMAT__,win64
         %define WIN64  1
+    %elifidn __OUTPUT_FORMAT__,x64
+        %define WIN64  1
     %else
         %define UNIX64 1
     %endif
 %endif
 
-%ifdef PREFIX
-    %define mangle(x) _ %+ x
-%else
+%ifidn   __OUTPUT_FORMAT__,elf32
+    %define mangle(x) x
+%elifidn __OUTPUT_FORMAT__,elf64
+    %define mangle(x) x
+%elifidn __OUTPUT_FORMAT__,x64
     %define mangle(x) x
+%else
+    %define mangle(x) _ %+ x
 %endif
 
 ; FIXME: All of the 64bit asm functions that take a stride as an argument
 
 %if WIN64
     %define PIC
+%elifidn __OUTPUT_FORMAT__,macho64
+    %define PIC
 %elif ARCH_X86_64 == 0
 ; x86_32 doesn't require PIC.
 ; Some distros prefer shared objects to be PIC, but nothing breaks if
 ; the code contains a few textrels, so we'll skip that complexity.
     %undef PIC
+%elif CONFIG_PIC
+    %define PIC
 %endif
 %ifdef PIC
     default rel