Ticket #13564: Portfile

File Portfile, 3.0 KB (added by pmoura (Paulo Moura), 17 years ago)
Line 
1# $Id: Portfile 31733 2007-12-05 08:03:49Z ryandesign@macports.org $
2
3PortSystem      1.0
4name            swi-prolog
5version         5.6.47
6epoch           20051223
7
8categories      lang
9maintainers     wielemak@science.uva.nl pmoura@logtalk.org
10platforms       darwin
11description     SWI-Prolog compiler plus extra packages (stable version)
12
13long_description        \
14        ISO/Edinburgh-style Prolog compiler including modules,          \
15        autoload, libraries, Garbage-collector, stack-expandor,         \
16        C/C++-interface, Multiple threads, GNU-readline interface,      \
17        coroutining, constraint programming, global variables,          \
18        very fast compiler. Including packages clib (Unix process       \
19        control, sockets, MIME), cpp (C++ interface), sgml (reading     \
20        XML/SGML), sgml/RDF (reading RDF into triples), ODBC            \
21        interface and XPCE (Graphics UI toolkit, integrated editor      \
22        (Emacs-clone) and graphical debugger).
23
24homepage        http://www.swi-prolog.org/
25master_sites    http://gollem.science.uva.nl/cgi-bin/nph-download/SWI-Prolog/
26
27checksums       md5     4651f59c31225e87aa977274516cf818
28
29depends_build   \
30        port:gawk       \
31        port:junit
32
33depends_lib             \
34        port:readline                           \
35        lib:libncursesw:ncurses         \
36        lib:libjpeg:jpeg                        \
37        lib:libmcrypt:libmcrypt         \
38        lib:libX11.6:XFree86            \
39        lib:libgmp:gmp                          \
40        lib:libzlib:zlib
41
42platform darwin 6 {
43        depends_lib-append lib:libdl:dlcompat
44}
45
46platform darwin 9 {
47        depends_lib-append port:expat
48}
49
50distname        pl-${version}
51
52configure.env   \
53        LIBRARY_PATH=/usr/lib:/usr/X11R6/lib:${prefix}/lib              \
54        CPATH=/usr/include:/usr/X11R6/include:${prefix}/include \
55        JUNIT=${prefix}/share/java/junit.jar
56
57configure.ldflags
58
59configure.args  \
60        --prefix=${prefix}                              \
61        --mandir=${prefix}/share/man    \
62        --with-world
63
64build.env       \
65        LIBRARY_PATH=/usr/lib:/usr/X11R6/lib:${prefix}/lib              \
66        CPATH=/usr/include:/usr/X11R6/include:${prefix}/include \
67        JUNIT=${prefix}/share/java/junit.jar
68
69post-build {
70        file mkdir ${workpath}/macosx
71        file copy -force -- ${workpath}/pl-${version}/man/macosx/License.html ${workpath}/macosx/
72        file copy -force -- ${workpath}/pl-${version}/man/macosx/macosx.html ${workpath}/macosx/
73        file copy -force -- ${workpath}/pl-${version}/man/macosx/Welcome.html ${workpath}/macosx/
74}
75
76post-pkg {
77        set resources ${workpath}/${name}-${version}.pkg/Contents/Resources/
78        file copy -force -- ${workpath}/macosx/License.html ${resources}
79        file copy -force -- ${workpath}/macosx/macosx.html ${resources}
80        file copy -force -- ${workpath}/macosx/Welcome.html ${resources}
81        file rename ${resources}/macosx.html ${resources}/ReadMe.html
82        file delete -force -- ${resources}/Welcome.rtf
83}
84
85post-mpkg {
86        set resources ${workpath}/${name}-${version}.mpkg/Contents/Resources/
87        file copy -force -- ${workpath}/macosx/License.html ${resources}
88        file copy -force -- ${workpath}/macosx/macosx.html ${resources}
89        file copy -force -- ${workpath}/macosx/Welcome.html ${resources}
90        file rename ${resources}/macosx.html ${resources}/ReadMe.html
91        file delete -force -- ${resources}/Welcome.rtf
92}
93
94default_variants +mt
95
96variant st {
97        configure.args-append --disable-mt
98}
99
100variant mt {
101        configure.args-append --enable-mt
102}