Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 487456 - dev-util/strace-4.8 fails to build with glibc-2.18
Summary: dev-util/strace-4.8 fails to build with glibc-2.18
Status: RESOLVED DUPLICATE of bug 482752
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: New packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Gentoo's Team for Core System packages
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: glibc-2.18
  Show dependency tree
 
Reported: 2013-10-09 18:15 UTC by Patrick McLean
Modified: 2014-01-05 22:24 UTC (History)
4 users (show)

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


Attachments
strace-4.8-glibc2.18.patch (strace-4.8-glibc2.18.patch,887 bytes, patch)
2013-10-09 18:15 UTC, Patrick McLean
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Patrick McLean gentoo-dev 2013-10-09 18:15:35 UTC
Created attachment 360516 [details, diff]
strace-4.8-glibc2.18.patch

x86_64-pc-linux-gnu-gcc -DHAVE_CONFIG_H -I.  -I./linux/x86_64 -I./linux -I./linux  -Wall -Wwrite-strings -O2 -march=native -pipe -c process.c
In file included from process.c:66:0:
/usr/include/linux/ptrace.h:58:8: error: redefinition of 'struct ptrace_peeksiginfo_args'
 struct ptrace_peeksiginfo_args {
        ^
In file included from defs.h:159:0,
                 from process.c:37:
/usr/include/sys/ptrace.h:191:8: note: originally defined here
 struct ptrace_peeksiginfo_args
        ^


I have attached a patch that fixes this issue, based off the patch for sandbox on bug #482752.
Comment 1 Andrés Becerra Sandoval 2013-12-03 19:51:11 UTC
Patrick,

I have this bug, tested your patch, and it did not work for me:

>>> Emerging (1 of 1) dev-util/strace-4.8
 * strace-4.8.tar.xz SHA256 SHA512 WHIRLPOOL size ;-) ...                                    [ ok ]
>>> Unpacking source...
>>> Unpacking strace-4.8.tar.xz to /var/tmp/portage/dev-util/strace-4.8/work
>>> Source unpacked in /var/tmp/portage/dev-util/strace-4.8/work
>>> Preparing source in /var/tmp/portage/dev-util/strace-4.8/work/strace-4.8 ...
 * Applying user patches from /etc/portage/patches//dev-util/strace-4.8 ...
 *   strace-4.8-glibc2.18.patch ...                                                          [ ok ]
 * Done with patching
/var/tmp/portage/dev-util/strace-4.8/temp/environment: line 2483: eautoreconf: command not found
>>> Source prepared.

But, at the end I get:


x86_64-pc-linux-gnu-gcc -DHAVE_CONFIG_H -I.  -I./linux/x86_64 -I./linux -I./linux  -Wall -Wwrite-strings -march=native -O2 -pipe -ggdb -c pathtrace.c
x86_64-pc-linux-gnu-gcc -DHAVE_CONFIG_H -I.  -I./linux/x86_64 -I./linux -I./linux  -Wall -Wwrite-strings -march=native -O2 -pipe -ggdb -c process.c
In file included from process.c:66:0:
/usr/include/linux/ptrace.h:58:8: error: redefinition of ‘struct ptrace_peeksiginfo_args’
 struct ptrace_peeksiginfo_args {
        ^
In file included from defs.h:159:0,
                 from process.c:37:
/usr/include/sys/ptrace.h:191:8: note: originally defined here
 struct ptrace_peeksiginfo_args
        ^
Makefile:682: recipe for target 'process.o' failed
make[2]: *** [process.o] Error 1
make[2]: *** Waiting for unfinished jobs....
make[2]: Leaving directory '/var/tmp/portage/dev-util/strace-4.8/work/strace-4.8'
Makefile:741: recipe for target 'all-recursive' failed
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory '/var/tmp/portage/dev-util/strace-4.8/work/strace-4.8'
Makefile:511: recipe for target 'all' failed
make: *** [all] Error 2
 * ERROR: dev-util/strace-4.8::gentoo failed (compile phase):
 *   emake failed
Comment 2 Patrick McLean gentoo-dev 2013-12-03 22:09:54 UTC
You need to add inherit autotools to the ebuild
Comment 3 Kenton Groombridge 2013-12-04 12:58:23 UTC
I was also getting this error.

Maybe I am a moron.  I added inherit autotools and I am still getting the same error.

I appended autotools to the existing inherit line in the ebuild:

inherit flag-o-matic eutils autotools

and also tried "inherit autotools" on its own line.
Comment 4 Yixun Lan archtester gentoo-dev 2013-12-06 01:54:17 UTC
trying with user patch, while found eautoreconf not supported, and the fix is quite easy (inherit autotools)

sorry for just reporting here instead of filing another bug, thought it's trivial.


 * Applying user patches from /etc/portage/patches//dev-util/strace-4.8 ...
 *   strace-4.8-glibc2.18.patch ...
 [ ok ]
 * Done with patching
/var/tmp/portage/dev-util/strace-4.8/temp/environment: line 2557: eautoreconf: command not found
configure: loading site script /usr/share/config.site
checking for a BSD-compatible install... /usr/bin/install -c
Comment 5 Kenton Groombridge 2013-12-06 17:38:47 UTC
Unforunately these fixes aren't working for me.  I have "inherit autotools" in my ebuild:

# Copyright 1999-2013 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/dev-util/strace/strace-4.8.ebuild,v 1.3 2013/11/29 14:04:14 vapier Exp $

EAPI="4"

inherit flag-o-matic eutils
inherit autotools
......

The patch is applying:

>>> Emerging (1 of 1) dev-util/strace-4.8 from x-portage
 * strace-4.8.tar.xz SHA256 SHA512 WHIRLPOOL size ;-) ...                                              [ ok ]
>>> Unpacking source...
>>> Unpacking strace-4.8.tar.xz to /var/tmp/portage/dev-util/strace-4.8/work
>>> Source unpacked in /var/tmp/portage/dev-util/strace-4.8/work
>>> Preparing source in /var/tmp/portage/dev-util/strace-4.8/work/strace-4.8 ...
 * Applying strace-4.8-glibc2.18.patch ...                                                             [ ok ]
>>> Source prepared.
.............


But build is still bombing:

pipe -march=native -mtune=native -c process.c
In file included from process.c:66:0:
/usr/include/linux/ptrace.h:58:8: error: redefinition of 'struct ptrace_peeksiginfo_args'
 struct ptrace_peeksiginfo_args {
        ^
In file included from defs.h:159:0,
                 from process.c:37:
/usr/include/sys/ptrace.h:191:8: note: originally defined here
 struct ptrace_peeksiginfo_args
        ^


I am probably doing something stupid, but I would appreciate it if somebody could point me in the right direction.
Comment 6 Kenton Groombridge 2013-12-06 18:29:45 UTC
Got it.

It took more that adding the applying the patch and "inherit autotools".

I had to add:

eautoreconf

Right after the application of the patch.

Hope it helps somebody else.
Comment 7 Yixun Lan archtester gentoo-dev 2013-12-06 23:13:26 UTC
eautoreconf already handled there, and for it to work, you should put the patch into /etc/portage/patches/dev-util/strace-4.8/, that will trigger a eautoreconf, no need to patch the original ebuild.

src_prepare() {
   ..
   if epatch_user || [[ ! -e configure ]] ; then
        # git generation
        eautoreconf
        [[ ! -e CREDITS ]] && cp CREDITS{.in,}
   fi
}

for ebuild, simply move out autotools eclass from live build

diff --git a/strace-4.8.ebuild b/strace-4.8.ebuild
index ba172e8..1934d8f 100644
--- a/strace-4.8.ebuild
+++ b/strace-4.8.ebuild
@@ -4,11 +4,11 @@
 
 EAPI="4"
 
-inherit flag-o-matic eutils
+inherit autotools flag-o-matic eutils
 
 if [[ ${PV} == "9999" ]] ; then
        EGIT_REPO_URI="git://strace.git.sourceforge.net/gitroot/strace/strace"
-       inherit git-2 autotools
+       inherit git-2
 else
        SRC_URI="mirror://sourceforge/${PN}/${P}.tar.xz"
Comment 8 SpanKY gentoo-dev 2014-01-05 22:24:26 UTC

*** This bug has been marked as a duplicate of bug 482752 ***