aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMike Stroyan <mike@LunarG.com>2014-10-30 15:59:54 -0600
committerCourtney Goeltzenleuchter <courtney@LunarG.com>2014-10-31 15:29:20 -0600
commit0b957ef9862855db7f68a19a41e5cd2244d5078c (patch)
tree4221e4402f21d3290de46f5c41ff9eff043939be
parent97db1c109593d2ee2854260457eaed0c495781aa (diff)
downloadusermoji-0b957ef9862855db7f68a19a41e5cd2244d5078c.tar.xz
Document build dependencies and demos
-rw-r--r--BUILD.md44
-rw-r--r--demos/CMakeLists.txt2
2 files changed, 39 insertions, 7 deletions
diff --git a/BUILD.md b/BUILD.md
index deb9c580..0d5ac1e5 100644
--- a/BUILD.md
+++ b/BUILD.md
@@ -3,34 +3,66 @@ The XGL Sample Intel driver supports Linux.
System Requirements
===================
-Ubuntu 13.10, Ubuntu 14.04 LTS
-gcc
-drm
+Ubuntu 14.04 LTS, (Ubuntu 14.10 needed for DRI 3 demos)
+
+sudo apt-get install git subversion cmake libgl1-mesa-dev freeglut3-dev libglm-dev libpng12-dev
+sudo apt-get build-dep mesa
BUILD
=====
-The sample driver users cmake and should work with the usual cmake options and utilities.
+The sample driver uses cmake and should work with the usual cmake options and utilities.
The standard build process builds the icd, the icd loader and all the tests.
Example debug build:
cd xgl # cd to the root of the xgl git repository
+export KHRONOS_ACCOUNT_NAME= <subversion login name for svn checkout of BIL>
+./update_external_sources.sh # fetches and builds glslang, llvm, LunarGLASS, and BIL
cmake -H. -Bdbuild -DCMAKE_BUILD_TYPE=Debug
cd dbuild
make
To run XGL programs you must tell the icd loader where to find the libraries. Set the
environment variable LIBXGL_DRIVERS_PATH to the driver path. For example:
-> export LIBXGL_DRIVERS_PATH=~/xgl/dbuild/icd/intel
+export LIBXGL_DRIVERS_PATH=$PWD/icd/intel
TEST
====
-The test executibles can be found in the build/tests directory. The tests use the Google
+The test executibles can be found in the dbuild/tests directory. The tests use the Google
gtest infrastructure. Tests avilable so far:
- xglinfo: Report GPU properties
- xglbase: Test basic entry points
+- xgl_blit_tests: Test XGL Blits (copy, clear, and resolve)
- xgl_image_tests: Test XGL image related calls needed by render_test
- xgl_render_tests: Render a single triangle with XGL. Triangle will be in a .ppm in
the current directory at the end of the test.
+
+DEMOS
+=====
+
+The demos executibles can be found in the dbuild/demos directory. The demos use DRI 3
+to render directly onto window surfaces.
+- tri: a textured triangle
+- cube: a textured spinning cube
+
+RENDER NODES
+============
+
+The render tests depend on access to DRM render nodes.
+To make that available, a couple of config files need to be created to set a module option
+and make accessible device files.
+The system will need to be rebooted with these files in place to complete initialization.
+These commands will create the config files.
+
+sudo tee /etc/modprobe.d/drm.conf << EOF
+# Enable render nodes
+options drm rnodes=1
+EOF
+
+sudo tee /etc/udev/rules.d/drm.rules << EOF
+# Add permissions to render nodes
+SUBSYSTEM=="drm", ACTION=="add", DEVPATH=="/devices/*/renderD*", MODE="020666"
+EOF
+
diff --git a/demos/CMakeLists.txt b/demos/CMakeLists.txt
index 79964a58..33a3f8ac 100644
--- a/demos/CMakeLists.txt
+++ b/demos/CMakeLists.txt
@@ -6,7 +6,7 @@ if(NOT EXISTS /usr/include/glm/glm.hpp)
message(FATAL_ERROR "Necessary libglm-dev headers cannot be found: sudo apt-get install libglm-dev")
endif()
if(NOT EXISTS /usr/include/png.h)
- message(FATAL_ERROR "Necessary png12-dev headers cannot be found: sudo apt-get install png12-dev")
+ message(FATAL_ERROR "Necessary png12-dev headers cannot be found: sudo apt-get install libpng12-dev")
endif()
file(GLOB TEXTURES