]> TLD Linux GIT Repositories - packages/rpm-build-tools.git/commitdiff
- tldized
authorMarcin Krol <hawk@tld-linux.org>
Mon, 9 Jul 2012 12:56:44 +0000 (12:56 +0000)
committerMarcin Krol <hawk@tld-linux.org>
Mon, 9 Jul 2012 12:56:44 +0000 (12:56 +0000)
builder

diff --git a/builder b/builder
index f634e610db43a24a848f2983a10728aa5252b113..1927dfd26441dfa672b113934ce1b60e53cacbe8 100755 (executable)
--- a/builder
+++ b/builder
@@ -97,7 +97,7 @@ BCOND=""
 GROUP_BCONDS="no"
 
 # create symlinks for tools in PACKAGE_DIR, see get_spec()
-SYMLINK_TOOLS="no"
+SYMLINK_TOOLS="yes"
 
 PATCHES=""
 SOURCES=""
@@ -118,8 +118,8 @@ WGET_RETRIES=${MAX_WGET_RETRIES:-0}
 CVS_FORCE=""
 CVSIGNORE_DF="yes"
 CVSTAG=""
-GIT_SERVER="git://git.pld-linux.org"
-GIT_PUSH="git@git.pld-linux.org"
+GIT_SERVER="git://git.tld-linux.org"
+GIT_PUSH="git@git.tld-linux.org"
 PACKAGES_DIR="packages"
 HEAD_DETACHED=""
 DEPTH=""
@@ -129,7 +129,7 @@ NEW_REPO=""
 
 RES_FILE=""
 
-DISTFILES_SERVER="://distfiles.pld-linux.org"
+DISTFILES_SERVER="://df.tld-linux.org"
 ATTICDISTFILES_SERVER="://attic-distfiles.pld-linux.org"
 
 DEF_NICE_LEVEL=19
@@ -943,7 +943,7 @@ find_mirror() {
        cd "$REPO_DIR"
        local url="$1"
        if [ ! -f "mirrors"  ] ; then
-               ln -s rpm-build-tools/mirrors .
+               ln -s scripts/mirrors .
        fi
 
        IFS="|"
@@ -2037,11 +2037,11 @@ init_rpm_dir() {
        mkdir -p $TOP_DIR $rpmdir $buildir $srpmdir
 
        cd "$TOP_DIR"
-       if [ ! -e ../rpm-build-tools ]; then
-               git clone  ${GIT_SERVER}/${PACKAGES_DIR}/rpm-build-tools.git ../rpm-build-tools
+       if [ ! -e ../scripts ]; then
+               git clone  ${GIT_SERVER}/${PACKAGES_DIR}/scripts.git ../scripts
        fi
        for a in adapter builder; do
-               ln -s ../rpm-build-tools/${a}.sh $a
+               ln -s ../scripts/${a}.sh $a
        done
        init_builder
 }
@@ -2365,6 +2365,16 @@ while [ $# -gt 0 ]; do
        esac
 done
 
+# Check if given package is available in TLD git
+if ! git ls-remote --heads ${GIT_SERVER}/${PACKAGES_DIR}/${ASSUMED_NAME} 1>/dev/null 2>&1; then
+  # Nope, we don't have it in TLD, switch for PLD repositories
+  GIT_SERVER="git://git.pld-linux.org"
+  GIT_PUSH="git@git.pld-linux.org"
+  PACKAGES_DIR="packages"
+  DISTFILES_SERVER="://distfiles.pld-linux.org"
+  ATTICDISTFILES_SERVER="://attic-distfiles.pld-linux.org"
+fi
+
 if [ "$CVSTAG" ]; then
        # pass $CVSTAG used by builder to rpmbuild too, so specs could use it
        RPMOPTS="$RPMOPTS --define \"_cvstag $CVSTAG\""