From ebff69b36d297f5e535c679af450210c71e29526 Mon Sep 17 00:00:00 2001 From: Maciej Mrozowski Date: Thu, 22 May 2025 08:52:31 +0200 Subject: [PATCH] games-simulation/flightgear: version bump 2024.1.1, remove old, #951572 Closes: https://bugs.gentoo.org/951572 Signed-off-by: Maciej Mrozowski --- dev-games/simgear/Manifest | 2 +- ...-that-n-is-not-being-set-as-format-t.patch | 34 + .../files/0002-fix-support-for-aarch64.patch | 25 + .../files/simgear-2019.1.1-gdal3.patch | 12 - ...-2020.1.2-do-not-assume-libc++-clang.patch | 12 - .../files/simgear-2020.3.17-boost-1.81.patch | 11 - ...r-2020.3.19-flightgear-CVE-2025-0781.patch | 84 --- dev-games/simgear/metadata.xml | 4 +- ...3.19-r1.ebuild => simgear-2024.1.1.ebuild} | 36 +- dev-games/simgear/simgear-9999.ebuild | 37 +- games-simulation/flightgear-data/Manifest | 2 +- ...ebuild => flightgear-data-2024.1.1.ebuild} | 11 +- .../flightgear-data-9999.ebuild | 8 +- games-simulation/flightgear-data/metadata.xml | 2 +- games-simulation/flightgear/Manifest | 2 +- ...-that-n-is-not-being-set-as-format-t.patch | 33 + ...003-make-fglauncher-a-static-library.patch | 25 + .../0005-make-fgqmlui-a-static-library.patch | 25 + .../0006-fgviewer-fix-crash-on-exit.patch | 29 + .../flightgear-2020.3.19-CVE-2025-0781.patch | 61 -- .../files/flightgear-2020.3.8-cmake.patch | 45 -- .../files/flightgear-2024.1.1-cmake.patch | 43 ++ .../flightgear-2024.1.1-fix-fgpanel.patch | 709 ++++++++++++++++++ ...9-r1.ebuild => flightgear-2024.1.1.ebuild} | 59 +- .../flightgear/flightgear-9999.ebuild | 57 +- games-simulation/flightgear/metadata.xml | 4 +- profiles/base/package.use.force | 4 - profiles/base/package.use.mask | 5 + 28 files changed, 1026 insertions(+), 355 deletions(-) create mode 100644 dev-games/simgear/files/0001-check-to-be-sure-that-n-is-not-being-set-as-format-t.patch create mode 100644 dev-games/simgear/files/0002-fix-support-for-aarch64.patch delete mode 100644 dev-games/simgear/files/simgear-2019.1.1-gdal3.patch delete mode 100644 dev-games/simgear/files/simgear-2020.1.2-do-not-assume-libc++-clang.patch delete mode 100644 dev-games/simgear/files/simgear-2020.3.17-boost-1.81.patch delete mode 100644 dev-games/simgear/files/simgear-2020.3.19-flightgear-CVE-2025-0781.patch rename dev-games/simgear/{simgear-2020.3.19-r1.ebuild => simgear-2024.1.1.ebuild} (59%) rename games-simulation/flightgear-data/{flightgear-data-2020.3.19.ebuild => flightgear-data-2024.1.1.ebuild} (60%) create mode 100644 games-simulation/flightgear/files/0001-check-to-be-sure-that-n-is-not-being-set-as-format-t.patch create mode 100644 games-simulation/flightgear/files/0003-make-fglauncher-a-static-library.patch create mode 100644 games-simulation/flightgear/files/0005-make-fgqmlui-a-static-library.patch create mode 100644 games-simulation/flightgear/files/0006-fgviewer-fix-crash-on-exit.patch delete mode 100644 games-simulation/flightgear/files/flightgear-2020.3.19-CVE-2025-0781.patch delete mode 100644 games-simulation/flightgear/files/flightgear-2020.3.8-cmake.patch create mode 100644 games-simulation/flightgear/files/flightgear-2024.1.1-cmake.patch create mode 100644 games-simulation/flightgear/files/flightgear-2024.1.1-fix-fgpanel.patch rename games-simulation/flightgear/{flightgear-2020.3.19-r1.ebuild => flightgear-2024.1.1.ebuild} (78%) diff --git a/dev-games/simgear/Manifest b/dev-games/simgear/Manifest index 4b9a4b11d829c..ca1871b827580 100644 --- a/dev-games/simgear/Manifest +++ b/dev-games/simgear/Manifest @@ -1 +1 @@ -DIST simgear-2020.3.19.tar.bz2 1427799 BLAKE2B a3c90756053d01fdbb7f7518cbf58018b21a1e7acfbee523ffda0ba27682113c67c531b2f0c0678d7e962f365411811b7044e0df9b995e0d3eabef2ede431757 SHA512 b5c2acb9b843c48e573764c1474bc8723167376546d2fe01246ea936d348abf7e26c8778037680dc76fad5e514209ccce03f8c49cdd90ff0fb44f86759f9ec64 +DIST simgear-2024.1.1.tar.bz2 1814060 BLAKE2B 296122debafe91fec4bad682071bd77d7ac84aac009fdca5db4143351da1a8fb6221c5137abb6bee66d49d0ff6417d7c8455ba738c66f4608dcead2f162fe274 SHA512 dfdf5515c3b8083bb9a314ce4cea619b049e33ca332cecaa14928be95de7ddadef1724c1aec126c49bfade030774b7952f79bb55facd1d3e2f26041f706eb231 diff --git a/dev-games/simgear/files/0001-check-to-be-sure-that-n-is-not-being-set-as-format-t.patch b/dev-games/simgear/files/0001-check-to-be-sure-that-n-is-not-being-set-as-format-t.patch new file mode 100644 index 0000000000000..fb31de6d7f5dd --- /dev/null +++ b/dev-games/simgear/files/0001-check-to-be-sure-that-n-is-not-being-set-as-format-t.patch @@ -0,0 +1,34 @@ +From 9465f10110e02686b3f8a860520a7e8f3c6a7936 Mon Sep 17 00:00:00 2001 +From: Fabrice Bellet +Date: Sun, 22 Sep 2013 11:56:12 +0200 +Subject: [PATCH 0/1] check to be sure that %n is not being set as format type + (CVE-2012-2090) + +--- + simgear/scene/model/SGText.cxx | 10 ++++++++++ + 1 file changed, 10 insertions(+) + +diff --git a/simgear/scene/model/SGText.cxx b/simgear/scene/model/SGText.cxx +index 08e84439..bc673511 100644 +--- a/simgear/scene/model/SGText.cxx ++++ b/simgear/scene/model/SGText.cxx +@@ -73,6 +73,16 @@ void SGText::UpdateCallback::operator()(osg::Node * node, osg::NodeVisitor *nv ) + // FIXME: + // hopefully the users never specifies bad formats here + // this should better be something more robust ++ // It is never safe for format.c_str to be %n. ++ string unsafe ("%n"); ++ size_t found; ++ ++ found=format.find(unsafe); ++ if (found!=string::npos) { ++ SG_LOG(SG_GENERAL, SG_ALERT, "format type contained %n, but this is unsafe, reverting to %s"); ++ format = "%s"; ++ } ++ + char buf[256]; + if( numeric ) { + double d = property->getDoubleValue() * scale + offset; +-- +2.48.1 + diff --git a/dev-games/simgear/files/0002-fix-support-for-aarch64.patch b/dev-games/simgear/files/0002-fix-support-for-aarch64.patch new file mode 100644 index 0000000000000..e83856a465606 --- /dev/null +++ b/dev-games/simgear/files/0002-fix-support-for-aarch64.patch @@ -0,0 +1,25 @@ +From 560be7700e03b20e5f252fed371ac14a0e7a7c17 Mon Sep 17 00:00:00 2001 +From: Fabrice Bellet +Date: Fri, 19 Feb 2016 15:57:19 +0100 +Subject: [PATCH 1/1] fix support for aarch64 + +--- + simgear/nasal/naref.h | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/simgear/nasal/naref.h b/simgear/nasal/naref.h +index 21f766f5..7e269a1f 100644 +--- a/simgear/nasal/naref.h ++++ b/simgear/nasal/naref.h +@@ -18,7 +18,7 @@ + # endif + #elif defined(_M_IX86) || defined(__i386) || defined(__x86_64) || \ + defined(__ia64__) || defined(_M_IA64) || defined(__ARMEL__) || \ +- defined(_M_X64) || defined(_M_ARM) || \ ++ defined(_M_X64) || defined(_M_ARM) || defined(__aarch64__) || \ + defined(__e2k__) + # define NASAL_LE + #elif defined(__sparc) || defined(__ARMEB__) || \ +-- +2.48.1 + diff --git a/dev-games/simgear/files/simgear-2019.1.1-gdal3.patch b/dev-games/simgear/files/simgear-2019.1.1-gdal3.patch deleted file mode 100644 index 6d48994224c88..0000000000000 --- a/dev-games/simgear/files/simgear-2019.1.1-gdal3.patch +++ /dev/null @@ -1,12 +0,0 @@ -diff --git a/CMakeLists.txt b/CMakeLists.txt -index 8a2f59f..5916c4c 100644 ---- a/CMakeLists.txt -+++ b/CMakeLists.txt -@@ -308,6 +308,7 @@ endif(ENABLE_RTI) - if(ENABLE_GDAL) - find_package(GDAL 2.0.0 REQUIRED) - if (GDAL_FOUND) -+ add_compile_definitions(USE_DEPRECATED_SRS_WKT_WGS84) - include_directories(${GDAL_INCLUDE_DIR}) - endif(GDAL_FOUND) - endif(ENABLE_GDAL) diff --git a/dev-games/simgear/files/simgear-2020.1.2-do-not-assume-libc++-clang.patch b/dev-games/simgear/files/simgear-2020.1.2-do-not-assume-libc++-clang.patch deleted file mode 100644 index 3ff70aeebdc59..0000000000000 --- a/dev-games/simgear/files/simgear-2020.1.2-do-not-assume-libc++-clang.patch +++ /dev/null @@ -1,12 +0,0 @@ -diff -ruN simgear-2020.1.2/CMakeLists.txt simgear-my/CMakeLists.txt ---- simgear-2020.1.2/CMakeLists.txt 2020-05-24 17:13:35.000000000 +0200 -+++ simgear-my/CMakeLists.txt 2020-10-17 15:48:58.375116913 +0200 -@@ -442,8 +442,6 @@ - set(WARNING_FLAGS_CXX "-Wall -fPIC -Wno-overloaded-virtual -Wno-redeclared-class-member") - set(WARNING_FLAGS_C "-Wall -fPIC") - set(CMAKE_XCODE_ATTRIBUTE_CLANG_CXX_LIBRARY "libc++") -- # fix Boost compilation :( -- set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -stdlib=libc++") - - # override CMake default RelWithDebInfo flags. - set(CMAKE_CXX_FLAGS_RELWITHDEBINFO "-O3 -g -DNDEBUG") diff --git a/dev-games/simgear/files/simgear-2020.3.17-boost-1.81.patch b/dev-games/simgear/files/simgear-2020.3.17-boost-1.81.patch deleted file mode 100644 index 6edcafcea0310..0000000000000 --- a/dev-games/simgear/files/simgear-2020.3.17-boost-1.81.patch +++ /dev/null @@ -1,11 +0,0 @@ -https://bugs.gentoo.org/887431 ---- a/simgear/scene/viewer/Compositor.hxx -+++ b/simgear/scene/viewer/Compositor.hxx -@@ -17,6 +17,7 @@ - #ifndef SG_COMPOSITOR_HXX - #define SG_COMPOSITOR_HXX - -+#include - #include - #include - diff --git a/dev-games/simgear/files/simgear-2020.3.19-flightgear-CVE-2025-0781.patch b/dev-games/simgear/files/simgear-2020.3.19-flightgear-CVE-2025-0781.patch deleted file mode 100644 index 3de416a1a2e96..0000000000000 --- a/dev-games/simgear/files/simgear-2020.3.19-flightgear-CVE-2025-0781.patch +++ /dev/null @@ -1,84 +0,0 @@ -From 5bb023647114267141a7610e8f1ca7d6f4f5a5a8 Mon Sep 17 00:00:00 2001 -From: Florent Rougon -Date: Tue, 21 Jan 2025 00:16:43 +0100 -Subject: [PATCH] cppbind: check I/O rules when auto-constructing an SGPath - from a Nasal scalar - -- Add static member function SGPath::NasalIORulesChecker as a - PermissionChecker (this is essentially checkIORules() moved from the - flightgear repository). - -- Use it in the from_nasal_helper() that creates an SGPath instance from - a Nasal scalar. ---- - simgear/misc/sg_path.cxx | 20 +++++++++++++++++++ - simgear/misc/sg_path.hxx | 7 +++++++ - .../cppbind/detail/from_nasal_helper.cxx | 3 ++- - 3 files changed, 29 insertions(+), 1 deletion(-) - -diff --git a/simgear/misc/sg_path.cxx b/simgear/misc/sg_path.cxx -index f6c5b089e..c66bc72c4 100644 ---- a/simgear/misc/sg_path.cxx -+++ b/simgear/misc/sg_path.cxx -@@ -275,6 +275,26 @@ void SGPath::set_cached(bool cached) - // * Access permissions for Nasal code * - // *************************************************************************** - -+// Static member function -+SGPath::Permissions SGPath::NasalIORulesChecker(const SGPath& path) -+{ -+ Permissions perm; -+ -+ if (!path.isAbsolute()) { -+ // SGPath caches permissions, which breaks for relative paths if the -+ // current directory changes. -+ SG_LOG(SG_NASAL, SG_ALERT, -+ "SGPath::NasalIORulesChecker(): file operation on '" << -+ path.utf8Str() << "': access denied (relative paths not " -+ "accepted; use realpath() to obtain an absolute path)"); -+ } -+ -+ perm.read = path.isAbsolute() && !path.validate(false).isNull(); -+ perm.write = path.isAbsolute() && !path.validate(true).isNull(); -+ -+ return perm; -+} -+ - // Static member function - void SGPath::clearListOfAllowedPaths(bool write) - { -diff --git a/simgear/misc/sg_path.hxx b/simgear/misc/sg_path.hxx -index 32e9d662b..75da94c95 100644 ---- a/simgear/misc/sg_path.hxx -+++ b/simgear/misc/sg_path.hxx -@@ -162,6 +162,13 @@ public: - */ - SGPath validate(bool write) const; - -+ /** -+ * Normal PermissionChecker for SGPath instances created from Nasal. -+ * @param path an SGPath instance -+ * @return read and write permissions conforming to validate() -+ */ -+ static Permissions NasalIORulesChecker(const SGPath& path); -+ - /** - * Append another piece to the existing path. Inserts a path - * separator between the existing component and the new component. -diff --git a/simgear/nasal/cppbind/detail/from_nasal_helper.cxx b/simgear/nasal/cppbind/detail/from_nasal_helper.cxx -index bdf10fe5e..ad027c0b0 100644 ---- a/simgear/nasal/cppbind/detail/from_nasal_helper.cxx -+++ b/simgear/nasal/cppbind/detail/from_nasal_helper.cxx -@@ -47,7 +47,8 @@ namespace nasal - SGPath from_nasal_helper(naContext c, naRef ref, const SGPath*) - { - naRef na_str = naStringValue(c, ref); -- return SGPath(std::string(naStr_data(na_str), naStr_len(na_str))); -+ return SGPath(std::string(naStr_data(na_str), naStr_len(na_str)), -+ &SGPath::NasalIORulesChecker); - } - - //---------------------------------------------------------------------------- --- -GitLab - diff --git a/dev-games/simgear/metadata.xml b/dev-games/simgear/metadata.xml index 241bec9110a6a..b81abeee21c92 100644 --- a/dev-games/simgear/metadata.xml +++ b/dev-games/simgear/metadata.xml @@ -14,11 +14,11 @@ SimGear is a set of open-source libraries designed to be used as building blocks quickly assembling 3d simulations, games, and visualization applications. - Enable DNS resolver via net-libs/udns + Enable video recording via media-video/ffmpeg Enable alternative terrain engine based on pagedLOD via sci-libs/gdal Enable terrasync scenery downloader - flightgear + flightgear/simgear diff --git a/dev-games/simgear/simgear-2020.3.19-r1.ebuild b/dev-games/simgear/simgear-2024.1.1.ebuild similarity index 59% rename from dev-games/simgear/simgear-2020.3.19-r1.ebuild rename to dev-games/simgear/simgear-2024.1.1.ebuild index fac3a4948f31c..900c52e996b89 100644 --- a/dev-games/simgear/simgear-2020.3.19-r1.ebuild +++ b/dev-games/simgear/simgear-2024.1.1.ebuild @@ -1,30 +1,31 @@ # Copyright 1999-2025 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 -EAPI=7 +EAPI=8 -inherit cmake toolchain-funcs +inherit cmake DESCRIPTION="Development library for simulation games" HOMEPAGE="https://www.flightgear.org/" -SRC_URI="https://downloads.sourceforge.net/flightgear/${P}.tar.bz2" +SRC_URI="https://gitlab.com/flightgear/fgmeta/-/jobs/9264813015/artifacts/raw/sgbuild/${P}.tar.bz2" LICENSE="GPL-2" -KEYWORDS="~amd64 ~x86" SLOT="0" -IUSE="cpu_flags_x86_sse2 +dns debug gdal openmp subversion test" +KEYWORDS="~amd64 ~x86" +IUSE="cpu_flags_x86_sse2 debug ffmpeg gdal subversion test" RESTRICT="!test? ( test )" -# TODO aeonwave +# TODO AeonWave, CycloneDDS COMMON_DEPEND=" app-arch/xz-utils dev-libs/expat dev-games/openscenegraph media-libs/openal + net-libs/udns net-misc/curl sys-libs/zlib virtual/opengl - dns? ( net-libs/udns ) + ffmpeg? ( media-video/ffmpeg:0 ) gdal? ( sci-libs/gdal:= ) " DEPEND="${COMMON_DEPEND} @@ -35,35 +36,28 @@ RDEPEND="${COMMON_DEPEND} " PATCHES=( - "${FILESDIR}/${PN}-2019.1.1-gdal3.patch" - "${FILESDIR}/${PN}-2020.1.2-do-not-assume-libc++-clang.patch" - "${FILESDIR}/${PN}-2020.3.17-boost-1.81.patch" - "${FILESDIR}/${PN}-2020.3.19-flightgear-CVE-2025-0781.patch" + "${FILESDIR}/0001-check-to-be-sure-that-n-is-not-being-set-as-format-t.patch" + "${FILESDIR}/0002-fix-support-for-aarch64.patch" ) -pkg_pretend() { - [[ ${MERGE_TYPE} != binary ]] && use openmp && tc-check-openmp -} - -pkg_setup() { - [[ ${MERGE_TYPE} != binary ]] && use openmp && tc-check-openmp -} - src_configure() { local mycmakeargs=( - -DENABLE_DNS=$(usex dns) + -DENABLE_ASAN=OFF + -DENABLE_CYCLONE=OFF -DENABLE_GDAL=$(usex gdal) - -DENABLE_OPENMP=$(usex openmp) -DENABLE_PKGUTIL=ON -DENABLE_RTI=OFF -DENABLE_SIMD=$(usex cpu_flags_x86_sse2) -DENABLE_SOUND=ON -DENABLE_TESTS=$(usex test) + -DENABLE_TSAN=OFF + -DENABLE_VIDEO_RECORD=$(usex ffmpeg) -DSIMGEAR_HEADLESS=OFF -DSIMGEAR_SHARED=ON -DSYSTEM_EXPAT=ON -DSYSTEM_UDNS=ON -DUSE_AEONWAVE=OFF + -DUSE_OPENALSOFT=ON -DOSG_FSTREAM_EXPORT_FIXED=OFF # TODO perhaps track it ) cmake_src_configure diff --git a/dev-games/simgear/simgear-9999.ebuild b/dev-games/simgear/simgear-9999.ebuild index a00bfb2e0bd78..0bd95f07ace04 100644 --- a/dev-games/simgear/simgear-9999.ebuild +++ b/dev-games/simgear/simgear-9999.ebuild @@ -1,30 +1,31 @@ -# Copyright 1999-2024 Gentoo Authors +# Copyright 1999-2025 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 -EAPI=7 +EAPI=8 -inherit cmake toolchain-funcs git-r3 +inherit cmake git-r3 DESCRIPTION="Development library for simulation games" HOMEPAGE="https://www.flightgear.org/" -EGIT_REPO_URI="https://git.code.sf.net/p/flightgear/${PN}" +EGIT_REPO_URI="https://gitlab.com/flightgear/${PN}.git" EGIT_BRANCH="next" LICENSE="GPL-2" -KEYWORDS="" SLOT="0" -IUSE="cpu_flags_x86_sse2 +dns debug gdal openmp subversion test" +KEYWORDS="" +IUSE="cpu_flags_x86_sse2 debug ffmpeg gdal subversion test" RESTRICT="!test? ( test )" -# TODO aeonwave +# TODO AeonWave, CycloneDDS COMMON_DEPEND=" dev-libs/expat dev-games/openscenegraph media-libs/openal + net-libs/udns net-misc/curl sys-libs/zlib virtual/opengl - dns? ( net-libs/udns ) + ffmpeg? ( media-video/ffmpeg:0 ) gdal? ( sci-libs/gdal:= ) " DEPEND="${COMMON_DEPEND} @@ -34,34 +35,24 @@ RDEPEND="${COMMON_DEPEND} subversion? ( dev-vcs/subversion ) " -PATCHES=( - "${FILESDIR}/${PN}-2019.1.1-gdal3.patch" - "${FILESDIR}/${PN}-2020.1.2-do-not-assume-libc++-clang.patch" -) - -pkg_pretend() { - [[ ${MERGE_TYPE} != binary ]] && use openmp && tc-check-openmp -} - -pkg_setup() { - [[ ${MERGE_TYPE} != binary ]] && use openmp && tc-check-openmp -} - src_configure() { local mycmakeargs=( - -DENABLE_DNS=$(usex dns) + -DENABLE_ASAN=OFF + -DENABLE_CYCLONE=OFF -DENABLE_GDAL=$(usex gdal) - -DENABLE_OPENMP=$(usex openmp) -DENABLE_PKGUTIL=ON -DENABLE_RTI=OFF -DENABLE_SIMD=$(usex cpu_flags_x86_sse2) -DENABLE_SOUND=ON -DENABLE_TESTS=$(usex test) + -DENABLE_TSAN=OFF + -DENABLE_VIDEO_RECORD=$(usex ffmpeg) -DSIMGEAR_HEADLESS=OFF -DSIMGEAR_SHARED=ON -DSYSTEM_EXPAT=ON -DSYSTEM_UDNS=ON -DUSE_AEONWAVE=OFF + -DUSE_OPENALSOFT=ON -DOSG_FSTREAM_EXPORT_FIXED=OFF # TODO perhaps track it ) cmake_src_configure diff --git a/games-simulation/flightgear-data/Manifest b/games-simulation/flightgear-data/Manifest index 3526353df994f..dfd4bbb60dc16 100644 --- a/games-simulation/flightgear-data/Manifest +++ b/games-simulation/flightgear-data/Manifest @@ -1 +1 @@ -DIST FlightGear-2020.3.19-data.txz 1789370768 BLAKE2B 2fa77d7821dc866e871ad92587204e82cb8bd2a961055b32a880285163505cd17b0044425a3b9d58cf181f32d94fdddbf4abc6e9e81d1264cf3d0173b9d65554 SHA512 054efd8a77f55b16e955d6489f34c671d927b3c4c6ea1d15e244189b1852215cee36de927a1a82d04e81d9afc3e8af8575724935c2113dfba919426be5f0eb95 +DIST FlightGear-2024.1.1-data.txz 1873735848 BLAKE2B b43cfd5aa90f749fb6f0c40c25c94e494a296c92eca452d7e171dd4654d9aae3b80c432cb0bd69af44981ec0704776d91cf85f67d6d93fe3b58db19859094e33 SHA512 ab478e806248783b4b8bb4ab5250d83e41f523c466beb3655fdb58e3ca508b2fb58247adb55041101e82729c9063901298b8220a608ddba5e9d3c80fc7575061 diff --git a/games-simulation/flightgear-data/flightgear-data-2020.3.19.ebuild b/games-simulation/flightgear-data/flightgear-data-2024.1.1.ebuild similarity index 60% rename from games-simulation/flightgear-data/flightgear-data-2020.3.19.ebuild rename to games-simulation/flightgear-data/flightgear-data-2024.1.1.ebuild index 24cfae895a84f..470dc9147526d 100644 --- a/games-simulation/flightgear-data/flightgear-data-2020.3.19.ebuild +++ b/games-simulation/flightgear-data/flightgear-data-2024.1.1.ebuild @@ -1,18 +1,17 @@ -# Copyright 1999-2024 Gentoo Authors +# Copyright 1999-2025 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 -EAPI=7 +EAPI=8 DESCRIPTION="FlightGear data files" HOMEPAGE="https://www.flightgear.org/" -SRC_URI="https://downloads.sourceforge.net/flightgear/FlightGear-${PV}-data.txz" +SRC_URI="https://download.flightgear.org/release-2024.1/FlightGear-${PV}-data.txz" + +S=${WORKDIR}/fgdata_$(ver_cut 1)_$(ver_cut 2) LICENSE="GPL-2" SLOT="0" KEYWORDS="~amd64 ~x86" -IUSE="" - -S=${WORKDIR}/fgdata src_install() { insinto /usr/share/flightgear diff --git a/games-simulation/flightgear-data/flightgear-data-9999.ebuild b/games-simulation/flightgear-data/flightgear-data-9999.ebuild index 27d27dcf76bf0..4689c0dd649c4 100644 --- a/games-simulation/flightgear-data/flightgear-data-9999.ebuild +++ b/games-simulation/flightgear-data/flightgear-data-9999.ebuild @@ -1,20 +1,18 @@ -# Copyright 1999-2020 Gentoo Authors +# Copyright 1999-2025 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 -EAPI=7 +EAPI=8 inherit git-r3 DESCRIPTION="FlightGear data files" HOMEPAGE="https://www.flightgear.org/" -EGIT_REPO_URI="git://git.code.sf.net/p/flightgear/fgdata - git://mapserver.flightgear.org/fgdata" +EGIT_REPO_URI="https://gitlab.com/flightgear/fgdata.git" EGIT_BRANCH="next" LICENSE="GPL-2" SLOT="0" KEYWORDS="" -IUSE="" src_install() { insinto /usr/share/flightgear diff --git a/games-simulation/flightgear-data/metadata.xml b/games-simulation/flightgear-data/metadata.xml index 5f385ce0fbfd9..6b3e58480c7fc 100644 --- a/games-simulation/flightgear-data/metadata.xml +++ b/games-simulation/flightgear-data/metadata.xml @@ -10,6 +10,6 @@ Gentoo Games Project - flightgear + flightgear/fgdata diff --git a/games-simulation/flightgear/Manifest b/games-simulation/flightgear/Manifest index 4c646ab93dec5..cc775842173bf 100644 --- a/games-simulation/flightgear/Manifest +++ b/games-simulation/flightgear/Manifest @@ -1 +1 @@ -DIST flightgear-2020.3.19.tar.bz2 8935152 BLAKE2B cc4ae515278ced52186683ae44b0ebf0aba9569fac12c5a5646b2a420663154651edcbf7eba18a040127f2d90dbffa1f48000529e8adc944d22fb314ce53c091 SHA512 ad5a4dd455a92bd9032c0f01084c0c114e4a91e60d53f200a754e54e1f8e08fd8e9008ea9f97f69410ee842fdc6c2210091d4ac5e5c6da6ba19f47e22438d207 +DIST flightgear-2024.1.1.tar.bz2 9421622 BLAKE2B 1ac040e66d651da16dd25d92a07b70670ccba55269997afb7789374b64f3cde73d0f5d8230f2048656b4f06e78534f013e608e8d908ad902104a98b72b0304ca SHA512 7d5cd04a6da75e0a5099ee545ef55f795c9493c15dbfecb6b534f8aa9374c972ba3cb60c31299a2132835a235ab7fc017a20c7b386522663238e4c1876865bb2 diff --git a/games-simulation/flightgear/files/0001-check-to-be-sure-that-n-is-not-being-set-as-format-t.patch b/games-simulation/flightgear/files/0001-check-to-be-sure-that-n-is-not-being-set-as-format-t.patch new file mode 100644 index 0000000000000..1cf5e6b4fa543 --- /dev/null +++ b/games-simulation/flightgear/files/0001-check-to-be-sure-that-n-is-not-being-set-as-format-t.patch @@ -0,0 +1,33 @@ +From 609b73ec6941321b157afb236f86c943f959a845 Mon Sep 17 00:00:00 2001 +From: Fabrice Bellet +Date: Sun, 22 Sep 2013 12:19:18 +0200 +Subject: [PATCH] check to be sure that %n is not being set as format type + (CVE-2012-2090) + +--- + src/Environment/fgclouds.cxx | 9 +++++++++ + 1 file changed, 9 insertions(+) + +diff --git a/src/Environment/fgclouds.cxx b/src/Environment/fgclouds.cxx +index 043cbb007..a57c529d8 100644 +--- a/src/Environment/fgclouds.cxx ++++ b/src/Environment/fgclouds.cxx +@@ -218,6 +218,15 @@ void FGClouds::buildLayer(int iLayer, const string& name, double coverage) { + double count = acloud->getDoubleValue("count", 1.0); + tCloudVariety[CloudVarietyCount].count = count; + int variety = 0; ++ // It is never safe for cloud_name.c_str to be %n. ++ string unsafe ("%n"); ++ size_t found; ++ ++ found=cloud_name.find(unsafe); ++ if (found!=string::npos) { ++ SG_LOG(SG_GENERAL, SG_ALERT, "format type contained %n, but this is unsafe , ignore it"); ++ continue; ++ } + char variety_name[50]; + do { + variety++; +-- +2.48.1 + diff --git a/games-simulation/flightgear/files/0003-make-fglauncher-a-static-library.patch b/games-simulation/flightgear/files/0003-make-fglauncher-a-static-library.patch new file mode 100644 index 0000000000000..a205953c8a4ec --- /dev/null +++ b/games-simulation/flightgear/files/0003-make-fglauncher-a-static-library.patch @@ -0,0 +1,25 @@ +From 00de7fd687bdc7ab7c679678f3a523d2038b7d8f Mon Sep 17 00:00:00 2001 +From: Fabrice Bellet +Date: Tue, 17 Feb 2015 23:00:29 +0100 +Subject: [PATCH] make fglauncher a static library + +--- + src/GUI/CMakeLists.txt | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/src/GUI/CMakeLists.txt b/src/GUI/CMakeLists.txt +index f4fc01a6e..0a0bd3398 100644 +--- a/src/GUI/CMakeLists.txt ++++ b/src/GUI/CMakeLists.txt +@@ -104,7 +104,7 @@ if (HAVE_QT) + + + +- add_library(fglauncher QtLauncher.cxx ++ add_library(fglauncher STATIC QtLauncher.cxx + QtLauncher.hxx + SettingsWrapper.hxx + LauncherMainWindow.hxx +-- +2.48.1 + diff --git a/games-simulation/flightgear/files/0005-make-fgqmlui-a-static-library.patch b/games-simulation/flightgear/files/0005-make-fgqmlui-a-static-library.patch new file mode 100644 index 0000000000000..450a701a5a260 --- /dev/null +++ b/games-simulation/flightgear/files/0005-make-fgqmlui-a-static-library.patch @@ -0,0 +1,25 @@ +From 5cd88182e3b8f3e011be53a307cbf981dbb97836 Mon Sep 17 00:00:00 2001 +From: Fabrice Bellet +Date: Sun, 8 Apr 2018 18:03:30 +0200 +Subject: [PATCH] make fgqmlui a static library + +--- + src/GUI/CMakeLists.txt | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/src/GUI/CMakeLists.txt b/src/GUI/CMakeLists.txt +index 0a0bd3398..34a1e1f2d 100644 +--- a/src/GUI/CMakeLists.txt ++++ b/src/GUI/CMakeLists.txt +@@ -185,7 +185,7 @@ if (HAVE_QT) + Qt${QT_VERSION_MAJOR}::Svg + SimGearCore) + +- add_library(fgqmlui ++ add_library(fgqmlui STATIC + PropertyItemModel.cxx + PropertyItemModel.hxx + FGQmlInstance.cxx +-- +2.48.1 + diff --git a/games-simulation/flightgear/files/0006-fgviewer-fix-crash-on-exit.patch b/games-simulation/flightgear/files/0006-fgviewer-fix-crash-on-exit.patch new file mode 100644 index 0000000000000..a93c6e0093564 --- /dev/null +++ b/games-simulation/flightgear/files/0006-fgviewer-fix-crash-on-exit.patch @@ -0,0 +1,29 @@ +From 95101b6fedaa332c70caca15a8fc762355d499b3 Mon Sep 17 00:00:00 2001 +From: Fabrice Bellet +Date: Wed, 7 Jun 2017 09:19:06 +0200 +Subject: [PATCH] fgviewer: fix crash on exit + +--- + utils/fgviewer/fgviewer.cxx | 8 +++++++- + 1 file changed, 7 insertions(+), 1 deletion(-) + +diff --git a/utils/fgviewer/fgviewer.cxx b/utils/fgviewer/fgviewer.cxx +index 1af450e96..c5628cef8 100644 +--- a/utils/fgviewer/fgviewer.cxx ++++ b/utils/fgviewer/fgviewer.cxx +@@ -271,5 +271,11 @@ main(int argc, char** argv) + // Note that this does not affect the hla camera manipulator + viewer.home(); + +- return viewer.run(); ++ int result = viewer.run(); ++ ++ // clear cache now, since it contains SimGear objects. Otherwise SG_LOG ++ // calls during shutdown will cause crashes. ++ osgDB::Registry::instance()->clearObjectCache(); ++ ++ return result; + } +-- +2.48.1 + diff --git a/games-simulation/flightgear/files/flightgear-2020.3.19-CVE-2025-0781.patch b/games-simulation/flightgear/files/flightgear-2020.3.19-CVE-2025-0781.patch deleted file mode 100644 index eb8e092c5d7ad..0000000000000 --- a/games-simulation/flightgear/files/flightgear-2020.3.19-CVE-2025-0781.patch +++ /dev/null @@ -1,61 +0,0 @@ -From ad37afce28083fad7f79467b3ffdead753584358 Mon Sep 17 00:00:00 2001 -From: Florent Rougon -Date: Tue, 21 Jan 2025 00:31:22 +0100 -Subject: [PATCH] NasalSGPath: move checkIORules() to - SGPath::NasalIORulesChecker() - -This allows the from_nasal_helper() in SimGear that constructs SGPath -instances from Nasal scalars to use SGPath::NasalIORulesChecker() as a -PermissionChecker. ---- - src/Scripting/NasalSGPath.cxx | 23 ++++------------------- - 1 file changed, 4 insertions(+), 19 deletions(-) - -diff --git a/src/Scripting/NasalSGPath.cxx b/src/Scripting/NasalSGPath.cxx -index 92abbbe873..d5f49d8922 100644 ---- a/src/Scripting/NasalSGPath.cxx -+++ b/src/Scripting/NasalSGPath.cxx -@@ -30,28 +30,12 @@ - typedef std::shared_ptr SGPathRef; - typedef nasal::Ghost NasalSGPath; - --SGPath::Permissions checkIORules(const SGPath& path) --{ -- SGPath::Permissions perm; -- if (!path.isAbsolute()) { -- // SGPath caches permissions, which breaks for relative paths -- // if the current directory changes -- SG_LOG(SG_NASAL, SG_ALERT, "os.path: file operation on '" << -- path<< "' access denied (relative paths not accepted; use " -- "realpath() to make a path absolute)"); -- } -- -- perm.read = path.isAbsolute() && !SGPath(path).validate(false).isNull(); -- perm.write = path.isAbsolute() && !SGPath(path).validate(true).isNull(); -- -- return perm; --} -- - // TODO make exposing such function easier... - static naRef validatedPathToNasal( const nasal::CallContext& ctx, - const SGPath& p ) - { -- return ctx.to_nasal( SGPathRef(new SGPath(p.utf8Str(), &checkIORules)) ); -+ return ctx.to_nasal(SGPathRef(new SGPath(p.utf8Str(), -+ &SGPath::NasalIORulesChecker))); - } - - /** -@@ -78,7 +62,8 @@ static void f_path_set(SGPath& p, const nasal::CallContext& ctx) - */ - static naRef f_desktop(const nasal::CallContext& ctx) - { -- return validatedPathToNasal(ctx, SGPath::desktop(SGPath(&checkIORules))); -+ return validatedPathToNasal( -+ ctx, SGPath::desktop(SGPath(&SGPath::NasalIORulesChecker))); - } - - /** --- -GitLab - diff --git a/games-simulation/flightgear/files/flightgear-2020.3.8-cmake.patch b/games-simulation/flightgear/files/flightgear-2020.3.8-cmake.patch deleted file mode 100644 index d89a0df947d82..0000000000000 --- a/games-simulation/flightgear/files/flightgear-2020.3.8-cmake.patch +++ /dev/null @@ -1,45 +0,0 @@ -diff -ruN flightgear-2020.3.8/CMakeLists.txt fgfs-my/CMakeLists.txt ---- flightgear-2020.3.8/CMakeLists.txt 2021-03-24 15:35:40.000000000 +0100 -+++ fgfs-my/CMakeLists.txt 2021-05-15 00:47:36.801503634 +0200 -@@ -373,7 +373,7 @@ - ## Qt5 setup setup - if (ENABLE_QT) - message(STATUS "Qt launcher enabled, checking for Qt >= 5.4 / qmake") -- find_package(Qt5 5.4 COMPONENTS Widgets Gui Network Qml Quick Svg) -+ find_package(Qt5 5.4 COMPONENTS Widgets Gui Network Qml Quick) - if (Qt5Widgets_FOUND AND Qt5Quick_FOUND) - message(STATUS "Will enable Qt launcher GUI") - set(HAVE_QT 1) -diff -ruN flightgear-2020.3.8/CMakeModules/SetupFGFSLibraries.cmake fgfs-my/CMakeModules/SetupFGFSLibraries.cmake ---- flightgear-2020.3.8/CMakeModules/SetupFGFSLibraries.cmake 2021-03-24 15:35:40.000000000 +0100 -+++ fgfs-my/CMakeModules/SetupFGFSLibraries.cmake 2021-05-15 00:47:36.801503634 +0200 -@@ -33,15 +33,8 @@ - - # PkgConfig::DBUS target - -- if(CMAKE_VERSION VERSION_LESS 3.6) -- if(DBUS_FOUND) -- target_link_libraries(${target} ${DBUS_LDFLAGS}) -- endif() -- else() -- # PkgConfig::DBUS target -- if(TARGET PkgConfig::DBUS) -- target_link_libraries(${target} PkgConfig::DBUS) -- endif() -+ if(DBUS_FOUND) -+ target_link_libraries(${target} ${DBUS_LDFLAGS}) - endif() - - if(FG_HAVE_GPERFTOOLS) -diff -ruN flightgear-2020.3.8/src/GUI/CMakeLists.txt fgfs-my/src/GUI/CMakeLists.txt ---- flightgear-2020.3.8/src/GUI/CMakeLists.txt 2021-03-24 15:35:40.000000000 +0100 -+++ fgfs-my/src/GUI/CMakeLists.txt 2021-05-15 00:47:36.801503634 +0200 -@@ -142,7 +142,7 @@ - - set_property(TARGET fglauncher PROPERTY AUTOMOC ON) - target_include_directories(fglauncher PRIVATE ${PROJECT_BINARY_DIR}/src/GUI) -- target_link_libraries(fglauncher Qt5::Core Qt5::Widgets Qt5::Network Qt5::Qml Qt5::Quick Qt5::Svg SimGearCore) -+ target_link_libraries(fglauncher Qt5::Core Qt5::Widgets Qt5::Network Qt5::Qml Qt5::Quick SimGearCore) - - if (ENABLE_QQ_UI) - set(QQUI_SOURCES diff --git a/games-simulation/flightgear/files/flightgear-2024.1.1-cmake.patch b/games-simulation/flightgear/files/flightgear-2024.1.1-cmake.patch new file mode 100644 index 0000000000000..0aa0f665e1ddb --- /dev/null +++ b/games-simulation/flightgear/files/flightgear-2024.1.1-cmake.patch @@ -0,0 +1,43 @@ +diff '--color=auto' -ruN flightgear-2024.1.1/CMakeLists.txt my/CMakeLists.txt +--- flightgear-2024.1.1/CMakeLists.txt 2025-02-27 15:49:31.000000000 +0100 ++++ my/CMakeLists.txt 2025-05-22 04:59:08.937714480 +0200 +@@ -368,7 +368,7 @@ + set(minQtVersion 5.12.1) + endif() + +- find_package(Qt${QT_VERSION_MAJOR} ${minQtVersion} REQUIRED COMPONENTS Widgets Gui Network Qml Quick Svg) ++ find_package(Qt${QT_VERSION_MAJOR} ${minQtVersion} REQUIRED COMPONENTS Widgets Gui Network Qml Quick) + if (NOT Qt${QT_VERSION_MAJOR}Widgets_FOUND) + message(FATAL_ERROR "Qt support enabled, Qt was found but some required packages are missing, stopping.") + endif() +diff '--color=auto' -ruN flightgear-2024.1.1/CMakeModules/Installation.cmake my/CMakeModules/Installation.cmake +--- flightgear-2024.1.1/CMakeModules/Installation.cmake 2025-02-27 15:49:31.000000000 +0100 ++++ my/CMakeModules/Installation.cmake 2025-05-22 05:25:32.200462286 +0200 +@@ -149,7 +149,7 @@ + ######################################################################################## + # AppDir creation for Linux AppImage + +-if (LINUX) ++if (LINUX AND APPIMAGE) + + install(DIRECTORY ${OSG_PLUGINS_DIR} + DESTINATION appdir/usr/lib +diff '--color=auto' -ruN flightgear-2024.1.1/src/GUI/CMakeLists.txt my/src/GUI/CMakeLists.txt +--- flightgear-2024.1.1/src/GUI/CMakeLists.txt 2025-02-27 15:49:31.000000000 +0100 ++++ my/src/GUI/CMakeLists.txt 2025-05-22 05:52:05.224936638 +0200 +@@ -182,7 +182,6 @@ + Qt${QT_VERSION_MAJOR}::Network + Qt${QT_VERSION_MAJOR}::Qml + Qt${QT_VERSION_MAJOR}::Quick +- Qt${QT_VERSION_MAJOR}::Svg + SimGearCore) + + add_library(fgqmlui +@@ -250,7 +249,6 @@ + Qt${QT_VERSION_MAJOR}::Network + Qt${QT_VERSION_MAJOR}::Qml + Qt${QT_VERSION_MAJOR}::Quick +- Qt${QT_VERSION_MAJOR}::Svg + SimGearCore) + + target_include_directories(fgqmlui PRIVATE ${PROJECT_BINARY_DIR}/src/GUI ${OPENSCENEGRAPH_INCLUDE_DIRS} ${CMAKE_CURRENT_SOURCE_DIR}) diff --git a/games-simulation/flightgear/files/flightgear-2024.1.1-fix-fgpanel.patch b/games-simulation/flightgear/files/flightgear-2024.1.1-fix-fgpanel.patch new file mode 100644 index 0000000000000..ff21afce83ce7 --- /dev/null +++ b/games-simulation/flightgear/files/flightgear-2024.1.1-fix-fgpanel.patch @@ -0,0 +1,709 @@ +diff '--color=auto' -ruN flightgear-2024.1.1/utils/fgpanel/ApplicationProperties.cxx my/utils/fgpanel/ApplicationProperties.cxx +--- flightgear-2024.1.1/utils/fgpanel/ApplicationProperties.cxx 2025-02-27 15:49:32.000000000 +0100 ++++ my/utils/fgpanel/ApplicationProperties.cxx 2025-05-22 06:30:47.453461696 +0200 +@@ -71,5 +71,5 @@ + return path; + } + +-string ApplicationProperties::root = "."; ++std::string ApplicationProperties::root = "."; + SGPropertyNode_ptr ApplicationProperties::Properties = new SGPropertyNode; +diff '--color=auto' -ruN flightgear-2024.1.1/utils/fgpanel/FGCroppedTexture.cxx my/utils/fgpanel/FGCroppedTexture.cxx +--- flightgear-2024.1.1/utils/fgpanel/FGCroppedTexture.cxx 2025-02-27 15:49:32.000000000 +0100 ++++ my/utils/fgpanel/FGCroppedTexture.cxx 2025-05-22 06:46:12.372528774 +0200 +@@ -23,11 +23,11 @@ + #include "FGCroppedTexture.hxx" + + GLuint FGCroppedTexture::s_current_bound_texture = 0; +-map FGCroppedTexture::s_cache; +-map FGCroppedTexture::s_TextureLoader; ++std::map FGCroppedTexture::s_cache; ++std::map FGCroppedTexture::s_TextureLoader; + FGDummyTextureLoader FGCroppedTexture::s_DummyTextureLoader; + +-FGCroppedTexture::FGCroppedTexture (const string &path, ++FGCroppedTexture::FGCroppedTexture (const std::string &path, + const float minX, const float minY, + const float maxX, const float maxY) : + m_path (path), +@@ -40,11 +40,11 @@ + } + + void +-FGCroppedTexture::setPath (const string &path) { ++FGCroppedTexture::setPath (const std::string &path) { + m_path = path; + } + +-const string & ++const std::string & + FGCroppedTexture::getPath () const { + return m_path; + } +@@ -55,7 +55,7 @@ + } + + void +-FGCroppedTexture::registerTextureLoader (const string &extension, ++FGCroppedTexture::registerTextureLoader (const std::string &extension, + FGTextureLoaderInterface * const loader) { + if (s_TextureLoader.count (extension) == 0) { + s_TextureLoader[extension] = loader; +@@ -100,7 +100,7 @@ + "Using texture " << m_path << " from cache (#" << m_texture << ")"); + } else { + const SGPath path (ApplicationProperties::GetRootPath (m_path.c_str ())); +- const string extension (path.extension ()); ++ const std::string extension (path.extension ()); + FGTextureLoaderInterface *loader (&s_DummyTextureLoader); + if (s_TextureLoader.count (extension) == 0) { + SG_LOG (SG_COCKPIT, +diff '--color=auto' -ruN flightgear-2024.1.1/utils/fgpanel/FGCroppedTexture.hxx my/utils/fgpanel/FGCroppedTexture.hxx +--- flightgear-2024.1.1/utils/fgpanel/FGCroppedTexture.hxx 2025-02-27 15:49:32.000000000 +0100 ++++ my/utils/fgpanel/FGCroppedTexture.hxx 2025-05-22 06:55:00.337444768 +0200 +@@ -30,19 +30,19 @@ + */ + class FGCroppedTexture : public SGReferenced { + public: +- FGCroppedTexture (const string &path, ++ FGCroppedTexture (const std::string &path, + const float minX = 0.0, const float minY = 0.0, + const float maxX = 1.0, const float maxY = 1.0); + + virtual ~FGCroppedTexture (); + +- virtual void setPath (const string &path); ++ virtual void setPath (const std::string &path); + +- virtual const string &getPath () const; ++ virtual const std::string &getPath () const; + + virtual void setCrop (const float minX, const float minY, const float maxX, const float maxY); + +- static void registerTextureLoader (const string &extension, ++ static void registerTextureLoader (const std::string &extension, + FGTextureLoaderInterface * const loader); + + virtual float getMinX () const; +@@ -54,13 +54,13 @@ + virtual void bind (const GLint Textured_Layer_Sampler_Loc); + + private: +- string m_path; ++ std::string m_path; + float m_minX, m_minY, m_maxX, m_maxY; + + GLuint m_texture; + static GLuint s_current_bound_texture; +- static map s_cache; +- static map s_TextureLoader; ++ static std::map s_cache; ++ static std::map s_TextureLoader; + static FGDummyTextureLoader s_DummyTextureLoader; + }; + +diff '--color=auto' -ruN flightgear-2024.1.1/utils/fgpanel/FGDummyTextureLoader.cxx my/utils/fgpanel/FGDummyTextureLoader.cxx +--- flightgear-2024.1.1/utils/fgpanel/FGDummyTextureLoader.cxx 2025-02-27 15:49:32.000000000 +0100 ++++ my/utils/fgpanel/FGDummyTextureLoader.cxx 2025-05-22 06:31:21.970651761 +0200 +@@ -19,7 +19,7 @@ + #include "FGDummyTextureLoader.hxx" + + GLuint +-FGDummyTextureLoader::loadTexture (const string& filename) { ++FGDummyTextureLoader::loadTexture (const std::string& filename) { + GLuint texture; + glGenTextures (1, &texture); + glBindTexture (GL_TEXTURE_2D, texture); +diff '--color=auto' -ruN flightgear-2024.1.1/utils/fgpanel/FGDummyTextureLoader.hxx my/utils/fgpanel/FGDummyTextureLoader.hxx +--- flightgear-2024.1.1/utils/fgpanel/FGDummyTextureLoader.hxx 2025-02-27 15:49:32.000000000 +0100 ++++ my/utils/fgpanel/FGDummyTextureLoader.hxx 2025-05-22 06:32:30.237016268 +0200 +@@ -18,8 +18,6 @@ + + #pragma once + +-#include +- + #include "FGTextureLoaderInterface.hxx" + + +diff '--color=auto' -ruN flightgear-2024.1.1/utils/fgpanel/FGFontCache.cxx my/utils/fgpanel/FGFontCache.cxx +--- flightgear-2024.1.1/utils/fgpanel/FGFontCache.cxx 2025-02-27 15:49:32.000000000 +0100 ++++ my/utils/fgpanel/FGFontCache.cxx 2025-05-22 06:59:46.822658662 +0200 +@@ -57,7 +57,7 @@ + } + + bool +-FGFontCache::Set_Font (const string& Font_Name, ++FGFontCache::Set_Font (const std::string& Font_Name, + const float Size, + GLuint &Glyph_Texture) { + if (m_Face_Map.find (Font_Name) != m_Face_Map.end ()) { +@@ -68,7 +68,7 @@ + SG_LOG (SG_COCKPIT, SG_ALERT, "Could not open font : " + Font_Name); + return false; + } +- m_Face_Map.insert (pair (Font_Name, Face_Ptr)); ++ m_Face_Map.insert (std::pair (Font_Name, Face_Ptr)); + m_Current_Face_Ptr = Face_Ptr; + } + if (m_Current_Face_Ptr != NULL) { +@@ -76,7 +76,7 @@ + } else { + return false; + } +- const string Key_Str (Font_Name + "_" + Get_Size (Size)); ++ const std::string Key_Str (Font_Name + "_" + Get_Size (Size)); + if (m_Pos_Map.find (Key_Str) != m_Pos_Map.end ()) { + m_Current_Pos = m_Pos_Map[Key_Str]; + } else { +@@ -117,7 +117,7 @@ + GL_ALPHA, + GL_UNSIGNED_BYTE, + m_Texture); +- m_Pos_Map.insert (pair (Key_Str, m_Current_Pos)); ++ m_Pos_Map.insert (std::pair (Key_Str, m_Current_Pos)); + } + Glyph_Texture = m_Glyph_Texture; + return true; +@@ -175,12 +175,12 @@ + Y = double (Line) / double (Texture_Size); + } + +-string ++std::string + FGFontCache::Get_Size (const float Size) { + const int Half_Size (int (round (2.0 * Size))); + const int Int_Part (Half_Size / 2); + const int Dec_Part ((Half_Size % 2) ? 5 : 0); +- stringstream Result_SS; ++ std::stringstream Result_SS; + Result_SS << Int_Part << "." << Dec_Part; + return Result_SS.str (); + } +diff '--color=auto' -ruN flightgear-2024.1.1/utils/fgpanel/FGGroupLayer.hxx my/utils/fgpanel/FGGroupLayer.hxx +--- flightgear-2024.1.1/utils/fgpanel/FGGroupLayer.hxx 2025-02-27 15:49:32.000000000 +0100 ++++ my/utils/fgpanel/FGGroupLayer.hxx 2025-05-22 06:58:50.708076810 +0200 +@@ -37,7 +37,7 @@ + // transfer pointer ownership + virtual void addLayer (FGInstrumentLayer * const layer); + protected: +- vector m_layers; ++ std::vector m_layers; + }; + + #endif +diff '--color=auto' -ruN flightgear-2024.1.1/utils/fgpanel/FGPanel.cxx my/utils/fgpanel/FGPanel.cxx +--- flightgear-2024.1.1/utils/fgpanel/FGPanel.cxx 2025-02-27 15:49:32.000000000 +0100 ++++ my/utils/fgpanel/FGPanel.cxx 2025-05-22 07:14:43.910871435 +0200 +@@ -127,7 +127,7 @@ + Textured_Layer_Program_Object = GL_utils::instance ().load_program (V_Textured_Layer_Shader_Str, + F_Textured_Layer_Shader_Str); + if (Textured_Layer_Program_Object == 0) { +- terminate (); ++ std::terminate (); + } + + // Get the attribute locations +@@ -148,7 +148,7 @@ + + // Text Layer Shaders + if (!FGTextLayer::Init ()) { +- terminate (); ++ std::terminate (); + } + + glClearColor (0.0f, 0.0f, 0.0f, 1.0f); +diff '--color=auto' -ruN flightgear-2024.1.1/utils/fgpanel/FGPanelProtocol.cxx my/utils/fgpanel/FGPanelProtocol.cxx +--- flightgear-2024.1.1/utils/fgpanel/FGPanelProtocol.cxx 2025-02-27 15:49:32.000000000 +0100 ++++ my/utils/fgpanel/FGPanelProtocol.cxx 2025-05-22 07:14:15.894624768 +0200 +@@ -88,8 +88,8 @@ + io (NULL) { + const SGPropertyNode_ptr outputNode (root->getNode ("protocol/generic/output")); + if (outputNode) { +- const vector chunks (outputNode->getChildren ("chunk")); +- for (vector::size_type i = 0; i < chunks.size (); i++) { ++ const std::vector chunks (outputNode->getChildren ("chunk")); ++ for (size_t i = 0; i < chunks.size (); i++) { + const SGPropertyNode_ptr chunk (chunks[i]); + + const SGPropertyNode_ptr nodeNode (chunk->getNode ("node", false)); +@@ -98,7 +98,7 @@ + } + const SGPropertyNode_ptr node (ApplicationProperties::Properties->getNode (nodeNode->getStringValue (), true)); + +- string type; ++ std::string type; + const SGPropertyNode_ptr typeNode (chunk->getNode ("type", false)); + if (typeNode != NULL) { + type = typeNode->getStringValue (); +@@ -144,8 +144,8 @@ + // process most recent line of data + Page ^= 1; + buf[Page][sizeof (buf[Page]) - 1] = 0; +- const vector tokens (simgear::strutils::split (buf[Page], ",")); +- for (vector::size_type i = 0; i < tokens.size (); i++) { ++ const std::vector tokens (simgear::strutils::split (buf[Page], ",")); ++ for (size_t i = 0; i < tokens.size (); i++) { + if (i < propertySetterVector.size ()) { + propertySetterVector[i]->setValue (tokens[i].c_str ()); + } +@@ -159,9 +159,9 @@ + if (listenNode == NULL) { + return; + } +- const string hostname (listenNode->getNode ("host", true)->getStringValue ()); +- const string port (listenNode->getNode ("port", true)->getStringValue ()); +- const string style (listenNode->getNode ("style", true)->getStringValue ()); ++ const std::string hostname (listenNode->getNode ("host", true)->getStringValue ()); ++ const std::string port (listenNode->getNode ("port", true)->getStringValue ()); ++ const std::string style (listenNode->getNode ("style", true)->getStringValue ()); + + if (io != NULL) { + delete io; +@@ -169,7 +169,7 @@ + io = new SGSocket (hostname, port, style); + + if (!io->open (SG_IO_IN)) { +- cerr << "can't open socket " << style << ":" << hostname << ":" << port << endl; ++ std::cerr << "can't open socket " << style << ":" << hostname << ":" << port << std::endl; + } + } + +diff '--color=auto' -ruN flightgear-2024.1.1/utils/fgpanel/FGPNGTextureLoader.cxx my/utils/fgpanel/FGPNGTextureLoader.cxx +--- flightgear-2024.1.1/utils/fgpanel/FGPNGTextureLoader.cxx 2025-02-27 15:49:32.000000000 +0100 ++++ my/utils/fgpanel/FGPNGTextureLoader.cxx 2025-05-22 07:10:38.485216103 +0200 +@@ -42,7 +42,7 @@ + using namespace std; + + GLuint +-FGPNGTextureLoader::loadTexture (const string &filename) { ++FGPNGTextureLoader::loadTexture (const std::string &filename) { + //header for testing if it is a png + png_byte header[8]; + +diff '--color=auto' -ruN flightgear-2024.1.1/utils/fgpanel/FGPNGTextureLoader.hxx my/utils/fgpanel/FGPNGTextureLoader.hxx +--- flightgear-2024.1.1/utils/fgpanel/FGPNGTextureLoader.hxx 2025-02-27 15:49:32.000000000 +0100 ++++ my/utils/fgpanel/FGPNGTextureLoader.hxx 2025-05-22 07:10:11.651891427 +0200 +@@ -20,7 +20,7 @@ + + class FGPNGTextureLoader : public FGTextureLoaderInterface { + public: +- virtual GLuint loadTexture (const string &filename); ++ virtual GLuint loadTexture (const std::string &filename); + + const static GLuint NOTEXTURE = 0; + }; +diff '--color=auto' -ruN flightgear-2024.1.1/utils/fgpanel/FGRGBTextureLoader.cxx my/utils/fgpanel/FGRGBTextureLoader.cxx +--- flightgear-2024.1.1/utils/fgpanel/FGRGBTextureLoader.cxx 2025-02-27 15:49:32.000000000 +0100 ++++ my/utils/fgpanel/FGRGBTextureLoader.cxx 2025-05-22 07:13:33.966248033 +0200 +@@ -52,7 +52,7 @@ + unsigned long wasteBytes; + char name[80]; + unsigned long colorMap; +- istream *file; ++ std::istream *file; + unsigned char *tmp, *tmpR, *tmpG, *tmpB, *tmpA; + unsigned long rleEnd; + GLuint *rowStart; +@@ -156,7 +156,7 @@ + } + + static rawImageRec * +-RawImageOpen (istream& fin) { ++RawImageOpen (std::istream& fin) { + union { + int testWord; + char testByte[4]; +@@ -242,7 +242,7 @@ + } + int x (ybyz * sizeof (GLuint)); + raw->rleEnd = 512 + (2 * x); +- fin.seekg (512, ios::beg); ++ fin.seekg (512, std::ios::beg); + fin.read ((char*) raw->rowStart, x); + fin.read ((char*) raw->rowSize, x); + if (raw->swapFlag) { +@@ -260,7 +260,7 @@ + unsigned short *tempShort; + + if ((raw->type & 0xFF00) == 0x0100) { +- raw->file->seekg (long (raw->rowStart[y + z * raw->sizeY]), ios::beg); ++ raw->file->seekg (long (raw->rowStart[y + z * raw->sizeY]), std::ios::beg); + raw->file->read ((char*) raw->tmp, (unsigned int) (raw->rowSize[y + z * raw->sizeY])); + + unsigned char *iPtr = raw->tmp; +@@ -333,7 +333,7 @@ + } + } + } else { +- raw->file->seekg (512 + (y * raw->sizeX * raw->bpc) + (z * raw->sizeX * raw->sizeY * raw->bpc), ios::beg); ++ raw->file->seekg (512 + (y * raw->sizeX * raw->bpc) + (z * raw->sizeX * raw->sizeY * raw->bpc), std::ios::beg); + raw->file->read ((char*) buf, raw->sizeX * raw->bpc); + if (raw->swapFlag && raw->bpc != 1) { + ConvertShort (reinterpret_cast (buf), raw->sizeX); +@@ -427,7 +427,7 @@ + // supportsExtension("bw","bw image format"); + + GLuint +-readRGBStream (istream &fin) { ++readRGBStream (std::istream &fin) { + rawImageRec * const raw (RawImageOpen (fin)); + + if (raw == NULL) { +@@ -468,9 +468,9 @@ + } + + GLuint +-FGRGBTextureLoader::loadTexture (const string &filename) { ++FGRGBTextureLoader::loadTexture (const std::string &filename) { + GLuint texture = NOTEXTURE; +- ifstream istream (filename.c_str (), ios::in | ios::binary); ++ std::ifstream istream (filename.c_str (), std::ios::in | std::ios::binary); + texture = readRGBStream (istream); + istream.close (); + return texture; +diff '--color=auto' -ruN flightgear-2024.1.1/utils/fgpanel/FGRGBTextureLoader.hxx my/utils/fgpanel/FGRGBTextureLoader.hxx +--- flightgear-2024.1.1/utils/fgpanel/FGRGBTextureLoader.hxx 2025-02-27 15:49:32.000000000 +0100 ++++ my/utils/fgpanel/FGRGBTextureLoader.hxx 2025-05-22 07:05:22.209920047 +0200 +@@ -20,7 +20,7 @@ + + class FGRGBTextureLoader : public FGTextureLoaderInterface { + public: +- virtual GLuint loadTexture (const string &filename); ++ virtual GLuint loadTexture (const std::string &filename); + + const static GLuint NOTEXTURE = 0; + }; +diff '--color=auto' -ruN flightgear-2024.1.1/utils/fgpanel/FGTextLayer.cxx my/utils/fgpanel/FGTextLayer.cxx +--- flightgear-2024.1.1/utils/fgpanel/FGTextLayer.cxx 2025-02-27 15:49:32.000000000 +0100 ++++ my/utils/fgpanel/FGTextLayer.cxx 2025-05-22 07:19:55.218845401 +0200 +@@ -156,7 +156,7 @@ + int Left, Bottom, W, H; + double X1, Y1, X2, Y2; + +- for (string::iterator It = m_value.begin (); It != m_value.end (); ++It) { ++ for (std::string::iterator It = m_value.begin (); It != m_value.end (); ++It) { + if (The_Font_Cache.Get_Char (*It, + X, Y, + Left, Bottom, +@@ -221,7 +221,7 @@ + } + + void +-FGTextLayer::setFontName (const string &name) { ++FGTextLayer::setFontName (const std::string &name) { + if (The_Font_Path.isNull ()) { + char *Env_Path = ::getenv ("FG_FONTS"); + if (Env_Path != NULL) { +@@ -247,8 +247,8 @@ + // Implementation of FGTextLayer::Chunk. + //////////////////////////////////////////////////////////////////////// + +-FGTextLayer::Chunk::Chunk (const string &text, +- const string &fmt) : ++FGTextLayer::Chunk::Chunk (const std::string &text, ++ const std::string &fmt) : + m_type (FGTextLayer::TEXT), + m_text (text), + m_fmt (fmt), +@@ -262,7 +262,7 @@ + + FGTextLayer::Chunk::Chunk (const ChunkType type, + const SGPropertyNode *node, +- const string &fmt, ++ const std::string &fmt, + const float mult, + const float offs, + const bool truncation) : +diff '--color=auto' -ruN flightgear-2024.1.1/utils/fgpanel/GL_utils.cxx my/utils/fgpanel/GL_utils.cxx +--- flightgear-2024.1.1/utils/fgpanel/GL_utils.cxx 2025-02-27 15:49:32.000000000 +0100 ++++ my/utils/fgpanel/GL_utils.cxx 2025-05-22 07:18:54.467677071 +0200 +@@ -57,7 +57,7 @@ + GLuint shader (glCreateShader (type)); + + if (shader == 0) { +- cerr << "Error creating shader" << endl; ++ std::cerr << "Error creating shader" << std::endl; + return 0; + } + +@@ -79,7 +79,7 @@ + char* info_log ((char *) malloc (sizeof (char) * info_len)); + + glGetShaderInfoLog (shader, info_len, NULL, info_log); +- cerr << "Error compiling shader:" << endl << info_log << endl; ++ std::cerr << "Error compiling shader:" << std::endl << info_log << std::endl; + + free (info_log); + } +@@ -106,13 +106,13 @@ + // Load the vertex/fragment shaders + GLuint vertex_shader (load_shader (GL_VERTEX_SHADER, vert_shader_src)); + if (vertex_shader == 0) { +- cerr << "Error loading vertex shader" << endl; ++ std::cerr << "Error loading vertex shader" << std::endl; + return 0; + } + + GLuint fragment_shader (load_shader (GL_FRAGMENT_SHADER, frag_shader_src)); + if (fragment_shader == 0) { +- cerr << "Error loading fragment shader" << endl; ++ std::cerr << "Error loading fragment shader" << std::endl; + glDeleteShader (vertex_shader); + return 0; + } +@@ -121,7 +121,7 @@ + GLuint program_object (glCreateProgram ()); + + if (program_object == 0) { +- cerr << "Error creating program" << endl; ++ std::cerr << "Error creating program" << std::endl; + return 0; + } + +@@ -143,7 +143,7 @@ + char* info_log ((char *) malloc (sizeof (char) * info_len)); + + glGetProgramInfoLog (program_object, info_len, NULL, info_log); +- cerr << "Error linking program:" << endl << info_log << endl; ++ std::cerr << "Error linking program:" << std::endl << info_log << std::endl; + + free (info_log); + } +@@ -364,11 +364,11 @@ + GL_utils::Debug (const GL_utils::GLenum_Mode mode) const { + if (mode < GL_UTILS_LAST) { + for (int l = 0; l < 4; ++l) { +- cout << " "; ++ std::cout << " "; + for (int c = 0; c < 4; ++c) { +- cout << m_Matrix[mode].top ().m[c][l] << " "; ++ std::cout << m_Matrix[mode].top ().m[c][l] << " "; + } +- cout << endl; ++ std::cout << std::endl; + } + } + } +diff '--color=auto' -ruN flightgear-2024.1.1/utils/fgpanel/main.cxx my/utils/fgpanel/main.cxx +--- flightgear-2024.1.1/utils/fgpanel/main.cxx 2025-02-27 15:49:32.000000000 +0100 ++++ my/utils/fgpanel/main.cxx 2025-05-22 06:55:23.033614787 +0200 +@@ -25,6 +25,6 @@ + return 0; + } + catch (...) { +- cerr << "Sorry, your program terminated." << endl; ++ std::cerr << "Sorry, your program terminated." << std::endl; + } + } +diff '--color=auto' -ruN flightgear-2024.1.1/utils/fgpanel/panel_io.cxx my/utils/fgpanel/panel_io.cxx +--- flightgear-2024.1.1/utils/fgpanel/panel_io.cxx 2025-02-27 15:49:32.000000000 +0100 ++++ my/utils/fgpanel/panel_io.cxx 2025-05-22 07:43:05.623983755 +0200 +@@ -26,8 +26,6 @@ + #include + #endif + +-#include // for strcmp() +- + #include + #include + #include +@@ -101,7 +99,7 @@ + */ + static FGCroppedTexture_ptr + readTexture (const SGPropertyNode *node) { +- SG_LOG(SG_COCKPIT, SG_DEBUG, "Read texture " << node->getName ()); ++ SG_LOG(SG_COCKPIT, SG_DEBUG, "Read texture " << node->getNameString ()); + + return new FGCroppedTexture (node->getStringValue ("path"), + node->getFloatValue ("x1"), +@@ -158,9 +156,9 @@ + readTransformation (const SGPropertyNode *node, const float w_scale, const float h_scale) { + FGPanelTransformation *t (new FGPanelTransformation); + +- const string name (node->getName ()); +- string type (node->getStringValue ("type")); +- const string propName (node->getStringValue ("property", "")); ++ const std::string name (node->getNameString ()); ++ std::string type (node->getStringValue ("type")); ++ const std::string propName (node->getStringValue ("property", "")); + const SGPropertyNode *target (0); + + if (type.empty ()) { +@@ -191,14 +189,14 @@ + t->table = new SGInterpTable(); + for (int i = 0; i < trans_table->nChildren(); i++) { + const SGPropertyNode * node = trans_table->getChild(i); +- if (!strcmp(node->getName(), "entry")) { ++ if (node->getNameString () == "entry") { + double ind = node->getDoubleValue("ind", 0.0); + double dep = node->getDoubleValue("dep", 0.0); + SG_LOG(SG_COCKPIT, SG_INFO, "Adding interpolation entry " + << ind << "==>" << dep); + t->table->addEntry(ind, dep); + } else { +- SG_LOG(SG_COCKPIT, SG_INFO, "Skipping " << node->getName() ++ SG_LOG(SG_COCKPIT, SG_INFO, "Skipping " << node->getNameString () + << " in interpolation"); + } + } +@@ -262,9 +260,9 @@ + FGTextLayer::Chunk * + readTextChunk (const SGPropertyNode *node) { + FGTextLayer::Chunk *chunk; +- const string name (node->getStringValue ("name")); +- string type (node->getStringValue ("type")); +- const string format (node->getStringValue ("format")); ++ const std::string name (node->getStringValue ("name")); ++ std::string type (node->getStringValue ("type")); ++ const std::string format (node->getStringValue ("format")); + + // Default to literal text. + if (type.empty ()) { +@@ -275,7 +273,7 @@ + + // A literal text string. + if (type == "literal") { +- const string text (node->getStringValue ("text")); ++ const std::string text (node->getStringValue ("text")); + chunk = new FGTextLayer::Chunk (text, format); + } else if (type == "text-value") { + // The value of a string property. +@@ -284,7 +282,7 @@ + chunk = new FGTextLayer::Chunk (FGTextLayer::TEXT_VALUE, target, format); + } else if (type == "number-value") { + // The value of a float property. +- const string propName (node->getStringValue ("property")); ++ const std::string propName (node->getStringValue ("property")); + const float scale (node->getFloatValue ("scale", 1.0)); + const float offset (node->getFloatValue ("offset", 0.0)); + const bool truncation (node->getBoolValue ("truncate", false)); +@@ -326,8 +324,8 @@ + static FGInstrumentLayer * + readLayer (const SGPropertyNode *node, const float w_scale, const float h_scale) { + FGInstrumentLayer *layer (NULL); +- const string name (node->getStringValue ("name")); +- string type (node->getStringValue ("type")); ++ const std::string name (node->getStringValue ("name")); ++ std::string type (node->getStringValue ("type")); + int w (node->getIntValue ("w", -1)); + int h (node->getIntValue ("h", -1)); + const bool emissive (node->getBoolValue ("emissive", false)); +@@ -357,7 +355,7 @@ + layer = new FGGroupLayer (); + for (int i = 0; i < node->nChildren(); i++) { + const SGPropertyNode *child = node->getChild (i); +- if (!strcmp (child->getName (), "layer")) { ++ if (child->getNameString () == "layer") { + ((FGGroupLayer *) layer)->addLayer (readLayer (child, w_scale, h_scale)); + } + } +@@ -376,7 +374,7 @@ + tlayer->setPointSize (pointSize); + + // Set the font. +- const string fontName (node->getStringValue ("font", "7-Segment")); ++ const std::string fontName (node->getStringValue ("font", "7-Segment")); + tlayer->setFontName (fontName); + + const SGPropertyNode *chunk_group (node->getNode ("chunks")); +@@ -384,13 +382,13 @@ + const int nChunks (chunk_group->nChildren ()); + for (int i = 0; i < nChunks; i++) { + const SGPropertyNode *node (chunk_group->getChild (i)); +- if (!strcmp(node->getName (), "chunk")) { ++ if (node->getNameString () == "chunk") { + FGTextLayer::Chunk * const chunk (readTextChunk (node)); + if (chunk != 0) { + tlayer->addChunk (chunk); + } + } else { +- SG_LOG(SG_COCKPIT, SG_INFO, "Skipping " << node->getName() ++ SG_LOG(SG_COCKPIT, SG_INFO, "Skipping " << node->getNameString () + << " in chunks"); + } + } +@@ -401,7 +399,7 @@ + layer = new FGSwitchLayer (); + for (int i = 0; i < node->nChildren (); i++) { + const SGPropertyNode *child (node->getChild (i)); +- if (!strcmp (child->getName (), "layer")) { ++ if (child->getNameString () == "layer") { + ((FGGroupLayer *) layer)->addLayer (readLayer (child, w_scale, h_scale)); + } + } +@@ -420,13 +418,13 @@ + const int nTransformations (trans_group->nChildren ()); + for (int i = 0; i < nTransformations; i++) { + const SGPropertyNode *node (trans_group->getChild (i)); +- if (!strcmp(node->getName (), "transformation")) { ++ if (node->getNameString () == "transformation") { + FGPanelTransformation * const t (readTransformation (node, w_scale, h_scale)); + if (t != 0) { + layer->addTransformation (t); + } + } else { +- SG_LOG(SG_COCKPIT, SG_INFO, "Skipping " << node->getName() ++ SG_LOG(SG_COCKPIT, SG_INFO, "Skipping " << node->getNameString () + << " in transformations"); + } + } +@@ -450,7 +448,7 @@ + */ + static FGPanelInstrument * + readInstrument (const SGPropertyNode *node) { +- const string name (node->getStringValue ("name")); ++ const std::string name (node->getStringValue ("name")); + const int x (node->getIntValue ("x", -1)); + const int y (node->getIntValue ("y", -1)); + const int real_w (node->getIntValue ("w", -1)); +@@ -488,13 +486,13 @@ + const int nLayers (layer_group->nChildren ()); + for (int i = 0; i < nLayers; i++) { + const SGPropertyNode *node (layer_group->getChild (i)); +- if (!strcmp (node->getName (), "layer")) { ++ if (node->getNameString () == "layer") { + FGInstrumentLayer * const layer (readLayer (node, w_scale, h_scale)); + if (layer != 0) { + instrument->addLayer (layer); + } + } else { +- SG_LOG(SG_COCKPIT, SG_INFO, "Skipping " << node->getName () ++ SG_LOG(SG_COCKPIT, SG_INFO, "Skipping " << node->getNameString () + << " in layers"); + } + } +@@ -521,7 +519,7 @@ + + // Assign the background texture, if any, or a bogus chequerboard. + // +- const string bgTexture (root->getStringValue ("background")); ++ const std::string bgTexture (root->getStringValue ("background")); + if (!bgTexture.empty ()) { + panel->setBackground (new FGCroppedTexture (bgTexture)); + } +@@ -534,7 +532,7 @@ + // + for (int i = 0; i < 8; i++) { + SGPropertyNode * const mbgNode (root->getChild ("multibackground", i)); +- string mbgTexture; ++ std::string mbgTexture; + if (mbgNode != NULL) { + mbgTexture = mbgNode->getStringValue (); + } +@@ -557,13 +555,13 @@ + const int nInstruments (instrument_group->nChildren ()); + for (int i = 0; i < nInstruments; i++) { + const SGPropertyNode *node = instrument_group->getChild (i); +- if (!strcmp (node->getName (), "instrument")) { ++ if (node->getNameString () == "instrument") { + FGPanelInstrument * const instrument (readInstrument (node)); + if (instrument != 0) { + panel->addInstrument (instrument); + } + } else { +- SG_LOG(SG_COCKPIT, SG_INFO, "Skipping " << node->getName() ++ SG_LOG(SG_COCKPIT, SG_INFO, "Skipping " << node->getNameString () + << " in instruments section"); + } + } diff --git a/games-simulation/flightgear/flightgear-2020.3.19-r1.ebuild b/games-simulation/flightgear/flightgear-2024.1.1.ebuild similarity index 78% rename from games-simulation/flightgear/flightgear-2020.3.19-r1.ebuild rename to games-simulation/flightgear/flightgear-2024.1.1.ebuild index a9721bf5e6c43..c6b686ffb695e 100644 --- a/games-simulation/flightgear/flightgear-2020.3.19-r1.ebuild +++ b/games-simulation/flightgear/flightgear-2024.1.1.ebuild @@ -1,27 +1,28 @@ # Copyright 1999-2025 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 -EAPI=7 +EAPI=8 -inherit cmake flag-o-matic toolchain-funcs +inherit cmake flag-o-matic DESCRIPTION="Open Source Flight Simulator" HOMEPAGE="https://www.flightgear.org/" -SRC_URI="https://downloads.sourceforge.net/flightgear/${P}.tar.bz2" +SRC_URI="https://gitlab.com/flightgear/fgmeta/-/jobs/9264813015/artifacts/raw/fgbuild/${P}.tar.bz2" LICENSE="GPL-2" -KEYWORDS="~amd64 ~x86" SLOT="0" -IUSE="cpu_flags_x86_sse2 dbus debug examples gdal openmp qt5 +udev +utils" +KEYWORDS="~amd64 ~x86" +IUSE="cpu_flags_x86_sse2 dbus debug examples gdal qt6 +udev +utils" # Needs --fg-root with path to flightgear-data passed to test runner passed, # not really worth patching RESTRICT="test" # zlib is some strange auto-dep from simgear +# TODO add osgXR COMMON_DEPEND=" dev-db/sqlite:3 - dev-games/openscenegraph[jpeg,png] + >=dev-games/openscenegraph-3.6.0[jpeg,png] ~dev-games/simgear-${PV}[gdal=] media-libs/openal >=media-libs/plib-1.8.5 @@ -33,12 +34,9 @@ COMMON_DEPEND=" x11-libs/libX11 dbus? ( >=sys-apps/dbus-1.6.18-r1 ) gdal? ( >=sci-libs/gdal-2.0.0:= ) - qt5? ( - >=dev-qt/qtcore-5.7.1:5 - >=dev-qt/qtdeclarative-5.7.1:5 - >=dev-qt/qtgui-5.7.1:5 - >=dev-qt/qtnetwork-5.7.1:5 - >=dev-qt/qtwidgets-5.7.1:5 + qt6? ( + dev-qt/qtbase:6[gui,network,widgets] + dev-qt/qtdeclarative:6 ) udev? ( virtual/udev ) utils? ( @@ -47,7 +45,7 @@ COMMON_DEPEND=" media-libs/glew:0 media-libs/libpng:0 virtual/opengl - qt5? ( >=dev-qt/qtwebsockets-5.7.1:5 ) + qt6? ( dev-qt/qtwebsockets:6 ) ) " # libXi and libXmu are build-only-deps according to FindGLUT.cmake @@ -62,23 +60,19 @@ DEPEND="${COMMON_DEPEND} RDEPEND="${COMMON_DEPEND} ~games-simulation/${PN}-data-${PV} " -BDEPEND="qt5? ( >=dev-qt/linguist-tools-5.7.1:5 )" +BDEPEND="qt6? ( dev-qt/qttools:6 )" PATCHES=( - "${FILESDIR}/${PN}-2020.3.8-cmake.patch" - "${FILESDIR}/${PN}-2020.3.19-CVE-2025-0781.patch" + "${FILESDIR}/${PN}-2024.1.1-cmake.patch" + "${FILESDIR}/${PN}-2024.1.1-fix-fgpanel.patch" + "${FILESDIR}/0001-check-to-be-sure-that-n-is-not-being-set-as-format-t.patch" + "${FILESDIR}/0003-make-fglauncher-a-static-library.patch" + "${FILESDIR}/0005-make-fgqmlui-a-static-library.patch" + "${FILESDIR}/0006-fgviewer-fix-crash-on-exit.patch" ) DOCS=(AUTHORS ChangeLog NEWS README Thanks) -pkg_pretend() { - [[ ${MERGE_TYPE} != binary ]] && use openmp && tc-check-openmp -} - -pkg_setup() { - [[ ${MERGE_TYPE} != binary ]] && use openmp && tc-check-openmp -} - src_configure() { # -Werror=lto-type-mismatch, -Werror=odr # https://bugs.gentoo.org/859217 @@ -87,8 +81,9 @@ src_configure() { local mycmakeargs=( -DBUILD_SHARED_LIBS=OFF + -DCHECK_FOR_QT5=OFF + -DCHECK_FOR_QT6=ON -DENABLE_AUTOTESTING=OFF - -DENABLE_COMPOSITOR=OFF -DENABLE_FGCOM=$(usex utils) -DENABLE_FGELEV=$(usex utils) -DENABLE_FGJS=$(usex utils) @@ -101,17 +96,18 @@ src_configure() { -DENABLE_JSBSIM=ON -DENABLE_LARCSIM=ON -DENABLE_METAR=$(usex utils) - -DENABLE_OPENMP=$(usex openmp) -DENABLE_PLIB_JOYSTICK=ON # NOTE look for defaults changes in CMake - -DENABLE_PROFILE=OFF - -DENABLE_QT=$(usex qt5) + -DENABLE_QT=$(usex qt6) -DENABLE_RTI=OFF + -DENABLE_SENTRY=OFF # sentry-native masked + -DENABLE_HUD=ON + -DENABLE_PUI=ON -DENABLE_SIMD=$(usex cpu_flags_x86_sse2) -DENABLE_STGMERGE=ON -DENABLE_SWIFT=OFF # swift pilot client not packaged yet - -DENABLE_TERRASYNC=$(usex utils) -DENABLE_TRAFFIC=$(usex utils) -DENABLE_UIUC_MODEL=ON + -DENABLE_VR=OFF -DENABLE_YASIM=ON -DEVENT_INPUT=$(usex udev) -DFG_BUILD_TYPE=Release @@ -125,6 +121,7 @@ src_configure() { -DSYSTEM_SPEEX=ON -DSYSTEM_GSM=ON -DSYSTEM_SQLITE=ON + -DSYSTEM_OSGXR=ON -DUSE_AEONWAVE=OFF -DUSE_DBUS=$(usex dbus) -DWITH_FGPANEL=$(usex utils) @@ -134,7 +131,7 @@ src_configure() { else mycmakeargs+=(-DENABLE_DEMCONVERT=OFF) fi - if use qt5 && use utils; then + if use qt6 && use utils; then mycmakeargs+=(-DENABLE_FGQCANVAS=ON) else mycmakeargs+=(-DENABLE_FGQCANVAS=OFF) @@ -171,7 +168,7 @@ src_install() { } pkg_postinst() { - if use qt5; then + if use qt6; then einfo "To use launcher, run fgfs with '--launcher' parameter" fi } diff --git a/games-simulation/flightgear/flightgear-9999.ebuild b/games-simulation/flightgear/flightgear-9999.ebuild index 720c1042bbd6c..784fced7bb9fc 100644 --- a/games-simulation/flightgear/flightgear-9999.ebuild +++ b/games-simulation/flightgear/flightgear-9999.ebuild @@ -1,28 +1,29 @@ -# Copyright 1999-2024 Gentoo Authors +# Copyright 1999-2025 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 -EAPI=7 +EAPI=8 -inherit cmake flag-o-matic toolchain-funcs git-r3 +inherit cmake flag-o-matic git-r3 DESCRIPTION="Open Source Flight Simulator" HOMEPAGE="https://www.flightgear.org/" -EGIT_REPO_URI="https://git.code.sf.net/p/${PN}/${PN}" +EGIT_REPO_URI="https://gitlab.com/flightgear/${PN}.git" EGIT_BRANCH="next" LICENSE="GPL-2" -KEYWORDS="" SLOT="0" -IUSE="cpu_flags_x86_sse2 dbus debug examples gdal openmp qt5 +udev +utils" +KEYWORDS="" +IUSE="cpu_flags_x86_sse2 dbus debug examples gdal qt6 +udev +utils" # Needs --fg-root with path to flightgear-data passed to test runner passed, # not really worth patching RESTRICT="test" # zlib is some strange auto-dep from simgear +# TODO add osgXR COMMON_DEPEND=" dev-db/sqlite:3 - dev-games/openscenegraph[jpeg,png] + >=dev-games/openscenegraph-3.6.0[jpeg,png] ~dev-games/simgear-${PV}[gdal=] media-libs/openal >=media-libs/plib-1.8.5 @@ -34,12 +35,9 @@ COMMON_DEPEND=" x11-libs/libX11 dbus? ( >=sys-apps/dbus-1.6.18-r1 ) gdal? ( >=sci-libs/gdal-2.0.0:= ) - qt5? ( - >=dev-qt/qtcore-5.7.1:5 - >=dev-qt/qtdeclarative-5.7.1:5 - >=dev-qt/qtgui-5.7.1:5 - >=dev-qt/qtnetwork-5.7.1:5 - >=dev-qt/qtwidgets-5.7.1:5 + qt6? ( + dev-qt/qtbase:6[gui,network,widgets] + dev-qt/qtdeclarative:6 ) udev? ( virtual/udev ) utils? ( @@ -48,7 +46,7 @@ COMMON_DEPEND=" media-libs/glew:0 media-libs/libpng:0 virtual/opengl - qt5? ( >=dev-qt/qtwebsockets-5.7.1:5 ) + qt6? ( dev-qt/qtwebsockets:6 ) ) " # libXi and libXmu are build-only-deps according to FindGLUT.cmake @@ -63,22 +61,15 @@ DEPEND="${COMMON_DEPEND} RDEPEND="${COMMON_DEPEND} ~games-simulation/${PN}-data-${PV} " -BDEPEND="qt5? ( >=dev-qt/linguist-tools-5.7.1:5 )" +BDEPEND="qt6? ( dev-qt/qttools:6 )" PATCHES=( - "${FILESDIR}/${PN}-2020.3.5-cmake.patch" + "${FILESDIR}/${PN}-2024.1.1-cmake.patch" + "${FILESDIR}/${PN}-2024.1.1-fix-fgpanel.patch" ) DOCS=(AUTHORS ChangeLog NEWS README Thanks) -pkg_pretend() { - [[ ${MERGE_TYPE} != binary ]] && use openmp && tc-check-openmp -} - -pkg_setup() { - [[ ${MERGE_TYPE} != binary ]] && use openmp && tc-check-openmp -} - src_configure() { # -Werror=lto-type-mismatch, -Werror=odr # https://bugs.gentoo.org/859217 @@ -87,8 +78,9 @@ src_configure() { local mycmakeargs=( -DBUILD_SHARED_LIBS=OFF + -DCHECK_FOR_QT5=OFF + -DCHECK_FOR_QT6=ON -DENABLE_AUTOTESTING=OFF - -DENABLE_COMPOSITOR=OFF -DENABLE_FGCOM=$(usex utils) -DENABLE_FGELEV=$(usex utils) -DENABLE_FGJS=$(usex utils) @@ -101,17 +93,18 @@ src_configure() { -DENABLE_JSBSIM=ON -DENABLE_LARCSIM=ON -DENABLE_METAR=$(usex utils) - -DENABLE_OPENMP=$(usex openmp) -DENABLE_PLIB_JOYSTICK=ON # NOTE look for defaults changes in CMake - -DENABLE_PROFILE=OFF - -DENABLE_QT=$(usex qt5) + -DENABLE_QT=$(usex qt6) -DENABLE_RTI=OFF + -DENABLE_SENTRY=OFF # sentry-native masked + -DENABLE_HUD=ON + -DENABLE_PUI=ON -DENABLE_SIMD=$(usex cpu_flags_x86_sse2) -DENABLE_STGMERGE=ON -DENABLE_SWIFT=OFF # swift pilot client not packaged yet - -DENABLE_TERRASYNC=$(usex utils) -DENABLE_TRAFFIC=$(usex utils) -DENABLE_UIUC_MODEL=ON + -DENABLE_VR=OFF -DENABLE_YASIM=ON -DEVENT_INPUT=$(usex udev) -DFG_BUILD_TYPE=Nightly @@ -125,6 +118,7 @@ src_configure() { -DSYSTEM_SPEEX=ON -DSYSTEM_GSM=ON -DSYSTEM_SQLITE=ON + -DSYSTEM_OSGXR=ON -DUSE_AEONWAVE=OFF -DUSE_DBUS=$(usex dbus) -DWITH_FGPANEL=$(usex utils) @@ -134,7 +128,7 @@ src_configure() { else mycmakeargs+=(-DENABLE_DEMCONVERT=OFF) fi - if use qt5 && use utils; then + if use qt6 && use utils; then mycmakeargs+=(-DENABLE_FGQCANVAS=ON) else mycmakeargs+=(-DENABLE_FGQCANVAS=OFF) @@ -171,8 +165,7 @@ src_install() { } pkg_postinst() { - einfo "Please note that data files location changed to /usr/share/flightgear" - if use qt5; then + if use qt6; then einfo "To use launcher, run fgfs with '--launcher' parameter" fi } diff --git a/games-simulation/flightgear/metadata.xml b/games-simulation/flightgear/metadata.xml index 7990d62117083..6cf62990e859f 100644 --- a/games-simulation/flightgear/metadata.xml +++ b/games-simulation/flightgear/metadata.xml @@ -12,11 +12,11 @@ Enable screensaver DBus interaction Enable alternative terrain engine based on pagedLOD using sci-libs/gdal - Build Qt5 launcher application + Build Qt6 launcher application Enable event-based Input devices through virtual/udev Build various utilities (fgpanel, fgviewer among others) - flightgear + flightgear/flightgear diff --git a/profiles/base/package.use.force b/profiles/base/package.use.force index c011518660468..12a79b6047237 100644 --- a/profiles/base/package.use.force +++ b/profiles/base/package.use.force @@ -321,10 +321,6 @@ net-fs/autofs libtirpc net-misc/netkit-bootparamd libtirpc sys-cluster/glusterfs libtirpc -# Maciej Mrozowski (2016-09-01) -# Workaround until resolved upstream (bug #586840) ->=dev-games/simgear-2016.2.1 dns - # Justin Lecher (2014-08-10) # Doesn't work without acl support # No patch yet, #516626 diff --git a/profiles/base/package.use.mask b/profiles/base/package.use.mask index 0ace8980d5521..a354d961dbd91 100644 --- a/profiles/base/package.use.mask +++ b/profiles/base/package.use.mask @@ -6,6 +6,11 @@ # New entries go on top. +# Maciej Mrozowski (2025-05-22) +# Does not compile as of 2024.1.1, requires buildsystem fixes. +dev-games/simgear gdal +games-simulation/flightgear gdal + # Andreas Sturmlechner (2025-05-14) # dev-qt/qtwebchannel:5 is masked, last revdep was dev-python/pyqtwebengine dev-python/pyqt5 webchannel