eclipsesource / J2V8

Java Bindings for V8
2.54k stars 355 forks source link

J2V8 Build issue #576

Open emokhub opened 2 years ago

emokhub commented 2 years ago

Hello Team, I followed the build instructions as per the BUILDING.md for linux and android. For below cases, build is failing for me.

Interactive android-arm @ Docker linux-x64 @ Docker

Error: Step 16/54 : RUN mkdir -p ${ANDROID_HOME} && cd ${ANDROID_HOME} && wget -q https://dl.google.com/android/repository/sdk-tools-linux-3859397.zip -O android_tools.zip && unzip -qq android_tools.zip && rm android_tools.zip ---> Running in 2e3159d57e19 The command '/bin/sh -c mkdir -p ${ANDROID_HOME} && cd ${ANDROID_HOME} && wget -q https://dl.google.com/android/repository/sdk-tools-linux-3859397.zip -O android_tools.zip && unzip -qq android_tools.zip && rm android_tools.zip' returned a non-zero code: 5 Traceback (most recent call last): File "build.py", line 13, in <module> interactive.run_interactive_cli() File "/home/test/gitrepos/J2V8/build_system/build_interactive.py", line 58, in run_interactive_cli bex.execute_build(build_params) File "/home/test/gitrepos/J2V8/build_system/build_executor.py", line 279, in execute_build execute_build_step(cross_compiler, cross_cfg) File "/home/test/gitrepos/J2V8/build_system/build_executor.py", line 231, in execute_build_step build_system.build(build_step) File "/home/test/gitrepos/J2V8/build_system/build_structures.py", line 95, in build self.pre_build(config) File "/home/test/gitrepos/J2V8/build_system/docker_build.py", line 155, in pre_build self.exec_host_cmd("docker build " + args_str + " -f $PLATFORM/Dockerfile -t \"" + image_name + "\" . ", config) File "/home/test/gitrepos/J2V8/build_system/build_structures.py", line 105, in exec_host_cmd self.__exec_cmd_core(cmd, config, config.host_cwd) File "/home/test/gitrepos/J2V8/build_system/build_structures.py", line 122, in __exec_cmd_core utils.execute(cmd, cwd) File "/home/test/gitrepos/J2V8/build_system/build_utils.py", line 157, in execute raise subprocess.CalledProcessError(return_code, cmd) subprocess.CalledProcessError: Command 'docker build --build-arg KEYSTORE=$KEYSTORE --build-arg KEYSTORE_PASSWORD=$KEYSTORE_PASSWORD -f android/Dockerfile -t "j2v8-android" . ' returned non-zero exit status 5 Waiting for docker process to exit...

Non-interactive build -t linux -a x64 -dkr

Error:

/usr/bin/python -u tools/mb/mb.py gen -f infra/mb/mb_config.pyl -m developer_default -b x64.release out.gn/x64.release

Writing """\ is_debug = false target_cpu = "x64" """ to /v8build/v8/out.gn/x64.release/args.gn.

/v8build/v8/buildtools/linux64/gn gen out.gn/x64.release --check -> returned 1 ERROR at //build/config/sysroot.gni:65:11: Script returned non-zero exit code. exec_script("//build/dir_exists.py", ^---------- Current dir: /v8build/v8/out.gn/x64.release/ Command: python3 /v8build/v8/build/dir_exists.py /v8build/v8/build/linux/debian_sid_amd64-sysroot Returned 127. stderr:

python3: error while loading shared libraries: libcrypt.so.1: cannot open shared object file: No such file or directory

See //build/toolchain/linux/BUILD.gn:6:1: whence it was imported. import("//build/config/sysroot.gni") ^---------------------------------- See //BUILD.gn:1310:1: which caused the file to be included. action("postmortem-metadata") { ^------------------------------

Anyone able to build J2V8 successfully with recent codebase? any pointers would definitely help.

Thanks a lot!

blabno commented 1 year ago

I had to check out 878080f8f30970e5908a68bfdcab26fac99cebfc and modify sys_image to debian:buster at https://github.com/eclipsesource/J2V8/blob/878080f8f30970e5908a68bfdcab26fac99cebfc/docker/linux/Dockerfile#L2.

The debian:buster docker image resolves for me to 26cc15e1a069.