You are here

Bug in the BuildBindings.py with Linux kernel version

3 posts / 0 new
Last post
Bug in the BuildBindings.py with Linux kernel version
#1

Hi,
I think I have found a rather minor bug. It happens only with Linux. I don't know if there is a report system for this, so I am posting it on the forum.
Thanks for your work with Rosetta, it is really amazing.
Cyril

Context:
I am building pyrosetta from source, using the BuildPyRosetta.sh generated by rosetta/tools/PyRosetta.develop/DeployPyRosetta.py.

Problem:
During the mini-lib linking step of BuildBindings.py, a 'change directory' command fails because the lib_path variable is incorrect in my case:
"cd build/src/pyrosetta/linux/3.1/64/x86/gcc/4.9/default/"
The correct filepath is build/src/pyrosetta/linux/3.15/64/x86/gcc/4.9/default/
lib_path's start is set in the get_all_rosetta_objs function using :
"if Platform == "linux":
lib_path = 'build/src/'+mode+'/linux/' + platform.release()[:3] + '/' + PlatformBits +'/x86/gcc/'"
platform.release() returns '3.15.5-2-ARCH', the '5' disappears.
Conclusion: when a minor version of the Linux kernel has more than one digit, the build will fail...

Suggested change:
[line 793, at the beginning of get_all_rosetta_objs]
lib_path = 'build/src/'+mode+'/linux/' + re.search(r'(\d\.\d+)\..*',platform.release()).group(1) + '/' + PlatformBits +'/x86/gcc/'
This seems to solve the issue.

Configuration:
Rosetta version: 2014.22.56873
ArchLinux distribution (rolling release)
Kernel: x86_64 Linux 3.15.5-2-ARCH
Python 2.7.8 using virtualenv
gcc version 4.9.1 (GCC) => unsupported, I know... Rosetta install is possible with a few tweaks. Does not matter here.

Post Situation: 
Mon, 2014-07-28 12:07
Cyril Cros

Feel free to post bugs here, but you can also submit bugs on our bug tracker at http://bugs.rosettacommons.org

I've submitted one for you on this issue: https://carbon.structbio.vanderbilt.edu/mantisbt/view.php?id=349

Mon, 2014-08-04 13:55
rmoretti

Thank you for the report and path Cyril! I will apply it to mainstream.

Best,

Wed, 2014-08-13 10:34
Sergey