$NetBSD: patch-aa,v 1.3 2008/06/20 01:09:37 joerg Exp $ --- Makefile.in.orig 2004-09-23 21:15:48.000000000 +0000 +++ Makefile.in @@ -213,6 +213,14 @@ MV = @MV@ NROFF = @NROFF@ +INSTALL_PROGRAM = $(BSD_INSTALL_PROGRAM) +INSTALL_MAN = $(BSD_INSTALL_MAN) +INSTALL_SCRIPT = $(BSD_INSTALL_SCRIPT) +INSTALL_DATA = $(BSD_INSTALL_DATA) +INSTALL_PROGRAM_DIR = $(BSD_INSTALL_PROGRAM_DIR) +INSTALL_MAN_DIR = $(BSD_INSTALL_MAN_DIR) +INSTALL_DATA_DIR = $(BSD_INSTALL_DATA_DIR) + # This variable defined to be empty, with the intent that the user can # set it on the make command line at build time to choose fancy # compiler-dependent optimization switches. @@ -388,11 +396,7 @@ TXT-FILES = $(MAN-FILES:.man=.txt) all: programs bibdup.sh: bibdup.sin Makefile - -$(RM) -f $@ - $(SED) -e 's=_LIBDIR_=$(SHRLIBDIR)=g' \ - -e 's=_BINDIR_=$(BINDIR)=g' \ - -e 's=_AWK_=$(AWK)=g' \ - $@ + CONFIG_FILES=$@:bibdup.sin CONFIG_HEADERS= $(SHELL) ./config.status $(CHMOD) 555 $@ biblex: lexmain.c biblex.c args.h bibyydcl.h token.h @@ -560,7 +564,7 @@ dw: html-files: $(HTML-FILES) -install: install-programs install-lib install-man install-show +install: install-programs install-lib install-man install-ftp: dist uninstall-ftp $(CP) bibparse-$(VERSION).jar $(FTPDIR) @@ -576,25 +580,23 @@ install-ftp: dist uninstall-ftp $(LS) -l $(FTPDIR)/bibparse-$(VERSION)* install-lib: uninstall-lib - -$(MKDIR) $(SHRLIBDIR) - $(CP) bibdup.awk $(SHRLIBDIR)/bibdup.awk - $(CHMOD) 664 $(SHRLIBDIR)/bibdup.awk + $(INSTALL_DATA_DIR) ${DESTDIR}$(SHRLIBDIR) + $(INSTALL_DATA) bibdup.awk ${DESTDIR}$(SHRLIBDIR)/bibdup.awk install-man: uninstall-man + $(INSTALL_MAN_DIR) $(MANDIR)/man$(MANEXT) for program in $(BASEPROGS) ; \ do \ - $(CP) $$program.man $(MANDIR)/man$(MANEXT)/$$program.1 ; \ - $(CHMOD) 664 $(MANDIR)/man$(MANEXT)/$$program.1 ; \ + $(INSTALL_MAN) $$program.man ${DESTDIR}$(MANDIR)/man$(MANEXT)/$$program.1 ; \ done install-programs: $(PROGRAMS) bibdup.sh uninstall-programs + $(INSTALL_PROGRAM_DIR) ${DESTDIR}$(BINDIR) for program in $(PROGRAMS) ; \ do \ - $(CP) $$program $(BINDIR)/$$program ; \ - $(CHMOD) 775 $(BINDIR)/$$program ; \ + $(INSTALL_PROGRAM) $$program ${DESTDIR}$(BINDIR)/$$program ; \ done ; \ - $(CP) bibdup.sh $(BINDIR)/bibdup ; \ - $(CHMOD) 775 $(BINDIR)/bibdup + $(INSTALL_SCRIPT) bibdup.sh ${DESTDIR}$(BINDIR)/bibdup install-show: @echo ''