Re: [Chicken-users] Chicken on Termux

2017-05-13 Thread Phil Bewig
That works. Thank you to Alexander and the others who responded, both here
and on the Gambit list.

On May 13, 2017 4:00 AM, "Alexander Shendi (web.de)" <
alexander.she...@web.de> wrote:

> Hi Phil,
>
> you have to set LD_LIBRARY_PATH explicitly :
>
> export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$HOME/chicken-4.12.0/lib
>
> Then you should be able to invoke "csi" directly. You don't need my patch,
> if you don't mind a linker warning message each time you run "csi".
>
> Best Regards,
>
> Alexander
>
> Am 13. Mai 2017 03:15:30 MESZ schrieb Phil Bewig <pbe...@gmail.com>:
>>
>> I began as John suggested with the following command line:
>>
>> TMPDIR=$HOME/tmp make C_COMPILER=clang PREFIX=$HOME/chicken-4.12.0
>> PLATFORM=linux install
>>
>> This ran fine (about ten minutes) until it encountered an error on the
>> line:
>>
>> clang -L. chicken.o batch-driver.o compiler.o optimizer.o lfa2.o
>> compiler-syntax.o scrutinizer.o support.o c-platform.o c-backend.o -o
>> chicken -lchicken -W1,-R"." -lm -ldl
>>
>> The error message is:
>>
>> ./libchicken.so: undefined reference to '__android_log_vprint'
>> clan-4.0: error: linker command failed with exit code 1 (use -v to see
>> invocation)
>> make: *** [rules.make:247: chicken] Error 1
>>
>> So I erased everything, untarred again, and did as Alexander suggested:
>>
>> TMPDIR=$HOME/tmp make C_COMPILER=clang PREFIX=$HOME/chicken-4.12.0
>> PLATFORM=android install
>>
>> The compile completed successfully, but when I run ./csi I get an error:
>>
>> CANNOT LINK EXECUTABLE: could not load library "libchicken.so" needed by
>> "./csi"; caused by library "libchicken.so" not found
>>
>> Of course, libchicken.so is in the same directory as csi. I suppose that
>> is the linker error Alexander talked about. I have questions:
>>
>> 1) How do I work around the link error and run csi?
>>
>> 2) Alexander: How do I apply your patch? (I'm not adept with C.) Is your
>> patch forward-compatible so it will work on future versions of chicken?
>>
>> 3) Is there a way to compile chicken so the library is included
>> statically and doesn't require a dynamically-loaded library? (I would
>> prefer that to a patch.)
>>
>> Thanks again,
>>
>> Phil
>>
>> On Fri, May 12, 2017 at 6:16 PM, Alexander Shendi (web.de) <
>> alexander.she...@web.de> wrote:
>>
>>> Dear Phil,
>>>
>>> It's me again.
>>>
>>> Some remarks:
>>> I did successfully compile CHICKEN 4.12.0 on Termux/Android. Please use
>>> that exact release as it contains several fixes for the Android platform.
>>>
>>> 1) I used PLATFORM=android as Termux uses Android's libc (Bionic) rather
>>> than GNU libc.
>>> 2) The complete make invocation I used was:
>>>
>>> TMPDIR=$HOME/tmp make C_COMPILER=clang PREFIX=$HOME/chickens/4.12.0
>>> PLATFORM=android install
>>>
>>> 3) the Android dynamic linker is rather dumb and doesn't support the
>>> --rpath feature used by the Makefile.
>>> It spits out a warning to that effect every time you run csi/csc or an
>>> executable made with csc.
>>> This also screws up the CHICKEN test suite. I have a patch that works
>>> around that
>>> (see https://paste.call-cc.org/paste?id=a738f447edf76ecbaa7b47eec
>>> ed51fa138972add#a0)
>>> But if you can live with the warning message and don't need to run the
>>> test suite you don't need to apply the patch.
>>>
>>> 3) I did (see above).
>>>
>>> 4.1) CHICKEN 's library directory (e.g. $HOME/chickens/4.12.0/lib) must
>>> be in your $LD_LIBRARY_PATH.
>>> 4.2) If you want to install eggs (CHICKEN's version of packages) you
>>> must say:
>>> TMPDIR=$HOME/tmp chicken-install 
>>>
>>>
>>> 5.) Good luck!
>>>
>>> 6.) Do not hesitate to ask for further info.
>>>
>>> Best Regards,
>>>
>>> Alexander
>>>
>>>
>>> Am 12. Mai 2017 23:00:10 MESZ schrieb Phil Bewig <pbe...@gmail.com>:
>>>>
>>>> I recently purchased a Lenovo TAB2 A10 tablet computer and installed
>>>> Termux, a unix-like environment, from the Play Store. I want to compile
>>>> Chicken for my computer so I can have a Scheme REPL with me wherever I go.
>>>> I have several questions:
>>>>
>>>> 1) What is the correct PLATFORM for the make command? Is it android?
>>>> Termux isn't really android, it is its own version of unix, similar to
>>>> Debian.
>>>>
>>>> 2) Are any of the optional features required or recommended for Termux?
>>>>
>>>> 3) Have any other Chicken users successfully compiled Chicken on Termux?
>>>>
>>>> 4) Is there anything else I need to know to compile Chicken on Termux?
>>>>
>>>> Thanks for your help.
>>>>
>>>> Phil
>>>>
>>>
>>> --
>>> Diese Nachricht wurde von meinem Android-Mobiltelefon mit K-9 Mail
>>> gesendet.
>>>
>>
>>
> --
> Diese Nachricht wurde von meinem Android-Mobiltelefon mit K-9 Mail
> gesendet.
>
___
Chicken-users mailing list
Chicken-users@nongnu.org
https://lists.nongnu.org/mailman/listinfo/chicken-users


Re: [Chicken-users] Chicken on Termux

2017-05-13 Thread Alexander Shendi (web.de)
Hi Phil, 

you have to set LD_LIBRARY_PATH explicitly :

export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$HOME/chicken-4.12.0/lib

Then you should be able to invoke "csi" directly. You don't need my patch, if 
you don't mind a linker warning message each time you run "csi". 

Best Regards, 

Alexander 

Am 13. Mai 2017 03:15:30 MESZ schrieb Phil Bewig <pbe...@gmail.com>:
>I began as John suggested with the following command line:
>
>TMPDIR=$HOME/tmp make C_COMPILER=clang PREFIX=$HOME/chicken-4.12.0
>PLATFORM=linux install
>
>This ran fine (about ten minutes) until it encountered an error on the
>line:
>
>clang -L. chicken.o batch-driver.o compiler.o optimizer.o lfa2.o
>compiler-syntax.o scrutinizer.o support.o c-platform.o c-backend.o -o
>chicken -lchicken -W1,-R"." -lm -ldl
>
>The error message is:
>
>./libchicken.so: undefined reference to '__android_log_vprint'
>clan-4.0: error: linker command failed with exit code 1 (use -v to see
>invocation)
>make: *** [rules.make:247: chicken] Error 1
>
>So I erased everything, untarred again, and did as Alexander suggested:
>
>TMPDIR=$HOME/tmp make C_COMPILER=clang PREFIX=$HOME/chicken-4.12.0
>PLATFORM=android install
>
>The compile completed successfully, but when I run ./csi I get an
>error:
>
>CANNOT LINK EXECUTABLE: could not load library "libchicken.so" needed
>by
>"./csi"; caused by library "libchicken.so" not found
>
>Of course, libchicken.so is in the same directory as csi. I suppose
>that is
>the linker error Alexander talked about. I have questions:
>
>1) How do I work around the link error and run csi?
>
>2) Alexander: How do I apply your patch? (I'm not adept with C.) Is
>your
>patch forward-compatible so it will work on future versions of chicken?
>
>3) Is there a way to compile chicken so the library is included
>statically
>and doesn't require a dynamically-loaded library? (I would prefer that
>to a
>patch.)
>
>Thanks again,
>
>Phil
>
>On Fri, May 12, 2017 at 6:16 PM, Alexander Shendi (web.de) <
>alexander.she...@web.de> wrote:
>
>> Dear Phil,
>>
>> It's me again.
>>
>> Some remarks:
>> I did successfully compile CHICKEN 4.12.0 on Termux/Android. Please
>use
>> that exact release as it contains several fixes for the Android
>platform.
>>
>> 1) I used PLATFORM=android as Termux uses Android's libc (Bionic)
>rather
>> than GNU libc.
>> 2) The complete make invocation I used was:
>>
>> TMPDIR=$HOME/tmp make C_COMPILER=clang PREFIX=$HOME/chickens/4.12.0
>> PLATFORM=android install
>>
>> 3) the Android dynamic linker is rather dumb and doesn't support the
>> --rpath feature used by the Makefile.
>> It spits out a warning to that effect every time you run csi/csc or
>an
>> executable made with csc.
>> This also screws up the CHICKEN test suite. I have a patch that works
>> around that
>> (see
>https://paste.call-cc.org/paste?id=a738f447edf76ecbaa7b47eeced51f
>> a138972add#a0)
>> But if you can live with the warning message and don't need to run
>the
>> test suite you don't need to apply the patch.
>>
>> 3) I did (see above).
>>
>> 4.1) CHICKEN 's library directory (e.g. $HOME/chickens/4.12.0/lib)
>must be
>> in your $LD_LIBRARY_PATH.
>> 4.2) If you want to install eggs (CHICKEN's version of packages) you
>must
>> say:
>> TMPDIR=$HOME/tmp chicken-install 
>>
>>
>> 5.) Good luck!
>>
>> 6.) Do not hesitate to ask for further info.
>>
>> Best Regards,
>>
>> Alexander
>>
>>
>> Am 12. Mai 2017 23:00:10 MESZ schrieb Phil Bewig <pbe...@gmail.com>:
>>>
>>> I recently purchased a Lenovo TAB2 A10 tablet computer and installed
>>> Termux, a unix-like environment, from the Play Store. I want to
>compile
>>> Chicken for my computer so I can have a Scheme REPL with me wherever
>I go.
>>> I have several questions:
>>>
>>> 1) What is the correct PLATFORM for the make command? Is it android?
>>> Termux isn't really android, it is its own version of unix, similar
>to
>>> Debian.
>>>
>>> 2) Are any of the optional features required or recommended for
>Termux?
>>>
>>> 3) Have any other Chicken users successfully compiled Chicken on
>Termux?
>>>
>>> 4) Is there anything else I need to know to compile Chicken on
>Termux?
>>>
>>> Thanks for your help.
>>>
>>> Phil
>>>
>>
>> --
>> Diese Nachricht wurde von meinem Android-Mobiltelefon mit K-9 Mail
>> gesendet.
>>

-- 
Diese Nachricht wurde von meinem Android-Mobiltelefon mit K-9 Mail gesendet.___
Chicken-users mailing list
Chicken-users@nongnu.org
https://lists.nongnu.org/mailman/listinfo/chicken-users


Re: [Chicken-users] Chicken on Termux

2017-05-12 Thread Phil Bewig
I began as John suggested with the following command line:

TMPDIR=$HOME/tmp make C_COMPILER=clang PREFIX=$HOME/chicken-4.12.0
PLATFORM=linux install

This ran fine (about ten minutes) until it encountered an error on the line:

clang -L. chicken.o batch-driver.o compiler.o optimizer.o lfa2.o
compiler-syntax.o scrutinizer.o support.o c-platform.o c-backend.o -o
chicken -lchicken -W1,-R"." -lm -ldl

The error message is:

./libchicken.so: undefined reference to '__android_log_vprint'
clan-4.0: error: linker command failed with exit code 1 (use -v to see
invocation)
make: *** [rules.make:247: chicken] Error 1

So I erased everything, untarred again, and did as Alexander suggested:

TMPDIR=$HOME/tmp make C_COMPILER=clang PREFIX=$HOME/chicken-4.12.0
PLATFORM=android install

The compile completed successfully, but when I run ./csi I get an error:

CANNOT LINK EXECUTABLE: could not load library "libchicken.so" needed by
"./csi"; caused by library "libchicken.so" not found

Of course, libchicken.so is in the same directory as csi. I suppose that is
the linker error Alexander talked about. I have questions:

1) How do I work around the link error and run csi?

2) Alexander: How do I apply your patch? (I'm not adept with C.) Is your
patch forward-compatible so it will work on future versions of chicken?

3) Is there a way to compile chicken so the library is included statically
and doesn't require a dynamically-loaded library? (I would prefer that to a
patch.)

Thanks again,

Phil

On Fri, May 12, 2017 at 6:16 PM, Alexander Shendi (web.de) <
alexander.she...@web.de> wrote:

> Dear Phil,
>
> It's me again.
>
> Some remarks:
> I did successfully compile CHICKEN 4.12.0 on Termux/Android. Please use
> that exact release as it contains several fixes for the Android platform.
>
> 1) I used PLATFORM=android as Termux uses Android's libc (Bionic) rather
> than GNU libc.
> 2) The complete make invocation I used was:
>
> TMPDIR=$HOME/tmp make C_COMPILER=clang PREFIX=$HOME/chickens/4.12.0
> PLATFORM=android install
>
> 3) the Android dynamic linker is rather dumb and doesn't support the
> --rpath feature used by the Makefile.
> It spits out a warning to that effect every time you run csi/csc or an
> executable made with csc.
> This also screws up the CHICKEN test suite. I have a patch that works
> around that
> (see https://paste.call-cc.org/paste?id=a738f447edf76ecbaa7b47eeced51f
> a138972add#a0)
> But if you can live with the warning message and don't need to run the
> test suite you don't need to apply the patch.
>
> 3) I did (see above).
>
> 4.1) CHICKEN 's library directory (e.g. $HOME/chickens/4.12.0/lib) must be
> in your $LD_LIBRARY_PATH.
> 4.2) If you want to install eggs (CHICKEN's version of packages) you must
> say:
> TMPDIR=$HOME/tmp chicken-install 
>
>
> 5.) Good luck!
>
> 6.) Do not hesitate to ask for further info.
>
> Best Regards,
>
> Alexander
>
>
> Am 12. Mai 2017 23:00:10 MESZ schrieb Phil Bewig <pbe...@gmail.com>:
>>
>> I recently purchased a Lenovo TAB2 A10 tablet computer and installed
>> Termux, a unix-like environment, from the Play Store. I want to compile
>> Chicken for my computer so I can have a Scheme REPL with me wherever I go.
>> I have several questions:
>>
>> 1) What is the correct PLATFORM for the make command? Is it android?
>> Termux isn't really android, it is its own version of unix, similar to
>> Debian.
>>
>> 2) Are any of the optional features required or recommended for Termux?
>>
>> 3) Have any other Chicken users successfully compiled Chicken on Termux?
>>
>> 4) Is there anything else I need to know to compile Chicken on Termux?
>>
>> Thanks for your help.
>>
>> Phil
>>
>
> --
> Diese Nachricht wurde von meinem Android-Mobiltelefon mit K-9 Mail
> gesendet.
>
___
Chicken-users mailing list
Chicken-users@nongnu.org
https://lists.nongnu.org/mailman/listinfo/chicken-users


Re: [Chicken-users] Chicken on Termux

2017-05-12 Thread Alexander Shendi (web.de)
Dear Phil, 

It's me again. 

Some remarks:
I did successfully compile CHICKEN 4.12.0 on Termux/Android. Please use that 
exact release as it contains several fixes for the Android platform. 

1) I used PLATFORM=android as Termux uses Android's libc (Bionic) rather than 
GNU libc. 
2) The complete make invocation I used was:

TMPDIR=$HOME/tmp make C_COMPILER=clang PREFIX=$HOME/chickens/4.12.0 
PLATFORM=android install

3) the Android dynamic linker is rather dumb and doesn't support the --rpath 
feature used by the Makefile. 
It spits out a warning to that effect every time you run csi/csc or an 
executable made with csc. 
This also screws up the CHICKEN test suite. I have a patch that works around 
that 
(see 
https://paste.call-cc.org/paste?id=a738f447edf76ecbaa7b47eeced51fa138972add#a0) 
But if you can live with the warning message and don't need to run the test 
suite you don't need to apply the patch. 

3) I did (see above). 

4.1) CHICKEN 's library directory (e.g. $HOME/chickens/4.12.0/lib) must  be in 
your $LD_LIBRARY_PATH. 
4.2) If you want to install eggs (CHICKEN's version of packages) you must say:
TMPDIR=$HOME/tmp chicken-install 


5.) Good luck! 

6.) Do not hesitate to ask for further info. 

Best Regards, 

Alexander 


Am 12. Mai 2017 23:00:10 MESZ schrieb Phil Bewig <pbe...@gmail.com>:
>I recently purchased a Lenovo TAB2 A10 tablet computer and installed
>Termux, a unix-like environment, from the Play Store. I want to compile
>Chicken for my computer so I can have a Scheme REPL with me wherever I
>go.
>I have several questions:
>
>1) What is the correct PLATFORM for the make command? Is it android?
>Termux
>isn't really android, it is its own version of unix, similar to Debian.
>
>2) Are any of the optional features required or recommended for Termux?
>
>3) Have any other Chicken users successfully compiled Chicken on
>Termux?
>
>4) Is there anything else I need to know to compile Chicken on Termux?
>
>Thanks for your help.
>
>Phil

-- 
Diese Nachricht wurde von meinem Android-Mobiltelefon mit K-9 Mail gesendet.___
Chicken-users mailing list
Chicken-users@nongnu.org
https://lists.nongnu.org/mailman/listinfo/chicken-users


Re: [Chicken-users] Chicken on Termux

2017-05-12 Thread John Cowan
On Fri, May 12, 2017 at 5:00 PM, Phil Bewig  wrote:

1) What is the correct PLATFORM for the make command? Is it android? Termux
> isn't really android, it is its own version of unix, similar to Debian.
>

I would try PLATFORM=linux and see if it works.  If not, you may need your
own sub-makefile for Termux, starting with Makefile.linux and tweaking a
few things.  Read the warnings here:  .

You'll need to set Chicken's idea of the PREFIX to the same as Termux's
idea with PREFIX=$PREFIX, or use some other prefix, as /usr does not exist.

You will have to specify C_COMPILER=clang on the make line, as Chicken's
makefile defaults to gcc and gcc is no longer available on Termux.

Best of luck, and tell us how it goes!

-- 
John Cowan  http://vrici.lojban.org/~cowanco...@ccil.org
Where the wombat has walked, it will inevitably walk again.
   (even through brick walls!)
___
Chicken-users mailing list
Chicken-users@nongnu.org
https://lists.nongnu.org/mailman/listinfo/chicken-users


[Chicken-users] Chicken on Termux

2017-05-12 Thread Phil Bewig
I recently purchased a Lenovo TAB2 A10 tablet computer and installed
Termux, a unix-like environment, from the Play Store. I want to compile
Chicken for my computer so I can have a Scheme REPL with me wherever I go.
I have several questions:

1) What is the correct PLATFORM for the make command? Is it android? Termux
isn't really android, it is its own version of unix, similar to Debian.

2) Are any of the optional features required or recommended for Termux?

3) Have any other Chicken users successfully compiled Chicken on Termux?

4) Is there anything else I need to know to compile Chicken on Termux?

Thanks for your help.

Phil
___
Chicken-users mailing list
Chicken-users@nongnu.org
https://lists.nongnu.org/mailman/listinfo/chicken-users