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 153226 2016-09-27 16:09:50Z devans@macports.org $ |
---|
3 | |
---|
4 | PortSystem 1.0 |
---|
5 | PortGroup active_variants 1.1 |
---|
6 | |
---|
7 | name gobject-introspection |
---|
8 | version 1.50.0 |
---|
9 | set branch [join [lrange [split ${version} .] 0 1] .] |
---|
10 | categories gnome |
---|
11 | platforms darwin |
---|
12 | # library under LGPL-2+, tools under GPL-2+ |
---|
13 | license {LGPL GPL-2+} |
---|
14 | maintainers juanrgar devans openmaintainer |
---|
15 | description GObject Introspection |
---|
16 | long_description Gobject Introspection acts as a bridge between low-level C+GObject code and \ |
---|
17 | a managed runtime (JavaScript, Python, Java, Lua, .NET, Scheme, etc.). |
---|
18 | |
---|
19 | homepage https://wiki.gnome.org/Projects/GObjectIntrospection |
---|
20 | master_sites gnome:sources/${name}/${branch}/ |
---|
21 | use_xz yes |
---|
22 | |
---|
23 | checksums rmd160 d2f07bcb3bdb73b09fb59b9d4ced7a7f12660c41 \ |
---|
24 | sha256 1c6597c666f543c70ef3d7c893ab052968afae620efdc080c36657f4226337c5 |
---|
25 | |
---|
26 | depends_build port:pkgconfig |
---|
27 | |
---|
28 | depends_lib path:lib/pkgconfig/cairo.pc:cairo \ |
---|
29 | path:lib/pkgconfig/glib-2.0.pc:glib2 \ |
---|
30 | port:libffi \ |
---|
31 | port:py27-mako |
---|
32 | |
---|
33 | depends_run bin:glibtool:libtool |
---|
34 | |
---|
35 | patchfiles no-env-shebang.patch |
---|
36 | |
---|
37 | post-patch { |
---|
38 | reinplace "s|'cc'|'${configure.cc}'|g" ${worksrcpath}/giscanner/sourcescanner.py |
---|
39 | reinplace "s|'gcc'|'${configure.cc}'|g" ${worksrcpath}/giscanner/dumper.py |
---|
40 | reinplace "s|libcairo-gobject.2.dylib|${prefix}/lib/libcairo-gobject.2.dylib|g" ${worksrcpath}/configure |
---|
41 | } |
---|
42 | |
---|
43 | configure.python ${prefix}/bin/python2.7 |
---|
44 | |
---|
45 | # GObject introspection doesn't build with tiger's make, #32358 |
---|
46 | platform darwin 8 { |
---|
47 | depends_build-append port:gmake |
---|
48 | build.cmd ${prefix}/bin/gmake |
---|
49 | } |
---|
50 | |
---|
51 | build.args CC="${configure.cc} ${configure.cc_archflags}" V=1 |
---|
52 | |
---|
53 | # gobject-introspection needs to be aware whether it was compiled against python +ucs4, see #35603 |
---|
54 | variant python_ucs4 description {Build against Python with +ucs4} { |
---|
55 | require_active_variants python27 ucs4 |
---|
56 | } |
---|
57 | |
---|
58 | if {![variant_isset python_ucs4]} { |
---|
59 | pre-configure { |
---|
60 | if {![active_variants python27 "" ucs4]} { |
---|
61 | error "You have python installed with the +ucs4 variant. Please build ${name} with +python_ucs4" |
---|
62 | } |
---|
63 | } |
---|
64 | } |
---|
65 | |
---|
66 | if {![catch {set result [active_variants python27 ucs4]}]} { |
---|
67 | if {$result} { |
---|
68 | default_variants +python_ucs4 |
---|
69 | } |
---|
70 | } |
---|
71 | |
---|
72 | livecheck.type gnome |
---|