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.
This commit is contained in:
parent
8c95b27ce6
commit
eb25a30a42
|
@ -40,6 +40,8 @@ dnl Determine the Guix host system type, and store it in the
|
||||||
dnl `guix_system' variable.
|
dnl `guix_system' variable.
|
||||||
AC_DEFUN([GUIX_SYSTEM_TYPE], [
|
AC_DEFUN([GUIX_SYSTEM_TYPE], [
|
||||||
AC_REQUIRE([AC_CANONICAL_HOST])
|
AC_REQUIRE([AC_CANONICAL_HOST])
|
||||||
|
AC_PATH_PROG([SED], [sed])
|
||||||
|
|
||||||
AC_ARG_WITH(system, AC_HELP_STRING([--with-system=SYSTEM],
|
AC_ARG_WITH(system, AC_HELP_STRING([--with-system=SYSTEM],
|
||||||
[Platform identifier (e.g., `i686-linux').]),
|
[Platform identifier (e.g., `i686-linux').]),
|
||||||
[guix_system="$withval"],
|
[guix_system="$withval"],
|
||||||
|
@ -59,7 +61,7 @@ AC_DEFUN([GUIX_SYSTEM_TYPE], [
|
||||||
*)
|
*)
|
||||||
# Strip the version number from names such as `gnu0.3',
|
# Strip the version number from names such as `gnu0.3',
|
||||||
# `darwin10.2.0', etc.
|
# `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])
|
esac])
|
||||||
|
|
||||||
AC_MSG_CHECKING([for the Guix system type])
|
AC_MSG_CHECKING([for the Guix system type])
|
||||||
|
|
Loading…
Reference in New Issue