Debian Codegraph @

Makefile

raw ◀ ▶
Source reconstructed at patch state 0 of 1 — not the installed (fully patched) source.
1 Debian patch touch this file
1 #
2 # Makefile for memtester by Charles Cazabon.
3 #
4 # Copyright (C) 1999 Simon Kirby.
5 # Copyright (C) 1999-2020 Charles Cazabon.
6 # Licensed under the GNU General Public License version 2. See the file
7 # COPYING for details.
8 #
9
10 # You don't need to edit these; change the contents of the conf-cc and conf-ld
11 # files if you need to change the compile/link commands. See the README for
12 # more information.
13 CC = $(shell head -n 1 conf-cc)
14 LD = $(shell head -n 1 conf-ld)
15
16 SOURCES = memtester.c tests.c
17 OBJECTS = $(SOURCES:.c=.o)
18 HEADERS = memtester.h
19 TARGETS = *.o compile load auto-ccld.sh find-systype make-compile make-load systype extra-libs
20 INSTALLPATH = /usr/local
21
22 #
23 # Targets
24 #
25 all: memtester
26
27 install: all
28 mkdir -m 755 -p $(INSTALLPATH)/bin
29 install -m 755 memtester $(INSTALLPATH)/bin/
30 mkdir -m 755 -p $(INSTALLPATH)/man/man8
31 gzip -c memtester.8 >memtester.8.gz ; install -m 644 memtester.8.gz $(INSTALLPATH)/man/man8/
32
33 auto-ccld.sh: \
34 conf-cc conf-ld warn-auto.sh
35 ( cat warn-auto.sh; \
36 echo CC=\'`head -1 conf-cc`\'; \
37 echo LD=\'`head -1 conf-ld`\' \
38 ) > auto-ccld.sh
39
40 compile: \
41 make-compile warn-auto.sh systype
42 ( cat warn-auto.sh; ./make-compile "`cat systype`" ) > \
43 compile
44 chmod 755 compile
45
46 find-systype: \
47 find-systype.sh auto-ccld.sh
48 cat auto-ccld.sh find-systype.sh > find-systype
49 chmod 755 find-systype
50
51 make-compile: \
52 make-compile.sh auto-ccld.sh
53 cat auto-ccld.sh make-compile.sh > make-compile
54 chmod 755 make-compile
55
56 make-load: \
57 make-load.sh auto-ccld.sh
58 cat auto-ccld.sh make-load.sh > make-load
59 chmod 755 make-load
60
61 systype: \
62 find-systype trycpp.c
63 ./find-systype > systype
64
65 extra-libs: \
66 extra-libs.sh systype
67 ./extra-libs.sh "`cat systype`" >extra-libs
68
69 load: \
70 make-load warn-auto.sh systype
71 ( cat warn-auto.sh; ./make-load "`cat systype`" ) > load
72 chmod 755 load
73
74 clean:
75 rm -f memtester $(TARGETS) $(OBJECTS) core
76
77 memtester: \
78 $(OBJECTS) memtester.c tests.h tests.c tests.h conf-cc Makefile load extra-libs
79 ./load memtester tests.o `cat extra-libs`
80
81 memtester.o: memtester.c tests.h conf-cc Makefile compile
82 ./compile memtester.c
83
84 tests.o: tests.c tests.h conf-cc Makefile compile
85 ./compile tests.c