# $Id: Portfile 72899 2010-10-29 22:20:44Z jmr@macports.org $ PortSystem 1.0 name commons-daemon version 1.0.2 license Apache-2.0 categories java maintainers nomaintainer platforms darwin description Jakarta Commons-Daemon long_description An alternative invocation mechanism for unix-daemon-like \ java code. homepage http://commons.apache.org/daemon/ distname ${name}-${version}-src master_sites apache:commons/daemon/source/ checksums md5 a6c68eed204bc9f1ef3b77488edfcfeb \ sha1 a4e7e267c6accfeae5226f3a64ad2d7bd19993d1 \ rmd160 afad8e7608f342ea576efde374511e50d269ae84 patchfiles patch-native-dso-dyld.c depends_build bin:ant:apache-ant depends_lib bin:java:kaffe \ port:junit configure.dir ${worksrcpath}/src/native/unix platform macosx { pre-configure { if {![file exists "/System/Library/Frameworks/JavaVM.framework/Headers/jni.h"]} { ui_error "${name} requires the Java for Mac OS X development headers." if {${os.major} == 10} { ui_error "Download the Java Developer Package from: " } elseif {${os.major} == 9} { ui_error "Download the Java Developer Package from: " } else { ui_error "Make sure your Xcode installation is complete." } return -code error "missing Java headers" } } } build.dir ${configure.dir} build.target clean all use_parallel_build no pre-build { system "cd ${worksrcpath} && \ ant dist -Djunit.jar=${prefix}/share/java/junit.jar" } destroot { xinstall -d ${destroot}${prefix}/share/java \ ${destroot}${prefix}/share/doc xinstall -m 644 ${worksrcpath}/dist/commons-daemon-${version}.jar \ ${destroot}${prefix}/share/java/commons-daemon.jar xinstall ${worksrcpath}/src/native/unix/jsvc \ ${destroot}${prefix}/bin set docdir ${prefix}/share/doc/${name} file copy ${worksrcpath}/dist/docs ${destroot}${docdir} xinstall -m 644 -W ${worksrcpath} LICENSE.txt NOTICE.txt PROPOSAL.html \ RELEASE-NOTES.txt ${destroot}${docdir} } livecheck.type regex livecheck.url http://commons.apache.org/downloads/download_daemon.cgi livecheck.regex {>(\d+(?:\.\d+)*)\.tar}