aboutsummaryrefslogtreecommitdiffstats
path: root/config/spl-build.m4
diff options
context:
space:
mode:
authorBrian Behlendorf <[email protected]>2010-09-02 15:39:08 -0700
committerBrian Behlendorf <[email protected]>2010-09-02 16:12:02 -0700
commit73fc084e9272e773efa4194bc5ead654f44c4846 (patch)
treecfe32a6696937209d9e4e422b885ca5c2059e1c8 /config/spl-build.m4
parent6295556b716df883ca719d24838281ccbcce5c44 (diff)
Move vendor check to spl-build.m4
This check was previously done with a hack in config.guess. However, since a new config.guess is copied in to place when forcing a full autoreconf this change was easily lost and never a good idea. This commit also updates all of the autoconf style support scripts in config.
Diffstat (limited to 'config/spl-build.m4')
-rw-r--r--config/spl-build.m421
1 files changed, 20 insertions, 1 deletions
diff --git a/config/spl-build.m4 b/config/spl-build.m4
index 0b9f8f430..d956a8b43 100644
--- a/config/spl-build.m4
+++ b/config/spl-build.m4
@@ -314,7 +314,26 @@ dnl # Using the VENDOR tag from config.guess set the default
dnl # package type for 'make pkg': (rpm | deb | tgz)
dnl #
AC_DEFUN([SPL_AC_DEFAULT_PACKAGE], [
- VENDOR=$(echo $ac_build_alias | cut -f2 -d'-')
+ AC_MSG_CHECKING([linux distribution])
+ if test -f /etc/redhat-release ; then
+ VENDOR=redhat ;
+ elif test -f /etc/fedora-release ; then
+ VENDOR=fedora ;
+ elif test -f /etc/lsb-release ; then
+ VENDOR=ubuntu ;
+ elif test -f /etc/debian_version ; then
+ VENDOR=debian ;
+ elif test -f /etc/SuSE-release ; then
+ VENDOR=sles ;
+ elif test -f /etc/slackware-version ; then
+ VENDOR=slackware ;
+ elif test -f /etc/gentoo-release ; then
+ VENDOR=gentoo ;
+ else
+ VENDOR= ;
+ fi
+ AC_MSG_RESULT([$VENDOR])
+ AC_SUBST(VENDOR)
AC_MSG_CHECKING([default package type])
case "$VENDOR" in