freebsd-ports/print/foo2zjs/files/patch-Makefile
Jose Alonso Cardenas Marquez ba037f0eac - Update to 20061004
Reported by:	bsam
2006-10-08 22:35:59 +00:00

66 lines
1.5 KiB
Text

--- Makefile Fri Sep 29 23:28:51 2006
+++ Makefile Sun Oct 8 17:29:53 2006
@@ -6,8 +6,7 @@
VERSION=0.0
# Installation prefix...
-PREFIX=/usr/local
-PREFIX=/usr
+PREFIX?=
# Pathnames for this package...
BIN=$(PREFIX)/bin
@@ -18,7 +17,7 @@
DOCDIR=$(PREFIX)/share/doc/foo2zjs/
# Pathnames for referenced packages...
-FOODB=/usr/share/foomatic/db/source
+FOODB=$(PREFIX)/share/foomatic/db/source
# User ID's
LPuid=-olp
@@ -154,7 +153,7 @@
endif
# Compiler flags
-CFLAGS += -O2 -Wall
+CFLAGS?=
#
# Rules to create test documents
@@ -291,7 +290,7 @@
# Installation rules
#
install: all install-test install-prog install-icc2ps install-extra \
- install-crd install-foo install-ppd install-man install-doc
+ install-crd install-ppd
#
# If you use CUPS, then restart the spooler:
# make cups
@@ -349,8 +348,10 @@
#
# Install current database files
#
+ mkdir -p $(FOODB)
@if [ -d $(FOODB) ]; then \
for dir in driver printer opt; do \
+ install -d $(FOODB)/$$dir/; \
echo install -m 644 foomatic-db/$$dir/*.xml $(FOODB)/$$dir/; \
install -c -m 644 foomatic-db/$$dir/*.xml $(FOODB)/$$dir/; \
done \
@@ -435,12 +436,13 @@
fi; \
done
-MODEL=/usr/share/cups/model
-LOCALMODEL=/usr/local/share/cups/model
+MODEL=$(PREFIX)/share/cups/model
+LOCALMODEL=$(PREFIX)/share/cups/model
install-ppd:
#
# Install PPD files for CUPS
#
+ mkdir -p $(MODEL)
if [ -d /usr/share/ppd/ ]; then \
find /usr/share/ppd/ -name '*foo2zjs*' | xargs rm -f; \
find /usr/share/ppd/ -name '*foo2hp*' | xargs rm -f; \