Revert "CMake: bump minimum requirement to 3.5"

This reverts commit 210dda2c4c.

The patch release should not change the build requirements.
This commit is contained in:
David Adam 2021-07-06 22:18:40 +08:00
parent 727934c6b6
commit 22e6b3db16
4 changed files with 7 additions and 3 deletions

View File

@ -27,7 +27,7 @@ Improved terminal support
For distributors
----------------
- The minimum version of CMake required to build fish was raised to 3.5.0.
- *This placeholder silences a sphinx doc warning, so the last section is not empty.*
--------------

View File

@ -1,4 +1,4 @@
cmake_minimum_required(VERSION 3.5)
cmake_minimum_required(VERSION 3.2)
if(POLICY CMP0066)
cmake_policy(SET CMP0066 OLD)

View File

@ -143,7 +143,7 @@ Dependencies
Compiling fish requires:
- a C++11 compiler (g++ 4.8 or later, or clang 3.3 or later)
- CMake (version 3.5 or later)
- CMake (version 3.2 or later)
- a curses implementation such as ncurses (headers and libraries)
- PCRE2 (headers and libraries) - a copy is included with fish
- gettext (headers and libraries) - optional, for translation support

View File

@ -56,6 +56,10 @@ endif()
# Get threads.
set(THREADS_PREFER_PTHREAD_FLAG ON)
# FindThreads < 3.4.0 doesn't work for C++-only projects
if(CMAKE_VERSION VERSION_LESS 3.4.0)
enable_language(C)
endif()
find_package(Threads REQUIRED)
# Detect WSL. Does not match against native Windows/WIN32.