Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 293792 - dev-lang/swi-prolog-5.9.1 fails to build, build system screws up CFLAGS
Summary: dev-lang/swi-prolog-5.9.1 fails to build, build system screws up CFLAGS
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: Gentoo Prolog project
URL:
Whiteboard:
Keywords:
: 293794 (view as bug list)
Depends on:
Blocks:
 
Reported: 2009-11-20 04:06 UTC by Maciej Piechotka
Modified: 2010-02-13 08:27 UTC (History)
1 user (show)

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


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Maciej Piechotka 2009-11-20 04:06:02 UTC
dev-lang/swi-prolog-5.9.1 fails to build:
 * Building SWI-Prolog additional packages
 * econf: updating pl-5.9.1/src/config.guess with /usr/share/gnuconfig/config.guess
 * econf: updating pl-5.9.1/src/config.sub with /usr/share/gnuconfig/config.sub
 * econf: updating pl-5.9.1/packages/jpl/config.guess with /usr/share/gnuconfig/config.guess
 * econf: updating pl-5.9.1/packages/jpl/config.sub with /usr/share/gnuconfig/config.sub
 * econf: updating pl-5.9.1/packages/xpce/src/config.guess with /usr/share/gnuconfig/config.guess
 * econf: updating pl-5.9.1/packages/xpce/src/config.sub with /usr/share/gnuconfig/config.sub
 * econf: updating pl-5.9.1/packages/xpce/config.guess with /usr/share/gnuconfig/config.guess
 * econf: updating pl-5.9.1/packages/xpce/config.sub with /usr/share/gnuconfig/config.sub
./configure --prefix=/usr --build=x86_64-pc-linux-gnu --host=x86_64-pc-linux-gnu --mandir=/usr/share/man --infodir=/usr/share/info --datadir=/usr/share --sysconfdir=/etc --localstatedir=/var/lib --libdir=/usr/lib64 --without-C-sicstus --with-chr --with-clib --with-clpqr --with-cpp --with-cppproxy --with-db --with-http --without-jasmine --with-jpl --with-nlp --without-odbc --with-pldoc --with-plunit --with-semweb --with-sgml --with-sgml/RDF --with-ssl --with-table --with-xpce --with-zlib COFLAGS="${CFLAGS}"
Added package chr
Added package clib
Added package clpqr
Added package cpp
Added package cppproxy
Added package db
Added package http
Added package jpl
Added package nlp
Dropped package odbc
Added package pldoc
Added package plunit
Added package semweb
Added package sgml
Added package sgml/RDF
Added package ssl
Added package table
Added package xpce
Added package zlib
Checking environment for package jpl ...ok
**********************
* Configuring packages tipc chr clib clpqr cpp cppproxy db http jpl nlp pldoc plunit semweb sgml sgml/RDF ssl table xpce zlib
**********************
**********************
* Package chr
**********************
configure: WARNING: unrecognized options: --enable-mt, --without-C-sicstus, --without-jasmine
checking for gmake... gmake
checking for a BSD-compatible install... /usr/bin/install -c
configure: creating ./config.status
config.status: creating Makefile
config.status: creating config.h
configure: WARNING: unrecognized options: --enable-mt, --without-C-sicstus, --without-jasmine
**********************
* Package clib
**********************
configure: WARNING: unrecognized options: --without-C-sicstus, --without-jasmine
checking for gmake... gmake
checking for etags... etags
checking for a BSD-compatible install... /usr/bin/install -c
checking for x86_64-pc-linux-gnu-gcc... ../plld.sh
checking for C compiler default output file name... 
configure: error: in `/var/tmp/portage/dev-lang/swi-prolog-5.9.1/work/pl-5.9.1/packages/clib':
configure: error: C compiler cannot create executables
See `config.log' for more details.
gmake: *** [configure] Error 1


# cat /var/tmp/portage/dev-lang/swi-prolog-5.9.1/work/pl-5.9.1/packages/clib/config.log 
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.

It was created by configure, which was
generated by GNU Autoconf 2.63.  Invocation command line was

  $ ./configure --enable-mt --prefix=/usr --build=x86_64-pc-linux-gnu --host=x86_64-pc-linux-gnu --mandir=/usr/share/man --infodir=/usr/share/info --datadir=/usr/share --sysconfdir=/etc --localstatedir=/var/lib --libdir=/usr/lib64 --without-C-sicstus --without-jasmine COFLAGS=-O2 -pipe -march=core2 -mfpmath=sse -mmmx -msse -msse2 -msse3 -msse4.1 -fgcse-sm -fgcse-las -fgcse-after-reload -ftracer -msahf -mcx16 -ftree-loop-linear -floop-interchange -floop-strip-mine -floop-block -ftree-loop-distribution -ftree-vectorize -fno-strict-aliasing --prefix=/usr

## --------- ##
## Platform. ##
## --------- ##

hostname = picard
uname -m = x86_64
uname -r = 2.6.31-gentoo-r6
uname -s = Linux
uname -v = #5 SMP PREEMPT Fri Nov 20 02:18:06 GMT 2009

/usr/bin/uname -p = Intel(R) Core(TM)2 Duo CPU T9600 @ 2.80GHz
/bin/uname -X     = unknown

/bin/arch              = unknown
/usr/bin/arch -k       = unknown
/usr/convex/getsysinfo = unknown
/usr/bin/hostinfo      = unknown
/bin/machine           = unknown
/usr/bin/oslevel       = unknown
/bin/universe          = unknown

PATH: /usr/bin
PATH: /usr/lib64/portage/bin/ebuild-helpers
PATH: /usr/local/sbin
PATH: /usr/local/bin
PATH: /usr/sbin
PATH: /usr/bin
PATH: /sbin
PATH: /bin
PATH: /opt/bin
PATH: /usr/x86_64-pc-linux-gnu/gcc-bin/4.4.2
PATH: /usr/qt/3/bin
PATH: /usr/lib64/subversion/bin


## ----------- ##
## Core tests. ##
## ----------- ##

configure:1972: checking for gmake
configure:1999: result: gmake
configure:2015: checking for etags
configure:2031: found /usr/bin/etags
configure:2042: result: etags
configure:2099: checking for a BSD-compatible install
configure:2167: result: /usr/bin/install -c
configure:2186: checking for x86_64-pc-linux-gnu-gcc
configure:2213: result: ../plld.sh
configure:2485: checking for C compiler version
configure:2493: ../plld.sh --version >&5
Unparsed Prolog option: ftree-vectorize -fno-strict-aliasing";

x86_64-pc-linux-gnu-gcc (Gentoo 4.4.2 p1.0) 4.4.2
Copyright (C) 2009 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

configure:2497: $? = 0
configure:2504: ../plld.sh -v >&5
Using built-in specs.
Target: x86_64-pc-linux-gnu
Configured with: /var/tmp/portage/sys-devel/gcc-4.4.2/work/gcc-4.4.2/configure --prefix=/usr --bindir=/usr/x86_64-pc-linux-gnu/gcc-bin/4.4.2 --includedir=/usr/lib/gcc/x86_64-pc-linux-gnu/4.4.2/include --datadir=/usr/share/gcc-data/x86_64-pc-linux-gnu/4.4.2 --mandir=/usr/share/gcc-data/x86_64-pc-linux-gnu/4.4.2/man --infodir=/usr/share/gcc-data/x86_64-pc-linux-gnu/4.4.2/info --with-gxx-include-dir=/usr/lib/gcc/x86_64-pc-linux-gnu/4.4.2/include/g++-v4 --host=x86_64-pc-linux-gnu --build=x86_64-pc-linux-gnu --disable-altivec --disable-fixed-point --with-ppl --with-cloog --enable-nls --without-included-gettext --with-system-zlib --disable-checking --disable-werror --enable-secureplt --enable-multilib --enable-libmudflap --disable-libssp --enable-libgomp --enable-cld --with-python-dir=/share/gcc-data/x86_64-pc-linux-gnu/4.4.2/python --disable-libgcj --enable-objc-gc --enable-languages=c,c++,objc,obj-c++,fortran --enable-shared --enable-threads=posix --enable-__cxa_atexit --enable-clocale=gnu --with-bugurl=http://bugs.gentoo.org/ --with-pkgversion='Gentoo 4.4.2 p1.0'
Thread model: posix
gcc version 4.4.2 (Gentoo 4.4.2 p1.0) 
configure:2508: $? = 0
configure:2515: ../plld.sh -V >&5
Unparsed Prolog option: ftree-vectorize -fno-strict-aliasing";

/usr/lib/gcc/x86_64-pc-linux-gnu/4.4.2/../../../../lib64/crt1.o: In function `_start':
(.text+0x20): undefined reference to `main'
collect2: ld returned 1 exit status
x86_64-pc-linux-gnu-gcc returned code 256
*** /var/tmp/portage/dev-lang/swi-prolog-5.9.1/work/pl-5.9.1/src/../src/plld exit status 1
configure:2519: $? = 1
configure:2542: checking for C compiler default output file name
configure:2564: ../plld.sh -O2 -pipe -march=core2 -mfpmath=sse -mmmx -msse -msse2 -msse3 -msse4.1 -fgcse-sm -fgcse-las -fgcse-after-reload -ftracer -msahf -mcx16 -ftree-loop-linear -floop-interchange -floop-strip-mine -floop-block -ftree-loop-distribution -ftree-vectorize -fno-strict-aliasing  -Wl,-O1 -Wl,--as-needed -Wl,--hash-style=both -Wl,--sort-common conftest.c  >&5
Unparsed Prolog option: ftree-vectorize -fno-strict-aliasing";

x86_64-pc-linux-gnu-gcc: cannot specify -o with -c or -S with multiple files
x86_64-pc-linux-gnu-gcc returned code 256
*** /var/tmp/portage/dev-lang/swi-prolog-5.9.1/work/pl-5.9.1/src/../src/plld exit status 1
configure:2568: $? = 1
configure:2606: result: 
configure: failed program was:
| /* confdefs.h.  */
| #define PACKAGE_NAME ""
| #define PACKAGE_TARNAME ""
| #define PACKAGE_VERSION ""
| #define PACKAGE_STRING ""
| #define PACKAGE_BUGREPORT ""
| #define _REENTRANT 1
| /* end confdefs.h.  */
| 
| int
| main ()
| {
| 
|   ;
|   return 0;
| }
configure:2612: error: in `/var/tmp/portage/dev-lang/swi-prolog-5.9.1/work/pl-5.9.1/packages/clib':
configure:2615: error: C compiler cannot create executables
See `config.log' for more details.



Reproducible: Always




Portage 2.1.7.5 (default/linux/amd64/10.0/desktop, gcc-4.4.2, glibc-2.11-r0, 2.6.31-gentoo-r6 x86_64)
=================================================================
                        System Settings
=================================================================
System uname: Linux-2.6.31-gentoo-r6-x86_64-Intel-R-_Core-TM-2_Duo_CPU_T9600_@_2.80GHz-with-gentoo-2.0.1
Timestamp of tree: Thu, 19 Nov 2009 23:45:01 +0000
app-shells/bash:     4.0_p35
dev-java/java-config: 2.1.9-r1
dev-lang/python:     2.6.4, 3.1.1-r1
dev-util/cmake:      2.8.0
sys-apps/baselayout: 2.0.1
sys-apps/openrc:     0.5.2-r2
sys-apps/sandbox:    2.2
sys-devel/autoconf:  2.13, 2.63-r1
sys-devel/automake:  1.9.6-r2, 1.10.2, 1.11
sys-devel/binutils:  2.20
sys-devel/gcc-config: 1.4.1
sys-devel/libtool:   2.2.6b
virtual/os-headers:  2.6.30-r1
ACCEPT_KEYWORDS="amd64 ~amd64"
ACCEPT_LICENSE="* -@EULA"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-O2 -pipe -march=core2 -mfpmath=sse -mmmx -msse -msse2 -msse3 -msse4.1 -fgcse-sm -fgcse-las -fgcse-after-reload -ftracer -msahf -mcx16 -ftree-loop-linear -floop-interchange -floop-strip-mine -floop-block -ftree-loop-distribution -ftree-vectorize"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/share/X11/xkb /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/sandbox.d /etc/terminfo /etc/texmf/language.dat.d /etc/texmf/language.def.d /etc/texmf/updmap.d /etc/texmf/web2c /etc/udev/rules.d"
CXXFLAGS="-O2 -pipe -march=core2 -mfpmath=sse -mmmx -msse -msse2 -msse3 -msse4.1 -fgcse-sm -fgcse-las -fgcse-after-reload -ftracer -msahf -mcx16 -ftree-loop-linear -floop-interchange -floop-strip-mine -floop-block -ftree-loop-distribution -ftree-vectorize"
DISTDIR="/var/tmp/distfiles"
FEATURES="assume-digests collision-protect distlocks fixpackages news parallel-fetch protect-owned sandbox sfperms splitdebug strict unmerge-logs unmerge-orphans userfetch userpriv usersandbox"
GENTOO_MIRRORS="ftp://212.219.56.132/sites/www.ibiblio.org/gentoo/ http://212.219.56.131/sites/www.ibiblio.org/gentoo/ ftp://212.219.56.133/sites/www.ibiblio.org/gentoo/"
LDFLAGS="-Wl,-O1 -Wl,--as-needed -Wl,--hash-style=both -Wl,--sort-common"
LINGUAS="en en_GB pl"
MAKEOPTS="-j3"
PKGDIR="/usr/portage/packages"
PORTAGE_CONFIGROOT="/"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --stats --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/portage/local/layman/java-overlay /usr/portage/local/layman/haskell /usr/portage/local/layman/gnome /usr/local/portage"
SYNC="rsync://rsync.europe.gentoo.org/gentoo-portage"
USE="X a52 aac acl acpi alsa amd64 applet autoipd avahi banshee bash-completion berkdb bluetooth bonjour boo branding bzip2 cairo caps cdr cli connection-sharing consolekit cracklib crypt cups dbus debugger deskbar devhelp device-mapper dirac disk-partition djvu dmraid dri dts dvd dvdr dvi eds emacs emboss encode evo exif expat extras fam fat ffmpeg firefox flac fontconfig fortran fuse galago gconf gdbm gif git glade glitz gmp gnome gnome-keyring gnutls gpg gphoto2 gpm graphite gsm gstreamer gtk gtksourceview guile hal iconv ieee1394 introspection ipv6 irc jabber java java6 javascript jpeg kdrive kerberos kpathsea kvm laptop latex ldap libffi libnotify libproxy libsigseg libsoup libwnck lua lzma lzo mad mikmod mmx modules mono moonlight mp3 mp4 mpeg mudflap multilib nautilus ncurses networkmanager nls nntp nptl nptlonly nsplugin ntfs objc objc++ objc-gc ogg opengl openmp pam pango pch pcre pdf perl png podcast policykit poppler ppds pppd prolog pulseaudio python qt3 qt3support qt4 quicktime readline reflection reiserfs ruby schroedinger sdl session sip sourceview spell spl sqlite sse sse2 ssl startup-notification subversion svg symlink sysfs tcpd theora thunar tiff truetype udev unicode usb v4l v4l2 videos vim-syntax vorbis vte wav webkit win64 wxwidgets wxwindows x264 xattr xcb xcomposite xml xorg xpm xrender xulrunner xv xvid zlib zsh-completion" ALSA_CARDS="ali5451 als4000 atiixp atiixp-modem bt87x ca0106 cmipci emu10k1x ens1370 ens1371 es1938 es1968 fm801 hda-intel intel8x0 intel8x0m maestro3 trident usb-audio via82xx via82xx-modem ymfpci" 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 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" ELIBC="glibc" INPUT_DEVICES="keyboard mouse evdev" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LINGUAS="en en_GB pl" USERLAND="GNU" VIDEO_CARDS="intel" 
Unset:  CPPFLAGS, CTARGET, EMERGE_DEFAULT_OPTS, FFLAGS, INSTALL_MASK, LANG, LC_ALL, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS
Comment 1 Patrick Lauer gentoo-dev 2009-11-20 09:18:42 UTC
CXXFLAGS="-O2 -pipe -march=core2 -mfpmath=sse -mmmx -msse -msse2 -msse3
-msse4.1 -fgcse-sm -fgcse-las -fgcse-after-reload -ftracer -msahf -mcx16
-ftree-loop-linear -floop-interchange -floop-strip-mine -floop-block
-ftree-loop-distribution -ftree-vectorize"


why ?!?
Comment 2 Patrick Lauer gentoo-dev 2009-11-20 09:19:16 UTC
*** Bug 293794 has been marked as a duplicate of this bug. ***
Comment 3 Maciej Piechotka 2009-11-20 22:59:37 UTC
The flag causing the problem is -ftree-vectorize. However I still don't understend why bug is triggered at configuration stage.

Comment 4 Patrick Lauer gentoo-dev 2009-11-21 18:33:14 UTC
Feel free to reopen if you've worked yourself down to sane CFLAGS :)
Comment 5 Patrick Lauer gentoo-dev 2009-11-21 18:44:51 UTC
Might be related to #270120
Comment 6 Sebastian Luther (few) 2009-11-21 19:23:07 UTC
configure:2564: ../plld.sh -O2 -pipe -march=core2 -mfpmath=sse -mmmx -msse
-msse2 -msse3 -msse4.1 -fgcse-sm -fgcse-las -fgcse-after-reload -ftracer -msahf
-mcx16 -ftree-loop-linear -floop-interchange -floop-strip-mine -floop-block
-ftree-loop-distribution -ftree-vectorize -fno-strict-aliasing  -Wl,-O1
-Wl,--as-needed -Wl,--hash-style=both -Wl,--sort-common conftest.c  >&5
Unparsed Prolog option: ftree-vectorize -fno-strict-aliasing";

Looks like the build system tries to be clever about user's CFLAGS. Instead of calling gcc directly it calls it through a wrapper script and this script messes up the CFLAGS.
Comment 7 Keri Harris gentoo-dev 2010-02-13 08:27:27 UTC
This is now fixed in CVS. Thanks for reporting.