From 3a22e55b52eadcb0559c1420f6818625d04dc2f284b22c1f900bb0f20d2afd31 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michael=20Schr=C3=B6der?= Date: Wed, 7 Apr 2010 15:12:18 +0000 Subject: [PATCH 1/6] - work around spurious tar message [bnc#558475] - fix defattr reset bug [bnc#594310] - don't consider prereq deprecated for now OBS-URL: https://build.opensuse.org/package/show/Base:System/rpm?expand=0&rev=46 --- noprereqdeprec.diff | 20 +++++++++++++++++ resetdefattr.diff | 55 +++++++++++++++++++++++++++++++++++++++++++++ rpm.changes | 7 ++++++ rpm.spec | 5 ++++- tarrecordsize.diff | 17 ++++++++++++++ 5 files changed, 103 insertions(+), 1 deletion(-) create mode 100644 noprereqdeprec.diff create mode 100644 resetdefattr.diff create mode 100644 tarrecordsize.diff diff --git a/noprereqdeprec.diff b/noprereqdeprec.diff new file mode 100644 index 0000000..7ac25c2 --- /dev/null +++ b/noprereqdeprec.diff @@ -0,0 +1,20 @@ +--- ./build/parsePreamble.c.orig 2010-04-07 14:52:57.000000000 +0000 ++++ ./build/parsePreamble.c 2010-04-07 14:53:51.000000000 +0000 +@@ -748,7 +748,7 @@ static struct PreambleRec_s const preamb + {RPMTAG_ICON, 0, 0, LEN_AND_STR("icon")}, + {RPMTAG_PROVIDEFLAGS, 0, 0, LEN_AND_STR("provides")}, + {RPMTAG_REQUIREFLAGS, 1, 0, LEN_AND_STR("requires")}, +- {RPMTAG_PREREQ, 1, 1, LEN_AND_STR("prereq")}, ++ {RPMTAG_PREREQ, 1, 0, LEN_AND_STR("prereq")}, + {RPMTAG_CONFLICTFLAGS, 0, 0, LEN_AND_STR("conflicts")}, + {RPMTAG_OBSOLETEFLAGS, 0, 0, LEN_AND_STR("obsoletes")}, + {RPMTAG_PREFIXES, 0, 0, LEN_AND_STR("prefixes")}, +@@ -757,7 +757,7 @@ static struct PreambleRec_s const preamb + {RPMTAG_BUILDARCHS, 0, 0, LEN_AND_STR("buildarchitectures")}, + {RPMTAG_BUILDARCHS, 0, 0, LEN_AND_STR("buildarch")}, + {RPMTAG_BUILDCONFLICTS, 0, 0, LEN_AND_STR("buildconflicts")}, +- {RPMTAG_BUILDPREREQ, 1, 1, LEN_AND_STR("buildprereq")}, ++ {RPMTAG_BUILDPREREQ, 1, 0, LEN_AND_STR("buildprereq")}, + {RPMTAG_BUILDREQUIRES, 1, 0, LEN_AND_STR("buildrequires")}, + {RPMTAG_AUTOREQPROV, 0, 0, LEN_AND_STR("autoreqprov")}, + {RPMTAG_AUTOREQ, 0, 0, LEN_AND_STR("autoreq")}, diff --git a/resetdefattr.diff b/resetdefattr.diff new file mode 100644 index 0000000..0e2a892 --- /dev/null +++ b/resetdefattr.diff @@ -0,0 +1,55 @@ +--- ./build/files.c.orig 2010-04-07 14:27:54.000000000 +0000 ++++ ./build/files.c 2010-04-07 14:51:11.000000000 +0000 +@@ -561,8 +561,13 @@ static rpmRC parseForAttr(const char * b + } + ar->ar_fmode = ui; + } else { +- ar->ar_fmodestr = fl->def_ar.ar_fmodestr; +- ar->ar_fmode = fl->def_ar.ar_fmode; ++ if (ret_ar == &(fl->def_ar)) { ++ ar->ar_fmodestr = NULL; ++ ar->ar_fmode = 0; ++ } else { ++ ar->ar_fmodestr = fl->def_ar.ar_fmodestr; ++ ar->ar_fmode = fl->def_ar.ar_fmode; ++ } + } + + if (ar->ar_dmodestr && !isAttrDefault(ar->ar_dmodestr)) { +@@ -574,15 +579,30 @@ static rpmRC parseForAttr(const char * b + } + ar->ar_dmode = ui; + } else { +- ar->ar_dmodestr = fl->def_ar.ar_dmodestr; +- ar->ar_dmode = fl->def_ar.ar_dmode; ++ if (ret_ar == &(fl->def_ar)) { ++ ar->ar_dmodestr = NULL; ++ ar->ar_dmode = 0; ++ } else { ++ ar->ar_dmodestr = fl->def_ar.ar_dmodestr; ++ ar->ar_dmode = fl->def_ar.ar_dmode; ++ } + } + +- if (!(ar->ar_user && !isAttrDefault(ar->ar_user))) +- ar->ar_user = fl->def_ar.ar_user; ++ if (!(ar->ar_user && !isAttrDefault(ar->ar_user))) { ++ if (ret_ar == &(fl->def_ar)) { ++ ar->ar_user = NULL; ++ } else { ++ ar->ar_user = fl->def_ar.ar_user; ++ } ++ } + +- if (!(ar->ar_group && !isAttrDefault(ar->ar_group))) +- ar->ar_group = fl->def_ar.ar_group; ++ if (!(ar->ar_group && !isAttrDefault(ar->ar_group))) { ++ if (ret_ar == &(fl->def_ar)) { ++ ar->ar_group = 0; ++ } else { ++ ar->ar_group = fl->def_ar.ar_group; ++ } ++ } + + dupAttrRec(ar, ret_ar); + diff --git a/rpm.changes b/rpm.changes index 364a858..6dd97c3 100644 --- a/rpm.changes +++ b/rpm.changes @@ -1,3 +1,10 @@ +------------------------------------------------------------------- +Wed Apr 7 16:59:58 CEST 2010 - mls@suse.de + +- work around spurious tar message [bnc#558475] +- fix defattr reset bug [bnc#594310] +- don't consider prereq deprecated for now + ------------------------------------------------------------------- Fri Mar 26 16:29:36 CET 2010 - mls@suse.de diff --git a/rpm.spec b/rpm.spec index fbfaa90..f60f189 100644 --- a/rpm.spec +++ b/rpm.spec @@ -105,6 +105,9 @@ Patch68: rpmdb-no-svc.diff Patch69: modemuncher.diff Patch70: repackage-nomd5.diff Patch71: safeugid.diff +Patch72: resetdefattr.diff +Patch73: noprereqdeprec.diff +Patch74: tarrecordsize.diff BuildRoot: %{_tmppath}/%{name}-%{version}-build # # avoid bootstrapping problem @@ -165,7 +168,7 @@ rm -f rpmdb/db.h %patch -P 40 -P 41 -P 42 -P 43 -P 44 -P 45 -P 46 -P 47 -P 48 -P 49 %patch -P 50 -P 51 -P 52 -P 53 -P 54 -P 55 -P 56 -P 57 -P 58 -P 59 %patch -P 60 -P 61 -P 62 -P 63 -P 64 -P 65 -P 66 -P 67 -P 68 -P 69 -%patch -P 70 -P 71 +%patch -P 70 -P 71 -P 72 -P 73 -P 74 #chmod 755 scripts/find-supplements{,.ksyms} #chmod 755 scripts/find-provides.ksyms scripts/find-requires.ksyms #chmod 755 scripts/firmware.prov diff --git a/tarrecordsize.diff b/tarrecordsize.diff new file mode 100644 index 0000000..7b79d61 --- /dev/null +++ b/tarrecordsize.diff @@ -0,0 +1,17 @@ +--- ./build.c.orig 2010-04-07 14:56:36.000000000 +0000 ++++ ./build.c 2010-04-07 14:58:52.000000000 +0000 +@@ -126,7 +126,13 @@ static char * getTarSpec(const char *arg + if (!(fp = popen(cmd, "r"))) { + rpmlog(RPMLOG_ERR, _("Failed to open tar pipe: %m\n")); + } else { +- char *fok = fgets(tarbuf, sizeof(tarbuf) - 1, fp); ++ char *fok; ++ for (;;) { ++ fok = fgets(tarbuf, sizeof(tarbuf) - 1, fp); ++ /* tar sometimes prints "tar: Record size = 16" messages */ ++ if (!fok || strncmp(fok, "tar: ", 5) != 0) ++ break; ++ } + pclose(fp); + gotspec = (fok != NULL) && isSpecFile(tmpSpecFile); + } From 8245a1792c13bea85069aaf6dfac31304d7c3d35f3a08cacc20e64162c8c6ceb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michael=20Schr=C3=B6der?= Date: Wed, 7 Apr 2010 16:07:43 +0000 Subject: [PATCH 2/6] - make 'rpmconfigcheck status' exit with 4 [bnc#592269] OBS-URL: https://build.opensuse.org/package/show/Base:System/rpm?expand=0&rev=47 --- rpm.changes | 1 + rpmconfigcheck | 6 +++++- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/rpm.changes b/rpm.changes index 6dd97c3..b4e072f 100644 --- a/rpm.changes +++ b/rpm.changes @@ -3,6 +3,7 @@ Wed Apr 7 16:59:58 CEST 2010 - mls@suse.de - work around spurious tar message [bnc#558475] - fix defattr reset bug [bnc#594310] +- make 'rpmconfigcheck status' exit with 4 [bnc#592269] - don't consider prereq deprecated for now ------------------------------------------------------------------- diff --git a/rpmconfigcheck b/rpmconfigcheck index a4eeb48..7699148 100644 --- a/rpmconfigcheck +++ b/rpmconfigcheck @@ -66,7 +66,11 @@ case "$1" in rm -f $configcheckfile.old $configcheckfile.dup $configcheckfile.new fi ;; - stop|status) + stop) + ;; + status) + rc_failed 4 + rc_status -v ;; *) echo "Usage: $0 {start}" From cc9e81ae5c0c4e6226b586ef85cd4510081d2d726c4549b21647d388afef6085 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michael=20Schr=C3=B6der?= Date: Thu, 8 Apr 2010 15:25:52 +0000 Subject: [PATCH 3/6] - backport some fixes from upstream - add generation of python/font/pkgconfig dependencies OBS-URL: https://build.opensuse.org/package/show/Base:System/rpm?expand=0&rev=48 --- backport.diff | 55 +++++++++++++++++++++++++++++++++++++ fontprovides.diff | 64 +++++++++++++++++++++++++++++++++++++++++++ pythondeps.diff | 69 +++++++++++++++++++++++++++++++++++++++++++++++ rpm.changes | 6 +++++ rpm.spec | 5 +++- 5 files changed, 198 insertions(+), 1 deletion(-) create mode 100644 backport.diff create mode 100644 fontprovides.diff create mode 100644 pythondeps.diff diff --git a/backport.diff b/backport.diff new file mode 100644 index 0000000..734f84f --- /dev/null +++ b/backport.diff @@ -0,0 +1,55 @@ +A couple of fixes picked from upstream. + +--- ./lib/rpminstall.c.orig 2010-04-08 12:35:48.000000000 +0000 ++++ ./lib/rpminstall.c 2010-04-08 12:36:00.000000000 +0000 +@@ -458,7 +458,7 @@ restart: + case URL_IS_HTTPS: + case URL_IS_HTTP: + case URL_IS_FTP: +- { char *tfn; ++ { char *tfn = NULL; + FD_t tfd; + + if (rpmIsVerbose()) +--- ./lib/transaction.c.orig 2010-04-08 12:33:22.000000000 +0000 ++++ ./lib/transaction.c 2010-04-08 12:35:00.000000000 +0000 +@@ -183,6 +183,10 @@ static void rpmtsUpdateDSI(const rpmts t + + if (fixupSize) + dsi->bneeded -= BLOCK_ROUND(fixupSize, dsi->bsize); ++ ++ /* adjust bookkeeping when requirements shrink */ ++ if (dsi->bneeded < dsi->obneeded) dsi->obneeded = dsi->bneeded; ++ if (dsi->ineeded < dsi->oineeded) dsi->oineeded = dsi->ineeded; + } + + static void rpmtsFindDSIMount(const rpmts ts, rpmDiskSpaceInfo dsi) +@@ -231,7 +235,7 @@ static void rpmtsCheckDSIProblems(const + for (; dsi->bsize; dsi++) { + + if (dsi->bavail >= 0 && adj_fs_blocks(dsi->bneeded) > dsi->bavail) { +- if (dsi->bneeded != dsi->obneeded) { ++ if (dsi->bneeded > dsi->obneeded) { + if (!dsi->mntPoint) + rpmtsFindDSIMount(ts, dsi); + rpmpsAppend(ps, RPMPROB_DISKSPACE, +@@ -243,7 +247,7 @@ static void rpmtsCheckDSIProblems(const + } + + if (dsi->iavail >= 0 && adj_fs_blocks(dsi->ineeded) > dsi->iavail) { +- if (dsi->ineeded != dsi->oineeded) { ++ if (dsi->ineeded > dsi->oineeded) { + if (!dsi->mntPoint) + rpmtsFindDSIMount(ts, dsi); + rpmpsAppend(ps, RPMPROB_DISKNODES, +--- ./lib/verify.c.orig 2010-04-08 12:36:09.000000000 +0000 ++++ ./lib/verify.c 2010-04-08 12:37:37.000000000 +0000 +@@ -348,7 +348,7 @@ static int verifyHeader(QVA_t qva, const + static const char *const aok = "."; + static const char *const unknown = "?"; + +- ec = (verifyResult != 0); ++ if (verifyResult) ec = 1; + + #define _verify(_RPMVERIFY_F, _C) \ + ((verifyResult & _RPMVERIFY_F) ? _C : aok) diff --git a/fontprovides.diff b/fontprovides.diff new file mode 100644 index 0000000..70d7537 --- /dev/null +++ b/fontprovides.diff @@ -0,0 +1,64 @@ +--- ./autodeps/linux.prov.orig 2010-04-08 14:52:42.000000000 +0000 ++++ ./autodeps/linux.prov 2010-04-08 15:04:37.000000000 +0000 +@@ -16,6 +16,8 @@ tcllist= + monolist=($(printf "%s\n" "${filelist[@]}" | egrep "\\.(exe|dll)\$")) + mimetypelist=($(printf "%s\n" "${filelist[@]}" | egrep "\\.(desktop)\$")) + firmwarelist=($(printf "%s\n" "${filelist[@]}" | grep "/lib/firmware/")) ++pkgconfiglist=($(printf "%s\n" "${filelist[@]}" | egrep '\.pc$')) ++fontlist=($(printf "%s\n" "${filelist[@]}" | egrep -i "/usr/share/fonts/.*\.(ttf|otf|pfa)$")) + + # + # --- Alpha does not mark 64bit dependencies +@@ -86,6 +88,16 @@ if [ -x $MONO_PREFIX/bin/mono -a -n "$mo + fi + + # ++# --- pkgconfig provides ++[ -x /usr/lib/rpm/pkgconfigdeps.sh -a -n "$pkgconfiglist" ] && ++ printf "%s\n" "${pkgconfiglist[@]}" | /usr/lib/rpm/pkgconfigdeps.sh -P | sort -u ++ ++# ++# --- font provides ++[ -x /usr/lib/rpm/fontconfig.prov -a -n "$fontlist" ] && ++ printf "%s\n" "${fontlist[@]}" | /usr/lib/rpm/fontconfig.prov | sort -u ++ ++# + # --- Kernel module exported symbols + [ -x /usr/lib/rpm/find-provides.ksyms ] && + printf "%s\n" "${filelist[@]}" | /usr/lib/rpm/find-provides.ksyms "$@" +--- ./autodeps/linux.req.orig 2010-04-08 15:01:18.000000000 +0000 ++++ ./autodeps/linux.req 2010-04-08 15:04:20.000000000 +0000 +@@ -35,6 +35,7 @@ perllist=() + pythonlist=($(printf "%s\n" "${filelist[@]}" | egrep '/usr/lib[^/]*/python.\..')) + tcllist=() + monolist=($(printf "%s\n" "${filelist[@]}" | egrep "\\.(exe|dll)(\\.config)?\$")) ++pkgconfiglist=($(printf "%s\n" "${filelist[@]}" | egrep '\.pc$')) + + # + # --- Alpha does not mark 64bit dependencies +@@ -144,6 +145,11 @@ if [ -x $MONO_PREFIX/bin/mono -a -n "$mo + fi + + # ++# --- pkgconfig requires ++[ -x /usr/lib/rpm/pkgconfigdeps.sh -a -n "$pkgconfiglist" ] && ++ printf "%s\n" "${pkgconfiglist[@]}" | /usr/lib/rpm/pkgconfigdeps.sh -R | sort -u ++ ++# + # --- Kernel module imported symbols + [ -x ${0%/*}/find-requires.ksyms ] && + printf "%s\n" "${filelist[@]}" | ${0%/*}/find-requires.ksyms "$@" +--- ./scripts/fontconfig.prov.orig 2010-04-08 14:57:21.000000000 +0000 ++++ ./scripts/fontconfig.prov 2010-04-08 14:57:42.000000000 +0000 +@@ -12,7 +12,10 @@ + + fcquery=/usr/bin/fc-query + +-[ -x $fcquery ] || exit 0 ++[ -x $fcquery ] || { ++ cat > /dev/null ++ exit 0 ++} + + # filter out anything outside main fontconfig path + grep /usr/share/fonts/ | diff --git a/pythondeps.diff b/pythondeps.diff new file mode 100644 index 0000000..6f07ea7 --- /dev/null +++ b/pythondeps.diff @@ -0,0 +1,69 @@ +--- ./autodeps/linux.prov.orig 2010-04-08 13:32:56.000000000 +0000 ++++ ./autodeps/linux.prov 2010-04-08 13:38:44.000000000 +0000 +@@ -11,7 +11,7 @@ filelist=($(printf "%s\n" "${filelist[@] + solist=($(printf "%s\n" "${filelist[@]}" | grep "\\.so" | grep -v "^/lib/ld.so" | \ + tr '\n' '\0' | xargs -0 -r file -L | grep "ELF.*shared object" | \ + cut -d: -f1)) +-pythonlist= ++pythonlist=($(printf "%s\n" "${filelist[@]}" | egrep '/usr/bin/python.\..$')) + tcllist= + monolist=($(printf "%s\n" "${filelist[@]}" | egrep "\\.(exe|dll)\$")) + mimetypelist=($(printf "%s\n" "${filelist[@]}" | egrep "\\.(desktop)\$")) +@@ -55,8 +55,8 @@ done | sort -u + + # + # --- Python modules. +-[ -x /usr/lib/rpm/python.prov -a -n "$pythonlist" ] && +- printf "%s\n" "${pythonlist[@]}" | /usr/lib/rpm/python.prov | sort -u ++[ -x /usr/lib/rpm/pythondeps.sh -a -n "$pythonlist" ] && ++ printf "%s\n" "${pythonlist[@]}" | /usr/lib/rpm/pythondeps.sh -P | sort -u + + # + # --- Tcl modules. +--- ./autodeps/linux.req.orig 2010-04-08 13:36:47.000000000 +0000 ++++ ./autodeps/linux.req 2010-04-08 13:40:25.000000000 +0000 +@@ -32,7 +32,7 @@ liblist=($(printf "%s\0" "${filelist[@]} + + interplist=() + perllist=() +-pythonlist=() ++pythonlist=($(printf "%s\n" "${filelist[@]}" | egrep '/usr/lib[^/]*/python.\..')) + tcllist=() + monolist=($(printf "%s\n" "${filelist[@]}" | egrep "\\.(exe|dll)(\\.config)?\$")) + +@@ -128,8 +128,8 @@ done | sort -u + + # + # --- Python modules. +-[ -x /usr/lib/rpm/python.req -a -n "$pythonlist" ] && \ +- printf "%s\n" "${pythonlist[@]}" | /usr/lib/rpm/python.req | sort -u ++[ -x /usr/lib/rpm/pythondeps.sh -a -n "$pythonlist" ] && \ ++ printf "%s\n" "${pythonlist[@]}" | /usr/lib/rpm/pythondeps.sh -R | sort -u + + # + # --- Tcl modules. +--- ./scripts/pythondeps.sh.orig 2010-04-08 13:40:34.000000000 +0000 ++++ ./scripts/pythondeps.sh 2010-04-08 13:42:19.000000000 +0000 +@@ -5,17 +5,17 @@ + exit 0 + } + +-PYVER=`python -c "import sys; v=sys.version_info[:2]; print '%d.%d'%v"` + case $1 in + -P|--provides) + shift +- grep "/usr/bin/python\*\$" >& /dev/null && echo "python(abi) = ${PYVER}" +- exit 0 ++ grep "/usr/bin/python.\..$" \ ++ | sed -e "s|.*/usr/bin/python\(.\..\)|python(abi) = \1|" + ;; + -R|--requires) + shift +- grep "/usr/lib[^/]*/python${PYVER}/" >& /dev/null && echo "python(abi) = ${PYVER}" +- exit 0 ++ grep "/usr/lib[^/]*/python.\../.*" \ ++ | sed -e "s|.*/usr/lib[^/]*/python\(.\..\)/.*|python(abi) = \1|g" \ ++ | sort | uniq + ;; + esac + diff --git a/rpm.changes b/rpm.changes index b4e072f..d42feac 100644 --- a/rpm.changes +++ b/rpm.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Thu Apr 8 17:11:08 CEST 2010 - mls@suse.de + +- backport some fixes from upstream +- add generation of python/font/pkgconfig dependencies + ------------------------------------------------------------------- Wed Apr 7 16:59:58 CEST 2010 - mls@suse.de diff --git a/rpm.spec b/rpm.spec index f60f189..1abc7f7 100644 --- a/rpm.spec +++ b/rpm.spec @@ -108,6 +108,9 @@ Patch71: safeugid.diff Patch72: resetdefattr.diff Patch73: noprereqdeprec.diff Patch74: tarrecordsize.diff +Patch75: backport.diff +Patch76: pythondeps.diff +Patch77: fontprovides.diff BuildRoot: %{_tmppath}/%{name}-%{version}-build # # avoid bootstrapping problem @@ -168,7 +171,7 @@ rm -f rpmdb/db.h %patch -P 40 -P 41 -P 42 -P 43 -P 44 -P 45 -P 46 -P 47 -P 48 -P 49 %patch -P 50 -P 51 -P 52 -P 53 -P 54 -P 55 -P 56 -P 57 -P 58 -P 59 %patch -P 60 -P 61 -P 62 -P 63 -P 64 -P 65 -P 66 -P 67 -P 68 -P 69 -%patch -P 70 -P 71 -P 72 -P 73 -P 74 +%patch -P 70 -P 71 -P 72 -P 73 -P 74 -P 75 -P 76 -P 77 #chmod 755 scripts/find-supplements{,.ksyms} #chmod 755 scripts/find-provides.ksyms scripts/find-requires.ksyms #chmod 755 scripts/firmware.prov From a907fe4ae3d4ccc18997dbf38c1ee3f6ec63b52572eaecce9895ef1b3f87e532 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michael=20Schr=C3=B6der?= Date: Fri, 9 Apr 2010 10:28:58 +0000 Subject: [PATCH 4/6] - do not load keyring if signature checking is disabled [bnc#554552] - fix nosource/nopatch srpm tag generation OBS-URL: https://build.opensuse.org/package/show/Base:System/rpm?expand=0&rev=49 --- nosignature.diff | 23 +++++++++++++++++++++++ nosource.diff | 36 ++++++++++++++++++++++++++++++++++++ rpm.changes | 6 ++++++ rpm.spec | 4 +++- 4 files changed, 68 insertions(+), 1 deletion(-) create mode 100644 nosignature.diff create mode 100644 nosource.diff diff --git a/nosignature.diff b/nosignature.diff new file mode 100644 index 0000000..0802056 --- /dev/null +++ b/nosignature.diff @@ -0,0 +1,23 @@ +Do not load keyring if signature checking is disabled. + +--- ./lib/package.c.orig 2010-04-09 09:56:42.000000000 +0000 ++++ ./lib/package.c 2010-04-09 09:57:50.000000000 +0000 +@@ -760,12 +760,16 @@ exit: + rpmRC rpmReadPackageFile(rpmts ts, FD_t fd, const char * fn, Header * hdrp) + { + rpmRC rc; +- rpmKeyring keyring = rpmtsGetKeyring(ts, 1); + rpmVSFlags vsflags = rpmtsVSFlags(ts); ++ rpmKeyring keyring = 0; ++ ++ if ((vsflags & _RPMVSF_NOSIGNATURES) != _RPMVSF_NOSIGNATURES) ++ keyring = rpmtsGetKeyring(ts, 1); + + rc = rpmpkgRead(keyring, vsflags, fd, fn, hdrp); + +- rpmKeyringFree(keyring); ++ if (keyring) ++ rpmKeyringFree(keyring); + return rc; + } + diff --git a/nosource.diff b/nosource.diff new file mode 100644 index 0000000..e824db0 --- /dev/null +++ b/nosource.diff @@ -0,0 +1,36 @@ +rpm does not allow headerPutUint32 on internal tags, so use +headerPut instead. (Maybe NOSOURCE/NOPATCH should not be internal +at all, though.) + +--- ./build/files.c.orig 2010-04-08 16:23:42.000000000 +0000 ++++ ./build/files.c 2010-04-08 16:23:44.000000000 +0000 +@@ -2088,15 +2088,25 @@ int processSourceFiles(rpmSpec spec) + if (srcPtr->flags & RPMBUILD_ISSOURCE) { + headerPutString(spec->sourceHeader, RPMTAG_SOURCE, srcPtr->source); + if (srcPtr->flags & RPMBUILD_ISNO) { +- headerPutUint32(spec->sourceHeader, RPMTAG_NOSOURCE, +- &srcPtr->num, 1); ++ struct rpmtd_s td; ++ rpmtdReset(&td); ++ td.tag = RPMTAG_NOSOURCE; ++ td.type = RPM_INT32_TYPE; ++ td.data = &srcPtr->num; ++ td.count = 1; ++ headerPut(spec->sourceHeader, &td, HEADERPUT_APPEND); + } + } + if (srcPtr->flags & RPMBUILD_ISPATCH) { + headerPutString(spec->sourceHeader, RPMTAG_PATCH, srcPtr->source); + if (srcPtr->flags & RPMBUILD_ISNO) { +- headerPutUint32(spec->sourceHeader, RPMTAG_NOSOURCE, +- &srcPtr->num, 1); ++ struct rpmtd_s td; ++ rpmtdReset(&td); ++ td.tag = RPMTAG_NOPATCH; ++ td.type = RPM_INT32_TYPE; ++ td.data = &srcPtr->num; ++ td.count = 1; ++ headerPut(spec->sourceHeader, &td, HEADERPUT_APPEND); + } + } + diff --git a/rpm.changes b/rpm.changes index d42feac..91e629b 100644 --- a/rpm.changes +++ b/rpm.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Fri Apr 9 12:00:29 CEST 2010 - mls@suse.de + +- do not load keyring if signature checking is disabled [bnc#554552] +- fix nosource/nopatch srpm tag generation + ------------------------------------------------------------------- Thu Apr 8 17:11:08 CEST 2010 - mls@suse.de diff --git a/rpm.spec b/rpm.spec index 1abc7f7..576aba9 100644 --- a/rpm.spec +++ b/rpm.spec @@ -111,6 +111,8 @@ Patch74: tarrecordsize.diff Patch75: backport.diff Patch76: pythondeps.diff Patch77: fontprovides.diff +Patch78: nosource.diff +Patch79: nosignature.diff BuildRoot: %{_tmppath}/%{name}-%{version}-build # # avoid bootstrapping problem @@ -171,7 +173,7 @@ rm -f rpmdb/db.h %patch -P 40 -P 41 -P 42 -P 43 -P 44 -P 45 -P 46 -P 47 -P 48 -P 49 %patch -P 50 -P 51 -P 52 -P 53 -P 54 -P 55 -P 56 -P 57 -P 58 -P 59 %patch -P 60 -P 61 -P 62 -P 63 -P 64 -P 65 -P 66 -P 67 -P 68 -P 69 -%patch -P 70 -P 71 -P 72 -P 73 -P 74 -P 75 -P 76 -P 77 +%patch -P 70 -P 71 -P 72 -P 73 -P 74 -P 75 -P 76 -P 77 -P 78 -P 79 #chmod 755 scripts/find-supplements{,.ksyms} #chmod 755 scripts/find-provides.ksyms scripts/find-requires.ksyms #chmod 755 scripts/firmware.prov From 68bb2738c176bc6a6ed68c91d1d8dd0e412df1c3193b4f1c8ceb508d9a7ecd52 Mon Sep 17 00:00:00 2001 From: OBS User autobuild Date: Tue, 13 Apr 2010 19:06:35 +0000 Subject: [PATCH 5/6] checked in (request 37534) OBS-URL: https://build.opensuse.org/package/show/Base:System/rpm?expand=0&rev=50 --- backport.diff | 55 ------------------------------------ fontprovides.diff | 64 ----------------------------------------- noprereqdeprec.diff | 20 ------------- nosignature.diff | 23 --------------- nosource.diff | 36 ----------------------- pythondeps.diff | 69 --------------------------------------------- resetdefattr.diff | 55 ------------------------------------ rpm.changes | 20 ------------- rpm.spec | 10 +------ rpmconfigcheck | 6 +--- tarrecordsize.diff | 17 ----------- 11 files changed, 2 insertions(+), 373 deletions(-) delete mode 100644 backport.diff delete mode 100644 fontprovides.diff delete mode 100644 noprereqdeprec.diff delete mode 100644 nosignature.diff delete mode 100644 nosource.diff delete mode 100644 pythondeps.diff delete mode 100644 resetdefattr.diff delete mode 100644 tarrecordsize.diff diff --git a/backport.diff b/backport.diff deleted file mode 100644 index 734f84f..0000000 --- a/backport.diff +++ /dev/null @@ -1,55 +0,0 @@ -A couple of fixes picked from upstream. - ---- ./lib/rpminstall.c.orig 2010-04-08 12:35:48.000000000 +0000 -+++ ./lib/rpminstall.c 2010-04-08 12:36:00.000000000 +0000 -@@ -458,7 +458,7 @@ restart: - case URL_IS_HTTPS: - case URL_IS_HTTP: - case URL_IS_FTP: -- { char *tfn; -+ { char *tfn = NULL; - FD_t tfd; - - if (rpmIsVerbose()) ---- ./lib/transaction.c.orig 2010-04-08 12:33:22.000000000 +0000 -+++ ./lib/transaction.c 2010-04-08 12:35:00.000000000 +0000 -@@ -183,6 +183,10 @@ static void rpmtsUpdateDSI(const rpmts t - - if (fixupSize) - dsi->bneeded -= BLOCK_ROUND(fixupSize, dsi->bsize); -+ -+ /* adjust bookkeeping when requirements shrink */ -+ if (dsi->bneeded < dsi->obneeded) dsi->obneeded = dsi->bneeded; -+ if (dsi->ineeded < dsi->oineeded) dsi->oineeded = dsi->ineeded; - } - - static void rpmtsFindDSIMount(const rpmts ts, rpmDiskSpaceInfo dsi) -@@ -231,7 +235,7 @@ static void rpmtsCheckDSIProblems(const - for (; dsi->bsize; dsi++) { - - if (dsi->bavail >= 0 && adj_fs_blocks(dsi->bneeded) > dsi->bavail) { -- if (dsi->bneeded != dsi->obneeded) { -+ if (dsi->bneeded > dsi->obneeded) { - if (!dsi->mntPoint) - rpmtsFindDSIMount(ts, dsi); - rpmpsAppend(ps, RPMPROB_DISKSPACE, -@@ -243,7 +247,7 @@ static void rpmtsCheckDSIProblems(const - } - - if (dsi->iavail >= 0 && adj_fs_blocks(dsi->ineeded) > dsi->iavail) { -- if (dsi->ineeded != dsi->oineeded) { -+ if (dsi->ineeded > dsi->oineeded) { - if (!dsi->mntPoint) - rpmtsFindDSIMount(ts, dsi); - rpmpsAppend(ps, RPMPROB_DISKNODES, ---- ./lib/verify.c.orig 2010-04-08 12:36:09.000000000 +0000 -+++ ./lib/verify.c 2010-04-08 12:37:37.000000000 +0000 -@@ -348,7 +348,7 @@ static int verifyHeader(QVA_t qva, const - static const char *const aok = "."; - static const char *const unknown = "?"; - -- ec = (verifyResult != 0); -+ if (verifyResult) ec = 1; - - #define _verify(_RPMVERIFY_F, _C) \ - ((verifyResult & _RPMVERIFY_F) ? _C : aok) diff --git a/fontprovides.diff b/fontprovides.diff deleted file mode 100644 index 70d7537..0000000 --- a/fontprovides.diff +++ /dev/null @@ -1,64 +0,0 @@ ---- ./autodeps/linux.prov.orig 2010-04-08 14:52:42.000000000 +0000 -+++ ./autodeps/linux.prov 2010-04-08 15:04:37.000000000 +0000 -@@ -16,6 +16,8 @@ tcllist= - monolist=($(printf "%s\n" "${filelist[@]}" | egrep "\\.(exe|dll)\$")) - mimetypelist=($(printf "%s\n" "${filelist[@]}" | egrep "\\.(desktop)\$")) - firmwarelist=($(printf "%s\n" "${filelist[@]}" | grep "/lib/firmware/")) -+pkgconfiglist=($(printf "%s\n" "${filelist[@]}" | egrep '\.pc$')) -+fontlist=($(printf "%s\n" "${filelist[@]}" | egrep -i "/usr/share/fonts/.*\.(ttf|otf|pfa)$")) - - # - # --- Alpha does not mark 64bit dependencies -@@ -86,6 +88,16 @@ if [ -x $MONO_PREFIX/bin/mono -a -n "$mo - fi - - # -+# --- pkgconfig provides -+[ -x /usr/lib/rpm/pkgconfigdeps.sh -a -n "$pkgconfiglist" ] && -+ printf "%s\n" "${pkgconfiglist[@]}" | /usr/lib/rpm/pkgconfigdeps.sh -P | sort -u -+ -+# -+# --- font provides -+[ -x /usr/lib/rpm/fontconfig.prov -a -n "$fontlist" ] && -+ printf "%s\n" "${fontlist[@]}" | /usr/lib/rpm/fontconfig.prov | sort -u -+ -+# - # --- Kernel module exported symbols - [ -x /usr/lib/rpm/find-provides.ksyms ] && - printf "%s\n" "${filelist[@]}" | /usr/lib/rpm/find-provides.ksyms "$@" ---- ./autodeps/linux.req.orig 2010-04-08 15:01:18.000000000 +0000 -+++ ./autodeps/linux.req 2010-04-08 15:04:20.000000000 +0000 -@@ -35,6 +35,7 @@ perllist=() - pythonlist=($(printf "%s\n" "${filelist[@]}" | egrep '/usr/lib[^/]*/python.\..')) - tcllist=() - monolist=($(printf "%s\n" "${filelist[@]}" | egrep "\\.(exe|dll)(\\.config)?\$")) -+pkgconfiglist=($(printf "%s\n" "${filelist[@]}" | egrep '\.pc$')) - - # - # --- Alpha does not mark 64bit dependencies -@@ -144,6 +145,11 @@ if [ -x $MONO_PREFIX/bin/mono -a -n "$mo - fi - - # -+# --- pkgconfig requires -+[ -x /usr/lib/rpm/pkgconfigdeps.sh -a -n "$pkgconfiglist" ] && -+ printf "%s\n" "${pkgconfiglist[@]}" | /usr/lib/rpm/pkgconfigdeps.sh -R | sort -u -+ -+# - # --- Kernel module imported symbols - [ -x ${0%/*}/find-requires.ksyms ] && - printf "%s\n" "${filelist[@]}" | ${0%/*}/find-requires.ksyms "$@" ---- ./scripts/fontconfig.prov.orig 2010-04-08 14:57:21.000000000 +0000 -+++ ./scripts/fontconfig.prov 2010-04-08 14:57:42.000000000 +0000 -@@ -12,7 +12,10 @@ - - fcquery=/usr/bin/fc-query - --[ -x $fcquery ] || exit 0 -+[ -x $fcquery ] || { -+ cat > /dev/null -+ exit 0 -+} - - # filter out anything outside main fontconfig path - grep /usr/share/fonts/ | diff --git a/noprereqdeprec.diff b/noprereqdeprec.diff deleted file mode 100644 index 7ac25c2..0000000 --- a/noprereqdeprec.diff +++ /dev/null @@ -1,20 +0,0 @@ ---- ./build/parsePreamble.c.orig 2010-04-07 14:52:57.000000000 +0000 -+++ ./build/parsePreamble.c 2010-04-07 14:53:51.000000000 +0000 -@@ -748,7 +748,7 @@ static struct PreambleRec_s const preamb - {RPMTAG_ICON, 0, 0, LEN_AND_STR("icon")}, - {RPMTAG_PROVIDEFLAGS, 0, 0, LEN_AND_STR("provides")}, - {RPMTAG_REQUIREFLAGS, 1, 0, LEN_AND_STR("requires")}, -- {RPMTAG_PREREQ, 1, 1, LEN_AND_STR("prereq")}, -+ {RPMTAG_PREREQ, 1, 0, LEN_AND_STR("prereq")}, - {RPMTAG_CONFLICTFLAGS, 0, 0, LEN_AND_STR("conflicts")}, - {RPMTAG_OBSOLETEFLAGS, 0, 0, LEN_AND_STR("obsoletes")}, - {RPMTAG_PREFIXES, 0, 0, LEN_AND_STR("prefixes")}, -@@ -757,7 +757,7 @@ static struct PreambleRec_s const preamb - {RPMTAG_BUILDARCHS, 0, 0, LEN_AND_STR("buildarchitectures")}, - {RPMTAG_BUILDARCHS, 0, 0, LEN_AND_STR("buildarch")}, - {RPMTAG_BUILDCONFLICTS, 0, 0, LEN_AND_STR("buildconflicts")}, -- {RPMTAG_BUILDPREREQ, 1, 1, LEN_AND_STR("buildprereq")}, -+ {RPMTAG_BUILDPREREQ, 1, 0, LEN_AND_STR("buildprereq")}, - {RPMTAG_BUILDREQUIRES, 1, 0, LEN_AND_STR("buildrequires")}, - {RPMTAG_AUTOREQPROV, 0, 0, LEN_AND_STR("autoreqprov")}, - {RPMTAG_AUTOREQ, 0, 0, LEN_AND_STR("autoreq")}, diff --git a/nosignature.diff b/nosignature.diff deleted file mode 100644 index 0802056..0000000 --- a/nosignature.diff +++ /dev/null @@ -1,23 +0,0 @@ -Do not load keyring if signature checking is disabled. - ---- ./lib/package.c.orig 2010-04-09 09:56:42.000000000 +0000 -+++ ./lib/package.c 2010-04-09 09:57:50.000000000 +0000 -@@ -760,12 +760,16 @@ exit: - rpmRC rpmReadPackageFile(rpmts ts, FD_t fd, const char * fn, Header * hdrp) - { - rpmRC rc; -- rpmKeyring keyring = rpmtsGetKeyring(ts, 1); - rpmVSFlags vsflags = rpmtsVSFlags(ts); -+ rpmKeyring keyring = 0; -+ -+ if ((vsflags & _RPMVSF_NOSIGNATURES) != _RPMVSF_NOSIGNATURES) -+ keyring = rpmtsGetKeyring(ts, 1); - - rc = rpmpkgRead(keyring, vsflags, fd, fn, hdrp); - -- rpmKeyringFree(keyring); -+ if (keyring) -+ rpmKeyringFree(keyring); - return rc; - } - diff --git a/nosource.diff b/nosource.diff deleted file mode 100644 index e824db0..0000000 --- a/nosource.diff +++ /dev/null @@ -1,36 +0,0 @@ -rpm does not allow headerPutUint32 on internal tags, so use -headerPut instead. (Maybe NOSOURCE/NOPATCH should not be internal -at all, though.) - ---- ./build/files.c.orig 2010-04-08 16:23:42.000000000 +0000 -+++ ./build/files.c 2010-04-08 16:23:44.000000000 +0000 -@@ -2088,15 +2088,25 @@ int processSourceFiles(rpmSpec spec) - if (srcPtr->flags & RPMBUILD_ISSOURCE) { - headerPutString(spec->sourceHeader, RPMTAG_SOURCE, srcPtr->source); - if (srcPtr->flags & RPMBUILD_ISNO) { -- headerPutUint32(spec->sourceHeader, RPMTAG_NOSOURCE, -- &srcPtr->num, 1); -+ struct rpmtd_s td; -+ rpmtdReset(&td); -+ td.tag = RPMTAG_NOSOURCE; -+ td.type = RPM_INT32_TYPE; -+ td.data = &srcPtr->num; -+ td.count = 1; -+ headerPut(spec->sourceHeader, &td, HEADERPUT_APPEND); - } - } - if (srcPtr->flags & RPMBUILD_ISPATCH) { - headerPutString(spec->sourceHeader, RPMTAG_PATCH, srcPtr->source); - if (srcPtr->flags & RPMBUILD_ISNO) { -- headerPutUint32(spec->sourceHeader, RPMTAG_NOSOURCE, -- &srcPtr->num, 1); -+ struct rpmtd_s td; -+ rpmtdReset(&td); -+ td.tag = RPMTAG_NOPATCH; -+ td.type = RPM_INT32_TYPE; -+ td.data = &srcPtr->num; -+ td.count = 1; -+ headerPut(spec->sourceHeader, &td, HEADERPUT_APPEND); - } - } - diff --git a/pythondeps.diff b/pythondeps.diff deleted file mode 100644 index 6f07ea7..0000000 --- a/pythondeps.diff +++ /dev/null @@ -1,69 +0,0 @@ ---- ./autodeps/linux.prov.orig 2010-04-08 13:32:56.000000000 +0000 -+++ ./autodeps/linux.prov 2010-04-08 13:38:44.000000000 +0000 -@@ -11,7 +11,7 @@ filelist=($(printf "%s\n" "${filelist[@] - solist=($(printf "%s\n" "${filelist[@]}" | grep "\\.so" | grep -v "^/lib/ld.so" | \ - tr '\n' '\0' | xargs -0 -r file -L | grep "ELF.*shared object" | \ - cut -d: -f1)) --pythonlist= -+pythonlist=($(printf "%s\n" "${filelist[@]}" | egrep '/usr/bin/python.\..$')) - tcllist= - monolist=($(printf "%s\n" "${filelist[@]}" | egrep "\\.(exe|dll)\$")) - mimetypelist=($(printf "%s\n" "${filelist[@]}" | egrep "\\.(desktop)\$")) -@@ -55,8 +55,8 @@ done | sort -u - - # - # --- Python modules. --[ -x /usr/lib/rpm/python.prov -a -n "$pythonlist" ] && -- printf "%s\n" "${pythonlist[@]}" | /usr/lib/rpm/python.prov | sort -u -+[ -x /usr/lib/rpm/pythondeps.sh -a -n "$pythonlist" ] && -+ printf "%s\n" "${pythonlist[@]}" | /usr/lib/rpm/pythondeps.sh -P | sort -u - - # - # --- Tcl modules. ---- ./autodeps/linux.req.orig 2010-04-08 13:36:47.000000000 +0000 -+++ ./autodeps/linux.req 2010-04-08 13:40:25.000000000 +0000 -@@ -32,7 +32,7 @@ liblist=($(printf "%s\0" "${filelist[@]} - - interplist=() - perllist=() --pythonlist=() -+pythonlist=($(printf "%s\n" "${filelist[@]}" | egrep '/usr/lib[^/]*/python.\..')) - tcllist=() - monolist=($(printf "%s\n" "${filelist[@]}" | egrep "\\.(exe|dll)(\\.config)?\$")) - -@@ -128,8 +128,8 @@ done | sort -u - - # - # --- Python modules. --[ -x /usr/lib/rpm/python.req -a -n "$pythonlist" ] && \ -- printf "%s\n" "${pythonlist[@]}" | /usr/lib/rpm/python.req | sort -u -+[ -x /usr/lib/rpm/pythondeps.sh -a -n "$pythonlist" ] && \ -+ printf "%s\n" "${pythonlist[@]}" | /usr/lib/rpm/pythondeps.sh -R | sort -u - - # - # --- Tcl modules. ---- ./scripts/pythondeps.sh.orig 2010-04-08 13:40:34.000000000 +0000 -+++ ./scripts/pythondeps.sh 2010-04-08 13:42:19.000000000 +0000 -@@ -5,17 +5,17 @@ - exit 0 - } - --PYVER=`python -c "import sys; v=sys.version_info[:2]; print '%d.%d'%v"` - case $1 in - -P|--provides) - shift -- grep "/usr/bin/python\*\$" >& /dev/null && echo "python(abi) = ${PYVER}" -- exit 0 -+ grep "/usr/bin/python.\..$" \ -+ | sed -e "s|.*/usr/bin/python\(.\..\)|python(abi) = \1|" - ;; - -R|--requires) - shift -- grep "/usr/lib[^/]*/python${PYVER}/" >& /dev/null && echo "python(abi) = ${PYVER}" -- exit 0 -+ grep "/usr/lib[^/]*/python.\../.*" \ -+ | sed -e "s|.*/usr/lib[^/]*/python\(.\..\)/.*|python(abi) = \1|g" \ -+ | sort | uniq - ;; - esac - diff --git a/resetdefattr.diff b/resetdefattr.diff deleted file mode 100644 index 0e2a892..0000000 --- a/resetdefattr.diff +++ /dev/null @@ -1,55 +0,0 @@ ---- ./build/files.c.orig 2010-04-07 14:27:54.000000000 +0000 -+++ ./build/files.c 2010-04-07 14:51:11.000000000 +0000 -@@ -561,8 +561,13 @@ static rpmRC parseForAttr(const char * b - } - ar->ar_fmode = ui; - } else { -- ar->ar_fmodestr = fl->def_ar.ar_fmodestr; -- ar->ar_fmode = fl->def_ar.ar_fmode; -+ if (ret_ar == &(fl->def_ar)) { -+ ar->ar_fmodestr = NULL; -+ ar->ar_fmode = 0; -+ } else { -+ ar->ar_fmodestr = fl->def_ar.ar_fmodestr; -+ ar->ar_fmode = fl->def_ar.ar_fmode; -+ } - } - - if (ar->ar_dmodestr && !isAttrDefault(ar->ar_dmodestr)) { -@@ -574,15 +579,30 @@ static rpmRC parseForAttr(const char * b - } - ar->ar_dmode = ui; - } else { -- ar->ar_dmodestr = fl->def_ar.ar_dmodestr; -- ar->ar_dmode = fl->def_ar.ar_dmode; -+ if (ret_ar == &(fl->def_ar)) { -+ ar->ar_dmodestr = NULL; -+ ar->ar_dmode = 0; -+ } else { -+ ar->ar_dmodestr = fl->def_ar.ar_dmodestr; -+ ar->ar_dmode = fl->def_ar.ar_dmode; -+ } - } - -- if (!(ar->ar_user && !isAttrDefault(ar->ar_user))) -- ar->ar_user = fl->def_ar.ar_user; -+ if (!(ar->ar_user && !isAttrDefault(ar->ar_user))) { -+ if (ret_ar == &(fl->def_ar)) { -+ ar->ar_user = NULL; -+ } else { -+ ar->ar_user = fl->def_ar.ar_user; -+ } -+ } - -- if (!(ar->ar_group && !isAttrDefault(ar->ar_group))) -- ar->ar_group = fl->def_ar.ar_group; -+ if (!(ar->ar_group && !isAttrDefault(ar->ar_group))) { -+ if (ret_ar == &(fl->def_ar)) { -+ ar->ar_group = 0; -+ } else { -+ ar->ar_group = fl->def_ar.ar_group; -+ } -+ } - - dupAttrRec(ar, ret_ar); - diff --git a/rpm.changes b/rpm.changes index 91e629b..364a858 100644 --- a/rpm.changes +++ b/rpm.changes @@ -1,23 +1,3 @@ -------------------------------------------------------------------- -Fri Apr 9 12:00:29 CEST 2010 - mls@suse.de - -- do not load keyring if signature checking is disabled [bnc#554552] -- fix nosource/nopatch srpm tag generation - -------------------------------------------------------------------- -Thu Apr 8 17:11:08 CEST 2010 - mls@suse.de - -- backport some fixes from upstream -- add generation of python/font/pkgconfig dependencies - -------------------------------------------------------------------- -Wed Apr 7 16:59:58 CEST 2010 - mls@suse.de - -- work around spurious tar message [bnc#558475] -- fix defattr reset bug [bnc#594310] -- make 'rpmconfigcheck status' exit with 4 [bnc#592269] -- don't consider prereq deprecated for now - ------------------------------------------------------------------- Fri Mar 26 16:29:36 CET 2010 - mls@suse.de diff --git a/rpm.spec b/rpm.spec index 576aba9..fbfaa90 100644 --- a/rpm.spec +++ b/rpm.spec @@ -105,14 +105,6 @@ Patch68: rpmdb-no-svc.diff Patch69: modemuncher.diff Patch70: repackage-nomd5.diff Patch71: safeugid.diff -Patch72: resetdefattr.diff -Patch73: noprereqdeprec.diff -Patch74: tarrecordsize.diff -Patch75: backport.diff -Patch76: pythondeps.diff -Patch77: fontprovides.diff -Patch78: nosource.diff -Patch79: nosignature.diff BuildRoot: %{_tmppath}/%{name}-%{version}-build # # avoid bootstrapping problem @@ -173,7 +165,7 @@ rm -f rpmdb/db.h %patch -P 40 -P 41 -P 42 -P 43 -P 44 -P 45 -P 46 -P 47 -P 48 -P 49 %patch -P 50 -P 51 -P 52 -P 53 -P 54 -P 55 -P 56 -P 57 -P 58 -P 59 %patch -P 60 -P 61 -P 62 -P 63 -P 64 -P 65 -P 66 -P 67 -P 68 -P 69 -%patch -P 70 -P 71 -P 72 -P 73 -P 74 -P 75 -P 76 -P 77 -P 78 -P 79 +%patch -P 70 -P 71 #chmod 755 scripts/find-supplements{,.ksyms} #chmod 755 scripts/find-provides.ksyms scripts/find-requires.ksyms #chmod 755 scripts/firmware.prov diff --git a/rpmconfigcheck b/rpmconfigcheck index 7699148..a4eeb48 100644 --- a/rpmconfigcheck +++ b/rpmconfigcheck @@ -66,11 +66,7 @@ case "$1" in rm -f $configcheckfile.old $configcheckfile.dup $configcheckfile.new fi ;; - stop) - ;; - status) - rc_failed 4 - rc_status -v + stop|status) ;; *) echo "Usage: $0 {start}" diff --git a/tarrecordsize.diff b/tarrecordsize.diff deleted file mode 100644 index 7b79d61..0000000 --- a/tarrecordsize.diff +++ /dev/null @@ -1,17 +0,0 @@ ---- ./build.c.orig 2010-04-07 14:56:36.000000000 +0000 -+++ ./build.c 2010-04-07 14:58:52.000000000 +0000 -@@ -126,7 +126,13 @@ static char * getTarSpec(const char *arg - if (!(fp = popen(cmd, "r"))) { - rpmlog(RPMLOG_ERR, _("Failed to open tar pipe: %m\n")); - } else { -- char *fok = fgets(tarbuf, sizeof(tarbuf) - 1, fp); -+ char *fok; -+ for (;;) { -+ fok = fgets(tarbuf, sizeof(tarbuf) - 1, fp); -+ /* tar sometimes prints "tar: Record size = 16" messages */ -+ if (!fok || strncmp(fok, "tar: ", 5) != 0) -+ break; -+ } - pclose(fp); - gotspec = (fok != NULL) && isSpecFile(tmpSpecFile); - } From 7b6eaa99d46468c7f327b3ac13af39d9d417f0d34006f1dae37bb96ee6aef9f2 Mon Sep 17 00:00:00 2001 From: OBS User buildservice-autocommit Date: Tue, 13 Apr 2010 19:06:36 +0000 Subject: [PATCH 6/6] Updating link to change in openSUSE:Factory/rpm revision 96.0 OBS-URL: https://build.opensuse.org/package/show/Base:System/rpm?expand=0&rev=c85e21a7ea9af7ce97598c7d3caa62e5 --- backport.diff | 55 ++++++++++++++++++++++++++++++++++++ fontprovides.diff | 64 +++++++++++++++++++++++++++++++++++++++++ noprereqdeprec.diff | 20 +++++++++++++ nosignature.diff | 23 +++++++++++++++ nosource.diff | 36 +++++++++++++++++++++++ pythondeps.diff | 69 +++++++++++++++++++++++++++++++++++++++++++++ resetdefattr.diff | 55 ++++++++++++++++++++++++++++++++++++ rpm-python.spec | 2 +- rpm.changes | 20 +++++++++++++ rpm.spec | 12 ++++++-- rpmconfigcheck | 6 +++- tarrecordsize.diff | 17 +++++++++++ 12 files changed, 375 insertions(+), 4 deletions(-) create mode 100644 backport.diff create mode 100644 fontprovides.diff create mode 100644 noprereqdeprec.diff create mode 100644 nosignature.diff create mode 100644 nosource.diff create mode 100644 pythondeps.diff create mode 100644 resetdefattr.diff create mode 100644 tarrecordsize.diff diff --git a/backport.diff b/backport.diff new file mode 100644 index 0000000..734f84f --- /dev/null +++ b/backport.diff @@ -0,0 +1,55 @@ +A couple of fixes picked from upstream. + +--- ./lib/rpminstall.c.orig 2010-04-08 12:35:48.000000000 +0000 ++++ ./lib/rpminstall.c 2010-04-08 12:36:00.000000000 +0000 +@@ -458,7 +458,7 @@ restart: + case URL_IS_HTTPS: + case URL_IS_HTTP: + case URL_IS_FTP: +- { char *tfn; ++ { char *tfn = NULL; + FD_t tfd; + + if (rpmIsVerbose()) +--- ./lib/transaction.c.orig 2010-04-08 12:33:22.000000000 +0000 ++++ ./lib/transaction.c 2010-04-08 12:35:00.000000000 +0000 +@@ -183,6 +183,10 @@ static void rpmtsUpdateDSI(const rpmts t + + if (fixupSize) + dsi->bneeded -= BLOCK_ROUND(fixupSize, dsi->bsize); ++ ++ /* adjust bookkeeping when requirements shrink */ ++ if (dsi->bneeded < dsi->obneeded) dsi->obneeded = dsi->bneeded; ++ if (dsi->ineeded < dsi->oineeded) dsi->oineeded = dsi->ineeded; + } + + static void rpmtsFindDSIMount(const rpmts ts, rpmDiskSpaceInfo dsi) +@@ -231,7 +235,7 @@ static void rpmtsCheckDSIProblems(const + for (; dsi->bsize; dsi++) { + + if (dsi->bavail >= 0 && adj_fs_blocks(dsi->bneeded) > dsi->bavail) { +- if (dsi->bneeded != dsi->obneeded) { ++ if (dsi->bneeded > dsi->obneeded) { + if (!dsi->mntPoint) + rpmtsFindDSIMount(ts, dsi); + rpmpsAppend(ps, RPMPROB_DISKSPACE, +@@ -243,7 +247,7 @@ static void rpmtsCheckDSIProblems(const + } + + if (dsi->iavail >= 0 && adj_fs_blocks(dsi->ineeded) > dsi->iavail) { +- if (dsi->ineeded != dsi->oineeded) { ++ if (dsi->ineeded > dsi->oineeded) { + if (!dsi->mntPoint) + rpmtsFindDSIMount(ts, dsi); + rpmpsAppend(ps, RPMPROB_DISKNODES, +--- ./lib/verify.c.orig 2010-04-08 12:36:09.000000000 +0000 ++++ ./lib/verify.c 2010-04-08 12:37:37.000000000 +0000 +@@ -348,7 +348,7 @@ static int verifyHeader(QVA_t qva, const + static const char *const aok = "."; + static const char *const unknown = "?"; + +- ec = (verifyResult != 0); ++ if (verifyResult) ec = 1; + + #define _verify(_RPMVERIFY_F, _C) \ + ((verifyResult & _RPMVERIFY_F) ? _C : aok) diff --git a/fontprovides.diff b/fontprovides.diff new file mode 100644 index 0000000..70d7537 --- /dev/null +++ b/fontprovides.diff @@ -0,0 +1,64 @@ +--- ./autodeps/linux.prov.orig 2010-04-08 14:52:42.000000000 +0000 ++++ ./autodeps/linux.prov 2010-04-08 15:04:37.000000000 +0000 +@@ -16,6 +16,8 @@ tcllist= + monolist=($(printf "%s\n" "${filelist[@]}" | egrep "\\.(exe|dll)\$")) + mimetypelist=($(printf "%s\n" "${filelist[@]}" | egrep "\\.(desktop)\$")) + firmwarelist=($(printf "%s\n" "${filelist[@]}" | grep "/lib/firmware/")) ++pkgconfiglist=($(printf "%s\n" "${filelist[@]}" | egrep '\.pc$')) ++fontlist=($(printf "%s\n" "${filelist[@]}" | egrep -i "/usr/share/fonts/.*\.(ttf|otf|pfa)$")) + + # + # --- Alpha does not mark 64bit dependencies +@@ -86,6 +88,16 @@ if [ -x $MONO_PREFIX/bin/mono -a -n "$mo + fi + + # ++# --- pkgconfig provides ++[ -x /usr/lib/rpm/pkgconfigdeps.sh -a -n "$pkgconfiglist" ] && ++ printf "%s\n" "${pkgconfiglist[@]}" | /usr/lib/rpm/pkgconfigdeps.sh -P | sort -u ++ ++# ++# --- font provides ++[ -x /usr/lib/rpm/fontconfig.prov -a -n "$fontlist" ] && ++ printf "%s\n" "${fontlist[@]}" | /usr/lib/rpm/fontconfig.prov | sort -u ++ ++# + # --- Kernel module exported symbols + [ -x /usr/lib/rpm/find-provides.ksyms ] && + printf "%s\n" "${filelist[@]}" | /usr/lib/rpm/find-provides.ksyms "$@" +--- ./autodeps/linux.req.orig 2010-04-08 15:01:18.000000000 +0000 ++++ ./autodeps/linux.req 2010-04-08 15:04:20.000000000 +0000 +@@ -35,6 +35,7 @@ perllist=() + pythonlist=($(printf "%s\n" "${filelist[@]}" | egrep '/usr/lib[^/]*/python.\..')) + tcllist=() + monolist=($(printf "%s\n" "${filelist[@]}" | egrep "\\.(exe|dll)(\\.config)?\$")) ++pkgconfiglist=($(printf "%s\n" "${filelist[@]}" | egrep '\.pc$')) + + # + # --- Alpha does not mark 64bit dependencies +@@ -144,6 +145,11 @@ if [ -x $MONO_PREFIX/bin/mono -a -n "$mo + fi + + # ++# --- pkgconfig requires ++[ -x /usr/lib/rpm/pkgconfigdeps.sh -a -n "$pkgconfiglist" ] && ++ printf "%s\n" "${pkgconfiglist[@]}" | /usr/lib/rpm/pkgconfigdeps.sh -R | sort -u ++ ++# + # --- Kernel module imported symbols + [ -x ${0%/*}/find-requires.ksyms ] && + printf "%s\n" "${filelist[@]}" | ${0%/*}/find-requires.ksyms "$@" +--- ./scripts/fontconfig.prov.orig 2010-04-08 14:57:21.000000000 +0000 ++++ ./scripts/fontconfig.prov 2010-04-08 14:57:42.000000000 +0000 +@@ -12,7 +12,10 @@ + + fcquery=/usr/bin/fc-query + +-[ -x $fcquery ] || exit 0 ++[ -x $fcquery ] || { ++ cat > /dev/null ++ exit 0 ++} + + # filter out anything outside main fontconfig path + grep /usr/share/fonts/ | diff --git a/noprereqdeprec.diff b/noprereqdeprec.diff new file mode 100644 index 0000000..7ac25c2 --- /dev/null +++ b/noprereqdeprec.diff @@ -0,0 +1,20 @@ +--- ./build/parsePreamble.c.orig 2010-04-07 14:52:57.000000000 +0000 ++++ ./build/parsePreamble.c 2010-04-07 14:53:51.000000000 +0000 +@@ -748,7 +748,7 @@ static struct PreambleRec_s const preamb + {RPMTAG_ICON, 0, 0, LEN_AND_STR("icon")}, + {RPMTAG_PROVIDEFLAGS, 0, 0, LEN_AND_STR("provides")}, + {RPMTAG_REQUIREFLAGS, 1, 0, LEN_AND_STR("requires")}, +- {RPMTAG_PREREQ, 1, 1, LEN_AND_STR("prereq")}, ++ {RPMTAG_PREREQ, 1, 0, LEN_AND_STR("prereq")}, + {RPMTAG_CONFLICTFLAGS, 0, 0, LEN_AND_STR("conflicts")}, + {RPMTAG_OBSOLETEFLAGS, 0, 0, LEN_AND_STR("obsoletes")}, + {RPMTAG_PREFIXES, 0, 0, LEN_AND_STR("prefixes")}, +@@ -757,7 +757,7 @@ static struct PreambleRec_s const preamb + {RPMTAG_BUILDARCHS, 0, 0, LEN_AND_STR("buildarchitectures")}, + {RPMTAG_BUILDARCHS, 0, 0, LEN_AND_STR("buildarch")}, + {RPMTAG_BUILDCONFLICTS, 0, 0, LEN_AND_STR("buildconflicts")}, +- {RPMTAG_BUILDPREREQ, 1, 1, LEN_AND_STR("buildprereq")}, ++ {RPMTAG_BUILDPREREQ, 1, 0, LEN_AND_STR("buildprereq")}, + {RPMTAG_BUILDREQUIRES, 1, 0, LEN_AND_STR("buildrequires")}, + {RPMTAG_AUTOREQPROV, 0, 0, LEN_AND_STR("autoreqprov")}, + {RPMTAG_AUTOREQ, 0, 0, LEN_AND_STR("autoreq")}, diff --git a/nosignature.diff b/nosignature.diff new file mode 100644 index 0000000..0802056 --- /dev/null +++ b/nosignature.diff @@ -0,0 +1,23 @@ +Do not load keyring if signature checking is disabled. + +--- ./lib/package.c.orig 2010-04-09 09:56:42.000000000 +0000 ++++ ./lib/package.c 2010-04-09 09:57:50.000000000 +0000 +@@ -760,12 +760,16 @@ exit: + rpmRC rpmReadPackageFile(rpmts ts, FD_t fd, const char * fn, Header * hdrp) + { + rpmRC rc; +- rpmKeyring keyring = rpmtsGetKeyring(ts, 1); + rpmVSFlags vsflags = rpmtsVSFlags(ts); ++ rpmKeyring keyring = 0; ++ ++ if ((vsflags & _RPMVSF_NOSIGNATURES) != _RPMVSF_NOSIGNATURES) ++ keyring = rpmtsGetKeyring(ts, 1); + + rc = rpmpkgRead(keyring, vsflags, fd, fn, hdrp); + +- rpmKeyringFree(keyring); ++ if (keyring) ++ rpmKeyringFree(keyring); + return rc; + } + diff --git a/nosource.diff b/nosource.diff new file mode 100644 index 0000000..e824db0 --- /dev/null +++ b/nosource.diff @@ -0,0 +1,36 @@ +rpm does not allow headerPutUint32 on internal tags, so use +headerPut instead. (Maybe NOSOURCE/NOPATCH should not be internal +at all, though.) + +--- ./build/files.c.orig 2010-04-08 16:23:42.000000000 +0000 ++++ ./build/files.c 2010-04-08 16:23:44.000000000 +0000 +@@ -2088,15 +2088,25 @@ int processSourceFiles(rpmSpec spec) + if (srcPtr->flags & RPMBUILD_ISSOURCE) { + headerPutString(spec->sourceHeader, RPMTAG_SOURCE, srcPtr->source); + if (srcPtr->flags & RPMBUILD_ISNO) { +- headerPutUint32(spec->sourceHeader, RPMTAG_NOSOURCE, +- &srcPtr->num, 1); ++ struct rpmtd_s td; ++ rpmtdReset(&td); ++ td.tag = RPMTAG_NOSOURCE; ++ td.type = RPM_INT32_TYPE; ++ td.data = &srcPtr->num; ++ td.count = 1; ++ headerPut(spec->sourceHeader, &td, HEADERPUT_APPEND); + } + } + if (srcPtr->flags & RPMBUILD_ISPATCH) { + headerPutString(spec->sourceHeader, RPMTAG_PATCH, srcPtr->source); + if (srcPtr->flags & RPMBUILD_ISNO) { +- headerPutUint32(spec->sourceHeader, RPMTAG_NOSOURCE, +- &srcPtr->num, 1); ++ struct rpmtd_s td; ++ rpmtdReset(&td); ++ td.tag = RPMTAG_NOPATCH; ++ td.type = RPM_INT32_TYPE; ++ td.data = &srcPtr->num; ++ td.count = 1; ++ headerPut(spec->sourceHeader, &td, HEADERPUT_APPEND); + } + } + diff --git a/pythondeps.diff b/pythondeps.diff new file mode 100644 index 0000000..6f07ea7 --- /dev/null +++ b/pythondeps.diff @@ -0,0 +1,69 @@ +--- ./autodeps/linux.prov.orig 2010-04-08 13:32:56.000000000 +0000 ++++ ./autodeps/linux.prov 2010-04-08 13:38:44.000000000 +0000 +@@ -11,7 +11,7 @@ filelist=($(printf "%s\n" "${filelist[@] + solist=($(printf "%s\n" "${filelist[@]}" | grep "\\.so" | grep -v "^/lib/ld.so" | \ + tr '\n' '\0' | xargs -0 -r file -L | grep "ELF.*shared object" | \ + cut -d: -f1)) +-pythonlist= ++pythonlist=($(printf "%s\n" "${filelist[@]}" | egrep '/usr/bin/python.\..$')) + tcllist= + monolist=($(printf "%s\n" "${filelist[@]}" | egrep "\\.(exe|dll)\$")) + mimetypelist=($(printf "%s\n" "${filelist[@]}" | egrep "\\.(desktop)\$")) +@@ -55,8 +55,8 @@ done | sort -u + + # + # --- Python modules. +-[ -x /usr/lib/rpm/python.prov -a -n "$pythonlist" ] && +- printf "%s\n" "${pythonlist[@]}" | /usr/lib/rpm/python.prov | sort -u ++[ -x /usr/lib/rpm/pythondeps.sh -a -n "$pythonlist" ] && ++ printf "%s\n" "${pythonlist[@]}" | /usr/lib/rpm/pythondeps.sh -P | sort -u + + # + # --- Tcl modules. +--- ./autodeps/linux.req.orig 2010-04-08 13:36:47.000000000 +0000 ++++ ./autodeps/linux.req 2010-04-08 13:40:25.000000000 +0000 +@@ -32,7 +32,7 @@ liblist=($(printf "%s\0" "${filelist[@]} + + interplist=() + perllist=() +-pythonlist=() ++pythonlist=($(printf "%s\n" "${filelist[@]}" | egrep '/usr/lib[^/]*/python.\..')) + tcllist=() + monolist=($(printf "%s\n" "${filelist[@]}" | egrep "\\.(exe|dll)(\\.config)?\$")) + +@@ -128,8 +128,8 @@ done | sort -u + + # + # --- Python modules. +-[ -x /usr/lib/rpm/python.req -a -n "$pythonlist" ] && \ +- printf "%s\n" "${pythonlist[@]}" | /usr/lib/rpm/python.req | sort -u ++[ -x /usr/lib/rpm/pythondeps.sh -a -n "$pythonlist" ] && \ ++ printf "%s\n" "${pythonlist[@]}" | /usr/lib/rpm/pythondeps.sh -R | sort -u + + # + # --- Tcl modules. +--- ./scripts/pythondeps.sh.orig 2010-04-08 13:40:34.000000000 +0000 ++++ ./scripts/pythondeps.sh 2010-04-08 13:42:19.000000000 +0000 +@@ -5,17 +5,17 @@ + exit 0 + } + +-PYVER=`python -c "import sys; v=sys.version_info[:2]; print '%d.%d'%v"` + case $1 in + -P|--provides) + shift +- grep "/usr/bin/python\*\$" >& /dev/null && echo "python(abi) = ${PYVER}" +- exit 0 ++ grep "/usr/bin/python.\..$" \ ++ | sed -e "s|.*/usr/bin/python\(.\..\)|python(abi) = \1|" + ;; + -R|--requires) + shift +- grep "/usr/lib[^/]*/python${PYVER}/" >& /dev/null && echo "python(abi) = ${PYVER}" +- exit 0 ++ grep "/usr/lib[^/]*/python.\../.*" \ ++ | sed -e "s|.*/usr/lib[^/]*/python\(.\..\)/.*|python(abi) = \1|g" \ ++ | sort | uniq + ;; + esac + diff --git a/resetdefattr.diff b/resetdefattr.diff new file mode 100644 index 0000000..0e2a892 --- /dev/null +++ b/resetdefattr.diff @@ -0,0 +1,55 @@ +--- ./build/files.c.orig 2010-04-07 14:27:54.000000000 +0000 ++++ ./build/files.c 2010-04-07 14:51:11.000000000 +0000 +@@ -561,8 +561,13 @@ static rpmRC parseForAttr(const char * b + } + ar->ar_fmode = ui; + } else { +- ar->ar_fmodestr = fl->def_ar.ar_fmodestr; +- ar->ar_fmode = fl->def_ar.ar_fmode; ++ if (ret_ar == &(fl->def_ar)) { ++ ar->ar_fmodestr = NULL; ++ ar->ar_fmode = 0; ++ } else { ++ ar->ar_fmodestr = fl->def_ar.ar_fmodestr; ++ ar->ar_fmode = fl->def_ar.ar_fmode; ++ } + } + + if (ar->ar_dmodestr && !isAttrDefault(ar->ar_dmodestr)) { +@@ -574,15 +579,30 @@ static rpmRC parseForAttr(const char * b + } + ar->ar_dmode = ui; + } else { +- ar->ar_dmodestr = fl->def_ar.ar_dmodestr; +- ar->ar_dmode = fl->def_ar.ar_dmode; ++ if (ret_ar == &(fl->def_ar)) { ++ ar->ar_dmodestr = NULL; ++ ar->ar_dmode = 0; ++ } else { ++ ar->ar_dmodestr = fl->def_ar.ar_dmodestr; ++ ar->ar_dmode = fl->def_ar.ar_dmode; ++ } + } + +- if (!(ar->ar_user && !isAttrDefault(ar->ar_user))) +- ar->ar_user = fl->def_ar.ar_user; ++ if (!(ar->ar_user && !isAttrDefault(ar->ar_user))) { ++ if (ret_ar == &(fl->def_ar)) { ++ ar->ar_user = NULL; ++ } else { ++ ar->ar_user = fl->def_ar.ar_user; ++ } ++ } + +- if (!(ar->ar_group && !isAttrDefault(ar->ar_group))) +- ar->ar_group = fl->def_ar.ar_group; ++ if (!(ar->ar_group && !isAttrDefault(ar->ar_group))) { ++ if (ret_ar == &(fl->def_ar)) { ++ ar->ar_group = 0; ++ } else { ++ ar->ar_group = fl->def_ar.ar_group; ++ } ++ } + + dupAttrRec(ar, ret_ar); + diff --git a/rpm-python.spec b/rpm-python.spec index 99636b0..b4b29ad 100644 --- a/rpm-python.spec +++ b/rpm-python.spec @@ -25,7 +25,7 @@ License: GPLv2+ Group: System/Packages Summary: Python Bindings for Manipulating RPM Packages Version: 4.8.0 -Release: 1 +Release: 2 Requires: rpm = %{version} %py_requires Source99: rpm.spec diff --git a/rpm.changes b/rpm.changes index 364a858..91e629b 100644 --- a/rpm.changes +++ b/rpm.changes @@ -1,3 +1,23 @@ +------------------------------------------------------------------- +Fri Apr 9 12:00:29 CEST 2010 - mls@suse.de + +- do not load keyring if signature checking is disabled [bnc#554552] +- fix nosource/nopatch srpm tag generation + +------------------------------------------------------------------- +Thu Apr 8 17:11:08 CEST 2010 - mls@suse.de + +- backport some fixes from upstream +- add generation of python/font/pkgconfig dependencies + +------------------------------------------------------------------- +Wed Apr 7 16:59:58 CEST 2010 - mls@suse.de + +- work around spurious tar message [bnc#558475] +- fix defattr reset bug [bnc#594310] +- make 'rpmconfigcheck status' exit with 4 [bnc#592269] +- don't consider prereq deprecated for now + ------------------------------------------------------------------- Fri Mar 26 16:29:36 CET 2010 - mls@suse.de diff --git a/rpm.spec b/rpm.spec index fbfaa90..50db57e 100644 --- a/rpm.spec +++ b/rpm.spec @@ -28,7 +28,7 @@ PreReq: %insserv_prereq %fillup_prereq permissions AutoReqProv: on Summary: The RPM Package Manager Version: 4.8.0 -Release: 1 +Release: 2 Source: rpm-%{version}.tar.bz2 Source1: RPM-HOWTO.tar.bz2 Source2: RPM-Tips.html.tar.bz2 @@ -105,6 +105,14 @@ Patch68: rpmdb-no-svc.diff Patch69: modemuncher.diff Patch70: repackage-nomd5.diff Patch71: safeugid.diff +Patch72: resetdefattr.diff +Patch73: noprereqdeprec.diff +Patch74: tarrecordsize.diff +Patch75: backport.diff +Patch76: pythondeps.diff +Patch77: fontprovides.diff +Patch78: nosource.diff +Patch79: nosignature.diff BuildRoot: %{_tmppath}/%{name}-%{version}-build # # avoid bootstrapping problem @@ -165,7 +173,7 @@ rm -f rpmdb/db.h %patch -P 40 -P 41 -P 42 -P 43 -P 44 -P 45 -P 46 -P 47 -P 48 -P 49 %patch -P 50 -P 51 -P 52 -P 53 -P 54 -P 55 -P 56 -P 57 -P 58 -P 59 %patch -P 60 -P 61 -P 62 -P 63 -P 64 -P 65 -P 66 -P 67 -P 68 -P 69 -%patch -P 70 -P 71 +%patch -P 70 -P 71 -P 72 -P 73 -P 74 -P 75 -P 76 -P 77 -P 78 -P 79 #chmod 755 scripts/find-supplements{,.ksyms} #chmod 755 scripts/find-provides.ksyms scripts/find-requires.ksyms #chmod 755 scripts/firmware.prov diff --git a/rpmconfigcheck b/rpmconfigcheck index a4eeb48..7699148 100644 --- a/rpmconfigcheck +++ b/rpmconfigcheck @@ -66,7 +66,11 @@ case "$1" in rm -f $configcheckfile.old $configcheckfile.dup $configcheckfile.new fi ;; - stop|status) + stop) + ;; + status) + rc_failed 4 + rc_status -v ;; *) echo "Usage: $0 {start}" diff --git a/tarrecordsize.diff b/tarrecordsize.diff new file mode 100644 index 0000000..7b79d61 --- /dev/null +++ b/tarrecordsize.diff @@ -0,0 +1,17 @@ +--- ./build.c.orig 2010-04-07 14:56:36.000000000 +0000 ++++ ./build.c 2010-04-07 14:58:52.000000000 +0000 +@@ -126,7 +126,13 @@ static char * getTarSpec(const char *arg + if (!(fp = popen(cmd, "r"))) { + rpmlog(RPMLOG_ERR, _("Failed to open tar pipe: %m\n")); + } else { +- char *fok = fgets(tarbuf, sizeof(tarbuf) - 1, fp); ++ char *fok; ++ for (;;) { ++ fok = fgets(tarbuf, sizeof(tarbuf) - 1, fp); ++ /* tar sometimes prints "tar: Record size = 16" messages */ ++ if (!fok || strncmp(fok, "tar: ", 5) != 0) ++ break; ++ } + pclose(fp); + gotspec = (fok != NULL) && isSpecFile(tmpSpecFile); + }