jlaurens / synctex

Synchronization for TeX
MIT License
57 stars 19 forks source link

stdarg.h missing #7

Closed stloeffler closed 6 years ago

stloeffler commented 6 years ago

At least on Mac OS X 10.11 with XCode 7.3 as used by travis-ci, compiling the current TeXLive version (which I believe is the 2017 branch?) fails with

synctex_parser.c:8155:9: warning: implicit declaration of function 'va_start' is invalid in C99 [-Wimplicit-function-declaration]
        va_start(va, format);
        ^

and

synctex_parser.c:8159:9: warning: implicit declaration of function 'va_end' is invalid in C99 [-Wimplicit-function-declaration]
        va_end(va);
        ^

followed by

Undefined symbols for architecture x86_64:
  "_va_end", referenced from:
      __synctex_updater_print in synctex_parser.c.o
      __synctex_updater_print_gz in synctex_parser.c.o
  "_va_start", referenced from:
      __synctex_updater_print in synctex_parser.c.o
      __synctex_updater_print_gz in synctex_parser.c.o

(see texworks job 140.1).

Adding #include <stdarg.h> at the beginning of synctex_parser.c (analogously to synctex_parser_utils.c) fixes this (see texworks job 142.1)

jlaurens commented 6 years ago

Fixed Thanks