summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2006-09-19 10:50:31 +0000
committerbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2006-09-19 10:50:31 +0000
commit32c1599c2180214e8c4d1684633b2e48f069a273 (patch)
tree132f1e53b91af6acad7832ddaf626e2565757e62
parentb91c37b8f9973ffb7e8affc0070138d2ef25d0da (diff)
Fix old interactive opts and -update etc
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@5291 e03df62e-2008-0410-955e-edbf42e46eb7
-rwxr-xr-xconfigure28
1 files changed, 16 insertions, 12 deletions
diff --git a/configure b/configure
index e233bfdcc..8cc7c7855 100755
--- a/configure
+++ b/configure
@@ -15,11 +15,6 @@
use Cwd;
use Getopt::Long;
-if ($ARGV[1] eq "-help")
-{
- showhelp();
-}
-
GetOptions (
'enable-gnutls' => \$opt_use_gnutls,
'enable-openssl' => \$opt_use_openssl,
@@ -50,6 +45,10 @@ GetOptions (
'binary-dir=s' => \$opt_binary_dir,
'library-dir=s' => \$opt_library_dir,
'help' => sub { showhelp(); },
+ 'modupdate' => sub { update(); },
+ 'update' => sub { modupdate(); },
+ 'svnupdate' => sub { svnupdate(); },
+ 'clean' => sub { clean(); },
);
my $non_interactive = (
@@ -283,12 +282,15 @@ if (!$config{MAX_CLIENT_T}) {
# Get and Set some important vars..
getmodules();
-my $arg = $ARGV[0]; # Do Some Argument Checks..
-if ($arg eq "-clean") {
- system("rm -rf .config.cache");
-} # Remove the config.cache file.
+sub clean
+{
+ if ($arg eq "-clean") {
+ system("rm -rf .config.cache");
+ }
+}
-if ($arg eq "-update") {
+sub update
+{
# Does the cache file exist?
if (!getcache()) {
# No, No it doesn't.. *BASH*
@@ -306,7 +308,8 @@ if ($arg eq "-update") {
}
}
-if ($arg eq "-modupdate") {
+sub modupdate
+{
# Does the cache file exist?
if (!getcache()) {
# No, No it doesn't.. *BASH*
@@ -326,7 +329,8 @@ if ($arg eq "-modupdate") {
-if ($arg eq "-svnupdate") {
+sub svnupdate
+{
my $fail = 0;
open(FH,"<.svn/entries") or $fail = 1;
if ($fail) {