From 46da65fe9f74e15aac46ab10fc1092367f2ff58e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=BCrgen=20Buchm=C3=BCller?= Date: Mon, 15 Apr 2019 12:43:34 +0200 Subject: [PATCH] libgpg-error: fix build with gawk-5.0.0 --- srcpkgs/libgpg-error/patches/001-awk.patch | 91 ++++++++++++++++++++++ srcpkgs/libgpg-error/template | 2 +- 2 files changed, 92 insertions(+), 1 deletion(-) create mode 100644 srcpkgs/libgpg-error/patches/001-awk.patch diff --git a/srcpkgs/libgpg-error/patches/001-awk.patch b/srcpkgs/libgpg-error/patches/001-awk.patch new file mode 100644 index 00000000000..e361e96a663 --- /dev/null +++ b/srcpkgs/libgpg-error/patches/001-awk.patch @@ -0,0 +1,91 @@ +--- src/mkerrcodes.awk 2013-03-15 20:24:25.000000000 +0100 ++++ src/mkerrcodes.awk 2019-04-15 12:27:18.223378102 +0200 +@@ -85,7 +85,7 @@ + } + + !header { +- sub (/\#.+/, ""); ++ sub (/#.+/, ""); + sub (/[ ]+$/, ""); # Strip trailing space and tab characters. + + if (/^$/) +--- src/mkerrcodes1.awk 2013-03-15 20:24:25.000000000 +0100 ++++ src/mkerrcodes1.awk 2019-04-15 12:30:40.960388561 +0200 +@@ -81,7 +81,7 @@ + } + + !header { +- sub (/\#.+/, ""); ++ sub (/#.+/, ""); + sub (/[ ]+$/, ""); # Strip trailing space and tab characters. + + if (/^$/) +--- src/mkerrnos.awk 2013-03-15 20:24:25.000000000 +0100 ++++ src/mkerrnos.awk 2019-04-15 12:32:10.966393204 +0200 +@@ -83,7 +83,7 @@ + } + + !header { +- sub (/\#.+/, ""); ++ sub (/#.+/, ""); + sub (/[ ]+$/, ""); # Strip trailing space and tab characters. + + if (/^$/) +--- src/mkstrtable.awk 2013-03-15 20:24:25.000000000 +0100 ++++ src/mkstrtable.awk 2019-04-15 12:39:46.679416714 +0200 +@@ -77,7 +77,7 @@ + # + # The variable prefix can be used to prepend a string to each message. + # +-# The variable namespace can be used to prepend a string to each ++# The variable my_namespace can be used to prepend a string to each + # variable and macro name. + + BEGIN { +@@ -102,7 +102,7 @@ + print "/* The purpose of this complex string table is to produce"; + print " optimal code with a minimum of relocations. */"; + print ""; +- print "static const char " namespace "msgstr[] = "; ++ print "static const char " my_namespace "msgstr[] = "; + header = 0; + } + else +@@ -110,7 +110,7 @@ + } + + !header { +- sub (/\#.+/, ""); ++ sub (/#.+/, ""); + sub (/[ ]+$/, ""); # Strip trailing space and tab characters. + + if (/^$/) +@@ -150,7 +150,7 @@ + else + print " gettext_noop (\"" last_msgstr "\");"; + print ""; +- print "static const int " namespace "msgidx[] ="; ++ print "static const int " my_namespace "msgidx[] ="; + print " {"; + for (i = 0; i < coded_msgs; i++) + print " " pos[i] ","; +@@ -158,7 +158,7 @@ + print " };"; + print ""; + print "static GPG_ERR_INLINE int"; +- print namespace "msgidxof (int code)"; ++ print my_namespace "msgidxof (int code)"; + print "{"; + print " return (0 ? 0"; + +--- src/Makefile.in 2019-03-19 09:58:04.000000000 +0100 ++++ src/Makefile.in 2019-04-15 12:41:31.470422120 +0200 +@@ -1615,7 +1615,7 @@ + + errnos-sym.h: Makefile mkstrtable.awk errnos.in + $(AWK) -f $(srcdir)/mkstrtable.awk -v textidx=2 -v nogettext=1 \ +- -v prefix=GPG_ERR_ -v namespace=errnos_ \ ++ -v prefix=GPG_ERR_ -v my_namespace=errnos_ \ + $(srcdir)/errnos.in >$@ + + mkheader$(EXEEXT_FOR_BUILD): mkheader.c Makefile diff --git a/srcpkgs/libgpg-error/template b/srcpkgs/libgpg-error/template index 5b69d5ed355..800b6bc7898 100644 --- a/srcpkgs/libgpg-error/template +++ b/srcpkgs/libgpg-error/template @@ -1,7 +1,7 @@ # Template file for 'libgpg-error' pkgname=libgpg-error version=1.36 -revision=1 +revision=2 build_style=gnu-configure short_desc="Library for error values used by GnuPG component" maintainer="Juan RP "