mirror of
https://github.com/pgbackrest/pgbackrest.git
synced 2025-01-06 03:53:59 +02:00
Use YAML::Any module instead of YAML::XS in Perl.
YAML::XS requires libyaml so it not as portable as pure Perl versions of YAML. Instead of using YAML:PP just use the general YAML::Any module which uses whatever is installed. We are not concerned about performance for YAML so whatever works is fine.
This commit is contained in:
parent
ea0dc8c2cb
commit
d2057c53bd
@ -31,8 +31,8 @@ sub errorDefineLoad
|
|||||||
{
|
{
|
||||||
my $strErrorYaml = shift;
|
my $strErrorYaml = shift;
|
||||||
|
|
||||||
require YAML::XS;
|
require YAML::Any;
|
||||||
YAML::XS->import(qw(Load));
|
YAML::Any->import(qw(Load));
|
||||||
|
|
||||||
$rhErrorDefine = Load($strErrorYaml);
|
$rhErrorDefine = Load($strErrorYaml);
|
||||||
}
|
}
|
||||||
|
@ -69,7 +69,7 @@
|
|||||||
<exe-cmd>
|
<exe-cmd>
|
||||||
apt-get install rsync git devscripts build-essential valgrind lcov autoconf
|
apt-get install rsync git devscripts build-essential valgrind lcov autoconf
|
||||||
autoconf-archive libssl-dev zlib1g-dev libxml2-dev libpq-dev pkg-config
|
autoconf-archive libssl-dev zlib1g-dev libxml2-dev libpq-dev pkg-config
|
||||||
libxml-checker-perl libyaml-libyaml-perl libdbd-pg-perl liblz4-dev liblz4-tool
|
libxml-checker-perl libyaml-perl libdbd-pg-perl liblz4-dev liblz4-tool
|
||||||
zstd libzstd-dev bzip2 libbz2-dev
|
zstd libzstd-dev bzip2 libbz2-dev
|
||||||
</exe-cmd>
|
</exe-cmd>
|
||||||
<exe-cmd-extra>-y 2>&1</exe-cmd-extra>
|
<exe-cmd-extra>-y 2>&1</exe-cmd-extra>
|
||||||
|
2
test/Vagrantfile
vendored
2
test/Vagrantfile
vendored
@ -70,7 +70,7 @@ Vagrant.configure(2) do |config|
|
|||||||
|
|
||||||
#-----------------------------------------------------------------------------------------------------------------------
|
#-----------------------------------------------------------------------------------------------------------------------
|
||||||
echo 'Install Perl Modules' && date
|
echo 'Install Perl Modules' && date
|
||||||
apt-get install -y libdbd-pg-perl libxml-checker-perl libyaml-libyaml-perl
|
apt-get install -y libdbd-pg-perl libxml-checker-perl libyaml-perl
|
||||||
|
|
||||||
#-----------------------------------------------------------------------------------------------------------------------
|
#-----------------------------------------------------------------------------------------------------------------------
|
||||||
echo 'Install Build Tools' && date
|
echo 'Install Build Tools' && date
|
||||||
|
@ -133,7 +133,7 @@ eval
|
|||||||
|
|
||||||
processBegin('install common packages');
|
processBegin('install common packages');
|
||||||
processExec('sudo apt-get -qq update', {bSuppressStdErr => true, bSuppressError => true});
|
processExec('sudo apt-get -qq update', {bSuppressStdErr => true, bSuppressError => true});
|
||||||
processExec('sudo apt-get install -y libxml-checker-perl libyaml-libyaml-perl', {bSuppressStdErr => true});
|
processExec('sudo apt-get install -y libxml-checker-perl libyaml-perl', {bSuppressStdErr => true});
|
||||||
processEnd();
|
processEnd();
|
||||||
|
|
||||||
processBegin('mount tmpfs');
|
processBegin('mount tmpfs');
|
||||||
|
@ -27,8 +27,8 @@ sub codeCountScan
|
|||||||
my $strBasePath = shift;
|
my $strBasePath = shift;
|
||||||
|
|
||||||
# Load YAML
|
# Load YAML
|
||||||
require YAML::XS;
|
require YAML::Any;
|
||||||
YAML::XS->import(qw(Load Dump));
|
YAML::Any->import(qw(Load Dump));
|
||||||
|
|
||||||
my $hCodeCount = {};
|
my $hCodeCount = {};
|
||||||
|
|
||||||
|
@ -301,8 +301,8 @@ sub containerBuild
|
|||||||
$oStorageDocker->pathCreate($strTempPath, {strMode => '0770', bIgnoreExists => true, bCreateParent => true});
|
$oStorageDocker->pathCreate($strTempPath, {strMode => '0770', bIgnoreExists => true, bCreateParent => true});
|
||||||
|
|
||||||
# Load container definitions from yaml
|
# Load container definitions from yaml
|
||||||
require YAML::XS;
|
require YAML::Any;
|
||||||
YAML::XS->import(qw(Load));
|
YAML::Any->import(qw(Load));
|
||||||
|
|
||||||
$hContainerCache = Load(${$oStorageDocker->get($oStorageDocker->pathGet('test/container.yaml'))});
|
$hContainerCache = Load(${$oStorageDocker->get($oStorageDocker->pathGet('test/container.yaml'))});
|
||||||
|
|
||||||
|
@ -87,8 +87,8 @@ sub testDefLoad
|
|||||||
my $strDefineYaml = shift;
|
my $strDefineYaml = shift;
|
||||||
|
|
||||||
# Load test definitions from yaml
|
# Load test definitions from yaml
|
||||||
require YAML::XS;
|
require YAML::Any;
|
||||||
YAML::XS->import(qw(Load));
|
YAML::Any->import(qw(Load));
|
||||||
|
|
||||||
my $hTestDef = Load($strDefineYaml);
|
my $hTestDef = Load($strDefineYaml);
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user