Ticket #51411: mlt.4.diff

File mlt.4.diff, 3.7 KB (added by RJVB (René Bertin), 8 years ago)

mlt-qt5 depends on a Qt5 component that's not installed by default by port:qt5 and port:qt55

  • multimedia/mlt/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$
     2# $Id: Portfile 145945 2016-02-22 08:53:45Z devans@macports.org $
    33
    44PortSystem          1.0
    55PortGroup           muniversal 1.0
    6 PortGroup           qt4 1.0
    76
    87name                mlt
    98epoch               3
    10 version             6.0.0
    11 revision            1
     9version             6.4.1
    1210categories          multimedia
    13 maintainers         dennedy.org:dan
     11maintainers         gmail.com:rjvbertin dennedy.org:dan openmaintainer
    1412license             GPL-2+
    1513
    1614description         Open source multimedia framework - core libraries
     
    2725master_sites        sourceforge:project/mlt/mlt
    2826platforms           darwin
    2927
    30 checksums           rmd160 e9b03671545aa5349541495bc226328f639178cf \
    31                     sha256 317874cfc7fc528dddbb3a7a32fd46372aae22bdc4527be1cfb55c93fa66e3bd
     28checksums           rmd160  647cdad41974b93c5745a358e1129f2ed5f6e577 \
     29                    sha256  d3a992f3e67463e68630cb0b455d408a2a12f4da7a19e46807fa08a79f09b2b6
     30
     31subport ${name}-qt5 {
     32    description     ${description} - Qt5 version
     33    long_description \
     34                    ${long_description} Built against Qt5.
     35}
     36
     37if {${subport} eq "${name}"} {
     38    conflicts       ${name}-qt5
     39    PortGroup       qt4 1.0
     40} else {
     41    conflicts       ${name}
     42    PortGroup       qt5 1.0
     43    if {[info procs qt5.depends_component] eq ""} {
     44        # A procedure to indicate dependencies on Qt components that are not
     45        # included in the default dependency declared by the Qt5 PortGroup.
     46        # It allows to specify those dependencies without having to handle
     47        # the appropriate path-style declarations that work against every Qt5 port
     48        # (currently port:qt5, port:qt55, "soon" port:qt5-kde too.)
     49        # A complete version of this procedure will be provided by the Qt5 PG
     50        # after qt5-kde is introduced. Provide a simplified version in the meantime.
     51        proc qt5.depends_component {first args} {
     52            # join ${first} and (the optional) ${args}
     53            set args [linsert $args[set list {}] 0 ${first}]
     54            # select the Qt5 port prefix, depending on OS version and which Qt5 port is installed
     55            if {${os.major} == 11} {
     56                set qt5pprefix  "qt55"
     57            } else {
     58                set qt5pprefix  "qt5"
     59            }
     60            foreach comp ${args} {
     61                if {${comp} eq "qt5"} {
     62                    # in case one needs an explicit dependency on the Qt5 main port itself:
     63                    depends_lib-append port:${qt5pprefix}
     64                } else {
     65                    set portname "${qt5pprefix}-${comp}"
     66                    depends_lib-append port:${portname}
     67                }
     68            }
     69        }
     70    }
     71
     72    qt5.depends_component \
     73                    qtsvg
     74}
    3275
    3376depends_build-append port:git \
    3477                    port:doxygen
     
    4487                    port:libxml2 \
    4588                    port:libexif
    4689
    47 configure.args      --enable-gpl \
     90# NB: qt-includedir can and should be set to ${qt_includes_dir},
     91# not ${qt_includes_dir}/Qt !!
     92configure.args-append \
     93                    --enable-gpl \
    4894                    --qt-libdir=${qt_frameworks_dir} \
    49                     --qt-includedir=${qt_includes_dir}/Qt \
     95                    --qt-includedir=${qt_includes_dir} \
    5096                    --disable-jackrack \
    5197                    --disable-mmx \
    5298                    --disable-gtk2 \