File tree Expand file tree Collapse file tree 1 file changed +21
-1
lines changed Expand file tree Collapse file tree 1 file changed +21
-1
lines changed Original file line number Diff line number Diff line change @@ -5659,8 +5659,17 @@ end_going_arg (void)
5659
5659
string = full_script_path;
5660
5660
}
5661
5661
store_arg (string, delete_this_arg, this_is_output_file);
5662
- if (this_is_output_file)
5662
+ if (this_is_output_file) {
5663
+ const char *ofn = env.get (" _GCC_WRITE_OUTFILES" );
5663
5664
outfiles[input_file_number] = string;
5665
+ if (ofn && *ofn) {
5666
+ FILE *f = fopen (ofn, " a" );
5667
+ if (f) {
5668
+ fprintf (f, " %s\n " , string);
5669
+ fclose (f);
5670
+ }
5671
+ }
5672
+ }
5664
5673
arg_going = 0 ;
5665
5674
}
5666
5675
}
@@ -8584,6 +8593,17 @@ driver::set_up_specs () const
8584
8593
/* Now that we have the switches and the specs, set
8585
8594
the subdirectory based on the options. */
8586
8595
set_multilib_dir ();
8596
+
8597
+ if (output_file) {
8598
+ const char *ofn = env.get (" _GCC_WRITE_OUTFILES" );
8599
+ if (ofn && *ofn) {
8600
+ FILE *f = fopen (ofn, " a" );
8601
+ if (f) {
8602
+ fprintf (f, " %s\n " , output_file);
8603
+ fclose (f);
8604
+ }
8605
+ }
8606
+ }
8587
8607
}
8588
8608
8589
8609
/* Set up to remember the pathname of gcc and any options
You can’t perform that action at this time.
0 commit comments