From 137ce23ae677b11e5483ef810751edae7bf96bb9 Mon Sep 17 00:00:00 2001
From: Khem Raj <raj.khem@gmail.com>
Date: Sat, 30 Nov 2019 18:40:06 -0800
Subject: [PATCH] Define error_t and include sys/types.h

Fix 'unknown type name' for error_t and u_int32_t.
u_int32_t is defined in sys/type.h

Signed-off-by: Khem Raj <raj.khem@gmail.com>
---
 utils/ir-ctl/keymap.h   | 4 ++++
 utils/keytable/keymap.h | 5 +++++
 2 files changed, 9 insertions(+)

diff --git a/utils/ir-ctl/keymap.h b/utils/ir-ctl/keymap.h
index f2b2963..1f8a3f8 100644
--- a/utils/ir-ctl/keymap.h
+++ b/utils/ir-ctl/keymap.h
@@ -2,6 +2,10 @@
 #ifndef __KEYMAP_H
 #define __KEYMAP_H
 
+#include <sys/types.h>
+#ifndef error_t
+typedef int error_t;
+#endif
 struct keymap {
 	struct keymap *next;
 	char *name;
diff --git a/utils/keytable/keymap.h b/utils/keytable/keymap.h
index f2b2963..345d55d 100644
--- a/utils/keytable/keymap.h
+++ b/utils/keytable/keymap.h
@@ -2,6 +2,11 @@
 #ifndef __KEYMAP_H
 #define __KEYMAP_H
 
+#include <sys/types.h>
+#ifndef error_t
+typedef int error_t;
+#endif
+
 struct keymap {
 	struct keymap *next;
 	char *name;
