Skip Menu |

This queue is for tickets about the Tie-LevelDB CPAN distribution.

Report information
The Basics
Id: 70978
Status: resolved
Priority: 0/
Queue: Tie-LevelDB

People
Owner: Nobody in particular
Requestors: svetlyo [...] gmail.com
Cc:
AdminCc:

Bug Information
Severity: Important
Broken in: 0.04
Fixed in: (no value)



Subject: Build fails on Mac OS X Snow Leopard - symbols from perl clash with iostream
When building the module, an error occurs because perl.h defines the do_open and do_close macros (without the Perl_ or PL_ prefix) and these clash with the same-named ones from iostream. A quick workaround would be to call #undef do_open #undef do_close just after including perl.h. System environment: Summary of my perl5 (revision 5 version 12 subversion 3) configuration: Platform: osname=darwin, osvers=10.8.0, archname=darwin-thread-multi-2level uname='darwin svetoslav-agafonkins-mac-mini.local 10.8.0 darwin kernel version 10.8.0: tue jun 7 16:33:36 pdt 2011; root:xnu-1504.15.3~1release_i386 i386 ' config_args='-D inc_version_list=5.12.2/darwin-thread-multi-2level 5.12.2 5.12.1/darwin-thread-multi-2level 5.12.1 5.12.0/darwin-thread-multi-2level 5.12.0 - Dusethreads -Duseshrplib -des -Dprefix=/opt/local -Dscriptdir=/opt/local/bin - Dcppflags=-I/opt/local/include -Dccflags=-O2 -arch x86_64 -Dldflags=-L/opt/local/lib - arch x86_64 -Dvendorprefix=/opt/local -Dusemultiplicity=y -D cc=/usr/bin/gcc-4.2 -D ld=/usr/bin/gcc-4.2 -D man1ext=1pm -D man3ext=3pm -D man1dir=/opt/local/share/man/man1p -D man3dir=/opt/local/share/man/man3p -D siteman1dir=/opt/local/share/man/man1 -D siteman3dir=/opt/local/share/man/man3 -D vendorman1dir=/opt/local/share/man/man1 -D vendorman3dir=/opt/local/share/man/man3 -D pager=/usr/bin/less -sR' hint=recommended, useposix=true, d_sigaction=define useithreads=define, usemultiplicity=define useperlio=define, d_sfio=undef, uselargefiles=define, usesocks=undef use64bitint=define, use64bitall=define, uselongdouble=undef usemymalloc=n, bincompat5005=undef Compiler: cc='/usr/bin/gcc-4.2', ccflags ='-O2 -arch x86_64 -fno-common -DPERL_DARWIN - I/opt/local/include -no-cpp-precomp -fno-strict-aliasing -pipe -fstack-protector - I/opt/local/include', optimize='-O3', cppflags='-I/opt/local/include -no-cpp-precomp -O2 -arch x86_64 -fno-common - DPERL_DARWIN -I/opt/local/include -no-cpp-precomp -fno-strict-aliasing -pipe -fstack- protector -I/opt/local/include' ccversion='', gccversion='4.2.1 (Apple Inc. build 5646) (dot 1)', gccosandvers='' intsize=4, longsize=8, ptrsize=8, doublesize=8, byteorder=12345678 d_longlong=define, longlongsize=8, d_longdbl=define, longdblsize=16 ivtype='long', ivsize=8, nvtype='double', nvsize=8, Off_t='off_t', lseeksize=8 alignbytes=8, prototype=define Linker and Libraries: ld='env MACOSX_DEPLOYMENT_TARGET=10.6 /usr/bin/gcc-4.2', ldflags ='- L/opt/local/lib -arch x86_64 -fstack-protector' libpth=/opt/local/lib /usr/lib libs=-lgdbm -ldbm -ldl -lm -lutil -lc perllibs=-ldl -lm -lutil -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='-L/opt/local/lib -arch x86_64 -bundle -undefined dynamic_lookup -fstack-protector' Characteristics of this binary (from libperl): Compile-time options: MULTIPLICITY PERL_DONT_CREATE_GVSV PERL_IMPLICIT_CONTEXT PERL_MALLOC_WRAP USE_64_BIT_ALL USE_64_BIT_INT USE_ITHREADS USE_LARGE_FILES USE_PERLIO USE_PERL_ATOF USE_REENTRANT_API Built under darwin Compiled at Aug 30 2011 11:41:29 @INC: /opt/local/lib/perl5/site_perl/5.12.3/darwin-thread-multi-2level /opt/local/lib/perl5/site_perl/5.12.3 /opt/local/lib/perl5/vendor_perl/5.12.3/darwin-thread-multi-2level /opt/local/lib/perl5/vendor_perl/5.12.3 /opt/local/lib/perl5/5.12.3/darwin-thread-multi-2level /opt/local/lib/perl5/5.12.3 /opt/local/lib/perl5/site_perl /opt/local/lib/perl5/vendor_perl OS details: Darwin mcfro 10.8.0 Darwin Kernel Version 10.8.0: Tue Jun 7 16:33:36 PDT 2011; root:xnu- 1504.15.3~1/RELEASE_I386 i386
Subject: Re: [rt.cpan.org #70978] Build fails on Mac OS X Snow Leopard - symbols from perl clash with iostream
Date: Mon, 19 Sep 2011 14:38:28 +0200
To: bug-Tie-LevelDB [...] rt.cpan.org
From: Martin Sarfy <martin [...] sarfy.cz>
Hi Svetoslav, I do not have MacOS X, please where exactly should I put those #undefs? Thank you, Martin Sarfy On Thu, Sep 15, 2011 at 10:25 AM, Svetoslav Agafonkin via RT < bug-Tie-LevelDB@rt.cpan.org> wrote: Show quoted text
> Thu Sep 15 04:25:19 2011: Request 70978 was acted upon. > Transaction: Ticket created by svetlyo > Queue: Tie-LevelDB > Subject: Build fails on Mac OS X Snow Leopard - symbols from perl clash > with iostream > Broken in: 0.04 > Severity: Important > Owner: Nobody > Requestors: svetlyo@gmail.com > Status: new > Ticket <URL: https://rt.cpan.org/Ticket/Display.html?id=70978 > > > > When building the module, an error occurs because perl.h defines the > do_open and > do_close macros (without the Perl_ or PL_ prefix) and these clash with the > same-named ones > from iostream. A quick workaround would be to call > > > #undef do_open > #undef do_close > > just after including perl.h. > > System environment: > > > Summary of my perl5 (revision 5 version 12 subversion 3) configuration: > > Platform: > osname=darwin, osvers=10.8.0, archname=darwin-thread-multi-2level > uname='darwin svetoslav-agafonkins-mac-mini.local 10.8.0 darwin kernel > version 10.8.0: > tue jun 7 16:33:36 pdt 2011; root:xnu-1504.15.3~1release_i386 i386 ' > config_args='-D inc_version_list=5.12.2/darwin-thread-multi-2level > 5.12.2 > 5.12.1/darwin-thread-multi-2level 5.12.1 5.12.0/darwin-thread-multi-2level > 5.12.0 - > Dusethreads -Duseshrplib -des -Dprefix=/opt/local > -Dscriptdir=/opt/local/bin - > Dcppflags=-I/opt/local/include -Dccflags=-O2 -arch x86_64 > -Dldflags=-L/opt/local/lib - > arch x86_64 -Dvendorprefix=/opt/local -Dusemultiplicity=y -D > cc=/usr/bin/gcc-4.2 -D > ld=/usr/bin/gcc-4.2 -D man1ext=1pm -D man3ext=3pm -D > man1dir=/opt/local/share/man/man1p -D man3dir=/opt/local/share/man/man3p -D > siteman1dir=/opt/local/share/man/man1 -D > siteman3dir=/opt/local/share/man/man3 -D > vendorman1dir=/opt/local/share/man/man1 -D > vendorman3dir=/opt/local/share/man/man3 -D pager=/usr/bin/less -sR' > hint=recommended, useposix=true, d_sigaction=define > useithreads=define, usemultiplicity=define > useperlio=define, d_sfio=undef, uselargefiles=define, usesocks=undef > use64bitint=define, use64bitall=define, uselongdouble=undef > usemymalloc=n, bincompat5005=undef > Compiler: > cc='/usr/bin/gcc-4.2', ccflags ='-O2 -arch x86_64 -fno-common > -DPERL_DARWIN - > I/opt/local/include -no-cpp-precomp -fno-strict-aliasing -pipe > -fstack-protector - > I/opt/local/include', > optimize='-O3', > cppflags='-I/opt/local/include -no-cpp-precomp -O2 -arch x86_64 > -fno-common - > DPERL_DARWIN -I/opt/local/include -no-cpp-precomp -fno-strict-aliasing > -pipe -fstack- > protector -I/opt/local/include' > ccversion='', gccversion='4.2.1 (Apple Inc. build 5646) (dot 1)', > gccosandvers='' > intsize=4, longsize=8, ptrsize=8, doublesize=8, byteorder=12345678 > d_longlong=define, longlongsize=8, d_longdbl=define, longdblsize=16 > ivtype='long', ivsize=8, nvtype='double', nvsize=8, Off_t='off_t', > lseeksize=8 > alignbytes=8, prototype=define > Linker and Libraries: > ld='env MACOSX_DEPLOYMENT_TARGET=10.6 /usr/bin/gcc-4.2', ldflags ='- > L/opt/local/lib -arch x86_64 -fstack-protector' > libpth=/opt/local/lib /usr/lib > libs=-lgdbm -ldbm -ldl -lm -lutil -lc > perllibs=-ldl -lm -lutil -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='-L/opt/local/lib -arch x86_64 -bundle > -undefined > dynamic_lookup -fstack-protector' > > > Characteristics of this binary (from libperl): > Compile-time options: MULTIPLICITY PERL_DONT_CREATE_GVSV > PERL_IMPLICIT_CONTEXT PERL_MALLOC_WRAP > USE_64_BIT_ALL > USE_64_BIT_INT USE_ITHREADS USE_LARGE_FILES > USE_PERLIO USE_PERL_ATOF USE_REENTRANT_API > Built under darwin > Compiled at Aug 30 2011 11:41:29 > @INC: > /opt/local/lib/perl5/site_perl/5.12.3/darwin-thread-multi-2level > /opt/local/lib/perl5/site_perl/5.12.3 > /opt/local/lib/perl5/vendor_perl/5.12.3/darwin-thread-multi-2level > /opt/local/lib/perl5/vendor_perl/5.12.3 > /opt/local/lib/perl5/5.12.3/darwin-thread-multi-2level > /opt/local/lib/perl5/5.12.3 > /opt/local/lib/perl5/site_perl > /opt/local/lib/perl5/vendor_perl > > > OS details: > Darwin mcfro 10.8.0 Darwin Kernel Version 10.8.0: Tue Jun 7 16:33:36 PDT > 2011; root:xnu- > 1504.15.3~1/RELEASE_I386 i386 >
-- Martin Šárfy
From: svetlyo [...] gmail.com
On Mon Sep 19 08:38:59 2011, martin@sarfy.cz wrote: Show quoted text
> Hi Svetoslav, > > I do not have MacOS X, please where exactly should I put those > #undefs? > > Thank you, > Martin Sarfy
See the attached patch.
Subject: undef.diff
--- LevelDB.xs.orij 2011-09-19 23:47:40.000000000 +0300 +++ LevelDB.xs 2011-09-19 23:49:30.000000000 +0300 @@ -8,6 +8,8 @@ #include "ppport.h" //#include <Tie::LevelDB> +#undef do_open +#undef do_close #ifdef __cplusplus }
Subject: Re: [rt.cpan.org #70978] Build fails on Mac OS X Snow Leopard - symbols from perl clash with iostream
Date: Wed, 21 Sep 2011 10:16:47 +0200
To: bug-Tie-LevelDB [...] rt.cpan.org
From: Martin Sarfy <martin [...] sarfy.cz>
Thank you :-) http://cpansearch.perl.org/src/SARFY/Tie-LevelDB-0.05/Changes Have a nice day, Martin On Mon, Sep 19, 2011 at 10:57 PM, Svetoslav Agafonkin via RT < bug-Tie-LevelDB@rt.cpan.org> wrote: Show quoted text
> Queue: Tie-LevelDB > Ticket <URL: https://rt.cpan.org/Ticket/Display.html?id=70978 > > > On Mon Sep 19 08:38:59 2011, martin@sarfy.cz wrote:
> > Hi Svetoslav, > > > > I do not have MacOS X, please where exactly should I put those > > #undefs? > > > > Thank you, > > Martin Sarfy
> > See the attached patch. >
-- Martin Šárfy
It has been fixed long time ago, now I am just closing the request.