Makefile

Wed, 19 Apr 2000 22:03:51 +0200

author
tuomov
date
Wed, 19 Apr 2000 22:03:51 +0200
changeset 4
ee28b655297b
parent 3
b1fbfab67908
child 5
f878a9ffa3e0
permissions
-rw-r--r--

trunk: changeset 7
Simpler optparser

3
b1fbfab67908 trunk: changeset 6
tuomov
parents: 1
diff changeset
1 ##
b1fbfab67908 trunk: changeset 6
tuomov
parents: 1
diff changeset
2 ## libtu Makefile
b1fbfab67908 trunk: changeset 6
tuomov
parents: 1
diff changeset
3 ##
0
86b7f6f9c5c0 Tailorization of trunk
tailor@f281.ttorni.ton.tut.fi
parents:
diff changeset
4
3
b1fbfab67908 trunk: changeset 6
tuomov
parents: 1
diff changeset
5 # System-specific configuration is in system.mk
b1fbfab67908 trunk: changeset 6
tuomov
parents: 1
diff changeset
6 include system.mk
0
86b7f6f9c5c0 Tailorization of trunk
tailor@f281.ttorni.ton.tut.fi
parents:
diff changeset
7
86b7f6f9c5c0 Tailorization of trunk
tailor@f281.ttorni.ton.tut.fi
parents:
diff changeset
8 ######################################
86b7f6f9c5c0 Tailorization of trunk
tailor@f281.ttorni.ton.tut.fi
parents:
diff changeset
9
86b7f6f9c5c0 Tailorization of trunk
tailor@f281.ttorni.ton.tut.fi
parents:
diff changeset
10 OBJS= misc.o output.o util.o optparser.o parser.o tokenizer.o
86b7f6f9c5c0 Tailorization of trunk
tailor@f281.ttorni.ton.tut.fi
parents:
diff changeset
11
86b7f6f9c5c0 Tailorization of trunk
tailor@f281.ttorni.ton.tut.fi
parents:
diff changeset
12 LIBDIR=$(PREFIX)/lib
86b7f6f9c5c0 Tailorization of trunk
tailor@f281.ttorni.ton.tut.fi
parents:
diff changeset
13 INCDIR=$(PREFIX)/include/libtu
86b7f6f9c5c0 Tailorization of trunk
tailor@f281.ttorni.ton.tut.fi
parents:
diff changeset
14
86b7f6f9c5c0 Tailorization of trunk
tailor@f281.ttorni.ton.tut.fi
parents:
diff changeset
15 TARGETS=libtu.a
86b7f6f9c5c0 Tailorization of trunk
tailor@f281.ttorni.ton.tut.fi
parents:
diff changeset
16 TESTERS=tester tester2 tester3
86b7f6f9c5c0 Tailorization of trunk
tailor@f281.ttorni.ton.tut.fi
parents:
diff changeset
17
86b7f6f9c5c0 Tailorization of trunk
tailor@f281.ttorni.ton.tut.fi
parents:
diff changeset
18 ######################################
86b7f6f9c5c0 Tailorization of trunk
tailor@f281.ttorni.ton.tut.fi
parents:
diff changeset
19
3
b1fbfab67908 trunk: changeset 6
tuomov
parents: 1
diff changeset
20 include rules.mk
b1fbfab67908 trunk: changeset 6
tuomov
parents: 1
diff changeset
21
b1fbfab67908 trunk: changeset 6
tuomov
parents: 1
diff changeset
22 ######################################
0
86b7f6f9c5c0 Tailorization of trunk
tailor@f281.ttorni.ton.tut.fi
parents:
diff changeset
23
86b7f6f9c5c0 Tailorization of trunk
tailor@f281.ttorni.ton.tut.fi
parents:
diff changeset
24 testers: $(TESTERS)
86b7f6f9c5c0 Tailorization of trunk
tailor@f281.ttorni.ton.tut.fi
parents:
diff changeset
25
86b7f6f9c5c0 Tailorization of trunk
tailor@f281.ttorni.ton.tut.fi
parents:
diff changeset
26 libtu.a: $(OBJS)
86b7f6f9c5c0 Tailorization of trunk
tailor@f281.ttorni.ton.tut.fi
parents:
diff changeset
27 $(AR) $(AR_FLAGS) $@ $+
86b7f6f9c5c0 Tailorization of trunk
tailor@f281.ttorni.ton.tut.fi
parents:
diff changeset
28
1
6e704fc09528 trunk: changeset 4
tuomov
parents: 0
diff changeset
29 %: %.c libtu.a
0
86b7f6f9c5c0 Tailorization of trunk
tailor@f281.ttorni.ton.tut.fi
parents:
diff changeset
30 $(CC) $(CC_FLAGS) $+ -L. -ltu -lm -o $@
86b7f6f9c5c0 Tailorization of trunk
tailor@f281.ttorni.ton.tut.fi
parents:
diff changeset
31
3
b1fbfab67908 trunk: changeset 6
tuomov
parents: 1
diff changeset
32 _install:
0
86b7f6f9c5c0 Tailorization of trunk
tailor@f281.ttorni.ton.tut.fi
parents:
diff changeset
33 $(INSTALL) -d $(LIBDIR)
86b7f6f9c5c0 Tailorization of trunk
tailor@f281.ttorni.ton.tut.fi
parents:
diff changeset
34 $(INSTALL) -d $(INCDIR)
3
b1fbfab67908 trunk: changeset 6
tuomov
parents: 1
diff changeset
35 $(INSTALL) -m $(DATA_MODE) libtu.a $(LIBDIR)
b1fbfab67908 trunk: changeset 6
tuomov
parents: 1
diff changeset
36 $(INSTALL) -m $(DATA_MODE) include/*.h $(INCDIR)
0
86b7f6f9c5c0 Tailorization of trunk
tailor@f281.ttorni.ton.tut.fi
parents:
diff changeset
37

mercurial