* [PATCH] common: fix possible build problem without password support
@ 2013-10-14 15:39 Jan Luebbe
2013-10-14 15:46 ` [SPAM] " Jean-Christophe PLAGNIOL-VILLARD
2013-10-15 6:37 ` Sascha Hauer
0 siblings, 2 replies; 5+ messages in thread
From: Jan Luebbe @ 2013-10-14 15:39 UTC (permalink / raw)
To: barebox
In the case where CONFIG_PASSWORD is off, CONFIG_PASSWORD_DEFAULT is
undefined. As undefined is not "", this causes make to call find -type f.
If there is a filename containing a :, make will complain about having
"multiple target patterns"
Signed-off-by: Jan Luebbe <jlu@pengutronix.de>
---
common/Makefile | 2 ++
1 file changed, 2 insertions(+)
diff --git a/common/Makefile b/common/Makefile
index 75d924e..6f6e360 100644
--- a/common/Makefile
+++ b/common/Makefile
@@ -116,6 +116,7 @@ $(obj)/barebox_default_env.h: $(obj)/barebox_default_env$(barebox_default_env_co
$(call if_changed,env_h)
quiet_cmd_pwd_h = PWDH $@
+ifdef CONFIG_PASSWORD
ifneq ($(CONFIG_PASSWORD_DEFAULT),"")
PASSWD_FILE := $(shell cd $(srctree); find $(CONFIG_PASSWORD_DEFAULT) -type f)
cmd_pwd_h = echo -n "const char default_passwd[] = \"" > $@; \
@@ -134,6 +135,7 @@ endif
targets += include/generated/passwd.h
$(obj)/password.o: include/generated/passwd.h
+endif
# dependencies on generated files need to be listed explicitly
$(obj)/version.o: include/generated/compile.h
--
1.8.4.rc3
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [SPAM] [PATCH] common: fix possible build problem without password support
2013-10-14 15:39 [PATCH] common: fix possible build problem without password support Jan Luebbe
@ 2013-10-14 15:46 ` Jean-Christophe PLAGNIOL-VILLARD
2013-10-14 16:01 ` Jan Lübbe
2013-10-15 6:37 ` Sascha Hauer
1 sibling, 1 reply; 5+ messages in thread
From: Jean-Christophe PLAGNIOL-VILLARD @ 2013-10-14 15:46 UTC (permalink / raw)
To: Jan Luebbe; +Cc: barebox
On 17:39 Mon 14 Oct , Jan Luebbe wrote:
> In the case where CONFIG_PASSWORD is off, CONFIG_PASSWORD_DEFAULT is
> undefined. As undefined is not "", this causes make to call find -type f.
> If there is a filename containing a :, make will complain about having
> "multiple target patterns"
>
> Signed-off-by: Jan Luebbe <jlu@pengutronix.de>
> ---
> common/Makefile | 2 ++
> 1 file changed, 2 insertions(+)
>
> diff --git a/common/Makefile b/common/Makefile
> index 75d924e..6f6e360 100644
> --- a/common/Makefile
> +++ b/common/Makefile
> @@ -116,6 +116,7 @@ $(obj)/barebox_default_env.h: $(obj)/barebox_default_env$(barebox_default_env_co
> $(call if_changed,env_h)
>
> quiet_cmd_pwd_h = PWDH $@
> +ifdef CONFIG_PASSWORD
??
so if no password then it do
cmd_pwd_h = echo "const char default_passwd[] = \"\";" > $@
that's all
so we do not need to check CONFIG_PASSSORD
> ifneq ($(CONFIG_PASSWORD_DEFAULT),"")
> PASSWD_FILE := $(shell cd $(srctree); find $(CONFIG_PASSWORD_DEFAULT) -type f)
> cmd_pwd_h = echo -n "const char default_passwd[] = \"" > $@; \
> @@ -134,6 +135,7 @@ endif
> targets += include/generated/passwd.h
>
> $(obj)/password.o: include/generated/passwd.h
> +endif
>
> # dependencies on generated files need to be listed explicitly
> $(obj)/version.o: include/generated/compile.h
> --
> 1.8.4.rc3
>
>
> _______________________________________________
> barebox mailing list
> barebox@lists.infradead.org
> http://lists.infradead.org/mailman/listinfo/barebox
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [SPAM] [PATCH] common: fix possible build problem without password support
2013-10-14 15:46 ` [SPAM] " Jean-Christophe PLAGNIOL-VILLARD
@ 2013-10-14 16:01 ` Jan Lübbe
2013-10-14 17:06 ` Jean-Christophe PLAGNIOL-VILLARD
0 siblings, 1 reply; 5+ messages in thread
From: Jan Lübbe @ 2013-10-14 16:01 UTC (permalink / raw)
To: Barebox List
Hi,
On Mon, 2013-10-14 at 17:46 +0200, Jean-Christophe PLAGNIOL-VILLARD wrote:
> > quiet_cmd_pwd_h = PWDH $@
> > +ifdef CONFIG_PASSWORD
>
> ??
>
> so if no password then it do
>
> cmd_pwd_h = echo "const char default_passwd[] = \"\";" > $@
>
> that's all
>
> so we do not need to check CONFIG_PASSSORD
No. Try adding 'set -x;' to the shell call and building without
CONFIG_PASSWORD. In that case CONFIG_PASSWORD_DEFAULT is not set.
An unset Kconfig variable is not equal to "".
> > ifneq ($(CONFIG_PASSWORD_DEFAULT),"")
> > PASSWD_FILE := $(shell cd $(srctree); find $(CONFIG_PASSWORD_DEFAULT) -type f)
Try with:
PASSWD_FILE := $(shell set -x; cd $(srctree); echo `find $(CONFIG_PASSWORD_DEFAULT) -type f`)
> > cmd_pwd_h = echo -n "const char default_passwd[] = \"" > $@; \
> > @@ -134,6 +135,7 @@ endif
> > targets += include/generated/passwd.h
--
Pengutronix e.K. | |
Industrial Linux Solutions | http://www.pengutronix.de/ |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 |
Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 |
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [SPAM] [PATCH] common: fix possible build problem without password support
2013-10-14 16:01 ` Jan Lübbe
@ 2013-10-14 17:06 ` Jean-Christophe PLAGNIOL-VILLARD
0 siblings, 0 replies; 5+ messages in thread
From: Jean-Christophe PLAGNIOL-VILLARD @ 2013-10-14 17:06 UTC (permalink / raw)
To: Jan L??bbe; +Cc: Barebox List
On 18:01 Mon 14 Oct , Jan L??bbe wrote:
> Hi,
>
> On Mon, 2013-10-14 at 17:46 +0200, Jean-Christophe PLAGNIOL-VILLARD wrote:
> > > quiet_cmd_pwd_h = PWDH $@
> > > +ifdef CONFIG_PASSWORD
> >
> > ??
> >
> > so if no password then it do
> >
> > cmd_pwd_h = echo "const char default_passwd[] = \"\";" > $@
> >
> > that's all
> >
> > so we do not need to check CONFIG_PASSSORD
>
> No. Try adding 'set -x;' to the shell call and building without
> CONFIG_PASSWORD. In that case CONFIG_PASSWORD_DEFAULT is not set.
> An unset Kconfig variable is not equal to "".
>
> > > ifneq ($(CONFIG_PASSWORD_DEFAULT),"")
> > > PASSWD_FILE := $(shell cd $(srctree); find $(CONFIG_PASSWORD_DEFAULT) -type f)
>
> Try with:
> PASSWD_FILE := $(shell set -x; cd $(srctree); echo `find $(CONFIG_PASSWORD_DEFAULT) -type f`)
with set -x I've the issue ok
Best Regards,
J.
>
> > > cmd_pwd_h = echo -n "const char default_passwd[] = \"" > $@; \
> > > @@ -134,6 +135,7 @@ endif
> > > targets += include/generated/passwd.h
> --
> Pengutronix e.K. | |
> Industrial Linux Solutions | http://www.pengutronix.de/ |
> Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 |
> Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 |
>
>
> _______________________________________________
> barebox mailing list
> barebox@lists.infradead.org
> http://lists.infradead.org/mailman/listinfo/barebox
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] common: fix possible build problem without password support
2013-10-14 15:39 [PATCH] common: fix possible build problem without password support Jan Luebbe
2013-10-14 15:46 ` [SPAM] " Jean-Christophe PLAGNIOL-VILLARD
@ 2013-10-15 6:37 ` Sascha Hauer
1 sibling, 0 replies; 5+ messages in thread
From: Sascha Hauer @ 2013-10-15 6:37 UTC (permalink / raw)
To: Jan Luebbe; +Cc: barebox
On Mon, Oct 14, 2013 at 05:39:25PM +0200, Jan Luebbe wrote:
> In the case where CONFIG_PASSWORD is off, CONFIG_PASSWORD_DEFAULT is
> undefined. As undefined is not "", this causes make to call find -type f.
> If there is a filename containing a :, make will complain about having
> "multiple target patterns"
>
> Signed-off-by: Jan Luebbe <jlu@pengutronix.de>
Applied, thanks
Sascha
> ---
> common/Makefile | 2 ++
> 1 file changed, 2 insertions(+)
>
> diff --git a/common/Makefile b/common/Makefile
> index 75d924e..6f6e360 100644
> --- a/common/Makefile
> +++ b/common/Makefile
> @@ -116,6 +116,7 @@ $(obj)/barebox_default_env.h: $(obj)/barebox_default_env$(barebox_default_env_co
> $(call if_changed,env_h)
>
> quiet_cmd_pwd_h = PWDH $@
> +ifdef CONFIG_PASSWORD
> ifneq ($(CONFIG_PASSWORD_DEFAULT),"")
> PASSWD_FILE := $(shell cd $(srctree); find $(CONFIG_PASSWORD_DEFAULT) -type f)
> cmd_pwd_h = echo -n "const char default_passwd[] = \"" > $@; \
> @@ -134,6 +135,7 @@ endif
> targets += include/generated/passwd.h
>
> $(obj)/password.o: include/generated/passwd.h
> +endif
>
> # dependencies on generated files need to be listed explicitly
> $(obj)/version.o: include/generated/compile.h
> --
> 1.8.4.rc3
>
>
> _______________________________________________
> barebox mailing list
> barebox@lists.infradead.org
> http://lists.infradead.org/mailman/listinfo/barebox
>
--
Pengutronix e.K. | |
Industrial Linux Solutions | http://www.pengutronix.de/ |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 |
Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 |
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2013-10-15 6:37 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-10-14 15:39 [PATCH] common: fix possible build problem without password support Jan Luebbe
2013-10-14 15:46 ` [SPAM] " Jean-Christophe PLAGNIOL-VILLARD
2013-10-14 16:01 ` Jan Lübbe
2013-10-14 17:06 ` Jean-Christophe PLAGNIOL-VILLARD
2013-10-15 6:37 ` Sascha Hauer
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox