pkgsrc/mk/build/bsd.build-vars.mk
jlam e31200b87c Refactor configure, build, test and wrapper phases out of bsd.pkg.mk
and into their own directories.  Also do some cleanups with build/_build
and pkginstall -- we get rid of _build and simply run pkginstall as
part of the "build" target.

Introduce a new mechanism to handle varying directory depths under
${WRKSRC} in which we find files to override, e.g. configure, config.*,
libtool, etc.  OVERRIDE_DIRDEPTH is a package-settable variable that
specifies how far under ${WRKSRC} the various targets should look,
and it defaults to "2".  We preserve the
meaning of the various *_OVERRIDE variables, so if they are defined,
then their values supersede the OVERRIDE_DIRDEPTH mechanism.

devel/tla will need to specially set OVERRIDE_DIRDEPTH to 3 (see log
for revision 1.1857 for bsd.pkg.mk -- to be done in a separate commit.
2006-07-05 06:09:15 +00:00

47 lines
1.6 KiB
Makefile

# $NetBSD: bsd.build-vars.mk,v 1.1 2006/07/05 06:09:15 jlam Exp $
#
# BUILD_DIRS is the list of directories in which to perform the build
# process. If the directories are relative paths, then they
# are assumed to be relative to ${WRKSRC}.
#
# MAKE_PROGRAM is the path to the make executable that is run to
# process the source makefiles. This is always overridden by
# the tools framework in pkgsrc/mk/tools/make.mk, but we provide
# a default here for documentation purposes.
#
# MAKE_ENV is the shell environment that is exported to the make
# process.
#
# MAKE_FLAGS is a list of arguments that is pass to the make process.
#
# MAKEFILE is the path to the makefile that is processed by the make
# executable. If the path is relative, then it is assumed to
# be relative to each directory listed in BUILD_DIRS.
#
BUILD_DIRS?= ${CONFIGURE_DIRS}
MAKE_PROGRAM?= ${MAKE}
MAKE_ENV?= # empty
MAKE_FLAGS?= # empty
MAKEFILE?= Makefile
MAKE_ENV+= ${ALL_ENV}
MAKE_ENV+= ${NO_EXPORT_CPP:D:UCPP=${CPP:Q}}
MAKE_ENV+= LINK_ALL_LIBGCC_HACK=${LINK_ALL_LIBGCC_HACK:Q}
MAKE_ENV+= LOCALBASE=${LOCALBASE:Q}
MAKE_ENV+= NO_WHOLE_ARCHIVE_FLAG=${NO_WHOLE_ARCHIVE_FLAG:Q}
MAKE_ENV+= WHOLE_ARCHIVE_FLAG=${WHOLE_ARCHIVE_FLAG:Q}
MAKE_ENV+= X11BASE=${X11BASE:Q}
MAKE_ENV+= X11PREFIX=${X11PREFIX:Q}
MAKE_ENV+= PKGMANDIR=${PKGMANDIR:Q}
# Provide a consistent environment for packages using (Net)BSD-style
# Makefiles.
#
MAKE_ENV+= MAKECONF=${PKGMAKECONF:U/dev/null}
MAKE_ENV+= OBJECT_FMT=${OBJECT_FMT:Q}
MAKE_ENV+= ${USETOOLS:DUSETOOLS=${USETOOLS:Q}}
# Add these bits to the environment used when invoking the recursive make
# processes for build-related phases.
#
BUILD_ENV+= PATH=${PATH:Q}