Openembedded Core Discussions
 help / color / mirror / Atom feed
From: Martin Jansa <martin.jansa@gmail.com>
To: Giuseppe CONDORELLI <giuseppe.condorelli@st.com>
Cc: openembedded-core@lists.openembedded.org
Subject: Re: [PATCH] base-files: do_install_basefilesissue error
Date: Tue, 23 Oct 2012 09:54:34 +0200	[thread overview]
Message-ID: <20121023075434.GM3269@jama.jama.net> (raw)
In-Reply-To: <1350919952-14859-1-git-send-email-giuseppe.condorelli@st.com>

[-- Attachment #1: Type: text/plain, Size: 2661 bytes --]

On Mon, Oct 22, 2012 at 05:32:32PM +0200, Giuseppe CONDORELLI wrote:
> Fixed error in do_install_basefilesissue, printf is now replaced by echo.

Looks like partial revert of

commit a19880ad10ccb5d7d909dcf9de5c3dc58a0ebcd3
Author: Andrei Gherzan <andrei@gherzan.ro>
Date:   Thu Sep 20 12:56:59 2012 +0300

    Replace "echo -e" with "printf" to have the same behavior in dash or bash

    oe-core removed the prerequisite to have sh as bash. POSIX doesn't define
    any options and furthermore allows 'echo -e' to be the default behavior.
    This means that in dash 'echo -e' will actually print '-e' and interpret
    backslashes by default. We use instead 'printf' builtin command with or
    without '\n' to simulate 'echo -e' or 'echo -n'.
    'printf' needs format while 'echo' can be used without any arguments. So
    'echo >' was replaced by 'printf "" >'.
    'echo' without '-n' flag adds a new line by default so to keep the same
    behavior of two new lines while using 'echo "\n"', 'printf "\n\n"' is
    used.

    [YOCTO #3138]

with very weak explanation why..

> 
> Signed-off-by: Giuseppe Condorelli <giuseppe.condorelli@st.com>
> ---
>  meta/recipes-core/base-files/base-files_3.0.14.bb |    8 ++++----
>  1 files changed, 4 insertions(+), 4 deletions(-)
> 
> diff --git a/meta/recipes-core/base-files/base-files_3.0.14.bb b/meta/recipes-core/base-files/base-files_3.0.14.bb
> index ba355ee..766b0e5 100644
> --- a/meta/recipes-core/base-files/base-files_3.0.14.bb
> +++ b/meta/recipes-core/base-files/base-files_3.0.14.bb
> @@ -117,11 +117,11 @@ do_install_basefilesissue () {
>  
>  	install -m 644 ${WORKDIR}/issue*  ${D}${sysconfdir}  
>          if [ -n "${DISTRO_NAME}" ]; then
> -		printf "${DISTRO_NAME} " >> ${D}${sysconfdir}/issue
> -		printf "${DISTRO_NAME} " >> ${D}${sysconfdir}/issue.net
> +		echo "${DISTRO_NAME} " >> ${D}${sysconfdir}/issue
> +		echo "${DISTRO_NAME} " >> ${D}${sysconfdir}/issue.net
>  		if [ -n "${DISTRO_VERSION}" ]; then
> -			printf "${DISTRO_VERSION} " >> ${D}${sysconfdir}/issue
> -			printf "${DISTRO_VERSION} " >> ${D}${sysconfdir}/issue.net
> +			echo "${DISTRO_VERSION} " >> ${D}${sysconfdir}/issue
> +			echo "${DISTRO_VERSION} " >> ${D}${sysconfdir}/issue.net
>  		fi
>  		echo "\n \l" >> ${D}${sysconfdir}/issue
>  		echo >> ${D}${sysconfdir}/issue
> -- 
> 1.7.4.4
> 
> 
> _______________________________________________
> Openembedded-core mailing list
> Openembedded-core@lists.openembedded.org
> http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-core

-- 
Martin 'JaMa' Jansa     jabber: Martin.Jansa@gmail.com

[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 205 bytes --]

  parent reply	other threads:[~2012-10-23  8:07 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-10-22 15:32 [PATCH] base-files: do_install_basefilesissue error Giuseppe CONDORELLI
2012-10-23  1:40 ` Chris Larson
2012-10-23  7:54 ` Martin Jansa [this message]
2012-10-23  7:56   ` Giuseppe Condorelli
  -- strict thread matches above, loose matches on Subject: below --
2012-10-23  6:45 Giuseppe CONDORELLI
2012-10-23  8:57 ` Richard Purdie
2012-10-23  9:00   ` Giuseppe Condorelli

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20121023075434.GM3269@jama.jama.net \
    --to=martin.jansa@gmail.com \
    --cc=giuseppe.condorelli@st.com \
    --cc=openembedded-core@lists.openembedded.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox