use ExtUtils::MakeMaker; print </dev/null 2>&1") ? "mysql_config" : "mariadb_config"; print "Using '$cfg' to get compile settings.\n\n"; sub cfg { my $param = join " ", @_; my $val = qx<$cfg $param>; $val =~ y/[\r\n]/ /; print "$cfg $param: $val\n"; $val } my %wm = ( dist => { PREOP => 'pod2text Mysql.pm | tee README >$(DISTVNAME)/README; chmod -R u=rwX,go=rX . ;', COMPRESS => 'gzip -9v', SUFFIX => '.gz', }, PREREQ_PM => { Scalar::Util => 0.00, Coro => 5.1, Guard => 1.0, DBI => 0, # not actually a hard dependency DBD::mysql => 0, # not actually a hard dependency }, NAME => "Coro::Mysql", VERSION_FROM => "Mysql.pm", INC => (cfg "--include"), LIBS => [cfg "--libs_r"], ); if (eval "require EV::MakeMaker; require Coro::MakeMaker; 1") { %wm = Coro::MakeMaker::coro_args (EV::MakeMaker::ev_args (%wm)); $wm{DEFINE} .= " -DHAVE_EV=1"; } else { print <