Makefile revision 1.58
11.58Stv#	$NetBSD: Makefile,v 1.58 1998/07/24 16:48:47 tv Exp $
21.32Scgd
31.32Scgd.include <bsd.own.mk>			# for configuration variables.
41.4Scgd
51.58StvHAVE_GCC28!=	${CXX} --version | egrep "^(2\.8|egcs)" ; echo
61.58Stv
71.4Scgd# NOTE THAT etc *DOES NOT* BELONG IN THE LIST BELOW
81.2Scgd
91.52SmycroftSUBDIR+= lib include bin libexec sbin usr.bin usr.sbin share sys
101.36Sexplorer
111.36Sexplorer.if exists(games)
121.36SexplorerSUBDIR+= games
131.36Sexplorer.endif
141.36Sexplorer
151.8ScgdSUBDIR+= gnu
161.52Smycroft# This is needed for libstdc++ and gen-params.
171.52Smycroftincludes-gnu: includes-include includes-sys
181.9Scgd
191.21Scgd.if exists(domestic) && !defined(EXPORTABLE_SYSTEM)
201.21ScgdSUBDIR+= domestic
211.21Scgd.endif
221.21Scgd
231.13Sbrezak.if exists(regress)
241.9Scgd.ifmake !(install)
251.9ScgdSUBDIR+= regress
261.9Scgd.endif
271.9Scgd
281.10Scgdregression-tests:
291.10Scgd	@echo Running regression tests...
301.22Scgd	@(cd ${.CURDIR}/regress && ${MAKE} regress)
311.13Sbrezak.endif
321.20Scgd
331.26Stlsbeforeinstall:
341.45Sperry.ifmake build
351.45Sperry	@echo -n "Build started at: "
361.45Sperry	@date
371.45Sperry.endif
381.26Stls.ifndef DESTDIR
391.26Stls	(cd ${.CURDIR}/etc && ${MAKE} DESTDIR=/ distrib-dirs)
401.31Stls.else
411.31Stls	(cd ${.CURDIR}/etc && ${MAKE} distrib-dirs)
421.26Stls.endif
431.15Scgd
441.15Scgdafterinstall:
451.19Scgd.ifndef NOMAN
461.22Scgd	(cd ${.CURDIR}/share/man && ${MAKE} makedb)
471.45Sperry.endif
481.15Scgd
491.43Sthorpejbuild: beforeinstall
501.32Scgd	(cd ${.CURDIR}/share/mk && ${MAKE} install)
511.47Sthorpej	(cd ${.CURDIR}/share/tmac && ${MAKE} && ${MAKE} install)
521.39Schristos.if !defined(UPDATE)
531.17Scgd	${MAKE} cleandir
541.39Schristos.endif
551.51Stv	${MAKE} includes
561.38Scgd	(cd ${.CURDIR}/lib/csu && ${MAKE} depend && ${MAKE} && ${MAKE} install)
571.22Scgd	(cd ${.CURDIR}/lib && ${MAKE} depend && ${MAKE} && ${MAKE} install)
581.22Scgd	(cd ${.CURDIR}/gnu/lib && ${MAKE} depend && ${MAKE} && ${MAKE} install)
591.57Sperry	(cd ${.CURDIR}/gnu/usr.bin/gcc/libgcc && ${MAKE} depend && ${MAKE} && ${MAKE} install)
601.32Scgd.if exists(domestic) && !defined(EXPORTABLE_SYSTEM)
611.46Sthorpej# libtelnet depends on libdes and libkrb.  libkrb depends on
621.46Sthorpej# libcom_err.
631.49Slukem.if exists(domestic/lib/libdes)
641.46Sthorpej	(cd ${.CURDIR}/domestic/lib/libdes && \
651.46Sthorpej	    ${MAKE} depend && ${MAKE} && ${MAKE} install)
661.49Slukem.endif
671.49Slukem.if exists(domestic/lib/libcom_err)
681.46Sthorpej	(cd ${.CURDIR}/domestic/lib/libcom_err && \
691.46Sthorpej	    ${MAKE} depend && ${MAKE} && ${MAKE} install)
701.49Slukem.endif
711.49Slukem.if exists(domestic/lib/libkrb)
721.44Smellon	(cd ${.CURDIR}/domestic/lib/libkrb && \
731.44Smellon	    ${MAKE} depend && ${MAKE} && ${MAKE} install)
741.49Slukem.endif
751.37Scjs	(cd ${.CURDIR}/domestic/lib/ && ${MAKE} depend && ${MAKE} && \
761.32Scgd	    ${MAKE} install)
771.21Scgd.endif
781.17Scgd	${MAKE} depend && ${MAKE} && ${MAKE} install
791.55Stv.if defined(USE_EGCS)
801.58Stv.if defined(DESTDIR)
811.58Stv.if (${HAVE_GCC28} == "")
821.58Stv	@echo '***** WARNING ***** Your system compiler is not GCC 2.8 or higher,'
831.58Stv	@echo 'and you have built a distribution with GCC 2.8 and DESTDIR set.'
841.58Stv	@echo 'You will need to rebuild libgcc from gnu/usr.bin/egcs/libgcc'
851.58Stv	@echo 'in order to have full C++ support in the binary set.'
861.58Stv.endif # HAVE_GCC28
871.58Stv.else
881.55Stv	(cd ${.CURDIR}/gnu/usr.bin/egcs/libgcc &&\
891.55Stv	    ${MAKE} depend && ${MAKE} && ${MAKE} install)
901.58Stv.endif # DESTDIR
911.55Stv.endif # USE_EGCS
921.50Smellon	@echo -n "Build finished at: "
931.50Smellon	@date
941.1Scgd
951.1Scgd.include <bsd.subdir.mk>
96