Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

vab can't see jdk version #332

Open
ibinshoid opened this issue Dec 15, 2024 · 2 comments
Open

vab can't see jdk version #332

ibinshoid opened this issue Dec 15, 2024 · 2 comments

Comments

@ibinshoid
Copy link

Running vab bring this:

error: No Java JDK install(s) could be detected
details: Please install Java JDK >= 8 or provide a valid path via `JAVA_HOME`

but java is installed and set in JAVA_HOME.

$JAVA_HOME"/bin/java" --version
openjdk 17.0.13 2024-10-15
OpenJDK Runtime Environment (build 17.0.13+11-suse-150400.3.48.2-x8664)
OpenJDK 64-Bit Server VM (build 17.0.13+11-suse-150400.3.48.2-x8664, mixed mode, sharing)

vab doctor can find it, but version is empty.

vab doctor

details:
  SDK API level 33 > highest NDK API level 29.
vab
	Version    0.4.3 11544d4
	Path       "/home/andreas/.vmodules/vab"
	Base files "/home/andreas/.vmodules/vab/platforms/android"
	os.args    ['vab', 'doctor']

Extra
	Commands
		Allowed false
env
	ANDROID_HOME=/home/andreas/Android
	ANDROID_SDK_ROOT=/home/andreas/Android/Sdk
	JAVA_HOME=/usr/lib64/jvm/java-17-openjdk-17
Java
	JDK
		Version 
		Path    "/usr/lib64/jvm/java-17-openjdk-17"
		Keytool "/usr/lib64/jvm/java-17-openjdk-17/bin/keytool"
Android
	ENV
		sdkmanager "/home/andreas/.cache/v/android/sdk/cmdline-tools/tools/bin/sdkmanager"
		sdkmanager.version "4.0.1"
		avdmanager "/home/andreas/.cache/v/android/sdk/cmdline-tools/tools/bin/avdmanager"
		emulator   "/home/andreas/Android/Sdk/emulator/emulator"
		Managable true
	SDK
		Path "/home/andreas/Android/Sdk"
		Writable true
		APIs available ['33', '32', '31', '29', '27', '23', '22', '21', '18', '']
	NDK
		Version 21.1.6352462
		Path "/home/andreas/Android/Sdk/ndk"
		Side-by-side true
		min API level available 16
		max API level available 29
		arm64-v8a   ['29', '28', '27', '26', '24', '23', '22', '21']
		armeabi-v7a ['29', '28', '27', '26', '24', '23', '22', '21', '19', '18', '17', '16']
		x86         ['29', '28', '27', '26', '24', '23', '22', '21', '19', '18', '17', '16']
		x86_64      ['29', '28', '27', '26', '24', '23', '22', '21']
	Build
		API 29
		Build-tools 32.0.0
	Packaging
		Format apk
Product
	Name "V Test App"
	Package ID "io.v.android"
	Output ""
V
	Version 0.4.8 3d5f81b
	Path "/home/andreas/.local/v"

	V full version: V 0.4.8 3223da6.3d5f81b
	OS: linux, Linux version 6.4.0-150600.23.25-default (geeko@buildhost) (gcc (SUSE Linux) 7.5.0, GNU ld (GNU Binutils; SUSE Linux Enterprise 15) 2.43.1.20240828-150100.7.49) #1 SMP PREEMPT_DYNAMIC Tue Oct  1 10:54:01 UTC 2024 (ea7c56d)
	Processor: 4 cpus, 64bit, little endian, AMD Ryzen 3 2200G with Radeon Vega Graphics
	getwd: /home/andreas
	vexe: /home/andreas/.local/v/v
	vexe mtime: 2024-12-15 11:35:23
	vroot: OK, value: /home/andreas/.local/v
	VMODULES: OK, value: /home/andreas/.vmodules
	VTMP: OK, value: /tmp/v_1000
	Git version: git version 2.43.0
	Git vroot status: weekly.2024.50-37-g3d5f81b0
	.git/config present: true
	CC version: cc (SUSE Linux) 7.5.0
	emcc version: N/A
	thirdparty/tcc status: thirdparty-linux-amd64 0134e9b9

@larpon
Copy link
Contributor

larpon commented Dec 16, 2024

@ibinshoid can you shed a little more light on how you run vab (what flags and input are passed)?
A complete command-line example of how you trigger the error would help greatly

@ibinshoid
Copy link
Author

It was a problem with the java17 packages from SuSE.
when i install java11, vab works fine.
tree /usr/lib64/jvm/java-17-openjdk-17/bin is this:

/usr/lib64/jvm/java-17-openjdk-17/bin
├── java
├── jfr
├── keytool
└── rmiregistry

tree /usr/lib64/jvm/java-11-openjdk-11/bin is this:

/usr/lib64/jvm/java-11-openjdk-11/bin
├── jar
├── jarsigner
├── java
├── javac
├── javadoc
├── javap
├── jcmd
├── jconsole
├── jdb
├── jdeprscan
├── jdeps
├── jfr
├── jhsdb
├── jimage
├── jinfo
├── jjs
├── jlink
├── jmap
├── jmod
├── jps
├── jrunscript
├── jshell
├── jstack
├── jstat
├── jstatd
├── keytool
├── pack200
├── rmic
├── rmid
├── rmiregistry
├── serialver
└── unpack200

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants