aboutsummaryrefslogtreecommitdiff
path: root/x11-wm/mcwm
diff options
context:
space:
mode:
authorChris Rees <crees@FreeBSD.org>2011-12-28 16:42:05 +0000
committerChris Rees <crees@FreeBSD.org>2011-12-28 16:42:05 +0000
commit8a479e3267d29c0c2a213e63d57d5f8b1ae15279 (patch)
treea9dd1fcf3138b2ee0fa8451f099a1af087b95d62 /x11-wm/mcwm
parent64d0df4091d788ab6f8715dc820e554e03fa241d (diff)
downloadports-8a479e3267d29c0c2a213e63d57d5f8b1ae15279.tar.gz
ports-8a479e3267d29c0c2a213e63d57d5f8b1ae15279.zip
- Fix build with gcc46
- Tidy install code; use do-install instead of patching Makefile PR: ports/163667 Submitted by: Jakub Lach <jakub_lach@mailplus.pl> (maintainer)
Notes
Notes: svn path=/head/; revision=288194
Diffstat (limited to 'x11-wm/mcwm')
-rw-r--r--x11-wm/mcwm/Makefile9
-rw-r--r--x11-wm/mcwm/files/patch-Makefile40
2 files changed, 22 insertions, 27 deletions
diff --git a/x11-wm/mcwm/Makefile b/x11-wm/mcwm/Makefile
index ae7f4d7af6d1..e3f6b963c48d 100644
--- a/x11-wm/mcwm/Makefile
+++ b/x11-wm/mcwm/Makefile
@@ -38,6 +38,15 @@ post-extract:
@${CP} ${MCWM_CONF} ${WRKSRC}/config.h
.endif
+post-patch:
+ @${REINPLACE_CMD} -e 's,/usr/local,${LOCALBASE},g' \
+ ${WRKSRC}/Makefile
+
+do-install:
+ ${INSTALL_PROGRAM} ${WRKSRC}/${PORTNAME} ${PREFIX}/bin/
+ ${INSTALL_MAN} ${WRKSRC}/${PORTNAME}.man \
+ ${MAN1PREFIX}/man/man1/${PORTNAME}.1
+
post-install:
.if !defined(NOPORTDOCS)
@${ECHO_MSG} "installing additional documentation to ${DOCSDIR}"
diff --git a/x11-wm/mcwm/files/patch-Makefile b/x11-wm/mcwm/files/patch-Makefile
index a1e5b3ade62b..3401fa110efd 100644
--- a/x11-wm/mcwm/files/patch-Makefile
+++ b/x11-wm/mcwm/files/patch-Makefile
@@ -1,6 +1,13 @@
---- Makefile.orig 2011-07-23 09:36:24.000000000 +0200
-+++ Makefile 2011-07-23 17:19:30.000000000 +0200
-@@ -3,13 +3,12 @@ DIST=mcwm-$(VERSION)
+$FreeBSD$
+
+Stops clobbering CC, CFLAGS, LDFLAGS, forcing -O2 and adds
+-lxcb-property to LDFLAGS to fix GCC46 build
+
+http://www.freebsd.org/cgi/query-pr.cgi?pr=ports/163667
+
+--- Makefile.orig 2011-12-28 14:56:20.865676731 +0000
++++ Makefile 2011-12-28 14:58:52.600677341 +0000
+@@ -3,13 +3,11 @@
SRC=mcwm.c list.c config.h events.h list.h
DISTFILES=LICENSE Makefile NEWS README TODO WISHLIST mcwm.man $(SRC)
@@ -8,33 +15,12 @@
-CFLAGS=-g -std=c99 -Wall -Wextra -O2 -I/usr/local/include #-DDEBUG #-DDMALLOC
-LDFLAGS=-L/usr/local/lib -lxcb -lxcb-randr -lxcb-keysyms -lxcb-icccm \
- -lxcb-atom #-ldmalloc
-+CFLAGS+=-g -std=c99 -Wall -Wextra -I${LOCALBASE}/include
-+LDFLAGS+=-L${LOCALBASE}/lib -lxcb -lxcb-randr -lxcb-keysyms -lxcb-icccm \
-+ -lxcb-atom
++CFLAGS+=-g -std=c99 -Wall -Wextra -I/usr/local/include #-DDEBUG #-DDMALLOC
++LDFLAGS+=-L/usr/local/lib -lxcb -lxcb-randr -lxcb-keysyms -lxcb-icccm \
++ -lxcb-atom -lxcb-property #-ldmalloc
RM=/bin/rm
-PREFIX=/usr/local
-+PREFIX?=/usr/local
TARGETS=mcwm
OBJS=mcwm.o list.o
-@@ -28,13 +27,14 @@ mcwm.o: mcwm.c events.h list.h config.h
- list.o: list.c list.h Makefile
-
- install: $(TARGETS)
-- install -m 755 mcwm $(PREFIX)/bin
-- install -m 644 mcwm.man $(PREFIX)/man/man1/mcwm.1
-+ install -m 755 mcwm ${DESTDIR}$(PREFIX)/bin
-+ @echo installing manual page to ${DESTDIR}${MANPREFIX}/man/man1
-+ @mkdir -p ${DESTDIR}${MANPREFIX}/man/man1
-+ install -m 644 mcwm.man ${DESTDIR}$(MANPREFIX)/man/man1/mcwm.1
-
- deinstall:
-- $(RM) $(PREFIX)/bin/mcwm
-- $(RM) $(PREFIX)/man/man1/mcwm.1
--
-+ $(RM) ${DESTDIR}$(PREFIX)/bin/mcwm
-+
- $(DIST).tar.bz2:
- mkdir $(DIST)
- cp $(DISTFILES) $(DIST)/