]> git.cworth.org Git - apitrace/blobdiff - retrace/CMakeLists.txt
common: dump backtrace on signals
[apitrace] / retrace / CMakeLists.txt
index b271727458bb2d6db722c045eaee1eb193dbe4c5..fcb8f187659bbc0b70f41b223ab5c525d9a26bfd 100644 (file)
@@ -18,6 +18,7 @@ add_custom_command (
                 glretrace.py
                 retrace.py
                 ${CMAKE_SOURCE_DIR}/specs/glapi.py
+                ${CMAKE_SOURCE_DIR}/specs/glesapi.py
                 ${CMAKE_SOURCE_DIR}/specs/gltypes.py
                 ${CMAKE_SOURCE_DIR}/specs/stdapi.py
 )
@@ -45,6 +46,7 @@ target_link_libraries (retrace_common
     ${ZLIB_LIBRARIES}
     ${SNAPPY_LIBRARIES}
     ${GETOPT_LIBRARIES}
+    ${LIBBACKTRACE_LIBRARIES}
 )
 
 add_library (glretrace_common STATIC
@@ -102,6 +104,9 @@ if (WIN32 OR APPLE OR X11_FOUND)
 
         if (${CMAKE_SYSTEM_NAME} MATCHES "Linux")
             target_link_libraries (glretrace rt)
+            if (READPROC_H_FOUND)
+                target_link_libraries (glretrace ${proc_LIBRARY})
+            endif ()
         endif ()
 
     endif ()
@@ -127,6 +132,9 @@ if (ENABLE_EGL AND X11_FOUND AND NOT WIN32 AND NOT APPLE)
 
     if (${CMAKE_SYSTEM_NAME} MATCHES "Linux")
         target_link_libraries (eglretrace rt)
+        if (READPROC_H_FOUND)
+            target_link_libraries (eglretrace ${proc_LIBRARY})
+        endif ()
     endif ()
 
     install (TARGETS eglretrace RUNTIME DESTINATION bin) 
@@ -187,13 +195,17 @@ if (WIN32)
             set (DXGI_MODULES ${DXGI_MODULES} d3d10_1)
         endif ()
         set (D3DSTATE_SOURCES ${D3DSTATE_SOURCES}
+            dxgistate.cpp
             d3d10state.cpp
             d3d10state_images.cpp
         )
     endif ()
 
     if (DirectX_D3D11_INCLUDE_DIR)
-        include_directories (BEFORE SYSTEM ${DirectX_D3D11_INCLUDE_DIR})
+        include_directories (BEFORE SYSTEM
+            ${DirectX_D3D11_INCLUDE_DIR}
+            ${CMAKE_SOURCE_DIR}/thirdparty/directxtex/DirectXTex
+        )
         set (DXGI_MODULES ${DXGI_MODULES} d3d11)
         if (DirectX_D3D11_1_INCLUDE_DIR)
             include_directories (BEFORE SYSTEM ${DirectX_D3D11_1_INCLUDE_DIR})
@@ -221,6 +233,7 @@ if (WIN32)
                 ${CMAKE_SOURCE_DIR}/specs/d3d10misc.py
                 ${CMAKE_SOURCE_DIR}/specs/d3d10sdklayers.py
                 ${CMAKE_SOURCE_DIR}/specs/d3dcommon.py
+                ${CMAKE_SOURCE_DIR}/specs/dxgi1_2.py
                 ${CMAKE_SOURCE_DIR}/specs/dxgi.py
                 ${CMAKE_SOURCE_DIR}/specs/dxgitype.py
                 ${CMAKE_SOURCE_DIR}/specs/dxgiformat.py
@@ -242,6 +255,9 @@ if (WIN32)
         retrace_common
         d3dhelpers
     )
+    if (DirectX_D3D11_INCLUDE_DIR)
+        target_link_libraries (d3dretrace directxtex)
+    endif ()
 
     install (TARGETS d3dretrace RUNTIME DESTINATION bin)
 endif ()