summaryrefslogtreecommitdiff
path: root/configure
diff options
context:
space:
mode:
authorom <om@e03df62e-2008-0410-955e-edbf42e46eb7>2006-08-10 15:04:10 +0000
committerom <om@e03df62e-2008-0410-955e-edbf42e46eb7>2006-08-10 15:04:10 +0000
commit75d72cb832f41c08b0f299e61ed6994b115cb7b7 (patch)
tree828b4c7bd1bb5cd6797d23262eb8c1027f2c9f22 /configure
parent5ad92066273a998cf85b5d13e0b3a335a7cd4d57 (diff)
Add a few tidbits for MinGW, check for C:\ style paths as well as just beginning with '/' when determining if a path is absolute (only check if OSTYPE = MINGW32)
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4834 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'configure')
-rwxr-xr-xconfigure23
1 files changed, 17 insertions, 6 deletions
diff --git a/configure b/configure
index f5f4d38c5..aa004f4f2 100755
--- a/configure
+++ b/configure
@@ -72,15 +72,22 @@ if ($config{GCCVER} eq "") {
# Keep my dynamic module experiments here for later
# concideration!
-if ($config{OSNAME} =~ /CYGWIN/) {
+if ($config{OSNAME} =~ /CYGWIN/)
+{
$config{OSNAME} = "CYG-STATIC";
}
-
-if ((!$config{OSNAME}) || ($config{OSNAME} eq "")) {
+elsif($config{OSNAME} =~ /^MINGW32/)
+{
+ $config{OSNAME} = "MINGW32";
+}
+elsif ((!$config{OSNAME}) || ($config{OSNAME} eq ""))
+{
chomp($config{OSNAME} = `/usr/bin/uname`);
- if ((!$config{OSNAME}) || ($config{OSNAME} eq "")){
+
+ if((!$config{OSNAME}) || ($config{OSNAME} eq ""))
+ {
$config{OSNAME} = "Unknown";
- }
+ }
}
if (!$config{MAX_CLIENT_T}) {
@@ -830,17 +837,20 @@ sub dir_check {
# Convert it to a full path..
$var = resolve_directory($ENV{HOME} . "/" . $1);
}
- if (substr($var,0,1) ne "/")
+ elsif ((($config{OSNAME} == "MINGW32") and ($var !~ /^[A-Z]{1}:\\.*/)) and (substr($var,0,1) ne "/"))
{
# Assume relative Path was given.. fill in the rest.
$var = $this . "/$var";
}
+
$var = resolve_directory($var);
if (! -e $var) {
print "$var does not exist. Create it?\n[\033[1;32my\033[0m] ";
chomp($tmp = <STDIN>);
if (($tmp eq "") || ($tmp =~ /^y/i)) {
# Attempt to Create the Dir..
+
+ print("mkdir -p \"$var\" >> /dev/null 2>&1");
$chk = system("mkdir -p \"$var\" >> /dev/null 2>&1") / 256;
if ($chk != 0) {
print "Unable to create directory. ($var)\n\n";
@@ -944,6 +954,7 @@ sub getrevision {
return "0";
}
my $data = `svn info`;
+
if ($data eq "") {
$no_svn = 1;
$rev = "0";