[PATCH] Support Android NDK (which has neither futimes nor futimens)
Neil Henning
llvm at neil-henning.co.uk
Wed Dec 11 07:15:09 PST 2013
As per the discussion on the llvm-commits mailing list - I've simplified the fix.
I've taken Alp Toker's approach but removed all mention of ANDROID from the patch, instead allowing setLastModificationAndAccessTime to gracefully fail at runtime should a platform not have support for futimes or futimens.
Hi rafael.espindola, chandlerc,
http://llvm-reviews.chandlerc.com/D2357
CHANGE SINCE LAST DIFF
http://llvm-reviews.chandlerc.com/D2357?vs=5971&id=6024#toc
Files:
lib/Support/Unix/Path.inc
Index: lib/Support/Unix/Path.inc
===================================================================
--- lib/Support/Unix/Path.inc
+++ lib/Support/Unix/Path.inc
@@ -537,7 +537,8 @@
Times[1] = Times[0];
if (::futimes(FD, Times))
#else
-#error Missing futimes() and futimens()
+#warning Missing futimes() and futimens()
+ return make_error_code(errc::operation_not_permitted);
#endif
return error_code(errno, system_category());
return error_code::success();
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D2357.2.patch
Type: text/x-patch
Size: 474 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20131211/eeb79fed/attachment.bin>
More information about the llvm-commits
mailing list