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

Bug 915056

Summary: sci-libs/geos-3.11.2: stabilisation (was: fails to compile with gcc-13 with "error: 'uint8_t' has not been declared")
Product: Gentoo Linux Reporter: Jack <ostroffjh>
Component: StabilizationAssignee: Sci-geo Project <sci-geosciences>
Status: IN_PROGRESS ---    
Severity: normal CC: msdobrescu, pgsql-bugs, x86
Priority: Normal Keywords: CC-ARCHES
Version: unspecifiedFlags: nattka: sanity-check+
Hardware: All   
OS: Linux   
Whiteboard:
Package list:
sci-libs/geos-3.11.2
Runtime testing required: ---
Bug Depends on: 921956    
Bug Blocks: 865117    
Attachments:
Description Flags
output of emerge --info
none
build.log none

Description Jack 2023-10-01 21:13:06 UTC
sci-libs/geos-3.11.0 compiles fine with sys-devel/12.3.1_p20230526 but fails with sys-devel/gcc-13.2.1_p20230826 with "error: 'uint8_t' has not been declared"

Reproducible: Always

Steps to Reproduce:
1. emerge geos with gcc-13
2.
3.
Actual Results:  
/usr/bin/x86_64-pc-linux-gnu-g++ -DDLL_EXPORT -DNDEBUG -DUSE_UNSTABLE_GEOS_CPP_API -Dgeos_EXPORTS -I/var/tmp/portage/sci-libs/geos-3.11.0/work/geos-3.11.0/include -I/var/tmp/portage/sci-libs/geos-3.11.0/work/geos-3.11.0_build/include -I/var/tmp/portage/sci-libs/geos-3.11.0/work/geos-3.11.0/src/deps -I/var/tmp/portage/sci-libs/geos-3.11.0/work/geos-3.11.0_build/src/deps  -march=native -O2 -pipe -std=c++11 -fPIC -ffp-contract=off -MD -MT CMakeFiles/geos.dir/src/geomgraph/Depth.cpp.o -MF CMakeFiles/geos.dir/src/geomgraph/Depth.cpp.o.d -o CMakeFiles/geos.dir/src/geomgraph/Depth.cpp.o -c /var/tmp/portage/sci-libs/geos-3.11.0/work/geos-3.11.0/src/geomgraph/Depth.cpp
In file included from /var/tmp/portage/sci-libs/geos-3.11.0/work/geos-3.11.0/src/geomgraph/Depth.cpp:23:
/var/tmp/portage/sci-libs/geos-3.11.0/work/geos-3.11.0/include/geos/geomgraph/Depth.h:115:17: error: 'uint8_t' has not been declared
  115 |     bool isNull(uint8_t geomIndex) const
      |                 ^~~~~~~
(will attach full build log)

Expected Results:  
successful emerge
Comment 1 Jack 2023-10-01 21:14:00 UTC
Created attachment 871987 [details]
output of emerge --info
Comment 2 Jack 2023-10-01 21:14:50 UTC
Created attachment 871988 [details]
build.log
Comment 3 msdobrescu 2023-10-03 07:54:18 UTC
From here: https://gcc.gnu.org/gcc-13/porting_to.html
Probably, must add #include <cstdint>
Comment 4 Jack 2023-10-03 11:30:59 UTC
But it needs to be added in more than one place.  I added one for the first error I got, and then got the same error further on.  I have no idea how many files need this added.  I suppose I can also file this upstream, unless it has already been done.
Comment 5 msdobrescu 2023-10-03 12:12:22 UTC
I know, I've just pointed to the cause and a solution.
It must definitely be fixed upstream, but also a grep for the `uint8_t` data type could find the files that need to be patched. There may be more data types with this issue too. I've seen many projects hit by this over the Internet.
Comment 6 Anton Bolshakov 2023-10-16 14:15:09 UTC
FYI, sci-libs/geos-3.12.0 compiles fine.
Comment 7 Bill Binder 2023-10-24 19:07:27 UTC
sci-libs/geos-3.11.1 also builds successfully
Comment 8 Jack 2023-10-24 20:07:30 UTC
Might this then most easily be solved by stabilizing 3.11.1?
Comment 9 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2023-10-26 12:47:20 UTC
amd64 done
Comment 10 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2023-10-26 12:50:35 UTC
arm done
Comment 11 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2023-10-26 13:03:40 UTC
arm64 done
Comment 12 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2023-10-27 12:14:26 UTC
ppc64 done