summaryrefslogtreecommitdiff
path: root/xc/Imakefile
blob: 68b2e20b4b55de0b388656beaaddf764c055b466 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
#define IHaveSubdirs
#define PassCDebugFlags

      WORLDOPTS = -k
     CHECKFNSRC = $(UTILSRC)/checkfn
        CHECKFN = $(CHECKFNSRC)/checkfn

/**/#
/**/# The order given here is necessary for some things to build; note that in
/**/# R4beta, the "fonts" and "rgb" directories will become subdirectories of
/**/# server so that BuildServer is no longer necessary.
/**/#
#if BuildServer
SERVERDIRSTOMAKE = server fonts rgb
#endif
#if BuildExamples
EXAMPLESDIRS = examples
#endif
        SUBDIRS = config include lib extensions $(SERVERDIRSTOMAKE) \
			clients demos $(EXAMPLESDIRS) util doc
  LNINSTALLDIRS = $(EXTENSIONSRC) $(LIBSRC)

MakeSubdirs($(SUBDIRS))

MakeDirectories(install.ln, $(LINTLIBDIR))

MakeLintSubdirs($(LNINSTALLDIRS),install.ln,install.ln)

MakeLintSubdirs($(LNINSTALLDIRS),external.ln,lintlib)


/**/#
/**/# Watch out!!!  Make sure you do make includes after removing X11....
/**/#
clean::
	$(RM) -r X11

includes::
	$(RM) -r X11


/**/#
/**/# before depending, be sure to have run make includes
/**/#
/* depend::  includes */

DependSubdirs($(SUBDIRS))


/**/# 
/**/# install stuff; create the directories that we are going to need
/**/# 

#if BuildServer
  DIRS_SERVER = $(FONTDIR) /* $(ADMDIR) */
#endif
#if InstallxinitConfig
   DIRS_XINIT = $(XINITDIR)
#endif
#if InstallxdmConfig
     DIRS_XDM = $(XDMDIR)
#endif
#if InstallAppDefFiles
  DIRS_APPDEF = $(XAPPLOADDIR)
#endif

 DIRS_CONTRIB = /* $(AWMDIR) $(TWMDIR) */

DIRS_TO_CREATE = $(DIRS_SERVER) /* $(LINTLIBDIR) */ \
	$(USRLIBDIR) $(BINDIR) $(INCDIR) $(LIBDIR) $(CONFIGDIR) \
	$(DIRS_XINIT) $(DIRS_XDM) $(DIRS_APPDEF) $(DIRS_CONTRIB)

MakeDirectories(install, $(DIRS_TO_CREATE))

MakeDirectories(install.man, $(MANPATH) $(MANDIR) $(LIBMANDIR))
InstallManPage(X,$(MANDIR))
InstallManPageLong(Consortium,$(MANDIR),XConsortium)
InstallManPageLong(Standards,$(MANDIR),XStandards)


/**/# do not name your log file make.log when you run this ...
World::
	@echo ""
	@echo "Building Release 4 of the X Window System"
	@echo ""
	@echo "##############################################################"
	@echo "# Did you remember to check the configuration parameters in  #"
	@echo "# the directory ./config and set BOOTSTRAPCFLAGS if needed?  #"
	@echo "##############################################################"
	@echo ""
	@date
	@echo ""
	cd $(IMAKESRC); $(MAKE) -f Makefile.ini clean; $(MAKE) -f Makefile.ini BOOTSTRAPCFLAGS="$(BOOTSTRAPCFLAGS)"
	-$(MV) Makefile Makefile.bak
	$(MAKE) -f Makefile.bak Makefile
	$(MAKE) Makefiles
	$(MAKE) clean
	$(MAKE) includes
	$(MAKE) depend
	$(MAKE) $(WORLDOPTS)
	@echo ""
	@date
	@echo ""
	@echo "Full build of Release 4 of the X Window System complete."
	@echo ""

Everything::
	@echo ""
	@echo "Rebuilding Release 4 of the X Window System"
	@echo ""
	@echo "##############################################################"
	@echo "# Did you remember to check the configuration parameters in  #"
	@echo "# the directory ./config and set BOOTSTRAPCFLAGS if needed?  #"
	@echo "##############################################################"
	@echo ""
	@date
	@echo ""
	cd $(IMAKESRC); $(MAKE) -f Makefile.ini BOOTSTRAPCFLAGS="$(BOOTSTRAPCFLAGS)"
	-$(MV) Makefile Makefile.bak
	$(MAKE) -f Makefile.bak Makefile
	$(MAKE) Makefiles
	$(MAKE) includes
	$(MAKE) depend
	$(MAKE) $(WORLDOPTS)
	@echo ""
	@date
	@echo ""
	@echo "Rebuild of Release 4 of the X Window System complete."
	@echo ""


RELNOTES.PS::  RELNOTES.ms
	tbl RELNOTES.ms | ptroff -t -ms >$@

RELNOTES.lpt:  RELNOTES.ms
	tbl RELNOTES.ms | nroff -ms >$@

RELNOTES.txt:  RELNOTES.ms
	tbl RELNOTES.ms | nroff -ms | colcrt >$@

    RESOLUTION = 75

RELNOTES.dit:  RELNOTES.ms
	tbl RELNOTES.ms | ditroff -TX$(RESOLUTION) -ms >$@

preview::
	xditview '| tbl RELNOTES.ms | ditroff -TX$(RESOLUTION) -ms'


CHANGES.ALL::
	$(RM) $@
	(for i in `find . -name CHANGES -print`; do \
	echo $$i; echo ""; cat $$i; echo ""; \
	echo "==========================================================="; \
	done) >$@


InstallSubdirs(config)

/*
 * This section used for generating distributions will not be useful to most
 * people.
 */
/**/# check all filenames for length, letters, and content
checkfilenames::  $(CHECKFNSRC)/checkfn
	@find . -type d \! -name RCS -exec $(CHECKFNSRC)/find.sh $(CHECKFN) {} \;

/**/# clean out link tree looking for stuff that should get checked in
flushlinks::
	make -k clean
	find . -type l -exec rm {} \;
	find . \( \! \( -type d -o -name Makefile \) \) -print

/**/# rebuild the Makefiles in the master source tree
mastermakefiles::
	cd $(IMAKESRC); $(MAKE) -f Makefile.ini clean; $(MAKE) -f Makefile.ini BOOTSTRAPCFLAGS="$(BOOTSTRAPCFLAGS)"
	-$(MV) Makefile Makefile.bak
	$(MAKE) -f Makefile.bak Makefile
	$(MAKE) Makefiles
	cd $(IMAKESRC); $(MAKE) clean