Skip to content

Commit

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

PR:		270314
Approved by:	portmgr (blanket, build fix)
Sponsored by:	Blinkinblox
  • Loading branch information
Daniel Engberg authored and Daniel Engberg committed Apr 27, 2023
1 parent 3eb37f1 commit c46e6a0
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 1 deletion.
4 changes: 3 additions & 1 deletion net/mediastreamer/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ VIDEOOPT_DESC= Video options
QTGL_DESC= Qt OpenGL rendering support

FFMPEG_IMPLIES= VIDEO
FFMPEG_LIB_DEPENDS= libavcodec.so:multimedia/ffmpeg
FFMPEG_LIB_DEPENDS= libavcodec.so.58:multimedia/ffmpeg4
FFMPEG_CMAKE_BOOL= ENABLE_FFMPEG
G726_LIB_DEPENDS= libspandsp.so:comms/spandsp
G726_CMAKE_BOOL= ENABLE_G726
Expand Down Expand Up @@ -98,6 +98,8 @@ XVIDEO_LDFLAGS= -L${LOCALBASE}/lib -lX11
post-patch:
@${REINPLACE_CMD} 's,gsm/gsm\.h,gsm.h,' \
${WRKSRC}/cmake/FindGSM.cmake ${WRKSRC}/src/audiofilters/gsm.c
@${REINPLACE_CMD} -e 's|%%LOCALBASE%%|${LOCALBASE}|g' \
${PATCH_WRKSRC}/CMakeLists.txt
.if ${CHOSEN_COMPILER_TYPE} == gcc
@${REINPLACE_CMD} '/-Wno-format-truncation/d' ${WRKSRC}/CMakeLists.txt
.endif
Expand Down
10 changes: 10 additions & 0 deletions net/mediastreamer/files/patch-CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
--- CMakeLists.txt.orig 2023-04-25 11:15:51 UTC
+++ CMakeLists.txt
@@ -260,6 +260,7 @@ if(ENABLE_VIDEO)
add_definitions(-DVIDEO_ENABLED)
endif()
if(ENABLE_FFMPEG)
+ set(CMAKE_PREFIX_PATH "%%LOCALBASE%%/ffmpeg4;%%LOCALBASE%%/ffmpeg4/libexec")
find_package(FFMpeg REQUIRED)
else()
add_definitions(-DNO_FFMPEG)

0 comments on commit c46e6a0

Please sign in to comment.