Swift stdlib tool Error
<p>I'm getting this error on compilation with Xcode 8.1 and Swift 3:</p>

<blockquote>
  <p>Swift stdlib tool Error</p>
</blockquote>

<p>The end of the compile log looks like:</p>

<pre><code>/Users/..../Library/Developer/Xcode/DerivedData/.../Build/Products/Debug/.../Contents/Frameworks/libswiftCore.dylib: replacing existing signature
/Users/..../Library/Developer/Xcode/DerivedData/.../Build/Products/Debug/.../Contents/Frameworks/libswiftCore.dylib: CSSMERR_CSP_INVALID_CONTEXT_HANDLE
In architecture: x86_64
Probing signature of /Users/..../Library/Developer/Xcode/DerivedData/.../Build/Products/Debug/.../Contents/Frameworks/libswiftXPC.dylib
  /usr/bin/codesign '-r-' '--display' '/Users/..../Library/Developer/Xcode/DerivedData/.../Build/Products/Debug/.../Contents/Frameworks/libswiftXPC.dylib'
error: Task failed with exit 1 signal 0 {
    /usr/bin/codesign '--force' '--sign' '-' '--verbose' '/Users/..../Library/Developer/Xcode/DerivedData/.../Build/Products/Debug/.../Contents/Frameworks/libswiftCore.dylib'
}
</code></pre>

<p>The very strange thing is that if I copy the folder with the project to my Desktop, it does compile without the error. If I copy it elsewhere, it errors. Moving it back and forth a couple of times to verify, finally after the third move, it's erroring on the Desktop as well.</p>

<p>Any ideas?</p>

<p>Many thanks in advance.</p>