Added devel/fribidi under LIB_DEPENDS as suggested by Lucas. Ok?
I don't have CVS account, if the patch is good please help to commit. Thanks. Index: Makefile =================================================================== RCS file: /cvs/ports/graphics/ffmpeg/Makefile,v diff -u -p -r1.244 Makefile --- Makefile 20 Mar 2025 08:48:34 -0000 1.244 +++ Makefile 21 May 2025 16:42:58 -0000 @@ -2,7 +2,7 @@ COMMENT= audio/video converter and strea V= 6.1.2 DISTNAME= ffmpeg-${V} -REVISION= 1 +REVISION= 2 EPOCH= 1 CATEGORIES= graphics multimedia SITES= https://ffmpeg.org/releases/ @@ -27,11 +27,11 @@ MAINTAINER= Brad Smith <b...@comstyle.co PERMIT_PACKAGE= Yes WANTLIB += SDL2 X11 Xext Xv aom ass bz2 c crypto dav1d fontconfig -WANTLIB += freetype fribidi gsm iconv lzma m mp3lame opus pthread -WANTLIB += sndio speex ssl theoradec theoraenc v4l2 va va-drm -WANTLIB += va-x11 vidstab vorbis vorbisenc vpx webp webpmux x264 -WANTLIB += x265 xcb xcb-shape xcb-shm xcb-xfixes xml2 xvidcore z -WANTLIB += zimg +WANTLIB += freetype fribidi gsm harfbuzz iconv lzma m mp3lame opus +WANTLIB += pthread sndio speex ssl theoradec theoraenc v4l2 va +WANTLIB += va-drm va-x11 vidstab vorbis vorbisenc vpx webp webpmux +WANTLIB += x264 x265 xcb xcb-shape xcb-shm xcb-xfixes xml2 xvidcore +WANTLIB += z zimg COMPILER= base-clang ports-gcc COMPILER_LANGS= c @@ -52,6 +52,8 @@ LIB_DEPENDS= archivers/bzip2 \ audio/speex \ audio/gsm \ converters/libiconv \ + devel/harfbuzz \ + devel/fribidi \ devel/sdl2 \ graphics/libwebp \ graphics/zimg \ @@ -120,6 +122,7 @@ CONFIGURE_ARGS+=--enable-shared \ --enable-libfreetype \ --enable-libfribidi \ --enable-libgsm \ + --enable-libharfbuzz \ --enable-libmp3lame \ --enable-libopus \ --enable-libspeex \ ________________________________ From: Lucas Gabriel Vuotto <lu...@sexy.is> Sent: Tuesday, May 20, 2025 20:47 To: Alex Tsang <alexts...@live.com> Cc: ports@openbsd.org <ports@openbsd.org> Subject: Re: graphics/ffmpeg: Fix drawtext filter OK lucas too, with devel/fribidi added to LDEPS. On Tue, May 20, 2025 at 10:28:24AM +0000, Alex Tsang wrote: > Hi Brad, ports, > > After upgrading to OpenBSD 7.7 I notice that the drawtext filter in FFmpeg no > longer works. > > For example: > > ffmpeg -i input.jpeg -vf > "drawtext=fontsize=20:fontcolor=Red:fontfile='/usr/X11R6/lib/X11/fonts/TTF/DejaVuSans.ttf':text='test'" > output.jpeg > > The expected behaviour is to generate a new image file output.jpeg with the > text > "test" in red on top-left corner. At the time of writing, running the command > gives the following error: > > [AVFilterGraph @ 0xe9320c9fc00] No such filter: 'drawtext' > [vost#0:0/mjpeg @ 0xe9320c9b400] Error initializing a simple filtergraph > > Looking at the manpage of ffmpeg-filters [0], regarding the drawtext filter, > it > says: > > To enable compilation of this filter, you need to configure FFmpeg with > "--enable-libfreetype" and "--enable-libharfbuzz". To enable default font > fallback and the font option you need to configure FFmpeg with > "--enable-libfontconfig". To enable the text_shaping option, you need to > configure FFmpeg with "--enable-libfribidi". > > In the Makefile, all options are set, except "--enable-libharfbuzz". I can > confirm that the harfbuzz-11.0.0 package is installed on the computer, though. > > This patch was prepared by Brad, I tested it on OpenBSD 7.7 amd64. I can see > the > image file being generated as expected. > > [0]: > https://jpn01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fffmpeg.org%2Fffmpeg-filters.html%23drawtext-1&data=05%7C02%7C%7C7dff7716259849784ec708dd97942da4%7C84df9e7fe9f640afb435aaaaaaaaaaaa%7C1%7C0%7C638833384879963673%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C0%7C%7C%7C&sdata=WGXllUviVzZi9RZZ4VPvJvgi2v%2BYYb11d%2F24XmyWGrE%3D&reserved=0<https://ffmpeg.org/ffmpeg-filters.html#drawtext-1> > > Ok? > > Index: graphics/ffmpeg/Makefile > =================================================================== > RCS file: /cvs/ports/graphics/ffmpeg/Makefile,v > diff -u -p -r1.244 Makefile > --- graphics/ffmpeg/Makefile 20 Mar 2025 08:48:34 -0000 1.244 > +++ graphics/ffmpeg/Makefile 20 May 2025 07:11:56 -0000 > @@ -2,7 +2,7 @@ COMMENT= audio/video converter and strea > > V= 6.1.2 > DISTNAME= ffmpeg-${V} > -REVISION= 1 > +REVISION= 2 > EPOCH= 1 > CATEGORIES= graphics multimedia > SITES= > https://jpn01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fffmpeg.org%2Freleases%2F&data=05%7C02%7C%7C7dff7716259849784ec708dd97942da4%7C84df9e7fe9f640afb435aaaaaaaaaaaa%7C1%7C0%7C638833384879977160%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C0%7C%7C%7C&sdata=pIK7k1wffTbmoXuaTa%2BKctccrnfP6NaC695MUs%2FDYgU%3D&reserved=0<https://ffmpeg.org/releases/> > @@ -27,11 +27,11 @@ MAINTAINER= Brad Smith <b...@comstyle.co > PERMIT_PACKAGE= Yes > > WANTLIB += SDL2 X11 Xext Xv aom ass bz2 c crypto dav1d fontconfig > -WANTLIB += freetype fribidi gsm iconv lzma m mp3lame opus pthread > -WANTLIB += sndio speex ssl theoradec theoraenc v4l2 va va-drm > -WANTLIB += va-x11 vidstab vorbis vorbisenc vpx webp webpmux x264 > -WANTLIB += x265 xcb xcb-shape xcb-shm xcb-xfixes xml2 xvidcore z > -WANTLIB += zimg > +WANTLIB += freetype fribidi gsm harfbuzz iconv lzma m mp3lame opus > +WANTLIB += pthread sndio speex ssl theoradec theoraenc v4l2 va > +WANTLIB += va-drm va-x11 vidstab vorbis vorbisenc vpx webp webpmux > +WANTLIB += x264 x265 xcb xcb-shape xcb-shm xcb-xfixes xml2 xvidcore > +WANTLIB += z zimg > > COMPILER= base-clang ports-gcc > COMPILER_LANGS= c > @@ -52,6 +52,7 @@ LIB_DEPENDS= archivers/bzip2 \ > audio/speex \ > audio/gsm \ > converters/libiconv \ > + devel/harfbuzz \ > devel/sdl2 \ > graphics/libwebp \ > graphics/zimg \ > @@ -120,6 +121,7 @@ CONFIGURE_ARGS+=--enable-shared \ > --enable-libfreetype \ > --enable-libfribidi \ > --enable-libgsm \ > + --enable-libharfbuzz \ > --enable-libmp3lame \ > --enable-libopus \ > --enable-libspeex \ >