source: trunk/dports/sysutils/bacula5/Portfile

Last change on this file was 146517, checked in by raimue@…, 21 months ago

Mass rev-bump dependents of port openssl due to ABI change

Disabling SSLv2 in r146162 changed the ABI of the library, leading to loading
errors for binaries with references to SSLv2 symbols.

https://lists.macosforge.org/pipermail/macports-dev/2016-March/032531.html

  • Property svn:eol-style set to native
  • Property svn:keywords set to Id
File size: 6.5 KB
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: Portfile 146517 2016-03-10 17:49:28Z ryandesign@macports.org $
3
4PortSystem          1.0
5
6name                bacula5
7set realname        bacula
8version             5.2.13
9revision            2
10categories          sysutils
11platforms           darwin
12license             {AGPL-3 OpenSSLException}
13maintainers         googlemail.com:robertoschwald
14
15description         network based backup program
16long_description    Bacula is a set of computer programs that permit you to \
17                    manage backup, recovery, and verification of computer data across \
18                    a network of computers of different kinds.
19
20homepage            http://www.bacula.org/
21master_sites        sourceforge:project/bacula/bacula/${version}/
22
23checksums           rmd160  bcc168143c0eec5cb5e983f765935534379f4fcf \
24                    sha256  a4bed458bf001889bd06bf31671b5d9908055a1d1e8113fd750ae4d326607ad8
25
26distname            ${realname}-${version}
27
28depends_build       port:pkgconfig
29depends_lib         port:gawk \
30                    port:gettext \
31                    port:libiconv \
32                    port:ncurses \
33                    path:lib/libssl.dylib:openssl \
34                    port:tcp_wrappers \
35                    port:zlib
36
37configure.ccache    no
38configure.args      --mandir=${prefix}/share/man \
39                    --docdir=${prefix}/share/doc/bacula \
40                    --datarootdir=${prefix}/share \
41                    --with-pid-dir=${prefix}/var/run \
42                    --with-subsys-dir=${prefix}/var/run/subsys \
43                    --sysconfdir=${prefix}/etc/${realname} \
44                    --with-libintl-prefix=${prefix} \
45                    --with-openssl=${prefix} \
46                    --with-libiconv-prefix=${prefix} \
47                    --with-readline=${prefix} \
48                    --with-archivedir=/var/tmp \
49                    --with-working-dir=${prefix}/var/bacula/working \
50                    --with-included-gettext=${prefix} \
51                    --enable-smartalloc \
52                    --enable-largefile \
53                    --without-sqlite \
54                    --without-sqlite3 \
55                    --without-postgresql \
56                    --without-mysql \
57                    --disable-gnome \
58                    --disable-wx-console \
59                    --disable-tray-monitor \
60                    --with-tcp-wrappers
61
62configure.cppflags-append   -I${prefix}/ncurses
63configure.ldflags           ""
64
65destroot.keepdirs   ${destroot}${prefix}/var/run/subsys \
66                    ${destroot}${prefix}/var/bacula/working
67
68# Don't overwrite preference files
69post-destroot {
70    file rename ${destroot}${prefix}/etc/bacula/bacula-fd.conf ${destroot}${prefix}/etc/bacula/bacula-fd.conf.example
71    file rename ${destroot}${prefix}/etc/bacula/bconsole.conf ${destroot}${prefix}/etc/bacula/bconsole.conf.example
72    file rename ${destroot}${prefix}/etc/bacula/mtx-changer.conf ${destroot}${prefix}/etc/bacula/mtx-changer.conf.example
73}
74
75startupitem.create  yes
76startupitem.init    "BIN=${prefix}/sbin/bacula-fd\nPID=${prefix}/var/run/bacula-fd.*.pid"
77startupitem.start   "\[ -x \${BIN} \] && \${BIN} -c ${prefix}/etc/bacula/bacula-fd.conf"
78startupitem.stop    "\[ -r \${PID} \] && /bin/kill \$(cat \${PID})"
79
80variant client_only conflicts mysql55 postgresql83 postgresql84 sqlite2 sqlite3 description "Install bacula client (bacula-fd) only" {
81    configure.args-append --enable-client-only
82}
83
84variant console_bat description "Install BAT console GUI application" {
85    depends_build-append  port:tcp_wrappers \
86                          port:makeicns
87    depends_lib-append    port:qt4-mac \
88                          port:qwt52
89    configure.args-append --enable-bat
90    post-patch {
91        system "makeicns -in ${worksrcpath}/src/qt-console/images/bat_icon.png -out ${worksrcpath}/src/qt-console/images/bat_icon.icns"
92    }
93    post-destroot {
94        file rename ${destroot}${prefix}/etc/bacula/bat.conf ${destroot}${prefix}/etc/bacula/bat.conf.example
95        # for now, copy manually until upstream provider fixes bat.app install routines
96        xinstall -m 755 -d ${destroot}${applications_dir}
97        copy ${worksrcpath}/src/qt-console/bat.app ${destroot}${applications_dir}/Bacula-BAT.app
98    }
99    notes "To use the Bacula BAT GUI, you'll need to configure \"${prefix}/etc/bacula/bat.conf\"."
100}
101
102variant mysql55 conflicts client_only postgresql83 postgresql84 sqlite2 sqlite3 description "Install bacula client and server with mysql 5 backend" {
103    depends_lib-append    port:mysql55
104    configure.args-append --with-mysql=${prefix}/include/mysql55/mysql
105    configure.args-delete --without-mysql
106    configure.cppflags-append   -I${prefix}/include/mysql55/mysql
107
108    patchfiles          patch-configure-mysql.diff
109    post-patch {
110                     reinplace "s|@@PREFIX@@|${prefix}|g" ${worksrcpath}/configure
111    }
112}
113
114variant postgresql83 conflicts mysql55 postgresql84 sqlite2 sqlite3 client_only description "Install bacula client and server with postgresql 8.3 backend" {
115    depends_lib-append    port:postgresql83
116    configure.args-append --with-postgresql
117    configure.args-delete --without-postgresql
118    configure.env-append  PATH=${prefix}/lib/postgresql83/bin:$env(PATH)
119}
120
121variant postgresql84 conflicts mysql55 postgresql83 sqlite2 sqlite3 client_only description "Install bacula client and server with postgresql 8.4 backend" {
122    depends_lib-append    port:postgresql84
123    configure.args-append --with-postgresql
124    configure.args-delete --without-postgresql
125    configure.env-append  PATH=${prefix}/lib/postgresql84/bin:$env(PATH)
126}
127
128variant sqlite2 conflicts client_only sqlite3 mysql55 postgresql83 postgresql84 description "Install bacula client and server with sqlite 2 backend" {
129    depends_lib-append    port:sqlite2
130    configure.args-append --with-sqlite=${prefix}
131    configure.args-delete --without-sqlite
132}
133
134variant sqlite3 conflicts client_only sqlite2 mysql55 postgresql83 postgresql84 description "Install bacula client and server with sqlite 3 backend" {
135    depends_lib-append    port:sqlite3
136    configure.args-append --with-sqlite3=${prefix}
137    configure.args-delete --without-sqlite3
138}
139
140default_variants +console_bat
141
142if {![variant_isset mysql55] && ![variant_isset postgresql83] && ![variant_isset postgresql84] && ![variant_isset sqlite2] && ![variant_isset sqlite3]} {
143    default_variants-append +client_only
144}
145
146livecheck.type           regex
147livecheck.url            ${homepage}
148livecheck.regex          {Bacula ([0-9\.]+)}
Note: See TracBrowser for help on using the repository browser.