From: Sebastian Harl Date: Wed, 14 Nov 2007 13:20:08 +0000 (+0100) Subject: Collectd.pm: Check for ithread support. X-Git-Tag: collectd-4.3.0beta0~99 X-Git-Url: https://git.octo.it/?a=commitdiff_plain;h=917976da22e3e1e424c2de6c1116dcc7876b083d;p=collectd.git Collectd.pm: Check for ithread support. Abort if perl has been compiled without ithread support (i.e. $Config{'useithreads'} is not defined). Signed-off-by: Sebastian Harl Signed-off-by: Florian Forster --- diff --git a/bindings/perl/Collectd.pm b/bindings/perl/Collectd.pm index fd5632a4..1d26d207 100644 --- a/bindings/perl/Collectd.pm +++ b/bindings/perl/Collectd.pm @@ -22,6 +22,14 @@ package Collectd; use strict; use warnings; +use Config; + +BEGIN { + if (! $Config{'useithreads'}) { + die "Perl does not support ithreads!"; + } +} + require Exporter; our @ISA = qw( Exporter );