1 | # |
---|
2 | # $Id$ |
---|
3 | # |
---|
4 | # make/main.cfg |
---|
5 | # |
---|
6 | # Make(1) configuration file include'd by all Makefile's |
---|
7 | # |
---|
8 | |
---|
9 | # |
---|
10 | # where things are relative to PROJECT_ROOT; shouldn't need to change, |
---|
11 | # but could be overridden in custom files. |
---|
12 | # |
---|
13 | |
---|
14 | PROJECT_RELEASE=$(exec_prefix)/$(RTEMS_BSP) |
---|
15 | PROJECT_BIN=$(PROJECT_ROOT)/bin |
---|
16 | PROJECT_INCLUDE=$(PROJECT_RELEASE)/lib/include |
---|
17 | PROJECT_TOOLS = $(PROJECT_RELEASE)/build-tools |
---|
18 | |
---|
19 | # |
---|
20 | # Target architecture; may be changed as per 'make "ARCH=debug"' |
---|
21 | # This is where the object files get put. |
---|
22 | # |
---|
23 | |
---|
24 | ifeq ($(VARIANT),) |
---|
25 | ARCH=o-optimize |
---|
26 | VARIANT= |
---|
27 | else |
---|
28 | ifeq ($(VARIANT),DEBUG) |
---|
29 | ARCH=o-debug |
---|
30 | VARIANT=DEBUG |
---|
31 | endif |
---|
32 | endif |
---|
33 | |
---|
34 | # |
---|
35 | # Initial target for make(1) |
---|
36 | # Once this is established we can safely include other targets |
---|
37 | # within this make-include file. |
---|
38 | # |
---|
39 | |
---|
40 | default_target: all |
---|
41 | |
---|
42 | # |
---|
43 | # Default makefile name |
---|
44 | # May be overridden by command line macro assignment |
---|
45 | # |
---|
46 | |
---|
47 | MAKEFILE=Makefile |
---|
48 | |
---|
49 | # |
---|
50 | # Target variant names |
---|
51 | # |
---|
52 | TARGET_VARIANTS = optimize debug profile |
---|
53 | |
---|
54 | # |
---|
55 | # Generate list of object directories: o-optimize, o-debug, o-profile |
---|
56 | # |
---|
57 | VARIANTS=${TARGET_VARIANTS:%=o-%} |
---|
58 | |
---|
59 | # |
---|
60 | # List of "recursion-able" targets for directory Makefiles |
---|
61 | # |
---|
62 | |
---|
63 | RECURSE_TARGETS=all depend install \ |
---|
64 | preinstall-recursive \ |
---|
65 | $(TARGET_VARIANTS) |
---|
66 | |
---|
67 | ${ARCH}: |
---|
68 | test -d ${ARCH} || mkdir ${ARCH} |
---|
69 | |
---|
70 | ifndef AUTOMAKE |
---|
71 | distclean-generic: |
---|
72 | -$(RM) .#* $(CONFIG_CLEAN_FILES) |
---|
73 | -$(RM) -r $(CLOBBER_ADDITIONS) |
---|
74 | |
---|
75 | clean-generic: |
---|
76 | -$(RM) a.out core mon.out gmon.out |
---|
77 | -$(RM) -r $(CLEAN_ADDITIONS) |
---|
78 | endif |
---|
79 | |
---|
80 | .PHONY: $(RECURSE_TARGETS) |
---|
81 | .PHONY: clean-generic |
---|
82 | .PHONY: distclean-generic |
---|