Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 479494 - libelf compatibility issue?: ctfconvert -L VERSION -g aicasm.o , segfault 11.
Summary: libelf compatibility issue?: ctfconvert -L VERSION -g aicasm.o , segfault 11.
Status: RESOLVED FIXED
Alias: None
Product: Gentoo/Alt
Classification: Unclassified
Component: FreeBSD (show other bugs)
Hardware: All FreeBSD
: Normal normal (vote)
Assignee: Gentoo/BSD Team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-08-02 11:00 UTC by Yuta SATOH
Modified: 2013-08-11 20:42 UTC (History)
0 users

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


Attachments
sample patch for freebsd-lib-9.1-r10.ebuild (libdwarf-fix-freebsd-lib.patch,1.18 KB, patch)
2013-08-02 11:05 UTC, Yuta SATOH
Details | Diff
sample patch for freebsd-cddl-9.1.ebuild (libdwarf-fix-freebsd-cddl.patch,438 bytes, patch)
2013-08-02 11:06 UTC, Yuta SATOH
Details | Diff
sample patch for freebsd-usbin-9.1.ebuild (libdwarf-fix-freebsd-usbin.patch,455 bytes, patch)
2013-08-02 11:07 UTC, Yuta SATOH
Details | Diff
sample patch for dev-libs/glib-2.36.3-r1.ebuild (libdwarf-fix-glib.patch,383 bytes, patch)
2013-08-02 11:07 UTC, Yuta SATOH
Details | Diff
freebsd-lib/files/freebsd-lib-9.1-liblink.patch (freebsd-lib-9.1-liblink.patch,1013 bytes, patch)
2013-08-02 11:34 UTC, Yuta SATOH
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Yuta SATOH 2013-08-02 11:00:57 UTC
When using libelf included in freebsd-lib, this issue does not occur.
I think better to use libelf contained in freebsd-lib instead of sys-libs/libelf...
Comment 1 Yuta SATOH 2013-08-02 11:05:53 UTC
Created attachment 354888 [details, diff]
sample patch for freebsd-lib-9.1-r10.ebuild

Don't forget rev bump.
Comment 2 Yuta SATOH 2013-08-02 11:06:37 UTC
Created attachment 354890 [details, diff]
sample patch for freebsd-cddl-9.1.ebuild
Comment 3 Yuta SATOH 2013-08-02 11:07:12 UTC
Created attachment 354892 [details, diff]
sample patch for freebsd-usbin-9.1.ebuild
Comment 4 Yuta SATOH 2013-08-02 11:07:58 UTC
Created attachment 354894 [details, diff]
sample patch for dev-libs/glib-2.36.3-r1.ebuild
Comment 5 Yuta SATOH 2013-08-02 11:34:43 UTC
Created attachment 354896 [details, diff]
freebsd-lib/files/freebsd-lib-9.1-liblink.patch
Comment 6 Yuta SATOH 2013-08-02 12:00:25 UTC
Steps to Reproduce:

prepare)
mkdir /9.1 && cd /9.1
wget http://distfiles.gentoo.org/experimental/bsd/freebsd/stages/amd64-fbsd-9.1/stage3-amd64-freebsd-9.1.tar.bz2
tar xjpf stage3-amd64-freebsd-9.1.tar.bz2
mkdir /9.1/usr/portage /9.1/var/tmp/portage
mount -t devfs devfs /9.1/dev
mount -t nullfs /usr/portage /9.1/usr/portage
cp /etc/resolv.conf /9.1/etc
chroot /9.1 /bin/bash

export MAKEOPTS=-j10
emerge freebsd-cddl
cd /usr/src/sys/amd64/conf
echo 'makeoptions     WITH_CTF=1' >> GENERIC
config GENERIC
cd ../compile/GENERIC
make clean && make cleandepend && make depend && make -j10
<snip>
ctfconvert -L VERSION -g aicasm.o
*** [aicasm.o] Signal 11

Got Signal 11. next step.

workaround)
cd /tmp
for num in 354888 354890 354892 354894 354896
do
wget --no-check-certificate -O ${num}.patch "https://bugs.gentoo.org/attachment.cgi?id=${num}"
sleep 10
done

cd /usr/portage/sys-freebsd/freebsd-lib
patch -p1 < /tmp/354888.patch
cp freebsd-lib-9.1-r10.ebuild freebsd-lib-9.1-r11.ebuild
cp /tmp/354896.patch files/freebsd-lib-9.1-liblink.patch
ebuild freebsd-lib-9.1-r11.ebuild digest

cd /usr/portage/sys-freebsd/freebsd-cddl
patch -p1 < /tmp/354890.patch
ebuild freebsd-cddl-9.1.ebuild digest

cd /usr/portage/sys-freebsd/freebsd-usbin
patch -p1 < /tmp/354892.patch
ebuild freebsd-usbin-9.1.ebuild digest

cd /usr/portage/dev-libs/glib
patch -p1 < /tmp/354894.patch
ebuild glib-2.36.3-r1.ebuild digest

emerge -C libelf
emerge freebsd-lib && emerge freebsd-cddl

retry)
cd /usr/src/sys/amd64/compile/GENERIC
ctfconvert -L VERSION -g aicasm.o

ok. no error. check kernel compile is successful.

make clean && make cleandepend && make depend && make -j10

done.
Comment 7 Alexis Ballier gentoo-dev 2013-08-09 13:05:56 UTC
better fix libelf / ctfconvert then I think
Comment 8 Alexis Ballier gentoo-dev 2013-08-11 20:42:26 UTC
applied your patches in the end, you're right its better that way, thanks!