I am trying to make the clean command in the makefile. When I just write make it compiles and makes the file but when I use the make clean command it gives me an error.
rm *.o
process_begin: CreateProcess(NULL, rm *.o, ...) failed.
make (e=2): The system cannot find the file specified.
make: *** [Makefile:17: clean] Error 2
this is the error I am getting and the make file is as shown below. Any help would be appreciated thank you very much.
output: main.o account.o limitedAccount.o unlimitedAccount.o
g++ main.o account.o limitedAccount.o unlimitedAccount.o -o output
main.o: main.cpp
g++ -c main.cpp
account.o: account.cpp
g++ -c account.cpp
limitedAccount.o: limitedAccount.cpp
g++ -c limitedAccount.cpp
unlimitedAccount.o: unlimitedAccount.cpp
g++ -c unlimitedAccount.cpp
clean:
rm *.o