Ticket #40741: Portfile.2

File Portfile.2, 3.6 KB (added by christophe.pradal@…, 8 years ago)

New Portfile including latest modifications

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: $
3
4PortSystem                      1.0
5
6name                            libPyQGLViewer
7version                         2.3.17   
8platforms                       darwin
9maintainers                     inria.fr:christophe.pradal openmaintainer
10license                         {GPL-2+ Commercial}
11categories                      graphics
12description                     A friendly fork of a C++ library based on Qt that eases the creation of OpenGL \
13                                3D viewers
14homepage                        http://www.libqglviewer.com/
15long_description                libQGLViewer is a C++ library based on Qt that eases the \
16                                creation of OpenGL 3D viewers. It provides some of the typical \
17                                3D viewer functionalities, such as the possibility to move the \
18                                camera using the mouse, which lacks in most of the other APIs. \
19                                Other features include mouse manipulated frames, interpolated \
20                                keyFrames, object selection, stereo display, screenshot saving \
21                                and much more. It can be used by OpenGL beginners as well as \
22                                to create complex applications, being fully customizable and \
23                                easy to extend.  \
24                                It as been forked to allow running sip on it to create Python wrappers.
25
26conflicts                       libQGLViewer
27
28master_sites                    https://gforge.inria.fr/frs/download.php/32979
29
30
31distname                       libPyQGLViewer
32worksrcdir                      ${distname}-${version}
33
34checksums                       rmd160  6451253bd9d6f347d1af73e7a48bc9d2d5cf48db \
35                                sha256  94860a337879f63ad7598192f0d31da1d275af7bff8c910a0c0abd5b902887fb
36
37patchfiles                      patch-QGLViewer.pro.diff \
38                                patch-designerPlugin.pro.diff
39# the terrain example does not compile on Lion; see #30886
40platform darwin 11 {
41    patchfiles-append           patch-contribs.pro.diff
42}
43
44variant universal {}
45
46
47depends_lib-append          port:qt4-x11
48configure.cmd               ${prefix}/libexec/qt4-x11/bin/qmake
49configure.pre_args          PREFIX=${prefix}
50configure.universal_args
51set qt_plugins_dir          ${prefix}/libexec/qt4-x11/plugins/designer
52
53
54post-patch {
55    reinplace "s|@@QT_PLUGINS_DIR@@|${qt_plugins_dir}|g" ${worksrcpath}/designerPlugin/designerPlugin.pro
56   
57    if {[variant_isset universal]} {
58        file copy ${filespath}/universal.sh ${worksrcpath}
59        reinplace "s|@@@WRKSRCPATH@@@|${worksrcpath}|" ${worksrcpath}/universal.sh
60        reinplace "s|@@@ARCHS@@@|${configure.universal_cxxflags}|" ${worksrcpath}/universal.sh
61        system "chmod +x ${worksrcpath}/universal.sh && ${worksrcpath}/universal.sh"
62    }
63}
64
65configure.pre_args-append       DOC_DIR=${prefix}/share/doc/${name}
66configure.post_args-append      -after QMAKE_POST_LINK=\"\"
67
68use_parallel_build              no
69
70post-destroot {
71    system -W ${worksrcpath}/examples "make clean"
72    copy ${worksrcpath}/examples ${destroot}${applications_dir}/libQGLViewer\ Examples
73    xinstall -m 755 -d ${destroot}${prefix}/share/doc/${name}
74    xinstall -m 644 -W ${worksrcpath} \
75        changelog.txt \
76        GPL_exception.txt \
77        licence.txt  \
78        readMe.txt \
79        ${destroot}${prefix}/share/doc/${name}
80}
81
82livecheck.type                  regex
83livecheck.regex                 "Version (\\d+(?:\\.\\d+)*)"