Important fixes to this branch:
* Don't download the repo again if it exists. * Remember the include directories.
This commit is contained in:
+27
-14
@@ -299,8 +299,10 @@ elseif(LINUX)
|
|||||||
set(HAS_FFMPEG TRUE)
|
set(HAS_FFMPEG TRUE)
|
||||||
endif()
|
endif()
|
||||||
else()
|
else()
|
||||||
|
set(SM_FFMPEG_SRC_DIR "${SM_EXTERN_DIR}/ffmpeg-linux-2.1.3")
|
||||||
|
set(SM_FFMPEG_ROOT "${CMAKE_BINARY_DIR}/ffmpeg-prefix/src/ffmpeg-build")
|
||||||
list(APPEND FFMPEG_CONFIGURE
|
list(APPEND FFMPEG_CONFIGURE
|
||||||
"${SM_EXTERN_DIR}/ffmpeg-linux-2.1.3/configure"
|
"${SM_FFMPEG_SRC_DIR}/configure"
|
||||||
"--disable-programs"
|
"--disable-programs"
|
||||||
"--disable-doc"
|
"--disable-doc"
|
||||||
"--disable-avdevice"
|
"--disable-avdevice"
|
||||||
@@ -315,19 +317,30 @@ elseif(LINUX)
|
|||||||
"--enable-gpl"
|
"--enable-gpl"
|
||||||
)
|
)
|
||||||
endif()
|
endif()
|
||||||
# --shlibdir=$our_installdir/stepmania-$VERSION
|
if (IS_DIRECTORY "${SM_FFMPEG_SRC_DIR}")
|
||||||
externalproject_add("ffmpeg"
|
externalproject_add("ffmpeg"
|
||||||
# DOWNLOAD_DIR "${SM_EXTERN_DIR}/ffmpeg-linux"
|
SOURCE_DIR "${SM_FFMPEG_SRC_DIR}"
|
||||||
# PREFIX "${SM_EXTERN_DIR}/ffmpeg-linux"
|
CONFIGURE_COMMAND ${FFMPEG_CONFIGURE}
|
||||||
# GIT_REPOSITORY "git://source.ffmpeg.org/ffmpeg.git"
|
BUILD_COMMAND "make"
|
||||||
# GIT_TAG "n2.1.3"
|
UPDATE_COMMAND ""
|
||||||
DOWNLOAD_COMMAND git clone "--branch" "n2.1.3" "--depth" "1" "git://source.ffmpeg.org/ffmpeg.git" "${SM_EXTERN_DIR}/ffmpeg-linux-2.1.3"
|
INSTALL_COMMAND ""
|
||||||
CONFIGURE_COMMAND ${FFMPEG_CONFIGURE}
|
TEST_COMMAND ""
|
||||||
BUILD_COMMAND "make"
|
)
|
||||||
UPDATE_COMMAND ""
|
else()
|
||||||
INSTALL_COMMAND ""
|
# --shlibdir=$our_installdir/stepmania-$VERSION
|
||||||
TEST_COMMAND ""
|
externalproject_add("ffmpeg"
|
||||||
)
|
# DOWNLOAD_DIR "${SM_EXTERN_DIR}/ffmpeg-linux"
|
||||||
|
# PREFIX "${SM_EXTERN_DIR}/ffmpeg-linux"
|
||||||
|
# GIT_REPOSITORY "git://source.ffmpeg.org/ffmpeg.git"
|
||||||
|
# GIT_TAG "n2.1.3"
|
||||||
|
DOWNLOAD_COMMAND git clone "--branch" "n2.1.3" "--depth" "1" "git://source.ffmpeg.org/ffmpeg.git" "${SM_FFMPEG_SRC_DIR}"
|
||||||
|
CONFIGURE_COMMAND ${FFMPEG_CONFIGURE}
|
||||||
|
BUILD_COMMAND "make"
|
||||||
|
UPDATE_COMMAND ""
|
||||||
|
INSTALL_COMMAND ""
|
||||||
|
TEST_COMMAND ""
|
||||||
|
)
|
||||||
|
endif()
|
||||||
set(HAS_FFMPEG TRUE)
|
set(HAS_FFMPEG TRUE)
|
||||||
endif()
|
endif()
|
||||||
else()
|
else()
|
||||||
|
|||||||
+2
-3
@@ -392,7 +392,6 @@ else() # Unix / Linux
|
|||||||
"${FFMPEG_avutil_LIBRARY}"
|
"${FFMPEG_avutil_LIBRARY}"
|
||||||
)
|
)
|
||||||
else()
|
else()
|
||||||
set(SM_FFMPEG_ROOT "${CMAKE_BINARY_DIR}/ffmpeg-prefix/src/ffmpeg-build")
|
|
||||||
list(APPEND SMDATA_LINK_LIB
|
list(APPEND SMDATA_LINK_LIB
|
||||||
"${SM_FFMPEG_ROOT}/libavformat/libavformat.a"
|
"${SM_FFMPEG_ROOT}/libavformat/libavformat.a"
|
||||||
"${SM_FFMPEG_ROOT}/libavcodec/libavcodec.a"
|
"${SM_FFMPEG_ROOT}/libavcodec/libavcodec.a"
|
||||||
@@ -496,8 +495,8 @@ if(NOT APPLE)
|
|||||||
else()
|
else()
|
||||||
add_dependencies("${SM_EXE_NAME}" "ffmpeg")
|
add_dependencies("${SM_EXE_NAME}" "ffmpeg")
|
||||||
list(APPEND SM_INCLUDE_DIRS
|
list(APPEND SM_INCLUDE_DIRS
|
||||||
"${SM_EXTERN_DIR}/ffmpeg-linux/src/ffmpeg"
|
"${SM_FFMPEG_SRC_DIR}"
|
||||||
"${SM_EXTERN_DIR}/ffmpeg-linux/src/ffmpeg-build"
|
"${SM_FFMPEG_ROOT}"
|
||||||
)
|
)
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
|||||||
Reference in New Issue
Block a user