Getting DBD::Informix running on Mac OS X 10.7 (lion)
Throwing this out there and adding it to the Google-fu mix.
According to the internets, DBD::Informix has issues on Lion. Many different solutions are offered, but this is what worked for me.
Download the “Client SDK” from the IBM site.
The problem: trying to build with out of the box everything, throws up:
lipo: /var/tmp//cc56iZs2.out and /var/tmp//ccKfcTb1.out have the same
architectures (x86_64) and can't be in the same fat output file
Upgrade XCode. I was on 4.1, one-click in the app store and a wait got me to 4.3.
Was your perl compiled with ‘-m64′? Stock mac perl wasn’t. So I brewed a new perl:
perlbrew install perl-5.12.4 -D'-m64'
According to the gcc manual, -m64 is:
Generate code for a 32-bit or 64-bit environment. The 32-bit environment sets
int, long and pointer to 32 bits and generates code that runs on any i386 system.
The 64-bit environment sets int to 32 bits and long and pointer to 64 bits and
generates code for AMD's x86-64 architecture. For darwin only the -m64 option
turns off the -fno-pic and -mdynamic-no-pic options.
Switch to that perl and a ‘perl -V’ should give you:
cc='cc -m64', ccflags ='-fno-common -DPERL_DARWIN -no-cpp-precomp
-fno-strict-aliasing -pipe -fstack-protector -I/usr/local/include',
This article also had some suggestions involving Devel::Patchperl which I didn’t use.