All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] opkg: Fix patch glitches
@ 2021-02-09 14:34 Richard Purdie
  2021-02-09 15:16 ` [OE-core] " Matt Madison
  0 siblings, 1 reply; 4+ messages in thread
From: Richard Purdie @ 2021-02-09 14:34 UTC (permalink / raw)
  To: openembedded-core

The original patch contained some text which shouldn't have been there
and used brackets in configure which isn't a great idea. Tweak the patch
to resolve this.

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
---
 meta/recipes-devtools/opkg/opkg/sourcedateepoch.patch | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/meta/recipes-devtools/opkg/opkg/sourcedateepoch.patch b/meta/recipes-devtools/opkg/opkg/sourcedateepoch.patch
index 285d258c635..6d0b1486ad3 100644
--- a/meta/recipes-devtools/opkg/opkg/sourcedateepoch.patch
+++ b/meta/recipes-devtools/opkg/opkg/sourcedateepoch.patch
@@ -9,13 +9,12 @@ Index: opkg-0.4.4/configure.ac
 ===================================================================
 --- opkg-0.4.4.orig/configure.ac
 +++ opkg-0.4.4/configure.ac
-@@ -281,7 +281,12 @@ AC_FUNC_UTIME_NULL
+@@ -281,7 +281,11 @@ AC_FUNC_UTIME_NULL
  AC_FUNC_VPRINTF
  AC_CHECK_FUNCS([memmove memset mkdir regcomp strchr strcspn strdup strerror strndup strrchr strstr strtol strtoul sysinfo utime])
  
 -CLEAN_DATE=`date +"%B %Y" | tr -d '\n'`
-+1607446883
-+if [ ! -z "$SOURCE_DATE_EPOCH" ]; then
++if ! -z "$SOURCE_DATE_EPOCH" ; then
 +    CLEAN_DATE=`LC_ALL=C date -d @$SOURCE_DATE_EPOCH +"%B %Y" | tr -d '\n'`
 +else
 +    CLEAN_DATE=`date +"%B %Y" | tr -d '\n'`
-- 
2.27.0


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [OE-core] [PATCH] opkg: Fix patch glitches
  2021-02-09 14:34 [PATCH] opkg: Fix patch glitches Richard Purdie
@ 2021-02-09 15:16 ` Matt Madison
  2021-02-09 15:23   ` Richard Purdie
  0 siblings, 1 reply; 4+ messages in thread
From: Matt Madison @ 2021-02-09 15:16 UTC (permalink / raw)
  To: Richard Purdie; +Cc: Patches and discussions about the oe-core layer

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

On Tue, Feb 9, 2021 at 6:34 AM Richard Purdie <
richard.purdie@linuxfoundation.org> wrote:

> The original patch contained some text which shouldn't have been there
> and used brackets in configure which isn't a great idea. Tweak the patch
> to resolve this.
>
> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
> ---
>  meta/recipes-devtools/opkg/opkg/sourcedateepoch.patch | 5 ++---
>  1 file changed, 2 insertions(+), 3 deletions(-)
>
> diff --git a/meta/recipes-devtools/opkg/opkg/sourcedateepoch.patch
> b/meta/recipes-devtools/opkg/opkg/sourcedateepoch.patch
> index 285d258c635..6d0b1486ad3 100644
> --- a/meta/recipes-devtools/opkg/opkg/sourcedateepoch.patch
> +++ b/meta/recipes-devtools/opkg/opkg/sourcedateepoch.patch
> @@ -9,13 +9,12 @@ Index: opkg-0.4.4/configure.ac
>  ===================================================================
>  --- opkg-0.4.4.orig/configure.ac
>  +++ opkg-0.4.4/configure.ac
> -@@ -281,7 +281,12 @@ AC_FUNC_UTIME_NULL
> +@@ -281,7 +281,11 @@ AC_FUNC_UTIME_NULL
>   AC_FUNC_VPRINTF
>   AC_CHECK_FUNCS([memmove memset mkdir regcomp strchr strcspn strdup
> strerror strndup strrchr strstr strtol strtoul sysinfo utime])
>
>  -CLEAN_DATE=`date +"%B %Y" | tr -d '\n'`
> -+1607446883
> -+if [ ! -z "$SOURCE_DATE_EPOCH" ]; then
> ++if ! -z "$SOURCE_DATE_EPOCH" ; then
>

This doesn't look like valid shell syntax - there should be a 'test'
command before the '!', right?
Or change the whole thing to use AS_IF.

-Matt

 +    CLEAN_DATE=`LC_ALL=C date -d @$SOURCE_DATE_EPOCH +"%B %Y" | tr -d
> '\n'`
>  +else
>  +    CLEAN_DATE=`date +"%B %Y" | tr -d '\n'`
> --
> 2.27.0
>
>
> 
>
>

[-- Attachment #2: Type: text/html, Size: 2666 bytes --]

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [OE-core] [PATCH] opkg: Fix patch glitches
  2021-02-09 15:16 ` [OE-core] " Matt Madison
@ 2021-02-09 15:23   ` Richard Purdie
  2021-02-09 16:53     ` Alex Stewart
  0 siblings, 1 reply; 4+ messages in thread
From: Richard Purdie @ 2021-02-09 15:23 UTC (permalink / raw)
  To: Matt Madison; +Cc: Patches and discussions about the oe-core layer

On Tue, 2021-02-09 at 07:16 -0800, Matt Madison wrote:
> 
> 
> On Tue, Feb 9, 2021 at 6:34 AM Richard Purdie
> <richard.purdie@linuxfoundation.org> wrote:
> > The original patch contained some text which shouldn't have been
> > there
> > and used brackets in configure which isn't a great idea. Tweak the
> > patch
> > to resolve this.
> > 
> > Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
> > ---
> >  meta/recipes-devtools/opkg/opkg/sourcedateepoch.patch | 5 ++---
> >  1 file changed, 2 insertions(+), 3 deletions(-)
> > 
> > diff --git a/meta/recipes-devtools/opkg/opkg/sourcedateepoch.patch
> > b/meta/recipes-devtools/opkg/opkg/sourcedateepoch.patch
> > index 285d258c635..6d0b1486ad3 100644
> > --- a/meta/recipes-devtools/opkg/opkg/sourcedateepoch.patch
> > +++ b/meta/recipes-devtools/opkg/opkg/sourcedateepoch.patch
> > @@ -9,13 +9,12 @@ Index: opkg-0.4.4/configure.ac
> >  ==================================================================
> > =
> >  --- opkg-0.4.4.orig/configure.ac
> >  +++ opkg-0.4.4/configure.ac
> > -@@ -281,7 +281,12 @@ AC_FUNC_UTIME_NULL
> > +@@ -281,7 +281,11 @@ AC_FUNC_UTIME_NULL
> >   AC_FUNC_VPRINTF
> >   AC_CHECK_FUNCS([memmove memset mkdir regcomp strchr strcspn
> > strdup strerror strndup strrchr strstr strtol strtoul sysinfo
> > utime])
> > 
> >  -CLEAN_DATE=`date +"%B %Y" | tr -d '\n'`
> > -+1607446883
> > -+if [ ! -z "$SOURCE_DATE_EPOCH" ]; then
> > ++if ! -z "$SOURCE_DATE_EPOCH" ; then
> > 
> 
> This doesn't look like valid shell syntax - there should be a 'test'
> command before the '!', right?
> Or change the whole thing to use AS_IF.

Well spotted. I somehow grabbed a half complete version, trying to
juggle too many things at once I think. I've fixed it on the branch,
third time lucky :/.

Cheers,

Richard



^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [OE-core] [PATCH] opkg: Fix patch glitches
  2021-02-09 15:23   ` Richard Purdie
@ 2021-02-09 16:53     ` Alex Stewart
  0 siblings, 0 replies; 4+ messages in thread
From: Alex Stewart @ 2021-02-09 16:53 UTC (permalink / raw)
  To: Richard Purdie; +Cc: Patches and discussions about the oe-core layer

Hey Richard,

On 2/9/21 9:23 AM, Richard Purdie wrote:
> Well spotted. I somehow grabbed a half complete version, trying to
> juggle too many things at once I think. I've fixed it on the branch,
> third time lucky :/.

The new patch on master-next looks good. Could you submit it to the 
opkg-devel ML, so that I can pull it from there?

Thanks!

-- 
Alex Stewart
Software Engineer - NI Real-Time OS
NI (National Instruments)

alex.stewart@ni.com


^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2021-02-09 16:53 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-02-09 14:34 [PATCH] opkg: Fix patch glitches Richard Purdie
2021-02-09 15:16 ` [OE-core] " Matt Madison
2021-02-09 15:23   ` Richard Purdie
2021-02-09 16:53     ` Alex Stewart

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.