domenica 1 luglio 2007

Installing Pastell and the CurlPlugin

Before sailing forth in the high seas of REST, there's a couple of addition to do to the Squeak image: Pastell and the CurlPlugin.

Installing Pastell

Pastell is a package for Squeak that adds XPath-like navigability to an XML DOM tree. I'll be using it for all RESTful Web Services' Squeak examples.
In order to install Pastell, you'll have to:
  1. Open the Monticello Browser and add the Pastell repository. You'll fine the repository info on Pastell's SqueakSource page

  2. Load the package Pastell-gc.10 . This will install Pastell.

  3. From the RWS repository, update to RWS-gc.4 . Just select the package and click on the "Load" button. This will install a version of RWS modified to use Pastell.

Installing CurlPlugin

CurlPlugin is a plugin that allows access to libCurl's functionalities from a Squeak image. Currently only libCurl's "easy" interface is supported, but that's good enough for the next examples.

I've had trouble using the premade CurlPlugin, so I've prepared a new one for Squeak's Unix VM. Just grab and extract it in the same directory of your RWS image. After extraction, open the image and file in the file and you're done.

This version of the CurlPlugin has been compiled on Fedora 7 system against libCurl version 7.16.2 . If you have any trouble using this plugin or you're on a different platform, please leave a comment and I'll try to help you.

Once you have installed both Pastell and the CurlPlugin, don't forget to save your image.

Later this afternoon I'll publish another post detailing the next example: a client.

2 commenti:

Anonimo ha detto...

I'm running ubuntu 6.06, Dapper, and it seems the latest curl for that release is 7.15.1.

I've got another more ubuntu I've not tried with the plugin yet, so I can always migrate these ubuntu boxes if needed.

Anyway -- I'd be happy to build a plugin for this older release. When I run your build I get a primitive failed error, which I am just assuming is a libcurl incompatibility between my version and yours.

Also -- do you have plans to merge this back into the squeaksource, or maybe start a new package there if they have to remain distinct?


Anonimo ha detto...

I know this thread is older, but I'm trying to use Curl from Squeak. Your examples that do not use Curl work just fine for me, but I can't get your CurlPlugin or the standard one to work. I keep getting primitive failed on instantiation when trying to get a new handle.

I'm on Ubuntu Gutsy (7.1) against curl 7.16.4 and squeak 3.9.

Going through Curly Hell here, any help would be very appreciated. Thanks, Leon.