mailing list of musl libc
 help / color / mirror / code / Atom feed
* [PATCH] fix missing forward declaration of memset in sched.h
@ 2017-09-08  9:39 Jörg Krause
  2017-09-28 12:44 ` Jörg Krause
  0 siblings, 1 reply; 4+ messages in thread
From: Jörg Krause @ 2017-09-08  9:39 UTC (permalink / raw)
  To: musl; +Cc: Jörg Krause

Fixes build issue when using the macro `CPU_EQUAL()`, e.g. in Boost [1]:

```
libs/fiber/src/numa/linux/pin_thread.cpp:31:5: error: 'memset' was not declared in this scope
     CPU_ZERO( & set);
     ^
```

[1] https://github.com/boostorg/fiber/pull/142

Reported-by: Oliver Kowalke <oliver.kowalke@gmail.com>
Signed-off-by: Jörg Krause <joerg.krause@embedded.rocks>
---
 include/sched.h | 1 +
 1 file changed, 1 insertion(+)

diff --git a/include/sched.h b/include/sched.h
index d1cccb70..05d40b1e 100644
--- a/include/sched.h
+++ b/include/sched.h
@@ -72,6 +72,7 @@ int setns(int, int);
 
 void *memcpy(void *__restrict, const void *__restrict, size_t);
 int memcmp(const void *, const void *, size_t);
+void *memset (void *, int, size_t);
 void *calloc(size_t, size_t);
 void free(void *);
 
-- 
2.14.1


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

* Re: [PATCH] fix missing forward declaration of memset in sched.h
  2017-09-08  9:39 [PATCH] fix missing forward declaration of memset in sched.h Jörg Krause
@ 2017-09-28 12:44 ` Jörg Krause
  2017-09-28 16:56   ` Rich Felker
  0 siblings, 1 reply; 4+ messages in thread
From: Jörg Krause @ 2017-09-28 12:44 UTC (permalink / raw)
  To: musl; +Cc: Szabolcs Nagy, Rich Felker

Hi,

On Fri, 2017-09-08 at 11:39 +0200, Jörg Krause wrote:
> Fixes build issue when using the macro `CPU_EQUAL()`, e.g. in Boost [1]:
> 
> ```
> libs/fiber/src/numa/linux/pin_thread.cpp:31:5: error: 'memset' was not declared in this scope
>      CPU_ZERO( & set);
>      ^
> ```
> 
> [1] https://github.com/boostorg/fiber/pull/142
> 
> Reported-by: Oliver Kowalke <oliver.kowalke@gmail.com>
> Signed-off-by: Jörg Krause <joerg.krause@embedded.rocks>
> ---
>  include/sched.h | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/include/sched.h b/include/sched.h
> index d1cccb70..05d40b1e 100644
> --- a/include/sched.h
> +++ b/include/sched.h
> @@ -72,6 +72,7 @@ int setns(int, int);
>  
>  void *memcpy(void *__restrict, const void *__restrict, size_t);
>  int memcmp(const void *, const void *, size_t);
> +void *memset (void *, int, size_t);
>  void *calloc(size_t, size_t);
>  void free(void *);
>  

Any feedback on this?

Best regards,
Jörg Krause


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

* Re: [PATCH] fix missing forward declaration of memset in sched.h
  2017-09-28 12:44 ` Jörg Krause
@ 2017-09-28 16:56   ` Rich Felker
  2017-10-02 16:41     ` Jörg Krause
  0 siblings, 1 reply; 4+ messages in thread
From: Rich Felker @ 2017-09-28 16:56 UTC (permalink / raw)
  To: musl

On Thu, Sep 28, 2017 at 02:44:51PM +0200, Jörg Krause wrote:
> Hi,
> 
> On Fri, 2017-09-08 at 11:39 +0200, Jörg Krause wrote:
> > Fixes build issue when using the macro `CPU_EQUAL()`, e.g. in Boost [1]:
> > 
> > ```
> > libs/fiber/src/numa/linux/pin_thread.cpp:31:5: error: 'memset' was not declared in this scope
> >      CPU_ZERO( & set);
> >      ^
> > ```
> > 
> > [1] https://github.com/boostorg/fiber/pull/142
> > 
> > Reported-by: Oliver Kowalke <oliver.kowalke@gmail.com>
> > Signed-off-by: Jörg Krause <joerg.krause@embedded.rocks>
> > ---
> >  include/sched.h | 1 +
> >  1 file changed, 1 insertion(+)
> > 
> > diff --git a/include/sched.h b/include/sched.h
> > index d1cccb70..05d40b1e 100644
> > --- a/include/sched.h
> > +++ b/include/sched.h
> > @@ -72,6 +72,7 @@ int setns(int, int);
> >  
> >  void *memcpy(void *__restrict, const void *__restrict, size_t);
> >  int memcmp(const void *, const void *, size_t);
> > +void *memset (void *, int, size_t);
> >  void *calloc(size_t, size_t);
> >  void free(void *);
> >  
> 
> Any feedback on this?

It looks fine. Thanks and sorry for not replying sooner.

Rich


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

* Re: [PATCH] fix missing forward declaration of memset in sched.h
  2017-09-28 16:56   ` Rich Felker
@ 2017-10-02 16:41     ` Jörg Krause
  0 siblings, 0 replies; 4+ messages in thread
From: Jörg Krause @ 2017-10-02 16:41 UTC (permalink / raw)
  To: musl; +Cc: Rich Felker

On Thu, 2017-09-28 at 12:56 -0400, Rich Felker wrote:
> On Thu, Sep 28, 2017 at 02:44:51PM +0200, Jörg Krause wrote:
> > Hi,
> > 
> > On Fri, 2017-09-08 at 11:39 +0200, Jörg Krause wrote:
> > > Fixes build issue when using the macro `CPU_EQUAL()`, e.g. in Boost [1]:
> > > 
> > > ```
> > > libs/fiber/src/numa/linux/pin_thread.cpp:31:5: error: 'memset' was not declared in this scope
> > >      CPU_ZERO( & set);
> > >      ^
> > > ```
> > > 
> > > [1] https://github.com/boostorg/fiber/pull/142
> > > 
> > > Reported-by: Oliver Kowalke <oliver.kowalke@gmail.com>
> > > Signed-off-by: Jörg Krause <joerg.krause@embedded.rocks>
> > > ---
> > >  include/sched.h | 1 +
> > >  1 file changed, 1 insertion(+)
> > > 
> > > diff --git a/include/sched.h b/include/sched.h
> > > index d1cccb70..05d40b1e 100644
> > > --- a/include/sched.h
> > > +++ b/include/sched.h
> > > @@ -72,6 +72,7 @@ int setns(int, int);
> > >  
> > >  void *memcpy(void *__restrict, const void *__restrict, size_t);
> > >  int memcmp(const void *, const void *, size_t);
> > > +void *memset (void *, int, size_t);
> > >  void *calloc(size_t, size_t);
> > >  void free(void *);
> > >  
> > 
> > Any feedback on this?
> 
> It looks fine. Thanks and sorry for not replying sooner.

No problem! Will it be merged?

Jörg


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

end of thread, other threads:[~2017-10-02 16:41 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-09-08  9:39 [PATCH] fix missing forward declaration of memset in sched.h Jörg Krause
2017-09-28 12:44 ` Jörg Krause
2017-09-28 16:56   ` Rich Felker
2017-10-02 16:41     ` Jörg Krause

Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/musl/

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).