[Haskell-cafe] Re: Does it deserve to be a hackage package?

Andy Stewart lazycat.manatee at gmail.com
Thu Oct 28 05:46:57 EDT 2010

Dmitry V'yal <akamaus at gmail.com> writes:

> On 27.10.2010 13:16, Andy Stewart wrote:
>> Christopher Done<chrisdone at googlemail.com>  writes:
>>> On 27 October 2010 10:13, Dmitry V'yal<akamaus at gmail.com>  wrote:
>>>> While ago I had a question about opening the url in the default browser from
>>>> haskell program. I didn't get any immediate answers so I wrote my own
>>>> solution. On Linux it uses xdg-open and on Windows - ShellExecute Api.
>>>> Does it deserve to be a hackage package?
>>> If it's not in an existing small library, yes. If I have to have a
>>> dependency on gtk2hs just to do that, I'd rather have a small library.
>>> Does it work on OS X? If not, I'm sure someone would submit a patch
>>> for that. This can also be used for opening the file browser and such,
>>> right?
>> It's APIs in GIO library (a sub-library in gtk2hs), you just need depend
>> on GIO don't need depend any other library.
>> Dmitry, it's unnecessary since GIO can do better with same experience
>> both Windows and Linux, don't need any external program help.
>> Infact, GIO not just call default browser for url, it can call any
>> program to open any format.
> Ok then. I'll wait for it.
> I hope binary package for Windows would be provided too. Currently I can't figure out how build
> gtk2hs there.
I guess we won't provide binary package for Windows, but i can tell you
how to build gtk2hs on Windows:

see http://code.haskell.org/gtk2hs/INSTALL

short summary:


and download one of the "All-in-one bundles".

Note that you need to have ~/.cabal/bin on your PATH since otherwise building
the libraries will fail, saying that e.g. gtk2hsC2hs cannot be found.

Then do "cabal install gtk2hs-buildtools gtk" will install gtk2hs.

I suggest you pull gtk2hs darcs code first to test the GIO code i send
you before.

When build gtk2hs darcs, you need replace "cabal install gtk2hs-buildtools gtk" with below commands:

   darcs get --lazy http://code.haskell.org/gtk2hs/
   cd ./gtk2hs
   sudo chmod +x ./bootstrap.sh


  -- Andy

More information about the Haskell-Cafe mailing list