#4166 closed defect (worksforme)
perl bindings doesn't respect 64 bit library dir
Reported by: | unnamedhero | Owned by: | Ari Jolma |
---|---|---|---|
Priority: | normal | Milestone: | |
Component: | PerlBindings | Version: | 1.8.1 |
Severity: | normal | Keywords: | |
Cc: |
Description
perl binding always being installed in /usr/lib/per5/.../ but most 64 bit linux system use /usr/lib64 library path. I think it must use --libdir= config variable.
And one more thing - in ogr/ogrsf_frmts/pgeo/ogrpgeodriver.cpp there is a hardcoded library search path
const char* libPath[] = { "/usr/lib", "/usr/local/lib" };
I do not know code structure, but may be it may cause problems with searching some files with /usr/lib64 library path.
Change History (9)
comment:1 by , 13 years ago
Component: | SWIG (all bindings) → PerlBindings |
---|---|
Owner: | changed from | to
comment:2 by , 13 years ago
Priority: | high → normal |
---|---|
Severity: | major → normal |
comment:3 by , 13 years ago
The whole gdal package is configuring with this command
./configure --prefix=/usr \ --libdir=/usr/lib64\ --mandir=/usr/man \ --with-netcdf \ --with-libtiff \ --with-sqlite3 \ --with-geotiff \ --with-mysql \ --with-python \ --without-libtool \ --with-curl \ --with-hdf5 \ --with-perl \ --with-geos \ --with-png \ --with-libz=/usr/lib64\ --with-curl=/usr/bin/curl-config \ --with-hide-internal-symbols=yes \ --enable-static=no make make install
Perl bundings will be installed in <destdir>/usr/lib/perl/<skipped...>
I suppose, perl bindings take options from configure script. If manually run in gdal-1.8.1/swig/perl (but before I forced to run global configure script)
perl Makefile.PL make make install DESTDIR=/<anydir>
in <anydir> we will see directory structure like /usr/lib64/perl5/site_perl
Can you confirm it in any x86_64 distro, which using /usr/lib64 library dir?
comment:4 by , 13 years ago
gdal configure puts arguments into GDALmake.opt, which is included by GNUmakefile in swig/perl and build runs "perl Makefile INSTALL_BASE=$(INST_PREFIX)"
It seems that INSTALL_BASE is in MakeMaker only since 6.31 and the 64bit RHEL I use has MakeMaker 6.30 so it says INSTALL_BASE is not a known parameter.
Anyway, you seem to be saying that build should run "perl Makefile INSTALL_BASE=$(INST_LIB)", which is against what MakeMaker manual seems to be saying.
So, I say it is a deficiency of MakeMaker. It should use lib64 in 64bit environments.
comment:6 by , 9 years ago
Resolution: | → worksforme |
---|---|
Status: | new → closed |
There is some strangeness in the way GDAL Perl modules get installed but I think this is "worksforme" in general.
I will take a look at the Perl modules installation at some later day since I suspect it will need some time.
comment:7 by , 9 years ago
I'm trying to refresh gdal package on openSUSE with last 2.0.0 version. I've applyed already the patch fixing issue #3084 for example.
What worry me is the following situation : We normally have a patch that do the following
- perl Makefile.PL INSTALL_BASE=$(INST_PREFIX)
+ perl Makefile.PL INSTALLDIRS=vendor
With 1.11.2 everyting just work as expected, and perl gdal goes to the vendor path rpm --eval "%perl_vendorarch" /usr/lib/perl5/vendor_perl/5.18.1/x86_64-linux-thread-multi on a x86_64 host.
But whatever combination I've done I got perl installed in /usr/lib/perl5/x86_64-linux-thread-multi
There's something that doesn't applied anymore with the 2x version. But I was not able to find where it failed. (so on my pov : notworkforme :-)
But as my trouble are not strictly related (except perhaps about the review of how perl things are done) it should goes to a new bug entry.
comment:8 by , 9 years ago
INSTALLDIRS should be completely managed by ExtUtils::MakeMaker, on which Makefile.PL of the Perl bindings depend, so I'd blame it. Did Perl version change openSUSE since the last update or something similar? On a quick google search I find some changes to how INSTALLDIRS is changed in Perl 5.11+.
comment:9 by , 9 years ago
Bruno,
Did you solve this problem? The workings of ExtUtils::MakeMaker are extremely complex. See for example the note in the Perl bindings Readme https://svn.osgeo.org/gdal/trunk/gdal/swig/perl/README
Please feel free to email me to discuss this issue further if you need to.
Ari
The Perl bindings uses ExtUtils::MakeMaker and so the default installation location is determined by it. That may be changed by specifying arguments to Makefile.PL. So I'd say "works for me", but will wait for patches / more explanation. Especially, provide --libdir= to what?
Ari