Skip to content

Commit

Permalink
games/hedgewars: Move to FFmpeg 4
Browse files Browse the repository at this point in the history
Fails to build with FFmpeg 6

PR:		270248
Approved by:	portmgr (blanket, build fix)
Sponsored by:	Blinkinblox
  • Loading branch information
Daniel Engberg authored and Daniel Engberg committed Apr 27, 2023
1 parent f1a196b commit 4ea6ffb
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 1 deletion.
4 changes: 3 additions & 1 deletion games/hedgewars/Makefile
Expand Up @@ -41,7 +41,7 @@ OPTIONS_EXCLUDE_i386= VIDEOREC # some pascal issues preventing to use it

VIDEOREC_DESC= Enable video recording (requires ffmpeg)

VIDEOREC_LIB_DEPENDS= libavcodec.so:multimedia/ffmpeg
VIDEOREC_LIB_DEPENDS= libavcodec.so.58:multimedia/ffmpeg4
VIDEOREC_PLIST_FILES= lib/libavwrapper.so \
lib/libavwrapper.so.1.0
VIDEOREC_CMAKE_OFF= -DNOVIDEOREC=1
Expand All @@ -60,6 +60,8 @@ post-patch:
@${REINPLACE_CMD} -e 's|/usr/local|${LOCALBASE}|' ${WRKSRC}/cmake_modules/*.cmake
@${REINPLACE_CMD} -e "s|'liblua'|'liblua-${LUA_VER}'|" ${WRKSRC}/hedgewars/LuaPas.pas
@${REINPLACE_CMD} -e "/linklib/ s|lua|&-${LUA_VER}|" ${WRKSRC}/hedgewars/LuaPas.pas
@${REINPLACE_CMD} -e 's|%%LOCALBASE%%|${LOCALBASE}|g' \
${PATCH_WRKSRC}/cmake_modules/FindLIBAV.cmake

post-install:
@${STRIP_CMD} ${STAGEDIR}${PREFIX}/bin/*
Expand Down
11 changes: 11 additions & 0 deletions games/hedgewars/files/patch-cmake__modules_FindLIBAV.cmake
@@ -0,0 +1,11 @@
--- cmake_modules/FindLIBAV.cmake.orig 2023-04-25 07:46:45 UTC
+++ cmake_modules/FindLIBAV.cmake
@@ -19,6 +19,8 @@
# BSD license.
#

+set(CMAKE_PREFIX_PATH "%%LOCALBASE%%/ffmpeg4;%%LOCALBASE%%/ffmpeg4/libexec")
+
include(FindPackageHandleStandardArgs)


0 comments on commit 4ea6ffb

Please sign in to comment.