i try to develop a make file and i got this error :

Dependency line needs colon or double colon operator.

my makefile is in this state yet:

Books.o: Books.cpp include/author.h include/Booksh.h include/library.h
	xlC -c SourceFiles/Books.cpp -l vista -L/sbx/asc/slib -I/user/serkans/myprog/BookLibraryTrial/include -I/sbx/asc/vista

libMan : main.cpp cmnlib/libfoo.a
	xlC main.cpp cmnlib/libfoo.a  -l vista -L/sbx/asc/slib -I/sbx/asc/vista -I/sbx/asc/inst/TRAINING++/include -bhalt:5

what could be the problem?

i solved that problem, it is because of the empty lines in a make file. Also if you edit a file in a unix server using microsoft visual studio.net, it causes some wierd characters at the end of the lines. So you have to configure the line endings so as not to cause problems

There are also linux utilties dos2unix and unix2dos (or something like that) that will convert the line endings to the appropriate type.

I'm glad you got it working.


This question has already been answered. Start a new discussion instead.