aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLudovic Courtès <ludo@gnu.org>2013-07-05 14:14:21 +0200
committerLudovic Courtès <ludo@gnu.org>2013-07-05 14:14:21 +0200
commiteb25a30a42fcfa5e3fec9c87b3f8a2ff20d01c3c (patch)
treef6c99f946a13d0cf7d8fd93d533489ce30ca3cbd
parent8c95b27ce6f2b5f067efa3c0911eb678ee211937 (diff)
downloadguix-eb25a30a42fcfa5e3fec9c87b3f8a2ff20d01c3c.tar
guix-eb25a30a42fcfa5e3fec9c87b3f8a2ff20d01c3c.tar.gz
build: Correctly determine the system type for non-Linux systems.
* m4/guix.m4 (GUIX_SYSTEM_TYPE): Find `sed'. Fix sed pattern in the non-Linux case.
-rw-r--r--m4/guix.m44
1 files changed, 3 insertions, 1 deletions
diff --git a/m4/guix.m4 b/m4/guix.m4
index 4fdc409602..ed2e720241 100644
--- a/m4/guix.m4
+++ b/m4/guix.m4
@@ -40,6 +40,8 @@ dnl Determine the Guix host system type, and store it in the
dnl `guix_system' variable.
AC_DEFUN([GUIX_SYSTEM_TYPE], [
AC_REQUIRE([AC_CANONICAL_HOST])
+ AC_PATH_PROG([SED], [sed])
+
AC_ARG_WITH(system, AC_HELP_STRING([--with-system=SYSTEM],
[Platform identifier (e.g., `i686-linux').]),
[guix_system="$withval"],
@@ -59,7 +61,7 @@ AC_DEFUN([GUIX_SYSTEM_TYPE], [
*)
# Strip the version number from names such as `gnu0.3',
# `darwin10.2.0', etc.
- guix_system="$machine_name-`echo $host_os | "$SED" -e's/@<:@0-9.@:>@*$//g'`";;
+ guix_system="$machine_name-`echo $host_os | "$SED" -e's/[0-9.]*$//g'`";;
esac])
AC_MSG_CHECKING([for the Guix system type])