Re: [PATCH 2/2] Support for pkg-config
Hi Remi, > > Name: @PACKAGE@ > > Description: oFono - Open Source Telephony > > Requires: glib-2.0 dbus-1 > > Hmm, wasn't the goal to not leak glib through the public API? I could not > find > any glib type from a quick check in include/ofono/ ... let's face it, you will integrate with glib one way or another in your plugin. That we don't wanna our API to be using glib types is a different story. Regards Marcel ___ ofono mailing list ofono@ofono.org http://lists.ofono.org/listinfo/ofono
Re: [PATCH 2/2] Support for pkg-config
On Wednesday 26 January 2011 13:27:23 ext Marcel Holtmann, you wrote: > Name: @PACKAGE@ > Description: oFono - Open Source Telephony > Requires: glib-2.0 dbus-1 Hmm, wasn't the goal to not leak glib through the public API? I could not find any glib type from a quick check in include/ofono/ ... -- Rémi Denis-Courmont Nokia Devices R&D, Maemo Software, Helsinki ___ ofono mailing list ofono@ofono.org http://lists.ofono.org/listinfo/ofono
Re: [PATCH 2/2] Support for pkg-config
Hi Remi, > > prefix=@prefix@ > > exec_prefix=@exec_prefix@ > > libdir=@libdir@ > > includedir=@includedir@ > > > > plugindir=${libdir}/@PACKAGE@/plugins > > > > Name: @PACKAGE@ > > Description: oFono - Open Source Telephony > > Requires: glib-2.0 dbus-1 > > Version: @VERSION@ > > Libs: -module -avoid-version -export-symbols-regex @PACKAGE@_plugin_desc > > In my experience, automake does not fancy LDFLAGS in LIBADD/LDADD. Call that > a > pkg-config limitation if you want. so pkg-config --libs clearly is for "all linker flags". So that seems pretty much fine. Alternatives are --libs-only-*. Regards Marcel ___ ofono mailing list ofono@ofono.org http://lists.ofono.org/listinfo/ofono
Re: [PATCH 2/2] Support for pkg-config
On Wednesday 26 January 2011 13:27:23 ext Marcel Holtmann, you wrote: > prefix=@prefix@ > exec_prefix=@exec_prefix@ > libdir=@libdir@ > includedir=@includedir@ > > plugindir=${libdir}/@PACKAGE@/plugins > > Name: @PACKAGE@ > Description: oFono - Open Source Telephony > Requires: glib-2.0 dbus-1 > Version: @VERSION@ > Libs: -module -avoid-version -export-symbols-regex @PACKAGE@_plugin_desc In my experience, automake does not fancy LDFLAGS in LIBADD/LDADD. Call that a pkg-config limitation if you want. > Cflags: -I${includedir} -- Rémi Denis-Courmont Nokia Devices R&D, Maemo Software, Helsinki ___ ofono mailing list ofono@ofono.org http://lists.ofono.org/listinfo/ofono
Re: [PATCH 2/2] Support for pkg-config
Hi Remi, > .gitignore |1 + > Makefile.am |3 +++ > configure.ac |2 +- > ofono.pc.in | 10 ++ > 4 files changed, 15 insertions(+), 1 deletions(-) > create mode 100644 ofono.pc.in > > diff --git a/.gitignore b/.gitignore > index 7cfb1d9..59308be 100644 > --- a/.gitignore > +++ b/.gitignore > @@ -20,6 +20,7 @@ install-sh > libtool > ltmain.sh > missing > +ofono.pc > stamp-h1 > autom4te.cache please put ofono.pc on top of include/ofono line. > diff --git a/Makefile.am b/Makefile.am > index 71365d7..3b29d19 100644 > --- a/Makefile.am > +++ b/Makefile.am > @@ -21,6 +21,9 @@ local_headers = $(foreach file,$(pkginclude_HEADERS) \ > $(nodist_pkginclude_HEADERS), \ > include/ofono/$(notdir $(file))) > > +pkgconfigdir = $(libdir)/pkgconfig > +pkgconfig_DATA = ofono.pc > + > > if DATAFILES > dbusconfdir = @DBUS_CONFDIR@ > diff --git a/configure.ac b/configure.ac > index b034ff0..d26b64f 100644 > --- a/configure.ac > +++ b/configure.ac > @@ -226,4 +226,4 @@ fi > AC_DEFINE_UNQUOTED(CONFIGDIR, "${configdir}", > [Directory for the configuration files]) > > -AC_OUTPUT(Makefile include/version.h src/ofono.service) > +AC_OUTPUT(Makefile include/version.h src/ofono.service ofono.pc) > diff --git a/ofono.pc.in b/ofono.pc.in > new file mode 100644 > index 000..19f12e6 > --- /dev/null > +++ b/ofono.pc.in > @@ -0,0 +1,10 @@ > +prefix=@prefix@ > +exec_prefix=@exec_prefix@ > +libdir=@libdir@ > +plugindir=${libdir}/@PACKAGE@/plugins Please remove plugindir in a separate paragraph. > +includedir=@includedir@ > + > +Name: oFono This needs to be all lowercase. So just ofono. > +Description: oFono - Open Source Telephony > +Version: @VERSION@ You are missing the Libs: and Requires: line here. > +Cflags: -I${includedir} Something like this should do it: prefix=@prefix@ exec_prefix=@exec_prefix@ libdir=@libdir@ includedir=@includedir@ plugindir=${libdir}/@PACKAGE@/plugins Name: @PACKAGE@ Description: oFono - Open Source Telephony Requires: glib-2.0 dbus-1 Version: @VERSION@ Libs: -module -avoid-version -export-symbols-regex @PACKAGE@_plugin_desc Cflags: -I${includedir} Otherwise you are a bit out of luck when building external plugins. Regards Marcel ___ ofono mailing list ofono@ofono.org http://lists.ofono.org/listinfo/ofono
[PATCH 2/2] Support for pkg-config
--- .gitignore |1 + Makefile.am |3 +++ configure.ac |2 +- ofono.pc.in | 10 ++ 4 files changed, 15 insertions(+), 1 deletions(-) create mode 100644 ofono.pc.in diff --git a/.gitignore b/.gitignore index 7cfb1d9..59308be 100644 --- a/.gitignore +++ b/.gitignore @@ -20,6 +20,7 @@ install-sh libtool ltmain.sh missing +ofono.pc stamp-h1 autom4te.cache diff --git a/Makefile.am b/Makefile.am index 71365d7..3b29d19 100644 --- a/Makefile.am +++ b/Makefile.am @@ -21,6 +21,9 @@ local_headers = $(foreach file,$(pkginclude_HEADERS) \ $(nodist_pkginclude_HEADERS), \ include/ofono/$(notdir $(file))) +pkgconfigdir = $(libdir)/pkgconfig +pkgconfig_DATA = ofono.pc + if DATAFILES dbusconfdir = @DBUS_CONFDIR@ diff --git a/configure.ac b/configure.ac index b034ff0..d26b64f 100644 --- a/configure.ac +++ b/configure.ac @@ -226,4 +226,4 @@ fi AC_DEFINE_UNQUOTED(CONFIGDIR, "${configdir}", [Directory for the configuration files]) -AC_OUTPUT(Makefile include/version.h src/ofono.service) +AC_OUTPUT(Makefile include/version.h src/ofono.service ofono.pc) diff --git a/ofono.pc.in b/ofono.pc.in new file mode 100644 index 000..19f12e6 --- /dev/null +++ b/ofono.pc.in @@ -0,0 +1,10 @@ +prefix=@prefix@ +exec_prefix=@exec_prefix@ +libdir=@libdir@ +plugindir=${libdir}/@PACKAGE@/plugins +includedir=@includedir@ + +Name: oFono +Description: oFono - Open Source Telephony +Version: @VERSION@ +Cflags: -I${includedir} -- 1.7.1 ___ ofono mailing list ofono@ofono.org http://lists.ofono.org/listinfo/ofono