source: trunk/unix/Makefile @ 201

Last change on this file since 201 was 201, checked in by nanardon, 16 years ago
  • add X11 frame
  • Property svn:eol-style set to native
File size: 1.6 KB
Line 
1# $Id: Makefile 187 2008-09-05 02:43:56Z nanardon $
2
3.SUFFIXES: .dvi .pdf .eps .fig .png .jpg
4
5PWD=$(shell pwd)
6
7# unix
8
9unix_TEX = \
10    unix.tex
11
12unix_INCLUDES = \
13
14unix_EXAMPLES = \
15        deleteopen.pl \
16        nosegfault.c \
17        malloc.c \
18        fork.c \
19
20unix_IMAGESJPG= \
21
22unix_IMAGESPNG= \
23        asus_mb.png \
24        process.png \
25        fork.png \
26        compil.png \
27        x.png \
28        x-mplayer-capcv.png \
29        x-mplayer-capcv-twm.png \
30        x-resume.png \
31
32unix_FIGURES= \
33
34unix_IMAGES= $(unix_IMAGESJPG) $(unix_IMAGESPNG)
35
36unix_PDFDEPS = Makefile \
37        $(unix_INCLUDES) \
38        $(unix_EXAMPLES) \
39        $(unix_FIGURES) \
40        $(unix_IMAGES) \
41
42unix_DVIDEPS = Makefile \
43        $(unix_INCLUDES) \
44        $(unix_EXAMPLES) \
45        $(unix_FIGURES) \
46        $(unix_IMAGES) \
47        $(unix_PNGEPS) \
48
49
50unix_DVI = $(unix_TEX:.tex=.dvi)
51unix_PDF = $(unix_TEX:.tex=.pdf)
52unix_EPS = $(unix_FIGEPS) $(unix_PNGEPS) $(unix_JPGEPS)
53unix_FIGEPS = $(unix_FIGURES:.fig=.eps) 
54unix_PNGEPS = $(unix_IMAGESPNG:.png=.eps)
55unix_JPGEPS = $(unix_IMAGESJPG:.jpg=.eps)
56
57# Everything
58ALL_PDF = $(unix_PDF)
59ALL_DVI = $(unix_DVI)
60
61all: pdf
62
63pdf: $(ALL_PDF)
64
65dvi: $(ALL_DVI)
66
67unix.pdf: $(unix_TEX) $(unix_PDFDEPS)
68        pdflatex -halt-on-error $< && pdflatex -halt-on-error $< 
69
70unix.dvi: $(unix_TEX) $(unix_DVIDEPS)
71        latex -halt-on-error $< && latex -halt-on-error $< 
72
73%.eps: %.fig
74        fig2dev -L eps  $< $@
75
76%.png: %.dia
77        dia -e $@ $<
78
79.png.eps:
80        convert $< $@
81
82.jpg.eps:
83        convert $< $@
84
85libsmall.so: libsmall.o
86        gcc -shared -o $@ $<
87
88libsmall.a: libsmall.o
89        ar rcs $@ $<
90
91small.dyn: small.o libsmall.so
92        gcc -Wl,-rpath=$(PWD) -I. -L. -lsmall -o $@ small.o
93
94small.static: small.o libsmall.a
95        gcc -I. -o $@ small.o libsmall.a
96
97clean:
98        rm -f $(FIGEPS)
99        rm -f $(ALL_DVI)
100        rm -f $(ALL_PDF)
101
102.PHONY: pdf dvi clean all
Note: See TracBrowser for help on using the repository browser.