guile curl is a project that has procedures that allow Guile to do client-side URL transfers, like requesting documents from http or ftp servers. It is based on the libcurl library. GNU Guile is an implementation of Scheme, a Lisp-like computer language.
Here is an example of using guile curl in an interactive Guile session.
scheme@(guile-user)> (use-modules (curl)) scheme@(guile-user)> (define handle (curl-easy-init)) scheme@(guile-user)> (curl-easy-setopt handle 'url "http://www.gnu.org") scheme@(guile-user)> (define s (curl-easy-perform handle)) scheme@(guile-user)> (display s) <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> ...
The full documentation is available:
guile-curl is freely available for download. It is licensed using the terms in the GNU General Public License version 3 (GPLv3).
To install from source code, download the latest compressed file archive and unpack it.
Then run this slightly unusual configure sequence.
$ ./configure --with-guilesitedir=<sitedir> --with-guileextensiondir=<extension-dir> $ make $ sudo make install
<sitedir> and <extensiondir> are where the guile module and the library object are supposed to be installed. The locations of these directories -- and the method used to determine those locations -- change with each version of Guile. To locate the appropriate directory for your installation, try the following commands.
For Guile 1.8's site dir try
$ guile -c '(display (%site-dir))'
For Guile 1.8's extension dir try
$ guile-config info libdir
For Guile 2.0's site dir try
$ pkg-config guile-2.0 --variable=sitedir
For Guile 2.0's extension dir try
$ pkg-config guile-2.0 --variable=extensiondir
The git repository for this project is at github.com/spk121/guile-curl