Makefile
author Markus Bröker <mbroeker@largo.localnet>
Thu, 16 Apr 2009 12:49:11 +0200
changeset 38 48f6f3918b82
parent 33 5e0a954f7c0b
child 39 46d7ec9d63bd
permissions -rw-r--r--
Project Split finished committer: Markus Bröker <mbroeker@largo.homelinux.org>
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
0
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
     1
CC=gcc -g -ggdb
2
97beb75e5ac7 bad alloc example added
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 0
diff changeset
     2
CPP=g++ -g -ggdb
0
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
     3
CFLAGS=-Wall -O2 -Iinclude -ansi
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
     4
TARGET=ncurses \
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
     5
	numerierung \
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
     6
	xdemo \
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
     7
	signals \
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
     8
	tree \
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
     9
	utf8 \
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    10
	file_demo \
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    11
	testcase \
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    12
	atoi_print \
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    13
	data_types \
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    14
	dnsresolve \
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    15
	nomalloc \
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    16
	urandom \
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    17
	threads \
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    18
	crypt \
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    19
	tokenpasting \
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    20
	hex2chars \
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    21
	floating \
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    22
	max \
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    23
	recording \
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    24
	endian \
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    25
	fak \
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    26
	blackhole \
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    27
	folge \
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    28
	counter \
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    29
	sudoku \
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    30
	cunit \
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    31
	md5 \
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    32
	varargs \
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    33
	concatenation \
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    34
	alpha_beta \
2
97beb75e5ac7 bad alloc example added
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 0
diff changeset
    35
	life \
3
820ed7fb9314 database, gauss, lotto, mem2swap, prog_limit moved to demos
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 2
diff changeset
    36
	bad_alloc \
820ed7fb9314 database, gauss, lotto, mem2swap, prog_limit moved to demos
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 2
diff changeset
    37
	lotto \
820ed7fb9314 database, gauss, lotto, mem2swap, prog_limit moved to demos
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 2
diff changeset
    38
	database \
820ed7fb9314 database, gauss, lotto, mem2swap, prog_limit moved to demos
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 2
diff changeset
    39
	gauss \
820ed7fb9314 database, gauss, lotto, mem2swap, prog_limit moved to demos
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 2
diff changeset
    40
	mem2swap \
10
f19f44e2e863 a nice connection demo from an irc user
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 8
diff changeset
    41
	prog_limit \
11
0a8be4eac87e c++ file copy demo added
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 10
diff changeset
    42
	connection \
24
9cdad6c45b47 function pointer demo added
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 11
diff changeset
    43
	copy \
25
6cf883f9c506 sort demo added
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 24
diff changeset
    44
	function_pointers \
26
d227047a3e88 convert minutes to timestamps
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 25
diff changeset
    45
	sort \
30
d037c433ec3e kleiner auffschrischungskurs compilerbau...
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 26
diff changeset
    46
	min2time \
33
5e0a954f7c0b getpwnam_error:
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 32
diff changeset
    47
	recursive_compiler \
5e0a954f7c0b getpwnam_error:
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 32
diff changeset
    48
	getpwnam_error
0
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    49
2
97beb75e5ac7 bad alloc example added
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 0
diff changeset
    50
.SUFFIXES: .c .cc .asm
0
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    51
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    52
.c.o:
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    53
	@echo Compiling $< ...
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    54
	@$(CC) -c $(CFLAGS) -o $@ $<
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    55
2
97beb75e5ac7 bad alloc example added
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 0
diff changeset
    56
.cc.o:
97beb75e5ac7 bad alloc example added
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 0
diff changeset
    57
	@echo Compiling $< ...
97beb75e5ac7 bad alloc example added
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 0
diff changeset
    58
	@$(CPP) -c $(CFLAGS) -o $@ $<
97beb75e5ac7 bad alloc example added
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 0
diff changeset
    59
0
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    60
.asm.o:
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    61
	@echo Assembling $< ...
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    62
	@$(NASM) $< -o $@
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    63
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    64
all: $(TARGET)
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    65
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    66
ncurses: ncurses.o
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    67
	@echo Linking $< ...
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    68
	@$(CC) $(CFLAGS) -lncursesw -o $@ $<
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    69
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    70
numerierung: numerierung.o
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    71
	@echo Linking $< ...
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    72
	@$(CC) $(CFLAGS) -o $@ $<
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    73
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    74
xdemo: xdemo.o
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    75
	@echo Linking $< ...
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    76
	@$(CC) $(CFLAGS) -lX11 -o $@ $<
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    77
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    78
signals: signals.o
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    79
	@echo Linking $< ...
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    80
	@$(CC) $(CFLAGS) -o $@ $<
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    81
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    82
tree: tree.o
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    83
	@echo Linking $< ...
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    84
	@$(CC) $(CFLAGS) -o $@ $<
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    85
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    86
utf8: utf8.o
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    87
	@echo Linking $< ...
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    88
	@$(CC) $(CFLAGS) -o $@ $<
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    89
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    90
file_demo: file_demo.o
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    91
	@echo Linking $< ...
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    92
	@$(CC) $(CFLAGS) -o $@ $<
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    93
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    94
testcase: testcase.o
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    95
	@echo Linking $< ...
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    96
	@$(CC) $(CFLAGS) -o $@ $<
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    97
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    98
atoi_print: atoi_print.o
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
    99
	@echo Linking $< ...
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   100
	@$(CC) $(CFLAGS) -o $@ $<
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   101
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   102
data_types: data_types.c
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   103
	@echo Linking $< ...
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   104
	@$(CC) $(CFLAGS) -std=c99 -o $@ $<
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   105
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   106
dnsresolve: dnsresolve.o
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   107
	@echo Linking $< ...
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   108
	@$(CC) $(CFLAGS) -o $@ $<
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   109
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   110
nomalloc: nomalloc.o
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   111
	@echo Linking $< ...
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   112
	@$(CC) $(CFLAGS) -o $@ $<
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   113
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   114
urandom: urandom.o
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   115
	@echo Linking $< ...
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   116
	@$(CC) $(CFLAGS) -o $@ $<
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   117
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   118
threads: threads.o
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   119
	@echo Linking $< ...
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   120
	@$(CC) $(CFLAGS) -o $@ $< -lpthread
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   121
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   122
crypt: crypt.o
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   123
	@echo Linking $< ...
32
9b56360ec64e crypt extended
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 30
diff changeset
   124
	@$(CC) $(CFLAGS) -o $@ $< -lcrypt
0
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   125
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   126
tokenpasting: tokenpasting.o
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   127
	@echo Linking $< ...
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   128
	@$(CC) $(CFLAGS) -o $@ $<
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   129
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   130
hex2chars: hex2chars.o
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   131
	@echo Linking $< ...
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   132
	@$(CC) $(CFLAGS) -o $@ $< -lm
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   133
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   134
floating: floating.o
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   135
	@echo Linking $< ...
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   136
	@$(CC) $(CFLAGS) -o $@ $< -lm
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   137
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   138
max: max.o
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   139
	@echo Linking $< ...
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   140
	@$(CC) $(CFLAGS) -o $@ $<
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   141
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   142
recording: recording.o
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   143
	@echo Linking $< ...
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   144
	@$(CC) $(CFLAGS) -o $@ $<
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   145
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   146
endian: endian.o
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   147
	@echo Linking $< ...
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   148
	@$(CC) $(CFLAGS) -o $@ $<
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   149
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   150
fak: fak.o
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   151
	@echo Linking $< ...
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   152
	@$(CC) $(CFLAGS) -o $@ $<
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   153
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   154
blackhole: blackhole.c
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   155
	@echo Compiling AND Linking $< WITH -O0 ...
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   156
	@$(CC) $(CFLAGS) -O0 -o $@ $<
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   157
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   158
folge: folge.o
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   159
	@echo Linking $< ...
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   160
	@$(CC) $(CFLAGS) -o $@ $< -lm
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   161
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   162
counter: counter.o
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   163
	@echo Linking $< ...
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   164
	@$(CC) $(CFLAGS) -o $@ $<
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   165
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   166
sudoku: sudoku.o
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   167
	@echo Linking $< ...
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   168
	@$(CC) $(CFLAGS) -o $@ $<
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   169
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   170
cunit: cunit.o
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   171
	@echo Linking $< ...
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   172
	@$(CC) $(CFLAGS) -o $@ $< -lcunit
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   173
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   174
md5: md5.o
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   175
	@echo Linking $< ...
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   176
	@$(CC) -o $@ $< -llsf
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   177
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   178
varargs: varargs.o
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   179
	@echo Linking $< ...
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   180
	@$(CC) -o $@ $<
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   181
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   182
concatenation: concatenation.o
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   183
	@echo Linking $< ...
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   184
	@$(CC) -o $@ $<
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   185
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   186
alpha_beta: alpha_beta.o
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   187
	@echo Linking $< ...
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   188
	@$(CC) -o $@ $<
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   189
2
97beb75e5ac7 bad alloc example added
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 0
diff changeset
   190
life: life.o
0
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   191
	@echo Linking $< ...
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   192
	@$(CC) -o $@ $<
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   193
2
97beb75e5ac7 bad alloc example added
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 0
diff changeset
   194
bad_alloc: bad_alloc.o
97beb75e5ac7 bad alloc example added
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 0
diff changeset
   195
	@echo Linking $< ...
97beb75e5ac7 bad alloc example added
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 0
diff changeset
   196
	@$(CPP) -o $@ $<
97beb75e5ac7 bad alloc example added
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 0
diff changeset
   197
3
820ed7fb9314 database, gauss, lotto, mem2swap, prog_limit moved to demos
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 2
diff changeset
   198
lotto: lotto.o
820ed7fb9314 database, gauss, lotto, mem2swap, prog_limit moved to demos
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 2
diff changeset
   199
	@echo Linking $< ...
820ed7fb9314 database, gauss, lotto, mem2swap, prog_limit moved to demos
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 2
diff changeset
   200
	@$(CPP) -o $@ $<
820ed7fb9314 database, gauss, lotto, mem2swap, prog_limit moved to demos
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 2
diff changeset
   201
820ed7fb9314 database, gauss, lotto, mem2swap, prog_limit moved to demos
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 2
diff changeset
   202
mem2swap: mem2swap.o set_limit.o
820ed7fb9314 database, gauss, lotto, mem2swap, prog_limit moved to demos
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 2
diff changeset
   203
	@echo Linking $< ...
820ed7fb9314 database, gauss, lotto, mem2swap, prog_limit moved to demos
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 2
diff changeset
   204
	@$(CPP) -o $@ mem2swap.o set_limit.o
820ed7fb9314 database, gauss, lotto, mem2swap, prog_limit moved to demos
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 2
diff changeset
   205
820ed7fb9314 database, gauss, lotto, mem2swap, prog_limit moved to demos
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 2
diff changeset
   206
prog_limit: prog_limit.o set_limit.o
820ed7fb9314 database, gauss, lotto, mem2swap, prog_limit moved to demos
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 2
diff changeset
   207
	@echo Linking $< ...
820ed7fb9314 database, gauss, lotto, mem2swap, prog_limit moved to demos
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 2
diff changeset
   208
	@$(CPP) -o $@ prog_limit.o set_limit.o
820ed7fb9314 database, gauss, lotto, mem2swap, prog_limit moved to demos
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 2
diff changeset
   209
820ed7fb9314 database, gauss, lotto, mem2swap, prog_limit moved to demos
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 2
diff changeset
   210
database: database.c
8
96d16dfe787a We use return EXIT_SUCCESS instead of return 0
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 3
diff changeset
   211
	@echo Compiling $< ...
96d16dfe787a We use return EXIT_SUCCESS instead of return 0
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 3
diff changeset
   212
	@$(CC) -c -I$(shell pg_config --includedir) $<
3
820ed7fb9314 database, gauss, lotto, mem2swap, prog_limit moved to demos
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 2
diff changeset
   213
	@echo Linking $< ...
8
96d16dfe787a We use return EXIT_SUCCESS instead of return 0
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 3
diff changeset
   214
	@$(CC) -lpq -o $@ $@.o
3
820ed7fb9314 database, gauss, lotto, mem2swap, prog_limit moved to demos
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 2
diff changeset
   215
820ed7fb9314 database, gauss, lotto, mem2swap, prog_limit moved to demos
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 2
diff changeset
   216
gauss: gauss.o
820ed7fb9314 database, gauss, lotto, mem2swap, prog_limit moved to demos
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 2
diff changeset
   217
	@echo Linking $< ...
820ed7fb9314 database, gauss, lotto, mem2swap, prog_limit moved to demos
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 2
diff changeset
   218
	@$(CPP) -o $@ $<
820ed7fb9314 database, gauss, lotto, mem2swap, prog_limit moved to demos
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 2
diff changeset
   219
10
f19f44e2e863 a nice connection demo from an irc user
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 8
diff changeset
   220
connection: connection.o
f19f44e2e863 a nice connection demo from an irc user
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 8
diff changeset
   221
	@echo Linking $< ...
f19f44e2e863 a nice connection demo from an irc user
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 8
diff changeset
   222
	@$(CPP) -o $@ $<
f19f44e2e863 a nice connection demo from an irc user
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 8
diff changeset
   223
11
0a8be4eac87e c++ file copy demo added
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 10
diff changeset
   224
copy: copy.o
0a8be4eac87e c++ file copy demo added
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 10
diff changeset
   225
	@echo Linking $< ...
0a8be4eac87e c++ file copy demo added
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 10
diff changeset
   226
	@$(CPP) -o $@ $<
0a8be4eac87e c++ file copy demo added
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 10
diff changeset
   227
24
9cdad6c45b47 function pointer demo added
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 11
diff changeset
   228
function_pointers: function_pointers.o
9cdad6c45b47 function pointer demo added
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 11
diff changeset
   229
	@echo Linking $< ...
9cdad6c45b47 function pointer demo added
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 11
diff changeset
   230
	@$(CC) -o $@ $<
9cdad6c45b47 function pointer demo added
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 11
diff changeset
   231
25
6cf883f9c506 sort demo added
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 24
diff changeset
   232
sort: sort.o
6cf883f9c506 sort demo added
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 24
diff changeset
   233
	@echo Linking $< ...
6cf883f9c506 sort demo added
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 24
diff changeset
   234
	@$(CC) -o $@ $<
6cf883f9c506 sort demo added
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 24
diff changeset
   235
26
d227047a3e88 convert minutes to timestamps
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 25
diff changeset
   236
min2time: min2time.o
d227047a3e88 convert minutes to timestamps
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 25
diff changeset
   237
	@echo Linking $< ...
d227047a3e88 convert minutes to timestamps
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 25
diff changeset
   238
	@$(CC) -o $@ $<
d227047a3e88 convert minutes to timestamps
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 25
diff changeset
   239
30
d037c433ec3e kleiner auffschrischungskurs compilerbau...
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 26
diff changeset
   240
recursive_compiler: recursive_compiler.o
d037c433ec3e kleiner auffschrischungskurs compilerbau...
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 26
diff changeset
   241
	@echo Linking $< ...
d037c433ec3e kleiner auffschrischungskurs compilerbau...
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 26
diff changeset
   242
	@$(CC) -o $@ $<
d037c433ec3e kleiner auffschrischungskurs compilerbau...
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 26
diff changeset
   243
33
5e0a954f7c0b getpwnam_error:
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 32
diff changeset
   244
getpwnam_error: getpwnam_error.o
5e0a954f7c0b getpwnam_error:
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 32
diff changeset
   245
	@echo Linking $< ...
5e0a954f7c0b getpwnam_error:
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 32
diff changeset
   246
	@$(CC) -o $@ $<
5e0a954f7c0b getpwnam_error:
Markus Bröker <mbroeker@largo.dyndns.tv>
parents: 32
diff changeset
   247
0
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   248
.PHONY: clean uninstall
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   249
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   250
clean:
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   251
	rm -f *.o *~
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   252
	rm -f $(TARGET)
af501b0c1716 demos cvs copy
Markus Bröker <mbroeker@largo.dyndns.tv>
parents:
diff changeset
   253