homebrew-core/Formula/ppsspp.rb
2018-11-19 13:18:05 +08:00

40 lines
1.3 KiB
Ruby

class Ppsspp < Formula
desc "PlayStation Portable emulator"
homepage "https://ppsspp.org/"
url "https://github.com/hrydgard/ppsspp.git",
:tag => "v1.7.2",
:revision => "640973ff4705dff816c435b240566987c399fdad"
head "https://github.com/hrydgard/ppsspp.git"
bottle do
cellar :any
sha256 "01811d6ffa75a454e9fc7b71b97676940c842976db4fcfa49d472ab6e3720545" => :mojave
sha256 "a902fa666f5472a091a5bfe5a5297da94d917f8d964e9fc90efea4d05c134051" => :high_sierra
sha256 "6deb010cdd86d50d60e678bed9045f3ba04129e26f40ddddd6918847fb69e729" => :sierra
end
depends_on "cmake" => :build
depends_on "pkg-config" => :build
depends_on "ffmpeg"
depends_on "glew"
depends_on "libzip"
depends_on "sdl2"
depends_on "snappy"
def install
args = std_cmake_args
# Use brewed FFmpeg rather than precompiled binaries in the repo
args << "-DUSE_SYSTEM_FFMPEG=ON"
# fix missing include for zipconf.h
ENV.append_to_cflags "-I#{Formula["libzip"].opt_prefix}/lib/libzip/include"
mkdir "build" do
system "cmake", "..", *args
system "make"
prefix.install "PPSSPPSDL.app"
bin.write_exec_script "#{prefix}/PPSSPPSDL.app/Contents/MacOS/PPSSPPSDL"
mv "#{bin}/PPSSPPSDL", "#{bin}/ppsspp"
end
end
end