source: CMT/HEAD/mgr/fragments/nmake/constituent_app_lib @ 631

Last change on this file since 631 was 631, checked in by rybkin, 11 years ago

See C.L. 502

File size: 6.1 KB
Line 
1#-- start of constituent_app_lib ------
2
3cmt_${CONSTITUENT}_${HASTARGETTAG} = 1
4cmt_${CONSTITUENT}_${HASPROTOTYPES} = 1
5cmt_${CONSTITUENT}_${HASDEPENDENCIES} = 1
6
7#----------------------------------------
8
9!if defined (cmt_${CONSTITUENT}_has_target_tag)
10
11cmt_local_tagfile_${CONSTITUENT} = $(bin)$(${PACKAGE}_tag)_${CONSTITUENT}.nmake
12cmt_final_setup_${CONSTITUENT} = $(bin)setup_${CONSTITUENT}.nmake
13cmt_local_${CONSTITUENT}_makefile = $(bin)${CONSTITUENT}.nmake
14
15${CONSTITUENT}_extratags = -tag_add=target_${CONSTITUENT}
16
17!else
18
19cmt_local_tagfile_${CONSTITUENT} = $(bin)$(${PACKAGE}_tag).nmake
20cmt_final_setup_${CONSTITUENT} = $(bin)setup.nmake
21cmt_local_${CONSTITUENT}_makefile = $(bin)${CONSTITUENT}.nmake
22
23!endif
24
25!if defined (cmt_${CONSTITUENT}_has_target_tag)
26
27!if "$(QUICK)" == "" || !exist ($(cmt_local_${CONSTITUENT}_makefile)) || !exist ($(cmt_local_tagfile_${CONSTITUENT})) || !exist ($(cmt_final_setup_${CONSTITUENT}))
28$(cmt_local_${CONSTITUENT}_makefile) :: $(${CONSTITUENT}compile_dependencies) dirs
29        $(echo) (constituents.nmake) Building ${CONSTITUENT}.nmake
30        @set include=$(include)
31        @set lib=$(lib)
32        @$(cmtexe) -tag=$(tags) $(${CONSTITUENT}_extratags) build -nmake constituent_config -out=$@ ${CONSTITUENT}
33!else
34$(cmt_local_${CONSTITUENT}_makefile) : $(${CONSTITUENT}compile_dependencies) $(use_requirements)
35        @set include=$(include)
36        @set lib=$(lib)
37        @if not "$?"=="$(${CONSTITUENT}compile_dependencies)" ((if not "$(cmtmsg)"=="" @echo "$(CMTMSGPREFIX)" "(constituents.nmake) Rebuilding ${CONSTITUENT}.nmake") & $(cmtexe) -tag=$(tags) $(${CONSTITUENT}_extratags) build -nmake constituent_config -out=$@ ${CONSTITUENT}) else (if not "$(cmtmsg)"=="" @echo "$(CMTMSGPREFIX)" "(constituents.nmake) ${CONSTITUENT}.nmake up-to-date")
38!endif
39
40!else
41
42!if "$(QUICK)" == "" || !exist ($(cmt_local_${CONSTITUENT}_makefile)) || !exist ($(cmt_local_tagfile_${CONSTITUENT})) || !exist ($(cmt_final_setup_${CONSTITUENT}))
43$(cmt_local_${CONSTITUENT}_makefile) :: $(${CONSTITUENT}compile_dependencies) dirs
44        $(echo) (constituents.nmake) Building ${CONSTITUENT}.nmake
45        @set include=$(include)
46        @set lib=$(lib)
47        @$(cmtexe) -f=$(bin)${CONSTITUENT}.in -tag=$(tags) $(${CONSTITUENT}_extratags) build -nmake constituent_makefile -without_cmt -out=$@ ${CONSTITUENT}
48!else
49$(cmt_local_${CONSTITUENT}_makefile) : $(${CONSTITUENT}compile_dependencies) $(use_requirements) $(bin)${CONSTITUENT}.in
50        @set include=$(include)
51        @set lib=$(lib)
52        @if not "$?"=="$(${CONSTITUENT}compile_dependencies)" ((if not "$(cmtmsg)"=="" @echo "$(CMTMSGPREFIX)" "(constituents.nmake) Rebuilding ${CONSTITUENT}.nmake") & $(cmtexe) -f=$(bin)${CONSTITUENT}.in -tag=$(tags) $(${CONSTITUENT}_extratags) build -nmake constituent_makefile -without_cmt -out=$@ ${CONSTITUENT}) else (if not "$(cmtmsg)"=="" @echo "$(CMTMSGPREFIX)" "(constituents.nmake) ${CONSTITUENT}.nmake up-to-date")
53!endif
54
55!endif
56
57${CONSTITUENT} :: ${CONSTITUENT}compile ${CONSTITUENT}install ;
58
59
60!if defined (cmt_${CONSTITUENT}_has_prototypes)
61
62${CONSTITUENT}prototype : $(${CONSTITUENT}prototype_dependencies) $(cmt_local_${CONSTITUENT}_makefile) dirs
63        $(echo) (constituents.nmake) Starting $@
64        @set include=$(include)
65        @set lib=$(lib)
66        @$(MAKE) /nologo /f $(cmt_local_${CONSTITUENT}_makefile) /$(MAKEFLAGS) bin=$(bin) build_strategy=keep_makefiles $@ tag=$(tag)
67        $(echo) (constituents.nmake) $@ done
68
69${CONSTITUENT}compile : ${CONSTITUENT}prototype
70
71!if defined (cmt_${CONSTITUENT}_has_dependencies)
72
73${CONSTITUENT}dependencies : ${CONSTITUENT}prototype
74
75!endif
76
77!endif
78
79
80!if defined (cmt_${CONSTITUENT}_has_dependencies)
81
82${CONSTITUENT}dependencies : $(cmt_local_${CONSTITUENT}_makefile) dirs
83        $(echo) (constituents.nmake) Starting $@
84        @set include=$(include)
85        @set lib=$(lib)
86        @$(MAKE) /nologo /f $(cmt_local_${CONSTITUENT}_makefile) /$(MAKEFLAGS) bin=$(bin) build_strategy=keep_makefiles dependencies tag=$(tag)
87        $(echo) (constituents.nmake) $@ done
88
89${CONSTITUENT}compile : ${CONSTITUENT}dependencies
90
91!endif
92
93${CONSTITUENT}compile : $(${CONSTITUENT}compile_dependencies) $(cmt_local_${CONSTITUENT}_makefile) dirs
94        $(echo) (constituents.nmake) Starting $@
95        @set include=$(include)
96        @set lib=$(lib)
97        @$(MAKE) /nologo /f $(cmt_local_${CONSTITUENT}_makefile) /$(MAKEFLAGS) bin=$(bin) build_strategy=keep_makefiles $@ tag=$(tag)
98        $(echo) (constituents.nmake) $@ done
99
100clean :: ${CONSTITUENT}clean ;
101
102${CONSTITUENT}clean :: $(${CONSTITUENT}clean_dependencies) ##$(cmt_local_${CONSTITUENT}_makefile)
103        $(echo) (constituents.nmake) Starting $@
104        @set include=$(include)
105        @set lib=$(lib)
106        @-if exist $(cmt_local_${CONSTITUENT}_makefile) $(MAKE) /nologo /f $(cmt_local_${CONSTITUENT}_makefile) /$(MAKEFLAGS) bin=$(bin) build_strategy=keep_makefiles $@ tag=$(tag)
107        $(echo) (constituents.nmake) $@ done
108#       @$(MAKE) /nologo /f $(cmt_local_${CONSTITUENT}_makefile) /$(MAKEFLAGS) bin=$(bin) build_strategy=keep_makefiles ${CONSTITUENT}clean tag=$(tag)
109
110install :: ${CONSTITUENT}install ;
111
112${CONSTITUENT}install :: ${CONSTITUENT}compile $(${CONSTITUENT}_dependencies) $(cmt_local_${CONSTITUENT}_makefile)
113        $(echo) (constituents.nmake) Starting $@
114        @set include=$(include)
115        @set lib=$(lib)
116        @$(MAKE) /nologo /f $(cmt_local_${CONSTITUENT}_makefile) /$(MAKEFLAGS) bin=$(bin) build_strategy=keep_makefiles install tag=$(tag)
117        $(echo) (constituents.nmake) $@ done
118
119uninstall :: ${CONSTITUENT}uninstall ;
120
121${CONSTITUENT}uninstall :: $(${CONSTITUENT}uninstall_dependencies)
122        $(echo) (constituents.nmake) Starting $@
123        @set include=$(include)
124        @set lib=$(lib)
125        @-if exist $(cmt_local_${CONSTITUENT}_makefile) $(MAKE) /nologo /f $(cmt_local_${CONSTITUENT}_makefile) /$(MAKEFLAGS) bin=$(bin) build_strategy=keep_makefiles uninstall tag=$(tag)
126#       @if not exist $(cmt_local_${CONSTITUENT}_makefile) $(cmtexe) -tag=$(tags) $(${CONSTITUENT}_extratags) build -nmake constituent_config -out=$(cmt_local_${CONSTITUENT}_makefile) ${CONSTITUENT}
127#       @if not exist $(cmt_local_${CONSTITUENT}_makefile) $(cmtexe) -tag=$(tags) $(${CONSTITUENT}_extratags) build -nmake constituent_makefile -out=$(cmt_local_${CONSTITUENT}_makefile) ${CONSTITUENT}
128#       @-$(MAKE) /nologo /f $(cmt_local_${CONSTITUENT}_makefile) /$(MAKEFLAGS) bin=$(bin) build_strategy=keep_makefiles uninstall tag=$(tag)
129        $(echo) (constituents.nmake) $@ done
130
131#-- end of constituent_app_lib ------
Note: See TracBrowser for help on using the repository browser.