libbdplus 0.1.2 (new formula)

libbdplus implements the Blu-Ray BD+ specification for VLC and other
open source players.

Closes #3483.

Signed-off-by: Alex Dunn <dunn.alex@gmail.com>
master
William Johnston 2016-07-31 13:31:51 -05:00 committed by Alex Dunn
parent c8c678d105
commit 6242ab6f30
1 changed files with 39 additions and 0 deletions

39
Formula/libbdplus.rb Normal file
View File

@ -0,0 +1,39 @@
class Libbdplus < Formula
desc "Implements the BD+ System Specifications"
homepage "https://www.videolan.org/developers/libbdplus.html"
url "https://download.videolan.org/pub/videolan/libbdplus/0.1.2/libbdplus-0.1.2.tar.bz2"
mirror "http://videolan-nyc.defaultroute.com/libbdplus/0.1.2/libbdplus-0.1.2.tar.bz2"
sha256 "a631cae3cd34bf054db040b64edbfc8430936e762eb433b1789358ac3d3dc80a"
head do
url "https://git.videolan.org/git/libbdplus.git"
depends_on "autoconf" => :build
depends_on "automake" => :build
depends_on "libtool" => :build
end
depends_on "libgcrypt"
def install
system "./bootstrap" if build.head?
system "./configure", "--disable-dependency-tracking",
"--prefix=#{prefix}"
system "make", "install"
end
test do
(testpath/"test.c").write <<-EOS.undent
#include <libbdplus/bdplus.h>
int main() {
int major = -1;
int minor = -1;
int micro = -1;
bdplus_get_version(&major, &minor, &micro);
return 0;
}
EOS
system ENV.cc, "test.c", "-L#{lib}", "-I#{include}", "-lbdplus", "-o", "test"
system "./test"
end
end