source: trunk/dports/devel/nspr/Portfile

Last change on this file was 153735, checked in by mps@…, 14 months ago

nspr: update to version 4.13.

  • Property svn:eol-style set to native
  • Property svn:keywords set to Id
File size: 2.5 KB
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 153735 2016-10-09 21:39:44Z ryandesign@macports.org $
3
4PortSystem  1.0
5PortGroup           muniversal 1.0
6
7name                nspr
8version             4.13
9categories          devel
10maintainers         nomaintainer
11license             {MPL-1.1 GPL-2+ LGPL-2.1+}
12platforms           darwin
13
14description         A platform-neutral API for system level and libc like functions.
15long_description    ${description}
16
17homepage            http://www.mozilla.org/projects/nspr
18master_sites        http://ftp.mozilla.org/pub/mozilla.org/nspr/releases/v${version}/src/ \
19                    ftp://ftp.mozilla.org/pub/mozilla.org/nspr/releases/v${version}/src/
20
21checksums           rmd160  9769164662cb9349bf1c33e39e644767d1c767ae \
22                    sha256  19c33334bb3fa6d24800ffa65d7d806c54ad5f8c3758a5c11352ad43212ab181
23
24worksrcdir          ${worksrcdir}/nspr
25
26post-patch {
27    reinplace "s:@LDFLAGS@:${configure.ldflags}:" \
28        ${worksrcpath}/config/nspr-config.in
29    reinplace "s|@executable_path|${prefix}/lib/nspr|g" \
30        ${worksrcpath}/configure
31}
32
33configure.args \
34    --disable-debug \
35    --enable-optimize='${configure.optflags}' \
36    --libdir=${prefix}/lib/nspr
37
38set merger_configure_args(ppc64)  "--enable-64bit"
39set merger_configure_args(x86_64) "--enable-64bit"
40
41variant debug description "build with debugging symbols" {
42    configure.args-delete   --disable-debug \
43                            --enable-optimize='${configure.optflags}'
44
45    configure.args-append   --enable-debug='-ggdb3' \
46                            --disable-optimize
47
48    configure.cflags ""
49}
50
51post-destroot {
52    file mkdir ${destroot}${prefix}/lib/pkgconfig
53    copy ${filespath}/nspr.pc ${destroot}${prefix}/lib/pkgconfig
54    reinplace "s|@@prefix@@|${prefix}|" ${destroot}${prefix}/lib/pkgconfig/nspr.pc
55    set mylibs [exec ${destroot}${prefix}/bin/nspr-config --libs]
56    set mycflags [exec ${destroot}${prefix}/bin/nspr-config --cflags]
57    set myversion [exec ${destroot}${prefix}/bin/nspr-config --version]
58    reinplace "s|@@FULL_NSPR_LIBS@@|${mylibs}|" ${destroot}${prefix}/lib/pkgconfig/nspr.pc
59    reinplace "s|@@FULL_NSPR_CFLAGS@@|${mycflags}|" ${destroot}${prefix}/lib/pkgconfig/nspr.pc
60    reinplace "s|@@NSPR_VERSION@@|${myversion}|" ${destroot}${prefix}/lib/pkgconfig/nspr.pc
61}
62
63livecheck.type      regex
64#livecheck.url   [lindex ${master_sites} 0]
65livecheck.url       http://ftp.mozilla.org/pub/mozilla.org/nspr/releases/
66livecheck.regex     "v(\\d+(?:\\.\\d+)*)"
Note: See TracBrowser for help on using the repository browser.