From a2ff748c9e7503130058d8301ccea44d92b728a7 Mon Sep 17 00:00:00 2001 From: Virgile Prevosto <virgile.prevosto@m4x.org> Date: Fri, 24 Mar 2023 14:23:18 +0100 Subject: [PATCH] [doc] update doc of cpp_arch_flags machdep field --- doc/developer/advance.tex | 13 ++++++------- share/machdeps/machdep-schema.yaml | 4 ++-- 2 files changed, 8 insertions(+), 9 deletions(-) diff --git a/doc/developer/advance.tex b/doc/developer/advance.tex index af30488ed5b..2f68a762d52 100644 --- a/doc/developer/advance.tex +++ b/doc/developer/advance.tex @@ -3269,13 +3269,12 @@ We present below a thorough description of each field. compiler-specific extensions. \end{itemize} Note that some compiler extensions, such as attributes, are always enabled. -\item[\texttt{cpp\_arch\_flags}]: list of arguments to be added to the - command-line when invoking the C preprocessor. Typically used to ensure that - multiarch compilers apply the appropriate predefined macros\footnote{Note that - the sizes of standard integer types are already defined in the machdep, - so they do not depend on these flags.}. - E.g. use \verb+["-m32"]+ for a 32-bit machdep when preprocessing with a - 64-bit multiarch GCC. +\item[\texttt{cpp\_arch\_flags}]: list of arguments used by the compiler to + select the corresponding architecture, e.g. \verb+["-m32"]+ for a 32-bit + machdep. Older versions (up to 26.x - Iron) of \framac did pass these flags to the pre-processor, + in order for it to define a set of built-in macros related to said architecture. + Current versions do not use this field, and rely on \texttt{\texttt{custom\_defs}} + containing the appropriate definitions. Note that, in practice, very few programs rely on such predefined macros, such as \verb+__x86_64+ and \verb+__i386+. \end{description} diff --git a/share/machdeps/machdep-schema.yaml b/share/machdeps/machdep-schema.yaml index 2044ecac188..3fd892b866a 100644 --- a/share/machdeps/machdep-schema.yaml +++ b/share/machdeps/machdep-schema.yaml @@ -87,8 +87,8 @@ compiler: cpp_arch_flags: description: | - arguments to be given to the compiler when this machdep is selected - (e.g. '-m32') + arguments to be given to the compiler to select the corresponding + architecture (e.g. '-m32') type: list -- GitLab