summaryrefslogtreecommitdiffstats
path: root/Makefile
diff options
context:
space:
mode:
authorSteffen Winter <steffen.winter@proton.me>2023-09-13 23:17:06 +0200
committerSteffen Winter <steffen.winter@proton.me>2024-01-02 19:28:24 +0100
commit85d75038e949e3aa07c9ca6c0544502b445981e1 (patch)
treeb8d4303a5ff14435bbcf66fb94436c486a904208 /Makefile
parent35672546536070931455214abf6c22e2e000fdbe (diff)
Remove detailed compiler check
Currently the Makefile tries to pick the latest version of g++ and overrides CXX when found. Since we give an error if the version of the compiler is not sufficient, we can remove this check. It's now possible to specify an older version (on purpose) and new compiler version don't need to be added manually.
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile31
1 files changed, 3 insertions, 28 deletions
diff --git a/Makefile b/Makefile
index 9f4db2e..36e2ea1 100644
--- a/Makefile
+++ b/Makefile
@@ -73,34 +73,9 @@ ifeq ($(CXX_IS_CLANG),true)
ifneq ($(shell test $(CXX_VERSION_MAJOR) -lt $(MIN_CLANG_VERSION); echo $$?),0)
CLANG_WORKS := true
endif
-endif
-ifeq ($(CLANG_WORKS),false)
- #? Try to find a newer GCC version
- ifeq ($(shell command -v g++-13 >/dev/null; echo $$?),0)
- CXX := g++-13
- else ifeq ($(shell command -v g++13 >/dev/null; echo $$?),0)
- CXX := g++13
- else ifeq ($(shell command -v g++-12 >/dev/null; echo $$?),0)
- CXX := g++-12
- else ifeq ($(shell command -v g++12 >/dev/null; echo $$?),0)
- CXX := g++12
- else ifeq ($(shell command -v g++-11 >/dev/null; echo $$?),0)
- CXX := g++-11
- else ifeq ($(shell command -v g++11 >/dev/null; echo $$?),0)
- CXX := g++11
- else ifeq ($(shell command -v g++ >/dev/null; echo $$?),0)
- CXX := g++
- else ifeq ($(shell command -v eg++ >/dev/null; echo $$?),0)
- CXX := eg++
- else
- GCC_NOT_FOUND := true
- endif
- ifndef GCC_NOT_FOUND
- override CXX_VERSION := $(shell $(CXX) -dumpfullversion -dumpversion || echo 0)
- override CXX_VERSION_MAJOR := $(shell echo $(CXX_VERSION) | cut -d '.' -f 1)
- ifneq ($(shell test $(CXX_VERSION_MAJOR) -lt 10; echo $$?),0)
- GCC_WORKS := true
- endif
+else
+ ifneq ($(shell test $(CXX_VERSION_MAJOR) -lt 10; echo $$?),0)
+ GCC_WORKS := true
endif
endif