diff -r 71503088f51b -r f880f219c566 openpkg/rpmpopt
--- a/openpkg/rpmpopt Tue Jul 31 12:12:54 2012 +0200
+++ b/openpkg/rpmpopt Tue Jul 31 12:23:42 2012 +0200
@@ -1,14 +1,13 @@
##
## rpmpopt -- OpenPKG RPM POPT Configuration
-## Copyright (c) 2000-2007 OpenPKG Foundation e.V.
-## Copyright (c) 2000-2007 Ralf S. Engelschall
+## Copyright (c) 2000-2012 OpenPKG GmbH
##
-## Permission to use, copy, modify, and distribute this software for
-## any purpose with or without fee is hereby granted, provided that
-## the above copyright notice and this permission notice appear in all
-## copies.
+## This software is property of the OpenPKG GmbH, DE MUC HRB 160208.
+## All rights reserved. Licenses which grant limited permission to use,
+## copy, modify and distribute this software are available from the
+## OpenPKG GmbH.
##
-## THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
+## THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESSED OR IMPLIED
## WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
## MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
## IN NO EVENT SHALL THE AUTHORS AND COPYRIGHT HOLDERS AND THEIR
@@ -21,11 +20,17 @@
## OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
## SUCH DAMAGE.
##
+
+##
## The purpose of this configuration file is to extend and override
## the "rpmpopt" directives in the default RPM POPT configuration with
## OpenPKG specific extensions and adjustments.
##
+# extended short-hand option
+rpm alias --force --replacepkgs --replacefiles --oldpackage --noparentdirs \
+ --POPTdesc=$"force operation (short hand for --replacepkgs --replacefiles --oldpackage --noparentdirs on installation)"
+
# backward compatibility for old RPM extensions
rpm exec --stowaway echo "install \"openpkg-tools\" and use \"openpkg stowaway\" now please."
rpm exec --makeproxy echo "install \"openpkg-tools\" and use \"openpkg makeproxy\" now please."
@@ -58,6 +63,8 @@
# RPM extension: "rpm --db-{build,rebuild,cleanup,fixate}"
rpm exec --db-build rpmdb --build \
--POPTdesc=$"RPM database administration: build new database (destructive operation; you have to know what you are doing)"
+rpm exec --db-migrate rpmdb --migrate \
+ --POPTdesc=$"RPM database administration: change database format (migration operation; you have to know what you are doing)"
rpm exec --db-rebuild rpmdb --rebuild \
--POPTdesc=$"RPM database administration: rebuild new from old database (upgrading operation; reasonable after upgrades or on DB corruption)"
rpm exec --db-cleanup rpmdb --cleanup \
@@ -66,7 +73,7 @@
--POPTdesc=$"RPM database administration: fixate existing database (harmless operation; for fixating files only)"
# RPM extension: "rpm --db-private ..."
-rpm alias --db-private --define "_rpmdb_private yes" \
+rpm alias --db-private --define "__dbi_private yes" \
--POPTdesc=$"operate RPM database in Berkeley-DB DB_PRIVATE mode"
# RPM extension: "rpm --track"
@@ -77,8 +84,8 @@
rpm alias --track-dump -bt --define '___track_dump yes' \
--POPTdesc=$"dump the vendor source tracking script (%track)"
-# RPM extension: "rpm --test"
-rpm alias --test -q --qf '%{TEST}\n' \
+# RPM extension: "rpm --runtime-test"
+rpm alias --runtime-test -q --qf '%{TEST}\n' \
--pipe "grep -v \(none\) | @l_prefix@/lib/openpkg/bash" \
--POPTdesc=$"run package run-time test script (%test)"
@@ -91,11 +98,39 @@
# RPM adjustment: "rpm --setugids ..."
rpm alias --setugids -q --qf \
'[run %{FILEUSERNAME:shescape} %{FILEGROUPNAME:shescape} %{FILENAMES:shescape}\n]' \
- --pipe "(echo 'run () { chown -- \"$1\" \"$3\"; chgrp -- \"$2\" \"$3\"; }'; grep -v '(none)') | @l_prefix@/lib/openpkg/bash" \
+ --pipe "(echo 'run () { chown -h -- \"$1\" \"$3\"; chgrp -h -- \"$2\" \"$3\"; }'; grep -v '(none)') | @l_prefix@/lib/openpkg/bash" \
--POPTdesc=$"set user/group ownership of files in a package"
+# RPM extension: "rpm -qp --environment"
+rpm alias --environment --qf '%{Environment}\n' \
+ --pipe "@l_prefix@/lib/openpkg/rpm --eval '%{__environment_to_xml}'" \
+ --POPTdesc=$"query the recursively tracked build environment of a package as XML"
+
+# RPM extension: "rpm --marker "
+rpm alias --mark --define "__marker !#:+" \
+ --POPTdesc=$"mark package with Marker: " \
+ --POPTargs=$""
+
+# RPM adjustment: "rpm -bs" implies "--nodeps"
+rpm alias -bs -bs --nodeps
+
+# RPM exentsion: "rpm --no-build{dependency,environment}"
+rpm alias --no-builddependency --undefine "__autogen_builddependency" \
+ --POPTdesc=$"do not auto-generate BuildDependency tag"
+rpm alias --no-buildenvironment --undefine "__autogen_buildenvironment" \
+ --POPTdesc=$"do not auto-generate BuildEnvironment tag"
+
+# RPM extension: "rpm --layout "
+rpm alias --layout --define "openpkg_layout basedir=%(pwd) layout=!#:+" \
+ --POPTdesc=$"choose a particular packaging environment layout (global, local, simple, structured, distributed)" \
+ --POPTargs=$""
+
+# RPM extension: "rpm --local"
+rpm alias --local --define "openpkg_layout basedir=%(pwd) layout=local" \
+ --POPTdesc=$"choose the 'local' packaging environment layout based on current directory as the base directory"
+
# RPM adjustment: improved and cleaned up "rpm -i/--info"
-rpmq alias --info --qf '\
+rpm alias --info --qf '\
Name: %-25{NAME} Source RPM: %{SOURCERPM}\n\
Version: %-25{VERSION} Signature: %|DSAHEADER?{dsa:%{DSAHEADER:pgpsig}}:{%|RSAHEADER?{rsa:%{RSAHEADER:pgpsig}}:{%|SIGGPG?{gpg:%{SIGGPG:pgpsig}}:{%|SIGPGP?{pgp:%{SIGPGP:pgpsig}}:{%|SIGMD5?{md5:%{SIGMD5}}:{(none)}|}|}|}|}|\n\
Release: %-25{RELEASE} Build Host: %{BUILDHOST}\n\
@@ -109,6 +144,12 @@
URL: %{URL}\n\
Description:\n%{DESCRIPTION}\n\
%|PROVIDENAME?{Provides:\n\
-[ %{PROVIDENAME} %|PROVIDEFLAGS?{%{PROVIDEFLAGS:depflags} %{PROVIDEVERSION}}:{}|\n]}:{}|\
+[ %{PROVIDENAME}%|PROVIDEFLAGS?{%{PROVIDEFLAGS:depflags}%{PROVIDEVERSION}}:{}|\n]}:{}|\
+%|CONFLICTNAME?{Conflicts:\n\
+[ %{CONFLICTNAME}%|CONFLICTFLAGS?{%{CONFLICTFLAGS:depflags}%{CONFLICTVERSION}}:{}|\n]}:{}|\
+%|OBSOLETENAME?{Obsoletes:\n\
+[ %{OBSOLETENAME}%|OBSOLETEFLAGS?{%{OBSOLETEFLAGS:depflags}%{OBSOLETEVERSION}}:{}|\n]}:{}|\
+%|REQUIRENAME?{Requires:\n\
+[ %{REQUIRENAME}%|REQUIREFLAGS?{%{REQUIREFLAGS:depflags}%{REQUIREVERSION}}:{}|\n]}:{}|\
' --POPTdesc=$"list descriptive information from package(s)"