summaryrefslogtreecommitdiff
path: root/common/ini
diff options
context:
space:
mode:
authorStephen Gallagher <sgallagh@redhat.com>2009-04-11 10:15:12 -0400
committerSimo Sorce <ssorce@redhat.com>2009-04-13 09:06:39 -0400
commitc1d6bffe9ba81c265042859dddf3b39be87c161b (patch)
tree34209f38304c86a78ea230b8d77c8cc76eeff90d /common/ini
parentb531c1872952c5f9a2a46d0a0dfe8dc63be470fd (diff)
downloadsssd-c1d6bffe9ba81c265042859dddf3b39be87c161b.tar.gz
sssd-c1d6bffe9ba81c265042859dddf3b39be87c161b.tar.bz2
sssd-c1d6bffe9ba81c265042859dddf3b39be87c161b.zip
Build system improvements for common tools
Allows building shared or static libraries using autotools and provides a pkg-config file to simplify inclusion into other parts of the project (or other projects in the future) For now, we will statically link the collection library and INI parser.
Diffstat (limited to 'common/ini')
-rw-r--r--common/ini/Makefile.am16
-rw-r--r--common/ini/ini_config.pc.in11
2 files changed, 20 insertions, 7 deletions
diff --git a/common/ini/Makefile.am b/common/ini/Makefile.am
index a673aecd..962172f6 100644
--- a/common/ini/Makefile.am
+++ b/common/ini/Makefile.am
@@ -4,14 +4,16 @@ TRACE_LEVEL=@TRACE_VAR@
topdir=..
AM_CPPFLAGS = -Wall -I$(topdir) -I$(topdir)/trace -I$(topdir)/collection $(TRACE_LEVEL)
-# Build static libraty
-noinst_LIBRARIES = libini_config.a
-libini_config_a_SOURCES = ini_config.c collection.h trace.h collection_tools.h collection_class.h ini_config.h
+# Set up the pkg-config file
+pkgconfigdir = $(libdir)/pkgconfig
+pkgconfig_DATA = ini_config.pc
-# Build shared library
-#lib_LTLIBRARIES = libini.la
-#libini_la_SOURCES = ini_config.c collection.h trace.h collection_tools.h collection_class.h ini_config.h
+# Build library
+lib_LTLIBRARIES = libini_config.la
+libini_config_la_SOURCES = ini_config.c collection.h collection_tools.h collection_class.h
+include_HEADERS = ini_config.h
+# Build unit test
noinst_PROGRAMS = ini_config_ut
ini_config_ut_SOURCES = ini_config_ut.c
-ini_config_ut_LDADD = libini_config.a -lm -lz ../collection/libcollection.a
+ini_config_ut_LDADD = libini_config.la -lm -lz ../collection/libcollection.la \ No newline at end of file
diff --git a/common/ini/ini_config.pc.in b/common/ini/ini_config.pc.in
new file mode 100644
index 00000000..d08e5b5e
--- /dev/null
+++ b/common/ini/ini_config.pc.in
@@ -0,0 +1,11 @@
+prefix=@prefix@
+exec_prefix=@exec_prefix@
+libdir=@libdir@
+includedir=@includedir@
+
+Name: ini_config
+Description: Library to process config files in INI format into a libcollection data structure
+Version: @PACKAGE_VERSION@
+Libs: -L${libdir} -lini_config
+Cflags: -I${includedir}
+URL: http://fedorahosted.org/sssd/