summaryrefslogtreecommitdiff
path: root/core/pacman/PKGBUILD
blob: ae268502124898281cc2171cdb3e2bdcae3eb9c4 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
# upstream git revision: 2519f7ad3a9ad47ee6bb997d53a2266ca34fdd52

depends+=(archlinux32-keyring)

# fail if upstream changes makepkg.conf or pacman.conf
for ((i=0; i<${#sha256sums[@]}; i++)); do
  if [ "${sha256sums[${i}]}" = 'b82e9c1073292766c2f49b5c771dddf37383f1151117ef9cd5e0c11047b4f3eb' ]; then
    sha256sums[${i}]='d75bbbe42d290c4f22a95e6ac86d4723dc6d0c08228d14c3dcbae9dc5d2514e5'
  fi
  if [ "${sha256sums[${i}]}" = '8442bbb3d1d83f09610e9d687f9121037d97c6acaa06c4e907fc6e9eb0b127ec' ]; then
    sha256sums[${i}]='730b6d399dc03ea0ea505fde9387b3fd14475a0e5421e53be30b6b2f946b974f'
  fi
done

if [ ! "${CARCH}" = "i686" ]; then
  # patch architecture where needed
  eval "$(
    declare -f package | \
      sed '
        /install.*makepkg.conf/ a \
          sed -i "s@i686@'"${CARCH}"'@g" "$pkgdir/etc/makepkg.conf"
      '
  )"
fi

# patches for the "i686" -> "pentium4" mangling if "Architecture = auto"
# see auto-pentium4 branch in git.archlinux32.org:archlinux32/pacman.git
source+=('pentium4-auto-config.patch'
         'pentium4-tests.patch')
sha256sums+=('266276a16aac85a9ee4745968a7bcac833505afa2896b60301997bbe2863fabd'
             '8e3d1b2dff0cfd7db462bae0d1def5bb83d169128117e2b6ea72d489ab7b0077')

prepare() {
  cd "$pkgname-$pkgver"
  patch -p1 -i ../pentium4-auto-config.patch
  patch -p1 -i ../pentium4-tests.patch
}