aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEvgeny Grin (Karlson2k) <k2k@narod.ru>2014-02-20 13:16:57 +0000
committerEvgeny Grin (Karlson2k) <k2k@narod.ru>2014-02-20 13:16:57 +0000
commite4791b96c8c3d172b25db65f15f46d086362c0f1 (patch)
tree5fd5b6f52ae97d470333b395e9c76d44ae8cc5f3
parentf5dd0355a32915d9524004e8b1c0e0a6b360c604 (diff)
downloadlibmicrohttpd-e4791b96c8c3d172b25db65f15f46d086362c0f1.tar.gz
libmicrohttpd-e4791b96c8c3d172b25db65f15f46d086362c0f1.zip
create W32 static lib with MS lib.exe if available
-rw-r--r--configure.ac1
-rw-r--r--src/microhttpd/Makefile.am12
2 files changed, 13 insertions, 0 deletions
diff --git a/configure.ac b/configure.ac
index 8d5b9e6a..c6159d00 100644
--- a/configure.ac
+++ b/configure.ac
@@ -206,6 +206,7 @@ if test "x$enable_shared" = "xyes" && test "x$os_is_native_w32" = "xyes"; then
206fi 206fi
207AM_CONDITIONAL(W32_SHARED_LIB_EXP, [test "x$w32_shared_lib_exp" = "xyes"]) 207AM_CONDITIONAL(W32_SHARED_LIB_EXP, [test "x$w32_shared_lib_exp" = "xyes"])
208AM_CONDITIONAL(USE_MS_LIB_TOOL, [test "x$ac_cv_use_ms_lib_tool" = "xyes"]) 208AM_CONDITIONAL(USE_MS_LIB_TOOL, [test "x$ac_cv_use_ms_lib_tool" = "xyes"])
209AM_CONDITIONAL(W32_STATIC_LIB, [test "x$os_is_native_w32" = "xyes" && test "x$enable_static" = "xyes"])
209 210
210 211
211if test "$enable_epoll" = "yes" 212if test "$enable_epoll" = "yes"
diff --git a/src/microhttpd/Makefile.am b/src/microhttpd/Makefile.am
index ee39c31b..489a3a22 100644
--- a/src/microhttpd/Makefile.am
+++ b/src/microhttpd/Makefile.am
@@ -43,6 +43,18 @@ else
43 W32_MHD_LIB_LDFLAGS = 43 W32_MHD_LIB_LDFLAGS =
44endif 44endif
45 45
46if W32_STATIC_LIB
47noinst_DATA += $(lt_cv_objdir)/libmicrohttpd-static.lib
48MOSTLYCLEANFILES += $(lt_cv_objdir)/libmicrohttpd-static.lib
49
50$(lt_cv_objdir)/libmicrohttpd-static.lib: libmicrohttpd.la $(libmicrohttpd_la_OBJECTS)
51if USE_MS_LIB_TOOL
52 $(MS_LIB_TOOL) -out:$@ $(libmicrohttpd_la_OBJECTS:.lo=.o)
53else
54 cp $(lt_cv_objdir)/libmicrohttpd.a $@
55endif
56endif
57
46 58
47libmicrohttpd_la_SOURCES = \ 59libmicrohttpd_la_SOURCES = \
48 connection.c connection.h \ 60 connection.c connection.h \