<html><head><meta http-equiv="Content-Type" content="text/html charset=us-ascii"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;">Hi,<div><br></div><div>I'm using CMake 3.0.2 on OS X 10.9.4.  When I do a "make install", it's somehow corrupting some of my libraries at install time.</div><div><br></div><div>Here is what otool reports for the library in my build directory - that is, the state of the library prior to installation:</div><div><br></div><div><div style="margin: 0px; font-size: 10px; font-family: Monaco;">$ otool -L libOpenMMAmoebaCUDA.dylib </div><div style="margin: 0px; font-size: 10px; font-family: Monaco;">libOpenMMAmoebaCUDA.dylib:</div><div style="margin: 0px; font-size: 10px; font-family: Monaco;"><span class="Apple-tab-span" style="white-space:pre">  </span>/Users/peastman/workspace/openmm/bin-release/libOpenMMAmoebaCUDA.dylib (compatibility version 0.0.0, current version 0.0.0)</div><div style="margin: 0px; font-size: 10px; font-family: Monaco;"><span class="Apple-tab-span" style="white-space:pre">     </span>@rpath/CUDA.framework/Versions/A/CUDA (compatibility version 1.1.0, current version 6.0.37)</div><div style="margin: 0px; font-size: 10px; font-family: Monaco;"><span class="Apple-tab-span" style="white-space:pre">     </span>/Users/peastman/workspace/openmm/bin-release/libOpenMM.dylib (compatibility version 0.0.0, current version 0.0.0)</div><div style="margin: 0px; font-size: 10px; font-family: Monaco;"><span class="Apple-tab-span" style="white-space:pre">       </span>@rpath/libcudart.6.0.dylib (compatibility version 0.0.0, current version 6.0.37)</div><div style="margin: 0px; font-size: 10px; font-family: Monaco;"><span class="Apple-tab-span" style="white-space:pre">        </span>/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 1197.1.1)</div><div style="margin: 0px; font-size: 10px; font-family: Monaco;"><span class="Apple-tab-span" style="white-space:pre">      </span>/Users/peastman/workspace/openmm/bin-release/libOpenMMCUDA.dylib (compatibility version 0.0.0, current version 0.0.0)</div><div style="margin: 0px; font-size: 10px; font-family: Monaco;"><span class="Apple-tab-span" style="white-space:pre">   </span>/Users/peastman/workspace/openmm/bin-release/libOpenMMAmoeba.dylib (compatibility version 0.0.0, current version 0.0.0)</div><div style="margin: 0px; font-size: 10px; font-family: Monaco;"><span class="Apple-tab-span" style="white-space:pre"> </span>/usr/local/cuda/lib/libcuda.dylib (compatibility version 1.1.0, current version 6.0.37)</div><div style="margin: 0px; font-size: 10px; font-family: Monaco;"><span class="Apple-tab-span" style="white-space:pre"> </span>@rpath/libcufft.6.0.dylib (compatibility version 0.0.0, current version 6.0.37)</div><div style="margin: 0px; font-size: 10px; font-family: Monaco;"><span class="Apple-tab-span" style="white-space:pre"> </span>/usr/lib/libc++.1.dylib (compatibility version 1.0.0, current version 120.0.0)</div></div><div><br></div><div>No problems.  Everything looks ok.  Now here is what it reports for the same library in the install directory - the is, the state of the library after installation:</div><div><br></div><div><div style="margin: 0px; font-size: 10px; font-family: Monaco;">$ otool -L /usr/local/openmm/lib/plugins/libOpenMMAmoebaCUDA.dylib </div><div style="margin: 0px; font-size: 10px; font-family: Monaco;">/usr/local/openmm/lib/plugins/libOpenMMAmoebaCUDA.dylib:</div><div style="margin: 0px; font-size: 10px; font-family: Monaco;"><span class="Apple-tab-span" style="white-space:pre">    </span>@rpath/libOpenMMAmoebaCUDA.dylib (compatibility version 0.0.0, current version 0.0.0)</div><div style="margin: 0px; font-size: 10px; font-family: Monaco;"><span class="Apple-tab-span" style="white-space:pre">   </span>@rpath/CUDA.framework/Versions/A/CUDA (compatibility version 1.1.0, current version 6.0.37)</div><div style="margin: 0px; font-size: 10px; font-family: Monaco;"><span class="Apple-tab-span" style="white-space:pre">     </span>@rpath/libOpenMM.dylib (compatibility version 0.0.0, current version 0.0.0)</div><div style="margin: 0px; font-size: 10px; font-family: Monaco;"><span class="Apple-tab-span" style="white-space:pre">     </span>@rpath/libcudart.6.0.dylib (compatibility version 0.0.0, current version 6.0.37)</div><div style="margin: 0px; font-size: 10px; font-family: Monaco;"><span class="Apple-tab-span" style="white-space:pre">        </span>/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 1197.1.1)</div><div style="margin: 0px; font-size: 10px; font-family: Monaco;"><span class="Apple-tab-span" style="white-space:pre">      </span>@rpath/libOpenMMCUDA.dylib (compatibility version 0.0.0, current version 0.0.0)</div><div style="margin: 0px; font-size: 10px; font-family: Monaco;"><span class="Apple-tab-span" style="white-space:pre"> </span>@rpath/libOpenMMAmoeba.dylib (compatibility version 0.0.0, current version 0.0.0)</div><div style="margin: 0px; font-size: 10px; font-family: Monaco;"><span class="Apple-tab-span" style="white-space:pre">       </span>/usr/local/cuda/lib/libcuda.dylib (compatibility version 1.1.0, current version 6.0.37)</div><div style="margin: 0px; font-size: 10px; font-family: Monaco;"><span class="Apple-tab-span" style="white-space:pre"> </span>@rpath/libcufft.6.0.dylib (compatibility version 0.0.0, current version 6.0.37)</div><div style="margin: 0px; font-size: 10px; font-family: Monaco;"><span class="Apple-tab-span" style="white-space:pre"> </span>/usr/lib/libc++.1.dylib (compatibility version 1.0.0, current version 120.0.0)</div><div style="margin: 0px; font-size: 10px; font-family: Monaco;">load command 22 size zero (can't advance to other load commands)</div></div><div><br></div><div>As expected, the absolute paths have been replaced by relative paths.  But it also now reports an error message at the end about "load command 22 size zero".  This error does not prevent the library from actually being loaded.  It seems to work fine as far as that is concerned.  However, if I try to use install_name_tool to make any further changes to the paths in the library it fails with an error message:</div><div><br></div><div><div style="margin: 0px; font-size: 10px; font-family: Monaco;">/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/install_name_tool: for architecture i386 object: /usr/local/openmm/lib/plugins/libOpenMMAmoebaCUDA.dylib malformed object (load command 22 cmdsize is zero)</div></div><div><br></div><div>Any idea what's going on?</div><div><br></div><div>Thanks!</div><div><br></div><div>Peter</div></body></html>