mirror of
https://github.com/cuberite/libevent.git
synced 2025-09-13 06:16:10 -04:00
Provide a mechanism for building the library on Windows with different compiler flags. Add a batch file that builds it for the M[DT][d] options and performs a hunt and gather of the different output libraries.
This commit is contained in:
parent
c9e6c3d70f
commit
ded8086656
@ -25,6 +25,9 @@ CFLAGS=/IWIN32-Code /IWIN32-Code/nmake /Iinclude /Icompat /DHAVE_CONFIG_H /I. $(
|
|||||||
# For optimization and warnings
|
# For optimization and warnings
|
||||||
CFLAGS=$(CFLAGS) /Ox /W3 /wd4996 /nologo
|
CFLAGS=$(CFLAGS) /Ox /W3 /wd4996 /nologo
|
||||||
|
|
||||||
|
# Add BUILD_CFLAGS from the environment
|
||||||
|
CFLAGS=$(CFLAGS) $(BUILD_CFLAGS)
|
||||||
|
|
||||||
# XXXX have a debug mode
|
# XXXX have a debug mode
|
||||||
|
|
||||||
LIBFLAGS=/nologo
|
LIBFLAGS=/nologo
|
||||||
@ -48,7 +51,6 @@ SSL_LIBS=
|
|||||||
ALL_OBJS=$(CORE_OBJS) $(WIN_OBJS) $(EXTRA_OBJS) $(SSL_OBJS)
|
ALL_OBJS=$(CORE_OBJS) $(WIN_OBJS) $(EXTRA_OBJS) $(SSL_OBJS)
|
||||||
STATIC_LIBS=libevent_core.lib libevent_extras.lib libevent.lib $(SSL_LIBS)
|
STATIC_LIBS=libevent_core.lib libevent_extras.lib libevent.lib $(SSL_LIBS)
|
||||||
|
|
||||||
|
|
||||||
all: static_libs tests
|
all: static_libs tests
|
||||||
|
|
||||||
static_libs: $(STATIC_LIBS)
|
static_libs: $(STATIC_LIBS)
|
||||||
|
26
buildall.bat
Normal file
26
buildall.bat
Normal file
@ -0,0 +1,26 @@
|
|||||||
|
nmake -f Makefile.nmake clean
|
||||||
|
|
||||||
|
set BUILD_CFLAGS=/MT
|
||||||
|
nmake -f Makefile.nmake
|
||||||
|
mkdir lib\MT\Release
|
||||||
|
move libev*.lib lib\MT\Release
|
||||||
|
nmake -f Makefile.nmake clean
|
||||||
|
|
||||||
|
set BUILD_CFLAGS=/MTd
|
||||||
|
nmake -f Makefile.nmake
|
||||||
|
mkdir lib\MT\Debug
|
||||||
|
move libev*.lib lib\MT\Debug
|
||||||
|
nmake -f Makefile.nmake clean
|
||||||
|
|
||||||
|
set BUILD_CFLAGS=/MD
|
||||||
|
nmake -f Makefile.nmake
|
||||||
|
mkdir lib\MD\Release
|
||||||
|
move libev*.lib lib\MD\Release
|
||||||
|
nmake -f Makefile.nmake clean
|
||||||
|
|
||||||
|
set BUILD_CFLAGS=/MDd
|
||||||
|
nmake -f Makefile.nmake
|
||||||
|
mkdir lib\MD\Debug
|
||||||
|
move libev*.lib lib\MD\Debug
|
||||||
|
nmake -f Makefile.nmake clean
|
||||||
|
|
@ -14,6 +14,9 @@ CFLAGS=/I.. /I../WIN32-Code /I../WIN32-Code/nmake /I../include /I../compat /DHAV
|
|||||||
|
|
||||||
CFLAGS=$(CFLAGS) /Ox /W3 /wd4996 /nologo
|
CFLAGS=$(CFLAGS) /Ox /W3 /wd4996 /nologo
|
||||||
|
|
||||||
|
# Add BUILD_CFLAGS from the environment
|
||||||
|
CFLAGS=$(CFLAGS) $(BUILD_CFLAGS)
|
||||||
|
|
||||||
REGRESS_OBJS=regress.obj regress_buffer.obj regress_http.obj regress_dns.obj \
|
REGRESS_OBJS=regress.obj regress_buffer.obj regress_http.obj regress_dns.obj \
|
||||||
regress_testutils.obj \
|
regress_testutils.obj \
|
||||||
regress_rpc.obj regress.gen.obj \
|
regress_rpc.obj regress.gen.obj \
|
||||||
|
Loading…
x
Reference in New Issue
Block a user