Skip to content

Commit 895229f

Browse files
Update libva build for FreeBSD and add Wayland support
Removes unused LIBVA_MAKE_ENV variable and adds --disable-dependency-tracking for FreeBSD to address make/gmake compatibility. Also includes libva-wayland.a in the build outputs.
1 parent 5d4e9ff commit 895229f

File tree

1 file changed

+7
-3
lines changed

1 file changed

+7
-3
lines changed

cmake/ffmpeg/libva.cmake

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,6 @@ endif()
1414
set(WORKING_DIR "${LIBVA_GENERATED_SRC_PATH}")
1515
UNIX_PATH(WORKING_DIR_UNIX ${WORKING_DIR})
1616

17-
set(LIBVA_MAKE_ENV "MAKE=${MAKE_EXECUTABLE}")
18-
1917
# Configure options for libva
2018
list(APPEND LIBVA_EXTRA_CONFIGURE
2119
--prefix=${CMAKE_CURRENT_BINARY_DIR_UNIX}/libva
@@ -28,6 +26,11 @@ list(APPEND LIBVA_EXTRA_CONFIGURE
2826
--without-legacy
2927
)
3028

29+
# On FreeBSD, disable dependency tracking to avoid gmake/make compatibility issues
30+
if(FREEBSD)
31+
list(APPEND LIBVA_EXTRA_CONFIGURE --disable-dependency-tracking)
32+
endif()
33+
3134
if(CMAKE_CROSSCOMPILING)
3235
set(LIBVA_EXTRA_CONFIGURE
3336
${LIBVA_EXTRA_CONFIGURE}
@@ -40,7 +43,7 @@ endif()
4043
string(REPLACE ";" " " LIBVA_EXTRA_CONFIGURE "${LIBVA_EXTRA_CONFIGURE}")
4144

4245
add_custom_target(libva ALL
43-
COMMAND ${SHELL_CMD} "${MAKE_COMPILER_FLAGS} ${LIBVA_MAKE_ENV} ./autogen.sh ${LIBVA_EXTRA_CONFIGURE}"
46+
COMMAND ${SHELL_CMD} "${MAKE_COMPILER_FLAGS} ./autogen.sh ${LIBVA_EXTRA_CONFIGURE}"
4447
COMMAND ${SHELL_CMD} "${MAKE_COMPILER_FLAGS} ${MAKE_EXECUTABLE} --jobs=${N_PROC}"
4548
COMMAND ${SHELL_CMD} "${MAKE_COMPILER_FLAGS} ${MAKE_EXECUTABLE} install"
4649
WORKING_DIRECTORY ${WORKING_DIR}
@@ -53,6 +56,7 @@ add_custom_target(libva ALL
5356
"${CMAKE_CURRENT_BINARY_DIR}/libva/lib/libva-drm.a"
5457
"${CMAKE_CURRENT_BINARY_DIR}/libva/lib/libva-x11.a"
5558
"${CMAKE_CURRENT_BINARY_DIR}/libva/lib/libva-glx.a"
59+
"${CMAKE_CURRENT_BINARY_DIR}/libva/lib/libva-wayland.a"
5660
)
5761
add_dependencies(${CMAKE_PROJECT_NAME} libva)
5862

0 commit comments

Comments
 (0)