summaryrefslogtreecommitdiff
path: root/x11-wm
diff options
context:
space:
mode:
authorMarcelo Araujo <araujo@FreeBSD.org>2012-12-20 05:35:39 +0000
committerMarcelo Araujo <araujo@FreeBSD.org>2012-12-20 05:35:39 +0000
commit039bcbeadfd49ad5b7927a2624202aa00a99e2a2 (patch)
tree420ad889efb5ef82faf34f59bb4bf923b6dcc0a6 /x11-wm
parent- Fix build. (diff)
- Add LICENSE.
- Support CFLAGS properly. - Support SUB_FILES. - Support PORTEXAMPLES. - Add MAKE_JOBS_SAFE. - Trim header. - Bump PORTREVISION. PR: ports/172073 Submitted by: KATO Tsuguru <tkato432@yahoo.com>
Notes
Notes: svn path=/head/; revision=309280
Diffstat (limited to 'x11-wm')
-rw-r--r--x11-wm/treewm/Makefile47
-rw-r--r--x11-wm/treewm/files/patch-xprop__xprop.c49
-rw-r--r--x11-wm/treewm/files/pkg-message.in (renamed from x11-wm/treewm/pkg-message)2
3 files changed, 78 insertions, 20 deletions
diff --git a/x11-wm/treewm/Makefile b/x11-wm/treewm/Makefile
index 2aa85bf62c75..258fa9e468f6 100644
--- a/x11-wm/treewm/Makefile
+++ b/x11-wm/treewm/Makefile
@@ -1,46 +1,55 @@
-# New ports collection makefile for: treewm
-# Date created: 09 Sep 2003
-# Whom: Rudolf Polzer
-#
+# Created by: Rudolf Polzer
# $FreeBSD$
-#
PORTNAME= treewm
PORTVERSION= 0.4.5
-PORTREVISION= 5
+PORTREVISION= 6
CATEGORIES= x11-wm
MASTER_SITES= SF
MAINTAINER= ports@FreeBSD.org
COMMENT= Window Manager that arranges the windows in a tree
+LICENSE= GPLv2
+
BUILD_DEPENDS= xmkmf:${PORTSDIR}/devel/imake
+OPTIONS_DEFINE= DOCS EXAMPLES
+
USE_BZIP2= yes
-USE_GMAKE= yes
USE_XORG= x11 ice sm xext xmu xpm xt xxf86vm
+USE_GMAKE= yes
+MAKE_JOBS_SAFE= yes
-PKGMESSAGE= ${WRKDIR}/pkg-message
+SUB_FILES= pkg-message
-PORTDOCS= AUTHORS ChangeLog INSTALL PROBLEMS README README.tiling TODO default.cfg sample.cfg
+PORTDOCS= AUTHORS ChangeLog INSTALL PROBLEMS README README.tiling TODO
+PORTEXAMPLES= default.cfg sample.cfg
-post-patch:
- @${REINPLACE_CMD} -e 's|/usr/local|${PREFIX}|; s|/usr/X11R6|${LOCALBASE}|g' ${WRKSRC}/Makefile
+.include <bsd.port.options.mk>
-post-build:
- @${SED} 's|%%D%%|${DOCSDIR}|g' ${PKGDIR}/pkg-message >${PKGMESSAGE}
+post-patch:
+ @${REINPLACE_CMD} -e \
+ '/^PREFIX/s| =| ?=| ; \
+ /^CXXFLAGS/s| =| ?=| ; \
+ s|/usr/X11R6|${LOCALBASE}|g' ${WRKSRC}/Makefile
do-install:
- ${MKDIR} ${DATADIR}
- ${MKDIR} ${DATADIR}/pixmaps
${INSTALL_PROGRAM} ${WRKSRC}/src/treewm ${PREFIX}/bin
${INSTALL_PROGRAM} ${WRKSRC}/xprop/xprop ${PREFIX}/bin/xprop-treewm
${INSTALL_PROGRAM} ${WRKSRC}/xkill/xkill ${PREFIX}/bin/xkill-treewm
+ ${MKDIR} ${DATADIR}/pixmaps
${INSTALL_DATA} ${WRKSRC}/src/pixmaps/*.xpm ${DATADIR}/pixmaps
-.if !defined(NOPORTDOCS)
- ${MKDIR} ${DOCSDIR}
-.for FILE in ${PORTDOCS}
- ${INSTALL_DATA} ${WRKSRC}/${FILE} ${DOCSDIR}
+.if ${PORT_OPTIONS:MDOCS}
+ @${MKDIR} ${DOCSDIR}
+.for F in ${PORTDOCS}
+ ${INSTALL_DATA} ${WRKSRC}/${F} ${DOCSDIR}
+.endfor
+.endif
+.if ${PORT_OPTIONS:MEXAMPLES}
+ @${MKDIR} ${EXAMPLESDIR}
+.for F in ${PORTEXAMPLES}
+ ${INSTALL_DATA} ${WRKSRC}/${F} ${EXAMPLESDIR}
.endfor
.endif
@${CAT} ${PKGMESSAGE}
diff --git a/x11-wm/treewm/files/patch-xprop__xprop.c b/x11-wm/treewm/files/patch-xprop__xprop.c
new file mode 100644
index 000000000000..488b55ccbec1
--- /dev/null
+++ b/x11-wm/treewm/files/patch-xprop__xprop.c
@@ -0,0 +1,49 @@
+--- xprop/xprop.c.orig 2002-03-14 21:14:47.000000000 +0900
++++ xprop/xprop.c 2012-09-13 15:21:40.000000000 +0900
+@@ -586,7 +586,7 @@
+ {
+ if (--_buf_len<0) {
+ _buf_ptr[0]='\0';
+- return;
++ return 0;
+ }
+ _buf_ptr++[0] = c;
+ }
+@@ -1357,10 +1357,10 @@
+ if (id == None) {
+ fprintf (stderr, "%s: no such property \"%s\"\n",
+ program_name, propname);
+- return;
++ return 0;
+ }
+ XDeleteProperty (dpy, w, id);
+- return;
++ return 0;
+ }
+
+ thunk *Handle_Prop_Requests(argc, argv)
+@@ -1514,13 +1514,13 @@
+ printf("%s", prop);
+ if (!(atom = Parse_Atom(prop, True))) {
+ printf(": no such atom on any window.\n");
+- return;
++ return 0;
+ }
+
+ data = Get_Property_Data_And_Type(atom, &length, &type, &size);
+ if (!size) {
+ puts(": not found.");
+- return;
++ return 0;
+ }
+
+ if (!notype && type)
+@@ -1535,7 +1535,7 @@
+ if (fsize!=size && fsize!=0) {
+ printf(": Type mismatch: assumed size %d bits, actual size %d bits.\n",
+ fsize, size);
+- return;
++ return 0;
+ }
+
+ thunks = Break_Down_Property(data, (int)length, format, size);
diff --git a/x11-wm/treewm/pkg-message b/x11-wm/treewm/files/pkg-message.in
index c3153ca83fd0..148c6d29cfa4 100644
--- a/x11-wm/treewm/pkg-message
+++ b/x11-wm/treewm/files/pkg-message.in
@@ -3,7 +3,7 @@
The treewm package has been successfully installed.
NB: Sample configuration files have been installed to
-%%D%% as "default.cfg" and "sample.cfg".
+%%EXAMPLESDIR%% as "default.cfg" and "sample.cfg".
Users can look at them as well as the README in the same directory to
write their .treewmrc in their homedir. Also, please take a look at