Re: [Haskell-cafe] Mobile app development?
On Tue, Jan 22, 2013 at 8:37 PM, Kristopher Micinski krismicin...@gmail.com wrote: By the way, the Android APIs aren't really meant to be used by native code: the only real use for native code in Android is GPU code and math code (think games and DSP-type programs). They may not be meant to be in some sense, but from Android 2.3 on they are exposed for such use --- and I believe language porting like this is one of the intended uses. -- brandon s allbery kf8nh sine nomine associates allber...@gmail.com ballb...@sinenomine.net unix, openafs, kerberos, infrastructure, xmonadhttp://sinenomine.net ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] Mobile app development?
In what way are they exposed for use? I certainly haven't seen any API which lets you touch any of the standard GUI utilities without writing JNI wrappers that communicate to the Java based UI elements. As far as I know there is no way to use the actual Android API: you have to write a wrapper through the JNI to use the Java version. Can you point to a native library which allows you to hook in to the Android SDK? I'd be very interested in seeing it. Kris On Wed, Jan 23, 2013 at 10:54 AM, Brandon Allbery allber...@gmail.com wrote: On Tue, Jan 22, 2013 at 8:37 PM, Kristopher Micinski krismicin...@gmail.com wrote: By the way, the Android APIs aren't really meant to be used by native code: the only real use for native code in Android is GPU code and math code (think games and DSP-type programs). They may not be meant to be in some sense, but from Android 2.3 on they are exposed for such use --- and I believe language porting like this is one of the intended uses. -- brandon s allbery kf8nh sine nomine associates allber...@gmail.com ballb...@sinenomine.net unix, openafs, kerberos, infrastructure, xmonadhttp://sinenomine.net ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] Mobile app development?
For reference, the only components provided by the Android platform (listed on the Android website, and what I found digging through the provided NDK) are: libc (C library) headers libm (math library) headers JNI interface headers libz (Zlib compression) headers liblog (Android logging) header OpenGL ES 1.1 and OpenGL ES 2.0 (3D graphics libraries) headers libjnigraphics (Pixel buffer access) header (for Android 2.2 and above). A Minimal set of headers for C++ support OpenSL ES native audio libraries Android native application APIS Having these things is a far cry from being able to use any of the typical Android facilities from native code: you can't even implement GUI normally. The one project I've seen which attempts to generate stubs for easy use by native code is: http://code.google.com/p/cle-for-android/ I'm not sure of the current status, but the last I checked it was still a bit premature. Kris On Wed, Jan 23, 2013 at 1:48 PM, Kristopher Micinski krismicin...@gmail.com wrote: In what way are they exposed for use? I certainly haven't seen any API which lets you touch any of the standard GUI utilities without writing JNI wrappers that communicate to the Java based UI elements. As far as I know there is no way to use the actual Android API: you have to write a wrapper through the JNI to use the Java version. Can you point to a native library which allows you to hook in to the Android SDK? I'd be very interested in seeing it. Kris On Wed, Jan 23, 2013 at 10:54 AM, Brandon Allbery allber...@gmail.com wrote: On Tue, Jan 22, 2013 at 8:37 PM, Kristopher Micinski krismicin...@gmail.com wrote: By the way, the Android APIs aren't really meant to be used by native code: the only real use for native code in Android is GPU code and math code (think games and DSP-type programs). They may not be meant to be in some sense, but from Android 2.3 on they are exposed for such use --- and I believe language porting like this is one of the intended uses. -- brandon s allbery kf8nh sine nomine associates allber...@gmail.com ballb...@sinenomine.net unix, openafs, kerberos, infrastructure, xmonadhttp://sinenomine.net ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] Mobile app development?
On Jan 19, 2013, at 10:29 PM, Nathan Hüsken wrote: Recently I managed to get ghc to target android working (this still needs some work): [4]. this is great news, thanks! Of couse, ffi bindings for all these platforms would be needed to get serious. i think that you can get quite serious already if the main model is implemented in haskell and you only need bindings for communicating with a native user interface. sk ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] Mobile app development?
Can we un-deprecate GHC's ability to compile to C code? C may be the best option to bridge to mobile, as Android, iOS, and Windows RT do support C/C++ apps. On Jan 22, 2013 2:14 PM, Dan Choi dhc...@gmail.com wrote: What about the option of using Haskell's Parsec or AttoParsec to implement a Haskell-ish language that compiles down not to machine code but to Objective C or Android Java? Like how CoffeeScript compiles down to JavaScript. On Saturday, January 19, 2013 1:58:03 PM UTC-5, Casey Hawthorne wrote: You would need native compilers for all the platforms and/or virtual machine technology. Might be easier to have the browser connect to a Haskell app. On Sat, Jan 19, 2013 at 10:42 AM, Andrew Pennebaker andrew.p...@gmail.com wrote: There are currently very few options, especially free and open source options, when it comes to developing cross-platform mobile applications. It's basically web apps with JavaScript, or C++. If Haskell supported app development on Android, iOS, and Windows RT, that alone would bring in more developers. Similarly, there are very few languages for mobile development that take advantage of multiple cores and multiple CPUs. Haskell's `parmap` is an amazing selling point. Can we please prioritize mobile support? I'd much rather write everything in ML than PhoneGap. -- Cheers, Andrew Pennebaker www.yellosoft.us __**_ Haskell-Cafe mailing list haskel...@haskell.org http://www.haskell.org/**mailman/listinfo/haskell-cafehttp://www.haskell.org/mailman/listinfo/haskell-cafe -- -- Regards, KC __**_ Haskell-Cafe mailing list haskel...@haskell.org http://www.haskell.org/**mailman/listinfo/haskell-cafehttp://www.haskell.org/mailman/listinfo/haskell-cafe ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] Mobile app development?
On Tue, Jan 22, 2013 at 2:40 PM, Andrew Pennebaker andrew.penneba...@gmail.com wrote: Can we un-deprecate GHC's ability to compile to C code? C may be the best option to bridge to mobile, as Android, iOS, and Windows RT do support C/C++ apps. The C code generated by GHC, except in unregisterised mode, was not particularly suitable for that use. -- brandon s allbery kf8nh sine nomine associates allber...@gmail.com ballb...@sinenomine.net unix, openafs, kerberos, infrastructure, xmonadhttp://sinenomine.net ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] Mobile app development?
I don't believe that was really the point of the C compiler, and I'd suspect you'd have a hard time with the runtime. By the way, the Android APIs aren't really meant to be used by native code: the only real use for native code in Android is GPU code and math code (think games and DSP-type programs). Wrapping the libraries for use by native code is *possible*, but getting it right will be very hard: it's not like you're going to have a simple C library which lets you touch Android's `View` hierarchy, for example. On top of that, you'd also want to have a true functional interface to Android's API: you probably don't want to just use the Java API verbatim. What was your implementation plan for doing this, should you get a runtime up for Haskell code? I'd guess that you can pretty easily get a Haskell program to *run* on the device from the device's command line. But I'd also guess that getting it to play well with Android will be a *lot* of work. I don't really have the time or GHC internals experience to do this, but if someone wanted help on it, I'd be interested. The web interface idea is okay, but obviously you're punting on speed if you do that. You might look into the Boot2Gecko project at Mozilla, it has similar aspirations. Kris On Tue, Jan 22, 2013 at 2:40 PM, Andrew Pennebaker andrew.penneba...@gmail.com wrote: Can we un-deprecate GHC's ability to compile to C code? C may be the best option to bridge to mobile, as Android, iOS, and Windows RT do support C/C++ apps. On Jan 22, 2013 2:14 PM, Dan Choi dhc...@gmail.com wrote: What about the option of using Haskell's Parsec or AttoParsec to implement a Haskell-ish language that compiles down not to machine code but to Objective C or Android Java? Like how CoffeeScript compiles down to JavaScript. On Saturday, January 19, 2013 1:58:03 PM UTC-5, Casey Hawthorne wrote: You would need native compilers for all the platforms and/or virtual machine technology. Might be easier to have the browser connect to a Haskell app. On Sat, Jan 19, 2013 at 10:42 AM, Andrew Pennebaker andrew.p...@gmail.com wrote: There are currently very few options, especially free and open source options, when it comes to developing cross-platform mobile applications. It's basically web apps with JavaScript, or C++. If Haskell supported app development on Android, iOS, and Windows RT, that alone would bring in more developers. Similarly, there are very few languages for mobile development that take advantage of multiple cores and multiple CPUs. Haskell's `parmap` is an amazing selling point. Can we please prioritize mobile support? I'd much rather write everything in ML than PhoneGap. -- Cheers, Andrew Pennebaker www.yellosoft.us ___ Haskell-Cafe mailing list haskel...@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe -- -- Regards, KC ___ Haskell-Cafe mailing list haskel...@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
[Haskell-cafe] Mobile app development?
There are currently very few options, especially free and open source options, when it comes to developing cross-platform mobile applications. It's basically web apps with JavaScript, or C++. If Haskell supported app development on Android, iOS, and Windows RT, that alone would bring in more developers. Similarly, there are very few languages for mobile development that take advantage of multiple cores and multiple CPUs. Haskell's `parmap` is an amazing selling point. Can we please prioritize mobile support? I'd much rather write everything in ML than PhoneGap. -- Cheers, Andrew Pennebaker www.yellosoft.us ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] Mobile app development?
You would need native compilers for all the platforms and/or virtual machine technology. Might be easier to have the browser connect to a Haskell app. On Sat, Jan 19, 2013 at 10:42 AM, Andrew Pennebaker andrew.penneba...@gmail.com wrote: There are currently very few options, especially free and open source options, when it comes to developing cross-platform mobile applications. It's basically web apps with JavaScript, or C++. If Haskell supported app development on Android, iOS, and Windows RT, that alone would bring in more developers. Similarly, there are very few languages for mobile development that take advantage of multiple cores and multiple CPUs. Haskell's `parmap` is an amazing selling point. Can we please prioritize mobile support? I'd much rather write everything in ML than PhoneGap. -- Cheers, Andrew Pennebaker www.yellosoft.us ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe -- -- Regards, KC ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] Mobile app development?
Then it looks as if the easier implementation would be small Haskell VM's for the various platforms with a byte code compiler. I do not believe the JVM supports all the optimizations GHC can do. Oh wait! Can the LLVM be easily ported to do this? On Sat, Jan 19, 2013 at 11:40 AM, Andrew Pennebaker andrew.penneba...@gmail.com wrote: Might be easier to have the browser connect to a Haskell app. Not all apps can be run as thin clients. 3D video games and other intensive programs aren't easily done as thin clients. Mobile Haskell would be very powerful, because concurrency and parallelism aren't something the C-family languages are supporting that well. On Sat, Jan 19, 2013 at 10:42 AM, Andrew Pennebaker andrew.penneba...@gmail.com wrote: There are currently very few options, especially free and open source options, when it comes to developing cross-platform mobile applications. It's basically web apps with JavaScript, or C++. If Haskell supported app development on Android, iOS, and Windows RT, that alone would bring in more developers. Similarly, there are very few languages for mobile development that take advantage of multiple cores and multiple CPUs. Haskell's `parmap` is an amazing selling point. Can we please prioritize mobile support? I'd much rather write everything in ML than PhoneGap. -- Cheers, Andrew Pennebaker www.yellosoft.us ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe -- -- Regards, KC -- Cheers, Andrew Pennebaker www.yellosoft.us -- -- Regards, KC ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] Mobile app development?
LLVM probably already supports producing native code for all of the architectures for the mobile platforms. The non-trivial parts are probably getting GHC to cross-compile and wrapping all of the libraries you need for the platforms you want to support. On Sat, Jan 19, 2013 at 12:41 PM, KC kc1...@gmail.com wrote: Then it looks as if the easier implementation would be small Haskell VM's for the various platforms with a byte code compiler. I do not believe the JVM supports all the optimizations GHC can do. Oh wait! Can the LLVM be easily ported to do this? On Sat, Jan 19, 2013 at 11:40 AM, Andrew Pennebaker andrew.penneba...@gmail.com wrote: Might be easier to have the browser connect to a Haskell app. Not all apps can be run as thin clients. 3D video games and other intensive programs aren't easily done as thin clients. Mobile Haskell would be very powerful, because concurrency and parallelism aren't something the C-family languages are supporting that well. On Sat, Jan 19, 2013 at 10:42 AM, Andrew Pennebaker andrew.penneba...@gmail.com wrote: There are currently very few options, especially free and open source options, when it comes to developing cross-platform mobile applications. It's basically web apps with JavaScript, or C++. If Haskell supported app development on Android, iOS, and Windows RT, that alone would bring in more developers. Similarly, there are very few languages for mobile development that take advantage of multiple cores and multiple CPUs. Haskell's `parmap` is an amazing selling point. Can we please prioritize mobile support? I'd much rather write everything in ML than PhoneGap. -- Cheers, Andrew Pennebaker www.yellosoft.us ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe -- -- Regards, KC -- Cheers, Andrew Pennebaker www.yellosoft.us -- -- Regards, KC ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] Mobile app development?
Well, to target javascript there is haste [1] and ghcjs [2]. Ghc can target iOS [3]. Recently I managed to get ghc to target android working (this still needs some work): [4]. And there is also an active effort by Stephen Paul Weber to get blackberry working in the devs-ghc mailinglist. So my impression is, that multiplatform haskell is on its way. Of couse, ffi bindings for all these platforms would be needed to get serious. [1]: https://github.com/valderman/haste-compiler.git [2]: https://github.com/ghcjs/ghcjs [3]: https://github.com/ghc-ios/ghc/wiki [4]: https://github.com/RudolfVonKrugstein/jshaskell-blog/blob/master/android_ghc/android_ghc.md On 01/19/2013 09:48 PM, Bob Ippolito wrote: LLVM probably already supports producing native code for all of the architectures for the mobile platforms. The non-trivial parts are probably getting GHC to cross-compile and wrapping all of the libraries you need for the platforms you want to support. On Sat, Jan 19, 2013 at 12:41 PM, KC kc1...@gmail.com wrote: Then it looks as if the easier implementation would be small Haskell VM's for the various platforms with a byte code compiler. I do not believe the JVM supports all the optimizations GHC can do. Oh wait! Can the LLVM be easily ported to do this? On Sat, Jan 19, 2013 at 11:40 AM, Andrew Pennebaker andrew.penneba...@gmail.com wrote: Might be easier to have the browser connect to a Haskell app. Not all apps can be run as thin clients. 3D video games and other intensive programs aren't easily done as thin clients. Mobile Haskell would be very powerful, because concurrency and parallelism aren't something the C-family languages are supporting that well. On Sat, Jan 19, 2013 at 10:42 AM, Andrew Pennebaker andrew.penneba...@gmail.com wrote: There are currently very few options, especially free and open source options, when it comes to developing cross-platform mobile applications. It's basically web apps with JavaScript, or C++. If Haskell supported app development on Android, iOS, and Windows RT, that alone would bring in more developers. Similarly, there are very few languages for mobile development that take advantage of multiple cores and multiple CPUs. Haskell's `parmap` is an amazing selling point. Can we please prioritize mobile support? I'd much rather write everything in ML than PhoneGap. -- Cheers, Andrew Pennebaker www.yellosoft.us ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe -- -- Regards, KC -- Cheers, Andrew Pennebaker www.yellosoft.us -- -- Regards, KC ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe