forked from Janmroca/bls
-
Notifications
You must be signed in to change notification settings - Fork 0
/
mklib.bat
22 lines (21 loc) · 897 Bytes
/
mklib.bat
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
@echo off
call ..\mcl\setvar.bat
if "%1"=="dll" (
echo make dynamic library DLL
) else (
echo make static library LIB
)
call setvar.bat
if "%1"=="dll" (
cl /c %CFLAGS% /Foobj/bls_c256.obj src/bls_c256.cpp /DBLS_NO_AUTOLINK
cl /c %CFLAGS% /Foobj/bls_c384.obj src/bls_c384.cpp /DBLS_NO_AUTOLINK
cl /c %CFLAGS% /Foobj/fp.obj ../mcl/src/fp.cpp
link /nologo /DLL /OUT:bin\bls256.dll obj\bls_c256.obj obj\fp.obj %LDFLAGS% /implib:lib\bls256.lib
link /nologo /DLL /OUT:bin\bls384.dll obj\bls_c384.obj obj\fp.obj %LDFLAGS% /implib:lib\bls384.lib
) else (
cl /c %CFLAGS% /Foobj/bls_c256.obj src/bls_c256.cpp
cl /c %CFLAGS% /Foobj/bls_c384.obj src/bls_c384.cpp
cl /c %CFLAGS% /Foobj/fp.obj ../mcl/src/fp.cpp /DMCLBN_DONT_EXPORT
lib /OUT:lib/bls256.lib /nodefaultlib obj/bls_c256.obj obj/fp.obj %LDFLAGS%
lib /OUT:lib/bls384.lib /nodefaultlib obj/bls_c384.obj obj/fp.obj %LDFLAGS%
)