summaryrefslogtreecommitdiff
path: root/src/modules/extra/pgsql_config.pl
blob: 683cb1ee83514f27713e0be970e8b0539ff21e6d (plain)
1
2
3
4
5
6
#!/usr/bin/perl

my $s = `pg_config --version`;
$s =~ /^.*?(\d+)\.(\d+)\.(\d+).*?$/;
my $v = hex(sprintf("0x%02x%02x%02x", $1, $2, $3));
print "-D PGSQL_HAS_ESCAPECONN" if(($v >= 0x080104) or (($v >= 0x07030F) and ($v < 0x080000)));