aboutsummaryrefslogtreecommitdiffstats
path: root/x11-fonts/ubuntu-font
diff options
context:
space:
mode:
authorkevlo <kevlo@FreeBSD.org>2011-11-10 10:11:42 +0800
committerkevlo <kevlo@FreeBSD.org>2011-11-10 10:11:42 +0800
commitbbdd507bfb7a41d80c0d951172130bcab4b36d6f (patch)
treeeb6bb7b2fadd6146ac58f48062094aa142c5ebf3 /x11-fonts/ubuntu-font
parentb9215be14f3e611923e30c7dc9e484faa7010777 (diff)
downloadfreebsd-ports-gnome-bbdd507bfb7a41d80c0d951172130bcab4b36d6f.tar.gz
freebsd-ports-gnome-bbdd507bfb7a41d80c0d951172130bcab4b36d6f.tar.zst
freebsd-ports-gnome-bbdd507bfb7a41d80c0d951172130bcab4b36d6f.zip
freetype font should depend on fontconfig rather than mkfontdir
Pointed out by: Jan Beich <jbeich at tormail dot net>
Diffstat (limited to 'x11-fonts/ubuntu-font')
-rw-r--r--x11-fonts/ubuntu-font/Makefile25
-rw-r--r--x11-fonts/ubuntu-font/files/pkg-message.in8
-rw-r--r--x11-fonts/ubuntu-font/pkg-plist32
3 files changed, 39 insertions, 26 deletions
diff --git a/x11-fonts/ubuntu-font/Makefile b/x11-fonts/ubuntu-font/Makefile
index 6590a3ff2933..1a24176d3062 100644
--- a/x11-fonts/ubuntu-font/Makefile
+++ b/x11-fonts/ubuntu-font/Makefile
@@ -7,30 +7,31 @@
PORTNAME= ubuntu-font
PORTVERSION= 0.80
+PORTREVISION= 1
CATEGORIES= x11-fonts
MASTER_SITES= http://font.ubuntu.com/download/
DISTNAME= ${PORTNAME}-family-${PORTVERSION}
MAINTAINER= kevloFreeBSD.org
-COMMENT= Ubuntu Font Family
+COMMENT= Ubuntu font family
LICENSE= UFL
LICENSE_FILE= ${WRKSRC}/LICENCE.txt
LICENSE_NAME= Ubuntu Font License (UFL)
LICENSE_PERMS= auto-accept
-BUILD_DEPENDS= mkfontdir:${PORTSDIR}/x11-fonts/mkfontdir \
- mkfontdir:${PORTSDIR}/x11-fonts/mkfontdir
+BUILD_DEPENDS= fc-cache:${PORTSDIR}/x11-fonts/fontconfig
+RUN_DEPENDS= ${BUILD_DEPENDS}
USE_ZIP= yes
+NO_BUILD= yes
-WRKSRC= ${WRKDIR}/${DISTNAME}
+PLIST_SUB= FONTSDIR="${FONTSDIR:S|${PREFIX}/||}"
FONTSDIR= ${PREFIX}/lib/X11/fonts/${PORTNAME}
-
-do-build:
- cd ${WRKSRC} && ${LOCALBASE}/bin/mkfontscale
- cd ${WRKSRC} && ${LOCALBASE}/bin/mkfontdir
+SUB_FILES= pkg-message
+SUB_LIST= FONTSDIR=${FONTSDIR}
+WRKSRC= ${WRKDIR}/${DISTNAME}
do-install:
.if !defined(NOPORTDOCS)
@@ -38,7 +39,11 @@ do-install:
cd ${WRKSRC} && ${INSTALL_DATA} *.txt ${DOCSDIR}
.endif
${MKDIR} ${FONTSDIR}
- cd ${WRKSRC} && \
- ${INSTALL_DATA} fonts.dir fonts.scale *.ttf ${FONTSDIR}
+ cd ${WRKSRC} && ${INSTALL_DATA} *.ttf ${FONTSDIR}
+
+post-install:
+ @${ECHO_MSG} "===> Running fc-cache"
+ -${LOCALBASE}/bin/fc-cache -f -v ${FONTSDIR}
+ @${CAT} ${PKGMESSAGE}
.include <bsd.port.mk>
diff --git a/x11-fonts/ubuntu-font/files/pkg-message.in b/x11-fonts/ubuntu-font/files/pkg-message.in
new file mode 100644
index 000000000000..82f1671ede7a
--- /dev/null
+++ b/x11-fonts/ubuntu-font/files/pkg-message.in
@@ -0,0 +1,8 @@
+Make sure that the freetype module is loaded. If it is not, add the following
+line to the "Modules" section of your X Windows configuration file:
+
+ Load "freetype"
+
+Add the following line to the "Files" section of X Windows configuration file:
+
+ FontPath "%%FONTSDIR%%/"
diff --git a/x11-fonts/ubuntu-font/pkg-plist b/x11-fonts/ubuntu-font/pkg-plist
index 67f0c8921613..5cfc5acf17c0 100644
--- a/x11-fonts/ubuntu-font/pkg-plist
+++ b/x11-fonts/ubuntu-font/pkg-plist
@@ -1,18 +1,16 @@
-lib/X11/fonts/ubuntu-font/Ubuntu-B.ttf
-lib/X11/fonts/ubuntu-font/Ubuntu-BI.ttf
-lib/X11/fonts/ubuntu-font/Ubuntu-C.ttf
-lib/X11/fonts/ubuntu-font/Ubuntu-L.ttf
-lib/X11/fonts/ubuntu-font/Ubuntu-LI.ttf
-lib/X11/fonts/ubuntu-font/Ubuntu-M.ttf
-lib/X11/fonts/ubuntu-font/Ubuntu-MI.ttf
-lib/X11/fonts/ubuntu-font/Ubuntu-R.ttf
-lib/X11/fonts/ubuntu-font/Ubuntu-RI.ttf
-lib/X11/fonts/ubuntu-font/UbuntuMono-B.ttf
-lib/X11/fonts/ubuntu-font/UbuntuMono-BI.ttf
-lib/X11/fonts/ubuntu-font/UbuntuMono-R.ttf
-lib/X11/fonts/ubuntu-font/UbuntuMono-RI.ttf
-lib/X11/fonts/ubuntu-font/fonts.dir
-lib/X11/fonts/ubuntu-font/fonts.scale
+%%FONTSDIR%%/Ubuntu-B.ttf
+%%FONTSDIR%%/Ubuntu-BI.ttf
+%%FONTSDIR%%/Ubuntu-C.ttf
+%%FONTSDIR%%/Ubuntu-L.ttf
+%%FONTSDIR%%/Ubuntu-LI.ttf
+%%FONTSDIR%%/Ubuntu-M.ttf
+%%FONTSDIR%%/Ubuntu-MI.ttf
+%%FONTSDIR%%/Ubuntu-R.ttf
+%%FONTSDIR%%/Ubuntu-RI.ttf
+%%FONTSDIR%%/UbuntuMono-B.ttf
+%%FONTSDIR%%/UbuntuMono-BI.ttf
+%%FONTSDIR%%/UbuntuMono-R.ttf
+%%FONTSDIR%%/UbuntuMono-RI.ttf
%%PORTDOCS%%%%DOCSDIR%%/CONTRIBUTING.txt
%%PORTDOCS%%%%DOCSDIR%%/FONTLOG.txt
%%PORTDOCS%%%%DOCSDIR%%/LICENCE-FAQ.txt
@@ -21,4 +19,6 @@ lib/X11/fonts/ubuntu-font/fonts.scale
%%PORTDOCS%%%%DOCSDIR%%/TRADEMARKS.txt
%%PORTDOCS%%%%DOCSDIR%%/copyright.txt
%%PORTDOCS%%@dirrm %%DOCSDIR%%
-@dirrm lib/X11/fonts/ubuntu-font
+@unexec /bin/rm %D/%%FONTSDIR%%/fonts.cache-1 2>/dev/null || /usr/bin/true
+@dirrm %%FONTSDIR%%
+@exec %%LOCALBASE%%/bin/fc-cache -f -v %D/%%FONTSDIR%% || /usr/bin/true