I saved the file as hello.c, and I think I'm inside /workspace/pset1/hello
However, I get the message "Nothing to be done for hello c.
Any idea what I'm doing wrong?
CS50 Stack Exchange is a question and answer site for students of Harvard University's CS50. It only takes a minute to sign up.Sign up to join this community
make's correct usage in this context is
make outfile, not
Without a Makefile (which just tells make how to compile more complicated programmes - covered in pset3),
make infers the source file to compile from the output filename.
make foo finds the file
foo.c in the present working directory, and if it exists and can be compiled, make creates the file
make searches for hello.c.c, which doesn't exist (In reality, this wouldn't work either due to
make's built-in rules regarding C programmes, but you get it).