c42da09796
installation directories) in configure, the files that depend on this information are not properly rebuilt. If you need this information, don't setup a -D in the Makefile.am - instead, include opal/install_dirs.h. * Use the : option in AC_CONFIG_FILES to avoid needing to expose that we are playing around with temporary files with our headers to avoid rebuilding * Clean up the version file information a bit, and like the install directory stuff, make sure that there is a dependency so that ompi_info gets rebuilt properly when a version number changes. This commit was SVN r9256.
69 строки
2.5 KiB
Bash
69 строки
2.5 KiB
Bash
dnl -*- shell-script -*-
|
|
dnl
|
|
dnl Copyright (c) 2004-2006 The Trustees of Indiana University and Indiana
|
|
dnl University Research and Technology
|
|
dnl Corporation. All rights reserved.
|
|
dnl Copyright (c) 2004-2005 The University of Tennessee and The University
|
|
dnl of Tennessee Research Foundation. All rights
|
|
dnl reserved.
|
|
dnl Copyright (c) 2004-2005 High Performance Computing Center Stuttgart,
|
|
dnl University of Stuttgart. All rights reserved.
|
|
dnl Copyright (c) 2004-2005 The Regents of the University of California.
|
|
dnl All rights reserved.
|
|
dnl $COPYRIGHT$
|
|
dnl
|
|
dnl Additional copyrights may follow
|
|
dnl
|
|
dnl $HEADER$
|
|
dnl
|
|
|
|
# OMPI_SAVE_VERSION(project_short, project-long,
|
|
# version_file, header_file])
|
|
# ----------------------------------------------
|
|
# creates version information for project from version_file, using
|
|
# OMPI_GET_VERSION(). Information is AC_SUBSTed and put in
|
|
# header_file.
|
|
AC_DEFUN([OMPI_SAVE_VERSION], [
|
|
OMPI_GET_VERSION([$3], [$1])
|
|
|
|
AC_SUBST($1[_MAJOR_VERSION])
|
|
AC_SUBST($1[_MINOR_VERSION])
|
|
AC_SUBST($1[_RELEASE_VERSION])
|
|
AC_SUBST($1[_GREEK_VERSION])
|
|
AC_SUBST($1[_WANT_SVN])
|
|
AC_SUBST($1[_SVN_R])
|
|
AC_SUBST($1[_VERSION])
|
|
|
|
AC_MSG_CHECKING([$2 version])
|
|
AC_MSG_RESULT([$]$1[_VERSION])
|
|
AC_MSG_CHECKING([$2 Subversion repository version])
|
|
AC_MSG_RESULT([$]$1[_SVN_R])
|
|
|
|
AC_DEFINE_UNQUOTED($1[_MAJOR_VERSION], [$]$1[_MAJOR_VERSION],
|
|
[Major release number of ]$2)
|
|
AC_DEFINE_UNQUOTED($1[_MINOR_VERSION], [$]$1[_MINOR_VERSION],
|
|
[Minor release number of ]$2)
|
|
AC_DEFINE_UNQUOTED($1[_RELEASE_VERSION], [$]$1[_RELEASE_VERSION],
|
|
[Release release number of ]$2)
|
|
AC_DEFINE_UNQUOTED($1[_GREEK_VERSION], ["$]$1[_GREEK_VERSION"],
|
|
[Greek - alpha, beta, etc - release number of ]$2)
|
|
AC_DEFINE_UNQUOTED($1[_VERSION], ["$]$1[_RELEASE_VERSION"],
|
|
[Complete release number of ]$2)
|
|
|
|
AC_CONFIG_FILES([$4.tmp:$4.in])
|
|
AC_CONFIG_COMMANDS([$1-versions], [
|
|
if test -f "$4" ; then
|
|
diff "$4" "$4.tmp" > /dev/null 2>&1
|
|
if test "$?" != "0" ; then
|
|
cp "$4.tmp" "$4"
|
|
echo "config.status: regenerating $4"
|
|
else
|
|
echo "config.status: $4 unchanged"
|
|
fi
|
|
else
|
|
cp "$4.tmp" "$4"
|
|
echo "config.status: creating $4"
|
|
fi
|
|
rm "$4.tmp"])
|
|
])dnl
|