Skip to content

Commit eb0ef53

Browse files
committed
git-svn-id: svn://tug.org/texlive/branches/branch2018/Build/source@47642 c570f23f-e606-0410-a88d-b1316a301751
1 parent 16c7b54 commit eb0ef53

File tree

27 files changed

+248
-79
lines changed

27 files changed

+248
-79
lines changed

texk/dvipdfm-x/ChangeLog

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,16 @@
1+
2018-05-06 Akira Kakuto <kakuto@fuk.kindai.ac.jp>
2+
3+
* tt_cmap.c: Revert a part of changes in 2017-12-09,
4+
which breaks to give tounicode entries for ligatures.
5+
http://tug.org/pipermail/tex-live/2018-May/041608.html.
6+
* configure.ac: Version 20180506.
7+
8+
2018-04-28 Stefan Br\"uns <stefan.bruens@rwth-aachen.de>
9+
10+
* pngimage.c: Fix a bug which causes a segfault with 1/2/4-bit
11+
transparent indexed PNGs.
12+
* configure.ac: Version 20180428.
13+
114
2018-03-03 Akira Kakuto <kakuto@fuk.kindai.ac.jp>
215

316
* xbb.c: Remove unused lines.

texk/dvipdfm-x/configure

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#! /bin/sh
22
# Guess values for system-dependent variables and create Makefiles.
3-
# Generated by GNU Autoconf 2.69 for dvipdfm-x (TeX Live) 20180217.
3+
# Generated by GNU Autoconf 2.69 for dvipdfm-x (TeX Live) 20180506.
44
#
55
# Report bugs to <tex-k@tug.org>.
66
#
@@ -590,8 +590,8 @@ MAKEFLAGS=
590590
# Identity of this package.
591591
PACKAGE_NAME='dvipdfm-x (TeX Live)'
592592
PACKAGE_TARNAME='dvipdfm-x--tex-live-'
593-
PACKAGE_VERSION='20180217'
594-
PACKAGE_STRING='dvipdfm-x (TeX Live) 20180217'
593+
PACKAGE_VERSION='20180506'
594+
PACKAGE_STRING='dvipdfm-x (TeX Live) 20180506'
595595
PACKAGE_BUGREPORT='tex-k@tug.org'
596596
PACKAGE_URL=''
597597

@@ -1350,7 +1350,7 @@ if test "$ac_init_help" = "long"; then
13501350
# Omit some internal or obsolete options to make the list less imposing.
13511351
# This message is too long to be a string in the A/UX 3.1 sh.
13521352
cat <<_ACEOF
1353-
\`configure' configures dvipdfm-x (TeX Live) 20180217 to adapt to many kinds of systems.
1353+
\`configure' configures dvipdfm-x (TeX Live) 20180506 to adapt to many kinds of systems.
13541354

13551355
Usage: $0 [OPTION]... [VAR=VALUE]...
13561356

@@ -1421,7 +1421,7 @@ fi
14211421

14221422
if test -n "$ac_init_help"; then
14231423
case $ac_init_help in
1424-
short | recursive ) echo "Configuration of dvipdfm-x (TeX Live) 20180217:";;
1424+
short | recursive ) echo "Configuration of dvipdfm-x (TeX Live) 20180506:";;
14251425
esac
14261426
cat <<\_ACEOF
14271427

@@ -1551,7 +1551,7 @@ fi
15511551
test -n "$ac_init_help" && exit $ac_status
15521552
if $ac_init_version; then
15531553
cat <<\_ACEOF
1554-
dvipdfm-x (TeX Live) configure 20180217
1554+
dvipdfm-x (TeX Live) configure 20180506
15551555
generated by GNU Autoconf 2.69
15561556

15571557
Copyright (C) 2012 Free Software Foundation, Inc.
@@ -2390,7 +2390,7 @@ cat >config.log <<_ACEOF
23902390
This file contains any messages produced by compilers while
23912391
running configure, to aid debugging if configure makes a mistake.
23922392

2393-
It was created by dvipdfm-x (TeX Live) $as_me 20180217, which was
2393+
It was created by dvipdfm-x (TeX Live) $as_me 20180506, which was
23942394
generated by GNU Autoconf 2.69. Invocation command line was
23952395

23962396
$ $0 $@
@@ -8075,7 +8075,7 @@ fi
80758075

80768076
# Define the identity of the package.
80778077
PACKAGE='dvipdfm-x--tex-live-'
8078-
VERSION='20180217'
8078+
VERSION='20180506'
80798079

80808080

80818081
cat >>confdefs.h <<_ACEOF
@@ -14744,7 +14744,7 @@ Usage: $0 [OPTIONS]
1474414744
Report bugs to <bug-libtool@gnu.org>."
1474514745

1474614746
lt_cl_version="\
14747-
dvipdfm-x (TeX Live) config.lt 20180217
14747+
dvipdfm-x (TeX Live) config.lt 20180506
1474814748
configured by $0, generated by GNU Autoconf 2.69.
1474914749

1475014750
Copyright (C) 2011 Free Software Foundation, Inc.
@@ -16624,7 +16624,7 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
1662416624
# report actual input values of CONFIG_FILES etc. instead of their
1662516625
# values after options handling.
1662616626
ac_log="
16627-
This file was extended by dvipdfm-x (TeX Live) $as_me 20180217, which was
16627+
This file was extended by dvipdfm-x (TeX Live) $as_me 20180506, which was
1662816628
generated by GNU Autoconf 2.69. Invocation command line was
1662916629

1663016630
CONFIG_FILES = $CONFIG_FILES
@@ -16694,7 +16694,7 @@ _ACEOF
1669416694
cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
1669516695
ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
1669616696
ac_cs_version="\\
16697-
dvipdfm-x (TeX Live) config.status 20180217
16697+
dvipdfm-x (TeX Live) config.status 20180506
1669816698
configured by $0, generated by GNU Autoconf 2.69,
1669916699
with options \\"\$ac_cs_config\\"
1670016700

texk/dvipdfm-x/configure.ac

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ dnl This file is free software; the copyright holder
77
dnl gives unlimited permission to copy and/or distribute it,
88
dnl with or without modifications, as long as this notice is preserved.
99
dnl
10-
AC_INIT([dvipdfm-x (TeX Live)], [20180217], [tex-k@tug.org])
10+
AC_INIT([dvipdfm-x (TeX Live)], [20180506], [tex-k@tug.org])
1111
AC_PREREQ([2.65])
1212
AC_CONFIG_SRCDIR([agl.c])
1313
AC_CONFIG_AUX_DIR([../../build-aux])

texk/dvipdfm-x/pngimage.c

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -964,12 +964,16 @@ create_soft_mask (png_structp png_ptr, png_infop info_ptr,
964964
png_bytep trans;
965965
int num_trans;
966966
png_uint_32 i;
967+
png_byte bpc, mask, shift;
967968

968969
if (!png_get_valid(png_ptr, info_ptr, PNG_INFO_tRNS) ||
969970
!png_get_tRNS(png_ptr, info_ptr, &trans, &num_trans, NULL)) {
970971
WARN("%s: PNG does not have valid tRNS chunk but tRNS is requested.", PNG_DEBUG_STR);
971972
return NULL;
972973
}
974+
bpc = png_get_bit_depth(png_ptr, info_ptr);
975+
mask = 0xff >> (8 - bpc);
976+
shift = 8 - bpc;
973977

974978
smask = pdf_new_stream(STREAM_COMPRESS);
975979
dict = pdf_stream_dict(smask);
@@ -981,7 +985,8 @@ create_soft_mask (png_structp png_ptr, png_infop info_ptr,
981985
pdf_add_dict(dict, pdf_new_name("ColorSpace"), pdf_new_name("DeviceGray"));
982986
pdf_add_dict(dict, pdf_new_name("BitsPerComponent"), pdf_new_number(8));
983987
for (i = 0; i < width*height; i++) {
984-
png_byte idx = image_data_ptr[i];
988+
/* data is packed for 1/2/4 bpc formats, msb first */
989+
png_byte idx = (image_data_ptr[bpc * i / 8] >> (shift - bpc * i % 8)) & mask;
985990
smask_data_ptr[i] = (idx < num_trans) ? trans[idx] : 0xff;
986991
}
987992
pdf_add_stream(smask, (char *)smask_data_ptr, width*height);

texk/dvipdfm-x/tt_cmap.c

Lines changed: 13 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
/* This is dvipdfmx, an eXtended version of dvipdfm by Mark A. Wicks.
22
3-
Copyright (C) 2007-2017 by Jin-Hwan Cho and Shunsaku Hirata,
3+
Copyright (C) 2007-2018 by Jin-Hwan Cho and Shunsaku Hirata,
44
the dvipdfmx project team.
55
66
This program is free software; you can redistribute it and/or modify
@@ -928,19 +928,12 @@ handle_subst_glyphs (CMap *cmap,
928928
}
929929
#undef MAX_UNICODES
930930
if (unicode_count == -1) {
931-
#if defined(LIBDPX)
932931
if(verbose > VERBOSE_LEVEL_MIN) {
933932
if (name)
934933
MESG("No Unicode mapping available: GID=%u, name=%s\n", gid, name);
935934
else
936935
MESG("No Unicode mapping available: GID=%u\n", gid);
937936
}
938-
#else
939-
if (name)
940-
MESG("No Unicode mapping available: GID=%u, name=%s\n", gid, name);
941-
else
942-
MESG("No Unicode mapping available: GID=%u\n", gid);
943-
#endif /* LIBDPX */
944937
} else {
945938
/* the Unicode characters go into wbuf[2] and following, in UTF16BE */
946939
/* we rely on WBUF_SIZE being more than adequate for MAX_UNICODES */
@@ -1021,13 +1014,7 @@ add_to_cmap_if_used (CMap *cmap,
10211014
{
10221015
USHORT count = 0;
10231016
USHORT cid = cffont ? cff_charsets_lookup_inverse(cffont, gid) : gid;
1024-
1025-
/* Skip PUA characters and alphabetic presentation forms, allowing
1026-
* handle_subst_glyphs() as it might find better mapping. Fixes the
1027-
* mapping of ligatures encoded in PUA in fonts like Linux Libertine
1028-
* and old Adobe fonts.
1029-
*/
1030-
if (is_used_char2(used_chars, cid) && !is_PUA_or_presentation(ch)) {
1017+
if (is_used_char2(used_chars, cid)) {
10311018
int len;
10321019
unsigned char *p = wbuf + 2;
10331020

@@ -1038,11 +1025,18 @@ add_to_cmap_if_used (CMap *cmap,
10381025
len = UC_UTF16BE_encode_char((int32_t) ch, &p, wbuf + WBUF_SIZE);
10391026
CMap_add_bfchar(cmap, wbuf, 2, wbuf + 2, len);
10401027

1041-
/* Avoid duplicate entry
1042-
* There are problem when two Unicode code is mapped to
1043-
* single glyph...
1028+
/* Skip PUA characters and alphabetic presentation forms, allowing
1029+
* handle_subst_glyphs() as it might find better mapping. Fixes the
1030+
* mapping of ligatures encoded in PUA in fonts like Linux Libertine
1031+
* and old Adobe fonts.
10441032
*/
1045-
used_chars[cid / 8] &= ~(1 << (7 - (cid % 8)));
1033+
if (!is_PUA_or_presentation(ch)) {
1034+
/* Avoid duplicate entry
1035+
* There are problem when two Unicode code is mapped to
1036+
* single glyph...
1037+
*/
1038+
used_chars[cid / 8] &= ~(1 << (7 - (cid % 8)));
1039+
}
10461040
}
10471041

10481042
return count;

texk/web2c/ptexdir/ChangeLog

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,16 @@
1+
2018-05-06 Hironori Kitagawa <h_kitagawa2001@yahoo.co.jp>
2+
3+
* kanji.c: More strict check kanji token.
4+
5+
2018-04-14 Hironori Kitagawa <h_kitagawa2001@yahoo.co.jp>
6+
7+
* ptex-base.ch: Fix issue GitHub:texjporg/tex-jp-build#57
8+
that discontinuous KINSOKU/INHIBIT table cannot be
9+
searched properly.
10+
(regression caused by a commmit of 2017-09-11)
11+
* tests/free_pena.tex, tests/free_ixsp.tex: Added.
12+
* ptex_version.h: pTeX version p3.8.1.
13+
114
2018-02-05 Hironobu Yamashita <h.y.acetaminophen@gmail.com>
215

316
* ptex-base.ch: Set subtype for JFM glue in math list.

texk/web2c/ptexdir/kanji.c

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
*/
55

66
#include "kanji.h"
7+
#define CS_TOKEN_FLAG 0xFFFF
78

89
#if !defined(WIN32)
910
int sjisterminal;
@@ -12,7 +13,8 @@ int sjisterminal;
1213
/* TOKEN */
1314
boolean check_kanji(integer c)
1415
{
15-
return is_char_kanji(c);
16+
if (c >= CS_TOKEN_FLAG) return false;
17+
else return is_char_kanji(c);
1618
}
1719

1820
boolean is_char_ascii(integer c)

texk/web2c/ptexdir/ptex-base.ch

Lines changed: 21 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,7 @@
5858
% pTeX p3.7.1.
5959
% (2017-09-07) HK pTeX p3.7.2 More restrictions on direction change commands.
6060
% (2018-01-21) HK Added \ptexversion primitive and co. pTeX p3.8.
61+
% (2018-04-14) HK pTeX p3.8.1 Bug fix for discontinuous KINSOKU table.
6162
%
6263

6364
@x
@@ -73,8 +74,8 @@
7374
@y
7475
@d pTeX_version=3
7576
@d pTeX_minor_version=8
76-
@d pTeX_revision==".0"
77-
@d pTeX_version_string=='-p3.8.0' {current \pTeX\ version}
77+
@d pTeX_revision==".1"
78+
@d pTeX_version_string=='-p3.8.1' {current \pTeX\ version}
7879
@#
7980
@d pTeX_banner=='This is pTeX, Version 3.14159265',pTeX_version_string
8081
@d pTeX_banner_k==pTeX_banner
@@ -6397,6 +6398,8 @@ inserting a space between 2byte-char and 1byte-char.
63976398
@d inhibit_both=0 {disable to insert space before 2byte-char and after it}
63986399
@d inhibit_previous=1 {disable to insert space before 2byte-char}
63996400
@d inhibit_after=2 {disable to insert space after 2byte-char}
6401+
@d inhibit_none=3 {enable to insert space before/after 2byte-char}
6402+
@d inhibit_unused=4 {unused entry}
64006403
@d no_entry=1000
64016404
@d new_pos=0
64026405
@d cur_pos=1
@@ -6427,14 +6430,15 @@ var p,s:pointer;
64276430
begin s:=calc_pos(c); p:=s;
64286431
if n=new_pos then
64296432
begin repeat
6430-
if (inhibit_xsp_code(p)=0)or(inhibit_xsp_code(p)=c) then goto done;
6433+
if (inhibit_xsp_type(p)=inhibit_unused)or(inhibit_xsp_code(p)=0)
6434+
or(inhibit_xsp_code(p)=c) then goto done;
64316435
incr(p); if p>255 then p:=0;
64326436
until s=p; p:=no_entry;
64336437
end
64346438
else
64356439
begin repeat
6436-
if inhibit_xsp_code(p)=0 then goto done1;
6437-
if inhibit_xsp_code(p)=c then goto done;
6440+
if inhibit_xsp_code(p)=0 then goto done1
6441+
else if (inhibit_xsp_type(p)<>inhibit_unused)and(inhibit_xsp_code(p)=c) then goto done;
64386442
incr(p); if p>255 then p:=0;
64396443
until s=p;
64406444
done1: p:=no_entry;
@@ -6447,9 +6451,10 @@ assign_inhibit_xsp_code:
64476451
begin p:=cur_chr; scan_int; n:=cur_val; scan_optional_equals; scan_int;
64486452
if is_char_kanji(n) then
64496453
begin j:=get_inhibit_pos(tokanji(n),new_pos);
6450-
if (j<>no_entry)and(cur_val>inhibit_after)and(global or cur_level=level_one) then
6451-
begin n:=0; cur_val:=0 end
6452-
{ remove the entry from inhibit table }
6454+
if (j<>no_entry)and(cur_val>inhibit_after) then
6455+
begin if global or(cur_level=level_one) then cur_val:=inhibit_unused
6456+
{ remove the entry from inhibit table }
6457+
else cur_val:=inhibit_none; end
64536458
else if j=no_entry then
64546459
begin print_err("Inhibit table is full!!");
64556460
help1("I'm skipping this control sequences.");@/
@@ -6466,7 +6471,7 @@ end;
64666471
64676472
@ @<Fetch inhibit type from some table@>=
64686473
begin scan_int; q:=get_inhibit_pos(tokanji(cur_val),cur_pos);
6469-
cur_val_level:=int_val; cur_val:=3;
6474+
cur_val_level:=int_val; cur_val:=inhibit_none;
64706475
if q<>no_entry then cur_val:=inhibit_xsp_type(q);
64716476
end
64726477
@@ -6476,6 +6481,7 @@ The \.{\\postbreakpenalty} is inserted after the 2byte-char.
64766481
64776482
@d pre_break_penalty_code=1
64786483
@d post_break_penalty_code=2
6484+
@d kinsoku_unused_code=3
64796485
64806486
@<Put each...@>=
64816487
primitive("prebreakpenalty",assign_kinsoku,pre_break_penalty_code);
@@ -6502,15 +6508,16 @@ if p+kinsoku_base<0 then
65026508
gubed
65036509
if n=new_pos then
65046510
begin repeat
6505-
if (kinsoku_type(p)=0)or(kinsoku_code(p)=c) then goto done;
6511+
if (kinsoku_type(p)=0)or(kinsoku_type(p)=kinsoku_unused_code)
6512+
or(kinsoku_code(p)=c) then goto done;
65066513
incr(p); if p>255 then p:=0;
65076514
until s=p;
65086515
p:=no_entry;
65096516
end
65106517
else
65116518
begin repeat
6512-
if kinsoku_type(p)=0 then goto done1;
6513-
if kinsoku_code(p)=c then goto done;
6519+
if kinsoku_type(p)=0 then goto done1
6520+
else if (kinsoku_type(p)<>kinsoku_unused_code)and(kinsoku_code(p)=c) then goto done;
65146521
incr(p); if p>255 then p:=0;
65156522
until s=p;
65166523
done1: p:=no_entry;
@@ -6523,8 +6530,8 @@ assign_kinsoku:
65236530
begin p:=cur_chr; scan_int; n:=cur_val; scan_optional_equals; scan_int;
65246531
if is_char_ascii(n) or is_char_kanji(n) then
65256532
begin j:=get_kinsoku_pos(tokanji(n),new_pos);
6526-
if (j<>no_entry)and(cur_val=0)and(global or cur_level=level_one) then
6527-
define(kinsoku_base+j,0,0) { remove the entry from KINSOKU table }
6533+
if (j<>no_entry)and(cur_val=0)and(global or(cur_level=level_one)) then
6534+
define(kinsoku_base+j,kinsoku_unused_code,0) { remove the entry from KINSOKU table }
65286535
else begin
65296536
if j=no_entry then begin
65306537
print_err("KINSOKU table is full!!");

texk/web2c/ptexdir/ptex_version.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
#define PTEX_VERSION "p3.8.0"
1+
#define PTEX_VERSION "p3.8.1"

0 commit comments

Comments
 (0)