b.liu | e958203 | 2025-04-17 19:18:16 +0800 | [diff] [blame^] | 1 | From 7235a786ea30ae5ca7c1b3458ef5b2388c08dfd9 Mon Sep 17 00:00:00 2001 |
| 2 | From: Rosen Penev <rosenp@gmail.com> |
| 3 | Date: Thu, 28 Mar 2019 18:44:27 -0700 |
| 4 | Subject: [PATCH] src/main: Add missing pthread header |
| 5 | |
| 6 | Otherwise compilation can fail with: |
| 7 | |
| 8 | main.cpp: In function 'void one_measurement(int, int, char*)': |
| 9 | main.cpp:226:3: error: 'pthread_t' was not declared in this scope |
| 10 | pthread_t thread = 0UL; |
| 11 | ^~~~~~~~~ |
| 12 | main.cpp:226:3: note: suggested alternative: 'pread' |
| 13 | pthread_t thread = 0UL; |
| 14 | ^~~~~~~~~ |
| 15 | pread |
| 16 | |
| 17 | et al. |
| 18 | |
| 19 | Signed-off-by: Rosen Penev <rosenp@gmail.com> |
| 20 | --- |
| 21 | src/main.cpp | 1 + |
| 22 | 1 file changed, 1 insertion(+) |
| 23 | |
| 24 | --- a/src/main.cpp |
| 25 | +++ b/src/main.cpp |
| 26 | @@ -39,6 +39,7 @@ |
| 27 | #include <locale.h> |
| 28 | #include <sys/resource.h> |
| 29 | #include <limits.h> |
| 30 | +#include <pthread.h> |
| 31 | |
| 32 | #include "cpu/cpu.h" |
| 33 | #include "process/process.h" |