[89265] trunk/dports/x11/Xaw3d

jeremyhu at macports.org jeremyhu at macports.org
Sun Jan 22 12:06:14 PST 2012


Revision: 89265
          http://trac.macports.org/changeset/89265
Author:   jeremyhu at macports.org
Date:     2012-01-22 12:06:11 -0800 (Sun, 22 Jan 2012)
Log Message:
-----------
Xaw3d: Bump to version 1.6

One less reason to have imake around.

Modified Paths:
--------------
    trunk/dports/x11/Xaw3d/Portfile

Added Paths:
-----------
    trunk/dports/x11/Xaw3d/files/
    trunk/dports/x11/Xaw3d/files/0001-Include-stdlib.h-for-abs.patch
    trunk/dports/x11/Xaw3d/files/0002-Cleanup-shadow-declarations.patch

Modified: trunk/dports/x11/Xaw3d/Portfile
===================================================================
--- trunk/dports/x11/Xaw3d/Portfile	2012-01-22 19:48:30 UTC (rev 89264)
+++ trunk/dports/x11/Xaw3d/Portfile	2012-01-22 20:06:11 UTC (rev 89265)
@@ -1,69 +1,41 @@
 # $Id$
 
-PortSystem              1.0
+PortSystem 1.0
 
-name                    Xaw3d
-version                 1.5E
-# The revision was increased to 5 in r73602 then reverted to 4 in r73629.
-# If you increase the revision again, skip 5 and go to 6, and remove this comment.
-revision                4
-categories              x11
-license                 X11
-maintainers             nomaintainer
+name            Xaw3d
+version         1.6
+categories      x11 devel
+license         X11
+maintainers     jeremyhu openmaintainer
+description     Athena Widgets toolkit library with 3-D styled widgets
+homepage        http://www.x.org
+platforms       darwin macosx
+long_description ${description}
+master_sites     xorg:individual/lib/
 
-description \
-    The Three-D Athena Toolkit
+distname    libXaw3d-${version}
+checksums           sha1    b10489c3cc9dde46bd13294ee971b1a782e0a4be \
+                    rmd160  afebb1802dfa9d485d60b39f9165ceb4ff8204e1 \
+                    sha256  1122082f2b3c484557c6147768300c356453918bf401e2e6c86fee12ade93325
 
-long_description \
-    This release of Xaw3d is based on X.Org's X11R6.3 Athena \
-    toolkit, with bits and pieces thrown in from other sources. \
-    It is intended to be a general-purpose replacement for the \
-    Athena (Xaw) toolkit. In general, you should be able to link \
-    almost any Athena-based application to this Xaw3d Athena \
-    toolkit, for a three-dimensional appearance on most of the \
-    widgets. On systems with shared libraries, you might be able \
-    replace your shared libXaw.* with libXaw3d.* to obtain the \
-    appearance without even relinking, but the odds of this \
-    working is slim, and not recommended.
+use_bzip2   yes
+use_parallel_build      yes
 
-homepage                http://www.visi.com/~hawkeyd/xaw3d.html
-platforms               darwin
-master_sites            freebsd \
-                        ftp://ftp.visi.com/users/hawkeyd/X/
-checksums               md5 29ecfdcd6bcf47f62ecfd672d31269a1 \
-                        sha1 efc5b923feda52866c859c59a5b553cb675a69d1 \
-                        rmd160 086cbabaa45ce5c110815aea24eebcbb54613118
+depends_build   port:pkgconfig
 
-depends_lib \
-	port:xorg-libsm \
-	port:xorg-libXext \
-	port:xorg-libXmu \
-	port:xorg-libXp \
-	port:xpm \
-	port:xorg-libXt
+depends_lib     port:xorg-libXext \
+                port:xorg-libXmu \
+                port:xpm \
+                port:xorg-libXt
 
-worksrcdir              xc/lib/${name}
+patchfiles      0001-Include-stdlib.h-for-abs.patch \
+                0002-Cleanup-shadow-declarations.patch
 
-patch {
-    reinplace "s|XCOMM EXTRA_INCLUDES|EXTRA_INCLUDES|" "${worksrcpath}/Imakefile"
-    file mkdir ${worksrcpath}/X11
-    system "ln -fs .. ${worksrcpath}/X11/Xaw3d"
-}
-use_xmkmf               yes
+patch.pre_args  -p1
 
-use_parallel_build      yes
+configure.args \
+        --enable-internationalization
 
-# This uses xmkmf to build and doesn't make a universal lib
-universal_variant	no
-
-# The Imakefile default is to install everything into /usr/X11R6/lib,
-# which prevents multiple MacPorts installs on the same system.  Have
-# it install the entire package into ${prefix} instead.
-build.target-append     INCDIR=${prefix}/include \
-                        SHLIBDIR=${prefix}/lib \
-                        USRLIBDIR=${prefix}/lib \
-                        INCROOT=${prefix}/include
-
-destroot.destdir-append INCDIR=${prefix}/include \
-                        SHLIBDIR=${prefix}/lib \
-                        USRLIBDIR=${prefix}/lib
+livecheck.type  regex
+livecheck.url   http://xorg.freedesktop.org/archive/individual/lib/?C=M&O=D
+livecheck.regex libXaw3d-(\\d+(?:\\.\\d+)*)

Added: trunk/dports/x11/Xaw3d/files/0001-Include-stdlib.h-for-abs.patch
===================================================================
--- trunk/dports/x11/Xaw3d/files/0001-Include-stdlib.h-for-abs.patch	                        (rev 0)
+++ trunk/dports/x11/Xaw3d/files/0001-Include-stdlib.h-for-abs.patch	2012-01-22 20:06:11 UTC (rev 89265)
@@ -0,0 +1,31 @@
+From d31153b30abd26c3f65e19d126ce4a3542cf14c0 Mon Sep 17 00:00:00 2001
+From: Jeremy Huddleston <jeremyhu at apple.com>
+Date: Sun, 22 Jan 2012 11:55:29 -0800
+Subject: [PATCH 1/2] Include <stdlib.h> for abs()
+
+Tip.c:336:9: error: implicit declaration of function 'abs' is invalid in C99 [-Werror,-Wimplicit-function-declaration]
+        ksy += abs(ext->max_ink_extent.y);
+               ^
+1 error generated.
+
+Signed-off-by: Jeremy Huddleston <jeremyhu at apple.com>
+---
+ src/Tip.c |    2 ++
+ 1 files changed, 2 insertions(+), 0 deletions(-)
+
+diff --git a/src/Tip.c b/src/Tip.c
+index 6881670..5f54d14 100644
+--- a/src/Tip.c
++++ b/src/Tip.c
+@@ -43,6 +43,8 @@
+ #include <X11/Xaw3d/TipP.h>
+ #include <X11/Xaw3d/XawInit.h>
+ 
++#include <stdlib.h>
++
+ #define	TIP_EVENT_MASK (ButtonPressMask	  |	\
+ 			ButtonReleaseMask |	\
+ 			PointerMotionMask |	\
+-- 
+1.7.7.4
+

Added: trunk/dports/x11/Xaw3d/files/0002-Cleanup-shadow-declarations.patch
===================================================================
--- trunk/dports/x11/Xaw3d/files/0002-Cleanup-shadow-declarations.patch	                        (rev 0)
+++ trunk/dports/x11/Xaw3d/files/0002-Cleanup-shadow-declarations.patch	2012-01-22 20:06:11 UTC (rev 89265)
@@ -0,0 +1,125 @@
+From 702e4ff9f5fbfae4aecba09f8c735dc97bac1b59 Mon Sep 17 00:00:00 2001
+From: Jeremy Huddleston <jeremyhu at apple.com>
+Date: Sun, 22 Jan 2012 11:58:09 -0800
+Subject: [PATCH 2/2] Cleanup shadow declarations
+
+Box.c:265:10: warning: declaration shadows a local variable [-Wshadow]
+            int i = bbw->composite.num_children;
+                ^
+Box.c:166:15: note: previous declaration is here
+    Cardinal  i;
+              ^
+1 warning generated.
+
+Form.c:809:9: warning: declaration shadows a local variable [-Wshadow]
+        Widget w = *childP;
+               ^
+Form.c:793:24: note: previous declaration is here
+XawFormDoLayout(Widget w,
+                       ^
+1 warning generated.
+
+Viewport.c:627:24: warning: declaration shadows a local variable [-Wshadow]
+                    if (!needshoriz) CheckHoriz();
+                                     ^
+Viewport.c:605:14: note: expanded from macro 'CheckHoriz'
+                    Widget bar = w->viewport.horiz_bar;                 \
+                           ^
+Viewport.c:620:14: note: previous declaration is here
+                    Widget bar = w->viewport.vert_bar;
+                           ^
+1 warning generated.
+
+Signed-off-by: Jeremy Huddleston <jeremyhu at apple.com>
+---
+ src/Box.c      |    4 ++--
+ src/Form.c     |    6 +++---
+ src/Viewport.c |   20 ++++++++++----------
+ 3 files changed, 15 insertions(+), 15 deletions(-)
+
+diff --git a/src/Box.c b/src/Box.c
+index ccd52fd..43be5dc 100644
+--- a/src/Box.c
++++ b/src/Box.c
+@@ -262,9 +262,9 @@ DoLayout(BoxWidget bbw, Dimension width, Dimension height,
+ 	if (bbw->composite.num_children == num_mapped_children)
+ 	    XMapSubwindows( XtDisplay((Widget)bbw), XtWindow((Widget)bbw) );
+ 	else {
+-	    int i = bbw->composite.num_children;
++	    int j = bbw->composite.num_children;
+ 	    Widget *childP = bbw->composite.children;
+-	    for (; i > 0; childP++, i--)
++	    for (; j > 0; childP++, j--)
+ 		if (XtIsRealized(*childP) && XtIsManaged(*childP) &&
+ 		    (*childP)->core.mapped_when_managed)
+ 		    XtMapWidget(*childP);
+diff --git a/src/Form.c b/src/Form.c
+index 49fceb6..f078270 100644
+--- a/src/Form.c
++++ b/src/Form.c
+@@ -790,7 +790,7 @@ PreferredGeometry(Widget widget, XtWidgetGeometry *request, XtWidgetGeometry *re
+  */
+ 
+ void
+-XawFormDoLayout(Widget w,
++XawFormDoLayout(Widget _fw,
+ #if NeedWidePrototypes
+ 		int doit)
+ #else
+@@ -798,11 +798,11 @@ XawFormDoLayout(Widget w,
+ #endif
+ {
+     Widget *childP;
+-    FormWidget fw = (FormWidget)w;
++    FormWidget fw = (FormWidget)_fw;
+     int num_children = fw->composite.num_children;
+     WidgetList children = fw->composite.children;
+ 
+-    if ( ((fw->form.no_refigure = !doit) == TRUE) || !XtIsRealized(w) )
++    if ( ((fw->form.no_refigure = !doit) == TRUE) || !XtIsRealized(_fw) )
+ 	return;
+ 
+     for (childP = children; childP - children < num_children; childP++) {
+diff --git a/src/Viewport.c b/src/Viewport.c
+index abb8961..a37a9a1 100644
+--- a/src/Viewport.c
++++ b/src/Viewport.c
+@@ -602,12 +602,12 @@ ComputeLayout(Widget widget, Boolean query, Boolean destroy_scrollbars)
+ 	    if (w->viewport.allowhoriz &&				\
+ 		    (int)preferred.width > clip_width + 2 * sw) {	\
+ 		if (!needshoriz) {					\
+-		    Widget bar = w->viewport.horiz_bar;			\
++		    Widget horiz_bar = w->viewport.horiz_bar;		\
+ 		    needshoriz = True;					\
+-		    if (bar == (Widget)NULL)				\
+-			bar = CreateScrollbar(w, True);			\
+-		    clip_height -= bar->core.height +			\
+-				   bar->core.border_width + pad;	\
++		    if (horiz_bar == (Widget)NULL)			\
++			horiz_bar = CreateScrollbar(w, True);		\
++		    clip_height -= horiz_bar->core.height +		\
++				   horiz_bar->core.border_width + pad;	\
+ 		    if (clip_height < 1) clip_height = 1;		\
+ 		}							\
+ 		intended.width = preferred.width;			\
+@@ -617,12 +617,12 @@ ComputeLayout(Widget widget, Boolean query, Boolean destroy_scrollbars)
+ 	    if (w->viewport.allowvert &&
+ 		    (int)preferred.height > clip_height + 2 * sw) {
+ 		if (!needsvert) {
+-		    Widget bar = w->viewport.vert_bar;
++		    Widget vert_bar = w->viewport.vert_bar;
+ 		    needsvert = True;
+-		    if (bar == (Widget)NULL)
+-			bar = CreateScrollbar(w, False);
+-		    clip_width -= bar->core.width +
+-				  bar->core.border_width + pad;
++		    if (vert_bar == (Widget)NULL)
++			vert_bar = CreateScrollbar(w, False);
++		    clip_width -= vert_bar->core.width +
++				  vert_bar->core.border_width + pad;
+ 		    if (clip_width < 1) clip_width = 1;
+ 		    if (!needshoriz) CheckHoriz();
+ 		}
+-- 
+1.7.7.4
+
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/macports-changes/attachments/20120122/3efdb2bb/attachment.html>


More information about the macports-changes mailing list