PERLINC in gnc-fq-*

John Ralls jralls at ceridwen.us
Thu Dec 10 15:24:03 EST 2009


On Dec 9, 2009, at 9:48 AM, Derek Atkins wrote:

> John Ralls <jralls at ceridwen.us> writes:
> 
>> A user complained in gnucash-users that gnc-fq-check failed on him
>> because of the line "use lib
>> /System/Library/Perl/5.8.8/darwin-thread-multi-2level". The directory
>> gets inserted at build time from running PERLINCL=`$PERL -MConfig -e
>> 'print $Config{"archlibexp"}'` in configure.
>> 
>> What's the point of that? That directory is already in @INC on the
>> build machine, but if the user doesn't have the exact same version of
>> perl installed, it will raise an exception because the directory won't
>> exist.
> 
> My GUESS is that there was a worry that it wouldn't be in @INC on the
> target machine, but I don't know if that makes any sense.
> 

OK. I dug into the history a bit. 

It seems that once upon a time, Gnucash embedded a perl interpreter and needed to find the perl headers in order to build it. That's why PERLINC was added to configure.in. At that time, GC had its own quote mechanism (written in perl, perhaps why the embedded perl interpreter was provided). Over the course of 2000, this was removed and replaced with F::Q, but the folks who wrote the perl module didn't really understand what PERLINC was about and included that "use lib" statement in three of the 5 perl programs.

It's the wrong thing to do.

So I've got a changeset ready to check in which removes the use lib line and changes the configurable shebang to /usr/bin/perl -w in each of gnc-fq-check, gnc-fq-helper, and gnc-fq-update; since there's no need to plug in anything anymore, those are renamed from their respective *.in. Makefile.in is adjusted accordingly.

For configure.in I've removed the PERLINC section. I've also removed the configurable perl section; as far as I can tell only intltool uses perl and it has its own perl invocation variable. 

If there are no objections, I'll check this into trunk.

Regards,
John Ralls



More information about the gnucash-devel mailing list