Merge pull request #1907 from mstorsjo/x86-64-arch-simplify
Use ARCH instead of ENABLE64BIT for distinguishing between x86 and x86_64
This commit is contained in:
commit
15b7bc22c3
@ -369,10 +369,10 @@ rem ***********************************************
|
||||
:Build
|
||||
set vConfiguration=%1
|
||||
cd %RootDir%
|
||||
echo bash -c "make OS=%vOSType% ARCH=%vArcType% ENABLE64BIT=%vEnable64BitFlag% USE_ASM=%vASMFlag% BUILDTYPE=%vConfiguration% clean"
|
||||
echo bash -c "make OS=%vOSType% ARCH=%vArcType% ENABLE64BIT=%vEnable64BitFlag% USE_ASM=%vASMFlag% BUILDTYPE=%vConfiguration%"
|
||||
bash -c "make OS=%vOSType% ARCH=%vArcType% ENABLE64BIT=%vEnable64BitFlag% USE_ASM=%vASMFlag% BUILDTYPE=%vConfiguration% clean"
|
||||
bash -c "make OS=%vOSType% ARCH=%vArcType% ENABLE64BIT=%vEnable64BitFlag% USE_ASM=%vASMFlag% BUILDTYPE=%vConfiguration%"
|
||||
echo bash -c "make OS=%vOSType% ARCH=%vArcType% USE_ASM=%vASMFlag% BUILDTYPE=%vConfiguration% clean"
|
||||
echo bash -c "make OS=%vOSType% ARCH=%vArcType% USE_ASM=%vASMFlag% BUILDTYPE=%vConfiguration%"
|
||||
bash -c "make OS=%vOSType% ARCH=%vArcType% USE_ASM=%vASMFlag% BUILDTYPE=%vConfiguration% clean"
|
||||
bash -c "make OS=%vOSType% ARCH=%vArcType% USE_ASM=%vASMFlag% BUILDTYPE=%vConfiguration%"
|
||||
if not %ERRORLEVEL%==0 (
|
||||
set BuildFlag=1
|
||||
)
|
||||
|
@ -1,6 +1,6 @@
|
||||
include $(SRC_PATH)build/arch.mk
|
||||
ifeq ($(ASM_ARCH), x86)
|
||||
ifeq ($(ENABLE64BIT), Yes)
|
||||
ifeq ($(ARCH), x86_64)
|
||||
ASMFLAGS += -f win64
|
||||
ASMFLAGS_PLATFORM = -DWIN64
|
||||
else
|
||||
|
@ -10,7 +10,7 @@ CFLAGS += -Wall -fPIC -MMD -MP
|
||||
LDFLAGS += -lpthread
|
||||
ifeq ($(ASM_ARCH), x86)
|
||||
ASMFLAGS += -DPREFIX
|
||||
ifeq ($(ENABLE64BIT), Yes)
|
||||
ifeq ($(ARCH), x86_64)
|
||||
ASMFLAGS += -f macho64
|
||||
else
|
||||
ASMFLAGS += -f macho
|
||||
|
@ -5,7 +5,7 @@ SHLDFLAGS = -Wl,-soname,$(LIBPREFIX)$(PROJECT_NAME).$(SHAREDLIBSUFFIXVER)
|
||||
CFLAGS += -fPIC
|
||||
LDFLAGS += -lpthread
|
||||
ifeq ($(ASM_ARCH), x86)
|
||||
ifeq ($(ENABLE64BIT), Yes)
|
||||
ifeq ($(ARCH), x86_64)
|
||||
ASMFLAGS += -f elf64
|
||||
else
|
||||
ASMFLAGS += -f elf
|
||||
|
@ -5,7 +5,7 @@ SHLDFLAGS = -Wl,-soname,$(LIBPREFIX)$(PROJECT_NAME).$(SHAREDLIBSUFFIXVER)
|
||||
CFLAGS += -Wall -fno-strict-aliasing -fPIC -MMD -MP
|
||||
LDFLAGS += -lpthread
|
||||
ifeq ($(ASM_ARCH), x86)
|
||||
ifeq ($(ENABLE64BIT), Yes)
|
||||
ifeq ($(ARCH), x86_64)
|
||||
ASMFLAGS += -f elf64
|
||||
else
|
||||
ASMFLAGS += -f elf
|
||||
|
@ -6,7 +6,7 @@ EXTRA_LIBRARY=$(LIBPREFIX)$(PROJECT_NAME).dll.a
|
||||
SHLDFLAGS = -Wl,--out-implib,$(EXTRA_LIBRARY)
|
||||
CFLAGS += -MMD -MP
|
||||
LDFLAGS +=
|
||||
ifeq ($(ENABLE64BIT), Yes)
|
||||
ifeq ($(ARCH), x86_64)
|
||||
ASMFLAGS += -f win64
|
||||
ASMFLAGS_PLATFORM = -DWIN64
|
||||
CC = x86_64-w64-mingw32-gcc
|
||||
|
@ -1,12 +1,14 @@
|
||||
CFLAGS_M32=-m32
|
||||
CFLAGS_M64=-m64
|
||||
ASM_INCLUDES = -I$(SRC_PATH)codec/common/x86/
|
||||
ifeq (, $(ENABLE64BIT))
|
||||
ifeq ($(ARCH), x86_64)
|
||||
ENABLE64BIT=Yes
|
||||
endif
|
||||
endif
|
||||
ifneq ($(ENABLE64BIT),)
|
||||
ifeq ($(ENABLE64BIT), Yes)
|
||||
ARCH = x86_64
|
||||
else
|
||||
ARCH = x86
|
||||
endif
|
||||
endif
|
||||
ifeq ($(ARCH), x86_64)
|
||||
CFLAGS += $(CFLAGS_M64)
|
||||
LDFLAGS += $(CFLAGS_M64)
|
||||
ASMFLAGS_PLATFORM = -DUNIX64
|
||||
@ -17,7 +19,7 @@ ASMFLAGS_PLATFORM = -DX86_32
|
||||
endif
|
||||
ifeq ($(USE_ASM),Yes)
|
||||
CFLAGS += -DX86_ASM
|
||||
ifneq ($(ENABLE64BIT), Yes)
|
||||
ifneq ($(ARCH), x86_64)
|
||||
CFLAGS += -DX86_32_ASM
|
||||
endif
|
||||
ASM_ARCH = x86
|
||||
|
Loading…
x
Reference in New Issue
Block a user