Mercurial > emacs
comparison Makefile.in @ 7704:022727dbe5f3
(install-arch-indep): Use /bin/pwd uniformly, not pwd.
(uninstall): Use /bin/pwd.
(blessmail): Depend on src.
(all): Don't depend on blessmail.
(src/paths.h): Don't force recomputation.
(paths-force): New target; force recomputation of paths.h.
(all): Depend on paths-force.
(src, lib-src): Depend on src/paths.h.
author | Richard M. Stallman <rms@gnu.org> |
---|---|
date | Fri, 27 May 1994 08:17:46 +0000 |
parents | 1ddcf94fe9c9 |
children | d836abb05e48 |
comparison
equal
deleted
inserted
replaced
7703:2b7b11a5e1e6 | 7704:022727dbe5f3 |
---|---|
193 # avoid nuking an existing dir file, so we don't do that here; | 193 # avoid nuking an existing dir file, so we don't do that here; |
194 # instead, we have written out explicit code in the `install' targets. | 194 # instead, we have written out explicit code in the `install' targets. |
195 COPYDIR = ${srcdir}/etc ${srcdir}/lisp | 195 COPYDIR = ${srcdir}/etc ${srcdir}/lisp |
196 COPYDESTS = ${etcdir} ${lispdir} | 196 COPYDESTS = ${etcdir} ${lispdir} |
197 | 197 |
198 all: src/paths.h ${SUBDIR} blessmail | 198 all: paths-force ${SUBDIR} |
199 | 199 |
200 removenullpaths=sed -e 's/^://' -e 's/:$$//' -e 's/::/:/' | 200 removenullpaths=sed -e 's/^://' -e 's/:$$//' -e 's/::/:/' |
201 | 201 |
202 # We force the rebuilding of src/paths.h because the user might give | |
203 # make different values for the various directories. Since we use | |
204 # move-if-change, src/paths.h only actually changes if the user did | |
205 # something notable, so the only unnecessary work we do is in building | |
206 # src/paths.h.tmp, which isn't much. | |
207 # Note that sed is not in /bin on 386bsd. | 202 # Note that sed is not in /bin on 386bsd. |
208 src/paths.h: Makefile ${srcdir}/src/paths.h.in FRC.src.paths.h | 203 src/paths.h: Makefile ${srcdir}/src/paths.h.in |
209 @echo "Producing \`src/paths.h' from \`src/paths.h.in'." | 204 @echo "Producing \`src/paths.h' from \`src/paths.h.in'." |
210 @(lisppath=`echo ${lisppath} | ${removenullpaths}` ; \ | 205 @(lisppath=`echo ${lisppath} | ${removenullpaths}` ; \ |
211 buildlisppath=`echo ${buildlisppath} | ${removenullpaths}` ; \ | 206 buildlisppath=`echo ${buildlisppath} | ${removenullpaths}` ; \ |
212 sed < ${srcdir}/src/paths.h.in > src/paths.h.tmp \ | 207 sed < ${srcdir}/src/paths.h.in > src/paths.h.tmp \ |
213 -e 's;\(#.*PATH_LOADSEARCH\).*$$;\1 "'$${lisppath}'";' \ | 208 -e 's;\(#.*PATH_LOADSEARCH\).*$$;\1 "'$${lisppath}'";' \ |
217 -e 's;\(#.*PATH_DATA\).*$$;\1 "${etcdir}";' \ | 212 -e 's;\(#.*PATH_DATA\).*$$;\1 "${etcdir}";' \ |
218 -e 's;\(#.*PATH_DOC\).*$$;\1 "${docdir}";' \ | 213 -e 's;\(#.*PATH_DOC\).*$$;\1 "${docdir}";' \ |
219 -e 's;\(#.*PATH_LOCK\).*$$;\1 "${lockdir}/";') | 214 -e 's;\(#.*PATH_LOCK\).*$$;\1 "${lockdir}/";') |
220 @${srcdir}/move-if-change src/paths.h.tmp src/paths.h | 215 @${srcdir}/move-if-change src/paths.h.tmp src/paths.h |
221 | 216 |
222 src: lib-src FRC.src | 217 # For `make all', |
218 # we force the rebuilding of src/paths.h because the user might give | |
219 # make different values for the various directories. Since we use | |
220 # move-if-change, src/paths.h only actually changes if the user did | |
221 # something notable, so the only unnecessary work we do is in building | |
222 # src/paths.h.tmp, which isn't much. | |
223 # Note that sed is not in /bin on 386bsd. | |
224 paths-force: FRC.src.paths.h | |
225 @echo "Producing \`src/paths.h' from \`src/paths.h.in'." | |
226 @(lisppath=`echo ${lisppath} | ${removenullpaths}` ; \ | |
227 buildlisppath=`echo ${buildlisppath} | ${removenullpaths}` ; \ | |
228 sed < ${srcdir}/src/paths.h.in > src/paths.h.tmp \ | |
229 -e 's;\(#.*PATH_LOADSEARCH\).*$$;\1 "'$${lisppath}'";' \ | |
230 -e 's;\(#.*PATH_DUMPLOADSEARCH\).*$$;\1 "'$${buildlisppath}'";' \ | |
231 -e 's;\(#.*PATH_EXEC\).*$$;\1 "${archlibdir}";' \ | |
232 -e 's;\(#.*PATH_INFO\).*$$;\1 "${infodir}";' \ | |
233 -e 's;\(#.*PATH_DATA\).*$$;\1 "${etcdir}";' \ | |
234 -e 's;\(#.*PATH_DOC\).*$$;\1 "${docdir}";' \ | |
235 -e 's;\(#.*PATH_LOCK\).*$$;\1 "${lockdir}/";') | |
236 @${srcdir}/move-if-change src/paths.h.tmp src/paths.h | |
237 | |
238 src: lib-src FRC.src src/paths.h | |
223 | 239 |
224 # This ought to depend on src/paths.h, so that in parallel make | 240 # This ought to depend on src/paths.h, so that in parallel make |
225 # src/paths.h will be available for the compilations in lib-src. | 241 # src/paths.h will be available for the compilations in lib-src. |
226 # But that causes trouble in `make install' if a different prefix | 242 # But that causes trouble in `make install' if a different prefix |
227 # is specified at that time. | 243 # is specified at that time. |
228 lib-src: FRC.lib-src | 244 lib-src: FRC.lib-src src/paths.h |
229 | 245 |
230 .RECURSIVE: ${SUBDIR} | 246 .RECURSIVE: ${SUBDIR} |
231 | 247 |
232 ${SUBDIR}: ${SUBDIR_MAKEFILES} FRC | 248 ${SUBDIR}: ${SUBDIR_MAKEFILES} FRC |
233 cd $@; $(MAKE) all $(MFLAGS) \ | 249 cd $@; $(MAKE) all $(MFLAGS) \ |
234 CC='${CC}' CFLAGS='${CFLAGS}' CPPFLAGS='${CPPFLAGS}' \ | 250 CC='${CC}' CFLAGS='${CFLAGS}' CPPFLAGS='${CPPFLAGS}' \ |
235 LDFLAGS='${LDFLAGS}' MAKE='${MAKE}' | 251 LDFLAGS='${LDFLAGS}' MAKE='${MAKE}' |
236 | 252 |
237 blessmail: ${SUBDIR_MAKEFILES} FRC | 253 blessmail: ${SUBDIR_MAKEFILES} src FRC |
238 cd lib-src; $(MAKE) maybe-blessmail $(MFLAGS) MAKE='${MAKE}' | 254 cd lib-src; $(MAKE) maybe-blessmail $(MFLAGS) MAKE='${MAKE}' |
239 | 255 |
240 Makefile: Makefile.in config.status | 256 Makefile: Makefile.in config.status |
241 ./config.status | 257 ./config.status |
242 | 258 |
287 ### Note that we copy the DOC-* files from the build etc directory | 303 ### Note that we copy the DOC-* files from the build etc directory |
288 ### as well as lots of things from ${srcdir}/etc. | 304 ### as well as lots of things from ${srcdir}/etc. |
289 install-arch-indep: mkdir | 305 install-arch-indep: mkdir |
290 -set ${COPYDESTS} ; \ | 306 -set ${COPYDESTS} ; \ |
291 for dir in ${COPYDIR} ; do \ | 307 for dir in ${COPYDIR} ; do \ |
292 if [ `(cd $$1 && pwd)` != `(cd $${dir} && pwd)` ] ; then \ | 308 if [ `(cd $$1 && /bin/pwd)` != `(cd $${dir} && /bin/pwd)` ] ; then \ |
293 rm -rf $$1 ; \ | 309 rm -rf $$1 ; \ |
294 fi ; \ | 310 fi ; \ |
295 shift ; \ | 311 shift ; \ |
296 done | 312 done |
297 -set ${COPYDESTS} ; \ | 313 -set ${COPYDESTS} ; \ |
312 if [ `(cd ./etc; /bin/pwd)` != `(cd ${docdir}; /bin/pwd)` ]; \ | 328 if [ `(cd ./etc; /bin/pwd)` != `(cd ${docdir}; /bin/pwd)` ]; \ |
313 then \ | 329 then \ |
314 echo "Copying etc/DOC* ..." ; \ | 330 echo "Copying etc/DOC* ..." ; \ |
315 (cd etc; tar -cf - DOC*)|(cd ${docdir}; umask 0; tar -xvf - ); \ | 331 (cd etc; tar -cf - DOC*)|(cd ${docdir}; umask 0; tar -xvf - ); \ |
316 else true; fi | 332 else true; fi |
317 thisdir=`pwd`; \ | 333 thisdir=`/bin/pwd`; \ |
318 if [ `(cd ${srcdir}/info && /bin/pwd)` != `(cd ${infodir} && /bin/pwd)` ]; \ | 334 if [ `(cd ${srcdir}/info && /bin/pwd)` != `(cd ${infodir} && /bin/pwd)` ]; \ |
319 then \ | 335 then \ |
320 (cd ${srcdir}/info ; \ | 336 (cd ${srcdir}/info ; \ |
321 if [ ! -f ${infodir}/dir ] && [ -f dir ]; then \ | 337 if [ ! -f ${infodir}/dir ] && [ -f dir ]; then \ |
322 (cd $${thisdir}; ${INSTALL_DATA} ${srcdir}/info/dir ${infodir}/dir); \ | 338 (cd $${thisdir}; ${INSTALL_DATA} ${srcdir}/info/dir ${infodir}/dir); \ |
323 fi ; \ | 339 fi ; \ |
324 for f in cl* dired-x* emacs* forms* gnus* info* sc* vip* ; do \ | 340 for f in cl* dired-x* emacs* forms* gnus* info* sc* vip* ; do \ |
325 (cd $${thisdir}; ${INSTALL_DATA} ${srcdir}/info/$$f ${infodir}/$$f); \ | 341 (cd $${thisdir}; ${INSTALL_DATA} ${srcdir}/info/$$f ${infodir}/$$f); \ |
326 done); \ | 342 done); \ |
327 else true; fi | 343 else true; fi |
328 thisdir=`pwd`; cd ${srcdir}/etc; for page in emacs etags ctags ; do \ | 344 thisdir=`/bin/pwd`; cd ${srcdir}/etc; for page in emacs etags ctags ; do \ |
329 (cd $${thisdir}; ${INSTALL_DATA} ${srcdir}/etc/$${page}.1 ${mandir}/$${page}${manext}); \ | 345 (cd $${thisdir}; ${INSTALL_DATA} ${srcdir}/etc/$${page}.1 ${mandir}/$${page}${manext}); \ |
330 done | 346 done |
331 | 347 |
332 ### Build all the directories we're going to install Emacs in. Since | 348 ### Build all the directories we're going to install Emacs in. Since |
333 ### we may be creating several layers of directories (for example, | 349 ### we may be creating several layers of directories (for example, |
349 $(MAKE) $(MFLAGS) uninstall \ | 365 $(MAKE) $(MFLAGS) uninstall \ |
350 prefix=${prefix} exec_prefix=${exec_prefix} \ | 366 prefix=${prefix} exec_prefix=${exec_prefix} \ |
351 bindir=${bindir} libdir=${libdir} archlibdir=${archlibdir}) | 367 bindir=${bindir} libdir=${libdir} archlibdir=${archlibdir}) |
352 for dir in ${lispdir} ${etcdir} ; do \ | 368 for dir in ${lispdir} ${etcdir} ; do \ |
353 if [ -d $${dir} ]; then \ | 369 if [ -d $${dir} ]; then \ |
354 case `(cd $${dir} ; pwd)` in \ | 370 case `(cd $${dir} ; /bin/pwd)` in \ |
355 `(cd ${srcdir} ; pwd)`* ) ;; \ | 371 `(cd ${srcdir} ; /bin/pwd)`* ) ;; \ |
356 * ) rm -rf $${dir} ;; \ | 372 * ) rm -rf $${dir} ;; \ |
357 esac ; \ | 373 esac ; \ |
358 case $${dir} in \ | 374 case $${dir} in \ |
359 ${datadir}/emacs/${version}/* ) \ | 375 ${datadir}/emacs/${version}/* ) \ |
360 rm -rf ${datadir}/emacs/${version} \ | 376 rm -rf ${datadir}/emacs/${version} \ |