File: Makefile.in

package info (click to toggle)
barcode 0.98%2Bdebian-9
  • links: PTS
  • area: main
  • in suites: squeeze, wheezy
  • size: 1,000 kB
  • ctags: 396
  • sloc: ansic: 3,329; perl: 1,676; python: 535; makefile: 205; sh: 152; awk: 79; sed: 5
file content (135 lines) | stat: -rw-r--r-- 3,499 bytes parent folder | download | duplicates (9)
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
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
#
# Makefile (now .in) for the documentation directory
#
# Copyright 1994,2000   rubini@gnu.org (Alessandro Rubini)
#
#################
#
# BE CAREFUL in editing:
#	due to the large number of index files, and my use of a non standard
#	info input file, any file $(TARGET).* is removed by "make clean"
#
#	I chose to use a prefix for the input file ("doc.$(TARGET)"), to ease
#	makeing clean and applying my own rules.
#
###################################################################
#
# First of all, retrieve features of makeinfo, to know if we can do images
# and --html. Also, allow MAKEINFO to be specified on the commandline to
# allow me testing with various versions.

# NOTE: it looks like semi-old versions can do images too, so CANDOIMAGES
#	is not (yet?) used


MAKEINFO = @MAKEINFO@
# According to whether this makeinfo can output html, autoconf define these
REMOVEHTMLTAGS = @REMOVEHTMLTAGS@
INFOTOHTML = @INFOTOHTML@

##############################################


TARGET = barcode
ALL    = $(TARGET).ps $(TARGET).info $(TARGET)doc.txt $(TARGET).html \
		$(TARGET).pdf 

all: $(ALL) terse

info: $(TARGET).info

$(TARGET)doc.txt: mktxt

mpage: all
	mv $(TARGET).ps $(TARGET)1.ps
	mpage -2A $(TARGET)1.ps > $(TARGET)2.ps && rm $(TARGET)1.ps

terse:
	# preserve the pdf copy
	-mv -f $(TARGET).pdf PDF 2> /dev/null && \
		rm -f *~ *.dvi *.log *.aux \
		      $(TARGET).*.bak $(TARGET).??? $(TARGET).texinfo && \
		mv PDF $(TARGET).pdf;

	# preserve the ps copy
	-mv $(TARGET).ps PS;
	-rm -f $(TARGET).??;
	-mv PS $(TARGET).ps;

clean: terse
	rm -f $(ALL) $(TARGET)_toc.html


####################################################

# These rules used to be expressed as "%.texinfo: doc.%" etc. However, this
# is gmake-specific, so I turned every % to $(TARGET), thus loosing generality
# but gaining portability. I also had to drop "$^": it worked with gmake
# and not pmake, while "$<" worked with pmake and not gmake.
# with gmake and not pmake.
#    ARub 2000-04-21

$(TARGET).texinfo: doc.$(TARGET)
	@rm -f $@ 2> /dev/null
	sed -f ./infofilter doc.$(TARGET) | $(REMOVEHTMLTAGS) > $@
	chmod 400 $@


# This rule is somewhat a rewrite of texi2dvi. I like make more than sh :-)
# This had to be rewritten too, as "$*" is different in gmake and pmake

$(TARGET).dvi: $(TARGET).texinfo

# create a spurious  index file to please silly sh (bash will work anyway)
	touch $(TARGET).oo

# get the index list
	if test "x`ls $(TARGET).?? $(TARGET).aux`" != "x"; then \
	  for i in `ls $(TARGET).?? $(TARGET).aux`; do \
	    cp $$i $$i~; \
	  done; \
	fi
	tex $(TARGET).texinfo

#check the file list, the file and if needed run TeX again
	old="`ls $(TARGET).??~ $(TARGET).aux~ | sed 's/~//g'`"; \
	new="`ls $(TARGET).?? $(TARGET).aux`"; \
	need="n"; \
	if test "$$old" != "$$new"; then need="y"; \
	else \
	  for i in  `ls $(TARGET).?? $(TARGET).aux`; do \
	    cmp -s $$i $$i~; if test $$? -ne 0; then need="y" break; fi; \
	  done; \
	fi; \
	if test "$$need" = "y"; then \
	  texindex $(TARGET).?? && tex $(TARGET).texinfo; \
	fi


$(TARGET).ps: $(TARGET).dvi
	dvips -f $(TARGET).dvi > $@

$(TARGET).pdf: $(TARGET).ps
	ps2pdf $(TARGET).ps > $@

$(TARGET).lj: $(TARGET).dvi
	dvilj -e- $(TARGET).dvi > $@

$(TARGET).info: $(TARGET).texinfo
	makeinfo $(TARGET).texinfo -o $@

$(TARGET).html: $(TARGET).texinfo
	$(INFOTOHTML) -o $@ $<

#$(TARGET).man: doc.$(TARGET)
#		manpages are created by the toplevel Makefile

$(TARGET)doc.txt: $(TARGET).info
	awk -f ./mktxt $(TARGET).info > $@