Send patches - preferably formatted by git format-patch - to patches at archlinux32 dot org.
summaryrefslogtreecommitdiff
path: root/extra/mesa/PKGBUILD
blob: b99acf241d008ae91c08528de676ffc4b67299de (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
49
50
51
52
53
54
55
# defaults changed to SSE2 enabled by default, disable it
if [ "$CARCH" = 'i686' -o "$CARCH" = 'i486' ]; then
  eval "$(
  declare -f build | \
  sed '
    s/arch-meson /arch-meson -Dsse2=false /
  '
  )"
fi

# no LTO on i486
if [ "$CARCH" = 'i486' ]; then
  sed -i '
    1i options=(!lto)
  ' PKGBUILD
fi
if [ "$CARCH" == 'i486' ]; then
  eval "$(
    declare -f build | \
      sed '
        s/-D b_lto=true/-D b_lto=false/
      '
  )"
fi

# See https://bugs.freedesktop.org/show_bug.cgi?id=93089
# do not build/package vulkan on i486
# do not build i915,i965 on i486
if [ "$CARCH" = 'i486' ]; then
  eval "$(
    declare -f build | \
      sed '
        s/\(-D vulkan-drivers=\)\S\+ /\1 /
      '
    declare -f package_mesa | \
      sed '
        \,rm .*/vulkan;,d
      '
    declare -f package_vulkan-intel | \
      sed '
        3 i if false; then
        $ i fi      
      '
    declare -f package_vulkan-radeon | \
      sed '
        3 i if false; then
        $ i fi      
      '
    declare -f package_vulkan-swrast | \
      sed '
        3 i if false; then
        $ i fi      
      '
  )"
fi