Changeset 0aa20e3 for driver/cfa.cc


Ignore:
Timestamp:
Jul 16, 2020, 5:30:03 PM (4 years ago)
Author:
Thierry Delisle <tdelisle@…>
Branches:
ADT, arm-eh, ast-experimental, enum, forall-pointer-decay, jacob/cs343-translation, master, new-ast, new-ast-unique-expr, pthread-emulation, qualifiedEnum
Children:
527acfc
Parents:
cf48a14
Message:

Added support for syntax -XCFA,OPTION instead of -XCFA OPTION in cfa.cc.
Now using -XCFA,-l syntax for prelude.cfa to fix distcc error

File:
1 edited

Legend:

Unmodified
Added
Removed
  • driver/cfa.cc

    rcf48a14 r0aa20e3  
    185185                                args[nargs++] = argv[i];                                // pass argument along
    186186                                if ( arg == "-o" ) o_file = i;                  // remember file
    187                         } else if ( arg == "-XCFA" ) {                          // CFA pass through
    188                                 i += 1;
    189                                 if ( i == argc ) continue;                              // next argument available ?
    190                                 Putenv( argv, argv[i] );
    191 
    192                                 // CFA specific arguments
     187                        } else if ( strncmp(arg.c_str(), "-XCFA", 5) == 0 ) {                           // CFA pass through
     188                                if(arg.size() == 5) {
     189                                        i += 1;
     190                                        if ( i == argc ) continue;                              // next argument available ?
     191                                        Putenv( argv, argv[i] );
     192
     193                                        // CFA specific arguments
     194                                }
     195                                else if(arg[5] == ',') {
     196                                        Putenv( argv, argv[i] + 6 );
     197                                        printf("%s\n", argv[i] + 6 );
     198                                        // CFA specific arguments
     199                                }
     200                                else {
     201                                        args[nargs++] = argv[i];
     202                                }
    193203
    194204                        } else if ( arg == "-CFA" ) {
Note: See TracChangeset for help on using the changeset viewer.