[Libav-user] Configuration from shared library?

Charles linux2 at orion15.org
Sun Jan 1 20:45:24 EET 2017


On 01/01/2017 12:29 PM, Steve Myers wrote:
> Due to circumstances I lost the build script I used to build the shared libraries for my app. Is there a way a to get the configuration used from shared libraries similar to the command line ffmpeg? I only have libavcodec-57.so, libavformat-57.so, etc.
> _______________________________________________
> Libav-user mailing list
> Libav-user at ffmpeg.org
> http://ffmpeg.org/mailman/listinfo/libav-user
>

No, but if using gcc it would look something like this
gcc -fPIC -shared -I[path] [files].c -o lib[name].so -l[other required lib]

If you build it look for errors in compile "name.h" not found means update include "-I" path
Unresolved symbols mean update linking options "-l"

ex: shared lib with ffmpeg would include something like this
-I/usr/include/ffmpeg
-lavformat -lavcodec -lavutil -lswscale -lavdevice"

Example:
g++ -g -std=c++0x -Wall -Wextra -shared -fPIC -DDEBUG -DGL_GLEXT_PROTOTYPES -I/usr/include/libdrm -I/usr/include/ffmpeg draw_inf.cpp 
draw_mbox.cpp sphere.cpp draw_cube.cpp util.cpp AvEncoder.cpp ThreadBase.cpp Image.cpp -lavformat -lavcodec -lavutil -lswscale -lavdevice 
-lGLEW -lGLU -lGL -lX11 -lm -lrt -o libmyutil.so

Thanks
cco


More information about the Libav-user mailing list