From b0bae2e9eedba51aa35ba0bb03ae5b62eb607ac2 Mon Sep 17 00:00:00 2001 From: Shukant Pal Date: Tue, 28 Nov 2023 18:47:08 -0800 Subject: [PATCH] pyktx (Python bindings for libktx) (#698) Add Python bindings, documentation and tests. Add to CI. Adds a manual Publish step for publishing to PyPl. See #663 for details. Fixes #663. Co-authored-by: Mark Callow <2244683+MarkCallow@users.noreply.github.com> --- cmake/docs.cmake | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/cmake/docs.cmake b/cmake/docs.cmake index 332642e5b7..09524e439f 100644 --- a/cmake/docs.cmake +++ b/cmake/docs.cmake @@ -189,6 +189,17 @@ function( CreateDocJSWrappers ) add_docs_cmake_plus( jswrappers.doc pkgdoc/jswrappersDoxyLayout.xml ) endfunction() +# pyktxwrappers.doc +function( CreateDocPyktxWrappers ) + add_custom_command( + TARGET libktx.doc + POST_BUILD + COMMAND + ${CMAKE_COMMAND} -E copy_directory ${KTX_BUILD_DIR}/interface/python_binding/docs/html/pyktx/html ${KTX_BUILD_DIR}/docs/html/pyktx + ) + add_dependencies( libktx.doc pyktx ) +endfunction() + # ktxpkg.doc function( CreateDocKTX ) set( DOXYGEN_PROJECT_NAME "Khronos Texture Software" ) @@ -215,6 +226,9 @@ endfunction() CreateDocLibKTX() CreateDocTools() CreateDocJSWrappers() +if (KTX_FEATURE_PY) + CreateDocPyktxWrappers() +endif() CreateDocKTX() add_dependencies( libktx.doc ktxpkg.doc ktx_version )