blob: 2545934d3b9cbad3560a2056819e8eb83091f9a0 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
|
=== modified file 'configure.ac'
--- configure.ac 2008-11-11 12:27:08 +0000
+++ configure.ac 2008-11-11 12:28:01 +0000
@@ -117,15 +117,23 @@
AC_SUBST(APP_LDFLAGS)
AC_SUBST(WARN_CFLAGS)
-dnl Get distro name from /etc/issue
-if test -r /etc/issue; then
- AC_MSG_CHECKING([distro name])
- DISTRO=`sed -e "s/.[0-9][0-9;]*[mJH]//g" < /etc/issue|tr "\n" " " | sed -e "s/(\\\\?\\\\\\\\.*//" -e "s/ */ /g" -e "s/^ //" -e "s/ $//"`
- AC_MSG_RESULT("$DISTRO")
- AC_SUBST(DISTRO)
- AC_DEFINE(HAVE_DISTRO, 1, [1 if DISTRO is defined])
- have_distro=yes
+AC_ARG_WITH(distro,
+ AC_HELP_STRING([--with-distro=distro],
+ [Provide distribution name, by default will try to grep /etc/issue]))
+
+if test "$with_distro" != "no"; then
+ DISTRO=$with_distro
+else
+ dnl Get distro name from /etc/issue
+ if test -r /etc/issue; then
+ AC_MSG_CHECKING([distro name])
+ DISTRO=`sed -e "s/.[0-9][0-9;]*[mJH]//g" < /etc/issue|tr "\n" " " | sed -e "s/(\\\\?\\\\\\\\.*//" -e "s/ */ /g" -e "s/^ //" -e "s/ $//"`
+ AC_MSG_RESULT("$DISTRO")
+ fi
fi
+AC_SUBST(DISTRO)
+AC_DEFINE(HAVE_DISTRO, 1, [1 if DISTRO is defined])
+have_distro=yes
AM_CONDITIONAL(HAVE_DISTRO, test x$have_distro = xyes)
dnl Check for system dependent features.
|