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

Bug 909430

Summary: sci-libs/gdal-3.7.0[java]: CMake Error at swig/CMakeLists.txt:50 (message): JNI is a requirement to build the Java bindings
Product: Gentoo Linux Reporter: Toralf Förster <toralf>
Component: Current packagesAssignee: Sci-geo Project <sci-geosciences>
Status: RESOLVED FIXED    
Severity: normal CC: bog
Priority: Normal Keywords: PullRequest
Version: unspecified   
Hardware: All   
OS: Linux   
See Also: https://bugs.gentoo.org/show_bug.cgi?id=857816
https://github.com/gentoo/gentoo/pull/31923
Whiteboard:
Package list:
Runtime testing required: ---
Bug Depends on:    
Bug Blocks: 910101    
Attachments: emerge-info.txt
emerge-history.txt
environment
etc.clang.tar.xz
etc.portage.tar.xz
sci-libs:gdal-3.7.0:20230701-075240.log
temp.tar.xz

Description Toralf Förster gentoo-dev 2023-07-01 08:49:59 UTC
-- Looking for linux/fs.h - found
-- Found BISON: /usr/bin/bison (found version "3.8.2") 
CMake Error at swig/CMakeLists.txt:50 (message):
  JNI is a requirement to build the Java bindings


-- Configuring incomplete, errors occurred!
 * ERROR: sci-libs/gdal-3.7.0::gentoo failed (configure phase):
 *   cmake failed

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

  This is an unstable amd64 chroot image at a tinderbox (==build bot)
  name: 17.1_desktop-20230628-230015

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

gcc-config -l:
 [1] x86_64-pc-linux-gnu-13 *
clang/llvm (if any):
clang version 16.0.6
Target: x86_64-pc-linux-gnu
Thread model: posix
InstalledDir: /usr/lib/llvm/16/bin
Configuration file: /etc/clang/clang.cfg
/usr/lib/llvm/16
16.0.6
Python 3.11.4
Available Ruby profiles:
  [1]   ruby31 (with Rubygems) *
Available Rust versions:
  [1]   rust-bin-1.69.0 *
GENTOO_VM=openjdk-bin-8  CLASSPATH="" JAVA_HOME="/opt/openjdk-bin-8.372_p07"
JAVACFLAGS="-source 1.8 -target 1.8" COMPILER=""
The following VMs are available for generation-2:
1)	Eclipse Temurin JDK 11.0.19_p7 [openjdk-bin-11]
2)	Eclipse Temurin JDK 17.0.7_p7 [openjdk-bin-17]
*)	Eclipse Temurin JDK 8.372_p07 [openjdk-bin-8]
4)	Eclipse Temurin JRE 11.0.19_p7 [openjdk-jre-bin-11]
Available Java Virtual Machines:
  [1]   openjdk-bin-8  system-vm
  [2]   openjdk-bin-11 
  [3]   openjdk-bin-17 
  [4]   openjdk-jre-bin-11 

php cli (if any):
go version go1.20.5 linux/amd64

  HEAD of ::gentoo
commit 8cc1b19c852c5d0b5f1fc5ed5376509f14955ed8
Author: Repository mirror & CI <repomirrorci@gentoo.org>
Date:   Sat Jul 1 07:32:09 2023 +0000

    2023-07-01 07:32:08 UTC

emerge -qpvO sci-libs/gdal
[ebuild  N    ] sci-libs/gdal-3.7.0  USE="curl gif java jpeg jpeg2k lzma odbc pdf png zstd -armadillo (-doc) -fits -geos -gml -hdf5 -heif -mysql -netcdf -ogdi -opencl -oracle -postgres -python -spatialite -sqlite -test -webp -xls" CPU_FLAGS_X86="avx avx2 sse sse2 sse4_1 ssse3" PYTHON_SINGLE_TARGET="python3_11 -python3_10"
Comment 1 Toralf Förster gentoo-dev 2023-07-01 08:50:00 UTC
Created attachment 864929 [details]
emerge-info.txt
Comment 2 Toralf Förster gentoo-dev 2023-07-01 08:50:02 UTC
Created attachment 864930 [details]
emerge-history.txt
Comment 3 Toralf Förster gentoo-dev 2023-07-01 08:50:03 UTC
Created attachment 864931 [details]
environment
Comment 4 Toralf Förster gentoo-dev 2023-07-01 08:50:04 UTC
Created attachment 864932 [details]
etc.clang.tar.xz
Comment 5 Toralf Förster gentoo-dev 2023-07-01 08:50:05 UTC
Created attachment 864933 [details]
etc.portage.tar.xz
Comment 6 Toralf Förster gentoo-dev 2023-07-01 08:50:06 UTC
Created attachment 864934 [details]
sci-libs:gdal-3.7.0:20230701-075240.log
Comment 7 Toralf Förster gentoo-dev 2023-07-01 08:50:07 UTC
Created attachment 864935 [details]
temp.tar.xz
Comment 8 Khumba 2023-07-09 14:35:53 UTC
This seems to be the culprit:

package.use/24thrown_package_use_flags:virtual/jdk                          headless-awt
package.use/27-28-3-b-necessary-use-flag:>=dev-java/openjdk-bin-17.0.7_p7     headless-awt
package.use/27-28-3-b-necessary-use-flag:>=dev-java/openjdk-bin-8.372_p07:8   headless-awt

Maybe gdal should depend on >=virtual/jdk-1.8:*[-headless-awt].
Comment 9 Larry the Git Cow gentoo-dev 2023-07-31 19:55:53 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=1f599dfac9589979c10b69d68774ac2f0129c06f

commit 1f599dfac9589979c10b69d68774ac2f0129c06f
Author:     Volkmar W. Pogatzki <gentoo@pogatzki.net>
AuthorDate: 2023-07-17 09:03:47 +0000
Commit:     Andreas Sturmlechner <asturm@gentoo.org>
CommitDate: 2023-07-31 19:55:36 +0000

    sci-libs/gdal: USE=-headless-awt for virtual/jdk
    
    Closes: https://bugs.gentoo.org/909430
    Signed-off-by: Volkmar W. Pogatzki <gentoo@pogatzki.net>
    Closes: https://github.com/gentoo/gentoo/pull/31923
    Signed-off-by: Andreas Sturmlechner <asturm@gentoo.org>

 sci-libs/gdal/gdal-3.7.0.ebuild | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)