Commit Graph

80 Commits

Author SHA1 Message Date
Jonathan G Rennison
19b99ee687 Fix 1ac0f186: Remove remaining use of CMAKE_PROJECT_VERSION_XXX 2021-05-12 17:52:46 +01:00
Loïc Guilloux
1ac0f186c8 Fix d4f0b6f4: [CMake] CMAKE_PROJECT_VERSION_XXX are not in CMake 3.9 (#9154)
(cherry picked from commit 2985277bec)
2021-05-06 20:15:17 +01:00
Jonathan G Rennison
253772e9af Merge branch 'master' into jgrpp
# Conflicts:
#	CMakeLists.txt
#	COMPILING.md
#	src/console.cpp
#	src/console_cmds.cpp
#	src/console_internal.h
#	src/rev.cpp.in
2021-04-25 02:14:58 +01:00
Loïc Guilloux
d4f0b6f434
Fix: [CMake] Auto-fill version details in rev.cpp and ottres.rc (#9066) 2021-04-20 21:38:46 +02:00
Jonathan G Rennison
edfa04286b Merge branch 'master' into jgrpp
# Conflicts:
#	.github/workflows/release.yml
#	bin/CMakeLists.txt
#	src/dock_gui.cpp
#	src/lang/brazilian_portuguese.txt
#	src/lang/catalan.txt
#	src/lang/czech.txt
#	src/lang/dutch.txt
#	src/lang/english.txt
#	src/lang/english_US.txt
#	src/lang/estonian.txt
#	src/lang/finnish.txt
#	src/lang/french.txt
#	src/lang/german.txt
#	src/lang/hungarian.txt
#	src/lang/indonesian.txt
#	src/lang/italian.txt
#	src/lang/japanese.txt
#	src/lang/korean.txt
#	src/lang/lithuanian.txt
#	src/lang/luxembourgish.txt
#	src/lang/norwegian_bokmal.txt
#	src/lang/polish.txt
#	src/lang/portuguese.txt
#	src/lang/romanian.txt
#	src/lang/russian.txt
#	src/lang/serbian.txt
#	src/lang/simplified_chinese.txt
#	src/lang/slovak.txt
#	src/lang/spanish.txt
#	src/lang/spanish_MX.txt
#	src/lang/swedish.txt
#	src/lang/tamil.txt
#	src/lang/ukrainian.txt
#	src/lang/vietnamese.txt
#	src/newgrf.cpp
#	src/newgrf_gui.cpp
#	src/object_gui.cpp
#	src/pathfinder/yapf/yapf_costrail.hpp
#	src/pathfinder/yapf/yapf_node_rail.hpp
#	src/rail_cmd.cpp
#	src/roadveh_cmd.cpp
#	src/town_cmd.cpp
#	src/vehicle.cpp
#	src/water_cmd.cpp
2021-04-11 02:39:33 +01:00
Loïc Guilloux
39b4a8e67e
Change: [CMake] Improve 'In-source build' error message (#8955) 2021-04-06 13:54:27 +02:00
Jonathan G Rennison
5e14b54a0c Merge branch 'master' into jgrpp 2021-04-05 17:51:45 +01:00
Loïc Guilloux
799eb31ff1
Change: [CMake] Copy AI/GS compatibility files to build dir (#8906) 2021-04-02 10:15:45 +02:00
glx22
35a228f78f Add: [CMake] Install menu and media files 2021-03-09 22:42:25 +01:00
Jonathan G Rennison
eab32e8861 Merge branch 'master' into jgrpp
# Conflicts:
#	CMakeLists.txt
#	src/blitter/32bpp_optimized.cpp
#	src/lang/serbian.txt
2021-03-04 15:33:52 +00:00
glx22
1d79f55a46 Fix: [CMake] Skip detection for unused libs for dedicated builds 2021-03-04 16:22:58 +01:00
Jonathan G Rennison
59741b9f3c CMake: Fix HOST_BINARY_DIR cross compiling 2021-03-02 22:57:29 +00:00
Jonathan G Rennison
8d650f82ae CMake: Fix OPTION_DOCS_ONLY mode 2021-03-02 21:56:13 +00:00
Jonathan G Rennison
64dd3c2a57 CMake: Set minimum zstd version to 1.4 2021-03-02 21:56:13 +00:00
Jonathan G Rennison
f4e29071be Merge tag '1.11.0-beta2' into jgrpp
# Conflicts:
#	.github/workflows/ci-build.yml
#	.github/workflows/release.yml
#	CMakeLists.txt
#	src/blitter/32bpp_optimized.cpp
#	src/debug.cpp
#	src/gfx.cpp
#	src/gfx_func.h
#	src/lang/czech.txt
#	src/lang/english.txt
#	src/lang/italian.txt
#	src/lang/swedish.txt
#	src/lang/ukrainian.txt
#	src/network/network_server.cpp
#	src/os/windows/crashlog_win.cpp
#	src/os/windows/win32.cpp
#	src/pathfinder/follow_track.hpp
#	src/screenshot.cpp
#	src/settings_type.h
#	src/spritecache.cpp
#	src/vehicle_gui.cpp
#	src/video/sdl2_v.cpp
#	src/video/video_driver.cpp
#	src/video/video_driver.hpp
#	src/video/win32_v.cpp
2021-03-02 11:59:03 +00:00
Jonathan G Rennison
b9332ee62c Zstd: Change package status to recommended 2021-03-01 23:08:23 +00:00
dP
b284d34277 Add: Support Zstandard(zstd) savegame compression
(cherry picked from commit 6f0aeaf2c5436550c93205e704624957e9abc969)
2021-03-01 18:08:28 +00:00
glx22
54fb4c04e3 Fix: [CMake] libpng header/library mismatch for macos 2021-02-27 02:23:33 +01:00
Patric Stout
dc7ba33b51
Fix: don't link to OpenGL with SDL2 as backend; SDL2 dynamically loads it (#8745)
Although for developers this doesn't change anything, for our
linux-generic binary it changes everything. Without this, the
OpenGL dynamic library is dragged in as dependency, and as it
depends on X11, that will be dragged in too. This is not
something we prefer to have, as that won't run on as many
machines as it could.

SDL2 doesn't depend on OpenGL directly, as it tries to load it
in on runtime. If found, it would work in exactly the same way
as if we would link to OpenGL ourselves. As such, this is
the best of both worlds: our linux-generics have less linked
dependencies, and developers won't notice any difference.

As a side-effect, if someone uses linux-generic on a machine
that does not have any OpenGL package installed, it will
gracefully fall back to the default backend of SDL instead.
2021-02-27 00:34:41 +01:00
Michael Lutz
ef478ade64 Add: [Win32] Video driver that uses OpenGL to transfer the video buffer to the screen. 2021-02-22 22:16:07 +01:00
Jonathan G Rennison
19b7ecf95a Merge branch 'master' into jgrpp 2021-02-22 17:45:58 +00:00
milek7
b749d6f1cb Fix: Allow building with Allegro and without SDL on Linux 2021-02-21 23:05:50 +00:00
Jonathan G Rennison
e95216b59d Merge branch 'master' into jgrpp
# Conflicts:
#	src/company_cmd.cpp
#	src/core/geometry_func.cpp
#	src/date.cpp
#	src/genworld_gui.cpp
#	src/gfx.cpp
#	src/object_gui.cpp
#	src/openttd.cpp
#	src/settings_type.h
#	src/video/allegro_v.cpp
#	src/video/dedicated_v.cpp
#	src/video/null_v.cpp
#	src/video/sdl2_v.cpp
#	src/video/sdl_v.cpp
#	src/video/win32_v.cpp
2021-02-19 15:38:34 +00:00
Michael Lutz
6755ff63e1 Add: [OSX] Native font rendering without using FreeType. 2021-02-14 11:48:58 +01:00
Michael Lutz
43326d11d8 Change: [OSX] Use a layer-backed view to speed up drawing. 2021-02-13 22:21:17 +01:00
Owen Rudge
395e015282 Change: Convert .md to .rtf for Windows/Mac packages 2021-02-08 23:23:24 +00:00
glx22
2cbfcd2327 Change: [CMake] Bump minimum version to 3.9 2021-02-07 16:21:13 +01:00
Loïc Guilloux
f7ac2969ef
Fix: [CMake] Restore 'games' as default install bindir (#8629) 2021-02-07 16:19:30 +01:00
glx22
99448eedca Fix: [CMake] os/windows/openttd.manifest is not a generated file 2021-02-05 23:41:55 +01:00
Patric Stout
05df7996a4
Feature: [Actions / CMake] support for generic linux builds (#8641)
These bundles can be opened on any "modern" Linux machine with
a driver that SDL2 supports.

Machines needs at least glibc 2.15, which was released 10 years ago.
It is build with CentOS 7 as base, and only assumes the following
libraries are available on the system:
- libc
- libdl
- libgcc_s
- libpthread
- librt
- libstdc++

All other libraries the game depends on are bundled together with
the game, so users don't need any library installed to use this
bundle. The downside of course is that this increases the binary
size a bit: 30 MiB of libraries are in this bundle.

RPATH is used to make ld-linux find the folder libraries are
stored in; however, system libraries are always used before these,
in the assumption libraries on the user system are more up-to-date.

Using -DOPTION_PACKAGE_DEPENDENCIES=ON switches on packaging
of libraries in the "lib" folder. This requires CMake 3.16 to
be installed; otherwise it will fail.
2021-02-05 12:31:27 +01:00
Jonathan G Rennison
6c3e5642f8 Merge branch 'master' into jgrpp
# Conflicts:
#	cmake/CompileFlags.cmake
#	src/crashlog.cpp
#	src/fileio.cpp
#	src/fileio_func.h
#	src/fios_gui.cpp
#	src/ini_load.cpp
#	src/ini_type.h
#	src/lang/english.txt
#	src/lang/german.txt
#	src/lang/korean.txt
#	src/network/network_client.cpp
#	src/order_base.h
#	src/order_cmd.cpp
#	src/os/windows/win32.cpp
#	src/road_cmd.cpp
#	src/saveload/saveload.cpp
#	src/saveload/saveload.h
#	src/settings.cpp
#	src/station_cmd.cpp
#	src/stdafx.h
#	src/table/settings.ini
#	src/tree_cmd.cpp
#	src/tree_gui.cpp
#	src/vehicle_base.h
#	src/video/cocoa/cocoa_v.mm
#	src/video/cocoa/event.mm
#	src/video/cocoa/wnd_quartz.mm
#	src/viewport.cpp
#	src/widgets/tree_widget.h
2021-01-31 01:08:35 +00:00
Jonathan G Rennison
43980639de Merge branch 'master' into jgrpp
# Conflicts:
#	.gitignore
#	CMakeLists.txt
#	src/3rdparty/optional/optional.hpp
#	src/group_cmd.cpp
#	src/industry_cmd.cpp
#	src/misc_gui.cpp
#	src/video/sdl2_v.cpp
2021-01-29 17:45:15 +00:00
Michael Lutz
a61a741683 Change: [OSX] Compiling the Cocoa/Quartz video driver cannot be disabled anymore. 2021-01-03 13:25:32 +01:00
Charles Pigott
3dfee979a7 Codechange: Drop libxdg-basedir dependency in favour of finding the directories ourselves 2021-01-02 19:46:08 +00:00
Jonathan G Rennison
483ed2f468 Merge branch 'master' into jgrpp
# Conflicts:
#	.github/workflows/ci-build.yml
#	.github/workflows/commit-checker.yml
#	src/openttd.cpp
2020-12-27 20:16:16 +00:00
Patric Stout
e0b953b804 Fix: [Emscripten] compile with exceptions enabled, as our AIs depend on it
Also parts of the saveload code does, and some other places. This
does slow down builds, but for most computers this will not be
measurable. At least, the ones I had access to I could not find
a difference in FPS, mainly as that is heavily limited by the Hz
of the screens of the computer.

Either way, it is better to have a full functional game than a
fast one in my opinion
2020-12-25 20:56:25 +01:00
Jonathan G Rennison
8b94d92158 CMake: Suppress warning messages when Fcitx is not found 2020-12-15 17:47:57 +00:00
Patric Stout
d15dc9f40f Add: support for emscripten (play-OpenTTD-in-the-browser)
Emscripten compiles to WASM, which can be loaded via
HTML / JavaScript. This allows you to play OpenTTD inside a
browser.

Co-authored-by: milek7 <me@milek7.pl>
2020-12-15 15:46:39 +01:00
frosch
5d278b62cc Codechange: switch to C++17 on all platforms. 2020-12-14 23:50:50 +01:00
glx22
d1fa6b129c Add: [CMake] Option to only build tools/docs 2020-12-13 22:46:46 +01:00
glx22
6fae0b83d9 Add: [CMake] targets to generate documentation 2020-12-12 15:48:04 +01:00
Jonathan G Rennison
bad2cd0677 CMake: Do not look for fctix on Apple 2020-12-12 00:10:52 +00:00
Owen Rudge
6e689e2038 Fix: FreeType is still required on macOS 2020-12-08 09:24:15 +00:00
Jonathan G Rennison
4da3cfcf56 Merge branch 'master' into jgrpp
# Conflicts:
#	CMakeLists.txt
#	src/bootstrap_gui.cpp
2020-12-07 17:56:44 +00:00
Patric Stout
ad47ebc1a8 Change: don't encourage the use of LZO
LZO was used before the first version we track in our version
control system, which dates back to Aug 2004. Somewhere before
that time a few savegames / scenarios exist which use LZO. No
other savegame / scenario does since then. Let's not encourage
people to install something that ancient.

There are no scenarios on BaNaNaS that require LZO.
2020-12-06 19:25:46 +00:00
glx22
a06fe8e8a7 Fix: [CMake] cross-compiling requires native tools 2020-12-04 09:49:31 +00:00
Jonathan G Rennison
d85a529f87 Merge branch 'master' into jgrpp 2020-10-14 17:38:23 +01:00
Charles Pigott
85ca1c535e Codechange: Set CMAKE_BUILD_TYPE to default to debug if not otherwise set 2020-09-25 21:50:06 +01:00
Charles Pigott
348c231e12 Codechange: Make codestyle for CMake files consistent for 'control' statements 2020-09-25 14:43:13 +01:00
Jonathan G Rennison
5970c936a6 CMake: Use freetype on Apple
See: #183, #188
2020-09-14 20:51:30 +01:00