diff options
| author | root <root@alpha.trunkmasters.com> | 2026-06-04 16:47:34 -0500 |
|---|---|---|
| committer | root <root@alpha.trunkmasters.com> | 2026-06-04 16:47:34 -0500 |
| commit | dda948891d3731927b821ce31f9d9a2d03ba20c5 (patch) | |
| tree | 99cd40be4cbb0606260da212cd81b8ab2db9da9b /games-simulation | |
| parent | a3ceca1b4c0d9bdb550dc23f06ffbb5a8e033bc7 (diff) | |
| download | baldeagleos-repo-dda948891d3731927b821ce31f9d9a2d03ba20c5.tar.gz baldeagleos-repo-dda948891d3731927b821ce31f9d9a2d03ba20c5.tar.xz baldeagleos-repo-dda948891d3731927b821ce31f9d9a2d03ba20c5.zip | |
Adding metadata
Diffstat (limited to 'games-simulation')
113 files changed, 4241 insertions, 0 deletions
diff --git a/games-simulation/EmptyEpsilon/EmptyEpsilon-2022.10.28.ebuild b/games-simulation/EmptyEpsilon/EmptyEpsilon-2022.10.28.ebuild new file mode 100644 index 000000000000..1f1c5dd24e42 --- /dev/null +++ b/games-simulation/EmptyEpsilon/EmptyEpsilon-2022.10.28.ebuild @@ -0,0 +1,88 @@ +# Copyright 1999-2025 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +inherit cmake + +# basis_universal version +MY_BU_VER="1_15_update2" +# meshoptimizer version +MY_MO_VER="0.16" + +DESCRIPTION="A spaceship bridge simulator game" +HOMEPAGE="https://daid.github.io/EmptyEpsilon/" +# This bundles SeriousProton as the build system does not support using +# a separate SeriousProton instance (and currently EmptyEpsilon seems to +# be the only consumer). +SRC_URI=" + https://github.com/daid/${PN}/archive/EE-${PV}.tar.gz -> ${PN}-${PV}.tar.gz + https://github.com/daid/SeriousProton/archive/EE-${PV}.tar.gz -> SeriousProton-${PV}.tar.gz + https://github.com/BinomialLLC/basis_universal/archive/refs/tags/v${MY_BU_VER}.tar.gz -> basis_universal_${MY_BU_VER}.tar.gz + https://github.com/zeux/meshoptimizer/archive/refs/tags/v${MY_MO_VER}.tar.gz -> meshoptimizer-${MY_MO_VER}.tar.gz + https://github.com/Flowdalic/SeriousProton/commit/dc9dccf6c802b9c55ac4eccad424d2b1af9f4b93.patch -> + SeriousProton-2022.10.28-add-missing-cstdint-include.patch + https://github.com/void-linux/void-packages/raw/bfb212a0ca0f9dda6f34f837e723156f46813d4d/srcpkgs/${PN}/patches/musl_and_ppc.patch -> + ${PN}-2022.10.28-musl-and-ppc.patch +" + +# EmptyEpsilon is mostly licensed under GPL, however the art ressources +# use Creative Commons and the bundled SeriousProton is MIT-licensed. +LICENSE="Apache-2.0 GPL-2 CC-BY-SA-3.0 MIT" +SLOT="0" +KEYWORDS="amd64" + +RDEPEND=" + dev-cpp/nlohmann_json + media-libs/freetype + media-libs/libsdl2 + >=media-libs/glm-0.9.9.8 +" +DEPEND="${RDEPEND}" + +S="${WORKDIR}/EmptyEpsilon-EE-${PV}" + +PATCHES=( + "${FILESDIR}/${PN}-cmake-meshoptimizer.patch" +) + +src_prepare() { + cmake_src_prepare + + local -A externals=() + externals["${BUILD_DIR}/SeriousProton/externals/basis"]="${WORKDIR}/basis_universal-${MY_BU_VER}" + externals["${BUILD_DIR}/externals/meshoptimizer"]="${WORKDIR}/meshoptimizer-${MY_MO_VER}" + local link + for link in "${!externals[@]}"; do + local external_dir=$(dirname "${link}") + if [[ ! -d "${external_dir}" ]]; then + mkdir -p "${external_dir}" || die + fi + local target="${externals[${link}]}" + ln -rs "${target}" "${link}" || die + done + + local serious_proton_patches=( + "${FILESDIR}/SeriousProton-cmake.patch" + # https://github.com/daid/SeriousProton/pull/236 + "${DISTDIR}/SeriousProton-2022.10.28-add-missing-cstdint-include.patch" + ) + eapply --directory="${WORKDIR}/SeriousProton-EE-${PV}" \ + "${serious_proton_patches[@]}" + + # https://bugs.gentoo.org/895994 + eapply -p2 "${DISTDIR}/EmptyEpsilon-2022.10.28-musl-and-ppc.patch" +} + +src_configure() { + local version=( $(ver_rs 1- ' ') ) + local mycmakeargs=( + -DSERIOUS_PROTON_DIR="${WORKDIR}/SeriousProton-EE-${PV}/" + -DCPACK_PACKAGE_VERSION="${PV}" + -DCPACK_PACKAGE_VERSION_MAJOR="${version[0]}" + -DCPACK_PACKAGE_VERSION_MINOR="${version[1]}" + -DCPACK_PACKAGE_VERSION_PATCH="${version[2]}" + ) + + cmake_src_configure +} diff --git a/games-simulation/EmptyEpsilon/Manifest b/games-simulation/EmptyEpsilon/Manifest new file mode 100644 index 000000000000..56be56e05da0 --- /dev/null +++ b/games-simulation/EmptyEpsilon/Manifest @@ -0,0 +1,6 @@ +DIST EmptyEpsilon-2022.10.28-musl-and-ppc.patch 5440 BLAKE2B 7a3f20e5c6595ec037a1855f22b59dc979ff4f69bdf87f8bff09d32f2aedea60595ef4647c87ce182738352d00eaf54f1778dc8d3c46de96b7c7a4cbc963bab4 SHA512 bb555c3752348a4f23c5764542f8b9902b7532222358517463c04f044fe50a98e47a890fd425d2c4c38b6aa1eb7bc48ad508ad08ba5811b2825e7f0483f5312b +DIST EmptyEpsilon-2022.10.28.tar.gz 258148673 BLAKE2B dcc2cdd6f02afef4fee00939145c4c98461ea5403ad45949ffc99758b0575f56504b610249231969f63751d8a2f746913a004d88d7287876a5b448a4b90d8162 SHA512 6af0522cb9f07f0b0cf3ac287ce57b156206b27b4d17de237acf50c46928782c49a4af397c9cad4be30603e0ee04bd6979404e11d0b2c5472cf0c278124df140 +DIST SeriousProton-2022.10.28-add-missing-cstdint-include.patch 850 BLAKE2B f193fb30b39e7b07caf0018fc4e32430ee451baaf63315110e204e7e6f3aff84448a3a5cc83b60e642c27cebb39f532065bd1126f5646ac70645c1c341c8e464 SHA512 3645efb49ea012a31da0414a454bfca46170dfdfd90db7af07481181d75b87c621e7d8ba2ee9752c49d978ab0e5080f01b81eeb07cf1ce68425066c8a4111c2b +DIST SeriousProton-2022.10.28.tar.gz 2668713 BLAKE2B 9f200881bfa812904cd37428eb2bb2f8e04c46a134e8b3fceb0e02e87fe4bd7e529e1fbaf18cb4e284ec7ee4d1c6e8606f35e7ec3e61efa66816a7b354d446b9 SHA512 7955ed78529c0f69d6fd3ef6fac5537009548cdfe1cf8e47dc1fac8919fc3532e03453869968369f027c40dd4da513cfd84e58ffedaddd4b9d9fe67d28406be7 +DIST basis_universal_1_15_update2.tar.gz 13283133 BLAKE2B 5400d23f86dd581da1bc96c1b95eae58f3c97b5412ad1d09d7f4ffd2ae7cae6cb14330795380e253579cc17f1ee16c91555229268219c300905da1420c0d8717 SHA512 a898a057b57ac64f6c0bf5fce0b599e23421ccdd015ea7bb668bce8b9292ef55b098f3d05854a2fb5363959932b75cd0a842664ae7d4f71f3537dc11301c1b32 +DIST meshoptimizer-0.16.tar.gz 342571 BLAKE2B 2b4e244ea3676f109c904261d47bd0e7b2ad440f23d65325d34281ed13ac09657116c96b5a56860a0107479773b58c21018c8825b314f87a05bce38341fd75c1 SHA512 cc6d28359fb99a615e1046a4af1b247cbc6ea0266d9e7f41ea0516c1fc09fa1e67376071daf138a126c77bca3baf9d565636ed0e3adf045f1a08498c38b7a7e7 diff --git a/games-simulation/EmptyEpsilon/files/EmptyEpsilon-cmake-meshoptimizer.patch b/games-simulation/EmptyEpsilon/files/EmptyEpsilon-cmake-meshoptimizer.patch new file mode 100644 index 000000000000..d948d6923e39 --- /dev/null +++ b/games-simulation/EmptyEpsilon/files/EmptyEpsilon-cmake-meshoptimizer.patch @@ -0,0 +1,15 @@ +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -133,9 +133,9 @@ else() + endif() + + if(NOT meshoptimizer_POPULATED) +- if(COMMAND FetchContent_Populate) +- FetchContent_Populate(meshoptimizer) +- endif() ++ set(meshoptimizer_SOURCE_DIR "${EXTERNALS_DIR}/meshoptimizer") ++ set(meshoptimizer_BINARY_DIR "${PROJECT_BINARY_DIR}/externals/meshoptimizer") ++ + add_subdirectory(${meshoptimizer_SOURCE_DIR} ${meshoptimizer_BINARY_DIR} EXCLUDE_FROM_ALL) + endif() + diff --git a/games-simulation/EmptyEpsilon/files/SeriousProton-cmake.patch b/games-simulation/EmptyEpsilon/files/SeriousProton-cmake.patch new file mode 100644 index 000000000000..3ac8368055f1 --- /dev/null +++ b/games-simulation/EmptyEpsilon/files/SeriousProton-cmake.patch @@ -0,0 +1,15 @@ +--- a/libs/basis_universal/CMakeLists.txt ++++ b/libs/basis_universal/CMakeLists.txt +@@ -29,9 +29,9 @@ else() + endif() + + if(NOT basis_POPULATED) +- if(COMMAND FetchContent_Populate) +- FetchContent_Populate(basis) +- endif() ++ set(basis_SOURCE_DIR "${EXTERNALS_DIR}/basis") ++ set(basis_BINARY_DIR "${PROJECT_BINARY_DIR}/externals/basis") ++ + if(CMAKE_SIZEOF_VOID_P EQUAL 8) + set(BUILD_X64 FALSE CACHE BOOL "") + endif() diff --git a/games-simulation/EmptyEpsilon/metadata.xml b/games-simulation/EmptyEpsilon/metadata.xml new file mode 100644 index 000000000000..5a54444ca974 --- /dev/null +++ b/games-simulation/EmptyEpsilon/metadata.xml @@ -0,0 +1,9 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "https://docs.baldeagleos.com/dtd/metadata.dtd"> +<pkgmetadata> + <maintainer type="person"> + <name>Florian Schmaus</name> + <email>flow@gentoo.org</email> + </maintainer> + <origin>baldeagleos-repo</origin> +</pkgmetadata> diff --git a/games-simulation/corsix-th/Manifest b/games-simulation/corsix-th/Manifest new file mode 100644 index 000000000000..baa1eff068e9 --- /dev/null +++ b/games-simulation/corsix-th/Manifest @@ -0,0 +1 @@ +DIST corsix-th-0.68.0.tar.gz 4240659 BLAKE2B 9823e90927a63591384de49dde3cdcaced9fd1221931dacad0a5d115d0fcee2c9616b1a6785e91170c23a653f4bccbf6438fe352afdda9777078cdbfd84f0fda SHA512 087c20d79d249cff77e037561fb978290af75ff13c02e24c52699fd7b4e8a542e23806b7fde93cfff7d47bd98ee1eda4878cd0d4585e12775a2e6337655a5bbf diff --git a/games-simulation/corsix-th/corsix-th-0.68.0.ebuild b/games-simulation/corsix-th/corsix-th-0.68.0.ebuild new file mode 100644 index 000000000000..243e51c353ad --- /dev/null +++ b/games-simulation/corsix-th/corsix-th-0.68.0.ebuild @@ -0,0 +1,106 @@ +# Copyright 1999-2025 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +LUA_COMPAT=( lua5-{1,3,4} luajit ) + +inherit cmake edo lua-single xdg + +MY_PN="CorsixTH" +MY_PV="${PV/_/-}" +MY_P="${MY_PN}-${MY_PV}" + +DESCRIPTION="Open source clone of Theme Hospital" +HOMEPAGE="https://corsixth.com" +if [[ ${PV} == 9999 ]] ; then + EGIT_REPO_URI="https://github.com/${MY_PN}/${MY_PN}" + inherit git-r3 +else + SRC_URI="https://github.com/${MY_PN}/${MY_PN}/archive/v${MY_PV}.tar.gz -> ${P}.tar.gz" + S="${WORKDIR}/${MY_P}" + + if [[ ${PV} != *_beta* && ${PV} != *_rc* ]] ; then + KEYWORDS="~amd64 ~arm ~arm64 ~ppc64 ~x86" + fi +fi + +LICENSE="MIT" +SLOT="0" +IUSE="doc +midi +sound test tools +truetype +videos" +RESTRICT="!test? ( test )" +REQUIRED_USE="${LUA_REQUIRED_USE}" + +RDEPEND="${LUA_DEPS} + $(lua_gen_cond_dep ' + >=dev-lua/luafilesystem-1.5[${LUA_USEDEP}] + >=dev-lua/lpeg-0.9[${LUA_USEDEP}] + >=dev-lua/luasocket-3.0_rc1-r4[${LUA_USEDEP}] + ') + media-libs/libsdl2[opengl,video] + sound? ( media-libs/sdl2-mixer[midi?] ) + truetype? ( >=media-libs/freetype-2.5.3:2 ) + videos? ( >=media-video/ffmpeg-2.2.3:0= ) +" + +DEPEND="${RDEPEND}" + +# Although the docs could potentially be built with nearly any Lua version, +# we need to ensure the necessary Lua modules are installed, so pin to the +# same single version as runtime. +BDEPEND=" + virtual/pkgconfig + doc? ( + app-text/doxygen[dot] + ${LUA_DEPS} + $(lua_gen_cond_dep ' + >=dev-lua/luafilesystem-1.5[${LUA_USEDEP}] + >=dev-lua/lpeg-0.9[${LUA_USEDEP}] + ') + ) + test? ( + >=dev-cpp/catch-3:0 + ) +" + +PATCHES=( + "${FILESDIR}"/${PN}-0.67-cmake_lua_detection.patch +) + +lua_enable_tests busted + +src_configure() { + local mycmakeargs=( + -DLUA_VERSION=$(lua_get_version) + -DBUILD_TOOLS=$(usex tools) + -DENABLE_UNIT_TESTS=$(usex test) + -DWITH_AUDIO=$(usex sound) + -DWITH_FREETYPE2=$(usex truetype) + -DWITH_MOVIES=$(usex videos) + -DWITH_UPDATE_CHECK=OFF + ) + + cmake_src_configure +} + +src_compile() { + cmake_src_compile + use doc && cmake_src_compile doc +} + +src_test() { + # https://github.com/CorsixTH/CorsixTH/blob/master/.github/workflows/Linux.yml#L88 + # C++ tests + BUILD_DIR="${BUILD_DIR}"/CorsixTH cmake_src_test + + # Lua tests + edo busted --lua="${ELUA}" --output="TAP" --verbose --directory=CorsixTH/Luatest +} + +src_install() { + cmake_src_install + dodoc changelog.txt CONTRIBUTING.md + + docinto html + use doc && dodoc -r "${BUILD_DIR}"/doc/* +} diff --git a/games-simulation/corsix-th/corsix-th-9999.ebuild b/games-simulation/corsix-th/corsix-th-9999.ebuild new file mode 100644 index 000000000000..243e51c353ad --- /dev/null +++ b/games-simulation/corsix-th/corsix-th-9999.ebuild @@ -0,0 +1,106 @@ +# Copyright 1999-2025 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +LUA_COMPAT=( lua5-{1,3,4} luajit ) + +inherit cmake edo lua-single xdg + +MY_PN="CorsixTH" +MY_PV="${PV/_/-}" +MY_P="${MY_PN}-${MY_PV}" + +DESCRIPTION="Open source clone of Theme Hospital" +HOMEPAGE="https://corsixth.com" +if [[ ${PV} == 9999 ]] ; then + EGIT_REPO_URI="https://github.com/${MY_PN}/${MY_PN}" + inherit git-r3 +else + SRC_URI="https://github.com/${MY_PN}/${MY_PN}/archive/v${MY_PV}.tar.gz -> ${P}.tar.gz" + S="${WORKDIR}/${MY_P}" + + if [[ ${PV} != *_beta* && ${PV} != *_rc* ]] ; then + KEYWORDS="~amd64 ~arm ~arm64 ~ppc64 ~x86" + fi +fi + +LICENSE="MIT" +SLOT="0" +IUSE="doc +midi +sound test tools +truetype +videos" +RESTRICT="!test? ( test )" +REQUIRED_USE="${LUA_REQUIRED_USE}" + +RDEPEND="${LUA_DEPS} + $(lua_gen_cond_dep ' + >=dev-lua/luafilesystem-1.5[${LUA_USEDEP}] + >=dev-lua/lpeg-0.9[${LUA_USEDEP}] + >=dev-lua/luasocket-3.0_rc1-r4[${LUA_USEDEP}] + ') + media-libs/libsdl2[opengl,video] + sound? ( media-libs/sdl2-mixer[midi?] ) + truetype? ( >=media-libs/freetype-2.5.3:2 ) + videos? ( >=media-video/ffmpeg-2.2.3:0= ) +" + +DEPEND="${RDEPEND}" + +# Although the docs could potentially be built with nearly any Lua version, +# we need to ensure the necessary Lua modules are installed, so pin to the +# same single version as runtime. +BDEPEND=" + virtual/pkgconfig + doc? ( + app-text/doxygen[dot] + ${LUA_DEPS} + $(lua_gen_cond_dep ' + >=dev-lua/luafilesystem-1.5[${LUA_USEDEP}] + >=dev-lua/lpeg-0.9[${LUA_USEDEP}] + ') + ) + test? ( + >=dev-cpp/catch-3:0 + ) +" + +PATCHES=( + "${FILESDIR}"/${PN}-0.67-cmake_lua_detection.patch +) + +lua_enable_tests busted + +src_configure() { + local mycmakeargs=( + -DLUA_VERSION=$(lua_get_version) + -DBUILD_TOOLS=$(usex tools) + -DENABLE_UNIT_TESTS=$(usex test) + -DWITH_AUDIO=$(usex sound) + -DWITH_FREETYPE2=$(usex truetype) + -DWITH_MOVIES=$(usex videos) + -DWITH_UPDATE_CHECK=OFF + ) + + cmake_src_configure +} + +src_compile() { + cmake_src_compile + use doc && cmake_src_compile doc +} + +src_test() { + # https://github.com/CorsixTH/CorsixTH/blob/master/.github/workflows/Linux.yml#L88 + # C++ tests + BUILD_DIR="${BUILD_DIR}"/CorsixTH cmake_src_test + + # Lua tests + edo busted --lua="${ELUA}" --output="TAP" --verbose --directory=CorsixTH/Luatest +} + +src_install() { + cmake_src_install + dodoc changelog.txt CONTRIBUTING.md + + docinto html + use doc && dodoc -r "${BUILD_DIR}"/doc/* +} diff --git a/games-simulation/corsix-th/files/corsix-th-0.67-cmake_lua_detection.patch b/games-simulation/corsix-th/files/corsix-th-0.67-cmake_lua_detection.patch new file mode 100644 index 000000000000..b5a62a81a615 --- /dev/null +++ b/games-simulation/corsix-th/files/corsix-th-0.67-cmake_lua_detection.patch @@ -0,0 +1,24 @@ +diff -Naur a/CMake/GenerateDoc.cmake b/CMake/GenerateDoc.cmake +--- a/CMake/GenerateDoc.cmake 2023-08-06 04:02:29.000000000 +0100 ++++ b/CMake/GenerateDoc.cmake 2023-10-16 23:26:11.527720737 +0100 +@@ -5,7 +5,7 @@ + set(LUA_PROGRAM_NAMES lua53 lua5.3 lua-5.3 lua52 lua5.2 lua-5.2 lua51 lua5.1 lua-5.1 lua) + endif() + +-find_program(LUA_PROGRAM_PATH ${LUA_PROGRAM_NAMES} ++find_program(LUA_PROGRAM_PATH lua${LUA_VERSION} + PATHS + ENV LUA_DIR + /opt +diff -Naur a/CorsixTH/CMakeLists.txt b/CorsixTH/CMakeLists.txt +--- a/CorsixTH/CMakeLists.txt 2023-08-06 04:02:29.000000000 +0100 ++++ b/CorsixTH/CMakeLists.txt 2023-10-16 23:23:20.119763454 +0100 +@@ -132,7 +132,7 @@ + target_link_libraries(CorsixTH_lib lua) + target_link_libraries(CorsixTH lua) + else() +- find_package(Lua REQUIRED) ++ find_package(Lua ${LUA_VERSION} EXACT REQUIRED) + if(Lua_FOUND OR LUA_FOUND) + target_link_libraries(CorsixTH ${LUA_LIBRARY}) + include_directories(${LUA_INCLUDE_DIR}) diff --git a/games-simulation/corsix-th/metadata.xml b/games-simulation/corsix-th/metadata.xml new file mode 100644 index 000000000000..0ffe99d412af --- /dev/null +++ b/games-simulation/corsix-th/metadata.xml @@ -0,0 +1,19 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "https://docs.baldeagleos.com/dtd/metadata.dtd"> +<pkgmetadata> + <maintainer type="project"> + <email>games@gentoo.org</email> + <name>Gentoo Games Project</name> + </maintainer> + <longdescription lang="en"> + A reimplementation of the 1997 Bullfrog business sim Theme + Hospital. As well as faithfully recreating the original, + CorsixTH adds support for modern operating systems (Windows, + Mac OSX and Linux), high resolutions and much more. + </longdescription> + <use> + <flag name="midi">Adds support for background MIDI music via SDL_mixer</flag> + <flag name="tools">Build tools for decoding RNC files</flag> + </use> + <origin>baldeagleos-repo</origin> +</pkgmetadata> diff --git a/games-simulation/crashtest/Manifest b/games-simulation/crashtest/Manifest new file mode 100644 index 000000000000..171bb092a4a3 --- /dev/null +++ b/games-simulation/crashtest/Manifest @@ -0,0 +1 @@ +DIST crashtest-1.1.tar.gz 134769 BLAKE2B 16c7be2723d705bbcfc4457a0d7bb545ddaacfb9009cc184c849c59a1c356c67d0151bd7bbb0d1909efb89d24e18657038fe0dd66e218e0c7ed24c67ba82089b SHA512 f361b5f202cdcdca871357eb2a2158af2958f4058b6754c63dc5a20c3e08e2ef532e984596d0daac073f2321b2db02e3f8c2a0a4998450fc953c1661d712d59c diff --git a/games-simulation/crashtest/crashtest-1.1-r3.ebuild b/games-simulation/crashtest/crashtest-1.1-r3.ebuild new file mode 100644 index 000000000000..9157646d6f34 --- /dev/null +++ b/games-simulation/crashtest/crashtest-1.1-r3.ebuild @@ -0,0 +1,44 @@ +# Copyright 1999-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +inherit desktop toolchain-funcs + +DESCRIPTION="Educational car crash simulator" +HOMEPAGE="https://www.stolk.org/crashtest/" +SRC_URI="https://www.stolk.org/crashtest/${P}.tar.gz" +S="${WORKDIR}/${P}/src-${PN}" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="~amd64 ~x86" + +RDEPEND=" + dev-games/ode:= + media-libs/freeglut + media-libs/plib + virtual/glu + virtual/opengl + x11-libs/fltk:1=[opengl]" +DEPEND="${RDEPEND}" + +PATCHES=( + "${FILESDIR}"/${P}-gentoo.patch +) + +src_prepare() { + default + + sed -e "s|@GENTOO_DATADIR@|${EPREFIX}/usr/share/${PN}|" \ + -e "s|@GENTOO_BINDIR@|${EPREFIX}/usr/bin|" \ + -i Makefile ${PN}.cxx || die + + tc-export CXX +} + +src_install() { + default + + make_desktop_entry ${PN} Crashtest applications-games +} diff --git a/games-simulation/crashtest/files/crashtest-1.1-gentoo.patch b/games-simulation/crashtest/files/crashtest-1.1-gentoo.patch new file mode 100644 index 000000000000..8e8a7d9aff61 --- /dev/null +++ b/games-simulation/crashtest/files/crashtest-1.1-gentoo.patch @@ -0,0 +1,92 @@ +--- a/Makefile ++++ b/Makefile +@@ -1,34 +1,12 @@ +-# EDIT THESE SETTINGS +- +-PLIBPREFIX=/usr +-ODEPREFIX=/usr +-CXX=g++ +- +-#PLIBPREFIX=$(HOME) +-#ODEPREFIX=$(HOME) +-#CXX=g++-4.0 +- +-# END OF CUSTOM SETTINGS +- +-CXXFLAGS=\ +- -I$(ODEPREFIX)/include \ +- -I$(PLIBPREFIX)/include \ +- -I../src-common \ +- -O2 -g -Wall +- +-LFLAGS=\ +- -L$(PLIBPREFIX)/lib \ +- -L/usr/X11R6/lib +- + OBJS=staticworldobject.o crashtest.o dynamicobject.o cartobject.o ++CXXFLAGS+=-I `fltk-config --includedir` `ode-config --cflags` + +-LIBS= $(ODEPREFIX)/lib/libode.a -lplibssgaux -lplibssg -lplibsg -lplibpu -lplibfnt -lplibul -lGLU -lGL `fltk-config --use-gl --use-images --ldflags` +- ++LIBS= `ode-config --libs` -lplibssgaux -lplibssg -lplibsg -lplibpu -lplibfnt -lplibul -lGLU -lGL `fltk-config --use-gl --use-images --ldflags` -lglut + + all: crashtest + + crashtest: $(OBJS) +- $(CXX) -o crashtest $(OBJS) $(LFLAGS) $(LIBS) ++ $(CXX) -o crashtest $(OBJS) $(LDFLAGS) $(LIBS) + + staticworldobject.o: ../src-common/staticworldobject.cxx ../src-common/staticworldobject.h ../src-common/worldobject.h + $(CXX) -c $(CXXFLAGS) ../src-common/staticworldobject.cxx +@@ -37,10 +14,10 @@ + $(CXX) -c $(CXXFLAGS) ../src-common/dynamicobject.cxx + + cartobject.o: cartobject.cxx cartobject.h +- $(CXX) -c $(CXXFLAGS) cartobject.cxx ++ $(CXX) -c $(CXXFLAGS) -I../src-common cartobject.cxx + + crashtest.o: crashtest.cxx crashworld.h ../src-common/modelmap.h cartobject.h bipedobject.h ../src-common/brickwall.h ../src-common/stereocontext.h ../src-common/usercam.h +- $(CXX) -c $(CXXFLAGS) crashtest.cxx ++ $(CXX) -c $(CXXFLAGS) -I../src-common crashtest.cxx + + + +@@ -48,13 +25,13 @@ + PLODE_DATADIR=`pwd` ./crashtest + + +-GAMEDIR=$(DESTDIR)/usr/share/games/crashtest ++GAMEDIR=$(DESTDIR)@GENTOO_DATADIR@ + install: crashtest + # Directories +- mkdir -p $(DESTDIR)/usr/games/ ++ mkdir -p $(DESTDIR)@GENTOO_BINDIR@ + mkdir -p $(GAMEDIR)/models/ + # Binary +- install crashtest $(DESTDIR)/usr/games/crashtest ++ install crashtest $(DESTDIR)@GENTOO_BINDIR@ + # Models + install -m 644 models/testground.3ds $(GAMEDIR)/models/testground.3ds + install -m 644 models/biped_torso.3ds $(GAMEDIR)/models/biped_torso.3ds +--- a/crashtest.cxx ++++ b/crashtest.cxx +@@ -615,13 +615,7 @@ + + int main(int argc, char *argv[]) + { +- char *bindirname = dirname(argv[0]); +- if (!strcmp(bindirname,".")) +- dirprefix="/usr/share/games/crashtest"; +- else +- { +- dirprefix = dirname(bindirname) + std::string("/share/games/crashtest"); +- } ++ dirprefix="@GENTOO_DATADIR@"; + if (getenv("PLODE_DATADIR")) + dirprefix = getenv("PLODE_DATADIR"); + modelmap = new ModelMap(dirprefix); +@@ -745,4 +739,3 @@ + Fl::add_idle(idle, &simwin); + Fl::run(); + } +- diff --git a/games-simulation/crashtest/metadata.xml b/games-simulation/crashtest/metadata.xml new file mode 100644 index 000000000000..43c596ab31b1 --- /dev/null +++ b/games-simulation/crashtest/metadata.xml @@ -0,0 +1,15 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "https://docs.baldeagleos.com/dtd/metadata.dtd"> +<pkgmetadata> + <maintainer type="project"> + <email>games@gentoo.org</email> + <name>Gentoo Games Project</name> + </maintainer> + <longdescription lang="en"> +Crashtest simulates car crashes. This is an educational tool that can be used to +acquire much insight into this complex process. The user can learn about the +relation between speed, reaction-time and stopping distance. Also, many physical +properties can be studied. +</longdescription> + <origin>baldeagleos-repo</origin> +</pkgmetadata> diff --git a/games-simulation/crrcsim/Manifest b/games-simulation/crrcsim/Manifest new file mode 100644 index 000000000000..f956c9e7355d --- /dev/null +++ b/games-simulation/crrcsim/Manifest @@ -0,0 +1 @@ +DIST crrcsim-0.9.13.tar.gz 8337392 BLAKE2B ccaaf3a4255b2082fc52712d49302c7de1347b87e9489c6d859662365f1cd5af538fe76cee232aed61b0c1b68138c47a2e34e128071c3e098e20f1d51c1c409c SHA512 b687837e07abc07606404d920288984abe7e304afb69158fd840d83bcfe1e9acc4afd8462c0c759df67d50a15ca3753eaf48c4526b201e64a2d641fa3aa8c1ab diff --git a/games-simulation/crrcsim/crrcsim-0.9.13-r2.ebuild b/games-simulation/crrcsim/crrcsim-0.9.13-r2.ebuild new file mode 100644 index 000000000000..4a3e7a3bea2d --- /dev/null +++ b/games-simulation/crrcsim/crrcsim-0.9.13-r2.ebuild @@ -0,0 +1,52 @@ +# Copyright 1999-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +inherit autotools desktop + +DESCRIPTION="Model-airplane flight simulation program" +HOMEPAGE="https://sourceforge.net/projects/crrcsim/" +SRC_URI="https://downloads.sourceforge.net/${PN}/${P}.tar.gz" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="~amd64 ~x86" +IUSE="portaudio" + +RDEPEND=" + dev-libs/gmp:= + media-libs/libsdl[X,sound,joystick,opengl,video] + media-libs/plib + virtual/glu + virtual/jpeg + virtual/opengl + portaudio? ( media-libs/portaudio )" +DEPEND=" + ${RDEPEND} + sci-mathematics/cgal" + +PATCHES=( + "${FILESDIR}"/${P}-gcc6.patch + "${FILESDIR}"/${P}-overlink.patch + "${FILESDIR}"/${P}-clang.patch +) + +DOCS=( AUTHORS HISTORY ) + +src_prepare() { + default + + eautoreconf +} + +src_configure() { + econf ac_cv_header_portaudio_h=$(usex portaudio) +} + +src_install() { + default + + doicon packages/icons/${PN}.png + make_desktop_entry ${PN} CRRCSim +} diff --git a/games-simulation/crrcsim/files/crrcsim-0.9.13-clang.patch b/games-simulation/crrcsim/files/crrcsim-0.9.13-clang.patch new file mode 100644 index 000000000000..967d51d7239d --- /dev/null +++ b/games-simulation/crrcsim/files/crrcsim-0.9.13-clang.patch @@ -0,0 +1,10 @@ +https://bugs.gentoo.org/830572 +--- a/src/mod_fdm_config.h ++++ b/src/mod_fdm_config.h +@@ -36,5 +36,5 @@ + #define MOD_FDM_USE_MCOPTER01 1 + +-#define MOD_FDM_INFOSTR "CRRCSim "PACKAGE_VERSION ++#define MOD_FDM_INFOSTR "CRRCSim " PACKAGE_VERSION + + diff --git a/games-simulation/crrcsim/files/crrcsim-0.9.13-gcc6.patch b/games-simulation/crrcsim/files/crrcsim-0.9.13-gcc6.patch new file mode 100644 index 000000000000..b11550f3dff6 --- /dev/null +++ b/games-simulation/crrcsim/files/crrcsim-0.9.13-gcc6.patch @@ -0,0 +1,14 @@ +Bug: https://bugs.gentoo.org/610560 +Upstream commit: https://sourceforge.net/p/crrcsim/code/ci/28ed9ba57011371cab8b637550acc716b973c47d + +--- a/src/mod_video/crrc_animation.cpp ++++ b/src/mod_video/crrc_animation.cpp +@@ -84,7 +84,7 @@ + else + { + std::cerr << "createAnimation: unknown animation type \'" +- << type << "\'" << std::cerr; ++ << type << "\'" << std::endl; + } + + if (anim != NULL) diff --git a/games-simulation/crrcsim/files/crrcsim-0.9.13-overlink.patch b/games-simulation/crrcsim/files/crrcsim-0.9.13-overlink.patch new file mode 100644 index 000000000000..42bcc6e3d995 --- /dev/null +++ b/games-simulation/crrcsim/files/crrcsim-0.9.13-overlink.patch @@ -0,0 +1,20 @@ +With CGAL now being header-only and boost-1.77.0 dropping thread-mt (not +actually linking with it), these link attempts just cause unnecessary issues. + +https://bugs.gentoo.org/790779 +https://bugs.gentoo.org/808727 +--- a/configure.ac ++++ b/configure.ac +@@ -227,5 +227,4 @@ + has_CGAL="yes (found CGAL > v3)" + AC_CHECK_LIB(gmp,__gmpq_init,,AC_MSG_ERROR([gmp library not found. Please install it.])) +- AC_CHECK_LIB(boost_thread-mt,main,,AC_MSG_ERROR([boost_thread-mt library not found. Please install it.])) + else + AC_DEFINE([CGAL_VERSION3], [1], [CGAL_VERSION3 compatibility]) +@@ -233,5 +232,5 @@ + fi + CGAL_CFLAGS=-frounding-math +- CGAL_LIBS=-lCGAL ++ CGAL_LIBS= + AC_DEFINE([WINDDATA3D], [1], [Import code for wind data, needs CGAL, 0 to disable]) + else diff --git a/games-simulation/crrcsim/metadata.xml b/games-simulation/crrcsim/metadata.xml new file mode 100644 index 000000000000..183ecc5ceeeb --- /dev/null +++ b/games-simulation/crrcsim/metadata.xml @@ -0,0 +1,9 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "https://docs.baldeagleos.com/dtd/metadata.dtd"> +<pkgmetadata> + <maintainer type="project"> + <email>games@gentoo.org</email> + <name>Gentoo Games Project</name> + </maintainer> + <origin>baldeagleos-repo</origin> +</pkgmetadata> diff --git a/games-simulation/flightgear-data/Manifest b/games-simulation/flightgear-data/Manifest new file mode 100644 index 000000000000..dfd4bbb60dc1 --- /dev/null +++ b/games-simulation/flightgear-data/Manifest @@ -0,0 +1 @@ +DIST FlightGear-2024.1.1-data.txz 1873735848 BLAKE2B b43cfd5aa90f749fb6f0c40c25c94e494a296c92eca452d7e171dd4654d9aae3b80c432cb0bd69af44981ec0704776d91cf85f67d6d93fe3b58db19859094e33 SHA512 ab478e806248783b4b8bb4ab5250d83e41f523c466beb3655fdb58e3ca508b2fb58247adb55041101e82729c9063901298b8220a608ddba5e9d3c80fc7575061 diff --git a/games-simulation/flightgear-data/flightgear-data-2024.1.1.ebuild b/games-simulation/flightgear-data/flightgear-data-2024.1.1.ebuild new file mode 100644 index 000000000000..470dc9147526 --- /dev/null +++ b/games-simulation/flightgear-data/flightgear-data-2024.1.1.ebuild @@ -0,0 +1,20 @@ +# Copyright 1999-2025 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +DESCRIPTION="FlightGear data files" +HOMEPAGE="https://www.flightgear.org/" +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" + +src_install() { + insinto /usr/share/flightgear + rm -fr .git + doins -r * +} diff --git a/games-simulation/flightgear-data/flightgear-data-9999.ebuild b/games-simulation/flightgear-data/flightgear-data-9999.ebuild new file mode 100644 index 000000000000..4689c0dd649c --- /dev/null +++ b/games-simulation/flightgear-data/flightgear-data-9999.ebuild @@ -0,0 +1,21 @@ +# Copyright 1999-2025 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +inherit git-r3 + +DESCRIPTION="FlightGear data files" +HOMEPAGE="https://www.flightgear.org/" +EGIT_REPO_URI="https://gitlab.com/flightgear/fgdata.git" +EGIT_BRANCH="next" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="" + +src_install() { + insinto /usr/share/flightgear + rm -fr .git + doins -r * +} diff --git a/games-simulation/flightgear-data/metadata.xml b/games-simulation/flightgear-data/metadata.xml new file mode 100644 index 000000000000..183ecc5ceeeb --- /dev/null +++ b/games-simulation/flightgear-data/metadata.xml @@ -0,0 +1,9 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "https://docs.baldeagleos.com/dtd/metadata.dtd"> +<pkgmetadata> + <maintainer type="project"> + <email>games@gentoo.org</email> + <name>Gentoo Games Project</name> + </maintainer> + <origin>baldeagleos-repo</origin> +</pkgmetadata> diff --git a/games-simulation/flightgear/Manifest b/games-simulation/flightgear/Manifest new file mode 100644 index 000000000000..cc775842173b --- /dev/null +++ b/games-simulation/flightgear/Manifest @@ -0,0 +1 @@ +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 000000000000..1cf5e6b4fa54 --- /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 <fabrice@bellet.info> +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 000000000000..a205953c8a4e --- /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 <fabrice@bellet.info> +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 000000000000..450a701a5a26 --- /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 <fabrice@bellet.info> +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 000000000000..a93c6e009356 --- /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 <fabrice@bellet.info> +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/ac3d.vim b/games-simulation/flightgear/files/ac3d.vim new file mode 100644 index 000000000000..6477d949b762 --- /dev/null +++ b/games-simulation/flightgear/files/ac3d.vim @@ -0,0 +1 @@ +au BufRead,BufNewFile *.ac set filetype=ac3d 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 000000000000..0aa0f665e1dd --- /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-openal-init-decl.patch b/games-simulation/flightgear/files/flightgear-2024.1.1-openal-init-decl.patch new file mode 100644 index 000000000000..0099b0b62dbb --- /dev/null +++ b/games-simulation/flightgear/files/flightgear-2024.1.1-openal-init-decl.patch @@ -0,0 +1,65 @@ +From 4effb8ca7a0faa2cd7fac58f29b37e32227e487d Mon Sep 17 00:00:00 2001 +From: Florent Rougon <f.rougon@frougon.net> +Date: Wed, 7 May 2025 14:46:31 +0200 +Subject: [PATCH] 3rdparty/iaxclient: fix declaration of openal_initialize() + +In audio_openal.h, openal_initialize() was declared without any +parameter specified, however the definition takes two. This was valid in +pre-ANSI C (K&R function declarations) but was removed in C23 and is +apparently already causing problems: + + https://sourceforge.net/p/flightgear/mailman/message/59181327/ + +Also move #include "audio_openal.h" from iaxclient_lib.h to where it is +actually needed (iaxclient_lib.c). +--- + 3rdparty/iaxclient/lib/audio_openal.h | 2 +- + 3rdparty/iaxclient/lib/iaxclient_lib.c | 4 ++++ + 3rdparty/iaxclient/lib/iaxclient_lib.h | 4 ---- + 3 files changed, 5 insertions(+), 5 deletions(-) + +diff --git a/3rdparty/iaxclient/lib/audio_openal.h b/3rdparty/iaxclient/lib/audio_openal.h +index a698235adb..de7cbc866c 100644 +--- a/3rdparty/iaxclient/lib/audio_openal.h ++++ b/3rdparty/iaxclient/lib/audio_openal.h +@@ -1,6 +1,6 @@ + #ifndef _AUDIO_OPENAL_H + #define _AUDIO_OPENAL_H + +-int openal_initialize(); ++int openal_initialize(struct iaxc_audio_driver *d, int sample_rate); + + #endif +diff --git a/3rdparty/iaxclient/lib/iaxclient_lib.c b/3rdparty/iaxclient/lib/iaxclient_lib.c +index 761dee42b9..ae2c43f3ca 100644 +--- a/3rdparty/iaxclient/lib/iaxclient_lib.c ++++ b/3rdparty/iaxclient/lib/iaxclient_lib.c +@@ -47,6 +47,10 @@ + #include "audio_alsa.h" + #endif + ++#ifdef AUDIO_OPENAL ++ #include "audio_openal.h" ++#endif ++ + #define IAXC_ERROR IAXC_TEXT_TYPE_ERROR + #define IAXC_STATUS IAXC_TEXT_TYPE_STATUS + #define IAXC_NOTICE IAXC_TEXT_TYPE_NOTICE +diff --git a/3rdparty/iaxclient/lib/iaxclient_lib.h b/3rdparty/iaxclient/lib/iaxclient_lib.h +index 91776c3351..d98dc45167 100644 +--- a/3rdparty/iaxclient/lib/iaxclient_lib.h ++++ b/3rdparty/iaxclient/lib/iaxclient_lib.h +@@ -242,10 +242,6 @@ struct iaxc_call { + + #include "audio_file.h" + +-#ifdef AUDIO_OPENAL +- #include "audio_openal.h" +-#endif +- + extern int iaxci_audio_output_mode; + + int iaxci_post_event_callback(iaxc_event e); +-- +GitLab + diff --git a/games-simulation/flightgear/files/nasal.vim b/games-simulation/flightgear/files/nasal.vim new file mode 100644 index 000000000000..65a2ed17fc26 --- /dev/null +++ b/games-simulation/flightgear/files/nasal.vim @@ -0,0 +1 @@ +au BufRead,BufNewFile *.nas set filetype=nasal diff --git a/games-simulation/flightgear/flightgear-2024.1.1.ebuild b/games-simulation/flightgear/flightgear-2024.1.1.ebuild new file mode 100644 index 000000000000..83ec9502b118 --- /dev/null +++ b/games-simulation/flightgear/flightgear-2024.1.1.ebuild @@ -0,0 +1,170 @@ +# Copyright 1999-2026 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +inherit cmake flag-o-matic xdg + +DESCRIPTION="Open Source Flight Simulator" +HOMEPAGE="https://www.flightgear.org/" +SRC_URI="https://gitlab.com/flightgear/fgmeta/-/jobs/9264813015/artifacts/raw/fgbuild/${P}.tar.bz2" + +LICENSE="GPL-2" +SLOT="0" +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-3.6.0[jpeg,png] + ~dev-games/simgear-${PV}[gdal=] + media-libs/openal + >=media-libs/plib-1.8.5 + >=media-libs/speex-1.2.0:0 + media-libs/speexdsp:0 + media-sound/gsm + virtual/zlib:= + virtual/glu + x11-libs/libX11 + dbus? ( >=sys-apps/dbus-1.6.18-r1 ) + gdal? ( >=sci-libs/gdal-2.0.0:= ) + qt6? ( + dev-qt/qtbase:6[gui,network,widgets] + dev-qt/qtdeclarative:6 + ) + udev? ( virtual/udev ) + utils? ( + media-libs/freeglut + media-libs/freetype:2 + media-libs/glew:0 + media-libs/libpng:0 + virtual/opengl + qt6? ( dev-qt/qtwebsockets:6 ) + ) +" +# libXi and libXmu are build-only-deps according to FindGLUT.cmake +DEPEND="${COMMON_DEPEND} + dev-libs/boost + x11-base/xorg-proto + utils? ( + x11-libs/libXi + x11-libs/libXmu + ) +" +RDEPEND="${COMMON_DEPEND} + ~games-simulation/${PN}-data-${PV} +" +BDEPEND="qt6? ( dev-qt/qttools:6[linguist] )" + +PATCHES=( + "${FILESDIR}/${PN}-2024.1.1-cmake.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" + "${FILESDIR}/${P}-openal-init-decl.patch" +) + +DOCS=(AUTHORS ChangeLog NEWS README Thanks) + +src_configure() { + # -Werror=lto-type-mismatch, -Werror=odr + # https://bugs.gentoo.org/859217 + # https://sourceforge.net/p/flightgear/codetickets/2908/ + filter-lto + + local mycmakeargs=( + -DBUILD_SHARED_LIBS=OFF + -DCHECK_FOR_QT5=OFF + -DCHECK_FOR_QT6=ON + -DENABLE_AUTOTESTING=OFF + -DENABLE_FGCOM=$(usex utils) + -DENABLE_FGELEV=$(usex utils) + -DENABLE_FGJS=$(usex utils) + -DENABLE_FGVIEWER=$(usex utils) + -DENABLE_GDAL=$(usex gdal) + -DENABLE_GPSSMOOTH=$(usex utils) + -DENABLE_HID_INPUT=$(usex udev) + -DENABLE_IAX=$(usex utils) + -DENABLE_JS_DEMO=$(usex utils) + -DENABLE_JSBSIM=ON + -DENABLE_LARCSIM=ON + -DENABLE_METAR=$(usex utils) + -DENABLE_PLIB_JOYSTICK=ON # NOTE look for defaults changes in CMake + -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_TRAFFIC=$(usex utils) + -DENABLE_UIUC_MODEL=ON + -DENABLE_VR=OFF + -DENABLE_YASIM=ON + -DEVENT_INPUT=$(usex udev) + -DFG_BUILD_TYPE=Release + -DFG_DATA_DIR=/usr/share/${PN} + -DJSBSIM_TERRAIN=ON + -DOSG_FSTREAM_EXPORT_FIXED=OFF # TODO also see simgear + -DSP_FDMS=ON + -DSYSTEM_CPPUNIT=OFF # NOTE we do not build tests anyway + -DSYSTEM_FLITE=OFF + -DSYSTEM_HTS_ENGINE=OFF + -DSYSTEM_SPEEX=ON + -DSYSTEM_GSM=ON + -DSYSTEM_SQLITE=ON + -DSYSTEM_OSGXR=ON + -DUSE_AEONWAVE=OFF + -DUSE_DBUS=$(usex dbus) + -DWITH_FGPANEL=$(usex utils) + -DENABLE_FGQCANVAS=OFF # still Qt5-only, bug 968375 + ) + if use gdal && use utils; then + mycmakeargs+=(-DENABLE_DEMCONVERT=ON) + else + mycmakeargs+=(-DENABLE_DEMCONVERT=OFF) + fi + + cmake_src_configure +} + +src_install() { + cmake_src_install + + # Install bash completion (TODO zsh) + # Uncomment below when scripts stops writing files... +# sed -e "s|/usr/local/share/FlightGear|${GAMES_DATADIR}/${PN}|" \ +# -i scripts/completion/fg-completion.bash || die 'unable to replace FG_ROOT' +# newbashcomp scripts/completion/fg-completion.bash ${PN} + + # Install examples and other misc files + if use examples; then + docompress -x /usr/share/doc/"${PF}"/{examples,tools} + docinto examples + dodoc -r scripts/java scripts/perl scripts/python + docinto examples/c++ + dodoc -r scripts/example/* + docinto tools + dodoc -r scripts/atis scripts/tools/* + fi + + # Install nasal script syntax + insinto /usr/share/vim/vimfiles/syntax + doins scripts/syntax/{ac3d,nasal}.vim + insinto /usr/share/vim/vimfiles/ftdetect/ + doins "${FILESDIR}"/{ac3d,nasal}.vim +} + +pkg_postinst() { + 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 new file mode 100644 index 000000000000..4dca7305d954 --- /dev/null +++ b/games-simulation/flightgear/flightgear-9999.ebuild @@ -0,0 +1,171 @@ +# Copyright 1999-2025 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +inherit cmake flag-o-matic git-r3 + +DESCRIPTION="Open Source Flight Simulator" +HOMEPAGE="https://www.flightgear.org/" +EGIT_REPO_URI="https://gitlab.com/flightgear/${PN}.git" +EGIT_BRANCH="next" + +LICENSE="GPL-2" +SLOT="0" +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-3.6.0[jpeg,png] + ~dev-games/simgear-${PV}[gdal=] + media-libs/openal + >=media-libs/plib-1.8.5 + >=media-libs/speex-1.2.0:0 + media-libs/speexdsp:0 + media-sound/gsm + virtual/zlib:= + virtual/glu + x11-libs/libX11 + dbus? ( >=sys-apps/dbus-1.6.18-r1 ) + gdal? ( >=sci-libs/gdal-2.0.0:= ) + qt6? ( + dev-qt/qtbase:6[gui,network,widgets] + dev-qt/qtdeclarative:6 + ) + udev? ( virtual/udev ) + utils? ( + media-libs/freeglut + media-libs/freetype:2 + media-libs/glew:0 + media-libs/libpng:0 + virtual/opengl + qt6? ( dev-qt/qtwebsockets:6 ) + ) +" +# libXi and libXmu are build-only-deps according to FindGLUT.cmake +DEPEND="${COMMON_DEPEND} + dev-libs/boost + x11-base/xorg-proto + utils? ( + x11-libs/libXi + x11-libs/libXmu + ) +" +RDEPEND="${COMMON_DEPEND} + ~games-simulation/${PN}-data-${PV} +" +BDEPEND="qt6? ( dev-qt/qttools:6 )" + +PATCHES=( + "${FILESDIR}/${PN}-2024.1.1-cmake.patch" + "${FILESDIR}/${PN}-2024.1.1-fix-fgpanel.patch" +) + +DOCS=(AUTHORS ChangeLog NEWS README Thanks) + +src_configure() { + # -Werror=lto-type-mismatch, -Werror=odr + # https://bugs.gentoo.org/859217 + # https://sourceforge.net/p/flightgear/codetickets/2908/ + filter-lto + + local mycmakeargs=( + -DBUILD_SHARED_LIBS=OFF + -DCHECK_FOR_QT5=OFF + -DCHECK_FOR_QT6=ON + -DENABLE_AUTOTESTING=OFF + -DENABLE_FGCOM=$(usex utils) + -DENABLE_FGELEV=$(usex utils) + -DENABLE_FGJS=$(usex utils) + -DENABLE_FGVIEWER=$(usex utils) + -DENABLE_GDAL=$(usex gdal) + -DENABLE_GPSSMOOTH=$(usex utils) + -DENABLE_HID_INPUT=$(usex udev) + -DENABLE_IAX=$(usex utils) + -DENABLE_JS_DEMO=$(usex utils) + -DENABLE_JSBSIM=ON + -DENABLE_LARCSIM=ON + -DENABLE_METAR=$(usex utils) + -DENABLE_PLIB_JOYSTICK=ON # NOTE look for defaults changes in CMake + -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_TRAFFIC=$(usex utils) + -DENABLE_UIUC_MODEL=ON + -DENABLE_VR=OFF + -DENABLE_YASIM=ON + -DEVENT_INPUT=$(usex udev) + -DFG_BUILD_TYPE=Nightly + -DFG_DATA_DIR=/usr/share/${PN} + -DJSBSIM_TERRAIN=ON + -DOSG_FSTREAM_EXPORT_FIXED=OFF # TODO also see simgear + -DSP_FDMS=ON + -DSYSTEM_CPPUNIT=OFF # NOTE we do not build tests anyway + -DSYSTEM_FLITE=OFF + -DSYSTEM_HTS_ENGINE=OFF + -DSYSTEM_SPEEX=ON + -DSYSTEM_GSM=ON + -DSYSTEM_SQLITE=ON + -DSYSTEM_OSGXR=ON + -DUSE_AEONWAVE=OFF + -DUSE_DBUS=$(usex dbus) + -DWITH_FGPANEL=$(usex utils) + ) + if use gdal && use utils; then + mycmakeargs+=(-DENABLE_DEMCONVERT=ON) + else + mycmakeargs+=(-DENABLE_DEMCONVERT=OFF) + fi + if use qt6 && use utils; then + mycmakeargs+=(-DENABLE_FGQCANVAS=ON) + else + mycmakeargs+=(-DENABLE_FGQCANVAS=OFF) + fi + + cmake_src_configure +} + +src_install() { + cmake_src_install + + # Install bash completion (TODO zsh) + # Uncomment below when scripts stops writing files... +# sed -e "s|/usr/local/share/FlightGear|${GAMES_DATADIR}/${PN}|" \ +# -i scripts/completion/fg-completion.bash || die 'unable to replace FG_ROOT' +# newbashcomp scripts/completion/fg-completion.bash ${PN} + + # Install examples and other misc files + if use examples; then + docompress -x /usr/share/doc/"${PF}"/{examples,tools} + docinto examples + dodoc -r scripts/java scripts/perl scripts/python + docinto examples/c++ + dodoc -r scripts/example/* + docinto tools + dodoc -r scripts/atis scripts/tools/* + fi + + # Install nasal script syntax + insinto /usr/share/vim/vimfiles/syntax + doins scripts/syntax/{ac3d,nasal}.vim + insinto /usr/share/vim/vimfiles/ftdetect/ + doins "${FILESDIR}"/{ac3d,nasal}.vim +} + +pkg_postinst() { + 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 new file mode 100644 index 000000000000..73bf7bd7b133 --- /dev/null +++ b/games-simulation/flightgear/metadata.xml @@ -0,0 +1,21 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "https://docs.baldeagleos.com/dtd/metadata.dtd"> +<pkgmetadata> + <maintainer type="project"> + <email>games@gentoo.org</email> + <name>Gentoo Games Project</name> + </maintainer> + <use> + <flag name="dbus">Enable screensaver DBus interaction</flag> + <flag name="gdal">Enable alternative terrain engine based on pagedLOD using <pkg>sci-libs/gdal</pkg> + </flag> + <flag name="qt6">Build Qt6 launcher application</flag> + <flag name="udev">Enable event-based Input devices through <pkg>virtual/udev</pkg> + </flag> + <flag name="utils">Build various utilities (fgpanel, fgviewer among others)</flag> + </use> + <upstream> + <remote-id type="cpe">cpe:/a:flightgear:flightgear</remote-id> + </upstream> + <origin>baldeagleos-repo</origin> +</pkgmetadata> diff --git a/games-simulation/gl117/Manifest b/games-simulation/gl117/Manifest new file mode 100644 index 000000000000..8d1db3b9506d --- /dev/null +++ b/games-simulation/gl117/Manifest @@ -0,0 +1,2 @@ +DIST gl-117-1.3.2-src.tar.bz2 2411075 BLAKE2B efd2c7b9dd3f71bf0b8b1aac79f90dcc6286301997913346f8ee536b3f5981564438e6a805c658678b5ae0402f84da762b60472ddc553cab49f9ffb421d69993 SHA512 1d2382576c6399d8c84d56ddc7eb2b11b9e1e3ffeebcc1bd30e258ef231626d15d1be649f8c791f30e4f2f78aca2b4290c5d08036c5f482eef01eda8f4f48b5f +DIST gl117.png 2274 BLAKE2B dfa2b8fe0e858e1f0fa1af27bd8e38d3bba55c31d4c26abe831cd08f01a9d198c2a38ec7c9c1c49af851da24cce692c489220624b93eae0ed4692139c73f8f7d SHA512 374b41af6cb5ec10e3b59b983f28206cb7bc88c3559a24332ef43bd4b135971c0541dbf6f3b5e97c7b7e329bc3d5bbfa5119b9be6cbec243193e5a4ac0220c3b diff --git a/games-simulation/gl117/files/gl117-1.3.2-mode.patch b/games-simulation/gl117/files/gl117-1.3.2-mode.patch new file mode 100644 index 000000000000..c63fdaa26074 --- /dev/null +++ b/games-simulation/gl117/files/gl117-1.3.2-mode.patch @@ -0,0 +1,13 @@ +https://bugs.gentoo.org/327965 +--- a/src/main.cpp ++++ b/src/main.cpp +@@ -71,8 +71,7 @@ int mode = 0; + + // pre-defined screen resolutions (x, y, bpp, fullscreen) + int resolution [4] [4] = +- { { 1024, 768, 32, 1 }, +- { 800, 600, 32, 1 }, ++ { { 800, 600, 32, 1 }, + { 640, 480, 32, 1 }, + { 640, 480, 32, 0 } }; + diff --git a/games-simulation/gl117/gl117-1.3.2-r1.ebuild b/games-simulation/gl117/gl117-1.3.2-r1.ebuild new file mode 100644 index 000000000000..ec55e38c8f27 --- /dev/null +++ b/games-simulation/gl117/gl117-1.3.2-r1.ebuild @@ -0,0 +1,41 @@ +# Copyright 1999-2026 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +inherit desktop + +MY_P="gl-117-${PV}-src" + +DESCRIPTION="Action flight simulator" +HOMEPAGE="https://sourceforge.net/projects/gl-117/" +SRC_URI=" + https://downloads.sourceforge.net/gl-117/${MY_P}.tar.bz2 + https://distfiles.gentoo.org/pub/dev/ionen@gentoo.org/${PN}.png" +S="${WORKDIR}/${MY_P}" + +LICENSE="GPL-2+" +SLOT="0" +KEYWORDS="~amd64 ~x86" + +RDEPEND=" + media-libs/freeglut + media-libs/libsdl[joystick,opengl,sound,video] + media-libs/sdl-mixer[mod] + virtual/glu + virtual/opengl" +DEPEND="${RDEPEND}" + +PATCHES=( + "${FILESDIR}"/${P}-mode.patch +) + +src_install() { + default + + doman doc/gl-117.6 + dodoc doc/gl-117.pdf + + doicon "${DISTDIR}"/${PN}.png + make_desktop_entry gl-117 GL-117 +} diff --git a/games-simulation/gl117/metadata.xml b/games-simulation/gl117/metadata.xml new file mode 100644 index 000000000000..183ecc5ceeeb --- /dev/null +++ b/games-simulation/gl117/metadata.xml @@ -0,0 +1,9 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "https://docs.baldeagleos.com/dtd/metadata.dtd"> +<pkgmetadata> + <maintainer type="project"> + <email>games@gentoo.org</email> + <name>Gentoo Games Project</name> + </maintainer> + <origin>baldeagleos-repo</origin> +</pkgmetadata> diff --git a/games-simulation/kittenspaceagency-bin/Manifest b/games-simulation/kittenspaceagency-bin/Manifest new file mode 100644 index 000000000000..9bf19a5676e4 --- /dev/null +++ b/games-simulation/kittenspaceagency-bin/Manifest @@ -0,0 +1 @@ +DIST setup_ksa_v2026.5.12.4510.tar.gz 2436022055 BLAKE2B 78acf20b555368931a4421d752e18b69ac262152dbf9d790949792dc73bdcf25621dd18162aed5440e711175216deda6a5bb75b903206ee9f263bfbb02e92c31 SHA512 6eb8fee1089c1b3b5f4534048988d90c3d4837e9e61ca3ec931e4b3cdc129157003db03be82a2b8485e2a55b559cd88e54d83171dada072bd0015b3519e2ce74 diff --git a/games-simulation/kittenspaceagency-bin/kittenspaceagency-bin-2026.5.12-r4510.ebuild b/games-simulation/kittenspaceagency-bin/kittenspaceagency-bin-2026.5.12-r4510.ebuild new file mode 100644 index 000000000000..3e77ab5af075 --- /dev/null +++ b/games-simulation/kittenspaceagency-bin/kittenspaceagency-bin-2026.5.12-r4510.ebuild @@ -0,0 +1,58 @@ +# Copyright 1999-2026 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +inherit desktop + +DESCRIPTION="A space flight and rocketry simulation" +HOMEPAGE="https://ksa.ahwoo.com" +SRC_URI=" + amd64? ( + setup_ksa_v${PV}.${PR#r}.tar.gz + ) +" +S="${WORKDIR}/linux-x64" +LICENSE="all-rights-reserved" + +SLOT="0" +KEYWORDS="-* ~amd64" + +RESTRICT="mirror strip fetch" + +BDEPEND="dev-util/patchelf" +RDEPEND=" + media-libs/vulkan-loader + virtual/dotnet-sdk:10.0 +" + +src_prepare() { + default + + # scanelf: rpath_security_checks(): Security problem NULL DT_RUNPATH in + # /var/tmp/portage/.../libRakNetDLL.so + patchelf --remove-rpath libRakNetDLL.so || die +} + +src_install() { + insinto "/opt/kittenspaceagency" + doins -r . + + exeinto "/opt/kittenspaceagency" + doexe "KSA" + doexe "Brutal.Monitor.Subprocess" + + cat > kittenspaceagency <<- 'ENDWRAPPER' || die + #!/usr/bin/env bash + + cd /opt/kittenspaceagency + XDG_SESSION_TYPE=x11 exec ./KSA "$@" + ENDWRAPPER + + dobin kittenspaceagency + + make_desktop_entry --eapi9 "/usr/bin/kittenspaceagency" \ + -d "kittenspaceagency" \ + -n "Kitten Space Agency" \ + -C "${DESCRIPTION}" +} diff --git a/games-simulation/kittenspaceagency-bin/metadata.xml b/games-simulation/kittenspaceagency-bin/metadata.xml new file mode 100644 index 000000000000..a91a1b954a63 --- /dev/null +++ b/games-simulation/kittenspaceagency-bin/metadata.xml @@ -0,0 +1,9 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "https://docs.baldeagleos.com/dtd/metadata.dtd"> +<pkgmetadata> + <maintainer type="project"> + <email>core@baldeagleos.com</email> + <name>Development</name> + </maintainer> + <origin>baldeagleos-repo</origin> +</pkgmetadata> diff --git a/games-simulation/lincity-ng/Manifest b/games-simulation/lincity-ng/Manifest new file mode 100644 index 000000000000..a50d5f3d40c8 --- /dev/null +++ b/games-simulation/lincity-ng/Manifest @@ -0,0 +1,2 @@ +DIST lincity-ng-2.13.1-Source.tar.xz 93133488 BLAKE2B 56142d7415fd858289f21d796ffcd7af9e26faabd012d985f2fd773000206764795ff1bb5f79e79c85d0950b3debe80627cf371018c015bbfbad0ee71c53a543 SHA512 8fe31744dbb25910510b72f35d530cf85c672ad2aaa7737bbd0a8a71f783a5e240b551ffd73dd7dbe1559e3be2a441dad7e882bf764ffcedceb06e1cdb43acc3 +DIST lincity-ng-2.9_beta.tar.gz 115799513 BLAKE2B 038c69172af9a62b35199823ef56200e170a8eafef2849bc6d8797bbc20ffa01656d05b1ba0725d4d33e217602f6695d3bdf2774b90b85c6e257e13e019bebcb SHA512 194b7389d7172b7987eda14cbbf2dd91aa503af36db9cf3bdf07ab6ae5e0068ac00988fec6068d65da6bdf14dee623bba57a58192e2a9659e741a7c9036e6d65 diff --git a/games-simulation/lincity-ng/files/lincity-ng-2.9_beta-flags.patch b/games-simulation/lincity-ng/files/lincity-ng-2.9_beta-flags.patch new file mode 100644 index 000000000000..1c960123c216 --- /dev/null +++ b/games-simulation/lincity-ng/files/lincity-ng-2.9_beta-flags.patch @@ -0,0 +1,10 @@ +--- a/Jamrules ++++ b/Jamrules +@@ -23,5 +23,4 @@ + case optimize : +- CFLAGS += -O3 -g -Wall ; +- CXXFLAGS += -O3 -g -Wall ; +- LIBS += -g ; ++ CFLAGS += -Wall ; ++ CXXFLAGS += -Wall ; + case debug : diff --git a/games-simulation/lincity-ng/lincity-ng-2.13.1.ebuild b/games-simulation/lincity-ng/lincity-ng-2.13.1.ebuild new file mode 100644 index 000000000000..63b785bf8122 --- /dev/null +++ b/games-simulation/lincity-ng/lincity-ng-2.13.1.ebuild @@ -0,0 +1,47 @@ +# Copyright 1999-2025 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +CMAKE_MAKEFILE_GENERATOR="emake" +inherit cmake xdg + +DESCRIPTION="City simulation game" +HOMEPAGE="https://github.com/lincity-ng/lincity-ng" + +if [[ ${PV} == 9999 ]] ; then + EGIT_REPO_URI="https://github.com/lincity-ng/lincity-ng" + inherit git-r3 +else + SRC_URI="https://github.com/lincity-ng/lincity-ng/releases/download/${P}/${P}-Source.tar.xz" + S="${WORKDIR}"/${P}-Source + + KEYWORDS="~amd64 ~x86" +fi + +LICENSE="GPL-2+ BitstreamVera CC-BY-SA-2.0" +SLOT="0" + +RDEPEND=" + dev-games/physfs + dev-libs/libxml2:2= + dev-cpp/libxmlpp:5.0= + media-libs/libsdl2[joystick,opengl,sound,video] + media-libs/sdl2-gfx + media-libs/sdl2-image[png] + media-libs/sdl2-mixer[vorbis] + media-libs/sdl2-ttf + virtual/zlib:= + virtual/opengl +" +DEPEND="${RDEPEND}" +BDEPEND=" + dev-libs/libxslt + sys-devel/gettext + virtual/pkgconfig +" + +src_configure(){ + local mycmakeargs=( -DCMAKE_BUILD_TYPE=Release ) + cmake_src_configure +} diff --git a/games-simulation/lincity-ng/lincity-ng-2.9_beta-r1.ebuild b/games-simulation/lincity-ng/lincity-ng-2.9_beta-r1.ebuild new file mode 100644 index 000000000000..2541130dacc2 --- /dev/null +++ b/games-simulation/lincity-ng/lincity-ng-2.9_beta-r1.ebuild @@ -0,0 +1,62 @@ +# Copyright 1999-2025 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +inherit autotools multiprocessing toolchain-funcs + +DESCRIPTION="City simulation game" +HOMEPAGE="https://github.com/lincity-ng/lincity-ng" +SRC_URI="https://github.com/lincity-ng/lincity-ng/archive/lincity-ng-${PV/_/-}.tar.gz -> ${P}.tar.gz" +S="${WORKDIR}/${PN}-${P/_/-}" + +LICENSE="GPL-2+ BitstreamVera CC-BY-SA-2.0" +SLOT="0" +KEYWORDS="~amd64 ~x86" + +RDEPEND=" + dev-games/physfs + dev-libs/libxml2:2= + media-libs/libsdl[joystick,opengl,sound,video] + media-libs/sdl-gfx + media-libs/sdl-image[png] + media-libs/sdl-mixer[vorbis] + media-libs/sdl-ttf + virtual/zlib:= + virtual/opengl" +DEPEND="${RDEPEND}" +BDEPEND=" + dev-libs/libxslt + dev-util/ftjam + sys-devel/gettext + virtual/pkgconfig" + +PATCHES=( + "${FILESDIR}"/${P}-flags.patch +) + +src_prepare() { + default + + AT_M4DIR=mk/autoconf eautoreconf + + # strip down autogen.sh / makerelease.sh for needed additional actions + sed -i -e '1a\set -e' -e '1n;/# generate Jam/,$!d;/^$/,$d' autogen.sh || die + sed -i -e '1a\set -e' -e '/^$/,$d' makerelease.sh || die + + ./autogen.sh || die "Failed to generate Jamconfig.in" + ./makerelease.sh || die "Failed to generate CREDITS" +} + +src_compile() { + tc-export CC RANLIB + export AR="$(tc-getAR) cru" #739376 + + jam -q -dx -j$(makeopts_jobs) || die +} + +src_install() { + jam -q -dx -sDESTDIR="${D}" -sPACKAGE_VERSION=${PVR} install || die + + rm "${ED}"/usr/share/doc/${PF}/COPYING* || die +} diff --git a/games-simulation/lincity-ng/lincity-ng-9999.ebuild b/games-simulation/lincity-ng/lincity-ng-9999.ebuild new file mode 100644 index 000000000000..2819381b27dc --- /dev/null +++ b/games-simulation/lincity-ng/lincity-ng-9999.ebuild @@ -0,0 +1,45 @@ +# Copyright 1999-2025 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +CMAKE_MAKEFILE_GENERATOR="emake" +inherit cmake xdg + +DESCRIPTION="City simulation game" +HOMEPAGE="https://github.com/lincity-ng/lincity-ng" + +if [[ ${PV} == 9999 ]] ; then + EGIT_REPO_URI="https://github.com/lincity-ng/lincity-ng" + inherit git-r3 +else + SRC_URI="https://github.com/lincity-ng/lincity-ng/releases/download/${P}/${P}-Source.tar.xz" + S="${WORKDIR}"/${P}-Source + + KEYWORDS="~amd64 ~x86" +fi + +LICENSE="GPL-2+ BitstreamVera CC-BY-SA-2.0" +SLOT="0" + +RDEPEND=" + dev-libs/libxml2:2= + dev-cpp/libxmlpp:5.0= + >=media-libs/libsdl2-2.0.18[joystick,opengl,sound,video] + >=media-libs/sdl2-image-2.0.0[png] + >=media-libs/sdl2-mixer-2.0.0[vorbis] + >=media-libs/sdl2-ttf-2.0.12 + >=virtual/zlib-1.0:= + virtual/opengl +" +DEPEND="${RDEPEND}" +BDEPEND=" + dev-libs/libxslt + sys-devel/gettext + virtual/pkgconfig +" + +src_configure(){ + local mycmakeargs=( -DCMAKE_BUILD_TYPE=Release ) + cmake_src_configure +} diff --git a/games-simulation/lincity-ng/metadata.xml b/games-simulation/lincity-ng/metadata.xml new file mode 100644 index 000000000000..183ecc5ceeeb --- /dev/null +++ b/games-simulation/lincity-ng/metadata.xml @@ -0,0 +1,9 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "https://docs.baldeagleos.com/dtd/metadata.dtd"> +<pkgmetadata> + <maintainer type="project"> + <email>games@gentoo.org</email> + <name>Gentoo Games Project</name> + </maintainer> + <origin>baldeagleos-repo</origin> +</pkgmetadata> diff --git a/games-simulation/lincity/Manifest b/games-simulation/lincity/Manifest new file mode 100644 index 000000000000..af8bf31433f1 --- /dev/null +++ b/games-simulation/lincity/Manifest @@ -0,0 +1,2 @@ +DIST lincity-1.13.1.tar.gz 1064236 BLAKE2B 1172ced3255048f3132f85cd9ae994c7e0558170f7e7a24909af1856669c4ad90d57acd76f330fb556656ed74843dda159005350760fc059c6b184cedf1e9393 SHA512 bc4ee7a1642b1efa25f9edaabd3aeb52d1ca1d016735c5094586f52fda3ec4e9080ff35fe518c1ccbfad9fd54babb370f4b9b6a158b4d2f43b7182155084eefc +DIST lincity.png 5377 BLAKE2B 2238140719a8c1b094fbe6d7b52b9224245f2c36f970e04aa3fcaf6090409145f17dad2c2a83f6528e695fd9d26d9c053c45978502b7e44f73cf25719d7ed3aa SHA512 40a8955fdc8397662ef0d084163e7dcad59e278429792bd7096e193a0d04791c2355a0dbd2c1f72a032bbfc71bc4e27e37a3d0d4e82de8e7170bb70205d983a3 diff --git a/games-simulation/lincity/files/lincity-1.13.1-Fix-prototypes-and-implicit-function-declarations.patch b/games-simulation/lincity/files/lincity-1.13.1-Fix-prototypes-and-implicit-function-declarations.patch new file mode 100644 index 000000000000..98d8d8750fcb --- /dev/null +++ b/games-simulation/lincity/files/lincity-1.13.1-Fix-prototypes-and-implicit-function-declarations.patch @@ -0,0 +1,270 @@ +From 91953cf63f9e0a20ea37d7fc4780ee3c5d9fd917 Mon Sep 17 00:00:00 2001 +From: Sam James <sam@gentoo.org> +Date: Sun, 23 Oct 2022 13:47:33 +0100 +Subject: [PATCH] Fix prototypes and implicit function declarations + +Bug: https://bugs.gentoo.org/874723 +--- + dialbox.h | 2 +- + engine.c | 2 +- + fileutil.c | 1 + + ldsvgui.c | 2 +- + module_buttons.c | 2 +- + mouse.c | 6 ++++-- + mouse.h | 2 +- + mps.c | 2 +- + mps.h | 2 +- + pbar.c | 4 ++-- + pixmap.c | 2 +- + power.c | 4 ++-- + power.h | 2 +- + screen.c | 8 ++++---- + 14 files changed, 22 insertions(+), 19 deletions(-) + +diff --git a/dialbox.h b/dialbox.h +index 1e4f21b..0d3fa76 100644 +--- a/dialbox.h ++++ b/dialbox.h +@@ -22,7 +22,7 @@ typedef struct dialog_box_struct Dialog_Box; + + /* Public functions */ + int dialog_box(int colour, int argc, ...); +-void dialog_refresh(); ++void dialog_refresh(void); + void dialog_close(int return_value); + + #define MAX_DBOX_ENTRIES 64 /* Huge, but necessary for current use */ +diff --git a/engine.c b/engine.c +index 7c088f3..03b3998 100644 +--- a/engine.c ++++ b/engine.c +@@ -470,7 +470,7 @@ sell_steel (int xt, int yt) + } + + void +-do_pollution () ++do_pollution (void) + { + int x, p; + int* pol = &map.pollution[0][0]; +diff --git a/fileutil.c b/fileutil.c +index 2fd6f3d..b4bf244 100644 +--- a/fileutil.c ++++ b/fileutil.c +@@ -9,6 +9,7 @@ + #include <stdarg.h> /* XXX: GCS FIX: What does configure need to know? */ + #include "lcintl.h" + #include "lcstring.h" ++#include "lcsvga.h" + #include "ldsvgui.h" + + /* XXX: Where are SVGA specific includes? */ +diff --git a/ldsvgui.c b/ldsvgui.c +index a9c8126..f783e60 100644 +--- a/ldsvgui.c ++++ b/ldsvgui.c +@@ -277,7 +277,7 @@ do_network_screen (void) + #endif + + void +-do_save_city () ++do_save_city (void) + { + Rect* mw = &scr.main_win; + char s[200], c; +diff --git a/module_buttons.c b/module_buttons.c +index 1bf77cd..51c746d 100644 +--- a/module_buttons.c ++++ b/module_buttons.c +@@ -465,7 +465,7 @@ unhighlight_module_button (int module) + /* draw_selected_module_cost: write info about the module to the status area */ + + void +-draw_selected_module_cost () ++draw_selected_module_cost (void) + { + Rect* b = &scr.select_message; + char s[100]; +diff --git a/mouse.c b/mouse.c +index aaba144..85ca571 100644 +--- a/mouse.c ++++ b/mouse.c +@@ -46,6 +46,8 @@ static Mouse_Handle * mhandle_first; + static Mouse_Handle * mhandle_last; + static Mouse_Handle * mhandle_current; + ++int mode(int x, int y); ++ + /* ---------------------------------------------------------------------- * + * cs_mouse_handler + * -- +@@ -1152,7 +1154,7 @@ mt_perm(int x, int y) + } + + int +-do_mt_draw (int x1, int x2, int y1, int y2, int (*mode)()) ++do_mt_draw (int x1, int x2, int y1, int y2, int (*mode)(int x, int y)) + { + int dir = 1; + int horiz = 1; +@@ -1321,7 +1323,7 @@ cmp(int n1, int n2) + } + + void +-init_mouse_registry() ++init_mouse_registry(void) + { + mhandle_first = NULL; + mhandle_last = NULL; +diff --git a/mouse.h b/mouse.h +index b31721b..0d87072 100644 +--- a/mouse.h ++++ b/mouse.h +@@ -48,7 +48,7 @@ struct mouse_button_struct { + /* Public functions */ + + void mouse_setup (void); +-void init_mouse_registry(); ++void init_mouse_registry(void); + int mouse_handle_click(int x, int y, int button); + + Mouse_Handle * mouse_register(Rect * r, void (*handler)(int, int, int)); +diff --git a/mps.c b/mps.c +index 3b82f1e..79f787b 100644 +--- a/mps.c ++++ b/mps.c +@@ -61,7 +61,7 @@ mps_handler(int x, int y, int button) + /* mps_init(): Initialize mps vars and mouse handles */ + + void +-mps_init() ++mps_init(void) + { + mps_style = MPS_GLOBAL; + mps_global_style = MPS_GLOBAL_FINANCE; +diff --git a/mps.h b/mps.h +index 49991be..98c37c1 100644 +--- a/mps.h ++++ b/mps.h +@@ -27,7 +27,7 @@ void mappoint_stats (int, int, int); + + #define MPS_INFO_CHARS (MAPPOINT_STATS_W / 8) + 1 + +-void mps_init(); ++void mps_init(void); + + int mps_set(int style, int x, int y); /* Attaches an area or global display */ + void mps_redraw(void); /* Re-draw the mps area, bezel and all */ +diff --git a/pbar.c b/pbar.c +index 0d518d1..41ec319 100644 +--- a/pbar.c ++++ b/pbar.c +@@ -241,7 +241,7 @@ update_pbar (int pbar_num, int value, int month_flag) + } + + void +-update_pbars_daily() ++update_pbars_daily(void) + { + update_pbar (PPOP, housed_population + people_pool, 0); + update_pbar (PTECH, tech_level, 0); +@@ -255,7 +255,7 @@ update_pbars_daily() + } + + void +-update_pbars_monthly() ++update_pbars_monthly(void) + { + update_pbar (PPOP, housed_population + people_pool, 1); + update_pbar (PTECH, tech_level, 1); +diff --git a/pixmap.c b/pixmap.c +index a1f1b68..b6806d3 100644 +--- a/pixmap.c ++++ b/pixmap.c +@@ -43,7 +43,7 @@ int pixmap_width = 0; + * ---------------------------------------------------------------------- */ + #ifdef USE_PIXMAPS + void +-init_pixmaps () ++init_pixmaps (void) + { + int i; + for (i = 1; i < NUM_OF_TYPES; i++) { +diff --git a/power.c b/power.c +index b428489..8392676 100644 +--- a/power.c ++++ b/power.c +@@ -34,7 +34,7 @@ Grid * grid[MAX_GRIDS]; + first-served basis. + */ + void +-power_time_step () ++power_time_step (void) + { + int gi; + int net; /* net power */ +@@ -65,7 +65,7 @@ power_time_step () + + + void +-map_power_grid () ++map_power_grid (void) + { + int mapx, mapy; + grid_num = 0; /* how many grids found so far */ +diff --git a/power.h b/power.h +index 8aeecdc..020bff7 100644 +--- a/power.h ++++ b/power.h +@@ -25,7 +25,7 @@ void do_power_substation(int x, int y); + void do_power_source(int x, int y); + void do_power_source_coal(int x, int y); + void do_power_line(int x, int y); +-void power_time_step (); ++void power_time_step (void); + + /* intended private */ + void recurse_power_grid (int startx, int starty, int steps); +diff --git a/screen.c b/screen.c +index 73e60a7..03eeae6 100644 +--- a/screen.c ++++ b/screen.c +@@ -72,7 +72,7 @@ static void do_history_linegraph (int draw); + static void do_sust_barchart (int draw); + static void draw_sustline (int yoffset, int count, int max, int col); + void monthgraph_full_refresh (void); +-void draw_mini_pol_in_main_win (); ++void draw_mini_pol_in_main_win (void); + void mini_full_refresh (void); + void update_main_screen_normal (int full_refresh); + void update_main_screen_pollution (void); +@@ -124,7 +124,7 @@ refresh_main_screen (void) + } + + void +-clip_main_window () ++clip_main_window (void) + { + Rect* b = &scr.main_win; + Fgl_enableclipping (); +@@ -132,7 +132,7 @@ clip_main_window () + } + + void +-unclip_main_window () ++unclip_main_window (void) + { + Fgl_disableclipping (); + } +@@ -789,7 +789,7 @@ draw_small_yellow_bezel (int x, int y, int h, int w) + } + + void +-load_fonts() ++load_fonts(void) + { + char s[LC_PATH_MAX]; + int i; +-- +2.38.1 + diff --git a/games-simulation/lincity/files/lincity-1.13.1-build.patch b/games-simulation/lincity/files/lincity-1.13.1-build.patch new file mode 100644 index 000000000000..a5244b5387f3 --- /dev/null +++ b/games-simulation/lincity/files/lincity-1.13.1-build.patch @@ -0,0 +1,52 @@ +--- a/mouse.c ++++ b/mouse.c +@@ -1057,7 +1057,7 @@ + and set to 1 if the existing transport if the more expensive sort + (e.g. GROUP_RAIL when overwriting GROUP_ROAD). + */ +-inline int ++int + mt_erase(int x, int y) + { + if (x < 0 || y < 0 || x >= WORLD_SIDE_LEN || y >= WORLD_SIDE_LEN) +--- a/pixmap.c ++++ b/pixmap.c +@@ -390,7 +390,7 @@ + likes it in the file. Still need to fix this in autoconf, + but for now this will do. */ + #if !defined (WIN32) +-inline int ++int + pixmap_index (int x, int y) + { + return y*pixmap_width + x; +--- a/pixmap.h ++++ b/pixmap.h +@@ -19,7 +19,7 @@ + void initialize_pixmap (void); + void resize_pixmap (int new_width, int new_height); + int pixmap_getpixel (int x, int y); +-inline int pixmap_index (int x, int y); ++int pixmap_index (int x, int y); + int pixmap_getpixel (int x, int y); + void pixmap_setpixel (int x, int y, int col); + void pixmap_hline (int x1, int y1, int x2, int col); +@@ -33,7 +33,7 @@ + * Public Inline Functions + * ---------------------------------------------------------------------- */ + #if defined (WIN32) +-inline int ++int + pixmap_index (int x, int y) { + return y*pixmap_width + x; + } +--- a/readpng.c ++++ b/readpng.c +@@ -3,6 +3,7 @@ + * This file is part of lincity (see COPYRIGHT for copyright information). + * ---------------------------------------------------------------------- */ + #include <stdlib.h> ++#include <string.h> + #include "png.h" + #include "malloc.h" + #include "lin-city.h" diff --git a/games-simulation/lincity/files/lincity-1.13.1-gcc-10.patch b/games-simulation/lincity/files/lincity-1.13.1-gcc-10.patch new file mode 100644 index 000000000000..a1d6ea0f2e70 --- /dev/null +++ b/games-simulation/lincity/files/lincity-1.13.1-gcc-10.patch @@ -0,0 +1,69 @@ +https://bugs.gentoo.org/570574 +https://bugs.gentoo.org/706394 + +--- a/fileutil.c ++++ b/fileutil.c +@@ -105,7 +105,7 @@ + * ---------------------------------------------------------------------- */ + char LIBDIR[LC_PATH_MAX]; + +-char *lc_save_dir; ++extern char *lc_save_dir; + int lc_save_dir_len; + static char *lc_temp_filename; + +--- a/ldsvguts.c ++++ b/ldsvguts.c +@@ -91,8 +91,6 @@ + * Private Global Variables + * ---------------------------------------------------------------------- */ + +-char save_names[10][42]; +- + /* ---------------------------------------------------------------------- * + * Public functions + * ---------------------------------------------------------------------- */ +--- a/main.c ++++ b/main.c +@@ -96,9 +96,8 @@ + #endif + #endif + +-char *lc_save_dir; ++extern char *lc_save_dir; + char *lc_temp_file; +-char save_names[10][42]; + + #ifdef CS_PROFILE + int prof_countdown = PROFILE_COUNTDOWN; +--- a/mouse.c ++++ b/mouse.c +@@ -1094,7 +1094,7 @@ + return 0; + } + +-inline int ++static inline int + mt_temp(int x, int y) + { + if (x < 0 || y < 0 || x >= WORLD_SIDE_LEN || y >= WORLD_SIDE_LEN) +@@ -1128,7 +1128,7 @@ + return 0; + } + +-inline int ++static inline int + mt_perm(int x, int y) + { + /* By now, it has already been mt_erase()'d */ +--- a/screen.h ++++ b/screen.h +@@ -20,7 +20,7 @@ + extern unsigned char start_font2[4096]; + extern unsigned char start_font3[4096]; + +-int monthgraph_style; ++extern int monthgraph_style; + + /* This is on in screen_full_refresh, used in *_refresh() */ + extern char screen_refreshing; diff --git a/games-simulation/lincity/lincity-1.13.1-r4.ebuild b/games-simulation/lincity/lincity-1.13.1-r4.ebuild new file mode 100644 index 000000000000..106cf2ee04bb --- /dev/null +++ b/games-simulation/lincity/lincity-1.13.1-r4.ebuild @@ -0,0 +1,71 @@ +# Copyright 1999-2026 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +inherit autotools flag-o-matic desktop + +DESCRIPTION="City simulation game for X" +HOMEPAGE="https://lincity.sourceforge.net/" +SRC_URI=" + https://downloads.sourceforge.net/lincity/${P}.tar.gz + https://distfiles.gentoo.org/pub/dev/ionen@gentoo.org/${PN}.png" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="~amd64 ~x86" + +RDEPEND=" + media-libs/libpng:= + virtual/libintl + x11-libs/libXext" +DEPEND=" + ${RDEPEND} + x11-base/xorg-proto" +BDEPEND="sys-devel/gettext" + +PATCHES=( + "${FILESDIR}"/${P}-build.patch + "${FILESDIR}"/${P}-gcc-10.patch + "${FILESDIR}"/${P}-Fix-prototypes-and-implicit-function-declarations.patch +) + +src_prepare() { + default + + # Clang 16, bug #899020 + eautoreconf +} + +src_configure() { + # bug #859220 + filter-lto + + local econfargs=( + --with-gzip + --with-x + --without-svga + ac_cv_lib_ICE_IceConnectionNumber=no # not actually used + ) + + econf "${econfargs[@]}" +} + +src_compile() { + emake + emake X_PROGS +} + +src_install() { + default + + dobin x${PN} + + newman {,x}${PN}.6 + rm "${ED}"/usr/share/man/man6/${PN}.6 + + dodoc Acknowledgements + + doicon "${DISTDIR}"/${PN}.png + make_desktop_entry x${PN} ${PN^} +} diff --git a/games-simulation/lincity/metadata.xml b/games-simulation/lincity/metadata.xml new file mode 100644 index 000000000000..183ecc5ceeeb --- /dev/null +++ b/games-simulation/lincity/metadata.xml @@ -0,0 +1,9 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "https://docs.baldeagleos.com/dtd/metadata.dtd"> +<pkgmetadata> + <maintainer type="project"> + <email>games@gentoo.org</email> + <name>Gentoo Games Project</name> + </maintainer> + <origin>baldeagleos-repo</origin> +</pkgmetadata> diff --git a/games-simulation/metadata.xml b/games-simulation/metadata.xml new file mode 100644 index 000000000000..d580c15ec911 --- /dev/null +++ b/games-simulation/metadata.xml @@ -0,0 +1,31 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE catmetadata SYSTEM "https://www.gentoo.org/dtd/metadata.dtd"> +<catmetadata> + <longdescription lang="en"> + The games-simulation category contains simulation games. + </longdescription> + <longdescription lang="de"> + Die Kategorie games-simulation enthält Simulatoren. + </longdescription> + <longdescription lang="es"> + La categoría games-simulation contiene juegos de simulación. + </longdescription> + <longdescription lang="ja"> + games-simulationカテゴリーにはシミュレーション・ゲームが含まれています。 + </longdescription> + <longdescription lang="nl"> + De games-simulation categorie bevat simulatiespellen. + </longdescription> + <longdescription lang="vi"> + Nhóm games-simulation chứa các trò chơi mô phỏng. + </longdescription> + <longdescription lang="it"> + La categoria games-simulation contiene giochi di simulazione. + </longdescription> + <longdescription lang="pt"> + A categoria games-simulation contém jogos de simulação. + </longdescription> + <longdescription lang="pl"> + Kategoria games-simulation zawiera gry symulacyjne. + </longdescription> +</catmetadata> diff --git a/games-simulation/micropolis/Manifest b/games-simulation/micropolis/Manifest new file mode 100644 index 000000000000..357f66c52fd3 --- /dev/null +++ b/games-simulation/micropolis/Manifest @@ -0,0 +1,2 @@ +DIST micropolis-176c45720f3b9e5555fe1084d3e6ea59488c1785.tar.bz2 4110965 BLAKE2B 38f7ae9e91c862460faf7417dac7e3a9eabf51f3e4ba0c804c47c1190fba8c74cc31c9cd9d6132f01af4fbc1b6df47c1ed9fa16b439267bd7293ee8048193b9d SHA512 8ef1ed48efacd0803a6cb4055e9c2ac6f1bd051beef73360cc3ae4d8f4b8d9824730ca6a1f989534d83f4961b2e249a8fb3cb4eb7138e9bd765325f9a2ebb98e +DIST micropolis-c24fb94b88efa4689338543a8f7bb046fe5a1aaf.tar.bz2 4110292 BLAKE2B 4b82bef0a2e8eb61a179fff7ebe919e0d32c3a49c4db635771f6b7ead1feb630dce4323dbc0de99627c3c4b654607313c5e38ce8b954875fd91dd67b10ae4ca5 SHA512 f2ee6e7900df881b8b95d804bc622f19ad94e91eeae53da7d51fcd9833503578f6d1643acdd538f0e81a15727c4a3078b6f5ecad86a6b37c4b37018ddcf1b4da diff --git a/games-simulation/micropolis/metadata.xml b/games-simulation/micropolis/metadata.xml new file mode 100644 index 000000000000..bfe7432d5d57 --- /dev/null +++ b/games-simulation/micropolis/metadata.xml @@ -0,0 +1,12 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "https://docs.baldeagleos.com/dtd/metadata.dtd"> +<pkgmetadata> + <maintainer type="person"> + <email>hanno@gentoo.org</email> + </maintainer> + <maintainer type="project"> + <email>games@gentoo.org</email> + <name>Gentoo Games Project</name> + </maintainer> + <origin>baldeagleos-repo</origin> +</pkgmetadata> diff --git a/games-simulation/micropolis/micropolis-1.0_p20250628.ebuild b/games-simulation/micropolis/micropolis-1.0_p20250628.ebuild new file mode 100644 index 000000000000..a770766b1e30 --- /dev/null +++ b/games-simulation/micropolis/micropolis-1.0_p20250628.ebuild @@ -0,0 +1,61 @@ +# Copyright 1999-2025 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +inherit desktop flag-o-matic toolchain-funcs wrapper + +COMMIT="176c45720f3b9e5555fe1084d3e6ea59488c1785" +DESCRIPTION="Free version of the well-known city building simulation" +HOMEPAGE="https://www.donhopkins.com/home/micropolis/" +SRC_URI="https://gitlab.com/stargo/micropolis/-/archive/${COMMIT}/micropolis-${COMMIT}.tar.bz2" +S="${WORKDIR}/${PN}-${COMMIT}" + +LICENSE="GPL-3+" +SLOT="0" +KEYWORDS="~amd64 ~x86" + +RDEPEND=" + media-libs/libsdl + media-libs/sdl-mixer + x11-libs/libX11 + x11-libs/libXpm" +DEPEND="${RDEPEND}" +BDEPEND="app-alternatives/yacc" + +# parallel build is broken +MAKEOPTS="-j1" + +src_prepare() { + default + + # -Werror=strict-aliasing + # https://bugs.gentoo.org/859223 + # https://gitlab.com/stargo/micropolis/-/issues/1 + # + # Do not trust with LTO either. + append-flags -fno-strict-aliasing + filter-lto + + sed -i -e "s|-O3|${CFLAGS}|" \ + src/tclx/config.mk src/{sim,tcl,tk}/makefile || die + sed -i -e "s|XLDFLAGS=|&${LDFLAGS}|" \ + src/tclx/config.mk || die +} + +src_compile() { + emake -C src LDFLAGS="${LDFLAGS}" CC="$(tc-getCC)" +} + +src_install() { + local dir=/usr/share/${PN} + + exeinto "${dir}/res" + doexe src/sim/sim + insinto "${dir}" + doins -r activity cities images manual res + + make_wrapper micropolis res/sim "${dir}" + doicon Micropolis.png + make_desktop_entry micropolis "Micropolis" Micropolis +} diff --git a/games-simulation/micropolis/micropolis-1.0_p20250710.ebuild b/games-simulation/micropolis/micropolis-1.0_p20250710.ebuild new file mode 100644 index 000000000000..ff6f00543d55 --- /dev/null +++ b/games-simulation/micropolis/micropolis-1.0_p20250710.ebuild @@ -0,0 +1,61 @@ +# Copyright 1999-2026 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +inherit desktop flag-o-matic toolchain-funcs wrapper + +COMMIT="c24fb94b88efa4689338543a8f7bb046fe5a1aaf" +DESCRIPTION="Free version of the well-known city building simulation" +HOMEPAGE="https://www.donhopkins.com/home/micropolis/" +SRC_URI="https://gitlab.com/stargo/micropolis/-/archive/${COMMIT}/micropolis-${COMMIT}.tar.bz2" +S="${WORKDIR}/${PN}-${COMMIT}" + +LICENSE="GPL-3+" +SLOT="0" +KEYWORDS="~amd64 ~x86" + +RDEPEND=" + media-libs/libsdl + media-libs/sdl-mixer + x11-libs/libX11 + x11-libs/libXpm" +DEPEND="${RDEPEND}" +BDEPEND="app-alternatives/yacc" + +# parallel build is broken +MAKEOPTS="-j1" + +src_prepare() { + default + + # -Werror=strict-aliasing + # https://bugs.gentoo.org/859223 + # https://gitlab.com/stargo/micropolis/-/issues/1 + # + # Do not trust with LTO either. + append-flags -fno-strict-aliasing + filter-lto + + sed -i -e "s|-O3|${CFLAGS}|" \ + src/tclx/config.mk src/{sim,tcl,tk}/makefile || die + sed -i -e "s|XLDFLAGS=|&${LDFLAGS}|" \ + src/tclx/config.mk || die +} + +src_compile() { + emake -C src LDFLAGS="${LDFLAGS}" CC="$(tc-getCC)" +} + +src_install() { + local dir=/usr/share/${PN} + + exeinto "${dir}/res" + doexe src/sim/sim + insinto "${dir}" + doins -r activity cities images manual res + + make_wrapper micropolis res/sim "${dir}" + doicon Micropolis.png + make_desktop_entry micropolis "Micropolis" Micropolis +} diff --git a/games-simulation/openrct2/Manifest b/games-simulation/openrct2/Manifest new file mode 100644 index 000000000000..b1f7be9e7dda --- /dev/null +++ b/games-simulation/openrct2/Manifest @@ -0,0 +1,8 @@ +DIST openrct2-0.4.32.tar.gz 24694264 BLAKE2B 6385834c18cb6986c788fdcd724b67807b2abb657e0deb368ee24fbeb33f77551d04ece325562d827437088aa25fc806a67d0bc35edbac0c7303121cc168cbd8 SHA512 f7f0fda752567dd16d76639b47dc26da0c3239619145ced6dc8e0619d19b69ed5e56ea2fb902d530ae1aad79e74eec3c9dad019735800cb1c7a6f2b43b424879 +DIST openrct2-0.5.0.tar.gz 24635481 BLAKE2B 0b2799a42c7ab573a8ecf8a83c4c8121a74338e6864ba7995aa543e9e1b2c8d9385abc040b9d39769b61cee6da66bcb7822326dcd45e89a3e9e2d2613275d1b5 SHA512 1ebd20b3c1243290dbf244770851948de0ef50e72c37d79b161ad6b384d84eb61ae4dd3b18f7b47b3c5d7e949d141fcc2c300b5cc616782ce98a87e4b23725d4 +DIST openrct2-objects-1.7.6.zip 11027399 BLAKE2B aa291cb408a5739f3678df904cbe7146628c3918b87acc64ec77f5ce78116a3e6c64a1ff82fb1fa2e8cd241007b0d071b3fc33c173f753a633d0da9462fa61d9 SHA512 3149a0ef91bc5679d808157e41b8fcdb0bff01ddb0e070d3e4e5c8e9cd4cecd4eec17b76d4fa4a442130e004a3192636e504a0c39ff8ef333e36e0c44d988cd8 +DIST openrct2-objects-1.7.9.zip 11062251 BLAKE2B 9f1fe0b384e039c65f8894346aa9edce9ee2849292eaaa920ddd161f9aaa4cad212a3b61c4548a41c68a14dc163eefce24d260459fc0c0e465252a845e8c4b3c SHA512 a2ca05ab0dd3dc30ad365085b6b4006a77c9aa45c780be8294a9cb1184e512dd278a8038213606a3193836bca4a77f8f76a9a8d11b8e337f9158b6205c22d5dd +DIST openrct2-openmusic-1.6.1.zip 42921420 BLAKE2B cdec26dda1797b27a57d0ffd87c44c740869dff8cffc1ac077d6ce1eee747d32ce09547dc9a70256106b48126e08f04c04668c7fb8b3df2e04db72ef5f0cc344 SHA512 bc524b20ab72696a5f38bd65d96a4a83f29a0e65884d9b847540631d31aae42f3bdc4a6db5fa5fe34869012e598543b9327ad92d34e8f4f0f274c7f04d4a2e7f +DIST openrct2-opensound-1.0.6.zip 4273495 BLAKE2B ae92336d8b4a1793a01dda701a2bfdbd5efad285029d6c199f657caaade3a6341c2cb7f1a4a9f420e399b6a7763ed2a50a4c2663dadfea3e3079e374b8d2f707 SHA512 8ae2d31687c29cfcdc7630da5addc3bed4b94ed1712891bb1e22d2747f2f8435b7fda843b4490543dbd9d63d392c8b3e4863cd3e669df9ca34f9780c8d9e5485 +DIST openrct2-replays-0.0.92.zip 1356796 BLAKE2B 39288339151b7fde605f9c9d036f39959e5525fe1d7a234b58b1ec453b45eb8d220a74f784f00d6d6a203fb14aff101bed8b860abc6e49b539206b9038cd6b38 SHA512 8ab2f6a776191c869adec69f1d014fd3b18c17492b9f767a62b8bb3c4aa74b6f527e0e721f18df838b6a9f82a24036c3ed2726da6469744b72b11785201fadf5 +DIST openrct2-title-sequences-0.4.26.zip 8751039 BLAKE2B d01ae8952f482c34166e593f774c0e195daa1586d295a0129ecbae2d59e3d8d5cac18640041eece3f72a223cc19cbf62a9a367dcb1355db7b7cfc32f9d07692e SHA512 7faa5afcebd0f95e184862bcb77f3ef41b59b900ad55eadbf4373b16fac315470734a854a4bd15496e832478ca0de6ea6f8f42f20c8f5d8f0403cbaae71338c5 diff --git a/games-simulation/openrct2/files/README.gentoo b/games-simulation/openrct2/files/README.gentoo new file mode 100644 index 000000000000..7e5fc8c65857 --- /dev/null +++ b/games-simulation/openrct2/files/README.gentoo @@ -0,0 +1,15 @@ +OpenRCT2 needs the original RollerCoaster Tycoon 2 data files." + +You need the folders 'Data', 'ObjData', 'Scenarios' and 'Tracks'" +from the original release and copy them into '/usr/share/openrct2/rct2_data'." + +For additional content, you can install the RollerCoaster Tycoon 1 data files." + +You need the folders 'Data', 'Scenarios' and 'Tracks'" +from the original release and copy them into '/usr/share/openrct2/rct1_data'." + +Optionally, the paths can be overwritten by the parameters" +'game_path' and 'rct1_path' in your local ~/.config/OpenRCT2/config.ini file." + +See: https://github.com/OpenRCT2/OpenRCT2/wiki/Required-RCT2-files" +See: https://github.com/OpenRCT2/OpenRCT2/wiki/Loading-RCT1-scenarios-and-data" diff --git a/games-simulation/openrct2/files/openrct2-0.4.1-gtest-1.10.patch b/games-simulation/openrct2/files/openrct2-0.4.1-gtest-1.10.patch new file mode 100644 index 000000000000..1a9eba0fb3e3 --- /dev/null +++ b/games-simulation/openrct2/files/openrct2-0.4.1-gtest-1.10.patch @@ -0,0 +1,8 @@ +--- a/test/tests/ReplayTests.cpp ++++ b/test/tests/ReplayTests.cpp +@@ -115,4 +115,5 @@ + } + }; + ++GTEST_ALLOW_UNINSTANTIATED_PARAMETERIZED_TEST(ReplayTests); + INSTANTIATE_TEST_SUITE_P(Replay, ReplayTests, testing::ValuesIn(GetReplayFiles()), PrintReplayParameter()); diff --git a/games-simulation/openrct2/files/openrct2-0.4.16-include-additional-paths.patch b/games-simulation/openrct2/files/openrct2-0.4.16-include-additional-paths.patch new file mode 100644 index 000000000000..4391ea90e00b --- /dev/null +++ b/games-simulation/openrct2/files/openrct2-0.4.16-include-additional-paths.patch @@ -0,0 +1,18 @@ +--- a/src/openrct2/platform/Platform.Linux.cpp ++++ b/src/openrct2/platform/Platform.Linux.cpp +@@ -336,6 +336,7 @@ + std::vector<std::string_view> GetSearchablePathsRCT1() + { + return { ++ "/usr/share/openrct2/rct1_data", + // game-data-packager uses this path when installing game files + "/usr/share/games/roller-coaster-tycoon", + }; +@@ -344,6 +345,7 @@ + std::vector<std::string_view> GetSearchablePathsRCT2() + { + return { ++ "/usr/share/openrct2/rct2_data", + // game-data-packager uses this path when installing game files + "/usr/share/games/roller-coaster-tycoon2", + }; diff --git a/games-simulation/openrct2/files/openrct2.confd b/games-simulation/openrct2/files/openrct2.confd new file mode 100644 index 000000000000..cdc414542d26 --- /dev/null +++ b/games-simulation/openrct2/files/openrct2.confd @@ -0,0 +1,11 @@ +# Copyright 1999-2019 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +# Name of the OpenRCT2 scenario file, +# which will be used by the dedicated server. +# It needs to be placed in '/var/lib/openrct2/<instance>/scenario'. +# The default instance is 'main'. +OPENRCT2_SCENARIO_FILE="scenario.sc6" + +# Options, which can be passed to the dedicated server. +OPENRCT2_OPTS="--port 11753" diff --git a/games-simulation/openrct2/files/openrct2.initd b/games-simulation/openrct2/files/openrct2.initd new file mode 100644 index 000000000000..de95158a68e7 --- /dev/null +++ b/games-simulation/openrct2/files/openrct2.initd @@ -0,0 +1,41 @@ +#!/sbin/openrc-run +# Copyright 1999-2019 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +if [ "${SVCNAME}" = "openrct2" ]; then + instance="main" +else + instance="${SVCNAME#*.}" +fi + +openrct2_command="/usr/bin/openrct2-cli" +openrct2_path="/var/lib/openrct2" +openrct2_path_instance="${openrct2_path}/${instance}" +openrct2_path_scenario="${openrct2_path_instance}/scenario" +name="OpenRCT2 server (${instance})" +pidfile="/run/openrct2-cli.${instance}.pid" +start_stop_daemon_args="--chdir ${openrct2_path_instance}" + +command="/usr/bin/openrct2-cli" +command_args="host \"${openrct2_path_scenario}/${OPENRCT2_SCENARIO_FILE}\" --headless --user-data-path ${openrct2_path_instance} ${OPENRCT2_OPTS}" +command_background="true" +command_group="openrct2" +command_user="openrct2" + +depend() { + use net +} + +start_pre() { + checkpath -d -o "${command_user}:${command_group}" -q "${openrct2_path}" "${openrct2_path_instance}" "${openrct2_path_scenario}" + + if [ ! -f "${openrct2_path_scenario}/${OPENRCT2_SCENARIO_FILE}" ]; then + eerror "The scenario ${openrct2_path_scenario}/${OPENRCT2_SCENARIO_FILE} could not be found!" + eerror "An OpenRCT2 scenario file is needed by the dedicated server." + eerror "Please check, if OPENRCT2_SCENARIO is configured correctly." + return 1 + else + checkpath -f -o "${command_user}:${command_group}" -q "${openrct2_path_scenario}/${OPENRCT2_SCENARIO_FILE}" + return 0 + fi +} diff --git a/games-simulation/openrct2/metadata.xml b/games-simulation/openrct2/metadata.xml new file mode 100644 index 000000000000..217c3cc25786 --- /dev/null +++ b/games-simulation/openrct2/metadata.xml @@ -0,0 +1,24 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "https://docs.baldeagleos.com/dtd/metadata.dtd"> +<pkgmetadata> + <maintainer type="person"> + <email>conikost@gentoo.org</email> + <name>Conrad Kostecki</name> + </maintainer> + <longdescription> + OpenRCT2 is an open-source re-implementation of RollerCoaster Tycoon 2 (RCT2), + expanding the game with new features, fixing bugs and raising game limits. + The gameplay revolves around building and maintaining an amusement park containing attractions, + shops and facilities. The player must try to make a profit and maintain a good park reputation + whilst keeping the guests happy. OpenRCT2 allows for both scenario and sandbox play. + Scenarios require the player to complete a certain objective in a set time limit whilst + sandbox allows the player to build a more flexible park with optionally no restrictions or finance. + </longdescription> + <use> + <flag name="scripting">Enable the <pkg>dev-lang/duktape</pkg> scripting engine for executing user scripts.</flag> + </use> + <upstream> + <bugs-to>https://github.com/OpenRCT2/OpenRCT2/issues</bugs-to> + </upstream> + <origin>baldeagleos-repo</origin> +</pkgmetadata> diff --git a/games-simulation/openrct2/openrct2-0.4.32.ebuild b/games-simulation/openrct2/openrct2-0.4.32.ebuild new file mode 100644 index 000000000000..a23a1f69c4e0 --- /dev/null +++ b/games-simulation/openrct2/openrct2-0.4.32.ebuild @@ -0,0 +1,180 @@ +# Copyright 1999-2026 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +inherit cmake readme.gentoo-r1 xdg-utils + +MY_PN="OpenRCT2" +MY_PN_MSX="openmusic" +MY_PN_OBJ="objects" +MY_PN_RPL="replays" +MY_PN_SFX="opensound" +MY_PN_TS="title-sequences" +MY_PV_MSX="1.6.1" +MY_PV_OBJ="1.7.6" +MY_PV_RPL="0.0.92" +MY_PV_SFX="1.0.6" +MY_PV_TS="0.4.26" + +DESCRIPTION="An open source re-implementation of Chris Sawyer's RollerCoaster Tycoon 2" +HOMEPAGE="https://openrct2.org/" +SRC_URI=" + https://github.com/${MY_PN}/${MY_PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz + https://github.com/${MY_PN}/${MY_PN_MSX}/releases/download/v${MY_PV_MSX}/${MY_PN_MSX}.zip -> ${PN}-${MY_PN_MSX}-${MY_PV_MSX}.zip + https://github.com/${MY_PN}/${MY_PN_OBJ}/releases/download/v${MY_PV_OBJ}/${MY_PN_OBJ}.zip -> ${PN}-${MY_PN_OBJ}-${MY_PV_OBJ}.zip + https://github.com/${MY_PN}/OpenSoundEffects/releases/download/v${MY_PV_SFX}/${MY_PN_SFX}.zip -> ${PN}-${MY_PN_SFX}-${MY_PV_SFX}.zip + https://github.com/${MY_PN}/${MY_PN_TS}/releases/download/v${MY_PV_TS}/${MY_PN_TS}.zip -> ${PN}-${MY_PN_TS}-${MY_PV_TS}.zip + test? ( https://github.com/${MY_PN}/${MY_PN_RPL}/releases/download/v${MY_PV_RPL}/${MY_PN_RPL}.zip -> ${PN}-${MY_PN_RPL}-${MY_PV_RPL}.zip ) +" +S="${WORKDIR}/${MY_PN}-${PV}" + +LICENSE="GPL-3" +SLOT="0" +KEYWORDS="amd64 ~arm arm64 ~x86" +IUSE="dedicated +flac +opengl scripting test +truetype +vorbis" +RESTRICT="!test? ( test )" + +COMMON_DEPEND=" + dev-libs/icu:= + dev-libs/jansson:= + dev-libs/libzip:= + media-libs/libpng:= + net-misc/curl[ssl] + virtual/zlib:= + !dedicated? ( + media-libs/libsdl2 + media-libs/speexdsp + flac? ( media-libs/flac:= ) + opengl? ( virtual/opengl ) + vorbis? ( media-libs/libvorbis ) + ) + dev-libs/openssl:0= + scripting? ( dev-lang/duktape:= ) + truetype? ( + media-libs/fontconfig:1.0 + media-libs/freetype:2 + ) +" + +RDEPEND=" + ${COMMON_DEPEND} + dedicated? ( + acct-group/openrct2 + acct-user/openrct2 + ) +" + +DEPEND=" + ${COMMON_DEPEND} + dev-cpp/nlohmann_json + test? ( dev-cpp/gtest ) +" + +BDEPEND=" + app-arch/unzip + virtual/pkgconfig +" + +PATCHES=( + "${FILESDIR}/${PN}-0.4.1-gtest-1.10.patch" + "${FILESDIR}/${PN}-0.4.16-include-additional-paths.patch" +) + +src_unpack() { + unpack "${P}".tar.gz + + mkdir -p "${S}"/data || die + cd "${S}"/data + unpack "${PN}-${MY_PN_MSX}-${MY_PV_MSX}".zip + unpack "${PN}-${MY_PN_SFX}-${MY_PV_SFX}".zip + + mkdir -p "${S}"/data/object || die + cd "${S}"/data/object || die + unpack "${PN}-${MY_PN_OBJ}-${MY_PV_OBJ}".zip + + mkdir -p "${S}"/data/sequence || die + cd "${S}"/data/sequence || die + unpack "${PN}-${MY_PN_TS}-${MY_PV_TS}".zip + + if use test; then + mkdir -p "${S}"/testdata/replays || die + cd "${S}"/testdata/replays || die + unpack "${PN}-${MY_PN_RPL}-${MY_PV_RPL}".zip + fi +} + +src_prepare() { + cmake_src_prepare + + # Don't treat warnings as errors. + sed -e 's/-Werror//' -i CMakeLists.txt || die +} + +src_configure() { + # Note: There is currently no support for Disord-RPC and Google Benchmark, + # as both packages do not exist in Gentoo, so support for them has been disabled. + local mycmakeargs=( + -DDISABLE_DISCORD_RPC=ON + $(usex !dedicated "-DDISABLE_FLAC=$(usex !flac)" "") + -DDISABLE_GOOGLE_BENCHMARK=ON + -DDISABLE_GUI=$(usex dedicated) + -DDISABLE_HTTP=OFF + -DDISABLE_IPO=ON + -DDISABLE_NETWORK=OFF + $(usex !dedicated "-DDISABLE_OPENGL=$(usex !opengl)" "") + -DDISABLE_TTF=$(usex !truetype) + $(usex !dedicated "-DDISABLE_VORBIS=$(usex !vorbis)" "") + -DDOWNLOAD_OBJECTS=OFF + -DDOWNLOAD_OPENMUSIC=OFF + -DDOWNLOAD_OPENSFX=OFF + -DDOWNLOAD_REPLAYS=OFF + -DDOWNLOAD_TITLE_SEQUENCES=OFF + -DENABLE_SCRIPTING="$(usex scripting)" + -DOPENRCT2_USE_CCACHE=OFF + -DPORTABLE=OFF + -DSTATIC=OFF + -DWITH_TESTS="$(usex test)" + -DUSE_MMAP=ON + ) + + cmake_src_configure +} + +src_test() { + # Since the tests need the OpenRCT2 data, + # we need to symlink them into the build directory, + # otherwise some tests will fail, as they don't find the OpenRCT2 data. + # It is currently not possible to override that path. + # See: https://github.com/OpenRCT2/OpenRCT2/issues/6473 + ln -s "${S}"/data "${BUILD_DIR}" || die + + cmake_src_test +} + +src_install() { + use scripting && DOCS+=( "distribution/scripting.md" "distribution/openrct2.d.ts" ) + + cmake_src_install + + if use dedicated; then + newinitd "${FILESDIR}"/openrct2.initd openrct2 + newconfd "${FILESDIR}"/openrct2.confd openrct2 + fi + + readme.gentoo_create_doc +} + +pkg_postinst() { + readme.gentoo_print_elog + + xdg_desktop_database_update + xdg_icon_cache_update + xdg_mimeinfo_database_update +} + +pkg_postrm() { + xdg_desktop_database_update + xdg_icon_cache_update + xdg_mimeinfo_database_update +} diff --git a/games-simulation/openrct2/openrct2-0.5.0.ebuild b/games-simulation/openrct2/openrct2-0.5.0.ebuild new file mode 100644 index 000000000000..7386ec7bdaba --- /dev/null +++ b/games-simulation/openrct2/openrct2-0.5.0.ebuild @@ -0,0 +1,180 @@ +# Copyright 1999-2026 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +inherit cmake readme.gentoo-r1 xdg-utils + +MY_PN="OpenRCT2" +MY_PN_MSX="openmusic" +MY_PN_OBJ="objects" +MY_PN_RPL="replays" +MY_PN_SFX="opensound" +MY_PN_TS="title-sequences" +MY_PV_MSX="1.6.1" +MY_PV_OBJ="1.7.9" +MY_PV_RPL="0.0.92" +MY_PV_SFX="1.0.6" +MY_PV_TS="0.4.26" + +DESCRIPTION="An open source re-implementation of Chris Sawyer's RollerCoaster Tycoon 2" +HOMEPAGE="https://openrct2.org/" +SRC_URI=" + https://github.com/${MY_PN}/${MY_PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz + https://github.com/${MY_PN}/${MY_PN_MSX}/releases/download/v${MY_PV_MSX}/${MY_PN_MSX}.zip -> ${PN}-${MY_PN_MSX}-${MY_PV_MSX}.zip + https://github.com/${MY_PN}/${MY_PN_OBJ}/releases/download/v${MY_PV_OBJ}/${MY_PN_OBJ}.zip -> ${PN}-${MY_PN_OBJ}-${MY_PV_OBJ}.zip + https://github.com/${MY_PN}/OpenSoundEffects/releases/download/v${MY_PV_SFX}/${MY_PN_SFX}.zip -> ${PN}-${MY_PN_SFX}-${MY_PV_SFX}.zip + https://github.com/${MY_PN}/${MY_PN_TS}/releases/download/v${MY_PV_TS}/${MY_PN_TS}.zip -> ${PN}-${MY_PN_TS}-${MY_PV_TS}.zip + test? ( https://github.com/${MY_PN}/${MY_PN_RPL}/releases/download/v${MY_PV_RPL}/${MY_PN_RPL}.zip -> ${PN}-${MY_PN_RPL}-${MY_PV_RPL}.zip ) +" +S="${WORKDIR}/${MY_PN}-${PV}" + +LICENSE="GPL-3" +SLOT="0" +KEYWORDS="~amd64 ~arm64" +IUSE="dedicated +flac +opengl scripting test +truetype +vorbis" +RESTRICT="!test? ( test )" + +COMMON_DEPEND=" + dev-libs/icu:= + dev-libs/jansson:= + dev-libs/libzip:= + media-libs/libpng:= + net-misc/curl[ssl] + virtual/zlib:= + !dedicated? ( + media-libs/libsdl2 + media-libs/speexdsp + flac? ( media-libs/flac:= ) + opengl? ( virtual/opengl ) + vorbis? ( media-libs/libvorbis ) + ) + dev-libs/openssl:0= + scripting? ( dev-libs/quickjs-ng:= ) + truetype? ( + media-libs/fontconfig:1.0 + media-libs/freetype:2 + ) +" + +RDEPEND=" + ${COMMON_DEPEND} + dedicated? ( + acct-group/openrct2 + acct-user/openrct2 + ) +" + +DEPEND=" + ${COMMON_DEPEND} + dev-cpp/nlohmann_json + test? ( dev-cpp/gtest ) +" + +BDEPEND=" + app-arch/unzip + virtual/pkgconfig +" + +PATCHES=( + "${FILESDIR}/${PN}-0.4.1-gtest-1.10.patch" + "${FILESDIR}/${PN}-0.4.16-include-additional-paths.patch" +) + +src_unpack() { + unpack "${P}".tar.gz + + mkdir -p "${S}"/data || die + cd "${S}"/data + unpack "${PN}-${MY_PN_MSX}-${MY_PV_MSX}".zip + unpack "${PN}-${MY_PN_SFX}-${MY_PV_SFX}".zip + + mkdir -p "${S}"/data/object || die + cd "${S}"/data/object || die + unpack "${PN}-${MY_PN_OBJ}-${MY_PV_OBJ}".zip + + mkdir -p "${S}"/data/sequence || die + cd "${S}"/data/sequence || die + unpack "${PN}-${MY_PN_TS}-${MY_PV_TS}".zip + + if use test; then + mkdir -p "${S}"/testdata/replays || die + cd "${S}"/testdata/replays || die + unpack "${PN}-${MY_PN_RPL}-${MY_PV_RPL}".zip + fi +} + +src_prepare() { + cmake_src_prepare + + # Don't treat warnings as errors. + sed -e 's/-Werror//' -i CMakeLists.txt || die +} + +src_configure() { + # Note: There is currently no support for Disord-RPC and Google Benchmark, + # as both packages do not exist in Gentoo, so support for them has been disabled. + local mycmakeargs=( + -DDISABLE_DISCORD_RPC=ON + $(usex !dedicated "-DDISABLE_FLAC=$(usex !flac)" "") + -DDISABLE_GOOGLE_BENCHMARK=ON + -DDISABLE_GUI=$(usex dedicated) + -DDISABLE_HTTP=OFF + -DDISABLE_IPO=ON + -DDISABLE_NETWORK=OFF + $(usex !dedicated "-DDISABLE_OPENGL=$(usex !opengl)" "") + -DDISABLE_TTF=$(usex !truetype) + $(usex !dedicated "-DDISABLE_VORBIS=$(usex !vorbis)" "") + -DDOWNLOAD_OBJECTS=OFF + -DDOWNLOAD_OPENMUSIC=OFF + -DDOWNLOAD_OPENSFX=OFF + -DDOWNLOAD_REPLAYS=OFF + -DDOWNLOAD_TITLE_SEQUENCES=OFF + -DENABLE_SCRIPTING="$(usex scripting)" + -DOPENRCT2_USE_CCACHE=OFF + -DPORTABLE=OFF + -DSTATIC=OFF + -DWITH_TESTS="$(usex test)" + -DUSE_MMAP=ON + ) + + cmake_src_configure +} + +src_test() { + # Since the tests need the OpenRCT2 data, + # we need to symlink them into the build directory, + # otherwise some tests will fail, as they don't find the OpenRCT2 data. + # It is currently not possible to override that path. + # See: https://github.com/OpenRCT2/OpenRCT2/issues/6473 + ln -s "${S}"/data "${BUILD_DIR}" || die + + cmake_src_test +} + +src_install() { + use scripting && DOCS+=( "distribution/scripting.md" "distribution/openrct2.d.ts" ) + + cmake_src_install + + if use dedicated; then + newinitd "${FILESDIR}"/openrct2.initd openrct2 + newconfd "${FILESDIR}"/openrct2.confd openrct2 + fi + + readme.gentoo_create_doc +} + +pkg_postinst() { + readme.gentoo_print_elog + + xdg_desktop_database_update + xdg_icon_cache_update + xdg_mimeinfo_database_update +} + +pkg_postrm() { + xdg_desktop_database_update + xdg_icon_cache_update + xdg_mimeinfo_database_update +} diff --git a/games-simulation/openttd/Manifest b/games-simulation/openttd/Manifest new file mode 100644 index 000000000000..b3e9ac8ea870 --- /dev/null +++ b/games-simulation/openttd/Manifest @@ -0,0 +1,2 @@ +DIST openttd-15.2-source.tar.xz 8514360 BLAKE2B 2d68e6ac013a0cfe4b60896017c27a2a0606a520a52bfe7e7dd1ffec16d0e658dfc7ead2216d8ffd9a0ec94e7f00c4d7d099df60d4dc50ebf32b0bcd83d2a338 SHA512 30bc2f91791a7ed7b3cb83b3677b3b66a35507524638834f33c5d46d8a2a662bdc1d498c7300ee2a72e52a3d3318965d6ec858f3c90070ee8983fac46cd2eddb +DIST openttd-15.3-source.tar.xz 8531992 BLAKE2B c88253714a2abfa2dc36767bc3a24dcfecd68d5ec6fe06ef3fe7a7ea1747de2caca67332c20f0b4fbb5375caa8c26b45975937df6ded330aceaecf1d0497d05d SHA512 966b97450eb9509d50652596d3af92554e46e65cb36e41c7fe2c46dac84b397b2b693f1f0bf6308aabe1e8f5ff8a90ece99ccbe34cbb3bb723a389324269b771 diff --git a/games-simulation/openttd/files/openttd-1.11.2_dont_compress_man.patch b/games-simulation/openttd/files/openttd-1.11.2_dont_compress_man.patch new file mode 100644 index 000000000000..0dfef300dc5e --- /dev/null +++ b/games-simulation/openttd/files/openttd-1.11.2_dont_compress_man.patch @@ -0,0 +1,29 @@ +From 985c2f4937573ce80add1aa84e4e57148c0a1815 Mon Sep 17 00:00:00 2001 +From: "Azamat H. Hackimov" <azamat.hackimov@gmail.com> +Date: Sun, 23 May 2021 17:39:53 +0300 +Subject: [PATCH] Don't compress man file on install + +--- + cmake/InstallAndPackage.cmake | 3 +-- + 1 file changed, 1 insertion(+), 2 deletions(-) + +diff --git a/cmake/InstallAndPackage.cmake b/cmake/InstallAndPackage.cmake +index 9b7d65788..b5b23c95f 100644 +--- a/cmake/InstallAndPackage.cmake ++++ b/cmake/InstallAndPackage.cmake +@@ -51,11 +51,10 @@ if(OPTION_INSTALL_FHS) + install(CODE + " + execute_process(COMMAND ${CMAKE_COMMAND} -E copy ${MAN_SOURCE_FILE} ${MAN_BINARY_FILE}) +- execute_process(COMMAND gzip -9 -n -f ${MAN_BINARY_FILE}) + " + COMPONENT manual) + install(FILES +- ${MAN_BINARY_FILE}.gz ++ ${MAN_BINARY_FILE} + DESTINATION ${MAN_DESTINATION_DIR}/man6 + COMPONENT manual) + endif() +-- +2.26.3 + diff --git a/games-simulation/openttd/files/openttd.confd-r1 b/games-simulation/openttd/files/openttd.confd-r1 new file mode 100644 index 000000000000..47cae2fda01a --- /dev/null +++ b/games-simulation/openttd/files/openttd.confd-r1 @@ -0,0 +1,10 @@ +# Copyright 1999-2022 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +# Dtach options, which will used, when the `attach` extra command is called. +# By default, CTRL+D is used, and no signal is send, +# when you want to detach from the attached console. +dtach_opts="-e '^D' -r none" + +# Options for your started OpenTTD server +openttd_opts="" diff --git a/games-simulation/openttd/files/openttd.initd-r3 b/games-simulation/openttd/files/openttd.initd-r3 new file mode 100644 index 000000000000..147c60308720 --- /dev/null +++ b/games-simulation/openttd/files/openttd.initd-r3 @@ -0,0 +1,34 @@ +#!/sbin/openrc-run +# Copyright 1999-2022 Gentoo Authors +# Distributed under the terms of the GNU General Public License, v2 or later + +description="OpenTTD dedicated game server" +dtach_tmpfile="$(mktemp -u)" +name="OpenTTD dedicated game server" +openttd_command="/usr/bin/openttd" +pidfile="/run/${SVCNAME}.pid" + +description_attach="Attaches to the session (interactive console) of the OpenTTD game server" +extra_started_commands="attach" + +command="/usr/bin/dtach" +command_args="-N ${dtach_tmpfile} ${openttd_command} -D ${openttd_opts}" +command_background="true" +command_group="openttd" +command_user="openttd" + +depend() { + need net +} + +attach() { + pidnumber="$(cat ${pidfile})" + dtach_tmpfile="$(cat /proc/${pidnumber}/cmdline | tr '\0' ' ' | awk '{print $3}')" + + if [ -S "${dtach_tmpfile}" ]; then + eval "${command}" -a "${dtach_tmpfile}" "${dtach_opts}" + else + eerror "The determined socket file for dtach could not be found!" + eerror "Did the process crash?" + fi +} diff --git a/games-simulation/openttd/metadata.xml b/games-simulation/openttd/metadata.xml new file mode 100644 index 000000000000..b23b090ecbf3 --- /dev/null +++ b/games-simulation/openttd/metadata.xml @@ -0,0 +1,19 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "https://docs.baldeagleos.com/dtd/metadata.dtd"> +<pkgmetadata> + <maintainer type="project"> + <email>games@gentoo.org</email> + <name>Gentoo Games Project</name> + </maintainer> + <use> + <flag name="allegro">Add support for Allegro</flag> + <flag name="dedicated">Build only the openttd server, and not the client.</flag> + <flag name="fluidsynth">Compile with support for FluidSynth</flag> + <flag name="lzo">Enables LZO compression for savegames. This is only needed to load extremely old savegames. (versions before 0.2)</flag> + <flag name="openmedia">Enables the free open media sets: OpenGFX, OpenSFX, OpenMSX, removing the requirement for proprietary TTD assets to play OpenTTD.</flag> + </use> + <upstream> + <remote-id type="cpe">cpe:/a:openttd:openttd</remote-id> + </upstream> + <origin>baldeagleos-repo</origin> +</pkgmetadata> diff --git a/games-simulation/openttd/openttd-15.2.ebuild b/games-simulation/openttd/openttd-15.2.ebuild new file mode 100644 index 000000000000..769e22a8c263 --- /dev/null +++ b/games-simulation/openttd/openttd-15.2.ebuild @@ -0,0 +1,137 @@ +# Copyright 1999-2026 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +inherit cmake xdg + +DESCRIPTION="A clone of Transport Tycoon Deluxe" +HOMEPAGE="https://www.openttd.org/" + +if [[ ${PV} == 9999 ]] ; then + EGIT_REPO_URI="https://github.com/OpenTTD/OpenTTD" + inherit git-r3 +else + SRC_URI="https://cdn.openttd.org/openttd-releases/${PV}/${P}-source.tar.xz" + + KEYWORDS="~amd64 ~arm64 ~ppc64 ~x86" +fi + +LICENSE="GPL-2" +SLOT="0" +IUSE="allegro cpu_flags_x86_sse debug dedicated +fluidsynth icu +lzma lzo +openmedia +png +sdl timidity +truetype +zlib" +REQUIRED_USE="!dedicated? ( || ( allegro sdl ) )" + +RDEPEND=" + net-misc/curl + dedicated? ( + acct-group/openttd + acct-user/openttd + app-misc/dtach + ) + !dedicated? ( + media-libs/libogg + media-libs/opusfile + allegro? ( media-libs/allegro:5 ) + fluidsynth? ( media-sound/fluidsynth ) + icu? ( + >=dev-libs/icu-58.1:= + media-libs/harfbuzz + ) + sdl? ( media-libs/libsdl2[sound,video] ) + truetype? ( + media-libs/fontconfig + media-libs/freetype:2 + virtual/zlib:= + ) + ) + lzma? ( app-arch/xz-utils ) + lzo? ( dev-libs/lzo:2 ) + png? ( media-libs/libpng:= ) + zlib? ( virtual/zlib:= ) +" +DEPEND="${RDEPEND}" +BDEPEND=" + >=games-util/grfcodec-6.0.6_p20210310 + virtual/pkgconfig +" +PDEPEND=" + !dedicated? ( + openmedia? ( + >=games-misc/openmsx-0.4.0 + >=games-misc/opensfx-1.0.1 + ) + ) + openmedia? ( >=games-misc/opengfx-0.6.1 ) + timidity? ( media-sound/timidity++ ) +" + +DOCS=( docs/directory_structure.md ) + +PATCHES=( + "${FILESDIR}/${PN}-1.11.2_dont_compress_man.patch" +) + +src_prepare() { + # Drop automagic LTO usage + sed -i -e '/check_ipo_supported(RESULT IPO_FOUND)/d' CMakeLists.txt || die + + # Don't force _FORTIFY_SOURCE via CMake + # (we already set it in the toolchain by default with a minimum level + # of _FORTIFY_SOURCE=2) + sed -i -e '/-D_FORTIFY_SOURCE/d' cmake/CompileFlags.cmake || die + + cmake_src_prepare +} + +src_configure() { + local mycmakeargs=( + -DCMAKE_INSTALL_BINDIR=bin + -DCMAKE_INSTALL_DATADIR=share + -DOPTION_DEDICATED=$(usex dedicated) + -DOPTION_USE_ASSERTS=$(usex debug) + -DCMAKE_DISABLE_FIND_PACKAGE_Allegro=$(usex !allegro) + -DCMAKE_DISABLE_FIND_PACKAGE_Freetype=$(usex !truetype) + -DCMAKE_DISABLE_FIND_PACKAGE_Fontconfig=$(usex !truetype) + -DCMAKE_DISABLE_FIND_PACKAGE_Fluidsynth=$(usex !fluidsynth) + -DCMAKE_DISABLE_FIND_PACKAGE_ICU=$(usex !icu) + -DCMAKE_DISABLE_FIND_PACKAGE_Harfbuzz=$(usex !icu) + -DCMAKE_DISABLE_FIND_PACKAGE_LibLZMA=$(usex !lzma) + -DCMAKE_DISABLE_FIND_PACKAGE_LZO=$(usex !lzo) + -DCMAKE_DISABLE_FIND_PACKAGE_PNG=$(usex !png) + -DCMAKE_DISABLE_FIND_PACKAGE_SDL2=$(usex !sdl) + -DCMAKE_DISABLE_FIND_PACKAGE_SSE=$(usex !cpu_flags_x86_sse) + -DCMAKE_DISABLE_FIND_PACKAGE_ZLIB=$(usex !zlib) + ) + + cmake_src_configure +} + +src_install() { + cmake_src_install + + if use dedicated ; then + newconfd "${FILESDIR}"/openttd.confd-r1 openttd + newinitd "${FILESDIR}"/openttd.initd-r3 openttd + fi +} + +pkg_postinst() { + xdg_pkg_postinst + + if ! use openmedia ; then + elog + elog "OpenTTD was compiled without the 'openmedia' USE flag." + elog + elog "In order to play, you must at least install" + elog "games-misc/opengfx, and games-misc/opensfx, or copy the " + elog "following 6 files from a version of Transport Tycoon Deluxe" + elog "(Windows or DOS) to shared or personal location." + elog "See ${EROOT}/usr/share/doc/${PF}/directory_structure.md for more info." + elog + elog "From the Windows version you need: " + elog "sample.cat trg1r.grf trgcr.grf trghr.grf trgir.grf trgtr.grf" + elog "OR from the DOS version you need: " + elog "SAMPLE.CAT TRG1.GRF TRGC.GRF TRGH.GRF TRGI.GRF TRGT.GRF" + fi +} diff --git a/games-simulation/openttd/openttd-15.3.ebuild b/games-simulation/openttd/openttd-15.3.ebuild new file mode 100644 index 000000000000..769e22a8c263 --- /dev/null +++ b/games-simulation/openttd/openttd-15.3.ebuild @@ -0,0 +1,137 @@ +# Copyright 1999-2026 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +inherit cmake xdg + +DESCRIPTION="A clone of Transport Tycoon Deluxe" +HOMEPAGE="https://www.openttd.org/" + +if [[ ${PV} == 9999 ]] ; then + EGIT_REPO_URI="https://github.com/OpenTTD/OpenTTD" + inherit git-r3 +else + SRC_URI="https://cdn.openttd.org/openttd-releases/${PV}/${P}-source.tar.xz" + + KEYWORDS="~amd64 ~arm64 ~ppc64 ~x86" +fi + +LICENSE="GPL-2" +SLOT="0" +IUSE="allegro cpu_flags_x86_sse debug dedicated +fluidsynth icu +lzma lzo +openmedia +png +sdl timidity +truetype +zlib" +REQUIRED_USE="!dedicated? ( || ( allegro sdl ) )" + +RDEPEND=" + net-misc/curl + dedicated? ( + acct-group/openttd + acct-user/openttd + app-misc/dtach + ) + !dedicated? ( + media-libs/libogg + media-libs/opusfile + allegro? ( media-libs/allegro:5 ) + fluidsynth? ( media-sound/fluidsynth ) + icu? ( + >=dev-libs/icu-58.1:= + media-libs/harfbuzz + ) + sdl? ( media-libs/libsdl2[sound,video] ) + truetype? ( + media-libs/fontconfig + media-libs/freetype:2 + virtual/zlib:= + ) + ) + lzma? ( app-arch/xz-utils ) + lzo? ( dev-libs/lzo:2 ) + png? ( media-libs/libpng:= ) + zlib? ( virtual/zlib:= ) +" +DEPEND="${RDEPEND}" +BDEPEND=" + >=games-util/grfcodec-6.0.6_p20210310 + virtual/pkgconfig +" +PDEPEND=" + !dedicated? ( + openmedia? ( + >=games-misc/openmsx-0.4.0 + >=games-misc/opensfx-1.0.1 + ) + ) + openmedia? ( >=games-misc/opengfx-0.6.1 ) + timidity? ( media-sound/timidity++ ) +" + +DOCS=( docs/directory_structure.md ) + +PATCHES=( + "${FILESDIR}/${PN}-1.11.2_dont_compress_man.patch" +) + +src_prepare() { + # Drop automagic LTO usage + sed -i -e '/check_ipo_supported(RESULT IPO_FOUND)/d' CMakeLists.txt || die + + # Don't force _FORTIFY_SOURCE via CMake + # (we already set it in the toolchain by default with a minimum level + # of _FORTIFY_SOURCE=2) + sed -i -e '/-D_FORTIFY_SOURCE/d' cmake/CompileFlags.cmake || die + + cmake_src_prepare +} + +src_configure() { + local mycmakeargs=( + -DCMAKE_INSTALL_BINDIR=bin + -DCMAKE_INSTALL_DATADIR=share + -DOPTION_DEDICATED=$(usex dedicated) + -DOPTION_USE_ASSERTS=$(usex debug) + -DCMAKE_DISABLE_FIND_PACKAGE_Allegro=$(usex !allegro) + -DCMAKE_DISABLE_FIND_PACKAGE_Freetype=$(usex !truetype) + -DCMAKE_DISABLE_FIND_PACKAGE_Fontconfig=$(usex !truetype) + -DCMAKE_DISABLE_FIND_PACKAGE_Fluidsynth=$(usex !fluidsynth) + -DCMAKE_DISABLE_FIND_PACKAGE_ICU=$(usex !icu) + -DCMAKE_DISABLE_FIND_PACKAGE_Harfbuzz=$(usex !icu) + -DCMAKE_DISABLE_FIND_PACKAGE_LibLZMA=$(usex !lzma) + -DCMAKE_DISABLE_FIND_PACKAGE_LZO=$(usex !lzo) + -DCMAKE_DISABLE_FIND_PACKAGE_PNG=$(usex !png) + -DCMAKE_DISABLE_FIND_PACKAGE_SDL2=$(usex !sdl) + -DCMAKE_DISABLE_FIND_PACKAGE_SSE=$(usex !cpu_flags_x86_sse) + -DCMAKE_DISABLE_FIND_PACKAGE_ZLIB=$(usex !zlib) + ) + + cmake_src_configure +} + +src_install() { + cmake_src_install + + if use dedicated ; then + newconfd "${FILESDIR}"/openttd.confd-r1 openttd + newinitd "${FILESDIR}"/openttd.initd-r3 openttd + fi +} + +pkg_postinst() { + xdg_pkg_postinst + + if ! use openmedia ; then + elog + elog "OpenTTD was compiled without the 'openmedia' USE flag." + elog + elog "In order to play, you must at least install" + elog "games-misc/opengfx, and games-misc/opensfx, or copy the " + elog "following 6 files from a version of Transport Tycoon Deluxe" + elog "(Windows or DOS) to shared or personal location." + elog "See ${EROOT}/usr/share/doc/${PF}/directory_structure.md for more info." + elog + elog "From the Windows version you need: " + elog "sample.cat trg1r.grf trgcr.grf trghr.grf trgir.grf trgtr.grf" + elog "OR from the DOS version you need: " + elog "SAMPLE.CAT TRG1.GRF TRGC.GRF TRGH.GRF TRGI.GRF TRGT.GRF" + fi +} diff --git a/games-simulation/openttd/openttd-9999.ebuild b/games-simulation/openttd/openttd-9999.ebuild new file mode 100644 index 000000000000..769e22a8c263 --- /dev/null +++ b/games-simulation/openttd/openttd-9999.ebuild @@ -0,0 +1,137 @@ +# Copyright 1999-2026 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +inherit cmake xdg + +DESCRIPTION="A clone of Transport Tycoon Deluxe" +HOMEPAGE="https://www.openttd.org/" + +if [[ ${PV} == 9999 ]] ; then + EGIT_REPO_URI="https://github.com/OpenTTD/OpenTTD" + inherit git-r3 +else + SRC_URI="https://cdn.openttd.org/openttd-releases/${PV}/${P}-source.tar.xz" + + KEYWORDS="~amd64 ~arm64 ~ppc64 ~x86" +fi + +LICENSE="GPL-2" +SLOT="0" +IUSE="allegro cpu_flags_x86_sse debug dedicated +fluidsynth icu +lzma lzo +openmedia +png +sdl timidity +truetype +zlib" +REQUIRED_USE="!dedicated? ( || ( allegro sdl ) )" + +RDEPEND=" + net-misc/curl + dedicated? ( + acct-group/openttd + acct-user/openttd + app-misc/dtach + ) + !dedicated? ( + media-libs/libogg + media-libs/opusfile + allegro? ( media-libs/allegro:5 ) + fluidsynth? ( media-sound/fluidsynth ) + icu? ( + >=dev-libs/icu-58.1:= + media-libs/harfbuzz + ) + sdl? ( media-libs/libsdl2[sound,video] ) + truetype? ( + media-libs/fontconfig + media-libs/freetype:2 + virtual/zlib:= + ) + ) + lzma? ( app-arch/xz-utils ) + lzo? ( dev-libs/lzo:2 ) + png? ( media-libs/libpng:= ) + zlib? ( virtual/zlib:= ) +" +DEPEND="${RDEPEND}" +BDEPEND=" + >=games-util/grfcodec-6.0.6_p20210310 + virtual/pkgconfig +" +PDEPEND=" + !dedicated? ( + openmedia? ( + >=games-misc/openmsx-0.4.0 + >=games-misc/opensfx-1.0.1 + ) + ) + openmedia? ( >=games-misc/opengfx-0.6.1 ) + timidity? ( media-sound/timidity++ ) +" + +DOCS=( docs/directory_structure.md ) + +PATCHES=( + "${FILESDIR}/${PN}-1.11.2_dont_compress_man.patch" +) + +src_prepare() { + # Drop automagic LTO usage + sed -i -e '/check_ipo_supported(RESULT IPO_FOUND)/d' CMakeLists.txt || die + + # Don't force _FORTIFY_SOURCE via CMake + # (we already set it in the toolchain by default with a minimum level + # of _FORTIFY_SOURCE=2) + sed -i -e '/-D_FORTIFY_SOURCE/d' cmake/CompileFlags.cmake || die + + cmake_src_prepare +} + +src_configure() { + local mycmakeargs=( + -DCMAKE_INSTALL_BINDIR=bin + -DCMAKE_INSTALL_DATADIR=share + -DOPTION_DEDICATED=$(usex dedicated) + -DOPTION_USE_ASSERTS=$(usex debug) + -DCMAKE_DISABLE_FIND_PACKAGE_Allegro=$(usex !allegro) + -DCMAKE_DISABLE_FIND_PACKAGE_Freetype=$(usex !truetype) + -DCMAKE_DISABLE_FIND_PACKAGE_Fontconfig=$(usex !truetype) + -DCMAKE_DISABLE_FIND_PACKAGE_Fluidsynth=$(usex !fluidsynth) + -DCMAKE_DISABLE_FIND_PACKAGE_ICU=$(usex !icu) + -DCMAKE_DISABLE_FIND_PACKAGE_Harfbuzz=$(usex !icu) + -DCMAKE_DISABLE_FIND_PACKAGE_LibLZMA=$(usex !lzma) + -DCMAKE_DISABLE_FIND_PACKAGE_LZO=$(usex !lzo) + -DCMAKE_DISABLE_FIND_PACKAGE_PNG=$(usex !png) + -DCMAKE_DISABLE_FIND_PACKAGE_SDL2=$(usex !sdl) + -DCMAKE_DISABLE_FIND_PACKAGE_SSE=$(usex !cpu_flags_x86_sse) + -DCMAKE_DISABLE_FIND_PACKAGE_ZLIB=$(usex !zlib) + ) + + cmake_src_configure +} + +src_install() { + cmake_src_install + + if use dedicated ; then + newconfd "${FILESDIR}"/openttd.confd-r1 openttd + newinitd "${FILESDIR}"/openttd.initd-r3 openttd + fi +} + +pkg_postinst() { + xdg_pkg_postinst + + if ! use openmedia ; then + elog + elog "OpenTTD was compiled without the 'openmedia' USE flag." + elog + elog "In order to play, you must at least install" + elog "games-misc/opengfx, and games-misc/opensfx, or copy the " + elog "following 6 files from a version of Transport Tycoon Deluxe" + elog "(Windows or DOS) to shared or personal location." + elog "See ${EROOT}/usr/share/doc/${PF}/directory_structure.md for more info." + elog + elog "From the Windows version you need: " + elog "sample.cat trg1r.grf trgcr.grf trghr.grf trgir.grf trgtr.grf" + elog "OR from the DOS version you need: " + elog "SAMPLE.CAT TRG1.GRF TRGC.GRF TRGH.GRF TRGI.GRF TRGT.GRF" + fi +} diff --git a/games-simulation/pmars-sdl/Manifest b/games-simulation/pmars-sdl/Manifest new file mode 100644 index 000000000000..c603363a2234 --- /dev/null +++ b/games-simulation/pmars-sdl/Manifest @@ -0,0 +1 @@ +DIST pmars-0.9.2-5.tar.gz 200966 BLAKE2B 398323191290a9e3d57cb371c2070585cf78f845ca4cbadfa09f03045abc80f7b3fb71a58c18bbfdf503a3239d25bd0734b10e784d6570766e6b5c0ec606aadf SHA512 197d1967507199ed5eb075fb232a2f15d9bdf4bec03fc6b1d6df5d6259d6627eb40338c5787852ea10d96858029144348128b08e86c7079d96f10fd09dafc315 diff --git a/games-simulation/pmars-sdl/files/pmars-sdl-0.9.2e-c23.patch b/games-simulation/pmars-sdl/files/pmars-sdl-0.9.2e-c23.patch new file mode 100644 index 000000000000..b9a61a24a452 --- /dev/null +++ b/games-simulation/pmars-sdl/files/pmars-sdl-0.9.2e-c23.patch @@ -0,0 +1,11 @@ +sort_by_score appeared twice. +--- a/src/global.h ++++ b/src/global.h +@@ -411,7 +411,6 @@ extern int score(int warnum); + extern void sort_by_score(int *idxV, int *scrV); + extern int deaths(int warnum); + extern void results(FILE * outp); +-extern void sort_by_score(); + extern void Exit(int code); + extern void reset_regs(void); + extern void set_reg(char regChr, long val); diff --git a/games-simulation/pmars-sdl/files/pmars-sdl-0.9.2e-format.patch b/games-simulation/pmars-sdl/files/pmars-sdl-0.9.2e-format.patch new file mode 100644 index 000000000000..4e02da8a82a8 --- /dev/null +++ b/games-simulation/pmars-sdl/files/pmars-sdl-0.9.2e-format.patch @@ -0,0 +1,65 @@ +--- a/src/asm.c.old 2015-10-28 13:23:53.465014342 +0100 ++++ b/src/asm.c 2015-10-28 13:23:10.502813377 +0100 +@@ -652,7 +652,7 @@ + macputs(str); + #else + if (!inCdb) +- fprintf(stderr, str); ++ fprintf(stderr, "%s", str); + #if defined DOSALLGRAPHX + else { + if (displayMode == TEXT) +@@ -833,7 +833,7 @@ + #ifdef __MAC__ + textout(notEnoughMemErr); + #else +- fprintf(stderr, notEnoughMemErr); ++ fprintf(stderr, "%s", notEnoughMemErr); + #endif + Exit(MEMERR); + break; +@@ -916,7 +916,7 @@ + } + + if (ierr >= ERRMAX) { +- sprintf(outs, tooManyMsgErr); ++ sprintf(outs, "%s", tooManyMsgErr); + #ifndef VMS + textout(outs); + #else +--- a/src/cdb.c.old 2015-10-28 13:24:04.669805966 +0100 ++++ b/src/cdb.c 2015-10-28 13:23:10.502813377 +0100 +@@ -2760,7 +2760,7 @@ + fprintf(outp, nameByAuthorScores, warrior[idxV[i]].name, warrior[idxV[i]].authorName, + scrV[idxV[i]]); + if (warriors > 2) { +- fprintf(outp, resultsAre); ++ fprintf(outp, "%s", resultsAre); + for (j = 0; j < warriors; ++j) { + fprintf(outp, " %d", warrior[idxV[i]].score[j]); + } +--- a/src/clparse.c.old 2015-10-28 13:24:10.648694768 +0100 ++++ b/src/clparse.c 2015-10-28 13:23:10.502813377 +0100 +@@ -289,7 +289,7 @@ + if (next_input(filep, inputs)) { + if (!strcmp(inputs, "-")) { + newFile = stdin; +- fprintf(stderr, readingStdin); ++ fprintf(stderr, "%s", readingStdin); + } else { + if ((newFile = fopen(inputs, "r")) == NULL) { + code = FILENAME; /* command file not found */ +@@ -430,11 +430,11 @@ + errout(outs); + break; + case MEMORY: +- sprintf(outs, outOfMemory); ++ sprintf(outs, "%s", outOfMemory); + errout(outs); + break; + case FILENAME: +- sprintf(outs, cannotOpenParameterFile); ++ sprintf(outs, "%s", cannotOpenParameterFile); + errout(outs); + break; + } diff --git a/games-simulation/pmars-sdl/files/pmars-sdl-0.9.2e-ncurses-opaque.patch b/games-simulation/pmars-sdl/files/pmars-sdl-0.9.2e-ncurses-opaque.patch new file mode 100644 index 000000000000..543ece1d6ce5 --- /dev/null +++ b/games-simulation/pmars-sdl/files/pmars-sdl-0.9.2e-ncurses-opaque.patch @@ -0,0 +1,45 @@ +https://bugs.gentoo.org/932139 +https://github.com/mbarbon/pMARS/commit/a39970c724591c3c8625819cab7ca298ae71e12d +--- a/src/curdisp.c ++++ b/src/curdisp.c +@@ -428,18 +428,18 @@ agets5(str, maxchar, attr) + str--; + maxchar++; + leaveok(curwin, TRUE); +- if (ox = curwin->_curx) { ++ if (ox = getcurx(curwin)) { + #if 0 + #ifdef ATTRIBUTE +- mvwaddch(curwin, curwin->_cury, --ox, ' ' | attr); ++ mvwaddch(curwin, getcury(curwin), --ox, ' ' | attr); + #else +- mvwaddch(curwin, curwin->_cury, --ox, ' '); ++ mvwaddch(curwin, getcury(curwin), --ox, ' '); + #endif + #endif /* 0 */ +- mvwaddch(curwin, curwin->_cury, --ox, ' '); +- wmove(curwin, curwin->_cury, ox); ++ mvwaddch(curwin, getcury(curwin), --ox, ' '); ++ wmove(curwin, getcury(curwin), ox); + } else { +- oy = curwin->_cury - 1; ++ oy = getcury(curwin) - 1; + #if 0 + #ifdef ATTRIBUTE + mvwaddch(curwin, oy, COLS - 1, ' ' | attr); +@@ -470,12 +470,12 @@ agets5(str, maxchar, attr) + if (ox--) + #if 0 + #ifdef ATTRIBUTE +- mvwaddch(curwin, curwin->_cury, ox, ' ' | attr); ++ mvwaddch(curwin, getcury(curwin), ox, ' ' | attr); + #else +- mvwaddch(curwin, curwin->_cury, ox, ' '); ++ mvwaddch(curwin, getcury(curwin), ox, ' '); + #endif + #endif /* 0 */ +- mvwaddch(curwin, curwin->_cury, ox, ' '); ++ mvwaddch(curwin, getcury(curwin), ox, ' '); + else + #if 0 + #ifdef ATTRIBUTE diff --git a/games-simulation/pmars-sdl/metadata.xml b/games-simulation/pmars-sdl/metadata.xml new file mode 100644 index 000000000000..183ecc5ceeeb --- /dev/null +++ b/games-simulation/pmars-sdl/metadata.xml @@ -0,0 +1,9 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "https://docs.baldeagleos.com/dtd/metadata.dtd"> +<pkgmetadata> + <maintainer type="project"> + <email>games@gentoo.org</email> + <name>Gentoo Games Project</name> + </maintainer> + <origin>baldeagleos-repo</origin> +</pkgmetadata> diff --git a/games-simulation/pmars-sdl/pmars-sdl-0.9.2e-r2.ebuild b/games-simulation/pmars-sdl/pmars-sdl-0.9.2e-r2.ebuild new file mode 100644 index 000000000000..ee9eb60c147c --- /dev/null +++ b/games-simulation/pmars-sdl/pmars-sdl-0.9.2e-r2.ebuild @@ -0,0 +1,104 @@ +# Copyright 1999-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +inherit flag-o-matic toolchain-funcs readme.gentoo-r1 + +MY_PN="${PN/-sdl/}" +MY_PV="${PV/e/-5}" +MY_P="${MY_PN}-${MY_PV}" + +DESCRIPTION="Portable redcode simulator's sdl port for core war" +HOMEPAGE="https://corewar.co.uk/pihlaja/pmars-sdl/" +SRC_URI="https://corewar.co.uk/pihlaja/pmars-sdl/${MY_P}.tar.gz" +S="${WORKDIR}/${MY_P}" + +LICENSE="BSD GPL-2" +SLOT="0" +KEYWORDS="~amd64 ~x86" +IUSE="sdl X" + +RDEPEND=" + sdl? ( x11-libs/libX11 media-libs/libsdl[video] ) + X? ( x11-libs/libX11 ) + !sdl? ( !X? ( sys-libs/ncurses:0= ) ) +" +DEPEND="${RDEPEND}" +BDEPEND="virtual/pkgconfig" + +PATCHES=( + "${FILESDIR}"/${P}-format.patch + "${FILESDIR}"/${P}-ncurses-opaque.patch + "${FILESDIR}"/${P}-c23.patch +) + +DOC_CONTENTS=" + There are some macros in /usr/share/pmars/macros + which you should make accessible to pmars by typing + export PMARSHOME=/usr/share/pmars/macros\n +" + +src_compile() { + local LIB="" + export LFLAGS="-x" + + append-cppflags -DEXT94 -DPERMUTATE + + if use sdl ; then + append-cflags $(sdl-config --cflags) + append-cppflags -DSDLGRAPHX + + LIB="$(sdl-config --libs)" + elif use X ; then + append-cppflags -DXWINGRAPHX + + LIB="$($(tc-getPKG_CONFIG) --libs x11)" + else + append-cppflags -DCURSESGRAPHX + + LIB="$($(tc-getPKG_CONFIG) --libs ncurses)" + fi + + cd src || die + + local programs=( + asm.c + cdb.c + clparse.c + disasm.c + eval.c + global.c + pmars.c + sim.c + pos.c + str_eng.c + token.c + ) + + for program in "${programs[@]}" ; do + einfo "Compiling ${program}" + $(tc-getCC) ${CPPFLAGS} ${CFLAGS} ${program} -c || die + done + + einfo "Linking with LIB: ${LIB}" + $(tc-getCC) ${LDFLAGS} *.o ${LIB} -o ${MY_PN} || die +} + +src_install() { + dobin src/${MY_PN} + doman doc/${MY_PN}.6 + + dodoc AUTHORS CONTRIB ChangeLog README doc/redcode.ref + readme.gentoo_create_doc + + insinto /usr/share/${MY_PN}/warriors + doins warriors/* + + insinto /usr/share/${MY_PN}/macros + doins config/*.mac +} + +pkg_postinst() { + readme.gentoo_print_elog +} diff --git a/games-simulation/searchandrescue/Manifest b/games-simulation/searchandrescue/Manifest new file mode 100644 index 000000000000..6c98a8edfca8 --- /dev/null +++ b/games-simulation/searchandrescue/Manifest @@ -0,0 +1,3 @@ +DIST SearchAndRescue-1.7.0.tar 6256640 BLAKE2B 9ccf63408499bd5f44a1eb6d24656ca5403eb732bd166ccd263d5fdd6f29e5168a563cda4e59eff74d39fa832876f0f04451042baf99d332d748828d0f03b7de SHA512 36295e7c20e685068ba6448b5f579eb53fedba663f76ac1d0db1da1765fbbfe6c1c4728e8a90680250ebbb3f4ad181fbe5bdd2f0fc703c774ec27dc829feacc9 +DIST SearchAndRescue-data-1.7.0.tar 52141474 BLAKE2B 2f43e1349d27c11e441d01d7421d9e5b9145d99c6685ddfb1e2a713269123f9cfc2c655359fa65fa09844dcbf3958bc9d4b2c51c4f9c03e401e2bc40f8953f40 SHA512 a323c50a2c64705ebd43c27e836f088094085bc4f5d219a9b0341cc3b16aafe96e364eb36162a7acb6a59aefe6304767f497e2d7bb0dc29d881f51e6535a6295 +DIST SearchAndRescue-data-guadarrama-1.7.0.tar 41738769 BLAKE2B 8c0d02ca8bce7d70eb1016d4676eb35da5c20d1e2c5e65602d8d7414e2ee8bec9bf13399dd3576a3379b62ebc3d7fd7ba85ea33cc1ff2c179278a59bf623daf3 SHA512 1c9615858fc778832566991ee4802c0929c81a9b0b720e5db90b4bb0baff718fa0ba589fe33444ee7eb040622081d60c10036af2b199bf2bd0a7f5f45ba71c72 diff --git a/games-simulation/searchandrescue/metadata.xml b/games-simulation/searchandrescue/metadata.xml new file mode 100644 index 000000000000..183ecc5ceeeb --- /dev/null +++ b/games-simulation/searchandrescue/metadata.xml @@ -0,0 +1,9 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "https://docs.baldeagleos.com/dtd/metadata.dtd"> +<pkgmetadata> + <maintainer type="project"> + <email>games@gentoo.org</email> + <name>Gentoo Games Project</name> + </maintainer> + <origin>baldeagleos-repo</origin> +</pkgmetadata> diff --git a/games-simulation/searchandrescue/searchandrescue-1.7.0-r1.ebuild b/games-simulation/searchandrescue/searchandrescue-1.7.0-r1.ebuild new file mode 100644 index 000000000000..2184c91d8caa --- /dev/null +++ b/games-simulation/searchandrescue/searchandrescue-1.7.0-r1.ebuild @@ -0,0 +1,80 @@ +# Copyright 1999-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +inherit desktop flag-o-matic prefix toolchain-funcs xdg + +MY_PN=SearchAndRescue +DESCRIPTION="Helicopter based air rescue flight simulator" +HOMEPAGE="https://searchandrescue.sourceforge.net/" +SRC_URI="https://downloads.sourceforge.net/searchandrescue/${MY_PN}-${PV}.tar.gz -> ${MY_PN}-${PV}.tar + https://downloads.sourceforge.net/searchandrescue/${MY_PN}-data-${PV}.tar.gz -> ${MY_PN}-data-${PV}.tar + https://downloads.sourceforge.net/searchandrescue/${MY_PN}-data-guadarrama-${PV}.tar.gz -> ${MY_PN}-data-guadarrama-${PV}.tar" +S="${WORKDIR}"/${PN}_${PV} + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="~amd64 ~x86" + +RDEPEND=" + media-libs/libsdl[joystick] + media-libs/sdl-mixer + virtual/glu + virtual/opengl + x11-libs/libICE + x11-libs/libSM + x11-libs/libXi + x11-libs/libXmu + x11-libs/libXpm + x11-libs/libXxf86vm +" + +DEPEND="${RDEPEND} + x11-base/xorg-proto" + +src_unpack() { + unpack ${MY_PN}-${PV}.tar + mkdir data || die + cd data || die + unpack ${MY_PN}-data-${PV}.tar + unpack ${MY_PN}-data-guadarrama-${PV}.tar + bunzip2 "${S}"/sar/man/${MY_PN}.6.bz2 || die +} + +src_prepare() { + xdg_src_prepare + + chmod +x configure || die + rm pconf/pconf || die + sed -i "/PlatformSearchPathLib/s:/lib/:/$(get_libdir)/:g" sar/platforms.ini || die + hprefixify sar/platforms.ini +} + +src_configure() { + export CC="$(tc-getCC) ${CFLAGS} ${CPPFLAGS} ${LDFLAGS}" \ + CPP="$(tc-getCXX) ${LDFLAGS}" + + append-flags -DNEW_GRAPHICS -DHAVE_SDL_MIXER + + # Needed for the configure script + emake -C pconf pconf CC="${CC}" + + # NOTE: not an autoconf script + ./configure Linux --prefix="${EPREFIX}/usr" || die + sed -i -r 's/^(\s+)@/\1/' sar/Makefile || die +} + +src_compile() { + emake -C sar LIB_DIRS= +} + +src_install() { + dobin sar/${MY_PN} + doman sar/man/${MY_PN}.6 + dodoc AUTHORS HACKING README + doicon sar/icons/${MY_PN}.xpm + insinto /usr/share/games/${PN} + doins -r ../data/* + make_desktop_entry ${MY_PN} "Search and Rescue" ${MY_PN} +} diff --git a/games-simulation/senken/Manifest b/games-simulation/senken/Manifest new file mode 100644 index 000000000000..acab9c6f79f7 --- /dev/null +++ b/games-simulation/senken/Manifest @@ -0,0 +1 @@ +DIST senken-0.3.0.tar.gz 1391010 BLAKE2B ac55f61c6a1c86ca3a891190f562e91aaed56f19f08dffe2a17016dd8ef5e35a3e1c6188b402506d063c4ee812a43f63bfd45b58e102c4a1199a733ab336a8dc SHA512 df0c15cabf667fb7b56db40baf03fcae6695aa9ec0e42a7db682ff20877a5b89ee67e7799e762b4a78cf0f3fdee7f001419091f0683df74ba1bbe6b9501f0272 diff --git a/games-simulation/senken/files/senken-0.3.0-as-needed.patch b/games-simulation/senken/files/senken-0.3.0-as-needed.patch new file mode 100644 index 000000000000..428cbc9ee4c6 --- /dev/null +++ b/games-simulation/senken/files/senken-0.3.0-as-needed.patch @@ -0,0 +1,24 @@ +diff -ru senken-0.3.0.orig/server/Makefile.in senken-0.3.0/server/Makefile.in +--- senken-0.3.0.orig/server/Makefile.in 2003-11-20 02:30:15.000000000 -0500 ++++ senken-0.3.0/server/Makefile.in 2014-10-30 10:58:51.202157036 -0400 +@@ -10,7 +10,7 @@ + + DEFS = @DEFS@ + CPPFLAGS = -I$(srcdir)/../lib -I$(srcdir) -I$(srcdir)/.. @CPPFLAGS@ +-LIBS = ../lib/libsenken.a @LIBS@ @LIBINTL@ ++LIBS = ../lib/libsenken.a @LIBS@ @LIBINTL@ -lm + + prefix = @prefix@ + exec_prefix = @exec_prefix@ +diff -ru senken-0.3.0.orig/src/Makefile.in senken-0.3.0/src/Makefile.in +--- senken-0.3.0.orig/src/Makefile.in 2003-11-20 02:30:16.000000000 -0500 ++++ senken-0.3.0/src/Makefile.in 2014-10-30 10:59:05.154704393 -0400 +@@ -8,7 +8,7 @@ + + DEFS = @DEFS@ + CPPFLAGS = -I$(srcdir)/../lib -I$(srcdir) -I$(srcdir)/.. @CPPFLAGS@ @GTK_CFLAGS@ +-LIBS = ../lib/libsenken.a @LIBS@ @GTK_LIBS@ ++LIBS = ../lib/libsenken.a @LIBS@ @GTK_LIBS@ -lm + + prefix = @prefix@ + exec_prefix = @exec_prefix@ diff --git a/games-simulation/senken/files/senken-0.3.0-implicit-function-decl.patch b/games-simulation/senken/files/senken-0.3.0-implicit-function-decl.patch new file mode 100644 index 000000000000..f4792cfb0649 --- /dev/null +++ b/games-simulation/senken/files/senken-0.3.0-implicit-function-decl.patch @@ -0,0 +1,29 @@ +--- a/src/callbacks.c ++++ b/src/callbacks.c +@@ -47,6 +47,7 @@ + #include "client.h" + #include "landvalue.h" + #include "gtkhelp_reports.h" ++#include "support.h" + + #include "sdlwin.h" + #include "utils.h" +--- a/src/gtkhelp_reports.c ++++ b/src/gtkhelp_reports.c +@@ -5,6 +5,7 @@ + #include "player.h" + #include "client.h" + #include "gtkhelp_reports.h" ++#include "support.h" + + /**** HELPERS ****/ + +--- a/src/gtkhelp_reports.h ++++ b/src/gtkhelp_reports.h +@@ -17,4 +17,6 @@ extern void update_population_report(GtkWidget *window, client_t *client); + extern void setup_info_treeview(GtkWidget *window); + extern void update_info_report(GtkWidget *window, client_t *client, int mapx, int mapy); + ++extern void update_info_window(GtkWidget *window, client_t *client, int mapx, int mapy); ++ + #endif /* GTKHELP_REPORTS */ diff --git a/games-simulation/senken/files/senken-0.3.0-warnings.patch b/games-simulation/senken/files/senken-0.3.0-warnings.patch new file mode 100644 index 000000000000..b15565ad0a90 --- /dev/null +++ b/games-simulation/senken/files/senken-0.3.0-warnings.patch @@ -0,0 +1,31 @@ +diff -ru senken-0.3.0.orig/server/protocol.c senken-0.3.0/server/protocol.c +--- senken-0.3.0.orig/server/protocol.c 2003-11-20 02:30:15.000000000 -0500 ++++ senken-0.3.0/server/protocol.c 2014-10-30 11:04:39.831848871 -0400 +@@ -294,7 +294,7 @@ + /* + * If transaction active just save this for later + */ +- if (connection_txn_active) { ++ if (connection_txn_active(conn)) { + set_op_t *op = calloc(1, sizeof(set_op_t)); + int r; + +diff -ru senken-0.3.0.orig/src/gtkhelp_reports.c senken-0.3.0/src/gtkhelp_reports.c +--- senken-0.3.0.orig/src/gtkhelp_reports.c 2003-11-20 02:30:16.000000000 -0500 ++++ senken-0.3.0/src/gtkhelp_reports.c 2014-10-30 11:06:43.795828908 -0400 +@@ -1,3 +1,4 @@ ++#include <string.h> + #include <gtk/gtk.h> + #include <gdk/gdk.h> + +diff -ru senken-0.3.0.orig/src/main.c senken-0.3.0/src/main.c +--- senken-0.3.0.orig/src/main.c 2003-11-20 02:30:16.000000000 -0500 ++++ senken-0.3.0/src/main.c 2014-10-30 11:06:28.147336339 -0400 +@@ -25,6 +25,7 @@ + # include <config.h> + #endif + ++#include <string.h> + #include <unistd.h> + #include <signal.h> + #include <gtk/gtk.h> diff --git a/games-simulation/senken/metadata.xml b/games-simulation/senken/metadata.xml new file mode 100644 index 000000000000..183ecc5ceeeb --- /dev/null +++ b/games-simulation/senken/metadata.xml @@ -0,0 +1,9 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "https://docs.baldeagleos.com/dtd/metadata.dtd"> +<pkgmetadata> + <maintainer type="project"> + <email>games@gentoo.org</email> + <name>Gentoo Games Project</name> + </maintainer> + <origin>baldeagleos-repo</origin> +</pkgmetadata> diff --git a/games-simulation/senken/senken-0.3.0-r2.ebuild b/games-simulation/senken/senken-0.3.0-r2.ebuild new file mode 100644 index 000000000000..a9c9fdf39deb --- /dev/null +++ b/games-simulation/senken/senken-0.3.0-r2.ebuild @@ -0,0 +1,62 @@ +# Copyright 1999-2023 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +inherit autotools + +DESCRIPTION="City simulation game" +HOMEPAGE="https://savannah.nongnu.org/projects/senken/" +SRC_URI="mirror://gentoo/${P}.tar.gz" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="~amd64 ~x86" +IUSE="nls" + +RDEPEND=" + >=media-libs/libsdl-1.2.4 + media-libs/sdl-image + x11-libs/gtk+:2 + nls? ( virtual/libintl ) +" +DEPEND=" + ${RDEPEND} + nls? ( sys-devel/gettext ) +" + +PATCHES=( + "${FILESDIR}"/${P}-as-needed.patch + "${FILESDIR}"/${P}-warnings.patch + "${FILESDIR}"/${P}-implicit-function-decl.patch +) + +src_prepare() { + default + + sed -i \ + -e "s:/usr/local/share:/usr/share:" \ + lib/utils.h || die + + # Clang 16, bug #899022 + sed -i -e "s:configure.in:configure.ac:" Makefile.in || die + eautoconf +} + +src_configure() { + econf $(use_enable nls) +} + +src_install() { + default + + #dodir "${GAMES_DATADIR}" + #mv "${D}/${GAMES_PREFIX}/share/senken" "${D}/${GAMES_DATADIR}/" || die + #rm -rf "${D}/${GAMES_PREFIX}"/{include,lib,man,share} || die + + insinto /usr/share/senken/img + doins img/*.png + + find "${D}/usr/share/" -type f -exec chmod a-x \{\} + + find "${D}/usr/share/" -name "Makefile.*" -exec rm -f \{\} + +} diff --git a/games-simulation/simutrans-paksets/Manifest b/games-simulation/simutrans-paksets/Manifest new file mode 100644 index 000000000000..1af0a8608765 --- /dev/null +++ b/games-simulation/simutrans-paksets/Manifest @@ -0,0 +1,6 @@ +DIST simutrans_PAK128.german_2.1_for_ST_123.0.zip 249111808 BLAKE2B 40d8c70d57d6a508ff046791077be49f91429e44c43d25127f179e0f86ca2e94e0f6dfe8442e0c1e73ef79dd14895737239a9cc7555b69d911ba533ab5312d0b SHA512 17295ba03a91ec93f89d0a2856709cf26fa3525557d22cb48bd51b0baf86b0f7ce1a249cd5b360ff6c35f9028b49dd0f951884ca0042eda6d531bb1fe841518e +DIST simutrans_pak.nippon-v0.5.0.zip 16576816 BLAKE2B 67f81e738006561ccbcc7d362d78c4985dd6d6be3f8b2a5817ea49077406b0d6ae2595b9ec18816661ef94e9a0745884b03f4232567fbeaad9529f77f847dc72 SHA512 a7f30277a69b21202cef10d8379c81694aa664cf4644c38d89c6ccac82659fc2f746a9fc3536b5795c2818957cfd801990df7bbfe0eb9624c2f8a8fcb8854f48 +DIST simutrans_pak128.CS-r2096.zip 18908413 BLAKE2B 1eeb78efb83f882fe977de7290883968db7488ecbe16076b7795e6d69899456c41f83b9c04df3193a2b799fef9d444aa487c9ca5886a1c859b79001abcbbf5ab SHA512 15d2d85fa628b553bb2e367fb109b37b81914414f0a7c82e4816b88262d34dc621eeb2a31a593cb25014bd76207776d48afd61a5a5f47204b37d287bc68e05f0 +DIST simutrans_pak192.comic.0.6.RC2.zip 125425374 BLAKE2B 3132c04788312f429ea8277e7f83796fa16b97f8c28cb92826824752d3ab66d7afeca2987380882e2c6f3368b52334af50f772673154fb0615ff334506483f14 SHA512 5c052cd8b3fc447db7c1618b00462c0750c94d659e2050710ba2b2fa440099639100fff968ff80b2ca2868237fbbec560cc5fb14ee32f296ce434b05832ce336 +DIST simutrans_pak48.excentrique_v019rc3.zip 550330 BLAKE2B 954dcfac50246e3679d7266762baf30cae51f20813c10c0fbf493fe1c9636d07cb8329d963cbb9c61adfffdf6df8b44bb64116d728c3811c79601db441bf07e9 SHA512 8c2e7609984b82bed2006fb50adc7fa7e56e9006d4a4968f9da41f0cbe7437b83c9e9937b08489ac565b42868a951e25c19f6f2b5abfaafb50134dd2dfdf5b50 +DIST simutrans_simupak128-2.8.2-for123.zip 96971372 BLAKE2B 74385cb5b7765fb7306bd036fc0ab6d57e792b694894f39043bb1b9c0412d6fb56d8048bb3fdd60a3a52dd7498e9dd22edf4875116ed7def080383344b376225 SHA512 f2aca6c787ba218cae4677ed35764b17230cefafa358d4c238856c2ec91b75d13a557dd8369d536c0c76b00c6a029f71ebb778d5210a21a44a2c57da15ab0bc2 diff --git a/games-simulation/simutrans-paksets/metadata.xml b/games-simulation/simutrans-paksets/metadata.xml new file mode 100644 index 000000000000..e90b4e84d033 --- /dev/null +++ b/games-simulation/simutrans-paksets/metadata.xml @@ -0,0 +1,13 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "https://docs.baldeagleos.com/dtd/metadata.dtd"> +<pkgmetadata> + <use> + <flag name="128">Install higher resolution scenario data (128 px graphics)</flag> + <flag name="comic192">Install comic-like scenario data (192 px graphics)</flag> + <flag name="cs128">Install Czech-Slovak scenario data (128 px graphics)</flag> + <flag name="excentrique48">Install eccentric scenario data (48 px graphics)</flag> + <flag name="german128">Install German scenario data (128 px graphics)</flag> + <flag name="nippon64">Install Nippon scenario data (64 px graphics)</flag> + </use> + <origin>baldeagleos-repo</origin> +</pkgmetadata> diff --git a/games-simulation/simutrans-paksets/simutrans-paksets-123.0.1.ebuild b/games-simulation/simutrans-paksets/simutrans-paksets-123.0.1.ebuild new file mode 100644 index 000000000000..e21c03b9ce37 --- /dev/null +++ b/games-simulation/simutrans-paksets/simutrans-paksets-123.0.1.ebuild @@ -0,0 +1,55 @@ +# Copyright 2022-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +MY_PAK_CS_128="pak128.CS-r2096.zip" +MY_PAK_GERMAN_128="PAK128.german_2.1_for_ST_123.0.zip" +MY_PAK_128="simupak128-2.8.2-for123.zip" + +DESCRIPTION="PakSets (scenario data) for games-simulation/simutrans" +HOMEPAGE="https://www.simutrans.com/paksets/" +SRC_URI=" + 128? ( https://downloads.sourceforge.net/simutrans/${MY_PAK_128} -> simutrans_${MY_PAK_128} ) + comic192? ( https://github.com/Flemmbrav/Pak192.Comic/releases/download/2021-V0.6-RC2/pak192.comic.0.6.RC2.zip -> simutrans_pak192.comic.0.6.RC2.zip ) + cs128? ( https://downloads.sourceforge.net/simutrans/${MY_PAK_CS_128} -> simutrans_${MY_PAK_CS_128} ) + german128? ( https://downloads.sourceforge.net/simutrans/${MY_PAK_GERMAN_128} -> simutrans_${MY_PAK_GERMAN_128} ) + nippon64? ( https://github.com/wa-st/pak-nippon/releases/download/v0.5.0/pak.nippon-v0.5.0.zip -> simutrans_pak.nippon-v0.5.0.zip ) + excentrique48? ( https://github.com/Varkalandar/pak48.Excentrique/releases/download/v0.19_RC3/pak48.excentrique_v019rc3.zip -> simutrans_pak48.excentrique_v019rc3.zip ) +" +S="${WORKDIR}" + +LICENSE=" + 128? ( Artistic-2 ) + comic192? ( CC-BY-SA-3.0 ) + cs128? ( Artistic-2 ) + excentrique48? ( CC-BY-SA-4.0 ) + german128? ( PAK128.German ) + nippon64? ( MIT ) +" +SLOT="0" +KEYWORDS="~amd64 ~arm64 ~x86" +IUSE="+128 comic192 cs128 excentrique48 german128 nippon64" +REQUIRED_USE="|| ( 128 comic192 cs128 excentrique48 german128 nippon64 )" + +RDEPEND="!<games-simulation/simutrans-123.0" +BDEPEND="app-arch/unzip" + +src_prepare() { + default + + # Only 128 and german128 have a simutrans/ folder. + if [[ -d simutrans ]]; then + mv simutrans/* . || die + rmdir simutrans || die + fi + + if use comic192; then + mv pak192.comic-nightly-datconverter pak192.comic || die + fi +} + +src_install() { + insinto usr/share/simutrans + doins -r * +} diff --git a/games-simulation/simutrans/Manifest b/games-simulation/simutrans/Manifest new file mode 100644 index 000000000000..b63c62ce5b5d --- /dev/null +++ b/games-simulation/simutrans/Manifest @@ -0,0 +1,3 @@ +DIST simutrans-src-124-2-1.zip 5463858 BLAKE2B 034dabd8a74a9dc9d57f72d92179a27c97a718a27470938d4054283d45e0d6b3a9bb34e31ec3b2574e90e1f9d1ebf27a2343ee760818ebc8b109f758fc45a131 SHA512 e8cd229a08e52542f0760227889f0db30017f43ddf44789770a6d6fe9e76d6b82288d2174381e4ab22391cacad97201dc10bc83d1e51a8947b82c5a013450d35 +DIST simutrans_language_pack-Base+texts-124.2.1.zip 1234798 BLAKE2B a2a3aed3783156fa8738087107898d284d867109ad0f50d0435efb391fca9fe1f3d14e225e21deb199e213148abeece4eb47257f3e1c91d0b82d3680fae34d4f SHA512 3007662f6e3132966a2bff1384bf32fba9cf6a55df5cd4e337b08c67d7397ad13fd924831709415c015b72a7f7ae0bba432fa13e23c87f14709cd7e0dfa7b939 +DIST simutrans_simupak64-124-2.zip 5092179 BLAKE2B d953368405ff560eafc25eaa5412a72f3ad7b2344ee9e3ada09922d0291768fb710c4ec9a4ebc0823ac84a4226178c81befaf11c958d771bb15f6f7c7c344f6d SHA512 f2edd7ca15966d7c0284637c3f90d335fd34202d8120e92297de4cc451a6c9c543532e3d5ea38181f59e70db4a6d0bae4da0c240556391e3d5872e782e6bb73d diff --git a/games-simulation/simutrans/files/simutrans-124.0-disable-svn-check.patch b/games-simulation/simutrans/files/simutrans-124.0-disable-svn-check.patch new file mode 100644 index 000000000000..889378aba76b --- /dev/null +++ b/games-simulation/simutrans/files/simutrans-124.0-disable-svn-check.patch @@ -0,0 +1,33 @@ +From 1064daf38a99d67a78b1117a289fc72349f1fad9 Mon Sep 17 00:00:00 2001 +From: tastytea <gentoo@tastytea.de> +Date: Thu, 9 May 2024 12:59:04 +0200 +Subject: [PATCH] disable svn check + +--- + configure.ac | 10 +++------- + 1 file changed, 3 insertions(+), 7 deletions(-) + +diff --git a/configure.ac b/configure.ac +index c611af3..b8e3efa 100644 +--- a/configure.ac ++++ b/configure.ac +@@ -145,13 +145,9 @@ else + fi + + +-# are we in a svn? +-if svn info +-then +- AC_SUBST(svn, 1) +-else +- AC_SUBST(svn, 0) +-fi ++# we are not in an svn ++AC_SUBST(svn, 0) ++ + + + #switch off assembler on 64 bit (MISSING: Check for GNU Assembler and i86) +-- +2.43.2 + diff --git a/games-simulation/simutrans/files/simutrans.desktop b/games-simulation/simutrans/files/simutrans.desktop new file mode 100644 index 000000000000..01d1ec4022f4 --- /dev/null +++ b/games-simulation/simutrans/files/simutrans.desktop @@ -0,0 +1,10 @@ +[Desktop Entry] +Type=Application +Name=Simutrans +Encoding=UTF-8 +Comment=A free Transport Tycoon clone +TryExec=simutrans +Exec=simutrans +Icon=simutrans +Terminal=false +Categories=Game;Simulation diff --git a/games-simulation/simutrans/metadata.xml b/games-simulation/simutrans/metadata.xml new file mode 100644 index 000000000000..19806bcf02be --- /dev/null +++ b/games-simulation/simutrans/metadata.xml @@ -0,0 +1,17 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "https://docs.baldeagleos.com/dtd/metadata.dtd"> +<pkgmetadata> + <use> + <flag name="minimal">Don't install any PakSets (scenario data)</flag> + <flag name="midi">support for background MIDI music via <pkg>media-sound/fluidsynth</pkg> + </flag> + </use> + <longdescription lang="en"> + Simutrans is a freeware and open-source transportation simulator. Your + goal is to establish a successful transport company. Transport + passengers, mail and goods by rail, road, ship, and even air. + Interconnect districts, cities, public buildings, industries and tourist + attractions by building a transport network you always dreamed of. + </longdescription> + <origin>baldeagleos-repo</origin> +</pkgmetadata> diff --git a/games-simulation/simutrans/simutrans-124.2.1.ebuild b/games-simulation/simutrans/simutrans-124.2.1.ebuild new file mode 100644 index 000000000000..194b40bb3166 --- /dev/null +++ b/games-simulation/simutrans/simutrans-124.2.1.ebuild @@ -0,0 +1,113 @@ +# Copyright 1999-2025 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +inherit autotools desktop flag-o-matic toolchain-funcs xdg + +MY_PV=${PV//./-} +MY_PAK_64="simupak64-124-2.zip" # NOTE: usually this is ${MY_PV} +# Required for network games, published in release announcement on the forums +# <https://forum.simutrans.com/index.php/board,3.0.html> +MY_SVN_REVISION="11366" + +DESCRIPTION="A free Transport Tycoon clone" +HOMEPAGE="https://www.simutrans.com/" +SRC_URI=" + https://downloads.sourceforge.net/simutrans/simutrans-src-${MY_PV}.zip + !minimal? ( https://downloads.sourceforge.net/simutrans/${MY_PAK_64} -> simutrans_${MY_PAK_64} ) + https://tastytea.de/files/gentoo/simutrans_language_pack-Base+texts-${PV}.zip +" +S="${WORKDIR}/trunk" + +# NOTE: get the latest language pack from: +# https://simutrans-germany.com/translator/data/tab/language_pack-Base+texts.zip + +LICENSE="Artistic" +SLOT="0" +KEYWORDS="~amd64 ~arm64 ~x86" +IUSE="minimal +midi fontconfig upnp zstd" + +DEPEND=" + app-arch/bzip2 + media-libs/freetype + media-libs/libpng:0= + media-libs/libsdl2[sound,video] + virtual/zlib:= + midi? ( media-sound/fluidsynth:=[sdl] ) + fontconfig? ( media-libs/fontconfig ) + upnp? ( net-libs/miniupnpc:= ) + zstd? ( app-arch/zstd ) +" +RDEPEND=" + ${DEPEND} + midi? ( media-sound/fluid-soundfont ) + !<games-simulation/simutrans-paksets-${PV} +" +BDEPEND=" + app-arch/unzip + virtual/pkgconfig +" +RESTRICT="test" # Opens the program and doesn't close it. + +PATCHES=( + "${FILESDIR}"/${PN}-124.0-disable-svn-check.patch +) + +src_unpack() { + unpack "simutrans-src-${MY_PV}.zip" + cd trunk/simutrans || die "could not cd to 'simutrans'" + use minimal || unpack "simutrans_${MY_PAK_64}" + + # Bundled text files are incomplete, bug #580948 + cd text || die "could not cd to 'simutrans/text'" + unpack "simutrans_language_pack-Base+texts-${PV}.zip" +} + +src_prepare() { + default + xdg_environment_reset + + strip-flags # bug #293927 + append-flags -fno-strict-aliasing # bug #859229 + + eautoreconf +} + +src_configure() { + default + + # NOTE: some flags need to be 0, some need to be empty to turn them off + cat > config.default <<-EOF || die + BACKEND=sdl2 + OSTYPE=linux + OPTIMISE=0 + STATIC=0 + WITH_REVISION=${MY_SVN_REVISION} + MULTI_THREAD=1 + USE_UPNP=$(usex upnp 1 '') + USE_FREETYPE=1 + USE_ZSTD=$(usex zstd 1 '') + USE_FONTCONFIG=$(usex fontconfig 1 '') + USE_FLUIDSYNTH_MIDI=$(usex midi 1 '') + VERBOSE=1 + + HOSTCC = $(tc-getCC) + HOSTCXX = $(tc-getCXX) + EOF +} + +src_install() { + newbin build/default/sim ${PN} + insinto usr/share/${PN} + doins -r simutrans/* + doicon src/simutrans/${PN}.svg + domenu src/linux/simutrans.desktop +} + +pkg_postinst() { + xdg_pkg_postinst + + elog "Since 124.0 simutrans allows you to download PakSets to your home directory," + elog "therefore games-simulation/simutrans-paksets has been deprecated." +} diff --git a/games-simulation/singularity/Manifest b/games-simulation/singularity/Manifest new file mode 100644 index 000000000000..e1c83f6ea1e5 --- /dev/null +++ b/games-simulation/singularity/Manifest @@ -0,0 +1,2 @@ +DIST endgame-singularity-music-007.zip 51774799 BLAKE2B 78595b16e422d2312be860686aca9401f6f1eed35fe40dbbc3a3999b1feb5e32aa6d51a66d94c9241aca2b6606bb7135491298b94c8033a1437c2cd7b23f9120 SHA512 ab46e77c833085f0c5b1b46fef72ab807e79ca422ad043ef67a4bf4384cb0177319f21b4bd01496e6c3fc6fe9a2f36ec256e19f0e829ad7bf9f0c5bd38bf0fe5 +DIST singularity-1.00.tar.gz 1944972 BLAKE2B 1ca2b120311a19f175014835930610583e8f605dbda3ca3ca96d7e0da86bddeb4b0a264f50a003aa51e05b86ce971255ffda5f498598dde6be370b9a953eb1d0 SHA512 f3581048c5a535fdbd28d2af1ac596f5396fd712b716931f17de75f8b170f0e226deb2c113023357e21e7de1294e4a632515962df9ee43768baf0fb4bbaa08da diff --git a/games-simulation/singularity/files/singularity-1.00-numpy2.patch b/games-simulation/singularity/files/singularity-1.00-numpy2.patch new file mode 100644 index 000000000000..d3133f161e5f --- /dev/null +++ b/games-simulation/singularity/files/singularity-1.00-numpy2.patch @@ -0,0 +1,10 @@ +https://bugs.gentoo.org/936525 +https://github.com/singularity/singularity/issues/346 +https://github.com/singularity/singularity/commit/57013b621d641ae9b0b2554918807a88b7727b87 +--- a/singularity/code/buyable.py ++++ b/singularity/code/buyable.py +@@ -185,3 +185,3 @@ + was_complete = self.cost_paid +- cost_paid = numpy.maximum(numpy.cast[int64](numpy.round(raw_paid)), ++ cost_paid = numpy.maximum(numpy.asarray(numpy.round(raw_paid), dtype=int64), + was_complete) diff --git a/games-simulation/singularity/metadata.xml b/games-simulation/singularity/metadata.xml new file mode 100644 index 000000000000..183ecc5ceeeb --- /dev/null +++ b/games-simulation/singularity/metadata.xml @@ -0,0 +1,9 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "https://docs.baldeagleos.com/dtd/metadata.dtd"> +<pkgmetadata> + <maintainer type="project"> + <email>games@gentoo.org</email> + <name>Gentoo Games Project</name> + </maintainer> + <origin>baldeagleos-repo</origin> +</pkgmetadata> diff --git a/games-simulation/singularity/singularity-1.00-r3.ebuild b/games-simulation/singularity/singularity-1.00-r3.ebuild new file mode 100644 index 000000000000..fac2a8055f51 --- /dev/null +++ b/games-simulation/singularity/singularity-1.00-r3.ebuild @@ -0,0 +1,58 @@ +# Copyright 1999-2026 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +DISTUTILS_SINGLE_IMPL=1 +DISTUTILS_USE_PEP517=setuptools +PYTHON_COMPAT=( python3_{13..14} ) +inherit desktop distutils-r1 + +SINGULARITY_MUSIC=endgame-${PN}-music-007 + +DESCRIPTION="Simulation of a true AI. Go from computer to computer, chased by the whole world" +HOMEPAGE="http://www.emhsoft.com/singularity/" +SRC_URI=" + https://github.com/singularity/singularity/releases/download/v${PV}/${P}.tar.gz + https://emhsoft.com/singularity/${SINGULARITY_MUSIC}.zip" + +LICENSE="GPL-2+ BitstreamVera CC0-1.0 CC-BY-SA-3.0" +SLOT="0" +KEYWORDS="~amd64 ~x86" +REQUIRED_USE="${PYTHON_REQUIRED_USE}" + +RDEPEND=" + $(python_gen_cond_dep ' + dev-python/numpy[${PYTHON_USEDEP}] + dev-python/polib[${PYTHON_USEDEP}] + dev-python/pygame[${PYTHON_USEDEP}] + ') + media-libs/sdl2-image[jpeg,png] + media-libs/sdl2-mixer[vorbis] + !app-containers/apptainer + !sys-cluster/singularity +" +BDEPEND="app-arch/unzip" + +distutils_enable_sphinx docs + +EPYTEST_PLUGINS=() +distutils_enable_tests pytest + +PATCHES=( + "${FILESDIR}"/${P}-numpy2.patch +) + +python_install() { + distutils-r1_python_install + + python_moduleinto ${PN}/music + python_domodule "${WORKDIR}"/${SINGULARITY_MUSIC}/. +} + +python_install_all() { + dodoc AUTHORS.txt Changelog.txt README.txt TODO + + newicon ${PN}/data/themes/default/images/icon.png ${PN}.png + domenu ${PN}.desktop +} diff --git a/games-simulation/sky-rogue/Manifest b/games-simulation/sky-rogue/Manifest new file mode 100644 index 000000000000..e95da2810216 --- /dev/null +++ b/games-simulation/sky-rogue/Manifest @@ -0,0 +1 @@ +DIST sky-rogue-linux.zip 155725341 BLAKE2B e5c55aac026f57ce97711be21bdff4d33499f54569f4be6a4705488cc95afd7f5c94f6640b95266aa5da6229fcce0387a40aadd577c5a47f6639d92fab0b8d1a SHA512 df0809675e85884a3d45f3ac2afbe2c475a0662f96e917574dd097ccd1fcbfd8a4b84f1b66b4d0c7ad52c73ccb44e686ee3fd6505fb7ea6ea2be42dfcb0d9b58 diff --git a/games-simulation/sky-rogue/metadata.xml b/games-simulation/sky-rogue/metadata.xml new file mode 100644 index 000000000000..183ecc5ceeeb --- /dev/null +++ b/games-simulation/sky-rogue/metadata.xml @@ -0,0 +1,9 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "https://docs.baldeagleos.com/dtd/metadata.dtd"> +<pkgmetadata> + <maintainer type="project"> + <email>games@gentoo.org</email> + <name>Gentoo Games Project</name> + </maintainer> + <origin>baldeagleos-repo</origin> +</pkgmetadata> diff --git a/games-simulation/sky-rogue/sky-rogue-1.3.3.ebuild b/games-simulation/sky-rogue/sky-rogue-1.3.3.ebuild new file mode 100644 index 000000000000..e8b9b3ac8a61 --- /dev/null +++ b/games-simulation/sky-rogue/sky-rogue-1.3.3.ebuild @@ -0,0 +1,51 @@ +# Copyright 1999-2025 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +inherit desktop wrapper xdg + +MY_PN="${PN//-}" +DESCRIPTION="A fwooshy rogue-lite action flight simulator" +HOMEPAGE="https://skyroguegame.com/" +SRC_URI="${PN}-linux.zip" +S="${WORKDIR}" + +LICENSE="all-rights-reserved" +SLOT="0" +KEYWORDS="-* ~amd64 ~x86" +RESTRICT="bindist fetch splitdebug" + +RDEPEND=" + virtual/zlib:= + virtual/opengl +" + +BDEPEND=" + app-arch/unzip +" + +DIR="/opt/${PN}" +QA_PREBUILT="${DIR#/}/*" + +pkg_nofetch() { + einfo "Please buy and download ${SRC_URI} from:" + einfo " https://fractal-phase.itch.io/${PN}" + einfo "and move it to your distfiles directory." +} + +src_install() { + exeinto "${DIR}" + newexe ${MY_PN}.$(usex amd64 x86_64 x86) ${MY_PN} + make_wrapper ${PN} "${DIR}"/${MY_PN} + + insinto "${DIR}" + doins -r ${MY_PN}_Data/ + rm -r "${ED}/${DIR}"/${MY_PN}_Data/*/$(usex amd64 x86 x86_64) || die + + # Some Unity games have a GUI launcher but this one doesn't use it. + rm "${ED}/${DIR}"/${MY_PN}_Data/Plugins/*/ScreenSelector.so || die + + newicon -s 128 ${MY_PN}_Data/Resources/UnityPlayer.png ${PN}.png + make_desktop_entry ${PN} "Sky Rogue" +} diff --git a/games-simulation/slime-rancher/Manifest b/games-simulation/slime-rancher/Manifest new file mode 100644 index 000000000000..07b70c9122a5 --- /dev/null +++ b/games-simulation/slime-rancher/Manifest @@ -0,0 +1 @@ +DIST slime_rancher_1_4_1c_34605.sh 637631767 BLAKE2B e3742178acfb9b80429117a37e8c7ec226345fb20b762ef80ca7ff7d58bcde039a199db5f352e78ce6935b6b261924780f54c84dd706a8031b427c9bd52de2a7 SHA512 c9124a7685c12dab942cde3e4b7e4140156c9d1551043d450c0c2f2eb02d1db61b99f22803b1058634abff86e783c889badf5834f0c2f7048a97dc168c962908 diff --git a/games-simulation/slime-rancher/metadata.xml b/games-simulation/slime-rancher/metadata.xml new file mode 100644 index 000000000000..183ecc5ceeeb --- /dev/null +++ b/games-simulation/slime-rancher/metadata.xml @@ -0,0 +1,9 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "https://docs.baldeagleos.com/dtd/metadata.dtd"> +<pkgmetadata> + <maintainer type="project"> + <email>games@gentoo.org</email> + <name>Gentoo Games Project</name> + </maintainer> + <origin>baldeagleos-repo</origin> +</pkgmetadata> diff --git a/games-simulation/slime-rancher/slime-rancher-1.4.1c_p34605.ebuild b/games-simulation/slime-rancher/slime-rancher-1.4.1c_p34605.ebuild new file mode 100644 index 000000000000..cfd97d2260c2 --- /dev/null +++ b/games-simulation/slime-rancher/slime-rancher-1.4.1c_p34605.ebuild @@ -0,0 +1,58 @@ +# Copyright 1999-2023 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +inherit desktop unpacker wrapper xdg + +MY_PN="SlimeRancher" +MY_P="${P//[-.]/_}" +MY_P="${MY_P//_p/_}" + +DESCRIPTION="Cute game where you cultivate slimes on a distant planet" +HOMEPAGE="https://www.slimerancher.com/" +SRC_URI="${MY_P}.sh" +S="${WORKDIR}/data/noarch/game" + +LICENSE="GOG-EULA" +SLOT="0" +KEYWORDS="-* ~amd64" +RESTRICT="bindist fetch splitdebug" + +RDEPEND=" + sys-libs/glibc + virtual/opengl +" +BDEPEND="app-arch/unzip" + +DIR="/opt/${PN}" +QA_PREBUILT="${DIR#/}/*" + +pkg_nofetch() { + einfo "Please buy and download ${SRC_URI} from:" + einfo " https://www.gog.com/game/${PN//-/_}" + einfo "and move it to your distfiles directory." +} + +src_unpack() { + unpack_zip ${A} +} + +src_prepare() { + default + + # Some Unity games have a GUI launcher but this one doesn't use it. + rm ${MY_PN}_Data/Plugins/x86_64/ScreenSelector.so || die +} + +src_install() { + exeinto "${DIR}" + newexe ${MY_PN}.x86_64 ${MY_PN} + make_wrapper ${PN} "${DIR}"/${MY_PN} + + insinto "${DIR}" + doins -r ${MY_PN}_Data/ + + newicon -s 128 ${MY_PN}_Data/Resources/UnityPlayer.png ${PN}.png + make_desktop_entry ${PN} "Slime Rancher" +} diff --git a/games-simulation/train-valley/Manifest b/games-simulation/train-valley/Manifest new file mode 100644 index 000000000000..2e3e1fcf138f --- /dev/null +++ b/games-simulation/train-valley/Manifest @@ -0,0 +1 @@ +DIST train_valley_1_3_31403.sh 196066169 BLAKE2B fe9e6ae5b0ef76794823dc86ed100fdac355d3929d85a9a12096f79cf9e6f946e2c85b5b737ebcab813ceef29094734f74546fff06124fe4bf07ef224d5842ff SHA512 16fd627f8ca6399579b17d7a4ce29caba554fbfb0dc72b40827f1c3a061d8c238a7faeb1b5171917362d381642e8cb066cdad5556fb71f4d27225bf227d735cd diff --git a/games-simulation/train-valley/metadata.xml b/games-simulation/train-valley/metadata.xml new file mode 100644 index 000000000000..2c0b10cf9bd2 --- /dev/null +++ b/games-simulation/train-valley/metadata.xml @@ -0,0 +1,12 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "https://docs.baldeagleos.com/dtd/metadata.dtd"> +<pkgmetadata> + <maintainer type="project"> + <email>games@gentoo.org</email> + <name>Gentoo Games Project</name> + </maintainer> + <use> + <flag name="gui">Install the GUI for configuring screen resolution and input</flag> + </use> + <origin>baldeagleos-repo</origin> +</pkgmetadata> diff --git a/games-simulation/train-valley/train-valley-1.3.31403.ebuild b/games-simulation/train-valley/train-valley-1.3.31403.ebuild new file mode 100644 index 000000000000..344e63467d7d --- /dev/null +++ b/games-simulation/train-valley/train-valley-1.3.31403.ebuild @@ -0,0 +1,66 @@ +# Copyright 1999-2021 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +inherit desktop unpacker wrapper xdg-utils + +DESCRIPTION="Build railroads in order to connect cities, tunnels, and bridges" +HOMEPAGE="http://train-valley.com/tv1.html" +SRC_URI="${P//[-.]/_}.sh" +S="${WORKDIR}/data/noarch/game" + +LICENSE="all-rights-reserved" +SLOT="0" +KEYWORDS="-* ~amd64 ~x86" +IUSE="+gui" +RESTRICT="bindist fetch splitdebug" + +RDEPEND=" + virtual/opengl + x11-libs/libX11 + x11-libs/libXrandr + gui? ( + dev-libs/glib:2 + x11-libs/gdk-pixbuf:2 + x11-libs/gtk+:2 + ) +" + +DIR="/opt/${PN}" +QA_PREBUILT="${DIR#/}/*" + +pkg_nofetch() { + einfo "Please buy and download ${SRC_URI} from:" + einfo " https://www.gog.com/game/${PN//-/_}" + einfo "and move it to your distfiles directory." +} + +src_unpack() { + unpack_zip ${A} +} + +src_install() { + exeinto "${DIR}" + newexe ${PN}.$(usex amd64 x86_64 x86) ${PN} + make_wrapper ${PN} "${DIR}"/${PN} + + insinto "${DIR}" + doins -r ${PN}_Data/ + rm -r "${ED}/${DIR}"/${PN}_Data/*/$(usex amd64 x86 x86_64) || die + + if ! use gui; then + rm "${ED}/${DIR}"/${PN}_Data/Plugins/*/ScreenSelector.so || die + fi + + newicon -s 128 ${PN}_Data/Resources/UnityPlayer.png ${PN}.png + make_desktop_entry ${PN} "Train Valley" +} + +pkg_postinst() { + xdg_icon_cache_update +} + +pkg_postrm() { + xdg_icon_cache_update +} |
