canonicalize_file_name() is a GNU-extension.
Replaced with call to realpath() to build on non-Linux systems, such as Mac OSX.
This commit is contained in:
parent
ecad249ae2
commit
7943d8ce53
|
@ -25,7 +25,7 @@
|
||||||
#ifndef _WIN32 // POSIX-style system
|
#ifndef _WIN32 // POSIX-style system
|
||||||
#include <glob.h>
|
#include <glob.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
#include <stdlib.h> // canonicalize_file_name
|
#include <stdlib.h>
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifndef _WIN32
|
#ifndef _WIN32
|
||||||
|
@ -58,7 +58,7 @@ void FileListerUnix::recursiveAddFiles2(std::vector<std::string> &relative,
|
||||||
if (filename[filename.length()-1] != '/')
|
if (filename[filename.length()-1] != '/')
|
||||||
{
|
{
|
||||||
// File
|
// File
|
||||||
char * const fname = canonicalize_file_name(filename.c_str());
|
char* const fname = realpath(filename.c_str(), NULL);
|
||||||
if (!fname)
|
if (!fname)
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue