diff options
author | Reinhard Tartler <siretart@tauware.de> | 2020-05-10 19:17:17 -0400 |
---|---|---|
committer | Reinhard Tartler <siretart@tauware.de> | 2020-05-10 19:17:17 -0400 |
commit | 228bc06db9e262b24a6c235b1e036cc8ef78565f (patch) | |
tree | 3703ceb787cf9345600fae3939afeccca7c47719 /lib/win32/emu.h | |
parent | ffb043c482053896b0190ea5ddc1cf2ba70cb4f0 (diff) | |
parent | c5c04da3823c36f03408821cbc5019ec18613922 (diff) |
Merge commit 'c5c04da3'debian/0.13__git20200326.g8e8b63c-1
Diffstat (limited to 'lib/win32/emu.h')
-rw-r--r-- | lib/win32/emu.h | 22 |
1 files changed, 14 insertions, 8 deletions
diff --git a/lib/win32/emu.h b/lib/win32/emu.h index 91793004..9b6ec117 100644 --- a/lib/win32/emu.h +++ b/lib/win32/emu.h @@ -4,14 +4,18 @@ #ifdef WIN32 #define EMU_STRUCT_STAT struct emu_stat - #define EMU_STAT emu_stat - #define EMU_FSTAT emu_fstat - #define EMU_LSTAT emu_stat + #define EMU_STAT emu_stat + #define EMU_FSTAT emu_fstat + #define EMU_LSTAT emu_stat + #define EMU_LINK emu_link + #define EMU_UNLINK emu_unlink #else #define EMU_STRUCT_STAT struct stat - #define EMU_STAT ::stat - #define EMU_FSTAT ::fstat - #define EMU_LSTAT ::lstat + #define EMU_STAT ::stat + #define EMU_FSTAT ::fstat + #define EMU_LSTAT ::lstat + #define EMU_LINK ::link + #define EMU_UNLINK ::unlink #endif #if ! defined EMU_INCLUDE && defined WIN32 @@ -352,13 +356,15 @@ int emu_rename (const char* pOldName, const char* pNewName); #define chdir(directory) emu_chdir (directory) #define mkdir(path, mode) emu_mkdir (path) -#define link(oldpath, newpath) emu_link (oldpath, newpath) -#define unlink(file) emu_unlink (file) #define utimes(buffer, times) emu_utimes (buffer, times) #define chmod(file, mode) emu_chmod (file, mode) #define getcwd(buffer, size) emu_getcwd (buffer, size) #define rename(oldname, newname) emu_rename (oldname, newname) +// link() and unlink() conflict with Boost if implemented using macros like +// the others above, so I've removed the macros and you need to use EMU_LINK +// and EMU_UNLINK everywhere. + // Not safe to replace stat/fstat/lstat on mingw at least, as struct stat // has a 16-bit st_ino and we need a 64-bit one. // |