From 8112d2aaa845022fc0b694f87cb0759231e3c812 Mon Sep 17 00:00:00 2001 From: Mario Sergio Fujikawa Ferreira <lioux@FreeBSD.org> Date: Fri, 23 Mar 2001 03:05:35 +0000 Subject: o Make it CFLAGS safe o Fix info installation o Fix PLIST PR: 25841 Submitted by: MAINTAINER Spotted by: bento --- lang/gforth/Makefile | 85 +++++++++++++++++++++++++++++++++++++++++++++++---- lang/gforth/pkg-plist | 34 ++------------------- 2 files changed, 82 insertions(+), 37 deletions(-) (limited to 'lang/gforth') diff --git a/lang/gforth/Makefile b/lang/gforth/Makefile index 0c2975ba6747..17d951238248 100644 --- a/lang/gforth/Makefile +++ b/lang/gforth/Makefile @@ -13,17 +13,90 @@ MASTER_SITE_SUBDIR= gforth MAINTAINER= clefevre@poboxes.com -CFLAGS= #none +# +# Global variables +# + STRIP= #none GNU_CONFIGURE= yes +USE_GMAKE= yes +ALL_TARGET= all info + +.if make(do-install) +# DESTDIR isn't honored. fake it w/ prefix. +MAKE_ARGS= prefix=${PREFIX} +.endif MAN1= gforth.1 -post-install: - @install-info ${PREFIX}/info/gforth.info ${PREFIX}/info/dir -.if !exists(${PREFIX}/share/emacs/site-lisp/gforth.el) - @${INSTALL_DATA} ${WRKSRC}/gforth.el ${PREFIX}/share/emacs/site-lisp -.endif +# +# Local variables +# + +INSTALL_INFO?= install-info + +INFO_FILES= ${PORTNAME}.info +INFO_DIR= ${PREFIX}/info + +EMACS_FILES= gforth.el +EMACS_DIR= ${PREFIX}/share/emacs/site-lisp + +SHARE_DIR= ${PREFIX}/share/${PORTNAME} + +EMPTY_FILES= siteinit.fs +FORTH_DIR= ${SHARE_DIR}/site-forth + +EMPTY_DIRS= 4stack 6502 8086 avr c165 generic h8 \ + hppa ia64 m68k misc power shboom sparc +ARCH_DIR= ${SHARE_DIR}/${PORTVERSION}/arch + +# +# Post-extract +# + +post-extract: remove-info-files + +remove-info-files: +.for file in ${INFO_FILES} + @${RM} -f ${WRKSRC}/doc/${file}* +.endfor + +# +# Post-patch +# + +post-patch: patch-makefiles + +patch-makefiles: + @${PERL} -pi.fbsd -e 's|makeinfo|makeinfo --no-split|g' \ + ${WRKSRC}/Makefile.in + +# +# Post-install +# + +post-install: install-info install-el \ + remove-empty-files remove-empty-dirs + +install-info: +.for file in ${INFO_FILES} + @${INSTALL_INFO} ${INFO_DIR}/${file} ${INFO_DIR}/dir +.endfor + +install-el: +.for file in ${EMACS_FILES} + @${INSTALL_DATA} ${WRKSRC}/${file} ${EMACS_DIR}/${file} +.endfor + +remove-empty-files: +.for file in ${EMPTY_FILES} + @${RM} -f ${FORTH_DIR}/${file} +.endfor + +remove-empty-dirs: +.for dir in ${EMPTY_DIRS} + @${RMDIR} ${ARCH_DIR}/${dir} +.endfor .include <bsd.port.mk> diff --git a/lang/gforth/pkg-plist b/lang/gforth/pkg-plist index 7a3118dcfaed..00090fc6ef46 100644 --- a/lang/gforth/pkg-plist +++ b/lang/gforth/pkg-plist @@ -1,3 +1,4 @@ +@comment $FreeBSD$ bin/gforth-0.5.0 @exec ln -fs %f %B/gforth @unexec rm -f %B/gforth @@ -9,23 +10,10 @@ bin/gforthmi-0.5.0 @unexec rm -f %B/gforthmi @unexec install-info --delete %D/info/gforth.info %D/info/dir info/gforth.info -info/gforth.info-1 -info/gforth.info-10 -info/gforth.info-11 -info/gforth.info-12 -info/gforth.info-13 -info/gforth.info-14 -info/gforth.info-2 -info/gforth.info-3 -info/gforth.info-4 -info/gforth.info-5 -info/gforth.info-6 -info/gforth.info-7 -info/gforth.info-8 -info/gforth.info-9 @exec install-info %D/info/gforth.info %D/info/dir lib/gforth/0.5.0/gforth-ditc lib/gforth/0.5.0/gforth.fi +@exec mkdir -p %D/lib/gforth/site-forth share/emacs/site-lisp/gforth.el share/gforth/0.5.0/TAGS share/gforth/0.5.0/add.fs @@ -179,7 +167,7 @@ share/gforth/0.5.0/vt100.fs share/gforth/0.5.0/vt100key.fs share/gforth/0.5.0/wordinfo.fs share/gforth/0.5.0/wordsets.fs -share/gforth/site-forth/siteinit.fs +@exec mkdir -p %D/share/gforth/site-forth @dirrm share/gforth/site-forth @dirrm share/gforth/0.5.0/test @dirrm share/gforth/0.5.0/kernel @@ -187,28 +175,12 @@ share/gforth/site-forth/siteinit.fs @dirrm share/gforth/0.5.0/doc @dirrm share/gforth/0.5.0/compat @dirrm share/gforth/0.5.0/asm -@dirrm share/gforth/0.5.0/arch/sparc -@dirrm share/gforth/0.5.0/arch/shboom -@dirrm share/gforth/0.5.0/arch/power -@dirrm share/gforth/0.5.0/arch/misc @dirrm share/gforth/0.5.0/arch/mips -@dirrm share/gforth/0.5.0/arch/m68k -@dirrm share/gforth/0.5.0/arch/ia64 -@dirrm share/gforth/0.5.0/arch/hppa -@dirrm share/gforth/0.5.0/arch/h8 -@dirrm share/gforth/0.5.0/arch/generic -@dirrm share/gforth/0.5.0/arch/c165 -@dirrm share/gforth/0.5.0/arch/avr @dirrm share/gforth/0.5.0/arch/alpha -@dirrm share/gforth/0.5.0/arch/8086 -@dirrm share/gforth/0.5.0/arch/6502 -@dirrm share/gforth/0.5.0/arch/4stack @dirrm share/gforth/0.5.0/arch/386 @dirrm share/gforth/0.5.0/arch @dirrm share/gforth/0.5.0 @dirrm share/gforth -@unexec rmdir %D/share/emacs/site-lisp 2>/dev/null || true -@unexec rmdir %D/share/emacs 2>/dev/null || true @dirrm lib/gforth/site-forth @dirrm lib/gforth/0.5.0 @dirrm lib/gforth -- cgit v1.2.3