Changeset 29705 for main


Ignore:
Timestamp:
2015-02-03T09:59:21+13:00 (9 years ago)
Author:
Jeremy Symon
Message:

Updated rpm repo script to no longer symlink noarch packages into 32- and 64-bit repos. (see r29704 where the same was done for pacman)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • main/trunk/package-kits/linux/repos/rpm

    r29700 r29705  
    88
    99createrepo_check() {
    10     cd $repos/rpm/ || {
     10    test -d $repos/rpm/ || {
    1111        echo "Repository not found. Have you set it up?" >&2
    1212        exit 1
     
    5353        for pkg in $@; do
    5454            # Default to all architectures unless an architecture is specified
    55             arch="any"
     55            arch="x86_64 i386"
    5656            echo $pkg | grep 'x86_64\.rpm' >/dev/null 2>/dev/null && {
    5757                arch="x86_64"
     
    6161            }
    6262            name="$(basename $pkg)"
    63             echo "$name: $arch"
    64             cp $pkg $arch/
    65             # Unfortunately RPM is (as usual) sub-standard, and will not use
    66             # gpg-agent. As such, you will probably be forced to enter a pass
    67             # phrase for every single package that gets signed, regardless of
    68             # whether your GPG key even has a pass-phrase (just hit enter in
    69             # that case)
    70             echo "Signing $name..."
    71             rpmsign --key-id=$keyid --addsign $arch/$name
    72             # If arch is any, symlink package into all architectures
    73             if test "$arch" = "any"; then
    74                 for link in x86_64 i386; do
    75                     echo "$name: $link (linked)"
    76                     cd $link
    77                     ln -sf ../any/$name $name
    78                     cd ..
    79                 done
    80             fi
     63            for pkgarch in $arch; do
     64                dir="$repos/rpm/$pkgarch"
     65                cp "$pkg" "$dir/"
     66                cd "$dir"
     67                echo "$name: $arch"
     68                # Unfortunately RPM is (as usual) sub-standard, and will not use
     69                # gpg-agent. As such, you will probably be forced to enter a pass
     70                # phrase for every single package that gets signed, regardless of
     71                # whether your GPG key even has a pass-phrase (just hit enter in
     72                # that case)
     73                echo "Signing $name..."
     74                rpmsign --key-id="$keyid" --addsign "$name"
     75                cd -
     76            done
    8177        done
    8278        for arch in x86_64 i386; do
    83             cd $arch
     79            cd "$repos/rpm/$arch"
    8480            createrepo --update .
    8581            rm -f repodata/repomd.xml.asc
    86             gpg --detach-sign --armor --use-agent --default-key $keyid repodata/repomd.xml
    87             cd ..
     82            gpg --detach-sign --armor --use-agent --default-key "$keyid" repodata/repomd.xml
     83            cd -
    8884        done
    8985        ;;
Note: See TracChangeset for help on using the changeset viewer.