Quantcast
Channel: Active questions tagged gcc - Stack Overflow
Viewing all articles
Browse latest Browse all 22039

gcc: undefined reference to

$
0
0

I would like to compile this.

program.c

#include <libavcodec/avcodec.h>

int main(){
    int i = avpicture_get_size(AV_PIX_FMT_RGB24,300,300);
}

Running this

gcc -I$HOME/ffmpeg/include program.c

gives error

/tmp/ccxMLBme.o: In function `main':
program.c:(.text+0x18): undefined reference to `avpicture_get_size'
collect2: ld returned 1 exit status

However, avpicture_get_size is defined. Why is this happening?


Viewing all articles
Browse latest Browse all 22039

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>