in reply to Really stumped trying to compile DBD::ODBC

Not sure if this applies here, but I've had problems in the past where modules try to compile with a different C compiler than the base perl build uses. You should be able to find out what C compiler and options your perl was built with via perl -V. Good luck.
  • Comment on Re: Really stumped trying to compile DBD::ODBC

Replies are listed 'Best First'.
Re^2: Really stumped trying to compile DBD::ODBC
by blairkutz (Initiate) on Feb 19, 2008 at 21:31 UTC
    Thanks for the reply!

    Ok so this is the Perl -V output from the perl installed with leopard

    Summary of my perl5 (revision 5 version 8 subversion 8) configuration: Platform: osname=darwin, osvers=9.0, archname=darwin-thread-multi-2level uname='darwin omen.apple.com 9.0 darwin kernel version 9.0.0b5: mo +n sep 10 17:17:11 pdt 2007; root:xnu-1166.6~1release_ppc power macint +osh ' config_args='-ds -e -Dprefix=/usr -Dccflags=-g -pipe -Dldflags=- +Dman3ext=3pm -Duseithreads -Duseshrplib' hint=recommended, useposix=true, d_sigaction=define usethreads=define use5005threads=undef useithreads=define usemulti +plicity=define useperlio=define d_sfio=undef uselargefiles=define usesocks=undef use64bitint=define use64bitall=define uselongdouble=undef usemymalloc=n, bincompat5005=undef Compiler: cc='cc', ccflags ='-arch i386 -arch ppc -g -pipe -fno-common -DPER +L_DARWIN -no-cpp-precomp -fno-strict-aliasing -Wdeclaration-after-sta +tement -I/usr/local/include', optimize='-O3', cppflags='-no-cpp-precomp -g -pipe -fno-common -DPERL_DARWIN -no-c +pp-precomp -fno-strict-aliasing -Wdeclaration-after-statement -I/usr/ +local/include' ccversion='', gccversion='4.0.1 (Apple Inc. build 5465)', gccosand +vers='' intsize=4, longsize=4, ptrsize=4, doublesize=8, byteorder=1234 d_longlong=define, longlongsize=8, d_longdbl=define, longdblsize=1 +6 ivtype='long', ivsize=4, nvtype='double', nvsize=8, Off_t='off_t', + lseeksize=8 alignbytes=8, prototype=define Linker and Libraries: ld='cc -mmacosx-version-min=10.5', ldflags ='-arch i386 -arch ppc +-L/usr/local/lib' libpth=/usr/local/lib /usr/lib libs=-ldbm -ldl -lm -lutil -lc perllibs=-ldl -lm -lutil -lc libc=/usr/lib/libc.dylib, so=dylib, useshrplib=true, libperl=libpe +rl.dylib gnulibc_version='' Dynamic Linking: dlsrc=dl_dlopen.xs, dlext=bundle, d_dlsymun=undef, ccdlflags=' ' cccdlflags=' ', lddlflags='-arch i386 -arch ppc -bundle -undefined + dynamic_lookup -L/usr/local/lib' Characteristics of this binary (from libperl): Compile-time options: MULTIPLICITY PERL_IMPLICIT_CONTEXT PERL_MALLOC_WRAP USE_ITHREADS USE_LARGE_FILES USE_PERLIO USE_REENTRANT_API Locally applied patches: fix for regcomp CVE-2007-5116 security vulnerability Built under darwin Compiled at Dec 7 2007 09:37:29 @INC: /System/Library/Perl/5.8.8/darwin-thread-multi-2level /System/Library/Perl/5.8.8 /Library/Perl/5.8.8/darwin-thread-multi-2level /Library/Perl/5.8.8 /Library/Perl /Network/Library/Perl/5.8.8/darwin-thread-multi-2level /Network/Library/Perl/5.8.8 /Network/Library/Perl /System/Library/Perl/Extras/5.8.8/darwin +-thread-multi-2level /System/Library/Perl/Extras/5.8.8 /Library/Perl/5.8.6 /Library/Perl/5.8.1 .

    Then the ActivePerl -V

    $ /usr/local/ActivePerl-5.8/bin/perl -V Summary of my perl5 (revision 5 version 8 subversion 8) configuration: Platform: osname=darwin, osvers=8.10.0, archname=darwin-thread-multi-2level uname='darwin sphinx 8.10.0 darwin kernel version 8.10.0: wed may +23 16:50:59 pdt 2007; root:xnu-792.21.3~1release_ppc power macintosh +powerpc ' config_args='-ders -Dcc=gcc -Dusethreads -Duseithreads -Ud_sigsetj +mp -Uinstallusrbinperl -Ulocincpth= -Uloclibpth= -Ud_poll -Ui_poll -U +d_pthread_atfork -Ud_msg -Ud_lchown -Ud_attribute_format -Ud_attribut +e_malloc -Ud_attribute_nonnull -Ud_attribute_noreturn -Ud_attribute_p +ure -Ud_attribute_unused -Ud_attribute_warn_unused_result -Aldflags=- +Wl,-search_paths_first -Alddlflags=-Wl,-search_paths_first -Accflags= +-arch ppc -arch i386 -Aldflags=-arch ppc -arch i386 -Alddlflags=-arch + ppc -arch i386 -Accflags=-nostdinc -B/Developer/SDKs/MacOSX10.4u.sdk +/usr/include/gcc -B/Developer/SDKs/MacOSX10.4u.sdk/usr/lib/gcc -isyst +em/Developer/SDKs/MacOSX10.4u.sdk/usr/include -F/Developer/SDKs/MacOS +X10.4u.sdk/System/Library/Frameworks -mmacosx-version-min=10.3 -Aldfl +ags=-Wl,-syslibroot,/Developer/SDKs/MacOSX10.4u.sdk -mmacosx-version- +min=10.3 -Alddlflags=-Wl,-syslibroot,/Developer/SDKs/MacOSX10.4u.sdk +-mmacosx-version-min=10.3 -Accflags=-DUSE_SITECUSTOMIZE -Duselargefil +es -Accflags=-DNO_HASH_SEED -Accflags=-DPRIVLIB_LAST_IN_INC -Dprefix= +/usr/local/ActivePerl-5.8 -Dprivlib=/usr/local/ActivePerl-5.8/lib -Da +rchlib=/usr/local/ActivePerl-5.8/lib -Dsiteprefix=/usr/local/ActivePe +rl-5.8/site -Dsitelib=/usr/local/ActivePerl-5.8/site/lib -Dsitearch=/ +usr/local/ActivePerl-5.8/site/lib -Dsed=/usr/bin/sed -Duseshrplib -Dc +onfig_heavy=Config_dynamic.pl -Dcf_by=ActiveState -Dcf_email=support@ +ActiveState.com' hint=recommended, useposix=true, d_sigaction=define usethreads=define use5005threads=undef useithreads=define usemulti +plicity=define useperlio=define d_sfio=undef uselargefiles=define usesocks=undef use64bitint=undef use64bitall=undef uselongdouble=undef usemymalloc=n, bincompat5005=undef Compiler: cc='gcc', ccflags ='-fno-common -DPERL_DARWIN -no-cpp-precomp -arc +h ppc -arch i386 -nostdinc -B/Developer/SDKs/MacOSX10.4u.sdk/usr/incl +ude/gcc -B/Developer/SDKs/MacOSX10.4u.sdk/usr/lib/gcc -isystem/Develo +per/SDKs/MacOSX10.4u.sdk/usr/include -F/Developer/SDKs/MacOSX10.4u.sd +k/System/Library/Frameworks -mmacosx-version-min=10.3 -DUSE_SITECUSTO +MIZE -DNO_HASH_SEED -DPRIVLIB_LAST_IN_INC -fno-strict-aliasing -pipe' +, optimize='-O3', cppflags='-no-cpp-precomp -fno-common -DPERL_DARWIN -no-cpp-precom +p -arch ppc -nostdinc -B/Developer/SDKs/MacOSX10.4u.sdk/usr/include/g +cc -B/Developer/SDKs/MacOSX10.4u.sdk/usr/lib/gcc -isystem/Developer/S +DKs/MacOSX10.4u.sdk/usr/include -F/Developer/SDKs/MacOSX10.4u.sdk/Sys +tem/Library/Frameworks -mmacosx-version-min=10.3 -DUSE_SITECUSTOMIZE +-DNO_HASH_SEED -DPRIVLIB_LAST_IN_INC -fno-strict-aliasing -pipe' ccversion='', gccversion='i686-apple-darwin9-gcc-4.0.1 (GCC) 4.0.1 + (Apple Inc. build 5465)', gccosandvers='' intsize=4, longsize=4, ptrsize=4, doublesize=8, byteorder=1234 d_longlong=define, longlongsize=8, d_longdbl=define, longdblsize=1 +6 ivtype='long', ivsize=4, nvtype='double', nvsize=8, Off_t='off_t', + lseeksize=8 alignbytes=8, prototype=define Linker and Libraries: ld='env MACOSX_DEPLOYMENT_TARGET=10.3 cc', ldflags =' -Wl,-search_ +paths_first -arch ppc -arch i386 -Wl,-syslibroot,/Developer/SDKs/MacO +SX10.4u.sdk -mmacosx-version-min=10.3' libpth=/usr/lib /usr/local/lib libs=-ldbm -ldl -lm -lc perllibs=-ldl -lm -lc libc=, so=dylib, useshrplib=true, libperl=libperl.dylib gnulibc_version='' Dynamic Linking: dlsrc=dl_dlopen.xs, dlext=bundle, d_dlsymun=undef, ccdlflags=' ' cccdlflags=' ', lddlflags=' -bundle -undefined dynamic_lookup -Wl, +-search_paths_first -arch ppc -arch i386 -Wl,-syslibroot,/Developer/S +DKs/MacOSX10.4u.sdk -mmacosx-version-min=10.3' Characteristics of this binary (from libperl): Compile-time options: MULTIPLICITY PERL_IMPLICIT_CONTEXT PERL_MALLOC_WRAP USE_ITHREADS USE_LARGE_FILES USE_PERLIO USE_REENTRANT_API USE_SITECUSTOMIZE Locally applied patches: ActivePerl Build 822 [280952] PerlEx support in CGI::Carp Less verbose ExtUtils::Install and Pod::Find Patch for CAN-2005-0448 from Debian with modifications Rearrange @INC so that 'site' is searched before 'perl' Partly reverted 24733 to preserve binary compatibility MAINT31223 plus additional changes 31324 Fix DynaLoader::dl_findfile() to locate .so files again 26970 Make Passive mode the default for Net::FTP 24699 ICMP_UNREACHABLE handling in Net::Ping Built under darwin Compiled at Jul 31 2007 19:44:51 @INC: /var/root/Library/ActivePerl/lib /usr/local/ActivePerl-5.8/site/lib /usr/local/ActivePerl-5.8/lib .
      The problem is the use of structure member names 'true' and 'false'. The compiler on os x does not seem to like these - perhaps they are macros. Just change all occurrences of 'true' and 'false' to xtrue and xfalse to fix or upgrade to DBD::ODBC 1.16 where this is fixed.
        I didn't realise I was not logged in when I posted this. I know this to be the issue because I fixed it in 1.16.