[racket] Compiling Racket on Maemo 5
Ok I tried compiling with your configure line myself.
I had to make an additional change to get racket/racketcgc to build.
the 3m variant still doesn't build do to more reliance on the ffi
during xform.
setup is also going to try to use the ffi.
We have added additional dependencies on the ffi (foreign function
interface) and need to decide if we are going to support building
without it.
My guess is that is possible but will require some engineering effort.
Kevin
diff --git a/src/racket/src/env.c b/src/racket/src/env.c
index b1c0a8d..68b634b 100644
--- a/src/racket/src/env.c
+++ b/src/racket/src/env.c
@@ -501,7 +501,9 @@ static Scheme_Env *place_instance_init(void
*stack_base, int initial_main_os_thr
scheme_init_gmp_places();
scheme_alloc_global_fdset();
scheme_init_file_places();
+#ifndef DONT_USE_FOREIGN
scheme_init_foreign_places();
+#endif
env = scheme_make_empty_env();
scheme_set_param(scheme_current_config(), MZCONFIG_ENV,
(Scheme_Object *)env);
diff --git a/src/racket/src/thread.c b/src/racket/src/thread.c
index 7329d58..3d2c4fb 100644
--- a/src/racket/src/thread.c
+++ b/src/racket/src/thread.c
@@ -4159,7 +4159,7 @@ void scheme_thread_block(float sleep_time)
#ifdef MZ_USE_FUTURES
scheme_check_future_work();
#endif
-#ifdef MZ_USE_MZRT
+#if defined(MZ_USE_MZRT) && !defined(DONT_USE_FOREIGN)
scheme_check_foreign_work();
#endif
On 07/13/2010 10:03 AM, Kevin Tew wrote:
> Try this patch, if it works for you. I'll commit it
>
> Kevin
>
> diff --git a/src/racket/src/env.c b/src/racket/src/env.c
> index b1c0a8d..68b634b 100644
> --- a/src/racket/src/env.c
> +++ b/src/racket/src/env.c
> @@ -501,7 +501,9 @@ static Scheme_Env *place_instance_init(void
> *stack_base, int initial_main_os_thr
> scheme_init_gmp_places();
> scheme_alloc_global_fdset();
> scheme_init_file_places();
> +#ifndef DONT_USE_FOREIGN
> scheme_init_foreign_places();
> +#endif
>
> env = scheme_make_empty_env();
> scheme_set_param(scheme_current_config(), MZCONFIG_ENV,
> (Scheme_Object *)env);
>
> On 07/13/2010 09:25 AM, nitralime wrote:
>> Hi folks!
>>
>> I have tried to compile Racket on Maemo 5 (<--> Nokia N900).
>> Following the usual configure and make schema I have proceeded
>> as follows:
>>
>> # cd plt-5.0/src/build
>> # ../configure --prefix=/home/user/local/racket-5.0 --without-x
>> --disable-gracket --disable-foreign
>> # make
>> ...
>> ...
>> a - src/unwind.o
>> a - src/vector.o
>> ranlib libracket.a
>> make[5]: Leaving directory `/home/user/tmp/plt-5.0/src/build/racket'
>> make[4]: Leaving directory `/home/user/tmp/plt-5.0/src/build/racket'
>> make racketcgc
>> make[4]: Entering directory `/home/user/tmp/plt-5.0/src/build/racket'
>> gcc -I. -I../../racket/include -g -O2 -Wall -D_LARGEFILE_SOURCE
>> -D_FILE_OFFSET_BITS=64 -DDONT_USE_FOREIGN
>> -DINITIAL_COLLECTS_DIRECTORY='"'"`cd ../../racket/../../collects;
>> pwd`"'"' -c ../../racket/main.c -o main.o
>> gcc -o racketcgc main.o libracket.a libmzgc.a -ldl -lm -ldl -lm
>> -rdynamic
>> libracket.a(env.o): In function `place_instance_init':
>> /home/user/tmp/plt-5.0/src/build/racket/src/../../../racket/src/env.c:500:
>> undefined reference to `scheme_init_foreign_places'
>> collect2: ld returned 1 exit status
>> make[4]: *** [racketcgc] Error 1
>> make[4]: Leaving directory `/home/user/tmp/plt-5.0/src/build/racket'
>> make[3]: *** [cgc] Error 2
>> make[3]: Leaving directory `/home/user/tmp/plt-5.0/src/build/racket'
>> make[2]: *** [3m] Error 2
>> make[2]: Leaving directory `/home/user/tmp/plt-5.0/src/build/racket'
>> make[1]: *** [3m] Error 2
>> make[1]: Leaving directory `/home/user/tmp/plt-5.0/src/build'
>> make: *** [all] Error
>>
>> Any idea how this problem can be resolved!
>>
>> Regards
>> Nik
>>
>>
>> _________________________________________________
>> For list-related administrative tasks:
>> http://lists.racket-lang.org/listinfo/users
>
>
> _________________________________________________
> For list-related administrative tasks:
> http://lists.racket-lang.org/listinfo/users
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.racket-lang.org/users/archive/attachments/20100713/c8ca5359/attachment.html>