Commit e5479d7c authored by Guillaume Poirier's avatar Guillaume Poirier

add support for x86_64 on Darwin9.0 (Mac OS X 10.5, aka Leopard)

Patch by Antoine Gerschenfeld %gerschen A clipper P ens P fr%


git-svn-id: svn://svn.videolan.org/x264/trunk@700 df754926-b1dd-0310-bc7b-ec298dee348c
parent bc77b5b9
......@@ -50,6 +50,17 @@ BITS 64
%endif
%endmacro
; Name of the .rodata section. On OS X we cannot use .rodata because YASM
; is unable to compute address offsets outside of .text so we use the .text
; section instead until YASM is fixed.
%macro SECTION_RODATA 0
%ifidn __OUTPUT_FORMAT__,macho64
SECTION .text align=16
%else
SECTION .rodata align=16
%endif
%endmacro
%macro pad 1
%undef %1
%ifdef PREFIX
......
......@@ -148,7 +148,7 @@ BITS 64
; Constants
;=============================================================================
SECTION .rodata align=16
SECTION_RODATA
pw_1: times 8 dw 1
pw_32: times 8 dw 32
......
......@@ -24,7 +24,7 @@ BITS 64
%include "amd64inc.asm"
SECTION .rodata align=16
SECTION_RODATA
pb_01: times 16 db 0x01
pb_03: times 16 db 0x03
pb_a1: times 16 db 0xa1
......
......@@ -42,9 +42,8 @@ BITS 64
; Constants
;=============================================================================
SECTION .rodata
SECTION_RODATA
ALIGN 16
pw_4: times 4 dw 4
pw_8: times 4 dw 8
pw_32: times 4 dw 32
......
......@@ -30,9 +30,8 @@ BITS 64
; Read only data
;=============================================================================
SECTION .rodata align=16
SECTION_RODATA
ALIGN 16
pw_1: times 4 dw 1
pw_16: times 4 dw 16
pw_32: times 4 dw 32
......
......@@ -29,7 +29,7 @@ BITS 64
%include "amd64inc.asm"
SECTION .rodata align=16
SECTION_RODATA
pw_1: times 8 dw 1
ssim_c1: times 4 dd 416 ; .01*.01*255*255*64
......
......@@ -58,9 +58,8 @@ ALIGN 4
%endmacro
SECTION .rodata align=16
SECTION_RODATA
ALIGN 16
pw_2: times 4 dw 2
pw_4: times 4 dw 4
pw_8: times 4 dw 8
......
......@@ -24,7 +24,7 @@ BITS 64
%include "amd64inc.asm"
SECTION .rodata
SECTION_RODATA
pd_1: times 2 dd 1
SECTION .text
......
......@@ -255,7 +255,13 @@ case $host_cpu in
x86_64)
ARCH="X86_64"
AS="yasm"
ASFLAGS="-f elf -m amd64"
if [ "$SYS" = MACOSX ];then
ASFLAGS="-f macho64 -m amd64 -D__PIC__ -DPREFIX"
CFLAGS="$CFLAGS -arch x86_64"
LDFLAGS="$LDFLAGS -arch x86_64"
else
ASFLAGS="-f elf -m amd64"
fi
;;
powerpc|powerpc64)
ARCH="PPC"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment