summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xBuild/source/texk/texlive/linked_scripts/latexmk/latexmk.pl299
-rw-r--r--Master/texmf-dist/doc/support/latexmk/CHANGES9
-rw-r--r--Master/texmf-dist/doc/support/latexmk/README14
-rw-r--r--Master/texmf-dist/doc/support/latexmk/extra-scripts/README149
-rw-r--r--Master/texmf-dist/doc/support/latexmk/latexmk.pdfbin79070 -> 79391 bytes
-rw-r--r--Master/texmf-dist/doc/support/latexmk/latexmk.txt846
-rwxr-xr-xMaster/texmf-dist/scripts/latexmk/latexmk.pl35
-rw-r--r--Master/texmf/doc/man/man1/latexmk.127
-rw-r--r--Master/texmf/doc/man/man1/latexmk.man1.pdfbin88980 -> 89821 bytes
9 files changed, 658 insertions, 621 deletions
diff --git a/Build/source/texk/texlive/linked_scripts/latexmk/latexmk.pl b/Build/source/texk/texlive/linked_scripts/latexmk/latexmk.pl
index 2ea0e023e8f..7372174cc9f 100755
--- a/Build/source/texk/texlive/linked_scripts/latexmk/latexmk.pl
+++ b/Build/source/texk/texlive/linked_scripts/latexmk/latexmk.pl
@@ -108,8 +108,8 @@ use warnings;
$my_name = 'latexmk';
$My_name = 'Latexmk';
-$version_num = '4.13';
-$version_details = "$My_name, John Collins, 13 January 2010";
+$version_num = '4.16';
+$version_details = "$My_name, John Collins, 10 May 2010";
use Config;
@@ -119,7 +119,7 @@ use FileHandle;
use File::Find;
use Cwd; # To be able to change cwd
use Cwd "chdir"; # Ensure $ENV{PWD} tracks cwd
-use Digest;
+use Digest::MD5;
#use strict;
@@ -176,47 +176,38 @@ else {
## 5. Parsing of log file instead of source file is used to
## obtain dependencies, by default.
##
-## Modification log from 25 Nov 2009 onwards in detail
+## Modification log from 22 Jan 2010 onwards in detail
##
-## 13 Jan 2010, John Collins V. 4.13
-## 27 Dec 2009, John Collins Correct position of inserting bbl into list
-## of generated extensions.
-## Correct clean_up. It stopped deleting aux
-## file.
-## $bibtex_use defaults to 1.
-## 15 Dec 2009, John Collins Option not to do bibtex
-## (to allow for case that bbl files
-## are available, but no bibtex).
-## 27 Nov 2009, John Collins Solve problem that changes in \include
-## files weren't reflected in changes
-## in bibtex source files.
-## Remove excess recalculations of md5 in
-## startup and when initializing rule
-## from fdb_latexmk file.
-## Fdb_latexmk now has data for all rules
-## need for making target files,
-## not just rules accessible from primary
-## rules.
-## 26 Nov 2009, John Collins In testing for changes, when filetime
-## has changed, but file is unchanged,
-## update filetime in rule.
-## This saves excessive md5 calculations.
-## 25 Nov 2009, John Collins Fixed issue with fdb_get and 1-second
-## granularity of file timestamps.
-## The issue was that if runs of
-## latex (etc) occur within the
-## 1-second time granularity, file
-## contents can change even though
-## the file's time and size are
-## unchanged, falsifying an
-## assumption made by fdb_get, but
-## only when the old time is the
-## same as the run time of a command
-## that uses the file.
-## Avoided excess md5 calculations at
-## startup.
+## 10 May 2010, John Collins Deal with filenames in log file that are
+## messed up by pdfTeX warnings not preceeded
+## by a new line
+## 18 Apr 2010, John Collins Clean up comment from previous mod.
+## 16 Apr 2010, John Collins V. 4.15c. Correct line wrapping issue.
+## 12 Apr 2010, John Collins V. 4.15b. Change
+## use Digest;
+## to
+## use Digest::MD5;
+## for TeX Live compatibility. Needed also to change
+## my $md5 = Digest->MD5;
+## to
+## my $md5 = Digest::MD5->new;
##
-## 1998-2009, John Collins. Many improvements and fixes.
+## 8 Apr 2010, John Collins V. 4.15a. Better defaults for system
+## configuration file under cygwin
+## 7 Apr 2010, John Collins V. 4.15: Change defaults on
+## $latex_silent_switch and $pdflatex_silent_switch
+## to make them TeXLive compatible always
+## 26 Mar 2010, John Collins V. 4.14b. Make sure md5 calc
+## doesn't bomb out on directory
+## Parse log file: if apparent dependent
+## is directory, remove it from list.
+## 27 Feb 2010, John Collins V. 4.14a. List failed primaries
+## 22 Jan 2010, John Collins V. 4.14. Try to fix problem that with -pvc
+## failure on latex should force a wait until
+## a user file is changed. But latexmk keeps
+## doing dvips, dvipdf, etc.
+##
+## 1998-2010, John Collins. Many improvements and fixes.
## See CHANGE-log.txt for full list, and CHANGES for summary
##
## Modified by Evan McLean (no longer available for support)
@@ -442,6 +433,8 @@ $new_viewer_always = 0; # If 1, always open a new viewer in pvc mode.
$quote_filenames = 1; # Quote filenames in external commands
+
+
#########################################################################
################################################################
@@ -502,10 +495,6 @@ if ( $^O eq "MSWin32" ) {
$search_path_separator = ';'; # Separator of elements in search_path
- # For both fptex and miktex, the following makes error messages explicit:
- $latex_silent_switch = '-interaction=batchmode -c-style-errors';
- $pdflatex_silent_switch = '-interaction=batchmode -c-style-errors';
-
# For a pdf-file, "start x.pdf" starts the pdf viewer associated with
# pdf files, so no program name is needed:
$pdf_previewer = 'start %O %S';
@@ -601,18 +590,21 @@ elsif ( $^O eq "cygwin" ) {
## List of possibilities for the system-wide initialization file.
## The first one found (if any) is used.
- ## We can stay with MSWin files here, since perl understands them,
- @rc_system_files = ( 'C:/latexmk/LatexMk' );
+ ## We could stay with MSWin files here, since cygwin perl understands them
+ ## @rc_system_files = ( 'C:/latexmk/LatexMk' );
+ ## But they are deprecated in v. 1.7. So use the UNIX version, prefixed
+ ## with a cygwin equivalent of the MSWin location
+ @rc_system_files =
+ ( '/cygdrive/c/latexmk/LatexMk',
+ '/opt/local/share/latexmk/LatexMk',
+ '/usr/local/share/latexmk/LatexMk',
+ '/usr/local/lib/latexmk/LatexMk' );
$search_path_separator = ';'; # Separator of elements in search_path
# This is tricky. The search_path_separator depends on the kind
# of executable: native NT v. cygwin.
# So the user will have to override this.
- # For both fptex and miktex, the following makes error messages explicit:
- $latex_silent_switch = '-interaction=batchmode -c-style-errors';
- $pdflatex_silent_switch = '-interaction=batchmode -c-style-errors';
-
# We will assume that files can be viewed by native NT programs.
# Then we must fix the start command/directive, so that the
# NT-native start command of a cmd.exe is used.
@@ -1562,13 +1554,11 @@ if ( $pdf_mode == 2 ) {
# Make convenient forms for lookup.
# Extensions always have period.
-# Convert @generated_exts to a hash for ease of look up, with exts
-# preceeded by a '.'
-# %generated_exts_all is used in analyzing file changes, to
-# distinguish changes in user files from changes in generated files.
+# Convert @generated_exts to a hash for ease of look up and deletion
+# Keep extension without period!
%generated_exts_all = ();
foreach (@generated_exts ) {
- $generated_exts_all{".$_"} = 1;
+ $generated_exts_all{$_} = 1;
}
$quell_uptodate_msgs = $silent;
@@ -1581,8 +1571,8 @@ $quell_uptodate_msgs = $silent;
#?? Unneeded now: $save_bibtex_mode = $bibtex_mode;
$failure_count = 0;
-$last_failed = 0; # Flag whether failed on making last file
- # This is used for showing suitable error diagnostics
+@failed_primaries = ();
+
FILE:
foreach $filename ( @file_list )
{
@@ -1810,10 +1800,7 @@ continue {
}
if ( ($failure > 0) || ($error_message_count > 0) ) {
$failure_count ++;
- $last_failed = 1;
- }
- else {
- $last_failed = 0;
+ push @failed_primaries, $filename;
}
&ifcd_popd;
}
@@ -1825,11 +1812,13 @@ if ( $do_cd && ($#dir_stack > -1) ) {
}
if ($failure_count > 0) {
- if ( $last_failed <= 0 ) {
- # Error occured, but not on last file, so
- # user may not have seen error messages
+ if ( $#file_list > 0 ) {
+ # Error occured, but multiple files were processed, so
+ # user may not have seen all the error messages
warn "\n------------\n";
- warn "$My_name: Some operations failed.\n";
+ show_array(
+ "$My_name: Some operations failed, for the following tex file(s)",
+ @failed_primaries);
}
if ( !$force_mode ) {
warn "$My_name: Use the -f option to force complete processing.\n";
@@ -2344,6 +2333,7 @@ sub make_preview_continuousB {
# Set $first_time to flag first run (to save unnecessary diagnostics)
CHANGE:
for (my $first_time = 1; 1; $first_time = 0 ) {
+ my %rules_to_watch = %requested_filerules;
$updated = 0;
$failure = 0;
$failure_msg = '';
@@ -2365,11 +2355,22 @@ CHANGE:
if ( !$failure_msg ) {
$failure_msg = 'Failure to make the files correctly';
}
+ @pre_primary = (); # Array of rules
+ @post_primary = (); # Array of rules
+ @one_time = (); # Array of rules
+ &rdb_classify_rules( \%possible_primaries, keys %requested_filerules );
# There will be files changed during the run that are irrelevant.
# We need to wait for the user to change the files.
- # So set the GENERATED files as up-to-date
+
+ # So set the GENERATED files from (pdf)latex as up-to-date:
rdb_for_some( [keys %current_primaries], \&rdb_update_gen_files );
+ # And don't watch for changes for post_primary rules (ps and pdf
+ # from dvi, etc haven't been run after an error in (pdf)latex, so
+ # are out-of-date by filetime criterion, but they should not be run
+ # until after another (pdf)latex run:
+ foreach (@post_primary) { delete $rules_to_watch{$_}; }
+
$failure_msg =~ s/\s*$//; #Remove trailing space
warn "$My_name: $failure_msg\n",
" ==> You will need to change a source file before I do another run <==\n";
@@ -2418,7 +2419,7 @@ CHANGE:
WAIT: while (1) {
sleep($sleep_time);
if ($have_break) { last WAIT; }
- if ( rdb_new_changes(@targets) ) {
+ if ( rdb_new_changes(keys %rules_to_watch) ) {
if (!$silent) {
warn "$My_name: Need to remake files.\n";
&rdb_diagnose_changes( ' ' );
@@ -2861,13 +2862,14 @@ sub parse_logB {
s/[\n\r]*$//;
# Handle wrapped lines:
# They are lines brutally broken at exactly $log_wrap chars
- # excluding line-end. The TeX program adds an EXTRA
- # end-of-line character whenever a line gets to $log_wrap
- # characters. So we recover the unwrapped line(s) simply
- # by deleting the end-of-line following a line of exactly
- # $log_wrap characters.
+ # excluding line-end. Sometimes a line $log_wrap chars
+ # long is an ordinary line, sometimes it is part of a line
+ # that was wrapped. To handle all cases, I keep both
+ # options open by putting the line into @lines before
+ # and after appending the next line:
my $len = length($_);
while ( ($len == $log_wrap) && !eof($log_file) ) {
+ push @lines, $_;
my $extra = <$log_file>;
$extra =~ s/[\n\r]*$//;
$len = length($extra);
@@ -2892,10 +2894,32 @@ sub parse_logB {
my $delegated_output = ""; # and output file. (Don't put in
# data structure until block is ended.)
my %new_conversions = ();
+ my @retries = ();
LINE:
- while( $line <= $#lines ) {
- $_ = $lines[$line];
- $line ++;
+ while( ($line <= $#lines) || ($#retries > -1) ) {
+ if ($#retries > -1) {
+ $_ = pop @retries;
+ }
+ else {
+ $_ = $lines[$line];
+ $line ++;
+ }
+ if ( /^! pdfTeX warning/ || /^pdfTeX warning/ ) {
+ # This kind of warning is produced by some versions of pdftex
+ # or produced by my reparse of warnings from other
+ # versions.
+ next;
+ }
+ elsif ( /^(.+)(pdfTeX warning.*)$/ ) {
+ # Line contains a pdfTeX warnings that may have been
+ # inserted directly after other material without an
+ # intervening new line. I think pdfTeX always inserts a
+ # newline after the warning. (From examination of source
+ # code.)
+ push @retries, $1;
+ # But continue parsing the original line, in case it was a
+ # misparse, e.g., of a filename ending in 'pdfTeX';
+ }
if ( $line == 1 ){
if ( /^This is / ) {
# First line OK
@@ -3196,7 +3220,14 @@ LINE:
CANDIDATE:
foreach my $candidate (keys %dependents) {
my $code = $dependents{$candidate};
- if ( -e $candidate ) {
+ if ( -d $candidate ) {
+ # If $candidate is directory, it was presumably found from a
+ # mis-parse, so remove it from the list. (Misparse can
+ # arise, for example from a mismatch of latexmk's $log_wrap
+ # value and texmf.cnf value of max_print_line.)
+ delete $dependents{$candidate};
+ }
+ elsif ( -e $candidate ) {
if ( exists $generated_log{$candidate} ){
$dependents{$candidate} = 6;
}
@@ -5165,7 +5196,7 @@ sub rdb_file_change1 {
#?? print "FC1 '$rule':$file $$Pout_of_date TK=$$Ptest_kind\n";
#?? print " OLD $$Ptime, $$Psize, $$Pmd5\n",
#?? " New $new_time, $new_size, $new_md5\n";
- my $ext = ext( $file );
+ my $ext_no_period = ext_no_period( $file );
if ( ($new_size < 0) && ($$Psize >= 0) ) {
# print "Disappeared '$file' in '$rule'\n";
push @disappeared, $file;
@@ -5189,7 +5220,7 @@ sub rdb_file_change1 {
#?? print "FC1: changed $file: ($new_size != $$Psize) $new_md5 ne $$Pmd5)\n";
push @changed, $file;
$$Pout_of_date = 1;
- if ( ! exists $generated_exts_all{$ext} ) {
+ if ( ! exists $generated_exts_all{$ext_no_period} ) {
$$Pout_of_date_user = 1;
}
}
@@ -5198,7 +5229,7 @@ sub rdb_file_change1 {
$$Ptime = $new_time;
}
if ( ( ($$Ptest_kind == 2) || ($$Ptest_kind == 3) )
- && (! exists $generated_exts_all{$ext} )
+ && (! exists $generated_exts_all{$ext_no_period} )
&& ( $new_time > $dest_mtime )
) {
#?? print "FC1: changed $file: ($new_time > $dest_mtime)\n";
@@ -5665,11 +5696,10 @@ sub rdb_file_exists {
#************************************************************
sub rdb_update_gen_files {
- # Call: fdb_updateA
# Assumes rule context. Update source files of rule to current state.
rdb_do_files(
sub{
- if ( exists $generated_exts_all{ ext($file) } ) {&rdb_update1;}
+ if ( exists $generated_exts_all{ ext_no_period($file) } ) {&rdb_update1;}
}
);
} #END rdb_update_gen_files
@@ -5952,7 +5982,7 @@ sub get_time_size_raw
sub get_checksum_md5 {
my $source = shift;
my $input = new FileHandle;
- my $md5 = Digest->MD5;
+ my $md5 = Digest::MD5->new;
my $ignore_pattern = '';
#warn "======= GETTING MD5: $source\n";
@@ -5960,6 +5990,10 @@ sub get_checksum_md5 {
# STDIN:
open( $input, '-' );
}
+ elsif ( -d $source ) {
+ # We won't use checksum for directory
+ return 0;
+ }
else {
open( $input, '<', $source )
or return 0;
@@ -5986,93 +6020,6 @@ sub get_checksum_md5 {
}
#************************************************************
-
-#?? OBSOLETE
-# Find file with default extension
-# Usage: find_file_ext( name, default_ext, ref_to_array_search_path)
-sub find_file_ext
-#?? Need to use kpsewhich, if possible. Leave to find_file?
-{
- my $full_filename = shift;
- my $ext = shift;
- my $ref_search_path = shift;
- my $full_filename1 = &find_file($full_filename, $ref_search_path, '1');
-#print "Finding \"$full_filename\" with ext \"$ext\" ... ";
- if (( $full_filename1 eq '' ) || ( ! -e $full_filename1 ))
- {
- my $full_filename2 =
- &find_file("$full_filename.$ext",$ref_search_path,'1');
- if (( $full_filename2 ne '' ) && ( -e $full_filename2 ))
- {
- $full_filename = $full_filename2;
- }
- else
- {
- $full_filename = $full_filename1;
- }
- }
- else
- {
- $full_filename = $full_filename1;
- }
-#print "Found \"$full_filename\".\n";
- return $full_filename;
-}
-
-#************************************************************
-#?? OBSOLETE
-# given filename and path, return full name of file, or die if none found.
-# when force_include_mode=1, only warn if an include file was not
-# found, and return 0 (PvdS).
-# Usage: find_file(name, ref_to_array_search_path, warn_on_continue)
-sub find_file
-#?? Need to use kpsewhich, if possible
-{
- my $name = $_[0];
- my $ref_path = $_[1];
- my $dir;
- if ( $name =~ /^\// )
- {
- #Aboslute pathname (by UNIX standards)
- if ( (!-e $name) && ( $_[2] eq '' ) ) {
- if ($force_include_mode) {
- warn "$My_name: Could not find file [$name]\n";
- }
- else {
- die "$My_name: Could not find file [$name]\n";
- }
- }
- return $name;
- }
- # Relative pathname
- foreach $dir ( @{$ref_path} )
- {
-#warn "\"$dir\", \"$name\"\n";
- if (-e "$dir/$name")
- {
- return("$dir/$name");
- }
- }
- if ($force_include_mode)
- {
- if ( $_[2] eq '' )
- {
- warn "$My_name: Could not find file [$name] in path [@{$ref_path}]\n";
- warn " assuming in current directory (./$name)\n";
- }
- return("./$name");
- }
- else
- {
- if ( $_[2] ne '' )
- {
- return('');
- }
-# warn "\"$name\", \"$ref_path\", \"$dir\"\n";
- die "$My_name: Could not find file [$name] in path [@{$ref_path}]\n";
- }
-}
-
#************************************************************
sub find_file1 {
@@ -6373,6 +6320,16 @@ sub ext {
#************************************************************
+sub ext_no_period {
+ # Return extension of filename. Extension excludes the period
+ my $file_name = $_[0];
+ my ($base_name, $path, $ext) = fileparseA( $file_name );
+ $ext =~ s/^\.//;
+ return $ext;
+ }
+
+#************************************************************
+
sub fileparseA {
# Like fileparse but replace $path for current dir ('./' or '.\') by ''
# Also default second argument to get normal extension.
diff --git a/Master/texmf-dist/doc/support/latexmk/CHANGES b/Master/texmf-dist/doc/support/latexmk/CHANGES
index db7c20270b3..fcd92f4ba7c 100644
--- a/Master/texmf-dist/doc/support/latexmk/CHANGES
+++ b/Master/texmf-dist/doc/support/latexmk/CHANGES
@@ -156,3 +156,12 @@ From v. 4.15b to v. 4.15c
dependent file when it analyzed a .log file. (It incorrectly
treated some lines of length 79 as being wrapped.)
+From v. 4.15b to v. 4.16
+ Solved another problem with misparsed log files. Some versions of
+ pdflatex fail to preceed some warning messages by a new line.
+ Thus these warning messages sometimes appear to be part of a
+ filename.
+ Updated documentation to mention previously undocumented feature
+ about the use of temporary files in making ps and pdf files.
+
+
diff --git a/Master/texmf-dist/doc/support/latexmk/README b/Master/texmf-dist/doc/support/latexmk/README
index 6f4560b28df..a7b85ae2b10 100644
--- a/Master/texmf-dist/doc/support/latexmk/README
+++ b/Master/texmf-dist/doc/support/latexmk/README
@@ -1,5 +1,5 @@
-Latexmk, version 4.15c, 18 April 2010
--------------------------------------
+Latexmk, version 4.16, 10 May 2010
+----------------------------------
Latexmk completely automates the process of generating a LaTeX document.
Essentially, it is a highly specialized cousin of the general make
@@ -21,9 +21,11 @@ for a run down on what latexmk does and what all the features are. A copy
of the fast help that can be seen by doing "latexmk -h" is at the end of
this file.
-The latexmk perl script was modified by Evan McLean from the original
-script called "go" written by David J. Musliner. Now it is supported
-by
+Latexmk is a perl script. It is licensed under the GNU General Public
+License.
+
+It was modified by Evan McLean from the original script called "go"
+written by David J. Musliner. Now it is supported by
John Collins
Physics Department
@@ -89,7 +91,7 @@ I hope you find this useful.
John Collins
---------------------------- "latexmk -h" ----------------------------
-Latexmk 4.15c: Automatic LaTeX document generation routine
+Latexmk 4.16: Automatic LaTeX document generation routine
Usage: latexmk [latexmk_options] [filename ...]
diff --git a/Master/texmf-dist/doc/support/latexmk/extra-scripts/README1 b/Master/texmf-dist/doc/support/latexmk/extra-scripts/README1
index aeb5e615e49..91ad908c9b0 100644
--- a/Master/texmf-dist/doc/support/latexmk/extra-scripts/README1
+++ b/Master/texmf-dist/doc/support/latexmk/extra-scripts/README1
@@ -2,7 +2,7 @@ Auxiliary scripts for latexmk
=============================
John Collins (collins at phys.psu.edu)
-20 Jan 2007
+19 Apr 2010
Latexmk can be configured to use different programs than the standard
ones to perform its tasks. If a user finds that the default behavior
@@ -110,31 +110,34 @@ needs you to do to make the script executable.
dvipdfm_call.bat
dvipdfmx_call.bat
- Scripts for using dvipdfm or dvipdfmx from latexmk. They solve
- the problem that when latexmk converts dvi files to pdf, it
- assumes that it is using dvipdf. If you reconfigure latexmk to
- use dvipdfm or dvipdfmx, the command line arguments are wrong, and
- you will get an error message. The scripts dvipdfm_call and
- dvipdfmx_call do the appropriate conversion of the command-line
- arguments.
+ Scripts for using dvipdfm or dvipdfmx with the same command-line
+ syntax as dvipdf.
- For Unix-like systems, including linux and Mac OS-X, use the
- scripts dvipdfm_call and dvipdfmx_call.
- For MS-Windows systems use the batch files dvipdfm_call.bat and
- dvipdfmx_call.bat.
+ To get latexmk to use dvipdfm or dvipdfmx to convert dvi files to
+ pdf files, it USED to be necessary to configure latexmk to use one
+ of these scripts. But since v. 4.01, latexmk has more flexible
+ configuration methods. Currently, to use dvipdfm, just put the
+ following in one of latexmk's initialization files (e.g.,
+ ~/.latexmkrc):
- To use these scripts: install the scripts/batch files as
- appropriate, and configure one of latexmk's initialization files
- to use the script you need. The correct configuration will have
- one of the lines
+ $dvipdf = "dvipdfm %O -o %D %S";
- $dvipdf = 'dvipdfm_call';
- or
- $dvipdf = 'dvipdfmx_call';
+ (To use dvipdfmx, just change the string dvipdfm to dvipdfmx.)
+ The command specified here is used when latexmk is requested to
+ make pdf files by conversion from dvi files, e.g., by the
+ latexmk's command-line option -pdfdvi.
- Then you will need to set to use the dvipdf method of making pdf
- files, either on latexmk's command line, or in a configuration
- file with the line
+ But I leave the scripts here. For OLD versions of latexmk, you
+ would have used the configuration line
- $pdf_mode = 3;
+ $dvipdf = 'dvipdfm_call'; #OBSOLETE
+ or
+ $dvipdf = 'dvipdfmx_call'; #OBSOLETE
+
+ These still work, but they are obsolete.
+
+ For Unix-like systems, including linux and Mac OS-X, use the
+ scripts dvipdfm_call and dvipdfmx_call.
+ For MS-Windows systems use the batch files dvipdfm_call.bat and
+ dvipdfmx_call.bat.
diff --git a/Master/texmf-dist/doc/support/latexmk/latexmk.pdf b/Master/texmf-dist/doc/support/latexmk/latexmk.pdf
index 45273f4f572..5b6a147d6be 100644
--- a/Master/texmf-dist/doc/support/latexmk/latexmk.pdf
+++ b/Master/texmf-dist/doc/support/latexmk/latexmk.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/support/latexmk/latexmk.txt b/Master/texmf-dist/doc/support/latexmk/latexmk.txt
index 3a974403443..1ba8104b662 100644
--- a/Master/texmf-dist/doc/support/latexmk/latexmk.txt
+++ b/Master/texmf-dist/doc/support/latexmk/latexmk.txt
@@ -127,7 +127,7 @@ LATEXMK OPTIONS AND ARGUMENTS ON COMMAND LINE
- 18 April 2010 2
+ 10 May 2010 2
@@ -193,7 +193,7 @@ LATEXMK(1L) LATEXMK(1L)
- 18 April 2010 3
+ 10 May 2010 3
@@ -259,7 +259,7 @@ LATEXMK(1L) LATEXMK(1L)
- 18 April 2010 4
+ 10 May 2010 4
@@ -325,7 +325,7 @@ LATEXMK(1L) LATEXMK(1L)
- 18 April 2010 5
+ 10 May 2010 5
@@ -391,7 +391,7 @@ LATEXMK(1L) LATEXMK(1L)
- 18 April 2010 6
+ 10 May 2010 6
@@ -457,7 +457,7 @@ LATEXMK(1L) LATEXMK(1L)
- 18 April 2010 7
+ 10 May 2010 7
@@ -523,7 +523,7 @@ LATEXMK(1L) LATEXMK(1L)
- 18 April 2010 8
+ 10 May 2010 8
@@ -589,7 +589,7 @@ LATEXMK(1L) LATEXMK(1L)
- 18 April 2010 9
+ 10 May 2010 9
@@ -655,7 +655,7 @@ CONFIGURATION/INITIALIZATION (RC) FILES
- 18 April 2010 10
+ 10 May 2010 10
@@ -722,7 +722,7 @@ FORMAT OF COMMAND SPECIFICATIONS
- 18 April 2010 11
+ 10 May 2010 11
@@ -789,7 +789,7 @@ LATEXMK(1L) LATEXMK(1L)
- 18 April 2010 12
+ 10 May 2010 12
@@ -856,7 +856,7 @@ LATEXMK(1L) LATEXMK(1L)
- 18 April 2010 13
+ 10 May 2010 13
@@ -907,23 +907,23 @@ LATEXMK(1L) LATEXMK(1L)
LIST OF CONFIGURATION VARIABLES USABLE IN INITIALIZATION FILES
Default values are indicated in brackets.
- $banner [0]
- If nonzero, the banner message is printed across each page when
- converting the dvi file to postscript. Without modifying the
- variable $banner_message, this is equivalent to specifying the
- -d option.
+ $always_view_file_via_temporary [0]
+ Whether ps and pdf files are initially to be made in a temporary
+ directory and then moved to the final location. (This applies
+ to dvips, dvipdf, and ps2pdf operations, and the filtering oper-
+ ators on dvi and ps files. It does not apply to pdflatex,
+ unfortunately.)
- Note that if $banner is nonzero, the $postscript_mode is assumed
- and the postscript file is always generated, even if it is newer
- than the dvi file.
+ This use of a temporary file solves a problem that the making of
+ these files can occupy a substantial time. If a viewer sees
+ that the file has changed, it reads the new file, and this can
+ cause havoc if the program writing the file has not yet finished
+ its work.
- $banner_intensity [0.95]
- Equivalent to the -bi option, this is a decimal number between 0
- and 1 that specifies how dark to print the banner message. 0 is
- 18 April 2010 14
+ 10 May 2010 14
@@ -932,6 +932,25 @@ LIST OF CONFIGURATION VARIABLES USABLE IN INITIALIZATION FILES
LATEXMK(1L) LATEXMK(1L)
+ See the $pvc_view_file_via_temporary variable for a setting that
+ applies only if preview-continuous mode (-pvc option) is used.
+ See $tmpdir for the setting of the directory where the temporary
+ file is created.
+
+
+ $banner [0]
+ If nonzero, the banner message is printed across each page when
+ converting the dvi file to postscript. Without modifying the
+ variable $banner_message, this is equivalent to specifying the
+ -d option.
+
+ Note that if $banner is nonzero, the $postscript_mode is assumed
+ and the postscript file is always generated, even if it is newer
+ than the dvi file.
+
+ $banner_intensity [0.95]
+ Equivalent to the -bi option, this is a decimal number between 0
+ and 1 that specifies how dark to print the banner message. 0 is
black, 1 is white. The default is just right if your toner car-
tridge isn't running too low.
@@ -940,19 +959,19 @@ LATEXMK(1L) LATEXMK(1L)
dvi file to postscript. This is equivalent to the -bm option.
$banner_scale [220.0]
- A decimal number that specifies how large the banner message
- will be printed. Experimentation is necessary to get the right
- scale for your message, as a rule of thumb the scale should be
- about equal to 1100 divided by the number of characters in the
- message. The Default is just right for 5 character messages.
+ A decimal number that specifies how large the banner message
+ will be printed. Experimentation is necessary to get the right
+ scale for your message, as a rule of thumb the scale should be
+ about equal to 1100 divided by the number of characters in the
+ message. The Default is just right for 5 character messages.
This is equivalent to the -bs option.
@BIBINPUTS
- This is an array variable, now mostly obsolete, that specifies
- directories where latexmk should look for .bib files. By
+ This is an array variable, now mostly obsolete, that specifies
+ directories where latexmk should look for .bib files. By
default it is set from the BIBINPUTS environment variable of the
- operating system. If that environment variable is not set, a
- single element list consisting of the current directory is set.
+ operating system. If that environment variable is not set, a
+ single element list consisting of the current directory is set.
The format of the directory names depends on your operating sys-
tem, of course. Examples for setting this variable are:
@@ -962,13 +981,25 @@ LATEXMK(1L) LATEXMK(1L)
@BIBINPUTS = ( ".", "//server/bibfiles" );
@BIBINPUTS = ( ".", "/usr/local/texmf/bibtex/bib" );
- Note that under MS Windows, either a forward slash "/" or a
- backward slash "\" can be used to separate pathname components,
- so the first two and the second two examples are equivalent.
- Each backward slash should be doubled to avoid running afoul of
+ Note that under MS Windows, either a forward slash "/" or a
+ backward slash "\" can be used to separate pathname components,
+ so the first two and the second two examples are equivalent.
+ Each backward slash should be doubled to avoid running afoul of
Perl's rules for writing strings.
- Important note: This variable is now mostly obsolete in the current
+
+
+
+ 10 May 2010 15
+
+
+
+
+
+LATEXMK(1L) LATEXMK(1L)
+
+
+ Important note: This variable is now mostly obsolete in the current
version of latexmk, since it has a better method of searching for files
using the kpsewhich command. However, if your system is an unusual one
without the kpsewhich command, you may need to set the variable @BIBIN-
@@ -982,89 +1013,79 @@ LATEXMK(1L) LATEXMK(1L)
on.
$bibtex_use [1]
- Under what conditions to run BibTeX. When latexmk discovers
+ Under what conditions to run BibTeX. When latexmk discovers
from the log file that one (or more) BibTeX-generated bibliogra-
- phies are used, it can run BibTeX whenever it appears necessary
- to regenerate the bbl file(s) from their source bib database
+ phies are used, it can run BibTeX whenever it appears necessary
+ to regenerate the bbl file(s) from their source bib database
file(s).
-
-
- 18 April 2010 15
-
-
-
-
-
-LATEXMK(1L) LATEXMK(1L)
-
-
- But sometimes, the bib file(s) are not available (e.g., for a
- document obtained from an external archive), but the bbl files
- are provided. In that case use of BibTeX will result in incor-
- rect overwriting of the precious bbl files. The variable $bib-
+ But sometimes, the bib file(s) are not available (e.g., for a
+ document obtained from an external archive), but the bbl files
+ are provided. In that case use of BibTeX will result in incor-
+ rect overwriting of the precious bbl files. The variable $bib-
tex_use controls whether this happens. Its possible values are:
0: never use BibTeX. 1: only use BibTeX if the bib files exist.
- 2: run BibTeX whenever it appears necessary to update the bbl
+ 2: run BibTeX whenever it appears necessary to update the bbl
files, without testing for the existence of the bib files.
$cleanup_includes_generated [0]
- If nonzero, specifies that cleanup also deletes files that are
- detected in log file as being generated (see the \openout lines
- in the log file). It will also include files made from these
+ If nonzero, specifies that cleanup also deletes files that are
+ detected in log file as being generated (see the \openout lines
+ in the log file). It will also include files made from these
first generation generated files.
$cleanup_mode [0]
- If nonzero, specifies cleanup mode: 1 for full cleanup, 2 for
- cleanup except for dvi, ps and pdf files, 3 for cleanup except
- for dep and aux files. (There is also extra cleaning as speci-
- fied by the $clean_ext, $clean_full_ext and @generated_exts
+ If nonzero, specifies cleanup mode: 1 for full cleanup, 2 for
+ cleanup except for dvi, ps and pdf files, 3 for cleanup except
+ for dep and aux files. (There is also extra cleaning as speci-
+ fied by the $clean_ext, $clean_full_ext and @generated_exts
variables.)
- This variable is equivalent to specifying one of the -c, -c1, or -C
- options. But there should be no need to set this variable from an RC
+ This variable is equivalent to specifying one of the -c, -c1, or -C
+ options. But there should be no need to set this variable from an RC
file.
$clean_ext [""]
- Extra extensions of files for latexmk to remove when any of the
- clean-up options (-c, -c1, or -C) is selected. The value of
+ Extra extensions of files for latexmk to remove when any of the
+ clean-up options (-c, -c1, or -C) is selected. The value of
this variable is a string containing the extensions separated by
spaces.
$clean_full_ext [""]
- Extra extensions of files for latexmk to remove when the -C
+ Extra extensions of files for latexmk to remove when the -C
option is selected, i.e., extensions of files to remove when the
- .dvi, etc files are to be cleaned-up.
- @cus_dep_list [()]
- Custom dependency list -- see section on "Custom Dependencies".
- @default_files [("*.tex")]
- Default list of files to be processed.
- Normally, if no filenames are specified on the command line,
- latexmk processes all tex files specified in the @default_files
- variable, which by default is set to all tex files ("*.tex") in
- the current directory. This is a convenience: just run latexmk
- and it will process an appropriate set of files. But sometimes
- you want only some of these files to be processed. In this case
- you set the @default_files in an initialization file (e.g., the
- file "latexmkrc" in the current directory). Then if no files
- are specified on the command line then the files you specify by
- setting @default_files are processed.
+ 10 May 2010 16
- Three examples:
- 18 April 2010 16
+LATEXMK(1L) LATEXMK(1L)
+ .dvi, etc files are to be cleaned-up.
+ @cus_dep_list [()]
+ Custom dependency list -- see section on "Custom Dependencies".
-LATEXMK(1L) LATEXMK(1L)
+ @default_files [("*.tex")]
+ Default list of files to be processed.
+
+ Normally, if no filenames are specified on the command line,
+ latexmk processes all tex files specified in the @default_files
+ variable, which by default is set to all tex files ("*.tex") in
+ the current directory. This is a convenience: just run latexmk
+ and it will process an appropriate set of files. But sometimes
+ you want only some of these files to be processed. In this case
+ you set the @default_files in an initialization file (e.g., the
+ file "latexmkrc" in the current directory). Then if no files
+ are specified on the command line then the files you specify by
+ setting @default_files are processed.
+ Three examples:
@default_files = ("paper_current");
@@ -1072,284 +1093,283 @@ LATEXMK(1L) LATEXMK(1L)
@default_files = ("*.tex", "*.dtx");
- Note that more than file may be given, and that the default
- extension is ".tex". Wild cards are allowed. The parentheses
+ Note that more than file may be given, and that the default
+ extension is ".tex". Wild cards are allowed. The parentheses
are because @default_files is an array variable, i.e., a
sequence of filename specifications is possible.
$dvi_filter [empty]
- The dvi file filter to be run on the newly produced dvi file
- before other processing. Equivalent to specifying the -dF
+ The dvi file filter to be run on the newly produced dvi file
+ before other processing. Equivalent to specifying the -dF
option.
$dvi_mode [See below for default]
- If nonzero, generate a dvi version of the document. Equivalent
+ If nonzero, generate a dvi version of the document. Equivalent
to the -dvi option.
- The variable $dvi_mode defaults to 0, but if no explicit requests are
- made for other types of file (postscript, pdf), then $dvi_mode will be
- set to 1. In addition, if a request for a file for which a .dvi file
+ The variable $dvi_mode defaults to 0, but if no explicit requests are
+ made for other types of file (postscript, pdf), then $dvi_mode will be
+ set to 1. In addition, if a request for a file for which a .dvi file
is a prerequisite, then $dvi_mode will be set to 1.
$dvi_previewer ["start xdvi %O %S" under UNIX]
- The command to invoke a dvi-previewer. [Default is "start"
- under MS-WINDOWS; under more recent versions of Windows, this
- will cause to be run whatever command the system has associated
+ The command to invoke a dvi-previewer. [Default is "start"
+ under MS-WINDOWS; under more recent versions of Windows, this
+ will cause to be run whatever command the system has associated
with .dvi files.]
$dvi_previewer_landscape ["start xdvi %O %S"]
The command to invoke a dvi-previewer in landscape mode.
[Default is "start" under MS-WINDOWS; under more recent versions
- of Windows, this will cause to be run whatever command the sys-
- tem has associated with .dvi files.]
- $dvipdf ["dvipdf %O %S %D"]
- Command to convert dvi to pdf file. A common reconfiguration is
- to use the dvipdfm command, which needs its arguments in a dif-
- ferent order:
- $dvipdf = "dvipdfm %O -o %D %S";
- WARNING: The default dvipdf script generates pdf files with
- bitmapped fonts, which do not look good when viewed by acroread.
- That script should be modified to give dvips the options "-P
- pdf" to ensure that type 1 fonts are used in the pdf file.
+ 10 May 2010 17
- $dvips ["dvips %O -o %D %S"]
- The program to used as a filter to convert a .dvi file to a .ps
- file. If pdf is going to be generated from pdf, then the value
- of the $dvips_pdf_switch -- see below -- will be included in the
- options substituted for "%O".
- 18 April 2010 17
+LATEXMK(1L) LATEXMK(1L)
+ of Windows, this will cause to be run whatever command the sys-
+ tem has associated with .dvi files.]
+ $dvipdf ["dvipdf %O %S %D"]
+ Command to convert dvi to pdf file. A common reconfiguration is
+ to use the dvipdfm command, which needs its arguments in a dif-
+ ferent order:
+ $dvipdf = "dvipdfm %O -o %D %S";
-LATEXMK(1L) LATEXMK(1L)
+ WARNING: The default dvipdf script generates pdf files with
+ bitmapped fonts, which do not look good when viewed by acroread.
+ That script should be modified to give dvips the options "-P
+ pdf" to ensure that type 1 fonts are used in the pdf file.
+ $dvips ["dvips %O -o %D %S"]
+ The program to used as a filter to convert a .dvi file to a .ps
+ file. If pdf is going to be generated from pdf, then the value
+ of the $dvips_pdf_switch -- see below -- will be included in the
+ options substituted for "%O".
$dvips_landscape ["dvips -tlandscape %O -o %D %S"]
- The program to used as a filter to convert a .dvi file to a .ps
+ The program to used as a filter to convert a .dvi file to a .ps
file in landscape mode.
$dvips_pdf_switch ["-P pdf"]
- Switch(es) for dvips program when pdf file is to be generated
+ Switch(es) for dvips program when pdf file is to be generated
from ps file.
$dvips_silent_switch ["-q"]
Switch(es) for dvips program when silent mode is on.
$dvi_update_command [""]
- When the dvi previewer is set to be updated by running a com-
- mand, this is the command that is run. See the information for
+ When the dvi previewer is set to be updated by running a com-
+ mand, this is the command that is run. See the information for
the variable $dvi_update_method for further information, and see
- information on the variable $pdf_update_method for an example
+ information on the variable $pdf_update_method for an example
for the analogous case of a pdf previewer.
$dvi_update_method [2 under UNIX, 1 under MS-Windows]
- How the dvi viewer updates its display when the dvi file has
- changed. The values here apply equally to the
+ How the dvi viewer updates its display when the dvi file has
+ changed. The values here apply equally to the
$pdf_update_method and to the $ps_update_method variables.
0 => update is automatic,
1=> manual update by user, which may only mean a mouse click
on the viewer's window or may mean a more serious action.
- 2 => Send the signal, whose number is in the variable
- $dvi_update_signal. The default value under UNIX is suitable
+ 2 => Send the signal, whose number is in the variable
+ $dvi_update_signal. The default value under UNIX is suitable
for xdvi.
- 3 => Viewer cannot do an update, because it locks the file.
+ 3 => Viewer cannot do an update, because it locks the file.
(As with acroread under MS-Windows.)
- 4 => run a command to do the update. The command is speci-
+ 4 => run a command to do the update. The command is speci-
fied by the variable $dvi_update_command.
- See information on the variable $pdf_update_method for an exam-
- ple of updating by command.
+ See information on the variable $pdf_update_method for an
- $dvi_update_signal [Under UNIX: SIGUSR1, which is a system-dependent
- value]
- The number of the signal that is sent to the dvi viewer when it
- is updated by sending a signal -- see the information on the
- variable $dvi_update_method. The default value is the one
- appropriate for xdvi on a UNIX system.
- $fdb_ext ["fdb_latexmk"]
- The extension of the file which latexmk generates to contain a
- database of information on source files. You will not normally
- need to change this.
- $force_mode [0]
- If nonzero, continue processing past minor latex errors includ-
- ing unrecognized cross references. Equivalent to specifying the
- -f option.
+ 10 May 2010 18
- @generated_exts [( aux , bbl , idx , ind , lof , lot , out , toc ,
- $fdb_ext )]
- This contains a list of extensions for files that are generated
- 18 April 2010 18
+LATEXMK(1L) LATEXMK(1L)
+ example of updating by command.
+ $dvi_update_signal [Under UNIX: SIGUSR1, which is a system-dependent
+ value]
+ The number of the signal that is sent to the dvi viewer when it
+ is updated by sending a signal -- see the information on the
+ variable $dvi_update_method. The default value is the one
+ appropriate for xdvi on a UNIX system.
-LATEXMK(1L) LATEXMK(1L)
+ $fdb_ext ["fdb_latexmk"]
+ The extension of the file which latexmk generates to contain a
+ database of information on source files. You will not normally
+ need to change this.
+ $force_mode [0]
+ If nonzero, continue processing past minor latex errors includ-
+ ing unrecognized cross references. Equivalent to specifying the
+ -f option.
- during a LaTeX run and that are read in by LaTeX in later runs,
+ @generated_exts [( aux , bbl , idx , ind , lof , lot , out , toc ,
+ $fdb_ext )]
+ This contains a list of extensions for files that are generated
+ during a LaTeX run and that are read in by LaTeX in later runs,
either directly or indirectly.
- This list has two uses: (a) to set the kinds of file to be
+ This list has two uses: (a) to set the kinds of file to be
deleted in a cleanup operation (with the -c, -C, -CA, -g and -gg
- options), and (b) in the determination of whether a rerun of
+ options), and (b) in the determination of whether a rerun of
(pdf)LaTeX is needed after a run that gives an error.
(Normally, a change of a source file during a run should provoke
- a rerun. This includes a file generated by LaTeX, e.g., an aux
- file, that is read in on subsequent runs. But after a run that
- results in an error, a new run should occur until the user has
- made a change in the files. But the user may have corrected an
+ a rerun. This includes a file generated by LaTeX, e.g., an aux
+ file, that is read in on subsequent runs. But after a run that
+ results in an error, a new run should occur until the user has
+ made a change in the files. But the user may have corrected an
error in a source .tex file during the run. So latexmk needs to
distinguish user-generated and automatically generated files; it
- determines the automatically generated files as those with
+ determines the automatically generated files as those with
extensions in the list in @generated_exts.)
- A convenient way to add an extra extension to the list, without
- losing the already defined ones is to use a push command in the
+ A convenient way to add an extra extension to the list, without
+ losing the already defined ones is to use a push command in the
line in an RC file. E.g.,
push @generated_exts, "end";
- adds the extension "end" to the list of predefined generated
- extensions. (This extension is used by the RevTeX package, for
+ adds the extension "end" to the list of predefined generated
+ extensions. (This extension is used by the RevTeX package, for
example.)
$go_mode [0]
- If nonzero, process files regardless of timestamps, and is then
+ If nonzero, process files regardless of timestamps, and is then
equivalent to the -g option.
%hash_calc_ignore_pattern
!!!This variable is for experts only!!!
- The general rule latexmk uses for determining when an extra run
- of some program is needed is that one of the source files has
- changed. But consider for example a latex package that causes
- an encapsulated postscript file (an "eps" file) to be made that
- is to be read in on the next run. The file contains a comment
- line giving its creation date and time. On the next run the
- time changes, latex sees that the eps file has changed, and
- therefore reruns latex. This causes an infinite loop, only
- exited becaues latexmk has a limit on the number of runs to
- guard against pathological situations.
- But the changing line has no real effect, since it is a comment.
- You can instruct latex to ignore the offending line as follows:
- $hash_calc_ignore_pattern{'eps'} = '^%%CreationDate: ';
- This creates a rule for files with extension .eps about lines to
- ignore. The left-hand side is a Perl idiom for setting an item
- in a hash. Note that the file extension is specified without a
- period. The value, on the right-hand side, is a string contain-
- ing a regular expresssion. (See documentation on Perl for how
+ 10 May 2010 19
- 18 April 2010 19
+LATEXMK(1L) LATEXMK(1L)
+ The general rule latexmk uses for determining when an extra run
+ of some program is needed is that one of the source files has
+ changed. But consider for example a latex package that causes
+ an encapsulated postscript file (an "eps" file) to be made that
+ is to be read in on the next run. The file contains a comment
+ line giving its creation date and time. On the next run the
+ time changes, latex sees that the eps file has changed, and
+ therefore reruns latex. This causes an infinite loop, only
+ exited becaues latexmk has a limit on the number of runs to
+ guard against pathological situations.
-LATEXMK(1L) LATEXMK(1L)
+ But the changing line has no real effect, since it is a comment.
+ You can instruct latex to ignore the offending line as follows:
+ $hash_calc_ignore_pattern{'eps'} = '^%%CreationDate: ';
- they are to be specified in general.) This particular regular
- expression specifies that lines beginning with "%%CreationDate:
- " are to be ignored in deciding whether a file of the given
+ This creates a rule for files with extension .eps about lines to
+ ignore. The left-hand side is a Perl idiom for setting an item
+ in a hash. Note that the file extension is specified without a
+ period. The value, on the right-hand side, is a string contain-
+ ing a regular expresssion. (See documentation on Perl for how
+ they are to be specified in general.) This particular regular
+ expression specifies that lines beginning with "%%CreationDate:
+ " are to be ignored in deciding whether a file of the given
extension .eps has changed.
$kpsewhich ["kpsewhich %S"]
- The program called to locate a source file when the name alone
- is not sufficient. Most filenames used by latexmk have suffi-
- cient path information to be found directly. But sometimes,
- notably when .bib files are found from the log file of a bibtex
- run, the name of the file, but not its path is known. The pro-
+ The program called to locate a source file when the name alone
+ is not sufficient. Most filenames used by latexmk have suffi-
+ cient path information to be found directly. But sometimes,
+ notably when .bib files are found from the log file of a bibtex
+ run, the name of the file, but not its path is known. The pro-
gram specified by $kpsewhich is used to find it.
- See also the @BIBINPUTS variable for another way that latexmk
+ See also the @BIBINPUTS variable for another way that latexmk
also uses to try to locate files; it applies only in the case of
.bib files.
$landscape_mode [0]
If nonzero, run in landscape mode, using the landscape mode pre-
- viewers and dvi to postscript converters. Equivalent to the -l
+ viewers and dvi to postscript converters. Equivalent to the -l
option. Normally not needed with current previewers.
$latex ["latex %O %S"]
The LaTeX processing program. Note that as with other programs,
- you can use this variable not just to change the name of the
+ you can use this variable not just to change the name of the
program used, but also specify options to the program. E.g.,
$latex = "latex --src-specials";
%latex_input_extensions
- This variable specifies the extensions tried by latexmk when it
- finds that a LaTeX run resulted in an error that a file has not
- been found, and the file is given without an extension. This
+ This variable specifies the extensions tried by latexmk when it
+ finds that a LaTeX run resulted in an error that a file has not
+ been found, and the file is given without an extension. This
typically happens when LaTeX commands of the form input{file} or
- includegraphics{figure}, when the relevant source file does not
+ includegraphics{figure}, when the relevant source file does not
exist.
- In this situation, latexmk searches for custom dependencies to
- make the missing file(s), but restricts it to the extensions
- specified by the variable %latex_input_extensions. The default
- extensions are
-
- (For Perl experts: %latex_input_extensions is a hash whose keys
- are the extensions. The values are irrelevant.) Two subrou-
- tines are provided for manipulating this and the related vari-
- able %pdflatex_input_extensions, add_input_ext and
- remove_input_ext. They are used as in the following examples
- are possible lines in an initialization file:
- remove_input_ext( 'latex', 'tex' );
- removes the extension 'tex' from latex_input_extensions
+ 10 May 2010 20
- add_input_ext( 'latex', 'asdf' );
- add the extension 'asdf to latex_input_extensions. (Naturally
- 18 April 2010 20
+LATEXMK(1L) LATEXMK(1L)
+ In this situation, latexmk searches for custom dependencies to
+ make the missing file(s), but restricts it to the extensions
+ specified by the variable %latex_input_extensions. The default
+ extensions are
+ (For Perl experts: %latex_input_extensions is a hash whose keys
+ are the extensions. The values are irrelevant.) Two subrou-
+ tines are provided for manipulating this and the related vari-
+ able %pdflatex_input_extensions, add_input_ext and
+ remove_input_ext. They are used as in the following examples
+ are possible lines in an initialization file:
+ remove_input_ext( 'latex', 'tex' );
-LATEXMK(1L) LATEXMK(1L)
+ removes the extension 'tex' from latex_input_extensions
+ add_input_ext( 'latex', 'asdf' );
+ add the extension 'asdf to latex_input_extensions. (Naturally
with such an extension, you should have made an appropriate cus-
tom dependency for latexmk, and should also have done the appro-
- priate programming in the LaTeX source file to enable the file
- to be read. The standard extensions are handled by LaTeX and
+ priate programming in the LaTeX source file to enable the file
+ to be read. The standard extensions are handled by LaTeX and
its graphics/graphicx packages.
$latex_silent_switch ["-interaction=batchmode"]
- Switch(es) for the LaTeX processing program when silent mode is
+ Switch(es) for the LaTeX processing program when silent mode is
on.
- If you use MikTeX, you may prefer the results if you configure
- the options to include -c-style-errors, e.g., by the following
+ If you use MikTeX, you may prefer the results if you configure
+ the options to include -c-style-errors, e.g., by the following
line in an initialization file
$latex_silent_switch = "-interaction=batchmode -c-style-
@@ -1359,119 +1379,119 @@ LATEXMK(1L) LATEXMK(1L)
$lpr ["lpr %O %S" under UNIX/LINUX, "NONE lpr" under MS-WINDOWS]
The command to print postscript files.
- Under MS-Windows (unlike UNIX/LINUX), there is no standard pro-
+ Under MS-Windows (unlike UNIX/LINUX), there is no standard pro-
gram for printing files. But there are ways you can do it. For
example, if you have gsview installed, you could use it with the
option "/p":
$lpr = '"c:/Program Files/Ghostgum/gsview/gsview32.exe" /p';
- If gsview is installed in a different directory, you will need
- to make the appropriate change. Note the combination of single
- and double quotes around the name. The single quotes specify
- that this is a string to be assigned to the configuration vari-
- able $lpr. The double quotes are part of the string passed to
- the operating system to get the command obeyed; this is neces-
+ If gsview is installed in a different directory, you will need
+ to make the appropriate change. Note the combination of single
+ and double quotes around the name. The single quotes specify
+ that this is a string to be assigned to the configuration vari-
+ able $lpr. The double quotes are part of the string passed to
+ the operating system to get the command obeyed; this is neces-
sary because one part of the command name ("Program Files") con-
tains a space which would otherwise be misinterpreted.
- $lpr_dvi ["NONE lpr_dvi"]
- The printing program to print dvi files.
- $lpr_pdf ["NONE lpr_pdf"]
- The printing program to print pdf files.
- Under MS-Windows you could set this to use gsview, if it is
- installed, e.g.,
- $lpr = '"c:/Program Files/Ghostgum/gsview/gsview32.exe" /p';
+ 10 May 2010 21
- If gsview is installed in a different directory, you will need
- to make the appropriate change. Note the double quotes around
- the name: this is necessary because one part of the command name
- ("Program Files") contains a space which would otherwise be mis-
- interpreted.
+LATEXMK(1L) LATEXMK(1L)
- 18 April 2010 21
+ $lpr_dvi ["NONE lpr_dvi"]
+ The printing program to print dvi files.
+ $lpr_pdf ["NONE lpr_pdf"]
+ The printing program to print pdf files.
+ Under MS-Windows you could set this to use gsview, if it is
+ installed, e.g.,
+ $lpr = '"c:/Program Files/Ghostgum/gsview/gsview32.exe" /p';
-LATEXMK(1L) LATEXMK(1L)
+ If gsview is installed in a different directory, you will need
+ to make the appropriate change. Note the double quotes around
+ the name: this is necessary because one part of the command name
+ ("Program Files") contains a space which would otherwise be mis-
+ interpreted.
$makeindex ["makeindex %O -o %D %S"]
The index processing program.
$max_repeat [5]
- The maximum number of times latexmk will run latex/pdflatex
- before deciding that there may be an infinite loop and that it
+ The maximum number of times latexmk will run latex/pdflatex
+ before deciding that there may be an infinite loop and that it
needs to bail out, rather than rerunning latex/pdflatex again to
- resolve cross-references, etc. The default value covers all
+ resolve cross-references, etc. The default value covers all
normal cases.
- (Note that the "etc" covers a lot of cases where one run of
+ (Note that the "etc" covers a lot of cases where one run of
latex/pdflatex generates files to be read in on a later run.)
$new_viewer_always [0]
- This variable applies to latexmk only in continuous-preview
+ This variable applies to latexmk only in continuous-preview
mode. If $new_viewer_always is 0, latexmk will check for a pre-
- viously running previewer on the same file, and if one is run-
- ning will not start a new one. If $new_viewer_always is non-
- zero, this check will be skipped, and latexmk will behave as if
+ viously running previewer on the same file, and if one is run-
+ ning will not start a new one. If $new_viewer_always is non-
+ zero, this check will be skipped, and latexmk will behave as if
no viewer is running.
$pdf_mode [0]
- If zero, do NOT generate a pdf version of the document. If
- equal to 1, generate a pdf version of the document using pdfla-
+ If zero, do NOT generate a pdf version of the document. If
+ equal to 1, generate a pdf version of the document using pdfla-
tex. If equal to 2, generate a pdf version of the document from
the ps file, by using the command specified by the $ps2pdf vari-
- able. If equal to 3, generate a pdf version of the document
+ able. If equal to 3, generate a pdf version of the document
from the dvi file, by using the command specified by the $dvipdf
variable.
Equivalent to the -pdf-, -pdf, -pdfdvi, -pdfps options.
$pdflatex ["pdflatex %O %S"]
- The LaTeX processing program in the version that makes a pdf
+ The LaTeX processing program in the version that makes a pdf
file instead of a dvi file.
%pdflatex_input_extensions
- This variable specifies the extensions tried by latexmk when it
- finds that a pdfLaTeX run resulted in an error that a file has
- not been found, and the file is given without an extension.
- This typically happens when LaTeX commands of the form
- input{file} or includegraphics{figure}, when the relevant source
- file does not exist.
+ This variable specifies the extensions tried by latexmk when it
+ finds that a pdfLaTeX run resulted in an error that a file has
- In this situation, latexmk searches for custom dependencies to
- make the missing file(s), but restricts it to the extensions
- specified by the variable %pdflatex_input_extensions. The
- default extensions are
- (For Perl experts: %pdflatex_input_extensions is a hash whose
- keys are the extensions. The values are irrelevant.) Two sub-
- routines are provided for manipulating this and the related
- variable %latex_input_extensions, add_input_ext and
- remove_input_ext. They are used as in the following examples
- are possible lines in an initialization file:
+ 10 May 2010 22
- 18 April 2010 22
+LATEXMK(1L) LATEXMK(1L)
+ not been found, and the file is given without an extension.
+ This typically happens when LaTeX commands of the form
+ input{file} or includegraphics{figure}, when the relevant source
+ file does not exist.
-LATEXMK(1L) LATEXMK(1L)
+ In this situation, latexmk searches for custom dependencies to
+ make the missing file(s), but restricts it to the extensions
+ specified by the variable %pdflatex_input_extensions. The
+ default extensions are
+ (For Perl experts: %pdflatex_input_extensions is a hash whose
+ keys are the extensions. The values are irrelevant.) Two sub-
+ routines are provided for manipulating this and the related
+ variable %latex_input_extensions, add_input_ext and
+ remove_input_ext. They are used as in the following examples
+ are possible lines in an initialization file:
remove_input_ext( 'pdflatex', 'tex' );
@@ -1479,20 +1499,20 @@ LATEXMK(1L) LATEXMK(1L)
add_input_ext( 'pdflatex', 'asdf' );
- add the extension 'asdf to pdflatex_input_extensions. (Natu-
- rally with such an extension, you should have made an appropri-
+ add the extension 'asdf to pdflatex_input_extensions. (Natu-
+ rally with such an extension, you should have made an appropri-
ate custom dependency for latexmk, and should also have done the
- appropriate programming in the LaTeX source file to enable the
- file to be read. The standard extensions are handled by pdfla-
+ appropriate programming in the LaTeX source file to enable the
+ file to be read. The standard extensions are handled by pdfla-
tex and its graphics/graphicx packages.)
$pdflatex_silent_switch ["-interaction=batchmode"]
- Switch(es) for the pdflatex program (specified in the variable
+ Switch(es) for the pdflatex program (specified in the variable
$pdflatex when silent mode is on.
- If you use MikTeX, you may prefer the results if you configure
- the options to include -c-style-errors, e.g., by the following
+ If you use MikTeX, you may prefer the results if you configure
+ the options to include -c-style-errors, e.g., by the following
line in an initialization file
$latex_silent_switch = "-interaction=batchmode -c-style-
@@ -1500,46 +1520,46 @@ LATEXMK(1L) LATEXMK(1L)
$pdf_previewer ["start acroread %O %S"]
- The command to invoke a pdf-previewer. [Default is changed to
- "start" on MS-WINDOWS; under more recent versions of Windows,
- this will cause to be run whatever command the system has asso-
+ The command to invoke a pdf-previewer. [Default is changed to
+ "start" on MS-WINDOWS; under more recent versions of Windows,
+ this will cause to be run whatever command the system has asso-
ciated with .pdf files.]
WARNING: Potential problem under MS-Windows: if acroread is used
as the pdf previewer, and it is actually viewing a pdf file, the
pdf file cannot be updated. Thus makes acroread a bad choice of
- previewer if you use latexmk's previous-continuous mode (option
- -pvc) under MS-windows. This problem does not occur if
+ previewer if you use latexmk's previous-continuous mode (option
+ -pvc) under MS-windows. This problem does not occur if
ghostview, gv or gsview is used to view pdf files.
$pdf_update_command [""]
- When the pdf previewer is set to be updated by running a com-
- mand, this is the command that is run. See the information for
- the variable $pdf_update_method.
+ When the pdf previewer is set to be updated by running a com-
+ mand, this is the command that is run. See the information for
- $pdf_update_method [1 under UNIX, 3 under MS-Windows]
- How the pdf viewer updates its display when the pdf file has
- changed. See the information on the variable $dvi_update_method
- for the codes. (Note that information needs be changed slightly
- so that for the value 4, to run a command to do the update, the
- command is specified by the variable $pdf_update_command, and
- for the value 2, to specify update by signal, the signal is
- specified by $pdf_update_signal.)
- Note that acroread under MS-Windows (but not UNIX) locks the pdf
- file, so the default value is then 3.
+ 10 May 2010 23
- 18 April 2010 23
+LATEXMK(1L) LATEXMK(1L)
+ the variable $pdf_update_method.
-LATEXMK(1L) LATEXMK(1L)
+ $pdf_update_method [1 under UNIX, 3 under MS-Windows]
+ How the pdf viewer updates its display when the pdf file has
+ changed. See the information on the variable $dvi_update_method
+ for the codes. (Note that information needs be changed slightly
+ so that for the value 4, to run a command to do the update, the
+ command is specified by the variable $pdf_update_command, and
+ for the value 2, to specify update by signal, the signal is
+ specified by $pdf_update_signal.)
+ Note that acroread under MS-Windows (but not UNIX) locks the pdf
+ file, so the default value is then 3.
Arranging to use a command to get a previewer explicitly updated
requires three variables to be set. For example:
@@ -1548,127 +1568,119 @@ LATEXMK(1L) LATEXMK(1L)
$pdf_update_method = 4;
$pdf_update_command = "xpdf -remote %R -reload";
- The first setting arranges for the xpdf program to be used in
- its "remote server mode", with the server name specified as the
- rootname of the TeX file. The second setting arranges for
+ The first setting arranges for the xpdf program to be used in
+ its "remote server mode", with the server name specified as the
+ rootname of the TeX file. The second setting arranges for
updating to be done in response to a command, and the third set-
ting sets the update command.
- $pdf_update_signal [Under UNIX: SIGHUP, which is a system-dependent
+ $pdf_update_signal [Under UNIX: SIGHUP, which is a system-dependent
value]
- The number of the signal that is sent to the pdf viewer when it
- is updated by sending a signal -- see the information on the
- variable $pdf_update_method. The default value is the one
+ The number of the signal that is sent to the pdf viewer when it
+ is updated by sending a signal -- see the information on the
+ variable $pdf_update_method. The default value is the one
appropriate for gv on a UNIX system.
$pid_position[1 under UNIX, -1 under MS-Windows]
- The variable $pid_position is used to specify which word in
- lines of the output from $pscmd corresponds to the process ID.
- The first word in the line is numbered 0. The default value of
+ The variable $pid_position is used to specify which word in
+ lines of the output from $pscmd corresponds to the process ID.
+ The first word in the line is numbered 0. The default value of
1 (2nd word in line) is correct for Solaris 2.6 and Linux. Set-
- ting the variable to -1 is used to indicate that $pscmd is not
+ ting the variable to -1 is used to indicate that $pscmd is not
to be used.
$postscript_mode [0]
- If nonzero, generate a postscript version of the document.
+ If nonzero, generate a postscript version of the document.
Equivalent to the -ps option.
- If some other request is made for which a postscript file is needed,
+ If some other request is made for which a postscript file is needed,
then $postscript_mode will be set to 1.
$preview_continuous_mode [0]
- If nonzero, run a previewer to view the document, and continue
+ If nonzero, run a previewer to view the document, and continue
running latexmk to keep .dvi up-to-date. Equivalent to the -pvc
- option. Which previewer is run depends on the other settings,
+ option. Which previewer is run depends on the other settings,
see the command line options -view=, and the variable $view.
$preview_mode [0]
If nonzero, run a previewer to preview the document. Equivalent
- to the -pv option. Which previewer is run depends on the other
- settings, see the command line options -view=, and the variable
- $view.
+ to the -pv option. Which previewer is run depends on the other
- $printout_mode [0]
- If nonzero, print the document using lpr. Equivalent to the -p
- option. This is recommended not to be set from an RC file, oth-
- erwise you could waste lots of paper.
- $print_type = ["ps"]
- Type of file to printout: possibilities are "dvi", "none",
- "pdf", or "ps".
+ 10 May 2010 24
- 18 April 2010 24
+LATEXMK(1L) LATEXMK(1L)
-LATEXMK(1L) LATEXMK(1L)
+ settings, see the command line options -view=, and the variable
+ $view.
+
+ $printout_mode [0]
+ If nonzero, print the document using lpr. Equivalent to the -p
+ option. This is recommended not to be set from an RC file, oth-
+ erwise you could waste lots of paper.
+ $print_type = ["ps"]
+ Type of file to printout: possibilities are "dvi", "none",
+ "pdf", or "ps".
$pscmd Command used to get all the processes currently run by the user.
- The -pvc option uses the command specified by the variable
- $pscmd to determine if there is an already running previewer,
- and to find the process ID (needed if latexmk needs to signal
+ The -pvc option uses the command specified by the variable
+ $pscmd to determine if there is an already running previewer,
+ and to find the process ID (needed if latexmk needs to signal
the previewer about file changes).
Each line of the output of this command is assumed to correspond
to one process. See the $pid_position variable for how the pro-
cess number is determined.
- The default for pscmd is "NONE" under MS-Windows and cygwin
+ The default for pscmd is "NONE" under MS-Windows and cygwin
(i.e., the command is not used), "ps --width 200 -f -u
- $ENV{USER}" under linux, "ps -ww -u $ENV{USER}" under darwin
- (Macintosh OS-X), and "ps -f -u $ENV{USER}" under other operat-
- ing systems (including other flavors of UNIX). In these speci-
+ $ENV{USER}" under linux, "ps -ww -u $ENV{USER}" under darwin
+ (Macintosh OS-X), and "ps -f -u $ENV{USER}" under other operat-
+ ing systems (including other flavors of UNIX). In these speci-
fications "$ENV{USER}" is substituted by the username.
$ps2pdf ["ps2pdf %O %S %D"]
Command to convert ps to pdf file.
$ps_filter [empty]
- The postscript file filter to be run on the newly produced
+ The postscript file filter to be run on the newly produced
postscript file before other processing. Equivalent to specify-
ing the -pF option.
$ps_previewer ["start gv %O %S", but "start %O %S" under MS-WINDOWS]
- The command to invoke a ps-previewer. (The default under MS-
- WINDOWS will cause to be run whatever command the system has
+ The command to invoke a ps-previewer. (The default under MS-
+ WINDOWS will cause to be run whatever command the system has
associated with .ps files.)
- Note that gv could be used with the -watch option updates its
- display whenever the postscript file changes, whereas ghostview
- does not. However, different versions of gv have slightly dif-
- ferent ways of writing this option. You can configure this
+ Note that gv could be used with the -watch option updates its
+ display whenever the postscript file changes, whereas ghostview
+ does not. However, different versions of gv have slightly dif-
+ ferent ways of writing this option. You can configure this
variable apppropriately.
WARNING: Linux systems may have installed one (or more) versions
- of gv under different names, e.g., ggv, kghostview, etc, but
+ of gv under different names, e.g., ggv, kghostview, etc, but
perhaps not one called gv.
- $ps_previewer_landscape ["start gv -swap %O %S", but "start %O %S"
+ $ps_previewer_landscape ["start gv -swap %O %S", but "start %O %S"
under MS-WINDOWS]
The command to invoke a ps-previewer in landscape mode.
$ps_update_command [""]
- When the postscript previewer is set to be updated by running a
- command, this is the command that is run. See the information
- for the variable $ps_update_method.
+ When the postscript previewer is set to be updated by running a
+ command, this is the command that is run. See the information
- $ps_update_method [0 under UNIX, 1 under MS-Windows]
- How the postscript viewer updates its display when the ps file
- has changed. See the information on the variable
- $dvi_update_method for the codes. (Note that information needs
- be changed slightly so that for the value 4, to run a command to
- do the update, the command is specified by the variable
- $ps_update_command, and for the value 2, to specify update by
-
- 18 April 2010 25
+ 10 May 2010 25
@@ -1677,15 +1689,30 @@ LATEXMK(1L) LATEXMK(1L)
LATEXMK(1L) LATEXMK(1L)
+ for the variable $ps_update_method.
+
+ $ps_update_method [0 under UNIX, 1 under MS-Windows]
+ How the postscript viewer updates its display when the ps file
+ has changed. See the information on the variable
+ $dvi_update_method for the codes. (Note that information needs
+ be changed slightly so that for the value 4, to run a command to
+ do the update, the command is specified by the variable
+ $ps_update_command, and for the value 2, to specify update by
signal, the signal is specified by $ps_update_signal.)
- $ps_update_signal [Under UNIX: SIGHUP, which is a system-dependent
+ $ps_update_signal [Under UNIX: SIGHUP, which is a system-dependent
value]
- The number of the signal that is sent to the pdf viewer when it
- is updated by sending a signal -- see $ps_update_method. The
+ The number of the signal that is sent to the pdf viewer when it
+ is updated by sending a signal -- see $ps_update_method. The
default value is the one appropriate for gv on a UNIX system.
+
+ $pvc_view_file_via_temporary [1]
+ The same as $always_view_file_via_temporary, except that it only
+ applies in preview-continuous mode (-pvc option).
+
+
$quote_filenames [1]
This specifies whether substitutions for placeholders in command
specifications (as in $pdflatex) are surrounded by double
@@ -1721,6 +1748,18 @@ LATEXMK(1L) LATEXMK(1L)
$tmpdir to the value of the first of whichever of the system
environment variables TMPDIR or TEMP exists, otherwise to the
current directory. Under other operating systems (expected to
+
+
+
+ 10 May 2010 26
+
+
+
+
+
+LATEXMK(1L) LATEXMK(1L)
+
+
be UNIX/Linux, including OS-X), the default is the value of the
system environment variable TMPDIR if it exists, otherwise
"/tmp".
@@ -1735,18 +1774,6 @@ LATEXMK(1L) LATEXMK(1L)
CUSTOM DEPENDENCIES
In any RC file a set of custom dependencies can be set up to convert a
file with one extension to a file with another. An example use of this
-
-
-
- 18 April 2010 26
-
-
-
-
-
-LATEXMK(1L) LATEXMK(1L)
-
-
would be to allow latexmk to convert a .fig file to .eps to be included
in the .tex file.
@@ -1792,30 +1819,30 @@ LATEXMK(1L) LATEXMK(1L)
the destination file (the one with the to-extension) is out-of-date
with respect to the corresponding source file.
- To make the new destination file, the Perl subroutine specified in the
- rule is invoked, with an argument that is the base name of the files in
- question. Simple cases just involve a subroutine invoking an external
- program; this can be done by following the templates below, even by
- those without knowledge of the Perl programming language. Of course,
- experts could do something much more elaborate.
- One other item in each custom-dependency rule labelled "must" above
- specifies how the rule should be applied when the source file fails to
- exist.
- A simple and typical example of code in an initialization rcfile is
+ 10 May 2010 27
- 18 April 2010 27
+LATEXMK(1L) LATEXMK(1L)
+ To make the new destination file, the Perl subroutine specified in the
+ rule is invoked, with an argument that is the base name of the files in
+ question. Simple cases just involve a subroutine invoking an external
+ program; this can be done by following the templates below, even by
+ those without knowledge of the Perl programming language. Of course,
+ experts could do something much more elaborate.
-LATEXMK(1L) LATEXMK(1L)
+ One other item in each custom-dependency rule labelled "must" above
+ specifies how the rule should be applied when the source file fails to
+ exist.
+ A simple and typical example of code in an initialization rcfile is
add_cus_dep( 'fig', 'eps', 0, 'fig2eps' );
sub fig2eps {
@@ -1863,30 +1890,30 @@ LATEXMK(1L) LATEXMK(1L)
between operating systems, command shells and individual pieces of
software, so this code may not always work.
- If you use pdflatex instead of latex, then you will probably prefer to
- convert your graphics files to pdf format, in which case you would
- replace the above code in an initialization file by
- add_cus_dep( 'fig', 'pdf, 0, 'fig2pdf' );
- sub fig2pdf {
- system("fig2dev -Lpdf $_[0].fig $_[0].pdf");
- }
- If you have some general custom dependencies defined in the system or
- user initialization file, you may find that for a particular project
- they are undesirable. So you might want to delete the unneeded ones.
+ 10 May 2010 28
- 18 April 2010 28
+LATEXMK(1L) LATEXMK(1L)
-LATEXMK(1L) LATEXMK(1L)
+ If you use pdflatex instead of latex, then you will probably prefer to
+ convert your graphics files to pdf format, in which case you would
+ replace the above code in an initialization file by
+ add_cus_dep( 'fig', 'pdf, 0, 'fig2pdf' );
+ sub fig2pdf {
+ system("fig2dev -Lpdf $_[0].fig $_[0].pdf");
+ }
+ If you have some general custom dependencies defined in the system or
+ user initialization file, you may find that for a particular project
+ they are undesirable. So you might want to delete the unneeded ones.
For example, you remove any "fig" to "eps" rule by the line
remove_cus_dep( 'fig', 'eps' );
@@ -1936,19 +1963,8 @@ LATEXMK(1L) LATEXMK(1L)
Glossaries can be dealt with similarly.
-OLD METHOD OF DEFINING CUSTOM DEPENDENCIES
- In previous versions of latexmk, the only method of defining custom
- dependencies was to directly manipulate the table of custom dependen-
- cies. This is contained in the @cus_dep_list array. It is an array of
- strings, and each string in the array has four items in it, each sepa-
- rated by a space, the from-extension, the to-extension, the "must"
- item, and the name of the subroutine for the custom dependency. These
- were all defined above.
-
-
-
- 18 April 2010 29
+ 10 May 2010 29
@@ -1957,6 +1973,15 @@ OLD METHOD OF DEFINING CUSTOM DEPENDENCIES
LATEXMK(1L) LATEXMK(1L)
+OLD METHOD OF DEFINING CUSTOM DEPENDENCIES
+ In previous versions of latexmk, the only method of defining custom
+ dependencies was to directly manipulate the table of custom dependen-
+ cies. This is contained in the @cus_dep_list array. It is an array of
+ strings, and each string in the array has four items in it, each sepa-
+ rated by a space, the from-extension, the to-extension, the "must"
+ item, and the name of the subroutine for the custom dependency. These
+ were all defined above.
+
An example of the old method of defining custom dependencies is as fol-
lows. It is the code in an RC file to ensure automatic conversion of
.fig files to .eps files:
@@ -2002,23 +2027,15 @@ THANKS TO
AUTHOR
Current version, by John Collins (username collins at node
- phys.psu.edu). (Version 4.15c).
+ phys.psu.edu). (Version 4.16).
Released version can be obtained from CTAN: <http://www.tug.org/tex-
archive/support/latexmk/>, and from the author's website
<http://www.phys.psu.edu/~collins/software/latexmk/>.
- Modifications and enhancements by Evan McLean (Version 2.0)
- Original script called "go" by David J. Musliner (RCS Version 3.2)
-
-
-
-
-
-
- 18 April 2010 30
+ 10 May 2010 30
@@ -2027,6 +2044,8 @@ AUTHOR
LATEXMK(1L) LATEXMK(1L)
+ Modifications and enhancements by Evan McLean (Version 2.0)
+ Original script called "go" by David J. Musliner (RCS Version 3.2)
@@ -2087,7 +2106,6 @@ LATEXMK(1L) LATEXMK(1L)
-
- 18 April 2010 31
+ 10 May 2010 31
diff --git a/Master/texmf-dist/scripts/latexmk/latexmk.pl b/Master/texmf-dist/scripts/latexmk/latexmk.pl
index 7f98a337b6b..7372174cc9f 100755
--- a/Master/texmf-dist/scripts/latexmk/latexmk.pl
+++ b/Master/texmf-dist/scripts/latexmk/latexmk.pl
@@ -108,8 +108,8 @@ use warnings;
$my_name = 'latexmk';
$My_name = 'Latexmk';
-$version_num = '4.15c';
-$version_details = "$My_name, John Collins, 18 April 2010";
+$version_num = '4.16';
+$version_details = "$My_name, John Collins, 10 May 2010";
use Config;
@@ -178,6 +178,9 @@ else {
##
## Modification log from 22 Jan 2010 onwards in detail
##
+## 10 May 2010, John Collins Deal with filenames in log file that are
+## messed up by pdfTeX warnings not preceeded
+## by a new line
## 18 Apr 2010, John Collins Clean up comment from previous mod.
## 16 Apr 2010, John Collins V. 4.15c. Correct line wrapping issue.
## 12 Apr 2010, John Collins V. 4.15b. Change
@@ -2891,10 +2894,32 @@ sub parse_logB {
my $delegated_output = ""; # and output file. (Don't put in
# data structure until block is ended.)
my %new_conversions = ();
+ my @retries = ();
LINE:
- while( $line <= $#lines ) {
- $_ = $lines[$line];
- $line ++;
+ while( ($line <= $#lines) || ($#retries > -1) ) {
+ if ($#retries > -1) {
+ $_ = pop @retries;
+ }
+ else {
+ $_ = $lines[$line];
+ $line ++;
+ }
+ if ( /^! pdfTeX warning/ || /^pdfTeX warning/ ) {
+ # This kind of warning is produced by some versions of pdftex
+ # or produced by my reparse of warnings from other
+ # versions.
+ next;
+ }
+ elsif ( /^(.+)(pdfTeX warning.*)$/ ) {
+ # Line contains a pdfTeX warnings that may have been
+ # inserted directly after other material without an
+ # intervening new line. I think pdfTeX always inserts a
+ # newline after the warning. (From examination of source
+ # code.)
+ push @retries, $1;
+ # But continue parsing the original line, in case it was a
+ # misparse, e.g., of a filename ending in 'pdfTeX';
+ }
if ( $line == 1 ){
if ( /^This is / ) {
# First line OK
diff --git a/Master/texmf/doc/man/man1/latexmk.1 b/Master/texmf/doc/man/man1/latexmk.1
index c8c5016e1b8..917435b18b1 100644
--- a/Master/texmf/doc/man/man1/latexmk.1
+++ b/Master/texmf/doc/man/man1/latexmk.1
@@ -1,4 +1,4 @@
-.TH LATEXMK 1L "18 April 2010" ""
+.TH LATEXMK 1L "10 May 2010" ""
.SH NAME
latexmk \- generate LaTeX document
.SH SYNOPSIS
@@ -786,6 +786,23 @@ the string.
.PP
Default values are indicated in brackets.
.TP
+.B $always_view_file_via_temporary [0]
+Whether ps and pdf files are initially to be made in a temporary
+directory and then moved to the final location. (This applies to
+dvips, dvipdf, and ps2pdf operations, and the filtering operators on
+dvi and ps files. It does not apply to pdflatex, unfortunately.)
+
+This use of a temporary file solves a problem that the making of these
+files can occupy a substantial time. If a viewer sees that the file
+has changed, it reads the new file, and this can cause havoc if the
+program writing the file has not yet finished its work.
+
+See the \fI$pvc_view_file_via_temporary\fR variable for a setting that
+applies only if preview-continuous mode (-pvc option) is used. See
+\fI$tmpdir\fR for the setting of the directory where the temporary
+file is created.
+
+.TP
.B $banner [0]
If nonzero, the banner message is printed across each page when
converting the dvi file to postscript. Without modifying the variable
@@ -1406,6 +1423,12 @@ value 2, to specify update by signal, the signal is specified by
The number of the signal that is sent to the pdf viewer when it is
updated by sending a signal -- see \fI$ps_update_method\fR. The
default value is the one appropriate for gv on a UNIX system.
+
+.TP
+.B $pvc_view_file_via_temporary [1]
+The same as \fI$always_view_file_via_temporary\fR, except that it only
+applies in preview-continuous mode (-pvc option).
+
.TP
.B $quote_filenames [1]
This specifies whether substitutions for placeholders in command
@@ -1677,7 +1700,7 @@ e-mail addresses are not written in their standard form to avoid being
harvested by worms and viruses.)
.SH AUTHOR
Current version, by John Collins (username collins at node phys.psu.edu).
-(Version 4.15c).
+(Version 4.16).
Released version can be obtained from CTAN:
<http://www.tug.org/tex-archive/support/latexmk/>, and from the
diff --git a/Master/texmf/doc/man/man1/latexmk.man1.pdf b/Master/texmf/doc/man/man1/latexmk.man1.pdf
index b80445710c5..3b064de0cf3 100644
--- a/Master/texmf/doc/man/man1/latexmk.man1.pdf
+++ b/Master/texmf/doc/man/man1/latexmk.man1.pdf
Binary files differ