From 5a13665e1747448e400d3f42367d72b2a48b75cc Mon Sep 17 00:00:00 2001 From: BrewTestBot <1589480+BrewTestBot@users.noreply.github.com> Date: Sun, 22 Dec 2024 02:39:54 +0000 Subject: [PATCH] sfml 3.0.0 Co-authored-by: Rui Chen Co-authored-by: Michka Popoff --- Aliases/sfml@3 | 1 + Formula/s/sfml.rb | 16 +++++++++------- 2 files changed, 10 insertions(+), 7 deletions(-) create mode 120000 Aliases/sfml@3 diff --git a/Aliases/sfml@3 b/Aliases/sfml@3 new file mode 120000 index 0000000000000..483217603bdf4 --- /dev/null +++ b/Aliases/sfml@3 @@ -0,0 +1 @@ +../Formula/s/sfml.rb \ No newline at end of file diff --git a/Formula/s/sfml.rb b/Formula/s/sfml.rb index 1a60e576923de..6c44b3aadd245 100644 --- a/Formula/s/sfml.rb +++ b/Formula/s/sfml.rb @@ -2,8 +2,8 @@ class Sfml < Formula # Don't update SFML until there's a corresponding CSFML release desc "Multi-media library with bindings for multiple languages" homepage "https://www.sfml-dev.org/" - url "https://www.sfml-dev.org/files/SFML-2.6.2-sources.zip" - sha256 "19d6dbd9c901c74441d9888c13cb1399f614fe8993d59062a72cfbceb00fed04" + url "https://www.sfml-dev.org/files/SFML-3.0.0-sources.zip" + sha256 "8cc41db46b59f07c44ecf21c74a0f956d37735dec9d90ff4522856cb162ba642" license "Zlib" head "https://github.com/SFML/SFML.git", branch: "master" @@ -18,6 +18,7 @@ class Sfml < Formula depends_on "cmake" => :build depends_on "doxygen" => :build + depends_on "pkgconf" => :build depends_on "flac" depends_on "freetype" depends_on "libogg" @@ -26,6 +27,7 @@ class Sfml < Formula on_linux do depends_on "libx11" depends_on "libxcursor" + depends_on "libxi" depends_on "libxrandr" depends_on "mesa" depends_on "mesa-glu" @@ -47,12 +49,12 @@ def install args = ["-DCMAKE_INSTALL_RPATH=#{lib}", "-DSFML_MISC_INSTALL_PREFIX=#{share}/SFML", "-DSFML_INSTALL_PKGCONFIG_FILES=TRUE", - "-DSFML_BUILD_DOC=TRUE"] - - args << "-DSFML_USE_SYSTEM_DEPS=ON" if OS.linux? + "-DSFML_BUILD_DOC=TRUE", + "-DSFML_USE_SYSTEM_DEPS=ON"] system "cmake", "-S", ".", "-B", "build", *std_cmake_args, *args system "cmake", "--build", "build" + system "cmake", "--build", "build", "--target=doc" system "cmake", "--install", "build" end @@ -64,8 +66,8 @@ def install return 0; } CPP - system ENV.cxx, "-I#{include}/SFML/System", testpath/"test.cpp", - "-L#{lib}", "-lsfml-system", "-o", "test" + system ENV.cxx, "-I#{include}/SFML/System", "-std=c++17", testpath/"test.cpp", + "-L#{lib}", "-o", "test" system "./test" end end