metalink: show help message even if disabled

Print message if --metalink is used while metalink support is not
enabled. Migrated Metalink support in tool_operate.c and removed
operatemetalink().
This commit is contained in:
Tatsuhiro Tsujikawa
2012-04-28 21:48:56 +09:00
committed by Daniel Stenberg
parent bb1ce6cc0b
commit a0d7a26e32
4 changed files with 97 additions and 974 deletions

View File

@@ -826,9 +826,9 @@ ParameterError getparameter(char *flag, /* f or -long-flag */
case 'H': /* --mail-auth */
GetStr(&config->mail_auth, nextarg);
break;
#ifdef HAVE_LIBMETALINK
case 'J': /* --metalink */
{
#ifdef HAVE_LIBMETALINK
metalink_error_t r;
metalink_t* metalink;
metalink_file_t **files;
@@ -889,9 +889,12 @@ ParameterError getparameter(char *flag, /* f or -long-flag */
}
}
}
#else
warnf(config, "--metalink option is ignored because the binary is "
"built without the Metalink support.\n");
#endif
break;
}
#endif /* HAVE_LIBMETALINK */
}
break;
case '#': /* --progress-bar */