diff --git a/src/fileio.cpp b/src/fileio.cpp index b837d4005f..b59de557b3 100644 --- a/src/fileio.cpp +++ b/src/fileio.cpp @@ -657,6 +657,9 @@ bool ExtractTar(const std::string &tar_filename, Subdirectory subdir) * @note defined in the OS related files (win32.cpp, unix.cpp etc) */ extern void DetermineBasePaths(std::string_view exe); + +/** Mimicks the getcwd from POSIX for Windows. */ +char *getcwd(char *buf, size_t size); #else /* defined(_WIN32) */ /** diff --git a/src/stdafx.h b/src/stdafx.h index f72b1ad9ee..cf75d44b1a 100644 --- a/src/stdafx.h +++ b/src/stdafx.h @@ -157,8 +157,6 @@ using namespace std::literals::string_view_literals; #if !defined(STRGEN) && !defined(SETTINGSGEN) # if defined(_WIN32) - char *getcwd(char *buf, size_t size); - std::string FS2OTTD(std::wstring_view name); std::wstring OTTD2FS(std::string_view name); # elif defined(WITH_ICONV)