I need on making a make file

I am try to make a makefile. but didnt work

i type touch makefile ---> makefile create ----> in the makefile i write this
1
2
3
4
5
6
7
8
9
10
11
12
13
  CC = gcc
  CFLAGS  = -g -Wall

  # the build target executable:
  TARGET = proj1.c

  all: $(TARGET)

  $(TARGET): $(TARGET).c
  	$(CC) $(CFLAGS) -o $(TARGET) $(TARGET).c

  clean:
  	$(RM) $(TARGET)
--->run it

but problem is i chose input file and outfile but dont see an output file


I do have test.txt and proj1.c in same dic


Fatal error in reader: Makefile, line 7: Unexpected end of line seen
Last edited on
I don't think you can start each line with 3 spaces like you have.
Topic archived. No new replies allowed.