0

so I finished my find.c but when I run make find or make all I get the error "clang: error: cannot specify -o when generating multiple output files". What can I do?

1 Answer 1

1

Here's an answer to a similar problem from FaceBook:

I am getting a problem in pset3. whenever i try to compile "find.c"

The error goes like this:

jharvard@appliance (~/Dropbox/pset3): ls
breakout find jharvard@appliance (~/Dropbox/pset3): cd find
jharvard@appliance (~/Dropbox/pset3/find): make find 
clang -ggdb3 -O0 -std=c99 -Wall -Werror find.c helpers.c helpers.h -lcs50 -lm -o find
clang: error: cannot specify -o when generating multiple output files

Brilliant Person 1:

You modified the Makefile didn't you? Not sure why you did, but the clang command shouldn't include the .h file

OP:

I doubt that. Anyway, I'll check. Thanks

Brilliant Person 2:

OP, don't doubt it. Brilliant Person 1 is right. Makefile somehow got modified and it's the addition of the .h file that's messing things up.

OP

Ya I found it...thanks

If that doesn't help, please share the line showing the clang options.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .