Fixes for build without cn-lite and cn-heavy.

This commit is contained in:
XMRig 2018-04-12 11:38:43 +07:00
parent a73ad9b089
commit b13640e4a1
8 changed files with 56 additions and 9 deletions

View file

@ -92,7 +92,7 @@ bool xmrig::CommonConfig::adjust()
bool xmrig::CommonConfig::isValid() const
{
return m_pools[0].isValid();
return m_pools[0].isValid() && m_algorithm != INVALID_ALGO;
}

View file

@ -168,7 +168,7 @@ xmrig::IConfig *xmrig::ConfigLoader::load(int argc, char **argv, IConfigCreator
}
if (!config->isValid()) {
fprintf(stderr, "No pool URL supplied. Exiting.\n");
fprintf(stderr, "No valid configuration found. Exiting.\n");
delete config;
return nullptr;
}
@ -293,13 +293,13 @@ void xmrig::ConfigLoader::showVersion()
printf("\n features:"
# if defined(__i386__) || defined(_M_IX86)
" i386"
" 32-bit"
# elif defined(__x86_64__) || defined(_M_AMD64)
" x86_64"
" 64-bit"
# endif
# if defined(__AES__) || defined(_MSC_VER)
" AES-NI"
" AES"
# endif
"\n");

View file

@ -43,7 +43,17 @@ namespace xmrig {
static char const usage[] = "\
Usage: " APP_ID " [OPTIONS]\n\
Options:\n\
-a, --algo=ALGO cryptonight (default) or cryptonight-lite\n\
-a, --algo=ALGO specify the algorithm to use\n\
cryptonight\n"
#ifndef XMRIG_NO_AEON
"\
cryptonight-lite\n"
#endif
#ifndef XMRIG_NO_SUMO
"\
cryptonight-heavy\n"
#endif
"\
-o, --url=URL URL of mining server\n\
-O, --userpass=U:P username:password pair for mining server\n\
-u, --user=USERNAME username for mining server\n\