|
|
|
SCTL is specifically designed to work with the GNU C++ compiler as
many of the elements within SCTL are mostly non-portable to other compilers.
For instance, the use of the #include_next preprocessor
directive is necessary to provide efficient header file overloading.
The broad range of target processors and platforms that the GNU compiler
support is a perfect fit for SCTL since the performance is mostly
achieved through specialized assembly programming within the SCTL class
functions.
SCTL has recently done away with the the previous sctl-config
script in favor of the pkg-config utility. To compile
a simple one-file code like the 'matrix' example provided, use the
following syntax:
|
|
g++ `pkg-config --cflags SCTL` -o matrix matrix.cpp
|
|
|
Operating system and CPU architecture specifications can be specified
using the --define-variable option. For example,
compiling the sorted list code for the 'i586' CPU architecture can be
accomplished by the following command:
|
|
g++ -c `pkg-config --cflags --define-variable=arch=i586 SCTL` sortedlist.cpp
g++ -o sortedlist sortedlist.o `pkg-config --libs --define-variable=arch=i586 SCTL`
|
|
|
|
This example assumes the 'i586' SCTL library is installed.
|
|
|
top of page
|
|