Pyroot passing a single argument to ld when it should pass multiple?

I’m having trouble in some environments when I compile a macro using pyROOT. It works fine when I use C++ root.

The error message I get is
/usr/bin/ld: cannot find -lRint -lCore -L/home/ubuntu/root/lib
It appears that pyroot is, for some reason, passing "-lRint -lCore -L/home/ubuntu/root/lib" to ld as a single argument. Since there’s no such thing as 'libRint -lCore -L/home/ubuntu/root/', it fails.

I tested this explicitly by hacking ld to do for a; do echo $a; done before compiling, and my suspicion was correct, -lRint -lCore -L/home/ubuntu/root/lib is printed on one line.

As a minimal test, I use test.C:

#include <iostream>

void test() {
    std::cout << "hi" << std::endl;


import ROOT

If I run python, it fails. If I first run root -l -b -q test.C+, that works fine, and I can then successfully run python, since test.C is already compiled.

I’m running root 6.06.08 on the ubuntu virtual machines from CircleCI. You can see the output here:
On any other machine I can run root on, I don’t get this error.

Any suggestions would be greatly appreciated! I’m very confused.

I don’t know what the problem might be, but I cannot reproduce it with ROOT v6.10.

If you can’t reproduce it either with other installations of ROOT, the cause of the issue might very well be a malfunctioning ROOT installation on your CircleCI virtual machine.


Thanks for the suggestion. Actually I just download the precompiled tarball.

I’ve tried compiling from source on their machines, but they don’t allow commands that take more than 2 hours, and it killed it. I may be able to try again by hacking it to run in two steps. Do you think that would help?

Thank you again,

Uhm, I see…weird issue then.

Is switching to a newer release an option? If the issue is still present in e.g. v6.10 I will open a ticket about it.

Hey, my minimal test works with 6.10!! Thanks!

I’m going to try it for the setup that we actually use and get back to you.

1 Like

can I mark this as solved then? :smiley:

Sorry about that! Yes, go ahead. Thanks!!

1 Like

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.