Skip Menu |
 

This queue is for tickets about the Text-BibTeX CPAN distribution.

Report information
The Basics
Id: 67533
Status: resolved
Priority: 0/
Queue: Text-BibTeX

People
Owner: Nobody in particular
Requestors: grousse [...] cpan.org
Cc:
AdminCc:

Bug Information
Severity: Important
Broken in: 0.53
Fixed in: (no value)

Attachments


Subject: wrong assumption about library installation directory
Download (untitled) / with headers
text/plain 582b
The Build.PL scripts assumes library installation directory on non-windows platform can be computed from binary installation directory by substituting 'lib' to 'bin'. However, this is wrong on biarch x86_64 platforms, which use 'lib64' for 64 bits libraries, and triggers runtime failure: https://qa.mandriva.com/show_bug.cgi?id=63052 A simple patch like the attached one is enough to workaround the issue, but it is still an ugly hack. Using a dedicated packaging, such as the previous standalone autotools-based btparse package, seems a much better alternative for native C code.
Subject: Text-BibTeX-0.53-fix-lib64.patch
diff -Naur -x '*~' Text-BibTeX-0.53/Build.PL Text-BibTeX-0.53-fix-lib64/Build.PL --- Text-BibTeX-0.53/Build.PL 2011-03-10 19:37:16.000000000 +0100 +++ Text-BibTeX-0.53-fix-lib64/Build.PL 2011-04-17 15:20:30.000000000 +0200 @@ -3,6 +3,7 @@ use lib 'inc'; use MyBuilder; +use Config; my $version = get_version(); @@ -55,7 +56,11 @@ if ($^O =~ /mswin32/i) { $libdir = $ENV{WINDIR} || 'c:\\WINDOWS\\'; ## HACK HACK HACK } else { - $libdir =~ s/\bbin\b/lib/; + if ($Config{archname} =~ /^x86_64/) { + $libdir =~ s/\bbin\b/lib64/; + } else { + $libdir =~ s/\bbin\b/lib/; + } } $builder->notes('btparse_version' => $version); $builder->notes('lib_path' => $libdir);
Download (untitled) / with headers
text/plain 933b
On Sun Apr 17 09:50:52 2011, GROUSSE wrote: Show quoted text
> The Build.PL scripts assumes library installation directory on > non-windows platform can be computed from binary installation directory > by substituting 'lib' to 'bin'. However, this is wrong on biarch x86_64 > platforms, which use 'lib64' for 64 bits libraries, and triggers runtime > failure: > https://qa.mandriva.com/show_bug.cgi?id=63052 > > A simple patch like the attached one is enough to workaround the issue, > but it is still an ugly hack. Using a dedicated packaging, such as the > previous standalone autotools-based btparse package, seems a much better > alternative for native C code.
Hello. Will try to fix it as soon as possible. Thank you for the patch. Unfortunately autotools are hell to maintain, and do not work out-of-the-box under Windows. Current approach works cleanly with Strawberry Perl, and is making a lot of users happy :) Kindest regards, Alberto
Applied, and sent to cpan. Hope it fixes the issue. Thank you!
Download (untitled) / with headers
text/plain 382b
Le Dim 17 Avr 2011 10:13:02, AMBS a écrit : Show quoted text
> Applied, and sent to cpan. Hope it fixes the issue. Thank you!
Unfortunatly, the patch just hardcode another assumption: x86_64-only linux distributions, such as Debian until latest release, use /usr/lib for their libraries :( A command-line option to select installation directory, instead of a wild guess, may be a better solution.
Download (untitled) / with headers
text/plain 902b
Hello Trying to understand the issue: for linux it is irrelevant if it uses lib or lib64, as far as it is in the loader search path. When installing in a non existing path, to use lib or lib64 will be irrelevant, as the user will need to add the path to ld.so.conf, anyway. If the path exists, then it would be great if I could check where to install (lib or lib64) and that is not that difficult. Am I understanding this issue correctly? Thanks ambs On Thu Apr 21 05:03:38 2011, GROUSSE wrote: Show quoted text
> Le Dim 17 Avr 2011 10:13:02, AMBS a écrit :
> > Applied, and sent to cpan. Hope it fixes the issue. Thank you!
> Unfortunatly, the patch just hardcode another assumption: x86_64-only > linux distributions, such as Debian until latest release, use /usr/lib > for their libraries :( > > A command-line option to select installation directory, instead of a > wild guess, may be a better solution.
Le Jeu 21 Avr 2011 07:17:22, AMBS a écrit : Show quoted text
> Hello > > Trying to understand the issue: for linux it is irrelevant if it uses > lib or lib64, as far as it is in the loader search path. > > When installing in a non existing path, to use lib or lib64 will be > irrelevant, as the user will need to add the path to ld.so.conf, anyway. > > If the path exists, then it would be great if I could check where to > install (lib or lib64) and that is not that difficult. > > Am I understanding this issue correctly?
Almost. Because the loader search path is not constant on dual arch systems, and depend of the architecture of the executed binary. But indeed, if perl has been built for 64 bits, testing /usr/lib64 existence should be enough to distinguish between dual arch and single arch systems. Of course, purist users as myself could still object than self-build stuff should not install under /usr prefix by default, but use /usr/local instead. But that kind of subtility will be hard to enforce with a tool designed to install perl modules.
Download (untitled) / with headers
text/plain 356b
Hello, 0.55 is on CPAN. Its behavior: Is it a 64 system? Does it have a lib64 folder in the Perl install dir? use it! Else Is there a lib folder in the Perl install dir? use it! Else get back to the lib64 folder, and create it as needed Else use lib folder. Hope it is good enough :) Cheers ambs
Download (untitled) / with headers
text/plain 482b
As it lost indentation, here it goes... On Mon Apr 25 10:07:03 2011, AMBS wrote: Show quoted text
> Hello, > > 0.55 is on CPAN. > > Its behavior: > > Is it a 64 system? > Does it have a lib64 folder in the Perl install dir? > use it! > Else > Is there a lib folder in the Perl install dir? > use it! > Else > get back to the lib64 folder, and create it as needed > Else > use lib folder. > > Hope it is good enough :) > > Cheers > ambs
Download (untitled) / with headers
text/plain 363b
Damn RT :S Manually indented :S Its behavior: --- Is it a 64 system? ------ Does it have a lib64 folder in the Perl install dir? --------- use it! ------ Else --------- Is there a lib folder in the Perl install dir? ------------ use it! --------- Else ------------ get back to the lib64 folder, and create it as needed --- Else ------ use lib folder. Phew :)


This service is sponsored and maintained by Best Practical Solutions and runs on Perl.org infrastructure.

Please report any issues with rt.cpan.org to rt-cpan-admin@bestpractical.com.