2

I am trying to build ffmpeg (0.6.1 release) with libx264 for h.264 support on windows platform over cygwin environment.

I compiled x264-snapshot-20101228-2245 and installed the library in /usr/local/lib/(libx264.a). The configure option here (./configure --enable-shared --disable-asm )

Now I am trying to build ffmpeg with below configure option:

./configure --enable-shared --disable-static --enable-pthreads --enable-libx264 --enable-gpl --disable-doc --enable-memalign-hack --extra-ldflags=/usr/local/lib

But configure is giving error. shell: ERROR: libx264 not found

++++++++++++++++++++ config.err

gcc -o /tmp/ffconf.ww1dJh1K.exe /tmp/ffconf.X7919VWP.o -lpsapi -lz -lbz2 -lm -lx264 -lm
/usr/lib/gcc/i686-pc-cygwin/4.3.4/../../../../i686-pc-cygwin/bin/ld: cannot find -lx264
collect2: ld returned 1 exit status
ERROR: libx264 not found
++++++++++++++++++++++

Tools Details Gcc version : gcc (GCC) 4.3.4 20090804 (release) 1

I will be glad if somebody points out the issue here.

rogerdpack
  • 62,887
  • 36
  • 269
  • 388
Rakesh Singh
  • 858
  • 1
  • 12
  • 31

3 Answers3

4

Try --extra-ldflags="-L /usr/local/lib". If that doesn't help, try LD_LIBRARY_PATH=/usr/local/lib:$LD_LIBRARY_PATH ./configure ...

Jiahao Chen
  • 896
  • 7
  • 14
  • Thanks --extra-ldflags="-L /usr/local/lib" worked and now the configure is completing. But I am getting another issue while doing make. Any idea How this can be fixed. ./usr/include/byteswap.h:19: error: redefinition of `bswap_16' ./libavutil/x86/bswap.h:33: error: previous definition of `bswap_16' was here – Rakesh Singh Jan 24 '11 at 17:39
0

On Windows, you should use

--extra-ldflags=/LIBPATH:path_to_lib_file
xiaoym
  • 41
  • 2
0

Have you tried adding --enable-memalign-hack to the configure flags

jocrag
  • 1