259 Commits

Author SHA1 Message Date
Jyrki Vesterinen
56433d12a3 Merge branch 'login_save_crypt' 2017-05-22 20:10:09 +03:00
Nils Kneuper
d41396ac32 bump version requirements for boost to meet INSTALL.md 2017-05-20 19:35:54 +02:00
Celtic Minstrel
c9191c9812 Add OpenSSL's libcrypto as a dependency
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.)
2017-05-12 15:57:13 -04:00
Jyrki Vesterinen
6b8273e003 Require Cairo 1.10 or above
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.
2017-05-02 19:49:13 +03:00
Jyrki Vesterinen
cd79780b68 CMake: demote failure to compile IEEE 754 test from error to warning
Apparently due to a CMake bug, some (but not all) CMake versions attempt to
compile the test with default flags, which means C++98 mode with GCC < 6.
As a result, compiling the test fails, and the whole game fails to build.

@gfgtdf pointed out to me that CMake reports the compile and run status
separately, and therefore it's possible to detect the situation where the
test fails to compile. Thus, I decided to allow building in that situation.
2017-03-13 21:37:44 +02:00
Celtic Minstrel
2417597028 Attempt to fix Travis build
Scons has a space here, and the scons builds work on Travis,
so I figure CMake should also work if a space is added.
2017-03-10 23:34:07 -05:00
loonycyborg
05f9f00289 Update autorevision script with upstream changes
this fixes autorevision errors if running from under su
2017-03-11 04:20:12 +03:00
Andreas Löf
90356fce46 Fix CMAKE build
This fixes the broken includes that stopepd the IEEE 754 check from compiling.
2016-12-28 16:36:17 +13:00
Jyrki Vesterinen
ea55e7dbbc Second attempt to fix builds failing with GCC < 6
9ad78036 fixed it for SCons but not for CMake.

I also removed some test output stuff that I no longer need.
2016-12-23 01:07:13 +02:00
Jyrki Vesterinen
9ad78036b5 Attempted fix for builds failing with compilers older than GCC 6 2016-12-23 00:26:01 +02:00
Jyrki Vesterinen
6c9ff7c4b3 Print the compile output too 2016-12-22 23:53:46 +02:00
Jyrki Vesterinen
1553cc6b6b CMake: print the bit representation of the test number
I need this to investigate why the test is failing in Travis CI.
2016-12-22 22:54:05 +02:00
Jyrki Vesterinen
7968f7ba5e Check that floats are in the IEEE 754 format when building with CMake
SCons version is coming a bit later.
2016-12-22 20:41:30 +02:00
loonycyborg
2ca7cb8a89 Fix naming of Optimized build variant in messages and comments of cmakelists 2016-11-28 15:34:48 +03:00
loonycyborg
60329a87a1 Rename Optimize build variant to Optimized for clarity 2016-11-26 14:59:42 +03:00
Sergey Popov
dd1351dc14 Merge pull request #847 from Pentarctagon/Pentarctagon-optimize-build
Add build which uses higher level of optimization
2016-11-26 01:18:22 +03:00
Celtic Minstrel
dc24fa16f7 Remove option to link libintl instead of Boost.Locale 2016-11-18 12:09:56 -05:00
pentarctagon
9de1f61924 Add -s flag, fix $OPT_FLAGS evaluating as an empty string, and correctly pass the arch needed by Windows with -O3 to the optimize build 2016-11-18 01:27:40 -06:00
pentarctagon
9bc33ff794 Add Optimize build to cmake 2016-11-18 01:27:40 -06:00
Pentarctagon
8ea76ce432 Fix compiling with TDM-GCC-64 and -O3
By default, TDM-GCC-64 was using -march=x86-64, which for whatever reason caused issues when compiling with -O3.  This makes scons force it to use -march=pentiumpro, the same as TDM-GCC-32.  This also changes the release build to use -O3 instead of -O2, which matches the release build default used by cmake and code::blocks.

Added -march=pentiumpro on Windows for -O3 build

m5
2016-11-18 01:27:40 -06:00
Pentarctagon
e55e4a6d60 Make cmake's Release and Debug builds match scons
Let cmake use its default -O3 again

m4
2016-11-18 01:27:40 -06:00
Gregory A Lundberg
f23127e65a Remove LOW_MEM compile-time option
Per @Vultraz
2016-11-11 09:20:56 -06:00
Gregory A Lundberg
0ecbbef033 Apply patch to boost
When using:

    scons strict=true ctool=clang

A number of issues appear concerning a known bug in Boost::Bind; applying the patch which should appear in Boost 1.63. Comments on the Boost ticket indicate this may also be an issue for earlier versions of GCC.

For the ticket, see

    https://svn.boost.org/trac/boost/ticket/12397

and the patch is at

    3c56630b54

NOTE: This does NOT create a dependency upon the patched header. If the header is changed, you must do a full re-build of all sources by hand.
2016-10-16 10:55:09 -05:00
Gregory A Lundberg
34dcd0657f Test for Travis and only require SDL 2.0.2 2016-10-16 03:36:57 -05:00
Gregory A Lundberg
907eb5bf7e Require SDL2 2.0.4 on all target platforms. 2016-10-16 00:55:24 -05:00
Ignacio R. Morelle
7e1798f342 cmake: Drop ENABLE_SDL_GPU option
The code conditionals using SDL_gpu in the source tree are unmaintained
and likely broken. From past discussions with vultraz and Aginor, the
plan ahead is to completely drop SDL_gpu and its support code once
there's no risk of conflict with certain WIP branches.
2016-10-03 07:23:12 -03:00
Ignacio R. Morelle
2c5904ae0a cmake: Remove ENABLE_PANDORA option
Pretty much all of the code for supporting OpenPandora is gone from the
source tree, and the last two mentions have just been slated for
removal, so it's effectively dead.
2016-10-03 07:19:21 -03:00
Ignacio R. Morelle
8b341411d6 cmake: Remove SDL_net-related checks and substitutions 2016-10-03 06:59:48 -03:00
loonycyborg
0f9e04501f Remove obsolete and unused HAVE_CXX0X macro from buildsystems 2016-06-01 22:14:09 +03:00
Andreas
94fc73fcde Merge pull request #551 from starius/respect-user-cmake-module-path
respect CMAKE_MODULE_PATH provided by user
2016-04-10 14:55:28 +12:00
Nils Kneuper
f758706ea2 fixed compiling with CMake in a hacky way
* Switched from C++98 to C++11 (as announced on the dev-ml)
* Added support for boost-thread

The current implementation is hacky and not clean. It at least builds on
my gentoo ~amd64 system.
2016-04-02 10:15:54 +02:00
Andreas Löf
5c6e7c7d20 Remove SDL1 from SCons and CMake
This makes SDL2 the only build alternative for Wesnoth. Any
conditionals are removed, leaving only the settings that rely on SDL2.
2016-03-13 11:34:29 +13:00
Andreas Löf
9b5870e14b Correct SDL2 versions for linux/win32/osx in build scripts
Codify the requirements set forth in the INSTALL file in scons and
cmake as they are used on other platforms that Linux and * BSD.
2016-01-17 10:41:36 +13:00
Andreas Löf
9ed01599ee Drop requiered SDL2 version to 2.0.2 on Linux and *BSD
This drops the required version to 2.0.2 on Linux and *BSD, as there are no known bugs that require us to have a later version on these platforms. Windows and Os X remains as 2.0.4.
2016-01-17 09:28:18 +13:00
Andreas Löf
4650202390 Update build requirements to SDL 2.0.4 2016-01-17 08:26:14 +13:00
Boris Nagaev
6e08864345 respect CMAKE_MODULE_PATH provided by user
Cross-compiling to Windows with MXE [1] requires providing custom
CMAKE_MODULE_PATH variable for CMake:

$ cmake -DCMAKE_MODULE_PATH=/file/provided/by/mxe.cmake

As Wesnoth's CMakeLists.txt resets CMAKE_MODULE_PATH, the effect of
CMAKE_MODULE_PATH provided by MXE is disabled and the build fails
with linking errors [2].

This commit changes CMakeLists.txt to respect the value of
user provided CMAKE_MODULE_PATH, so both MXE and Wesnoth
customizations of CMake variables are applied.

[1] http://mxe.cc/
[2] https://gist.github.com/starius/abfb9033d92f21ef521d
2015-11-08 14:56:28 +03:00
Andreas Löf
1890e948e4 Merge branch 'master' into sdl2 2015-10-26 18:57:32 +13:00
Ignacio R. Morelle
03a85fde56 cmake: Tests and tools also need Boost.Filesystem + Boost.Locale
Fixes linker errors found when building after configuring with
`-DENABLE_TOOLS=ON -DENABLE_GAME=OFF -DENABLE_SERVER=OFF
-DENABLE_NLS=OFF`.
2015-10-19 21:46:44 -03:00
Andreas Löf
e8c3e99dad Make SDL2 the default in cmake and scons
This changes the default settings in the cmake and scons to make all
targets be compiled with SDL2 as opposed to SDL1.
2015-09-15 20:45:27 +12:00
Andreas Löf
c5bec31dae Change the ordering of the CMakeLists so options comes first.
This changes the ordering of the compile time options so the options
comes before any before any flags or checks that may depend on them.
2015-09-09 21:42:29 +12:00
Andreas Löf
4c4c469ead Add SDL2 support to the CMake.
To compile with SDL2, run with -DENABLE_SDL2=TRUE. SDL2 is disabled by default.
2015-08-17 03:40:22 +12:00
Charles Dang
7923a41663 cmake: drop reference to standalone editor icon and .desktop files
These were removed in 176bda844c7d.
2015-07-30 13:09:51 +11:00
Ignacio R. Morelle
24a166db22 cmake: Disable strict compilation by default
It's no good for users who are likely to hit issues with compilers not
used by the release team.
2015-06-26 23:09:18 -03:00
Ignacio R. Morelle
35fdff6622 Remove ANA
This project was never completed, the author left, and what we had was
too buggy to use in production (including such gems as a server DoS
bug).

Only removed from the CMake recipe since it was already removed from the
SCons script in commit 634b0039f80e3ba3ecf9729516071d533c25d3d5.
2015-04-23 06:08:40 -03:00
Ignacio R. Morelle
cfbeee2f50 cmake: Add ENABLE_HISTORY option
For enabling history expansion support in the Lua console. Uses GNU
libhistory.
2015-04-13 04:30:57 -03:00
Ignacio R. Morelle
1dd02d7b18 cmake: Fix typo in the SDL_gpu option's description 2015-04-13 03:53:06 -03:00
Ignacio R. Morelle
135bcf15d6 cmake: Add ENABLE_LIBINTL option to use libintl instead of Boost.Locale
This also makes it so libintl isn't mandatory when this option isn't
enabled anymore.

Additionally, the BFS and Boost.Locale checks are now properly shared
between ENABLE_SERVER and ENABLE_GAME configurations without duplicating
code in the CMake recipe.
2015-04-13 03:44:23 -03:00
Nils Kneuper
76c6cc1de3 switch to better way finding FriBiDi in cmake
* FriBiDi can be found using pkgconfig, switch to using it instead of
  using our homegrown FindFriBiDi.cmake file for finding it in cmake
* had to set some extra "do not consider these warnings" for font.cpp,
  is this really no issue for scons for strict compilation with -Wall?
2015-04-12 15:12:29 +02:00
Nils Kneuper
05d6e7dd9b remove option to use ancient FriBiDi 2015-04-12 13:23:54 +02:00
Nils Kneuper
2d1e0804aa enforce cmake default build type (bug #23445)
If no build type is selected it can happen that the game builds without
any optimization. Now the user has to explicitly specify the 'none' type
if they want it.
2015-04-12 11:53:19 +02:00