Skip to content

Commit

Permalink
Fix arch labeling issue on Mac CI for Java build (#1784)
Browse files Browse the repository at this point in the history
* X

* Y

* Force arch ARM64

* OK
  • Loading branch information
mewim committed Jul 8, 2023
1 parent dfe42f2 commit 6f1999a
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
2 changes: 1 addition & 1 deletion .github/workflows/mac-java-workflow.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ jobs:

- name: Build Java lib for Apple Silicon
run: |
env JAVA_HOME=$(/usr/libexec/java_home) make java NUM_THREADS=8
arch -arm64 env JAVA_HOME=$(/usr/libexec/java_home) make java NUM_THREADS=8
env:
MACOSX_DEPLOYMENT_TARGET: 11.0
ARCHFLAGS: "-arch arm64"
Expand Down
3 changes: 3 additions & 0 deletions tools/java_api/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,10 @@ include_directories(${JNI_INCLUDE_DIRS} ${_classDir} ${_stubDir})
add_library(kuzu_java_native SHARED src/jni/kuzu_java.cpp)
target_link_libraries(kuzu_java_native PRIVATE kuzu_native_header kuzu)

message(STATUS "OS_NAME=${OS_NAME}")
message(STATUS "OS_ARCH=${OS_ARCH}")
string(JOIN "_" LIB_SUFFIX ".so" ${OS_NAME} ${OS_ARCH})

set_target_properties(kuzu_java_native PROPERTIES SUFFIX ${LIB_SUFFIX})
set_target_properties(kuzu_java_native PROPERTIES PREFIX "lib")
set_target_properties(kuzu_java_native
Expand Down

0 comments on commit 6f1999a

Please sign in to comment.