mirror of https://github.com/AlexeyAB/darknet.git
Merge pull request #4341 from giordano/objdir-makefile
Add $(OBJDIR) as prerequisite to $(LIBNAMESO)
This commit is contained in:
commit
326d56a987
8
Makefile
8
Makefile
|
@ -127,12 +127,12 @@ endif
|
|||
OBJS = $(addprefix $(OBJDIR), $(OBJ))
|
||||
DEPS = $(wildcard src/*.h) Makefile include/darknet.h
|
||||
|
||||
all: obj backup results setchmod $(EXEC) $(LIBNAMESO) $(APPNAMESO)
|
||||
all: $(OBJDIR) backup results setchmod $(EXEC) $(LIBNAMESO) $(APPNAMESO)
|
||||
|
||||
ifeq ($(LIBSO), 1)
|
||||
CFLAGS+= -fPIC
|
||||
|
||||
$(LIBNAMESO): $(OBJS) include/yolo_v2_class.hpp src/yolo_v2_class.cpp
|
||||
$(LIBNAMESO): $(OBJDIR) $(OBJS) include/yolo_v2_class.hpp src/yolo_v2_class.cpp
|
||||
$(CPP) -shared -std=c++11 -fvisibility=hidden -DLIB_EXPORTS $(COMMON) $(CFLAGS) $(OBJS) src/yolo_v2_class.cpp -o $@ $(LDFLAGS)
|
||||
|
||||
$(APPNAMESO): $(LIBNAMESO) include/yolo_v2_class.hpp src/yolo_console_dll.cpp
|
||||
|
@ -151,8 +151,8 @@ $(OBJDIR)%.o: %.cpp $(DEPS)
|
|||
$(OBJDIR)%.o: %.cu $(DEPS)
|
||||
$(NVCC) $(ARCH) $(COMMON) --compiler-options "$(CFLAGS)" -c $< -o $@
|
||||
|
||||
obj:
|
||||
mkdir -p obj
|
||||
$(OBJDIR):
|
||||
mkdir -p $(OBJDIR)
|
||||
backup:
|
||||
mkdir -p backup
|
||||
results:
|
||||
|
|
Loading…
Reference in New Issue