Ticket #47671: exim-portfile.patch

File exim-portfile.patch, 4.7 KB (added by pokui@…, 9 years ago)

patch to Portfile

  • Portfile

    old new  
    44PortSystem              1.0
    55
    66name                    exim
    7 version                 4.82.1
    8 revision                1
    9 checksums               rmd160  2caa80ed8b5fef07fd0449dc5ac7958681466a2d \
    10                         sha256  51798cead70b9ca03df88afb63f7a0cabedee8ef82c02bd18d67591c08b14500
     7version                 4.85
     8revision                0
     9checksums               rmd160  334e5eeb9242b3fff49bd581b8cb22c12c0e8215 \
     10                        sha256  13211f2bbc5400d095a9b4be075eb1347e0d98676fdfe4be8a3b4d56281daaa4
    1111
    1212categories              mail
    1313license                 GPL-2
     
    4242
    4343set exim_user           exim
    4444
     45add_users ${exim_user} group=mail realname=Exim
     46
    4547use_parallel_build      no
    4648
    4749universal_variant       no
     
    6971    reinplace "s|# Exim: OS-specific make file for Darwin (Mac OS X).|INCLUDE=-I${prefix}/include/db44|g" ${worksrcpath}/OS/Makefile-Darwin
    7072    reinplace "s|DBMLIB =|DBMLIB=${prefix}/lib/db44/libdb-4.dylib|g" ${worksrcpath}/OS/Makefile-Darwin
    7173    reinplace "s|/etc/aliases|${destroot}${prefix}/etc/aliases|g" ${worksrcpath}/scripts/exim_install
    72     adduser ${exim_user} gid=[existsgroup mail]
    7374}
    7475
    7576build.args              FULLECHO=
     
    9091    reinplace "s|__PREFIX|${prefix}|g" ${destroot}${prefix}/share/exim/exim.sh
    9192}
    9293
    93 variant mysql4 conflicts mysql5 description {build exim with support for mysql4 lookups} {
     94variant mysql4 conflicts mysql5 mysql51 mysql56 mariadb description {build exim with support for mysql4 lookups} {
    9495    depends_lib-append  port:mysql4
    9596}
    9697
    97 variant mysql5 conflicts mysql4 description {build exim with support for mysql5 lookups} {
    98     depends_lib-append  path:bin/mysql_config5:mysql5
     98variant mysql5 conflicts mysql4 mysql56 mariadb requires mysql51 description {Legacy compatibility variant} {
     99    # stub do nothing
     100}
     101
     102variant mysql51 conflicts mysql4 description {build exim with support for mysql51 lookups} {
     103    depends_lib-append      port:mysql51
     104}
     105
     106variant mysql56 conflicts mysql4 mysql5 mysql51 mariadb description {build with with support for mysql56 lookups} {
     107    depends_lib-append      port:mysql56
     108}
     109
     110variant mariadb conflicts mysql4 mysql5 mysql51 mysql56 description {build with mariadb port for mysql lookups} {
     111    depends_lib-append      port:mariadb
    99112}
    100113
    101114variant ldap conflicts macports_ldap description {build exim with support for ldap lookups using the shipped ldap} {
     
    117130    # settings common to any lookup
    118131    if {[variant_isset mysql4]
    119132        ||  [variant_isset mysql5]
     133        ||  [variant_isset mysql51]
     134        ||  [variant_isset mysql56]
     135        ||  [variant_isset mariadb]
    120136        ||  [variant_isset ldap]
    121137        ||  [variant_isset macports_ldap]
    122138    } then {
     
    128144            reinplace "s|^LOOKUP_LIBS=.*|& -L${prefix}/lib/mysql -lmysqlclient|g" ${worksrcpath}/Local/Makefile
    129145            reinplace "s|^LOOKUP_INCLUDE=.*|& -I${prefix}/include/mysql -I ${prefix}/include|g" ${worksrcpath}/Local/Makefile
    130146        }
    131         if {[variant_isset mysql5]} {
     147        if {[variant_isset mysql5] || [variant_isset mysql51]} {
     148            reinplace "s|^# LOOKUP_MYSQL=yes|LOOKUP_MYSQL=yes|g" ${worksrcpath}/Local/Makefile
     149            reinplace "s|^LOOKUP_LIBS=.*|& -L${prefix}/lib/mysql51/mysql -lmysqlclient |g" ${worksrcpath}/Local/Makefile
     150            reinplace "s|^LOOKUP_INCLUDE=.*|& -I${prefix}/include/mysql51/mysql |g"  ${worksrcpath}/Local/Makefile
     151        }
     152        if {[variant_isset mysql56]} {
     153            reinplace "s|^# LOOKUP_MYSQL=yes|LOOKUP_MYSQL=yes|g" ${worksrcpath}/Local/Makefile
     154            reinplace "s|^LOOKUP_LIBS=.*|& -L${prefix}/lib/mysql56/mysql -lmysqlclient |g" ${worksrcpath}/Local/Makefile
     155            reinplace "s|^LOOKUP_INCLUDE=.*|& -I${prefix}/include/mysql56/mysql |g"  ${worksrcpath}/Local/Makefile
     156        }
     157        if {[variant_isset mariadb]} {
    132158            reinplace "s|^# LOOKUP_MYSQL=yes|LOOKUP_MYSQL=yes|g" ${worksrcpath}/Local/Makefile
    133             reinplace "s|^LOOKUP_LIBS=.*|& -L${prefix}/lib/mysql5/mysql -lmysqlclient |g" ${worksrcpath}/Local/Makefile
    134             reinplace "s|^LOOKUP_INCLUDE=.*|& -I${prefix}/include/mysql5/mysql |g"  ${worksrcpath}/Local/Makefile
     159            reinplace "s|^LOOKUP_LIBS=.*|& -L${prefix}/lib/mariadb/mysql -lmysqlclient |g" ${worksrcpath}/Local/Makefile
     160            reinplace "s|^LOOKUP_INCLUDE=.*|& -I${prefix}/include/mariadb/mysql |g"  ${worksrcpath}/Local/Makefile
    135161        }
    136162        if {[variant_isset ldap]} {
    137163            reinplace "s|^# LOOKUP_LDAP=yes|LOOKUP_LDAP=yes|g"  ${worksrcpath}/Local/Makefile