hedgewars/CMakeLists.txt
changeset 7540 cc6c656f70b5
parent 7538 2d6e69b392cb
child 7615 b39beffcf05e
--- a/hedgewars/CMakeLists.txt	Fri Aug 10 17:35:48 2012 +0400
+++ b/hedgewars/CMakeLists.txt	Sat Aug 11 21:25:57 2012 +0400
@@ -190,14 +190,18 @@
         message(STATUS "Compiling with video recording")
         include_directories(${FFMPEG_INCLUDE_DIR})
         set(pascal_flags "-dUSE_VIDEO_RECORDING" ${pascal_flags})
+        set(LIBRARY_OUTPUT_PATH ${EXECUTABLE_OUTPUT_PATH})
         IF (WIN32)
-            set(LIBRARY_OUTPUT_PATH ${CMAKE_BINARY_DIR}/bin)
             # there are some problems with linking our avwrapper as static lib, so link it as shared
             add_library(avwrapper SHARED avwrapper.c)
             target_link_libraries(avwrapper ${FFMPEG_LIBRARIES})
         ELSE()
             add_library(avwrapper STATIC avwrapper.c)
+            set(pascal_flags "-k${FFMPEG_LIBAVCODEC} ${FFMPEG_LIBAVFORMAT} ${FFMPEG_LIBAVUTIL}" ${pascal_flags})
+         #   set(pascal_flags "-k${LIBRARY_OUTPUT_PATH}/${CMAKE_STATIC_LIBRARY_PREFIX}avwrapper${CMAKE_STATIC_LIBRARY_SUFFIX}" ${pascal_flags})
         ENDIF()
+    else()
+        message(STATUS "FFMPEG library not found, video recording will be disabled")
     endif()
 else()
     message(STATUS "Video recording disabled by user")