Ticket #36216: Portfile

File Portfile, 4.7 KB (added by bill@…, 12 years ago)
Line 
1# -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:ft=tcl:et:sw=4:ts=4:sts=4
2# $Id: Portfile 94944 2012-07-02 17:42:59Z mww@macports.org $
3
4PortSystem          1.0
5
6name                pike
7version             7.8.700
8revision            5
9categories          lang
10license             GPL-2
11platforms           darwin
12maintainers         gmx.de:exodusd openmaintainer
13
14description         dynamic programming language
15
16long_description    Pike is a dynamic programming language with a syntax \
17                    similar to Java and C. It is simple to learn, does \
18                    not require long compilation passes and has powerful \
19                    built-in data types allowing simple and really fast \
20                    data manipulation.
21
22homepage            http://pike.ida.liu.se/
23master_sites        ${homepage}pub/pike/all/${version}/
24distname            Pike-v${version}
25
26checksums           rmd160 241c6d531ac74a64322ef57bdd7dee306be1e8c3 \
27                    sha1 877bd50d2bb202aa485d1f7c62398922d60696c7 \
28                    md5 9f758c484e55f0660e956823cbf13c7e
29
30depends_lib port:bzip2 \
31                    port:zlib \
32                    port:gmp \
33                    port:nettle \
34                    port:pcre
35
36variant image description {Images (JPEG, PNG, GIF, TIFF) support for Pike} {
37    configure.args-append --with-jpeglib --with-gif --with-tifflib
38    depends_lib-append port:jpeg port:tiff port:libpng path:include/gif_lib.h:giflib
39}
40
41variant ttf description {TrueType (TTF) support (using FreeType) for Pike} {
42    configure.args-append --with-freetype
43    depends_lib-append port:freetype
44}
45
46variant gdbm description {GDBM database support for Pike} {
47    configure.args-append --with-gdbm
48    depends_lib-append port:gdbm
49}
50
51variant mysql description {MySQL database support for Pike} {
52    configure.args-append --with-mysql
53    depends_lib-append lib:libmysqlclient:mysql5
54}
55
56variant odbc description {ODBC database support for Pike} {
57    configure.args-append --with-odbc
58    depends_lib-append port:unixODBC
59}
60
61variant postgresql description {Postgres database support for Pike} {
62    configure.args-append --with-postgres
63    depends_lib-append port:postgresql83
64}
65
66variant gtk description {GTK support for Pike} {
67    configure.args-append --with-gtk
68    depends_lib-append port:gtk2
69}
70
71variant opengl description {OpenGL support for Pike} {
72    configure.args-append --with-GL --with-GLUT
73    depends_lib-append port:mesa
74}
75
76#variant perl description {Perl support for Pike} {
77#    configure.args-append --with-perl
78#    depends_lib-append port:perl5.10
79#}
80
81variant sane description {SANE scanner support for Pike} {
82    configure.args-append --with-sane
83    depends_lib-append port:sane-backends
84}
85
86variant sdl description {SDL support for Pike} {
87    configure.args-append --with-SDL
88    depends_lib-append path:lib/pkgconfig/sdl.pc:libsdl port:libsdl_mixer
89}
90
91variant svg description {SVG vector graphics support for Pike} {
92    configure.args-append --with-svg
93    depends_lib-append port:librsvg
94}
95
96variant doc description {Pike documentation} {
97    build.target-append doc
98}
99
100use_configure       no
101
102configure.cc        gcc-4.2
103configure.cxx       g++-4.2
104
105build.jobs          1
106
107configure.args      --without-bundles \
108                    --mandir=${prefix}/share/man \
109                    --with-include-path=${prefix}/include \
110                    --with-lib-path=${prefix}/lib \
111                    --without-machine-code \
112                    --with-pcre \
113                    --with-zlib
114
115pre-build {
116    # setup the build.args here, because then the configure.args from the
117    # variants will have been assembled:
118    build.args      CONFIGUREARGS="${configure.pre_args} ${configure.args}" \
119                    INSTALLARGS="--traditional" \
120                    CC="${configure.cc}" CXX="${configure.cxx}"
121}
122
123test.run            yes
124test.target         verify
125
126destroot.target     install_nodoc
127destroot.destdir    buildroot=${destroot} INSTALLARGS="--traditional"
128
129post-destroot {
130    file delete -force ${destroot}${prefix}/bin/pike.syms
131    file delete -force ${destroot}${prefix}/doc/pike
132    # move manpage to correct location:
133    #move ${destroot}${prefix}/man/man1/pike.1 \
134    #    ${destroot}${prefix}/share/man/man1/
135    # move documentation to correct location:
136    xinstall -d ${destroot}${prefix}/share/doc/pike-${version}
137    xinstall -W ${worksrcpath} README COPYING COPYRIGHT ANNOUNCE \
138        COMMITTERS ${destroot}${prefix}/share/doc/pike-${version}
139    if {[variant_isset doc]} {
140        move ${worksrcpath}/refdoc/modref \
141            ${destroot}${prefix}/share/doc/pike-${version}
142        move ${worksrcpath}/refdoc/traditional_manual \
143            ${destroot}${prefix}/share/doc/pike-${version}
144    }
145}