New formula: OpenAL Soft

Closes Homebrew/homebrew#30177.
Closes Homebrew/homebrew#30941.

Signed-off-by: Jack Nagel <jacknagel@gmail.com>
This commit is contained in:
Nick Gravelyn 2014-06-15 14:53:49 -07:00 committed by Jack Nagel
parent a5d8eb2726
commit 1391072562

28
Formula/openal-soft.rb Normal file
View file

@ -0,0 +1,28 @@
require "formula"
class OpenalSoft < Formula
homepage "http://kcat.strangesoft.net/openal.html"
url "http://kcat.strangesoft.net/openal-releases/openal-soft-1.15.1.tar.bz2"
sha1 "a0e73a46740c52ccbde38a3912c5b0fd72679ec8"
depends_on "cmake" => :build
def install
system "cmake", ".", *std_cmake_args
system "make", "install"
end
test do
(testpath/"test.c").write <<-EOS.undent
#include "AL/al.h"
#include "AL/alc.h"
int main() {
ALCdevice *device;
device = alcOpenDevice(0);
alcCloseDevice(device);
return 0;
}
EOS
system ENV.cc, "test.c", "-lopenal"
end
end