1include $(SRC_PATH)build/arch.mk 2ifeq ($(ASM_ARCH), x86) 3ifeq ($(ARCH), x86_64) 4ASMFLAGS += -f win64 5ASMFLAGS_PLATFORM = -DWIN64 6else 7ASMFLAGS += -f win32 -DPREFIX 8endif 9else 10endif 11ifeq ($(ASM_ARCH), arm) 12CCAS = gas-preprocessor.pl -as-type armasm -force-thumb -- armasm 13CCASFLAGS = -nologo -DHAVE_NEON -ignore 4509 14endif 15 16CC=cl 17CXX=cl 18AR=lib 19CXX_O=-Fo$@ 20 21ifeq ($(ASM_ARCH), arm64) 22CCAS = clang-cl 23CCASFLAGS = -nologo -DHAVE_NEON_AARCH64 --target=arm64-windows 24endif 25 26 27# -D_VARIADIC_MAX=10 is required to fix building gtest on MSVC 2012, but 28# since we don't (easily) know which version of MSVC we use here, we add 29# it unconditionally. The same issue can also be worked around by adding 30# -DGTEST_HAS_TR1_TUPLE=0 instead, but we prefer this version since it 31# matches what gtest itself does. 32CFLAGS += -nologo -W3 -EHsc -fp:precise -Zc:wchar_t -Zc:forScope -D_VARIADIC_MAX=10 33CXX_LINK_O=-nologo -Fe$@ 34AR_OPTS=-nologo -out:$@ 35CFLAGS_OPT=-O2 -Ob1 -Oy- -Zi -FS -GF -GS -Gy -DNDEBUG 36CFLAGS_DEBUG=-Od -Oy- -Zi -FS -RTC1 -D_DEBUG 37CFLAGS_M32= 38CFLAGS_M64= 39LINK_LOCAL_DIR= 40LINK_LIB=$(1).lib 41LIBSUFFIX=lib 42LIBPREFIX= 43EXEEXT=.exe 44OBJ=obj 45SHAREDLIB_DIR = $(PREFIX)/bin 46SHAREDLIBSUFFIX=dll 47SHAREDLIBSUFFIXFULLVER=$(SHAREDLIBSUFFIX) 48SHAREDLIBSUFFIXMAJORVER=$(SHAREDLIBSUFFIX) 49SHARED=-LD 50EXTRA_LIBRARY=$(PROJECT_NAME)_dll.lib 51LDFLAGS += -link 52SHLDFLAGS=-debug -map -opt:ref -opt:icf -def:$(SRC_PATH)openh264.def -implib:$(EXTRA_LIBRARY) 53STATIC_LDFLAGS= 54CODEC_UNITTEST_CFLAGS+=-D_CRT_SECURE_NO_WARNINGS 55 56ifneq ($(filter %86 x86_64, $(ARCH)),) 57LDFLAGS += -cetcompat 58endif 59 60%.res: %.rc 61 $(QUIET_RC)rc -fo $@ $< 62