Commit 4cb13b41 authored by gates's avatar gates

Make libaacs it's own standalone library.

Leaving in source tree for now.
parent d9af0188
......@@ -51,42 +51,24 @@ elif [[ $use_dlopen = "yes" ]]; then
AC_DEFINE([USING_DLOPEN], [1], ["Define to 1 if using dlopen"])],
[AC_MSG_ERROR($library_not_found)])
else
AC_CHECK_LIB([aacs], [aacs_open],,
[AC_MSG_ERROR($library_not_found)])
AC_MSG_NOTICE($using_normal_linking)
fi
AM_CONDITIONAL([USING_DLOPEN],
[test $use_dlopen = "auto" || test $use_dlopen = "yes"])
# libaacs checks
if [[ -d src/libaacs ]]; then
# libbdplus checks
if [[ -d src/libbdplus ]]; then
PKG_CHECK_MODULES([OPENSSL], [openssl],
[OPENSSL_INCLUDES="$INCLUDES $OPENSSL_CFLAGS";
OPENSSL_LDFLAGS="$LIBS $OPENSSL_LIBS"],
OPENSSL_LDFLAGS="$LIBS $OPENSSL_LIBS"],
AC_MSG_ERROR($library_not_found))
# Make sure OpenSSL is cool enough to play with the big boys.
AC_CHECK_HEADERS([openssl/ecdsa.h], [], [
AC_MSG_ERROR([Version of OpenSSL does not feature openssl/ecdsa.h, please
upgrade]) ]
, [])
libaacs_src_available=1
else
libaacs_src_available=0
fi
AM_CONDITIONAL([HAVE_LIBAACS_SRC], [test $libaacs_src_available = "1"])
# libbdplus checks
if [[ -d src/libbdplus ]]; then
# Don't check openssl again if already checked before
if [[ libaacs_src_available != "1" ]]; then
PKG_CHECK_MODULES([OPENSSL], [openssl],
[OPENSSL_INCLUDES="$INCLUDES $OPENSSL_CFLAGS";
OPENSSL_LDFLAGS="$LIBS $OPENSSL_LIBS"],
AC_MSG_ERROR($library_not_found))
# Make sure OpenSSL is cool enough to play with the big boys.
AC_CHECK_HEADERS([openssl/ecdsa.h], [], [
AC_MSG_ERROR([Version of OpenSSL does not feature openssl/ecdsa.h, please
upgrade]) ]
, [])
fi
libbdplus_src_available=1
else
libbdplus_src_available=0
......
......@@ -4,15 +4,6 @@ AM_CFLAGS = -I$(top_builddir)/src
lib_LTLIBRARIES=
if HAVE_LIBAACS_SRC
LIBAACS_LIBADD = libaacs.la
lib_LTLIBRARIES += $(LIBAACS_LIBADD)
libaacs_la_SOURCES=libaacs/aacs.c libaacs/crypto.c libaacs/mkb.c libaacs/mmc.c \
file/configfile.c file/file_posix.c util/logging.c
libaacs_la_CFLAGS=@OPENSSL_INCLUDES@
libaacs_la_LDFLAGS=@OPENSSL_LDFLAGS@
endif
if HAVE_LIBBDPLUS_SRC
LIBBDPLUS_LIBADD = libbdplus.la
lib_LTLIBRARIES += $(LIBBDPLUS_LIBADD)
......@@ -29,7 +20,7 @@ endif
if USING_DLOPEN
LIBBLURAY_LDFLAGS=@DLOPEN_LDFLAGS@
else
LIBBLURAY_LIBADD=$(LIBAACS_LIBADD) $(LIBBDPLUS_LIBADD)
LIBBLURAY_LIBADD=$(LIBBDPLUS_LIBADD)
endif
lib_LTLIBRARIES+=libbluray.la
......
......@@ -26,7 +26,7 @@
#include "libbdnav/index_parse.h"
#ifndef USING_DLOPEN
#include "libaacs/aacs.h"
#include <libaacs/aacs.h>
#include "libbdplus/bdplus.h"
#endif
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment