PKG_CHECK_MODULES(LIBSNDFILE, [ sndfile >= 1.0.20 ])
-PKG_CHECK_MODULES(VCONF, vconf)
-AC_SUBST(VCONF_CFLAGS)
-AC_SUBST(VCONF_LIBS)
+dnl use samsung policy module --------------------------------------------------------
+AC_ARG_ENABLE(samsung-policy, AC_HELP_STRING([--enable-samsung-policy], [using samsung-policy]),
+[
+ case "${enableval}" in
+ yes) USE_SAMSUNG_POLICY=yes ;;
+ no) USE_SAMSUNG_POLICY=no ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for --enable-samsung_policy) ;;
+ esac
+ ],[USE_SAMSUNG_POLICY=no])
+
+if test "x$USE_SAMSUNG_POLICY" = "xyes"; then
+ PKG_CHECK_MODULES(VCONF, vconf)
+ AC_SUBST(VCONF_CFLAGS)
+ AC_SUBST(VCONF_LIBS)
+fi
+AM_CONDITIONAL(USE_SAMSUNG_POLICY, test "x$USE_SAMSUNG_POLICY" = "xyes")
+dnl end --------------------------------------------------------------------
dnl use dlog --------------------------------------------------------------------------
AC_ARG_ENABLE(dlog, AC_HELP_STRING([--enable-dlog], [using dlog]),
pulse/ext-stream-restore.h \
pulse/ext-node-manager.h \
pulse/ext-echo-cancel.h \
- pulse/ext-policy.h \
pulse/format.h \
pulse/gccmacro.h \
pulse/introspect.h \
pulse/volume.h \
pulse/xmalloc.h
+if USE_SAMSUNG_POLICY
+pulseinclude_HEADERS += \
+ pulse/ext-policy.h
+endif
+
lib_LTLIBRARIES = \
libpulse.la \
libpulse-simple.la
pulse/ext-stream-restore.c pulse/ext-stream-restore.h \
pulse/ext-node-manager.c pulse/ext-node-manager.h \
pulse/ext-echo-cancel.c pulse/ext-echo-cancel.h \
- pulse/ext-policy.c pulse/ext-policy.h \
pulse/format.c pulse/format.h \
pulse/gccmacro.h \
pulse/internal.h \
pulse/volume.c pulse/volume.h \
pulse/xmalloc.c pulse/xmalloc.h
+if USE_SAMSUNG_POLICY
+libpulse_la_SOURCES += \
+ pulse/ext-policy.c pulse/ext-policy.h
+endif
+
libpulse_la_CFLAGS = $(AM_CFLAGS) $(DBUS_CFLAGS) $(LIBJSON_CFLAGS)
libpulse_la_LIBADD = $(AM_LIBADD) $(WINSOCK_LIBS) $(LTLIBICONV) $(LIBJSON_LIBS) libpulsecommon-@PA_MAJORMINOR@.la
libpulse_la_LDFLAGS = $(AM_LDFLAGS) $(VERSIONING_LDFLAGS) -version-info $(LIBPULSE_VERSION_INFO)
if HAVE_DBUS
# Serveral module (e.g. libalsa-util.la)
modlibexec_LTLIBRARIES += \
- module-console-kit.la \
+ module-console-kit.la
+if USE_SAMSUNG_POLICY
+modlibexec_LTLIBRARIES += \
module-policy.la
endif
+endif
modlibexec_LTLIBRARIES += \
module-cli.la \
module-switch-on-connect-symdef.h \
module-switch-on-port-available-symdef.h \
module-filter-apply-symdef.h \
- module-filter-heuristics-symdef.h \
+ module-filter-heuristics-symdef.h
+if USE_SAMSUNG_POLICY
+SYMDEF_FILES += \
module-policy-symdef.h
-
+endif
if HAVE_ESOUND
SYMDEF_FILES += \
module-esound-protocol-tcp-symdef.h \
module_rygel_media_server_la_LIBADD = $(MODULE_LIBADD) $(DBUS_LIBS) libprotocol-http.la
module_rygel_media_server_la_CFLAGS = $(AM_CFLAGS) $(DBUS_CFLAGS)
+if USE_SAMSUNG_POLICY
module_policy_la_SOURCES = modules/module-policy.c
module_policy_la_LDFLAGS = $(MODULE_LDFLAGS)
module_policy_la_LIBADD = $(AM_LIBADD) $(DBUS_LIBS) $(VCONF_LIBS) libprotocol-native.la libpulsecore-@PA_MAJORMINOR@.la libpulsecommon-@PA_MAJORMINOR@.la libpulse.la
module_policy_la_CFLAGS = $(AM_CFLAGS) $(DBUS_CFLAGS) $(VCONF_CFLAGS)
+endif
###################################
# Some minor stuff #