gitignore: add infolib/etc UTF-8 locales
[oweals/cde.git] / cde / Imakefile
1 XCOMM $TOG: Imakefile /main/22 1999/01/18 10:38:29 samborn $
2 #define IHaveSubdirs
3 #define PassCDebugFlags CDEBUGFLAGS="$(CDEBUGFLAGS)"
4
5 CDE_RELEASE = 2.2.0
6
7 SUBDIRS = config util include lib programs databases admin
8 DOCSUBDIRS = config doc
9
10 MakeSubdirs($(SUBDIRS))
11
12 DependSubdirs($(SUBDIRS))
13
14 #define IHaveSpecialMakefileTarget
15 Makefile:: xmakefile
16 ImakeDependency(xmakefile)
17 xmakefile:: Imakefile
18         RMoveToBakFile(xmakefile)
19         $(IMAKE_CMD) -s xmakefile -DTOPDIR=$(TOP) -DCURDIR=$(CURRENT_DIR)
20
21
22 VerifyOS::
23         @echo ""
24         @echo Building on OSName.
25         @echo ""
26
27 includes::
28         MakeDir($(BUILDINCDIR))
29
30 XCOMM
31 XCOMM Watch out!!!  Make sure you do make includes after removing X11....
32 XCOMM
33 clean::
34         $(RM) -r $(BUILDINCDIR)
35         $(RM) -r $(BUILDLIBDIR)
36
37       WORLDOPTS = 
38       MAKE_OPTS = -f xmakefile
39
40 XCOMM 
41 XCOMM install; create the directories that we're going to need
42 XCOMM 
43
44 DIRS_TO_CREATE = $(USRLIBDIR) $(BINDIR) $(INCDIR) $(USRINCDIR) $(LIBDIR) $(XAPPLOADDIR)
45
46 MakeDirectories(install, $(DIRS_TO_CREATE))
47
48 XCOMM 
49 XCOMM Everything builds everything in the SUBDIRS directories
50 XCOMM 
51
52 Everything::
53         @echo ""
54         @echo "Rebuilding Release $(CDE_RELEASE) of CDE"
55         @echo ""
56         @date
57         @echo ""
58         MakeImakeDir()
59         -$(RM) xmakefile.bak; $(MV) xmakefile xmakefile.bak
60         $(MAKE) $(MFLAGS) -f xmakefile.bak xmakefile
61         $(MAKE) $(MFLAGS) $(MAKE_OPTS) Makefiles
62         $(MAKE) $(MFLAGS) $(MAKE_OPTS) Makefiles.doc
63         $(MAKE) $(MFLAGS) $(MAKE_OPTS) includes
64         $(MAKE) $(MFLAGS) $(MAKE_OPTS) includes.doc
65         $(MAKE) $(MFLAGS) $(MAKE_OPTS) depend
66         $(MAKE) $(MFLAGS) $(MAKE_OPTS) depend.doc
67         $(MAKE) $(MFLAGS) $(MAKE_OPTS) $(WORLDOPTS)
68         $(MAKE) $(MFLAGS) $(MAKE_OPTS) $(WORLDOPTS) all.doc
69         @echo ""
70         @date
71         @echo ""
72         @echo "Rebuild of Release $(CDE_RELEASE) of CDE complete."
73         @echo ""
74
75 Everything.dev::
76         @echo ""
77         @echo "Rebuilding Release $(CDE_RELEASE) of CDE excluding DOC"
78         @echo ""
79         @date
80         @echo ""
81         MakeImakeDir()
82         -$(RM) xmakefile.bak; $(MV) xmakefile xmakefile.bak
83         $(MAKE) $(MFLAGS) -f xmakefile.bak xmakefile
84         $(MAKE) $(MFLAGS) $(MAKE_OPTS) Makefiles
85         $(MAKE) $(MFLAGS) $(MAKE_OPTS) includes
86         $(MAKE) $(MFLAGS) $(MAKE_OPTS) depend
87         $(MAKE) $(MFLAGS) $(MAKE_OPTS) $(WORLDOPTS)
88         @echo ""
89         @date
90         @echo ""
91         @echo "Rebuild of Release $(CDE_RELEASE) of CDE excluding DOC complete."
92         @echo ""
93
94 XCOMM clean out link tree looking for stuff that should get checked in
95 dangerous_strip_clean::
96         make -k clean clean.doc
97         find . -type l -exec rm {} \;
98         find . \( \! \( -type d -o -name Makefile \) \) -print
99
100 XCOMM special target to determine if the xmakefile exists. 
101 XCOMM Works on both Unix and NMAKE.EXE
102 xmakefile-exists::
103
104
105 XCOMM 
106 XCOMM Everything.doc builds everything in the DOCSUBDIRS directories
107 XCOMM 
108
109 Everything.doc::
110         @echo ""
111         @echo "Rebuilding Release $(CDE_RELEASE) of DOC"
112         @echo ""
113         @date
114         @echo ""
115         MakeImakeDir()
116         -$(RM) xmakefile.bak; $(MV) xmakefile xmakefile.bak
117         $(MAKE) $(MFLAGS) -f xmakefile.bak xmakefile
118         $(MAKE) $(MFLAGS) $(MAKE_OPTS) Makefiles.doc
119         $(MAKE) $(MFLAGS) $(MAKE_OPTS) includes.doc
120         $(MAKE) $(MFLAGS) $(MAKE_OPTS) depend.doc
121         $(MAKE) $(MFLAGS) $(MAKE_OPTS) $(WORLDOPTS) all.doc
122         @echo ""
123         @date
124         @echo ""
125         @echo "Rebuild of Release $(CDE_RELEASE) of DOC complete."
126         @echo ""
127
128 NamedTargetSubdirs(install.doc,$(DOCSUBDIRS),"installing",DESTDIR=$(DESTDIR),install)
129 NamedTargetSubdirs(install.man.doc,$(DOCSUBDIRS),"installing man pages",DESTDIR=$(DESTDIR),install.man)
130 NamedCleanSubdirs(clean.doc,$(DOCSUBDIRS))
131 NamedTagSubdirs(tags.doc,$(DOCSUBDIRS))
132 MakeMakeSubdirs($(DOCSUBDIRS),Makefiles.doc)
133 NamedTargetSubdirs(includes.doc,$(DOCSUBDIRS),including,NullParameter,includes)
134 NamedTargetSubdirs(depend.doc,$(DOCSUBDIRS),depending,NullParameter,depend)
135 NamedMakeSubdirs(all.doc, $(DOCSUBDIRS))