Sync up different copies of the m4 macros, noop change for this package.
[xfstests-dev.git] / m4 / package_globals.m4
1
2 # Generic macro, sets up all of the global packaging variables.
3 # The following environment variables may be set to override defaults:
4 #   DEBUG OPTIMIZER MALLOCLIB PLATFORM DISTRIBUTION INSTALL_USER INSTALL_GROUP
5 #   BUILD_VERSION
6 #
7 AC_DEFUN([AC_PACKAGE_GLOBALS],
8   [ pkg_name="$1"
9     AC_SUBST(pkg_name)
10
11     . ./VERSION
12     pkg_version=${PKG_MAJOR}.${PKG_MINOR}.${PKG_REVISION}
13     AC_SUBST(pkg_version)
14     pkg_release=$PKG_BUILD
15     test -z "$BUILD_VERSION" || pkg_release="$BUILD_VERSION"
16     AC_SUBST(pkg_release)
17
18     DEBUG=${DEBUG:-'-DDEBUG'}           dnl  -DNDEBUG
19     debug_build="$DEBUG"
20     AC_SUBST(debug_build)
21
22     OPTIMIZER=${OPTIMIZER:-'-g'}        dnl  -O2
23     opt_build="$OPTIMIZER"
24     AC_SUBST(opt_build)
25
26     MALLOCLIB=${MALLOCLIB:-''}          dnl  /usr/lib/libefence.a
27     malloc_lib="$MALLOCLIB"
28     AC_SUBST(malloc_lib)
29
30     PKG_USER=${INSTALL_USER:-'root'}
31     pkg_user="$PKG_USER"
32     AC_SUBST(pkg_user)
33
34     PKG_GROUP=${INSTALL_GROUP:-'root'}
35     pkg_group="$PKG_GROUP"
36     AC_SUBST(pkg_group)
37
38     pkg_distribution=`uname -s`
39     test -z "$DISTRIBUTION" || pkg_distribution="$DISTRIBUTION"
40     AC_SUBST(pkg_distribution)
41
42     pkg_platform=`uname -s | tr 'A-Z' 'a-z' | sed -e 's/irix64/irix/'`
43     test -z "$PLATFORM" || pkg_platform="$PLATFORM"
44     AC_SUBST(pkg_platform)
45   ])