Hsffig is a tool to convert a C header file (.h) into Haskell code containing FFI import statements for all entities whose declarations are found in the header file. Current release version of hsffig is 1.0 (release date 07/30/2005).
The project homepage is located at http://hsffig.sourceforge.net. Hsffig source code may be downloaded from the "File Releases" section of the web page http://www.sourceforge.net/projects/hsffig. Source tarball file name is hsffig-1.0.tar.gz. Darcs users may check out from the repos at:
- darcs get http://hsffig.sourceforge.net/repos/hsffig-1.0 ("stable" snapshot)
- darcs get http://www.golubovsky.org/repos/hsffig-1.0 ("unstable" snapshot)
Building from source
Hsffig has been released as a Cabalized package. The distribution tarball file contains a minimal version of Cabal setup program, so it is not necessary to have Cabal installed in order to install hsffig. Even more, it is advised to use the Cabal setup program (further referred to as cabal-setup) as it was slightly tailored to the details of hsffig installation.
- After unpacking the tarball, go to the root directory of the distibution and run make. This builds the cabal-setup executable necessary for proper package build and installation.
- Run ./cabal-setup configure. Alex is required to compile hsffig, so it is necessary to provide path to Alex executable (the --with-alex= option of ./cabal-setup configure). This creates the package build configuration file.
- Run ./cabal-setup build. This builds the hsffig library, and all executables.
- Run ./cabal-setup install. This installs the library and the executables, and registers the package with GHC.
At this point, hsffig is ready to use.