SPECS: repackage.sh - another hack for rpm 4.4.9 to skip %clean an...
glen
glen at pld-linux.org
Tue Jan 29 22:09:18 CET 2008
Author: glen Date: Tue Jan 29 21:09:18 2008 GMT
Module: SPECS Tag: HEAD
---- Log message:
- another hack for rpm 4.4.9 to skip %clean and be 4.4.2 compatible
---- Files affected:
SPECS:
repackage.sh (1.20 -> 1.21)
---- Diffs:
================================================================
Index: SPECS/repackage.sh
diff -u SPECS/repackage.sh:1.20 SPECS/repackage.sh:1.21
--- SPECS/repackage.sh:1.20 Sun Jan 27 01:40:45 2008
+++ SPECS/repackage.sh Tue Jan 29 22:09:13 2008
@@ -21,18 +21,22 @@
rpmbuild() {
# use gz payload as time is what we need here, not compress ratio
+
+ # we use %__ldconfig variable to test are we on rpm 4.4.9
+ # on 4.4.9 we should not redefine %clean to contain %clean, and redefine %__spec_clean_body instead
+ # on 4.4.2 we must redefine %clean to contain %clean
set -x
/usr/bin/rpmbuild \
${TARGET:+--target $TARGET} \
$BCONDS \
--short-circuit \
- --define '_source_payload w9.gzdio' \
- --define '__spec_install_pre %___build_pre' \
- --define '__spec_clean_body %{nil}' \
- --define 'clean %%clean \
+ --define 'clean %%%{!?__ldconfig:clean}%{?__ldconfig:check} \
exit 0%{nil}' \
--define 'check %%check \
exit 0%{nil}' \
+ --define '_source_payload w9.gzdio' \
+ --define '__spec_install_pre %___build_pre' \
+ --define '__spec_clean_body %{nil}' \
"$@" || exit
}
================================================================
---- CVS-web:
http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/SPECS/repackage.sh?r1=1.20&r2=1.21&f=u
More information about the pld-cvs-commit
mailing list