From 5b7f8c1816544102011815ee570093c3ae7d339e Mon Sep 17 00:00:00 2001 From: Chris Robinson Date: Mon, 2 Jan 2012 11:52:20 -0800 Subject: Check earlier for ffmpeg --- CMakeLists.txt | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 8e0f9dae..d98010aa 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -648,6 +648,10 @@ ENDIF() # This is always available SET(BACKENDS "${BACKENDS} Null") +IF(EXAMPLES) + PKG_CHECK_MODULES(FFMPEG libavcodec libavformat) +ENDIF() + IF(LIBTYPE STREQUAL "STATIC") ADD_DEFINITIONS(-DAL_LIBTYPE_STATIC) SET(PKG_CONFIG_CFLAGS -DAL_LIBTYPE_STATIC ${PKG_CONFIG_CFLAGS}) @@ -735,7 +739,6 @@ IF(UTILS) ENDIF() IF(EXAMPLES) - PKG_CHECK_MODULES(FFMPEG libavcodec libavformat) IF(FFMPEG_FOUND) ADD_EXECUTABLE(alstream examples/alhelpers.c examples/alffmpeg.c examples/alstream.c) TARGET_LINK_LIBRARIES(alstream ${FFMPEG_LIBRARIES} ${LIBNAME}) -- cgit v1.2.3