Skip to content

Commit

Permalink
{,e}uptex: Accept extended upTeX internal encoding also in pTeX-compa…
Browse files Browse the repository at this point in the history
…tible EUC/SJIS mode

git-svn-id: svn://tug.org/texlive/trunk/Build/source@73271 c570f23f-e606-0410-a88d-b1316a301751
  • Loading branch information
t-tk committed Jan 2, 2025
1 parent 8e9652c commit 42cf944
Show file tree
Hide file tree
Showing 29 changed files with 2,705 additions and 83 deletions.
78 changes: 42 additions & 36 deletions texk/web2c/Makefile.in
Original file line number Diff line number Diff line change
Expand Up @@ -3283,12 +3283,13 @@ EXTRA_DIST = PROJECTS cftests cpascal.h help.h w2c/config.h \
ptexdir/tests/pknj-e.log ptexdir/tests/p-pknj-sa.typ \
ptexdir/tests/p-pknj-ea.typ ptexdir/tests/ucs.tex \
ptexdir/tests/ucs-s.log ptexdir/tests/ucs-e.log \
$(uptex_web_srcs) $(uptex_ch_srcs) uptexdir/uptex.defines \
uptexdir/upbibtex.ch uptexdir/updvitype.ch \
uptexdir/uppltotf.ch uptexdir/uptftopl.ch uptexdir/COPYRIGHT \
uptexdir/COPYRIGHT.ja uptexdir/ChangeLog $(uptex_tests) \
$(upweb_tests) tests/enc-u.bbl tests/enc-eu.bbl \
tests/enc-su.bbl tests/enc-uu.bbl uptexdir/tests/uptex3.tex \
ptexdir/tests/p-jchwidow.log $(uptex_web_srcs) \
$(uptex_ch_srcs) uptexdir/uptex.defines uptexdir/upbibtex.ch \
uptexdir/updvitype.ch uptexdir/uppltotf.ch \
uptexdir/uptftopl.ch uptexdir/COPYRIGHT uptexdir/COPYRIGHT.ja \
uptexdir/ChangeLog $(uptex_tests) $(upweb_tests) \
tests/enc-u.bbl tests/enc-eu.bbl tests/enc-su.bbl \
tests/enc-uu.bbl uptexdir/tests/uptex3.tex \
uptexdir/tests/uptex3.dvi uptexdir/tests/uptex4.tex \
uptexdir/tests/uptex4.dvi uptexdir/tests/uptex5.tex \
uptexdir/tests/uptex5.dvi uptexdir/tests/uptex3a.typ \
Expand All @@ -3307,6 +3308,7 @@ EXTRA_DIST = PROJECTS cftests cpascal.h help.h w2c/config.h \
uptexdir/tests/lmr1.tex uptexdir/tests/up-lmr1.log \
uptexdir/tests/lmr2.tex uptexdir/tests/up-lmr2.log \
uptexdir/tests/noto1.tex uptexdir/tests/up-noto1.log \
uptexdir/tests/jchwidow.tex uptexdir/tests/up-jchwidow.log \
$(euptex_web_srcs) $(euptex_ch_srcs) euptexdir/euptex.defines \
euptexdir/COPYRIGHT euptexdir/COPYRIGHT.jis \
euptexdir/ChangeLog euptexdir/EUPTEX.txt $(euptex_tests) \
Expand Down Expand Up @@ -3336,22 +3338,23 @@ EXTRA_DIST = PROJECTS cftests cpascal.h help.h w2c/config.h \
euptexdir/tests/eup-ofm.log euptexdir/tests/eup-prim.tex \
euptexdir/tests/eup-prim.log euptexdir/tests/ucs.tex \
euptexdir/tests/ucs-s.log euptexdir/tests/ucs-e.log \
euptexdir/tests/ucs-u.log hitexdir/ChangeLog $(hitex_web) \
$(hitex_tests) hitexdir/tests/hello.tex \
hitexdir/tests/rule.tex pdftexdir/regex/COPYING.LIB \
pdftexdir/regex/README $(pdftex_ch_srcs) \
pdftexdir/pdftex.defines pdftexdir/ChangeLog pdftexdir/NEWS \
pdftexdir/README pdftexdir/change-files.txt $(pdftex_tests) \
tests/wprob.tex pdftexdir/tests/pdfimage.tex tests/1-4.jpg \
tests/B.pdf tests/basic.tex tests/lily-ledger-broken.png \
tests/expanded.tex tests/expanded.txt tests/cnfline.tex \
tests/partoken-ok.tex tests/partoken-xfail.tex \
$(ttf2afm_tests) pdftexdir/tests/postV3.afm \
pdftexdir/tests/postV3.ttf pdftexdir/tests/postV7.afm \
pdftexdir/tests/postV7.ttf $(pdftosrc_tests) \
pdftexdir/tests/test-13.pdf pdftexdir/tests/test-13.xref \
pdftexdir/tests/test-15.pdf pdftexdir/tests/test-15.xref \
$(libluasocket_sources) luatexdir/luasocket/src/ftp_lua.c \
euptexdir/tests/ucs-u.log euptexdir/tests/eup-jchwidow.log \
hitexdir/ChangeLog $(hitex_web) $(hitex_tests) \
hitexdir/tests/hello.tex hitexdir/tests/rule.tex \
pdftexdir/regex/COPYING.LIB pdftexdir/regex/README \
$(pdftex_ch_srcs) pdftexdir/pdftex.defines pdftexdir/ChangeLog \
pdftexdir/NEWS pdftexdir/README pdftexdir/change-files.txt \
$(pdftex_tests) tests/wprob.tex pdftexdir/tests/pdfimage.tex \
tests/1-4.jpg tests/B.pdf tests/basic.tex \
tests/lily-ledger-broken.png tests/expanded.tex \
tests/expanded.txt tests/cnfline.tex tests/partoken-ok.tex \
tests/partoken-xfail.tex $(ttf2afm_tests) \
pdftexdir/tests/postV3.afm pdftexdir/tests/postV3.ttf \
pdftexdir/tests/postV7.afm pdftexdir/tests/postV7.ttf \
$(pdftosrc_tests) pdftexdir/tests/test-13.pdf \
pdftexdir/tests/test-13.xref pdftexdir/tests/test-15.pdf \
pdftexdir/tests/test-15.xref $(libluasocket_sources) \
luatexdir/luasocket/src/ftp_lua.c \
luatexdir/luasocket/src/headers_lua.c \
luatexdir/luasocket/src/http_lua.c \
luatexdir/luasocket/src/ltn12_lua.c \
Expand Down Expand Up @@ -3652,7 +3655,7 @@ DISTCLEANFILES = CXXLD.sh tangle.c tangle.h tangle.p tangle-web2c \
ptests/xcmr10.pl ptests/xsample*.typ ptests/x*min10.* \
ptests/xchcode*.* ptests/xskipjfmp.* ptrip.diffs p-ctrlsym.log \
p-ctrlsym.out p-ctrlsym.tex p-endline*.* p-jctrlsym*.* \
p-chartoken.* p-lineend.* p-pknj-*.* p-ucs*.* \
p-chartoken.* p-lineend.* p-pknj-*.* p-ucs*.* p-jchwidow*.* \
$(nodist_uptex_SOURCES) uptex.web uptex.ch uptex-web2c uptex.p \
uptex.pool uptex-tangle $(upweb_programs:=.c) \
$(upweb_programs:=.h) $(upweb_programs:=.p) \
Expand All @@ -3665,13 +3668,14 @@ DISTCLEANFILES = CXXLD.sh tangle.c tangle.h tangle.p tangle-web2c \
uptests/x*min10.* uptests/xchcode*.* uptests/xtestnewu*.* \
uptests/xuparse.* uptests/yuparse.* uptests/ygkhuge*.* \
uptests/ygk256*.* uptests/xskipjfmp.* uptrip.diffs up-ofm.* \
up-prim.* up-lmr*.* up-noto*.* $(nodist_euptex_SOURCES) \
euptex.web euptex.ch euptex-web2c euptex.p euptex.pool \
euptex-tangle euptrip.diffs pdfprimitive-euptex.* \
eup-ctrlsym.log eup-ctrlsym.out eup-ctrlsym.tex eup-endline*.* \
eup-jctrlsym*.* eup-pknj-*.* eup-postpena*.* eup-free_*.* \
eup-inhibitglue*.* eup-kinsoku*.* eup-ofm.* eup-prim.* \
eup-ucs*.* $(nodist_hitex_SOURCES) $(nodist_hishrink_SOURCES) \
up-prim.* up-lmr*.* up-noto*.* up-jchwidow.* \
$(nodist_euptex_SOURCES) euptex.web euptex.ch euptex-web2c \
euptex.p euptex.pool euptex-tangle euptrip.diffs \
pdfprimitive-euptex.* eup-ctrlsym.log eup-ctrlsym.out \
eup-ctrlsym.tex eup-endline*.* eup-jctrlsym*.* eup-pknj-*.* \
eup-postpena*.* eup-free_*.* eup-inhibitglue*.* eup-kinsoku*.* \
eup-ofm.* eup-prim.* eup-ucs*.* eup-jchwidow.* \
$(nodist_hitex_SOURCES) $(nodist_hishrink_SOURCES) \
$(nodist_histretch_SOURCES) hiformat-tangle hitex-tangle \
hello.log rule.log $(nodist_pdftex_SOURCES) pdftex-final.ch \
pdftex-web2c pdftex.p pdftex.pool pdftex-tangle pwprob.log \
Expand Down Expand Up @@ -4496,7 +4500,7 @@ ptex_tests = \
ptexdir/wcfname.test \
ptexdir/ptex-ctrlsym.test \
ptexdir/ptex-prntknj.test \
ptexdir/ptex-ucs.test
ptexdir/ptex-ucs.test ptexdir/ptex-widow.test

uptex_cppflags = $(PTEXENC_INCLUDES) $(AM_CPPFLAGS) $(ZLIB_INCLUDES)
uptex_ldadd = libukanji.a $(pproglib) $(PTEXENC_LIBS) $(LDADD) $(ZLIB_LIBS)
Expand Down Expand Up @@ -4561,7 +4565,8 @@ uptex_tests = \
uptexdir/upkcat.test \
uptexdir/wcfname.test uptexdir/wcfname0.test \
uptexdir/uptex-ofm.test uptexdir/uptex-prim.test \
uptexdir/uptex-lmr.test uptexdir/uptex-noto.test
uptexdir/uptex-lmr.test uptexdir/uptex-noto.test \
uptexdir/uptex-widow.test

# uppPLtoTF/upTFtoPL
upweb_tests = uptexdir/upbibtex.test uptexdir/updvitype.test \
Expand Down Expand Up @@ -4629,7 +4634,7 @@ euptex_tests = \
euptexdir/euptex-prntknj.test \
euptexdir/euptex-kinsoku.test \
euptexdir/euptex-ofm.test euptexdir/euptex-prim.test \
euptexdir/euptex-ucs.test
euptexdir/euptex-ucs.test euptexdir/euptex-widow.test


# At the moment, these are the only man pages handled in the
Expand Down Expand Up @@ -22066,7 +22071,7 @@ ptex.ch: tie$(EXEEXT) ptex.web $(ptex_ch_srcs)
ptexdir/ptriptest.log: ptex$(EXEEXT) dvitype$(EXEEXT) pltotf$(EXEEXT) tftopl$(EXEEXT)
ptexdir/pver.log ptexdir/wcfname.log \
ptexdir/ptex-ctrlsym.log ptexdir/ptex-prntknj.log \
ptexdir/ptex-ucs.log: ptex$(EXEEXT)
ptexdir/ptex-ucs.log ptexdir/ptex-widow.log: ptex$(EXEEXT)

ptrip.diffs: ptex$(EXEEXT) dvitype$(EXEEXT) pltotf$(EXEEXT) tftopl$(EXEEXT)
$(triptrap_diffs) $@
Expand Down Expand Up @@ -22140,7 +22145,8 @@ uptexdir/uptriptest.log uptexdir/ptriptest.log: \
uptexdir/upver.log uptexdir/upkcat.log \
uptexdir/wcfname.log uptexdir/wcfname0.log \
uptexdir/uptex-ofm.log uptexdir/uptex-prim.log \
uptexdir/uptex-lmr.log uptexdir/uptex-noto.log: uptex$(EXEEXT)
uptexdir/uptex-lmr.log uptexdir/uptex-noto.log \
uptexdir/uptex-widow.log: uptex$(EXEEXT)
uptexdir/upbibtex.log: upbibtex$(EXEEXT)
uptexdir/updvitype.log: updvitype$(EXEEXT)
uptexdir/uppltotf.log: uppltotf$(EXEEXT)
Expand Down Expand Up @@ -22191,7 +22197,7 @@ euptexdir/eupver.log euptexdir/upkcat.log \
euptexdir/euptex-ctrlsym.log euptexdir/euptex-prntknj.log \
euptexdir/euptex-kinsoku.log \
euptexdir/euptex-ofm.log euptexdir/euptex-prim.log \
euptexdir/euptex-ucs.log: euptex$(EXEEXT)
euptexdir/euptex-ucs.log euptexdir/euptex-widow.log: euptex$(EXEEXT)

euptrip.diffs: euptex$(EXEEXT) dvitype$(EXEEXT) pltotf$(EXEEXT) tftopl$(EXEEXT)
$(triptrap_diffs) $@
Expand Down
4 changes: 2 additions & 2 deletions texk/web2c/euptexdir/COPYRIGHT
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Copyright (C) 2009 ASCII MEDIA WORKS.
Copyright (C) 2007-2024 Takuji Tanaka
Copyright (C) 2010-2024 Japanese TeX Development Community
Copyright (C) 2007-2025 Takuji Tanaka
Copyright (C) 2010-2025 Japanese TeX Development Community
All rights reserved.

Redistribution and use in source and binary forms, with or without
Expand Down
9 changes: 9 additions & 0 deletions texk/web2c/euptexdir/ChangeLog
Original file line number Diff line number Diff line change
@@ -1,3 +1,12 @@
2025-01-02 TANAKA Takuji <[email protected]>

* upkcat.test: Update tests.
* euptex-widow.test, tests/eup-jchwidow.log,
am/euptex.am: Add new tests for widow penalty originally
written by Kitagawa-san.
https://github.com/texjporg/tex-jp-build/issues/103
* COPYRIGHT: copyright year.

2024-10-20 TANAKA Takuji <[email protected]>

* eptex.ech, etex.ch{0,1}, fam256,ch,
Expand Down
19 changes: 11 additions & 8 deletions texk/web2c/euptexdir/am/euptex.am
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ euptex_tests = \
euptexdir/euptex-prntknj.test \
euptexdir/euptex-kinsoku.test \
euptexdir/euptex-ofm.test euptexdir/euptex-prim.test \
euptexdir/euptex-ucs.test
euptexdir/euptex-ucs.test euptexdir/euptex-widow.test
euptexdir/euptriptest.log euptexdir/eptriptest.log: \
euptex$(EXEEXT) dvitype$(EXEEXT) pltotf$(EXEEXT) tftopl$(EXEEXT)
euptexdir/pdfprimitive.log: euptex$(EXEEXT)
Expand All @@ -114,7 +114,7 @@ euptexdir/eupver.log euptexdir/upkcat.log \
euptexdir/euptex-ctrlsym.log euptexdir/euptex-prntknj.log \
euptexdir/euptex-kinsoku.log \
euptexdir/euptex-ofm.log euptexdir/euptex-prim.log \
euptexdir/euptex-ucs.log: euptex$(EXEEXT)
euptexdir/euptex-ucs.log euptexdir/euptex-widow.log: euptex$(EXEEXT)

EXTRA_DIST += $(euptex_tests)

Expand All @@ -140,37 +140,40 @@ EXTRA_DIST += \
euptexdir/tests/pdfprimitive-euptex.log
DISTCLEANFILES += pdfprimitive-euptex.*

## euptex-ctrlsym.test
## euptexdir/euptex-ctrlsym.test
EXTRA_DIST += euptexdir/tests/ctrlsym.tex euptexdir/tests/ctrlsym.log \
euptexdir/tests/endlinechar.tex euptexdir/tests/endline.log \
euptexdir/tests/control-symbol.tex euptexdir/tests/jctrlsym.log \
euptexdir/tests/eup-endlinea.typ euptexdir/tests/eup-jctrlsyma.typ
DISTCLEANFILES += eup-ctrlsym.log eup-ctrlsym.out eup-ctrlsym.tex \
eup-endline*.* eup-jctrlsym*.*
## euptex-prntknj.test
## euptexdir/euptex-prntknj.test
EXTRA_DIST += euptexdir/tests/printkanji.tex euptexdir/tests/pknj-s.log \
euptexdir/tests/pknj-e.log euptexdir/tests/pknj-u.log \
euptexdir/tests/eup-pknj-sa.typ euptexdir/tests/eup-pknj-ea.typ \
euptexdir/tests/eup-pknj-ua.typ
DISTCLEANFILES += eup-pknj-*.*
## euptex-kinsoku.test
## euptexdir/euptex-kinsoku.test
EXTRA_DIST += euptexdir/tests/postpena.tex euptexdir/tests/postpena.log \
euptexdir/tests/free_ixsp.tex euptexdir/tests/free_ixsp.log \
euptexdir/tests/free_pena.tex euptexdir/tests/free_pena.log \
euptexdir/tests/inhibitglue.tex euptexdir/tests/eup-inhibitgluea.typ \
euptexdir/tests/kinsoku-table.tex euptexdir/tests/kinsoku-table.log \
euptexdir/tests/kinsoku-search.tex euptexdir/tests/kinsoku-search.log
DISTCLEANFILES += eup-postpena*.* eup-free_*.* eup-inhibitglue*.* eup-kinsoku*.*
## euptex-ofm.test
## euptexdir/euptex-ofm.test
EXTRA_DIST += euptexdir/tests/eup-ofm.tex euptexdir/tests/eup-ofm.log
DISTCLEANFILES += eup-ofm.*
## euptex-prim.test
## euptexdir/euptex-prim.test
EXTRA_DIST += euptexdir/tests/eup-prim.tex euptexdir/tests/eup-prim.log
DISTCLEANFILES += eup-prim.*
## euptex-ucs.test
## euptexdir/euptex-ucs.test
EXTRA_DIST += euptexdir/tests/ucs.tex euptexdir/tests/ucs-s.log \
euptexdir/tests/ucs-e.log euptexdir/tests/ucs-u.log
DISTCLEANFILES += eup-ucs*.*
## euptexdir/euptex-widow.test
EXTRA_DIST += euptexdir/tests/eup-jchwidow.log
DISTCLEANFILES += eup-jchwidow.*

euptrip.diffs: euptex$(EXEEXT) dvitype$(EXEEXT) pltotf$(EXEEXT) tftopl$(EXEEXT)
$(triptrap_diffs) $@
Expand Down
32 changes: 32 additions & 0 deletions texk/web2c/euptexdir/euptex-widow.test
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
#! /bin/sh -vx
# Copyright 2025 Japanese TeX Development Community <[email protected]>
# You may freely use, modify and/or distribute this file.

BinDir=${BinDir:-.}
ExeExt=${ExeExt:-}
_euptex=$BinDir/euptex$ExeExt

LC_ALL=C; export LC_ALL; LANGUAGE=C; export LANGUAGE

TEXMFCNF=$srcdir/../kpathsea;export TEXMFCNF
TEXINPUTS=".;$srcdir/tests"; export TEXINPUTS
TEXFONTS=".;$srcdir//tests"; export TEXFONTS
TEXFORMATS=.; export TEXFORMATS

# get same filename in log
rm -f eup-jchwidow.*
$LN_S $srcdir/uptexdir/tests/jchwidow.tex ./eup-jchwidow.tex

if test ! -f ./eup-basic.tex; then
cp $srcdir/tests/dump-basic.tex ./eup-basic.tex
fi
if test ! -f ./eup-basic.fmt; then
$_euptex -ini -etex eup-basic || exit 1
fi

$_euptex -fmt=eup-basic -interaction=batchmode eup-jchwidow || :

sed 1d eup-jchwidow.log >eup-jchwidow.out

diff $srcdir/euptexdir/tests/eup-jchwidow.log eup-jchwidow.out || exit 3

Loading

0 comments on commit 42cf944

Please sign in to comment.