PortSystem 1.0
name                    jgoodies-forms
version                 1.6.0
categories              java
platforms               darwin
maintainers             nomaintainer

description             Framework to lay out and implement Swing panels.
long_description        The JGoodies Forms framework helps you lay out and \
                        implement elegant Swing panels quickly and \
                        consistently.  It makes simple things easy and the \
                        hard stuff possible, the good design easy and the \
                        bad difficult.
homepage                http://www.jgoodies.com/freeware/forms/

master_sites            http://www.jgoodies.com/download/libraries/forms/
distname                ${name}-1_6_0
checksums               sha1 a78396323a1866d5eeb48bcf3b22a3d8696a8f30 \
                        sha256 5d38b462de4cee37d00a3fa656247bb530dc9c2d83068827e0c1d258933a1b29
use_zip                 yes

depends_lib             bin:java:kaffe \
                        port:jgoodies-common

use_configure           no

worksrcdir              ${name}-${version}

if {${os.platform} eq "darwin" && ${os.major} < 10} {
    known_fail          yes
    pre-fetch {
        ui_error "${name} ${version} requires OS X 10.6 or greater for Java 6."
        return -code error "incompatible OS X version"
    }
}

build {}

destroot {
        set javadir ${destroot}${prefix}/share/java
        set docdir ${destroot}${prefix}/share/doc/${name}

        xinstall -d -m 755 ${javadir}
        xinstall -d -m 755 ${docdir}

        file copy ${worksrcpath}/${name}-${version}.jar ${javadir}/${name}.jar
        foreach f {LICENSE.txt README.html RELEASE-NOTES.txt docs} {
                file copy ${worksrcpath}/${f} ${docdir}/
        }
}