Skip to content
mpictor edited this page Mar 6, 2012 · 11 revisions

Required packages

cmake >= v2.8.3
bison
flex

For windows, the versions of flex and bison that are distributed in msysgit are known to work. Some flex versions newer than v2.5.35 do not work on windows.

How to build

cd scl
mkdir build
cd build
cmake ..    # '..' is the path to the directory containing the top-level CMakeLists.txt
make

Configuration options (append to the 'cmake ..' line):

  • -DBUILD_SCHEMAS="path/to/schema.exp;path/to/schema2.exp"
    • For each schema listed, this
      • generates c++
      • compiles it into a library
      • builds a 'p21read' program (see below)
    • Will also work with directories, as long as each directory has a single express file. Multiple files/directories are separated by semicolons.
  • -DSCL_BUILD_TYPE=[Debug|Release|RelWithDebInfo|MinSizeRel]
    • default is a Debug build
    • Release turns on optimizations and strips out debugging information
    • see also: cmake documentation for CMAKE_BUILD_TYPE

Create c++ for a schema manually:

mkdir schema_name
cd schema_name
path/to/fedex_plus path/to/schema.exp

Files created in build dir

  • build/src/ contains source generated by flex and bison
  • build/CMakeFiles contains temporary files (i.e. .o files)
  • build/SCHEMA_NAME contains source generated for schema SCHEMA_NAME
    • note that SCHEMA_NAME is the name of the express file, without the .exp extension
  • build/bin/ contains executables
    • fedex_plus
      • Generates C++ code
    • fedex_python
      • Generates Python code
    • exppp
      • Express Pretty Printer
      • Normally, this isn't built
    • check_express
      • Formerly fedex
      • Parses the express and checks for errors. The functionality of fedex_plus/fedex_python is a superset of this.
    • p21read_sdai_SCHEMA_NAME
      • reads one step file and writes another. It may change whitespace or remove comments; otherwise, the input and output files are supposed to be identical. If they are not identical, either the file does not match the schema, or there is a bug in SCL.
  • build/lib/ contains libraries, including libs created for schemas

More options are available - see the man pages, and read comments in the various CMakeLists.txt files.

Clone this wiki locally