Skip to content

Commit 9fa7400

Browse files
committed
separate static and dynamic builds
1 parent fa289f9 commit 9fa7400

File tree

2 files changed

+11
-6
lines changed

2 files changed

+11
-6
lines changed

appveyor.yml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,9 @@ build_script:
1616
if "Visual Studio 2017"=="%APPVEYOR_BUILD_WORKER_IMAGE%" call "C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Auxiliary\Build\vcvars64.bat"
1717
if "Visual Studio 2015"=="%APPVEYOR_BUILD_WORKER_IMAGE%" call "C:\Program Files\Microsoft SDKs\Windows\v7.1\Bin\SetEnv.cmd" /x64
1818
if "Visual Studio 2015"=="%APPVEYOR_BUILD_WORKER_IMAGE%" call "C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\vcvarsall.bat" x86_amd64
19-
nmake -f makefile.msvc all CFLAGS="/Ox /MD"
19+
nmake -f makefile.msvc test.exe
20+
nmake -f makefile.msvc clean-obj
21+
nmake -f makefile.msvc test_dll.exe CFLAGS="/Ox /MD /DLTM_TEST_DYNAMIC"
2022
test_script:
2123
- cmd: test.exe
2224
- cmd: test_dll.exe

makefile.msvc

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -71,22 +71,25 @@ $(LIBMAIN_D) $(LIBMAIN_I): $(OBJECTS) tommath.def
7171

7272
#Build test suite
7373
test.exe: $(LIBMAIN_S) demo/shared.obj demo/test.obj
74-
link $(TOBJECTS) $(LTM_LDFLAGS) $? /out:$@
74+
link $(TOBJECTS) $(LTM_LDFLAGS) $? /out:$@
7575
@echo NOTICE: start the tests by launching test.exe
7676

7777
#Build test suite for dll
7878
test_dll.exe: $(LIBMAIN_I) demo/shared.obj demo/test.obj
79-
link $(TOBJECTS) $(LTM_LDFLAGS) $? /out:$@
80-
@echo NOTICE: start the tests by launching test_dll.exe
79+
link $(TOBJECTS) $(LTM_LDFLAGS) $? /out:$@
80+
@echo NOTICE: start the tests by launching test_dll.exe
8181

8282
all: $(LIBMAIN_S) test.exe $(LIBMAIN_D) test_dll.exe
8383

8484
tune: $(LIBMAIN_S)
8585
$(MAKE) -C etc tune
8686
$(MAKE)
8787

88-
clean:
89-
@-cmd /c del /Q /S *.OBJ *.LIB *.EXE *.DLL 2>nul
88+
clean-obj:
89+
@-cmd /c del /Q /S *.OBJ 2>nul
90+
91+
clean: clean-obj
92+
@-cmd /c del /Q /S *.LIB *.EXE *.DLL 2>nul
9093

9194
#Install the library + headers
9295
install: $(LIBMAIN_S) $(LIBMAIN_I) $(LIBMAIN_D)

0 commit comments

Comments
 (0)