summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPanu Matilainen <pmatilai@redhat.com>2008-05-12 12:28:12 +0300
committerPanu Matilainen <pmatilai@redhat.com>2008-05-12 12:28:12 +0300
commit90e10708f824ff8e86b0f030d12e14329b1cf2c0 (patch)
tree7e6acf37286a04ed0d3e9f7ba0729af5a11bb878
parenta68a5a049e98bc8406c0e7015ad5dadbed39972d (diff)
downloadrpm-90e10708f824ff8e86b0f030d12e14329b1cf2c0.tar.gz
rpm-90e10708f824ff8e86b0f030d12e14329b1cf2c0.tar.bz2
rpm-90e10708f824ff8e86b0f030d12e14329b1cf2c0.zip
Fixup paths and Makefiles for rpmdb/ elimination
-rw-r--r--Makefile.am26
-rw-r--r--build/Makefile.am1
-rw-r--r--configure.ac4
-rw-r--r--lib/Makefile.am141
-rw-r--r--lib/backend/db3.c4
-rw-r--r--lib/backend/dbconfig.c6
-rw-r--r--lib/backend/sqlite.c2
-rw-r--r--lib/depends.c2
-rw-r--r--lib/fprint.c6
-rw-r--r--lib/fprint.h4
-rw-r--r--lib/hdrNVR.c2
-rw-r--r--lib/header.c4
-rw-r--r--lib/header.h2
-rw-r--r--lib/header_internal.c4
-rw-r--r--lib/header_internal.h2
-rw-r--r--lib/merge.c2
-rw-r--r--lib/package.c2
-rw-r--r--lib/poptDB.c2
-rw-r--r--lib/rpmdb.c8
-rw-r--r--lib/rpmdb.h2
-rw-r--r--lib/rpmhash.c4
-rw-r--r--lib/rpmhash.h2
-rw-r--r--lib/rpmts_internal.h2
-rw-r--r--lib/signature.c2
-rw-r--r--lib/tagname.c2
-rw-r--r--lib/transaction.c4
-rw-r--r--po/POTFILES.in24
-rw-r--r--preinstall.am12
-rw-r--r--python/Makefile.am1
-rw-r--r--rpmdb/Makefile.am157
-rw-r--r--tools/dump.c2
-rw-r--r--tools/dumpdb.c2
32 files changed, 208 insertions, 232 deletions
diff --git a/Makefile.am b/Makefile.am
index 361c7959d..368b38ae2 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -19,16 +19,15 @@ endif
if WITH_LUAEXT
SUBDIRS += luaext
endif
-SUBDIRS += rpmio rpmdb lib build python scripts doc . tests
+SUBDIRS += rpmio lib build python scripts doc . tests
-DIST_SUBDIRS = po misc luaext rpmio rpmdb lib build python scripts doc tests
+DIST_SUBDIRS = po misc luaext rpmio lib build python scripts doc tests
pkgconfigdir = $(libdir)/pkgconfig
AM_CPPFLAGS = -I$(top_builddir) -I$(top_srcdir) -I$(top_builddir)/include/
AM_CPPFLAGS += -I$(top_srcdir)/build
AM_CPPFLAGS += -I$(top_srcdir)/lib
-AM_CPPFLAGS += -I$(top_builddir)/rpmdb -I$(top_srcdir)/rpmdb
AM_CPPFLAGS += -I$(top_srcdir)/rpmio
AM_CPPFLAGS += @WITH_NSS_INCLUDE@
AM_CPPFLAGS += @WITH_POPT_INCLUDE@
@@ -55,10 +54,8 @@ pkginclude_HEADERS += rpmio/rpmsw.h
pkginclude_HEADERS += rpmio/rpmfileutil.h
pkginclude_HEADERS += rpmio/rpmutil.h
-pkginclude_HEADERS += rpmdb/header.h
-pkginclude_HEADERS += rpmdb/rpmdb.h
-nodist_pkginclude_HEADERS += rpmdb/rpmints.h
-
+pkginclude_HEADERS += lib/header.h
+pkginclude_HEADERS += lib/rpmdb.h
pkginclude_HEADERS += lib/rpmcallback.h
pkginclude_HEADERS += lib/rpmcli.h
pkginclude_HEADERS += lib/rpmlib.h
@@ -72,6 +69,7 @@ pkginclude_HEADERS += lib/rpmte.h
pkginclude_HEADERS += lib/rpmts.h
pkginclude_HEADERS += lib/rpmtypes.h
pkginclude_HEADERS += lib/rpmvf.h
+nodist_pkginclude_HEADERS += lib/rpmints.h
pkginclude_HEADERS += build/rpmbuild.h
pkginclude_HEADERS += build/rpmfc.h
@@ -91,36 +89,36 @@ DISTCLEANFILES += find-requires
rpm_SOURCES = rpmqv.c debug.h system.h
rpm_CPPFLAGS = $(AM_CPPFLAGS) -DIAM_RPMDB -DIAM_RPMEIU -DIAM_RPMK -DIAM_RPMQV
-rpm_LDADD = build/librpmbuild.la lib/librpm.la rpmdb/librpmdb.la rpmio/librpmio.la
+rpm_LDADD = build/librpmbuild.la lib/librpm.la rpmio/librpmio.la
rpm_LDADD += @WITH_LIBELF_LIB@ @WITH_NSS_LIB@ @WITH_POPT_LIB@ @WITH_ZLIB_LIB@
rpmb_SOURCES = build.c rpmqv.c build.h debug.h system.h
rpmb_CPPFLAGS = $(AM_CPPFLAGS) -DIAM_RPMBT
-rpmb_LDADD = build/librpmbuild.la lib/librpm.la rpmdb/librpmdb.la rpmio/librpmio.la
+rpmb_LDADD = build/librpmbuild.la lib/librpm.la rpmio/librpmio.la
rpmb_LDADD += @WITH_LIBELF_LIB@ @WITH_NSS_LIB@ @WITH_POPT_LIB@ @WITH_ZLIB_LIB@
rpmd_SOURCES = rpmqv.c debug.h system.h
rpmd_CPPFLAGS = $(AM_CPPFLAGS) -DIAM_RPMDB
-rpmd_LDADD = lib/librpm.la rpmdb/librpmdb.la rpmio/librpmio.la
+rpmd_LDADD = lib/librpm.la rpmio/librpmio.la
rpmd_LDADD += @WITH_LIBELF_LIB@ @WITH_NSS_LIB@ @WITH_POPT_LIB@ @WITH_ZLIB_LIB@
rpmi_SOURCES = rpmqv.c debug.h system.h
rpmi_CPPFLAGS = $(AM_CPPFLAGS) -DIAM_RPMEIU
-rpmi_LDADD = lib/librpm.la rpmdb/librpmdb.la rpmio/librpmio.la
+rpmi_LDADD = lib/librpm.la rpmio/librpmio.la
rpmi_LDADD += @WITH_LIBELF_LIB@ @WITH_NSS_LIB@ @WITH_POPT_LIB@ @WITH_ZLIB_LIB@
rpmk_SOURCES = rpmqv.c debug.h system.h
rpmk_CPPFLAGS = $(AM_CPPFLAGS) -DIAM_RPMK
-rpmk_LDADD = lib/librpm.la rpmdb/librpmdb.la rpmio/librpmio.la
+rpmk_LDADD = lib/librpm.la rpmio/librpmio.la
rpmk_LDADD += @WITH_LIBELF_LIB@ @WITH_NSS_LIB@ @WITH_POPT_LIB@ @WITH_ZLIB_LIB@
rpmq_SOURCES = rpmqv.c debug.h system.h
rpmq_CPPFLAGS = $(AM_CPPFLAGS) -DIAM_RPMQV
-rpmq_LDADD = build/librpmbuild.la lib/librpm.la rpmdb/librpmdb.la rpmio/librpmio.la
+rpmq_LDADD = build/librpmbuild.la lib/librpm.la rpmio/librpmio.la
rpmq_LDADD += @WITH_LIBELF_LIB@ @WITH_NSS_LIB@ @WITH_POPT_LIB@ @WITH_ZLIB_LIB@
rpm2cpio_SOURCES = rpm2cpio.c debug.h system.h
-rpm2cpio_LDADD = lib/librpm.la rpmdb/librpmdb.la rpmio/librpmio.la
+rpm2cpio_LDADD = lib/librpm.la rpmio/librpmio.la
rpm2cpio_LDADD += @WITH_LIBELF_LIB@ @WITH_NSS_LIB@ @WITH_POPT_LIB@ @WITH_ZLIB_LIB@
diff --git a/build/Makefile.am b/build/Makefile.am
index 62ddf9b60..d03afefb8 100644
--- a/build/Makefile.am
+++ b/build/Makefile.am
@@ -17,7 +17,6 @@ librpmbuild_la_SOURCES = \
librpmbuild_la_LDFLAGS = -release 4.6
librpmbuild_la_LIBADD = \
$(top_builddir)/lib/librpm.la \
- $(top_builddir)/rpmdb/librpmdb.la \
$(top_builddir)/rpmio/librpmio.la \
@WITH_POPT_LIB@ \
@WITH_LIBELF_LIB@ \
diff --git a/configure.ac b/configure.ac
index 04c936c75..c2ff04438 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1028,10 +1028,10 @@ AC_DEFINE([__RPM_USES_STDINT_H__],[1],[if rpm uses stdint.h])
AC_SUBST([dirstamp],[\${am__leading_dot}dirstamp])
-AC_CONFIG_HEADERS([rpmdb/rpmints.h])
+AC_CONFIG_HEADERS([lib/rpmints.h])
AC_CONFIG_FILES([Makefile
- rpmio/Makefile rpmdb/Makefile lib/Makefile build/Makefile
+ rpmio/Makefile lib/Makefile build/Makefile
po/Makefile.in scripts/Makefile
misc/Makefile
doc/Makefile
diff --git a/lib/Makefile.am b/lib/Makefile.am
index 4f5e1932e..aac7b2eed 100644
--- a/lib/Makefile.am
+++ b/lib/Makefile.am
@@ -1,8 +1,11 @@
# Makefile for rpm library.
+include $(top_srcdir)/rpm.am
+
AM_CPPFLAGS = -I$(top_builddir) -I$(top_srcdir) -I$(top_builddir)/include/
AM_CPPFLAGS += @WITH_NSS_INCLUDE@
AM_CPPFLAGS += @WITH_POPT_INCLUDE@
+AM_CPPFLAGS += @WITH_SQLITE3_INCLUDE@
AM_CPPFLAGS += -I$(top_srcdir)/misc
AM_CPPFLAGS += -DLOCALEDIR="\"$(localedir)\""
AM_CPPFLAGS += -DSYSCONFDIR="\"$(sysconfdir)\""
@@ -11,10 +14,17 @@ AM_CPPFLAGS += -DRPMCONFIGDIR="\"@RPMCONFIGDIR@\""
AM_CPPFLAGS += -DLIBRPMALIAS_FILENAME="\"@RPMCONFIGDIR@/rpmpopt-${VERSION}\""
check_PROGRAMS =
+CLEANFILES =
+EXTRA_DIST = gentagtbl.sh
+EXTRA_PROGRAMS =
usrlibdir = $(libdir)
usrlib_LTLIBRARIES = librpm.la
librpm_la_SOURCES = \
+ backend/dbconfig.c backend/db3.c \
+ hdrNVR.c header.c header_internal.c header_internal.h \
+ poptDB.c rpmhash.c rpmhash.h rpmdb.c rpmdb_internal.h \
+ fprint.c fprint.h tagname.c tagtbl.c \
cpio.c cpio.h depends.c formats.c fs.c fsm.c fsm.h \
manifest.c manifest.h misc.c package.c \
poptALL.c poptI.c poptQV.c psm.c psm.h query.c \
@@ -24,15 +34,142 @@ librpm_la_SOURCES = \
rpmte.c rpmte_internal.h rpmts.c \
rpmvercmp.c signature.c signature.h transaction.c \
verify.c rpmlock.c rpmlock.h misc.h \
- legacy.c legacy.h
+ legacy.c legacy.h merge.c
+if SQLITE3
+librpm_la_SOURCES += backend/sqlite.c
+endif
librpm_la_LDFLAGS = -release 4.6
librpm_la_LIBADD = \
- $(top_builddir)/rpmdb/librpmdb.la \
$(top_builddir)/rpmio/librpmio.la \
@WITH_NSS_LIB@ \
@WITH_POPT_LIB@ \
@WITH_SELINUX_LIB@ \
+ @WITH_SQLITE3_LIB@ \
@LIBINTL@
+if WITH_INTERNAL_DB
+librpm_la_LIBADD += $(libdb_la)
+else
+librpm_la_LIBADD += @WITH_DB_LIB@
+endif
+
+tagtbl.c: Makefile.am $(top_srcdir)/lib/rpmtag.h gentagtbl.sh
+ @AWK=${AWK} ${SHELL} gentagtbl.sh $(top_srcdir)/lib/rpmtag.h > $@
+BUILT_SOURCES = tagtbl.c
+
+if WITH_INTERNAL_DB
+# XXX watchout, $(top_builddir)/db3/libdb.la created by this Makefile may surprise
+libdb_la = $(top_builddir)/db3/libdb.la
+
+# XXX grrr, force noinst libdb.la for db3.
+# there are more reliable ways to get the BDB version info, just a dirty
+# hack for now...
+BDBVER = $(shell grep ^LIBVERSION $(top_builddir)/db3/Makefile|cut -f2)
+$(libdb_la): $(top_builddir)/db3/libdb-$(BDBVER).la
+ sed -e"/^libdir=/s/^.*$$/libdir=''/" \
+ < $(top_builddir)/db3/libdb-$(BDBVER).la > $(libdb_la)
+CLEANFILES += $(libdb_la)
+
+rpmlibexec_PROGRAMS =
+
+rpmlibexec_PROGRAMS += rpmdb_archive
+rpmdb_archive_SOURCES =
+rpmdb_archive_LDADD = \
+ $(top_builddir)/db3/db_archive.o \
+ $(top_builddir)/db3/util_sig.o \
+ librpm.la
+
+rpmlibexec_PROGRAMS += rpmdb_checkpoint
+rpmdb_checkpoint_SOURCES =
+rpmdb_checkpoint_LDADD = \
+ $(top_builddir)/db3/db_checkpoint.o \
+ $(top_builddir)/db3/util_log.o \
+ $(top_builddir)/db3/util_sig.o \
+ librpm.la
+
+rpmlibexec_PROGRAMS += rpmdb_deadlock
+rpmdb_deadlock_SOURCES =
+rpmdb_deadlock_LDADD = \
+ $(top_builddir)/db3/db_deadlock.o \
+ $(top_builddir)/db3/util_log.o \
+ $(top_builddir)/db3/util_sig.o \
+ librpm.la
+
+rpmlibexec_PROGRAMS += rpmdb_dump
+rpmdb_dump_SOURCES =
+rpmdb_dump_LDADD = \
+ $(top_builddir)/db3/db_dump.o \
+ $(top_builddir)/db3/util_cache.o \
+ $(top_builddir)/db3/util_sig.o \
+ librpm.la
+
+rpmlibexec_PROGRAMS += rpmdb_load
+rpmdb_load_SOURCES =
+rpmdb_load_LDADD = \
+ $(top_builddir)/db3/db_load.o \
+ $(top_builddir)/db3/util_cache.o \
+ $(top_builddir)/db3/util_sig.o \
+ librpm.la
+
+rpmlibexec_PROGRAMS += rpmdb_printlog
+rpmdb_printlog_SOURCES =
+rpmdb_printlog_LDADD = \
+ $(top_builddir)/db3/db_printlog.o \
+ $(top_builddir)/db3/btree_autop.o \
+ $(top_builddir)/db3/crdel_autop.o \
+ $(top_builddir)/db3/db_autop.o \
+ $(top_builddir)/db3/dbreg_autop.o \
+ $(top_builddir)/db3/fileops_autop.o \
+ $(top_builddir)/db3/hash_autop.o \
+ $(top_builddir)/db3/qam_autop.o \
+ $(top_builddir)/db3/rep_autop.o \
+ $(top_builddir)/db3/txn_autop.o \
+ $(top_builddir)/db3/util_sig.o \
+ librpm.la
+
+rpmlibexec_PROGRAMS += rpmdb_recover
+rpmdb_recover_SOURCES =
+rpmdb_recover_LDADD = \
+ $(top_builddir)/db3/db_recover.o \
+ $(top_builddir)/db3/util_cache.o \
+ $(top_builddir)/db3/util_sig.o \
+ librpm.la
+
+rpmlibexec_PROGRAMS += rpmdb_stat
+rpmdb_stat_SOURCES =
+rpmdb_stat_LDADD = \
+ $(top_builddir)/db3/db_stat.o \
+ $(top_builddir)/db3/util_cache.o \
+ $(top_builddir)/db3/util_sig.o \
+ librpm.la
+
+rpmlibexec_PROGRAMS += rpmdb_svc
+rpmdb_svc_SOURCES =
+rpmdb_svc_LDADD = \
+ $(top_builddir)/db3/db_server_proc.o \
+ $(top_builddir)/db3/db_server_svc.o \
+ $(top_builddir)/db3/db_server_util.o \
+ $(top_builddir)/db3/gen_db_server.o \
+ $(top_builddir)/db3/util_log.o \
+ librpm.la
+
+rpmlibexec_PROGRAMS += rpmdb_upgrade
+rpmdb_upgrade_SOURCES =
+rpmdb_upgrade_LDADD = \
+ $(top_builddir)/db3/db_upgrade.o \
+ $(top_builddir)/db3/util_cache.o \
+ $(top_builddir)/db3/util_sig.o \
+ librpm.la
+
+rpmlibexec_PROGRAMS += rpmdb_verify
+rpmdb_verify_SOURCES =
+rpmdb_verify_LDADD = \
+ $(top_builddir)/db3/db_verify.o \
+ $(top_builddir)/db3/util_cache.o \
+ $(top_builddir)/db3/util_sig.o \
+ librpm.la
+endif
+
+CLEANFILES += $(BUILT_SOURCES)
diff --git a/lib/backend/db3.c b/lib/backend/db3.c
index e1983de41..05c7d8284 100644
--- a/lib/backend/db3.c
+++ b/lib/backend/db3.c
@@ -1,5 +1,5 @@
/** \ingroup db3
- * \file rpmdb/db3.c
+ * \file lib/db3.c
*/
static int _debug = 1; /* XXX if < 0 debugging, > 0 unusual error returns */
@@ -15,7 +15,7 @@ static int _debug = 1; /* XXX if < 0 debugging, > 0 unusual error returns */
#include <rpm/rpmfileutil.h> /* rpmioMkPath */
#include <rpm/rpmlog.h>
-#include "rpmdb/rpmdb_internal.h"
+#include "lib/rpmdb_internal.h"
#include "debug.h"
diff --git a/lib/backend/dbconfig.c b/lib/backend/dbconfig.c
index fc75af3bf..fd7e11aef 100644
--- a/lib/backend/dbconfig.c
+++ b/lib/backend/dbconfig.c
@@ -1,5 +1,5 @@
/** \ingroup rpmdb
- * \file rpmdb/dbconfig.c
+ * \file lib/dbconfig.c
*/
#include "system.h"
@@ -11,7 +11,7 @@
#include <rpm/rpmstring.h>
#include <rpm/rpmlog.h>
#include <rpm/argv.h>
-#include "rpmdb/rpmdb_internal.h"
+#include "lib/rpmdb_internal.h"
#include "debug.h"
@@ -402,7 +402,7 @@ dbiIndex db3New(rpmdb rpmdb, rpmTag rpmtag)
if (!(dbi->dbi_perms & 0600))
dbi->dbi_perms = 0644;
dbi->dbi_mode = rpmdb->db_mode;
- /* FIX: figger rpmdb/dbi refcounts */
+ /* FIX: figger lib/dbi refcounts */
dbi->dbi_rpmdb = rpmdb;
dbi->dbi_rpmtag = rpmtag;
diff --git a/lib/backend/sqlite.c b/lib/backend/sqlite.c
index e290a5b25..5178c8711 100644
--- a/lib/backend/sqlite.c
+++ b/lib/backend/sqlite.c
@@ -35,7 +35,7 @@
#include <rpm/rpmstring.h>
#include <rpm/rpmdb.h>
-#include "rpmdb/rpmdb_internal.h"
+#include "lib/rpmdb_internal.h"
#include "debug.h"
diff --git a/lib/depends.c b/lib/depends.c
index 614cf5abc..dbd128d84 100644
--- a/lib/depends.c
+++ b/lib/depends.c
@@ -14,7 +14,7 @@
#include <rpm/rpmds.h>
#include <rpm/rpmfi.h>
-#include "rpmdb/rpmdb_internal.h" /* XXX response cache needs dbiOpen et al. */
+#include "lib/rpmdb_internal.h" /* XXX response cache needs dbiOpen et al. */
#include "lib/rpmte_internal.h" /* XXX tsortInfo_s */
#include "lib/rpmts_internal.h"
diff --git a/lib/fprint.c b/lib/fprint.c
index b1996689c..2f757ddfe 100644
--- a/lib/fprint.c
+++ b/lib/fprint.c
@@ -1,13 +1,13 @@
/**
- * \file rpmdb/fprint.c
+ * \file lib/fprint.c
*/
#include "system.h"
#include <rpm/rpmfileutil.h> /* for rpmCleanPath */
-#include "rpmdb/rpmdb_internal.h"
-#include "rpmdb/fprint.h"
+#include "lib/rpmdb_internal.h"
+#include "lib/fprint.h"
#include "debug.h"
fingerPrintCache fpCacheCreate(int sizeHint)
diff --git a/lib/fprint.h b/lib/fprint.h
index 3e478fbbe..36f1f59ae 100644
--- a/lib/fprint.h
+++ b/lib/fprint.h
@@ -2,12 +2,12 @@
#define H_FINGERPRINT
/** \ingroup rpmtrans
- * \file rpmdb/fprint.h
+ * \file lib/fprint.h
* Identify a file name path by a unique "finger print".
*/
#include <rpm/header.h>
-#include "rpmdb/rpmhash.h"
+#include "lib/rpmhash.h"
/**
*/
diff --git a/lib/hdrNVR.c b/lib/hdrNVR.c
index 367d165a1..0238f981f 100644
--- a/lib/hdrNVR.c
+++ b/lib/hdrNVR.c
@@ -1,5 +1,5 @@
/** \ingroup rpmdb
- * \file rpmdb/hdrNVR.c
+ * \file lib/hdrNVR.c
*/
#include "system.h"
diff --git a/lib/header.c b/lib/header.c
index 1639c4313..890d12013 100644
--- a/lib/header.c
+++ b/lib/header.c
@@ -1,5 +1,5 @@
/** \ingroup header
- * \file rpmdb/header.c
+ * \file lib/header.c
*/
/* RPM - Copyright (C) 1995-2002 Red Hat Software */
@@ -13,7 +13,7 @@
#include <rpm/rpmtag.h>
#include <rpm/rpmstring.h>
#include <rpm/rpmpgp.h>
-#include "rpmdb/header_internal.h"
+#include "lib/header_internal.h"
#include "debug.h"
diff --git a/lib/header.h b/lib/header.h
index 19dd0a53f..9a2f223d0 100644
--- a/lib/header.h
+++ b/lib/header.h
@@ -2,7 +2,7 @@
#define H_HEADER
/** \ingroup header
- * \file rpmdb/header.h
+ * \file lib/header.h
*
* An rpm header carries all information about a package. A header is
* a collection of data elements called tags. Each tag has a data type,
diff --git a/lib/header_internal.c b/lib/header_internal.c
index 1af4bc0ab..a48351437 100644
--- a/lib/header_internal.c
+++ b/lib/header_internal.c
@@ -1,11 +1,11 @@
/** \ingroup header
- * \file rpmdb/header_internal.c
+ * \file lib/header_internal.c
*/
#include "system.h"
#include <rpm/rpmtag.h>
-#include "rpmdb/header_internal.h"
+#include "lib/header_internal.h"
#include "debug.h"
diff --git a/lib/header_internal.h b/lib/header_internal.h
index f789fbbbe..c866caf5d 100644
--- a/lib/header_internal.h
+++ b/lib/header_internal.h
@@ -2,7 +2,7 @@
#define H_HEADER_INTERNAL
/** \ingroup header
- * \file rpmdb/header_internal.h
+ * \file lib/header_internal.h
*/
#include <netinet/in.h>
diff --git a/lib/merge.c b/lib/merge.c
index 02f922d7f..b4163e235 100644
--- a/lib/merge.c
+++ b/lib/merge.c
@@ -54,7 +54,7 @@ static char sccsid[] = "@(#)merge.c 8.2 (Berkeley) 2/14/94";
*/
#include "system.h"
-#include "rpmdb/rpmdb_internal.h" /* XXX for mergesort */
+#include "lib/rpmdb_internal.h" /* XXX for mergesort */
#define ISIZE sizeof(int)
#define PSIZE sizeof(unsigned char *)
diff --git a/lib/package.c b/lib/package.c
index 1bea015ba..143923df2 100644
--- a/lib/package.c
+++ b/lib/package.c
@@ -16,7 +16,7 @@
#include "lib/signature.h"
#include "rpmio/digest.h"
#include "rpmio/rpmio_internal.h" /* fd*Digest(), fd stats */
-#include "rpmdb/header_internal.h" /* XXX headerCheck */
+#include "lib/header_internal.h" /* XXX headerCheck */
#include "debug.h"
diff --git a/lib/poptDB.c b/lib/poptDB.c
index db3266306..3dfc9642e 100644
--- a/lib/poptDB.c
+++ b/lib/poptDB.c
@@ -1,5 +1,5 @@
/** \ingroup rpmcli
- * \file rpmdb/poptDB.c
+ * \file lib/poptDB.c
* Popt tables for database modes.
*/
diff --git a/lib/rpmdb.c b/lib/rpmdb.c
index 72d86adee..a8c94868d 100644
--- a/lib/rpmdb.c
+++ b/lib/rpmdb.c
@@ -1,5 +1,5 @@
/** \ingroup rpmdb dbi
- * \file rpmdb/rpmdb.c
+ * \file lib/rpmdb.c
*/
#include "system.h"
@@ -27,9 +27,9 @@
#include <rpm/rpmdb.h>
#include <rpm/argv.h>
-#include "rpmdb/rpmdb_internal.h"
-#include "rpmdb/fprint.h"
-#include "rpmdb/header_internal.h" /* XXX for HEADERFLAG_ALLOCATED */
+#include "lib/rpmdb_internal.h"
+#include "lib/fprint.h"
+#include "lib/header_internal.h" /* XXX for HEADERFLAG_ALLOCATED */
#include "debug.h"
int _rpmdb_debug = 0;
diff --git a/lib/rpmdb.h b/lib/rpmdb.h
index 9526133bd..30465eea8 100644
--- a/lib/rpmdb.h
+++ b/lib/rpmdb.h
@@ -2,7 +2,7 @@
#define H_RPMDB
/** \ingroup rpmdb dbi db1 db3
- * \file rpmdb/rpmdb.h
+ * \file lib/rpmdb.h
* Access RPM indices using Berkeley DB interface(s).
*/
diff --git a/lib/rpmhash.c b/lib/rpmhash.c
index c7f7fc506..383697514 100644
--- a/lib/rpmhash.c
+++ b/lib/rpmhash.c
@@ -1,10 +1,10 @@
/**
- * \file rpmdb/rpmhash.c
+ * \file lib/rpmhash.c
* Hash table implemenation
*/
#include "system.h"
-#include "rpmdb/rpmhash.h"
+#include "lib/rpmhash.h"
#include "debug.h"
typedef const void * voidptr;
diff --git a/lib/rpmhash.h b/lib/rpmhash.h
index 5e840bd5a..a2008717e 100644
--- a/lib/rpmhash.h
+++ b/lib/rpmhash.h
@@ -2,7 +2,7 @@
#define H_RPMHASH
/**
- * \file rpmdb/rpmhash.h
+ * \file lib/rpmhash.h
* Hash table implemenation.
*/
diff --git a/lib/rpmts_internal.h b/lib/rpmts_internal.h
index 7e0fd4519..6c662e481 100644
--- a/lib/rpmts_internal.h
+++ b/lib/rpmts_internal.h
@@ -4,7 +4,7 @@
#include <rpm/rpmts.h>
#include <rpm/rpmal.h> /* XXX availablePackage/relocateFileList ,*/
-#include "rpmdb/rpmhash.h" /* XXX hashTable */
+#include "lib/rpmhash.h" /* XXX hashTable */
/** \ingroup rpmts
*/
diff --git a/lib/signature.c b/lib/signature.c
index 953c1bb30..fe57310c8 100644
--- a/lib/signature.c
+++ b/lib/signature.c
@@ -19,7 +19,7 @@
#include "lib/misc.h" /* XXX for dosetenv() */
#include "lib/rpmlead.h"
#include "lib/signature.h"
-#include "rpmdb/header_internal.h"
+#include "lib/header_internal.h"
#include "debug.h"
diff --git a/lib/tagname.c b/lib/tagname.c
index 2ea0a96b1..c962330ec 100644
--- a/lib/tagname.c
+++ b/lib/tagname.c
@@ -1,5 +1,5 @@
/**
- * \file rpmdb/tagname.c
+ * \file lib/tagname.c
*/
#include "system.h"
diff --git a/lib/transaction.c b/lib/transaction.c
index 685d2b762..471cdc687 100644
--- a/lib/transaction.c
+++ b/lib/transaction.c
@@ -13,8 +13,8 @@
#include <rpm/rpmstring.h>
#include <rpm/argv.h>
-#include "rpmdb/rpmdb_internal.h" /* XXX for dbiIndexSetCount */
-#include "rpmdb/fprint.h"
+#include "lib/rpmdb_internal.h" /* XXX for dbiIndexSetCount */
+#include "lib/fprint.h"
#include "lib/psm.h"
#include "lib/rpmlock.h"
#include "lib/rpmfi_internal.h" /* fi->replaced, fi->actions... */
diff --git a/po/POTFILES.in b/po/POTFILES.in
index 7f59ca720..fc29af5e2 100644
--- a/po/POTFILES.in
+++ b/po/POTFILES.in
@@ -54,19 +54,19 @@ lib/rpmvercmp.c
lib/signature.c
lib/transaction.c
lib/verify.c
+lib/fprint.c
+lib/hdrNVR.c
+lib/header.c
+lib/header_internal.c
+lib/merge.c
+lib/poptDB.c
+lib/rpmdb.c
+lib/rpmhash.c
+lib/tagname.c
+lib/backend/db3.c
+lib/backend/dbconfig.c
+lib/backend/sqlite.c
misc/error.c
-rpmdb/db3.c
-rpmdb/dbconfig.c
-rpmdb/fprint.c
-rpmdb/hdrNVR.c
-rpmdb/header.c
-rpmdb/header_internal.c
-rpmdb/merge.c
-rpmdb/poptDB.c
-rpmdb/rpmdb.c
-rpmdb/rpmhash.c
-rpmdb/sqlite.c
-rpmdb/tagname.c
rpmio/argv.c
rpmio/digest.c
rpmio/fts.c
diff --git a/preinstall.am b/preinstall.am
index 192459d0c..dedabba46 100644
--- a/preinstall.am
+++ b/preinstall.am
@@ -1,5 +1,5 @@
-include/rpm/rpmints.h: rpmdb/rpmints.h include/rpm/$(dirstamp)
- $(INSTALL_DATA) $(top_srcdir)/rpmdb/rpmints.h include/rpm/rpmints.h
+include/rpm/rpmints.h: lib/rpmints.h include/rpm/$(dirstamp)
+ $(INSTALL_DATA) $(top_srcdir)/lib/rpmints.h include/rpm/rpmints.h
BUILT_SOURCES += include/rpm/rpmints.h
CLEANFILES += include/rpm/rpmints.h
include/rpm/argv.h: rpmio/argv.h include/rpm/$(dirstamp)
@@ -46,12 +46,12 @@ include/rpm/rpmutil.h: rpmio/rpmutil.h include/rpm/$(dirstamp)
$(INSTALL_DATA) $(top_srcdir)/rpmio/rpmutil.h include/rpm/rpmutil.h
BUILT_SOURCES += include/rpm/rpmutil.h
CLEANFILES += include/rpm/rpmutil.h
-include/rpm/header.h: rpmdb/header.h include/rpm/$(dirstamp)
- $(INSTALL_DATA) $(top_srcdir)/rpmdb/header.h include/rpm/header.h
+include/rpm/header.h: lib/header.h include/rpm/$(dirstamp)
+ $(INSTALL_DATA) $(top_srcdir)/lib/header.h include/rpm/header.h
BUILT_SOURCES += include/rpm/header.h
CLEANFILES += include/rpm/header.h
-include/rpm/rpmdb.h: rpmdb/rpmdb.h include/rpm/$(dirstamp)
- $(INSTALL_DATA) $(top_srcdir)/rpmdb/rpmdb.h include/rpm/rpmdb.h
+include/rpm/rpmdb.h: lib/rpmdb.h include/rpm/$(dirstamp)
+ $(INSTALL_DATA) $(top_srcdir)/lib/rpmdb.h include/rpm/rpmdb.h
BUILT_SOURCES += include/rpm/rpmdb.h
CLEANFILES += include/rpm/rpmdb.h
include/rpm/rpmcallback.h: lib/rpmcallback.h include/rpm/$(dirstamp)
diff --git a/python/Makefile.am b/python/Makefile.am
index a1818b9bd..776505164 100644
--- a/python/Makefile.am
+++ b/python/Makefile.am
@@ -18,7 +18,6 @@ _rpmmodule_la_LDFLAGS = -module -avoid-version
_rpmmodule_la_LIBADD = \
$(top_builddir)/build/librpmbuild.la \
$(top_builddir)/lib/librpm.la \
- $(top_builddir)/rpmdb/librpmdb.la \
$(top_builddir)/rpmio/librpmio.la \
@WITH_NSS_LIB@ \
@WITH_POPT_LIB@ \
diff --git a/rpmdb/Makefile.am b/rpmdb/Makefile.am
deleted file mode 100644
index 471cba075..000000000
--- a/rpmdb/Makefile.am
+++ /dev/null
@@ -1,157 +0,0 @@
-# Makefile for rpm library.
-
-include $(top_srcdir)/rpm.am
-
-AM_CPPFLAGS = -I$(top_builddir) -I$(top_srcdir) -I$(top_builddir)/include/
-AM_CPPFLAGS += @WITH_POPT_INCLUDE@
-AM_CPPFLAGS += -I$(top_srcdir)/misc
-AM_CPPFLAGS += @WITH_SQLITE3_INCLUDE@
-AM_CPPFLAGS += @WITH_LIBELF_INCLUDE@
-
-check_PROGRAMS =
-EXTRA_PROGRAMS =
-CLEANFILES =
-EXTRA_DIST = gentagtbl.sh
-
-usrlibdir = $(libdir)
-usrlib_LTLIBRARIES = librpmdb.la
-librpmdb_la_SOURCES = \
- dbconfig.c fprint.c fprint.h \
- hdrNVR.c header.c header_internal.c header_internal.h \
- merge.c \
- poptDB.c rpmhash.c rpmhash.h rpmdb.c rpmdb_internal.h \
- tagname.c tagtbl.c
-librpmdb_la_SOURCES += db3.c
-if SQLITE3
-librpmdb_la_SOURCES += sqlite.c
-endif
-librpmdb_la_LDFLAGS = -release 4.6
-librpmdb_la_LIBADD = \
- $(top_builddir)/rpmio/librpmio.la \
- @WITH_POPT_LIB@ \
- @WITH_SQLITE3_LIB@ \
- @WITH_LIBELF_LIB@
-if WITH_INTERNAL_DB
-librpmdb_la_LIBADD += $(libdb_la)
-else
-librpmdb_la_LIBADD += @WITH_DB_LIB@
-endif
-
-tagtbl.c: Makefile.am $(top_srcdir)/lib/rpmtag.h gentagtbl.sh
- @AWK=${AWK} ${SHELL} gentagtbl.sh $(top_srcdir)/lib/rpmtag.h > $@
-BUILT_SOURCES = tagtbl.c
-
-if WITH_INTERNAL_DB
-# XXX watchout, $(top_builddir)/db3/libdb.la created by this Makefile may surprise
-libdb_la = $(top_builddir)/db3/libdb.la
-
-# XXX grrr, force noinst libdb.la for db3.
-# there are more reliable ways to get the BDB version info, just a dirty
-# hack for now...
-BDBVER = $(shell grep ^LIBVERSION $(top_builddir)/db3/Makefile|cut -f2)
-$(libdb_la): $(top_builddir)/db3/libdb-$(BDBVER).la
- sed -e"/^libdir=/s/^.*$$/libdir=''/" \
- < $(top_builddir)/db3/libdb-$(BDBVER).la > $(libdb_la)
-CLEANFILES += $(libdb_la)
-
-rpmlibexec_PROGRAMS =
-
-rpmlibexec_PROGRAMS += rpmdb_archive
-rpmdb_archive_SOURCES =
-rpmdb_archive_LDADD = \
- $(top_builddir)/db3/db_archive.o \
- $(top_builddir)/db3/util_sig.o \
- librpmdb.la
-
-rpmlibexec_PROGRAMS += rpmdb_checkpoint
-rpmdb_checkpoint_SOURCES =
-rpmdb_checkpoint_LDADD = \
- $(top_builddir)/db3/db_checkpoint.o \
- $(top_builddir)/db3/util_log.o \
- $(top_builddir)/db3/util_sig.o \
- librpmdb.la
-
-rpmlibexec_PROGRAMS += rpmdb_deadlock
-rpmdb_deadlock_SOURCES =
-rpmdb_deadlock_LDADD = \
- $(top_builddir)/db3/db_deadlock.o \
- $(top_builddir)/db3/util_log.o \
- $(top_builddir)/db3/util_sig.o \
- librpmdb.la
-
-rpmlibexec_PROGRAMS += rpmdb_dump
-rpmdb_dump_SOURCES =
-rpmdb_dump_LDADD = \
- $(top_builddir)/db3/db_dump.o \
- $(top_builddir)/db3/util_cache.o \
- $(top_builddir)/db3/util_sig.o \
- librpmdb.la
-
-rpmlibexec_PROGRAMS += rpmdb_load
-rpmdb_load_SOURCES =
-rpmdb_load_LDADD = \
- $(top_builddir)/db3/db_load.o \
- $(top_builddir)/db3/util_cache.o \
- $(top_builddir)/db3/util_sig.o \
- librpmdb.la
-
-rpmlibexec_PROGRAMS += rpmdb_printlog
-rpmdb_printlog_SOURCES =
-rpmdb_printlog_LDADD = \
- $(top_builddir)/db3/db_printlog.o \
- $(top_builddir)/db3/btree_autop.o \
- $(top_builddir)/db3/crdel_autop.o \
- $(top_builddir)/db3/db_autop.o \
- $(top_builddir)/db3/dbreg_autop.o \
- $(top_builddir)/db3/fileops_autop.o \
- $(top_builddir)/db3/hash_autop.o \
- $(top_builddir)/db3/qam_autop.o \
- $(top_builddir)/db3/rep_autop.o \
- $(top_builddir)/db3/txn_autop.o \
- $(top_builddir)/db3/util_sig.o \
- librpmdb.la
-
-rpmlibexec_PROGRAMS += rpmdb_recover
-rpmdb_recover_SOURCES =
-rpmdb_recover_LDADD = \
- $(top_builddir)/db3/db_recover.o \
- $(top_builddir)/db3/util_cache.o \
- $(top_builddir)/db3/util_sig.o \
- librpmdb.la
-
-rpmlibexec_PROGRAMS += rpmdb_stat
-rpmdb_stat_SOURCES =
-rpmdb_stat_LDADD = \
- $(top_builddir)/db3/db_stat.o \
- $(top_builddir)/db3/util_cache.o \
- $(top_builddir)/db3/util_sig.o \
- librpmdb.la
-
-rpmlibexec_PROGRAMS += rpmdb_svc
-rpmdb_svc_SOURCES =
-rpmdb_svc_LDADD = \
- $(top_builddir)/db3/db_server_proc.o \
- $(top_builddir)/db3/db_server_svc.o \
- $(top_builddir)/db3/db_server_util.o \
- $(top_builddir)/db3/gen_db_server.o \
- $(top_builddir)/db3/util_log.o \
- librpmdb.la
-
-rpmlibexec_PROGRAMS += rpmdb_upgrade
-rpmdb_upgrade_SOURCES =
-rpmdb_upgrade_LDADD = \
- $(top_builddir)/db3/db_upgrade.o \
- $(top_builddir)/db3/util_cache.o \
- $(top_builddir)/db3/util_sig.o \
- librpmdb.la
-
-rpmlibexec_PROGRAMS += rpmdb_verify
-rpmdb_verify_SOURCES =
-rpmdb_verify_LDADD = \
- $(top_builddir)/db3/db_verify.o \
- $(top_builddir)/db3/util_cache.o \
- $(top_builddir)/db3/util_sig.o \
- librpmdb.la
-endif
-
-CLEANFILES += $(BUILT_SOURCES)
diff --git a/tools/dump.c b/tools/dump.c
index b3243da6f..0f3ecde6e 100644
--- a/tools/dump.c
+++ b/tools/dump.c
@@ -1,7 +1,7 @@
#include "system.h"
const char *__progname;
-#include "rpmdb/header_internal.h"
+#include "lib/header_internal.h"
#include "debug.h"
int main(int argc, char *argv[])
diff --git a/tools/dumpdb.c b/tools/dumpdb.c
index 8815d4e99..69a3f0608 100644
--- a/tools/dumpdb.c
+++ b/tools/dumpdb.c
@@ -1,7 +1,7 @@
#include "system.h"
const char *__progname;
-#include "rpmdb/header_internal.h"
+#include "lib/header_internal.h"
#include <rpm/rpmtag.h>
#include <rpm/rpmlib.h> /* rpmReadConfigFiles */