forked from unihedron/spectrum
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile.in
118 lines (96 loc) · 3.45 KB
/
Makefile.in
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
VERSION=@PACKAGE_VERSION@
NAME=@PACKAGE_NAME@
LATEX=@LATEX@
DVIPS=@DVIPS@
GS=@GS@
CC=@CC@
#for when "a drawing error occurred" in acroread
# GS=gs-gpl
all: numbers spectrum
# Make the spectrum chart
spectrum: pictures
$(LATEX) tex/spectrum.tex
$(DVIPS) -Ppdf -T 21in,40in spectrum.dvi -f > spectrum.eps
$(GS) -dSAFER -q -dNOPAUSE -dBATCH -sDEVICE=pdfwrite -sOutputFile=spectrum_current.pdf -dSAFER -c .setpdfwrite -f spectrum.eps
pictures:
cd pictures && make
cmyk:
$(GS) -dSAFER -dBATCH -dNOPAUSE -dNOCACHE -sDEVICE=pdfwrite \
-sColorConversionStrategy=CMYK -dProcessColorModel=/DeviceCMYK \
-sOutputFile=spectrum_20100428_cmyk.pdf spectrum_20100428_test.pdf
thumbnail:
convert spectrum.eps -scale 300 full_thumbnail.jpg
# makes a huge JPEG file with decent resolution for printing
jpeg:
$(GS) -sDEVICE=jpeg -sOutputFile=spectrum.jpg -r300x300 -dGraphicsAlphaBits=4 spectrum.eps
jpeg600:
$(GS) -sDEVICE=jpeg -sOutputFile=spectrum.jpg -r600x600 -dGraphicsAlphaBits=4 spectrum.eps
# Split poster up into smaller printable sheets
# This function may not work too well with newer versions of "poster" program.
split:
poster -v -c5% -s1 -mletter spectrum.eps -ospectrum_pages.eps
ps2pdf spectrum_pages.eps
zip spectrum_pages spectrum_pages.pdf
# Compile the C program that generates the numbers on the scales
numbers: numbers.c
$(CC) -lm -o numbers numbers.c
./numbers > tex/numbers.tex &
# Compile the utility to convert frequencies to positions on chart
xpos: xpos.c xpose6.c
$(CC) -lm -o xpos xpos.c
$(CC) -lm -o xpose6 xpose6.c
cell:
cat tex/3G-F.txt | ./xpose6 1e6 0.000 0.020 > tex/3Gbands.tex
cat tex/LTE-F.txt | ./xpose6 1e6 0.020 0.020 > tex/4Gbands.tex
cat tex/5G-F1.txt | ./xpose6 1e6 0.040 0.020 > tex/5GF1bands.tex
cat tex/5G-F2.txt | ./xpose6 1e9 0.040 0.020 > tex/5GF2bands.tex
# Compile the utility to convert a frequency range to positions on chart
kuband:
echo "% Upload channels 1-16" > kbandTV.txt
./xposrange.pl 14014.75e6 16 30.5e6 >> kbandTV.txt
echo "% Download channels 17-32" >> kbandTV.txt
./xposrange.pl 14027.75e6 16 30.5e6 >> kbandTV.txt
echo "% Download channels 1-16" >> kbandTV.txt
./xposrange.pl 11714.75e6 16 30.5e6 >> kbandTV.txt
echo "% Download channels 17-32" >> kbandTV.txt
./xposrange.pl 11727.75e6 16 30.5e6 >> kbandTV.txt
# Compile the scales program
scale: scale.c
$(CC) -lm -o scale scale.c
# remove compiled temporary files
clean:
cd pictures && $(MAKE) clean
rm -f *.dvi
rm -f *.aux
rm -f spectrum.eps
rm -f *.log
distclean: clean
rm -rf autom4te.cache
rm -f tex/numbers.tex
rm -f numbers
rm -f config.status
rm -f spectrum_current.pdf
# new update to website, modified for more recent changes.
new:
cp spectrum_current.pdf /home/anthony/web/unihedron/projects/spectrum/downloads/
sitecopy --update unihedron
# make a distributable file of the source code
dist:
if test -d "$(NAME)-$(VERSION)"; then rm -rf $(NAME)-$(VERSION); fi
if test -f "$(NAME)-$(VERSION).tar.gz"; then rm -f $(NAME)-$(VERSION).tar.gz; fi
mkdir $(NAME)-$(VERSION)
cp Makefile $(NAME)-$(VERSION)
cp -R doc $(NAME)-$(VERSION)
cp -R tex $(NAME)-$(VERSION)
cp -R sizes $(NAME)-$(VERSION)
cp -R sources $(NAME)-$(VERSION)
cp -R pictures $(NAME)-$(VERSION)
cp numbers.c $(NAME)-$(VERSION)
cp xpos.c $(NAME)-$(VERSION)
cp scale.c $(NAME)-$(VERSION)
tar cvzf $(NAME)-$(VERSION).tar.gz $(NAME)-$(VERSION)
rm -rf $(NAME)-$(VERSION)
configure: configure.ac
autoconf
config.status: configure
[ ! -f config.status ] || ./config.status --recheck