simonjwright / distributing-gcc

Binary releases of GCC (native and cross) on macOS; also, the scripts/Makefiles used for producing them.
BSD 3-Clause "New" or "Revised" License
40 stars 0 forks source link

Case sensitivity on aarch64-apple-darwin #9

Open simonjwright opened 1 year ago

simonjwright commented 1 year ago

As discussed here, GCC thinks that macs with Apple silicon have case-sensitive file systems.

Most times you won’t notice this (because your files all have lower-case names which don’t use international characters); however, there’s one case where it has shown up, and that’s if your project (.gpr) file uses configuration pragmas. The case in point said

   package Builder is
      for Global_Configuration_Pragmas use "gnat.adc";
      ...
   end Builder;

   package Compiler is
      for Local_Configuration_Pragmas use "gnat_local.adc";
      ...
   end Compiler;

and the effect was that the whole project was recompiled even though nothing had changed.

The workround is to set

   export GNAT_FILE_NAME_CASE_SENSITIVE=0

in your login script.