The real problem may be your perl is buggy or it's configuration is incorrect (or is just compiled with some special restrictions) /real solution would be fixing perl/.
Would be better if you first get a simplified test running (maybe loading your own simpler module instead of Bugzilla). Here another option which seems to work for me (dynamic addition to paths): my $installation_directory; BEGIN { $installation_directory = "/your/path/to/bugzilla"; } use lib "$installation_directory/lib"; use lib "$installation_directory"; I.e. - variables initialized in BEGIN block are allowed to be referenced by use lib. Yavor On Wed, Mar 9, 2011 at 16:14, Marcel Loose <lo...@astron.nl> wrote: > On Wed, 2011-03-09 at 14:55 +0100, Thorsten Schöning wrote: > > Guten Tag Marcel Loose, > > am Mittwoch, 9. März 2011 um 14:42 schrieben Sie: > > > > > One solution -- set PERL5LIB in /etc/init.d/scmbug-server -- was > already > > > suggested by Thorsten and works. Personally I can happily live with > that > > > solution. However, Kristis rejected it as not being a "real" solution, > > > because it contains a hard-coded path in scmbug-server. So, the quest > is > > > now for the "real" solution! > > > > use lib is the real solution, but seems to not work with a dynamically > > created path. Did we had a try with the hardcoded path and use lib? If > > not, one could try that and I bet it would work like setting PERL5LIB. > > > > And I found, why use lib won't work: > > > > > lib - manipulate @INC at compile time > > > > > http://perldoc.perl.org/lib.html > > > > So that's probably the reason why > > unshift @INC, $self->installation_directory(); > > is used instead. > > Is the fact that > <quote> > "use lib LIST;" > is /almost/ the same as saying > "BEGIN { unshift(@INC, LIST) }" > </quote> > the reason that the latter doesn't work, whereas setting PERL5LIB does? > I cannot really deduce that from the documentation of "use lib". > > > During compile time there's of course no > > $self->installation_directory of any kind. Seems I need glasses. ;-) > > > > Mit freundlichen Grüßen, > > > > Thorsten Schöning > > > > Cheers, > Marcel Loose. > > > _______________________________________________ > scmbug-users mailing list > scmbug-users@lists.mkgnu.net > http://lists.mkgnu.net/cgi-bin/mailman/listinfo/scmbug-users >
_______________________________________________ scmbug-users mailing list scmbug-users@lists.mkgnu.net http://lists.mkgnu.net/cgi-bin/mailman/listinfo/scmbug-users