From 8b0afc6df1bb369e5e20eead56f61e6af914bef6 Mon Sep 17 00:00:00 2001 From: Richard Hughes Date: Wed, 22 Aug 2007 14:33:56 +0100 Subject: [PATCH] add initial apt build framework. based on a patch from Tom Parker many thanks. --- configure.ac | 11 +++++++++++ src/Makefile.am | 7 +++++++ 2 files changed, 18 insertions(+) diff --git a/configure.ac b/configure.ac index 4f4cd6d59..6c139e9d3 100644 --- a/configure.ac +++ b/configure.ac @@ -162,6 +162,17 @@ if test x$with_backend = x; then with_backend=dummy fi fi + +# apt has other BR's +if test x$with_backend = xapt; then +# This does not work for me on fedora +# PKG_CHECK_MODULES(APT,libapt-pkg) + APT_CFLAGS="-I/usr/include/apt-pkg" + APT_LIBS="-lapt-pkg" + AC_SUBST(APT_CFLAGS) + AC_SUBST(APT_LIBS) +fi + AM_CONDITIONAL(BACKEND_TYPE_DUMMY, [test x$with_backend = xdummy], [using dummy backend]) AM_CONDITIONAL(BACKEND_TYPE_APT, [test x$with_backend = xapt], [using APT backend]) AM_CONDITIONAL(BACKEND_TYPE_YUM, [test x$with_backend = xyum], [using YUM backend]) diff --git a/src/Makefile.am b/src/Makefile.am index a05e8615c..0873c9f50 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -75,6 +75,13 @@ packagekitd_LDADD = \ $(POLKIT_LIBS) \ $(NULL) +if BACKEND_TYPE_APT +packagekitd_INCLUDES = \ + $(APT_CFLAGS) +packagekitd_LDADD += \ + $(APT_LIBS) +endif + BUILT_SOURCES = \ pk-marshal.c \ pk-marshal.h \