diff --git a/.files b/.files
index b18c263..f7bef83 100644
Binary files a/.files and b/.files differ
diff --git a/.rev b/.rev
index 8798cb6..e3ba41c 100644
--- a/.rev
+++ b/.rev
@@ -64,4 +64,12 @@
- Update to version 0.14.7
889328
+
+ 99cc7f154376e3d65d9cf92530a1e8a0
+ 0.14.7
+
+ dimstar_suse
+ - Backport patches to fix signed/unsigned char usage on Arm:
+ 988029
+
diff --git a/6895f7d1.patch b/6895f7d1.patch
new file mode 100644
index 0000000..a25beda
--- /dev/null
+++ b/6895f7d1.patch
@@ -0,0 +1,23 @@
+From 6895f7d153500a18f08fa9e64972799763c775e6 Mon Sep 17 00:00:00 2001
+From: Adrian Thurston
+Date: Sat, 6 Nov 2021 12:09:17 -0700
+Subject: [PATCH] C codegen: use SCHAR_MIN and SCHAR_MAX for signed char host
+ type
+
+---
+ src/libfsm/common.cc | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/src/libfsm/common.cc b/src/libfsm/common.cc
+index b46cc571..349d06f7 100644
+--- a/src/libfsm/common.cc
++++ b/src/libfsm/common.cc
+@@ -42,7 +42,7 @@ const char *defaultOutFnC( const char *inputFileName )
+ HostType hostTypesC[] =
+ {
+ { "char", 0, "char", (CHAR_MIN != 0), true, false, SCHAR_MIN, SCHAR_MAX, 0, UCHAR_MAX, sizeof(char) },
+- { "signed", "char", "char", true, true, false, CHAR_MIN, CHAR_MAX, 0, 0, sizeof(char) },
++ { "signed", "char", "char", true, true, false, SCHAR_MIN, SCHAR_MAX, 0, 0, sizeof(char) },
+ { "unsigned", "char", "uchar", false, true, false, 0, 0, 0, UCHAR_MAX, sizeof(unsigned char) },
+ { "short", 0, "short", true, true, false, SHRT_MIN, SHRT_MAX, 0, 0, sizeof(short) },
+ { "signed", "short", "short", true, true, false, SHRT_MIN, SHRT_MAX, 0, 0, sizeof(short) },
diff --git a/9f0ac141.patch b/9f0ac141.patch
new file mode 100644
index 0000000..aa08ab5
--- /dev/null
+++ b/9f0ac141.patch
@@ -0,0 +1,35 @@
+From 9f0ac141731d635fbdc963c16c198d5de920f31d Mon Sep 17 00:00:00 2001
+From: Adrian Thurston
+Date: Sat, 6 Nov 2021 12:09:56 -0700
+Subject: [PATCH] C codegen: use the 'signed' prefix when specifying the size
+ of the signed types
+
+---
+ src/libfsm/common.cc | 8 ++++----
+ 1 file changed, 4 insertions(+), 4 deletions(-)
+
+diff --git a/src/libfsm/common.cc b/src/libfsm/common.cc
+index 349d06f7..9a14a290 100644
+--- a/src/libfsm/common.cc
++++ b/src/libfsm/common.cc
+@@ -42,16 +42,16 @@ const char *defaultOutFnC( const char *inputFileName )
+ HostType hostTypesC[] =
+ {
+ { "char", 0, "char", (CHAR_MIN != 0), true, false, SCHAR_MIN, SCHAR_MAX, 0, UCHAR_MAX, sizeof(char) },
+- { "signed", "char", "char", true, true, false, SCHAR_MIN, SCHAR_MAX, 0, 0, sizeof(char) },
++ { "signed", "char", "char", true, true, false, SCHAR_MIN, SCHAR_MAX, 0, 0, sizeof(signed char) },
+ { "unsigned", "char", "uchar", false, true, false, 0, 0, 0, UCHAR_MAX, sizeof(unsigned char) },
+ { "short", 0, "short", true, true, false, SHRT_MIN, SHRT_MAX, 0, 0, sizeof(short) },
+- { "signed", "short", "short", true, true, false, SHRT_MIN, SHRT_MAX, 0, 0, sizeof(short) },
++ { "signed", "short", "short", true, true, false, SHRT_MIN, SHRT_MAX, 0, 0, sizeof(signed short) },
+ { "unsigned", "short", "ushort", false, true, false, 0, 0, 0, USHRT_MAX, sizeof(unsigned short) },
+ { "int", 0, "int", true, true, false, INT_MIN, INT_MAX, 0, 0, sizeof(int) },
+- { "signed", "int", "int", true, true, false, INT_MIN, INT_MAX, 0, 0, sizeof(int) },
++ { "signed", "int", "int", true, true, false, INT_MIN, INT_MAX, 0, 0, sizeof(signed int) },
+ { "unsigned", "int", "uint", false, true, false, 0, 0, 0, UINT_MAX, sizeof(unsigned int) },
+ { "long", 0, "long", true, true, false, LONG_MIN, LONG_MAX, 0, 0, sizeof(long) },
+- { "signed", "long", "long", true, true, false, LONG_MIN, LONG_MAX, 0, 0, sizeof(long) },
++ { "signed", "long", "long", true, true, false, LONG_MIN, LONG_MAX, 0, 0, sizeof(signed long) },
+ { "unsigned", "long", "ulong", false, true, false, 0, 0, 0, ULONG_MAX, sizeof(unsigned long) },
+ };
+
diff --git a/colm.changes b/colm.changes
index 8683403..8648f99 100644
--- a/colm.changes
+++ b/colm.changes
@@ -1,4 +1,12 @@
-------------------------------------------------------------------
+Fri Jul 8 12:50:08 UTC 2022 - Guillaume GARDET
+
+- Backport patches to fix signed/unsigned char usage on Arm:
+ * e1f1c598.patch
+ * 6895f7d1.patch
+ * 9f0ac141.patch
+
+-------------------------------------------------------------------
Mon Apr 26 19:32:48 UTC 2021 - Ferdinand Thiessen
- Update to version 0.14.7
diff --git a/colm.spec b/colm.spec
index 67b9de9..9f2ecf5 100644
--- a/colm.spec
+++ b/colm.spec
@@ -1,7 +1,7 @@
#
# spec file for package colm
#
-# Copyright (c) 2021 SUSE LLC
+# Copyright (c) 2022 SUSE LLC
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
@@ -28,6 +28,9 @@ URL: https://www.colm.net/open-source/colm/
Source: https://www.colm.net/files/colm/%name-%version.tar.gz
Patch1: fix-library.patch
Patch2: reproducible.diff
+Patch3: e1f1c598.patch
+Patch4: 6895f7d1.patch
+Patch5: 9f0ac141.patch
BuildRequires: asciidoc
BuildRequires: gcc-c++
BuildRequires: libtool
diff --git a/e1f1c598.patch b/e1f1c598.patch
new file mode 100644
index 0000000..76cbf1b
--- /dev/null
+++ b/e1f1c598.patch
@@ -0,0 +1,50 @@
+From e1f1c598d5bf66484e4dccccddd420a8ed1ebc84 Mon Sep 17 00:00:00 2001
+From: Adrian Thurston
+Date: Sat, 30 Oct 2021 09:05:06 -0700
+Subject: [PATCH] C codegen: decide char signedness based on value of CHAR_MIN
+
+Decide signedness of "char" on at runtime (probably compile time) using a check
+on CHAR_MIN. This should work with cross compiling setups.
+
+With this approach, if you plan to use "char" on ARM you cannot literally
+specify outside the range 0-127 using decimal/hex. If you need that you can use
+"signed char" or "unsigned char".
+---
+ src/libfsm/common.cc | 24 ++++++++++++------------
+ 1 file changed, 12 insertions(+), 12 deletions(-)
+
+diff --git a/src/libfsm/common.cc b/src/libfsm/common.cc
+index 9ebbd9052..b46cc5714 100644
+--- a/src/libfsm/common.cc
++++ b/src/libfsm/common.cc
+@@ -41,18 +41,18 @@ const char *defaultOutFnC( const char *inputFileName )
+
+ HostType hostTypesC[] =
+ {
+- { "char", 0, "char", true, true, false, CHAR_MIN, CHAR_MAX, 0, 0, sizeof(char) },
+- { "signed", "char", "char", true, true, false, CHAR_MIN, CHAR_MAX, 0, 0, sizeof(char) },
+- { "unsigned", "char", "uchar", false, true, false, 0, 0, 0, UCHAR_MAX, sizeof(unsigned char) },
+- { "short", 0, "short", true, true, false, SHRT_MIN, SHRT_MAX, 0, 0, sizeof(short) },
+- { "signed", "short", "short", true, true, false, SHRT_MIN, SHRT_MAX, 0, 0, sizeof(short) },
+- { "unsigned", "short", "ushort", false, true, false, 0, 0, 0, USHRT_MAX, sizeof(unsigned short) },
+- { "int", 0, "int", true, true, false, INT_MIN, INT_MAX, 0, 0, sizeof(int) },
+- { "signed", "int", "int", true, true, false, INT_MIN, INT_MAX, 0, 0, sizeof(int) },
+- { "unsigned", "int", "uint", false, true, false, 0, 0, 0, UINT_MAX, sizeof(unsigned int) },
+- { "long", 0, "long", true, true, false, LONG_MIN, LONG_MAX, 0, 0, sizeof(long) },
+- { "signed", "long", "long", true, true, false, LONG_MIN, LONG_MAX, 0, 0, sizeof(long) },
+- { "unsigned", "long", "ulong", false, true, false, 0, 0, 0, ULONG_MAX, sizeof(unsigned long) },
++ { "char", 0, "char", (CHAR_MIN != 0), true, false, SCHAR_MIN, SCHAR_MAX, 0, UCHAR_MAX, sizeof(char) },
++ { "signed", "char", "char", true, true, false, CHAR_MIN, CHAR_MAX, 0, 0, sizeof(char) },
++ { "unsigned", "char", "uchar", false, true, false, 0, 0, 0, UCHAR_MAX, sizeof(unsigned char) },
++ { "short", 0, "short", true, true, false, SHRT_MIN, SHRT_MAX, 0, 0, sizeof(short) },
++ { "signed", "short", "short", true, true, false, SHRT_MIN, SHRT_MAX, 0, 0, sizeof(short) },
++ { "unsigned", "short", "ushort", false, true, false, 0, 0, 0, USHRT_MAX, sizeof(unsigned short) },
++ { "int", 0, "int", true, true, false, INT_MIN, INT_MAX, 0, 0, sizeof(int) },
++ { "signed", "int", "int", true, true, false, INT_MIN, INT_MAX, 0, 0, sizeof(int) },
++ { "unsigned", "int", "uint", false, true, false, 0, 0, 0, UINT_MAX, sizeof(unsigned int) },
++ { "long", 0, "long", true, true, false, LONG_MIN, LONG_MAX, 0, 0, sizeof(long) },
++ { "signed", "long", "long", true, true, false, LONG_MIN, LONG_MAX, 0, 0, sizeof(long) },
++ { "unsigned", "long", "ulong", false, true, false, 0, 0, 0, ULONG_MAX, sizeof(unsigned long) },
+ };
+
+ const HostLang hostLangC = {