build: Generate package-config file

Change-Id: I4aeaa38e190d2327e08106d42f83f9476beccccd
Signed-off-by: Deepak Kodihalli <dkodihal@in.ibm.com>
diff --git a/Makefile.am b/Makefile.am
index 6e63e81..105f33a 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -10,6 +10,9 @@
 BUILT_SOURCES = libopenpower_dbus.cpp
 CLEANFILES = libopenpower_dbus.cpp
 
+pkgconfiglibdir = ${libdir}/pkgconfig
+pkgconfiglib_DATA = openpower-dbus-interfaces.pc
+
 clean-local: clean-dbus
 
 -include Makefile.interfaces
diff --git a/configure.ac b/configure.ac
index f194a38..35f80a2 100644
--- a/configure.ac
+++ b/configure.ac
@@ -34,4 +34,5 @@
     [${srcdir}/generate_makefile.sh ${srcdir} > Makefile.interfaces])
 
 AC_CONFIG_FILES([Makefile])
+AC_CONFIG_FILES([openpower-dbus-interfaces.pc])
 AC_OUTPUT
diff --git a/openpower-dbus-interfaces.pc.in b/openpower-dbus-interfaces.pc.in
new file mode 100644
index 0000000..5ec151e
--- /dev/null
+++ b/openpower-dbus-interfaces.pc.in
@@ -0,0 +1,12 @@
+prefix=@prefix@
+exec_prefix=@exec_prefix@
+libdir=@libdir@
+includedir=@includedir@
+
+Name: openpower-dbus-interfaces
+Description: Generated sdbusplus bindings for openpower-dbus-interfaces.
+URL: https://github.com/openbmc/openpower-dbus-interfaces
+Version: @VERSION@
+Requires.private: @AX_PACKAGE_REQUIRES_PRIVATE@
+Libs: -L@libdir@ -lopenpower_dbus
+Cflags: -I@includedir@