diff options
author | brain <brain@e03df62e-2008-0410-955e-edbf42e46eb7> | 2008-02-13 18:30:38 +0000 |
---|---|---|
committer | brain <brain@e03df62e-2008-0410-955e-edbf42e46eb7> | 2008-02-13 18:30:38 +0000 |
commit | 9a4067dac488d3896afceaf7c12f26ba7723307a (patch) | |
tree | 51d171d483e89e4e6f3903998bb2df57e7552341 | |
parent | 9e139f31b2e79cdfd7d468771176b736671a8b9d (diff) |
More fixes to configure stability with undefined values/closed filehandles
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8924 e03df62e-2008-0410-955e-edbf42e46eb7
-rw-r--r-- | make/configure.pm | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/make/configure.pm b/make/configure.pm index 41a116df0..42ea206bd 100644 --- a/make/configure.pm +++ b/make/configure.pm @@ -87,7 +87,7 @@ sub getcompilerflags { sub getlinkerflags { my ($file) = @_; - open(FLAGS, $file); + open(FLAGS, $file) or return ""; while (<FLAGS>) { if ($_ =~ /^\/\* \$LinkerFlags: (.+) \*\/$/) { close(FLAGS); @@ -100,7 +100,7 @@ sub getlinkerflags { sub getdependencies { my ($file) = @_; - open(FLAGS, $file); + open(FLAGS, $file) or return ""; while (<FLAGS>) { if ($_ =~ /^\/\* \$ModDep: (.+) \*\/$/) { close(FLAGS); @@ -113,7 +113,7 @@ sub getdependencies { sub nopedantic { my ($file) = @_; - open(FLAGS, $file); + open(FLAGS, $file) or return ""; while (<FLAGS>) { if ($_ =~ /^\/\* \$NoPedantic \*\/$/) { close(FLAGS); @@ -128,7 +128,7 @@ sub getmodules { my $i = 0; print "Detecting modules "; - opendir(DIRHANDLE, "src/modules"); + opendir(DIRHANDLE, "src/modules") or die("WTF, missing src/modules!"); foreach my $name (sort readdir(DIRHANDLE)) { if ($name =~ /^m_(.+)\.cpp$/) |