After spending 3-4 days for searching solutions for fixing the error with GD module used in koha, finally I am successful to upload the patron images in to koha after referring many forums. and am documenting the same here.
I manually installed GD after downloading it from CPAN.
the perl dependencies check was not showing any problem but while uploading patron images I was getting following error:
Can't locate object method "newFromjPeg" via package "GD::Image" at /usr/local/lib/perl/5.10.1/GD/Image.pm line 81.
Reason: ( provided in the various forums)
Building GD perl modules or libgd without jpeg/png support might cause
that error. libgd-gd2-perl ( in ubuntu) which is good enough
and should be used instead of build-it-yourself from cpan.
Steps followed :
Adding the lib path (in specific to Red Hat/Fedora)
1) open /etc/ld.so.conf and add
Include /usr/local/lib
and run
#ldconfig -v
------
2) libgd
+ Downloaded from : https://bitbucket.org/libgd/gd-libgd/downloads
+ mkdir /usr/local/gd
+ ./configure --prefix=/usr/local/gd --with-jpeg=/usr/local/jpeg-6b
+ make
+ make install
or
../configure --enable-shared
make && make install
3) install libpng:
Download at: http://www.ijg.org/files/
make && make install
In detail:
+ mkdir /usr/local/jpeg-6b
+ mkdir /usr/local/jpeg-6b/bin
+ mkdir /usr/local/jpeg-6b/man
+ mkdir /usr/local/jpeg-6b/man/man1
+ mkdir /usr/local/jpeg-6b/incude
+ mkdir /usr/local/jpeg-6b/lib
+ ./configure --prefix=/usr/local/jpeg-6b --enable-shared
+ make
+ make test
+ make install
4) install jpeg libs :
../configure --enable-shared
make && make install
5) install freetype2:
../configure
make && make install
6) png/jpeg packages
search libpng in debian packages.
eg: libpng3_1.2.44-1+squeeze4_all.deb
7) install perl module GD
download GD-2.49.tar.gz from CPAN
LD_LIBRARY_PATH="/usr/local/lib"
In detail:
+ export
LD_LIBRARY_PATH=/usr/local/lib:/usr/local/gd/lib:/usr/local/zlib/lib:/usr/local/jpeg-6b/lib:$LD_LIBRARY_PATH
+ perl Makefile.PL GD_JPEG -lib_gd_path /usr/local/gd -lib_jpeg_path
/usr/local/jpeg-6b -lib_zlib_path /usr/local/zlib
I manually installed GD after downloading it from CPAN.
the perl dependencies check was not showing any problem but while uploading patron images I was getting following error:
Can't locate object method "newFromjPeg" via package "GD::Image" at /usr/local/lib/perl/5.10.1/GD/Image.pm line 81.
Reason: ( provided in the various forums)
Building GD perl modules or libgd without jpeg/png support might cause
that error. libgd-gd2-perl ( in ubuntu) which is good enough
and should be used instead of build-it-yourself from cpan.
Steps followed :
Adding the lib path (in specific to Red Hat/Fedora)
1) open /etc/ld.so.conf and add
Include /usr/local/lib
and run
#ldconfig -v
------
2) libgd
+ Downloaded from : https://bitbucket.org/libgd/gd-libgd/downloads
+ mkdir /usr/local/gd
+ ./configure --prefix=/usr/local/gd --with-jpeg=/usr/local/jpeg-6b
+ make
+ make install
or
../configure --enable-shared
make && make install
3) install libpng:
Download at: http://www.ijg.org/files/
make && make install
In detail:
+ mkdir /usr/local/jpeg-6b
+ mkdir /usr/local/jpeg-6b/bin
+ mkdir /usr/local/jpeg-6b/man
+ mkdir /usr/local/jpeg-6b/man/man1
+ mkdir /usr/local/jpeg-6b/incude
+ mkdir /usr/local/jpeg-6b/lib
+ ./configure --prefix=/usr/local/jpeg-6b --enable-shared
+ make
+ make test
+ make install
4) install jpeg libs :
../configure --enable-shared
make && make install
5) install freetype2:
../configure
make && make install
6) png/jpeg packages
search libpng in debian packages.
eg: libpng3_1.2.44-1+squeeze4_all.deb
7) install perl module GD
download GD-2.49.tar.gz from CPAN
LD_LIBRARY_PATH="/usr/local/lib"
export LD_LIBRARY_PATH
perl Makefile.PL
make && make test && make install
perl Makefile.PL
make && make test && make install
In detail:
+ export
LD_LIBRARY_PATH=/usr/local/lib:/usr/local/gd/lib:/usr/local/zlib/lib:/usr/local/jpeg-6b/lib:$LD_LIBRARY_PATH
+ perl Makefile.PL GD_JPEG -lib_gd_path /usr/local/gd -lib_jpeg_path
/usr/local/jpeg-6b -lib_zlib_path /usr/local/zlib
No comments:
Post a Comment