1 | # $Id: Portfile 38017 2008-07-02 21:06:50Z gwright@macports.org $ |
---|
2 | |
---|
3 | PortSystem 1.0 |
---|
4 | |
---|
5 | name gtk2hs |
---|
6 | version 0.10.0 |
---|
7 | categories devel graphics |
---|
8 | platforms darwin |
---|
9 | maintainers gwright@macports.org |
---|
10 | |
---|
11 | description Portable and native GUI library for Haskell |
---|
12 | long_description \ |
---|
13 | gtk2hs is a Haskell binding to GTK, a comprehensive \ |
---|
14 | C GUI library that is portable across many platforms. |
---|
15 | |
---|
16 | homepage http://www.haskell.org/gtk2hs |
---|
17 | master_sites sourceforge |
---|
18 | |
---|
19 | extract.suffix .tar.gz |
---|
20 | checksums md5 08df47256cbcd5668e82b9f8beb621ab \ |
---|
21 | sha1 de502c153d571b662c3a296baec659f129a8964d \ |
---|
22 | rmd160 945f94e78b1ed462be3f6100b7541b385d6b3d35 |
---|
23 | |
---|
24 | depends_lib port:ghc \ |
---|
25 | port:gtk2 \ |
---|
26 | port:cairo \ |
---|
27 | port:librsvg \ |
---|
28 | port:libglade2 \ |
---|
29 | port:gtkglext \ |
---|
30 | port:gtksourceview2 |
---|
31 | |
---|
32 | configure.args --with-hc=${prefix}/bin/ghc \ |
---|
33 | --enable-gtk \ |
---|
34 | --enable-gio \ |
---|
35 | --enable-profiling \ |
---|
36 | --enable-packager-mode \ |
---|
37 | --enable-libglade \ |
---|
38 | --enable-gconf \ |
---|
39 | --enable-gtksourceview2 \ |
---|
40 | --enable-cairo \ |
---|
41 | --enable-svg \ |
---|
42 | --enable-opengl \ |
---|
43 | --without-pkgreg |
---|
44 | |
---|
45 | variant no_x11 description "Remove X11 support (disables gtkglext)" { |
---|
46 | depends_lib-delete port:gtkglext |
---|
47 | configure.args-delete --enable-opengl |
---|
48 | } |
---|
49 | |
---|
50 | # Fix gtk.package.conf to allow interoperating with non-MacPorts |
---|
51 | # ghc. (MacPorts' ghc adds ${prefix}/lib to the linker path |
---|
52 | # automatically.) |
---|
53 | |
---|
54 | post-destroot { reinplace "s|library-dirs: |library-dirs: \"${prefix}/lib\",|" \ |
---|
55 | ${destroot}${prefix}/lib/${name}/gtk.package.conf |
---|
56 | } |
---|
57 | |
---|
58 | # Note that the order of package registration is important: certain |
---|
59 | # packages must be registered before the packages that depend on them. |
---|
60 | |
---|
61 | post-activate { set pkgs {glib cairo svgcairo gtk gconf glade gtksourceview2 soegtk} |
---|
62 | foreach pkg ${pkgs} { |
---|
63 | system "ghc-pkg update ${destroot}${prefix}/lib/${name}/${pkg}.package.conf" |
---|
64 | } |
---|
65 | if {![variant_isset no_x11]} { |
---|
66 | system "ghc-pkg update ${destroot}${prefix}/lib/${name}/gtkglext.package.conf" |
---|
67 | } |
---|
68 | } |
---|
69 | |
---|