Errors in make file : *** missing separator. Stop
centos, linux, makefile
Solution
You can find an explanation of this error in Appendix B Errors Generated by Make.
Every line in a recipe must begin with a tab character. The recipes starting with `$(C++)` and `$(CC)` near the top of your file do not seem to start with a tab character.
Additionally, the section
INCLUDE = \
-I./usr/include/sys
-I./Headers \
seems to be missing a backslash after `sys` and that same section (and many more) have superfluous empty lines.
Problem
I am facing errors in make file in CentOS 6.02 64 bit. I need to know what should be done to make the makefile workable. Any suggestion will be greatly helpful. My make file is pasted below: - ``` # .SUFFIXES: .cc $(.SUFFIXES) ALL = libpal.a #all = $(ALL) all: $(ALL) .cpp.o: $(C++) -o $@ -c $(PROF) $(CFLAGS) $*.cpp .cc.o: $(C++) -o $@ -c $(PROF) $(CFLAGS) $*.cc .c.o: $(CC) -o $@ -c $(PROF) $(CFLAGS) $*.c top_srcdir = .. OPENSSL_LIB_DIR = ../../ThirdPartyLibs/openssl-0.9.8e/include BOOST_DIR = ../../ThirdPartyLibs/boost/stage/lib BOOST_INCLUDE_DIR = ../../ThirdPartyLibs/boost CC = gcc C++ = g++ CCOPT = -Os -Wall -Wno-deprecated CCOPT_DEBUG = -Wall -g -Wno-deprecated PROF = STATIC = -static INCLUDE = \ -I./usr/include/sys -I./Headers \ -I$(top_srcdir)/PAL/Headers \ -I$(top_srcdir)/BaseMulti/Headers \ -I$(top_srcdir)/NetworkMulti/Headers \ -I$(top_srcdir)/RTP/Headers \ -I$(BOOST_INCLUDE_DIR) \ -I$(OPENSSL_LIB_DIR) \ LIBDIRS = \ -L$(BOOST_DIR) \ #XXX NLAYER define / MB_DEBUG DEFINE = -D_LINUX -DDEBUGLOG -D_INDENT_DB_PRINT -fsigned-char -fno-inline -D_REENTRANT -D_POSIX_PTHREAD_SEMANTICS -D_POSIX_PER_PROCESS_TIMER_SOURCE -D_PTHREADS -DUNICODE #-DDISABLE_LOG SHLIB_SUFFIX = .so SHLIB_LD = gcc -shared SHLIB_LD_LIBS = SHLIB_CFLAGS = -fPIC BFLAGS = $(DEFINE) $(INCLUDE) CFLAGS = $(CCOPT) $(BFLAGS) OBJ_C = OBJ_CC = \ ./Sources/PALsystime.o \ ./Sources/PALdebug.o \ ./Sources/PALdebuglog.o \ ./Sources/PALthread.o \ ./Sources/PALcritsec.o \ ./Sources/PALprofiler.o \ ./Sources/PALserializable.o \ ./Sources/PALinet.o \ ./Sources/PALnetwork.o \ ./Sources/PALsocket.o \ ./Sources/PALlocalhostUdpEvent.o \ ./Sources/PALpollarray.o \ ./Sources/PALrandom.o \ OBJS = $(OBJ_C) $(OBJ_CC) SRCS = $(OBJ_C:.o=.c) $(OBJ_CC:.o=.cc) debug: DEFINE += -DDEBUG debug: BFLAGS = $(DEFINE) $(INCLUDE) debug: CFLAGS = $(CCOPT_DEBUG) $(BFLAGS) debug: $(OBJS) ar crsu libpal_debug.a $(OBJS) libpal.a: $(OBJS) ar crsu libpal.a $(OBJS) cleandeps: $(RM) ./Sources/*.o .depend* core clean: cleandeps $(RM) ./libpal.a ./libpal_debug.a $(RM) $(ALL) ``` And the resultant error is: ``` Makefile:34: *** missing separator. Stop. ```