Ticket #51060: Portfile-nghttp2.diff

File Portfile-nghttp2.diff, 2.3 KB (added by Schamschula (Marius Schamschula), 9 years ago)
  • Portfile

    old new  
    11# -*- 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 147481 2016-04-05 12:50:13Z khindenburg@macports.org $
     2# $Id: Portfile 147204 2016-03-31 02:39:48Z khindenburg@macports.org $
    33
    44PortSystem          1.0
    55PortGroup           cxx11 1.0
    66PortGroup           github 1.0
    77
    88github.setup        tatsuhiro-t nghttp2 1.9.2 v
    9 set PythonVersion   2.7
    10 set PythonBranch    [join [lrange [split ${PythonVersion} .] 0 1] ""]
    119categories          www
    1210platforms           darwin
    1311maintainers         gmail.com:mschamschula openmaintainer
     
    2422checksums           rmd160 ef40a5c6782294116863e22890c0a74a54715fdb \
    2523                    sha256 3d600ef8bfd151769559bc23806877b8b4eaf3d66776e6c1427b9c04cce8e853
    2624
     25if {![variant_isset python35]} { default_variants +python27 }
     26
     27if {![variant_isset python27] && ![variant_isset python35]} {
     28    error "You must select one of the python variants."
     29}
     30
     31if {[variant_isset python27]} { set PythonVersion   2.7 }
     32if {[variant_isset python35]} { set PythonVersion   3.5 }
     33set PythonBranch    [join [lrange [split ${PythonVersion} .] 0 1] ""]
     34
    2735depends_build       port:pkgconfig
    2836
    2937depends_lib         port:jansson \
     
    4654                    LIBEVENT_OPENSSL_LIBS="-L${prefix}/lib -levent -levent_openssl" \
    4755                    OPENSSL_CFLAGS=-I${prefix}/include/openssl \
    4856                    OPENSSL_LIBS="-L${prefix}/lib -lcrypto -lssl" \
    49                     PYTHON=${prefix}/bin/python${PythonVersion} \
    50                     PYTHON_EXTRA_LDFLAGS="-u _PyMac_Error ${frameworks_dir}/Python.framework/Versions/${PythonVersion}/Python"
     57                    PYTHON=${prefix}/bin/python${PythonVersion}
    5158
    5259destroot.env        PYTHONPATH=${destroot}${prefix}/lib/python${PythonVersion}/site-packages/
    5360
    5461pre-destroot {
    5562    xinstall -d ${destroot}${prefix}/lib/python${PythonVersion}/site-packages/
    5663}
     64
     65variant python27 conflicts python35 description {Build using Python 2.7} {
     66    configure.env-append   PYTHON_EXTRA_LDFLAGS="-u _PyMac_Error ${frameworks_dir}/Python.framework/Versions/${PythonVersion}/Python"
     67}
     68
     69variant python35 conflicts python27 description {Build using Python 3.5} {}