build: Conditionally compile senseApis
This commit is contained in:
@@ -53,12 +53,16 @@ AC_SUBST([AM_CPPFLAGS])
|
||||
AC_SUBST([YACC])
|
||||
AC_SUBST([LEX])
|
||||
|
||||
m4_include([m4/senseApis.m4])
|
||||
AC_SUBST([SENSEAPIS_ENABLED])
|
||||
|
||||
AC_CONFIG_HEADERS([include/config.h])
|
||||
AC_CONFIG_FILES([
|
||||
Makefile hcore/Makefile
|
||||
hcore/deviceManager/Makefile
|
||||
hcore/senseApis/Makefile
|
||||
senseApis/Makefile
|
||||
senseApis/xcbXorg/Makefile
|
||||
])
|
||||
|
||||
AC_CONFIG_COMMANDS_POST([
|
||||
@@ -66,6 +70,8 @@ AC_CONFIG_COMMANDS_POST([
|
||||
AC_MSG_NOTICE(m4_normalize([* MIND_VOSCILLATOR_PERIOD_MS:
|
||||
${MIND_VOSCILLATOR_PERIOD_MS} ms
|
||||
(freq: ${MIND_VOSCILLATOR_FREQ_MS} Hz)]))
|
||||
AC_MSG_NOTICE(m4_normalize(
|
||||
[* SenseAPI backends enabled: ${SENSEAPIS_ENABLED}]))
|
||||
])
|
||||
|
||||
AC_OUTPUT
|
||||
|
||||
@@ -0,0 +1,16 @@
|
||||
SENSEAPIS_ENABLED=
|
||||
|
||||
AC_ARG_ENABLE([senseapi-xcbxorg],
|
||||
[AS_HELP_STRING([--enable-senseapi-xcbxorg],
|
||||
[Enable XCB/Xorg SenseAPI backend])],
|
||||
[AS_CASE([$enableval],
|
||||
[no], [enable_senseapi_xcbxorg=no],
|
||||
[yes|*], [
|
||||
enable_senseapi_xcbxorg=yes
|
||||
AC_DEFINE([XCBXORG_ENABLED], [1],
|
||||
[Define to 1 if you have XCB/Xorg SenseAPI backend])
|
||||
SENSEAPIS_ENABLED="${SENSEAPIS_ENABLED} xcbXorg"
|
||||
]
|
||||
)],
|
||||
[enable_senseapi_xcbxorg=no]
|
||||
)
|
||||
@@ -1,2 +1 @@
|
||||
pkglib_LTLIBRARIES=libxcbXorg.la
|
||||
libxcbXorg_la_SOURCES=xcbXorg.cpp
|
||||
SUBDIRS = @SENSEAPIS_ENABLED@
|
||||
|
||||
@@ -0,0 +1,2 @@
|
||||
pkglib_LTLIBRARIES=libxcbXorg.la
|
||||
libxcbXorg_la_SOURCES=xcbXorg.cpp
|
||||
Reference in New Issue
Block a user