summaryrefslogtreecommitdiffstats
path: root/redhat/build/update_repository.sh
diff options
context:
space:
mode:
authorFrançois Andriot <albator78@libertysurf.fr>2015-06-29 20:17:57 +0200
committerFrançois Andriot <albator78@libertysurf.fr>2015-06-29 20:17:57 +0200
commit2835777e9ae7bde053e0da2f083ee020f26ea04a (patch)
tree8695f4161ce1d52053a016a69712dcd8cea97d4d /redhat/build/update_repository.sh
parentd3c1f8ab667376639b6ff83e4eff50cd861fe5d2 (diff)
downloadtde-packaging-2835777e9ae7bde053e0da2f083ee020f26ea04a.tar.gz
tde-packaging-2835777e9ae7bde053e0da2f083ee020f26ea04a.zip
RPM Packaging: massive update spec files
Diffstat (limited to 'redhat/build/update_repository.sh')
-rwxr-xr-xredhat/build/update_repository.sh4
1 files changed, 3 insertions, 1 deletions
diff --git a/redhat/build/update_repository.sh b/redhat/build/update_repository.sh
index 1694f34f4..72a142db9 100755
--- a/redhat/build/update_repository.sh
+++ b/redhat/build/update_repository.sh
@@ -15,7 +15,9 @@ RPMDIR=$(rpm -E %{_rpmdir}.tde-${TDE_VERSION})
[ -d "${RPMDIR}/noarch" ] || mkdir -p "${RPMDIR}/noarch"
[ -d "${RPMDIR}/${ARCH}" ] || mkdir -p "${RPMDIR}/${ARCH}"
-if [ -x /usr/sbin/urpmi ]; then
+if [ -x /usr/bin/dnf ]; then
+ REPOUPDATE='(cd ${RPMDIR}; createrepo --workers=${WORKERS} ${ARCH} & createrepo --workers=${WORKERS} noarch & wait; sudo dnf clean all --disablerepo="*" --enablerepo="rpmbuild*")'
+elif [ -x /usr/sbin/urpmi ]; then
REPOUPDATE='(cd ${RPMDIR}; genhdlist2 --clean --allow-empty noarch & genhdlist2 --clean --allow-empty ${ARCH} & wait; sudo urpmi.update rpmbuild.${ARCH} rpmbuild.noarch)'
elif [ -x /usr/bin/zypper ]; then
REPOUPDATE='(cd ${RPMDIR}; createrepo --workers=${WORKERS} ${ARCH} & createrepo --workers=${WORKERS} noarch & wait; sudo zypper refresh rpmbuild.${ARCH} rpmbuild.noarch)'