Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 257516

Summary: media-sound/gigedit-0.1.1 does not compile with gcc 4.3. Error related to mainwindow.cpp.
Product: Gentoo Linux Reporter: seg.laco
Component: Current packagesAssignee: Gentoo Sound Team <sound>
Status: RESOLVED FIXED    
Severity: normal CC: col
Priority: High    
Version: unspecified   
Hardware: x86   
OS: Linux   
Whiteboard:
Package list:
Runtime testing required: ---
Bug Depends on:    
Bug Blocks: 198121    
Attachments: the build-log
The build.log to see the crash trying to emerge with the patch.
The ebuild with the 2 patches. (Doesn't work yet)
Patch for mainwindow.cpp
Patch for paramedit.cpp
gigedit-0.1.1-r1.ebuild with 2 patchs and inherit from eutils eclass
This ebuild worked for me.
This patch worked.
This patch worked.

Description seg.laco 2009-02-03 18:36:50 UTC
The emerge of media-sound/gigedit-0.1.1 crashes. There seems to be a bug in mainwindow.cpp:605.

Reproducible: Always

Steps to Reproduce:
1.emerge gigedit
2.
3.

Actual Results:  
emerge stops with an errormessage.

Expected Results:  
emerge should finish comiling.

emerge --info
Portage 2.1.6.7 (default/linux/x86/2008.0, gcc-4.3.3, glibc-2.9_p20081201-r1, 2.6.27-gentoo-r8 i686)
=================================================================
System uname: Linux-2.6.27-gentoo-r8-i686-AMD_Athlon-tm-_64_Processor_3200+-with-glibc2.0
Timestamp of tree: Tue, 03 Feb 2009 15:15:01 +0000
distcc 3.0 i686-pc-linux-gnu [disabled]
app-shells/bash:     3.2_p39
dev-java/java-config: 1.3.7-r1, 2.1.6-r1
dev-lang/python:     2.5.2-r7
dev-python/pycrypto: 2.0.1-r6
dev-util/cmake:      2.4.8
sys-apps/baselayout: 1.12.11.1
sys-apps/sandbox:    1.2.18.1-r2
sys-devel/autoconf:  2.13, 2.63
sys-devel/automake:  1.4_p6, 1.5, 1.7.9-r1, 1.8.5-r3, 1.9.6-r2, 1.10.2
sys-devel/binutils:  2.18-r3
sys-devel/gcc-config: 1.4.0-r4
sys-devel/libtool:   1.5.26
virtual/os-headers:  2.6.27-r2
ACCEPT_KEYWORDS="x86"
CBUILD="i686-pc-linux-gnu"
CFLAGS="-O2 -march=athlon64 -pipe"
CHOST="i686-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/kde/3.5/env /usr/kde/3.5/share/config /usr/kde/3.5/shutdown /usr/share/config"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/env.d/java/ /etc/fonts/fonts.conf /etc/gconf /etc/revdep-rebuild /etc/terminfo /etc/texmf/web2c /etc/udev/rules.d"
CXXFLAGS="-O2 -march=athlon64 -pipe"
DISTDIR="/usr/portage/distfiles"
FEATURES="distlocks fixpackages parallel-fetch protect-owned sandbox sfperms strict unmerge-orphans userfetch"
GENTOO_MIRRORS="http://ftp-stud.fht-esslingen.de/pub/Mirrors/gentoo/"
LANG="de_DE@euro"
LDFLAGS="-Wl,-O1"
LINGUAS="de"
MAKEOPTS="-j2"
PKGDIR="/usr/portage/packages"
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/overlay /usr/portage/local/layman/desktop-effects"
SYNC="rsync://rsync.europe.gentoo.org/gentoo-portage"
USE="3dnow 3dnowext 7zip X a52 aac acl acpi aiglx alsa altenburgcards audiofile avahi berkdb blas branding bzip2 cairo cli cracklib crypt css cups dbus dga divx dri dvd dvdr dvdread dvi effects emerald encode esd ffmpeg flac fortran ftp gdbm gif glitz gmedia gnome gphoto2 gpm gstreamer gtk hal iconv inkjar ipv6 isdnlog jack java javascript jpeg kdecards ladspa latex mad midi mikmod mmx mmxext mozbranding mp3 mpeg mtp mudflap musepack musicbrainz mysql ncurses nls nptl nptlonly ogg openal opengl openmp pam pcre pdf perl png pppd python qt3 quicktime readline realmedia reflection science sdl session skins spell spl sqlite sse ssl ssse3 stream svg symlink sysfs tagwriting tcpd theora tiff tk truetype unicode usb v4l vcd vorbis vst win32codecs wma wmp wxwindows x86 xcb xforms xorg xprint xv xvid xvmc zlib" ALSA_CARDS="ali5451 als4000 atiixp atiixp-modem bt87x ca0106 cmipci emu10k1 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="de" USERLAND="GNU" VIDEO_CARDS="nvidia vesa"
Unset:  CPPFLAGS, CTARGET, EMERGE_DEFAULT_OPTS, FFLAGS, INSTALL_MASK, LC_ALL, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS
Comment 1 seg.laco 2009-02-03 18:38:20 UTC
Created attachment 180835 [details]
the build-log
Comment 2 Rafał Mużyło 2009-02-03 18:45:04 UTC
Looks like a gcc 4.3 problem.
'#include <cstring>' ?
Comment 3 Romain Perier (RETIRED) gentoo-dev 2009-02-03 18:58:47 UTC
(In reply to comment #2)
> Looks like a gcc 4.3 problem.
> '#include <cstring>' ?
> 

#include <cstring> seems to missing in mainwindow.cpp,
if you want i can write a patch and join it in attachment for test... ?
Comment 4 seg.laco 2009-02-03 19:48:14 UTC
Thank you for the fast answer.

I needed to add #include <cstring> in both mainwindow.cpp and paramedit.cpp.
Then make worked without errors.

Is there an elegant way to fix this, so that I could install the program with emerge? Creating a new tar-archive and copying it into /usr/portage/distfiles doesn't work because of the checksum.
Comment 5 Romain Perier (RETIRED) gentoo-dev 2009-02-03 22:09:30 UTC
(In reply to comment #4)
> Thank you for the fast answer.
> 
> I needed to add #include <cstring> in both mainwindow.cpp and paramedit.cpp.
> Then make worked without errors.
> 
> Is there an elegant way to fix this, so that I could install the program with
> emerge? Creating a new tar-archive and copying it into /usr/portage/distfiles
> doesn't work because of the checksum.
> 

Steps :
1. make a patch as fallowing : diff -u mainwindow_orig.cpp mainwindow.cpp > include_fix.patch
2. copy the original ebuild to an overlay (/usr/local/portage/overlay/media-sound/gigedit)
3. rename the ebuild to gigedit-0.1.1-r1.ebuild
4. edit the ebuild and edit src_unpack() function to added:
 epatch "${FILESDIR}/include_fix.patch" (at end of function)
5. copy the patch to /usr/local/portage/overlay/media-sound/gigedit/files
6. exec the following command: ebuild /usr/local/portage/overlay/media-sound/gigedit/gigedit-0.1.1-r1.ebuild digest

and now normaly you can merge ;)
Comment 6 seg.laco 2009-02-03 23:27:55 UTC
> and now normaly you can merge ;)

Unfortunatelly it doesn't. Emerge dies complaining that there is no configure script found.
What I did additionally was to create a second patch for paramedit.cpp.
What else do I need to edit in the ebuild?
In the Attachement there is the ebuild I wrote so far, the patches and the build.log.

Comment 7 seg.laco 2009-02-03 23:29:22 UTC
Created attachment 180867 [details]
The build.log to see the crash trying to emerge with the patch.
Comment 8 seg.laco 2009-02-03 23:30:22 UTC
Created attachment 180868 [details]
The ebuild with the 2 patches. (Doesn't work yet)
Comment 9 seg.laco 2009-02-03 23:31:01 UTC
Created attachment 180869 [details, diff]
Patch for mainwindow.cpp
Comment 10 seg.laco 2009-02-03 23:31:28 UTC
Created attachment 180871 [details, diff]
Patch for paramedit.cpp
Comment 11 Romain Perier (RETIRED) gentoo-dev 2009-02-04 09:15:46 UTC
the two patchs seems to be good, thanks for them.
in build.log we can read explicitly that epatch command is not found, due to eutils eclass missing.

please find in attachment new ebuild which just inherit from eutils eclass, normaly fixs the "epatch command not found" error, and try again because the configure script is directly in tarball source code and should be found.

Comment 12 Romain Perier (RETIRED) gentoo-dev 2009-02-04 09:16:45 UTC
Created attachment 180887 [details]
gigedit-0.1.1-r1.ebuild with 2 patchs and inherit from eutils eclass
Comment 13 seg.laco 2009-02-05 18:53:02 UTC
Unfortunatelly your ebuild doesn't work for me. Emerge stops trying to patch and complains that it doesn't find the files to be patched. After I had a look in the temp-folder I realized that the src_unpack was not complete. Because I don't know what to add aditionally in the src_unpack I deleted it completely and put the epatch commands in the beginning of src_compile.
Than there was another thing to do. The patches were not correct, because the mainwindow.cpp and paramedit.cpp are not in the work-directory but in a subfolder. So I needed to add a relative path.

Thanks for your help. I will upload the correct patches and the ebuild.
Comment 14 seg.laco 2009-02-05 18:55:01 UTC
Created attachment 181067 [details]
This ebuild worked for me.
Comment 15 seg.laco 2009-02-05 18:55:40 UTC
Created attachment 181069 [details, diff]
This patch worked.
Comment 16 seg.laco 2009-02-05 18:55:56 UTC
Created attachment 181070 [details, diff]
This patch worked.
Comment 17 Romain Perier (RETIRED) gentoo-dev 2009-02-06 12:16:46 UTC
(In reply to comment #13)
> Unfortunatelly your ebuild doesn't work for me. Emerge stops trying to patch
> and complains that it doesn't find the files to be patched. After I had a look
> in the temp-folder I realized that the src_unpack was not complete. Because I
> don't know what to add aditionally in the src_unpack I deleted it completely
> and put the epatch commands in the beginning of src_compile.
> Than there was another thing to do. The patches were not correct, because the
> mainwindow.cpp and paramedit.cpp are not in the work-directory but in a
> subfolder. So I needed to add a relative path.
> 
> Thanks for your help. I will upload the correct patches and the ebuild.
> 

your merge problem was not because the ebuild didn't work but because theses patchs didn't include the absolute path from tarball directory, patch are fixed so emerge too (the main thing being that the source are patched before compile)
Comment 18 Alexis Ballier gentoo-dev 2009-02-08 10:05:28 UTC
fixed, thanks; please don't forget to forward your patches to the upstream author.
Comment 19 michael higgins 2009-11-09 17:16:59 UTC
(In reply to comment #18)
> fixed, thanks; please don't forget to forward your patches to the upstream
> author.
> 

Hey, like, this bug report is the only source for a working ebuild... BUT ITS CLOSED! What gives? It's marked as "resolved fixed". WHY? IT ISN'T RESOLVED OR FIXED!

Please re-open this bug and keep it open until a working ebuild is in the tree or pro-audio overlay. Thanks!