I wrote a makefile to compile and link all the files in my project. Right now i only have 2 cpp files: src/main.cpp
and src/DBEngine/benchmark/ssb/ssb_main.cpp
.
My makefile content is :
CPP_FILES := $(wildcard src/*.cpp) $(wildcard src/DBEngine/benchmark/ssb/*.cpp)
OBJ_FILES := $(addprefix bin/obj/,$(notdir $(CPP_FILES:.cpp=.o)))
DEBUG_OBJ_FILES := $(addprefix bin/debug/,$(notdir $(CPP_FILES:.cpp=.o)))
CC_FLAGS := -I${PWD}
main.out: $(OBJ_FILES)
g++ -o $@ $(OBJ_FILES)
bin/obj/%.o: src/%.cpp
g++ -c -o $@ $< (CC_FLAGS) -w
But when i do a make it gives the error :
make: *** No rule to make target
bin/debug/ssb_main.o
, needed bymain.out
. Stop.