[73143] trunk/dports/aqua/qtpfsgui
michaelld at macports.org
michaelld at macports.org
Fri Nov 5 09:23:41 PDT 2010
Revision: 73143
http://trac.macports.org/changeset/73143
Author: michaelld at macports.org
Date: 2010-11-05 09:23:38 -0700 (Fri, 05 Nov 2010)
Log Message:
-----------
qtpfsgui: better way to handle arch type(s) and release/debug.
Modified Paths:
--------------
trunk/dports/aqua/qtpfsgui/Portfile
trunk/dports/aqua/qtpfsgui/files/patch-project.pro.diff
Modified: trunk/dports/aqua/qtpfsgui/Portfile
===================================================================
--- trunk/dports/aqua/qtpfsgui/Portfile 2010-11-05 15:51:50 UTC (rev 73142)
+++ trunk/dports/aqua/qtpfsgui/Portfile 2010-11-05 16:23:38 UTC (rev 73143)
@@ -26,16 +26,19 @@
patchfiles patch-project.pro.diff
-post-patch {
- # set arch type(s)
- reinplace "s|@ARCHES@|${qt_arch_types}|g" \
- ${worksrcpath}/project.pro
+# set arch type(s); done is a stage to make sure the 'options
+# qt_arch_types' is evaluated -after- +universal (if selected).
+pre-configure {
+ configure.pre_args CONFIG+="${qt_arch_types}"
}
-configure.pre_args PREFIX="${prefix}"
-configure.args APPLICATIONS_DIR="${applications_dir}" \
- DOCDIR="${prefix}/share/doc/${name}"
-configure.cmd "LOCALSOFT=${prefix} ${qt_qmake_cmd}"
+configure.args APPLICATIONS_DIR="${applications_dir}" \
+ DOCDIR="${prefix}/share/doc/${name}" \
+ PREFIX="${prefix}" CONFIG+="release" \
+ LOCALSOFT="${prefix}"
+configure.cmd ${qt_qmake_cmd}
+configure.post_args
+configure.universal_args
# allow ccache, if specified by the user
pre-build {
Modified: trunk/dports/aqua/qtpfsgui/files/patch-project.pro.diff
===================================================================
--- trunk/dports/aqua/qtpfsgui/files/patch-project.pro.diff 2010-11-05 15:51:50 UTC (rev 73142)
+++ trunk/dports/aqua/qtpfsgui/files/patch-project.pro.diff 2010-11-05 16:23:38 UTC (rev 73143)
@@ -1,6 +1,63 @@
---- project.pro.orig 2010-10-18 14:55:56.000000000 -0400
-+++ project.pro 2010-10-18 14:56:39.000000000 -0400
-@@ -315,7 +315,11 @@
+--- project.pro.orig 2010-11-05 12:17:22.000000000 -0400
++++ project.pro 2010-11-05 12:18:44.000000000 -0400
+@@ -1,5 +1,5 @@
+ TEMPLATE = app
+-CONFIG += release qt thread
++CONFIG += qt thread
+ DEFINES += QT_NO_DEBUG_OUTPUT
+
+ # Assume openmp-capable g++ (>=4.2)
+@@ -192,7 +192,7 @@
+ message ( "Detecting exiv2:" )
+ #I think these are the only paths where we have to search for.
+ #If your system is more exotic let me know.
+-EXIV2IMAGEHPP = /usr/include/exiv2/image.hpp /usr/local/include/exiv2/image.hpp $$(LOCALSOFT)/include/exiv2/image.hpp
++EXIV2IMAGEHPP = /usr/include/exiv2/image.hpp /usr/local/include/exiv2/image.hpp $${LOCALSOFT}/include/exiv2/image.hpp
+ for(path, EXIV2IMAGEHPP) {
+ exists($$path) {
+ EXIV2PATH = $$dirname(path)
+@@ -218,7 +218,7 @@
+ message ( "Detecting OpenEXR:" )
+ #I think these are the only paths where we have to search for.
+ #If your system is more exotic let me know.
+-OPENEXRHEADER = /usr/include/OpenEXR/ImfHeader.h /usr/local/include/OpenEXR/ImfHeader.h /usr/local/include/ilmbase/ImfHeader.h /usr/include/ilmbase/ImfHeader.h $$(LOCALSOFT)/include/OpenEXR/ImfHeader.h
++OPENEXRHEADER = /usr/include/OpenEXR/ImfHeader.h /usr/local/include/OpenEXR/ImfHeader.h /usr/local/include/ilmbase/ImfHeader.h /usr/include/ilmbase/ImfHeader.h $${LOCALSOFT}/include/OpenEXR/ImfHeader.h
+ for(path, OPENEXRHEADER) {
+ exists($$path) {
+ OPENEXRDIR = $$dirname(path)
+@@ -244,7 +244,7 @@
+ message ( "Detecting fftw3:" )
+ #I think these are the only paths where we have to search for.
+ #If your system is more exotic let me know.
+-FFTW3HEADER = /usr/include/fftw3.h /usr/local/include/fftw3.h $$(LOCALSOFT)/include/fftw3.h
++FFTW3HEADER = /usr/include/fftw3.h /usr/local/include/fftw3.h $${LOCALSOFT}/include/fftw3.h
+ for(path, FFTW3HEADER) {
+ exists($$path) {
+ FFTW3DIR = $$dirname(path)
+@@ -271,7 +271,7 @@
+ message ( "Detecting libtiff:" )
+ #I think these are the only paths where we have to search for.
+ #If your system is more exotic let me know.
+-LIBTIFFHEADER = /usr/include/tiffio.h /usr/local/include/tiffio.h $$(LOCALSOFT)/include/tiffio.h
++LIBTIFFHEADER = /usr/include/tiffio.h /usr/local/include/tiffio.h $${LOCALSOFT}/include/tiffio.h
+ for(path, LIBTIFFHEADER) {
+ exists($$path) {
+ LIBTIFFDIR = $$dirname(path)
+@@ -295,8 +295,12 @@
+
+ ############################## required by "make install" ########################################
+ isEmpty(PREFIX) {
+- PREFIX = /usr/local
++ error( "PREFIX must be set before executing this script; fatal error, bailing out." )
+ }
++isEmpty(LOCALSOFT) {
++ error( "LOCALSOFT must be set before executing this script; fatal error, bailing out." )
++}
++
+ isEmpty(I18NDIR) {
+ mac {
+ #I18NDIR=(QCoreApplication::applicationDirPath()+\"/i18n\")
+@@ -315,7 +319,11 @@
HTMLDIR = $${DOCDIR}
}
@@ -13,10 +70,12 @@
menu.files = qtpfsgui.desktop
menu.path = $${PREFIX}/share/applications
icon.files = images/qtpfsgui.png
-@@ -367,32 +371,7 @@
+@@ -365,37 +373,8 @@
+ #TODO we have to complete this.
+ LIBS+=-lIlmThread
- # Enable universal (requires a universal Qt)? Default = non-universal
- # If you wish to build a Universal Binary please un-comment the following line
+-# Enable universal (requires a universal Qt)? Default = non-universal
+-# If you wish to build a Universal Binary please un-comment the following line
-#CONFIG += x86 ppc
-
-# Warn user what type of binary is being built and what the possible implications are
@@ -43,7 +102,18 @@
- CONFIG += ppc
- }
-}
-+CONFIG += release @ARCHES@
+-
+ # We like to search the LOCALSOFT/lib explicitly on MacOSX
+-LIBS += -L$$(LOCALSOFT)/lib
++LIBS += -L$${LOCALSOFT}/lib
+ # Libtiff depends on jpeg, but it is not searched for automatically on MacOSX
+ LIBS += -ljpeg
+ # Exiv also depend on libexpat and libiconv, so same as above:
+@@ -418,7 +397,6 @@
- # We like to search the LOCALSOFT/lib explicitly on MacOSX
- LIBS += -L$$(LOCALSOFT)/lib
+ # this is just how my MinGW installation is. You gotta change it if you want to compile it in windows.
+ CONFIG += windows
+-#CONFIG += debug
+ CONFIG += console
+
+ #OpenEXR available in win32
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/macports-changes/attachments/20101105/76c30857/attachment.html>
More information about the macports-changes
mailing list