Re: perl5162-core build/install problem on case-sensitiveFS

Derek Homeier <[email protected]> Tue, 19 Nov 2013 18:42:04 +0100
Newsgroups gmane.os.apple.fink.devel,gmane.os.apple.fink.core
Message-ID <52F4569E-7E5A-482C-9157-2373A96EC2FF@astro.physik.uni-goettingen.de>
Hi Dan,

thanks for the pointer, this seems to be a bigger can of worms than I've thought!

>> It would seem, since the .deb contains both the lower- and uppercase version dirs with their content,
>> it should install just fine on a case-sensitive filesystem, but apparently dpkg-deb is still refusing to
>> install it (even in non-maintainer mode), because the package would be broken on a case-insensitive fs. 
>> I suppose the proper fix would be to manually rename either "version" or "Version" before/during/after
>> the build process to have Requirements.pm and Internals.pod coexist in the same subdir?
> 
> It's broken in several ways, including .deb portability and (in this case) perl functionality relating to filename<->namespace mapping. Perl has fought with this issue for years, and even this specific instance of it. Apparently the .pod is the remnant documentation regarding the actual perl-module fix (maybe there had been a version/Internals.pm that was renamed). See:
> 
> http://www.nntp.perl.org/group/perl.perl5.porters/2011/06/msg173951.html
> 
> that mentions the idea of moving the contents of the .pod into the documentation for another module. That thread talks about it being finally fixed by perl5.18ish, I wonder if perl more recent than 5.16.2 has any improvements in this regard. 

Indeed, so renaming the directories in the source tree does not help, as perl immediately
complains at the beginning of the build. So I tried the less nice approach of fixing things up
afterwards, hoping, as the list mail above indicated, that this would not mess up namespace things, 
but I am certainly a bit over my head into this… With the following changes

@@ -68,6 +68,7 @@
 <<
 
 InstallScript: <<
+#! /bin/sh -ev
  make install DESTDIR=%d
 
  mkdir -p %i/etc/profile.d
@@ -77,6 +78,9 @@
  echo "append_path MANPATH %p/lib/perl5/5.16.2/man" >> %i/etc/profile.d/%N-core.sh
  echo "export MANPATH" >> %i/etc/profile.d/%N-core.sh
  chmod 755 %i/etc/profile.d/%N-core.*
+ if [ ! -f %i/lib/perl5-core/%v/Version/Internals.pod ]; then
+  mv %i/lib/perl5-core/%v/version/Internals.pod %i/lib/perl5-core/%v/Version && rmdir %i/lib/perl5-core/%v/version
+ fi
 
 <<
 SplitOff: <<

perl5162-core and perl5162 build and install in maintainer mode (though the latter has a name conflict
with json-pp-pm - is that package unversioned on purpose?).

But building any of the modules (e.g. test-harness-pm5162) fails at the step

ARCHFLAGS="" /usr/bin/arch -x86_64 perl5.16 Makefile.PL PERL="/usr/bin/arch -x86_64 perl5.16" PREFIX=/sw INSTALLPRIVLIB=/sw/lib/perl5/5.16.2 INSTALLARCHLIB=/sw/lib/perl5/5.16.2/darwin-thread-multi-2level INSTALLSITELIB=/sw/lib/perl5/5.16.2 INSTALLSITEARCH=/sw/lib/perl5/5.16.2/darwin-thread-multi-2level INSTALLMAN1DIR=/sw/share/man/man1 INSTALLMAN3DIR=/sw/share/man/man3 INSTALLSITEMAN1DIR=/sw/share/man/man1 INSTALLSITEMAN3DIR=/sw/share/man/man3 INSTALLBIN=/sw/bin INSTALLSITEBIN=/sw/bin INSTALLSCRIPT=/sw/bin
arch: Can't find perl5.16 in PATH

(there is /sw/bin/perl5.16.2 in PATH, and the equivalent works for "arch -x86_64 perl5.12" vs. /sw/bin/perl5.12.3; 
"/usr/bin/arch -x86_64 perl5.16.2" apparently works as well, but here not without the full versioned name).
I don't know if this is somehow due to Internals.pod now possibly not being found - it seems to contain some
versioning information, but I really don't know anything about perl internals at this level…

						Derek


------------------------------------------------------------------------------
Shape the Mobile Experience: Free Subscription
Software experts and developers: Be at the forefront of tech innovation.
Intel(R) Software Adrenaline delivers strategic insight and game-changing 
conversations that shape the rapidly evolving mobile landscape. Sign up now. 
http://pubads.g.doubleclick.net/gampad/clk?id=63431311&iu=/4140/ostg.clktrk
_______________________________________________
Fink-devel mailing list
[email protected]
List archive:
http://news.gmane.org/gmane.os.apple.fink.devel
Subscription management:
https://lists.sourceforge.net/lists/listinfo/fink-devel