I have the following makefile for my program. It creates program.o file, but when I try running it
./program.o
I get the following error:
./statsh.o: Permission denied.
Any ideas why this might be happening?
HEADERS = statsh.h functions.h
default: statsh
statsh.o: statsh.c $(HEADERS)
gcc -c statsh.c -o statsh.o
statsh: statsh.o
gcc statsh.o -o statsh
clean:
-rm -f statsh.o
-rm -f statsh