[tlbuild] build failure: texk/dvisvgm/dvisvgm-0.8.7/src/FileSystem.cpp includes <unistd.h> only for GCC, but it is needed on all posix systems

Vladimir Volovich vvv at vsu.ru
Fri May 28 13:08:06 CEST 2010


Hi!

i've got a build failure (on AIX):

source='dvisvgm-0.8.7/src/FileSystem.cpp' object='FileSystem.o' libtool=no \
        DEPDIR=.deps depmode=aix /bin/bash ../../../texk/dvisvgm/../../build-aux/depcomp \
        xlC -DHAVE_CONFIG_H -I. -I../../../texk/dvisvgm -I../../../texk/dvisvgm/dvisvgm-0.8.7/src -I../../../texk/dvisvgm/dvisvgm-0.8.7/potracelib -I/usr/local/vvv/src/source/Work/texk -I/usr/local/vvv/src/source/texk `cat /usr/local/vvv/src/source/Work/libs/freetype2/ft-includes` -I/usr/local/vvv/src/source/Work/libs/zlib/include   -I/opt/freeware/include -DUSE_STDLIB_WORKAROUNDS  -O2 -qmaxmem=262144 -qarch=com -qlanglvl=extended -c -o FileSystem.o `test -f 'dvisvgm-0.8.7/src/FileSystem.cpp' || echo '../../../texk/dvisvgm/'`dvisvgm-0.8.7/src/FileSystem.cpp
"../../../texk/dvisvgm/dvisvgm-0.8.7/src/FileSystem.cpp", line 50.16: 1540-0274 (S) The name lookup for "unlink" did not find a declaration.
"../../../texk/dvisvgm/dvisvgm-0.8.7/src/FileSystem.cpp", line 86.16: 1540-0130 (S) "::getcwd" is not declared.
"../../../texk/dvisvgm/dvisvgm-0.8.7/src/FileSystem.cpp", line 151.17: 1540-0274 (S) The name lookup for "rmdir" did not find a declaration.
gmake[3]: *** [FileSystem.o] Error 1
gmake[3]: Leaving directory `/usr/local/vvv/src/source/Work/texk/dvisvgm'

texk/dvisvgm/dvisvgm-0.8.7/src/FileSystem.cpp has:

#ifdef __GNUC__
#include <unistd.h>
#endif

after removing "#ifdef __GNUC__" and "#endif", compilation proceeds. it
seems that it should be changed to something like

#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif

Best,
v.


More information about the tlbuild mailing list