bug-gnulib@gnu.org mirror (unofficial)
 help / color / mirror / Atom feed
* HAVE_SYS_CDEFS_H set to empty
@ 2019-03-01 18:49 Reuben Thomas
  2019-03-01 22:44 ` Reuben Thomas
  0 siblings, 1 reply; 2+ messages in thread
From: Reuben Thomas @ 2019-03-01 18:49 UTC (permalink / raw)
  To: bug-gnulib

[-- Attachment #1: Type: text/plain, Size: 829 bytes --]

Building some code on Android 9 that uses the getopt-gnu module, I found
that HAVE_SYS_CDEFS_H was empty.

This looks wrong, but I see that it is set to empty on my GNU system which
uses glibc, and hence doesn't need getopt replacing, so the value of
HAVE_SYS_CDEFS_H (which is tested in getopt-cdefs.h) is not substituted
after #if, where its emptiness causes a syntax error on Android.

Oddly, the config.log on Android suggests that sys/cdefs.h is indeed found.

So I'm not clear what the real problem is here.

Very happy to perform further debugging if anyone can give me any pointers
as to what to look for!

(I was using a commit of gnulib from last year, and no relevant code seems
to have changed since then, but I've tested with current git master HEAD
just to confirm I get the same result.)

-- 
https://rrt.sc3d.org

[-- Attachment #2: Type: text/html, Size: 2100 bytes --]

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: HAVE_SYS_CDEFS_H set to empty
  2019-03-01 18:49 HAVE_SYS_CDEFS_H set to empty Reuben Thomas
@ 2019-03-01 22:44 ` Reuben Thomas
  0 siblings, 0 replies; 2+ messages in thread
From: Reuben Thomas @ 2019-03-01 22:44 UTC (permalink / raw)
  To: bug-gnulib

[-- Attachment #1: Type: text/plain, Size: 1181 bytes --]

Apologies, false alarm: I had tried to build the project without a magic
Android environment variable, and this caused getopt to be misdetected; I
had to remove the gnulib "lib" directory's contents in order to fix this.

On Fri, 1 Mar 2019 at 18:49, Reuben Thomas <rrt@sc3d.org> wrote:

> Building some code on Android 9 that uses the getopt-gnu module, I found
> that HAVE_SYS_CDEFS_H was empty.
>
> This looks wrong, but I see that it is set to empty on my GNU system which
> uses glibc, and hence doesn't need getopt replacing, so the value of
> HAVE_SYS_CDEFS_H (which is tested in getopt-cdefs.h) is not substituted
> after #if, where its emptiness causes a syntax error on Android.
>
> Oddly, the config.log on Android suggests that sys/cdefs.h is indeed found.
>
> So I'm not clear what the real problem is here.
>
> Very happy to perform further debugging if anyone can give me any pointers
> as to what to look for!
>
> (I was using a commit of gnulib from last year, and no relevant code seems
> to have changed since then, but I've tested with current git master HEAD
> just to confirm I get the same result.)
>
> --
> https://rrt.sc3d.org
>


-- 
https://rrt.sc3d.org

[-- Attachment #2: Type: text/html, Size: 2932 bytes --]

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2019-03-01 22:44 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-03-01 18:49 HAVE_SYS_CDEFS_H set to empty Reuben Thomas
2019-03-01 22:44 ` Reuben Thomas

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).