[x264-devel] build: Set all ASFLAGS from within configure

Diego Biurrun git at videolan.org
Sun Jul 20 11:58:29 CEST 2014


x264 | branch: master | Diego Biurrun <diego at biurrun.de> | Sun Apr 27 23:19:04 2014 +0200| [dd5b5d3959e35c122c7709a9823a26b589c950da] | committer: Fiona Glaser

build: Set all ASFLAGS from within configure

This is how all other toolchain flags are handled.

> http://git.videolan.org/gitweb.cgi/x264.git/?a=commit;h=dd5b5d3959e35c122c7709a9823a26b589c950da
---

 Makefile  |    3 ---
 configure |    3 ++-
 2 files changed, 2 insertions(+), 4 deletions(-)

diff --git a/Makefile b/Makefile
index a2bc0dc..0141287 100644
--- a/Makefile
+++ b/Makefile
@@ -88,17 +88,14 @@ X86SRC = $(X86SRC0:%=common/x86/%)
 ifeq ($(ARCH),X86)
 ARCH_X86 = yes
 ASMSRC   = $(X86SRC) common/x86/pixel-32.asm
-ASFLAGS += -DARCH_X86_64=0
 endif
 
 ifeq ($(ARCH),X86_64)
 ARCH_X86 = yes
 ASMSRC   = $(X86SRC:-32.asm=-64.asm) common/x86/trellis-64.asm
-ASFLAGS += -DARCH_X86_64=1
 endif
 
 ifdef ARCH_X86
-ASFLAGS += -I$(SRCPATH)/common/x86/
 SRCS   += common/x86/mc-c.c common/x86/predict-c.c
 OBJASM  = $(ASMSRC:%.asm=%.o)
 $(OBJASM): common/x86/x86inc.asm common/x86/x86util.asm
diff --git a/configure b/configure
index 1f38d6f..5f6e5f1 100755
--- a/configure
+++ b/configure
@@ -561,7 +561,7 @@ case $host_cpu in
     i*86)
         ARCH="X86"
         AS="yasm"
-        ASFLAGS="$ASFLAGS -O2"
+        ASFLAGS="$ASFLAGS -O2 -DARCH_X86_64=0 -I\$(SRCPATH)/common/x86/"
         if [ $compiler = GNU ]; then
             if [[ "$asm" == auto && "$CFLAGS" != *-march* ]]; then
                 CFLAGS="$CFLAGS -march=i686"
@@ -600,6 +600,7 @@ case $host_cpu in
     x86_64)
         ARCH="X86_64"
         AS="yasm"
+        ASFLAGS="$ASFLAGS -DARCH_X86_64=1 -I\$(SRCPATH)/common/x86/"
         [ $compiler = GNU ] && CFLAGS="-m64 $CFLAGS" && LDFLAGS="-m64 $LDFLAGS"
         if [ "$SYS" = MACOSX ]; then
             ASFLAGS="$ASFLAGS -f macho64 -m amd64 -DPIC -DPREFIX"



More information about the x264-devel mailing list