Ticket #44835: Portfile

File Portfile, 5.7 KB (added by jul_bsd@…, 10 years ago)
Line 
1# -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:ft=tcl:et:sw=4:ts=4:sts=4
2# $Id$
3
4PortSystem          1.0
5
6PortGroup           github 1.0
7
8github.setup        firnsy barnyard2 1.13 v2-
9categories          net security
10platforms           darwin
11maintainers         yahoo.fr:jul_bsd openmaintainer
12license             GPL-2
13description         dedicated spooler for Snort's unified2 binary output format
14long_description    ${description}
15
16#depends_lib         port:libpcap
17#patchfiles          patch-Makefile.diff
18
19use_autoconf         yes
20autoconf.cmd         ./autogen.sh
21depends_build        port:automake port:autoconf port:libtool
22#pre-configure {
23#    system -W ${worksrcpath} "./autogen.sh"
24#}
25
26configure.args       --enable-ipv6 --without-mysql --disable-prelude
27
28variant universal {}
29build.args          CC=${configure.cc}
30configure.cflags-append "${configure.cflags} [get_canonical_archflags cc]"
31
32## FIXME! build: error: expected parameter declarator strlcat
33patchfiles          patch-src-strlcpyu.h.diff patch-src-strlcatu.h.diff
34
35#destroot.env        PREFIX=${prefix}
36#post-destroot {
37#    xinstall -m 644 ${worksrcpath}/doc/masscan.8 ${destroot}${prefix}/share/man/man8/
38#}
39
40#use_configure       no
41
42#test.run            yes
43#test.target         regress
44
45if {${subport} eq ${name}} {
46
47    ## github group configuration does not seem to be effective
48    distname            v2-${version}
49    worksrcdir          ${name}-2-${version}
50    master_sites        https://github.com/firnsy/barnyard2/archive/
51    checksums           rmd160  d77c60fbd4884f8e9dae772a6190c778b619e693 \
52                        sha256  b9e67f22334b937a59cf808ca20bdcd9c46561a4369979c965a0bb554d7dd09b
53
54}
55
56subport ${name}-devel {
57    version    20140525
58    fetch.type git
59#    git.url    https://github.com/firnsy/barnyard2.git
60    git.branch 272eaf7cb9fe7dfa2faf1df22d8cb02233ad512d
61}
62
63variant prelude description "use prelude" {
64    depends_lib-append          port:libprelude
65    configure.args-delete       --disable-prelude
66    configure.args-append       --enable-prelude --with-libprelude-prefix=${prefix}
67}
68
69if {![variant_isset mysql51] && ![variant_isset mysql55] && ![variant_isset mariadb] && ![variant_isset mariadb10] && ![variant_isset mariadb101] && ![variant_isset percona]} {
70    default_variants +mysql56
71}
72
73variant mysql51 \
74    conflicts mysql55 mysql56 mariadb mariadb10 mariadb101 percona \
75    description "Enable MySQL 5.1 support" {
76
77    depends_lib-append          port:mysql51
78    configure.args-delete       --without-mysql
79    configure.args-append       --with-mysql --enable-mysql-ssl-support \
80        --with-mysql-includes=${prefix}/include/mysql51/mysql \
81        --with-mysql-libraries=${prefix}/lib/mysql51/mysql
82}
83
84variant mysql55 \
85    conflicts mysql51 mysql56 mariadb mariadb10 mariadb101 percona \
86    description "Enable MySQL 5.5 support" {
87
88    depends_lib-append          port:mysql55
89    configure.args-delete       --without-mysql
90    configure.args-append       --with-mysql=${prefix}/include/mysql55/mysql
91    configure.args-append       --with-mysql --enable-mysql-ssl-support \
92        --with-mysql-includes=${prefix}/include/mysql55/mysql \
93        --with-mysql-libraries=${prefix}/lib/mysql55/mysql
94}
95
96variant mysql56 \
97    conflicts mysql51 mysql55 mariadb mariadb10 mariadb101 percona \
98    description "Enable MySQL 5.6 support" {
99
100    depends_lib-append          port:mysql56
101    configure.args-delete       --without-mysql
102    configure.args-append       --with-mysql=${prefix}/include/mysql56/mysql
103    configure.args-append       --with-mysql --enable-mysql-ssl-support \
104        --with-mysql-includes=${prefix}/include/mysql56/mysql \
105        --with-mysql-libraries=${prefix}/lib/mysql56/mysql
106}
107
108variant mariadb \
109    conflicts mysql51 mysql55 mysql56 mariadb10 mariadb101 percona \
110    description "Enable mariadb 5 (MySQL) support" {
111
112    depends_lib-append          port:mariadb
113    configure.args-delete       --without-mysql
114    configure.args-append       --with-mysql=${prefix}/include/mariadb/mysql
115    configure.args-append       --with-mysql --enable-mysql-ssl-support \
116        --with-mysql-includes=${prefix}/include/mariadb/mysql \
117        --with-mysql-libraries=${prefix}/lib/mariadb/mysql
118}
119
120variant mariadb10 \
121    conflicts mysql51 mysql55 mysql56 mariadb mariadb101 percona \
122    description "Enable mariadb 10 (MySQL) support" {
123
124    depends_lib-append          port:mariadb
125    configure.args-delete       --without-mysql
126    configure.args-append       --with-mysql=${prefix}/include/mariadb/mysql
127    configure.args-append       --with-mysql --enable-mysql-ssl-support \
128        --with-mysql-includes=${prefix}/include/mariadb/mysql \
129        --with-mysql-libraries=${prefix}/lib/mariadb/mysql
130}
131
132variant mariadb101 \
133    conflicts mysql51 mysql55 mysql56 mariadb mariadb10 percona \
134    description "Enable mariadb 10.1 (MySQL) support" {
135
136    depends_lib-append          port:mariadb
137    configure.args-delete       --without-mysql
138    configure.args-append       --with-mysql=${prefix}/include/mariadb/mysql
139    configure.args-append       --with-mysql --enable-mysql-ssl-support \
140        --with-mysql-includes=${prefix}/include/mariadb/mysql \
141        --with-mysql-libraries=${prefix}/lib/mariadb/mysql
142}
143
144variant percona \
145    conflicts mysql51 mysql55 mysql56 mariadb mariadb10 mariadb101 \
146    description "Enable Percona (MySQL) support" {
147        depends_lib-append          port:percona
148    configure.args-delete       --without-mysql
149    configure.args-append       --with-mysql --enable-mysql-ssl-support \
150        --with-mysql-includes=${prefix}/include/percona/mysql \
151        --with-mysql-libraries=${prefix}/lib/percona/mysql
152}
153
154livecheck.regex     "<span class=\"tag-name\">v2-(.*)</span>"