Blame docs/build-with-makefiles.md

Packit bfcc33
### Get the sources
Packit bfcc33
```bash
Packit bfcc33
# using git is preferred
Packit bfcc33
git clone https://github.com/sass/libsass.git
Packit bfcc33
# only needed for sassc and/or testsuite
Packit bfcc33
git clone https://github.com/sass/sassc.git libsass/sassc
Packit bfcc33
git clone https://github.com/sass/sass-spec.git libsass/sass-spec
Packit bfcc33
```
Packit bfcc33
Packit bfcc33
### Decide for static or shared library
Packit bfcc33
Packit bfcc33
`libsass` can be built and linked as a `static` or as a `shared` library. The default is `static`. To change it you can set the `BUILD` environment variable:
Packit bfcc33
Packit bfcc33
```bash
Packit bfcc33
export BUILD="shared"
Packit bfcc33
```
Packit bfcc33
Packit bfcc33
Alternatively you can also define it directly when calling make:
Packit bfcc33
Packit bfcc33
```bash
Packit bfcc33
BUILD="shared" make ...
Packit bfcc33
```
Packit bfcc33
Packit bfcc33
### Compile the library
Packit bfcc33
```bash
Packit bfcc33
make -C libsass -j5
Packit bfcc33
```
Packit bfcc33
Packit bfcc33
### Results can be found in
Packit bfcc33
```bash
Packit bfcc33
$ ls libsass/lib
Packit bfcc33
libsass.a libsass.so
Packit bfcc33
```
Packit bfcc33
Packit bfcc33
### Install onto the system
Packit bfcc33
Packit bfcc33
We recommend to use [autotools to install](build-with-autotools.md) libsass onto the
Packit bfcc33
system, since that brings all the benefits of using libtools as the main install method.
Packit bfcc33
If you still want to install libsass via the makefile, you need to make sure that gnu
Packit bfcc33
`install` utility (or compatible) is installed on your system.
Packit bfcc33
```bash
Packit bfcc33
yum install coreutils # RedHat Linux
Packit bfcc33
emerge -a coreutils # Gentoo Linux
Packit bfcc33
pkgin install coreutils # SmartOS
Packit bfcc33
```
Packit bfcc33
Packit bfcc33
You can set the install location by setting `PREFIX`
Packit bfcc33
```bash
Packit bfcc33
PREFIX="/opt/local" make install
Packit bfcc33
```
Packit bfcc33
Packit bfcc33
Packit bfcc33
### Compling sassc
Packit bfcc33
Packit bfcc33
```bash
Packit bfcc33
# Let build know library location
Packit bfcc33
export SASS_LIBSASS_PATH="`pwd`/libsass"
Packit bfcc33
# Invokes the sassc makefile
Packit bfcc33
make -C libsass -j5 sassc
Packit bfcc33
```
Packit bfcc33
Packit bfcc33
### Run the spec test-suite
Packit bfcc33
Packit bfcc33
```bash
Packit bfcc33
# needs ruby available
Packit bfcc33
# also gem install minitest
Packit bfcc33
make -C libsass -j5 test_build
Packit bfcc33
```