]> rtime.felk.cvut.cz Git - coffee/buildroot.git/blob - package/xfsprogs/0003-workqueue-add-missing-pthreads-header.patch
xfsprogs: fix build with musl
[coffee/buildroot.git] / package / xfsprogs / 0003-workqueue-add-missing-pthreads-header.patch
1 From c05fc32d43b3870b63539c57428e1c52e3e7c3cd Mon Sep 17 00:00:00 2001
2 From: Baruch Siach <baruch@tkos.co.il>
3 Date: Fri, 16 Mar 2018 07:14:56 +0200
4 Subject: [PATCH] workqueue: add missing pthreads header
5
6 Fix the following build failure with musl libc:
7
8 In file included from read_verify.c:25:0:
9 ../include/workqueue.h:39:2: error: unknown type name 'pthread_t'
10   pthread_t  *threads;
11   ^~~~~~~~~
12 ../include/workqueue.h:42:2: error: unknown type name 'pthread_mutex_t'
13   pthread_mutex_t  lock;
14   ^~~~~~~~~~~~~~~
15 ../include/workqueue.h:43:2: error: unknown type name 'pthread_cond_t'
16   pthread_cond_t  wakeup;
17   ^~~~~~~~~~~~~~
18
19 Signed-off-by: Baruch Siach <baruch@tkos.co.il>
20 ---
21 Upstream status: https://marc.info/?l=linux-xfs&m=152117771313565&w=2
22
23  include/workqueue.h | 2 ++
24  1 file changed, 2 insertions(+)
25
26 diff --git a/include/workqueue.h b/include/workqueue.h
27 index b4b3541701df..edb2f8ac5991 100644
28 --- a/include/workqueue.h
29 +++ b/include/workqueue.h
30 @@ -22,6 +22,8 @@
31  #ifndef        _WORKQUEUE_H_
32  #define        _WORKQUEUE_H_
33  
34 +#include <pthread.h>
35 +
36  struct workqueue;
37  
38  typedef void workqueue_func_t(struct workqueue *wq, uint32_t index, void *arg);
39 -- 
40 2.16.2
41