diff mbox series

[v2,1/3] package/vdr: Fix patch for uclibc build

Message ID 20230516194855.1548486-1-bernd.kuhls@t-online.de
State Accepted
Headers show
Series [v2,1/3] package/vdr: Fix patch for uclibc build | expand

Commit Message

Bernd Kuhls May 16, 2023, 7:48 p.m. UTC
uClibc-ng 1.0.42 added support for getloadavg:
https://cgit.uclibc-ng.org/cgi/cgit/uclibc-ng.git/commit/?id=ad3a130dad88ad7a59dcd965b0cf9bd0d713595e

leading to build errors of the vdr package:

skinlcars.c:1105:12: error: 'int getloadavg(double*, int)' was declared 'extern' and later 'static' [-fpermissive]

since its version bump in buildroot:
https://git.busybox.net/buildroot/commit/?id=61ae6add9e5d4761536fa4ff24150d5f8f82a61d

Fixes:
http://autobuild.buildroot.net/results/d3a/d3a65044fabdafa1b6d75a508eae006a2cfebdc0/

Signed-off-by: Bernd Kuhls <bernd.kuhls@t-online.de>
---
I do not know whether all external toolchains were already updated to
uClibc-ng >= 1.0.42 so I fixed the patch instead of removing it.
Due to uClibc-ng providing getloadavg() sending 0001-getloadavg.patch
makes no sense imho.

v2: no changes

 package/vdr/0001-getloadavg.patch | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Arnout Vandecappelle June 3, 2023, 7:53 p.m. UTC | #1
On 16/05/2023 21:48, Bernd Kuhls wrote:
> uClibc-ng 1.0.42 added support for getloadavg:
> https://cgit.uclibc-ng.org/cgi/cgit/uclibc-ng.git/commit/?id=ad3a130dad88ad7a59dcd965b0cf9bd0d713595e
> 
> leading to build errors of the vdr package:
> 
> skinlcars.c:1105:12: error: 'int getloadavg(double*, int)' was declared 'extern' and later 'static' [-fpermissive]
> 
> since its version bump in buildroot:
> https://git.busybox.net/buildroot/commit/?id=61ae6add9e5d4761536fa4ff24150d5f8f82a61d
> 
> Fixes:
> http://autobuild.buildroot.net/results/d3a/d3a65044fabdafa1b6d75a508eae006a2cfebdc0/
> 
> Signed-off-by: Bernd Kuhls <bernd.kuhls@t-online.de>

  Applied all three to master, thanks.

> ---
> I do not know whether all external toolchains were already updated to
> uClibc-ng >= 1.0.42 so I fixed the patch instead of removing it.

  Yeah, 1.0.42 is just a year old so a bit early to rely on it I think.

> Due to uClibc-ng providing getloadavg() sending 0001-getloadavg.patch
> makes no sense imho.

  True, but it would make sense to add an Upstream: tag to the patch that 
explains why it's not upstreamable. Well, not really important, don't bother 
doing it.

  Regards,
  Arnout

> 
> v2: no changes
> 
>   package/vdr/0001-getloadavg.patch | 2 +-
>   1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/package/vdr/0001-getloadavg.patch b/package/vdr/0001-getloadavg.patch
> index 9e6316e284..f6ba84c9e5 100644
> --- a/package/vdr/0001-getloadavg.patch
> +++ b/package/vdr/0001-getloadavg.patch
> @@ -14,7 +14,7 @@ diff -uwNr vdr-2.3.1.org/skinlcars.c vdr-2.3.1/skinlcars.c
>    
>   +/* uclibc and dietlibc do not have this junk -ReneR */
>   +#if defined (__UCLIBC__) || defined (__dietlibc__)
> -+static int getloadavg (double loadavg[], int nelem)
> ++int getloadavg (double loadavg[], int nelem)
>   +{
>   +  int fd;
>   +
Peter Korsgaard June 14, 2023, 1:33 p.m. UTC | #2
>>>>> "Bernd" == Bernd Kuhls <bernd.kuhls@t-online.de> writes:

 > uClibc-ng 1.0.42 added support for getloadavg:
 > https://cgit.uclibc-ng.org/cgi/cgit/uclibc-ng.git/commit/?id=ad3a130dad88ad7a59dcd965b0cf9bd0d713595e

 > leading to build errors of the vdr package:

 > skinlcars.c:1105:12: error: 'int getloadavg(double*, int)' was declared 'extern' and later 'static' [-fpermissive]

 > since its version bump in buildroot:
 > https://git.busybox.net/buildroot/commit/?id=61ae6add9e5d4761536fa4ff24150d5f8f82a61d

 > Fixes:
 > http://autobuild.buildroot.net/results/d3a/d3a65044fabdafa1b6d75a508eae006a2cfebdc0/

 > Signed-off-by: Bernd Kuhls <bernd.kuhls@t-online.de>
 > ---
 > I do not know whether all external toolchains were already updated to
 > uClibc-ng >= 1.0.42 so I fixed the patch instead of removing it.
 > Due to uClibc-ng providing getloadavg() sending 0001-getloadavg.patch
 > makes no sense imho.

Committed to 2023.02.x, thanks.
diff mbox series

Patch

diff --git a/package/vdr/0001-getloadavg.patch b/package/vdr/0001-getloadavg.patch
index 9e6316e284..f6ba84c9e5 100644
--- a/package/vdr/0001-getloadavg.patch
+++ b/package/vdr/0001-getloadavg.patch
@@ -14,7 +14,7 @@  diff -uwNr vdr-2.3.1.org/skinlcars.c vdr-2.3.1/skinlcars.c
  
 +/* uclibc and dietlibc do not have this junk -ReneR */
 +#if defined (__UCLIBC__) || defined (__dietlibc__)
-+static int getloadavg (double loadavg[], int nelem)
++int getloadavg (double loadavg[], int nelem)
 +{
 +  int fd;
 +