[Chimera-users] BioPython in a Chimera Python script; PDBio?

Tom Goddard goddard at sonic.net
Tue Jan 7 16:15:26 PST 2014


Hi Darrell,

  Chimera is compiled on Mac OS 10.6.  The compilation explicitly specifies MacOSX10.6.sdk and that setting gets put into the Chimera Python configuration files.   So when you try to install a Python module using the Chimera Python and it requires compiling some C or C++ code it attempts to use the same compiler and same settings that Python itself was compiled with to assure that the new compiled module will work with Python.  But as you point out Mac OS 10.8 (and 10.9) don't have the Mac 10.6 SDK files.  And in fact Apple changed the location where SDK files live.  I have encountered this and on my Mac 10.8 system use a symbollic link

  /Developer/SDKs -> /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs

so that when I recompile parts of Chimera on my Mac 10.8 machine that were originally compiled on Mac 10.6 it can find the 10.6 SDKs.

  It seems you already figured out all of the above.  Your error says it cannot find "xcrun".  xcrun is in /usr/bin on my Mac 10.8 system

$ locate xcrun
/Applications/Xcode.app/Contents/Developer/usr/bin/xcrun
/Applications/Xcode.app/Contents/Developer/usr/share/man/man1/xcrun.1
/usr/bin/xcrun
/usr/share/man/man1/xcrun.1

and on our Mac 10.6 build machine it is also in /usr/bin

$ locate xcrun
/Developer/usr/share/man/man1/xcrun.1
/private/var/db/receipts/com.apple.pkg.xcrunLeo.bom
/private/var/db/receipts/com.apple.pkg.xcrunLeo.plist
/usr/bin/xcrun
/usr/share/man/man1/xcrun.1

Is xcrun in /usr/bin on your computer?

If your goal is to get title and doi info from PDB files, it would be much easier to do the minor parsing needed on the records obtained from Chimera.  Installing BioPython just to do that is hitting a needle with a sledgehammer.  But maybe you have other reasons for wanting BioPython in Chimera.

  I'm not sure what you mean by "EMDB records".  If you mean the XML meta data file provided by EMDB, Chimera does not fetch that because it doesn't need any data it contains currently.  I used it many years ago to find the PDB entries fit to an EMDB map but switched that to use and EMDB web service instead of the XML file.  If instead you mean you want the header values of the EMDB CCP4 binary map files, Chimera reads those and I can tell you how to get them if you are interested.

	Tom



On Jan 7, 2014, at 11:55 AM, "Hurt, Darrell (NIH/NIAID) [E]"  wrote:

> Hi Chimera friends,
> 
> I've been trying to install BioPython into the Python interpreter embedded within Chimera. I've been following the guidelines posted a couple of years ago:
> http://www.cgl.ucsf.edu/pipermail/chimera-dev/2011/000807.html
> 
> This works up to a point for me. I'm using Mac OS X 10.8.5 with MacPorts installed. I'm trying to install BioPython 1.63:
> http://biopython.org/wiki/Download#Installation_Instructions
> 
> The "build" process starts to work, but gets hung up with the error "xcrun: Error: failed to exec real xcrun. (No such file or directory)". It seems to be referencing "/Developer/SDKs/MacOSX10.6.sdk", which does not exist in recent versions of Xcode. I've been able to install the 10.6 frameworks into both Xcode 4.6.2 and Xcode 5.x, but that still doesn't work. I manually installed the MacOSX10.6.sdk from Xcode 4.2 into the appropriate location, but still no luck.
> 
> I'm using BioPython because I want to pull some information out of the PDB headers. I was able to use PDBio as described in this discussion:
> http://www.cgl.ucsf.edu/pipermail/chimera-users/2007-February/001291.html
> 
> But the "dictionary" entries "keyed by record type" need additional cleanup/parsing before I can use them (which is why I wanted to use BioPython).
> 
> Is this just a case of Apple not building in enough backwards compatibility? Or is it something that Chimera needs to fix?
> 
> Do you have any additional suggestions for me about "PDBio"? The fields I want are the DOI and title information.
> 
> Finally, is there an analogous "EMDBio" for EMDB records?
> 
> Thanks,
> Darrell
> 
> --
> Darrell Hurt, Ph.D.
> Section Head, Computational Biology
> Bioinformatics and Computational Biosciences Branch (BCBB)
> OCICB/OSMO/OD/NIAID/NIH
> 
> 31 Center Drive, Room 3B62B, MSC 2135
> Bethesda, MD 20892-2135
> Office: 301-402-0095
> Mobile: 301-758-3559
> Web: BCBB Home Page<http://www.niaid.nih.gov/about/organization/odoffices/omo/ocicb/Pages/bcbb.aspx#niaid_inlineNav_Anchor>
> Twitter: @niaidbioit<https://twitter.com/niaidbioit>
> 
> Disclaimer: The information in this e-mail and any of its attachments is confidential and may contain sensitive information. It should not be used by anyone who is not the original intended recipient. If you have received this e-mail in error please inform the sender and delete it from your mailbox or any other storage devices. National Institute of Allergy and Infectious Diseases shall not accept liability for any statements made that are sender's own and not expressly made on behalf of the NIAID by one of its representatives.
> 
> _______________________________________________
> Chimera-users mailing list
> Chimera-users at cgl.ucsf.edu
> http://plato.cgl.ucsf.edu/mailman/listinfo/chimera-users
> 





More information about the Chimera-users mailing list