Hey Adam,

>   I've spent a couple of hours on this - and have run into a snag.  I've got
> libgc compiling/linking with arm iOS and the Xcode project compiles cljc.c
> fine. The problem is glib.  From what I've read, iOS can not use glib as it
> must be statically linked into the app - but the LGPL doesn't allow that (at
> least from what I've read).  Currently, there only seems to be about 7
> methods that you're using that need it - 6 of which at utf8 related.  So,
> I'm thinking that I'll make a 'prepreamble.m' and use NSString's
> utf8/unichar support for simulating those methods.  But before I spend time
> on that, any comments or ideas?  For g_file_get_contents(), I can probably
> use [NSString stringWithContentsOfFile:encoding:error].

I see the problem.

My guess is that on iOS we'd use NSString anyway, even if we use glib2
or whatever else for command-line programs.  One problem here is that
you cannot allocate NSString's from Boehm, so you'd have to use
finalizers to make sure the NSString's are released when the
corresponding Clojure objects are collected.  See
GC_register_finalizer in Boehm's gc.h.

Late on we'll have proper Objective-C bindings, so the glueing will
become much easier.

Mark

-- 
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send email to clojure@googlegroups.com
Note that posts from new members are moderated - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

Reply via email to