Ubuntu Natty (11.04) 32 비트에서 PDFLib를 컴파일하려고합니다. 그러나 나는 'make'단계에서 몇 가지 문제를 겪고있다. 그냥 요약하자면Ubuntu Natty 32 비트에 PDFLib을 설치할 때 오류가 발생합니다.
:
- 내가 디렉토리에 내용과 CD를 추출
- here에서 PDFLib 다운로드
- 그때
./configure
할 모든 것을 잘
그러나 때 간다 내가 할 make
나는 잠시 후 실행하면 아래 보이는 것을 얻을 :
../../libtool --silent --mode=link gcc -o libpdf.la -rpath /usr/local/lib -version-info 6:5:0 ./pdflib.lo ../../libs/pdflib/libpdf_.la ../../libs/font/libfont.la ../../libs/pdcore/libpdcore.la ../../libs/png/libpng.la ../../libs/flate/libz.la ../../libs/tiff/libtiff.la ../../libs/jpeg/libjpeg.la -lm -export-dynamic
../../libtool --silent --mode=link gcc -o libs_libpdf.la ./pdflib.lo ../../libs/pdflib/libpdf_.la ../../libs/font/libfont.la ../../libs/pdcore/libpdcore.la ../../libs/png/libpng.la ../../libs/flate/libz.la ../../libs/tiff/libtiff.la ../../libs/jpeg/libjpeg.la -lm
make[2]: Leaving directory `/mnt/hgfs/src/php/pdflib-7.0.5/libs/pdflib'
make[1]: Leaving directory `/mnt/hgfs/src/php/pdflib-7.0.5/libs'
make[1]: Entering directory `/mnt/hgfs/src/php/pdflib-7.0.5/bind'
make[2]: Entering directory `/mnt/hgfs/src/php/pdflib-7.0.5/bind/pdflib'
make[3]: Entering directory `/mnt/hgfs/src/php/pdflib-7.0.5/bind/pdflib/c'
make[3]: Warning: File `../../../libs/pdflib/libs_libpdf.la' has modification time 1.2 s in the future
../../../libtool --silent --mode=compile gcc -c -I../../../libs/pdflib -I../../../libs/pdcore -O2 -g -D__NO_CTYPE -DPDC_PF_LINUX_IA32 -DASMV -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -DPDF_PLATFORM=\""Linux"\" -DPACKAGE_NAME=\"\" -DPACKAGE_TARNAME=\"\" -DPACKAGE_VERSION=\"\" -DPACKAGE_STRING=\"\" -DPACKAGE_BUGREPORT=\"\" -DSTDC_HEADERS=1 -DHAVE_SYS_TYPES_H=1 -DHAVE_SYS_STAT_H=1 -DHAVE_STDLIB_H=1 -DHAVE_STRING_H=1 -DHAVE_MEMORY_H=1 -DHAVE_STRINGS_H=1 -DHAVE_INTTYPES_H=1 -DHAVE_STDINT_H=1 -DHAVE_UNISTD_H=1 -DHAVE_DLFCN_H=1 -Wall hello.c
../../../libtool --silent --mode=link gcc -static -o hello hello.lo ../../../libs/pdflib/libs_libpdf.la ../../../libs/pdflib/libs_libpdf.la -lm
../../../libs/pdflib/.libs/libs_libpdf.a(deflate.o): In function `deflate_slow':
/mnt/hgfs/src/php/pdflib-7.0.5/libs/flate/deflate.c:1602: undefined reference to `pdf_z_longest_match'
../../../libs/pdflib/.libs/libs_libpdf.a(deflate.o): In function `deflate_fast':
/mnt/hgfs/src/php/pdflib-7.0.5/libs/flate/deflate.c:1498: undefined reference to `pdf_z_longest_match'
../../../libs/pdflib/.libs/libs_libpdf.a(deflate.o): In function `lm_init':
/mnt/hgfs/src/php/pdflib-7.0.5/libs/flate/deflate.c:1015: undefined reference to `pdf_z_match_init'
collect2: ld returned 1 exit status
make[3]: *** [hello] Error 1
make[3]: Leaving directory `/mnt/hgfs/src/php/pdflib-7.0.5/bind/pdflib/c'
make[2]: *** [all] Error 2
make[2]: Leaving directory `/mnt/hgfs/src/php/pdflib-7.0.5/bind/pdflib'
make[1]: *** [all] Error 2
make[1]: Leaving directory `/mnt/hgfs/src/php/pdflib-7.0.5/bind'
make: *** [all] Error 2
이 오류는 무엇에 관한 것입니까? Ubuntu Natty 64 비트를 실행하는 Cloud Server에서 이와 동일한 작업을 수행했지만 문제가 발생하지 않았습니다.
몇 가지 지침을 알려 주시면 감사하겠습니다. 미리 감사드립니다.
편집 아래
PDFLib의 PECL 패키지를 사용하는 것이 좋습니다
wget http://www.pdflib.com/binaries/PDFlib/705/PDFlib-Lite-7.0.5.tar.gz
tar -zxf PDFlib-Lite-7.0.5.tar.gz
mv PDFlib-Lite-7.0.5 pdflib-7.0.5
cd pdflib-7.0.5 && ./configure && make && make install
cd ..
wget http://pecl.php.net/get/pdflib-2.1.8.tgz
tar -zxf pdflib-2.1.8.tgz
mv pdflib-2.1.8 pdflib-pecl-2.1.8
cd pdflib-pecl-2.1.8
phpize && ./configure --with-pdflib && make
cp modules/pdf.so /usr/lib/php5/20090626+lfs/
빌드에 필수 패키지가 설치되어 있습니까? pecl을 통해 설치를 시도 했습니까? – hovanessyan