public inbox for openembedded-core@lists.openembedded.org
 help / color / mirror / Atom feed
* [PATCH pseudo] Fix build with gcc 10
@ 2020-11-20 16:38 vincent.stehle
  2020-11-20 17:24 ` [OE-core] " Richard Purdie
  0 siblings, 1 reply; 3+ messages in thread
From: vincent.stehle @ 2020-11-20 16:38 UTC (permalink / raw)
  To: openembedded-core; +Cc: Vincent Stehlé

Add a missing typedef in front of the pseudo_access_t definition. Otherwise
pseudo_access_t ends up being a global enum, defined each time pseudo_ipc.h
is included.

This fixes the following link time error with gcc 10:

  multiple definition of `pseudo_access_t'

Signed-off-by: Vincent Stehlé <vincent.stehle@arm.com>
---
 pseudo_ipc.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/pseudo_ipc.h b/pseudo_ipc.h
index caeae5c..d945257 100644
--- a/pseudo_ipc.h
+++ b/pseudo_ipc.h
@@ -29,7 +29,7 @@ typedef struct {
 	char path[];
 } pseudo_msg_t;
 
-enum {
+typedef enum {
 	PSA_EXEC = 1,
 	PSA_WRITE = (PSA_EXEC << 1),
 	PSA_READ = (PSA_WRITE << 1),
-- 
2.29.2


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

* Re: [OE-core] [PATCH pseudo] Fix build with gcc 10
  2020-11-20 16:38 [PATCH pseudo] Fix build with gcc 10 vincent.stehle
@ 2020-11-20 17:24 ` Richard Purdie
  2020-11-20 17:28   ` Vincent Stehlé
  0 siblings, 1 reply; 3+ messages in thread
From: Richard Purdie @ 2020-11-20 17:24 UTC (permalink / raw)
  To: Vincent Stehlé, openembedded-core

On Fri, 2020-11-20 at 17:38 +0100, Vincent Stehlé wrote:
> Add a missing typedef in front of the pseudo_access_t definition.
> Otherwise
> pseudo_access_t ends up being a global enum, defined each time
> pseudo_ipc.h
> is included.
> 
> This fixes the following link time error with gcc 10:
> 
>   multiple definition of `pseudo_access_t'
> 
> Signed-off-by: Vincent Stehlé <vincent.stehle@arm.com>
> ---
>  pseudo_ipc.h | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/pseudo_ipc.h b/pseudo_ipc.h
> index caeae5c..d945257 100644
> --- a/pseudo_ipc.h
> +++ b/pseudo_ipc.h
> @@ -29,7 +29,7 @@ typedef struct {
>  	char path[];
>  } pseudo_msg_t;
>  
> -enum {
> +typedef enum {
>  	PSA_EXEC = 1,
>  	PSA_WRITE = (PSA_EXEC << 1),
>  	PSA_READ = (PSA_WRITE << 1),

I think we already have this in the pseudo branch we use for OE?

http://git.yoctoproject.org/cgit.cgi/pseudo/commit/pseudo_ipc.h?h=oe-core&id=a44361b8d3fbf5fc40cd87b599caeb380454efbe

Cheers,

Richard


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

* Re: [OE-core] [PATCH pseudo] Fix build with gcc 10
  2020-11-20 17:24 ` [OE-core] " Richard Purdie
@ 2020-11-20 17:28   ` Vincent Stehlé
  0 siblings, 0 replies; 3+ messages in thread
From: Vincent Stehlé @ 2020-11-20 17:28 UTC (permalink / raw)
  To: Richard Purdie; +Cc: openembedded-core

On Fri, Nov 20, 2020 at 05:24:31PM +0000, Richard Purdie wrote:
> I think we already have this in the pseudo branch we use for OE?

Hi Richard,

This is correct. I was looking at the master branch. Sorry for the noise.

Best regards,
Vincent.

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

end of thread, other threads:[~2020-11-20 17:28 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2020-11-20 16:38 [PATCH pseudo] Fix build with gcc 10 vincent.stehle
2020-11-20 17:24 ` [OE-core] " Richard Purdie
2020-11-20 17:28   ` Vincent Stehlé

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox