unofficial mirror of guile-user@gnu.org 
 help / color / mirror / Atom feed
From: ludo@gnu.org (Ludovic Courtès)
To: beuc@beuc.net
Cc: guile-user@gnu.org
Subject: Re: Compiling for Android
Date: Sat, 21 Jun 2014 23:34:18 +0200	[thread overview]
Message-ID: <874mzeeylh.fsf@gnu.org> (raw)
In-Reply-To: <20140621200625.GB9974@mail.beuc.net> (beuc@beuc.net's message of "Sat, 21 Jun 2014 22:06:25 +0200")

Hello!

beuc@beuc.net skribis:

> On Fri, Jun 20, 2014 at 12:16:41PM +0200, Ludovic Courtès wrote:
>> beuc@beuc.net skribis:
>> 
>> > Is there anybody working on compiling Guile for Android?
>> 
>> Not that I know of.
>> 
>> > Here are some notes when trying to compile stable-2.0.
>> >
>> > First important note: I had to move "AC_CHECK_LIB(m, cos)" (which btw
>> > could be rewritten at LT_LIB_M()) before gl_INIT in configure.ac,
>> > otherwise libunistring would fail to be detected.
>> 
>> Could you send the config.log of the failing thing?
>
> Selected bits:
>
>   configure:14688: checking for libunistring
>   configure:14710: arm-linux-androideabi-gcc -o conftest -g -O2 -I/usr/src/ndk-standalone-12/sysroot/usr/include  conftest.c /usr/src/ndk-standalone-12/sysroot/usr/lib/libunistring.so -Wl,-rpath -Wl,/usr/src/ndk-standalone-12/sysroot/usr/lib  >&5
>   /usr/src/ndk-standalone-12/bin/../lib/gcc/arm-linux-androideabi/4.6/../../../../arm-linux-androideabi/bin/ld: /usr/src/ndk-standalone-12/sysroot/usr/lib/libunistring.so: error: undefined reference to 'frexp'
>   collect2: ld returned 1 exit status

It looks like a libunistring issue no?  Namely, libunistring assumed
frexp to be available in libc, and it isn’t.

Does Bionic provide that function in libm or something?

>> I wasn’t aware of LT_LIB_M, thanks for the tip.
>> 
>> > The compilation fails when libgc tries to use pthread features not
>> > implemented under Android (btw ./configure was happy to start
>> > compiling even if libgc wasn't present).  Not sure where to go from
>> > here, maybe other projects use libgc and already faced the issue?
>> 
>> Does it work if libgc is configure with --disable-threads?
>
> Not in 7.2 :/
>
> libtool: compile:  arm-linux-androideabi-gcc -DHAVE_CONFIG_H -I./include -I../include -I./libatomic_ops/src -I../libatomic_ops/src -fexceptions -g -O2 -fno-strict-aliasing -MT alloc.lo -MD -MP -MF .deps/alloc.Tpo -c ../alloc.c -o alloc.o
> ../alloc.c: In function 'GC_collect_a_little_inner':
> ../alloc.c:507:5: error: 'PTHREAD_CANCEL_DISABLE' undeclared (first use in this function)

Does it help to configure with --disable-parallel-mark?

>> > Which version of libgc do you recommend?
>> 
>> 7.4.0 should be good.
>
> Hmmm, the one that requires yet another dependency (libatomic)? T-T

It’s just a part of libgc that has been separated.

HTH,
Ludo’.



  reply	other threads:[~2014-06-21 21:34 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-06-18 21:54 Compiling for Android beuc
2014-06-20 10:16 ` Ludovic Courtès
2014-06-21 20:06   ` beuc
2014-06-21 21:34     ` Ludovic Courtès [this message]
2014-06-22 14:08       ` beuc
2014-06-23  7:59         ` Ludovic Courtès
2014-06-23 18:59           ` beuc
2014-06-24  7:56             ` Ludovic Courtès
2014-06-25 21:23               ` beuc
2014-06-25 22:04                 ` Ludovic Courtès
2014-06-24 14:04             ` Mark H Weaver
2014-07-04 14:00             ` Ludovic Courtès
2014-07-04 14:01         ` Ludovic Courtès
2014-06-22 15:42       ` libunistring test beuc
2014-06-23  8:04         ` Ludovic Courtès
2014-06-23 16:48           ` beuc

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/guile/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=874mzeeylh.fsf@gnu.org \
    --to=ludo@gnu.org \
    --cc=beuc@beuc.net \
    --cc=guile-user@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).