2001-03-14 10:04:11 -05:00
|
|
|
$OpenBSD: patch-Makefile,v 1.1 2001/03/14 15:04:11 naddy Exp $
|
|
|
|
--- Makefile.orig Wed Dec 16 13:34:09 1998
|
|
|
|
+++ Makefile Wed Mar 14 15:55:55 2001
|
1999-01-04 00:28:48 -05:00
|
|
|
@@ -5,10 +5,10 @@
|
2001-03-14 10:04:11 -05:00
|
|
|
# @(#)$Id: patch-Makefile,v 1.1 2001/03/14 15:04:11 naddy Exp $
|
1999-01-04 00:28:48 -05:00
|
|
|
#
|
|
|
|
|
|
|
|
-PREFIX?=/usr/local
|
|
|
|
BINDIR=$(PREFIX)/bin
|
|
|
|
-ETCDIR=$(PREFIX)/etc
|
|
|
|
MANDIR=$(PREFIX)/man
|
2001-03-14 10:04:11 -05:00
|
|
|
+SAMPLEDIR=$(PREFIX)/share/examples/tosha
|
|
|
|
+ETCDIR=$(SYSCONFDIR)
|
1999-01-04 00:28:48 -05:00
|
|
|
|
|
|
|
###################################################
|
|
|
|
###### ######
|
2001-03-14 10:04:11 -05:00
|
|
|
@@ -16,17 +16,7 @@ MANDIR=$(PREFIX)/man
|
1999-01-04 00:28:48 -05:00
|
|
|
###### ######
|
|
|
|
###################################################
|
|
|
|
|
|
|
|
-CFLAGS?=-O2
|
2001-03-14 10:04:11 -05:00
|
|
|
-CFLAGS+=-Wall -ansi -DGLOBAL_ETC_DIR=\"$(ETCDIR)\"
|
|
|
|
-
|
1999-01-04 00:28:48 -05:00
|
|
|
-.if (exists(/usr/include/camlib.h))
|
|
|
|
-CFLAGS+=-DCAM
|
|
|
|
-LDFLAGS=-lcam
|
|
|
|
-.else
|
|
|
|
-LDFLAGS=-lscsi
|
|
|
|
-.endif
|
|
|
|
-
|
|
|
|
-GZIP_CMD?=gzip -9
|
2001-03-14 10:04:11 -05:00
|
|
|
+CFLAGS+= -DGLOBAL_ETC_DIR=\"$(ETCDIR)\"
|
|
|
|
|
1999-01-04 00:28:48 -05:00
|
|
|
BINS=tosha pcmplay pcmfade
|
|
|
|
OBJS=utils.o getlopt.o tosha.o toscsi.o toform.o toconf.o pcmplay.o pcmfade.o
|
2001-03-14 10:04:11 -05:00
|
|
|
@@ -43,25 +33,22 @@ pcmplay.o: pcmplay.c utils.h getlopt.h
|
1999-01-04 00:28:48 -05:00
|
|
|
pcmfade.o: pcmfade.c utils.h
|
|
|
|
|
|
|
|
tosha: tosha.o toscsi.o toform.o toconf.o utils.o getlopt.o
|
|
|
|
- $(CC) $(CFLAGS) -o tosha \
|
|
|
|
- tosha.o toscsi.o toform.o toconf.o utils.o getlopt.o $(LDFLAGS)
|
|
|
|
+ $(CC) $(CFLAGS) -o tosha tosha.o toscsi.o toform.o toconf.o \
|
|
|
|
+ utils.o getlopt.o -lutil -lossaudio
|
|
|
|
|
|
|
|
pcmplay: pcmplay.o utils.o getlopt.o
|
|
|
|
- $(CC) $(CFLAGS) -o pcmplay pcmplay.o utils.o getlopt.o
|
|
|
|
+ $(CC) $(CFLAGS) -o pcmplay pcmplay.o utils.o getlopt.o -lossaudio
|
|
|
|
|
|
|
|
pcmfade: pcmfade.o utils.o
|
|
|
|
$(CC) $(CFLAGS) -o pcmfade pcmfade.o utils.o
|
|
|
|
|
|
|
|
install: $(BINS)
|
|
|
|
strip $(BINS)
|
|
|
|
- install -s -g bin -o bin -m 755 $(BINS) $(BINDIR)
|
|
|
|
- install -c -g bin -o bin -m 644 tosharc $(ETCDIR)
|
|
|
|
- install -c -g bin -o bin -m 644 tosha.1 pcmplay.1 pcmfade.1 \
|
|
|
|
+ install -s -o root -g bin -m 755 $(BINS) $(BINDIR)
|
2001-03-14 10:04:11 -05:00
|
|
|
+ install -d -o root -g wheel -m 755 $(SAMPLEDIR)
|
|
|
|
+ install -c -o root -g wheel -m 644 tosharc $(SAMPLEDIR)/tosharc.sample
|
1999-01-04 00:28:48 -05:00
|
|
|
+ install -c -o root -g wheel -m 644 tosha.1 pcmplay.1 pcmfade.1 \
|
|
|
|
$(MANDIR)/man1
|
|
|
|
-.if !defined(NOMANCOMPRESS)
|
|
|
|
- cd $(MANDIR)/man1 ; \
|
|
|
|
- $(GZIP_CMD) tosha.1 pcmplay.1 pcmfade.1
|
|
|
|
-.endif
|
|
|
|
|
|
|
|
clean:
|
|
|
|
rm -f $(OBJS) *core $(BINS)
|