summaryrefslogtreecommitdiff
path: root/core/gcc/PKGBUILD
blob: 86d70aae9185aea7d418da437b27985312dee25e (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
38
39
40
41
42
43
44
45
46
47
48
# remove tsan (thread sanitizer) plugin, not available for i686
pkgname=(
  $(
    printf '%s\n' "${pkgname[@]}" | \
      grep -vFx 'lib32-gcc-libs'
  )
)
unset -f 'package_lib32-gcc-libs'
eval "$(
  declare -f prepare | \
    sed '
      \,/s/lib64/lib/, d
    '
  declare -f build | \
    sed '
      s/--enable-multilib/--disable-multilib/
    '
  declare -f package_gcc-libs | \
    sed '
      s/\$pkgname-multilib//
      s@libsanitizer/{a,l,ub,t}san@libsanitizer/{a,l,ub}san@
      /provides=/s/libtsan.so//
      \@/usr/lib32/@ d
    '
  declare -f package_gcc | \
    sed '
      s/"lib32-gcc-libs[^"]*"//g
      s@make.*tsan.*install@#\0@
    '
  declare -f package_gcc-ada | \
    sed '
      \,cd .*/32/libada,{
        N
        d
      }
    '
)"
eval "$(
  for name in "${pkgname[@]}"; do
    declare -f package_${name} | \
      sed '
        s/$pkgname-multilib//
        s/{,32}//
        \,/lib32/,d
        \,/32/,d
      '
  done
)"