make system changed to be a subset of the library make system
[physics.git] / rules.mk
CommitLineData
6d8ae407
PG
1
2# HACK
3all: ${TARGET_$P} ${CFGS_$P} ${LIBSTXT_$P} ${LIBSCPY_$P} ${TXT_$P}
4
5#${G_OBJS_TESTS}: ${L_OBJS_$P}
6#${G_DEPS_TESTS}: ${L_DEPS_$P}
7
8
9# how to link the main target
10${TARGETTMP_$P}: ${L_OBJS_$P} | $${@D}
11 ${cmd-link}
12
13# rule to copy tmp target to working directory
14${TARGET_$P}: ${TARGETTMP_$P} | $${@D}
15 ${cmd-cp}
16
17# how to copy a library to the bin directory
18#${BINDIR_$P}${SONAME_${G_LIB}}: ${TARGET_${G_LIB}} | $${@D}
19# ${cmd-cp}
20
21# rule to copy the config files into the working directory
22${DSTCFGDIR_$P}%: ${SRCCFGDIR_$P}% | $$(dir $$@)
23 ${cmd-cp}
24
25# rule to copy the library files into the working directory
26${DSTLIBSDIR_$P}%: ${SRCLIBSDIR_$P}% | $$(dir $$@)
27 ${cmd-cp}
28
29# rule to copy the text files into the working directory
30${DSTTXTDIR_$P}%: ${SRCTXTDIR_$P}% | $$(dir $$@)
31 ${cmd-cp}
32
33# rule to make an object file from a .cpp
34${OBJSDIR_$P}%.o: ${SRCSDIR_$P}%.cpp | $${@D}
35 ${cmd-cpptoobj}
36
37# rule to make a depend file from a .cpp
38${DEPSDIR_$P}%.d: ${SRCSDIR_$P}%.cpp | $${@D}
39 ${cmd-cpptodep}
40
41
42L_CLEANCMDS += cleanbin-$P
43cleanbin: cleanbin-$P
44.PHONY: cleanbin-$P
45cleanbin-$P:
46 ${Q1}${PRNTFMT} "rm" "${BINDIR}"
47 ${Q2}rm -rf ${BINDIR}
48
49L_CLEANCMDS += cleanobjs-$P
50cleanobjs: cleanobjs-$P
51.PHONY: cleanobjs-$P
52cleanobjs-$P:
53 ${Q1}${PRNTFMT} "rm" "${OBJSDIR}"
54 ${Q2}rm -rf ${OBJSDIR}
55
56L_CLEANCMDS += cleandeps-$P
57cleandeps: cleandeps-$P
58.PHONY: cleandeps-$P
59cleandeps-$P:
60 ${Q1}${PRNTFMT} "rm" "${DEPSDIR}"
61 ${Q2}rm -rf ${DEPSDIR}
62
63L_CLEANCMDS += clean-$P
64clean: clean-$P
65.PHONY: clean-$P
66clean-$P: cleanobjs-$P cleanbin-$P
67
68L_CLEANCMDS += cleanall-$P
69cleanall: cleanall-$P
70.PHONY: cleanall-$P
71cleanall-$P: cleanbin-$P cleanobjs-$P cleandeps-$P
72