On Tue, 06 Apr 2021, Solene Rapenne wrote: > On Sun, 28 Feb 2021 23:09:24 -0700 > "Anthony J. Bentley" <anth...@anjbe.name>: > > > Hi, > > > > Here's an update to openttd-1.11.0-beta2. > > > > Upstream claims new OpenGL support, faster video, and 60fps. > > > > The build system has been switched to CMake. This led to the GTK icons > > and .desktop file not being installed, a bug upstream claims will be > > fixed before release; see: > > https://github.com/OpenTTD/OpenTTD/issues/8613 > > https://github.com/OpenTTD/OpenTTD/issues/8778 > > > > The endian patch no longer applies and seems to have been refactored > > although the original pull request was merged. I'd appreciate a > > test on PowerPC to make sure this is still correct. > > > > Update to 1.11.0, the Allegro patch wasn't applying since last diff, > context around second hunk slightly changed. > > I don't understand the .desktop issue, I read on github that it should > be fixed but I see a rm -fr openttd.desktop* in the post-install target? > > Game works fine, fast mode is a LOT faster and draw a LOT less CPU :)
Builds and runs fine for me on amd64. Tried at 1080 60fps it does not get over 20% CPU at any time :-) I don't have any big-ish saved game to test (I would have to look at my backups). I also tested it with a 32bpp graphics set and it works smoothly. ok paco > > Index: Makefile > =================================================================== > RCS file: /home/reposync/ports/games/openttd/Makefile,v > retrieving revision 1.70 > diff -u -p -r1.70 Makefile > --- Makefile 10 Aug 2020 21:10:35 -0000 1.70 > +++ Makefile 1 Apr 2021 14:55:34 -0000 > @@ -2,9 +2,9 @@ > > COMMENT= open source clone of the game Transport Tycoon Deluxe > > -V = 1.10.3 > +V = 1.11.0 > DISTNAME = openttd-$V-source > -PKGNAME = openttd-$V > +PKGNAME = openttd-1.11.0 > > CATEGORIES= games > > @@ -15,8 +15,9 @@ MAINTAINER = Anthony J. Bentley <anthony > # GPLv2 only > PERMIT_PACKAGE= Yes > > +WANTLIB += ${COMPILER_LIBCXX} > WANTLIB += SDL2 c fluidsynth fontconfig freetype icudata icui18n icuuc > -WANTLIB += lzma lzo2 m png pthread ${COMPILER_LIBCXX} xdg-basedir z > +WANTLIB += lzma lzo2 m png pthread z > > COMPILER = base-clang ports-gcc base-gcc > > @@ -25,13 +26,14 @@ EXTRACT_SUFX = .tar.xz > > DIST_SUBDIR = openttd > > +MODULES = devel/cmake > + > LIB_DEPENDS= archivers/lzo2 \ > audio/fluidsynth \ > devel/sdl2 \ > graphics/png \ > textproc/icu4c \ > - archivers/xz \ > - x11/libxdg-basedir > + archivers/xz > > RUN_DEPENDS = audio/timidity \ > devel/desktop-file-utils \ > @@ -40,36 +42,21 @@ RUN_DEPENDS = audio/timidity \ > games/openttd-data/opensfx \ > x11/gtk+3,-guic > > -CONFIGURE_STYLE= simple > -CONFIGURE_ARGS+= --prefix-dir=${PREFIX} \ > - --binary-dir=bin \ > - --data-dir=share/openttd \ > - --icon-dir=share/pixmaps \ > - --man-dir=man/man6 \ > - --personal-dir=.openttd \ > - --install-dir=${WRKINST} \ > - --with-png \ > - --with-zlib \ > - --without-allegro \ > - --CFLAGS_BUILD="${CFLAGS}" \ > - --disable-strip > - > -MAKE_ENV+= VERBOSE=1 > +CONFIGURE_ARGS = -DCMAKE_INSTALL_BINDIR=bin \ > + -DCMAKE_INSTALL_DATADIR=share > > -USE_GMAKE= Yes > NO_TEST= Yes > > DOCSDIR= ${PREFIX}/share/doc/openttd > EXAMPLESDIR= ${PREFIX}/share/examples/openttd > GAMEDIR= ${PREFIX}/share/openttd > > -FAKE_FLAGS=BUNDLE_DIR=${WRKINST}/bundle BUNDLES_DIR=${WRKINST}/bundle > - > WRKDIST = ${WRKDIR}/openttd-$V > > DEBUG_PACKAGES = ${BUILD_PACKAGES} > > post-install: > + gunzip ${PREFIX}/man/man6/openttd.6.gz > ${INSTALL_DATA_DIR} ${GAMEDIR}/media > cd ${WRKSRC}/media/ && umask 022 && pax -rw . ${GAMEDIR}/media > ${INSTALL_DATA_DIR} ${EXAMPLESDIR} > Index: distinfo > =================================================================== > RCS file: /home/reposync/ports/games/openttd/distinfo,v > retrieving revision 1.37 > diff -u -p -r1.37 distinfo > --- distinfo 10 Aug 2020 21:10:35 -0000 1.37 > +++ distinfo 1 Apr 2021 14:55:47 -0000 > @@ -1,2 +1,2 @@ > -SHA256 (openttd/openttd-1.10.3-source.tar.xz) = > wRYB71R+sfbU+aA1vRngp2C0eHLOfZtBF6qkWsN3tTs= > -SIZE (openttd/openttd-1.10.3-source.tar.xz) = 6815924 > +SHA256 (openttd/openttd-1.11.0-source.tar.xz) = > XmUYTgc2i6Gvpi27PjWrrubE2mcw/0vJ60RH1TNjx6g= > +SIZE (openttd/openttd-1.11.0-source.tar.xz) = 6805420 > Index: patches/patch-CMakeLists_txt > =================================================================== > RCS file: patches/patch-CMakeLists_txt > diff -N patches/patch-CMakeLists_txt > --- /dev/null 1 Jan 1970 00:00:00 -0000 > +++ patches/patch-CMakeLists_txt 6 Apr 2021 13:12:08 -0000 > @@ -0,0 +1,22 @@ > +$OpenBSD$ > +Disable allegro support. > +Ours (4.2.3 at time of writing) is old and seemingly incompatible. > +Index: CMakeLists.txt > +--- CMakeLists.txt.orig > ++++ CMakeLists.txt > +@@ -121,7 +121,6 @@ find_package(PNG) > + > + if(NOT OPTION_DEDICATED) > + if(NOT WIN32) > +- find_package(Allegro) > + if(NOT APPLE) > + find_package(Freetype) > + find_package(SDL2) > +@@ -253,7 +252,6 @@ if(NOT OPTION_DEDICATED) > + link_package(Fluidsynth) > + link_package(SDL) > + link_package(SDL2 TARGET SDL2::SDL2) > +- link_package(Allegro) > + link_package(FREETYPE TARGET Freetype::Freetype) > + link_package(Fontconfig TARGET Fontconfig::Fontconfig) > + link_package(ICU_lx) > Index: patches/patch-Makefile_bundle_in > =================================================================== > RCS file: > /home/reposync/ports/games/openttd/patches/patch-Makefile_bundle_in,v > retrieving revision 1.8 > diff -u -p -r1.8 patch-Makefile_bundle_in > --- patches/patch-Makefile_bundle_in 7 Apr 2020 15:13:34 -0000 1.8 > +++ patches/patch-Makefile_bundle_in 1 Mar 2021 08:07:21 -0000 > @@ -1,24 +0,0 @@ > -$OpenBSD: patch-Makefile_bundle_in,v 1.8 2020/04/07 15:13:34 solene Exp $ > - > -Don't gzip(1) the manual page. > - > -Index: Makefile.bundle.in > ---- Makefile.bundle.in.orig > -+++ Makefile.bundle.in > -@@ -75,7 +75,6 @@ endif > - ifdef MAN_DIR > - $(Q)mkdir -p "$(BUNDLE_DIR)/man/" > - $(Q)cp "$(ROOT_DIR)/docs/openttd.6" "$(BUNDLE_DIR)/man/" > -- $(Q)gzip -9 "$(BUNDLE_DIR)/man/openttd.6" > - endif > - $(Q)cp "$(ROOT_DIR)/media/openttd.32.xpm" "$(BUNDLE_DIR)/media/" > - $(Q)cp "$(ROOT_DIR)/media/openttd."*.png "$(BUNDLE_DIR)/media/" > -@@ -211,7 +210,7 @@ endif > - ifdef MAN_DIR > - ifndef DO_NOT_INSTALL_MAN > - $(Q)install -d "$(INSTALL_MAN_DIR)" > -- $(Q)install -m 644 "$(BUNDLE_DIR)/man/openttd.6.gz" > "$(INSTALL_MAN_DIR)/${BINARY_NAME}.6.gz" > -+ $(Q)install -m 644 "$(BUNDLE_DIR)/man/openttd.6" > "$(INSTALL_MAN_DIR)/${BINARY_NAME}.6" > - endif > - endif > - ifdef MENU_DIR > Index: patches/patch-config_lib > =================================================================== > RCS file: /home/reposync/ports/games/openttd/patches/patch-config_lib,v > retrieving revision 1.7 > diff -u -p -r1.7 patch-config_lib > --- patches/patch-config_lib 7 Apr 2020 15:13:34 -0000 1.7 > +++ patches/patch-config_lib 1 Mar 2021 08:07:21 -0000 > @@ -1,14 +0,0 @@ > -$OpenBSD: patch-config_lib,v 1.7 2020/04/07 15:13:34 solene Exp $ > -Don't build with -O1. The reason they add it is irrevelant to OpenBSD anyway. > -Index: config.lib > ---- config.lib.orig > -+++ config.lib > -@@ -1525,7 +1525,7 @@ make_cflags_and_ldflags() { > - cc_build_is_gcc=`basename "$cc_build" | grep "gcc" 2>/dev/null` > - if [ -n "$cc_build_is_gcc" ]; then > - # Just add -O1 to the tools needed for building. > -- CFLAGS_BUILD="$CFLAGS_BUILD -D_FORTIFY_SOURCE=2 -O1" > -+ CFLAGS_BUILD="$CFLAGS_BUILD -D_FORTIFY_SOURCE=2" > - if [ "$os" = "MINGW" ]; then > - # Prevent undefined references when > _FORTIFY_SOURCE > 0 > - LDFLAGS_BUILD="$LDFLAGS_BUILD -fstack-protector" > Index: patches/patch-src_core_endian_type_hpp > =================================================================== > RCS file: > /home/reposync/ports/games/openttd/patches/patch-src_core_endian_type_hpp,v > retrieving revision 1.1 > diff -u -p -r1.1 patch-src_core_endian_type_hpp > --- patches/patch-src_core_endian_type_hpp 12 Feb 2020 10:23:36 -0000 > 1.1 > +++ patches/patch-src_core_endian_type_hpp 1 Mar 2021 08:07:21 -0000 > @@ -1,22 +0,0 @@ > -$OpenBSD: patch-src_core_endian_type_hpp,v 1.1 2020/02/12 10:23:36 cwen Exp $ > - > -Fix endianness detection, see: > -https://github.com/OpenTTD/OpenTTD/pull/7996 > - > -Index: src/core/endian_type.hpp > ---- src/core/endian_type.hpp.orig > -+++ src/core/endian_type.hpp > -@@ -35,6 +35,13 @@ > - # else > - # define TTD_ENDIAN TTD_BIG_ENDIAN > - # endif > -+#elif defined(__OpenBSD__) > -+# include <endian.h> > -+# if BYTE_ORDER == LITTLE_ENDIAN > -+# define TTD_ENDIAN TTD_LITTLE_ENDIAN > -+# else > -+# define TTD_ENDIAN TTD_BIG_ENDIAN > -+# endif > - #elif !defined(TESTING) > - # include <sys/param.h> > - # if __BYTE_ORDER == __LITTLE_ENDIAN > Index: patches/patch-src_string_func_h > =================================================================== > RCS file: /home/reposync/ports/games/openttd/patches/patch-src_string_func_h,v > retrieving revision 1.4 > diff -u -p -r1.4 patch-src_string_func_h > --- patches/patch-src_string_func_h 7 Apr 2020 15:13:34 -0000 1.4 > +++ patches/patch-src_string_func_h 1 Mar 2021 08:07:21 -0000 > @@ -3,7 +3,7 @@ Don't use openttd's internal copy of str > Index: src/string_func.h > --- src/string_func.h.orig > +++ src/string_func.h > -@@ -248,7 +248,7 @@ static inline bool IsWhitespace(WChar c) > +@@ -260,7 +260,7 @@ static inline bool IsWhitespace(WChar c) > #endif > > /* strcasestr is available for _GNU_SOURCE, BSD and some Apple */ > Index: pkg/PLIST > =================================================================== > RCS file: /home/reposync/ports/games/openttd/pkg/PLIST,v > retrieving revision 1.31 > diff -u -p -r1.31 PLIST > --- pkg/PLIST 7 Apr 2020 15:13:34 -0000 1.31 > +++ pkg/PLIST 6 Apr 2021 13:53:57 -0000 > @@ -29,6 +29,7 @@ share/doc/openttd/ottd-colourtext-palett > share/doc/openttd/palettes/ > share/doc/openttd/palettes/openttd.gpl > share/doc/openttd/palettes/palette.act > +share/doc/openttd/palettes/palette_key.png > share/doc/openttd/tileh.png > share/doc/pkg-readmes/${PKGSTEM} > share/examples/openttd/ > @@ -52,6 +53,7 @@ share/openttd/ai/compat_0.7.nut > share/openttd/ai/compat_1.0.nut > share/openttd/ai/compat_1.1.nut > share/openttd/ai/compat_1.10.nut > +share/openttd/ai/compat_1.11.nut > share/openttd/ai/compat_1.2.nut > share/openttd/ai/compat_1.3.nut > share/openttd/ai/compat_1.4.nut > @@ -76,6 +78,7 @@ share/openttd/baseset/orig_win.obm > share/openttd/baseset/orig_win.obs > share/openttd/game/ > share/openttd/game/compat_1.10.nut > +share/openttd/game/compat_1.11.nut > share/openttd/game/compat_1.2.nut > share/openttd/game/compat_1.3.nut > share/openttd/game/compat_1.4.nut > @@ -142,85 +145,90 @@ share/openttd/lang/ukrainian.lng > share/openttd/lang/vietnamese.lng > share/openttd/lang/welsh.lng > share/openttd/media/ > +share/openttd/media/CMakeLists.txt > share/openttd/media/baseset/ > +share/openttd/media/baseset/CMakeLists.txt > share/openttd/media/baseset/no_music.obm > share/openttd/media/baseset/no_sound.obs > +share/openttd/media/baseset/openttd/ > +share/openttd/media/baseset/openttd.grf > +share/openttd/media/baseset/openttd/2ccmap.nfo > +share/openttd/media/baseset/openttd/CMakeLists.txt > +share/openttd/media/baseset/openttd/airport_preview.nfo > +share/openttd/media/baseset/openttd/airport_preview.png > +share/openttd/media/baseset/openttd/airports.nfo > +share/openttd/media/baseset/openttd/airports.png > +share/openttd/media/baseset/openttd/aqueduct.nfo > +share/openttd/media/baseset/openttd/aqueduct.png > +share/openttd/media/baseset/openttd/autorail.nfo > +share/openttd/media/baseset/openttd/autorail.png > +share/openttd/media/baseset/openttd/canal_locks.png > +share/openttd/media/baseset/openttd/canals.nfo > +share/openttd/media/baseset/openttd/canals.png > +share/openttd/media/baseset/openttd/chars.nfo > +share/openttd/media/baseset/openttd/chars.png > +share/openttd/media/baseset/openttd/elrails.nfo > +share/openttd/media/baseset/openttd/elrails.png > +share/openttd/media/baseset/openttd/flags.nfo > +share/openttd/media/baseset/openttd/flags.png > +share/openttd/media/baseset/openttd/foundations.nfo > +share/openttd/media/baseset/openttd/foundations.png > +share/openttd/media/baseset/openttd/mono.nfo > +share/openttd/media/baseset/openttd/mono.png > +share/openttd/media/baseset/openttd/oneway.nfo > +share/openttd/media/baseset/openttd/oneway.png > +share/openttd/media/baseset/openttd/openttd.nfo > +share/openttd/media/baseset/openttd/openttdgui.nfo > +share/openttd/media/baseset/openttd/openttdgui.png > +share/openttd/media/baseset/openttd/openttdgui_build_tram.png > +share/openttd/media/baseset/openttd/openttdgui_convert_road.png > +share/openttd/media/baseset/openttd/openttdgui_convert_tram.png > +share/openttd/media/baseset/openttd/openttdgui_group_livery.png > +share/openttd/media/baseset/openttd/palette.nfo > +share/openttd/media/baseset/openttd/roadstops.nfo > +share/openttd/media/baseset/openttd/roadstops.png > +share/openttd/media/baseset/openttd/signals.nfo > +share/openttd/media/baseset/openttd/signals.png > +share/openttd/media/baseset/openttd/sloped_tracks.nfo > +share/openttd/media/baseset/openttd/sloped_tracks.png > +share/openttd/media/baseset/openttd/tramtracks.nfo > +share/openttd/media/baseset/openttd/tramtracks.png > +share/openttd/media/baseset/openttd/tramtracks_bare_depot.png > +share/openttd/media/baseset/openttd/tunnel_portals.nfo > +share/openttd/media/baseset/openttd/tunnel_portals.png > +share/openttd/media/baseset/opntitle.dat > share/openttd/media/baseset/orig_dos.obg > share/openttd/media/baseset/orig_dos.obm > share/openttd/media/baseset/orig_dos.obs > share/openttd/media/baseset/orig_dos_de.obg > +share/openttd/media/baseset/orig_extra/ > +share/openttd/media/baseset/orig_extra.grf > +share/openttd/media/baseset/orig_extra/CMakeLists.txt > +share/openttd/media/baseset/orig_extra/airports_orig_extra.nfo > +share/openttd/media/baseset/orig_extra/canals_extra.nfo > +share/openttd/media/baseset/orig_extra/chars_orig_extra.nfo > +share/openttd/media/baseset/orig_extra/fix_graphics.nfo > +share/openttd/media/baseset/orig_extra/fix_graphics.png > +share/openttd/media/baseset/orig_extra/orig_extra.nfo > +share/openttd/media/baseset/orig_extra/rivers/ > +share/openttd/media/baseset/orig_extra/rivers/arctic.nfo > +share/openttd/media/baseset/orig_extra/rivers/arctic_brown.png > +share/openttd/media/baseset/orig_extra/rivers/arctic_snowy.png > +share/openttd/media/baseset/orig_extra/rivers/rapids.nfo > +share/openttd/media/baseset/orig_extra/rivers/rapids.png > +share/openttd/media/baseset/orig_extra/rivers/temperate.nfo > +share/openttd/media/baseset/orig_extra/rivers/temperate.png > +share/openttd/media/baseset/orig_extra/rivers/toyland.nfo > +share/openttd/media/baseset/orig_extra/rivers/toyland.png > +share/openttd/media/baseset/orig_extra/rivers/tropic.nfo > +share/openttd/media/baseset/orig_extra/rivers/tropic_desert.png > +share/openttd/media/baseset/orig_extra/rivers/tropic_forest.png > +share/openttd/media/baseset/orig_extra/shore.nfo > +share/openttd/media/baseset/orig_extra/shore.png > share/openttd/media/baseset/orig_tto.obm > share/openttd/media/baseset/orig_win.obg > share/openttd/media/baseset/orig_win.obm > share/openttd/media/baseset/orig_win.obs > -share/openttd/media/baseset/translations.awk > -share/openttd/media/baseset/translations.vbs > -share/openttd/media/extra_grf/ > -share/openttd/media/extra_grf/2ccmap.nfo > -share/openttd/media/extra_grf/airport_preview.nfo > -share/openttd/media/extra_grf/airport_preview.png > -share/openttd/media/extra_grf/airports.nfo > -share/openttd/media/extra_grf/airports.png > -share/openttd/media/extra_grf/airports_orig_extra.nfo > -share/openttd/media/extra_grf/aqueduct.nfo > -share/openttd/media/extra_grf/aqueduct.png > -share/openttd/media/extra_grf/assemble_nfo.awk > -share/openttd/media/extra_grf/autorail.nfo > -share/openttd/media/extra_grf/autorail.png > -share/openttd/media/extra_grf/canal_locks.png > -share/openttd/media/extra_grf/canals.nfo > -share/openttd/media/extra_grf/canals.png > -share/openttd/media/extra_grf/canals_extra.nfo > -share/openttd/media/extra_grf/chars.nfo > -share/openttd/media/extra_grf/chars.png > -share/openttd/media/extra_grf/chars_orig_extra.nfo > -share/openttd/media/extra_grf/elrails.nfo > -share/openttd/media/extra_grf/elrails.png > -share/openttd/media/extra_grf/fix_graphics.nfo > -share/openttd/media/extra_grf/fix_graphics.png > -share/openttd/media/extra_grf/flags.nfo > -share/openttd/media/extra_grf/flags.png > -share/openttd/media/extra_grf/foundations.nfo > -share/openttd/media/extra_grf/foundations.png > -share/openttd/media/extra_grf/mono.nfo > -share/openttd/media/extra_grf/mono.png > -share/openttd/media/extra_grf/oneway.nfo > -share/openttd/media/extra_grf/oneway.png > -share/openttd/media/extra_grf/openttd.nfo > -share/openttd/media/extra_grf/openttdgui.nfo > -share/openttd/media/extra_grf/openttdgui.png > -share/openttd/media/extra_grf/openttdgui_build_tram.png > -share/openttd/media/extra_grf/openttdgui_convert_road.png > -share/openttd/media/extra_grf/openttdgui_convert_tram.png > -share/openttd/media/extra_grf/openttdgui_group_livery.png > -share/openttd/media/extra_grf/orig_extra.nfo > -share/openttd/media/extra_grf/palette.nfo > -share/openttd/media/extra_grf/rivers/ > -share/openttd/media/extra_grf/rivers/arctic.nfo > -share/openttd/media/extra_grf/rivers/arctic_brown.png > -share/openttd/media/extra_grf/rivers/arctic_snowy.png > -share/openttd/media/extra_grf/rivers/rapids.nfo > -share/openttd/media/extra_grf/rivers/rapids.png > -share/openttd/media/extra_grf/rivers/temperate.nfo > -share/openttd/media/extra_grf/rivers/temperate.png > -share/openttd/media/extra_grf/rivers/toyland.nfo > -share/openttd/media/extra_grf/rivers/toyland.png > -share/openttd/media/extra_grf/rivers/tropic.nfo > -share/openttd/media/extra_grf/rivers/tropic_desert.png > -share/openttd/media/extra_grf/rivers/tropic_forest.png > -share/openttd/media/extra_grf/roadstops.nfo > -share/openttd/media/extra_grf/roadstops.png > -share/openttd/media/extra_grf/shore.nfo > -share/openttd/media/extra_grf/shore.png > -share/openttd/media/extra_grf/signals.nfo > -share/openttd/media/extra_grf/signals.png > -share/openttd/media/extra_grf/sloped_tracks.nfo > -share/openttd/media/extra_grf/sloped_tracks.png > -share/openttd/media/extra_grf/tramtracks.nfo > -share/openttd/media/extra_grf/tramtracks.png > -share/openttd/media/extra_grf/tramtracks_bare_depot.png > -share/openttd/media/extra_grf/tunnel_portals.nfo > -share/openttd/media/extra_grf/tunnel_portals.png > share/openttd/media/openttd.128.png > share/openttd/media/openttd.16.png > share/openttd/media/openttd.256.png > @@ -230,7 +238,6 @@ share/openttd/media/openttd.32.xpm > share/openttd/media/openttd.48.png > share/openttd/media/openttd.64.png > share/openttd/media/openttd.64.xpm > -share/openttd/media/openttd.ico > share/openttd/media/openttd.svg > share/openttd/scripts/ > share/openttd/scripts/autoexec.scr.example > @@ -242,7 +249,8 @@ share/openttd/scripts/on_server_connect. > share/openttd/scripts/pre_dedicated.scr.example > share/openttd/scripts/pre_server.scr.example > share/openttd/scripts/readme.txt > -share/pixmaps/ > -share/pixmaps/openttd.32.xpm > @tag update-desktop-database > @tag gtk-update-icon-cache %D/share/icons/hicolor > +share/pixmaps/ > +share/pixmaps/openttd.32.xpm > +share/pixmaps/openttd.64.xpm > -- Paco Esteban. 0x5818130B8A6DBC03