Browse Source

Fix automake to build shared libraries

personal/stbuehler/wip
Stefan Bühler 13 years ago
parent
commit
b61013d9e0
  1. 2
      src/angel/Makefile.am
  2. 7
      src/common/Makefile.am
  3. 2
      src/main/Makefile.am
  4. 35
      src/modules/Makefile.am

2
src/angel/Makefile.am

@ -20,4 +20,4 @@ lighttpd_angel_SOURCES=angel_main.c $(lighttpd_angel_shared_src)
lighttpd_angel_CPPFLAGS=$(common_cflags) $(GTHREAD_CFLAGS) $(GMODULE_CFLAGS) $(LIBEV_CFLAGS) $(LUA_CFLAGS) -DDEFAULT_LIBDIR='"$(pkglibdir)"'
lighttpd_angel_LDFLAGS=-export-dynamic $(GTHREAD_LIBS) $(GMODULE_LIBS) $(LIBEV_LIBS) $(LUA_LIBS)
lighttpd_angel_LDADD=../common/libcommon.a
lighttpd_angel_LDADD=../common/liblighttpd-common.la

7
src/common/Makefile.am

@ -1,5 +1,5 @@
noinst_LIBRARIES=libcommon.a
lib_LTLIBRARIES=liblighttpd-common.la
common_cflags=-I$(top_srcdir)/include -I$(top_builddir)/include
common_src= \
@ -20,5 +20,6 @@ BUILT_SOURCES=ip_parsers.c
ip_parsers.c: ip_parsers.rl
ragel -C -T1 -o $@ $<
libcommon_a_SOURCES=$(common_src)
libcommon_a_CPPFLAGS=$(common_cflags) $(GTHREAD_CFLAGS) $(GMODULE_CFLAGS) $(LIBEV_CFLAGS) $(LUA_CFLAGS)
liblighttpd_common_la_SOURCES=$(common_src)
liblighttpd_common_la_CPPFLAGS=$(common_cflags) $(GTHREAD_CFLAGS) $(GMODULE_CFLAGS) $(LIBEV_CFLAGS)
liblighttpd_common_la_LDFLAGS=-export-dynamic $(GTHREAD_LIBS) $(GMODULE_LIBS) $(LIBEV_LIBS)

2
src/main/Makefile.am

@ -66,4 +66,4 @@ lighttpd_SOURCES=lighttpd.c $(lighttpd_shared_src)
lighttpd_CPPFLAGS=$(common_cflags) $(GTHREAD_CFLAGS) $(GMODULE_CFLAGS) $(LIBEV_CFLAGS) $(LUA_CFLAGS) -DDEFAULT_LIBDIR='"$(pkglibdir)"'
lighttpd_LDFLAGS=-export-dynamic $(GTHREAD_LIBS) $(GMODULE_LIBS) $(LIBEV_LIBS) $(LUA_LIBS)
lighttpd_LDADD=../common/libcommon.a
lighttpd_LDADD=../common/liblighttpd-common.la

35
src/modules/Makefile.am

@ -2,84 +2,85 @@ install_libs =
common_cflags = -I$(top_srcdir)/include -I$(top_builddir)/include
common_cflags += $(GTHREAD_CFLAGS) $(GMODULE_CFLAGS) $(LIBEV_CFLAGS) $(LUA_CFLAGS) $(OPENSSL_CFLAGS)
common_libadd = $(GTHREAD_LIBS) $(GMODULE_LIBS) $(LIBEV_LIBS) $(LUA_LIBS)
common_ldflags = -module -export-dynamic -avoid-version -no-undefined $(common_libadd)
common_libs = $(GTHREAD_LIBS) $(GMODULE_LIBS) $(LIBEV_LIBS) $(LUA_LIBS)
common_ldflags = -module -export-dynamic -avoid-version -no-undefined $(common_libs)
common_libadd = ../common/liblighttpd-common.la
AM_CPPFLAGS = $(common_cflags)
install_libs += libmod_access.la
libmod_access_la_SOURCES = mod_access.c
libmod_access_la_LDFLAGS = $(common_ldflags)
# libmod_access_la_LIBADD = $(common_libadd)
libmod_access_la_LIBADD = $(common_libadd)
install_libs += libmod_accesslog.la
libmod_accesslog_la_SOURCES = mod_accesslog.c
libmod_accesslog_la_LDFLAGS = $(common_ldflags)
# libmod_accesslog_la_LIBADD = $(common_libadd)
libmod_accesslog_la_LIBADD = $(common_libadd)
install_libs += libmod_auth.la
libmod_auth_la_SOURCES = mod_auth.c
libmod_auth_la_LDFLAGS = $(common_ldflags)
# libmod_auth_la_LIBADD = $(common_libadd)
libmod_auth_la_LIBADD = $(common_libadd)
install_libs += libmod_balancer.la
libmod_balancer_la_SOURCES = mod_balancer.c
libmod_balancer_la_LDFLAGS = $(common_ldflags)
# libmod_balancer_la_LIBADD = $(common_libadd)
libmod_balancer_la_LIBADD = $(common_libadd)
install_libs += libmod_cache_disk_etag.la
libmod_cache_disk_etag_la_SOURCES = mod_cache_disk_etag.c
libmod_cache_disk_etag_la_LDFLAGS = $(common_ldflags)
# libmod_cache_disk_etag_la_LIBADD = $(common_libadd)
libmod_cache_disk_etag_la_LIBADD = $(common_libadd)
install_libs += libmod_debug.la
libmod_debug_la_SOURCES = mod_debug.c
libmod_debug_la_LDFLAGS = $(common_ldflags)
# libmod_debug_la_LIBADD = $(common_libadd)
libmod_debug_la_LIBADD = $(common_libadd)
install_libs += libmod_dirlist.la
libmod_dirlist_la_SOURCES = mod_dirlist.c
libmod_dirlist_la_LDFLAGS = $(common_ldflags)
# libmod_dirlist_la_LIBADD = $(common_libadd)
libmod_dirlist_la_LIBADD = $(common_libadd)
install_libs += libmod_expire.la
libmod_expire_la_SOURCES = mod_expire.c
libmod_expire_la_LDFLAGS = $(common_ldflags)
# libmod_expire_la_LIBADD = $(common_libadd)
libmod_expire_la_LIBADD = $(common_libadd)
install_libs += libmod_fastcgi.la
libmod_fastcgi_la_SOURCES = mod_fastcgi.c
libmod_fastcgi_la_LDFLAGS = $(common_ldflags)
# libmod_fastcgi_la_LIBADD = $(common_libadd)
libmod_fastcgi_la_LIBADD = $(common_libadd)
install_libs += libmod_fortune.la
libmod_fortune_la_SOURCES = mod_fortune.c
libmod_fortune_la_LDFLAGS = $(common_ldflags)
# libmod_fortune_la_LIBADD = $(common_libadd)
libmod_fortune_la_LIBADD = $(common_libadd)
install_libs += libmod_openssl.la
libmod_openssl_la_SOURCES = mod_openssl.c
libmod_openssl_la_LDFLAGS = $(common_ldflags) $(OPENSSL_LIBS)
# libmod_openssl_la_LIBADD = $(common_libadd)
libmod_openssl_la_LIBADD = $(common_libadd)
install_libs += libmod_redirect.la
libmod_redirect_la_SOURCES = mod_redirect.c
libmod_redirect_la_LDFLAGS = $(common_ldflags)
# libmod_redirect_la_LIBADD = $(common_libadd)
libmod_redirect_la_LIBADD = $(common_libadd)
install_libs += libmod_rewrite.la
libmod_rewrite_la_SOURCES = mod_rewrite.c
libmod_rewrite_la_LDFLAGS = $(common_ldflags)
# libmod_rewrite_la_LIBADD = $(common_libadd)
libmod_rewrite_la_LIBADD = $(common_libadd)
install_libs += libmod_status.la
libmod_status_la_SOURCES = mod_status.c
libmod_status_la_LDFLAGS = $(common_ldflags)
# libmod_status_la_LIBADD = $(common_libadd)
libmod_status_la_LIBADD = $(common_libadd)
install_libs += libmod_vhost.la
libmod_vhost_la_SOURCES = mod_vhost.c
libmod_vhost_la_LDFLAGS = $(common_ldflags)
# libmod_vhost_la_LIBADD = $(common_libadd)
libmod_vhost_la_LIBADD = $(common_libadd)
pkglib_LTLIBRARIES=$(install_libs)

Loading…
Cancel
Save