summaryrefslogtreecommitdiff
path: root/Build/source/texk
diff options
context:
space:
mode:
authorJérôme Laurens <jerome.laurens@u-bourgogne.fr>2011-06-10 21:21:52 +0000
committerJérôme Laurens <jerome.laurens@u-bourgogne.fr>2011-06-10 21:21:52 +0000
commitd39a25fec754593858c5a518590c5d27651f53c2 (patch)
tree2bb3aabbb3faf42024c232e9594ca473268c3bb2 /Build/source/texk
parent37f6b7b2c32a7857611501709d42ae114370efec (diff)
synctex: 1 bug fix and 1 enhancement to support some luatex change. Only for the synctex command line utility and 3rd party clients
git-svn-id: svn://tug.org/texlive/trunk@22905 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Build/source/texk')
-rw-r--r--Build/source/texk/web2c/synctexdir/synctex_main.c8
-rw-r--r--Build/source/texk/web2c/synctexdir/synctex_parser.c4
-rw-r--r--Build/source/texk/web2c/synctexdir/synctex_parser.h4
-rw-r--r--Build/source/texk/web2c/synctexdir/synctex_parser_local.h4
-rw-r--r--Build/source/texk/web2c/synctexdir/synctex_parser_readme.txt5
-rw-r--r--Build/source/texk/web2c/synctexdir/synctex_parser_utils.c22
-rw-r--r--Build/source/texk/web2c/synctexdir/synctex_parser_utils.h14
-rw-r--r--Build/source/texk/web2c/synctexdir/synctex_parser_version.txt2
8 files changed, 46 insertions, 17 deletions
diff --git a/Build/source/texk/web2c/synctexdir/synctex_main.c b/Build/source/texk/web2c/synctexdir/synctex_main.c
index ff3b6794f9f..ca88b58e79d 100644
--- a/Build/source/texk/web2c/synctexdir/synctex_main.c
+++ b/Build/source/texk/web2c/synctexdir/synctex_main.c
@@ -1,9 +1,11 @@
/*
-Copyright (c) 2008, 2009 jerome DOT laurens AT u-bourgogne DOT fr
+Copyright (c) 2008, 2009, 2010, 2011 jerome DOT laurens AT u-bourgogne DOT fr
This file is part of the SyncTeX package.
-Latest Revision: Wed Jul 1 11:18:13 UTC 2009
+Latest Revision: Fri Jun 10 14:10:17 UTC 2011
+
+Version: 1.15
License:
--------
@@ -144,7 +146,7 @@ static void synctex_usage(const char * error,va_list ap) {
}
fprintf((error?stderr:stdout),
"usage: synctex <subcommand> [options] [args]\n"
- "Synchronize TeXnology command-line client, version 1.2\n\n"
+ "Synchronize TeXnology command-line client, version 1.15\n\n"
"The Synchronization TeXnology by Jérôme Laurens is a new feature of recent TeX engines.\n"
"It allows to synchronize between input and output, which means to\n"
"navigate from the source document to the typeset material and vice versa.\n\n"
diff --git a/Build/source/texk/web2c/synctexdir/synctex_parser.c b/Build/source/texk/web2c/synctexdir/synctex_parser.c
index 397707659c2..d32b5e9eb74 100644
--- a/Build/source/texk/web2c/synctexdir/synctex_parser.c
+++ b/Build/source/texk/web2c/synctexdir/synctex_parser.c
@@ -3,9 +3,9 @@ Copyright (c) 2008, 2009, 2010 , 2011 jerome DOT laurens AT u-bourgogne DOT fr
This file is part of the SyncTeX package.
-Latest Revision: Fri Mar 11 07:39:12 UTC 2011
+Latest Revision: Fri Jun 10 14:10:17 UTC 2011
-Version: 1.13
+Version: 1.15
See synctex_parser_readme.txt for more details
diff --git a/Build/source/texk/web2c/synctexdir/synctex_parser.h b/Build/source/texk/web2c/synctexdir/synctex_parser.h
index 87cff430c90..1bdd703bd03 100644
--- a/Build/source/texk/web2c/synctexdir/synctex_parser.h
+++ b/Build/source/texk/web2c/synctexdir/synctex_parser.h
@@ -3,9 +3,9 @@ Copyright (c) 2008, 2009, 2010 , 2011 jerome DOT laurens AT u-bourgogne DOT fr
This file is part of the SyncTeX package.
-Latest Revision: Fri Mar 11 07:39:12 UTC 2011
+Latest Revision: Fri Jun 10 14:10:17 UTC 2011
-Version: 1.13
+Version: 1.15
See synctex_parser_readme.txt for more details
diff --git a/Build/source/texk/web2c/synctexdir/synctex_parser_local.h b/Build/source/texk/web2c/synctexdir/synctex_parser_local.h
index e4f88295136..ede61f42b2d 100644
--- a/Build/source/texk/web2c/synctexdir/synctex_parser_local.h
+++ b/Build/source/texk/web2c/synctexdir/synctex_parser_local.h
@@ -3,9 +3,9 @@ Copyright (c) 2008, 2009, 2010 , 2011 jerome DOT laurens AT u-bourgogne DOT fr
This file is part of the SyncTeX package.
-Latest Revision: Fri Mar 11 07:39:12 UTC 2011
+Latest Revision: Fri Jun 10 14:10:17 UTC 2011
-Version: 1.13
+Version: 1.15
See synctex_parser_readme.txt for more details
diff --git a/Build/source/texk/web2c/synctexdir/synctex_parser_readme.txt b/Build/source/texk/web2c/synctexdir/synctex_parser_readme.txt
index f6264872264..3d1643df193 100644
--- a/Build/source/texk/web2c/synctexdir/synctex_parser_readme.txt
+++ b/Build/source/texk/web2c/synctexdir/synctex_parser_readme.txt
@@ -116,6 +116,11 @@ causing a void .synctex.gz file to be created even if it was not expected. Repor
- taking output_directory into account
- Replaced FOPEN_WBIN_MODE by FOPEN_W_MODE when opening the text version of the .synctex file.
- Merging with LuaTeX's version of synctex.c
+1.15: Fri Jun 10 14:10:17 UTC 2011
+This concerns the synctex command line tool and 3rd party developers.
+TeX and friends are not concerned by these changes.
+- Bug fixed in _synctex_get_io_mode_name, sometimes the wrong mode was returned
+- Support for LuaTeX convention of './' file prefixing
Acknowledgments:
----------------
diff --git a/Build/source/texk/web2c/synctexdir/synctex_parser_utils.c b/Build/source/texk/web2c/synctexdir/synctex_parser_utils.c
index ee0544389ce..5c544126ae6 100644
--- a/Build/source/texk/web2c/synctexdir/synctex_parser_utils.c
+++ b/Build/source/texk/web2c/synctexdir/synctex_parser_utils.c
@@ -3,9 +3,9 @@ Copyright (c) 2008, 2009, 2010 , 2011 jerome DOT laurens AT u-bourgogne DOT fr
This file is part of the SyncTeX package.
-Latest Revision: Fri Mar 11 07:39:12 UTC 2011
+Latest Revision: Fri Jun 10 14:10:17 UTC 2011
-Version: 1.13
+Version: 1.15
See synctex_parser_readme.txt for more details
@@ -141,6 +141,17 @@ void _synctex_strip_last_path_extension(char * string) {
}
}
+const char * synctex_ignore_leading_dot_slash(const char * name)
+{
+ while(SYNCTEX_IS_DOT(*name) && SYNCTEX_IS_PATH_SEPARATOR(name[1])) {
+ name += 2;
+ while (SYNCTEX_IS_PATH_SEPARATOR(*name)) {
+ ++name;
+ }
+ }
+ return name;
+}
+
/* Compare two file names, windows is sometimes case insensitive... */
synctex_bool_t _synctex_is_equivalent_file_name(const char *lhs, const char *rhs) {
# if SYNCTEX_WINDOWS
@@ -149,6 +160,9 @@ synctex_bool_t _synctex_is_equivalent_file_name(const char *lhs, const char *rhs
* There will be a very serious problem concerning UTF8 because
* not all the characters must be toupper...
* I would like to have URL's instead of filenames. */
+ /* Remove the leading regex '(\./+)*' in both rhs and lhs */
+ lhs = synctex_ignore_leading_dot_slash(lhs);
+ rhs = synctex_ignore_leading_dot_slash(rhs);
next_character:
if(SYNCTEX_IS_PATH_SEPARATOR(*lhs)) {/* lhs points to a path separator */
if(!SYNCTEX_IS_PATH_SEPARATOR(*rhs)) {/* but not rhs */
@@ -156,7 +170,7 @@ next_character:
}
} else if(SYNCTEX_IS_PATH_SEPARATOR(*rhs)) {/* rhs points to a path separator but not lhs */
return synctex_NO;
- } else if(toupper(*lhs) != toupper(*rhs)){/* uppercase do not match */
+ } else {else if(toupper(*lhs) != toupper(*rhs)){/* uppercase do not match */
return synctex_NO;
} else if (!*lhs) {/* lhs is at the end of the string */
return *rhs ? synctex_NO : synctex_YES;
@@ -460,6 +474,6 @@ int _synctex_get_name(const char * output, const char * build_directory, char **
const char * _synctex_get_io_mode_name(synctex_io_mode_t io_mode) {
static const char * synctex_io_modes[4] = {"r","rb","a","ab"};
- unsigned index = (io_mode & synctex_io_gz_mask) + 2 * (io_mode & synctex_io_append_mask);
+ unsigned index = ((io_mode & synctex_io_gz_mask)?1:0) + ((io_mode & synctex_io_append_mask)?2:0);
return synctex_io_modes[index];
}
diff --git a/Build/source/texk/web2c/synctexdir/synctex_parser_utils.h b/Build/source/texk/web2c/synctexdir/synctex_parser_utils.h
index 6d36d738e93..d15a48a8207 100644
--- a/Build/source/texk/web2c/synctexdir/synctex_parser_utils.h
+++ b/Build/source/texk/web2c/synctexdir/synctex_parser_utils.h
@@ -3,9 +3,9 @@ Copyright (c) 2008, 2009, 2010, 2011 jerome DOT laurens AT u-bourgogne DOT fr
This file is part of the SyncTeX package.
-Latest Revision: Fri Mar 11 07:39:12 UTC 2011
+Latest Revision: Fri Jun 10 14:10:17 UTC 2011
-Version: 1.13
+Version: 1.15
See synctex_parser_readme.txt for more details
@@ -66,7 +66,13 @@ extern "C" {
# else
# define SYNCTEX_IS_PATH_SEPARATOR(c) ('/' == c)
# endif
-
+
+# if _WIN32
+# define SYNCTEX_IS_DOT(c) ('.' == c)
+# else
+# define SYNCTEX_IS_DOT(c) ('.' == c)
+# endif
+
/* This custom malloc functions initializes to 0 the newly allocated memory.
* There is no bzero function on windows. */
void *_synctex_malloc(size_t size);
@@ -126,6 +132,8 @@ int _synctex_get_name(const char * output, const char * build_directory, char **
/* returns the correct mode required by fopen and gzopen from the given io_mode */
const char * _synctex_get_io_mode_name(synctex_io_mode_t io_mode);
+const char * synctex_ignore_leading_dot_slash(const char * name);
+
#ifdef __cplusplus
}
#endif
diff --git a/Build/source/texk/web2c/synctexdir/synctex_parser_version.txt b/Build/source/texk/web2c/synctexdir/synctex_parser_version.txt
index 9f76d37b710..07fe6f6c9fd 100644
--- a/Build/source/texk/web2c/synctexdir/synctex_parser_version.txt
+++ b/Build/source/texk/web2c/synctexdir/synctex_parser_version.txt
@@ -1 +1 @@
-1.13 \ No newline at end of file
+1.15 \ No newline at end of file