if ($line =~ /GNU C Library .* version (.*?) /)
{
$libcv = $1;
- $libcv =~ /([0-9\.\-])+/;
+ $libcv =~ /(\d+\.\d+)/;
$libcv = $1;
}
elsif ($line =~ /Compiled on a Linux (.*?\..*?)\.* system/)
{
$kernelv = $1;
# Fix for some retarded libc builds, strip off >> and << etc.
- $kernelv =~ /([0-9\.\-])+/;
+ $kernelv =~ /(\d+\.\d+)/;
$kernelv = $1;
}
}
$version = `uname -r`;
if ($version =~ /^4\./)
{
- # ICKY ICKY ICK, FREEBSD 4.x! GET AN UPGRADE!
- $config{CRAQ} = "-L/usr/local/lib -lgnugetopt -DHAVE_DECL_GETOPT=1";
- print "yes\n";
+ $foundit = `ls -l /usr/local/lib/libgnugetopt* | wc -l`;
+ if ($foundit > 0)
+ {
+ # ICKY ICKY ICK, FREEBSD 4.x! GET AN UPGRADE!
+ $config{CRAQ} = "-L/usr/local/lib -lgnugetopt -DHAVE_DECL_GETOPT=1";
+ print "yes\n";
+ }
+ else
+ {
+ print "\n\nERROR: You require libgnugetopt (from ports or packages) to build InspIRCd on FreeBSD 4.11.\n";
+ }
}
else
{