openjpeg-1.5.0
check_func opj_version -lopenjpeg
check_ld cc -lopenjpeg
check_cc
BEGIN /tmp/ffconf.FjPhvrcd.c
1 extern int opj_version();
2 int main(void){ opj_version(); }
END /tmp/ffconf.FjPhvrcd.c
gcc -D_ISOC99_SOURCE -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -U__STRICT_ANSI__ -I/mingw/include \
-std=c99 -fno-common -fomit-frame-pointer -mms-bitfields -IC:/MinGW/include -IC:/MinGW/include/fribidi \
-IC:/MinGW/include/freetype2 -IC:/MinGW/include/glib-2.0 -IC:/MinGW/lib/glib-2.0/include \
-IC:/MinGW/include/freetype2 -IC:/MinGW/include -c -o /tmp/ffconf.sopDAXEw.o /tmp/ffconf.FjPhvrcd.c
gcc -L/mingw/lib -Wl,--as-needed -o /tmp/ffconf.auqRaaGu.exe /tmp/ffconf.sopDAXEw.o \
-lopenjpeg -lopencore-amrwb -lopencore-amrnb -lnut -lmp3lame -lgsm -LC:/MinGW/lib\
-lfreetype -lcelt0 -lcelt0 -LC:/MinGW/lib -lass -lavifil32 -lm -lz
-lpsapi -lshell32
D:/TEMP/ffconf.sopDAXEw.o:ffconf.FjPhvrcd.c:(.text+0xc): undefined reference to `_opj_version'
collect2.exe: error: ld returned 1 exit status
ERROR: libopenjpeg not found
需要libopenjpeg static编译
./configure --prefix=/mingw --build=mingw32 --target=mingw32 --enable-static --disable-shared \
--includedir=/mingw/include --libdir=/mingw/lib
make CFLAGS="-DWIN32 -DOPJ_STATIC $CFLAGS"
make install-strip
需要正确安装 libpng libpng不能static编译.
libpng 需要默认编译 我用的 [libpng-1.5.12]
./configure --prefix=/mingw
make
make install-strip