commit 85358fea26e41d289c31dfe52eb74c076c2534b8
parent 7f1cd658ba1388818120067767aa9c3e2a34f8f7
Author: Heikki Lindholm <holin@iki.fi>
Date: Thu, 20 Nov 2008 12:14:51 +0000
move LDFLAGS and version info to configure.ac
Diffstat:
3 files changed, 35 insertions(+), 9 deletions(-)
diff --git a/configure.ac b/configure.ac
@@ -27,6 +27,13 @@ AM_CONFIG_HEADER([MHD_config.h])
AH_TOP([#define _GNU_SOURCE 1])
+LIB_VERSION_CURRENT=4
+LIB_VERSION_REVISION=3
+LIB_VERSION_AGE=0
+AC_SUBST(LIB_VERSION_CURRENT)
+AC_SUBST(LIB_VERSION_REVISION)
+AC_SUBST(LIB_VERSION_AGE)
+
if test `uname -s` = "OS/390"
then
# configure binaries for z/OS
@@ -183,7 +190,7 @@ AC_SYS_LARGEFILE
AC_FUNC_FSEEKO
# optional: have error messages ?
-AC_MSG_CHECKING(--enable-messages argument)
+AC_MSG_CHECKING(whether to enable error messages)
AC_ARG_ENABLE(messages,
[AS_HELP_STRING([--enable-messages],
[enable MHD error messages])],
@@ -265,6 +272,9 @@ AC_ARG_ENABLE([coverage], AS_HELP_STRING([--enable-coverage],
AM_CONDITIONAL([USE_COVERAGE], [test "x$use_gcov" = "xyes"])
+MHD_LIB_LDFLAGS="-export-dynamic -no-undefined"
+MHD_LIB_LDFLAGS="$MHD_LIB_LDFLAGS -export-symbols \$(srcdir)/EXPORT.sym"
+AC_SUBST(MHD_LIB_LDFLAGS)
AC_SUBST(CPPFLAGS)
diff --git a/src/daemon/EXPORT.sym b/src/daemon/EXPORT.sym
@@ -0,0 +1,21 @@
+MHD_start_daemon
+MHD_stop_daemon
+MHD_get_fdset
+MHD_get_timeout
+MHD_run
+MHD_get_connection_values
+MHD_set_connection_value
+MHD_lookup_connection_value
+MHD_queue_response
+MHD_create_response_from_callback
+MHD_create_response_from_data
+MHD_destroy_response
+MHD_add_response_header
+MHD_del_response_header
+MHD_get_response_headers
+MHD_get_response_header
+MHD_create_post_processor
+MHD_post_process
+MHD_destroy_post_processor
+MHD_get_daemon_info
+MHD_get_connection_info
diff --git a/src/daemon/Makefile.am b/src/daemon/Makefile.am
@@ -8,12 +8,7 @@ AM_CPPFLAGS = \
-I$(top_srcdir)/src/daemon/https \
@LIBGCRYPT_CFLAGS@
-if HAVE_GNU_LD
-# If you want to debug with gdb, comment out this line:
- retaincommand=-Wl,--retain-symbols-file -Wl,$(srcdir)/SYMBOLS
-endif
-
-EXTRA_DIST = SYMBOLS
+EXTRA_DIST = EXPORT.sym
lib_LTLIBRARIES = \
libmicrohttpd.la
@@ -27,8 +22,8 @@ libmicrohttpd_la_SOURCES = \
postprocessor.c \
response.c response.h
libmicrohttpd_la_LDFLAGS = \
- -version-info 4:3:0 \
- -export-dynamic $(retaincommand)
+ $(MHD_LIB_LDFLAGS) \
+ -version-info @LIB_VERSION_CURRENT@:@LIB_VERSION_REVISION@:@LIB_VERSION_AGE@
if USE_COVERAGE
AM_CFLAGS = --coverage