diff options
author | Peter Breitenlohner <peb@mppmu.mpg.de> | 2010-04-21 10:54:29 +0000 |
---|---|---|
committer | Peter Breitenlohner <peb@mppmu.mpg.de> | 2010-04-21 10:54:29 +0000 |
commit | 97aaaf3c94bd0e59a6e23015d8713c29bb0382a1 (patch) | |
tree | 00f8a29a0228ec6c69f871c912b67763731b12c2 /Build | |
parent | 119068dad278743ad2aedb15184947628a30d558 (diff) |
build system: more texk/web2c/ cleanup
git-svn-id: svn://tug.org/texlive/trunk@17953 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Build')
-rw-r--r-- | Build/source/texk/web2c/web2c/ChangeLog | 1 | ||||
-rw-r--r-- | Build/source/texk/web2c/web2c/coerce.h | 6 | ||||
-rwxr-xr-x | Build/source/texk/web2c/web2c/convert | 54 | ||||
-rw-r--r-- | Build/source/texk/web2c/web2c/splitup.c | 8 |
4 files changed, 32 insertions, 37 deletions
diff --git a/Build/source/texk/web2c/web2c/ChangeLog b/Build/source/texk/web2c/web2c/ChangeLog index 0d0f25b6f36..89f963309f6 100644 --- a/Build/source/texk/web2c/web2c/ChangeLog +++ b/Build/source/texk/web2c/web2c/ChangeLog @@ -1,6 +1,7 @@ 2010-04-20 Peter Breitenlohner <peb@mppmu.mpg.de> * coerce.h: Remove luaTeX specific code. + * convert: Reorganize (common code for TeX and MF). 2010-04-18 Peter Breitenlohner <peb@mppmu.mpg.de> diff --git a/Build/source/texk/web2c/web2c/coerce.h b/Build/source/texk/web2c/web2c/coerce.h index d2feb82a340..6b36130ad21 100644 --- a/Build/source/texk/web2c/web2c/coerce.h +++ b/Build/source/texk/web2c/web2c/coerce.h @@ -46,10 +46,7 @@ extern string gettexstring (strnumber); extern boolean isnewsource (strnumber, int); extern poolpointer makesrcspecial (strnumber, int); extern void remembersourceinfo (strnumber, int); -#endif -/* When compiling the lib in luatexdir, we -DpdfTeX so code can be more - easily shared. But we can't have both pdftexd.h and luatexd.h, etc. */ #ifdef pdfTeX #include <pdftexdir/pdftex.h> #endif /* pdfTeX */ @@ -58,6 +55,7 @@ extern void remembersourceinfo (strnumber, int); #include <xetexdir/xetex.h> #endif /* XeTeX */ -#if defined(TeX) && defined(__SyncTeX__) +#ifdef __SyncTeX__ #include <synctexdir/synctex.h> #endif +#endif /* TeX */ diff --git a/Build/source/texk/web2c/web2c/convert b/Build/source/texk/web2c/web2c/convert index 27f22748c2a..b08527a4734 100755 --- a/Build/source/texk/web2c/web2c/convert +++ b/Build/source/texk/web2c/web2c/convert @@ -49,12 +49,6 @@ output="> $cfile" output_files="$cfile $basefile.h" case $basefile in - bibtex|pbibtex) - midcmd="| sed -f $srcdir/web2c/cvtbib.sed" - ;; -esac - -case $basefile in pbibtex|pdvitype|ppltotf|ptftopl) more_defines="$srcdir/ptexdir/ptex.defines" hfile=ptexdir/kanji.h @@ -62,29 +56,31 @@ case $basefile in esac case $basefile in - mf) - more_defines="$srcdir/web2c/texmf.defines $srcdir/web2c/mfmp.defines" - precmd="| sed -f $srcdir/web2c/cvtmf1.sed" - web2c_options="-m -c${basefile}coerce" - hfile=texmfmp.h - midcmd="| sed -f $srcdir/web2c/cvtmf2.sed" - postcmd="| ./web2c/splitup $splitup_options $basefile" - cfile=${basefile}0.c # last output file, or thereabouts - output= - output_files="$basefile[0-9].c ${basefile}ini.c ${basefile}d.h \ - ${basefile}coerce.h" + bibtex|pbibtex) + midcmd="| sed -f $srcdir/web2c/cvtbib.sed" ;; - tex|etex|pdftex|aleph|xetex|ptex) - more_defines="$srcdir/web2c/texmf.defines $srcdir/synctexdir/synctex.defines" - prog_defines="$srcdir/${basefile}dir/$basefile.defines" - if test -f $prog_defines; then - more_defines="$more_defines $prog_defines" - fi - web2c_options="-t -c${basefile}coerce" + mf|tex|aleph|etex|pdftex|ptex|xetex) + case $basefile in + mf) + more_defines="$srcdir/web2c/texmf.defines $srcdir/web2c/mfmp.defines" + precmd="| sed -f $srcdir/web2c/cvtmf1.sed" + web2c_options="-m -c${basefile}coerce" + midcmd="| sed -f $srcdir/web2c/cvtmf2.sed" + ;; + + *) + more_defines="$srcdir/web2c/texmf.defines $srcdir/synctexdir/synctex.defines" + prog_defines="$srcdir/${basefile}dir/$basefile.defines" + if test -f $prog_defines; then + more_defines="$more_defines $prog_defines" + fi + web2c_options="-t -c${basefile}coerce" + fixwrites_options=-t + ;; + esac hfile=texmfmp.h - fixwrites_options=-t - postcmd="| ./web2c/splitup $splitup_options ${basefile}" + postcmd="| ./web2c/splitup $splitup_options $basefile" cfile=${basefile}0.c # last output file, or thereabouts output= output_files="$basefile[0-9].c ${basefile}ini.c ${basefile}d.h \ @@ -118,10 +114,10 @@ fi case $basefile in bibtex|pbibtex) - sed -e 's/(buftype)//g' -e 's/(pdstype)//g' <${basefile}.h >x${basefile}.h - mv x${basefile}.h ${basefile}.h + sed -e 's/(buftype)//g' -e 's/(pdstype)//g' <$basefile.h >x$basefile.h + mv x$basefile.h $basefile.h ;; - tex|etex|luatex|pdftex|aleph|mf|xetex|ptex) + mf|tex|aleph|etex|pdftex|ptex|xetex) sleep 2 # so timestamps are definitely later, to avoid make weirdness cat $srcdir/web2c/coerce.h >>${basefile}coerce.h touch ${basefile}d.h diff --git a/Build/source/texk/web2c/web2c/splitup.c b/Build/source/texk/web2c/web2c/splitup.c index 1f798cdf441..51c08345bfb 100644 --- a/Build/source/texk/web2c/web2c/splitup.c +++ b/Build/source/texk/web2c/web2c/splitup.c @@ -123,14 +123,14 @@ main (int argc, string *argv) } else if (STREQ (output_name, "pdftex")) { fputs ("#define INITEX\n#define TeX\n#define pdfTeX\n", out); coerce = "pdftexcoerce.h"; - } else if (STREQ (output_name, "xetex")) { - fputs ("#define INITEX\n#define TeX\n#define XeTeX\n", out); - coerce = "xetexcoerce.h"; } else if (STREQ (output_name, "ptex")) { fputs ("#define INITEX\n#define TeX\n#define pTeX\n", out); coerce = "ptexcoerce.h"; + } else if (STREQ (output_name, "xetex")) { + fputs ("#define INITEX\n#define TeX\n#define XeTeX\n", out); + coerce = "xetexcoerce.h"; } else - FATAL1 ("Can only split mf, tex, etex, aleph, pdftex, or xetex,\n not %s", output_name); + FATAL1 ("Can only split mf, tex, aleph, etex, pdftex, ptex, or xetex,\n not %s", output_name); coerce_len = strlen (coerce); |