-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 4/27/10 8:47 PM, PFudd wrote:
> On Tue, 2010-04-27 at 19:47 -0400, Alexander Hansen wrote:
>> -----BEGIN PGP SIGNED MESSAGE-----
>> Hash: SHA1
>>
>> On 4/27/10 7:26 PM, PFudd wrote:
>>> Hi..
>>>
>>> I was having this problem, and I finally found the answer when I noticed
>>> that there were perl cgi scripts successfully using DBD::mysql while I
>>> was getting the '_mysql_init not found' error with the command line.
>>>
>>> The problem is the environment variable VERSIONER_PERL_PREFER_32_BIT.
>>> When it is set to 'yes', I get the error, but when it's unset or 'no',
>>> everything works.  This variable is set in /sw/etc/profile.d/fink.sh and
>>> fink.csh, and it's one of the few situations where a fink change affects
>>> the rest of the operating system.
>>>
>>> As for how to remedy the problem, I haven't figured that part out yet.
>>> Do I have to rebuild fink from scratch in 64 bit mode?
>>>
>>> Thanks!
>>>
>>>
>>
>> Hard to say, given that you haven't actually told us anything other than
>> that you had "this problem" (which doesn't appear to be that mentioned
>> in the subject).  Nor did you mention what OS you're on (we'll assume
>> you're on 32-bit Fink on 10.6).
>>
>> Not using 32-bit Fink would be one solution, I guess.
> 
> I apologize, my reply to Oliver Niehuis's thread entitled "Re:
> [Fink-beginners] dbd-mysql-pm5100 installation problem" from yesterday
> was not clear enough.
> 
> I was having the exact same problem, also on SnowLeopard.  I could not
> install the dbd-mysql-pm5100 package, due to the error:
> 
> Can't load
> '/sw/lib/perl5/5.10.0/darwin-thread-multi-2level/auto/DBI/DBI.bundle'
> for module DBI:
> dlopen(/sw/lib/perl5/5.10.0/darwin-thread-multi-2level/auto/DBI/DBI.bundle,
> 1): no suitable image found.  Did find:
>       /sw/lib/perl5/5.10.0/darwin-thread-multi-2level/auto/DBI/DBI.bundle:
> mach-o, but wrong architecture at
> /System/Library/Perl/5.10.0/darwin-thread-multi-2level/DynaLoader.pm
> line 207.
> 
> This problem (no suitable image found, due to wrong architecture) also
> occurred when trying to compile gd-graph-pm588 a couple of weeks ago,
> but we worked around the problem by giving up and using an older
> computer running Leopard.

Did you report it?  I can't find that in my archives.  We aren't
mind-readers and don't have a connection to your machine, and so we
don't know if a package is broken unless we receive a report.

> 
> Trying to reinstall DBD::mysql was just one step in a long, tedious,
> confusing, frustrating and altogether f***ed up debugging process:
> 

<snip 1-3 as irrelevant to Fink>

> 
> 4. Install DBI and fail to install DBD::mysql from fink (compile error
> seen above by me and Oliver).
> 
> 5. Install mysql from fink despite mysql being installed on system by
> Apple.  I really don't want to damage the system version.
> 

It shouldn't hurt anything.  It's supposed to be able to coexist.

> 

<snip 6-10 as also irrelevant to Fink>

> 
> 11. Careful trial and error of:
>   a. deleting all environment variables from the test CGI script
>   b. adding back just the essential ones: PATH and PERL5LIB (for the
> vendor's packages)
>   c. trying one variable from the command line environment at a time
> until the CGI script can no longer run the command line program
>   d. finding that VERSIONER_PERL_PREFER_32_BIT=yes is the guilty party
> 
> 12. Looking for VERSIONER_PERL_PREFER_32_BIT in my startup files
> and /etc directory tree was fruitless.
> 
> 13. In a moment of clarity, check /sw/etc directory tree: found it!
> 
> 14. unsetenv VERSIONER_PERL_PREFER_32_BIT makes command line programs
> work.
> 
> 15. Find someone to tell this to.
> 
> Anyhoo, yes, the problem is that #$%#$ environment variable.  It's set
> by Fink, and affects non-fink programs started from the command line.
> The web server is unaffected, since it doesn't run
> the /sw/etc/profile.d/fink.sh file; that server is started from launchd.
> 
> The problem (bad architecture) Oliver had is one of the steps listed
> above (#4), and is intimately related to that environment variable.
> It's possible that he's installing dbd-mysql-pm5100 in an effort to
> solve the same problem I encountered (the system DBD::mysql doesn't
> work, gives _mysql_init not found error).  The process of uninstalling
> and reinstalling things in an effort to get the architecture consistent
> was suggested by various articles found via Google, and didn't work.

Again, that's not our problem.

> 
> Does that spell things out enough?
> 
> 
> 

It's clearer now.  The original message was a bit too jammed together
for me to parse out what exactly was being reported.

So there are two issues which are actually within _our_ scope here:

1)  make dbd-mysql-pm5100 work--which is probably not too hard, and just
requires somebody to take the time to do it.

2)  determine whether VERSIONER_PERL_PREFER_32_BIT has to be set at
runtime for fink to work.  That might be more involved.

As a workaround, you might try deactivating the ". /sw/bin/init.sh" in
your .profile, and run that manually when you need to use Fink stuff or
do builds.  That way the environment variable won't be set unless it
needs to be.

- -- 
Alexander Hansen
Fink User Liaison
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.10 (Darwin)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iEYEARECAAYFAkvXjmYACgkQB8UpO3rKjQ8HVwCgjHH9lCAEUq+qKlVVs+izrR+R
eTYAnRUCYAO04FZDL5sL9MqDgCNf4PJs
=/pOT
-----END PGP SIGNATURE-----

------------------------------------------------------------------------------
_______________________________________________
Fink-beginners mailing list
[email protected]
http://news.gmane.org/gmane.os.apple.fink.beginners

Reply via email to