Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 679824 - app-emulation/xen-tools-4.12.0_rc4 USE=ovmf fails to build
Summary: app-emulation/xen-tools-4.12.0_rc4 USE=ovmf fails to build
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: AMD64 Linux
: Normal normal (vote)
Assignee: Gentoo Xen Devs
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2019-03-09 05:03 UTC by John L. Poole
Modified: 2019-04-04 14:03 UTC (History)
1 user (show)

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


Attachments
Build Log (app-emulation%3Axen-tools-4.12.0_rc4%3A20190309-030937.log.zip,55.78 KB, application/x-zip-compressed)
2019-03-09 05:15 UTC, John L. Poole
Details
Environment (environment,120.51 KB, text/plain)
2019-03-09 05:17 UTC, John L. Poole
Details
emerge log (app-emulation_xen-tools-4.12.0_rc4_20190309-180712.log.ta.bz2,23.71 KB, application/x-bzip)
2019-03-09 18:43 UTC, John L. Poole
Details

Note You need to log in before you can comment on or make changes to this bug.
Description John L. Poole 2019-03-09 05:03:25 UTC
emerge app-emulation/xen-tools app-emulation/xen

>>> Failed to emerge app-emulation/xen-tools-4.12.0_rc4, Log file:

>>>  '/var/log/portage/app-emulation:xen-tools-4.12.0_rc4:20190309-030937.log'

 * Messages for package app-emulation/xen-4.12.0_rc4:
 * Log file: /var/log/portage/app-emulation:xen-4.12.0_rc4:20190309-030932.log

 * To avoid automounting and auto(un)installing with /boot,
 * just export the DONT_MOUNT_BOOT variable.

 * Messages for package app-emulation/xen-tools-4.12.0_rc4:
 * Log file: /var/log/portage/app-emulation:xen-tools-4.12.0_rc4:20190309-030937.log

 * ERROR: app-emulation/xen-tools-4.12.0_rc4::gentoo failed (compile phase):
 *   emake failed
 *
 * If you need support, post the output of `emerge --info '=app-emulation/xen-tools-4.12.0_rc4::gentoo'`,
 * the complete build log and the output of `emerge -pqv '=app-emulation/xen-tools-4.12.0_rc4::gentoo'`.
 * The complete build log is located at '/var/log/portage/app-emulation:xen-tools-4.12.0_rc4:20190309-030937.log'.
 * For convenience, a symlink to the build log is located at '/mnt/extra/portagetemp/portage/app-emulation/xen-tools-4.12.0_rc4/temp/build.log'.
 * The ebuild environment file is located at '/mnt/extra/portagetemp/portage/app-emulation/xen-tools-4.12.0_rc4/temp/environment'.
 * Working directory: '/mnt/extra/portagetemp/portage/app-emulation/xen-tools-4.12.0_rc4/work/xen-4.12.0-rc4'
 * S: '/mnt/extra/portagetemp/portage/app-emulation/xen-tools-4.12.0_rc4/work/xen-4.12.0-rc4'
zeta 

Attachments to follow
Comment 1 John L. Poole 2019-03-09 05:15:01 UTC
Created attachment 568242 [details]
Build Log
Comment 2 John L. Poole 2019-03-09 05:16:34 UTC
emerge -pqv:
[ebuild     U ] app-emulation/xen-tools-4.12.0_rc4 [4.11.1] USE="flask hvm ovmf pam qemu qemu-traditional screen sdl -api -custom-cflags -debug -doc -ocaml -pygrub -python -static-libs -system-qemu -system-seabios" PYTHON_TARGETS="python2_7" 

When peforming "emerge -pqv" the following came to STDERR:
zeta / # emerge -pqv '=app-emulation/xen-tools-4.12.0_rc4::gentoo' > /home/jlpoole/gentoobugs/679824/emerge.pqv


!!! Multiple package instances within a single package slot have been pulled
!!! into the dependency graph, resulting in a slot conflict:

app-emulation/xen-tools:0

  (app-emulation/xen-tools-4.12.0_rc4:0/4.12::gentoo, ebuild scheduled for merge) pulled in by
    =app-emulation/xen-tools-4.12.0_rc4::gentoo (Argument)

  (app-emulation/xen-tools-4.11.1:0/4.11::gentoo, installed) pulled in by
    ~app-emulation/xen-tools-4.11.1 required by (app-emulation/xen-4.11.1:0/0::gentoo, installed)
    ^                        ^^^^^^                                             


zeta / #
Comment 3 John L. Poole 2019-03-09 05:17:15 UTC
Created attachment 568244 [details]
Environment
Comment 4 John L. Poole 2019-03-09 05:18:30 UTC
emerge --info '=app-emulation/xen-tools-4.12.0_rc4::gentoo':

Portage 2.3.51 (python 3.6.5-final-0, default/linux/amd64/17.0, gcc-7.3.0, glibc-2.27-r6, 4.19.23-gentoo x86_64)
=================================================================
                         System Settings
=================================================================
System uname: Linux-4.19.23-gentoo-x86_64-Intel-R-_Atom-TM-_CPU_C2750_@_2.40GHz-with-gentoo-2.6
KiB Mem:    62419344 total,  60201632 free
KiB Swap:     524284 total,    524284 free
Timestamp of repository gentoo: Sat, 09 Mar 2019 02:30:01 +0000
Head commit of repository gentoo: 151e6a4a1478591e5908ae95b494b3d48ff62b58
sh bash 4.4_p23-r1
ld GNU ld (Gentoo 2.30 p5) 2.30.0
app-shells/bash:          4.4_p23-r1::gentoo
dev-lang/perl:            5.26.2::gentoo
dev-lang/python:          2.7.15::gentoo, 3.6.5::gentoo
dev-util/cmake:           3.9.6::gentoo
dev-util/pkgconfig:       0.29.2::gentoo
sys-apps/baselayout:      2.6-r1::gentoo
sys-apps/openrc:          0.38.3-r1::gentoo
sys-apps/sandbox:         2.13::gentoo
sys-devel/autoconf:       2.69-r4::gentoo
sys-devel/automake:       1.16.1-r1::gentoo
sys-devel/binutils:       2.30-r4::gentoo
sys-devel/gcc:            7.3.0-r3::gentoo, 8.2.0-r6::gentoo
sys-devel/gcc-config:     2.0::gentoo
sys-devel/libtool:        2.4.6-r3::gentoo
sys-devel/make:           4.2.1-r4::gentoo
sys-kernel/linux-headers: 4.14-r1::gentoo (virtual/os-headers)
sys-libs/glibc:           2.27-r6::gentoo
Repositories:

gentoo
    location: /mnt/extra/portage
    sync-type: rsync
    sync-uri: rsync://rsync.gentoo.org/gentoo-portage
    priority: -1000
    sync-rsync-extra-opts: 
    sync-rsync-verify-jobs: 1
    sync-rsync-verify-metamanifest: yes
    sync-rsync-verify-max-age: 24

localrepo
    location: /usr/local/portage
    masters: gentoo

ACCEPT_KEYWORDS="amd64"
ACCEPT_LICENSE="* -@EULA"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-march=native -O2 -pipe"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/share/gnupg/qualified.txt"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo"
CXXFLAGS="-march=native -O2 -pipe"
DISTDIR="/usr/portage/distfiles"
ENV_UNSET="DBUS_SESSION_BUS_ADDRESS DISPLAY GOBIN PERL5LIB PERL5OPT PERLPREFIX PERL_CORE PERL_MB_OPT PERL_MM_OPT XAUTHORITY XDG_CACHE_HOME XDG_CONFIG_HOME XDG_DATA_HOME XDG_RUNTIME_DIR"
FCFLAGS="-O2 -pipe"
FEATURES="assume-digests binpkg-logs config-protect-if-modified distlocks ebuild-locks fixlafiles merge-sync multilib-strict news parallel-fetch preserve-libs protect-owned sandbox sfperms strict unknown-features-warn unmerge-logs unmerge-orphans userfetch userpriv usersandbox usersync xattr"
FFLAGS="-O2 -pipe"
GENTOO_MIRRORS="http://www.gtlib.gatech.edu/pub/gentoo http://gentoo.osuosl.org/ http://mirror.usu.edu/mirrors/gentoo/"
LANG="en_US.utf8"
LDFLAGS="-Wl,-O1 -Wl,--as-needed"
MAKEOPTS="-j7"
PKGDIR="/usr/portage/packages"
PORTAGE_CONFIGROOT="/"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --omit-dir-times --compress --force --whole-file --delete --stats --human-readable --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages --exclude=/.git"
PORTAGE_TMPDIR="/mnt/extra/portagetemp"
USE="X acl amd64 berkdb bindist bzip2 cli crypt cxx dri efi fortran gdbm iconv idm ipv6 libtirpc mmx multilib ncurses nls nptl openmp pam pcre readline seccomp sse sse2 ssl tcpd unicode urandom xattr zlib" ABI_X86="64" 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" APACHE2_MODULES="authn_core authz_core socache_shmcb unixd 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" CALLIGRA_FEATURES="karbon sheets words" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" CPU_FLAGS_X86="mmx sse sse2" ELIBC="glibc" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock isync itrax mtk3301 nmea ntrip navcom oceanserver oldstyle oncore rtcm104v2 rtcm104v3 sirf skytraq superstar2 timing tsip tripmate tnt ublox ubx" GRUB_PLATFORMS="efi-64 xen" INPUT_DEVICES="libinput keyboard mouse" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LIBREOFFICE_EXTENSIONS="presenter-console presenter-minimizer" NETBEANS_MODULES="apisupport cnd groovy gsf harness ide identity j2ee java mobility nb php profiler soa visualweb webcommon websvccommon xml" OFFICE_IMPLEMENTATION="libreoffice" PHP_TARGETS="php5-6 php7-1" POSTGRES_TARGETS="postgres9_5 postgres10" PYTHON_SINGLE_TARGET="python3_6" PYTHON_TARGETS="python2_7 python3_6" RUBY_TARGETS="ruby24" USERLAND="GNU" VIDEO_CARDS="amdgpu fbdev intel nouveau radeon radeonsi vesa 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:  CC, CPPFLAGS, CTARGET, CXX, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LC_ALL, LINGUAS, PORTAGE_BINHOST, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS
Comment 5 Tomáš Mózes 2019-03-09 06:00:16 UTC
Thanks for the report, haven't tested with USE=ovmf.
Comment 6 John L. Poole 2019-03-09 06:04:24 UTC
Just to get this off my chest and to share with any readers considering building a xen server on newer components:  When I purchased my Supermicro Intel Atom based server, I was unaware of the UEFI.  It has been an absolute nightmare.
Comment 7 Tomáš Mózes 2019-03-09 06:49:15 UTC
Seems like it builds fine with USE=ovmf locally, do you have USE=debug enabled?
Comment 8 Tomáš Mózes 2019-03-09 06:49:44 UTC
(In reply to John L. Poole from comment #6)
> Just to get this off my chest and to share with any readers considering
> building a xen server on newer components:  When I purchased my Supermicro
> Intel Atom based server, I was unaware of the UEFI.  It has been an absolute
> nightmare.

Cannot you switch to legacy boot without EFI?
Comment 9 John L. Poole 2019-03-09 18:03:46 UTC
In response to: " do you have USE=debug enabled?"
No, did not try: USE=debug.  
I'll do so and update with my findings.

In response to: "Cannot you switch to legacy boot without EFI?"
I do not recall it's possible, I think what I would be invoking is a BIOS simulator.  In Bug #679826 - "app-emulation/xen seldom boots -- hangs on masked ExtINT on CPU#[various number]" I think the problem may be caused by the underlying UEFI system interfering with the code that attempts to mask the interrupt on the CPU.  This is based upon an observation I have quote in  Bug #679826 that suggests something akin to that problem.  I remember wondering if I could just configure my server without EUFI and my conclusion was I could not.
Comment 10 John L. Poole 2019-03-09 18:43:26 UTC
Created attachment 568344 [details]
emerge log

As suggest, tried:  USE=debug emerge app-emulation/xen-tools app-emulation/xen

Result: failed:

build.py...
 : error 7000: Failed to execute command
        make tbuild [/mnt/extra/portagetemp/portage/app-emulation/xen-tools-4.12.0_rc4/work/xen-4.12.0-rc4/tools/firmware/ovmf-dir-remote/Build/OvmfX64/DEBUG_GCC5/X64/MdeModulePkg/Library/BootMaintenanceManagerUiLib/BootMaintenanceManagerUiLib]


build.py...
 : error F002: Failed to build module
        /mnt/extra/portagetemp/portage/app-emulation/xen-tools-4.12.0_rc4/work/xen-4.12.0-rc4/tools/firmware/ovmf-dir-remote/MdeModulePkg/Library/BootMaintenanceManagerUiLib/BootMaintenanceManagerUiLib.inf [X64, GCC5, DEBUG]

- Failed -
Build end time: 10:11:07, Mar.09 2019
Build total time: 00:01:13

make[6]: *** [Makefile:20: build] Error 1
make[6]: Leaving directory '/mnt/extra/portagetemp/portage/app-emulation/xen-tools-4.12.0_rc4/work/xen-4.12.0-rc4/tools/firmware/ovmf-dir-remote'
make[5]: *** [/mnt/extra/portagetemp/portage/app-emulation/xen-tools-4.12.0_rc4/work/xen-4.12.0-rc4/tools/firmware/../../tools/Rules.mk:251: subdir-all-ovmf-dir] Error 2
make[5]: Leaving directory '/mnt/extra/portagetemp/portage/app-emulation/xen-tools-4.12.0_rc4/work/xen-4.12.0-rc4/tools/firmware'
make[4]: *** [/mnt/extra/portagetemp/portage/app-emulation/xen-tools-4.12.0_rc4/work/xen-4.12.0-rc4/tools/firmware/../../tools/Rules.mk:246: subdirs-all] Error 2
make[4]: Leaving directory '/mnt/extra/portagetemp/portage/app-emulation/xen-tools-4.12.0_rc4/work/xen-4.12.0-rc4/tools/firmware'
make[3]: *** [Makefile:40: all] Error 2
make[3]: Leaving directory '/mnt/extra/portagetemp/portage/app-emulation/xen-tools-4.12.0_rc4/work/xen-4.12.0-rc4/tools/firmware'
make[2]: *** [/mnt/extra/portagetemp/portage/app-emulation/xen-tools-4.12.0_rc4/work/xen-4.12.0-rc4/tools/../tools/Rules.mk:251: subdir-all-firmware] Error 2
make[2]: Leaving directory '/mnt/extra/portagetemp/portage/app-emulation/xen-tools-4.12.0_rc4/work/xen-4.12.0-rc4/tools'
make[1]: *** [/mnt/extra/portagetemp/portage/app-emulation/xen-tools-4.12.0_rc4/work/xen-4.12.0-rc4/tools/../tools/Rules.mk:246: subdirs-all] Error 2
make[1]: Leaving directory '/mnt/extra/portagetemp/portage/app-emulation/xen-tools-4.12.0_rc4/work/xen-4.12.0-rc4/tools'
make: *** [Makefile:59: build-tools] Error 2
 * ERROR: app-emulation/xen-tools-4.12.0_rc4::gentoo failed (compile phase):
 *   emake failed
 *
 * If you need support, post the output of `emerge --info '=app-emulation/xen-tools-4.12.0_rc4::gentoo'`,
 * the complete build log and the output of `emerge -pqv '=app-emulation/xen-tools-4.12.0_rc4::gentoo'`.
 * The complete build log is located at '/var/log/portage/app-emulation:xen-tools-4.12.0_rc4:20190309-180712.log'.
 * For convenience, a symlink to the build log is located at '/mnt/extra/portagetemp/portage/app-emulation/xen-tools-4.12.0_rc4/temp/build.log'.
 * The ebuild environment file is located at '/mnt/extra/portagetemp/portage/app-emulation/xen-tools-4.12.0_rc4/temp/environment'.
 * Working directory: '/mnt/extra/portagetemp/portage/app-emulation/xen-tools-4.12.0_rc4/work/xen-4.12.0-rc4'
 * S: '/mnt/extra/portagetemp/portage/app-emulation/xen-tools-4.12.0_rc4/work/xen-4.12.0-rc4'

>>> Failed to emerge app-emulation/xen-tools-4.12.0_rc4, Log file:

>>>  '/var/log/portage/app-emulation:xen-tools-4.12.0_rc4:20190309-180712.log'

 * Messages for package app-emulation/xen-4.12.0_rc4:
 * Log file: /var/log/portage/app-emulation:xen-4.12.0_rc4:20190309-180708.log

 * To avoid automounting and auto(un)installing with /boot,
 * just export the DONT_MOUN

Log app-emulation_xen-tools-4.12.0_rc4_20190309-180712.log.ta.bz2 attached.
Comment 11 Tomáš Mózes 2019-03-14 07:01:26 UTC
Cannot reproduce this on a current amd64 nor ~amd64 system. 

Tried with the following USE flags:
app-emulation/xen-tools hvm qemu sdl pygrub python ovmf flask screen

Do you have your system up to date? Can you try updating to gcc 8?
Comment 12 John L. Poole 2019-03-14 17:12:15 UTC
(In reply to Tomáš Mózes from comment #11)
> Cannot reproduce this on a current amd64 nor ~amd64 system. 
> 
> Tried with the following USE flags:
> app-emulation/xen-tools hvm qemu sdl pygrub python ovmf flask screen
> 
> Do you have your system up to date? Can you try updating to gcc 8?

This machine is current and I have been keeping it current during this process.
I was using gcc 7.3, so I switched to 8.2 and attempted a build.
Result:  Fails at the same place: 

...BootMaintenanceManagerUiLib/DEBUG/BootMaintenanceManager.c

The flags I'm showing for xen are: 
mine:  flask hvm ovmf pam qemu qemu-traditional screen sdl
yours: hvm qemu sdl pygrub python ovmf flask screen
diff -> yours has pygrub and python

So I modified xen-tools use variables specifying your line above and attempted to build the package.

zeta / #  emerge  app-emulation/xen -p

These are the packages that would be merged, in order:

Calculating dependencies... done!
[ebuild     U *] app-emulation/xen-tools-4.12.0_rc4 [4.11.1] USE="pygrub* python*"
[ebuild     U *] app-emulation/xen-4.12.0_rc4 [4.11.1-r1]
zeta / #


============= logs below ===============
zeta /home/jlpoole # date; emerge --sync
Thu Mar 14 09:40:32 PDT 2019
>>> Syncing repository 'gentoo' into '/mnt/extra/portage'...
 * Using keys from /usr/share/openpgp-keys/gentoo-release.asc
 * Refreshing keys from keyserver ...                                    [ ok ]
>>> Starting rsync with rsync://35.190.132.250/gentoo-portage...
>>> Checking server timestamp ...

receiving incremental file list
timestamp.chk

Number of files: 1 (reg: 1)
Number of created files: 0
Number of deleted files: 0
Number of regular files transferred: 1
Total file size: 32 bytes
Total transferred file size: 32 bytes
Literal data: 32 bytes
Matched data: 0 bytes
File list size: 41
File list generation time: 0.001 seconds
File list transfer time: 0.000 seconds
Total bytes sent: 104
Total bytes received: 127

sent 104 bytes  received 127 bytes  154.00 bytes/sec
total size is 32  speedup is 0.14

>>>
>>> Timestamps on the server and in the local repository are the same.
>>> Cancelling all further sync action. You are already up to date.
>>>
>>> In order to force sync, remove '/mnt/extra/portage/metadata/timestamp.chk'.
>>>

 * Manifest timestamp: 2019-03-14 15:38:50 UTC
 * Valid OpenPGP signature found:
 * - primary key: DCD05B71EAB94199527F44ACDB6B8C1F96D8BF6D
 * - subkey: E1D6ABB63BFCFB4BA02FDF1CEC590EEAC9189250
 * - timestamp: 2019-03-14 15:38:50 UTC
=== Sync completed for gentoo
q: Updating ebuild cache for /mnt/extra/portage ...
q: Finished 36446 entries in 0.721864 seconds

Action: sync for repo: gentoo, returned code = 0

 * An update to portage is available. It is _highly_ recommended
 * that you update portage now, before any other packages are updated.

 * To update portage, run 'emerge --oneshot portage' now.



zeta /home/jlpoole #

zeta /home/jlpoole # eix gcc -I
[I] sys-devel/gcc
     Available versions:
     (3.3.6) [M]~3.3.6-r1^s [M]~3.3.6-r2^s
     (3.4.6) [M]3.4.6-r2^s
     (4.0.4) [M]**4.0.4^s [M]**4.0.4-r1^s
     (4.1.2) [M]4.1.2^s [M]~4.1.2-r1^s
     (4.2.4) [M]~4.2.4-r1^s [M]~4.2.4-r2^s
     (4.3.6) [M]4.3.6-r1^s [M]~4.3.6-r2^s
     (4.4.7) [M]4.4.7^s [M]~4.4.7-r1^s
     (4.5.4) [M]4.5.4^s [M]~4.5.4-r1^s
     (4.6.4) [M]4.6.4^s [M]~4.6.4-r1^s
     (4.7.4) [M]4.7.4-r1^s [M]~4.7.4-r2^s
     (4.8.5) [M]4.8.5-r1^s [M]~4.8.5-r2^s
     (4.9.4) [M]4.9.4^s
     (5.4.0) [M]5.4.0-r4^s [M]~5.4.0-r6^s
     (5.5.0) [M]~5.5.0^s
     (6.4.0) 6.4.0-r1^s ~6.4.0-r5^s
     (6.5.0) ~6.5.0^s
     (7.3.0) 7.3.0-r3^s ~7.3.0-r6^s
     (7.4.0) ~7.4.0^s ~7.4.0-r1^s
     (8.2.0) ~8.2.0-r5^s 8.2.0-r6^s
     (8.3.0) ~8.3.0^s
       {altivec awt boundschecking cilk +cxx d debug doc fixed-point +fortran gcj go graphite hardened jit libssp mpx mudflap multilib +nls nopie nossp +nptl objc objc++ objc-gc +openmp +pch pgo +pie regression-test +sanitize +ssp systemtap test vanilla +vtv}
     Installed versions:  7.3.0-r3(7.3.0)^s(07:15:17 AM 12/06/2018)(cxx fortran multilib nls nptl openmp pch pie sanitize ssp vtv -altivec -cilk -debug -doc -fixed-point -go -graphite -hardened -jit -libssp -mpx -objc -objc++ -objc-gc -pgo -regression-test -vanilla) 8.2.0-r6(8.2.0)^s(08:08:32 PM 03/01/2019)(cxx fortran multilib nls nptl openmp pch pie sanitize ssp vtv -altivec -debug -doc -fixed-point -go -graphite -hardened -jit -libssp -mpx -objc -objc++ -objc-gc -pgo -regression-test -systemtap -vanilla)
     Homepage:            https://gcc.gnu.org/
     Description:         The GNU Compiler Collection

[I] sys-devel/gcc-config
     Available versions:  1.8-r1 ~1.9.0-r1 ~1.9.1 2.0 **9999
     Installed versions:  2.0(09:43:03 PM 02/20/2019)
     Homepage:            https://gitweb.gentoo.org/proj/gcc-config.git/
     Description:         Utility to manage compilers

Found 2 matches
zeta /home/jlpoole # eselect gcc list
 [1] x86_64-pc-linux-gnu-7.3.0 *
 [2] x86_64-pc-linux-gnu-8.2.0
zeta /home/jlpoole # eselect gcc set 2
 * Switching native-compiler to x86_64-pc-linux-gnu-8.2.0 ...
>>> Regenerating /etc/ld.so.cache...                                      [ ok ]

 * If you intend to use the gcc from the new profile in an already
 * running shell, please remember to do:

 *   . /etc/profile

zeta /home/jlpoole # . /etc/profile
zeta /home/jlpoole #

 emerge  app-emulation/xen 

make[7]: *** [GNUmakefile:382: /mnt/extra/portagetemp/portage/app-emulation/xen-tools-4.12.0_rc4/work/xen-4.12.0-rc4/tools/firmware/ovmf-dir-remote/Build/OvmfX64/DEBUG_GCC5/X64/MdeModulePkg/Library/BootMaintenanceManagerUiLib/BootMaintenanceManagerUiLib/DEBUG/BootMaintenanceManager.c] Error 2

...
>>> Failed to emerge app-emulation/xen-tools-4.12.0_rc4, Log file:

>>>  '/var/log/portage/app-emulation:xen-tools-4.12.0_rc4:20190314-164547.log'

 * Messages for package app-emulation/xen-4.12.0_rc4:
 * Log file: /var/log/portage/app-emulation:xen-4.12.0_rc4:20190314-164544.log

 * To avoid automounting and auto(un)installing with /boot,
 * just export the DONT_MOUNT_BOOT variable.

 * Messages for package app-emulation/xen-tools-4.12.0_rc4:
 * Log file: /var/log/portage/app-emulation:xen-tools-4.12.0_rc4:20190314-164547.log

 * ERROR: app-emulation/xen-tools-4.12.0_rc4::gentoo failed (compile phase):
 *   emake failed
 *
 * If you need support, post the output of `emerge --info '=app-emulation/xen-tools-4.12.0_rc4::gentoo'`,
 * the complete build log and the output of `emerge -pqv '=app-emulation/xen-tools-4.12.0_rc4::gentoo'`.
 * The complete build log is located at '/var/log/portage/app-emulation:xen-tools-4.12.0_rc4:20190314-164547.log'.
 * For convenience, a symlink to the build log is located at '/mnt/extra/portagetemp/portage/app-emulation/xen-tools-4.12.0_rc4/temp/build.log'.
 * The ebuild environment file is located at '/mnt/extra/portagetemp/portage/app-emulation/xen-tools-4.12.0_rc4/temp/environment'.
 * Working directory: '/mnt/extra/portagetemp/portage/app-emulation/xen-tools-4.12.0_rc4/work/xen-4.12.0-rc4'
 * S: '/mnt/extra/portagetemp/portage/app-emulation/xen-tools-4.12.0_rc4/work/xen-4.12.0-rc4'
zeta / # eselect gcc list
 [1] x86_64-pc-linux-gnu-7.3.0
 [2] x86_64-pc-linux-gnu-8.2.0 *
zeta / #

=========  2nd attempt to build using same USE variables as Tomáš Mózes =======


build.py...
 : error 7000: Failed to execute command
        make tbuild [/mnt/extra/portagetemp/portage/app-emulation/xen-tools-4.12.0_rc4/work/xen-4.12.0-rc4/tools/firmware/ovmf-dir-remote/Build/OvmfX64/DEBUG_GCC5/X64/MdeModulePkg/Library/BootMaintenanceManagerUiLib/BootMaintenanceManagerUiLib]


build.py...
 : error F002: Failed to build module
        /mnt/extra/portagetemp/portage/app-emulation/xen-tools-4.12.0_rc4/work/xen-4.12.0-rc4/tools/firmware/ovmf-dir-remote/MdeModulePkg/Library/BootMaintenanceManagerUiLib/BootMaintenanceManagerUiLib.inf [X64, GCC5, DEBUG]

- Failed -
Build end time: 10:09:04, Mar.14 2019
Build total time: 00:01:14

make[6]: *** [Makefile:20: build] Error 1
make[6]: Leaving directory '/mnt/extra/portagetemp/portage/app-emulation/xen-tools-4.12.0_rc4/work/xen-4.12.0-rc4/tools/firmware/ovmf-dir-remote'
make[5]: *** [/mnt/extra/portagetemp/portage/app-emulation/xen-tools-4.12.0_rc4/work/xen-4.12.0-rc4/tools/firmware/../../tools/Rules.mk:251: subdir-all-ovmf-dir] Error 2
make[5]: Leaving directory '/mnt/extra/portagetemp/portage/app-emulation/xen-tools-4.12.0_rc4/work/xen-4.12.0-rc4/tools/firmware'
make[4]: *** [/mnt/extra/portagetemp/portage/app-emulation/xen-tools-4.12.0_rc4/work/xen-4.12.0-rc4/tools/firmware/../../tools/Rules.mk:246: subdirs-all] Error 2
make[4]: Leaving directory '/mnt/extra/portagetemp/portage/app-emulation/xen-tools-4.12.0_rc4/work/xen-4.12.0-rc4/tools/firmware'
make[3]: *** [Makefile:40: all] Error 2
make[3]: Leaving directory '/mnt/extra/portagetemp/portage/app-emulation/xen-tools-4.12.0_rc4/work/xen-4.12.0-rc4/tools/firmware'
make[2]: *** [/mnt/extra/portagetemp/portage/app-emulation/xen-tools-4.12.0_rc4/work/xen-4.12.0-rc4/tools/../tools/Rules.mk:251: subdir-all-firmware] Error 2
make[2]: Leaving directory '/mnt/extra/portagetemp/portage/app-emulation/xen-tools-4.12.0_rc4/work/xen-4.12.0-rc4/tools'
make[1]: *** [/mnt/extra/portagetemp/portage/app-emulation/xen-tools-4.12.0_rc4/work/xen-4.12.0-rc4/tools/../tools/Rules.mk:246: subdirs-all] Error 2
make[1]: Leaving directory '/mnt/extra/portagetemp/portage/app-emulation/xen-tools-4.12.0_rc4/work/xen-4.12.0-rc4/tools'
make: *** [Makefile:59: build-tools] Error 2
 * ERROR: app-emulation/xen-tools-4.12.0_rc4::gentoo failed (compile phase):
 *   emake failed
Comment 13 John L. Poole 2019-03-14 17:23:29 UTC
line 382 of GNUmakefile in directory  /mnt/extra/portagetemp/portage/app-emulation/xen-tools-4.12.0_rc4/work/xen-4.12.0-rc4/tools/firmware/ovmf-dir-remote/Build/OvmfX64/DEBUG_GCC5/X64/MdeModulePkg/Library/BootManagerUiLib/BootManagerUiLib :

$(DEBUG_DIR)/BootManagerVfr.c : $(WORKSPACE)/MdePkg/Include/Protocol/DebugSupport.h

DebugSupport.h is present:
zeta /mnt/extra/portagetemp/portage/app-emulation/xen-tools-4.12.0_rc4/work # find . -name DebugSupport.h
./xen-4.12.0-rc4/tools/firmware/ovmf-dir-remote/EdkCompatibilityPkg/Foundation/Efi/Protocol/DebugSupport/DebugSupport.h
./xen-4.12.0-rc4/tools/firmware/ovmf-dir-remote/MdeModulePkg/Universal/DebugSupportDxe/Ia32/DebugSupport.h
./xen-4.12.0-rc4/tools/firmware/ovmf-dir-remote/MdePkg/Include/Protocol/DebugSupport.h
zeta /mnt/extra/portagetemp/portage/app-emulation/xen-tools-4.12.0_rc4/work #

and BootManagerVfr.c is present:
zeta /mnt/extra/portagetemp/portage/app-emulation/xen-tools-4.12.0_rc4/work # ls -la /mnt/extra/portagetemp/portage/app-emulation/xen-tools-4.12.0_rc4/work/xen-4.12.0-rc4/tools/firmware/ovmf-dir-remote/Build/OvmfX64/DEBUG_GCC5/X64/MdeModulePkg/Library/BootManagerUiLib/BootManagerUiLib/DEBUG
total 44
drwxr-xr-x 2 portage portage 4096 Mar 14 10:09 .
drwxr-xr-x 4 portage portage 4096 Mar 14 10:18 ..
-rw-r--r-- 1 portage portage 8452 Mar 14 10:08 AutoGen.c
-rw-r--r-- 1 portage portage 5495 Mar 14 10:08 AutoGen.h
-rw-r--r-- 1 portage portage 1867 Mar 14 10:08 BootManagerUiLibStrDefs.h
-rw-r--r-- 1 portage portage 1495 Mar 14 10:09 BootManagerVfr.c
-rw-r--r-- 1 portage portage 4335 Mar 14 10:09 BootManagerVfr.lst
zeta /mnt/extra/portagetemp/portage/app-emulation/xen-tools-4.12.0_rc4/work #
Comment 14 Tomáš Mózes 2019-03-15 03:32:01 UTC
Does it build when you disable ovmf?
Comment 15 John L. Poole 2019-03-15 04:02:00 UTC
(In reply to Tomáš Mózes from comment #14)
> Does it build when you disable ovmf?

Answer: Yes - app-emulation/xen-tools successfully builds.  app-emulation/xen builds, too.

Here's what I did:

1) USE=-ovmf  emerge  app-emulation/xen

So, equery tells me:

 + - ovmf                     : Enable support to boot UEFI guest vm, needed by
                                hvm

I'm wondering if I need support for booting a UEFI guest?  If the DOM0 is on EUFI, do all guests have to be supported, as well?

I'll try and boot on this newly built Xen kernel and see what happens or explodes.
Comment 16 John L. Poole 2019-03-15 04:16:28 UTC
I am able to launch the two VMs that are critical for me.

I do not plan to launch Windows on this server, so is the ovmf unnecessary?  I'm thinking if I can successfully boot the Gentoo VMs (and log into them), I'm in a good place?
Comment 17 John L. Poole 2019-03-15 04:44:41 UTC
I was able to successfully boot 2 times, then I ran into the problems I am encountering in Bug #679826.  Two attempts at booting have ended in hanging at this stage:

(XEN) [2019-03-15 04:36:49] mwait-idle: MWAIT substates: 0x3000020
(XEN) [2019-03-15 04:36:49] mwait-idle: v0.4.1 model 0x4d
(XEN) [2019-03-15 04:36:49] mwait-idle: lapic_timer_reliable_states 0xffffffff
(XEN) [2019-03-15 04:36:49] VMX: Supported advanced features:
(XEN) [2019-03-15 04:36:49]  - APIC MMIO access virtualisation
(XEN) [2019-03-15 04:36:49]  - APIC TPR shadow
(XEN) [2019-03-15 04:36:49]  - Extended Page Tables (EPT)
(XEN) [2019-03-15 04:36:49]  - Virtual-Processor Identifiers (VPID)
(XEN) [2019-03-15 04:36:49]  - Virtual NMI
(XEN) [2019-03-15 04:36:49]  - MSR direct-access bitmap
(XEN) [2019-03-15 04:36:49]  - Unrestricted Guest
(XEN) [2019-03-15 04:36:49]  - VM Functions
(XEN) [2019-03-15 04:36:49] HVM: ASIDs enabled.
(XEN) [2019-03-15 04:36:49] HVM: VMX enabled
(XEN) [2019-03-15 04:36:49] HVM: Hardware Assisted Paging (HAP) detected
(XEN) [2019-03-15 04:36:49] HVM: HAP page sizes: 4kB, 2MB
(XEN) [2019-03-15 04:36:45] masked ExtINT on CPU#1
(XEN) [2019-03-15 04:36:49] Adding cpu 1 to runqueue 0
(XEN) [2019-03-15 04:36:45] masked ExtINT on CPU#2
(XEN) [2019-03-15 04:36:49] Adding cpu 2 to runqueue 0
(XEN) [2019-03-15 04:36:45] masked ExtINT on CPU#3
(XEN) [2019-03-15 04:36:49] Adding cpu 3 to runqueue 0
(XEN) [2019-03-15 04:36:45] masked ExtINT on CPU#4
(XEN) [2019-03-15 04:36:49] Adding cpu 4 to runqueue 0
(XEN) [2019-03-15 04:36:45] masked ExtINT on CPU#5
(XEN) [2019-03-15 04:36:49] Adding cpu 5 to runqueue 0


But, this bug was for the compiling of 4.12.0_rc4.  I think we can conclude that the removal of ovmf flag provides a work-around.  Perhaps I should open a new bug based on this 4.12.0_rc4 kernal about my boot-up problem?

I had sent an email on 3/12/2019, 9:30 PM to xen@gentoo.org asking among other things:

On 3/11/2019 Juergen Gross announced  xen.git 4.12.0-rc5.  Will the Xen Team be deploying a build of rc5?  Does the team follow every release candidate build? 

I have not received a response.  I probably have 40+ hours into the problems of Xen on this Supermicro server, so I'd like to use my time efficiently and wonder if 4.12.0_rc5 is going to have a package and whether I should focus my boot problem of handing at the ExtINT point on the latest and greatest code so it might be of greater interest up stream to the Xen team.

Thank you for the work-around on this and I look forward to learning more about the significance of the "ovmf" flag and determining whether I need it.
Comment 18 Tomáš Mózes 2019-03-15 07:04:13 UTC
(In reply to John L. Poole from comment #15)
> I'm wondering if I need support for booting a UEFI guest?  If the DOM0 is on
> EUFI, do all guests have to be supported, as well?

I try to avoid efi where possible and i don't have ovmf enabled. I suppose it's only needed for the domU, since these are the tools, not xen itself.
Comment 19 Tomáš Mózes 2019-03-15 07:07:39 UTC
(In reply to John L. Poole from comment #17)
> But, this bug was for the compiling of 4.12.0_rc4.  I think we can conclude
> that the removal of ovmf flag provides a work-around.  Perhaps I should open
> a new bug based on this 4.12.0_rc4 kernal about my boot-up problem?

This seems a xen issue, i'll adjust the bug subject to include it only applies to USE=ovmf. However i don't know how to reproduce it.

> 
> I had sent an email on 3/12/2019, 9:30 PM to xen@gentoo.org asking among
> other things:
> 
> On 3/11/2019 Juergen Gross announced  xen.git 4.12.0-rc5.  Will the Xen Team
> be deploying a build of rc5?  Does the team follow every release candidate
> build? 

It's here: https://github.com/gentoo/gentoo/pull/11361
Comment 20 Tomáš Mózes 2019-03-15 07:08:56 UTC
So xen-tools-4.11 works with USE=ovmf, but 4.12 does not, is that correct? It may be related to https://bugs.gentoo.org/680284.
Comment 21 Tomáš Mózes 2019-04-04 09:05:46 UTC
Can you please try the latest 4.12.0 with USE=ovmf? It was updated to a later snapshot:

https://github.com/gentoo/gentoo/commit/0887e98f46b36f78df9ef8b2c827455ad86f7800
Comment 22 John L. Poole 2019-04-04 13:06:15 UTC
I set /etc/portage/package.keywords/xen to:

zeta /home/jlpoole # tail /etc/portage/package.keywords/xen
# jlpoole 3/4/2019 reverting to stable to test if that works
#=app-emulation/xen-4.12.0_rc4 **
#=app-emulation/xen-tools-4.12.0_rc4 **
#
# 4/4/2019 jlpoole:  trying  4.12.0
# per Bug https://bugs.gentoo.org/679824
#
=app-emulation/xen-4.12.0
=app-emulation/xen-tools-4.12.0

zeta /home/jlpoole #


and successfully built 4.12.0.

I then tried using the Xen Source EFI 4.13 unstable to launch the Gentoo 4.12.0 kernel from the EFI console and the boot hung at the usual place:
Log (30 days only) at: 
https://pastebin.com/fd0v5T5D

I then tried using the Gentoo EFI created in /usr/lib/efi and the boot also hung in the usual place.  
Log (30 days only) at:
https://pastebin.com/EpTnXzfW
Comment 23 John L. Poole 2019-04-04 13:10:52 UTC
Interesting, xen-tools doesn't seem to have a log file saved:

zeta /home/jlpoole #  ls -la /var/tmp/portage/portage/app-emulation/
total 40
drwxrwxr-x 10 portage portage 4096 Apr  4 05:42 .
drwxrwxr-x  4 portage portage 4096 Apr  4 05:42 ..
drwxr-xr-x  3 portage portage 4096 Mar  4 10:16 xen-4.10.2-r2
drwxr-xr-x  3 portage portage 4096 Dec  8 16:58 xen-4.11.0-r4
drwxr-xr-x  3 portage portage 4096 Mar  6 19:36 xen-4.11.1
drwxr-xr-x  7 portage portage 4096 Mar 12 11:16 xen-4.11.1-r1
drwxr-xr-x  3 portage portage 4096 Apr  4 05:42 xen-4.12.0
drwxr-xr-x  7 portage portage 4096 Mar 16 20:02 xen-4.12.0_rc4
drwxr-xr-x  4 portage portage 4096 Mar  3 20:23 xen-tools-4.12.0_rc2
drwxr-xr-x  6 portage portage 4096 Mar 13 06:09 xen-tools-4.12.0_rc5
zeta /home/jlpoole # eix xen-tools
[I] app-emulation/xen-tools
     Available versions:  4.10.3-r2(0/4.10)^t ~4.11.1-r3(0/4.11)^t **4.12.0_rc5(0/4.12)^t[1] (~)4.12.0(0/4.12)^t {api custom-cflags debug doc flask hvm ocaml ovmf +pam pygrub python +qemu +qemu-traditional screen sdl static-libs system-qemu system-seabios PYTHON_TARGETS="python2_7"}
     Installed versions:  4.12.0(0/4.12)^t(05:39:15 AM 04/04/2019)(flask hvm ovmf pam pygrub python qemu qemu-traditional screen sdl -api -custom-cflags -debug -doc -ocaml -static-libs -system-qemu -system-seabios PYTHON_TARGETS="python2_7")
     Homepage:            https://www.xenproject.org
     Description:         Xen tools including QEMU and xl

[1] "localrepo" /usr/local/portage
zeta /home/jlpoole #
Comment 24 Tomáš Mózes 2019-04-04 14:03:06 UTC
Thanks for testing, that means this bug can be closed. The other bug with your cpus being masked is still open.

Thanks for testing and letting me know.