You are right that changing this behavior would have serious consequences. But wouldn't you agree that gcc could somehow distinguish whether the input files is of *.c or *.s source kind, and then decide if it should pass -I to the assembler or the preprocessor or both? That would be more in line with what I would expect after reading the documentation. Passing -I to the assembler when invoking the command 'gcc -c source.c' seems unnecessary. Of course I admit there could be something I'm missing here. sob., 24 wrz 2022 o 07:13 Xi Ruoyao napisaƂ(a): > On Fri, 2022-09-23 at 23:11 +0200, mizo 91 wrote: > > > From GNU assembler manual: > > > > > > -I dir > > > Add directory dir to the search list for ".include" > > > directives. > > > > > > So -I flags may be for preprocessor, or for assembler. > > > > I'm not calling the assembler. Im calling gcc. Check what gcc manual > > have to say about it. > > The problem is it's common to use "gcc -c foo.s" instead of "as foo.s -o > foo.o" in the building system of the packages. It can ensure the > assembler used for both C files and assembly files the same one. If you > suddenly stop to pass -I options to the assembler, you can break the > building process of existing packages. > -- > Xi Ruoyao > School of Aerospace Science and Technology, Xidian University >