source: trunk/dports/lang/scala2.8/Portfile

Last change on this file was 152779, checked in by blair@…, 10 months ago

scala2.8: add livecheck.

  • Property svn:eol-style set to native
  • Property svn:keywords set to Id
File size: 2.5 KB
Line 
1# $Id: Portfile 152779 2016-09-18 01:46:55Z ryandesign@macports.org $
2
3PortSystem 1.0
4PortGroup select 1.0
5
6name            scala2.8
7version         2.8.2
8set branch      [join [lrange [split ${version} .] 0 1] .]
9categories      lang java
10license         BSD
11maintainers     openmaintainer blair
12description     The Scala Programming Language
13long_description \
14                Scala is a modern multi-paradigm programming language \
15                designed to express common programming patterns in a \
16                concise, elegant, and type-safe way.  It smoothly \
17                integrates features of object-oriented and functional \
18                languages.  It runs inside a Java Virtual Machine and \
19                is fully interoperable with Java.
20homepage        http://www.scala-lang.org/
21platforms       darwin
22supported_archs noarch
23
24master_sites    ${homepage}downloads/distrib/files/
25distname        scala-${version}.final
26extract.suffix  .tgz
27checksums       md5 8201780fcc796f3b68e401f8165c0002 \
28                sha1 2d6250763dcba02f371e0c26999a4f43670e8e3e \
29                rmd160 48e04679e627b72aef371dd62e966fc76a2598d8
30
31depends_lib     port:scala_select
32
33use_configure   no
34build           {}
35
36select.group    scala
37select.file     ${filespath}/${name}
38
39destroot {
40    set sharedir ${destroot}${prefix}/share
41    set man1dir ${sharedir}/man/man1
42    set scaladir ${sharedir}/scala-${branch}
43    set docscaladir ${sharedir}/doc/scala-${branch}
44
45    xinstall -d -m 755 ${sharedir}
46    file copy ${worksrcpath} ${scaladir}
47
48    foreach f {fsc sbaz sbaz-setup scala scalac scaladoc scalap} {
49        ln -s ../share/scala-${branch}/bin/${f} \
50            ${destroot}${prefix}/bin/${f}-${branch}
51    }
52
53    file delete ${man1dir}
54    file rename ${scaladir}/man/man1 ${man1dir}
55    foreach f {fsc sbaz scala scalac scaladoc scalap} {
56        file rename ${man1dir}/${f}.1 ${man1dir}/${f}-${branch}.1
57    }
58    file delete -force ${scaladir}/man
59
60    xinstall -d -m 755 ${docscaladir}
61    foreach doc {sbaz sbaz-setup} {
62        file rename ${scaladir}/doc/${doc} ${docscaladir}/${doc}
63    }
64    file delete -force ${scaladir}/doc
65
66    xinstall -d -m 755 ${sharedir}/java
67    foreach f {scala-compiler.jar
68               scala-dbc.jar
69               scala-library.jar
70               scala-swing.jar
71               scalap.jar} {
72        set g [strsed ${f} "/.jar/-${branch}.jar/"]
73        ln -s ../scala-${branch}/lib/${f} ${sharedir}/java/${g}
74    }
75}
76
77livecheck.type  regex
78livecheck.url   http://scala-lang.org/download/all.html
79livecheck.regex {/download/(2\.8\.\d+(?:\.\d+)*)\.final\.html}
Note: See TracBrowser for help on using the repository browser.