Thanks guys, that really helped! In my case, some of ffmpeg's optional dependencies build static libraries but not shared ones. libaribcaption I had to pass an option to and then I got shared libraries. Libmpeghdec I had to file a bug.
On Tue, 28 Jul 2026 17:08:48 +0200 Timo Rothenpieler via ffmpeg-user <[email protected]> wrote: > On 27.07.2026 22:21, David Niklas via ffmpeg-user wrote: > > Hello, > > I'm trying to compile ffmpeg 8.1.2 on Devuan (Debian) Linux. I got the > > dependencies together. > > > > When trying to compile it, I'm getting error's saying that I need to > > pass -fPIC. I tried setting -fPIC in the CFLAGS and CXXFLAGS. I set > > --enable-pic in the configure options. > > > > But I still get the error. Here's an example: > > /usr/bin/ld: /usr/local/lib/libaribcaption.a(renderer_capi.cpp.o): > > warning: relocation against `_ZSt7nothrow@@GLIBCXX_3.4' in read-only > > section `.text' /usr/bin/ld: > > /usr/local/lib/libaribcaption.a(caption_capi.cpp.o): relocation > > R_X86_64_PC32 against symbol `_ZSt7nothrow@@GLIBCXX_3.4' can not be > > used when making a shared object; recompile with -fPIC /usr/bin/ld: > > final link failed: bad value collect2: error: ld returned 1 exit > > status make: *** [ffbuild/library.mak:136: > > libavcodec/libavcodec.so.62] Error 1 > > You cannot link non-PIC code into shared objects. > Most distributions build static libraries without PIC. > So you can only link them into executables, not shared objects. > > Either build your own static libraries with PIC, or build ffmpeg in > statically as well. _______________________________________________ ffmpeg-user mailing list -- [email protected] To unsubscribe send an email to [email protected]
