source: CMT/v1r25-branch/mgr/fragments/nmake/library @ 666

Last change on this file since 666 was 666, checked in by rybkin, 10 years ago

merge -r 664:665 HEAD

File size: 3.6 KB
Line 
1#-- start of libary ----------------------
2
3${CONSTITUENT}LIB :: $(${CONSTITUENT}shstamp)
4        $(echo) "${CONSTITUENT} : library ok"
5
6$(${CONSTITUENT}arc) :: ${OBJS}
7        $(lib_echo) library
8        $(lib_silent) $(ar) /out:$(bin)${CONSTITUENT}.arc @<<
9${OBJS}
10<<
11        $(lib_silent) echo "" >$(${CONSTITUENT}stamp)
12
13$(${CONSTITUENT}shstamp) :: $(${CONSTITUENT}arc) requirements $(use_requirements) $(${CONSTITUENT}stamps)
14        $(lib_echo) dynamic library $(bin)${CONSTITUENT}.dll
15        $(lib_silent) $(make_shlib) $(tag) ${CONSTITUENT} $(cpplinkflags) $(${CONSTITUENT}_shlibflags)
16        $(lib_silent) if exist $(bin)${CONSTITUENT}.dll echo "" >$(${CONSTITUENT}shstamp)
17
18${CONSTITUENT}clean ::
19        $(cleanup_echo) #objects
20        $(cleanup_silent) for %f in (${OBJS}) do $(cleanup_silent)if exist %f del %f
21        $(cleanup_silent) if exist $(bin)${CONSTITUENT} rmdir /S /Q $(bin)${CONSTITUENT}
22        $(cleanup_silent) if exist $(bin)${CONSTITUENT}.arc del $(bin)${CONSTITUENT}.arc
23        $(cleanup_silent) if exist $(bin)${CONSTITUENT}.lib del $(bin)${CONSTITUENT}.lib
24        $(cleanup_silent) if exist $(bin)${CONSTITUENT}.def del $(bin)${CONSTITUENT}.def
25        $(cleanup_silent) if exist $(bin)${CONSTITUENT}.exp del $(bin)${CONSTITUENT}.exp
26        $(cleanup_silent) if exist $(bin)${CONSTITUENT}.dll del $(bin)${CONSTITUENT}.dll
27        $(cleanup_silent) if exist $(bin)${CONSTITUENT}.dll.manifest del $(bin)${CONSTITUENT}.dll.manifest
28        $(cleanup_silent) if exist $(bin)${CONSTITUENT}.pdb del $(bin)${CONSTITUENT}.pdb
29
30
31install_dir = $(CMTINSTALLAREA)\$(tag)\lib
32${CONSTITUENT}installlibname = $(library_prefix)${CONSTITUENT}$(library_suffix).lib
33${CONSTITUENT}installdllname = $(library_prefix)${CONSTITUENT}$(library_suffix).dll
34${CONSTITUENT}installpdbname = $(library_prefix)${CONSTITUENT}$(library_suffix).pdb
35
36${CONSTITUENT} :: ${CONSTITUENT}install ;
37
38install :: ${CONSTITUENT}install ;
39
40!IF "$(vsCONFIG)" == "Debug"
41${CONSTITUENT}install :: $(${CONSTITUENT}shstamp) $(install_dir)\$(${CONSTITUENT}installlibname) $(install_dir)\$(${CONSTITUENT}installdllname) $(install_dir)\$(${CONSTITUENT}installpdbname)
42!if "$(CMTINSTALLAREA)" != ""
43        $(echo) "installation done"
44!endif
45
46!ELSE
47
48${CONSTITUENT}install :: $(${CONSTITUENT}shstamp) $(install_dir)\$(${CONSTITUENT}installlibname) $(install_dir)\$(${CONSTITUENT}installdllname)
49!if "$(CMTINSTALLAREA)" != ""
50        $(echo) "installation done"
51!endif
52!ENDIF
53
54$(install_dir)\$(${CONSTITUENT}installlibname) :: $(bin)$(${CONSTITUENT}installlibname)
55!if "$(CMTINSTALLAREA)" != ""
56        $(install_echo) $(@F) into $(@D)
57        $(install_silent) $(cmt_install_action) "$(BIN)" "$(${CONSTITUENT}installlibname)" "$(install_dir)"
58!endif
59
60$(install_dir)\$(${CONSTITUENT}installdllname) :: $(bin)$(${CONSTITUENT}installdllname)
61!if "$(CMTINSTALLAREA)" != ""
62        $(install_echo) $(@F) into $(@D)
63        $(install_silent) $(cmt_install_action) "$(BIN)" "$(${CONSTITUENT}installdllname)" "$(install_dir)"
64!endif
65
66$(install_dir)\$(${CONSTITUENT}installpdbname) :: $(bin)$(${CONSTITUENT}installpdbname)
67!if "$(CMTINSTALLAREA)" != ""
68        $(install_echo) $(@F) into $(@D)
69        $(install_silent) $(cmt_install_action) "$(BIN)" "$(${CONSTITUENT}installpdbname)" "$(install_dir)"
70!endif
71
72##${CONSTITUENT}clean :: ${CONSTITUENT}uninstall
73
74uninstall :: ${CONSTITUENT}uninstall ;
75
76${CONSTITUENT}uninstall ::
77!if "$(CMTINSTALLAREA)" != ""
78        $(cleanup_echo) "$(${CONSTITUENT}installlibname)" from "$(install_dir)"
79        $(cleanup_silent) $(cmt_uninstall_action) "$(BIN)" "$(${CONSTITUENT}installlibname)" "$(install_dir)"
80        $(cleanup_echo) "$(${CONSTITUENT}installdllname)" from "$(install_dir)"
81        $(cleanup_silent) $(cmt_uninstall_action) "$(BIN)" "$(${CONSTITUENT}installdllname)" "$(install_dir)"
82!endif
83
84#-- end of libary -----------------------
Note: See TracBrowser for help on using the repository browser.