[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: More Android patches

From: Bruno Haible
Subject: Re: More Android patches
Date: Thu, 19 Jan 2023 00:07:51 +0100

Po Lu wrote:
> With the NDK 16.1.4479499 and __ANDROID_API__ set to 8, utimensat and
> ftruncate appear in libc.so but not in the system headers.

Thanks for the report. The problem, however, is much larger than these
two symbols. Previously I handled the __INTRODUCED_IN that I found in
the Termux /usr/include files. But you are right: Any developer can use
any NDK from 16b to 25b, since these are those than a developer can
currently download through Android Studio.

In a first step, I searched for the symbols marked with
for x = 2 ... 35. This gave me the symbol lists in the attached

In a second step, I looked for occurrences to AC_CHECK_FUNC[S]
or AC_CHECK_FUNCS_ONCE of these symbols. E.g.
  for s in `cat in-8.txt`; do grep -rw "$s" m4 modules | grep CHECK_FUNC; echo 
; done
and replaced these with gl_CHECK_FUNCS_ANDROID invocations.

> REPLACE_UTIMENSAT is not defined.

For the moment, it appears OK to treat these symbols like absent
from the header files and from libc (i.e. HAVE_UTIMENSAT=0).

In theory, you are right: it will be better to mark them as REPLACEd,
so that Gnulib will define a function named 'rpl_utimensat' rather than
'utimensat'. But as this matters only for rare situations with shared
libraries (since on Android, everything links against libc.so, not libc.a),
it can wait a bit.

Here's my current work-in-progress; I'll continue with it tomorrow.

Attachment: android-introduced.zip
Description: Zip archive

Attachment: 0001-Fix-warnings-for-functions-introduced-in-Android-API.patch
Description: Text Data

Attachment: 0002-Fix-warnings-for-functions-introduced-in-Android-API.patch
Description: Text Data

Attachment: 0003-Fix-warnings-for-functions-introduced-in-Android-API.patch
Description: Text Data

Attachment: 0004-Fix-warnings-for-functions-introduced-in-Android-API.patch
Description: Text Data

Attachment: 0005-Fix-warnings-for-functions-introduced-in-Android-API.patch
Description: Text Data

Attachment: 0006-Fix-warnings-for-functions-introduced-in-Android-API.patch
Description: Text Data

reply via email to

[Prev in Thread] Current Thread [Next in Thread]