Print AW version in -h output.
Signed-off-by: Andrea Odetti <mariofutire@gmail.com>
This commit is contained in:
parent
a5734cac10
commit
600d6cf00e
2 changed files with 6 additions and 4 deletions
|
@ -1,4 +1,5 @@
|
|||
#include <frontends/common2/programoptions.h>
|
||||
#include <linux/version.h>
|
||||
#include <boost/program_options.hpp>
|
||||
|
||||
#include "StdAfx.h"
|
||||
|
@ -7,9 +8,10 @@
|
|||
|
||||
namespace po = boost::program_options;
|
||||
|
||||
bool getEmulatorOptions(int argc, const char * argv [], const std::string & version, EmulatorOptions & options)
|
||||
bool getEmulatorOptions(int argc, const char * argv [], const std::string & edition, EmulatorOptions & options)
|
||||
{
|
||||
po::options_description desc("AppleWin " + version);
|
||||
const std::string name = "Apple Emulator for " + edition + " (based on AppleWin " + getVersion() + ")\n";
|
||||
po::options_description desc(name);
|
||||
desc.add_options()
|
||||
("help,h", "Print this help message")
|
||||
("conf", "Save configuration on exit")
|
||||
|
@ -53,7 +55,7 @@ bool getEmulatorOptions(int argc, const char * argv [], const std::string & vers
|
|||
|
||||
if (vm.count("help"))
|
||||
{
|
||||
std::cout << "AppleWin " << version << " edition." << std::endl << std::endl << desc << std::endl;
|
||||
std::cout << desc << std::endl;
|
||||
return false;
|
||||
}
|
||||
|
||||
|
|
|
@ -34,4 +34,4 @@ struct EmulatorOptions
|
|||
int sdlDriver = -1; // default = -1 to let SDL choose
|
||||
};
|
||||
|
||||
bool getEmulatorOptions(int argc, const char * argv [], const std::string & version, EmulatorOptions & options);
|
||||
bool getEmulatorOptions(int argc, const char * argv [], const std::string & edition, EmulatorOptions & options);
|
||||
|
|
Loading…
Add table
Reference in a new issue