diff options
author | Jan Beich <jbeich@FreeBSD.org> | 2016-03-11 10:42:54 +0000 |
---|---|---|
committer | Jan Beich <jbeich@FreeBSD.org> | 2016-03-11 10:42:54 +0000 |
commit | bd250ce6b8b8e6ba6c8f9f9156b94d3eb3ed9a0d (patch) | |
tree | 23f79c8d030b0fd17a5fab08039cab54f9b2496f /sysutils/freefilesync | |
parent | cf3c9b550cec040918233f403bfdcef74d20c361 (diff) |
Notes
Diffstat (limited to 'sysutils/freefilesync')
-rw-r--r-- | sysutils/freefilesync/Makefile | 2 | ||||
-rw-r--r-- | sysutils/freefilesync/files/patch-zen_file__access.cpp | 23 |
2 files changed, 25 insertions, 0 deletions
diff --git a/sysutils/freefilesync/Makefile b/sysutils/freefilesync/Makefile index d0a62bc0ca67..f337c604bee3 100644 --- a/sysutils/freefilesync/Makefile +++ b/sysutils/freefilesync/Makefile @@ -17,6 +17,8 @@ LIB_DEPENDS= libboost_system.so:${PORTSDIR}/devel/boost-libs \ libnotify.so:${PORTSDIR}/devel/libnotify WRKSRC= ${WRKDIR}/FreeFileSync/Source +DOS2UNIX_WRKSRC=${WRKDIR} +DOS2UNIX_GLOB= *.cpp *.h USES= compiler:c++14-lang dos2unix gmake pkgconfig zip USE_LDCONFIG= yes diff --git a/sysutils/freefilesync/files/patch-zen_file__access.cpp b/sysutils/freefilesync/files/patch-zen_file__access.cpp new file mode 100644 index 000000000000..385996b71b9d --- /dev/null +++ b/sysutils/freefilesync/files/patch-zen_file__access.cpp @@ -0,0 +1,23 @@ +--- ../../zen/file_access.cpp.orig 2016-01-11 12:13:10 UTC ++++ ../../zen/file_access.cpp +@@ -877,6 +877,11 @@ void setFileTimeRaw(const Zstring& fileP + //https://sourceforge.net/p/freefilesync/discussion/open-discussion/thread/218564cf/ + newTimes[1] = modTime; //modification time + ++#if defined(__FreeBSD__) ++#include <osreldate.h> ++#if __FreeBSD_version < 1002506 || (__FreeBSD_version >= 1100000 && __FreeBSD_version < 1100056) ++ throw ErrorLinuxFallbackToUtimes(L""); ++#else + //=> using open()/futimens() for regular files and utimensat(AT_SYMLINK_NOFOLLOW) for symlinks is consistent with "cp" and "touch"! + if (procSl == ProcSymlink::FOLLOW) + { +@@ -898,6 +903,8 @@ void setFileTimeRaw(const Zstring& fileP + if (::utimensat(AT_FDCWD, filePath.c_str(), newTimes, AT_SYMLINK_NOFOLLOW) != 0) + THROW_LAST_FILE_ERROR(replaceCpy(_("Cannot write modification time of %x."), L"%x", fmtPath(filePath)), L"utimensat"); + } ++#endif ++#endif + } + + |