Ticket #55361: Portfile.diff

File Portfile.diff, 1.7 KB (added by MarcusCalhoun-Lopez (Marcus Calhoun-Lopez), 7 years ago)
  • Portfile

    old new  
    1919variant python27 description "Use Python 2.7 SymPy" conflicts python34 python35 python36 {
    2020    depends_lib-append  port:python27 \
    2121                        port:py27-sympy
    22    
    23     configure.env-append \
    24         PYTHON=${prefix}/bin/python2.7
     22    configure.python    ${prefix}/bin/python2.7
    2523}
    2624
    2725variant python34 description "Use Python 3.4 SymPy" conflicts python27 python35 python36 {
    2826    depends_lib-append  port:python34 \
    2927                        port:py34-sympy
    30    
    31     configure.env-append \
    32         PYTHON=${prefix}/bin/python3.4
     28    configure.python    ${prefix}/bin/python3.4
    3329}
    3430
    3531variant python35 description "Use Python 3.5 SymPy" conflicts python27 python34 python36 {
    3632    depends_lib-append  port:python35 \
    3733        port:py35-sympy
    38 
    39     configure.env-append \
    40         PYTHON=${prefix}/bin/python3.5
     34    configure.python    ${prefix}/bin/python3.5
    4135}
    4236
    4337variant python36 description "Use Python 3.6 SymPy" conflicts python27 python34 python35 {
    4438    depends_lib-append  port:python36 \
    4539        port:py36-sympy
    46 
    47     configure.env-append \
    48         PYTHON=${prefix}/bin/python3.6
     40    configure.python    ${prefix}/bin/python3.6
    4941}
    5042
    5143if {![variant_isset python27] && ![variant_isset python34] && ![variant_isset python35] && ![variant_isset python36]} {
     
    6052    return -code error "Invalid variant selection"
    6153
    6254}
     55
     56# see https://trac.macports.org/ticket/55361
     57patchfiles-append patch-python.diff
     58post-patch {
     59    reinplace \
     60        "s|__MACPORTS_PYTHON__|${configure.python}|g" \
     61        ${worksrcpath}/inst/sympref.m
     62}