huo-ju / photoprism-freebsd-port

The photoprism port for FreeBSD
BSD 2-Clause "Simplified" License
69 stars 15 forks source link

multimedia/ffmpeg updated to version 6, not compatible with Photoprism #56

Closed jan666 closed 1 year ago

jan666 commented 1 year ago

multimedia/ffmpeg was updated to the new default version 6. This version is not yet compatible with Photoprism.

I tried to fix that by changing the version to RUN_DEPENDS= ffmpeg:multimedia/ffmpeg4 but the problem is that multimedia/ffmpeg4 does not install /usr/local/bin/ffmpeg but /usr/local/ffmpeg4/bin/ffmpeg. I "fixed" that for my setup by creating a link from /usr/local/bin/ffmpeg to /usr/local/ffmpeg4/bin/ffmpeg.

I guess there is a proper way to fix that but I don't know how.

huo-ju commented 1 year ago

The best way is that waiting for the upstream upgrade to fix the compatible on ffmpeg v6, and for the temporary solution you can pass a cli flag --ffmpeg-bin to the /usr/local/ffmpeg4/bin/ffmpeg

https://github.com/photoprism/photoprism/blob/9de9a354067b85bb28924c003841b8a140718130/internal/config/flags.go#L576

jan666 commented 1 year ago

For everyone thats interested:

-RUN_DEPENDS=  ffmpeg:multimedia/ffmpeg \
+RUN_DEPENDS=  /usr/local/ffmpeg4/bin/ffmpeg:multimedia/ffmpeg4 \

to change the port to ffmpeg 4. Or just install ffmpeg4 next to ffmpeg (6), it doesn't matter.

and add

photoprism_args="--ffmpeg-bin /usr/local/ffmpeg4/bin/ffmpeg"

to your /etc/rc.conf (or update your existing photoprism_args)