DPDK patches and discussions
 help / color / mirror / Atom feed
From: Christian Ehrhardt <christian.ehrhardt@canonical.com>
To: Thomas Monjalon <thomas.monjalon@6wind.com>
Cc: Ferruh Yigit <ferruh.yigit@intel.com>, dev <dev@dpdk.org>
Subject: Re: [dpdk-dev] [PATCH v2] mk: filter duplicate configuration entries
Date: Wed, 6 Jul 2016 07:37:18 +0200	[thread overview]
Message-ID: <CAATJJ0+1MWVE6C1MAr=etkSAErmNOg3mVm2k6b6yxL=VVB1e0w@mail.gmail.com> (raw)
In-Reply-To: <2194981.Lpk1XbM1Qo@xps13>

Hi,
I came up with something very similar when looking for tac replacements
yesterday, but had no time to finish things.
But your suggestion is even shorter - I had found "sed -n '1{h;T;};G;h;$p;'
file" or "sed -n '1!G;h;$p'".
That removes the tac dependency, which I agree is a good thing.

To chain things up without a temp file one would need the "in-place"
features of sed&awk which I'm not sure they are available (awk >=4.1 and
only GNU awk).
sed -i is only used in validate-abi.sh which might not be used on all
platforms to count as "-i is there already so I can use it".
And I really don't want to break anyone due to that change, just naively
clean up the resulting config a bit.
Also we already have a temp file .config_tmp in the same scope and remove
it on our own.
So it is not that much different to create and remove a second one for that
section.

Thanks for both of your feedback, submitting v3 now ...


Christian Ehrhardt
Software Engineer, Ubuntu Server
Canonical Ltd

On Tue, Jul 5, 2016 at 9:47 PM, Thomas Monjalon <thomas.monjalon@6wind.com>
wrote:

> 2016-07-05 17:47, Ferruh Yigit:
> > On 6/30/2016 1:00 PM, Christian Ehrhardt wrote:
> > > +           tac $(RTE_OUTPUT)/.config_tmp >
> $(RTE_OUTPUT)/.config_tmp_reverse ; \
> > Now we are adding new binary dependency (tac) to build system
>
> tac can be replaced by sed '1!G;h;$!d'
>
>

  reply	other threads:[~2016-07-06  5:37 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-06-13 11:50 [dpdk-dev] Duplicate config symbols Christian Ehrhardt
2016-06-13 13:07 ` Ferruh Yigit
2016-06-13 13:47 ` Thomas Monjalon
2016-06-13 15:09   ` Christian Ehrhardt
2016-06-13 15:10     ` [dpdk-dev] [RFC] mk: filter duplicate configuration entries Christian Ehrhardt
2016-06-28 16:11       ` Ferruh Yigit
2016-06-28 16:38         ` Christian Ehrhardt
2016-06-28 16:48           ` Ferruh Yigit
2016-06-30 11:57             ` Christian Ehrhardt
2016-06-30 12:00               ` [dpdk-dev] [PATCH v2] " Christian Ehrhardt
2016-07-05 16:47                 ` Ferruh Yigit
2016-07-05 19:47                   ` Thomas Monjalon
2016-07-06  5:37                     ` Christian Ehrhardt [this message]
2016-07-06  5:37                       ` [dpdk-dev] [PATCH v3] " Christian Ehrhardt
2016-07-06  8:06                         ` Ferruh Yigit
2016-07-06  8:12                         ` Bruce Richardson
2016-07-06  8:57                           ` Ferruh Yigit
2016-07-06  9:08                             ` Christian Ehrhardt
2016-07-06  9:13                               ` [dpdk-dev] [PATCH v4] " Christian Ehrhardt
2016-07-11 12:47                                 ` Thomas Monjalon
2016-07-06  9:30                             ` [dpdk-dev] [PATCH v3] " Bruce Richardson
2016-06-13 16:55     ` [dpdk-dev] Duplicate config symbols Thomas Monjalon

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='CAATJJ0+1MWVE6C1MAr=etkSAErmNOg3mVm2k6b6yxL=VVB1e0w@mail.gmail.com' \
    --to=christian.ehrhardt@canonical.com \
    --cc=dev@dpdk.org \
    --cc=ferruh.yigit@intel.com \
    --cc=thomas.monjalon@6wind.com \
    /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;
as well as URLs for NNTP newsgroup(s).