summaryrefslogtreecommitdiff
path: root/extra/postfix/PKGBUILD
blob: 79e1e48f012f4183b9745b26db8b8e631d45b19c (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
# do not make postfix depend on a micro-optimized Mysql (for i486)
if [ "${CARCH}" = "i486" ]; then
  makedepends=(${makedepends[@]//mariadb-libs/})
  eval "$(
    declare -f build | \
      sed '
        s|'-DHAS_MYSQL' '-I/usr/include/mysql'||g
      '
  )"

  source+=(postfix-3.5.10-no-mysql.patch)
  sha512sums+=('48598226c220caa2b58be25727f3f0d978beef5c6f42f4dfd8e97a32125739d3b15ef8328c17f9ab8b0d659c13ae6902afb5c5d2257cabe02e9f5efa8ea7d4f8')
  b2sums+=('df89a8bdf214af3253c9967749c36ae6cd48cb1fee1a38a349180599ad59b700764e83c6b19cba49866ffbe6d34d0c2f710affa240e0e89fec5256fc0ede9f0f')
  
  eval "$(
    declare -f prepare | \
      sed '
        /main_defaults.patch/a patch -p1 -i ${srcdir}/postfix-3.5.10-no-mysql.patch
      '
    declare -f package_postfix | \
      sed '
        /for _feature/s/,mysql//g
        s/LD_LIBRARY_PATH/touch lib\/postfix-mysql.so; LD_LIBRARY_PATH/
      '
    declare -f package_postfix-mysql | \
      sed '
        3 i if false; then
        $ i fi      
      '
  )
  "
fi