diff --git a/Formula/t/tgui.rb b/Formula/t/tgui.rb index 53ac2ee3e27a9..ddf4e5e13f866 100644 --- a/Formula/t/tgui.rb +++ b/Formula/t/tgui.rb @@ -4,6 +4,7 @@ class Tgui < Formula url "https://github.com/texus/TGUI/archive/refs/tags/v1.7.0.tar.gz" sha256 "7d40359770e2f8e534a57332c99fd56c72cf79a8b59642676e01394fe05cb1fa" license "Zlib" + revision 1 livecheck do url :stable @@ -20,7 +21,7 @@ class Tgui < Formula end depends_on "cmake" => :build - depends_on "sfml" + depends_on "sfml@2" # sfml 3.0 build issue report, https://github.com/texus/TGUI/issues/249 def install args = %W[ @@ -49,8 +50,10 @@ def install return 0; } CPP - system ENV.cxx, "test.cpp", "-std=c++17", "-I#{include}", - "-L#{lib}", "-L#{Formula["sfml"].opt_lib}", + + ENV.append_path "LD_LIBRARY_PATH", Formula["sfml@2"].opt_lib if OS.linux? + system ENV.cxx, "test.cpp", "-std=c++17", "-I#{include}", "-I#{Formula["sfml@2"].opt_include}", + "-L#{lib}", "-L#{Formula["sfml@2"].opt_lib}", "-ltgui", "-lsfml-graphics", "-lsfml-system", "-lsfml-window", "-o", "test" system "./test"