# This file is part of PulseAudio.
#
+# Copyright 2004-2006 Lennart Poettering
+# Copyright 2006-2007 Pierre Ossman <ossman@cendio.se> for Cendio AB
+#
# PulseAudio is free software; you can redistribute it and/or modify it
# under the terms of the GNU Lesser General Public License as published by
# the Free Software Foundation; either version 2 of the License, or
AC_SUBST(LIBPULSE_BROWSE_VERSION_INFO, [1:0:1])
AC_SUBST(LIBPULSE_MAINLOOP_GLIB_VERSION_INFO, [0:2:0])
+AC_CANONICAL_HOST
+
if type -p stow > /dev/null && test -d /usr/local/stow ; then
AC_MSG_NOTICE([*** Found /usr/local/stow: default install prefix set to /usr/local/stow/${PACKAGE_NAME}-${PACKAGE_VERSION} ***])
ac_default_prefix="/usr/local/stow/${PACKAGE_NAME}-${PACKAGE_VERSION}"
# POSIX
AC_CHECK_HEADERS([arpa/inet.h glob.h grp.h netdb.h netinet/in.h \
- netinet/in_systm.h netinet/ip.h netinet/tcp.h pwd.h sched.h \
+ netinet/in_systm.h netinet/tcp.h pwd.h sched.h \
sys/mman.h sys/resource.h sys/select.h sys/socket.h sys/wait.h \
syslog.h])
+AC_CHECK_HEADERS([netinet/ip.h], [], [],
+ [#include <sys/types.h>
+ #if HAVE_NETINET_IN_H
+ # include <netinet/in.h>
+ #endif
+ #if HAVE_NETINET_IN_SYSTM_H
+ # include <netinet/in_systm.h>
+ #endif
+ ])
AC_CHECK_HEADERS([regex.h], [HAVE_REGEX=1], [HAVE_REGEX=0])
AC_CHECK_HEADERS([sys/un.h], [HAVE_AF_UNIX=1], [HAVE_AF_UNIX=0])
AC_SUBST(LIBSNDFILE_CFLAGS)
AC_SUBST(LIBSNDFILE_LIBS)
+#### atomic-ops ###
+
+AC_CHECK_HEADERS([atomic_ops.h], [], [
+AC_MSG_ERROR([*** libatomic-ops headers not found])
+])
+
+# Win32 does not need the lib and breaks horribly if we try to include it
+if test "x$os_is_win32" != "x1" ; then
+ LIBS="$LIBS -latomic_ops"
+fi
+
#### OSS support (optional) ####
AC_ARG_ENABLE([oss],
AC_ARG_WITH(realtime_group,AS_HELP_STRING([--with-realtime-group=<group>],[Group for users that are allowed to start the PulseAudio daemon with realtime scheduling (realtime)]))
if test -z "$with_realtime_group" ; then
- PA_REALTIME_GROUP=realtime
+ PA_REALTIME_GROUP=pulse-rt
else
PA_REALTIME_GROUP=$with_realtime_group
fi