summaryrefslogtreecommitdiff
path: root/Build/source/texk/web2c/synctexdir
diff options
context:
space:
mode:
authorPeter Breitenlohner <peb@mppmu.mpg.de>2009-03-19 13:59:30 +0000
committerPeter Breitenlohner <peb@mppmu.mpg.de>2009-03-19 13:59:30 +0000
commit0b7b2c69ec83497d9accab064da0f4ad07662d42 (patch)
treee8f22a2acecbf3035850f56beb1c8161c53cdf2d /Build/source/texk/web2c/synctexdir
parentee507bbd1fc483c58acb33cca25509a4dd81df9b (diff)
prepare for new build system
git-svn-id: svn://tug.org/texlive/trunk@12429 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Build/source/texk/web2c/synctexdir')
-rw-r--r--Build/source/texk/web2c/synctexdir/am/synctex.am172
-rw-r--r--Build/source/texk/web2c/synctexdir/am/synctex.mk42
2 files changed, 214 insertions, 0 deletions
diff --git a/Build/source/texk/web2c/synctexdir/am/synctex.am b/Build/source/texk/web2c/synctexdir/am/synctex.am
new file mode 100644
index 00000000000..03d793eac69
--- /dev/null
+++ b/Build/source/texk/web2c/synctexdir/am/synctex.am
@@ -0,0 +1,172 @@
+## texk/web2c/synctexdir/am/synctex.am: Makefile fragment for SyncTeX.
+
+## The SyncTeX tool
+
+bin_PROGRAMS += synctex
+
+synctex_SOURCES = \
+ synctexdir/synctex_main.c \
+ synctexdir/synctex_parser.c \
+ synctexdir/synctex_parser.h \
+ synctexdir/synctex_parser_local.h
+
+synctex_CPPFLAGS = -I$(srcdir)/synctexdir $(ZLIB_INCLUDES) -DSYNCTEX_USE_LOCAL_HEADER
+
+synctex_LDADD = $(ZLIB_LIBS)
+
+synctex_DEPENDENCIES = $(ZLIB_DEPEND)
+
+dist_man_MANS += synctexdir/man1/synctex.1 synctexdir/man5/synctex.5
+
+EXTRA_DIST += \
+ synctexdir/INSTALL \
+ synctexdir/Makefile \
+ synctexdir/Makefile.in \
+ synctexdir/README.txt
+
+## SyncTeX infrastructure: common for all engines
+
+EXTRA_DIST += \
+ synctexdir/synctex-common.h \
+ synctexdir/synctex-convert.sh \
+ synctexdir/synctex.c \
+ synctexdir/synctex.defines \
+ synctexdir/synctex.h
+
+## SyncTeX infrastructure: TeX
+
+if TEX_SYNCTEX
+
+tex_CPPFLAGS += -I$(srcdir)/synctexdir $(ZLIB_INCLUDES)
+
+tex_LDADD += $(ZLIB_LIBS)
+
+tex_ch_synctex = \
+ synctexdir/synctex-mem.ch0 \
+ synctexdir/synctex-mem.ch1 \
+ synctexdir/synctex-mem.ch2 \
+ synctexdir/synctex-rec.ch0 \
+ synctexdir/synctex-rec.ch1 \
+ synctexdir/synctex-rec.ch2
+
+dist_tex_SOURCES = \
+ synctexdir/synctex.h \
+ synctexdir/synctex-common.h \
+ synctexdir/synctex-tex.h
+
+nodist_tex_SOURCES += \
+ synctex.c
+
+synctex_convert_tex = && $(SHELL) $(srcdir)/synctexdir/synctex-convert.sh tex
+
+else !TEX_SYNCTEX
+
+synctex_convert_tex = && echo "warning: SyncTeX for TeX is NOT enabled"
+
+endif !TEX_SYNCTEX
+
+synctex.c: texd.h synctexdir/synctex.c $(dist_tex_SOURCES)
+ sed s/TEX-OR-MF-OR-MP/tex/ $(srcdir)/synctexdir/synctex.c >$@
+
+EXTRA_DIST += \
+ synctexdir/synctex-mem.ch0 \
+ synctexdir/synctex-mem.ch1 \
+ synctexdir/synctex-mem.ch2 \
+ synctexdir/synctex-rec.ch0 \
+ synctexdir/synctex-rec.ch1 \
+ synctexdir/synctex-rec.ch2
+
+## SyncTeX infrastructure: e-TeX
+
+if ETEX_SYNCTEX
+
+etex_CPPFLAGS += -I$(srcdir)/synctexdir $(ZLIB_INCLUDES)
+
+etex_LDADD += $(ZLIB_LIBS)
+
+etex_ch_synctex = \
+ synctexdir/synctex-mem.ch0 \
+ synctexdir/synctex-mem.ch1 \
+ synctexdir/synctex-e-mem.ch0 \
+ synctexdir/synctex-e-mem.ch1 \
+ synctexdir/synctex-rec.ch0 \
+ synctexdir/synctex-rec.ch1 \
+ synctexdir/synctex-e-rec.ch0 \
+ synctexdir/synctex-e-rec.ch1
+
+dist_etex_SOURCES = \
+ synctexdir/synctex.h \
+ synctexdir/synctex-common.h \
+ synctexdir/synctex-etex.h
+
+nodist_etex_SOURCES += \
+ synctex-e.c
+
+synctex_convert_etex = && $(SHELL) $(srcdir)/synctexdir/synctex-convert.sh etex
+
+else !ETEX_SYNCTEX
+
+synctex_convert_etex = && echo "warning: SyncTeX for e-TeX is NOT enabled"
+
+endif !ETEX_SYNCTEX
+
+synctex-e.c: etexd.h synctexdir/synctex.c $(dist_etex_SOURCES)
+ sed s/TEX-OR-MF-OR-MP/etex/ $(srcdir)/synctexdir/synctex.c >$@
+
+EXTRA_DIST += \
+ synctexdir/synctex-e-mem.ch0 \
+ synctexdir/synctex-e-mem.ch1 \
+ synctexdir/synctex-e-rec.ch0 \
+ synctexdir/synctex-e-rec.ch1
+
+## SyncTeX infrastructure: pdfTeX
+
+if PDFTEX_SYNCTEX
+
+pdftex_CPPFLAGS += -I$(srcdir)/synctexdir
+
+pdftex_ch_synctex = \
+ synctexdir/synctex-mem.ch0 \
+ synctexdir/synctex-mem.ch1 \
+ synctexdir/synctex-e-mem.ch0 \
+ synctexdir/synctex-e-mem.ch1 \
+ synctexdir/synctex-rec.ch0 \
+ synctexdir/synctex-rec.ch1 \
+ synctexdir/synctex-e-rec.ch0 \
+ synctexdir/synctex-e-rec.ch1 \
+ synctexdir/synctex-pdf-rec.ch2
+
+dist_pdftex_SOURCES = \
+ synctexdir/synctex.h \
+ synctexdir/synctex-common.h \
+ synctexdir/synctex-pdftex.h
+
+nodist_pdftex_SOURCES += \
+ synctex-pdf.c
+
+synctex_convert_pdftex = && $(SHELL) $(srcdir)/synctexdir/synctex-convert.sh pdftex
+
+else !PDFTEX_SYNCTEX
+
+synctex_convert_pdftex = && echo "warning: SyncTeX for pdfTeX is NOT enabled"
+
+endif !PDFTEX_SYNCTEX
+
+synctex-pdf.c: pdftexd.h synctexdir/synctex.c $(dist_pdftex_SOURCES)
+ sed s/TEX-OR-MF-OR-MP/pdftex/ $(srcdir)/synctexdir/synctex.c >$@
+
+EXTRA_DIST += \
+ synctexdir/synctex-pdf-rec.ch2
+
+## SyncTeX infrastructure: XeTeX
+
+EXTRA_DIST += \
+ synctexdir/synctex-xe-mem.ch2 \
+ synctexdir/synctex-xe-rec.ch2 \
+ synctexdir/synctex-xe-rec.ch3 \
+ synctexdir/synctex-xetex.h
+
+## Eventually delete these files
+##
+EXTRA_DIST += synctexdir/am/synctex.mk synctexdir/synctex.mk
+
diff --git a/Build/source/texk/web2c/synctexdir/am/synctex.mk b/Build/source/texk/web2c/synctexdir/am/synctex.mk
new file mode 100644
index 00000000000..3f3c4a0293a
--- /dev/null
+++ b/Build/source/texk/web2c/synctexdir/am/synctex.mk
@@ -0,0 +1,42 @@
+
+### SyncTeX support in xetex
+# Actually, xetex cannot build without SyncTeX because the tex.web
+# code does not provide proper entry points
+# list of change files
+xetex_ch_srcs-with_synctex-mem_only = \
+ $(synctex_dir)/synctex-mem.ch0 \
+ $(synctex_dir)/synctex-e-mem.ch0 \
+ $(synctex_dir)/synctex-e-mem.ch1 \
+ $(synctex_dir)/synctex-xe-mem.ch2
+xetex_ch_srcs-with_synctex = \
+ $(xetex_ch_srcs-with_synctex-mem_only) \
+ $(synctex_dir)/synctex-rec.ch0 \
+ $(synctex_dir)/synctex-e-rec.ch0 \
+ $(synctex_dir)/synctex-xe-rec.ch2
+xetex_ch_srcs-without_synctex =
+xetex_post_ch_srcs-with_synctex = \
+ $(synctex_dir)/synctex-xe-rec.ch3
+xetex_post_ch_srcs-without_synctex =
+# The C sources and headers
+xetex_o-with_synctex = synctex-xe.o
+xetex_o-without_synctex =
+synctex-xe.h: $(synctex_dir)/synctex.h
+ cat $(synctex_dir)/synctex.h >$@
+synctex-xetex.h: $(synctex_dir)/$@
+ cat $(synctex_dir)/$@ >$@
+synctex-xe.c: xetexd.h $(synctex_dir)/synctex.c synctex-xetex.h
+ sed s/TEX-OR-MF-OR-MP/xetex/ $(synctex_dir)/synctex.c >$@
+xetexd.h-with_synctex = if test -z "`grep __SyncTeX__ xetexd.h`";\
+ then\
+ $(synctex_common_texd);\
+ sed -f synctex_sed_command.txt xetexd.h > synctex_xetexd.h;\
+ mv synctex_xetexd.h xetexd.h;\
+ if test -z "`grep __SyncTeX__ xetexd.h`";\
+ then\
+ echo "warning: SyncTeX activation FAILED";\
+ exit 1;\
+ fi;\
+ echo "warning: SyncTeX is enabled";\
+ fi
+xetexd.h-without_synctex = echo "warning: SyncTeX is NOT enabled"
+