From: Lennart Poettering Date: Mon, 15 Aug 2005 18:54:32 +0000 (+0000) Subject: * Add pkg-config files for avahi-glib/avahi-client X-Git-Url: https://git.meshlink.io/?a=commitdiff_plain;h=86727e2f97a5e845d462178692c8574d226f22d7;p=catta * Add pkg-config files for avahi-glib/avahi-client * Generate .pc files with sed * use libtool for building libdbus-watch-glue git-svn-id: file:///home/lennart/svn/public/avahi/trunk@335 941a03a8-eaeb-0310-b9a0-b1bbd8fe43fe --- diff --git a/Makefile.am b/Makefile.am index e23db8e..719ecad 100644 --- a/Makefile.am +++ b/Makefile.am @@ -31,7 +31,10 @@ EXTRA_DIST = \ docs/DBUS-API \ docs/AUTHORS \ docs/HACKING \ - docs/overview.dia + docs/overview.dia \ + avahi-core.pc.in \ + avahi-client.pc.in \ + avahi-glib.pc.in SUBDIRS = \ common \ @@ -49,7 +52,23 @@ SUBDIRS = \ tests pkgconfigdir = $(libdir)/pkgconfig -pkgconfig_DATA = avahi-core.pc +pkgconfig_DATA = \ + avahi-core.pc \ + avahi-client.pc \ + avahi-glib.pc + +avahi-core.pc: avahi-core.pc.in + sed -e 's,@prefix\@,$(prefix),g' \ + -e 's,@PACKAGE_VERSION\@,$(PACKAGE_VERSION),g' $< > $@ + +avahi-client.pc: avahi-client.pc.in + sed -e 's,@prefix\@,$(prefix),g' \ + -e 's,@PACKAGE_VERSION\@,$(PACKAGE_VERSION),g' $< > $@ + +avahi-glib.pc: avahi-glib.pc.in + sed -e 's,@prefix\@,$(prefix),g' \ + -e 's,@PACKAGE_VERSION\@,$(PACKAGE_VERSION),g' $< > $@ + MOSTLYCLEANFILES = $(DX_CLEANFILES) diff --git a/avahi-client.pc.in b/avahi-client.pc.in new file mode 100644 index 0000000..23a4d4f --- /dev/null +++ b/avahi-client.pc.in @@ -0,0 +1,10 @@ +prefix=@prefix@ +exec_prefix=${prefix} +libdir=${exec_prefix}/lib +includedir=${prefix}/include + +Name: avahi-client +Description: Avahi Multicast DNS Responder (Client Support) +Version: @PACKAGE_VERSION@ +Libs: -L${libdir} -lavahi-common -lavahi-client +Cflags: -D_REENTRANT -I${includedir} diff --git a/avahi-client/Makefile.am b/avahi-client/Makefile.am index b7abf9f..0a5bffa 100644 --- a/avahi-client/Makefile.am +++ b/avahi-client/Makefile.am @@ -44,7 +44,8 @@ libavahi_client_la_SOURCES = \ browser.c libavahi_client_la_CFLAGS = $(AM_CFLAGS) $(DBUS_CFLAGS) -libavahi_client_la_LIBADD = $(AM_LDADD) $(DBUS_LIBS) ../avahi-common/libavahi-common.la ../avahi-common/libdbus-watch-glue.a +libavahi_client_la_LIBADD = $(AM_LDADD) $(DBUS_LIBS) ../avahi-common/libavahi-common.la ../avahi-common/libdbus-watch-glue.la +libavahi_client_la_LDFLAGS = $(AM_LDFLAGS) -export-dynamic -version-info 0:0:0 client_test_SOURCES = \ client-test.c diff --git a/avahi-common/Makefile.am b/avahi-common/Makefile.am index 4310797..c9c04e8 100644 --- a/avahi-common/Makefile.am +++ b/avahi-common/Makefile.am @@ -62,14 +62,13 @@ libavahi_common_la_SOURCES = \ watch.h gccmacro.h libavahi_common_la_CFLAGS = $(AM_CFLAGS) -libavahi_common_la_LIBADD = $(AM_LDADD) +libavahi_common_la_LDFLAGS = $(AM_LDFLAGS) -export-dynamic -version-info 0:0:0 strlst_test_SOURCES = \ strlst.c strlst.h \ malloc.c malloc.h \ strlst-test.c strlst_test_CFLAGS = $(AM_CFLAGS) -strlst_test_LDADD = $(AM_LDADD) alternative_test_SOURCES = \ alternative.c alternative.h \ @@ -77,14 +76,12 @@ alternative_test_SOURCES = \ domain.c domain.h \ alternative-test.c alternative_test_CFLAGS = $(AM_CFLAGS) -alternative_test_LDADD = $(AM_LDADD) domain_test_SOURCES = \ domain.c domain.h \ malloc.c malloc.h \ domain-test.c domain_test_CFLAGS = $(AM_CFLAGS) -domain_test_LDADD = $(AM_LDADD) watch_test_SOURCES = \ timeval.c timeval.h \ @@ -93,28 +90,25 @@ watch_test_SOURCES = \ malloc.c malloc.h \ watch-test.c watch_test_CFLAGS = $(AM_CFLAGS) -watch_test_LDADD = $(AM_LDADD) timeval_test_SOURCES = \ timeval.c timeval.h \ timeval-test.c timeval_test_CFLAGS = $(AM_CFLAGS) -timeval_test_LDADD = $(AM_LDADD) - - if ENABLE_DBUS + noinst_HEADERS += \ dbus.h \ dbus-watch-glue.h -noinst_LIBRARIES = \ - libdbus-watch-glue.a +noinst_LTLIBRARIES = \ + libdbus-watch-glue.la -libdbus_watch_glue_a_SOURCES = \ +libdbus_watch_glue_la_SOURCES = \ dbus-watch-glue.h dbus-watch-glue.c - -libdbus_watch_glue_a_CFLAGS = $(AM_CFLAGS) $(DBUS_CFLAGS) +libdbus_watch_glue_la_CFLAGS = $(AM_CFLAGS) $(DBUS_CFLAGS) +libdbus_watch_glue_la_LDFLAGS = $(AM_LDFLAGS) -static -export-dynamic endif diff --git a/avahi-core.pc.in b/avahi-core.pc.in index 1dcbb8a..e8629c0 100644 --- a/avahi-core.pc.in +++ b/avahi-core.pc.in @@ -4,7 +4,7 @@ libdir=${exec_prefix}/lib includedir=${prefix}/include Name: avahi-core -Description: Avahi Embeddable Multicast DNS Engine +Description: Avahi Multicast DNS Responder (Embeddable Stack) Version: @PACKAGE_VERSION@ -Libs: -L${libdir} -lavahi-core -lavahi-common +Libs: -L${libdir} -lavahi-common -lavahi-core Cflags: -D_REENTRANT -I${includedir} diff --git a/avahi-core/Makefile.am b/avahi-core/Makefile.am index a300560..71f698e 100644 --- a/avahi-core/Makefile.am +++ b/avahi-core/Makefile.am @@ -78,6 +78,7 @@ libavahi_core_la_SOURCES = \ libavahi_core_la_CFLAGS = $(AM_CFLAGS) libavahi_core_la_LIBADD = $(AM_LDADD) $(COMMON_LDADD) +libavahi_core_la_LDFLAGS = $(AM_LDFLAGS) -export-dynamic -version-info 0:0:0 prioq_test_SOURCES = \ prioq-test.c \ diff --git a/avahi-daemon/Makefile.am b/avahi-daemon/Makefile.am index 2792f21..563b8d1 100644 --- a/avahi-daemon/Makefile.am +++ b/avahi-daemon/Makefile.am @@ -92,12 +92,13 @@ EXTRA_DIST = \ introspect.xsl if ENABLE_DBUS + avahi_daemon_SOURCES += \ dbus-protocol.c \ dbus-protocol.h avahi_daemon_LDADD += \ - ../avahi-common/libdbus-watch-glue.a + ../avahi-common/libdbus-watch-glue.la dbusservice_DATA = avahi-dbus.conf diff --git a/avahi-glib.pc.in b/avahi-glib.pc.in new file mode 100644 index 0000000..6556047 --- /dev/null +++ b/avahi-glib.pc.in @@ -0,0 +1,11 @@ +prefix=@prefix@ +exec_prefix=${prefix} +libdir=${exec_prefix}/lib +includedir=${prefix}/include + +Name: avahi-glib +Description: Avahi Multicast DNS Responder (GLib Support) +Version: @PACKAGE_VERSION@ +Requires: glib-2.0 +Libs: -L${libdir} -lavahi-commong -lavahi-glib +Cflags: -D_REENTRANT -I${includedir} diff --git a/configure.ac b/configure.ac index 99803ec..693a7bc 100644 --- a/configure.ac +++ b/configure.ac @@ -280,7 +280,6 @@ AM_CONDITIONAL(HAVE_PYTHON, [test "x$HAVE_PYTHON" = xyes ]) # ========================================================================== AC_CONFIG_FILES([ Makefile -avahi-core.pc avahi-common/Makefile avahi-core/Makefile avahi-glib/Makefile