View Full Version : Eclipse "Launch Failed: No Binaries"

10-11-2007, 09:51 PM
I'm using Eclipse for making C++ applications. Sometimes it runs smoothly, and sometimes, when I try compiling the program, I get a "No Binaries" issue. I've tried all the various ways of creating a C++ project it has to offer by default. Now, I'm running into this problem again, and I need to compile a program for my class tonight.

If anyone can help me, that would be great.

Here's my source if anyone wants to try compiling it if it works as is, which is doubtful.

//Program #14 Writing Structs to Files, Thomas Eding CS265-8051

#include <cstdlib>
#include <fstream>
#include <iostream>

using namespace std;

struct Record {
char name[15];
double amt;

void printRecord(const Record &r) {
cout << "Name: " << r.name << "\nAmount: " << r.amt << "\n";

int main() {
Record master[10] = {{"Helen", 10}, {"Julie", 20}, {"Lena", 30}, {"Alan", 40}, {"Annie", 50}, {"May", 60}, {"Lee", 70}, {"Sam", 80}, {"June", 90}, {"Bill", 100}};
Record trans[7] = {{"Lena", 10}, {"Julie", 5.75}, {"Lee", 15.02}, {"Ed", 40}, {"Julie", 10}, {"Art", 5}, {"Bill", 7.32}};
ofstream fout;
fout.open("master.dat", ios::binary);
for(int i=0; i<10; ++i) fout.write((char*) &master[i], sizeof(Record));
fout.open("trans.dat", ios::binary);
for(int i=0; i<7; ++i) fout.write((char*) &trans[i], sizeof(Record));
Record temp;
ifstream fin;
fin.open("master.dat", ios::binary);
cout << "master.dat records:\n\n";
for(int i=0; i<10; ++i) {
fin.read((char*) &temp, sizeof(Record));
fin.open("trans.dat", ios::binary);
cout << "trans.dat records:\n\n";
for(int i=0; i<7; ++i) {
fin.read((char*) &temp, sizeof(Record));
return 0;

10-11-2007, 10:51 PM
You're missing a colon after the ending brace of the struct definition, but other than that it's OK. I must say, though, it looks like a badly-translated C program. This is a task to which a class would be perfectly suited.

A quick Google (http://www.google.com/search?q=eclipse+%22no+binaries%22) turned up a whole load of posts on various issues. I don't know which one matches your problem best, but you're sure to find an answer in there somewhere.

10-11-2007, 10:56 PM
I would use classes, but my teacher wanted structs to be used, and I didn't feel like putting much effort into it :p

Aha! I just had to select the right compiler, mingw, not cygwin