develooper Front page | perl.perl5.porters | Postings from January 2019

Re: [perl #133787] perl-5.29.6 fails to build on Android 8.1 (Oreo)under Termux app environment

Thread Previous | Thread Next
From:
Tony Cook
Date:
January 22, 2019 22:53
Subject:
Re: [perl #133787] perl-5.29.6 fails to build on Android 8.1 (Oreo)under Termux app environment
Message ID:
20190122225338.gy2kxjnylrq4lvlv@mars.tony.develop-help.com
On Tue, Jan 22, 2019 at 10:26:27PM +0000, Richard Leach wrote:
> On Tue, Jan 22, 2019 at 2:41 AM Tony Cook via RT
> <perlbug-followup@perl.org> wrote:
> >
> > It looks like something is wrong with your build environment.
> >
> > The libandroid-support langinfo.h uses the nl_item type:
> >
> > https://github.com/termux/libandroid-support/blob/08ad732aa81f0109410c362eb817fbac50c73b06/include/langinfo.h#L105
> >
> > as does the bionic header:
> >
> > https://github.com/aosp-mirror/platform_bionic/blob/822326db922ac5d0e4dea8cff1d774e8f04db94a/libc/include/langinfo.h#L95
> >
> > Could you please attach the complete config.sh generated by Configure?
> 
> config.sh attached.
> 
> This was generated by following the "Native Builds" instructions in
> README.android (which are for CCTools not Termux, but seemed like a
> good place to start):
> 
> export SYSROOT=/data/data/com.termux/files
> export LD_LIBRARY_PATH="$SYSROOT/lib:`pwd`:`pwd`/lib:`pwd`/lib/auto:$LD_LIBRARY_PATH"
> sh Configure -des -Dsysroot=$SYSROOT -Alibpth="/system/lib
> /vendor/lib" -Dusedevel

...
> i_langinfo='undef'
...
> incpth='/data/data/com.termux/files/usr/lib/clang/7.0.1/include /data/data/com.termux/files/usr/include'
...

It looks like Configure isn't finding your langinfo.h header.

There's a couple of options, first, try adding the directory
containing langinfo.h to incpth:

  sh Configure -des -Dsysroot=$SYSROOT -Alibpth="/system/lib /vendor/lib" -Dusedevel -Aincpth=/whereever/it/is

You may need to add the existing names too:

  sh Configure -des -Dsysroot=$SYSROOT -Alibpth="/system/lib /vendor/lib" -Dusedevel -Dincpth="/data/data/com.termux/files/usr/lib/clang/7.0.1/include /data/data/com.termux/files/usr/include /whereever/it/is"

If langinfo.h is already in one of the those directories, check it's
preprocessable:

  echo '#include <langinfo.h>' >test.c
  cc -E test.c >/dev/null && echo Success

If the file is preprocessable, but adding the directory to incpth
didn't help, try forcing i_langinfo on:

  sh Configure -des -Dsysroot=$SYSROOT -Alibpth="/system/lib /vendor/lib" -Dusedevel -Di_langinfo

Tony

Thread Previous | Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About