summaryrefslogtreecommitdiffstats
path: root/src/external/platform.m4
diff options
context:
space:
mode:
authorStephen Gallagher <sgallagh@redhat.com>2010-02-18 07:49:04 -0500
committerStephen Gallagher <sgallagh@redhat.com>2010-02-18 13:48:45 -0500
commit1c48b5a62f73234ed26bb20f0ab345ab61cda0ab (patch)
tree0b6cddd567a862e1a7b5df23764869782a62ca78 /src/external/platform.m4
parent8c56df3176f528fe0260974b3bf934173c4651ea (diff)
downloadsssd-1c48b5a62f73234ed26bb20f0ab345ab61cda0ab.tar.gz
sssd-1c48b5a62f73234ed26bb20f0ab345ab61cda0ab.tar.xz
sssd-1c48b5a62f73234ed26bb20f0ab345ab61cda0ab.zip
Rename server/ directory to src/
Also update BUILD.txt
Diffstat (limited to 'src/external/platform.m4')
-rw-r--r--src/external/platform.m429
1 files changed, 29 insertions, 0 deletions
diff --git a/src/external/platform.m4 b/src/external/platform.m4
new file mode 100644
index 000000000..71b4f2c85
--- /dev/null
+++ b/src/external/platform.m4
@@ -0,0 +1,29 @@
+AC_ARG_WITH([os],
+ [AC_HELP_STRING([--with-os=OS_TYPE], [Type of your operation system (fedora|redhat|suse)])]
+ )
+osname=""
+if test x"$with_os" != x ; then
+ if test x"$with_os" == xfedora -o \
+ x"$with_os" == xredhat -o \
+ x"$with_os" == xsuse ; then
+ osname=$with_os
+ else
+ AC_MSG_ERROR([Illegal value -$with_os- for option --with-os])
+ fi
+fi
+
+if test x"$osname" = x ; then
+ if test -f /etc/fedora-release ; then
+ osname="fedora"
+ elif test -f /etc/redhat-release ; then
+ osname="redhat"
+ elif test -f /etc/SuSE-release ; then
+ osname="suse"
+ fi
+
+ AC_MSG_NOTICE([Detected operation system type: $osname])
+fi
+
+AM_CONDITIONAL([HAVE_FEDORA], [test x"$osname" == xfedora])
+AM_CONDITIONAL([HAVE_REDHAT], [test x"$osname" == xredhat])
+AM_CONDITIONAL([HAVE_SUSE], [test x"$osname" == xsuse])