Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 433870 - x11-wm/compiz-0.8.8[kde] - decorator.cpp:216:27: error: cannot allocate an object of abstract type 'KWD::Window'
Summary: x11-wm/compiz-0.8.8[kde] - decorator.cpp:216:27: error: cannot allocate an ob...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Unspecified (show other bugs)
Hardware: AMD64 Linux
: Normal normal (vote)
Assignee: Desktop-Effects herd
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: 410979
  Show dependency tree
 
Reported: 2012-09-04 05:36 UTC by d_dart
Modified: 2012-09-12 19:35 UTC (History)
0 users

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


Attachments
the patch provided above was named compiz-kde-bgo.patch (compiz-0.8.8.ebuild,3.63 KB, text/plain)
2012-09-08 02:28 UTC, d_dart
Details
build log (build.log,132.89 KB, text/plain)
2012-09-10 17:09 UTC, Christian
Details
emerge --info (emerge.info,17.36 KB, text/plain)
2012-09-10 17:09 UTC, Christian
Details
build.log (build.log,164.57 KB, text/plain)
2012-09-10 23:21 UTC, megabaks
Details
Corrected patch for compatibility with KDE 4.9 (compiz-kde-4.9.patch,4.86 KB, text/plain)
2012-09-11 09:40 UTC, Sergey Popov
Details

Note You need to log in before you can comment on or make changes to this bug.
Description d_dart 2012-09-04 05:36:46 UTC
when i have USE=kde (and gnome?) i get the following error

decorator.cpp:218:33: error: cannot allocate an object of abstract type 'KWD::Window'

http://pastebin.com/juprKr0M -- full output

Reproducible: Always

Steps to Reproduce:
1. USE="cairo dbus gnome gtk kde* svg -fuse -gconf
2. comile
Comment 1 Jeroen Roovers (RETIRED) gentoo-dev 2012-09-04 15:10:17 UTC
1) Please post your `emerge --info' output in a comment.
2) Please attach the entire build log to this bug report.
Comment 2 Sergey Popov gentoo-dev 2012-09-04 20:31:28 UTC
Also it would be nice to know, which version of KDE are you use?
Comment 3 d_dart 2012-09-07 03:33:30 UTC
Sorry for the late response, A lot of iRL stuff

kde 4.9, my make.conf is arch ~amd64 so most of my packages should be past portage 'stable'

that being said here are the files that have been requested

(emerge --info) http://bpaste.net/show/44186/
(build log) http://bpaste.net/show/44187/
Comment 4 Sergey Popov gentoo-dev 2012-09-07 06:43:31 UTC
I can not test compiz with KDE 4.9 right now. Can you test this patch(http://cgit.compiz.org/compiz/core/patch/?id=3c6f698c12f455661807c4115feaa73007fc33d1) and post result here?

Also, do not post links on pastebin-like services! Put ebuilds and 'emerge --info' stuff directly here(in a comments or attachments).
Comment 5 d_dart 2012-09-08 02:28:20 UTC
Created attachment 323182 [details]
the patch provided above was named compiz-kde-bgo.patch
Comment 6 d_dart 2012-09-08 02:29:20 UTC
Sorry, 

I ended up upgrading to kde 4.9.1 due to unrelated issues with kwin (didn't get resolved, but that's another matter entirely), I could only figure out how to get my overlay working with the patch now, So I must apologize again

im not sure if my ebuild didnt end up working right however (pretty much just applied that patch), but i would imagine that the patch parameters are obsolete with the new kde version. in anycase, the patch failed. 



>>> Emerging (1 of 1) x11-wm/compiz-0.8.8 from x-portage
 * compiz-0.8.8.tar.bz2 SHA256 SHA512 WHIRLPOOL size ;-) ...                               [ ok ]
>>> Unpacking source...
>>> Unpacking compiz-0.8.8.tar.bz2 to /var/tmp/portage/portage/x11-wm/compiz-0.8.8/work
>>> Source unpacked in /var/tmp/portage/portage/x11-wm/compiz-0.8.8/work
>>> Preparing source in /var/tmp/portage/portage/x11-wm/compiz-0.8.8/work/compiz-0.8.8 ...
 * Applying compiz-no-gconf.patch ...                                                      [ ok ]
 * Applying compiz-kde-4.8.patch ...                                                       [ ok ]
 * Applying compiz-kde-bgo.patch ...

 * Failed Patch: compiz-kde-bgo.patch !
 *  ( /usr/local/portage/x11-wm/compiz/files/compiz-kde-bgo.patch )
 * 
 * Include in your bugreport the contents of:
 * 
 *   /var/tmp/portage/portage/x11-wm/compiz-0.8.8/temp/compiz-kde-bgo.patch.out

 * ERROR: x11-wm/compiz-0.8.8 failed (prepare phase):
 *   Failed Patch: compiz-kde-bgo.patch!
 * 
 * Call stack:
 *     ebuild.sh, line   85:  Called src_prepare
 *   environment, line 3222:  Called epatch '/usr/local/portage/x11-wm/compiz/files/compiz-kde-bgo.patch'
 *   environment, line 1783:  Called die
 * The specific snippet of code:
 *               die "Failed Patch: ${patchname}!";
 * 
 * If you need support, post the output of `emerge --info '=x11-wm/compiz-0.8.8'`,
 * the complete build log and the output of `emerge -pqv '=x11-wm/compiz-0.8.8'`.
 * This ebuild is from an overlay named 'x-portage': '/usr/local/portage/'
 * The complete build log is located at '/var/tmp/portage/portage/x11-wm/compiz-0.8.8/temp/build.log'.
 * The ebuild environment file is located at '/var/tmp/portage/portage/x11-wm/compiz-0.8.8/temp/environment'.
 * Working directory: '/var/tmp/portage/portage/x11-wm/compiz-0.8.8/work/compiz-0.8.8'
 * S: '/var/tmp/portage/portage/x11-wm/compiz-0.8.8/work/compiz-0.8.8'
Comment 7 Christian 2012-09-08 11:05:32 UTC
Hi, when you remove the kde-8.8 patch froom your ebuild this error goes away, the two patches seem to be incompatible.

but i have another issue, which is unrelated to this one, it was also there before applying the bgo-patch. shall i continue here or open a new bug?

btw: this is the error in short:
window.cpp: In member function 'void KWD::Window::showKillProcessDialog(Time)':
window.cpp:1780:43: error: 'gethostname' was not declared in this scope
Comment 8 megabaks 2012-09-10 07:08:35 UTC
> * Applying compiz-kde-4.8.patch ...                                                       [ ok ]
> * Applying compiz-kde-bgo.patch ...
WUT?
choose one!
i.e. https://github.com/megabaks/stuff/blob/master/x11-wm/compiz/compiz-0.8.8.ebuild
just works

${PN}-kde-4.8.patch == compiz-kde-bgo.patch
Comment 9 megabaks 2012-09-10 07:09:51 UTC
(In reply to comment #8)
ooops 
${PN}-kde-4.9.patch == compiz-kde-bgo.patch
Comment 10 Christian 2012-09-10 17:08:34 UTC
With your ebuild, I still get the gethostname-not-declared error.
I'll add the build log and emerge --info, if this shoudl go to another thread, just tell it.
Comment 11 Christian 2012-09-10 17:09:01 UTC
Created attachment 323434 [details]
build log
Comment 12 Christian 2012-09-10 17:09:34 UTC
Created attachment 323436 [details]
emerge --info
Comment 13 megabaks 2012-09-10 23:21:18 UTC
Created attachment 323464 [details]
build.log

how are you do it?
Comment 14 Christian 2012-09-11 06:03:58 UTC
What do you mean?
Comment 15 megabaks 2012-09-11 07:02:36 UTC
(In reply to comment #14)
> What do you mean?
you are first, who can't compile the stuff's compiz.
32bit - see my comments
64bit - see http://pastebin.com/gRWghTse
and only you have warning "_FORTIFY_SOURCE redefined"
Comment 16 Sergey Popov gentoo-dev 2012-09-11 09:40:25 UTC
Created attachment 323488 [details]
Corrected patch for compatibility with KDE 4.9

+  11 Sep 2012; Sergey Popov <pinkbyte@gentoo.org> compiz-0.8.8.ebuild,
+  +files/compiz-kde-4.9.patch:
+  Add compatibility patch for KDE 4.9

Compiles fine. Please test it
Comment 17 megabaks 2012-09-11 17:07:12 UTC
(In reply to comment #16)
> Created attachment 323488 [details]
> Corrected patch for compatibility with KDE 4.9
> 
> +  11 Sep 2012; Sergey Popov <pinkbyte@gentoo.org> compiz-0.8.8.ebuild,
> +  +files/compiz-kde-4.9.patch:
> +  Add compatibility patch for KDE 4.9
> 
> Compiles fine. Please test it

watch for?
Christian's problem don't fixed (инфа 146%)
one patch for 4.8&4.9?
why?
Comment 18 megabaks 2012-09-11 17:08:08 UTC
(In reply to comment #17)
> (In reply to comment #16)
> > Created attachment 323488 [details]
> > Corrected patch for compatibility with KDE 4.9
> > 
> > +  11 Sep 2012; Sergey Popov <pinkbyte@gentoo.org> compiz-0.8.8.ebuild,
> > +  +files/compiz-kde-4.9.patch:
> > +  Add compatibility patch for KDE 4.9
> > 
> > Compiles fine. Please test it
> 
> watch for?
> Christian's problem don't fixed (инфа 146%)
> one patch for 4.8&4.9?
> why?
*what
Comment 19 Christian 2012-09-11 22:57:02 UTC
I found it: it's a problem with gcc-4.7, 4.7 libstdc++ removed unistd.h from includes, including it manually in compiz-0.8.8/kde/window-decorator-kde4/window.cpp finally made it compile. Should this go to upstream?
Unfortunately I couldn't find anything about FORTIFY_SOURCE, but maybe its related?
Comment 20 megabaks 2012-09-12 05:10:42 UTC
(In reply to comment #19)
> I found it: it's a problem with gcc-4.7, 4.7 libstdc++ removed unistd.h from
> includes, including it manually in
> compiz-0.8.8/kde/window-decorator-kde4/window.cpp finally made it compile.
> Should this go to upstream?
> Unfortunately I couldn't find anything about FORTIFY_SOURCE, but maybe its
> related?

about 4.7
https://github.com/megabaks/stuff/commit/4c47b92ab1a7b972774a2ab71a27ae531dba100a
can you test it at 64?
32 - works 0.8.6/0.8.8
about FORTIFY_SOURCE
gcc-4.7 problem - looking now....
Comment 21 Christian 2012-09-12 05:28:48 UTC
Still the warnings about _FORTIFY_SOURCE, but works flawless otherwise.
Thanks for help!!
Comment 22 megabaks 2012-09-12 05:41:00 UTC
(In reply to comment #21)
> Still the warnings about _FORTIFY_SOURCE, but works flawless otherwise.
> Thanks for help!!

about _FORTIFY_SOURCE:
in gcc-4.7
http://gcc.gnu.org/gcc-4.7/changes.html
>A string length optimization pass has been added. It attempts to track string lengths and optimize >various standard C string functions like strlen, strchr, strcpy, strcat, stpcpy and their >_FORTIFY_SOURCE counterparts into faster alternatives. This pass is enabled by default at -O2 or >above, unless optimizing for size, and can be disabled by the -fno-optimize-strlen option. The pass >can e.g. optimize

in compiz
CFLAGS="$CFLAGS -D_FORTIFY_SOURCE=2"
...
PROFIT :3
Comment 23 megabaks 2012-09-12 05:52:30 UTC
(In reply to comment #21)
about _FORTIFY_SOURCE

sed -e 's|-D_FORTIFY_SOURCE=2||g' -i /var/tmp/portage/x11-wm/compiz-0.8.8/work/compiz-0.8.8/configure{,.ac} ---> no warnings
http://bpaste.net/show/yS66BI7ZG5xQ5K0eXUhW/
Comment 24 megabaks 2012-09-12 06:03:57 UTC
Sergey Popov, in stuff added patch for gcc-4.7 and hack for '_FORTIFY_SOURCE redefined'
test it && copy in the main tree
Comment 25 Sergey Popov gentoo-dev 2012-09-12 19:35:11 UTC
+  12 Sep 2012; Sergey Popov <pinkbyte@gentoo.org> compiz-0.8.8-r1.ebuild,
+  +files/compiz-gcc-4.7.patch:
+  Add patch for compatibility with gcc 4.7 or higher, wrt bug #433870. Thanks
+  to Christian for discovering this issue and megabaks - for providing solution
+  to it

It should be a separate bug, but if we began to talk about it here - let's began fixing it here too. This patch also fixes problem about _FORTIFY_SOURCES too, but not fully, some warnings still presents :-/

Christian, file a new bug about _FORTIFY_SOURCES, will look on it closer there.

Closing this as FIXED