#!/usr/bin/perl
-# Configure script for the libucw example
+# Configure script for the libucw example (inspired by ../external/configure)
# (c) 2008 Michal Vaner <vorner@ucw.cz>
-# A lot copyed from ../external/configure
-# (c) 2007 Martin Mares <mj@ucw.cz>
use warnings;
use strict;
die "Don't know how to find myself. Please set SRCDIR manually.";
}
}
- # Ask pkg-config for the rest of configure
+ # Ask pkg-config if libucw is installed and find its configure modules
+ `pkg-config libucw --atleast-version=3.13`;
+ !$? or die "Package `libucw' (version 3.13 or newer) not found. Is PKG_CONFIG_PATH set properly?";
$libdir=`pkg-config libucw --variable=perl_modules_dir`;
chomp $libdir;
- die "libUCW not found. Is PKG_CONFIG_PATH set properly?" if $? || not defined $libdir;
+ die "Unable to find the libucw configure system" if $? || not defined $libdir;
}
use lib $libdir;
use UCW::Configure;