Tuesday, December 4, 2012

snowball

I wanted to play a bit with cgo. As a project I tried to have Go bindings to snowball.

One of the problems was that snowball does not come as a library but an archive of sources. cgo can handle C source files, but all in the same directory. I had to "flatten" the source tree, rewriting #include directives (sed FTW!).

One the above was done, the rest was pretty much straightforward. I confess that at the beginning I wanted to write a lot of C helper functions, but managed to resist the temptation :)

You can get it with go get bitbucket.org/tebeka/snowball. Note the building takes time - that's C compilation for you :)

1 comment:

  1. Superb. I really enjoyed very much with this article here. Really it is an amazing article I had ever read. I hope it will help a lot for all. Thank you so much for this amazing posts and please keep update like this excellent article.thank you for sharing such a great blog with us. expecting for your.
    Digital Marketing Company in India
    seo Company in India

    ReplyDelete

/* MIKI: Analytics */