diff options
author | Tomi Valkeinen | 2015-10-01 03:40:36 -0500 |
---|---|---|
committer | Tomi Valkeinen | 2015-10-01 11:40:22 -0500 |
commit | 6b04b303b7cc4a5eba912d4b67349bae7b8e88b6 (patch) | |
tree | bc515e4bce60450129b1fb629aec8e963a2e9bb0 /README.md | |
parent | ba853e936dd33f32291b2958c13530d5796b575c (diff) | |
download | external-libkmsxx-6b04b303b7cc4a5eba912d4b67349bae7b8e88b6.tar.gz external-libkmsxx-6b04b303b7cc4a5eba912d4b67349bae7b8e88b6.tar.xz external-libkmsxx-6b04b303b7cc4a5eba912d4b67349bae7b8e88b6.zip |
add README
Diffstat (limited to 'README.md')
-rw-r--r-- | README.md | 54 |
1 files changed, 54 insertions, 0 deletions
diff --git a/README.md b/README.md new file mode 100644 index 0000000..ea3cd24 --- /dev/null +++ b/README.md | |||
@@ -0,0 +1,54 @@ | |||
1 | # libkms++ - C++ library for kernel mode setting | ||
2 | |||
3 | libkms++ is a C++11 library for kernel mode setting. | ||
4 | |||
5 | Also included are simple test tools for KMS and python and lua wrappers for libkms++. | ||
6 | |||
7 | ## Dependencies: | ||
8 | |||
9 | - libdrm | ||
10 | - SWIG 3.x (for python & lua bindings) | ||
11 | - Python 3.x (for python bindings) | ||
12 | - Lua 5.x (for lua bindings) | ||
13 | |||
14 | ## Build instructions: | ||
15 | |||
16 | ``` | ||
17 | $ mkdir build | ||
18 | $ cd build | ||
19 | $ cmake .. | ||
20 | $ make -j4 | ||
21 | ``` | ||
22 | |||
23 | ## Cross compiling instructions: | ||
24 | |||
25 | Directions for cross compiling depend on your environment. These are for mine (buildroot): | ||
26 | |||
27 | As above, but specify `-DCMAKE_TOOLCHAIN_FILE=<path>/your-toolchain.cmake` for cmake, where your-toolchain.cmake is something similar to: | ||
28 | |||
29 | ``` | ||
30 | SET(CMAKE_SYSTEM_NAME Linux) | ||
31 | |||
32 | SET(BROOT "<buildroot>/output/") | ||
33 | |||
34 | # specify the cross compiler | ||
35 | SET(CMAKE_C_COMPILER ${BROOT}/host/usr/bin/arm-buildroot-linux-gnueabihf-gcc) | ||
36 | SET(CMAKE_CXX_COMPILER ${BROOT}/host/usr/bin/arm-buildroot-linux-gnueabihf-g++) | ||
37 | |||
38 | # where is the target environment | ||
39 | SET(CMAKE_FIND_ROOT_PATH ${BROOT}/target ${BROOT}/host) | ||
40 | |||
41 | SET(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM ONLY) | ||
42 | SET(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ONLY) | ||
43 | SET(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY) | ||
44 | ``` | ||
45 | |||
46 | ## Build options | ||
47 | |||
48 | You can use the following cmake flags to control the build. Use `-DFLAG=VALUE` to set them. | ||
49 | |||
50 | Option name | Values | Default | ||
51 | -------------------- | ------------- | -------- | ||
52 | CMAKE_BUILD_TYPE | Release/Debug | Release | ||
53 | LIBKMS_ENABLE_PYTHON | ON/OFF | ON | ||
54 | LIBKMS_ENABLE_LUA | ON/OFF | ON | ||