summaryrefslogtreecommitdiff
path: root/Build/source/texk/web2c/eptexdir
diff options
context:
space:
mode:
authorPeter Breitenlohner <peb@mppmu.mpg.de>2015-07-04 11:28:05 +0000
committerPeter Breitenlohner <peb@mppmu.mpg.de>2015-07-04 11:28:05 +0000
commit1b54746a7a7087af138fe21c002cd967fdaf6597 (patch)
tree7b2910c2dc0bf60f055f7adba0f25fc8b7b42b2a /Build/source/texk/web2c/eptexdir
parent4ebe01e691e6b0b4d0373f42e02118c6641573ed (diff)
e-(u)pTeX: Add \pdfmdfivesum as in pdfTeX (from Hironori Kitagawa)
git-svn-id: svn://tug.org/texlive/trunk@37756 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Build/source/texk/web2c/eptexdir')
-rw-r--r--Build/source/texk/web2c/eptexdir/ChangeLog7
-rw-r--r--Build/source/texk/web2c/eptexdir/am/eptex.am4
-rw-r--r--Build/source/texk/web2c/eptexdir/eptex.defines1
-rw-r--r--Build/source/texk/web2c/eptexdir/eptex.ech2
-rw-r--r--Build/source/texk/web2c/eptexdir/eptex_version.h2
-rw-r--r--Build/source/texk/web2c/eptexdir/pdfutils.ch37
6 files changed, 46 insertions, 7 deletions
diff --git a/Build/source/texk/web2c/eptexdir/ChangeLog b/Build/source/texk/web2c/eptexdir/ChangeLog
index 5e396f88c43..22511983d84 100644
--- a/Build/source/texk/web2c/eptexdir/ChangeLog
+++ b/Build/source/texk/web2c/eptexdir/ChangeLog
@@ -1,3 +1,10 @@
+2015-07-02 Hironori Kitagawa <h_kitagawa2001@yahoo.co.jp>
+
+ * am/eptex.am: Add libmd5.a.
+ * pdfutils.ch: Add primitive \pdfmdfivesum to e-(u)pTeX.
+ * eptex.defines: Add getmd5sum().
+ * eptex.ech, eptex_version.h: Change version to 150702.
+
2015-06-22 Peter Breitenlohner <peb@mppmu.mpg.de>
* am/eptx.am: Use $(tie_c) and $(tie_m).
diff --git a/Build/source/texk/web2c/eptexdir/am/eptex.am b/Build/source/texk/web2c/eptexdir/am/eptex.am
index b3837a3a4ea..6a50e2ac08c 100644
--- a/Build/source/texk/web2c/eptexdir/am/eptex.am
+++ b/Build/source/texk/web2c/eptexdir/am/eptex.am
@@ -16,10 +16,10 @@ eptex_tests = eptexdir/eptriptest
EXTRA_DIST += $(eptex_tests)
-eptex_CPPFLAGS = $(PTEXENC_INCLUDES) $(AM_CPPFLAGS)
+eptex_CPPFLAGS = $(PTEXENC_INCLUDES) $(AM_CPPFLAGS) -I$(srcdir)/libmd5
# With --enable-ipc, e-pTeX may need to link with -lsocket.
-eptex_LDADD = libkanji.a $(pproglib) $(PTEXENC_LIBS) $(LDADD) $(ipc_socketlibs)
+eptex_LDADD = libkanji.a $(pproglib) $(PTEXENC_LIBS) $(LDADD) $(ipc_socketlibs) libmd5.a
eptex_DEPENDENCIES = libkanji.a $(pproglib) $(PTEXENC_DEPEND) $(default_dependencies)
# e-pTeX C sources
diff --git a/Build/source/texk/web2c/eptexdir/eptex.defines b/Build/source/texk/web2c/eptexdir/eptex.defines
index 0d288a3e6f8..8b4e16e0a95 100644
--- a/Build/source/texk/web2c/eptexdir/eptex.defines
+++ b/Build/source/texk/web2c/eptexdir/eptex.defines
@@ -41,3 +41,4 @@
@define procedure getfilemoddate();
@define procedure getfilesize();
@define procedure getfiledump();
+@define procedure getmd5sum();
diff --git a/Build/source/texk/web2c/eptexdir/eptex.ech b/Build/source/texk/web2c/eptexdir/eptex.ech
index 96d12f9154d..b432bda6c48 100644
--- a/Build/source/texk/web2c/eptexdir/eptex.ech
+++ b/Build/source/texk/web2c/eptexdir/eptex.ech
@@ -19,7 +19,7 @@
@y
@d eTeX_version_string=='-2.6' {current \eTeX\ version}
@#
-@d epTeX_version_string=='-141210'
+@d epTeX_version_string=='-150702'
@z
@x e-pTeX: banner
diff --git a/Build/source/texk/web2c/eptexdir/eptex_version.h b/Build/source/texk/web2c/eptexdir/eptex_version.h
index abf14fd3be5..a5ca0955da0 100644
--- a/Build/source/texk/web2c/eptexdir/eptex_version.h
+++ b/Build/source/texk/web2c/eptexdir/eptex_version.h
@@ -1 +1 @@
-#define EPTEX_VERSION "141210"
+#define EPTEX_VERSION "150702"
diff --git a/Build/source/texk/web2c/eptexdir/pdfutils.ch b/Build/source/texk/web2c/eptexdir/pdfutils.ch
index fa978ac6348..5667fe427a2 100644
--- a/Build/source/texk/web2c/eptexdir/pdfutils.ch
+++ b/Build/source/texk/web2c/eptexdir/pdfutils.ch
@@ -14,6 +14,9 @@
%%
%% \pdfshellescape: by doraTeX's request
%%
+%% \pdfmdfivesum: by Akira's request
+%% As \pdfstrcmp, Japanese characters will be always encoded in UTF-8 in
+%% \pdfmdfivesum {...}. (no conversion for \pdfmdfivesum file <filename>)
@x
@* \[12] Displaying boxes.
@@ -69,8 +72,9 @@ pdf_page_height_code: print_esc("pdfpageheight");
@d pdf_creation_date_code = etex_convert_base+2 {command code for \.{\\pdfcreationdate}}
@d pdf_file_mod_date_code = etex_convert_base+3 {command code for \.{\\pdffilemoddate}}
@d pdf_file_size_code = etex_convert_base+4 {command code for \.{\\pdffilesize}}
-@d pdf_file_dump_code = etex_convert_base+5 {command code for \.{\\pdffiledump}}
-@d etex_convert_codes=etex_convert_base+6 {end of \eTeX's command codes}
+@d pdf_mdfive_sum_code = etex_convert_base+5 {command code for \.{\\pdfmdfivesum}}
+@d pdf_file_dump_code = etex_convert_base+6 {command code for \.{\\pdffiledump}}
+@d etex_convert_codes=etex_convert_base+7 {end of \eTeX's command codes}
@z
@x
@@ -81,6 +85,7 @@ pdf_page_height_code: print_esc("pdfpageheight");
pdf_creation_date_code: print_esc("pdfcreationdate");
pdf_file_mod_date_code: print_esc("pdffilemoddate");
pdf_file_size_code: print_esc("pdffilesize");
+ pdf_mdfive_sum_code: print_esc("pdfmdfivesum");
pdf_file_dump_code: print_esc("pdffiledump");
@z
@@ -104,6 +109,7 @@ we have to create a temporary string that is destroyed immediately after.
@!save_scanner_status:small_number; {|scanner_status| upon entry}
@!save_def_ref: pointer; {|def_ref| upon entry, important if inside `\.{\\message}'}
@!save_warning_index: pointer;
+@!bool: boolean; {temp boolean}
@!u: str_number; {saved current string string}
@!s: str_number; {first temp string}
@!i: integer;
@@ -179,7 +185,30 @@ pdf_file_size_code:
restore_cur_string;
return;
end;
-
+pdf_mdfive_sum_code:
+ begin
+ save_scanner_status := scanner_status;
+ save_warning_index := warning_index;
+ save_def_ref := def_ref;
+ save_cur_string;
+ bool := scan_keyword("file");
+ scan_pdf_ext_toks;
+ if bool then s := tokens_to_string(def_ref)
+ else begin
+ isprint_utf8:=true; s := tokens_to_string(def_ref); isprint_utf8:=false;
+ end;
+ delete_token_ref(def_ref);
+ def_ref := save_def_ref;
+ warning_index := save_warning_index;
+ scanner_status := save_scanner_status;
+ b := pool_ptr;
+ getmd5sum(s, bool);
+ link(garbage) := str_toks(b);
+ flush_str(s);
+ ins_list(link(temp_head));
+ restore_cur_string;
+ return;
+ end;
pdf_file_dump_code:
begin
save_scanner_status := scanner_status;
@@ -354,6 +383,8 @@ primitive("pdffilemoddate",convert,pdf_file_mod_date_code);@/
@!@:pdf_file_mod_date_}{\.{\\pdffilemoddate} primitive@>
primitive("pdffilesize",convert,pdf_file_size_code);@/
@!@:pdf_file_size_}{\.{\\pdffilesize} primitive@>
+primitive("pdfmdfivesum",convert,pdf_mdfive_sum_code);@/
+@!@:pdf_mdfive_sum_}{\.{\\pdfmdfivesum} primitive@>
primitive("pdffiledump",convert,pdf_file_dump_code);@/
@!@:pdf_file_dump_}{\.{\\pdffiledump} primitive@>
primitive("pdfsavepos",extension,pdf_save_pos_node);@/