Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 617434 - dev-vcs/subversion-1.9.5 fails to build with sys-devel/gcc-5.4.0 and sys-devel/autoconf-2.69-r3 during the configure phase
Summary: dev-vcs/subversion-1.9.5 fails to build with sys-devel/gcc-5.4.0 and sys-deve...
Status: RESOLVED OBSOLETE
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Lars Wendler (Polynomial-C) (RETIRED)
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2017-05-03 23:46 UTC by Melker Narikka
Modified: 2019-04-20 22:41 UTC (History)
1 user (show)

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


Attachments
build.log for dev-vcs/subversion-1.9.5 (build.log,12.46 KB, text/x-log)
2017-05-04 12:29 UTC, Melker Narikka
Details
config.log for dev-vcs/subversion-1.9.5 (config.log,66.09 KB, text/x-log)
2017-05-04 12:29 UTC, Melker Narikka
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Melker Narikka 2017-05-03 23:46:39 UTC
The problem seems to stem from the fact that the use of the AC_EGREP_CPP macro in conjunction with a fairly new version of GCC, 5.4.0 in my case. The newer versions of GCC's C preprocessor add things such as newlines and other characters in uncomfortable places in their output, which will render any grepping on it quite futile. As a workaround, slapping the -P switch into CPPFLAGS makes it build just fine.

There's a thread on the autoconf mailing list discussing this new GCC output without a whole lot of activity:
https://www.mail-archive.com/bug-autoconf@gnu.org/msg04157.html

Reproducible: Always

Steps to Reproduce:
1. # gcc-config x86_64-pc-linux-gnu-5.4.0
2. # emerge subversion
3. You're there!
Actual Results:  
Build fails.

Expected Results:  
Build succeeds.

The offending file in SVN's build system is 'subversion-1.9.5/build/ac-macros/swig.m4'.

Here's an example of the difference in cpp's output with and without -P:

% echo '#include <apr-1/apr.h>'$'\n''HELLO APR_INT64_T_FMT WORLD' | cpp
typedef apr_uint64_t apr_uintptr_t;
/* <snip> */
# 2 "<stdin>"
HELLO
# 2 "<stdin>" 3 4
     "ld"
# 2 "<stdin>"
                     WORLD
% echo '#include <apr-1/apr.h>'$'\n''HELLO APR_INT64_T_FMT WORLD' | cpp -P
/* <snip> */
typedef ino_t apr_ino_t;
typedef apr_uint64_t apr_uintptr_t;
HELLO "ld" WORLD
Comment 1 Mike Gilbert gentoo-dev 2017-05-04 00:58:45 UTC
Please provide emerge --info and attach a full build log.
Comment 2 Melker Narikka 2017-05-04 12:27:29 UTC
% emerge --info
Portage 2.2.27-multilib (python 2.7.13-final-0, default/linux/amd64/13.0/desktop/plasma/systemd, gcc-5.4.0, glibc-2.24-r1, 4.8.0-pf8 x86_64)
=================================================================
System uname: Linux-4.8.0-pf8-x86_64-AMD_FX-tm-8320_Eight-Core_Processor-with-gentoo-2.3
KiB Mem:    12203832 total,    738876 free
KiB Swap:   52436060 total,  51623892 free
Timestamp of repository gentoo: Wed, 03 May 2017 11:45:01 +0000
sh bash 4.4_p12
ld GNU ld-versio (Gentoo 2.27 p1.0) 2.27
ccache version 3.3.4 [disabled]
app-shells/bash:          4.4_p12::gentoo
dev-java/java-config:     2.2.0-r3::gentoo
dev-lang/perl:            5.24.1-r1::gentoo
dev-lang/python:          2.7.13::gentoo, 3.4.6::gentoo
dev-util/ccache:          3.3.4::gentoo
dev-util/cmake:           3.8.1::gentoo
dev-util/pkgconfig:       0.29.2::gentoo
sys-apps/baselayout:      2.3::gentoo
sys-apps/openrc:          0.25::gentoo
sys-apps/sandbox:         2.10-r4::gentoo
sys-devel/autoconf:       2.13::gentoo, 2.69-r3::gentoo
sys-devel/automake:       1.11.6-r2::gentoo, 1.12.6::gentoo, 1.13.4-r1::gentoo, 1.14.1-r1::gentoo, 1.15-r2::gentoo
sys-devel/binutils:       2.25.1-r1::gentoo, 2.26.1::gentoo, 2.27::gentoo
sys-devel/gcc:            4.6.4::gentoo, 4.7.3-r1::gentoo, 4.8.3::gentoo, 4.9.3::gentoo, 4.9.4::gentoo, 5.3.0::gentoo, 5.4.0::gentoo, 6.3.0::gentoo
sys-devel/gcc-config:     1.8-r1::gentoo
sys-devel/libtool:        2.4.6-r4::gentoo
sys-devel/make:           4.2.1-r1::gentoo
sys-kernel/linux-headers: 4.10::gentoo (virtual/os-headers)
sys-libs/glibc:           2.24-r1::gentoo
Repositories:

gentoo
    location: /usr/portage
    sync-type: rsync
    sync-uri: rsync://rsync.de.gentoo.org/gentoo-portage/
    priority: -1000

local
    location: /home/meklu/portage/local
    masters: gentoo
    priority: 0

dstien
    location: /home/meklu/portage/dstien
    masters: gentoo
    priority: 1

nikos-gentoo-overlay
    location: /home/meklu/portage/nikob
    masters: gentoo
    priority: 2

bitcoin
    location: /var/lib/layman/bitcoin
    masters: gentoo
    priority: 50

gamerlay
    location: /var/lib/layman/gamerlay
    masters: gentoo
    priority: 50

kde
    location: /var/lib/layman/kde
    masters: gentoo
    priority: 50

mekoverlay
    location: /var/lib/layman/mekoverlay
    masters: gentoo
    priority: 50

multilib-portage
    location: /var/lib/layman/multilib-portage
    masters: gentoo
    priority: 50

multimedia
    location: /var/lib/layman/multimedia
    masters: gentoo
    priority: 50

proaudio
    location: /var/lib/layman/proaudio
    masters: gentoo
    priority: 50

qt
    location: /var/lib/layman/qt
    masters: gentoo
    priority: 50

sunrise
    location: /var/lib/layman/sunrise
    masters: gentoo
    priority: 50

systemd
    location: /var/lib/layman/systemd
    masters: gentoo
    priority: 50

systemd-love
    location: /var/lib/layman/systemd-love
    masters: gentoo
    priority: 50

tox-overlay
    location: /var/lib/layman/tox-overlay
    masters: gentoo
    priority: 50

x11
    location: /var/lib/layman/x11
    masters: gentoo
    priority: 50

ACCEPT_KEYWORDS="amd64 ~amd64"
ACCEPT_LICENSE="*"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-O2"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/share/config /usr/share/gnupg/qualified.txt /usr/share/themes/oxygen-gtk/gtk-2.0 /var/lib/hsqldb"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/dconf /etc/env.d /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/php/apache2-php5.6/ext-active/ /etc/php/apache2-php7.0/ext-active/ /etc/php/apache2-php7.1/ext-active/ /etc/php/cgi-php5.6/ext-active/ /etc/php/cgi-php7.0/ext-active/ /etc/php/cgi-php7.1/ext-active/ /etc/php/cli-php5.6/ext-active/ /etc/php/cli-php7.0/ext-active/ /etc/php/cli-php7.1/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"
DISTDIR="/usr/portage/distfiles"
FCFLAGS="-O2 -pipe"
FEATURES="assume-digests binpkg-logs config-protect-if-modified distlocks ebuild-locks fixlafiles force-multilib merge-sync news parallel-fetch preserve-libs protect-owned sandbox sfperms splitdebug strict unknown-features-warn unmerge-logs unmerge-orphans userfetch usersync xattr"
FFLAGS="-O2 -pipe"
GENTOO_MIRRORS="rsync://trumpetti.atm.tut.fi/gentoo/"
LANG="fi_FI.UTF-8"
LC_ALL="fi_FI.UTF-8"
LDFLAGS="-Wl,-O1 -Wl,--as-needed"
MAKEOPTS="-j6"
PKGDIR="/usr/portage/packages"
PORTAGE_CONFIGROOT="/"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --omit-dir-times --compress --force --whole-file --delete --stats --human-readable --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages --exclude=/.git"
PORTAGE_TMPDIR="/var/tmp"
USE="32bit 3dnowprefetch X a52 aac aalib abm acl acpi aes alsa amd64 amr aperfmperf apic arat avx bash-completion berkdb bluetooth bluray bmi1 branding bzip2 cairo cdda cdr clflush cli cmov cmp_legacy constant_tsc cpb cr8_legacy cracklib crypt css cups curl cx16 cx8 cxx dbus de declarative decodeassists desktopglobe dirac dri dts dvd dvdr embedded emboss enca encode exif extapic extd_apicid extras f16c faac fam ffmpeg firefox flac flushbyasid fma fma4 fontconfig fortran fpu fxsr fxsr_opt gdbm gif glamor gnutls gpm gsm ht hw_pstate ibs iconv icu imagemagick imlib ipv6 jpeg jpeg2k kde kipi kwallet lahf_lm lame lbrv lcms ldap libnotify lm lwp mad mca mce misalignsse mmx mmxext mng modules monitor mp3 mp4 mpeg msr mtrr musepack musicbrainz mysql ncurses network nls nodeid_msr nonstop_tsc nopl npt nptl nrip_save nsplugin nx offensive ogg openal opengl openmp opus osvw pae pam pango pat pausefilter pch pclmulqdq pcre pdf pdpe1gb perfctr_core perfctr_nb pfthreshold pge phonon pic plasma png pni policykit popcnt ppds private-headers pse pse36 pulseaudio qml qt3support qt4 qt5 quicktime radio rdtscp readline rep_good rss schroedinger script sdl seccomp sep session skinit sound sox speex spell sql sqlite sse sse2 sse4 sse4_1 sse4_2 sse4a ssl ssse3 startup-notification svg svm svm_lock syscall systemd taglib tbm tce tcpd theora threads tiff topoext truetype tsc tsc_scale udev udisks unicode upower usb utf8 v4l v4l2 vaapi vmcb_clean vme vorbis vpx wdt webkit widgets wifi wxwidgets x264 x265 xattr xcb xcomposite xinerama xml xop xsave xscreensaver xv xvba xvid zlib" 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" APACHE2_MODULES="autoindex alias log_config headers proxy proxy_connect deflate filter env negotiation rewrite remoteip cgid authn_core authz_core authz_host dir mime unixd socache_shmcb" APACHE2_MPMS="worker" CALLIGRA_FEATURES="kexi words flow plan sheets stage tables krita karbon braindump author" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" CPU_FLAGS_X86="mmx mmxext sse sse2 3dnowprefetch abm aes aperfmperf apic arat avx bmi1 clflush cmov cmp_legacy constant_tsc cpb cr8_legacy cx16 cx8 de decodeassists extapic extd_apicid f16c flushbyasid fma fma4 fpu fxsr fxsr_opt ht hw_pstate ibs lahf_lm lbrv lm lwp mca mce misalignsse monitor msr mtrr nodeid_msr nonstop_tsc nopl npt nrip_save nx osvw pae pat pausefilter pclmulqdq pdpe1gb perfctr_core perfctr_nb pfthreshold pge pni popcnt pse pse36 rdtscp rep_good sep skinit sse3 sse4 sse4_1 sse4_2 sse4a ssse3 svm svm_lock syscall tbm tce topoext tsc tsc_scale vmcb_clean vme wdt xop xsave" ELIBC="glibc" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock isync itrax mtk3301 nmea ntrip navcom oceanserver oldstyle oncore rtcm104v2 rtcm104v3 sirf skytraq superstar2 timing tsip tripmate tnt ublox ubx" GRUB_PLATFORMS="pc efi-64" INPUT_DEVICES="evdev roccat_kovaplus" KERNEL="linux" L10N="fi" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LIBREOFFICE_EXTENSIONS="presenter-console presenter-minimizer" LINGUAS="fi" OFFICE_IMPLEMENTATION="libreoffice" PHP_TARGETS="php7-1" PYTHON_SINGLE_TARGET="python3_4" PYTHON_TARGETS="python3_4 python2_7" RUBY_TARGETS="ruby23 ruby24" USERLAND="GNU" VIDEO_CARDS="nvidia 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" multilib_abi="amd64"
Unset:  CC, CPPFLAGS, CTARGET, CXX, EMERGE_DEFAULT_OPTS, INSTALL_MASK, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS, USE_PYTHON
Comment 3 Melker Narikka 2017-05-04 12:29:16 UTC
Created attachment 471604 [details]
build.log for dev-vcs/subversion-1.9.5
Comment 4 Melker Narikka 2017-05-04 12:29:58 UTC
Created attachment 471606 [details]
config.log for dev-vcs/subversion-1.9.5
Comment 5 Melker Narikka 2017-05-04 12:45:12 UTC
This is how the (now failing) check is implemented in build/ac-macros/swig.m4:

build/ac-macros/swig.m4:133:    dnl Sun Forte adds an extra space before substituting APR_INT64_T_FMT
build/ac-macros/swig.m4:134:    dnl gcc-2.95 adds an extra space after substituting APR_INT64_T_FMT
build/ac-macros/swig.m4:135:    dnl thus the egrep patterns have a + in them.
build/ac-macros/swig.m4:136:    SVN_PYCFMT_SAVE_CPPFLAGS="$CPPFLAGS"
build/ac-macros/swig.m4:137:    CPPFLAGS="$CPPFLAGS $SVN_APR_INCLUDES"
build/ac-macros/swig.m4:138:    AC_CACHE_CHECK([for apr_int64_t Python/C API format string],
build/ac-macros/swig.m4:139:                   [svn_cv_pycfmt_apr_int64_t], [
build/ac-macros/swig.m4:140:      if test "x$svn_cv_pycfmt_apr_int64_t" = "x"; then
build/ac-macros/swig.m4:141:        AC_EGREP_CPP([MaTcHtHiS +\"lld\" +EnDeNd],
build/ac-macros/swig.m4:142:                     [#include <apr.h>
build/ac-macros/swig.m4:143:                      MaTcHtHiS APR_INT64_T_FMT EnDeNd],
build/ac-macros/swig.m4:144:                     [svn_cv_pycfmt_apr_int64_t="L"])
build/ac-macros/swig.m4:145:      fi
build/ac-macros/swig.m4:146:      if test "x$svn_cv_pycfmt_apr_int64_t" = "x"; then
build/ac-macros/swig.m4:147:        AC_EGREP_CPP([MaTcHtHiS +\"ld\" +EnDeNd],r
build/ac-macros/swig.m4:148:                     [#include <apr.h>
build/ac-macros/swig.m4:149:                      MaTcHtHiS APR_INT64_T_FMT EnDeNd],
build/ac-macros/swig.m4:150:                     [svn_cv_pycfmt_apr_int64_t="l"])
build/ac-macros/swig.m4:151:      fi
build/ac-macros/swig.m4:152:      if test "x$svn_cv_pycfmt_apr_int64_t" = "x"; then
build/ac-macros/swig.m4:153:        AC_EGREP_CPP([MaTcHtHiS +\"d\" +EnDeNd],
build/ac-macros/swig.m4:154:                     [#include <apr.h>
build/ac-macros/swig.m4:155:                      MaTcHtHiS APR_INT64_T_FMT EnDeNd],
build/ac-macros/swig.m4:156:                     [svn_cv_pycfmt_apr_int64_t="i"])
build/ac-macros/swig.m4:157:      fi
build/ac-macros/swig.m4:158:    ])
build/ac-macros/swig.m4:159:    CPPFLAGS="$SVN_PYCFMT_SAVE_CPPFLAGS"
build/ac-macros/swig.m4:160:    if test "x$svn_cv_pycfmt_apr_int64_t" = "x"; then
build/ac-macros/swig.m4:161:      AC_MSG_ERROR([failed to recognize APR_INT64_T_FMT on this platform])
build/ac-macros/swig.m4:162:    fi
build/ac-macros/swig.m4:163:    AC_DEFINE_UNQUOTED([SVN_APR_INT64_T_PYCFMT],
build/ac-macros/swig.m4:164:                       ["$svn_cv_pycfmt_apr_int64_t"],
build/ac-macros/swig.m4:165:                       [Define to the Python/C API format character suitable]
build/ac-macros/swig.m4:166:                       [ for apr_int64_t])

As the example cpp output in the initial comment demonstrates, something like the -P switch is needed if cpp points to a new GCC.

Interestingly enough, sys-devel/clang-4.0.0-r2 produces output that doesn't break the check, even without -P.