summaryrefslogtreecommitdiff
path: root/biblio/bibtex/utils/lookbibtex/Makefile
blob: f80e34b912969379e0864f0f60b3655dc3f1c538 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69

#
# lookbibtex makefile
# very simple, right?
# Actually, it was simple, once.
#

#
# The following parameters you may wish to change.
#

BINDIR=/usr/dist/bin
BINOWN=johnh
BINMOD=755

MANEXT=1
MANDIR=/usr/dist/share/man/man$(MANEXT)
MANOWN=johnh
MANMOD=644

# perl path in scripts.dist
OLDPERLPATH=/usr/dist/bin/perl
# perl path on your system
NEWPERLPATH=/usr/dist/bin/perl

#
# End of stuff to localize
#



PROGRAMS=lookbibtex bibdestringify


default: $(PROGRAMS)
	@echo "bibtex tools are up-to-date."

lookbibtex: lookbibtex.dist
	sed s:#!$(OLDPERLPATH):#!$(NEWPERLPATH):p <lookbibtex.dist >lookbibtex

bibdestringify: bibdestringify.dist
	sed s:#!$(OLDPERLPATH):#!$(NEWPERLPATH):p <bibdestringify.dist >bibdestringify



# install things in the right place
install:  $(PROGRAMS)
	cp lookbibtex.1 $(MANDIR)/lookbibtex.$(MANEXT)
	chmod $(MANMOD) $(MANDIR)/lookbibtex.$(MANEXT)
	chown $(MANOWN) $(MANDIR)/lookbibtex.$(MANEXT)
	cp bibdestringify.1 $(MANDIR)/bibdestringify.$(MANEXT)
	chmod $(MANMOD) $(MANDIR)/bibdestringify.$(MANEXT)
	chown $(MANOWN) $(MANDIR)/bibdestringify.$(MANEXT)
	cp lookbibtex $(BINDIR)
	chmod $(BINMOD) $(BINDIR)/lookbibtex
	chown $(BINOWN) $(BINDIR)/lookbibtex
	cp bibdestringify $(BINDIR)
	chmod $(BINMOD) $(BINDIR)/bibdestringify
	chown $(BINOWN) $(BINDIR)/bibdestringify


# package up a shar for distribution
shar:
	shar README lookbibtex.1 lookbibtex.dist \
		bibdestringify.1 bibdestringify.dist release \
		Makefile>lookbibtex.`cat release`.shar
	compress <lookbibtex.`cat release`.shar >lookbibtex.`cat release`.shar.Z