diff options
author | B. Watson <yalhcru@gmail.com> | 2021-08-22 15:42:34 -0400 |
---|---|---|
committer | Willy Sudiarto Raharjo <willysr@slackbuilds.org> | 2021-10-13 00:51:34 +0700 |
commit | f51dbcd5c14e580516fc4c0663da91c154b139aa (patch) | |
tree | b125066e4ec58882fb5086e8efc0fb85597344cc /perl/perl-text-unaccent | |
parent | 78298c73d1dfbf945211861154bebe840136dc4b (diff) | |
download | slackbuilds-f51dbcd5c14e580516fc4c0663da91c154b139aa.tar.gz |
perl/perl-text-unaccent: Fix build on -current.
Signed-off-by: B. Watson <yalhcru@gmail.com>
Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org>
Diffstat (limited to 'perl/perl-text-unaccent')
-rw-r--r-- | perl/perl-text-unaccent/README | 12 | ||||
-rw-r--r-- | perl/perl-text-unaccent/ligatures.diff | 105 | ||||
-rw-r--r-- | perl/perl-text-unaccent/oe_lig_and_size_t.diff | 46 | ||||
-rw-r--r-- | perl/perl-text-unaccent/perl-text-unaccent.SlackBuild | 27 | ||||
-rw-r--r-- | perl/perl-text-unaccent/podfix.diff | 12 | ||||
-rw-r--r-- | perl/perl-text-unaccent/slack-desc | 8 |
6 files changed, 146 insertions, 64 deletions
diff --git a/perl/perl-text-unaccent/README b/perl/perl-text-unaccent/README index 1167d43ea0..c4e2edd1a0 100644 --- a/perl/perl-text-unaccent/README +++ b/perl/perl-text-unaccent/README @@ -1,6 +1,10 @@ perl-text-unaccent (perl module to remove accents from a string) -Text::Unaccent is a module that remove accents from a string. unac_string -converts the input string from the specified charset to UTF-16 and call -unac_string_utf16 to return the unaccented equivalent. The conversion -from and to UTF-16 is done with iconv(1). +Text::Unaccent is a module that remove accents from a string. + +unac_string converts the input string from the specified charset +to UTF-16 and calls unac_string_utf16 to return the unaccented +equivalent. The conversion from and to UTF-16 is done with iconv(1). + +See also: system/unac, for a library and command-line tool that does +the same thing. diff --git a/perl/perl-text-unaccent/ligatures.diff b/perl/perl-text-unaccent/ligatures.diff new file mode 100644 index 0000000000..be5e834e20 --- /dev/null +++ b/perl/perl-text-unaccent/ligatures.diff @@ -0,0 +1,105 @@ +diff -Naur Text-Unaccent-1.08/unac.c Text-Unaccent-1.08.patched/unac.c +--- Text-Unaccent-1.08/unac.c 2004-10-17 15:00:36.000000000 -0400 ++++ Text-Unaccent-1.08.patched/unac.c 2021-08-22 15:27:29.207153493 -0400 +@@ -21,14 +21,6 @@ + #endif /* HAVE_CONFIG_H */ + + /* +- * Perl config.h defines HAS_VPRINTF if printf variants are +- * available +- */ +-#ifdef HAS_VPRINTF +-#define HAVE_VSNPRINTF +-#endif /* HAS_VPRINTF */ +- +-/* + * If configure.in has not defined this symbol, assume const. It + * does not harm much: a warning will be issued during compilation. + */ +@@ -140,6 +132,9 @@ + * 0055 LATIN CAPITAL LETTER U + * 00DD LATIN CAPITAL LETTER Y WITH ACUTE + * 0059 LATIN CAPITAL LETTER Y ++ * 00DF LATIN SMALL LETTER SHARP S ++ * 0073 LATIN SMALL LETTER S ++ * 0073 LATIN SMALL LETTER S + * 00E0 LATIN SMALL LETTER A WITH GRAVE + * 0061 LATIN SMALL LETTER A + * 00E1 LATIN SMALL LETTER A WITH ACUTE +@@ -360,6 +355,12 @@ + * 004F LATIN CAPITAL LETTER O + * 0151 LATIN SMALL LETTER O WITH DOUBLE ACUTE + * 006F LATIN SMALL LETTER O ++ * 0152 LATIN CAPITAL LIGATURE OE ++ * 004F LATIN CAPITAL LETTER O ++ * 0045 LATIN CAPITAL LETTER E ++ * 0153 LATIN SMALL LIGATURE OE ++ * 006F LATIN SMALL LETTER O ++ * 0065 LATIN SMALL LETTER E + * 0154 LATIN CAPITAL LETTER R WITH ACUTE + * 0052 LATIN CAPITAL LETTER R + * 0155 LATIN SMALL LETTER R WITH ACUTE +@@ -472,6 +473,9 @@ + * 0066 LATIN SMALL LETTER F + * 0193 LATIN CAPITAL LETTER G WITH HOOK + * 0047 LATIN CAPITAL LETTER G ++ * 0195 LATIN SMALL LETTER HV ++ * 0068 LATIN SMALL LETTER H ++ * 0076 LATIN SMALL LETTER V + * 0197 LATIN CAPITAL LETTER I WITH STROKE + * 0049 LATIN CAPITAL LETTER I + * 0198 LATIN CAPITAL LETTER K WITH HOOK +@@ -12929,13 +12933,13 @@ + unsigned char unac_positions[UNAC_BLOCK_COUNT][UNAC_BLOCK_SIZE + 1] = { + /* 0 */ { 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32 }, + /* 1 */ { 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 31, 34, 37, 38 }, +-/* 2 */ { 0, 1, 2, 3, 4, 5, 6, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33 }, ++/* 2 */ { 0, 1, 2, 3, 4, 5, 6, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 34 }, + /* 3 */ { 0, 1, 2, 3, 4, 5, 6, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33 }, + /* 4 */ { 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32 }, + /* 5 */ { 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 20, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 35 }, +-/* 6 */ { 0, 2, 3, 4, 5, 6, 7, 8, 9, 10, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34 }, ++/* 6 */ { 0, 2, 3, 4, 5, 6, 7, 8, 9, 10, 12, 13, 14, 15, 16, 17, 18, 19, 20, 22, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36 }, + /* 7 */ { 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32 }, +-/* 8 */ { 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32 }, ++/* 8 */ { 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33 }, + /* 9 */ { 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32 }, + /* 10 */ { 0, 1, 2, 3, 4, 6, 8, 10, 12, 14, 16, 18, 20, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41 }, + /* 11 */ { 0, 1, 2, 4, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 21, 23, 25, 26, 27, 28, 29, 30, 31, 32, 33, 35, 37, 38, 39 }, +@@ -13145,13 +13149,13 @@ + + unsigned short unac_data0[] = { 0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF }; + unsigned short unac_data1[] = { 0x0020, 0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF, 0x0020, 0xFFFF, 0x0061, 0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF, 0x0020, 0xFFFF, 0xFFFF, 0x0032, 0x0033, 0x0020, 0x03BC, 0xFFFF, 0xFFFF, 0x0020, 0x0031, 0x006F, 0xFFFF, 0x0031, 0x2044, 0x0034, 0x0031, 0x2044, 0x0032, 0x0033, 0x2044, 0x0034, 0xFFFF }; +-unsigned short unac_data2[] = { 0x0041, 0x0041, 0x0041, 0x0041, 0x0041, 0x0041, 0x0041, 0x0045, 0x0043, 0x0045, 0x0045, 0x0045, 0x0045, 0x0049, 0x0049, 0x0049, 0x0049, 0xFFFF, 0x004E, 0x004F, 0x004F, 0x004F, 0x004F, 0x004F, 0xFFFF, 0x004F, 0x0055, 0x0055, 0x0055, 0x0055, 0x0059, 0xFFFF, 0xFFFF }; ++unsigned short unac_data2[] = { 0x0041, 0x0041, 0x0041, 0x0041, 0x0041, 0x0041, 0x0041, 0x0045, 0x0043, 0x0045, 0x0045, 0x0045, 0x0045, 0x0049, 0x0049, 0x0049, 0x0049, 0xFFFF, 0x004E, 0x004F, 0x004F, 0x004F, 0x004F, 0x004F, 0xFFFF, 0x004F, 0x0055, 0x0055, 0x0055, 0x0055, 0x0059, 0xFFFF, 0x0073, 0x0073 }; + unsigned short unac_data3[] = { 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0065, 0x0063, 0x0065, 0x0065, 0x0065, 0x0065, 0x0069, 0x0069, 0x0069, 0x0069, 0xFFFF, 0x006E, 0x006F, 0x006F, 0x006F, 0x006F, 0x006F, 0xFFFF, 0x006F, 0x0075, 0x0075, 0x0075, 0x0075, 0x0079, 0xFFFF, 0x0079 }; + unsigned short unac_data4[] = { 0x0041, 0x0061, 0x0041, 0x0061, 0x0041, 0x0061, 0x0043, 0x0063, 0x0043, 0x0063, 0x0043, 0x0063, 0x0043, 0x0063, 0x0044, 0x0064, 0x0044, 0x0064, 0x0045, 0x0065, 0x0045, 0x0065, 0x0045, 0x0065, 0x0045, 0x0065, 0x0045, 0x0065, 0x0047, 0x0067, 0x0047, 0x0067 }; + unsigned short unac_data5[] = { 0x0047, 0x0067, 0x0047, 0x0067, 0x0048, 0x0068, 0x0048, 0x0068, 0x0049, 0x0069, 0x0049, 0x0069, 0x0049, 0x0069, 0x0049, 0x0069, 0x0049, 0xFFFF, 0x0049, 0x004A, 0x0069, 0x006A, 0x004A, 0x006A, 0x004B, 0x006B, 0xFFFF, 0x004C, 0x006C, 0x004C, 0x006C, 0x004C, 0x006C, 0x004C, 0x00B7 }; +-unsigned short unac_data6[] = { 0x006C, 0x00B7, 0x004C, 0x006C, 0x004E, 0x006E, 0x004E, 0x006E, 0x004E, 0x006E, 0x02BC, 0x006E, 0xFFFF, 0xFFFF, 0x004F, 0x006F, 0x004F, 0x006F, 0x004F, 0x006F, 0xFFFF, 0xFFFF, 0x0052, 0x0072, 0x0052, 0x0072, 0x0052, 0x0072, 0x0053, 0x0073, 0x0053, 0x0073, 0x0053, 0x0073 }; ++unsigned short unac_data6[] = { 0x006C, 0x00B7, 0x004C, 0x006C, 0x004E, 0x006E, 0x004E, 0x006E, 0x004E, 0x006E, 0x02BC, 0x006E, 0xFFFF, 0xFFFF, 0x004F, 0x006F, 0x004F, 0x006F, 0x004F, 0x006F, 0x004F, 0x0045, 0x006F, 0x0065, 0x0052, 0x0072, 0x0052, 0x0072, 0x0052, 0x0072, 0x0053, 0x0073, 0x0053, 0x0073, 0x0053, 0x0073 }; + unsigned short unac_data7[] = { 0x0053, 0x0073, 0x0054, 0x0074, 0x0054, 0x0074, 0x0054, 0x0074, 0x0055, 0x0075, 0x0055, 0x0075, 0x0055, 0x0075, 0x0055, 0x0075, 0x0055, 0x0075, 0x0055, 0x0075, 0x0057, 0x0077, 0x0059, 0x0079, 0x0059, 0x005A, 0x007A, 0x005A, 0x007A, 0x005A, 0x007A, 0x0073 }; +-unsigned short unac_data8[] = { 0x0062, 0x0042, 0x0042, 0x0062, 0xFFFF, 0xFFFF, 0xFFFF, 0x0043, 0x0063, 0xFFFF, 0x0044, 0x0044, 0x0064, 0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF, 0x0046, 0x0066, 0x0047, 0xFFFF, 0xFFFF, 0xFFFF, 0x0049, 0x004B, 0x006B, 0x006C, 0xFFFF, 0xFFFF, 0x004E, 0x006E, 0x004F }; ++unsigned short unac_data8[] = { 0x0062, 0x0042, 0x0042, 0x0062, 0xFFFF, 0xFFFF, 0xFFFF, 0x0043, 0x0063, 0xFFFF, 0x0044, 0x0044, 0x0064, 0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF, 0x0046, 0x0066, 0x0047, 0xFFFF, 0x0068, 0x0076, 0xFFFF, 0x0049, 0x004B, 0x006B, 0x006C, 0xFFFF, 0xFFFF, 0x004E, 0x006E, 0x004F }; + unsigned short unac_data9[] = { 0x004F, 0x006F, 0xFFFF, 0xFFFF, 0x0050, 0x0070, 0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF, 0x0074, 0x0054, 0x0074, 0x0054, 0x0055, 0x0075, 0xFFFF, 0x0056, 0x0059, 0x0079, 0x005A, 0x007A, 0xFFFF, 0xFFFF, 0xFFFF, 0x0292, 0xFFFF, 0xFFFF, 0xFFFF, 0x0296, 0xFFFF }; + unsigned short unac_data10[] = { 0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF, 0x0044, 0x005A, 0x0044, 0x007A, 0x0064, 0x007A, 0x004C, 0x004A, 0x004C, 0x006A, 0x006C, 0x006A, 0x004E, 0x004A, 0x004E, 0x006A, 0x006E, 0x006A, 0x0041, 0x0061, 0x0049, 0x0069, 0x004F, 0x006F, 0x0055, 0x0075, 0x0055, 0x0075, 0x0055, 0x0075, 0x0055, 0x0075, 0x0055, 0x0075, 0xFFFF, 0x0041, 0x0061 }; + unsigned short unac_data11[] = { 0x0041, 0x0061, 0x0041, 0x0045, 0x0061, 0x0065, 0x0047, 0x0067, 0x0047, 0x0067, 0x004B, 0x006B, 0x004F, 0x006F, 0x004F, 0x006F, 0x01B7, 0x0292, 0x006A, 0x0044, 0x005A, 0x0044, 0x007A, 0x0064, 0x007A, 0x0047, 0x0067, 0xFFFF, 0xFFFF, 0x004E, 0x006E, 0x0041, 0x0061, 0x0041, 0x0045, 0x0061, 0x0065, 0x004F, 0x006F }; +@@ -13881,9 +13885,9 @@ + *out_lengthp = 0; + } else { + char* utf16 = 0; +- int utf16_length = 0; ++ size_t utf16_length = 0; + char* utf16_unaccented = 0; +- int utf16_unaccented_length = 0; ++ size_t utf16_unaccented_length = 0; + + if(convert(charset, utf16be(), in, in_length, &utf16, &utf16_length) < 0) { + return -1; +@@ -13901,6 +13905,7 @@ + return 0; + } + ++ + #define UNAC_VERSION "1.8.0" + + const char* unac_version(void) diff --git a/perl/perl-text-unaccent/oe_lig_and_size_t.diff b/perl/perl-text-unaccent/oe_lig_and_size_t.diff deleted file mode 100644 index 2249cd5fe8..0000000000 --- a/perl/perl-text-unaccent/oe_lig_and_size_t.diff +++ /dev/null @@ -1,46 +0,0 @@ -diff -Naur Text-Unaccent-1.08/unac.c Text-Unaccent-1.08.patched/unac.c ---- Text-Unaccent-1.08/unac.c 2004-10-17 15:00:36.000000000 -0400 -+++ Text-Unaccent-1.08.patched/unac.c 2015-10-26 18:41:33.000000000 -0400 -@@ -360,6 +360,12 @@ - * 004F LATIN CAPITAL LETTER O - * 0151 LATIN SMALL LETTER O WITH DOUBLE ACUTE - * 006F LATIN SMALL LETTER O -+ * 0152 LATIN CAPITAL LIGATURE OE -+ * 004F LATIN CAPITAL LETTER O -+ * 0045 LATIN CAPITAL LETTER E -+ * 0153 LATIN SMALL LIGATURE OE -+ * 006F LATIN SMALL LETTER O -+ * 0065 LATIN SMALL LETTER E - * 0154 LATIN CAPITAL LETTER R WITH ACUTE - * 0052 LATIN CAPITAL LETTER R - * 0155 LATIN SMALL LETTER R WITH ACUTE -@@ -12933,7 +12939,7 @@ - /* 3 */ { 0, 1, 2, 3, 4, 5, 6, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33 }, - /* 4 */ { 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32 }, - /* 5 */ { 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 20, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 35 }, --/* 6 */ { 0, 2, 3, 4, 5, 6, 7, 8, 9, 10, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34 }, -+/* 6 */ { 0, 2, 3, 4, 5, 6, 7, 8, 9, 10, 12, 13, 14, 15, 16, 17, 18, 19, 20, 22, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36 }, - /* 7 */ { 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32 }, - /* 8 */ { 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32 }, - /* 9 */ { 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32 }, -@@ -13149,7 +13155,7 @@ - unsigned short unac_data3[] = { 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0061, 0x0065, 0x0063, 0x0065, 0x0065, 0x0065, 0x0065, 0x0069, 0x0069, 0x0069, 0x0069, 0xFFFF, 0x006E, 0x006F, 0x006F, 0x006F, 0x006F, 0x006F, 0xFFFF, 0x006F, 0x0075, 0x0075, 0x0075, 0x0075, 0x0079, 0xFFFF, 0x0079 }; - unsigned short unac_data4[] = { 0x0041, 0x0061, 0x0041, 0x0061, 0x0041, 0x0061, 0x0043, 0x0063, 0x0043, 0x0063, 0x0043, 0x0063, 0x0043, 0x0063, 0x0044, 0x0064, 0x0044, 0x0064, 0x0045, 0x0065, 0x0045, 0x0065, 0x0045, 0x0065, 0x0045, 0x0065, 0x0045, 0x0065, 0x0047, 0x0067, 0x0047, 0x0067 }; - unsigned short unac_data5[] = { 0x0047, 0x0067, 0x0047, 0x0067, 0x0048, 0x0068, 0x0048, 0x0068, 0x0049, 0x0069, 0x0049, 0x0069, 0x0049, 0x0069, 0x0049, 0x0069, 0x0049, 0xFFFF, 0x0049, 0x004A, 0x0069, 0x006A, 0x004A, 0x006A, 0x004B, 0x006B, 0xFFFF, 0x004C, 0x006C, 0x004C, 0x006C, 0x004C, 0x006C, 0x004C, 0x00B7 }; --unsigned short unac_data6[] = { 0x006C, 0x00B7, 0x004C, 0x006C, 0x004E, 0x006E, 0x004E, 0x006E, 0x004E, 0x006E, 0x02BC, 0x006E, 0xFFFF, 0xFFFF, 0x004F, 0x006F, 0x004F, 0x006F, 0x004F, 0x006F, 0xFFFF, 0xFFFF, 0x0052, 0x0072, 0x0052, 0x0072, 0x0052, 0x0072, 0x0053, 0x0073, 0x0053, 0x0073, 0x0053, 0x0073 }; -+unsigned short unac_data6[] = { 0x006C, 0x00B7, 0x004C, 0x006C, 0x004E, 0x006E, 0x004E, 0x006E, 0x004E, 0x006E, 0x02BC, 0x006E, 0xFFFF, 0xFFFF, 0x004F, 0x006F, 0x004F, 0x006F, 0x004F, 0x006F, 0x004F, 0x0045, 0x006F, 0x0065, 0x0052, 0x0072, 0x0052, 0x0072, 0x0052, 0x0072, 0x0053, 0x0073, 0x0053, 0x0073, 0x0053, 0x0073 }; - unsigned short unac_data7[] = { 0x0053, 0x0073, 0x0054, 0x0074, 0x0054, 0x0074, 0x0054, 0x0074, 0x0055, 0x0075, 0x0055, 0x0075, 0x0055, 0x0075, 0x0055, 0x0075, 0x0055, 0x0075, 0x0055, 0x0075, 0x0057, 0x0077, 0x0059, 0x0079, 0x0059, 0x005A, 0x007A, 0x005A, 0x007A, 0x005A, 0x007A, 0x0073 }; - unsigned short unac_data8[] = { 0x0062, 0x0042, 0x0042, 0x0062, 0xFFFF, 0xFFFF, 0xFFFF, 0x0043, 0x0063, 0xFFFF, 0x0044, 0x0044, 0x0064, 0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF, 0x0046, 0x0066, 0x0047, 0xFFFF, 0xFFFF, 0xFFFF, 0x0049, 0x004B, 0x006B, 0x006C, 0xFFFF, 0xFFFF, 0x004E, 0x006E, 0x004F }; - unsigned short unac_data9[] = { 0x004F, 0x006F, 0xFFFF, 0xFFFF, 0x0050, 0x0070, 0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF, 0x0074, 0x0054, 0x0074, 0x0054, 0x0055, 0x0075, 0xFFFF, 0x0056, 0x0059, 0x0079, 0x005A, 0x007A, 0xFFFF, 0xFFFF, 0xFFFF, 0x0292, 0xFFFF, 0xFFFF, 0xFFFF, 0x0296, 0xFFFF }; -@@ -13881,9 +13887,9 @@ - *out_lengthp = 0; - } else { - char* utf16 = 0; -- int utf16_length = 0; -+ size_t utf16_length = 0; - char* utf16_unaccented = 0; -- int utf16_unaccented_length = 0; -+ size_t utf16_unaccented_length = 0; - - if(convert(charset, utf16be(), in, in_length, &utf16, &utf16_length) < 0) { - return -1; diff --git a/perl/perl-text-unaccent/perl-text-unaccent.SlackBuild b/perl/perl-text-unaccent/perl-text-unaccent.SlackBuild index b88bf28ea4..f90e0c9627 100644 --- a/perl/perl-text-unaccent/perl-text-unaccent.SlackBuild +++ b/perl/perl-text-unaccent/perl-text-unaccent.SlackBuild @@ -6,6 +6,12 @@ # Licensed under the WTFPL. See http://www.wtfpl.net/txt/copying/ for details. +# 20210822 bkw: BUILD=2. +# - fix build on -current. +# - update unac.[ch] to match latest system/unac. +# - fix the perldoc/manpage. +# - typo-fix and reflow README and slack-desc. + cd $(dirname $0) ; CWD=$(pwd) PRGNAM=perl-text-unaccent @@ -22,9 +28,6 @@ if [ -z "$ARCH" ]; then esac fi -# If the variable PRINT_PACKAGE_NAME is set, then this script will report what -# the name of the created package would be, and then exit. This information -# could be useful to other scripts. if [ ! -z "${PRINT_PACKAGE_NAME}" ]; then echo "$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.$PKGTYPE" exit 0 @@ -59,14 +62,15 @@ rm -rf $TARNAME-$VERSION tar xvf $CWD/$TARNAME-$VERSION.tar.gz cd $TARNAME-$VERSION chown -R root:root . -find -L . \ - \( -perm 777 -o -perm 775 -o -perm 750 -o -perm 711 -o -perm 555 \ - -o -perm 511 \) -exec chmod 755 {} \; -o \ - \( -perm 666 -o -perm 664 -o -perm 640 -o -perm 600 -o -perm 444 \ - -o -perm 440 -o -perm 400 \) -exec chmod 644 {} \; +find -L . -perm /111 -a \! -perm 755 -a -exec chmod 755 {} \+ -o \ + \! -perm /111 -a \! -perm 644 -a -exec chmod 644 {} \+ # combined patch made by diffing against the unac.c in system/unac. -patch -p1 < $CWD/oe_lig_and_size_t.diff +# also UNAC_VERSION has to be defined. +patch -p1 < $CWD/ligatures.diff + +# fix minor issue with the docs. +patch -p1 < $CWD/podfix.diff # https://rt.cpan.org/Public/Bug/Display.html?id=124815 # patch for newer perls @@ -76,7 +80,10 @@ perl Makefile.PL \ PREFIX=/usr \ INSTALLDIRS=vendor \ INSTALLVENDORMAN3DIR=/usr/man/man3 -make + +# 20210822 bkw: we have vsnprintf(), but somehow it's not getting defined +# on -current, which breaks the build... so define it ourselves. +make OPTIMIZE="$SLKCFLAGS -DHAVE_VSNPRINTF" make test make install DESTDIR=$PKG diff --git a/perl/perl-text-unaccent/podfix.diff b/perl/perl-text-unaccent/podfix.diff new file mode 100644 index 0000000000..c2db83371b --- /dev/null +++ b/perl/perl-text-unaccent/podfix.diff @@ -0,0 +1,12 @@ +diff -Naur Text-Unaccent-1.08/Unaccent.pm Text-Unaccent-1.08.patched/Unaccent.pm +--- Text-Unaccent-1.08/Unaccent.pm 2004-12-29 06:44:28.000000000 -0500 ++++ Text-Unaccent-1.08.patched/Unaccent.pm 2021-08-22 15:31:50.237129764 -0400 +@@ -98,6 +98,8 @@ + + =back + ++=back ++ + =head1 AUTHOR + + Loic Dachary (loic@senga.org) diff --git a/perl/perl-text-unaccent/slack-desc b/perl/perl-text-unaccent/slack-desc index a508e866a9..0a15530b33 100644 --- a/perl/perl-text-unaccent/slack-desc +++ b/perl/perl-text-unaccent/slack-desc @@ -8,11 +8,11 @@ |-----handy-ruler------------------------------------------------------| perl-text-unaccent: perl-text-unaccent (perl module to remove accents from a string) perl-text-unaccent: -perl-text-unaccent: Text::Unaccent is a module that remove accents from a -perl-text-unaccent: string. unac_string converts the input string from the specified -perl-text-unaccent: charset to UTF-16 and call unac_string_utf16 to return the unaccented -perl-text-unaccent: equivalent. The conversion from and to UTF-16 is done with iconv(1). +perl-text-unaccent: Text::Unaccent is a module that remove accents from a string. perl-text-unaccent: +perl-text-unaccent: unac_string converts the input string from the specified charset +perl-text-unaccent: to UTF-16 and calls unac_string_utf16 to return the unaccented +perl-text-unaccent: equivalent. The conversion from and to UTF-16 is done with iconv(1). perl-text-unaccent: perl-text-unaccent: perl-text-unaccent: |