2022-03-07 Hironobu Yamashita * fwrite.c: output to file instead of accumulating too much. https://github.com/texjporg/tex-jp-build/issues/137 2022-01-22 Hironori Kitagawa * fread.c: Adapt to arguments of input_line2() in ptexenc-1.4.0. 2022-01-18 Karl Berry * COPYRIGHT, * main.c: 2022. 2021-09-19 TANAKA Takuji * fread.c: Modify heuristic detection of page number types. * tests/mendex.test, tests/range.idx, tests/range[123].ind, tests/pprecB.idx, tests/pprec[34].ist, tests/pprecB-[034].ind: Update tests. * version.h: Date [19-Sep-2021] 2021-09-18 TANAKA Takuji * fread.c, fwrite.c, sort.c, mendex.h, {,ex}var.h: Extend levels of page numbers from 3 to 10 for compatibility with makeindex. Fix a bug of page ranges with multi-level page numbers. * fread.c: Strict check for "page_precedence" and "page_compositor" in style file. * fwrite.c: Do not break lines before "delim_n". * tests/mendex.test, tests/range.idx, tests/range[123].{ist,ind}, removed tests/rangetwo.*: Update tests. * version.h: Date [18-Sep-2021] 2021-09-04 TANAKA Takuji * configure.ac, version.h: Version 3.6 [4-Sep-2021]. * styfile.c, sort.c, fwrite.c, mendex.h, {,ex}var.h: Support output order of symbols and numbers separately when "symbol_flag" is 2 in style file. 2021-08-29 TANAKA Takuji * sort.c: Strict check for "character_order" in style file. * fwrite.c: Fix a bug when "symbol_flag" is 0. * version.h: Date [29-Aug-2021] 2021-08-28 TANAKA Takuji * styfile.c: Add a alias "headings_flag" of the keyword "heading_flag" in style file for compatibility with makeindex. Warn if specifier in style file is unknown. * version.h: Date [28-Aug-2021] 2021-06-13 Hironobu Yamashita * fwrite.c: Avoid segmentation fault for unwritable fopen. Recognize symhead_{positive,negative} for non-default character_order. * pageread.c, styfile.c: Exit code 255 for non-existent style/log file. * version.h: Date [13-Jun-2021], but still Version 3.5 (bugfix only). 2021-06-06 TANAKA Takuji * configure.ac, version.h: Version 3.5 [6-Jun-2021]. * main.c, styfile.c: Accept multiple numbers of style files by option '-s'. * tests/mendex.test, tests/uni[12].ist: Add a new test. * mendex.1{,ja}, mendex.ja.txt: Update documents. 2021-05-19 TANAKA Takuji * main.c, configure.ac, version.h: Version 3.4 [19-May-2021]. * styfile.c, var.h, exvar.h: Fix a bug of reading keywords "setpage_prefix", "setpage_suffix" in style file. More strictly check string length. 2021-05-09 Karl Berry * mendex.h (page.attr): use int, not char, since we do signed comparison and aarch64 apparently treats char as unsigned. (index.words): use unsigned char for consistency. * fwrite.c (printpage): factor out beginning/end page values. * tests/rangetwo.idx, * tests/rangetwo.ind, * tests/rangetwo.ist: new simple test. * tests/mendex.test: run the rangetwo test. Report from Johannes Hielscher, https://tug.org/pipermail/tlbuild/2021q1/004873.html. 2021-03-23 Karl Berry * TL'21. 2021-03-21 TANAKA Takuji * main.c, configure.ac, version.h: Version 3.3 [21-Mar-2021]. * fread.c: Fix a bug about page_precedence in style. Thanks to Suzana Sagadin for the report. * tests/pprec[012].ist, tests/pprecA.idx, tests/pprecA-[012].ind, tests/mendex.test, Makefile.am: Add new tests. 2020-01-16 Karl Berry * COPYRIGHT, * main.c: 2021. 2020-05-01 TANAKA Takuji * main.c, version.h, Makefile.{am.in}: Add bug report addresses on command line help. * main.c: Remove option "T" from command line help (w32 only). 2020-01-16 Karl Berry * configure.ac, * COPYRIGHT, * main.c (VERSION): version 3.2 16-Jan-2020 for TL'20. 2019-03-16 TANAKA Takuji * mendex.ja.txt: Rename from mendex.doc 2019-02-17 TANAKA Takuji * main.c, configure.ac, configure: Version 3.1 [17-Feb-2019]. * main.c, COPYRIGHT: Update copyright year. * fread.c: Fix typo. It seems a bug. * {convert,fread,fwrite,kp,main}.c: Avoid compiler warnings. Thanks to @ngothan for a report by covscan. https://github.com/TeX-Live/texlive-source/issues/11 2019-01-23 Hironobu Yamashita * mendex.1, mendex.1.ja: Add fallback TeX and LaTeX logos. 2018-07-22 TANAKA Takuji * README.md: Added. * mendex.1, mendex.1.ja: Sync with upstream. 2018-06-27 TANAKA Takuji * mendex.1, mendex.doc, mendex.1.ja, README_asciimw: Sync with upstream. 2018-06-14 Akira Kakuto * main.c: remove sjisterminal (w32 only). 2018-05-15 TANAKA Takuji * README, main.c, configure.ac, configure: Version 3.0 [15-May-2018]. * main.c, mendex.1, mendex.doc, mendex.1.ja: Set default encoding of internal buffer UTF-8. * indexsty, kana.h, ktable.h: Convert encoding from EUC-JP to UTF-8. * README_asciimw: Rename from README and convert encoding from EUC-JP to UTF-8. 2018-01-17 Karl Berry * mendex.1 (.TH): use 1 instead of L, per Debian (and all our other man pages). 2017-04-05 TANAKA Takuji * main.c: Avoid access violation. Thanks to I. Wada san. 2016-12-21 TANAKA Takuji * mendex.1, mendex.doc, mendex.1.ja: Sync with upstream. Now they are maintained at https://github.com/texjporg/mendex-doc * COPYRIGHT.ja, ChangeLog.ja: Rename from *.jis and convert encoding to UTF-8 * Makefile.am: Add those files to EXTRA_DIST. 2016-12-15 Akira Kakuto * main.c: Remove email address "ptex-staff@ml.asciimw.jp" as in upmendex. 2016-11-12 Akira Kakuto * mendex.h: Sync with W32TeX (W32 only). * main.c: Avoid access violation. 2016-09-28 Hironobu Yamashita * styfile.c: Use mfgets() instead of fgets() in bfgets(). 2016-02-02 TANAKA Takuji * mendex.1, mendex.doc: Convert encoding from EUC-JP to UTF-8 2016-01-31 TANAKA Takuji * mendex.1, mendex.doc: Remove unimplemented style option 'letter_head=0' from document. 2016-01-18 TANAKA Takuji * fwrite.c: Fix bug of -g option. 2015-08-23 TANAKA Takuji * main.c, fwrite.c: Accept long file name for a log file and a index file. 2015-08-08 TANAKA Takuji * main.c: Add '--help' option. 2015-07-07 Peter Breitenlohner * Makefile.am: Better dependencies for 'make check'. 2015-01-24 TANAKA Takuji * main.c, mendex.1, mendex.doc: Add '--' option. Update manuals. 2015-01-09 Peter Breitenlohner * fwrite.c: Some compilers mishandle the use of sizeof(buf) inside C99 variadic macros, so we replace it by BUFFERLEN. 2014-07-05 TANAKA Takuji * convert.c: Better timing for xstrdup. 2014-06-25 Peter Breitenlohner * main.c: Drop definition of TL_VERSION. * configure.ac: Use ../../version.ac to AC_DEFINE([TL_VERSION]). 2014-06-16 Peter Breitenlohner * Makefile.am: Drop the obsolete ACLOCAL_AMFLAGS. * configure.ac: Check for C99 variadic macros. * fwrite.c: Better handling of snprintf(). 2014-05-13 Peter Breitenlohner * fread.c (copy_multibyte_char): Avoid ambiguous operation. 2014-05-13 TANAKA Takuji * fread.c: Add copy_multibyte_char() to copy multibyte character correctly. * tests/uni.{idx,ind}: Update. 2014-05-12 Akira Kakuto * fread.c: Wide char is not always even bytes in getestr(). 2014-05-11 Peter Breitenlohner * convert.c: Add (unsigned char*) cast arg1 of UTF8StoUCS(). * fwrite.c: Declare fprint_euc_char() as static. 2014-05-11 TANAKA Takuji * main.c: Add TeX Live version. * {main,convert,fread,fwrite,styfile}.c, kana.h, mendex.doc, mendex.1: Add a new option -I to switch internal buffers for key words to EUC-JP or UTF-8. * tests/mendex.test: Add a new test. * tests/uni.{idx,dict,ist} (new): Test input. * tests/uni.ind (new): Expected output. * Makefile.am: Adapted. 2014-05-10 TANAKA Takuji * mendex.1: Fix usage. 2014-05-05 TANAKA Takuji * convert.c: Allow longer words in dictionary. * fwrite.c: Make a buffer size larger. 2014-05-02 Peter Breitenlohner * fwrite.c: OS X build fix. 2014-04-30 Norbert Preining * fwrite.c: Replace sprintf with snprintf. 2013-11-16 Akira Kakuto * fread.c: Allow lines with only a line ending in mfgets(), because dictionary files with DOS line endings can't be read. 2013-09-10 Peter Breitenlohner * fwrite.c: Bug fix as suggested by Akira, Karl, and Norbert. * tests/mendex.test (new): Shell script for a test case. * tests/foo.idx (new): Test input. * tests/foo.ind (new): Expected output. * Makefile.am: Adapted. 2013-06-28 Peter Breitenlohner * mendex.h: First include . 2012-11-19 Peter Breitenlohner * Makefile.am: Avoid use of deprecated INCLUDES. 2012-10-16 Peter Breitenlohner * convert.c: Move common #include's from here ... * fread.c: ... and here ... * fwrite.c: ... and here ... * main.c: ... and here ... * pageread.c: ... and here ... * sort.c: ... and here ... * styfile.c: ... and here ... * mendex.h: ... to here and add '#include '. * kp.c: Add '#include "mendex.h"' for common #include's. Avoid TL vs W32TeX diffs. * main.c: Use "PTEX_KANJI_ENC" and "guess_input_kanji_encoding". [WIN32}: Add command line option '-T' (from W32TeX). 2012-09-06 Peter Breitenlohner * main.c [WIN32]: Use "sjis" file encoding (from W32TeX). 2012-07-28 Peter Breitenlohner * convert.c, pageread.c, styfile.c: Handle input files with Dos/Windows (CRLF) line endings (from W32TeX). Use Nelson Beebe's qqsort() instead of qsort() (from W32TeX). * convert.c, sort.c: Add #include "qsort.h". * qsort.[ch] (new): Copied from ../makeindexk. * Makefile.am (mendex_SOURCES): Add the new files. 2012-07-27 Peter Breitenlohner * convert.c, kp.[ch], main.c, styfile.c: Always use KPATHSEA. * Makefile.am (AM_CPPFLAGS): Remove '-DKPATHSEA'. * convert.c, fread.c, main.c, sort.c: Use xmalloc(). * fread.c, main.c: Use xstrdup() instead of malloc()+strcpy(). * fwrite.c, mendex.h, kp.[ch]: Change {verb,warn}_printf() and KP_entry_filetype() return type from 'int' into 'void'. 2012-07-26 Peter Breitenlohner * fwrite.c, main.c: Use binary mode for input and output (from W32TeX). * convert.c, fread.c, main.c: Use 8-bit exit() codes. * main.c: Terminate main() with return instead of exit(). 2012-07-15 Peter Breitenlohner * kp.c: Pass program name string to kpse_set_program_name. 2012-03-04 Peter Breitenlohner Avoid 'differ in signedness' warnings. * fread.c (mfgets): Cast buf to 'char *'. 2011-10-21 Akira Kakuto * kp.c: program name should be mendex. 2011-08-23 Peter Breitenlohner Rename: ChangeLog => ChangeLog.jis, ChangeLog.TL => ChangeLog. * Makefile.am: Adapt. * mendex.h [WIN32]: #define nkf_open as fopen and nkf_close as fclose. * convert.c, fread.c, styfile.c: Open files with mode "rb" (required for WIN32, ignored for Unix). 2011-08-02 Peter Breitenlohner * convert.c, kp.[ch], main.c: Remove code for ancient kpathsea. * Makefile.am (AM_CPPFLAGS): Drop `-DKPATHSEA3'. 2011-04-23 Peter Breitenlohner * Makefile.am (EXTRA_DIST): No need to mention ChangeLog, README. * configure.ac: Drop useless check for . * convert.c, fread.c, main.c, sort.c: Do not typecast the result of malloc(). 2011-04-22 Peter Breitenlohner Avoid 'differ in signedness' warnings. The string functions strlen(), strcmp(), strncmp(), strcpy(), and strncpy() all expect 'char *' arguments and gcc-4.x will create warnings for 'signed char *' and 'unsigned char *' args. Moreover strcmp() and strncmp() will always compare string bytes interpreted as 'unsigned char'. Finally initializing plain char array elements with, e.g., '0x80' always does the right thing. * convert.c, exkana.h, exvar.h, fread.c, fwrite.c, kana.h, ktable.h, mendex.h, sort.c, var.h: Change type of all global and local vars, function params, and struct members from 'unsigned char' or 'unsigned char *' to plain 'char' or 'char *', but always cast string bytes to 'unsigned char' when tested for '<', '<=', '>', or '>='. 2010-04-17 Peter Breitenlohner * convert.c (dicread, dicvalread), fread.c (idxread), pageread.c (lastpage), styfile.c (styread): Use kpse_in_name_ok. * fwrite.c (indwrite), main.c (main): Use kpse_out_name_ok. From Akira Kakuto , 17 Apr 2010 23:30:15. Added #include for prototypes. * convert.c (kp_dict): Move extern declaration from here ... * styfile.c (kp_ist): ... and here ... * kp.h (kp_ist, kp_dict): ... to here. 2010-04-16 Peter Breitenlohner * exvar.h, var.h (atama, page_compositor, page_precedence): Change types from 'char' back to 'unsigned char' as they originally were in exvar.h. From Sadayuki Tanaka , 16 Apr 2010 16:30:22. 2010-04-15 Peter Breitenlohner * pageread.c: #include "mendex.h" for prototype. * kana.h: #include "exkana.h" for type checking. * var.h: #include "exvar.h" for type checking. * sort.c (wcomp): Initialize local variable prechar. * kp.c (KP_init): Use kpse_set_program_name() because kpse_set_progname() is deprecated since ages and no longer exported from kpathsea. FIXME: Is this correct? * exvar.h (atama, page_compositor, page_precedence): Change type from 'unsigned char' to 'char' as defined in var.h. * convert.c (dicread): Add 'return 0' at end. Avoid compiler warnings. * ANSI C function prototypes and definitions. * Declare functions as static, skip compilation of unused ones. * Declare various function param or result, struct member, and local or global var strings as const. 2010-04-12 Peter Breitenlohner * Makefile.am (EXTRA_DIST): Add indexsty, mendex.doc. Add rule to rebuild kpathsea.