Ticket #48995: Portfile.bob.diff

File Portfile.bob.diff, 5.0 KB (added by tiagofrepereira2012 (Tiago Freitas Pereira), 9 years ago)
  • (a) /Users/tiagodefreitaspereira/Documents/buildOutProjects/bioidiap/dports/science/bob/Portfile vs. (b) Portfile.current

    a b  
    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 136416 2015-05-16 16:52:31Z mmoll@macports.org $
     2# $Id$
    33
    44PortSystem          1.0
    5 PortGroup           cmake 1.0
    6 PortGroup           github 1.0
    7 PortGroup           active_variants 1.1
    8 PortGroup           compiler_blacklist_versions 1.0
    9 
    10 github.setup        idiap bob 1.2.2 v
    11 revision            9
    12 set soversion       1.2
     5replaced_by         py27-bob
     6PortGroup           obsolete 1.0
     7
     8name                bob
     9version             1.2.2
     10
     11revision            10
    1312categories          science math devel
    1413platforms           darwin
    1514maintainers         idiap.ch:andre.anjos \
    16                     idiap.ch:laurent.el-shafey
     15                    idiap.ch:laurent.el-shafey \
     16                    idiap.ch:tiago.pereira
    1717
    1818description         Bob is a signal-processing and machine learning toolbox
    1919
     
    2424                    reduce development time.
    2525
    2626license             GPL-3
    27 homepage            http://idiap.github.com/bob/
    28 
    29 checksums           rmd160  fa2ededccdee5cb2cf8db1900631490dd9f412a9 \
    30                     sha256  df88a3c41ea2be42f6695da13b861fb10b5bbf8bff85ad8f4b7f345543a789e1
    31 
    32 depends_build-append \
    33     port:pkgconfig
    34 
    35 depends_lib         port:blitz \
    36     path:lib/libavcodec.dylib:ffmpeg \
    37     port:matio \
    38     port:jpeg \
    39     port:netpbm \
    40     port:libpng \
    41     port:tiff \
    42     port:giflib \
    43     port:hdf5 \
    44     port:boost \
    45     port:fftw-3 \
    46     port:vlfeat \
    47     port:libsvm
    48 
    49 # compiler needs to support C++11 features
    50 if {[lsearch [get_canonical_archs] ppc] != -1 || [lsearch [get_canonical_archs] ppc64] != -1} {
    51     # Until llvm better supports darwin/ppc, the only C++11 compiler for ppc is gcc
    52     compiler.whitelist macports-gcc-4.7
    53 } else {
    54     compiler.blacklist gcc-4.0 gcc-4.2 apple-gcc-4.2 llvm-gcc-4.2 macports-llvm-gcc-4.2 {clang < 300}
    55 }
    56 
    57 configure.args      -DCMAKE_BUILD_TYPE=Release -DBOB_VERSION=${version} -DBOB_SOVERSION=${soversion} -DWITH_QT4=OFF
    58 
    59 # blitz is not universal
    60 universal_variant   no
    61 
    62 if { ![variant_isset python26] } {
    63     default_variants-append +python27
    64 }
    65 
    66 variant python26 conflicts python27 description "Build for python 2.6" {
    67     depends_build-append  port:py26-sphinx
    68 
    69     depends_lib-append    port:py26-setuptools \
    70       port:py26-numpy \
    71       port:py26-matplotlib \
    72       port:py26-sqlalchemy \
    73       port:py26-argparse \
    74       port:py26-scipy \
    75       port:py26-nose \
    76       port:py26-pillow
    77 }
    78 
    79 variant python27 conflicts python26 description "Build for python 2.7" {
    80     depends_build-append  port:py27-sphinx
    81 
    82     depends_lib-append    port:py27-setuptools \
    83       port:py27-numpy \
    84       port:py27-matplotlib \
    85       port:py27-sqlalchemy \
    86       port:py27-scipy \
    87       port:py27-nose \
    88       port:py27-pillow
    89 }
    90 
    91 variant doc description "Build documentation" {
    92     depends_build-append    port:dvipng \
    93         port:doxygen \
    94         path:bin/dot:graphviz \
    95         port:texlive-latex-extra \
    96         port:texlive-fonts-recommended
    97     destroot.target-append  sphinx-latex install-sphinx install-doxygen
    98 
    99     test.run yes
    100     test.target sphinx-doctest
    101 }
    102 
    103 pre-configure {
    104     if {[variant_isset python26]} {
    105         configure.args-append -DWITH_PYTHON=${prefix}/bin/python2.6
    106     } elseif {[variant_isset python27]} {
    107         configure.args-append -DWITH_PYTHON=${prefix}/bin/python2.7
    108     }
    109 }
    110 
    111 post-destroot {
    112     if {[variant_isset python26]} {
    113         set pypath ${prefix}/lib/python2.6/site-packages
    114         set pycompile ${prefix}/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages
    115         xinstall -d ${destroot}/${pycompile}
    116         system "${prefix}/bin/python2.6 -m compileall ${destroot}/${pypath}/bob"
    117         move ${destroot}/${pypath}/bob ${destroot}/${pycompile}/bob
    118         move ${destroot}/${pypath}/bob-${version}-py2.6.egg-info ${destroot}/${pycompile}/
    119     } elseif {[variant_isset python27]} {
    120         set pypath ${prefix}/lib/python2.7/site-packages
    121         set pycompile ${prefix}/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages
    122         xinstall -d ${destroot}/${pycompile}
    123         system "${prefix}/bin/python2.7 -m compileall ${destroot}/${pypath}/bob"
    124         move ${destroot}/${pypath}/bob ${destroot}/${pycompile}/bob
    125         move ${destroot}/${pypath}/bob-${version}-py2.7.egg-info ${destroot}/${pycompile}/
    126     }
    127 }
    128 
    129 # check if boost is installed with the required python variant
    130 if {[variant_isset python26]} {
    131     set boost_python_variant    python26
    132 } elseif {[variant_isset python27]} {
    133     set boost_python_variant    python27
    134 }
    135 
    136 require_active_variants boost   ${boost_python_variant}
     27homepage            http://idiap.github.com/bob/
     28 No newline at end of file