[110541] users/mojca/wxports/graphics
mojca at macports.org
mojca at macports.org
Sun Sep 1 14:23:33 PDT 2013
Revision: 110541
https://trac.macports.org/changeset/110541
Author: mojca at macports.org
Date: 2013-09-01 14:23:32 -0700 (Sun, 01 Sep 2013)
Log Message:
-----------
mojca/wxWidgets-2.8/3.0: hopefully fix wx-config symlink, fix 'dangling else' in 2.9, use port:pkgconfig, remove URL from trac
Modified Paths:
--------------
users/mojca/wxports/graphics/wxWidgets-2.8/Portfile
users/mojca/wxports/graphics/wxWidgets-3.0/Portfile
Added Paths:
-----------
users/mojca/wxports/graphics/wxWidgets-3.0/files/patch-Makefile.in.294.patch
users/mojca/wxports/graphics/wxWidgets-3.0/files/patch-Makefile.in.295.patch
users/mojca/wxports/graphics/wxWidgets-3.0/files/patch-include-wx-log.h.diff
Modified: users/mojca/wxports/graphics/wxWidgets-2.8/Portfile
===================================================================
--- users/mojca/wxports/graphics/wxWidgets-2.8/Portfile 2013-09-01 21:05:20 UTC (rev 110540)
+++ users/mojca/wxports/graphics/wxWidgets-2.8/Portfile 2013-09-01 21:23:32 UTC (rev 110541)
@@ -31,13 +31,12 @@
homepage http://www.wxwidgets.org/
distname wxWidgets
master_sites sourceforge:project/wxwindows/${version} \
- http://biolpc22.york.ac.uk/pub/${version}/ \
- http://trac.macports.org/raw-attachment/ticket/19190/:trac
+ http://biolpc22.york.ac.uk/pub/${version}/
use_bzip2 yes
distfiles ${distname}-${version}${extract.suffix} \
- ${wxpythonsubset}${extract.suffix}:trac
+ ${wxpythonsubset}${extract.suffix}
dist_subdir ${distname}/${version}
checksums ${distname}-${version}${extract.suffix} \
@@ -119,7 +118,7 @@
# wxgtk-2.8 (it doesn't work with Quartz)
if {$subport != $name} {
- depends_build-append path:bin/pkg-config:pkgconfig
+ depends_build-append port:pkgconfig
depends_lib-append path:lib/pkgconfig/cairo.pc:cairo \
port:gtk2 \
port:mesa \
@@ -158,10 +157,6 @@
xinstall -m 644 -W ${workpath}/${distname}-${version} \
install-mac.txt readme-mac.txt \
install-gtk.txt readme-gtk.txt ${destdocdir}
-
- # maybe not needed
- set confscript ${wxWidgets.prefix}/lib/wx/config/${wxtype}-unicode-${installtype}-${branch}
- ln -sf ${confscript} ${destroot}${wxWidgets.prefix}/bin/wx-config
}
variant aui description {add support for AUI docking library} {
Modified: users/mojca/wxports/graphics/wxWidgets-3.0/Portfile
===================================================================
--- users/mojca/wxports/graphics/wxWidgets-3.0/Portfile 2013-09-01 21:05:20 UTC (rev 110540)
+++ users/mojca/wxports/graphics/wxWidgets-3.0/Portfile 2013-09-01 21:23:32 UTC (rev 110541)
@@ -44,8 +44,7 @@
homepage http://www.wxwidgets.org/
distname wxWidgets
master_sites sourceforge:project/wxwindows/${version} \
- http://biolpc22.york.ac.uk/pub/${version}/ \
- http://trac.macports.org/raw-attachment/ticket/19190/:trac
+ http://biolpc22.york.ac.uk/pub/${version}/
use_bzip2 yes
@@ -71,9 +70,13 @@
patch.dir ${worksrcpath}/..
-# without (the second part of) this patch wxrc-2.9 ends up linking to libraries in workdir
-# http://trac.wxwidgets.org/ticket/15452
-patchfiles-append patch-configure.diff
+# without (the second part of) patch-configure.diff wxrc-2.9 ends up linking to libraries in workdir
+# patch-configure.diff: http://trac.wxwidgets.org/ticket/15452
+# patch-include-wx-log.h.diff: http://trac.wxwidgets.org/ticket/11829
+# patch-Makefile.in.295.diff: http://trac.wxwidgets.org/ticket/15463
+patchfiles-append patch-configure.diff \
+ patch-include-wx-log.h.diff \
+ patch-Makefile.in.295.diff
post-patch {
reinplace "s|@@PREFIX@@|${prefix}|g" ${patch.dir}/configure
@@ -99,12 +102,14 @@
if {$subport == "wxPython-3.0"} {
set wxpythonsubset wxPython-2.9.4.0-MacPorts-subset
- distfiles-append ${wxpythonsubset}${extract.suffix}:trac
+ distfiles-append ${wxpythonsubset}${extract.suffix}
# patch-src-osx-cocoa-window.mm.diff: http://trac.wxwidgets.org/changeset/72195 (only needed for 2.9.4)
# patch-include-wx-math.h.diff: http://trac.wxwidgets.org/changeset/74456 (only needed for 2.9.4)
patchfiles-append patch-src-osx-cocoa-window.mm.diff \
patch-include-wx-math.h.diff
+ patchfiles-replace patch-Makefile.in.295.diff \
+ patch-Makefile.in.294.diff
description wxWidgets ${branch} for the wxPython distribution
long_description The port installs wxWidgets ${branch} for wxPython \
@@ -134,7 +139,7 @@
patchfiles-append patch-sdl.diff \
patch-upstream-psn.diff
- depends_build-append path:bin/pkg-config:pkgconfig
+ depends_build-append port:pkgconfig
depends_lib-append path:lib/pkgconfig/cairo.pc:cairo \
path:lib/pkgconfig/sdl.pc:libsdl \
port:libsdl_mixer
@@ -183,8 +188,8 @@
}
post-destroot {
- set confscript ${wxWidgets.prefix}/lib/wx/config/${wxtype}-unicode-${branch}
- ln -sf ${confscript} ${destroot}${wxWidgets.prefix}/bin/wx-config
+ # otherwise 'port select --set wxWidgets wxWidgets-3.0' doesn't work
+ # it would be nice to fix that at some other level
xinstall -m 755 -d ${destroot}${prefix}/share/bakefile/presets
}
Added: users/mojca/wxports/graphics/wxWidgets-3.0/files/patch-Makefile.in.294.patch
===================================================================
--- users/mojca/wxports/graphics/wxWidgets-3.0/files/patch-Makefile.in.294.patch (rev 0)
+++ users/mojca/wxports/graphics/wxWidgets-3.0/files/patch-Makefile.in.294.patch 2013-09-01 21:23:32 UTC (rev 110541)
@@ -0,0 +1,12 @@
+http://trac.wxwidgets.org/ticket/15463
+--- Makefile.in.orig
++++ Makefile.in
+@@ -15662,7 +15662,7 @@ install-wxconfig:
+ $(INSTALL_DIR) $(DESTDIR)$(bindir)
+ $(INSTALL_DIR) $(DESTDIR)$(libdir)/wx/config
+ $(INSTALL_PROGRAM) lib/wx/config/$(TOOLCHAIN_FULLNAME) $(DESTDIR)$(libdir)/wx/config
+- (cd $(DESTDIR)$(bindir) && rm -f wx-config && $(LN_S) $(DESTDIR)$(libdir)/wx/config/$(TOOLCHAIN_FULLNAME) wx-config)
++ (cd $(DESTDIR)$(bindir) && rm -f wx-config && $(LN_S) $(libdir)/wx/config/$(TOOLCHAIN_FULLNAME) wx-config)
+
+ locale_install:
+ $(INSTALL_DIR) $(DESTDIR)$(datadir)/locale
Added: users/mojca/wxports/graphics/wxWidgets-3.0/files/patch-Makefile.in.295.patch
===================================================================
--- users/mojca/wxports/graphics/wxWidgets-3.0/files/patch-Makefile.in.295.patch (rev 0)
+++ users/mojca/wxports/graphics/wxWidgets-3.0/files/patch-Makefile.in.295.patch 2013-09-01 21:23:32 UTC (rev 110541)
@@ -0,0 +1,12 @@
+http://trac.wxwidgets.org/ticket/15463
+--- Makefile.in.orig
++++ Makefile.in
+@@ -16098,7 +16098,7 @@ install-wxconfig:
+ $(INSTALL_DIR) $(DESTDIR)$(bindir)
+ $(INSTALL_DIR) $(DESTDIR)$(libdir)/wx/config
+ $(INSTALL_PROGRAM) lib/wx/config/$(TOOLCHAIN_FULLNAME) $(DESTDIR)$(libdir)/wx/config
+- (cd $(DESTDIR)$(bindir) && rm -f wx-config && $(LN_S) ../`basename $(libdir)`/wx/config/$(TOOLCHAIN_FULLNAME) wx-config)
++ (cd $(DESTDIR)$(bindir) && rm -f wx-config && $(LN_S) $(libdir)/wx/config/$(TOOLCHAIN_FULLNAME) wx-config)
+
+ locale_install:
+ $(INSTALL_DIR) $(DESTDIR)$(datadir)/locale
Added: users/mojca/wxports/graphics/wxWidgets-3.0/files/patch-include-wx-log.h.diff
===================================================================
--- users/mojca/wxports/graphics/wxWidgets-3.0/files/patch-include-wx-log.h.diff (rev 0)
+++ users/mojca/wxports/graphics/wxWidgets-3.0/files/patch-include-wx-log.h.diff 2013-09-01 21:23:32 UTC (rev 110541)
@@ -0,0 +1,48 @@
+Upstream: http://trac.wxwidgets.org/changeset/74735
+--- include/wx/log.h (revision 74602)
++++ include/wx/log.h (revision 74735)
+@@ -14,4 +14,5 @@
+
+ #include "wx/defs.h"
++#include "wx/cpp.h"
+
+ // ----------------------------------------------------------------------------
+@@ -1331,5 +1332,8 @@
+ // unnecessary overhead)
+ //
+-// Note: the strange if/else construct is needed to make the following code
++// Note: the strange (because executing at most once) for() loop because we
++// must arrange for wxDO_LOG() to be at the end of the macro and using a
++// more natural "if (IsLevelEnabled()) wxDO_LOG()" would result in wrong
++// behaviour for the following code ("else" would bind to the wrong "if"):
+ //
+ // if ( cond )
+@@ -1338,19 +1342,14 @@
+ // ...
+ //
+-// work as expected, without it the second "else" would match the "if"
+-// inside wxLogError(). Unfortunately code like
+-//
+-// if ( cond )
+-// wxLogError("!!!");
+-//
+-// now provokes "suggest explicit braces to avoid ambiguous 'else'"
+-// warnings from g++ 4.3 and later with -Wparentheses on but they can be
+-// easily fixed by adding curly braces around wxLogError() and at least
+-// the code still does do the right thing.
++// See also #11829 for the problems with other simpler approaches,
++// notably the need for two macros due to buggy __LINE__ in MSVC.
++#define wxDO_LOG_IF_ENABLED_HELPER(level, loopvar) \
++ for ( bool loopvar = false; \
++ !loopvar && wxLog::IsLevelEnabled(wxLOG_##level, wxLOG_COMPONENT); \
++ loopvar = true ) \
++ wxDO_LOG(level)
++
+ #define wxDO_LOG_IF_ENABLED(level) \
+- if ( !wxLog::IsLevelEnabled(wxLOG_##level, wxLOG_COMPONENT) ) \
+- {} \
+- else \
+- wxDO_LOG(level)
++ wxDO_LOG_IF_ENABLED_HELPER(level, wxMAKE_UNIQUE_NAME(wxlogcheck))
+
+ // wxLogFatalError() is special as it can't be disabled
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/macports-changes/attachments/20130901/e35a5150/attachment.html>
More information about the macports-changes
mailing list