summaryrefslogtreecommitdiff
path: root/README
blob: cf3d425acabed459e31ff28d0a2d5b7d64890e22 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
LibCSS -- a CSS parser and selection engine
===========================================

Overview
--------

  LibCSS is a CSS parser and selection engine. It aims to parse the forward
  compatible CSS grammar.

Requirements
------------

  LibCSS requires the following tools:

    + A C99 capable C compiler
    + GNU make or compatible
    + Pkg-config
    + Perl (for the testcases)
    + Python3 (minimum 3.6, for generated selection code)

  LibCSS also requires the following libraries to be installed:

    +  LibNSLog
    +  LibParserUtils
    +  LibWapcaplet

Compilation
-----------

  If necessary, modify the toolchain settings in the Makefile.
  Invoke make:

      $ make

Regenerating generated selection source code
--------------------------------------------

  To regenerate the selection sources (computed style data accesses),
  note this requires python3:

      $ make select_generator

Verification
------------

  To verify that the parser is working, it is necessary to specify a
  different makefile target than that used for normal compilation, thus:

      $ make test

API documentation
-----------------

  Currently, there is none. However, the code is well commented and the
  public API may be found in the "include" directory. The testcase sources
  may also be of use in working out how to use it.