source: trunk/dports/lang/fsharp/Portfile

Last change on this file was 142698, checked in by landonf@…, 20 months ago

Drop maintainership of (almost) all my ports, as I'm no longer using Mac OS X as my desktop OS.

The dict port here dates back to ~2002; it was the first port used as a test case when we were developing MacPorts.

  • Property svn:eol-style set to native
  • Property svn:keywords set to Id
File size: 2.5 KB
Line 
1# $Id: Portfile 142698 2015-11-20 16:55:09Z ryandesign@macports.org $
2
3PortSystem 1.0
4
5name                fsharp
6version             1.9.4.19
7categories          lang
8license             Restrictive Noncommercial
9maintainers         nomaintainer
10supported_archs     noarch
11
12description         F# is a typed functional programming language.
13long_description    F# is a typed functional programming language \
14                    for the .NET Framework. It combines the succinctness, \
15                    expressivity, and compositionality of typed functional \
16                    programming with the runtime support, libraries, \
17                    interoperability, tools and object model of .NET. \
18                    F# stems from the ML family of languages and has a \
19                    core language compatible with that of OCaml, though \
20                    also draws from C# and Haskell.
21homepage            http://research.microsoft.com/en-us/um/cambridge/projects/fsharp/
22platforms           darwin
23
24use_zip             yes
25
26master_sites        ftp://ftp.research.microsoft.com/downloads/6f48a466-4294-4973-9e15-25e0ddff422f
27checksums           md5 d51c93d29599540a957f94ff387e65fa \
28                    sha1 655a790fd98f7b68c19722b0a29e9d1048c39e0f
29
30depends_lib         port:mono
31
32worksrcdir          FSharp-${version}
33
34use_configure       no
35
36post-patch {
37    reinplace "s|gacutil -i|gacutil -i -root ${destroot}${prefix}/lib/|g" ${worksrcpath}/install-mono.sh
38    reinplace "s|^echo.*||g" ${worksrcpath}/install-mono.sh
39}
40
41build {
42}
43
44destroot {
45    # Install the assemblies
46    system "cd ${worksrcpath} && bash install-mono.sh"
47
48    # Copy the entire lot to ${prefix}/share
49    set sharedir ${prefix}/share/fsharp-${version}
50    file copy ${worksrcpath} ${destroot}/${sharedir}
51
52    # Create launchers for the binaries
53    foreach binary [glob -dir ${worksrcpath}/bin *.exe] {
54        # fsc is a windows binary
55        if {[file tail $binary] == "fsc.exe"} {
56            continue
57        }
58
59        set destfile [file join "${destroot}${prefix}/bin/" [file tail [file rootname $binary]]]
60        set linkdest [file join ${sharedir}/bin/ [file tail $binary]]
61
62        # Write the launcher script
63        set fd [open ${destfile} "w"]
64        puts $fd "#/bin/sh"
65        puts $fd "if \[ -z \$DYLD_FALLBACK_LIBRARY_PATH \]; then"
66        puts $fd "    export DYLD_FALLBACK_LIBRARY_PATH=/usr/local/lib:/lib:/usr/lib:${prefix}/lib"
67        puts $fd "fi"
68        puts $fd "exec ${prefix}/bin/mono ${linkdest} \$\*"
69        close $fd
70
71        system "chmod +x ${destfile}"
72    }
73}
Note: See TracBrowser for help on using the repository browser.