4paradigm / 4paradigm/OpenMLDB

higher cmake may failed on find jni in required mode

Đang mở
#2,883 3 bình luận 0 reaction 1 người được giao Được @vagetablechicken nhận Xem trên GitHub
bug build
Ngôn ngữ chính
C++
Star
1.7k
Fork
331
Merge trung bình
12 ngày 12 giờ
Pull request đã merge (30 ngày)
1

Mô tả

In higher cmake e.g. 3.24.1 https://github.com/Kitware/CMake/blob/v3.24.1/Modules/FindJNI.cmake
FindJNI will find the components, jvm and jawt, it's set by
https://github.com/Kitware/CMake/blob/8c7ac278cd5af00e0f6ec661635921af40ae3839/Modules/FindJNI.cmake#L119-L120

If we can find the Main JNI target, but can't find jvm and jawt(some weird env), it'll fatal too.
```
Could NOT find JNI (missing: AWT)
```

`set(JNI_FIND_COMPONENTS )` doesn't work.
If find missing components, `JNI_FOUND` will be FALSE.

Hướng dẫn đóng góp

Mở hướng dẫn đóng góp

Hướng nghiên cứu

Look at the CMake configuration for JNI, likely in CMakeLists.txt or related build scripts. Understand how FindJNI.cmake works in CMake 3.24.1 and later. The issue is that missing components (jvm, jawt) cause JNI_FOUND to be false even if the main JNI target is found. Check the environment and see if setting JNI_FIND_COMPONENTS can be adjusted or if the find_package call needs modification. Test the build with a higher CMake version to reproduce the error.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Đánh giá

Công nghệ
cmake
Lĩnh vực
build-system
Loại issue
Lỗi
Độ khó
3/5
Thời gian dự kiến
1-2 ngày
Mức độ hoạt động
Đình trệ
Độ rõ ràng
Khá rõ ràng
Mức phù hợp với người mới
45/100

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.