From fc990ef48b29b1b5995d9fe5ef229bb223ad5095 Mon Sep 17 00:00:00 2001 From: jbj Date: Fri, 29 Nov 2002 21:35:53 +0000 Subject: - build with external elfutils (preferred), if available. CVS patchset: 5900 CVS date: 2002/11/29 21:35:53 --- CHANGES | 1 + Makefile.am | 2 +- autogen.sh | 20 +++++++++++++++----- build/Makefile.am | 2 ++ configure.ac | 45 +++++++++++++++++++++++++++++---------------- doc/rpm.8 | 4 ++-- po/cs.po | 2 +- po/da.po | 2 +- po/de.po | 2 +- po/fi.po | 2 +- po/fr.po | 2 +- po/gl.po | 2 +- po/is.po | 2 +- po/ja.po | 2 +- po/ko.po | 2 +- po/no.po | 2 +- po/pl.po | 2 +- po/pt.po | 2 +- po/pt_BR.po | 2 +- po/ro.po | 2 +- po/rpm.pot | 2 +- po/ru.po | 2 +- po/sk.po | 2 +- po/sl.po | 4 ++-- po/sr.po | 2 +- po/sv.po | 2 +- po/tr.po | 2 +- rpm.spec.in | 6 +++++- rpmqv.c | 2 +- tools/Makefile.am | 1 - 30 files changed, 78 insertions(+), 49 deletions(-) diff --git a/CHANGES b/CHANGES index bd10443a8..d88c85626 100644 --- a/CHANGES +++ b/CHANGES @@ -32,6 +32,7 @@ - apply patches 7 and 8 to db-4.1.24. - upgrade to elfutils-0.59. - add -g to all platforms optflags. + - build with external elfutils (preferred), if available. 4.0.4 -> 4.1: - loosely wire beecrypt library into rpm. diff --git a/Makefile.am b/Makefile.am index 51c2eb267..42168c3db 100644 --- a/Makefile.am +++ b/Makefile.am @@ -14,7 +14,7 @@ EXTRA_DIST = CHANGES CREDITS Doxyheader GROUPS README.amiga INSTALL \ po/*.in po/*.po po/rpm.pot \ rpm.magic rpmpopt-$(VERSION) rpmqv.c rpm.c -SUBDIRS = intl po @WITH_ZLIB_SUBDIR@ elfutils file @WITH_DB_SUBDIR@ popt beecrypt rpmio rpmdb lib build misc @WITH_PYTHON_SUBDIR@ tools scripts tests doc . +SUBDIRS = intl po @WITH_ZLIB_SUBDIR@ @WITH_ELFUTILS_SUBDIR@ file @WITH_DB_SUBDIR@ popt beecrypt rpmio rpmdb lib build misc @WITH_PYTHON_SUBDIR@ tools scripts tests doc . INCLUDES = \ -I$(top_srcdir)/build \ diff --git a/autogen.sh b/autogen.sh index cec02e8b1..41a5a208e 100755 --- a/autogen.sh +++ b/autogen.sh @@ -20,11 +20,21 @@ recent versions of libtool/autoconf/automake. [ "`autoconf --version | head -1`" != "$ACV" ] && echo "$USAGE" && exit 1 [ "`automake --version | head -1 | sed -e 's/1\.4[a-z]/1.4/'`" != "$AMV" ] && echo "$USAGE" && exit 1 -(echo "--- popt"; cd popt; ./autogen.sh --noconfigure "$@") -(echo "--- zlib"; cd zlib; ./autogen.sh --noconfigure "$@") -(echo "--- beecrypt"; cd beecrypt; ./autogen.sh --noconfigure "$@") -(echo "--- elfutils"; cd elfutils; ./autogen.sh --noconfigure "$@") -(echo "--- file"; cd file; ./autogen.sh --noconfigure "$@") +if [ -d popt ]; then + (echo "--- popt"; cd popt; ./autogen.sh --noconfigure "$@") +fi +if [ -d zlib ]; then + (echo "--- zlib"; cd zlib; ./autogen.sh --noconfigure "$@") +fi +if [ -d beecrypt ]; then + (echo "--- beecrypt"; cd beecrypt; ./autogen.sh --noconfigure "$@") +fi +if [ -d elfutils ]; then + (echo "--- elfutils"; cd elfutils; ./autogen.sh --noconfigure "$@") +fi +if [ -d file ]; then + (echo "--- file"; cd file; ./autogen.sh --noconfigure "$@") +fi echo "--- rpm" libtoolize --copy --force diff --git a/build/Makefile.am b/build/Makefile.am index 1187a6241..56e65de8c 100644 --- a/build/Makefile.am +++ b/build/Makefile.am @@ -43,6 +43,8 @@ $(top_builddir)/file/listobjs: done touch $@ +rpmfc.c: rpmfile.h + clean-local: rm -f $(FILELOBJS) *.o .created rpmfile.h diff --git a/configure.ac b/configure.ac index d39279feb..46fdd7cd9 100644 --- a/configure.ac +++ b/configure.ac @@ -364,39 +364,52 @@ dnl dnl Checks for libraries. -WITH_LIBELF_SUBDIR= +oCPPFLAGS="$CPPFLAGS" +WITH_ELFUTILS_SUBDIR= +if test -d /usr/include/elfutils; then + CPPFLAGS="$CPPFLAGS -I/usr/include/elfutils" +elif test -d ./elfutils; then + WITH_ELFUTILS_SUBDIR=elfutils +fi +AC_SUBST(WITH_ELFUTILS_SUBDIR) + WITH_LIBELF_INCLUDE= WITH_LIBELF_LIB= -WITH_LIBELF_ARCHIVE= +AC_CHECK_HEADER([elfutils/libelf.h]) +AC_CHECK_HEADER([elfutils/gelf.h], [ + AC_CHECK_LIB(elf, gelf_getvernaux, [ + WITH_LIBELF_INCLUDE="-I/usr/include/elfutils" + WITH_LIBELF_LIB="-lelf" + ]) + ], [ if test -d elfutils/libelf ; then AC_DEFINE(HAVE_GELF_H, 1, [Define to 1 if you have the header file.]) AC_DEFINE(HAVE_LIBELF, 1, [Define to 1 if you have the `elf' library (-lelf).]) - WITH_LIBELF_SUBDIR=elfutils/libelf - WITH_LIBELF_INCLUDE="-I\${top_srcdir}/${WITH_LIBELF_SUBDIR}" - WITH_LIBELF_LIB="\${top_builddir}/${WITH_LIBELF_SUBDIR}/libelf.la" - WITH_LIBELF_ARCHIVE="\${top_builddir}/${WITH_LIBELF_SUBDIR}/.libs/libelf.a" + WITH_LIBELF_INCLUDE="-I\${top_srcdir}/${WITH_ELFUTILS_SUBDIR}/libelf" + WITH_LIBELF_LIB="\${top_builddir}/${WITH_ELFUTILS_SUBDIR}/libelf/libelf.la" fi -AC_SUBST(WITH_LIBELF_SUBDIR) +]) AC_SUBST(WITH_LIBELF_INCLUDE) AC_SUBST(WITH_LIBELF_LIB) -AC_SUBST(WITH_LIBELF_ARCHIVE) -WITH_LIBDWARF_SUBDIR= WITH_LIBDWARF_INCLUDE= WITH_LIBDWARF_LIB= -WITH_LIBDWARF_ARCHIVE= +AC_CHECK_HEADER([elfutils/libdwarf.h], [ + AC_CHECK_LIB(dwarf, dwarf_init, [ + WITH_LIBDWARF_INCLUDE="-I/usr/include/elfutils" + WITH_LIBDWARF_LIB="-ldwarf" + ]) + ], [ if test -d elfutils/libdwarf ; then AC_DEFINE(HAVE_DWARF_H, 1, [Define to 1 if you have the header file.]) AC_DEFINE(HAVE_LIBDWARF, 1, [Define to 1 if you have the `dwarf' library (-ldwarf).]) - WITH_LIBDWARF_SUBDIR=elfutils/libdwarf - WITH_LIBDWARF_INCLUDE="-I\${top_srcdir}/${WITH_LIBDWARF_SUBDIR}" - WITH_LIBDWARF_LIB="\${top_builddir}/${WITH_LIBDWARF_SUBDIR}/libdwarf.la" - WITH_LIBDWARF_ARCHIVE="\${top_builddir}/${WITH_LIBDWARF_SUBDIR}/.libs/libdwarf.a" + WITH_LIBDWARF_INCLUDE="-I\${top_srcdir}/${WITH_ELFUTILS_SUBDIR}/libdwarf" + WITH_LIBDWARF_LIB="\${top_builddir}/${WITH_ELFUTILS_SUBDIR}/libdwarf/libdwarf.la" fi -AC_SUBST(WITH_LIBDWARF_SUBDIR) +]) AC_SUBST(WITH_LIBDWARF_INCLUDE) AC_SUBST(WITH_LIBDWARF_LIB) -AC_SUBST(WITH_LIBDWARF_ARCHIVE) +CPPFLAGS="$oCPPFLAGS" AC_CHECK_FUNC(setreuid, [], [ AC_CHECK_LIB(ucb, setreuid, [if echo $LIBS | grep -- -lucb >/dev/null ;then :; else LIBS="$LIBS -lc -lucb" USEUCB=y;fi]) diff --git a/doc/rpm.8 b/doc/rpm.8 index faebb5b84..43f67930f 100644 --- a/doc/rpm.8 +++ b/doc/rpm.8 @@ -23,7 +23,7 @@ rpm \- RPM Package Manager -\fBrpm\fR {\fB-K|--checksig\fR} [\fB--nogpg\fR] [\fB--nopgp\fR] [\fB--nomd5\fR] +\fBrpm\fR {\fB-K|--checksig\fR} [\fB--nosignature\fR] [\fB--nodigest\fR] \fB\fIPACKAGE_FILE\fB\fR\fI ...\fR .SS "INSTALLING, UPGRADING, AND REMOVING PACKAGES:" @@ -737,7 +737,7 @@ The general forms of rpm digital signature commands are \fBrpm\fR \fB--import\fR \fB\fIPUBKEY\fB\fR\fI ...\fR -\fBrpm\fR {\fB--checksig\fR} [\fB--nogpg\fR] [\fB--nopgp\fR] [\fB--nomd5\fR] +\fBrpm\fR {\fB--checksig\fR} [\fB--nosignature\fR] [\fB--nodigest\fR] \fB\fIPACKAGE_FILE\fB\fR\fI ...\fR .PP diff --git a/po/cs.po b/po/cs.po index 8cea35e4e..48935776b 100644 --- a/po/cs.po +++ b/po/cs.po @@ -1,7 +1,7 @@ msgid "" msgstr "" "Project-Id-Version: rpm 4.0.3\n" -"POT-Creation-Date: 2002-11-19 13:41-0500\n" +"POT-Creation-Date: 2002-11-29 16:35-0500\n" "PO-Revision-Date: 2001-07-24 10:02+0100\n" "Last-Translator: Milan Kerslager \n" "Language-Team: Czech \n" diff --git a/po/da.po b/po/da.po index 9e1b8be15..8610bc1f9 100644 --- a/po/da.po +++ b/po/da.po @@ -1,7 +1,7 @@ msgid "" msgstr "" "Project-Id-Version: rpm 4.0.3\n" -"POT-Creation-Date: 2002-11-19 13:41-0500\n" +"POT-Creation-Date: 2002-11-29 16:35-0500\n" "PO-Revision-Date: 2001-04-05 23:03GMT\n" "Last-Translator: Claus Hindsgaul \n" "Language-Team: Danish \n" diff --git a/po/de.po b/po/de.po index e439ee579..c7b1d1322 100644 --- a/po/de.po +++ b/po/de.po @@ -37,7 +37,7 @@ msgid "" msgstr "" "Project-Id-Version: rpm 4.0.3\n" -"POT-Creation-Date: 2002-11-19 13:41-0500\n" +"POT-Creation-Date: 2002-11-29 16:35-0500\n" "PO-Revision-Date: 1998-08-03 18:02+02:00\n" "Last-Translator: Karl Eichwalder \n" "Language-Team: German \n" diff --git a/po/fi.po b/po/fi.po index ec9138091..49642729c 100644 --- a/po/fi.po +++ b/po/fi.po @@ -1,7 +1,7 @@ msgid "" msgstr "" "Project-Id-Version: rpm 4.0.3\n" -"POT-Creation-Date: 2002-11-19 13:41-0500\n" +"POT-Creation-Date: 2002-11-29 16:35-0500\n" "PO-Revision-Date: 1998-05-02 21:41:47-0400\n" "Last-Translator: Raimo Koski \n" "Language-Team: Finnish \n" diff --git a/po/fr.po b/po/fr.po index 2477636f7..24d901622 100644 --- a/po/fr.po +++ b/po/fr.po @@ -6,7 +6,7 @@ msgid "" msgstr "" "Project-Id-Version: rpm 4.0.3\n" -"POT-Creation-Date: 2002-11-19 13:41-0500\n" +"POT-Creation-Date: 2002-11-29 16:35-0500\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" diff --git a/po/gl.po b/po/gl.po index 29adae063..dcc77a831 100644 --- a/po/gl.po +++ b/po/gl.po @@ -1,7 +1,7 @@ msgid "" msgstr "" "Project-Id-Version: rpm 4.0.1\n" -"POT-Creation-Date: 2002-11-19 13:41-0500\n" +"POT-Creation-Date: 2002-11-29 16:35-0500\n" "PO-Revision-Date: 2001-01-13 22:31+0100\n" "Last-Translator: Jesús Bravo Álvarez \n" "Language-Team: Galician \n" diff --git a/po/is.po b/po/is.po index ef05e7e05..eafdf1634 100644 --- a/po/is.po +++ b/po/is.po @@ -1,7 +1,7 @@ msgid "" msgstr "" "Project-Id-Version: rpm 4.0.3\n" -"POT-Creation-Date: 2002-11-19 13:41-0500\n" +"POT-Creation-Date: 2002-11-29 16:35-0500\n" "PO-Revision-Date: 2001-07-12 13:25+0000\n" "Last-Translator: Richard Allen \n" "Language-Team: is \n" diff --git a/po/ja.po b/po/ja.po index 18685285f..1e1b59b43 100644 --- a/po/ja.po +++ b/po/ja.po @@ -6,7 +6,7 @@ msgid "" msgstr "" "Project-Id-Version: rpm 4.0.3\n" -"POT-Creation-Date: 2002-11-19 13:41-0500\n" +"POT-Creation-Date: 2002-11-29 16:35-0500\n" "PO-Revision-Date: 1999-12-01 22:49 +JST\n" "Last-Translator: Kanda Mitsuru \n" "Language-Team: JRPM \n" diff --git a/po/ko.po b/po/ko.po index 41b806a17..84e9421e1 100644 --- a/po/ko.po +++ b/po/ko.po @@ -1,7 +1,7 @@ msgid "" msgstr "" "Project-Id-Version: rpm 4.0.4\n" -"POT-Creation-Date: 2002-11-19 13:41-0500\n" +"POT-Creation-Date: 2002-11-29 16:35-0500\n" "PO-Revision-Date: 2002-03-04 17:17+0900\n" "Last-Translator: Jong-Hoon Ryu \n" "Language-Team: GNU Translation project \n" diff --git a/po/no.po b/po/no.po index 04284a33c..06ab95830 100644 --- a/po/no.po +++ b/po/no.po @@ -1,7 +1,7 @@ msgid "" msgstr "" "Project-Id-Version: rpm 4.0.3\n" -"POT-Creation-Date: 2002-11-19 13:41-0500\n" +"POT-Creation-Date: 2002-11-29 16:35-0500\n" "PO-Revision-Date: 2001-06-27 12:24+0200\n" "Last-Translator: Kjartan Maraas \n" "Language-Team: Norwegian \n" diff --git a/po/pl.po b/po/pl.po index ae1768a13..de4d75932 100644 --- a/po/pl.po +++ b/po/pl.po @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: rpm 4.0.3\n" -"POT-Creation-Date: 2002-11-19 13:41-0500\n" +"POT-Creation-Date: 2002-11-29 16:35-0500\n" "PO-Revision-Date: 1999-05-25 17:00+0100\n" "Last-Translator: Pawe³ Dziekoñski \n" "Language-Team: Polish \n" diff --git a/po/pt.po b/po/pt.po index 0a33a8b74..17e922f87 100644 --- a/po/pt.po +++ b/po/pt.po @@ -1,7 +1,7 @@ msgid "" msgstr "" "Project-Id-Version: rpm\n" -"POT-Creation-Date: 2002-11-19 13:41-0500\n" +"POT-Creation-Date: 2002-11-29 16:35-0500\n" "PO-Revision-Date: 2002-02-14 10:51+0000\n" "Last-Translator: José Nuno Coelho Sanarra Pires \n" "Language-Team: pt \n" "Language-Team: Romanian \n" diff --git a/po/rpm.pot b/po/rpm.pot index dd5b59077..cbd3576ce 100644 --- a/po/rpm.pot +++ b/po/rpm.pot @@ -7,7 +7,7 @@ msgid "" msgstr "" "Project-Id-Version: PACKAGE VERSION\n" -"POT-Creation-Date: 2002-11-19 13:41-0500\n" +"POT-Creation-Date: 2002-11-29 16:35-0500\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" diff --git a/po/ru.po b/po/ru.po index f0ab817e5..a49d232a4 100644 --- a/po/ru.po +++ b/po/ru.po @@ -1,7 +1,7 @@ msgid "" msgstr "" "Project-Id-Version: rpm 4.0.3\n" -"POT-Creation-Date: 2002-11-19 13:41-0500\n" +"POT-Creation-Date: 2002-11-29 16:35-0500\n" "PO-Revision-Date: 2002-08-27 13:36-0400\n" "Last-Translator: Eugene Kanter, \n" "Language-Team: Black Cat Linux Team \n" diff --git a/po/sk.po b/po/sk.po index edc8972fb..3396e09ec 100644 --- a/po/sk.po +++ b/po/sk.po @@ -1,7 +1,7 @@ msgid "" msgstr "" "Project-Id-Version: rpm 4.0.3\n" -"POT-Creation-Date: 2002-11-19 13:41-0500\n" +"POT-Creation-Date: 2002-11-29 16:35-0500\n" "PO-Revision-Date: 1999-04-08 21:37+02:00\n" "Last-Translator: Stanislav Meduna \n" "Language-Team: Slovak \n" diff --git a/po/sl.po b/po/sl.po index b5dc839a8..d6645f21c 100644 --- a/po/sl.po +++ b/po/sl.po @@ -1,12 +1,12 @@ # -*- mode:po; coding:iso-latin-2; -*- Slovenian messages for Redhat pkg. mngr. # Copyright (C) 2000 Free Software Foundation, Inc. # Primo¾ Peterlin , 2000. -# $Id: sl.po,v 1.326 2002/11/19 18:40:47 jbj Exp $ +# $Id: sl.po,v 1.327 2002/11/29 21:36:31 jbj Exp $ # msgid "" msgstr "" "Project-Id-Version: rpm 4.0.3\n" -"POT-Creation-Date: 2002-11-19 13:41-0500\n" +"POT-Creation-Date: 2002-11-29 16:35-0500\n" "PO-Revision-Date: 2000-10-08 19:05+0200\n" "Last-Translator: Grega Fajdiga \n" "Language-Team: Slovenian \n" diff --git a/po/sr.po b/po/sr.po index d938ad6cc..f15623d8d 100644 --- a/po/sr.po +++ b/po/sr.po @@ -1,7 +1,7 @@ msgid "" msgstr "" "Project-Id-Version: rpm 4.0.3\n" -"POT-Creation-Date: 2002-11-19 13:41-0500\n" +"POT-Creation-Date: 2002-11-29 16:35-0500\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=iso-8859-2\n" "Content-Transfer-Encoding: 8bit\n" diff --git a/po/sv.po b/po/sv.po index 744a783ed..eb4251404 100644 --- a/po/sv.po +++ b/po/sv.po @@ -1,7 +1,7 @@ msgid "" msgstr "" "Project-Id-Version: rpm 4.1\n" -"POT-Creation-Date: 2002-11-19 13:41-0500\n" +"POT-Creation-Date: 2002-11-29 16:35-0500\n" "PO-Revision-Date: 2002-08-19 22:26+0200\n" "Last-Translator: Göran Uddeborg \n" "Language-Team: Swedish \n" diff --git a/po/tr.po b/po/tr.po index ba8d12fa8..f77cfe6c2 100644 --- a/po/tr.po +++ b/po/tr.po @@ -1,7 +1,7 @@ msgid "" msgstr "" "Project-Id-Version: rpm 4.0.3\n" -"POT-Creation-Date: 2002-11-19 13:41-0500\n" +"POT-Creation-Date: 2002-11-29 16:35-0500\n" "PO-Revision-Date: 2001-07-05 08:02+300\n" "Last-Translator: Nilgun Belma Buguner \n" "Language-Team: Turkish \n" diff --git a/rpm.spec.in b/rpm.spec.in index 588dd3859..53030270e 100644 --- a/rpm.spec.in +++ b/rpm.spec.in @@ -27,6 +27,9 @@ Prereq: gawk fileutils textutils mktemp shadow-utils Requires: popt = 1.8 Obsoletes: rpm-perl < %{version} +# XXX not really necessary with internal elfutils +BuildRequires: elfutils + %if !%{with_internal_db} BuildRequires: db3-devel @@ -493,11 +496,12 @@ exit 0 %{__prefix}/include/popt.h %changelog -* Tue Nov 26 2002 Jeff Johnson 4.2-0.13 +* Fri Nov 29 2002 Jeff Johnson 4.2-0.13 - bundle libfmagic into librpmbuild for now. - apply patches 7 and 8 to db-4.1.24. - upgrade to elfutils-0.59. - add -g to all platforms optflags. +- build with external elfutils (preferred), if available. * Wed Nov 20 2002 Jeff Johnson 4.2-0.12 - use rpmdeps rather than find-{requires,provides}. diff --git a/rpmqv.c b/rpmqv.c index f3e50b0e4..6e42bfb11 100755 --- a/rpmqv.c +++ b/rpmqv.c @@ -391,7 +391,7 @@ int main(int argc, const char ** argv) else if (eflags) bigMode = MODE_ERASE; } -#endif /* IAM_RPMQV */ +#endif /* IAM_RPMEIU */ #ifdef IAM_RPMK if (bigMode == MODE_UNKNOWN || (bigMode & MODES_K)) { diff --git a/tools/Makefile.am b/tools/Makefile.am index b17938ba3..525131fd8 100644 --- a/tools/Makefile.am +++ b/tools/Makefile.am @@ -12,7 +12,6 @@ INCLUDES = -I. \ @WITH_LIBELF_INCLUDE@ \ @WITH_LIBDWARF_INCLUDE@ \ -I$(top_srcdir)/file \ - @WITH_ZLIB_INCLUDE@ \ @INCPATH@ \ -I$(top_srcdir)/misc -- cgit v1.2.3