Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 378865 - dev-db/postgresql-server-9.0.4-r2[perl] fails to build because of mismatch of ExtUtils::ParseXS
Summary: dev-db/postgresql-server-9.0.4-r2[perl] fails to build because of mismatch of...
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Server (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: PgSQL Bugs
: 378897 380971 384141 (view as bug list)
Depends on:
Blocks: ExtUtils-ParseXS-3
  Show dependency tree
Reported: 2011-08-12 06:59 UTC by Graham Murray
Modified: 2011-12-08 03:16 UTC (History)
8 users (show)

See Also:
Package list:
Runtime testing required: ---

ExtUtils::ParseXS patch for configure path discovery (perl-ExtUtils-ParseXS.patch,737 bytes, patch)
2011-08-24 00:09 UTC, Aaron W. Swenson
Details | Diff
Implements proper path detection (xsubpp.patch,2.50 KB, patch)
2011-10-17 01:01 UTC, Aaron W. Swenson
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Graham Murray 2011-08-12 06:59:48 UTC
plperl.c:777:1: warning: control reaches end of non-void function
"/usr/bin/perl" /usr/lib/perl5/5.12.4/ExtUtils/xsubpp -typemap /usr/lib/perl5/5.12.4/ExtUtils/typemap SPI.xs >SPI.c
Undefined subroutine &ExtUtils::ParseXS::errors called at /usr/lib/perl5/5.12.4/ExtUtils/xsubpp line 41.

emerge --info
Portage 2.2.0_alpha50 (default/linux/x86/10.0/desktop/gnome, gcc-4.5.3, glibc-2.13-r4, 3.0.1-gentoo i686)
System uname: Linux-3.0.1-gentoo-i686-Intel-R-_Core-TM-2_Duo_CPU_E8200_@_2.66GHz-with-gentoo-2.0.3
Timestamp of tree: Thu, 11 Aug 2011 06:30:01 +0000
app-shells/bash:          4.2_p10
dev-java/java-config:     2.1.11-r3
dev-lang/python:          2.6.7-r2, 2.7.2-r2, 3.1.4-r2, 3.2-r2
dev-util/cmake:           2.8.5-r2
dev-util/pkgconfig:       0.26
sys-apps/baselayout:      2.0.3
sys-apps/openrc:          0.8.3-r1
sys-apps/sandbox:         2.5
sys-devel/autoconf:       2.13, 2.68
sys-devel/automake:       1.9.6-r3, 1.10.3, 1.11.1-r1
sys-devel/binutils:       2.21.1
sys-devel/gcc:            4.4.6, 4.5.3
sys-devel/gcc-config:     1.4.1-r1
sys-devel/libtool:        2.4-r1
sys-devel/make:           3.82-r1
sys-kernel/linux-headers: 2.6.38 (virtual/os-headers)
sys-libs/glibc:           2.13-r4
Repositories: gentoo sunrise x11 bitcoin Grahams_local_portage
Installed sets: @system
CFLAGS="-O2 -march=native -mtune=native -pipe -ggdb"
CONFIG_PROTECT="/etc /usr/share/config /usr/share/gnupg/qualified.txt /var/bind /var/lib/hsqldb"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/env.d/java/ /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/php/apache2-php5.3/ext-active/ /etc/php/cgi-php5.3/ext-active/ /etc/php/cli-php5.3/ext-active/ /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo /etc/texmf/language.dat.d /etc/texmf/language.def.d /etc/texmf/updmap.d /etc/texmf/web2c"
CXXFLAGS="-O2 -march=native -mtune=native -pipe -ggdb"
EMERGE_DEFAULT_OPTS="--with-bdeps y --autounmask-write y"
FEATURES="assume-digests binpkg-logs buildsyspkg distlocks ebuild-locks fixlafiles fixpackages news parallel-fetch preserve-libs protect-owned sandbox sfperms splitdebug strict unknown-features-warn unmerge-logs unmerge-orphans userfetch"
LDFLAGS="-Wl,-O1 -Wl,--as-needed"
LINGUAS="en_GB en"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --stats --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages"
PORTDIR_OVERLAY="/var/lib/layman/sunrise /var/lib/layman/x11 /var/lib/layman/bitcoin /usr/portage/local"
USE="X a52 aac acl acpi alsa apache2 avahi bash-completion berkdb branding bzip2 cairo caps cdda cdr cli consolekit cracklib crypt cups curl cvs cxx dbus doc dri dts dvd dvdr eds emacs emboss encode evo examples exif expat fam ffmpeg flac fortran gd gdbm gdu geoip gif gnome gnome-keyring gnutls gpm gstreamer gtk gtkhtml hardened htmlhandbook iconv icu idn imagemagick imlib ipv6 java jpeg kde kdehiddenvisibility lcms ldap libnotify libsamplerate logrotate lzma lzo mad mmap mmx mng modules mono mp3 mp4 mpeg mudflap nautilus ncurses nls nptl nptlonly nsplugin ogg opengl openmp pam pango pcre pdf perl pic png policykit postgres ppds pppd pulseaudio python qt3support qt4 readline samba sdl semantic-desktop session speex spell sqlite sqlite3 sse sse2 ssl startup-notification subversion svg sysfs tcl tcpd theora threads tiff tk truetype udev unicode usb vim-syntax vorbis x264 x86 xattr xcb xcomposite xml xorg xulrunner xv xvid zlib" ALSA_CARDS="intel-hda" ALSA_PCM_PLUGINS="adpcm alaw asym copy dmix dshare dsnoop empty extplug file hooks iec958 ioplug ladspa lfloat linear meter mmap_emul mulaw multi null plug rate route share shm softvol" APACHE2_MODULES="actions alias auth_basic authn_alias authn_anon authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache cgi cgid dav dav_fs dav_lock deflate dir disk_cache env expires ext_filter file_cache filter headers include info log_config logio mem_cache mime mime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias" APACHE2_MPMS="worker" CALLIGRA_FEATURES="braindump flow karbon kexi kpresenter krita tables words" CAMERAS="ptp2" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" ELIBC="glibc" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock itrax mtk3301 nmea ntrip navcom oceanserver oldstyle oncore rtcm104v2 rtcm104v3 sirf superstar2 timing tsip tripmate tnt ubx" INPUT_DEVICES="keyboard mouse evdev" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LINGUAS="en_GB en" PHP_TARGETS="php5-3" RUBY_TARGETS="ruby18" USERLAND="GNU" VIDEO_CARDS="vesa fbdev nv nouveau" XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipset ipp2p iface geoip fuzzy condition tee tarpit sysrq steal rawnat logmark ipmark dhcpmac delude chaos account" 
Comment 1 Torsten Veller (RETIRED) gentoo-dev 2011-08-12 12:17:59 UTC
*** Bug 378897 has been marked as a duplicate of this bug. ***
Comment 2 Kent Fredric (IRC: kent\n) (RETIRED) gentoo-dev 2011-08-18 12:18:36 UTC
The error as far as I can make out appears to be caused by calling the wrong xsubpp method. 

Vim also appears to suffer this problem. 

# cd /tmp/portage/app-editors-vim-7.3.266/work/vim73/src  

using the xsubpp shipped in Perl:

# /usr/bin/perl /usr/lib64/perl5/5.14.1/ExtUtils/xsubpp -prototypes -typemap /usr/lib64/perl5/5.14.1/ExtUtils/typemap if_perl.xs >> auto/if_perl.c
Undefined subroutine &ExtUtils::ParseXS::errors called at /usr/lib64/perl5/5.14.1/ExtUtils/xsubpp line 41.

using the xsubpp shiped in perl-core/ExtUtils-ParseXS

# /usr/bin/perl /usr/lib64/perl5/vendor_perl/5.14.1/ExtUtils/xsubpp -prototypes -typemap /usr/lib64/perl5/5.14.1/ExtUtils/typemap if_perl.xs >> auto/if_perl.c

the former of course fails because the latter is installed and thus,  the xsubpp from perl uses the modules shipped with ParseXS instead.
Comment 3 Ivan Havlicek 2011-08-18 15:07:04 UTC

For now, the only way I found to solve this :

# mv /usr/lib64/perl5/5.12.4/ExtUtils/xsubpp /usr/lib64/perl5/5.12.4/ExtUtils/xsubpp.bad
# ln -s /usr/lib64/perl5/vendor_perl/5.12.4/ExtUtils/xsubpp /usr/lib64/perl5/5.12.4/ExtUtils/xsubpp

# emerge dev-db/postgresql-server
==> It works !

and after that put things back :

# mv /usr/lib64/perl5/5.12.4/ExtUtils/xsubpp.bad /usr/lib64/perl5/5.12.4/ExtUtils/xsubpp

This bug is not PostgreSQL ebuild problem and should be solved by perl-core/ExtUtils-ParseXS or dev-lang/perl mainteners...
Comment 4 Kent Fredric (IRC: kent\n) (RETIRED) gentoo-dev 2011-08-18 17:53:00 UTC
(In reply to comment #3)
> Hi,
> For now, the only way I found to solve this :
> # mv /usr/lib64/perl5/5.12.4/ExtUtils/xsubpp
> /usr/lib64/perl5/5.12.4/ExtUtils/xsubpp.bad
> # ln -s /usr/lib64/perl5/vendor_perl/5.12.4/ExtUtils/xsubpp
> /usr/lib64/perl5/5.12.4/ExtUtils/xsubpp
> # emerge dev-db/postgresql-server
> ...
> ==> It works !
> and after that put things back :
> # mv /usr/lib64/perl5/5.12.4/ExtUtils/xsubpp.bad
> /usr/lib64/perl5/5.12.4/ExtUtils/xsubpp
> This bug is not PostgreSQL ebuild problem and should be solved by
> perl-core/ExtUtils-ParseXS or dev-lang/perl mainteners...

Well, its somewhat a bit of both. Its an error in the first place that the postgresql build calls the wrong xsubpp , see bug #378107 , where this problem occurs due to misuse of variables. Ideally, there should not be a "wrong" xsubpp anywhere, but if "/usr/lib64/perl5/5.12.4/ExtUtils/xsubpp" simply didn't exist many things ( possibly this one included ) would simply not work at all, because it would still try to explicitly call the wrong ( and now non-existant) path.
Comment 5 Aaron W. Swenson gentoo-dev 2011-08-24 00:09:09 UTC
Created attachment 284419 [details, diff]
ExtUtils::ParseXS patch for configure path discovery

Give the attached patch a go. It should be the proper means of discovering the path to xsubpp.
Comment 6 Juergen Rose 2011-08-26 10:41:42 UTC
'emerge PDL' fails for me with similar error, even with ExtUtils-ParseXS-3.40.0:

Extracting Core.xs (WITH bad value support)
/usr/bin/perl5.12.4 /usr/lib64/perl5/vendor_perl/5.12.4/ExtUtils/xsubpp  -typemap /usr/lib64/perl5/5.12.4/ExtUtils/typemap -typemap typemap Core.xs > Core.xsc && mv Core.xsc Core.c
Could not find a typemap for C type 'PDL_Long *' in Core.xs, line 1142
make[2]: *** [Core.o] Error 1
Comment 7 Aaron W. Swenson gentoo-dev 2011-08-28 19:32:05 UTC
*** Bug 380971 has been marked as a duplicate of this bug. ***
Comment 8 Torsten Veller (RETIRED) gentoo-dev 2011-09-23 03:45:53 UTC
*** Bug 384141 has been marked as a duplicate of this bug. ***
Comment 9 Aaron W. Swenson gentoo-dev 2011-10-17 01:01:27 UTC
Created attachment 290015 [details, diff]
Implements proper path detection

This patch from upstream, written by David E. Wheeler, should do the trick for a proper path detection.
Comment 10 Aaron W. Swenson gentoo-dev 2011-12-08 03:16:30 UTC
  08 Dec 2011; Aaron W. Swenson <>
  +postgresql-server-8.2.23.ebuild, +postgresql-server-8.3.17.ebuild,
  +postgresql-server-8.4.10.ebuild, +postgresql-server-9.0.6.ebuild,
  Version bump. Fixes bugs 391851, 383471, and 378865.