summaryrefslogtreecommitdiffstats
path: root/testing/raspberrypi/fix-musl.patch
diff options
context:
space:
mode:
Diffstat (limited to 'testing/raspberrypi/fix-musl.patch')
-rw-r--r--testing/raspberrypi/fix-musl.patch49
1 files changed, 49 insertions, 0 deletions
diff --git a/testing/raspberrypi/fix-musl.patch b/testing/raspberrypi/fix-musl.patch
new file mode 100644
index 000000000..2460d3044
--- /dev/null
+++ b/testing/raspberrypi/fix-musl.patch
@@ -0,0 +1,49 @@
+diff --git a/interface/vcos/pthreads/vcos_platform.h b/interface/vcos/pthreads/vcos_platform.h
+index 465abd2..9356479 100755
+--- a/interface/vcos/pthreads/vcos_platform.h
++++ b/interface/vcos/pthreads/vcos_platform.h
+@@ -120,9 +120,6 @@ typedef struct
+
+ #define VCOS_ONCE_INIT PTHREAD_ONCE_INIT
+
+-#if defined(__arm__) && !defined(_HAVE_TIMER_T) && !defined(ANDROID)
+-typedef __timer_t timer_t;
+-#endif
+ typedef struct VCOS_TIMER_T
+ {
+ pthread_t thread; /**< id of the timer thread */
+diff --git a/interface/vcos/pthreads/vcos_pthreads.c b/interface/vcos/pthreads/vcos_pthreads.c
+index 6ecc7da..9296ebe 100644
+--- a/interface/vcos/pthreads/vcos_pthreads.c
++++ b/interface/vcos/pthreads/vcos_pthreads.c
+@@ -580,7 +580,7 @@ const char ** vcos_get_argv(void)
+ */
+ uint32_t _vcos_get_ticks_per_second(void)
+ {
+- return HZ;
++ return 100;
+ }
+
+ VCOS_STATUS_T vcos_once(VCOS_ONCE_T *once_control,
+diff --git a/interface/vmcs_host/linux/vcfilesys.c b/interface/vmcs_host/linux/vcfilesys.c
+index ab65e3e..53c7486 100644
+--- a/interface/vmcs_host/linux/vcfilesys.c
++++ b/interface/vmcs_host/linux/vcfilesys.c
+@@ -49,7 +49,7 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ #include <ctype.h>
+ #include <limits.h>
+
+-#if !defined(ANDROID) && !defined( __USE_FILE_OFFSET64 )
++#if defined(__GLIBC__) && !defined( __USE_FILE_OFFSET64 )
+ #error "__USE_FILE_OFFSET64 isn't defined"
+ #endif
+
+@@ -916,7 +916,7 @@ int vc_hostfs_set_attr(const char *path, fattributes_t attr)
+
+ if (pathbuf)
+ {
+- __mode_t mode = 0;
++ mode_t mode = 0;
+ struct stat sb;
+
+ backslash_to_slash(pathbuf);