Opened 11 years ago

Closed 5 years ago

Last modified 5 years ago

#2009 closed defect (fixed)

Bogus library dependencies (e.g. on SDL)

Reported by: Rudolf Polzer Owned by:
Priority: normal Component: build system
Version: git-master Keywords: pkg-config
Cc: Blocked By:
Blocking: Reproduced by developer: yes
Analyzed by developer: no

Description

Summary of the bug:
pkg-config files contain unneeded dependencies (e.g. libavcodec.pc contains -lSDL)

How to reproduce:

% grep SDL /usr/lib/pkgconfig/libav*
/usr/lib/pkgconfig/libavcodec.pc:Libs: -L${libdir} -lavcodec -ldl -lva -lXfixes -lXext -lX11 -ljack -lasound -lSDL -lpthread -lx264 -lvorbisenc -lvorbis -logg -ltheoraenc -ltheoradec -logg -lmp3lame -lfdk-aac -lfaac -lass -lm -pthread -lbz2 -lz -lrt
/usr/lib/pkgconfig/libavdevice.pc:Libs: -L${libdir} -lavdevice -ldl -lva -lXfixes -lXext -lX11 -ljack -lasound -lSDL -lpthread -lx264 -lvorbisenc -lvorbis -logg -ltheoraenc -ltheoradec -logg -lmp3lame -lfdk-aac -lfaac -lass -lm -pthread -lbz2 -lz -lrt
/usr/lib/pkgconfig/libavfilter.pc:Libs: -L${libdir} -lavfilter -ldl -lva -lXfixes -lXext -lX11 -ljack -lasound -lSDL -lpthread -lx264 -lvorbisenc -lvorbis -logg -ltheoraenc -ltheoradec -logg -lmp3lame -lfdk-aac -lfaac -lass -lm -pthread -lbz2 -lz -lrt
/usr/lib/pkgconfig/libavformat.pc:Libs: -L${libdir} -lavformat -ldl -lva -lXfixes -lXext -lX11 -ljack -lasound -lSDL -lpthread -lx264 -lvorbisenc -lvorbis -logg -ltheoraenc -ltheoradec -logg -lmp3lame -lfdk-aac -lfaac -lass -lm -pthread -lbz2 -lz -lrt
% nm -A /usr/lib/libavcodec.a  | grep SDL
%

Issue is that $extralibs is generally used in the configure script for multiple modules, despite them needing different things. It causes issues for programs linking to both libavcodec/libavformat and SDL2.

Change History (3)

comment:1 by Carl Eugen Hoyos, 11 years ago

Reproduced by developer: set
Status: newopen
Version: unspecifiedgit-master

comment:2 by Elon Musk, 5 years ago

Resolution: fixed
Status: openclosed

Should be fixed.

comment:3 by Carl Eugen Hoyos, 5 years ago

Not reproducible since 6dfcbd80

Note: See TracTickets for help on using tickets.