38
38
#include < unistd.h>
39
39
#include < vector>
40
40
41
- #include " f18_version.h"
42
-
43
41
static std::list<std::string> argList (int argc, char *const argv[]) {
44
42
std::list<std::string> result;
45
43
for (int j = 0 ; j < argc; ++j) {
@@ -392,13 +390,6 @@ void Link(std::vector<std::string> &liblist, std::vector<std::string> &objects,
392
390
}
393
391
}
394
392
395
- int printVersion () {
396
- llvm::errs () << " \n f18 compiler (under development), version "
397
- << __FLANG_MAJOR__ << " ." << __FLANG_MINOR__ << " ."
398
- << __FLANG_PATCHLEVEL__ << " \n " ;
399
- return exitStatus;
400
- }
401
-
402
393
int main (int argc, char *const argv[]) {
403
394
404
395
atexit (CleanUpAtExit);
@@ -420,11 +411,6 @@ int main(int argc, char *const argv[]) {
420
411
options.predefinitions .emplace_back (" __F18_MAJOR__" , " 1" );
421
412
options.predefinitions .emplace_back (" __F18_MINOR__" , " 1" );
422
413
options.predefinitions .emplace_back (" __F18_PATCHLEVEL__" , " 1" );
423
- options.predefinitions .emplace_back (" __flang__" , __FLANG__);
424
- options.predefinitions .emplace_back (" __flang_major__" , __FLANG_MAJOR__);
425
- options.predefinitions .emplace_back (" __flang_minor__" , __FLANG_MINOR__);
426
- options.predefinitions .emplace_back (
427
- " __flang_patchlevel__" , __FLANG_PATCHLEVEL__);
428
414
#if __x86_64__
429
415
options.predefinitions .emplace_back (" __x86_64__" , " 1" );
430
416
#endif
@@ -665,16 +651,13 @@ int main(int argc, char *const argv[]) {
665
651
<< " Unrecognised options are passed through to the external compiler\n "
666
652
<< " set by F18_FC (see defaults).\n " ;
667
653
return exitStatus;
668
- } else if (arg == " -V" || arg == " --version" ) {
669
- return printVersion ();
654
+ } else if (arg == " -V" ) {
655
+ llvm::errs () << " \n f18 compiler (under development)\n " ;
656
+ return exitStatus;
670
657
} else {
671
658
driver.F18_FCArgs .push_back (arg);
672
659
if (arg == " -v" ) {
673
- if (args.size () > 1 ) {
674
- driver.verbose = true ;
675
- } else {
676
- return printVersion ();
677
- }
660
+ driver.verbose = true ;
678
661
} else if (arg == " -I" ) {
679
662
driver.F18_FCArgs .push_back (args.front ());
680
663
driver.searchDirectories .push_back (args.front ());
0 commit comments