summaryrefslogtreecommitdiff
path: root/rpmdb
diff options
context:
space:
mode:
authorjbj <devnull@localhost>2002-12-01 21:34:06 +0000
committerjbj <devnull@localhost>2002-12-01 21:34:06 +0000
commit80b23366e79f229831efb6a590c90e2724d37927 (patch)
treee62a5951bd28e84579d84d988e3546808dcd8df3 /rpmdb
parent0efbbada0f3005d6f81a940ba7b06aef2703a50b (diff)
downloadlibrpm-tizen-80b23366e79f229831efb6a590c90e2724d37927.tar.gz
librpm-tizen-80b23366e79f229831efb6a590c90e2724d37927.tar.bz2
librpm-tizen-80b23366e79f229831efb6a590c90e2724d37927.zip
- use usrlib_LTLIBRARIES to install directly in /usr/lib64 instead.
CVS patchset: 5911 CVS date: 2002/12/01 21:34:06
Diffstat (limited to 'rpmdb')
-rw-r--r--rpmdb/Makefile.am21
-rw-r--r--rpmdb/tdbi.c7
-rw-r--r--rpmdb/tjfn.c7
3 files changed, 24 insertions, 11 deletions
diff --git a/rpmdb/Makefile.am b/rpmdb/Makefile.am
index ea929b1cd..951ce546d 100644
--- a/rpmdb/Makefile.am
+++ b/rpmdb/Makefile.am
@@ -25,23 +25,26 @@ pkgincdir = $(pkgincludedir)
pkginc_HEADERS = db.h header.h hdrinline.h rpmdb.h rpmhash.h
noinst_HEADERS = fprint.h header_internal.h legacy.h
-mylibpaths = \
- -L$(top_builddir)/lib \
- -L$(top_builddir)/rpmio \
- -L$(top_builddir)/popt
+#mylibpaths = \
+# -L$(top_builddir)/lib \
+# -L$(top_builddir)/rpmio \
+# -L$(top_builddir)/popt
+
+#mylibs = -lrpm -lrpmio -lpopt @WITH_LIBELF_LIB@ @LIBS@ @INTLLIBS@ @LIBMISC@
+mylibs = librpmdb.la
-mylibs = -lrpm -lrpmio -lpopt @WITH_LIBELF_LIB@ @LIBS@ @INTLLIBS@ @LIBMISC@
LIBS =
DB3LOBJS = $(shell cat $(top_builddir)/$(WITH_DB_SUBDIR)/db3lobjs)
-lib_LTLIBRARIES = librpmdb.la
+usrlibdir = $(libdir)@MARK64@
+usrlib_LTLIBRARIES = librpmdb.la
librpmdb_la_SOURCES = \
dbconfig.c fprint.c \
hdrNVR.c header.c header_internal.c legacy.c merge.c \
poptDB.c rpmhash.c rpmdb.c \
tagname.c tagtbl.c
-librpmdb_la_LDFLAGS = -release @VERSION@ @HACK_LIBTOOLPATH@ $(top_builddir)/rpmio/librpmio.la $(top_builddir)/popt/libpopt.la @WITH_LIBELF_LIB@ @libdb3@
+librpmdb_la_LDFLAGS = -release @VERSION@ $(top_builddir)/rpmio/librpmio.la $(top_builddir)/popt/libpopt.la @WITH_LIBELF_LIB@ @libdb3@
librpmdb_la_LIBADD = $(DBLIBOBJS) $(DB3LOBJS)
librpmdb_la_DEPENDENCIES = $(DBLIBOBJS) .created
@@ -49,8 +52,8 @@ librpmdb_la_DEPENDENCIES = $(DBLIBOBJS) .created
dbconfig.c: db.h
# XXX Add internal libtool dependence
-install-data-local:
- @cd $(DESTDIR)/$(libdir) && \
+install-data-local: install-usrlibLTLIBRARIES
+ @cd $(DESTDIR)/$(usrlibdir) && \
sed -e "s|^dependency_libs='|& -lrpmio-@VERSION@|" < librpmdb.la > .librpmdb.la && \
mv .librpmdb.la librpmdb.la
diff --git a/rpmdb/tdbi.c b/rpmdb/tdbi.c
index a7d2046a0..300817c6b 100644
--- a/rpmdb/tdbi.c
+++ b/rpmdb/tdbi.c
@@ -25,7 +25,12 @@ main(int argc, char *argv[])
exit (1);
}
- if ((rc = db->open(db, dbfile, NULL, DB_UNKNOWN, DB_RDONLY, 0664)) != 0) {
+#if (DB_VERSION_MAJOR == 4 && DB_VERSION_MINOR == 1)
+ rc = db->open(db, txnid, dbfile, NULL, DB_UNKNOWN, DB_RDONLY, 0664);
+#else
+ rc = db->open(db, dbfile, NULL, DB_UNKNOWN, DB_RDONLY, 0664);
+#endif
+ if (rc != 0) {
db->err(db, rc, "db->open");
if (!ec) ec = rc;
goto err;
diff --git a/rpmdb/tjfn.c b/rpmdb/tjfn.c
index 435894489..a3b5cf5f2 100644
--- a/rpmdb/tjfn.c
+++ b/rpmdb/tjfn.c
@@ -69,7 +69,12 @@ db_open(const char * dbfn, DB_ENV * dbenv, DB ** dbp)
goto err;
}
- if ((ret = db->open(db, dbfn, NULL, DB_BTREE, DB_CREATE, 0664)) != 0) {
+#if (DB_VERSION_MAJOR == 4 && DB_VERSION_MINOR == 1)
+ ret = db->open(db, NULL, dbfn, NULL, DB_BTREE, DB_CREATE, 0664);
+#else
+ ret = db->open(db, dbfn, NULL, DB_BTREE, DB_CREATE, 0664);
+#endif
+ if (ret != 0) {
db->err(db, ret, "db->open(%s)", dbfn);
goto err;
}