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

libclingJupyter.so didn't created using build instructions #537

Open
orhosko opened this issue Oct 27, 2024 · 0 comments
Open

libclingJupyter.so didn't created using build instructions #537

orhosko opened this issue Oct 27, 2024 · 0 comments
Labels

Comments

@orhosko
Copy link

orhosko commented Oct 27, 2024

After using these commands, cling works as expected.

git clone https://github.com/root-project/llvm-project.git
cd llvm-project
git checkout cling-latest
cd ..
git clone https://github.com/root-project/cling.git
mkdir cling-build && cd cling-build
cmake -DLLVM_EXTERNAL_PROJECTS=cling -DLLVM_EXTERNAL_CLING_SOURCE_DIR=../cling/ -DLLVM_ENABLE_PROJECTS="clang" -DLLVM_TARGETS_TO_BUILD="host;NVPTX" -DCMAKE_BUILD_TYPE=Release ../llvm-project/llvm
cmake --build . --target clang
cmake --build . --target cling

However when I run these instructions for Jupyter support

export PATH=/cling-install-prefix/bin:$PATH
cd /cling-install-prefix/share/cling/Jupyter/kernel

pip install -e .
jupyter-kernelspec install --user cling-cpp17
jupyter-kernelspec install --user cling-cpp1z
jupyter-kernelspec install --user cling-cpp14
jupyter-kernelspec install --user cling-cpp11

I got kernel inside Jupyter but it dies immediately. As far as i understood, the earlier issues solved with an update and there is no similar problems. Here is the error:

    raise RuntimeError('Cannot find ' + clingInstDir + '/lib/libclingJupyter.{so,dylib,dll}')
RuntimeError: Cannot find /home/xxx/Documents/projects/cling/cling-build/lib/libclingJupyter.{so,dylib,dll}

It seemes like the file doesn't even created in .../cling-build/lib/. So, I don't think it's about not finding the file. When I ran make command inside .../cling-build/tools/cling/tools/Jupyter, it solved the issue. Now, I have .../cling-build/lib/libclingJupyter.so and works fine.

I didn't get any error while linking and my consecutive runs didn't changed anything. Maybe important point, I learnt that I need to run first after my first error cmake --build . --target clang. However, I also ran cmake --build . --target cling afterwards so I don't think this is the issue.

I'm on fedora 40 and ran soft linked directory from another drive if it helps.

@orhosko orhosko added the bug label Oct 27, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant