Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 350746 - app-emulation/kqemu-1.4.0_pre1-r1 does not build against 2.6.37
Summary: app-emulation/kqemu-1.4.0_pre1-r1 does not build against 2.6.37
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: Luca Barbato
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-01-05 22:00 UTC by Alexandre Rostovtsev (RETIRED)
Modified: 2011-01-18 20:55 UTC (History)
3 users (show)

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


Attachments
patch for kernel 2.6.37 compatibility (kqemu-1.4.0_pre1-init_MUTEX.patch,645 bytes, patch)
2011-01-05 22:03 UTC, Alexandre Rostovtsev (RETIRED)
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Alexandre Rostovtsev (RETIRED) gentoo-dev 2011-01-05 22:00:45 UTC
kernel 2.6.37 has finally removed the init_MUTEX macro:
http://git.kernel.org/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commitdiff;h=4882720b267b7b1d1b0ce08334b205f0329d4615;hp=45f4d0243525b6bc747c946937ced437b135a84d

As a result, kqemu-1.4.0_pre1-r1, which uses this macro, fails to build:
# emerge kqemu
[...]
make[1]: Entering directory `/usr/src/linux-2.6.37-gentoo'
  CC [M]  /var/tmp/portage/app-emulation/kqemu-1.4.0_pre1-r1/work/kqemu-1.4.0pre1/kqemu-linux.o
/var/tmp/portage/app-emulation/kqemu-1.4.0_pre1-r1/work/kqemu-1.4.0pre1/kqemu-linux.c: In function ‘kqemu_open’:
/var/tmp/portage/app-emulation/kqemu-1.4.0_pre1-r1/work/kqemu-1.4.0pre1/kqemu-linux.c:228:5: error: implicit declaration of function ‘init_MUTEX’
make[2]: *** [/var/tmp/portage/app-emulation/kqemu-1.4.0_pre1-r1/work/kqemu-1.4.0pre1/kqemu-linux.o] Error 1
make[1]: *** [_module_/var/tmp/portage/app-emulation/kqemu-1.4.0_pre1-r1/work/kqemu-1.4.0pre1] Error 2
make[1]: Leaving directory `/usr/src/linux-2.6.37-gentoo'
make: *** [kqemu.ko] Error 2
 * ERROR: app-emulation/kqemu-1.4.0_pre1-r1 failed:
 *   Make failed
Comment 1 Alexandre Rostovtsev (RETIRED) gentoo-dev 2011-01-05 22:03:39 UTC
Created attachment 258984 [details, diff]
patch for kernel 2.6.37 compatibility

This patch #defines init_MUTEX in kqemu-linux.c if it is not already defined, allowing kqemu to build against kernel 2.6.37
Comment 2 Ian Abbott 2011-01-13 10:59:19 UTC
(In reply to comment #1)
> Created an attachment (id=258984) [details]
> patch for kernel 2.6.37 compatibility
> 
> This patch #defines init_MUTEX in kqemu-linux.c if it is not already defined,
> allowing kqemu to build against kernel 2.6.37
> 

Patch works for me (on amd64), thanks! 

Comment 3 Alexey 2011-01-18 11:52:10 UTC
> patch for kernel 2.6.37 compatibility

Thank you, all works (on x86).
Comment 4 Markos Chandras (RETIRED) gentoo-dev 2011-01-18 19:10:21 UTC
I want to apply this patch to portage but I can't find a way to send it upstream. Can you please do it?
Comment 5 Alexandre Rostovtsev (RETIRED) gentoo-dev 2011-01-18 20:18:34 UTC
(In reply to comment #4)
> I want to apply this patch to portage but I can't find a way to send it
> upstream. Can you please do it?

Upstream appears to have abandoned it: http://lists.nongnu.org/archive/html/qemu-devel/2009-08/msg00680.html
Comment 6 Markos Chandras (RETIRED) gentoo-dev 2011-01-18 20:47:11 UTC
I see. Thank you
Comment 7 Markos Chandras (RETIRED) gentoo-dev 2011-01-18 20:55:06 UTC
+  18 Jan 2011; Markos Chandras <hwoarang@gentoo.org>
+  kqemu-1.4.0_pre1-r1.ebuild, +files/kqemu-1.4.0_pre1-init_MUTEX.patch:
+  Non-maintainer commit. Apply patch to build against 2.6.37. Thanks to
+  Alexandre Rostovtsev <tetromino@gmail.com>. Bug #350746
+