chicken-users
[Top][All Lists]
Advanced

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

Re: [Chicken-users] Building Chicken Scheme for Android


From: Shawn Rutledge
Subject: Re: [Chicken-users] Building Chicken Scheme for Android
Date: Mon, 1 Oct 2012 16:37:48 +0200

On 1 October 2012 16:15, Alan Post <address@hidden> wrote:
> Off topic, but I've played with several mobile devices and none of
> them have ever really 'stuck.'  I wind up back on my laptop happier
> than I was when I wandered away.
>
> After enough of these experiences, I came to realize that not having
> a C compiler+native development environment was the common
> denominator in my negative experiences.
>
> Now I've been seeing more and more android stuff, and wondering
> whether one of these devices is going to fall in my lap, so I ask:
> can you get a C compiler and native development environment on these
> devices?

I was thinking of that too.  In fact, tcc (tiny c compiler) now has an
arm port, and there is cdroid in the app store which apparently
bundles it into some kind of IDE.  It's not free so I didn't try it
yet.  But I've been farting around with android, so maybe could try to
build tcc myself.  After following the process here
http://source.android.com/source/ one not only has a system image
(which I didn't actually flash on my phone, since I like cyanogenmod
well enough) but also the cross-compiler, includes, set of libraries
to link against, etc.  So it should be possible to build anything.
But what you build will not be terribly portable, since the libs can
change between android versions.  If you instead build with NDK
(native development kit), in theory the result will be portable, but
maybe the exposed APIs aren't rich enough for some purposes.

Then I was thinking maybe with an Android version of icecream,
compiling could even be fast, if you have a bunch of other arm
thingies on the same network (phones, raspberry pi's, routers,
gumstix, whatever).  But the compiler would have to be portable
enough.

However I think maybe the future is to have a Scheme which uses llvm
to implement a compiler that works on multiple platforms.  When Java
was new, I thought its main value would end up being a common VM, with
lots of languages being ported to it.  That's true to an extent, but
it's even nicer that LLVM seems to cover intermediate form, a portable
bytecode format, standardized optimizations, and backends to generate
native code for multiple platforms.  So whether you want to run
portable bytecode, JIT it or pre-compile it, there is a way, and it's
not such a black box.



reply via email to

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