From bbe9c10ae848838adafe5772aec8f8b9624c4432 Mon Sep 17 00:00:00 2001 From: Marcin Krol Date: Tue, 15 Jan 2019 08:35:40 +0000 Subject: [PATCH] - drop attic distfiles support, attic no longer exists - fix url, we dropped backward compatible ditfiles subdir linking --- builder.sh | 44 +++----------------------------------------- rpm-build-tools.spec | 2 +- 2 files changed, 4 insertions(+), 42 deletions(-) diff --git a/builder.sh b/builder.sh index 9f62964..056cdf4 100755 --- a/builder.sh +++ b/builder.sh @@ -127,14 +127,12 @@ TLD_GIT_SERVER="git://git.tld-linux.org" TLD_GIT_PUSH="git@git.tld-linux.org:7272" TLD_PACKAGES_DIR="packages" TLD_DISTFILES_SERVER="://df.tld-linux.org" -TLD_ATTICDISTFILES_SERVER="" # PLD git/df config PLD_GIT_SERVER="git://git.pld-linux.org" PLD_GIT_PUSH="git@git.pld-linux.org" PLD_PACKAGES_DIR="packages" PLD_DISTFILES_SERVER="://distfiles.pld-linux.org" -PLD_ATTICDISTFILES_SERVER="://attic-distfiles.pld-linux.org" CVS_FORCE="" CVSIGNORE_DF="yes" @@ -151,7 +149,6 @@ NEW_REPO="" RES_FILE="" DISTFILES_SERVER=${TLD_DISTFILES_SERVER} -ATTICDISTFILES_SERVER=${TLD_ATTICDISTFILES_SERVER} DEF_NICE_LEVEL=19 SCHEDTOOL="auto" @@ -1121,11 +1118,7 @@ distfiles_path() { } distfiles_url() { - echo "$PROTOCOL$DISTFILES_SERVER/distfiles/$(distfiles_path "$1")" -} - -distfiles_attic_url() { - echo "$PROTOCOL$ATTICDISTFILES_SERVER/distfiles/Attic/$(distfiles_path "$1")" + echo "$PROTOCOL$DISTFILES_SERVER/$(distfiles_path "$1")" } good_md5() { @@ -1299,7 +1292,6 @@ get_files() { url=$(distfiles_url "$i") fi - url_attic=$(distfiles_attic_url "$i") FROM_DISTFILES=1 # is $url local file? if [[ "$url" = [./]* ]]; then @@ -1308,9 +1300,8 @@ get_files() { else local uri=${url} # make shorter message for distfiles urls - if [[ "$uri" = ${PROTOCOL}${DISTFILES_SERVER}* ]] || [[ "$uri" = ${PROTOCOL}${ATTICDISTFILES_SERVER}* ]]; then - uri=${uri#${PROTOCOL}${DISTFILES_SERVER}/distfiles/by-md5/?/?/*/} - uri=${uri#${PROTOCOL}${ATTICDISTFILES_SERVER}/distfiles/by-md5/?/?/*/} + if [[ "$uri" = ${PROTOCOL}${DISTFILES_SERVER}* ]]; then + uri=${uri#${PROTOCOL}${DISTFILES_SERVER}/by-md5/?/?/*/} uri="df: $uri" fi update_shell_title "${GETURI%% *}: $uri" @@ -1321,23 +1312,6 @@ get_files() { fi fi - # is it empty file? - if [ ! -s "$target" ]; then - rm -f "$target" - if [ `echo $url_attic | grep -E '^(\.|/)'` ]; then - update_shell_title "${GETLOCAL%% *}: $url_attic" - ${GETLOCAL} $url_attic $target - else - update_shell_title "${GETURI%% *}: $url_attic" - ${GETURI} ${OUTFILEOPT} "$target" "$url_attic" || \ - if [ "`echo $url_attic | grep -E 'ftp://'`" ]; then - update_shell_title "${GETURI2%% *}: $url_attic" - ${GETURI2} ${OUTFILEOPT} "$target" "$url_attic" - fi - test -s "$target" || rm -f "$target" - fi - fi - if [ -s "$target" ]; then cvsignore_df $target else @@ -1387,15 +1361,6 @@ get_files() { update_shell_title "${GETURI2%% *}: $url" ${GETURI2} ${OUTFILEOPT} "$target" "$url" fi - if [ ! -s "$target" ]; then - rm -f "$target" - update_shell_title "${GETURI%% *}: $url_attic" - ${GETURI} ${OUTFILEOPT} "$target" "$url_attic" || \ - if [ "`echo $url_attic | grep -E 'ftp://'`" ]; then - update_shell_title "${GETURI2%% *}: $url_attic" - ${GETURI2} ${OUTFILEOPT} "$target" "$url_attic" - fi - fi test -s "$target" || rm -f "$target" fi done @@ -2485,7 +2450,6 @@ while [ $# -gt 0 ]; do GIT_PUSH=${PLD_GIT_PUSH} PACKAGES_DIR=${PLD_PACKAGES_DIR} DISTFILES_SERVER=${PLD_DISTFILES_SERVER} - ATTICDISTFILES_SERVER=${PLD_ATTICDISTFILES_SERVER} ;; --git-tld) shift @@ -2493,7 +2457,6 @@ while [ $# -gt 0 ]; do GIT_PUSH=${TLD_GIT_PUSH} PACKAGES_DIR=${TLD_PACKAGES_DIR} DISTFILES_SERVER=${TLD_DISTFILES_SERVER} - ATTICDISTFILES_SERVER=${TLD_ATTICDISTFILES_SERVER} ;; --pkgrev) COMMAND="set_pkgrev" @@ -2524,7 +2487,6 @@ if ! git ls-remote --heads ${GIT_SERVER}/${PACKAGES_DIR}/${ASSUMED_NAME} 1>/dev/ GIT_PUSH=${PLD_GIT_PUSH} PACKAGES_DIR=${PLD_PACKAGES_DIR} DISTFILES_SERVER=${PLD_DISTFILES_SERVER} - ATTICDISTFILES_SERVER=${PLD_ATTICDISTFILES_SERVER} fi if [ "$CVSTAG" ]; then diff --git a/rpm-build-tools.spec b/rpm-build-tools.spec index 0bb50f5..9388165 100644 --- a/rpm-build-tools.spec +++ b/rpm-build-tools.spec @@ -6,7 +6,7 @@ Summary(ru.UTF-8): Скрипты и утилиты, необходимые дл Summary(uk.UTF-8): Скрипти та утиліти, необхідні для побудови пакетів Name: rpm-build-tools Version: 4.5 -Release: 11 +Release: 12 License: GPL Group: Applications/File Group: Base -- 2.46.0