diff options
author | Roland Reichwein <mail@reichwein.it> | 2021-01-30 19:20:15 +0100 |
---|---|---|
committer | Roland Reichwein <mail@reichwein.it> | 2021-01-30 19:20:15 +0100 |
commit | 2ef9f51df48b14556e236d14213233e1bd7f829a (patch) | |
tree | f5230e326501ebaec1baca9615dc69b7538f1911 /Makefile | |
parent | ee9dfd30e8c02e9a7457385786218d2b4b935720 (diff) |
Added Support for Debian and Ubuntu, add is_valid_utf()
Diffstat (limited to 'Makefile')
-rw-r--r-- | Makefile | 20 |
1 files changed, 18 insertions, 2 deletions
@@ -1,22 +1,38 @@ PROJECTNAME=unicode VERSION=$(shell dpkg-parsechangelog --show-field Version) -DISTROS=base #debian10 +DISTROS=base debian10 ubuntu2004 ubuntu2010 +ifeq ($(wildcard $(shell which clang++-11)),) +ifeq ($(wildcard $(shell which clang++)),) +$(error No clang++-11 nor clang++ available!) +else +CXX=clang++ +endif +else CXX=clang++-11 # GCC is buggy: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=85282 #CXX=g++-10 +endif STANDARD=c++17 #STANDARD=c++20 +ifeq ($(CXXFLAGS),) CXXFLAGS=-O0 -g -D_DEBUG #CXXFLAGS=-O2 -DNDEBUG +endif CXXFLAGS+=-Wall -Iinclude -std=$(STANDARD) ifeq ($(CXX),clang++-11) COMPILER_SUITE=clang +LIBS+=-fuse-ld=lld-11 +endif + +ifeq ($(CXX),clang++) +COMPILER_SUITE=clang +LIBS+=-fuse-ld=lld endif ifeq ($(COMPILER_SUITE),clang) @@ -31,7 +47,6 @@ LDLIBS+=\ ifeq ($(COMPILER_SUITE),clang) LIBS+= \ --fuse-ld=lld-11 \ -lc++ \ -lc++abi #-lc++fs @@ -68,6 +83,7 @@ dep: $(SRC:.cpp=.d) clean: -rm -f src/recode src/test-unicode + -rm -rf result -find . -name '*.o' -o -name '*.d' -o -name '*.gcno' -o -name '*.gcda' | xargs rm -f install: |