<html><head><meta http-equiv="content-type" content="text/html; charset=utf-8"></head><body style="overflow-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;">Hi Even,<div><br></div><div>This patch worked fine to resolve the ‘pread64’ error on iOS and Mac Catalyst.<div><br></div><div>Thank you.</div><div>-Nik<br><div><br><blockquote type="cite"><div>On 12 Nov 2022, at 12:12 pm, Even Rouault <even.rouault@spatialys.com> wrote:</div><br class="Apple-interchange-newline"><div><div>Nik,<br><br>actually I've just modified it to the following that still tries to detect pread(). Can you test and report?<br><br>diff --git a/cmake/helpers/configure.cmake b/cmake/helpers/configure.cmake<br>index f52ea47db3..0939ffadda 100644<br>--- a/cmake/helpers/configure.cmake<br>+++ b/cmake/helpers/configure.cmake<br>@@ -241,16 +241,6 @@ else ()<br> check_type_size("off_t" SIZEOF_OFF_T)<br><br> check_function_exists(pread64 HAVE_PREAD64)<br>- if( NOT HAVE_PREAD64 )<br>- check_c_source_compiles(<br>- "<br>- #include <sys/types.h><br>- #include <sys/uio.h><br>- #include <unistd.h><br>- int main() { pread(0, NULL, 0, 0); return 0; }<br>- "<br>- HAVE_PREAD_BSD)<br>- endif()<br><br> check_function_exists(ftruncate64 HAVE_FTRUNCATE64)<br> if (HAVE_FTRUNCATE64)<br>@@ -280,6 +270,19 @@ else ()<br> unset(HAVE_FSEEK64 CACHE)<br> unset(HAVE_STATVFS64)<br> unset(HAVE_STATVFS64 CACHE)<br>+ unset(HAVE_PREAD64)<br>+ unset(HAVE_PREAD64 CACHE)<br>+ endif()<br>+<br>+ if( NOT HAVE_PREAD64 )<br>+ check_c_source_compiles(<br>+ "<br>+ #include <sys/types.h><br>+ #include <sys/uio.h><br>+ #include <unistd.h><br>+ int main() { pread(0, NULL, 0, 0); return 0; }<br>+ "<br>+ HAVE_PREAD_BSD)<br> endif()<br><br> set(UNIX_STDIO_64 TRUE)<br><br>Le 12/11/2022 à 02:07, Even Rouault a écrit :<br><blockquote type="cite"><br>Le 12/11/2022 à 02:00, Nik Sands a écrit :<br><blockquote type="cite">Hi GDAL devs<br><br>It appears as though ‘pread64’, introduced in 3.6.0, has broken building on iOS in the same way that other ‘…64’ errors used to occur on version 3.5.0 before being patched for 3.5.2.<br><br>The attached patch (text content also pasted below) allows the build to continue past that point for iOS (and Mac Catalyst). I’m just an ignorant hobbyist who doesn’t really understand a lot of this stuff, so please check that what I’ve done here is correct! :-) If it’s all OK, then please apply this (or similar) patch for the next release.<br></blockquote><br>Patch queued in https://github.com/OSGeo/gdal/pull/6673<br><br>Thanks<br><br></blockquote>-- <br>http://www.spatialys.com<br>My software is free, but my time generally not.<br><br></div></div></blockquote></div><br><div>
<div style="color: rgb(0, 0, 0); letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;"><div style="color: rgb(0, 0, 0); letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;"><div style="color: rgb(0, 0, 0); letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;"><div style="color: rgb(0, 0, 0); letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;"><div style="color: rgb(0, 0, 0); letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;"><div style="color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-text-stroke-width: 0px;"><br class="Apple-interchange-newline">========================================================</div><div style="color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-text-stroke-width: 0px;">NIK SANDS</div><div style="color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-text-stroke-width: 0px;">Line Tamer | Time Traveller | Space Cadet</div></div></div></div></div></div>
</div>
<br></div></div></body></html>