diff options
author | brain <brain@e03df62e-2008-0410-955e-edbf42e46eb7> | 2007-01-13 23:58:51 +0000 |
---|---|---|
committer | brain <brain@e03df62e-2008-0410-955e-edbf42e46eb7> | 2007-01-13 23:58:51 +0000 |
commit | 2e9951e823c6178f1126c68e5f37e6fd3a724ea9 (patch) | |
tree | 98cbbf3afb875d02bda36bc3eb26393ff41a0350 /make/utilities.pm | |
parent | 4f0e6377e80d61ba633588568640881f6ddca9ec (diff) |
Colour coding, tidying, and more verbose output to configure
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@6307 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'make/utilities.pm')
-rw-r--r-- | make/utilities.pm | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/make/utilities.pm b/make/utilities.pm index a227be3a4..3c0f76188 100644 --- a/make/utilities.pm +++ b/make/utilities.pm @@ -6,12 +6,21 @@ use Exporter 'import'; # such as pcre_config, take out the -L # directive and return an rpath for it. +# \033[1;32msrc/Makefile\033[0m + +my %already_added = (); + sub make_rpath($) { my ($executable) = @_; chomp($data = `$executable`); $data =~ /-L(\S+)\s/; $libpath = $1; + if (!exists $already_added{$libpath}) + { + print "Adding extra library path \033[1;32m$libpath\033[0m ...\n"; + $already_added{$libpath} = 1; + } return "-Wl,--rpath -Wl,$libpath -L$libpath"; } @@ -32,6 +41,8 @@ sub pkgconfig_get_include_dirs($$$) my ($packagename, $headername, $defaults) = @_; extend_pkg_path(); + print "Locating include directory for package \033[1;32m$packagename\033[0m ... "; + $ret = `pkg-config --cflags $packagename 2>/dev/null`; if ((!defined $ret) || ($ret eq "")) { @@ -52,6 +63,8 @@ sub pkgconfig_get_include_dirs($$$) $ret = "$foo " . $defaults; } chomp($ret); + + print "\033[1;32m$ret\033[0m\n"; return $ret; } @@ -60,6 +73,8 @@ sub pkgconfig_get_lib_dirs($$$) my ($packagename, $libname, $defaults) = @_; extend_pkg_path(); + print "Locating library directory for package \033[1;32m$packagename\033[0m ... "; + $ret = `pkg-config --libs $packagename 2>/dev/null`; if ((!defined $ret) || ($ret eq "")) { @@ -81,6 +96,7 @@ sub pkgconfig_get_lib_dirs($$$) $ret = "$foo " . $defaults; } chomp($ret); + print "\033[1;32m$ret\033[0m\n"; return $ret; } |