aboutsummaryrefslogtreecommitdiffstats
path: root/x11/dmenu
diff options
context:
space:
mode:
authormakc <makc@FreeBSD.org>2010-05-16 18:16:21 +0800
committermakc <makc@FreeBSD.org>2010-05-16 18:16:21 +0800
commit738e09b4e10d27c1848fe279b301f4a9f47c7103 (patch)
treeb191f4275df4d2e92fe8859bb94f3954c007949e /x11/dmenu
parent3ff23de3b29662c451f75611fb7aa185022b68a8 (diff)
downloadfreebsd-ports-gnome-738e09b4e10d27c1848fe279b301f4a9f47c7103.tar.gz
freebsd-ports-gnome-738e09b4e10d27c1848fe279b301f4a9f47c7103.tar.zst
freebsd-ports-gnome-738e09b4e10d27c1848fe279b301f4a9f47c7103.zip
Add optional support for Xft.
PR: ports/143951 Submitted by: Ashish SHUKLA <wahjava at gmail.com> Reviewed by: maintainer
Diffstat (limited to 'x11/dmenu')
-rw-r--r--x11/dmenu/Makefile18
-rw-r--r--x11/dmenu/distinfo3
-rw-r--r--x11/dmenu/files/patch-config.mk37
3 files changed, 28 insertions, 30 deletions
diff --git a/x11/dmenu/Makefile b/x11/dmenu/Makefile
index 6eda25e16120..f60339f3e876 100644
--- a/x11/dmenu/Makefile
+++ b/x11/dmenu/Makefile
@@ -7,16 +7,34 @@
PORTNAME= dmenu
PORTVERSION= 4.0
+PORTREVISION= 1
CATEGORIES= x11
MASTER_SITES= http://code.suckless.org/dl/tools/ \
http://schot.a-eskwadraat.nl/files/
+PATCH_SITES= http://schot.a-eskwadraat.nl/files/
MAINTAINER= schot@a-eskwadraat.nl
COMMENT= X11 menu application (not only) for the dwm window manager
+OPTIONS= XFT "XFT support" On
+
USE_XORG= x11 xinerama
MAN1= dmenu.1
PLIST_FILES= bin/dmenu bin/dmenu_path bin/dmenu_run
+.include <bsd.port.options.mk>
+
+.if defined(WITH_XFT)
+PATCHFILES+= ${PORTNAME}-${PORTVERSION}-xft.diff
+PATCH_DIST_STRIP= -p1
+USE_XORG+= xft
+.endif
+
+post-patch:
+ @${GREP} -Rl '%%[[:alpha:]]\+%%' ${WRKSRC}|${XARGS} ${REINPLACE_CMD} \
+ -e "s,%%PREFIX%%,${PREFIX},g" \
+ -e "s,%%LOCALBASE%%,${LOCALBASE},g" \
+ -e "s,%%MANPREFIX%%,${MANPREFIX}/man,g"
+
.include <bsd.port.mk>
diff --git a/x11/dmenu/distinfo b/x11/dmenu/distinfo
index fafcea7dfdcc..8cd8f4a522e4 100644
--- a/x11/dmenu/distinfo
+++ b/x11/dmenu/distinfo
@@ -1,3 +1,6 @@
MD5 (dmenu-4.0.tar.gz) = 66e761a653930cc8a21614ba9fedf903
SHA256 (dmenu-4.0.tar.gz) = c04508285e21a1fc055b76890ec47e9956d8edc4d460dbcac59f96f061b2e862
SIZE (dmenu-4.0.tar.gz) = 8576
+MD5 (dmenu-4.0-xft.diff) = e259bf32b4ff15d345581f934ba99e46
+SHA256 (dmenu-4.0-xft.diff) = d7bbc1883453ef2d1025111fec48831f453c586007349a13ba2ab4b54177fd15
+SIZE (dmenu-4.0-xft.diff) = 8596
diff --git a/x11/dmenu/files/patch-config.mk b/x11/dmenu/files/patch-config.mk
index bc134b12d3e4..f6cb7ea2f2eb 100644
--- a/x11/dmenu/files/patch-config.mk
+++ b/x11/dmenu/files/patch-config.mk
@@ -1,36 +1,13 @@
---- config.mk.orig 2009-04-18 13:50:04.000000000 +0200
-+++ config.mk 2009-04-21 13:15:36.000000000 +0200
-@@ -4,11 +4,11 @@
+--- ./config.mk.orig 2010-04-04 18:37:12.000000000 +0530
++++ ./config.mk 2010-04-04 18:37:36.000000000 +0530
+@@ -4,8 +4,8 @@
# Customize below to fit your system
# paths
-PREFIX = /usr/local
-MANPREFIX = ${PREFIX}/share/man
-+PREFIX?= /usr/local
-+MANPREFIX = ${PREFIX}/man
++PREFIX = %%PREFIX%%
++MANPREFIX = %%MANPREFIX%%
--X11INC = /usr/X11R6/include
--X11LIB = /usr/X11R6/lib
-+X11INC = $(LOCALBASE)/include
-+X11LIB = $(LOCALBASE)/lib
-
- # Xinerama, comment if you don't want it
- XINERAMALIBS = -L${X11LIB} -lXinerama
-@@ -19,13 +19,13 @@
- LIBS = -L/usr/lib -lc -L${X11LIB} -lX11 ${XINERAMALIBS}
-
- # flags
--CPPFLAGS = -D_BSD_SOURCE -DVERSION=\"${VERSION}\" ${XINERAMAFLAGS}
--CFLAGS = -std=c99 -pedantic -Wall -Os ${INCS} ${CPPFLAGS}
--LDFLAGS = -s ${LIBS}
-+CPPFLAGS+= -D_BSD_SOURCE -DVERSION=\"${VERSION}\" ${XINERAMAFLAGS}
-+CFLAGS+= -std=c99 ${INCS} ${CPPFLAGS}
-+LDFLAGS+= ${LIBS}
-
- # Solaris
- #CFLAGS = -fast ${INCS} -DVERSION=\"${VERSION}\"
- #LDFLAGS = ${LIBS}
-
- # compiler and linker
--CC = cc
-+CC?= cc
+ X11INC = /usr/X11R6/include
+ X11LIB = /usr/X11R6/lib