[ROOT-7436] CompileMacro fails if unrelated TCanvas is created Created: 25/Jun/15  Updated: 25/Jun/15  Resolved: 25/Jun/15

Status: Closed
Project: ROOT
Component/s: CINT, Cling, Graphics, PyROOT
Affects Version/s: 6.04.00
Fix Version/s: 6.06/00, 6.04/02, 6.02/14

Type: Bug Priority: High
Reporter: Christopher Lester Assignee: Axel Naumann
Resolution: Fixed Votes: 0
Labels: None
Environment:

Clean install of root_v6.04.00.macosx64-10.10-clang61.dmg from https://root.cern.ch/drupal/content/production-version-604
on an OSX Yosemite 10.10.3 intel macbook air with Version 6.3.2 (6D2105)

lester@mac:test $ which python
/usr/bin/python
lester@mac:test $ python
Python 2.7.6 (default, Sep 9 2014, 15:04:36)
[GCC 4.2.1 Compatible Apple LLVM 6.0 (clang-600.0.39)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>>


Attachments: Text File BAD.txt     Text File GOOD.txt     File test.py    
Development:

 Description   

The attached file test.py creates a file "moo.cxx" containing the text "int moo()

{ return 0; }

"
It then asks gSystem to compile it with ROOT.gSystem.CompileMacro("moo.cxx","vfO")

If the word "crash" is given as a command line argument to the script, the compilation above is preceded by the creation of a canvas:
c = ROOT.TCanvas(),
otherwise no canvas is created.
Compilation fails if the canvas is created, and doesn't fail if the canvas is not created. Full output is provided as attachments GOOD.txt and BAD.txt generated as follows (assumes bash):

lester@mac:test $ python -u test.py do_not_crash > GOOD.txt 2>&1
lester@mac:test $ python -u test.py crash > BAD.txt 2>&1

To "quickly" see whether the failure occurred, one could do:

            1. EXAMPLE OF FAILURE (assumes bash shell) #######
              lester@mac:test $ python -u test.py crash 2>&1 | grep -i Error | tail -3
              clang: error: no such file or directory: 'cl_kernels'
              clang: error: no such file or directory: 'cl_kernels'
              Error in <ACLiC>: Compilation failed!
              lester@mac:test $
              ####################################################
            1. EXAMPLE OF SUCCESS (assumes bash shell) #######
              lester@mac:test $ python -u test.py do_not_crash 2>&1 | grep -i Error | tail -3
              lester@mac:test $
              ####################################################

which suggests a link to the problem reported here:

https://groups.cern.ch/group/roottalk/Lists/Archive/Flat.aspx?RootFolder=%2fgroup%2froottalk%2fLists%2fArchive%2fACliC%20no%20such%20file%20or%20directory%20%27cl%5fkernels%27&FolderCTID=0x01200200A201AF59FD011C4E9284C43BF0CDA2A4

which promised a fix in this version of root, that has evidently not appeared

Note that the logs show the compilation environment appears to be polluted by references to many directories created by user "jenkins" (a distributor/pacakage manager?) and it is only by "luck" that these don't also cause problems. The cl_kernels are therefore not the issue per-se, it is the pollution of the ACLIC compilation environment that seems to be the problem.



 Comments   
Comment by Christopher Lester [ 25/Jun/15 ]

I should note, that the bug goes away if root is put into batch mode before the canvas creation. This is the "workaround" that I have been using.

Comment by Axel Naumann [ 25/Jun/15 ]

Hi,

Fixed in all active ROOT 6 branches - thanks for reporting!

Axel.

Comment by Christopher Lester [ 25/Jun/15 ]

Thank you – am pleased to hear it is "fixed".

Do you know how soon I have to wait for a "fixed" dmg file to appear at https://root.cern.ch/drupal/content/production-version-604 ... or will I have to wait for 6.05 ?

PS - what was the fix?

Comment by Axel Naumann [ 25/Jun/15 ]

The fix is http://root.cern.ch/gitweb/?p=root.git;a=commit;h=6c4dacc3d8880d3ef5f399dd8e64806e3463857b

We will tag a new 6.04 patch release before Friday next week.

Cheers, Axel.

Generated at Tue Sep 24 11:08:34 CEST 2019 using Jira 7.13.1#713001-sha1:5e06076c2d215a6f699b7e5c90ab2fae7ba5a1ce.