GTKWave (fstapi.c) needs realpath() so check for it
This commit is contained in:
parent
9fbb7f84e6
commit
818379b9bc
|
|
@ -1,7 +1,7 @@
|
||||||
#ifndef IVL_config_H /* -*- c++ -*- */
|
#ifndef IVL_config_H /* -*- c++ -*- */
|
||||||
#define IVL_config_H
|
#define IVL_config_H
|
||||||
/*
|
/*
|
||||||
* Copyright (c) 2001-2014 Stephen Williams (steve@icarus.com)
|
* Copyright (c) 2001-2015 Stephen Williams (steve@icarus.com)
|
||||||
*
|
*
|
||||||
* This source code is free software; you can redistribute it
|
* This source code is free software; you can redistribute it
|
||||||
* and/or modify it in source code form under the terms of the GNU
|
* and/or modify it in source code form under the terms of the GNU
|
||||||
|
|
@ -55,6 +55,7 @@
|
||||||
# undef HAVE_FSEEKO
|
# undef HAVE_FSEEKO
|
||||||
/* And this is needed by the fst files (copied from GTKWave). */
|
/* And this is needed by the fst files (copied from GTKWave). */
|
||||||
# undef HAVE_LIBPTHREAD
|
# undef HAVE_LIBPTHREAD
|
||||||
|
# undef HAVE_REALPATH
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Define this if you want to compile vvp with memory freeing and
|
* Define this if you want to compile vvp with memory freeing and
|
||||||
|
|
|
||||||
|
|
@ -242,6 +242,9 @@ case "${host}" in
|
||||||
esac
|
esac
|
||||||
AC_SUBST(file64_support)
|
AC_SUBST(file64_support)
|
||||||
|
|
||||||
|
# fstapi.c (from GTKWave) needs this define.
|
||||||
|
AC_CHECK_FUNCS(realpath)
|
||||||
|
|
||||||
# Check that these functions exist. They are mostly C99
|
# Check that these functions exist. They are mostly C99
|
||||||
# functions that older compilers may not yet support.
|
# functions that older compilers may not yet support.
|
||||||
AC_CHECK_FUNCS(fopen64)
|
AC_CHECK_FUNCS(fopen64)
|
||||||
|
|
|
||||||
|
|
@ -279,7 +279,6 @@ return(ftruncate(fd, length));
|
||||||
static char *fstRealpath(const char *path, char *resolved_path)
|
static char *fstRealpath(const char *path, char *resolved_path)
|
||||||
{
|
{
|
||||||
#if defined __USE_BSD || defined __USE_XOPEN_EXTENDED || defined __CYGWIN__ || defined HAVE_REALPATH
|
#if defined __USE_BSD || defined __USE_XOPEN_EXTENDED || defined __CYGWIN__ || defined HAVE_REALPATH
|
||||||
|
|
||||||
#if (defined(__MACH__) && defined(__APPLE__))
|
#if (defined(__MACH__) && defined(__APPLE__))
|
||||||
if(!resolved_path)
|
if(!resolved_path)
|
||||||
{
|
{
|
||||||
|
|
@ -297,6 +296,8 @@ if(!resolved_path)
|
||||||
}
|
}
|
||||||
return(_fullpath(resolved_path, path, PATH_MAX));
|
return(_fullpath(resolved_path, path, PATH_MAX));
|
||||||
#else
|
#else
|
||||||
|
(void)path;
|
||||||
|
(void)resolved_path;
|
||||||
return(NULL);
|
return(NULL);
|
||||||
#endif
|
#endif
|
||||||
#endif
|
#endif
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue