Add docker usage

This commit is contained in:
Marcos Luciano
2022-08-19 13:41:49 -03:00
parent f62a2d627b
commit 89089145fd
2 changed files with 45 additions and 6 deletions

View File

@@ -25,12 +25,12 @@
CUDA_VER?=
ifeq ($(CUDA_VER),)
$(error "CUDA_VER is not set")
$(error "CUDA_VER is not set")
endif
OPENCV?=
ifeq ($(OPENCV),)
OPENCV=0
OPENCV=0
endif
CC:= g++
@@ -40,9 +40,9 @@ CFLAGS:= -Wall -std=c++11 -shared -fPIC -Wno-error=deprecated-declarations
CFLAGS+= -I/opt/nvidia/deepstream/deepstream/sources/includes -I/usr/local/cuda-$(CUDA_VER)/include
ifeq ($(OPENCV), 1)
COMMON= -DOPENCV
CFLAGS+= $(shell pkg-config --cflags opencv4 2> /dev/null || pkg-config --cflags opencv)
LIBS+= $(shell pkg-config --libs opencv4 2> /dev/null || pkg-config --libs opencv)
COMMON= -DOPENCV
CFLAGS+= $(shell pkg-config --cflags opencv4 2> /dev/null || pkg-config --cflags opencv)
LIBS+= $(shell pkg-config --libs opencv4 2> /dev/null || pkg-config --libs opencv)
endif
LIBS+= -lnvinfer_plugin -lnvinfer -lnvparsers -L/usr/local/cuda-$(CUDA_VER)/lib64 -lcudart -lcublas -lstdc++fs
@@ -53,7 +53,7 @@ INCS:= $(wildcard *.h)
SRCFILES:= $(filter-out calibrator.cpp, $(wildcard *.cpp))
ifeq ($(OPENCV), 1)
SRCFILES+= calibrator.cpp
SRCFILES+= calibrator.cpp
endif
SRCFILES+= $(wildcard layers/*.cpp)