From 94e3a6ff7fcb85e214cd84439ebf2e7c25df52bd Mon Sep 17 00:00:00 2001
From: Isuru Fernando <isuruf@gmail.com>
Date: Thu, 26 Nov 2020 18:47:37 +0000
Subject: [PATCH 1/3] Allow cross compiling for Darwin

---
 configure    | 6 ++++++
 configure.ac | 6 ++++++
 2 files changed, 12 insertions(+)

diff --git a/configure b/configure
index c9ea72cf6efa..917315d42db3 100755
--- a/configure
+++ b/configure
@@ -3869,6 +3869,9 @@ then
 	*-*-linux*)
 		ac_sys_system=Linux
 		;;
+	*-*-darwin*)
+		ac_sys_system=Darwin
+		;;
 	*-*-cygwin*)
 		ac_sys_system=Cygwin
 		;;
@@ -3925,6 +3928,9 @@ if test "$cross_compiling" = yes; then
 			_host_cpu=$host_cpu
 		esac
 		;;
+	*-*-darwin*)
+		_host_cpu=$host_cpu
+		;;
 	*-*-cygwin*)
 		_host_cpu=
 		;;
diff --git a/configure.ac b/configure.ac
index 10672bd3761d..c31bd6286ce0 100644
--- a/configure.ac
+++ b/configure.ac
@@ -541,6 +541,9 @@ then
 	*-*-linux*)
 		ac_sys_system=Linux
 		;;
+	*-*-darwin*)
+		ac_sys_system=Darwin
+		;;
 	*-*-cygwin*)
 		ac_sys_system=Cygwin
 		;;
@@ -596,6 +599,9 @@ if test "$cross_compiling" = yes; then
 			_host_cpu=$host_cpu
 		esac
 		;;
+	*-*-darwin*)
+		_host_cpu=$host_cpu
+		;;
 	*-*-cygwin*)
 		_host_cpu=
 		;;

