Fredrik Holmqvist wrote: > In configure you have the possibility to set them: > HAIKU_CCFLAGS The C flags. Defaults to "". > HAIKU_CXXFLAGS The C++ flags. Defaults to "". > > They are saved in generated/build/BuildConfig and read by JamRules. > After that they are completly overwritten by BuildSetup. > > So if the user now configure with these flags, like my tests with > "-march=native -O3" and "-march=native -Os" they get respected and > used. > > It was done because people trying to use llvm needed to set specific > flags at the moment. OK, I see. I believe the flags support in the configure script was only introduced for sake of completeness, not because anyone needed it at that time. Flags given this way usually don't replace flags set by the build system, but just are added. So the only change I'd have suggested is replacing the "=" in the first assignment to these variables in BuildSetup by a "+=". > If it should not be available I understand that, but the current form > is kindof broken. I don't mind the variables to work correctly. I just wondered what you actually implemented. The -march=native is nothing I find useful at all as it produces unportable code. I don't think that's something we should allow (via the configure variables or otherwise). The optimization level can be specified with the OPTIM jam variable, which can be set in UserBuildConfig. There's no need to do that at configuration time. CU, Ingo