Summary: | app-emulation/xen-tools-4.0.0 fails to compile: "../lib/blktaplib.h:199:0: error: "WRITE" redefined" | ||
---|---|---|---|
Product: | Gentoo Linux | Reporter: | Charlie Gehlin <charlie> |
Component: | Current packages | Assignee: | Gentoo Xen Devs <xen> |
Status: | RESOLVED WORKSFORME | ||
Severity: | normal | CC: | 4glitch, diego.abelenda, dimitrije.ziv, flameeyes, holler.loudly, joost.ruis, mail2lx, me, patrick, rose, sebastian, virginian, wojciech |
Priority: | High | ||
Version: | unspecified | ||
Hardware: | AMD64 | ||
OS: | Linux | ||
Whiteboard: | |||
Package list: | Runtime testing required: | --- | |
Attachments: |
emerge --info
Redefines READ and WRITE in tools/blktap/lib/blktaplib.h and all consumers to BLKTAP_READ and BLKTAP_WRITE |
Description
Charlie Gehlin
2010-12-03 16:36:45 UTC
Created attachment 256253 [details]
emerge --info
I can reproduce that. Seems to be newer kernel-headers causing this. Stupid idiotic stupid xen build system with -Wall ... (In reply to comment #2) > I can reproduce that. Seems to be newer kernel-headers causing this. > Downgrading to linux-headers 2.6.33 allows it to build. This will need some investigation :( This is also the case with app-emulation/xen-tools-4.0.1 And linux-headers-2.6.35 was the newest version that worked. i'm having the exact same problem in a fresh ~amd64 setup same here with x86 and amd64. I temp fixed it with: vim /usr/include/linux/fs.h :150 and change #define WRITE RW_MASK to /* #define WRITE RW_MASK */ (In reply to comment #6) > same here with x86 and amd64. > > I temp fixed it with: > > vim /usr/include/linux/fs.h > :150 > and change > #define WRITE RW_MASK > to > /* #define WRITE RW_MASK */ > I have the same problem: Info as follows: xen1 ~ # emerge --info app-emulation/xen-tools Portage 2.1.9.39 (default/linux/amd64/10.0/server, gcc-4.4.4, glibc-2.13-r0, 2.6.36-gentoo-r5 x86_64) ================================================================= System Settings ================================================================= System uname: Linux-2.6.36-gentoo-r5-x86_64-Intel-R-_Atom-TM-_CPU_D525_@_1.80GHz-with-gentoo-2.0.1 Timestamp of tree: Mon, 14 Feb 2011 16:45:01 +0000 app-shells/bash: 4.1_p9 dev-java/java-config: 2.1.11-r3 dev-lang/python: 2.6.6-r1, 2.7.1, 3.1.3 dev-util/cmake: 2.8.3-r1 sys-apps/baselayout: 2.0.1-r1 sys-apps/openrc: 0.7.0 sys-apps/sandbox: 2.4 sys-devel/autoconf: 2.68 sys-devel/automake: 1.11.1 sys-devel/binutils: 2.21 sys-devel/gcc: 4.4.4-r2, 4.5.2 sys-devel/gcc-config: 1.4.1 sys-devel/libtool: 2.4-r1 sys-devel/make: 3.82 virtual/os-headers: 2.6.36.1 (sys-kernel/linux-headers) ACCEPT_KEYWORDS="amd64 ~amd64" ACCEPT_LICENSE="* -@EULA" CBUILD="x86_64-pc-linux-gnu" CFLAGS="-O2 -pipe" CHOST="x86_64-pc-linux-gnu" CONFIG_PROTECT="/etc" CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/env.d/java/ /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo" CXXFLAGS="-O2 -pipe" DISTDIR="/usr/portage/distfiles" FEATURES="assume-digests binpkg-logs distlocks fixlafiles fixpackages news parallel-fetch protect-owned sandbox sfperms strict unknown-features-warn unmerge-logs unmerge-orphans userfetch" FFLAGS="" GENTOO_MIRRORS="http://gentoo.virginmedia.com/" LDFLAGS="-Wl,-O1 -Wl,--as-needed" PKGDIR="/usr/portage/packages" PORTAGE_CONFIGROOT="/" 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" SYNC="rsync://rsync.uk.gentoo.org/gentoo-portage" USE="X acl amd64 berkdb bzip2 cli cracklib crypt cups cxx dri fortran gdbm gpm iconv ipv6 mmx modules mudflap multilib ncurses nls nptl nptlonly openmp pam pcre pppd python readline session snmp sse sse2 ssl sysfs tcpd truetype unicode xml xorg zlib" ALSA_CARDS="ali5451 als4000 atiixp atiixp-modem bt87x ca0106 cmipci 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 cgi cgid 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" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" ELIBC="glibc" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock itrax mtk3301 nmea ntrip navcom oceanserver oldstyle oncore rtcm104v2 rtcm104v3 sirf superstar2 timing tsip tripmate tnt ubx" INPUT_DEVICES="keyboard mouse evdev" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" PHP_TARGETS="php5-3" RUBY_TARGETS="ruby18" USERLAND="GNU" VIDEO_CARDS="fbdev glint intel mach64 mga neomagic nouveau nv r128 radeon savage sis tdfx trident vesa via vmware dummy v4l" XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipset ipp2p iface geoip fuzzy condition tee tarpit sysrq steal rawnat logmark ipmark dhcpmac delude chaos account" Unset: CPPFLAGS, CTARGET, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LANG, LC_ALL, LINGUAS, MAKEOPTS, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS, PORTDIR_OVERLAY ================================================================= Package Settings ================================================================= app-emulation/xen-tools-4.0.1 was built with the following: USE="(multilib) -acm -api -custom-cflags -debug -doc -flask -hvm -ioemu -pygrub -screen" CFLAGS="-fno-strict-overflow" CXXFLAGS="-O2 -pipe -fno-strict-overflow" LDFLAGS="" I made the change as suggested by Joerg and the compilation worked. What I don't know is what impact 9if any) this will now have on my system. Could anybody explain that to me? hopefully there isn't any but as I searched the fs.h file and found out that WRITE is defined as (1 << __REQ_WRITE) it could pose a problem if the Xen code thinks WRITE is really equal to 1 and not something else (and at the same time __REQ_WRITE is different than 0 -- as I couldn't find where this is defined I don't know its value). Sadly if the source code thinks WRITE == 1 there could be really unpredictable problems, and as it seems to be used in the virtual disk part of the code it could break completely the images. So it all depends on the code quality, and I don't want to review it completely to see if it is safe ^^ Downgrading the linux-headers should be safe though because the linux policy is to keep the binary interface between kernel and userspace. BTW bug #354043 is the same as this one for another version of xen-tools. *** Bug 347843 has been marked as a duplicate of this bug. *** *** Bug 349455 has been marked as a duplicate of this bug. *** Xen 4.1 in tree. Please test with it and reopen if it doesnt work Confirmed on new x86 install that this does happen with 3.4.2 and 4.0.1 Does not happen on 4.1 series, but 4.1 has issues that are stopping production. Why should we be forced to upgrade due to a bug? Created attachment 277033 [details, diff]
Redefines READ and WRITE in tools/blktap/lib/blktaplib.h and all consumers to BLKTAP_READ and BLKTAP_WRITE
For those users subscribed to this bug who require a working ebuild for xen-tools-4.0.1 one is now available in my [hacking-gentoo] overlay via layman. Please be aware that this build has only received VERY light testing however no problems have been reported thus far. |