Initial v17 Release

Headers and Unit tests have been updated to match the v17 spec.

Documentation can be found here:
https://developers.devsite.corp.google.com/widevine/drm/client/oemcrypto/v17
This commit is contained in:
Fred Gylys-Colwell
2021-12-04 01:13:15 +00:00
parent 8e55868e8a
commit 044a89ef55
131 changed files with 6072 additions and 9038 deletions

View File

@@ -5,18 +5,53 @@
#ifndef WVCDM_UTIL_UTIL_COMMON_H_
#define WVCDM_UTIL_UTIL_COMMON_H_
// This section deals with defines that are platform-specific.
#ifdef _WIN32
# ifdef CORE_UTIL_IMPLEMENTATION
# define CORE_UTIL_EXPORT __declspec(dllexport)
# else
# define CORE_UTIL_EXPORT __declspec(dllimport)
# endif
# define CORE_UTIL_IGNORE_DEPRECATED
# define CORE_UTIL_RESTORE_WARNINGS
#else
# ifdef CORE_UTIL_IMPLEMENTATION
# define CORE_UTIL_EXPORT __attribute__((visibility("default")))
# else
# define CORE_UTIL_EXPORT
# endif
# ifdef __GNUC__
# define CORE_UTIL_IGNORE_DEPRECATED \
_Pragma("GCC diagnostic push") \
_Pragma("GCC diagnostic ignored \"-Wdeprecated-declarations\"")
# define CORE_UTIL_RESTORE_WARNINGS _Pragma("GCC diagnostic pop")
# else
# define CORE_UTIL_IGNORE_DEPRECATED
# define CORE_UTIL_RESTORE_WARNINGS
# endif
#endif
// This section deals with attribute-detection and is platform-agnostic.
#if !defined(__has_cpp_attribute)
# define __has_cpp_attribute(x) 0
#endif
#if __has_cpp_attribute(fallthrough)
# define CORE_UTIL_FALLTHROUGH [[fallthrough]]
#elif __has_cpp_attribute(clang::fallthrough)
# define CORE_UTIL_FALLTHROUGH [[clang::fallthrough]]
#elif __has_cpp_attribute(gnu::fallthrough)
# define CORE_UTIL_FALLTHROUGH [[gnu::fallthrough]]
#else
# define CORE_UTIL_FALLTHROUGH
#endif
#endif // WVCDM_UTIL_UTIL_COMMON_H_