Quantcast
Channel: UNIX and Linux Forums
Viewing all articles
Browse latest Browse all 16232

Makefile help

$
0
0
I am creating a make file, but i keep getting an error when i try to run it with the following code:

Code:

make foo . make $(EXE)
i get

Code:

EXE: command not found
make: `foo' is up to date.
make: Nothing to be done for `.'.
make: *** No rule to make target `make'.  Stop.

Here is my Makefile

Code:

cc  = gcc
EXE = foo
JAVAC = javac
JRE = java
PAGER = less
TEST_OUT = test.out
EXP_OUT = expected.out

foo.o: foo.c foo.h
  $(cc) -c foo.c

main.o: main.c foo.h
  $(cc) -c main.c

$(EXE): foo.o main.o
  $(cc) -o$(EXE) main.o foo.o

run-c: $(EXE)
  ./$(EXE)

Not sure what the errors mean

Viewing all articles
Browse latest Browse all 16232

Latest Images

Trending Articles



Latest Images