This reverts commit 44f567c6a3.
Enabling LTO by default causes too many problems, inclusing build
failures for @doofus-01 and link failures with Clang for me.
Players and packagers can still amanually enable LTO in case it
works fine for them.
The detection for when Clang is used was incorrect, resulting in GCC-only
parameter being passed to Clang.
In addition, at least on my system LTO+Clang caused linking errors even
with that fixed. As an emergency fix, I completely disabled LTO for Clang.
LTO for Windows is disabled for now, as TDM-GCC does not work well with it.
LTO for Travis is also disabled, due to the extra time linking with LTO takes.
This moves all the warnings flags from the strict build to the regular build, except for -Werror. This means that the only difference between strict builds and non-strict builds will be if warnings are turned into errors.
This quells warnings from CMake about reserved target names, and reduces confusion about which `test` is intended: the wesnoth executable or the standard shell command.
We have needed to suppress it in a bunch of places because GCC has kept
giving false positives depending on optimization settings. When I noticed
yet another false positive when I attempted to build the game with PGO
profiling data using CMake, it was the last straw.
Let's just suppress the warning globally and move on with our lives.
At branch 'doc-from-discord-boost-discussion-20170926'.
The build documentation and scripts were slightly out of date about
Boost. This commit makes a (probably interim) update to them.
(CMakeLists.txt|SConstruct): `wesnoth` won't build using Boost earlier
than '1.50.0'. Boost 1.50.0 changed the location of version 3 of Boost
filesystem, from 'boost/filesystem/v3/' (e.g. for
'using boost::filesystem::v3::path;') to 'boost/filesystem/' (e.g. for
'using boost::filesystem::path;', enforced since the very introduction
of 'src/filesystem_boost.cpp'), making it incompatible unless using
precompiler directives for supporting backwards versions of Boost
filesystem prior than '1.50.0'. Using Boost 1.50.0 (and 51, 52 etc.)
`wesnoth` is able build and run. I checked using `ldd` that I am right
about the run time environment.
INSTALL.md: Requirement of Boost libraries version up to date.
projectfiles/VC12/README.md: Requirement of Boost libraries up to
date, only the statement of which one is the minimum version, not the
rest of the build guide for Boost as requirement.
.gitignore: Add KDevelop backup documents.
This also removes the included SHA1 and MD5 implementations
in favour of those from OpenSSL.
Thanks to @jyrkive for helping to get the CMake build working and
ensuring the game still compiles with OpenSSL 1.1.0.
(The SHA_xxx() aliases were removed in OpenSSL 1.1.0.)
This is needed because the CAIRO_STATUS_INVALID_SIZE constant was added in
that version.
1.10 is old enough that this change shouldn't cause problems for anyone.
For example, Debian Wheezy (2013) has Cairo 1.12.2.