From 5809286a73e0560f73fd3e6bb692610f940adb97 Mon Sep 17 00:00:00 2001 From: sthen Date: Mon, 28 Nov 2022 20:52:35 +0000 Subject: [PATCH] update to recode-3.7.12 --- converters/recode/Makefile | 27 +++++------- converters/recode/distinfo | 4 +- converters/recode/patches/patch-configure | 19 -------- .../recode/patches/patch-libiconv_aliases_h | 11 ----- .../recode/patches/patch-src_Makefile_in | 20 --------- .../recode/patches/patch-src_libiconv_c | 22 ---------- .../recode/patches/patch-src_recodext_h | 11 ----- .../recode/patches/patch-tests_bigauto_py | 43 ------------------- converters/recode/pkg/DESCR | 13 +++--- converters/recode/pkg/PLIST | 22 +++++++++- 10 files changed, 41 insertions(+), 151 deletions(-) delete mode 100644 converters/recode/patches/patch-configure delete mode 100644 converters/recode/patches/patch-libiconv_aliases_h delete mode 100644 converters/recode/patches/patch-src_Makefile_in delete mode 100644 converters/recode/patches/patch-src_libiconv_c delete mode 100644 converters/recode/patches/patch-src_recodext_h delete mode 100644 converters/recode/patches/patch-tests_bigauto_py diff --git a/converters/recode/Makefile b/converters/recode/Makefile index 70171d85e0b..72c90d33413 100644 --- a/converters/recode/Makefile +++ b/converters/recode/Makefile @@ -1,37 +1,32 @@ COMMENT= convert files between character sets and usages -DISTNAME= recode-3.6 -REVISION = 12 -SHARED_LIBS += recode 0.0 # .0.0 +V= 3.7.12 +DISTNAME= recode-$V +SHARED_LIBS += recode 1.0 # 10.12 CATEGORIES= converters textproc -HOMEPAGE= http://recode.progiciels-bpi.ca - -MODULES= lang/python -MODPY_VERSION = ${MODPY_DEFAULT_VERSION_2} +HOMEPAGE= https://github.com/rrthomas/recode # (L)GPLv2 PERMIT_PACKAGE= Yes -WANTLIB= c iconv intl +WANTLIB= c iconv intl -# moved to https://github.com/pinard/Recode/ -MASTER_SITES= ${MASTER_SITE_GNU:=recode/} +MASTER_SITES= https://github.com/rrthomas/recode/releases/download/v$V/ +MODULES= lang/python MODPY_RUNDEP= No LIB_DEPENDS= devel/gettext,-runtime +TEST_DEPENDS= lang/cython${MODPY_FLAVOR} CONFIGURE_STYLE= gnu CONFIGURE_ARGS= --without-included-gettext CONFIGURE_ENV= CPPFLAGS="-I${LOCALBASE}/include" \ + LDFLAGS="-L${LOCALBASE}/lib" \ + CYTHON=cython +TEST_ENV= CPPFLAGS="-I${LOCALBASE}/include" \ LDFLAGS="-L${LOCALBASE}/lib" -post-extract: - @cd ${WRKSRC}/lib && cp -p error.c ../src - -post-test: - @cd ${WRKBUILD}/tests && ${MAKE_PROGRAM} PYTHON=${MODPY_BIN} bigtest - .include diff --git a/converters/recode/distinfo b/converters/recode/distinfo index 095417a51a8..9249e55d497 100644 --- a/converters/recode/distinfo +++ b/converters/recode/distinfo @@ -1,2 +1,2 @@ -SHA256 (recode-3.6.tar.gz) = 4+ak8/jlxgUqtwFVmQwHTYeqC2FPwb4x0ZR1DR2WL88= -SIZE (recode-3.6.tar.gz) = 1751886 +SHA256 (recode-3.7.12.tar.gz) = TbHJB28E26oVlyb1AAhH5eWoOuyOXGT4ygQ4P2zaEtU= +SIZE (recode-3.7.12.tar.gz) = 2399126 diff --git a/converters/recode/patches/patch-configure b/converters/recode/patches/patch-configure deleted file mode 100644 index 8a80dcbbc94..00000000000 --- a/converters/recode/patches/patch-configure +++ /dev/null @@ -1,19 +0,0 @@ ---- configure.orig Wed Jan 3 17:40:32 2001 -+++ configure Sat Apr 25 19:18:55 2009 -@@ -3399,7 +3399,7 @@ if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set - echo $ac_n "(cached) $ac_c" 1>&6 - else - ac_save_LIBS="$LIBS" --LIBS="-lintl $LIBS" -+LIBS="-lintl -liconv $LIBS" - cat > conftest.$ac_ext <&5 - if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then - echo $ac_n "(cached) $ac_c" 1>&6 - else -+ LIBS="-lintl -liconv $LIBS" - cat > conftest.$ac_ext < input_buffer || input_char != EOF)" loop, -the "cursor" pointer sometimes refers to "input_buffer" and sometimes -to "output_buffer". It must refer to "input_buffer" at the start of -the loop, but the present code forgets to ensure this. - -Examples that trigger the problem: -$ perl -e 'print "\xc3\xa4"x1025' | recode utf8..latin1 | wc -c -$ perl -e 'print "\xc3\xa4"x2000' | recode utf8..latin1 | wc -c - ---- src/libiconv.c.orig Sat Jul 1 19:13:25 2000 -+++ src/libiconv.c Sat Sep 27 23:47:54 2014 -@@ -195,9 +195,9 @@ wrapped_transform (iconv_t conversion, iconv_t convers - memcpy() doesn't do here, because the regions might overlap. - memmove() isn't worth it, because we rarely have to move more - than 12 bytes. */ -+ cursor = input_buffer; - if (input > input_buffer && input_left > 0) - { -- cursor = input_buffer; - do - *cursor++ = *input++; - while (--input_left > 0); diff --git a/converters/recode/patches/patch-src_recodext_h b/converters/recode/patches/patch-src_recodext_h deleted file mode 100644 index e0f6759e30d..00000000000 --- a/converters/recode/patches/patch-src_recodext_h +++ /dev/null @@ -1,11 +0,0 @@ ---- src/recodext.h.orig Sat Apr 15 20:09:37 2017 -+++ src/recodext.h Sat Apr 15 20:10:14 2017 -@@ -218,7 +218,7 @@ struct recode_symbol - enum recode_symbol_type type : 3; - - /* Non zero if this one should be ignored. */ -- bool ignore : 2; -+ bool ignore : 1; - }; - - struct recode_surface_list diff --git a/converters/recode/patches/patch-tests_bigauto_py b/converters/recode/patches/patch-tests_bigauto_py deleted file mode 100644 index dab543f7e54..00000000000 --- a/converters/recode/patches/patch-tests_bigauto_py +++ /dev/null @@ -1,43 +0,0 @@ ---- tests/bigauto.py.orig Thu Apr 27 01:16:04 2000 -+++ tests/bigauto.py Sat Sep 27 22:57:00 2014 -@@ -1,6 +1,6 @@ - #!/usr/bin/env python --# Copyright © 1997, 1999, 2000 Progiciels Bourbeau-Pinard inc. --# François Pinard , 1997. -+# Copyright (c) 1997, 1999, 2000 Progiciels Bourbeau-Pinard inc. -+# Francois Pinard , 1997. - - """\ - Produce statistics from the results of the bigauto check. -@@ -48,7 +48,7 @@ def create_data(name, recode_options, charset_options) - charsets = [] - for line in os.popen('recode -l').readlines(): - charset = string.split(line)[0] -- if charset[0] in ':/': -+ if charset[0] in ':/' or charset == 'data' or charset == 'tree': - continue - charsets.append(charset) - # Do the work, calling a subshell once per `before' value. -@@ -81,16 +81,20 @@ class Report: - lensep = len(os.linesep) - line = readline() - while line: -- type, request = string.split(line[:-lensep], ':', 1) -+ split = string.split(line[:-lensep], ':', 1) -+ type = split[0] - if type == 'Request': -+ request = split[1] - steps = self.get_steps(request) - self.count_original_request(steps, request) - line = readline() - if line: - if len(string.split(line[:-lensep], ':', 1)) != 2: - print '*', line, -- type, shrunk_to = string.split(line[:-lensep], ':', 1) -+ split = string.split(line[:-lensep], ':', 1) -+ type = split[0] - if type == 'Shrunk to': -+ shrunk_to = split[1] - steps = self.get_steps(shrunk_to) - self.count_shrunk_request(steps, shrunk_to) - line = readline() diff --git a/converters/recode/pkg/DESCR b/converters/recode/pkg/DESCR index 96598c30c9c..401f9210a42 100644 --- a/converters/recode/pkg/DESCR +++ b/converters/recode/pkg/DESCR @@ -1,6 +1,7 @@ -GNU `recode' converts files between character sets and usages. When -exact transliterations are not possible, it may get rid of the -offending characters or fall back on approximations. This program -recognizes or produces nearly 150 different character sets and is able -to transliterate files between almost any pair. Most RFC 1345 -character sets are supported. +The Recode library converts files between character sets and usages. +It recognises or produces over 200 different character sets (or about +300 if combined with an iconv library) and transliterates files between +almost any pair. When exact transliterations are not possible, it gets +rid of offending characters or falls back on approximations. + +The recode(1) program is a handy front-end to the library. diff --git a/converters/recode/pkg/PLIST b/converters/recode/pkg/PLIST index ffaf869bb50..3e03979e33f 100644 --- a/converters/recode/pkg/PLIST +++ b/converters/recode/pkg/PLIST @@ -3,19 +3,39 @@ include/recode.h include/recodext.h @info info/recode.info @comment lib/charset.alias -lib/librecode.a +@static-lib lib/librecode.a lib/librecode.la @lib lib/librecode.so.${LIBrecode_VERSION} @man man/man1/recode.1 +share/locale/be/LC_MESSAGES/recode.mo +share/locale/ca/LC_MESSAGES/recode.mo +share/locale/cs/LC_MESSAGES/recode.mo share/locale/da/LC_MESSAGES/recode.mo share/locale/de/LC_MESSAGES/recode.mo share/locale/el/LC_MESSAGES/recode.mo +share/locale/eo/LC_MESSAGES/recode.mo share/locale/es/LC_MESSAGES/recode.mo +share/locale/fi/LC_MESSAGES/recode.mo share/locale/fr/LC_MESSAGES/recode.mo +share/locale/ga/LC_MESSAGES/recode.mo share/locale/gl/LC_MESSAGES/recode.mo +share/locale/he/LC_MESSAGES/recode.mo +share/locale/hr/LC_MESSAGES/recode.mo +share/locale/hu/LC_MESSAGES/recode.mo +share/locale/id/LC_MESSAGES/recode.mo share/locale/it/LC_MESSAGES/recode.mo +share/locale/nb/LC_MESSAGES/recode.mo share/locale/nl/LC_MESSAGES/recode.mo share/locale/pl/LC_MESSAGES/recode.mo share/locale/pt/LC_MESSAGES/recode.mo +share/locale/pt_BR/LC_MESSAGES/recode.mo +share/locale/ro/LC_MESSAGES/recode.mo +share/locale/ru/LC_MESSAGES/recode.mo +share/locale/sk/LC_MESSAGES/recode.mo share/locale/sl/LC_MESSAGES/recode.mo +share/locale/sr/LC_MESSAGES/recode.mo share/locale/sv/LC_MESSAGES/recode.mo +share/locale/tr/LC_MESSAGES/recode.mo +share/locale/uk/LC_MESSAGES/recode.mo +share/locale/vi/LC_MESSAGES/recode.mo +share/locale/zh_CN/LC_MESSAGES/recode.mo