Looks like no one’s replied in a while. To start the conversation again, simply ask a new question.

fatal error: error writing to -: Broken pipe

Why does this simple default program for Xcode fail in this way? I didn't code this, this is the default for a new C++ project in Xcode (3.2)


#include <iostream>


int main (int argc, char * const argv[]) {

// insert code here...

std::cout << "Hello, World!\n";

return 0;

}



What is really weird is that it worked the first time, and I have changed nothing. All proper files appear to be in the /Developer/usr/bin folder and it doesn't seem to have problems finding anything.

Xcode 3.2-OTHER, Mac OS X (10.6.8)

Posted on Jul 14, 2012 4:23 PM

Reply
2 replies

Jul 14, 2012 4:29 PM in response to joelsaxton

This is the salient portion of the log:


/Developer/usr/bin/../libexec/gcc/i686-apple-darwin10/4.2.1/as: assembler (/Developer/usr/bin/../libexec/gcc/darwin/i386/as or /Developer/usr/bin/../local/libexec/gcc/darwin/i386/as) for architecture i386 not installed

/Developer/usr/bin/../libexec/gcc/i686-apple-darwin10/4.2.1/as: no assemblers installed


writing to -: Broken pipe

compilation terminated.


For whatever reason, I see a shortcut to both "as" and "ld". It seems the Xcode installer has a bug in it.

fatal error: error writing to -: Broken pipe

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple ID.