NAME
Alien::CorvusJsonSchema - The corvus-json-schema C library, for JSON Schema validation
SYNOPSIS
In a Makefile.PL:
use Alien::Base::Wrapper qw(Alien::CorvusJsonSchema !export);
WriteMakefile(
Alien::Base::Wrapper->mm_args,
CONFIGURE_REQUIRES => { 'Alien::CorvusJsonSchema' => 'v0.1.0' },
...
);
and in the XS:
#include "corvus_json_schema.h"
DESCRIPTION
This distribution finds or installs the corvus-json-schema C library, a JSON Schema validator (draft 4, 6, 7, 2019-09 and 2020-12) built from the Rust crate of the same name, for JSON::Schema::Corvus::XS. See https://github.com/corvus-dotnet/Corvus.JsonSchema/tree/main/src-rs/corvus-json-schema-capi for the library and its API.
An installed C library, version 0.1.4 or later, that pkg-config finds as corvus-json-schema is used as it is. Otherwise the C library's release package for the platform (Linux on x86_64 and aarch64 with glibc or musl, macOS, and Windows on x64 and arm64 with Strawberry Perl) is downloaded from its GitHub release, checked against the SHA-256 digest this distribution records, and installed with it. There the static library is linked, except on Windows, where the library is a DLL that dynamic_libs names and that must be loaded before the XS module that links it.
Set ALIEN_INSTALL_TYPE=share to install the release package even when the library is installed, and ALIEN_INSTALL_TYPE=system to require the installed one.
METHODS
The methods of Alien::Base: cflags, libs, dynamic_libs, install_type and version. version is the C library's version.
LICENSE
Apache License 2.0. The C library's package holds the notices of the third-party material it is built from, in THIRD-PARTY-NOTICES.txt.