| 1 | # $Id: Portfile 57375 2009-09-10 08:16:41Z ryandesign@macports.org $ |
|---|
| 2 | |
|---|
| 3 | PortSystem 1.0 |
|---|
| 4 | |
|---|
| 5 | name ejabberd |
|---|
| 6 | version 2.0.5 |
|---|
| 7 | revision 1 |
|---|
| 8 | categories net |
|---|
| 9 | platforms darwin |
|---|
| 10 | maintainers simon openmaintainer |
|---|
| 11 | description ejabberd is an XMPP application server. |
|---|
| 12 | long_description ${description} ejabberd stands for "Erlang Jabber Daemon" |
|---|
| 13 | |
|---|
| 14 | homepage http://www.process-one.net/en/ejabberd/ |
|---|
| 15 | master_sites http://www.process-one.net/downloads/ejabberd/${version}/ |
|---|
| 16 | checksums md5 2d85b47df969daf0a78ed3b16562d731 \ |
|---|
| 17 | sha1 e5b8c4b742fdcc439da9458f94f530604abdfdd5 \ |
|---|
| 18 | rmd160 5ec0210b3995004c708180a66a096e0b9be5f1ba |
|---|
| 19 | worksrcdir ${worksrcdir}/src |
|---|
| 20 | |
|---|
| 21 | depends_lib port:erlang \ |
|---|
| 22 | port:expat \ |
|---|
| 23 | port:openssl \ |
|---|
| 24 | port:libiconv \ |
|---|
| 25 | port:zlib |
|---|
| 26 | |
|---|
| 27 | configure.args --with-expat=${prefix} \ |
|---|
| 28 | --with-zlib=${prefix} \ |
|---|
| 29 | --with-openssl=${prefix} |
|---|
| 30 | |
|---|
| 31 | # All ejabberd configuration files. |
|---|
| 32 | set conf_files {ejabberd.cfg ejabberdctl.cfg inetrc} |
|---|
| 33 | |
|---|
| 34 | destroot.keepdirs ${destroot}${prefix}/var/log/ejabberd/ |
|---|
| 35 | |
|---|
| 36 | patchfiles-append dynamic_compile_loglevel.patch |
|---|
| 37 | |
|---|
| 38 | post-destroot { |
|---|
| 39 | # Create sample configuration files so they don't get overwritten by an |
|---|
| 40 | # update. |
|---|
| 41 | set etc ${destroot}${prefix}/etc/ejabberd |
|---|
| 42 | foreach file ${conf_files} { |
|---|
| 43 | file rename ${etc}/${file} ${etc}/${file}.sample |
|---|
| 44 | } |
|---|
| 45 | |
|---|
| 46 | # Install documentation. |
|---|
| 47 | set doc ${destroot}${prefix}/share/doc |
|---|
| 48 | xinstall -d ${doc} |
|---|
| 49 | file copy ${worksrcpath}/../doc ${doc}/${name}-${version} |
|---|
| 50 | } |
|---|
| 51 | |
|---|
| 52 | post-install { |
|---|
| 53 | ui_msg "****************************************************************" |
|---|
| 54 | ui_msg "* *" |
|---|
| 55 | ui_msg "* If you run ejabberd for the first time, then you must rename *" |
|---|
| 56 | ui_msg "* the following configuration files by removing the .sample *" |
|---|
| 57 | ui_msg "* extension: *" |
|---|
| 58 | ui_msg "* *" |
|---|
| 59 | ui_msg "* cd ${prefix}/etc/ejabberd/ *" |
|---|
| 60 | foreach file ${conf_files} { |
|---|
| 61 | ui_msg "* mv ${file}.sample ${file}" |
|---|
| 62 | } |
|---|
| 63 | ui_msg "* *" |
|---|
| 64 | ui_msg "****************************************************************" |
|---|
| 65 | } |
|---|
| 66 | |
|---|
| 67 | livecheck.type regex |
|---|
| 68 | livecheck.url ${homepage}release_notes |
|---|
| 69 | livecheck.regex "${name} (\\d+(?:\\.\\d+)*)" |
|---|