As a rule, the later parameters in the line redefinition are passed earlier, as you noted in the first example. I personally have not come across any other behavior for the -m or -f flags, but I don't know the specific link in the documentation.
Note that some options do not behave like this:
$ gcc example.c -DABC -DABC=12 <command-line>: warning: "ABC" redefined <command-line>: warning: this is the location of the previous definition
Therefore, there must be -UABC to close this warning.
As an aside, clang especially good at solving this problem - it will issue a warning if it ignores a command line parameter that may help you.
Carl Norum
source share