Compile adapter test/example only if the required headers are available (fixes #391915).

Original commit message from CVS:
* configure.ac:
* tests/examples/Makefile.am:
Compile adapter test/example only if the required headers are
available (fixes #391915).
This commit is contained in:
Tim-Philipp Müller 2007-01-02 17:01:33 +00:00
parent c254a2345b
commit 40f4221ac5
3 changed files with 30 additions and 7 deletions

View file

@ -1,3 +1,10 @@
2007-01-02 Tim-Philipp Müller <tim at centricular dot net>
* configure.ac:
* tests/examples/Makefile.am:
Compile adapter test/example only if the required headers are
available (fixes #391915).
2007-01-01 David Schleef <ds@schleef.org>
* gst/gstplugin.c:

View file

@ -268,8 +268,17 @@ AC_HEADER_STDC
dnl Check for ucontext.h
AC_CHECK_HEADERS([ucontext.h])
dnl Check for sys/socket.h
AC_CHECK_HEADERS([sys/socket.h], HAVE_SYS_SOCKET_H=yes)
AM_CONDITIONAL(HAVE_SYS_SOCKET_H, test "x$HAVE_SYS_SOCKET_H" = "xyes")
dnl check for sys/times.h for tests/examples/adapter/
AC_CHECK_HEADERS([sys/times.h], HAVE_SYS_TIMES_H=yes)
AC_CHECK_HEADERS([unistd.h], HAVE_UNISTD_H=yes)
AM_CONDITIONAL(HAVE_SYS_TIMES_H_AND_UNISTD_H, test "x$HAVE_SYS_TIMES_H" = "xyes" -a "x$HAVE_UNISTD_H" = "xyes")
dnl Check for process.h for getpid() on win32
AC_CHECK_HEADERS([process.h])
dnl Check for sys/utsname.h for uname

View file

@ -10,13 +10,19 @@ else
GST_PARSE_DIRS = launch
endif
# adapter test needs sys/times.h and unistd.h
if HAVE_SYS_TIMES_H_AND_UNISTD_H
ADAPTER_TEST_DIR = adapter
else
ADAPTER_TEST_DIR =
endif
always_dirs = \
controller \
helloworld \
manual \
metadata \
queue \
adapter
controller \
helloworld \
manual \
metadata \
queue
#appreader
#cutter
@ -36,7 +42,8 @@ always_dirs = \
SUBDIRS = \
$(always_dirs) \
$(ADAPTER_TEST_DIR) \
$(GST_PARSE_DIRS) \
$(GST_LOADSAVE_DIRS)
DIST_SUBDIRS = $(always_dirs) xml typefind launch
DIST_SUBDIRS = $(always_dirs) adapter xml typefind launch