From 3aedaf31a1f1bd8eb5220eb7fd06a7814786057d Mon Sep 17 00:00:00 2001 From: Chris Tallon Date: Tue, 7 Sep 2021 15:19:46 +0100 Subject: [PATCH] Makefile fixes --- GNUmakefile | 21 ++++++++++----------- 1 file changed, 10 insertions(+), 11 deletions(-) diff --git a/GNUmakefile b/GNUmakefile index 45e607b..c5cf6ab 100644 --- a/GNUmakefile +++ b/GNUmakefile @@ -15,13 +15,11 @@ vomp_platform=$(shell ./select-platform) $(info Build system selected: $(vomp_platform)) +CROSSROOT=/pi-root # uncomment the line below if you want to build vomp application without a reboot option, automatically set for windows! #VOMP_OPTIONS+= -DVOMP_HAS_EXIT -CROSSROOT=/pi-root -SYSROOT=--sysroot=$(CROSSROOT) - ifndef VERBOSE Q = @ endif @@ -63,13 +61,13 @@ LD=g++ #CXX=clang++-9 #LD=clang++-9 -LDFLAGS = -fuse-ld=gold $(PICTURES) +LDFLAGS = $(PICTURES) #-fuse-ld=gold DEFINES += -DIPV4 -DIPV6 LIBPATHS = -L/opt/vc/lib -L/usr/lib/arm-linux-gnueabihf -LIBS = -lpthread -lrt -lbrcmEGL -lbrcmOpenVG -lopenmaxil -lbcm_host -lavformat -lavcodec -lavutil -lswresample -LIBS += -ldl -lfontconfig -lfreetype -lMagick++-6.Q16 +LIBS = -lpthread -lrt -lbrcmEGL -lbrcmOpenVG -lopenmaxil -lbcm_host -lavformat -lavcodec \ + -lavutil -lswresample -ljsoncpp -lfmt -ldl -lfontconfig -lfreetype -lMagick++-6.Q16 OBJECTS = $(OBJ_COMMON) $(OBJ_RASPBERRY) INCLUDES = -I/opt/vc/include -I/opt/vc/include/interface/vcos/pthreads -I/usr/include/freetype2 -I/usr/include/ImageMagick -I/usr/include/ImageMagick-6 -I/usr/include/arm-linux-gnueabihf/ImageMagick-6 DEFINES += -DVOMP_PLATFORM_RASPBERRY @@ -82,6 +80,7 @@ endif # apt install g++-arm-linux-gnueabihf # Set vomp_platform=crossraspberry above ifeq ($(vomp_platform),crossraspberry) +SYSROOT= --sysroot=$(CROSSROOT) DEFINES += -DIPV4 -DIPV6 CROSS_PREFIX=arm-linux-gnueabihf- CC=$(CROSS_PREFIX)gcc @@ -90,11 +89,11 @@ CXX=$(CROSS_PREFIX)g++ LD=$(CROSS_PREFIX)g++ LDFLAGS = -Wall $(PICTURES) $(SYSROOT) \ - -Wl,-rpath-link,$(CROSSROOT)/opt/vc/lib -Wl,-rpath-link,$(CROSSROOT)/usr/lib/arm-linux-gnueabihf \ - -L=/opt/vc/lib -L=/usr/lib/arm-linux-gnueabihf -LIBPATHS = -LIBS = -lpthread -lstdc++ -lrt -lbrcmEGL -lbrcmOpenVG -lopenmaxil -lbcm_host -lavformat -lavcodec -lfmt \ - -lavutil -lswresample -lm -ldl -lfontconfig -lfreetype -lMagick++-6.Q16 -lMagickWand-6.Q16 -lMagickCore-6.Q16 -ljsoncpp + -Wl,-rpath-link,$(CROSSROOT)/opt/vc/lib -Wl,-rpath-link,$(CROSSROOT)/usr/lib/arm-linux-gnueabihf +LIBPATHS = -L=/opt/vc/lib -L=/usr/lib/arm-linux-gnueabihf +LIBS = -lpthread -lstdc++ -lrt -lbrcmEGL -lbrcmOpenVG -lopenmaxil -lbcm_host -lavformat -lavcodec \ + -lfmt -lavutil -lswresample -lm -ldl -lfontconfig -lfreetype -lMagick++-6.Q16 -lMagickWand-6.Q16 \ + -lMagickCore-6.Q16 -ljsoncpp OBJECTS = $(OBJ_COMMON) $(OBJ_RASPBERRY) INCLUDES = -isystem=/usr/include/arm-linux-gnueabihf -isystem=/opt/vc/include -isystem=/usr/include/freetype2 -isystem=/usr/include/arm-linux-gnueabihf/ImageMagick-6 -isystem=/usr/include/ImageMagick-6 DEFINES += -DVOMP_PLATFORM_RASPBERRY -DMAGICKCORE_HDRI_ENABLE=0 -DMAGICKCORE_QUANTUM_DEPTH=16 -- 2.39.5