Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 851705 - media-libs/embree-3.13.3 failed to emerge on arm64 (CMake Error at CMakeLists.txt:459 (MESSAGE): You have to enable at least one ISA!)
Summary: media-libs/embree-3.13.3 failed to emerge on arm64 (CMake Error at CMakeLists...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: ARM64 Linux
: Normal normal (vote)
Assignee: Sebastian Parborg
URL:
Whiteboard:
Keywords: PullRequest
Depends on:
Blocks:
 
Reported: 2022-06-13 13:19 UTC by Leonid Kopylov
Modified: 2023-05-09 17:51 UTC (History)
1 user (show)

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


Attachments
build.log (build.log,5.00 KB, text/plain)
2022-06-13 13:20 UTC, Leonid Kopylov
Details
build.log (build.log,4.60 KB, text/plain)
2023-05-05 13:25 UTC, Leonid Kopylov
Details
build.log (build.log,14.28 KB, text/plain)
2023-05-05 13:51 UTC, Leonid Kopylov
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Leonid Kopylov 2022-06-13 13:19:45 UTC
# emerge -pqv '=media-libs/embree-3.13.3::gentoo'
[ebuild  N    ] media-libs/embree-3.13.3  USE="compact-polys raymask tbb tutorial -ispc -ssp" CPU_FLAGS_ARM="(-neon)"

# emerge --info '=media-libs/embree-3.13.3::gentoo'
Portage 3.0.30 (python 3.9.13-final-0, default/linux/arm64/17.0/desktop/gnome/systemd, gcc-11.3.0, glibc-2.35-r7, 5.18.3-gentoo-arm64 aarch64)
=================================================================
                         System Settings
=================================================================
System uname: Linux-5.18.3-gentoo-arm64-aarch64-with-glibc2.35
KiB Mem:    16350188 total,  10019796 free
KiB Swap:    8388604 total,   8371452 free
Timestamp of repository gentoo: Mon, 13 Jun 2022 11:30:01 +0000
Head commit of repository gentoo: 63fee1bfbad880001446a6a18073cb1da826d780
sh bash 5.1_p16
ld GNU ld (Gentoo 2.37_p1 p2) 2.37
app-misc/pax-utils:        1.3.4::gentoo
app-shells/bash:           5.1_p16::gentoo
dev-java/java-config:      2.3.1::gentoo
dev-lang/perl:             5.36.0::gentoo
dev-lang/python:           3.9.13::gentoo, 3.10.5::gentoo, 3.11.0_beta3::gentoo
dev-lang/rust-bin:         1.61.0::gentoo
dev-util/cmake:            3.23.2::gentoo
dev-util/meson:            0.62.2::gentoo
sys-apps/baselayout:       2.8::gentoo
sys-apps/sandbox:          2.29::gentoo
sys-apps/systemd:          251.2::gentoo
sys-devel/autoconf:        2.13-r1::gentoo, 2.71-r1::gentoo
sys-devel/automake:        1.16.5::gentoo
sys-devel/binutils:        2.37_p1-r2::gentoo, 2.38-r2::gentoo
sys-devel/binutils-config: 5.4.1::gentoo
sys-devel/clang:           14.0.5::gentoo
sys-devel/gcc:             11.3.0::gentoo
sys-devel/gcc-config:      2.5-r1::gentoo
sys-devel/libtool:         2.4.7::gentoo
sys-devel/lld:             14.0.5::gentoo
sys-devel/llvm:            13.0.1::gentoo, 14.0.5::gentoo
sys-devel/make:            4.3::gentoo
sys-kernel/linux-headers:  5.18-r1::gentoo (virtual/os-headers)
sys-libs/glibc:            2.35-r7::gentoo
Repositories:

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

guru
    location: /var/lib/layman/guru
    sync-type: laymansync
    sync-uri: https://anongit.gentoo.org/git/repo/proj/guru.git
    masters: gentoo
    priority: 50

ACCEPT_KEYWORDS="arm64 ~arm64"
ACCEPT_LICENSE="* -@EULA AnyDesk-TOS geekbench TeamViewer Vivaldi"
CBUILD="aarch64-unknown-linux-gnu"
CFLAGS="-march=native -O2 -pipe"
CHOST="aarch64-unknown-linux-gnu"
CONFIG_PROTECT="/etc /usr/lib64/libreoffice/program/sofficerc /usr/share/config /usr/share/gnupg/qualified.txt"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/dconf /etc/env.d /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/php/apache2-php8.1/ext-active/ /etc/php/cgi-php8.1/ext-active/ /etc/php/cli-php8.1/ext-active/ /etc/php/fpm-php8.1/ext-active/ /etc/php/phpdbg-php8.1/ext-active/ /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo /etc/texmf/language.dat.d /etc/texmf/language.def.d /etc/texmf/updmap.d /etc/texmf/web2c"
CXXFLAGS="-march=native -O2 -pipe"
DISTDIR="/var/cache/distfiles"
ENV_UNSET="CARGO_HOME DBUS_SESSION_BUS_ADDRESS DISPLAY GOBIN GOPATH 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="-march=native -O2 -pipe"
FEATURES="assume-digests binpkg-docompress binpkg-dostrip binpkg-logs binpkg-multi-instance buildpkg-live config-protect-if-modified distlocks ebuild-locks fixlafiles ipc-sandbox merge-sync multilib-strict network-sandbox news parallel-fetch pid-sandbox preserve-libs protect-owned qa-unresolved-soname-deps sandbox sfperms strict unknown-features-warn unmerge-logs unmerge-orphans userfetch userpriv usersandbox usersync xattr"
FFLAGS="-march=native -O2 -pipe"
GENTOO_MIRRORS="https://mirror.isoc.org.il/pub/gentoo/"
LANG="en_US.utf8"
LDFLAGS="-Wl,-O1 -Wl,--as-needed"
MAKEOPTS="-j4"
PKGDIR="/var/cache/binpkgs"
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="/var/tmp"
SHELL="/bin/bash"
USE="X a52 aac aalib accessibility acl acpi alsa archive arm64 audit bash-completion berkdb bidi bluray branding brotli bzip2 cairo cdda cddb cdr cgi cli colord cracklib cron crypt cryptsetup cups curl dbi dbus designer device-mapper djvu doc dri dts dvb dvdr eds emacs encode evo examples exif expat experimental extras fam fbcon fftw flac fluidsynth fontconfig fortran ftp fuse game gamepad games gcrypt gd gdbm gdk-pixbuf geoip geolocation gif git glade gme gmp gnome gnome-keyring gnome-online-accounts gnutls go gpg gphoto2 gpm graphite graphviz gsm gssapi gstreamer gtk gtk-doc gtk3 gui guile harfbuzz hdf5 heif highlight html http http2 iconv icu idn imagemagick imlib introspection iodbc ipv6 jack java javascript jbig jemalloc joystick jpeg jpeg2k json kde kerberos latex lcms ldap libcaca libevent libglvnd libnotify libsecret libtirpc libxml2 lmdb lua lvm lz4 lzma lzo mad maildir man mbedtls mbox midi mng mp3 mp4 mpeg mtp musepack mysql nas nautilus ncurses netlink nettle network networkmanager nfs nls nptl nss ntlm odbc ogg openal openexr opengl openmp openssl opus pam pango pcap pcre pdf perl pkcs11 plasma plugins plymouth png policykit portaudio postgres postscript ppds pulseaudio python qdbm qml qrcode qt5 raw readline redis rss samba sasl savedconfig screencast sctp sdl seccomp session skey snappy sndfile sndio snmp sound source sox speech speex spell split-usr sql sqlite ssh ssl startup-notification svg symlink syslog systemd tcl theora threads tiff tk tools tracker tremor truetype twolame udev udisks unicode unwind upnp upower usb utils uuid v4l vala vim-syntax vnc vorbis vpx wavpack wayland webengine webkit webp widgets wmf wxwidgets x264 xattr xcb xface xinerama xml xmp xpm xscreensaver xv xvid yaml zeroconf zip zlib zsh-completion zstd" ADA_TARGET="gnat_2020" 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 stage words" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" CPU_FLAGS_ARM="edsp thumb thumb2 v4 v5 v6 v7 v8 vfp vfp-d32 vfpv3 vfpv4" CPU_FLAGS_X86="edsp neon thumb vfp vfpv3 vfpv4 vfp-d32 sha1 sha2 crc32 v4 v5 v6 v7 v8 thumb2" ELIBC="glibc" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock greis isync itrax mtk3301 nmea ntrip navcom oceanserver oldstyle oncore rtcm104v2 rtcm104v3 sirf skytraq superstar2 timing tsip tripmate tnt ublox ubx" GRUB_PLATFORMS="efi-64" INPUT_DEVICES="evdev" KERNEL="linux" L10N="en en-US he ru" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LIBREOFFICE_EXTENSIONS="nlpsolver" LUA_SINGLE_TARGET="lua5-1" LUA_TARGETS="lua5-1" OFFICE_IMPLEMENTATION="libreoffice" PHP_TARGETS="php7-4 php8-0" POSTGRES_TARGETS="postgres12 postgres13" PYTHON_SINGLE_TARGET="python3_9" PYTHON_TARGETS="python3_9" RUBY_TARGETS="ruby26 ruby27 ruby30 ruby31" USERLAND="GNU" VIDEO_CARDS="virgl" XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipset ipp2p iface geoip fuzzy condition tee tarpit sysrq proto steal rawnat logmark ipmark dhcpmac delude chaos account"
Unset:  ADDR2LINE, AR, ARFLAGS, AS, ASFLAGS, CC, CCLD, CONFIG_SHELL, CPP, CPPFLAGS, CTARGET, CXX, CXXFILT, ELFEDIT, EMERGE_DEFAULT_OPTS, EXTRA_ECONF, F77FLAGS, FC, GCOV, GPROF, INSTALL_MASK, LC_ALL, LD, LEX, LFLAGS, LIBTOOL, LINGUAS, MAKE, MAKEFLAGS, NM, OBJCOPY, OBJDUMP, PORTAGE_BINHOST, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS, RANLIB, READELF, RUSTFLAGS, SIZE, STRINGS, STRIP, YACC, YFLAGS
Comment 1 Leonid Kopylov 2022-06-13 13:20:10 UTC
Created attachment 784619 [details]
build.log
Comment 2 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2022-06-16 15:57:50 UTC
CMake Error at CMakeLists.txt:459 (MESSAGE):
  You have to enable at least one ISA!
Comment 3 Leonid Kopylov 2023-05-05 11:38:08 UTC
still issue with media-libs/embree-3.13.5
Comment 4 Sebastian Parborg 2023-05-05 12:52:42 UTC
I've done some research and it seems like both embree and openpgl needs ARM NEON to be able to be built. (So they can emulate SSE and AVX instructions)

I don't have a ARM CPU, so I can't test. But from my understanding you should be able to use the same approach as in the ffmpeg with the `cpu_flags_arm_neon` flag usage.

Can you edit the ebuild and add support for this flag and see if it works?
Comment 5 Leonid Kopylov 2023-05-05 12:59:53 UTC
(In reply to Sebastian Parborg from comment #4)
> I've done some research and it seems like both embree and openpgl needs ARM
> NEON to be able to be built. (So they can emulate SSE and AVX instructions)
> 
> I don't have a ARM CPU, so I can't test. But from my understanding you
> should be able to use the same approach as in the ffmpeg with the
> `cpu_flags_arm_neon` flag usage.
> 
> Can you edit the ebuild and add support for this flag and see if it works?

can you, please, guide me, how to do it?
Comment 6 Sebastian Parborg 2023-05-05 13:16:56 UTC
Actually, seems like you have configured your make.conf incorrectly?

You have put the "neon" flag under "CPU_FLAGS_X86" instead of "CPU_FLAGS_ARM".

Can you try to add "neon" to your arm flags and see if that works?
Comment 7 Leonid Kopylov 2023-05-05 13:18:46 UTC
(In reply to Sebastian Parborg from comment #6)
> Actually, seems like you have configured your make.conf incorrectly?
> 
> You have put the "neon" flag under "CPU_FLAGS_X86" instead of
> "CPU_FLAGS_ARM".
> 
> Can you try to add "neon" to your arm flags and see if that works?

this is from my make.conf:
CPU_FLAGS_ARM="edsp neon thumb vfp vfpv3 vfpv4 vfp-d32 aes sha1 sha2 crc32 v4 v5 v6 v7 v8 thumb2"


generated by:
# cpuid2cpuflags
CPU_FLAGS_ARM: edsp neon thumb vfp vfpv3 vfpv4 vfp-d32 aes sha1 sha2 crc32 v4 v5 v6 v7 v8 thumb2
Comment 8 Sebastian Parborg 2023-05-05 13:23:35 UTC
Ok, so the "emerge --info" you posted last year is out of date?
There the neon flag is in the X86 flags, not the ARM one.
Comment 9 Leonid Kopylov 2023-05-05 13:25:25 UTC
# emerge -pqv '=media-libs/embree-3.13.5::gentoo'
[ebuild  N    ] media-libs/embree-3.13.5  USE="compact-polys raymask ssp tbb -ispc -tutorial" CPU_FLAGS_ARM="(-neon)"

# emerge --info '=media-libs/embree-3.13.5::gentoo'
Portage 3.0.47 (python 3.11.3-final-0, default/linux/arm64/17.0/desktop/gnome/systemd/merged-usr, gcc-13, glibc-2.37-r2, 6.3.1-gentoo-arm64 aarch64)
=================================================================
                         System Settings
=================================================================
System uname: Linux-6.3.1-gentoo-arm64-aarch64-with-glibc2.37
KiB Mem:    32817680 total,  15037632 free
KiB Swap:    8388604 total,   8388604 free
Timestamp of repository gentoo: Fri, 05 May 2023 09:00:01 +0000
Head commit of repository gentoo: 460a8f68d767b8a634aed94cd7478e384b456f1c
sh bash 5.2_p15-r2
ld GNU ld (Gentoo 2.40 p4) 2.40.0
ccache version 4.8 [disabled]
app-misc/pax-utils:        1.3.7::gentoo
app-shells/bash:           5.2_p15-r2::gentoo
dev-java/java-config:      2.3.1::gentoo
dev-lang/perl:             5.36.1-r1::gentoo
dev-lang/python:           3.10.11::gentoo, 3.11.3::gentoo, 3.12.0_alpha7::gentoo
dev-lang/rust:             1.69.0-r1::gentoo
dev-util/ccache:           4.8::gentoo
dev-util/cmake:            3.26.3::gentoo
dev-util/meson:            1.1.0::gentoo
sys-apps/baselayout:       2.13-r1::gentoo
sys-apps/sandbox:          2.30-r1::gentoo
sys-apps/systemd:          253.4::gentoo
sys-devel/autoconf:        2.13-r8::gentoo, 2.71-r6::gentoo
sys-devel/automake:        1.16.5-r1::gentoo
sys-devel/binutils:        2.40-r4::gentoo
sys-devel/binutils-config: 5.5::gentoo
sys-devel/clang:           14.0.6-r1::gentoo, 15.0.7-r1::gentoo, 16.0.3::gentoo
sys-devel/gcc:             12.2.1_p20230428-r1::gentoo, 13.1.0-r1::gentoo
sys-devel/gcc-config:      2.10::gentoo
sys-devel/libtool:         2.4.7-r1::gentoo
sys-devel/llvm:            14.0.6-r2::gentoo, 15.0.7::gentoo, 16.0.3::gentoo
sys-devel/make:            4.4.1::gentoo
sys-kernel/linux-headers:  6.3::gentoo (virtual/os-headers)
sys-libs/glibc:            2.37-r2::gentoo
Repositories:

gentoo
    location: /var/db/repos/gentoo
    sync-type: rsync
    sync-uri: rsync://server.kopylovs.net/gentoo-portage
    priority: -1000
    volatile: False
    sync-rsync-verify-metamanifest: yes
    sync-rsync-extra-opts:
    sync-rsync-verify-jobs: 1
    sync-rsync-verify-max-age: 24

HomeAssistantRepository
    location: /var/lib/layman/HomeAssistantRepository
    sync-type: laymansync
    sync-uri: https://git.edevau.net/onkelbeh/HomeAssistantRepository.git
    masters: gentoo
    priority: 50
    volatile: True

guru
    location: /var/lib/layman/guru
    sync-type: laymansync
    sync-uri: https://anongit.gentoo.org/git/repo/proj/guru.git
    masters: gentoo
    priority: 50
    volatile: True

kde
    location: /var/lib/layman/kde
    sync-type: laymansync
    sync-uri: https://anongit.gentoo.org/git/proj/kde.git
    masters: gentoo
    priority: 50
    volatile: True

ACCEPT_KEYWORDS="arm64 ~arm64"
ACCEPT_LICENSE="* -@EULA android AnyDesk-TOS geekbench Microsoft-vscode TeamViewer Vivaldi"
CBUILD="aarch64-unknown-linux-gnu"
CFLAGS="-march=armv8-a+crc+lse+rcpc+rdma+dotprod+aes+fp16fml+sb+ssbs+flagm+pauth -O2 -pipe -fomit-frame-pointer"
CHOST="aarch64-unknown-linux-gnu"
CONFIG_PROTECT="/etc /usr/lib64/libreoffice/program/sofficerc /usr/share/config /usr/share/gnupg/qualified.txt"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/dconf /etc/env.d /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/php/apache2-php7.4/ext-active/ /etc/php/apache2-php8.0/ext-active/ /etc/php/apache2-php8.2/ext-active/ /etc/php/cgi-php7.4/ext-active/ /etc/php/cgi-php8.0/ext-active/ /etc/php/cgi-php8.2/ext-active/ /etc/php/cli-php7.4/ext-active/ /etc/php/cli-php8.0/ext-active/ /etc/php/cli-php8.2/ext-active/ /etc/php/fpm-php7.4/ext-active/ /etc/php/fpm-php8.0/ext-active/ /etc/php/fpm-php8.2/ext-active/ /etc/php/phpdbg-php7.4/ext-active/ /etc/php/phpdbg-php8.0/ext-active/ /etc/php/phpdbg-php8.2/ext-active/ /etc/revdep-rebuild /etc/sandbox.d /etc/texmf/language.dat.d /etc/texmf/language.def.d /etc/texmf/updmap.d /etc/texmf/web2c"
CXXFLAGS="-march=armv8-a+crc+lse+rcpc+rdma+dotprod+aes+fp16fml+sb+ssbs+flagm+pauth -O2 -pipe -fomit-frame-pointer"
DISTDIR="/var/cache/distfiles"
ENV_UNSET="CARGO_HOME DBUS_SESSION_BUS_ADDRESS DISPLAY GDK_PIXBUF_MODULE_FILE GOBIN GOPATH PERL5LIB PERL5OPT PERLPREFIX PERL_CORE PERL_MB_OPT PERL_MM_OPT XAUTHORITY XDG_CACHE_HOME XDG_CONFIG_HOME XDG_DATA_HOME XDG_RUNTIME_DIR XDG_STATE_HOME"
FCFLAGS="-march=armv8-a+crc+lse+rcpc+rdma+dotprod+aes+fp16fml+sb+ssbs+flagm+pauth -O2 -pipe -fomit-frame-pointer"
FEATURES="assume-digests binpkg-docompress binpkg-dostrip binpkg-logs binpkg-multi-instance buildpkg-live config-protect-if-modified distlocks ebuild-locks fixlafiles ipc-sandbox merge-sync multilib-strict network-sandbox news parallel-fetch pid-sandbox preserve-libs protect-owned qa-unresolved-soname-deps sandbox sfperms strict strict-keepdir unknown-features-warn unmerge-logs unmerge-orphans userfetch userpriv usersandbox usersync warn-on-large-env xattr"
FFLAGS="-march=armv8-a+crc+lse+rcpc+rdma+dotprod+aes+fp16fml+sb+ssbs+flagm+pauth -O2 -pipe -fomit-frame-pointer"
GENTOO_MIRRORS="https://mirror.isoc.org.il/pub/gentoo/"
LANG="en_US.utf8"
LC_ALL="en_US.UTF-8"
LDFLAGS="-Wl,-O1 -Wl,--as-needed"
LEX="flex"
MAKEOPTS="-j6"
PKGDIR="/var/cache/binpkgs"
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="/var/tmp"
SHELL="/bin/bash"
USE="X a52 aac aalib accessibility acl acpi activities alsa ao appindicator archive arm64 aspell audit bash-completion berkdb bidi bluetooth bluray boost branding brotli btrfs bzip2 cairo cdda cddb cdio cdr cgi cli colord contrib cron crypt cryptsetup cups curl dbi dbus designer device-mapper djvu doc dri dts dv dvb dvdr eds emacs enchant encode evdev evo examples executable exif expat experimental extra extras fam fastcgi fbcon ffmpeg fftw flac fluidsynth fontconfig fontforge fortran freetds ftp fuse gamepad games gcrypt gd gdbm gdk-pixbuf geoip geolocation gif git glade glib glusterfs gme gmp gnome gnome-keyring gnome-online-accounts gnuplot gnutls go gpg gphoto2 gpm graphite graphviz gsm gssapi gstreamer gtk gtk-doc gtk3 gui guile harfbuzz hdf5 heif highlight hscolour html http http2 ibus iconv icu idn imagemagick imap imlib introspection iodbc ipv6 jack java javascript jbig jemalloc joystick jpeg jpeg2k jpegxl json kde kerberos ladspa lame latex lcms ldap libass libcaca libevent libglvnd libnotify libsamplerate libsecret libtirpc libxml2 lmdb lua lv2 lvm lz4 lzma lzo mad magic maildir man mbedtls mbox memcached midi mmap mng modplug mp3 mp4 mpeg mplayer mtp multimedia musepack mysql nas nautilus ncurses netlink nettle network networkmanager nfs nls nptl nss ntlm odbc offensive ogg openal openexr opengl openmp openssl opus pam pango pcap pcre pdf perl phonon pkcs11 plasma plugins png policykit portaudio postgres postscript ppds pulseaudio python qdbm qml qrcode qt5 raw rdma readline redis rss samba sasl screencast sctp sdl seccomp semantic-desktop sftp share skey smp smtp snappy sndfile sndio snmp sound source sox speech speex spell sql sqlite ssh ssl startup-notification svg symlink syslog systemd taglib tbb tcl tcpd telemetry telepathy test-rust theora threads tiff tk tools tracker tremor truetype twolame udev udisks unicode unwind upnp upower usb utils uuid v4l vala vcd vim-syntax vnc vorbis vpx wavpack wayland webengine webkit webp websockets widgets wmf wxwidgets x264 x265 xattr xcb xface xft xinerama xml xmp xpm xscreensaver xv xvid yaml zeroconf zip zlib zsh-completion zstd" ADA_TARGET="gnat_2021" 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 stage" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" CPU_FLAGS_ARM="edsp thumb vfp vfpv3 vfpv4 vfp-d32 aes sha1 sha2 crc32 v4 v5 v6 v7 v8 thumb2" ELIBC="glibc" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock greis isync itrax mtk3301 nmea ntrip navcom oceanserver oldstyle oncore rtcm104v2 rtcm104v3 sirf skytraq superstar2 timing tsip tripmate tnt ublox ubx" GRUB_PLATFORMS="efi-64" INPUT_DEVICES="evdev joystick libinput" KERNEL="linux" L10N="en en-US he ru" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LIBREOFFICE_EXTENSIONS="nlpsolver" LUA_SINGLE_TARGET="lua5-1" LUA_TARGETS="lua5-1" OFFICE_IMPLEMENTATION="libreoffice" PHP_TARGETS="php7-4 php8-0" POSTGRES_TARGETS="postgres12 postgres13" PYTHON_SINGLE_TARGET="python3_11" PYTHON_TARGETS="python3_11 python3_10" RUBY_TARGETS="ruby30 ruby31 ruby32" USERLAND="GNU" VIDEO_CARDS="virgl" XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipset ipp2p iface geoip fuzzy condition tee tarpit sysrq proto steal rawnat logmark ipmark dhcpmac delude chaos account"
Unset:  ADDR2LINE, AR, ARFLAGS, AS, ASFLAGS, CC, CCLD, CONFIG_SHELL, CPP, CPPFLAGS, CTARGET, CXX, CXXFILT, ELFEDIT, EMERGE_DEFAULT_OPTS, EXTRA_ECONF, F77FLAGS, FC, GCOV, GPROF, INSTALL_MASK, LD, LFLAGS, LIBTOOL, LINGUAS, MAKE, MAKEFLAGS, NM, OBJCOPY, OBJDUMP, PORTAGE_BINHOST, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS, RANLIB, READELF, RUSTFLAGS, SIZE, STRINGS, STRIP, YACC, YFLAGS
Comment 10 Leonid Kopylov 2023-05-05 13:25:35 UTC
Created attachment 861191 [details]
build.log
Comment 11 Sebastian Parborg 2023-05-05 13:28:32 UTC
Hmm, now it is missing competely from your emerge info output... :S

Does `USE="cpu_flags_arm_neon" emerge -av embree` show that the neon flag is turned on? I'm guessing that it might be masked by something.
Comment 12 Leonid Kopylov 2023-05-05 13:29:45 UTC
(In reply to Sebastian Parborg from comment #11)
> Hmm, now it is missing competely from your emerge info output... :S
> 
> Does `USE="cpu_flags_arm_neon" emerge -av embree` show that the neon flag is
> turned on? I'm guessing that it might be masked by something.

# USE="cpu_flags_arm_neon" emerge -pvq embree
[ebuild  N    ] media-libs/embree-3.13.5  USE="compact-polys raymask ssp tbb -ispc -tutorial" CPU_FLAGS_ARM="(-neon)"
Comment 13 Leonid Kopylov 2023-05-05 13:38:36 UTC
maybe this related in '/var/db/repos/gentoo/profiles/arch/arm64/use.mask':

# Mask cpu_flags_arm_neon for all of arm64
# A neon64 USE is being discussed
cpu_flags_arm_neon
Comment 14 Sebastian Parborg 2023-05-05 13:43:46 UTC
Yepp, seems like the the default arm64 profile masks the neon useflag for everything besides ffmpeg.

Can you try to unmask the neon useflag?
https://wiki.gentoo.org/wiki//etc/portage/profile/use.mask
Comment 15 Leonid Kopylov 2023-05-05 13:51:39 UTC
# emerge -pqv '=media-libs/embree-3.13.5::gentoo'
[ebuild  N    ] media-libs/embree-3.13.5  USE="compact-polys raymask ssp tbb -ispc -tutorial" CPU_FLAGS_ARM="neon"


# emerge --info '=media-libs/embree-3.13.5::gentoo'
Portage 3.0.47 (python 3.11.3-final-0, default/linux/arm64/17.0/desktop/gnome/systemd/merged-usr, gcc-13, glibc-2.37-r2, 6.3.1-gentoo-arm64 aarch64)
=================================================================
                         System Settings
=================================================================
System uname: Linux-6.3.1-gentoo-arm64-aarch64-with-glibc2.37
KiB Mem:    32817680 total,   4712596 free
KiB Swap:    8388604 total,   8368124 free
Timestamp of repository gentoo: Fri, 05 May 2023 09:00:01 +0000
Head commit of repository gentoo: 460a8f68d767b8a634aed94cd7478e384b456f1c
sh bash 5.2_p15-r2
ld GNU ld (Gentoo 2.40 p4) 2.40.0
ccache version 4.8 [disabled]
app-misc/pax-utils:        1.3.7::gentoo
app-shells/bash:           5.2_p15-r2::gentoo
dev-java/java-config:      2.3.1::gentoo
dev-lang/perl:             5.36.1-r1::gentoo
dev-lang/python:           3.10.11::gentoo, 3.11.3::gentoo, 3.12.0_alpha7::gentoo
dev-lang/rust:             1.69.0-r1::gentoo
dev-util/ccache:           4.8::gentoo
dev-util/cmake:            3.26.3::gentoo
dev-util/meson:            1.1.0::gentoo
sys-apps/baselayout:       2.13-r1::gentoo
sys-apps/sandbox:          2.30-r1::gentoo
sys-apps/systemd:          253.4::gentoo
sys-devel/autoconf:        2.13-r8::gentoo, 2.71-r6::gentoo
sys-devel/automake:        1.16.5-r1::gentoo
sys-devel/binutils:        2.40-r4::gentoo
sys-devel/binutils-config: 5.5::gentoo
sys-devel/clang:           14.0.6-r1::gentoo, 15.0.7-r1::gentoo, 16.0.3::gentoo
sys-devel/gcc:             12.2.1_p20230428-r1::gentoo, 13.1.0-r1::gentoo
sys-devel/gcc-config:      2.10::gentoo
sys-devel/libtool:         2.4.7-r1::gentoo
sys-devel/llvm:            14.0.6-r2::gentoo, 15.0.7::gentoo, 16.0.3::gentoo
sys-devel/make:            4.4.1::gentoo
sys-kernel/linux-headers:  6.3::gentoo (virtual/os-headers)
sys-libs/glibc:            2.37-r2::gentoo
Repositories:

gentoo
    location: /var/db/repos/gentoo
    sync-type: rsync
    sync-uri: rsync://server.kopylovs.net/gentoo-portage
    priority: -1000
    volatile: False
    sync-rsync-verify-metamanifest: yes
    sync-rsync-extra-opts:
    sync-rsync-verify-jobs: 1
    sync-rsync-verify-max-age: 24

HomeAssistantRepository
    location: /var/lib/layman/HomeAssistantRepository
    sync-type: laymansync
    sync-uri: https://git.edevau.net/onkelbeh/HomeAssistantRepository.git
    masters: gentoo
    priority: 50
    volatile: True

guru
    location: /var/lib/layman/guru
    sync-type: laymansync
    sync-uri: https://anongit.gentoo.org/git/repo/proj/guru.git
    masters: gentoo
    priority: 50
    volatile: True

kde
    location: /var/lib/layman/kde
    sync-type: laymansync
    sync-uri: https://anongit.gentoo.org/git/proj/kde.git
    masters: gentoo
    priority: 50
    volatile: True

ACCEPT_KEYWORDS="arm64 ~arm64"
ACCEPT_LICENSE="* -@EULA android AnyDesk-TOS geekbench Microsoft-vscode TeamViewer Vivaldi"
CBUILD="aarch64-unknown-linux-gnu"
CFLAGS="-march=armv8-a+crc+lse+rcpc+rdma+dotprod+aes+fp16fml+sb+ssbs+flagm+pauth -O2 -pipe -fomit-frame-pointer"
CHOST="aarch64-unknown-linux-gnu"
CONFIG_PROTECT="/etc /usr/lib64/libreoffice/program/sofficerc /usr/share/config /usr/share/gnupg/qualified.txt"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/dconf /etc/env.d /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/php/apache2-php7.4/ext-active/ /etc/php/apache2-php8.0/ext-active/ /etc/php/apache2-php8.2/ext-active/ /etc/php/cgi-php7.4/ext-active/ /etc/php/cgi-php8.0/ext-active/ /etc/php/cgi-php8.2/ext-active/ /etc/php/cli-php7.4/ext-active/ /etc/php/cli-php8.0/ext-active/ /etc/php/cli-php8.2/ext-active/ /etc/php/fpm-php7.4/ext-active/ /etc/php/fpm-php8.0/ext-active/ /etc/php/fpm-php8.2/ext-active/ /etc/php/phpdbg-php7.4/ext-active/ /etc/php/phpdbg-php8.0/ext-active/ /etc/php/phpdbg-php8.2/ext-active/ /etc/revdep-rebuild /etc/sandbox.d /etc/texmf/language.dat.d /etc/texmf/language.def.d /etc/texmf/updmap.d /etc/texmf/web2c"
CXXFLAGS="-march=armv8-a+crc+lse+rcpc+rdma+dotprod+aes+fp16fml+sb+ssbs+flagm+pauth -O2 -pipe -fomit-frame-pointer"
DISTDIR="/var/cache/distfiles"
ENV_UNSET="CARGO_HOME DBUS_SESSION_BUS_ADDRESS DISPLAY GDK_PIXBUF_MODULE_FILE GOBIN GOPATH PERL5LIB PERL5OPT PERLPREFIX PERL_CORE PERL_MB_OPT PERL_MM_OPT XAUTHORITY XDG_CACHE_HOME XDG_CONFIG_HOME XDG_DATA_HOME XDG_RUNTIME_DIR XDG_STATE_HOME"
FCFLAGS="-march=armv8-a+crc+lse+rcpc+rdma+dotprod+aes+fp16fml+sb+ssbs+flagm+pauth -O2 -pipe -fomit-frame-pointer"
FEATURES="assume-digests binpkg-docompress binpkg-dostrip binpkg-logs binpkg-multi-instance buildpkg-live config-protect-if-modified distlocks ebuild-locks fixlafiles ipc-sandbox merge-sync multilib-strict network-sandbox news parallel-fetch pid-sandbox preserve-libs protect-owned qa-unresolved-soname-deps sandbox sfperms strict strict-keepdir unknown-features-warn unmerge-logs unmerge-orphans userfetch userpriv usersandbox usersync warn-on-large-env xattr"
FFLAGS="-march=armv8-a+crc+lse+rcpc+rdma+dotprod+aes+fp16fml+sb+ssbs+flagm+pauth -O2 -pipe -fomit-frame-pointer"
GENTOO_MIRRORS="https://mirror.isoc.org.il/pub/gentoo/"
LANG="en_US.utf8"
LC_ALL="en_US.UTF-8"
LDFLAGS="-Wl,-O1 -Wl,--as-needed"
LEX="flex"
MAKEOPTS="-j6"
PKGDIR="/var/cache/binpkgs"
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="/var/tmp"
SHELL="/bin/bash"
USE="X a52 aac aalib accessibility acl acpi activities alsa ao appindicator archive arm64 aspell audit bash-completion berkdb bidi bluetooth bluray boost branding brotli btrfs bzip2 cairo cdda cddb cdio cdr cgi cli colord contrib cron crypt cryptsetup cups curl dbi dbus designer device-mapper djvu doc dri dts dv dvb dvdr eds emacs enchant encode evdev evo examples executable exif expat experimental extra extras fam fastcgi fbcon ffmpeg fftw flac fluidsynth fontconfig fontforge fortran freetds ftp fuse gamepad games gcrypt gd gdbm gdk-pixbuf geoip geolocation gif git glade glib glusterfs gme gmp gnome gnome-keyring gnome-online-accounts gnuplot gnutls go gpg gphoto2 gpm graphite graphviz gsm gssapi gstreamer gtk gtk-doc gtk3 gui guile harfbuzz hdf5 heif highlight hscolour html http http2 ibus iconv icu idn imagemagick imap imlib introspection iodbc ipv6 jack java javascript jbig jemalloc joystick jpeg jpeg2k jpegxl json kde kerberos ladspa lame latex lcms ldap libass libcaca libevent libglvnd libnotify libsamplerate libsecret libtirpc libxml2 lmdb lua lv2 lvm lz4 lzma lzo mad magic maildir man mbedtls mbox memcached midi mmap mng modplug mp3 mp4 mpeg mplayer mtp multimedia musepack mysql nas nautilus ncurses netlink nettle network networkmanager nfs nls nptl nss ntlm odbc offensive ogg openal openexr opengl openmp openssl opus pam pango pcap pcre pdf perl phonon pkcs11 plasma plugins png policykit portaudio postgres postscript ppds pulseaudio python qdbm qml qrcode qt5 raw rdma readline redis rss samba sasl screencast sctp sdl seccomp semantic-desktop sftp share skey smp smtp snappy sndfile sndio snmp sound source sox speech speex spell sql sqlite ssh ssl startup-notification svg symlink syslog systemd taglib tbb tcl tcpd telemetry telepathy test-rust theora threads tiff tk tools tracker tremor truetype twolame udev udisks unicode unwind upnp upower usb utils uuid v4l vala vcd vim-syntax vnc vorbis vpx wavpack wayland webengine webkit webp websockets widgets wmf wxwidgets x264 x265 xattr xcb xface xft xinerama xml xmp xpm xscreensaver xv xvid yaml zeroconf zip zlib zsh-completion zstd" ADA_TARGET="gnat_2021" 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 stage" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" CPU_FLAGS_ARM="edsp thumb vfp vfpv3 vfpv4 vfp-d32 aes sha1 sha2 crc32 v4 v5 v6 v7 v8 thumb2" ELIBC="glibc" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock greis isync itrax mtk3301 nmea ntrip navcom oceanserver oldstyle oncore rtcm104v2 rtcm104v3 sirf skytraq superstar2 timing tsip tripmate tnt ublox ubx" GRUB_PLATFORMS="efi-64" INPUT_DEVICES="evdev joystick libinput" KERNEL="linux" L10N="en en-US he ru" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LIBREOFFICE_EXTENSIONS="nlpsolver" LUA_SINGLE_TARGET="lua5-1" LUA_TARGETS="lua5-1" OFFICE_IMPLEMENTATION="libreoffice" PHP_TARGETS="php7-4 php8-0" POSTGRES_TARGETS="postgres12 postgres13" PYTHON_SINGLE_TARGET="python3_11" PYTHON_TARGETS="python3_11 python3_10" RUBY_TARGETS="ruby30 ruby31 ruby32" USERLAND="GNU" VIDEO_CARDS="virgl" XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipset ipp2p iface geoip fuzzy condition tee tarpit sysrq proto steal rawnat logmark ipmark dhcpmac delude chaos account"
Unset:  ADDR2LINE, AR, ARFLAGS, AS, ASFLAGS, CC, CCLD, CONFIG_SHELL, CPP, CPPFLAGS, CTARGET, CXX, CXXFILT, ELFEDIT, EMERGE_DEFAULT_OPTS, EXTRA_ECONF, F77FLAGS, FC, GCOV, GPROF, INSTALL_MASK, LD, LFLAGS, LIBTOOL, LINGUAS, MAKE, MAKEFLAGS, NM, OBJCOPY, OBJDUMP, PORTAGE_BINHOST, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS, RANLIB, READELF, RUSTFLAGS, SIZE, STRINGS, STRIP, YACC, YFLAGS
Comment 16 Leonid Kopylov 2023-05-05 13:51:47 UTC
Created attachment 861198 [details]
build.log
Comment 17 Sebastian Parborg 2023-05-05 14:34:05 UTC
If I would have a guess, then it seems like the cmake flag `EMBREE_ARM` does not get turned on for some reason.

Could you try to download and compile embree outside of portage and see if it works for you there?
Comment 18 Leonid Kopylov 2023-05-05 14:39:37 UTC
(In reply to Sebastian Parborg from comment #17)
> If I would have a guess, then it seems like the cmake flag `EMBREE_ARM` does
> not get turned on for some reason.
> 
> Could you try to download and compile embree outside of portage and see if
> it works for you there?

i guess i need to download it from here? https://github.com/embree/embree/releases

what should i run to start the build?
Comment 19 Sebastian Parborg 2023-05-05 16:05:40 UTC
To build embree yourself, you first navigate to a folder where you want to build it. In this case you can simply just go to /tmp and do:

wget https://github.com/embree/embree/archive/refs/tags/v3.13.5.tar.gz

tar -xf v3.13.5.tar.gz

cd embree-3.13.5/
mkdir build
cd build
cmake ..
make -j8


And see if it builds.
Comment 20 Leonid Kopylov 2023-05-05 16:08:40 UTC
(In reply to Sebastian Parborg from comment #19)
> To build embree yourself, you first navigate to a folder where you want to
> build it. In this case you can simply just go to /tmp and do:
> 
> wget https://github.com/embree/embree/archive/refs/tags/v3.13.5.tar.gz
> 
> tar -xf v3.13.5.tar.gz
> 
> cd embree-3.13.5/
> mkdir build
> cd build
> cmake ..
> make -j8
> 
> 
> And see if it builds.

gentoo /tmp/embree/embree-3.13.5/build # cmake ..
CMake Warning (dev) at CMakeLists.txt:13 (PROJECT):
  cmake_minimum_required() should be called prior to this top-level project()
  call.  Please see the cmake-commands(7) manual for usage documentation of
  both commands.
This warning is for project developers.  Use -Wno-dev to suppress it.

-- The C compiler identification is GNU 13.1.0
-- The CXX compiler identification is GNU 13.1.0
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working C compiler: /usr/bin/cc - skipped
-- Detecting C compile features
-- Detecting C compile features - done
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: /usr/bin/c++ - skipped
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- GNU detected
CMake Error at common/cmake/ispc.cmake:41 (MESSAGE):
  Intel SPMD Compiler (ISPC) not found.  Disable EMBREE_ISPC_SUPPORT or
  install ISPC.
Call Stack (most recent call first):
  CMakeLists.txt:548 (INCLUDE)


-- Configuring incomplete, errors occurred!
Comment 21 Leonid Kopylov 2023-05-05 16:09:32 UTC
dev-lang/ispc cannot be installed - https://bugs.gentoo.org/842879
Comment 22 Leonid Kopylov 2023-05-05 16:13:37 UTC
i can't find how to disable EMBREE_ISPC_SUPPORT
Comment 23 Sebastian Parborg 2023-05-05 16:15:55 UTC
You can disable it by doing this:
cmake .. -DEMBREE_ISPC_SUPPORT=OFF
Comment 24 Leonid Kopylov 2023-05-05 16:17:26 UTC
(In reply to Sebastian Parborg from comment #23)
> You can disable it by doing this:
> cmake .. -DEMBREE_ISPC_SUPPORT=OFF

# make -j8
[  0%] Building CXX object common/simd/CMakeFiles/simd.dir/sse.cpp.o
[  1%] Building CXX object common/sys/CMakeFiles/sys.dir/sysinfo.cpp.o
[  2%] Building CXX object common/math/CMakeFiles/math.dir/constants.cpp.o
c++: error: unrecognized command-line option ‘-msse2’
make[2]: *** [common/simd/CMakeFiles/simd.dir/build.make:76: common/simd/CMakeFiles/simd.dir/sse.cpp.o] Error 1
make[1]: *** [CMakeFiles/Makefile2:985: common/simd/CMakeFiles/simd.dir/all] Error 2
make[1]: *** Waiting for unfinished jobs....
c++: error: unrecognized command-line option ‘-msse2’
make[2]: *** [common/sys/CMakeFiles/sys.dir/build.make:76: common/sys/CMakeFiles/sys.dir/sysinfo.cpp.o] Error 1
make[1]: *** [CMakeFiles/Makefile2:933: common/sys/CMakeFiles/sys.dir/all] Error 2
c++: error: unrecognized command-line option ‘-msse2’
make[2]: *** [common/math/CMakeFiles/math.dir/build.make:76: common/math/CMakeFiles/math.dir/constants.cpp.o] Error 1
make[1]: *** [CMakeFiles/Makefile2:959: common/math/CMakeFiles/math.dir/all] Error 2
[  2%] Building CXX object tutorials/common/tutorial/CMakeFiles/benchmark.dir/benchmark.cpp.o
[  2%] Building CXX object tutorials/common/imgui/CMakeFiles/imgui.dir/imgui.cpp.o
[  3%] Building CXX object common/tasking/CMakeFiles/tasking.dir/taskschedulertbb.cpp.o
[  5%] Building CXX object tutorials/common/tutorial/CMakeFiles/noise.dir/noise.cpp.o
[  5%] Building CXX object tutorials/common/imgui/CMakeFiles/imgui.dir/imgui_impl_glfw_gl2.cpp.o
c++: error: unrecognized command-line option ‘-msse2’
make[2]: *** [tutorials/common/tutorial/CMakeFiles/benchmark.dir/build.make:76: tutorials/common/tutorial/CMakeFiles/benchmark.dir/benchmark.cpp.o] Error 1
make[1]: *** [CMakeFiles/Makefile2:1208: tutorials/common/tutorial/CMakeFiles/benchmark.dir/all] Error 2
[  6%] Building C object tutorials/verify/CMakeFiles/c99_compile_test.dir/api_c99.c.o
c++: error: unrecognized command-line option ‘-msse2’
make[2]: *** [common/tasking/CMakeFiles/tasking.dir/build.make:76: common/tasking/CMakeFiles/tasking.dir/taskschedulertbb.cpp.o] Error 1
make[1]: *** [CMakeFiles/Makefile2:1038: common/tasking/CMakeFiles/tasking.dir/all] Error 2
c++: error: unrecognized command-line option ‘-msse2’
make[2]: *** [tutorials/common/tutorial/CMakeFiles/noise.dir/build.make:76: tutorials/common/tutorial/CMakeFiles/noise.dir/noise.cpp.o] Error 1
make[1]: *** [CMakeFiles/Makefile2:1234: tutorials/common/tutorial/CMakeFiles/noise.dir/all] Error 2
c++: error: unrecognized command-line option ‘-msse2’
c++: error: unrecognized command-line option ‘-msse2’
make[2]: *** [tutorials/common/imgui/CMakeFiles/imgui.dir/build.make:90: tutorials/common/imgui/CMakeFiles/imgui.dir/imgui_impl_glfw_gl2.cpp.o] Error 1
make[2]: *** Waiting for unfinished jobs....
make[2]: *** [tutorials/common/imgui/CMakeFiles/imgui.dir/build.make:76: tutorials/common/imgui/CMakeFiles/imgui.dir/imgui.cpp.o] Error 1
[  6%] Building CXX object tutorials/common/imgui/CMakeFiles/imgui.dir/imgui_draw.cpp.o
c++: error: unrecognized command-line option ‘-msse2’
make[2]: *** [tutorials/common/imgui/CMakeFiles/imgui.dir/build.make:104: tutorials/common/imgui/CMakeFiles/imgui.dir/imgui_draw.cpp.o] Error 1
make[1]: *** [CMakeFiles/Makefile2:1147: tutorials/common/imgui/CMakeFiles/imgui.dir/all] Error 2
[  6%] Linking C static library ../../libc99_compile_test.a
[  6%] Built target c99_compile_test
make: *** [Makefile:156: all] Error 2
Comment 25 Sebastian Parborg 2023-05-05 16:33:30 UTC
What do you get if you do:
grep ISA CMakeCache.txt

In the build directory?
Comment 26 Leonid Kopylov 2023-05-05 16:36:09 UTC
(In reply to Sebastian Parborg from comment #25)
> What do you get if you do:
> grep ISA CMakeCache.txt
> 
> In the build directory?

# grep ISA CMakeCache.txt
//Enables NEON ISA.
EMBREE_ISA_NEON:BOOL=ON
//Enables NEON ISA double pumped.
EMBREE_ISA_NEON2X:BOOL=OFF
//Selects highest ISA to support.
EMBREE_MAX_ISA:STRING=NONE
//STRINGS property for variable: EMBREE_MAX_ISA
EMBREE_MAX_ISA-STRINGS:INTERNAL=NONE;NEON;NEON2X
Comment 27 Sebastian Parborg 2023-05-05 16:39:57 UTC
Ok, then I guess arm support might just be broken on linux in embree 3.5...

Perhaps you can see if the 4.0 release compiles? The change log did state they did some stuff on the Linux ARM side of things.
Comment 28 Leonid Kopylov 2023-05-05 16:44:38 UTC
(In reply to Sebastian Parborg from comment #27)
> Ok, then I guess arm support might just be broken on linux in embree 3.5...
> 
> Perhaps you can see if the 4.0 release compiles? The change log did state
> they did some stuff on the Linux ARM side of things.
for v4.0.1

[  2%] Building CXX object tutorials/common/tutorial/CMakeFiles/embree_benchmark.dir/benchmark.cpp.o
In file included from /tmp/embree/embree-4.0.1/tutorials/common/imgui/imgui.cpp:862:
/tmp/embree/embree-4.0.1/tutorials/common/imgui/imgui_internal.h:61:10: fatal error: immintrin.h: No such file or directory
   61 | #include <immintrin.h>
      |          ^~~~~~~~~~~~~
compilation terminated.
[  2%] Linking C static library ../../libc99_compile_test.a
make[2]: *** [tutorials/common/imgui/CMakeFiles/imgui.dir/build.make:76: tutorials/common/imgui/CMakeFiles/imgui.dir/imgui.cpp.o] Error 1
make[1]: *** [CMakeFiles/Makefile2:1183: tutorials/common/imgui/CMakeFiles/imgui.dir/all] Error 2
make[1]: *** Waiting for unfinished jobs....
[  3%] Building CXX object common/sys/CMakeFiles/sys.dir/alloc.cpp.o
Comment 29 Leonid Kopylov 2023-05-05 16:46:31 UTC
if i run:
cmake .. -DEMBREE_ISPC_SUPPORT=OFF -DEMBREE_TUTORIALS=OFF

it seems to work:
[ 98%] Building CXX object kernels/CMakeFiles/embree.dir/bvh/bvh_intersector_hybrid4_bvh4.cpp.o
[100%] Linking CXX shared library ../libembree4.so
[100%] Built target embree
Comment 30 Sebastian Parborg 2023-05-05 16:49:10 UTC
Ok, so then it seems like it is fixed in the 4.0 version.
I also found this upstream issue ticket: https://github.com/embree/embree/issues/383

With the 3.5 version can you try the suggested trick of doing:
cmake .. -DEMBREE_ARM=ON

And see if that works?
Comment 31 Leonid Kopylov 2023-05-05 16:51:35 UTC
(In reply to Sebastian Parborg from comment #30)
> Ok, so then it seems like it is fixed in the 4.0 version.
> I also found this upstream issue ticket:
> https://github.com/embree/embree/issues/383
> 
> With the 3.5 version can you try the suggested trick of doing:
> cmake .. -DEMBREE_ARM=ON
> 
> And see if that works?

with cmake .. -DEMBREE_ISPC_SUPPORT=OFF -DEMBREE_ARM=ON it fails:

/tmp/embree/embree-3.13.5/common/sys/../simd/arm/avx2neon.h: In function ‘__m256i _mm256_mask_i32gather_epi32(__m256i, const int*, __m256i, __m256i, int)’:
/tmp/embree/embree-3.13.5/common/sys/../simd/arm/avx2neon.h:1181:31: error: cannot convert ‘__m128i’ {aka ‘int32x4_t’} to ‘uint32x4_t’ in initialization
 1181 |     uint32x4_t mask_lo = mask.lo;
      |                          ~~~~~^~
      |                               |
      |                               __m128i {aka int32x4_t}
/tmp/embree/embree-3.13.5/common/sys/../simd/arm/avx2neon.h:1182:31: error: cannot convert ‘__m128i’ {aka ‘int32x4_t’} to ‘uint32x4_t’ in initialization
 1182 |     uint32x4_t mask_hi = mask.hi;
      |                          ~~~~~^~
      |                               |
      |                               __m128i {aka int32x4_t}
In file included from /tmp/embree/embree-3.13.5/tutorials/common/imgui/imgui_draw.cpp:117:
/tmp/embree/embree-3.13.5/tutorials/common/imgui/stb_truetype.h:250:1: warning: multi-line comment [-Wcomment]
  250 | //   Software rasterization             240 LOC  \
      | ^
make[2]: *** [common/sys/CMakeFiles/sys.dir/build.make:90: common/sys/CMakeFiles/sys.dir/alloc.cpp.o] Error 1
make[2]: *** [common/tasking/CMakeFiles/tasking.dir/build.make:76: common/tasking/CMakeFiles/tasking.dir/taskschedulertbb.cpp.o] Error 1
make[1]: *** [CMakeFiles/Makefile2:1038: common/tasking/CMakeFiles/tasking.dir/all] Error 2
make[1]: *** [CMakeFiles/Makefile2:933: common/sys/CMakeFiles/sys.dir/all] Error 2
make[2]: *** [tutorials/common/tutorial/CMakeFiles/benchmark.dir/build.make:76: tutorials/common/tutorial/CMakeFiles/benchmark.dir/benchmark.cpp.o] Error 1
make[1]: *** [CMakeFiles/Makefile2:1208: tutorials/common/tutorial/CMakeFiles/benchmark.dir/all] Error 2
[  8%] Linking CXX static library ../../../libimgui.a
[  8%] Built target imgui
make: *** [Makefile:156: all] Error 2
Comment 32 Sebastian Parborg 2023-05-05 17:12:27 UTC
Ok, in the embree source directory (embree-3.13.5) can you try to do
wget https://github.com/embree/embree/commit/82ca6b5ccb7abe0403a658a0e079926478f04cb1.patch
git apply 82ca6b5ccb7abe0403a658a0e079926478f04cb1.patch

And then try to rebuild it and see if it works?
Comment 33 Leonid Kopylov 2023-05-05 17:16:48 UTC
(In reply to Sebastian Parborg from comment #32)
> Ok, in the embree source directory (embree-3.13.5) can you try to do
> wget
> https://github.com/embree/embree/commit/
> 82ca6b5ccb7abe0403a658a0e079926478f04cb1.patch
> git apply 82ca6b5ccb7abe0403a658a0e079926478f04cb1.patch
> 
> And then try to rebuild it and see if it works?

worked:

[ 99%] Building CXX object tutorials/viewer_anim/CMakeFiles/viewer_anim.dir/viewer_anim_device.cpp.o
[ 99%] Built target voronoi
[ 99%] Linking CXX executable ../../quaternion_motion_blur
[ 99%] Built target quaternion_motion_blur
[ 99%] Linking CXX executable ../../embree_verify
[ 99%] Built target embree_verify
[ 99%] Linking CXX executable ../../viewer_stream
[ 99%] Built target viewer_stream
[100%] Linking CXX executable ../../viewer_anim
[100%] Built target viewer_anim
Comment 34 Sebastian Parborg 2023-05-05 17:21:11 UTC
Ok, thanks for testing.
I'll create a pull request that will include the patch so it actually builds on arm.
Comment 35 Larry the Git Cow gentoo-dev 2023-05-09 17:51:18 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=6e16952c578fdc0e662e2986bf8139df0d8c3530

commit 6e16952c578fdc0e662e2986bf8139df0d8c3530
Author:     Sebastian Parborg <darkdefende@gmail.com>
AuthorDate: 2023-05-08 12:59:51 +0000
Commit:     Sam James <sam@gentoo.org>
CommitDate: 2023-05-09 17:50:56 +0000

    media-libs/embree: Fix arches and REQUIRED_USE
    
    Embree does not support anything else than amd64 and arm64.
    The other arches will not compile.
    
    arm64 needs a patch to work on linux in the current 3.x.x release
    
    Closes: https://bugs.gentoo.org/851705
    Signed-off-by: Sebastian Parborg <darkdefende@gmail.com>
    Signed-off-by: Sam James <sam@gentoo.org>

 media-libs/embree/embree-3.13.5.ebuild             | 12 ++---
 .../embree/files/embree-3.13.5-fix-arm64.patch     | 53 ++++++++++++++++++++++
 2 files changed, 59 insertions(+), 6 deletions(-)