[BACK]Return to Makefile CVS log [TXT][DIR] Up to [cvs.NetBSD.org] / src

Annotation of src/Makefile, Revision 1.99

1.99    ! perry       1: #      $NetBSD: Makefile,v 1.98 1999/07/12 21:53:52 thorpej Exp $
1.95      cjs         2:
                      3: # This is the top-level makefile for building NetBSD. For an outline of
                      4: # how to build a snapshot or release, as well as other release engineering
                      5: # information, see http://www.netbsd.org/developers/releng/index.html
                      6: #
                      7: # Not everything you can set or do is documented in this makefile. In
                      8: # particular, you should review the files in /usr/share/mk (especially
                      9: # bsd.README) for general information on building programs and writing
                     10: # Makefiles within this structure, and see the comments in src/etc/Makefile
                     11: # for further information on installation and release set options.
                     12: #
                     13: # Variables listed below can be set on the make command line (highest
                     14: # priority), in /etc/mk.conf (middle priority), or in the environment
                     15: # (lowest priority).
                     16: #
                     17: # Variables:
                     18: #   NBUILDJOBS is the number of jobs to start in parallel during a
                     19: #      'make build'. It defaults to 1.
                     20: #   MKMAN, if set to `no', will prevent building of manual pages.
                     21: #   MKSHARE, if set to `no', will prevent building and installing
                     22: #      anything in /usr/share.
                     23: #   UPDATE will avoid a `make cleandir' at the start of `make build',
                     24: #      as well as having the effects listed in /usr/share/mk/bsd.README.
                     25: #   DESTDIR is the target directory for installation of the compiled
                     26: #      software. It defaults to /. Note that programs are built against
                     27: #      libraries installed in DESTDIR.
                     28: #
                     29: # Targets:
                     30: #   build: builds a full release of netbsd in DESTDIR.
                     31: #   release: does a `make build,' and then tars up the DESTDIR files
                     32: #      into RELEASEDIR, in release(7) format. (See etc/Makefile for
                     33: #      more information on this.)
                     34: #   snapshot: a synonym for release.
1.32      cgd        35:
                     36: .include <bsd.own.mk>                  # for configuration variables.
1.4       cgd        37:
1.76      bouyer     38:
1.58      tv         39: HAVE_GCC28!=   ${CXX} --version | egrep "^(2\.8|egcs)" ; echo
                     40:
1.76      bouyer     41: .if defined(NBUILDJOBS)
                     42: _J= -j${NBUILDJOBS}
                     43: .endif
                     44:
1.4       cgd        45: # NOTE THAT etc *DOES NOT* BELONG IN THE LIST BELOW
1.2       cgd        46:
1.52      mycroft    47: SUBDIR+= lib include bin libexec sbin usr.bin usr.sbin share sys
1.36      explorer   48:
                     49: .if exists(games)
                     50: SUBDIR+= games
                     51: .endif
                     52:
1.8       cgd        53: SUBDIR+= gnu
1.52      mycroft    54: # This is needed for libstdc++ and gen-params.
                     55: includes-gnu: includes-include includes-sys
1.21      cgd        56:
1.13      brezak     57: .if exists(regress)
1.9       cgd        58: .ifmake !(install)
                     59: SUBDIR+= regress
                     60: .endif
                     61:
1.10      cgd        62: regression-tests:
                     63:        @echo Running regression tests...
1.22      cgd        64:        @(cd ${.CURDIR}/regress && ${MAKE} regress)
1.13      brezak     65: .endif
1.20      cgd        66:
1.26      tls        67: beforeinstall:
1.45      perry      68: .ifmake build
                     69:        @echo -n "Build started at: "
                     70:        @date
                     71: .endif
1.26      tls        72: .ifndef DESTDIR
                     73:        (cd ${.CURDIR}/etc && ${MAKE} DESTDIR=/ distrib-dirs)
1.31      tls        74: .else
                     75:        (cd ${.CURDIR}/etc && ${MAKE} distrib-dirs)
1.26      tls        76: .endif
1.15      cgd        77:
                     78: afterinstall:
1.86      lukem      79: .if ${MKMAN} != "no" && !defined(_BUILD)
1.81      scottr     80:        ${MAKE} whatis.db
                     81: .endif
                     82:
                     83: whatis.db:
1.22      cgd        84:        (cd ${.CURDIR}/share/man && ${MAKE} makedb)
1.15      cgd        85:
1.84      tv         86: # wrt info/dir below:  It's safe to move this over top of /usr/share/info/dir,
                     87: # as the build will automatically remove/replace the non-pkg entries there.
                     88:
1.43      thorpej    89: build: beforeinstall
1.96      scottr     90: .if defined(FORCE_DOMESTIC)
                     91:        @echo '*** CAPUTE!'
                     92:        @echo '    The FORCE_DOMESTIC flag is not compatible with "make build".'
                     93:        @echo '    Please correct the problem and try again.'
                     94:        @false
                     95: .endif
1.86      lukem      96: .if ${MKSHARE} != "no"
1.32      cgd        97:        (cd ${.CURDIR}/share/mk && ${MAKE} install)
1.47      thorpej    98:        (cd ${.CURDIR}/share/tmac && ${MAKE} && ${MAKE} install)
1.68      lukem      99: .endif
1.39      christos  100: .if !defined(UPDATE)
1.17      cgd       101:        ${MAKE} cleandir
1.39      christos  102: .endif
1.75      tv        103: .if empty(HAVE_GCC28)
1.71      mycroft   104: .if defined(DESTDIR)
                    105:        @echo "*** CAPUTE!"
1.84      tv        106:        @echo "    You attempted to compile the world without egcs.  You must"
1.71      mycroft   107:        @echo "    first install a native egcs compiler."
1.84      tv        108:        @false
1.71      mycroft   109: .else
                    110:        (cd ${.CURDIR}/gnu/usr.bin/egcs && \
1.99    ! perry     111:            ${MAKE} ${_J} dependall MKMAN=no && \
1.86      lukem     112:            ${MAKE} MKMAN=no install && ${MAKE} cleandir)
1.71      mycroft   113: .endif
                    114: .endif
1.93      scottr    115:        ${MAKE} includes
1.61      mycroft   116:        (cd ${.CURDIR}/lib/csu && \
1.99    ! perry     117:            ${MAKE} ${_J} dependall MKMAN=no && \
1.86      lukem     118:            ${MAKE} MKMAN=no install)
1.61      mycroft   119:        (cd ${.CURDIR}/lib && \
1.99    ! perry     120:            ${MAKE} ${_J} dependall MKMAN=no && \
1.86      lukem     121:            ${MAKE} MKMAN=no install)
1.61      mycroft   122:        (cd ${.CURDIR}/gnu/lib && \
1.99    ! perry     123:            ${MAKE} ${_J} dependall MKMAN=no MKINFO=no && \
1.89      mellon    124:            ${MAKE} MKMAN=no MKINFO=no install)
1.99    ! perry     125:        ${MAKE} ${_J} dependall && ${MAKE} _BUILD= install
1.97      christos  126: .if defined(DOMESTIC) && !defined(EXPORTABLE_SYSTEM)
                    127:        (cd ${.CURDIR}/${DOMESTIC} && ${MAKE} ${_J} _SLAVE_BUILD= build)
1.49      lukem     128: .endif
1.81      scottr    129:        ${MAKE} whatis.db
1.50      mellon    130:        @echo -n "Build finished at: "
                    131:        @date
1.87      cjs       132:
                    133: release snapshot: build
1.91      scottr    134:        (cd ${.CURDIR}/etc && ${MAKE} INSTALL_DONE=1 release)
1.1       cgd       135:
                    136: .include <bsd.subdir.mk>

CVSweb <webmaster@jp.NetBSD.org>