Ticket #24371: Portfile

File Portfile, 2.9 KB (added by brennan@…, 14 years ago)

new portfile to help build mono 2.6.3

Line 
1# $Id: Portfile 66159 2010-04-06 08:48:23Z mww@macports.org $
2
3PortSystem 1.0
4
5name             mono
6version          2.6.3
7categories       devel lang mono
8platforms        darwin
9license          GPLv2 LGPLv2 MIT
10maintainers      mww openmaintainer
11description      Implementation of the .NET Development Framework
12long_description Mono is an effort to create an open source \
13                 implementation of the .NET Development Framework \
14                 including a C# compiler.
15
16homepage         http://www.go-mono.com/
17master_sites     ${homepage}sources/${name}/
18use_bzip2        yes
19universal_variant no
20
21if {[info exists supported_archs]} {
22    supported_archs i386 ppc
23}
24if {${build_arch} == "x86_64"} {
25    configure.build_arch i386
26} elseif {${build_arch} == "ppc64"} {
27    configure.build_arch ppc
28}
29
30checksums        md5     b1dc21bac2c7c75814a9f32246eadadd \
31                 sha1    a4aab7f46983664dc4cf63a01e4fe7a8a49de2c6 \
32                 rmd160  e3d61f618a0e9f063d6eb86e336f5deaa23cbcc8
33
34depends_build    port:pkgconfig port:gawk
35depends_lib      port:gettext path:lib/pkgconfig/glib-2.0.pc:glib2 port:icu \
36                 port:libiconv port:zlib port:libgdiplus port:xorg-libX11
37
38patchfiles       patch-configure.diff \
39                 patch-data-config.in.diff
40
41# Do NOT pick up external boehmgc (prefixing CPPFLAGS or CFLAGS does not suffice -- ugly++)
42configure.cc-append     "-I${worksrcpath}/libgc/include"
43
44configure.args   --with-gc=included \
45                 --with-preview=yes \
46                 --without-sigaltstack \
47                 --with-libgdiplus=${prefix} \
48                 --disable-dtrace
49
50test.run         yes
51test.target      check
52
53post-patch {
54    reinplace "s/-pthread/-lpthread/g" ${worksrcpath}/configure
55    reinplace s|@PREFIX@|$prefix|g $worksrcpath/data/config.in
56}
57
58post-destroot {
59    set docdir ${prefix}/share/doc/${name}-${version}
60
61    xinstall -d ${destroot}${docdir}
62    xinstall -m 0644 -W ${worksrcpath} AUTHORS COPYING.LIB ChangeLog NEWS README \
63        ${destroot}${docdir}
64
65    xinstall -m 0644 -W ${worksrcpath}/docs assembly-bundle embedded-api exceptions \
66        gc-issues jit-thoughts jit-trampolines object-layout stack-alignment unmanaged-calls \
67        ${destroot}${docdir}
68
69    move ${destroot}${prefix}/share/jay ${destroot}${docdir}
70
71    set libgc_docdir ${prefix}/share/doc/ligbc-mono-6.6
72
73    eval move ${destroot}${prefix}/share/libgc-mono \
74        ${destroot}${libgc_docdir}
75
76    xinstall -d ${destroot}${libgc_docdir}/html
77
78    eval move [glob ${destroot}${libgc_docdir}/*.html] \
79        ${destroot}${libgc_docdir}/html
80}
81
82platform darwin 9 {
83    # is this still valid for 2.6.3+ ?
84    configure.cflags-append    -D_NONSTD_SOURCE
85    configure.cxxflags-append    -D_NONSTD_SOURCE
86    patchfiles-append patch-interp.h.diff patch-sys-mman.c.diff \
87        patch-libgc-darwin_stop_world.c.diff
88}
89
90livecheck.type  regex
91livecheck.url   ${homepage}sources-stable/
92livecheck.regex mono/mono-(\\d+(?:\\.\\d+)*)
93