Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 738832

Summary: games-fps/quake2-icculus-0.16.1-r1 : src/.../g_local.h: fatal error: bits/nan.h: No such file or directory
Product: Gentoo Linux Reporter: Toralf Förster <toralf>
Component: Current packagesAssignee: Gentoo Games <games>
Status: CONFIRMED ---    
Severity: normal CC: sam
Priority: Normal Keywords: PATCH
Version: unspecified   
Hardware: All   
OS: Linux   
See Also: https://bugs.gentoo.org/show_bug.cgi?id=770904
Whiteboard:
Package list:
Runtime testing required: ---
Bug Depends on:    
Bug Blocks: 637144    
Attachments: emerge-info.txt
emerge-history.txt
environment
etc.portage.tbz2
games-fps:quake2-icculus-0.16.1-r1:20200824-094654.log
temp.tbz2

Description Toralf Förster gentoo-dev 2020-08-24 15:55:21 UTC
x86_64-pc-linux-gnu-gcc -Wall -pipe -Dstricmp=strcasecmp -DHAVE_IPV6 -DDEFAULT_BASEDIR=\"/usr/share/games/quake2\" -DDEFAULT_LIBDIR=\"/usr/games/lib64/quake2-icculus\" -DC_ONLY -O2 -pipe -march=native -fno-diagnostics-color  -falign-functions=32:25:16 -DLINUX_VERSION=\"3.21+r0.16\" -fPIC -o releasex86_64/rogue/dm_ball.o -c src/rogue/dm_ball.c
In file included from src/rogue/dm_ball.c:5:
src/rogue/g_local.h:25:10: fatal error: bits/nan.h: No such file or directory
   25 | #include <bits/nan.h>
      |          ^~~~~~~~~~~~
compilation terminated.

  -------------------------------------------------------------------

  This is an unstable amd64 chroot image at a tinderbox (==build bot)
  name: 17.1_systemd-libressl_abi32+64-20200821-231953

  -------------------------------------------------------------------

gcc-config -l:
 [1] x86_64-pc-linux-gnu-10.2.0 *
clang version 10.0.1 
Target: x86_64-pc-linux-gnu
Thread model: posix
InstalledDir: /usr/lib/llvm/10/bin
/usr/lib/llvm/10
10.0.1
Available Python interpreters, in order of preference:
  [1]   python3.7
  [2]   python3.9 (fallback)
  [3]   python3.8 (fallback)
  [4]   python2.7 (fallback)
Available Ruby profiles:
  [1]   ruby25 (with Rubygems) *
The following VMs are available for generation-2:
Available Java Virtual Machines:
  (none found)

The Glorious Glasgow Haskell Compilation System, version 8.8.4

  timestamp(s) of HEAD at this tinderbox image:
/var/db/repos/gentoo	Mon Aug 24 09:05:36 AM UTC 2020
/var/db/repos/libressl	Mon Aug 10 09:13:35 AM UTC 2020

emerge -qpvO games-fps/quake2-icculus
[ebuild  N    ] games-fps/quake2-icculus-0.16.1-r1  USE="ipv6 rogue xatrix -X -aalib -alsa -cdinstall -dedicated -demo -joystick -opengl -qmax -sdl"
Comment 1 Toralf Förster gentoo-dev 2020-08-24 15:55:23 UTC
Created attachment 656474 [details]
emerge-info.txt
Comment 2 Toralf Förster gentoo-dev 2020-08-24 15:55:25 UTC
Created attachment 656476 [details]
emerge-history.txt
Comment 3 Toralf Förster gentoo-dev 2020-08-24 15:55:27 UTC
Created attachment 656478 [details]
environment
Comment 4 Toralf Förster gentoo-dev 2020-08-24 15:55:28 UTC
Created attachment 656480 [details]
etc.portage.tbz2
Comment 5 Toralf Förster gentoo-dev 2020-08-24 15:55:30 UTC
Created attachment 656482 [details]
games-fps:quake2-icculus-0.16.1-r1:20200824-094654.log
Comment 6 Toralf Förster gentoo-dev 2020-08-24 15:55:32 UTC
Created attachment 656484 [details]
temp.tbz2
Comment 7 Jeremy Stent 2021-04-08 23:28:11 UTC
It appears as if we need to change line 25 of src/rogue/g_local.h to #include math.h instead of bits/nan.h
Doing so allowed my to finish the compile.  I found this by reading nan.h on a different architecture, where it says to use math.h instead of including nan.h directly.
Comment 8 Alex D-Bug 2022-03-05 22:17:57 UTC
https://aur.archlinux.org/cgit/aur.git/tree/updates_for_gcc.patch?h=quake2
Here's the same. Can confirm, builds fine with bits/nan.h changed to math.h