From owner-freebsd-ports Sat Sep 2 13:20:16 2000 Delivered-To: freebsd-ports@freebsd.org Received: from freefall.freebsd.org (freefall.FreeBSD.org [216.136.204.21]) by hub.freebsd.org (Postfix) with ESMTP id AC27C37B43C for ; Sat, 2 Sep 2000 13:20:01 -0700 (PDT) Received: (from gnats@localhost) by freefall.freebsd.org (8.9.3/8.9.2) id NAA69657; Sat, 2 Sep 2000 13:20:01 -0700 (PDT) (envelope-from gnats@FreeBSD.org) Received: from vega.uli.it (vega.uli.it [62.212.0.2]) by hub.freebsd.org (Postfix) with ESMTP id E9F1C37B422 for ; Sat, 2 Sep 2000 13:15:06 -0700 (PDT) Received: from olgeni.uli.it (olgeni.uli.it [62.212.0.22]) by vega.uli.it (Postfix) with ESMTP id 1C1CF3B00F; Sat, 2 Sep 2000 22:15:04 +0200 (CEST) Message-Id: Date: Sat, 2 Sep 2000 22:15:19 +0200 (CEST) From: Jimmy Olgeni To: FreeBSD-gnats-submit@freebsd.org Cc: rip@pinetec.co.za Subject: ports/20998: [PATCH] Enhancements for Xfstt port Sender: owner-freebsd-ports@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org >Number: 20998 >Category: ports >Synopsis: [PATCH] Enhancements for Xfstt port >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-ports >State: open >Quarter: >Keywords: >Date-Required: >Class: change-request >Submitter-Id: current-users >Arrival-Date: Sat Sep 02 13:20:01 PDT 2000 >Closed-Date: >Last-Modified: >Originator: Jimmy Olgeni >Release: FreeBSD 4.1-STABLE i386 >Organization: Colby >Environment: Current Xfstt port (version 1.1) >Description: Changes ======= Makefile: post-install target: * Install a startup file in PREFIX/etc/rc.d/xfstt.sh: it runs xfstt --sync before starting the font server with xfstt --daemon. At shutdown time, it will kill xfstt with them killall command. This could be renamed to xfstt.sh.sample if an automatic startup is not recommended for security reasons. * Create the PREFIX/lib/X11/fonts/TrueType font directory. * ${CAT} ${PKGMESSAGE} at the end of install. files/xfstt.sh: New file, provides startup/shutdown functionality. pkg/PLIST: Add etc/rc.d/xfstt.sh to the list. Create the lib/X11/fonts/TrueType at install time, and try to remove it when the package is uninstalled. The ttinfo.dir and ttname.dir are removed, since they will be automatically created at the next install/startup of the same package (by xfstt --sync). Does not complain if it's not able to remove the font directory. pkg/MESSAGE: New file. Tell the user where to put the TrueType font files. Display a reminder about "xfstt --sync" to update the database. >How-To-Repeat: >Fix: diff -rcN Xfstt.orig/Makefile Xfstt/Makefile *** Xfstt.orig/Makefile Wed Jun 14 19:57:50 2000 --- Xfstt/Makefile Sat Sep 2 19:17:13 2000 *************** *** 22,27 **** --- 22,31 ---- post-install: strip $(PREFIX)/bin/xfstt + ${SED} -e "/%%PREFIX%%/s##${PREFIX}#g" ${FILESDIR}/xfstt.sh \ + > ${PREFIX}/etc/rc.d/xfstt.sh + ${CHMOD} 755 ${PREFIX}/etc/rc.d/xfstt.sh + $(MKDIR) $(PREFIX)/lib/X11/fonts/TrueType .if !defined(NOPORTDOCS) $(MKDIR) $(PREFIX)/share/doc/xfstt $(INSTALL_DATA) $(WRKSRC)/FAQ $(PREFIX)/share/doc/xfstt *************** *** 29,33 **** --- 33,40 ---- $(INSTALL_DATA) $(WRKSRC)/INSTALL $(PREFIX)/share/doc/xfstt $(INSTALL_DATA) $(WRKSRC)/THANKS.txt $(PREFIX)/share/doc/xfstt .endif + @${ECHO} + @${CAT} ${PKGMESSAGE} + @${ECHO} .include diff -rcN Xfstt.orig/files/xfstt.sh Xfstt/files/xfstt.sh *** Xfstt.orig/files/xfstt.sh Thu Jan 1 01:00:00 1970 --- Xfstt/files/xfstt.sh Sat Sep 2 16:54:11 2000 *************** *** 0 **** --- 1,18 ---- + #!/bin/sh + + PREFIX=%%PREFIX%% + + case "$1" in + + start) + ${PREFIX}/bin/xfstt --sync >/dev/null + ${PREFIX}/bin/xfstt --daemon && echo -n ' xfstt' + ;; + stop) + /usr/bin/killall xfstt 2>/dev/null && echo -n ' xfstt' + ;; + *) + echo "$0 start | stop" + ;; + + esac diff -rcN Xfstt.orig/pkg/MESSAGE Xfstt/pkg/MESSAGE *** Xfstt.orig/pkg/MESSAGE Thu Jan 1 01:00:00 1970 --- Xfstt/pkg/MESSAGE Sat Sep 2 19:11:45 2000 *************** *** 0 **** --- 1,6 ---- + You will have to install your TrueType fonts in + + PREFIX/lib/X11/fonts/TrueType + + Remember to run the "xfstt --sync" command if you + add fonts while the font server is running. diff -rcN Xfstt.orig/pkg/PLIST Xfstt/pkg/PLIST *** Xfstt.orig/pkg/PLIST Thu Dec 24 07:36:08 1998 --- Xfstt/pkg/PLIST Sat Sep 2 19:11:40 2000 *************** *** 1,6 **** --- 1,11 ---- bin/xfstt + etc/rc.d/xfstt.sh share/doc/xfstt/FAQ share/doc/xfstt/CHANGES share/doc/xfstt/INSTALL share/doc/xfstt/THANKS.txt @dirrm share/doc/xfstt + @exec mkdir -p %D/lib/X11/fonts/TrueType + @unexec rmdir %D/lib/X11/fonts/TrueType 2>/dev/null || true + @unexec rm -f %D/lib/X11/fonts/TrueType/ttname.dir + @unexec rm -f %D/lib/X11/fonts/TrueType/ttinfo.dir >Release-Note: >Audit-Trail: >Unformatted: To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-ports" in the body of the message