From 54539cc210afcda25f6da12ad08c2b5fa8bd5be2 Mon Sep 17 00:00:00 2001 From: Roland Reichwein Date: Sat, 5 Nov 2022 14:41:12 +0100 Subject: Fix build on Ubuntu --- Makefile | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/Makefile b/Makefile index 034b024..d85bad7 100755 --- a/Makefile +++ b/Makefile @@ -4,7 +4,7 @@ # Environment: Debian # -DISTROS=debian10 debian11 ubuntu2004 ubuntu2204 +DISTROS=base debian10 debian11 ubuntu2004 ubuntu2204 VERSION=$(shell dpkg-parsechangelog --show-field Version) CXX=clang++-10 @@ -23,12 +23,18 @@ endif LIBS=-lfcgi -lboost_filesystem INCLUDES=-I. -CXXFLAGS=-Wall -g -O2 -fPIC -std=c++17 -Wpedantic HEADERS=file.h SOURCES=$(HEADERS:.h=.cpp) OBJECTS=$(HEADERS:.h=.o) TARGETS=whiteboard.fcgi +ifeq ($(CXXFLAGS),) +CXXFLAGS=-g -O2 +endif + +CXXFLAGS+=-Wall -fPIE -std=c++17 -Wpedantic -gdwarf-4 +LDFLAGS+=-pie + ifeq ($(CXX),clang++-10) LIBS+= \ -fuse-ld=lld-10 \ -- cgit v1.2.3