Wednesday, May 8, 2024
 Popular · Latest · Hot · Upcoming
0
rated 0 times [  0] [ 0]  / answers: 1 / hits: 1578  / 1 Year ago, wed, december 28, 2022, 8:58:25

How do I specify the location of a library when running ./configure ?



I have searched around and think the answer lies in setting LDFLAGS and CPPFLAGS, but I,m not sure how to do it.



Specifically, I have compiled libx264 and I now want to compile libav and enable libx264 support, but dont know how to point ./configure to my libx264 include and lib folders.



Thanks.


More From » compiling

 Answers
2

Thanks for the pointer. I did more reading and discovered how to do this. The solution is two-fold.




  1. Compile x264 with '--enable-shared' as well as '--enable-static'. Without specifying '--enable-shared', the library was never found.


  2. Specify the location of the 'lib' and 'include' files generated by the x264 make process like this :-



    ./configure --extra-ldflags="-L/path/to/extra/lib" --extra-cflags="-I/path/to/extra/includes" --enable-x264 ..etc ..etc




I have now successfully compiled libav, with x264 support, and have the following binaries :-



avconv, avplay, avprobe, avserver, ffmpeg.



Off course I am sure if I had just installed libav using apt-get I would have saved myself a lot of trouble, but as this was a learning process I think I have learned a lot.


[#24616] Thursday, December 29, 2022, 1 Year  [reply] [flag answer]
Only authorized users can answer the question. Please sign in first, or register a free account.
velelf

Total Points: 395
Total Questions: 115
Total Answers: 107

Location: Sudan
Member since Mon, Jun 1, 2020
4 Years ago
velelf questions
Sat, Nov 6, 21, 05:08, 3 Years ago
Fri, Sep 24, 21, 01:23, 3 Years ago
Sun, Oct 9, 22, 07:37, 2 Years ago
Mon, Oct 10, 22, 08:55, 2 Years ago
;