When I write Makefile below, It went run,how to solve?
hideqr.o : hide_pic.cpp hide_pic.h
g++ ${CPP_FLAGS} -c $< -I/home/wangxiaofei01/hideqr/hideqr/hideqr/include -o $@
When I write Makefile below, It went run,how to solve?
hideqr.o : hide_pic.cpp hide_pic.h
g++ ${CPP_FLAGS} -c $< -I/home/wangxiaofei01/hideqr/hideqr/hideqr/include -o $@
First, chechout if the file of hide_pic.h has the common dir path with Makefile, if not, then change hideqr.o : hide_pic.cpp hide_pic.h to hideqr.o : hide_pic.cpp, then use -I option to specify hide_pic.h path; The example is below;
HDIEQR_ROOT:=$(shell cd ../../.. && pwd)
HIDEQR_INCLUDE = -I$(HDIEQR_ROOT)/hideqr/hideqr/include
$(warning $(HIDEQR_INCLUDE)) # -I/home/wangxiaofei01/hideqr/hideqr/hideqr/include
hideqr.o : hide_pic.cpp
g++ ${CPP_FLAGS} -c $< $(HIDEQR_INCLUDE) -o $@