Ticket #44127: Portfile-7.0.4_2014-06-29.diff
File Portfile-7.0.4_2014-06-29.diff, 11.3 KB (added by robertoschwald (Robert Oschwald), 10 years ago) |
---|
-
Portfile
old new 4 4 PortSystem 1.0 5 5 6 6 name bacula 7 version 5.2.137 version 7.0.4 8 8 categories sysutils 9 9 platforms darwin 10 10 license {AGPL-3 OpenSSLException} … … 18 18 homepage http://www.bacula.org/ 19 19 master_sites sourceforge 20 20 21 checksums rmd160 bcc168143c0eec5cb5e983f765935534379f4fcf\22 sha256 a4bed458bf001889bd06bf31671b5d9908055a1d1e8113fd750ae4d326607ad821 checksums rmd160 09d033f4ea3431f57d8018647af41c1ae417652d \ 22 sha256 ebf802b843a95f6526e82dd181dff7cd7dc7d1fdc55cec8636e0fe3af69acf7e 23 23 24 24 depends_build port:pkgconfig 25 25 depends_lib port:gawk \ … … 28 28 port:ncurses \ 29 29 port:openssl \ 30 30 port:tcp_wrappers \ 31 port:zlib 31 port:zlib \ 32 port:lzo2 32 33 33 34 configure.ccache no 34 35 configure.args --mandir=${prefix}/share/man \ … … 40 41 --with-libintl-prefix=${prefix} \ 41 42 --with-openssl=${prefix} \ 42 43 --with-libiconv-prefix=${prefix} \ 43 --with-readline=${prefix} \44 44 --with-archivedir=/var/tmp \ 45 45 --with-working-dir=${prefix}/var/bacula/working \ 46 46 --with-included-gettext=${prefix} \ 47 47 --enable-smartalloc \ 48 48 --enable-largefile \ 49 -- without-sqlite\49 --enable-conio \ 50 50 --without-sqlite3 \ 51 51 --without-postgresql \ 52 52 --without-mysql \ 53 --disable-gnome \54 --disable-wx-console \55 --disable-tray-monitor \56 53 --with-tcp-wrappers 57 54 58 55 configure.cppflags-append -I${prefix}/ncurses … … 73 70 startupitem.start "\[ -x \${BIN} \] && \${BIN} -c ${prefix}/etc/bacula/bacula-fd.conf" 74 71 startupitem.stop "\[ -r \${PID} \] && /bin/kill \$(cat \${PID})" 75 72 76 variant client_only conflicts mysql55 postgresql83 postgresql84 sqlite2 sqlite3 description "Install bacula client (bacula-fd) only" { 73 notes "*******************************************************************************************************************" 74 notes-append "To use the Bacula FD client, you'll need to configure \"${prefix}/etc/bacula/bacula-fd.conf\"." 75 notes-append "To use bconsole, you'll need to configure \"${prefix}/etc/bacula/bconsole.conf\"." 76 77 variant client_only conflicts mysql51 mysql55 postgresql83 postgresql84 sqlite3 description "Install bacula client (bacula-fd) only" { 77 78 configure.args-append --enable-client-only 78 79 } 79 80 … … 92 93 xinstall -m 755 -d ${destroot}${applications_dir} 93 94 copy ${worksrcpath}/src/qt-console/bat.app ${destroot}${applications_dir}/Bacula-BAT.app 94 95 } 95 notes "To use the Bacula BAT GUI, you'll need to configure \"${prefix}/etc/bacula/bat.conf\"."96 notes-append "To use the Bacula BAT GUI, you'll need to configure \"${prefix}/etc/bacula/bat.conf\"." 96 97 } 97 98 98 variant mysql55 conflicts client_only postgresql83 postgresql84 sqlite2 sqlite3 description "Install bacula client and server with mysql 5 backend" { 99 variant mysql51 conflicts client_only mysql55 postgresql83 postgresql84 sqlite3 description "Install bacula client and server with mysql 5.1 backend" { 100 depends_lib-append port:mysql51 101 configure.args-append --with-mysql=${prefix}/include/mysql51/mysql 102 configure.args-delete --without-mysql 103 configure.args-append --enable-batch-insert 104 configure.cppflags-append -I${prefix}/include/mysql51/mysql 105 106 patchfiles patch-configure-mysql.diff 107 post-patch { 108 reinplace "s|@@PREFIX@@|${prefix}|g" ${worksrcpath}/configure 109 } 110 notes-append " 111 To use the Bacula Director, you'll need to perform the following steps: 112 1. create user \"bacula\" on a mysql database 113 2. execute \"${prefix}/etc/bacula/create_bacula_database -h <mysql_server> -u <db_admin_user> -p\" 114 3. execute \"${prefix}/etc/bacula/make_bacula_tables -h <mysql_server> -u <db_admin_user> -p\" 115 4. execute \"${prefix}/etc/bacula/grant_bacula_privileges -h <mysql_server> -u <db_admin_user> -p\" 116 5. configure \"${prefix}/etc/bacula/bacula-dir.conf\" and set the catalog database settings for the bacula db user. 117 " 118 } 119 120 variant mysql55 conflicts client_only mysql51 postgresql83 postgresql84 sqlite3 description "Install bacula client and server with mysql 5.5 backend" { 99 121 depends_lib-append port:mysql55 100 122 configure.args-append --with-mysql=${prefix}/include/mysql55/mysql 101 123 configure.args-delete --without-mysql 124 configure.args-append --enable-batch-insert 102 125 configure.cppflags-append -I${prefix}/include/mysql55/mysql 103 126 104 127 patchfiles patch-configure-mysql.diff 105 128 post-patch { 106 129 reinplace "s|@@PREFIX@@|${prefix}|g" ${worksrcpath}/configure 107 130 } 131 notes-append " 132 To use the Bacula Director, you'll need to perform the following steps: 133 1. create user \"bacula\" on a mysql database 134 2. execute \"${prefix}/etc/bacula/create_bacula_database -h <mysql_server> -u <db_admin_user> -p\" 135 3. execute \"${prefix}/etc/bacula/make_bacula_tables -h <mysql_server> -u <db_admin_user> -p\" 136 4. execute \"${prefix}/etc/bacula/grant_bacula_privileges -h <mysql_server> -u <db_admin_user> -p\" 137 5. configure \"${prefix}/etc/bacula/bacula-dir.conf\" and set the catalog database settings for the bacula db user. 138 " 108 139 } 109 140 110 variant postgresql83 conflicts mysql5 5 postgresql84 sqlite2sqlite3 client_only description "Install bacula client and server with postgresql 8.3 backend" {141 variant postgresql83 conflicts mysql51 mysql55 postgresql84 sqlite3 client_only description "Install bacula client and server with postgresql 8.3 backend" { 111 142 depends_lib-append port:postgresql83 112 143 configure.args-append --with-postgresql 113 144 configure.args-delete --without-postgresql 145 configure.args-append --enable-batch-insert 114 146 configure.env-append PATH=${prefix}/lib/postgresql83/bin:$env(PATH) 147 148 patchfiles patch-create_postgresql_database.diff 149 150 notes-append " 151 To use the Bacula Director, you'll need to perform the following steps: 152 1. create user \"bacula\" on a PostgreSQL database 153 2. execute \"${prefix}/etc/bacula/create_bacula_database -h <postgresql-server> -U <db_admin_user>\" 154 3. execute \"${prefix}/etc/bacula/make_bacula_tables -h <postgresql-server> -U <db_admin_user>\" 155 4. execute \"${prefix}/etc/bacula/grant_bacula_privileges -h <postgresql-server> -U <db_admin_user> -p\" 156 5. configure \"${prefix}/etc/bacula/bacula-dir.conf\" and set the catalog database settings for the bacula db user. 157 " 115 158 } 116 159 117 variant postgresql84 conflicts mysql5 5 postgresql83 sqlite2sqlite3 client_only description "Install bacula client and server with postgresql 8.4 backend" {160 variant postgresql84 conflicts mysql51 mysql55 postgresql83 sqlite3 client_only description "Install bacula client and server with postgresql 8.4 backend" { 118 161 depends_lib-append port:postgresql84 119 162 configure.args-append --with-postgresql 120 163 configure.args-delete --without-postgresql 164 configure.args-append --enable-batch-insert 121 165 configure.env-append PATH=${prefix}/lib/postgresql84/bin:$env(PATH) 122 }123 166 124 variant sqlite2 conflicts client_only sqlite3 mysql55 postgresql83 postgresql84 description "Install bacula client and server with sqlite 2 backend" { 125 depends_lib-append port:sqlite2 126 configure.args-append --with-sqlite=${prefix} 127 configure.args-delete --without-sqlite 167 patchfiles patch-create_postgresql_database.diff 168 169 notes-append " 170 To use the Bacula Director, you'll need to perform the following steps: 171 1. create user \"bacula\" on a PostgreSQL database 172 2. execute \"${prefix}/etc/bacula/create_bacula_database -h <postgresql-server> -U <db_admin_user>\" 173 3. execute \"${prefix}/etc/bacula/make_bacula_tables -h <postgresql-server> -U <db_admin_user>\" 174 4. execute \"${prefix}/etc/bacula/grant_bacula_privileges -h <postgresql-server> -U <db_admin_user> -p\" 175 5. configure \"${prefix}/etc/bacula/bacula-dir.conf\" and set the catalog database settings for the bacula db user. 176 " 128 177 } 129 178 130 variant sqlite3 conflicts client_only sqlite2mysql55 postgresql83 postgresql84 description "Install bacula client and server with sqlite 3 backend" {179 variant sqlite3 conflicts client_only mysql51 mysql55 postgresql83 postgresql84 description "Install bacula client and server with sqlite 3 backend" { 131 180 depends_lib-append port:sqlite3 132 181 configure.args-append --with-sqlite3=${prefix} 133 182 configure.args-delete --without-sqlite3 183 configure.args-append --enable-batch-insert 184 notes-append " 185 To use the Bacula Director, you'll need to perform the following steps: 186 1. execute \"${prefix}/etc/bacula/create_bacula_database\" 187 2. execute \"${prefix}/etc/bacula/make_bacula_tables\" 188 3. configure \"${prefix}/etc/bacula/bacula-dir.conf\" and set the catalog database settings for the bacula db user. 189 " 134 190 } 135 191 136 192 default_variants +console_bat 137 193 138 if {![variant_isset mysql5 5] && ![variant_isset postgresql83] && ![variant_isset postgresql84] && ![variant_isset sqlite2] && ![variant_isset sqlite3]} {194 if {![variant_isset mysql51] && ![variant_isset mysql55] && ![variant_isset postgresql83] && ![variant_isset postgresql84] && ![variant_isset sqlite3]} { 139 195 default_variants-append +client_only 196 } else { 197 # is a server installation 198 199 # Add the server daemons to the startupitem wrapper 200 startupitem.init-append "BIN_DIR=${prefix}/sbin/bacula-dir\nPID_DIR=${prefix}/var/run/bacula-dir.*.pid\n" 201 startupitem.init-append "BIN_SD=${prefix}/sbin/bacula-sd\nPID_SD=${prefix}/var/run/bacula-sd.*.pid\n" 202 startupitem.start-append "\[ -x \${BIN_DIR} -a -f ${prefix}/etc/bacula/bacula-dir.conf \] && \${BIN_DIR} -c ${prefix}/etc/bacula/bacula-dir.conf" 203 startupitem.start-append "\[ -x \${BIN_SD} -a -f ${prefix}/etc/bacula/bacula-sd.conf \] && \${BIN_SD} -c ${prefix}/etc/bacula/bacula-sd.conf" 204 startupitem.stop-append "\[ -r \${PID_DIR} \] && /bin/kill \$(cat \${PID_DIR})" 205 startupitem.stop-append "\[ -r \${PID_SD} \] && /bin/kill \$(cat \${PID_SD})" 206 207 # Don't overwrite existing preference files 208 post-destroot { 209 file rename ${destroot}${prefix}/etc/bacula/bacula-dir.conf ${destroot}${prefix}/etc/bacula/bacula-dir.conf.example 210 file rename ${destroot}${prefix}/etc/bacula/bacula-sd.conf ${destroot}${prefix}/etc/bacula/bacula-sd.conf.example 211 } 212 notes-append "To use the Bacula Storage Daemon, you'll need to configure \"${prefix}/etc/bacula/bacula-sd.conf\"." 213 } 214 215 pre-activate { 216 notes-append "*******************************************************************************************************************" 217 } 218 219 pre-deactivate { 220 if {[file exists /Library/LaunchDaemons/org.macports.bacula.plist]} { 221 system "launchctl unload /Library/LaunchDaemons/org.macports.bacula.plist" 222 } 140 223 } 141 224 142 225 livecheck.type regex