To compare an array of characters (c-string) to a string (std::string) you would you have to use a for loop or strcmp not ==. You could however change it from a c-string to a c++ string (std::string)
c-strings, i.e. char*, are just pointers to memory. For your char *inpufile, inputfile will point to the first character of your c-string. When you de-references it (line 21) using *inputfile, you get the first character only. Taking the address, i.e. &, brings you back to the pointer.
If you want to (or are required to) use c-strings you should use strcmp as suggested by gitblit. Line 21 turns into: if ( strcmp( inputfile, "generate" ) == 0 )
Using std::string it morphs into:
1 2 3
std::string mystring( inputfile ); // in order to make the std::string from inputfile.
if ( mystring == string( "generate" ) )
... or:
if ( mystring.compare( "generate" ) == 0 )
I recommend using std::string. It is portable, has a lot of functionality build in - and cleans up after itself.