Live data from Hacker News

iPhone, meet Haskell

groups.google.com

31–40 of 53 posts

Re: iPhone, meet Haskell

#31
post #5

Anybody here know, off the cuff, if the GHC packaged in Homebrew is compiled correctly to utilize the wrapper scripts out of the box, or if I'd need to build the cross-compiler myself as described in the linked documentation?

Nope. I also strongly recommend against using the normal "brew" formulas for haskell tools, its only by PROACTIVE efforts by mac using haskellers that the standard brew aren't a complete disaster (or at least, wont' be a disaster, soonish). I strongly recommend using standard haskell binary distributions, such as those prepared by GHC HQ, or the Haskell Platform folks, or perhaps any brew Tap that Darin Morrison or L…

You are right.

I started with haskell-platform from brew and ended up with a broken ghc build.

"inplace/bin/ghc-stage1" -static -H32m -O -Iincludes -Iincludes/dist -Iincludes/dist-derivedconstants/header -Iincludes/dist-ghcconstants/header -Irts -Irts/dist/build -DCOMPILING_RTS -package-name rts -dcmm-lint -i -irts -irts/dist/build -irts/dist/build/autogen -Irts/dist/build -Irts/dist/build/autogen -O2 -c rts/Apply.cmm -o rts/dist/build/Apply.o /usr/local/bin/llc: : error: unable to get target for 'arm-apple-darwin10', see --version and --triple. make[1]: * [rts/dist/build/Apply.o] Error 1

I am starting over with the binary GHC distribution.

Re: iPhone, meet Haskell

#32

Earlier quoted context omitted.

Nope. I also strongly recommend against using the normal "brew" formulas for haskell tools, its only by PROACTIVE efforts by mac using haskellers that the standard brew aren't a complete disaster (or at least, wont' be a disaster, soonish). I strongly recommend using standard haskell binary distributions, such as those prepared by GHC HQ, or the Haskell Platform folks, or perhaps any brew Tap that Darin Morrison or L…

You are right. I started with haskell-platform from brew and ended up with a broken ghc build. "inplace/bin/ghc-stage1" -static -H32m -O -Iincludes -Iincludes/dist -Iincludes/dist-derivedconstants/header -Iincludes/dist-ghcconstants/header -Irts -Irts/dist/build -DCOMPILING_RTS -package-name rts -dcmm-lint -i -irts -irts/dist/build -irts/dist/build/autogen -Irts/dist/build -Irts/dist/build/autogen -O2 -c rts/Apply.cm…

yeah, the brew folks don't understand the point of haskell platform, and honestly botch it. Their GHC formula should have something like ---add-Haskell-Platform-if-this-version-has-it (but a shorted name for it), because haskell platform is tied to specific GHC versions, rather than as another brew formula/package.

Haskell platform is tied to very very specific GHC releases, and have specially prepared and tested installers for each major OS target. Brew throws this all away and treats it like a simplistic "nice things" wrapper, when in fact its actually 1+ months of engineering time a year for Mark Lenctzer (and a handful of others) to make sure that everything JUST WORKS™ for new haskellers when they install GHC and tools on a machine.

also, for near term sanity, stick to Xcode 4.6 if you're using GHC 7.6

Without some hacky tricks i'm going to help the haskell platform folks work out, GHC 7.8 is the only GHC version that will play nice with OS X mavericks/Xcode 5. Hopefully with the tricks Luke Iannini and I have cooked up, GHC 7.6 in this fall's Haskell Platform release will work very nicely on Mavericks / Xcode 5. (but it will have to be a different haskell platform install than for systems pre Xcode 5)

Re: iPhone, meet Haskell

#34
post #3

This is interesting. I've been keen on experimenting with FRP for a while, and now I can use it for 'real world' stuff on a platform I know I just might have the push I need to jump into Haskell.

please note: FRP is an idea, and while theres some interesting tools out there for FRP, it is not always the right solution, and in many respects, "FRP done Right" is still an open research problem.

That said, have fun and try things out! Share what you learn, and either way, it'll be time enjoyably spent.

Re: iPhone, meet Haskell

#35
post #6

I would love to also run the interpreter inside iOS to learn Haskell from a tablet. I will support a crowdfunding campaign.

the reason that won't happen is simple: GHCI works by doing dynamic linking. The iOS security model does not allow dynamic linking.

(There may be some clever way to modify how GHCI works to change that, but offhand, its not obvious to me what that would be)

Re: iPhone, meet Haskell

#36
post #3

This is interesting. I've been keen on experimenting with FRP for a while, and now I can use it for 'real world' stuff on a platform I know I just might have the push I need to jump into Haskell.

please note: FRP is an idea, and while theres some interesting tools out there for FRP, it is not always the right solution, and in many respects, "FRP done Right" is still an open research problem. That said, have fun and try things out! Share what you learn, and either way, it'll be time enjoyably spent.

I think you could say the same thing about anything else in the software world.

Re: iPhone, meet Haskell

#37
post #21

I'm going to withhold my excitement until I get proof that Apple will approve GHC compiled binaries.

There now are many interpreted as well as compiled non Objective-C languages around; from .NET languages to Object Pascal, Ruby, Java, Lua, Python, Javascript and others used to create iOS applications and they all are happily allowed in the Appstore. You are just not allowed to dynamically load 'new code' from servers and execute it on the device unless it's via the Safari Javascript engine.

Compiling to ARM and then running on the device is perfectly fine with Apple.

Re: iPhone, meet Haskell

#39
post #6

I would love to also run the interpreter inside iOS to learn Haskell from a tablet. I will support a crowdfunding campaign.

the reason that won't happen is simple: GHCI works by doing dynamic linking. The iOS security model does not allow dynamic linking. (There may be some clever way to modify how GHCI works to change that, but offhand, its not obvious to me what that would be)

haskell has plenty of interpreters

Re: iPhone, meet Haskell

#40
This is brilliant news!

Would it be possible to drop a cross compiled Haskell library into a Xamarin project and call into it from the .Net (F#) world? That would be the killer feature for me!

Also not much mention of android here - is it possible to target android with Haskell at the moment?

Post reply on HN