https://github.com/lexi-lambda/libsol
A C runtime for the sol programming language.
https://github.com/lexi-lambda/libsol
Last synced: 2 months ago
JSON representation
A C runtime for the sol programming language.
- Host: GitHub
- URL: https://github.com/lexi-lambda/libsol
- Owner: lexi-lambda
- License: other
- Created: 2013-02-03T22:40:38.000Z (over 12 years ago)
- Default Branch: master
- Last Pushed: 2014-10-07T08:06:35.000Z (over 10 years ago)
- Last Synced: 2025-04-13T17:09:43.899Z (2 months ago)
- Language: C
- Homepage:
- Size: 488 KB
- Stars: 11
- Watchers: 2
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.markdown
- License: LICENSE
Awesome Lists containing this project
README
Building libsol
===============
Building libsol only requires a C compiler (preferably Clang or GCC) and a
few dependencies.Requirements
------------
To build libsol, you'll need to have the following installed on your system:* [libYAML](http://pyyaml.org/wiki/LibYAML) - a C YAML parser
* [libuv](https://github.com/joyent/libuv) - a C event library, originally designed for use in Node.jsIf you're running Debian, you can get libYAML from the `lib-yaml-0-2` and `lib-yaml-dev`
packages. libuv does not currently distribute packages, so it will need to be built
from source (see the libuv readme).Building
--------
The libsol project can be built using [CMake](http://www.cmake.org/). It is
installed to the /usr/local directories. Currently, most Unix-based operating
systems should be supported, including Linux and Mac OS X.It is recommended that you keep all build files in a subdirectory to avoid
cluttering the repository. The `build` folder is automatically ignored
in the .gitignore file, so you could build the project using GNU Make like this:cd libsol
mkdir build
cd build
cmake ..
make
sudo make installAlternatively, you can specify other generators to use other build systems. For
example, you could generate an Xcode project with the following command:cmake -G Xcode ..
Compiling Sol Programs
======================
In order to compile a sol program, you will need to have generated a C source
file from a standard sol source file. This can be done with the solc utility.
This will output a .c file, which can then be compiled with the following
command (using Clang):clang -lsol -o my-program my-program.c
This should generate a standard executable which can be run view the command
line as usual.