summaryrefslogtreecommitdiff
path: root/media-libs/libsfml
diff options
context:
space:
mode:
authorroot <root@alpha.trunkmasters.com>2026-06-04 05:48:38 -0500
committerroot <root@alpha.trunkmasters.com>2026-06-04 05:48:38 -0500
commitbfd9c39e4712ebdb442d4ca0673061faed1e70e1 (patch)
tree0d7a74b4463ee387f9cf9368ceb1b757f694f72a /media-libs/libsfml
parentf716a9fe6455d39eef01e718aae68dae61c19704 (diff)
downloadbaldeagleos-repo-bfd9c39e4712ebdb442d4ca0673061faed1e70e1.tar.gz
baldeagleos-repo-bfd9c39e4712ebdb442d4ca0673061faed1e70e1.tar.xz
baldeagleos-repo-bfd9c39e4712ebdb442d4ca0673061faed1e70e1.zip
Revert "Adding metadata"
This reverts commit f716a9fe6455d39eef01e718aae68dae61c19704.
Diffstat (limited to 'media-libs/libsfml')
-rw-r--r--media-libs/libsfml/Manifest2
-rw-r--r--media-libs/libsfml/files/libsfml-2.6.0-supress-werror.patch30
-rw-r--r--media-libs/libsfml/files/libsfml-3.0.0-catch-depend.patch28
-rw-r--r--media-libs/libsfml/libsfml-2.6.2.ebuild75
-rw-r--r--media-libs/libsfml/libsfml-3.0.1.ebuild97
-rw-r--r--media-libs/libsfml/metadata.xml17
6 files changed, 249 insertions, 0 deletions
diff --git a/media-libs/libsfml/Manifest b/media-libs/libsfml/Manifest
new file mode 100644
index 000000000000..5816fbcb0539
--- /dev/null
+++ b/media-libs/libsfml/Manifest
@@ -0,0 +1,2 @@
+DIST libsfml-2.6.2.tar.gz 28624288 BLAKE2B 52442ef05a2719c1e7cd45ba15a4a41af7f3026c7c3a01c55993769bde39c9426962d640ffa2ac293dd4d90b9290b5f0895fffe7c10d3ffadbc189b10001c7ff SHA512 d8a8bee3aa9acda4609104c2a9d4a2512e4be6d6e85fd4b24c287c03f60cfb888e669e61bfac4113dae35f0c3492559b65b3453baf38766d8c0223d9ab77aada
+DIST libsfml-3.0.1.tar.gz 4383964 BLAKE2B 00aa84ae65ee5d3994b1eac365b7231dde60d9d18243d9282d9660773b46c7292e8abdd19d0a64ebe9526e746c43ba479e5301da111ccbf127a8d26305364981 SHA512 cee56eef93728aef9b361f8b1080572532ce5247c80a9d1be53b30dab4d67e8588316890555d4c4ba423e87b09f954327d70615e1ba72d458d8238fa84e589f9
diff --git a/media-libs/libsfml/files/libsfml-2.6.0-supress-werror.patch b/media-libs/libsfml/files/libsfml-2.6.0-supress-werror.patch
new file mode 100644
index 000000000000..1110b4b89492
--- /dev/null
+++ b/media-libs/libsfml/files/libsfml-2.6.0-supress-werror.patch
@@ -0,0 +1,30 @@
+This primarily to suppress error such as:
+/var/tmp/portage/media-libs/libsfml-2.6.0/work/SFML-2.6.0/src/SFML/Window/Unix/JoystickImpl.cpp:405:36: error: implicit conversion changes signedness: 'unsigned long' to 'int' [-Werror,-Wsign-conversion]
+ int result = ioctl(fd, JSIOCGNAME(sizeof(name)), name);
+ ~~~~~ ^~~~~~~~~~~~~~~~~~~~~~~~
+/usr/include/linux/joystick.h:59:26: note: expanded from macro 'JSIOCGNAME'
+#define JSIOCGNAME(len) _IOC(_IOC_READ, 'j', 0x13, len) /* get identifier string */
+ ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+
+Even seems like upstream is has removed it with commit
+https://github.com/SFML/SFML/commit/aa82ea132b9296a31922772027ad5d14c1fa381b
+--- a/cmake/CompilerWarnings.cmake
++++ b/cmake/CompilerWarnings.cmake
+@@ -68,16 +68,11 @@ function(set_file_warnings)
+ # -Wimplicit-fallthrough # warn when a missing break causes control flow to continue at the next case in a switch statement (disabled until better compiler support for explicit fallthrough is available)
+ ${NON_ANDROID_CLANG_AND_GCC_WARNINGS}
+ )
+-
++
+ # Disable warnings as errors when using Clang on Windows to work around deprecation warnings in Windows APIs
+ if(SFML_OS_WINDOWS AND (SFML_COMPILER_CLANG OR SFML_COMPILER_CLANG_CL))
+ set(WARNINGS_AS_ERRORS FALSE)
+ endif()
+-
+- if(WARNINGS_AS_ERRORS)
+- set(CLANG_AND_GCC_WARNINGS ${CLANG_AND_GCC_WARNINGS} -Werror)
+- set(MSVC_WARNINGS ${MSVC_WARNINGS} /WX)
+- endif()
+
+ set(CLANG_WARNINGS
+ ${CLANG_AND_GCC_WARNINGS}
diff --git a/media-libs/libsfml/files/libsfml-3.0.0-catch-depend.patch b/media-libs/libsfml/files/libsfml-3.0.0-catch-depend.patch
new file mode 100644
index 000000000000..5a22a1f0ac82
--- /dev/null
+++ b/media-libs/libsfml/files/libsfml-3.0.0-catch-depend.patch
@@ -0,0 +1,28 @@
+Unbundle dev-cpp/catch
+https://bugs.gentoo.org/951166
+--- a/test/CMakeLists.txt
++++ b/test/CMakeLists.txt
+@@ -5,22 +5,9 @@
+
+ set(CATCH_CONFIG_FAST_COMPILE ON CACHE BOOL "")
+ set(CATCH_CONFIG_NO_EXPERIMENTAL_STATIC_ANALYSIS_SUPPORT ON CACHE BOOL "")
+-FetchContent_Declare(Catch2
+- GIT_REPOSITORY https://github.com/catchorg/Catch2.git
+- GIT_TAG v3.8.1
+- GIT_SHALLOW ON)
+-FetchContent_MakeAvailable(Catch2)
++find_package(Catch2 REQUIRED)
+ include(Catch)
+
+-# Build Catch2 in C++17 mode to enable C++17 features
+-target_compile_features(Catch2 PRIVATE cxx_std_17)
+-
+-# Ensure that Catch2 sources and headers are not analyzed by any tools
+-set_target_properties(Catch2 PROPERTIES COMPILE_OPTIONS "" EXPORT_COMPILE_COMMANDS OFF)
+-set_target_properties(Catch2WithMain PROPERTIES EXPORT_COMPILE_COMMANDS OFF)
+-set_target_properties(Catch2 Catch2WithMain PROPERTIES FOLDER "Dependencies")
+-get_target_property(CATCH2_INCLUDE_DIRS Catch2 INTERFACE_INCLUDE_DIRECTORIES)
+-target_include_directories(Catch2 SYSTEM INTERFACE ${CATCH2_INCLUDE_DIRS})
+
+ add_library(sfml-test-main STATIC
+ TestUtilities/SystemUtil.hpp
diff --git a/media-libs/libsfml/libsfml-2.6.2.ebuild b/media-libs/libsfml/libsfml-2.6.2.ebuild
new file mode 100644
index 000000000000..1788a2e4ab15
--- /dev/null
+++ b/media-libs/libsfml/libsfml-2.6.2.ebuild
@@ -0,0 +1,75 @@
+# Copyright 1999-2025 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit cmake
+
+DESCRIPTION="Simple and Fast Multimedia Library (SFML)"
+HOMEPAGE="https://www.sfml-dev.org/ https://github.com/SFML/SFML"
+SRC_URI="https://github.com/SFML/SFML/archive/${PV}.tar.gz -> ${P}.tar.gz"
+S="${WORKDIR}/SFML-${PV}"
+
+LICENSE="ZLIB"
+SLOT="0/$(ver_cut 1-2)"
+KEYWORDS="amd64 ~arm ~arm64 ~ppc64 ~riscv x86"
+IUSE="debug doc examples"
+
+RDEPEND="
+ media-libs/flac:=
+ media-libs/freetype:2
+ media-libs/libjpeg-turbo:=
+ media-libs/libogg
+ media-libs/libpng:=
+ media-libs/libvorbis
+ media-libs/openal
+ virtual/zlib:=
+ virtual/opengl
+ x11-libs/libX11
+ x11-libs/libXcursor
+ x11-libs/libXrandr
+ x11-libs/libxcb
+ x11-libs/xcb-util-image
+ kernel_linux? ( virtual/libudev:= )
+"
+DEPEND="
+ ${RDEPEND}
+ x11-base/xorg-proto
+"
+BDEPEND="
+ doc? ( app-text/doxygen )
+"
+
+DOCS=( changelog.md readme.md )
+
+PATCHES=( "${FILESDIR}"/libsfml-2.6.0-supress-werror.patch )
+
+src_prepare() {
+ sed -i "s:DESTINATION .*:DESTINATION /usr/share/doc/${PF}:" \
+ doc/CMakeLists.txt || die
+
+ find examples -name CMakeLists.txt -delete || die
+ cmake_src_prepare
+}
+
+src_configure() {
+ local mycmakeargs=(
+ -DSFML_BUILD_DOC=$(usex doc)
+ -DSFML_INSTALL_PKGCONFIG_FILES=TRUE
+ )
+
+ cmake_src_configure
+}
+
+src_install() {
+ cmake_src_install
+
+ insinto /usr/share/cmake/Modules
+ doins cmake/SFMLConfig.cmake.in
+ doins cmake/SFMLConfigDependencies.cmake.in
+
+ if use examples ; then
+ docompress -x /usr/share/doc/${PF}/examples
+ dodoc -r examples
+ fi
+}
diff --git a/media-libs/libsfml/libsfml-3.0.1.ebuild b/media-libs/libsfml/libsfml-3.0.1.ebuild
new file mode 100644
index 000000000000..6ce46a2f98f0
--- /dev/null
+++ b/media-libs/libsfml/libsfml-3.0.1.ebuild
@@ -0,0 +1,97 @@
+# Copyright 1999-2025 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit cmake virtualx
+
+DESCRIPTION="Simple and Fast Multimedia Library (SFML)"
+HOMEPAGE="https://www.sfml-dev.org/ https://github.com/SFML/SFML"
+SRC_URI="https://github.com/SFML/SFML/archive/${PV}.tar.gz -> ${P}.tar.gz"
+S="${WORKDIR}/SFML-${PV}"
+
+LICENSE="ZLIB"
+# Vendored header dependencies:
+# glad
+LICENSE+=" Apache-2.0 || ( WTFPL-2 CC0-1.0 )"
+# miniaudio
+LICENSE+=" || ( MIT-0 public-domain )"
+# minimp3
+LICENSE+=" CC0-1.0"
+# stb_image
+LICENSE+=" || ( MIT public-domain )"
+# vulkan
+LICENSE+=" Apache-2.0"
+
+SLOT="0/$(ver_cut 1-2)"
+KEYWORDS="amd64 ~arm ~arm64 ~ppc64 ~riscv x86"
+IUSE="doc examples test"
+RESTRICT="!test? ( test )"
+
+RDEPEND="
+ media-libs/flac:=
+ media-libs/freetype:2
+ media-libs/libogg
+ media-libs/libvorbis
+ virtual/opengl
+ x11-libs/libX11
+ x11-libs/libXcursor
+ x11-libs/libXi
+ x11-libs/libXrandr
+ x11-libs/libxcb
+ x11-libs/xcb-util-image
+ kernel_linux? ( virtual/libudev:= )
+"
+DEPEND="
+ ${RDEPEND}
+ x11-base/xorg-proto
+"
+BDEPEND="
+ doc? ( app-text/doxygen )
+ test? ( >=dev-cpp/catch-3.7.0 )
+"
+
+DOCS=( changelog.md readme.md )
+
+PATCHES=(
+ "${FILESDIR}"/libsfml-3.0.0-catch-depend.patch
+)
+
+src_configure() {
+ local mycmakeargs=(
+ -DSFML_BUILD_DOC=$(usex doc)
+ -DSFML_USE_SYSTEM_DEPS=ON
+ -DSFML_INSTALL_PKGCONFIG_FILES=ON
+ -DSFML_PKGCONFIG_INSTALL_DIR="${EPREFIX}/usr/$(get_libdir)/pkgconfig/"
+ -DSFML_BUILD_TEST_SUITE=$(usex test)
+ )
+
+ cmake_src_configure
+}
+
+src_compile() {
+ cmake_src_compile
+ use doc && cmake_build doc
+}
+
+src_test() {
+ local CMAKE_SKIP_TESTS=(
+ # Requires a more capable graphical enviroment (opengl?)
+ "sf::Window"
+ # Requires a running pulseaudio daemon to query
+ "sf::Sound"
+ "sf::SoundStream"
+ # Network sandbox
+ "sf::IpAddress"
+ )
+ virtx cmake_src_test
+}
+
+src_install() {
+ cmake_src_install
+
+ if use examples ; then
+ docompress -x /usr/share/doc/${PF}/examples
+ dodoc -r examples
+ fi
+}
diff --git a/media-libs/libsfml/metadata.xml b/media-libs/libsfml/metadata.xml
new file mode 100644
index 000000000000..9376f6e1bffc
--- /dev/null
+++ b/media-libs/libsfml/metadata.xml
@@ -0,0 +1,17 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "https://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <!-- maintainer-needed -->
+ <longdescription lang="en">
+ The Simple and Fast Multimedia Library (SFML) is a portable and easy to use
+ multimedia API written in C++. You can see it as a modern, object-oriented
+ alternative to SDL. SFML is composed of several packages to suit your needs.
+ You can use SFML as a minimal windowing system to interface with OpenGL, or
+ as a fully-featured multimedia library for building games or interactive
+ programs.
+ </longdescription>
+ <upstream>
+ <remote-id type="github">SFML/SFML</remote-id>
+ <remote-id type="sourceforge">sfml</remote-id>
+ </upstream>
+</pkgmetadata>