* [ptxdist] [PATCH v2] doc: mention dedicated PTXdist macros to be used in rule files
@ 2019-02-22 11:57 Juergen Borleis
2019-02-22 13:15 ` Juergen Borleis
0 siblings, 1 reply; 2+ messages in thread
From: Juergen Borleis @ 2019-02-22 11:57 UTC (permalink / raw)
To: ptxdist
In order to simplify rule files, it's worth to use more of the provided
rule file option macros PTXdist already provides.
Signed-off-by: Juergen Borleis <jbe@pengutronix.de>
---
doc/dev_manual.rst | 22 ++++++++--------------
1 file changed, 8 insertions(+), 14 deletions(-)
diff --git a/doc/dev_manual.rst b/doc/dev_manual.rst
index f0c2e00ee..effafa6e0 100644
--- a/doc/dev_manual.rst
+++ b/doc/dev_manual.rst
@@ -892,23 +892,17 @@ file and add the correct parameters:
#
# autoconf
#
- FOO_CONF_OPT := $(CROSS_AUTOCONF_USR)
-
- ifdef PTXCONF_FOO_DEBUG
- FOO_CONF_OPT += --enable-debug
- else
- FOO_CONF_OPT += --disable-debug
- endif
-
- ifdef PTXCONF_FOO_BAR
- FOO_CONF_OPT += --with-bar
- else
- FOO_CONF_OPT += --without-bar
- endif
+ FOO_CONF_OPT := \
+ $(CROSS_AUTOCONF_USR) \
+ --$(call ptx/endis, PTXCONF_FOO_DEBUG)-debug \
+ --$(call ptx/wwo, PTXCONF_FOO_BAR)-bar
-.. important:: Please note the trailing ``PTXCONF_`` for each define. While Kconfig is
+.. important:: Please note the leading ``PTXCONF_`` for each define. While Kconfig is
using ``FOO_BAR``, the rule file must use ``PTXCONF_FOO_BAR`` instead.
+.. note:: Refer :ref:`Rule File Macro Reference <param_macros>` for further
+ details about these special kind of option macros (e.g. ``ptx/...``).
+
It is a good practice to add both settings, e.g. ``--disable-debug``
even if this is the default case. Sometimes ``configure`` tries to guess
something and the binary result might differ depending on the build
--
2.11.0
_______________________________________________
ptxdist mailing list
ptxdist@pengutronix.de
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [ptxdist] [PATCH v2] doc: mention dedicated PTXdist macros to be used in rule files
2019-02-22 11:57 [ptxdist] [PATCH v2] doc: mention dedicated PTXdist macros to be used in rule files Juergen Borleis
@ 2019-02-22 13:15 ` Juergen Borleis
0 siblings, 0 replies; 2+ messages in thread
From: Juergen Borleis @ 2019-02-22 13:15 UTC (permalink / raw)
To: ptxdist
On Friday 22 February 2019 12:57:05 Myself wrote:
> In order to simplify rule files, it's worth to use more of the provided
> rule file option macros PTXdist already provides.
>
> Signed-off-by: Juergen Borleis <jbe@pengutronix.de>
> ---
> doc/dev_manual.rst | 22 ++++++++--------------
> 1 file changed, 8 insertions(+), 14 deletions(-)
>
> diff --git a/doc/dev_manual.rst b/doc/dev_manual.rst
> index f0c2e00ee..effafa6e0 100644
> --- a/doc/dev_manual.rst
> +++ b/doc/dev_manual.rst
> @@ -892,23 +892,17 @@ file and add the correct parameters:
> #
> # autoconf
> #
> - FOO_CONF_OPT := $(CROSS_AUTOCONF_USR)
> -
> - ifdef PTXCONF_FOO_DEBUG
> - FOO_CONF_OPT += --enable-debug
> - else
> - FOO_CONF_OPT += --disable-debug
> - endif
> -
> - ifdef PTXCONF_FOO_BAR
> - FOO_CONF_OPT += --with-bar
> - else
> - FOO_CONF_OPT += --without-bar
> - endif
> + FOO_CONF_OPT := \
> + $(CROSS_AUTOCONF_USR) \
> + --$(call ptx/endis, PTXCONF_FOO_DEBUG)-debug \
> + --$(call ptx/wwo, PTXCONF_FOO_BAR)-bar
>
> -.. important:: Please note the trailing ``PTXCONF_`` for each define.
> While Kconfig is +.. important:: Please note the leading ``PTXCONF_`` for
> each define. While Kconfig is using ``FOO_BAR``, the rule file must use
> ``PTXCONF_FOO_BAR`` instead.
>
> +.. note:: Refer :ref:`Rule File Macro Reference <param_macros>` for
> further + details about these special kind of option macros (e.g.
> ``ptx/...``). +
> It is a good practice to add both settings, e.g. ``--disable-debug``
> even if this is the default case. Sometimes ``configure`` tries to guess
> something and the binary result might differ depending on the build
Please do not apply. The same text can be found a few lines below.
jb
--
Pengutronix e.K. | Juergen Borleis |
Industrial Linux Solutions | http://www.pengutronix.de/ |
_______________________________________________
ptxdist mailing list
ptxdist@pengutronix.de
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2019-02-22 13:15 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-02-22 11:57 [ptxdist] [PATCH v2] doc: mention dedicated PTXdist macros to be used in rule files Juergen Borleis
2019-02-22 13:15 ` Juergen Borleis
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox