[Libav-user] make shared lib including libav*.a on linux x64 platform
Zanelli Franco
fzanelli at tecnosens.it
Tue Oct 29 17:22:03 CET 2013
Hello again,
Did someone experienced the same problem and can help me to understand what is wrong please?
Thank you
Franco
Il 28/10/2013 14:20, Zanelli Franco ha scritto:
Ok,
I'd like to make a shared library called mylib.so that include static ffmpeg libraries libavcodec.a libavformat.a ..etc. in order to have just one shared library
I'm working on a linux machine 64 bit (ubuntu 12.04).
I've built ffmpeg libraries from ffmpeg 2.0.1 sources with this configuration:
--prefix="$HOME/ffmpeg_build" --extra-cflags="-m64 -I$HOME/ffmpeg_build/include" --extra-ldflags="-L$HOME/ffmpeg_build/lib" --bindir="$HOME/bin" --extra-libs="-ldl" --enable-gpl --enable-libmp3lame --enable-libx264 --enable-pic
When I link the avlibs in mine, with this command:
gcc -m64 -o mylib.so -L../ffmpeg_build/lib /home/uts/ffmpeg_build/lib/libavcodec.a -Wl,-R. -shared -s -fPIC
I always get this error:
/usr/bin/ld: /home/uts/ffmpeg_build/lib/libavcodec.a(deinterlace.o): relocation R_X86_64_PC32 against symbol `ff_pw_4' can not be used when making a shared object; recompile with -fPIC
/usr/bin/ld: final link failed: Bad value
The same procedure on a x86 linux platform succeded.
This is the same problem experienced from Dayana in this mailing list the 1st may 2013, I read the answers but they were not helpful
Can you help me please?
thank you
Il 28/10/2013 12:37, Carl Eugen Hoyos ha scritto:
Zanelli Franco <fzanelli at ...> <mailto:fzanelli at ...> writes:
> I experienced it when I was trying to include static ffmpeg
> libraries (libavcodec.a, libavformat.a ...) in my shared lib
> (mylib.so) on a 64 bit linux platform, but I don't know how to
> solve, can you help me please?
Could you explain (FFmpeg version, configure line, etc.)
how to reproduce your problem? That may allow us to help.
Carl Eugen
_______________________________________________
Libav-user mailing list
Libav-user at ffmpeg.org
http://ffmpeg.org/mailman/listinfo/libav-user
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://ffmpeg.org/pipermail/libav-user/attachments/20131029/029d6aa0/attachment.html>
More information about the Libav-user
mailing list