1 | # $Id: Portfile 25915 2007-06-05 18:05:15Z blair@macports.org $ |
---|
2 | PortSystem 1.0 |
---|
3 | |
---|
4 | name qt3-mac |
---|
5 | version 3.3.8 |
---|
6 | categories aqua |
---|
7 | maintainers blair |
---|
8 | description Qt Tool Kit (Native Aqua Version) |
---|
9 | long_description This is Qt, TrollTech's C++ toolkit for writing \ |
---|
10 | cross-platform GUI applications. |
---|
11 | homepage http://www.trolltech.com/ |
---|
12 | master_sites ftp://ftp.trolltech.com/qt/source/ \ |
---|
13 | http://ftp.silug.org/mirrors/ftp.trolltech.com/qt/source/ \ |
---|
14 | macports:blair |
---|
15 | distname qt-mac-free-${version} |
---|
16 | checksums md5 dc8013ea4e5b54849f1ed5eedf6b03a3 \ |
---|
17 | sha1 b4835adbf5afc15042ce25270e684df395fe897c \ |
---|
18 | rmd160 dd2bfc62488e2d0dd500df4899aeaf28738bd8b0 |
---|
19 | platforms darwin |
---|
20 | |
---|
21 | depends_lib port:zlib port:libpng port:libmng |
---|
22 | |
---|
23 | variant mysql4 { |
---|
24 | depends_lib-append port:mysql4 |
---|
25 | configure.args-delete -no-sql-mysql |
---|
26 | configure.args-append -qt-sql-mysql \ |
---|
27 | -L${prefix}/lib/mysql \ |
---|
28 | -I${prefix}/include/mysql \ |
---|
29 | -plugin-sql-mysql |
---|
30 | } |
---|
31 | |
---|
32 | variant mysql5 { |
---|
33 | depends_lib-append port:mysql5 |
---|
34 | configure.args-delete -no-sql-mysql |
---|
35 | configure.args-append -qt-sql-mysql \ |
---|
36 | -L${prefix}/lib/mysql5/mysql \ |
---|
37 | -I${prefix}/include/mysql5/mysql \ |
---|
38 | -plugin-sql-mysql |
---|
39 | } |
---|
40 | |
---|
41 | variant ipv6 { |
---|
42 | configure.args-delete -no-ipv6 |
---|
43 | configure.args-append -ipv6 |
---|
44 | } |
---|
45 | |
---|
46 | configure.cmd "echo yes | ./configure" |
---|
47 | configure.args -v -prefix '${prefix}' \ |
---|
48 | -docdir '${prefix}/share/doc/${name}/html' \ |
---|
49 | -datadir '${prefix}/share/qt3' \ |
---|
50 | -headerdir '${prefix}/include/qt3' \ |
---|
51 | -plugindir '${prefix}/lib/qt3-plugins' \ |
---|
52 | -release -shared -fast -thread -stl \ |
---|
53 | -qt-gif -qt-imgfmt-png -qt-imgfmt-jpeg -qt-imgfmt-mng \ |
---|
54 | -no-sql-ibase -no-sql-mysql -no-sql-odbc -no-sql-psql \ |
---|
55 | -no-sql-sqlite -no-nis -no-cups -no-ipv6 \ |
---|
56 | -largefile \ |
---|
57 | -system-zlib -system-libpng -system-libjpeg \ |
---|
58 | -system-libmng \ |
---|
59 | '-I${prefix}/include' '-L${prefix}/lib' |
---|
60 | |
---|
61 | build.env DYLD_LIBRARY_PATH="${worksrcpath}/lib" |
---|
62 | build.target symlinks src-qmake src-moc sub-src sub-tools |
---|
63 | |
---|
64 | destroot.destdir INSTALL_ROOT='${destroot}' |
---|
65 | post-destroot { |
---|
66 | system "ranlib -s ${destroot}${prefix}/lib/libdesignercore.a" |
---|
67 | system "ranlib -s ${destroot}${prefix}/lib/libeditor.a" |
---|
68 | system "ranlib -s ${destroot}${prefix}/lib/libqassistantclient.a" |
---|
69 | } |
---|
70 | |
---|
71 | platform darwin { |
---|
72 | patchfiles patch-src-qt_install.pri \ |
---|
73 | patch-mkspecs-qmake.conf |
---|
74 | post-destroot { |
---|
75 | system "sh ${filespath}/fix_install_names.sh '${prefix}' '${destroot}'" |
---|
76 | set appPath ${destroot}/Applications/MacPorts/Qt3 |
---|
77 | xinstall -d -m 0755 ${appPath} |
---|
78 | foreach app {assistant designer linguist qtconfig} { |
---|
79 | system "mv -v ${destroot}${prefix}/bin/${app}.app \ |
---|
80 | ${appPath}/${app}.app" |
---|
81 | } |
---|
82 | if {![file exists ${destroot}${prefix}/lib/libqt.dylib]} { |
---|
83 | set majorver [strsed ${version} {s/\.[0-9]*\.[0-9]*$//}] |
---|
84 | set minorver [strsed ${version} {s/\.[0-9]*$//}] |
---|
85 | cd ${destroot}${prefix}/lib |
---|
86 | system "ln -s libqt-mt.${version}.dylib libqt.dylib" |
---|
87 | system "ln -s libqt-mt.${version}.dylib libqt.${majorver}.dylib" |
---|
88 | system "ln -s libqt-mt.${version}.dylib libqt.${minorver}.dylib" |
---|
89 | } |
---|
90 | } |
---|
91 | } |
---|