source: trunk/dports/lang/jruby-devel/Portfile

Last change on this file was 98608, checked in by ciserlohn@…, 5 years ago

jruby-devel: update to version 1.7.0.RC2

  • remove patches for darwin 12 - issue has been fixed upstream
  • Property svn:eol-style set to native
  • Property svn:keywords set to Id
File size: 3.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 98608 2012-10-09 19:47:13Z ryandesign@macports.org $
3
4PortSystem          1.0
5
6name                jruby-devel
7version             1.7.0.RC2
8epoch               1
9                   
10categories          lang ruby
11maintainers         ciserlohn
12platforms           darwin
13                   
14description         JRuby is an 100% pure-Java implementation of the Ruby \
15                    programming language.
16                    long_description  JRuby provides a complete set of core "builtin" classes \
17                    and syntax for the Ruby language, as well as most of the \
18                    Ruby Standard Libraries. The standard libraries are mostly \
19                    Ruby's own complement of .rb files, but a few that depend \
20                    on C language-based extensions have been reimplemented.
21
22conflicts           jruby
23                   
24homepage            http://jruby.org/
25                   
26master_sites        http://jruby.org.s3.amazonaws.com/downloads/${version}/
27distname            jruby-src-${version}
28worksrcdir          jruby-${version}
29                   
30checksums           rmd160  884b17ef595159c2e4c84cb355b0ec61f215ee6a \
31                    sha256  b6d35ff087843f4c835b49897c7e1cc8f76fb8f0e45b38b408fe9d1eb337edf7
32                   
33depends_build       port:apache-ant
34depends_lib         bin:java:kaffe
35                   
36use_configure       no
37universal_variant   no
38                   
39build.cmd           ant
40build.target        jar
41                   
42build.asroot        yes
43
44variant apidocs description "include API documentation" {
45    build.target-append  apidocs
46}
47
48variant nailgun description "include Nailgun support" {
49    build.target-append  build-ng
50    post-destroot {
51        xinstall -m 755 -d ${destroot}${prefix}/share/java/${name}/tool/nailgun
52        copy ${worksrcpath}/tool/nailgun/ng ${destroot}${prefix}/share/java/${name}/tool/nailgun
53    }
54}
55
56variant default_ruby description "build without j prefix" {}
57
58
59destroot {
60    # Create the target java directory exists
61    xinstall -m 755 -d ${destroot}${prefix}/share/java/${name}
62
63    # Copy over the needed elements of our directory tree
64    file copy \
65        ${worksrcpath}/bin \
66        ${worksrcpath}/lib \
67        ${destroot}${prefix}/share/java/${name}
68
69    if { [variant_isset apidocs] } {
70        file copy ${worksrcpath}/docs ${destroot}${prefix}/share/java/${name}
71    }
72
73    # Remove extraneous .bat, .exe and .dll files
74    foreach f [glob -directory ${destroot}${prefix}/share/java/${name}/bin *.bat] {
75        file delete $f
76    }
77    foreach f [glob -directory ${destroot}${prefix}/share/java/${name}/bin *.exe] {
78        file delete $f
79    }
80    foreach f [glob -directory ${destroot}${prefix}/share/java/${name}/bin *.dll] {
81        file delete $f
82    }
83
84    set jruby_prefix ""
85
86    if { ![variant_isset default_ruby] } {
87        set jruby_prefix "j"
88    }
89
90    foreach f { jruby jirb jrubyc jirb_swing } {
91        regsub {^j} $f $jruby_prefix dest
92        if { ${dest} != ${f} } {
93            ln -s ${prefix}/share/java/${name}/bin/${f} ${destroot}${prefix}/bin/${dest}
94        }
95        ln -s ${prefix}/share/java/${name}/bin/${f} ${destroot}${prefix}/bin/
96    }
97
98    foreach f { ast gem rdoc ri testrb } {
99        ln -s ${prefix}/share/java/${name}/bin/${f} \
100            ${destroot}${prefix}/bin/${jruby_prefix}${f}
101    }
102}
103
104livecheck.type      regex
105livecheck.url       ${homepage}
106livecheck.regex     {Download the latest release.*<strong>(.*)</strong>}
Note: See TracBrowser for help on using the repository browser.