Ticket #20894: Portfile

File Portfile, 2.8 KB (added by rob@…, 14 years ago)

Portfile for mono build on Snow Leopard with x86_64 patch

Line 
1# $Id: Portfile 58271 2009-09-25 03:17:55Z ryandesign@macports.org $
2
3PortSystem 1.0
4
5name             mono
6version          2.4.2.3
7categories       devel lang mono
8platforms        darwin
9license          GPLv2 LGPLv2 MIT
10maintainers      mww
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
21checksums           md5     696f25afc8453cd0d1c78de6e905dcf2 \
22                    sha1    c0e7c2992ef6c1ea3d1fd48ef581aa1ff6ec29cb \
23                    rmd160  f52bf6e281b076b859a567c17917577710522684
24
25depends_build    port:pkgconfig port:gawk
26depends_lib      port:gettext path:lib/pkgconfig/glib-2.0.pc:glib2 port:icu \
27                 port:libiconv port:zlib port:libgdiplus port:xorg-libX11
28
29patchfiles       patch-configure.diff \
30                 patch-data-config.in.diff
31
32# Do NOT pick up external boehmgc (prefixing CPPFLAGS or CFLAGS does not suffice -- ugly++)
33configure.cc-append     "-I${worksrcpath}/libgc/include"
34
35configure.build_arch i386
36
37configure.args   --with-gc=included \
38                 --with-preview=yes \
39                 --without-sigaltstack \
40                 --with-libgdiplus=${prefix} \
41                 --disable-dtrace
42
43test.run         yes
44test.target      check
45
46post-patch {
47    reinplace "s/-pthread/-lpthread/g" ${worksrcpath}/configure
48    reinplace s|@PREFIX@|$prefix|g $worksrcpath/data/config.in
49}
50
51post-destroot {
52    set docdir ${prefix}/share/doc/${name}-${version}
53
54    xinstall -d ${destroot}${docdir}
55    xinstall -m 0644 -W ${worksrcpath} AUTHORS COPYING.LIB ChangeLog NEWS README \
56        ${destroot}${docdir}
57
58    xinstall -m 0644 -W ${worksrcpath}/docs assembly-bundle embedded-api exceptions \
59        gc-issues jit-thoughts jit-trampolines object-layout stack-alignment unmanaged-calls \
60        ${destroot}${docdir}
61
62    move ${destroot}${prefix}/share/jay ${destroot}${docdir}
63
64    set libgc_docdir ${prefix}/share/doc/ligbc-mono-6.6
65
66    eval move ${destroot}${prefix}/share/libgc-mono \
67        ${destroot}${libgc_docdir}
68
69    xinstall -d ${destroot}${libgc_docdir}/html
70
71    eval move [glob ${destroot}${libgc_docdir}/*.html] \
72        ${destroot}${libgc_docdir}/html
73}
74
75platform darwin 9 {
76    configure.cflags-append    -D_NONSTD_SOURCE
77    configure.cxxflags-append    -D_NONSTD_SOURCE
78    patchfiles-append patch-interp.h.diff patch-sys-mman.c.diff \
79        patch-mono-mini-mini-x86.h.diff \
80        patch-libgc-darwin_stop_world.c.diff
81}
82
83platform darwin 10 {
84configure.cflags-append -m32 -Dmacosx -D_XOPEN_SOURCE
85}
86
87livecheck.type  regex
88livecheck.url   ${homepage}sources-stable/
89livecheck.regex mono/mono-(\\d+(?:\\.\\d+)*)
90