From c17a98f73de96ea7525cec330c9fd0f960975bcc Mon Sep 17 00:00:00 2001
From: Joris Vaillant <joris.vaillant@inria.fr>
Date: Wed, 22 Nov 2023 09:43:34 +0100
Subject: [PATCH] cmake: fix stub generation on windows

---
 .github/workflows/windows-conda.yml | 5 -----
 python/CMakeLists.txt               | 2 +-
 2 files changed, 1 insertion(+), 6 deletions(-)

diff --git a/.github/workflows/windows-conda.yml b/.github/workflows/windows-conda.yml
index ced408f..3a5ca23 100644
--- a/.github/workflows/windows-conda.yml
+++ b/.github/workflows/windows-conda.yml
@@ -51,11 +51,6 @@ jobs:
         cmake --build . --config Release --target install
         if errorlevel 1 exit 1
 
-        :: Build stubs
-        git clone https://github.com/jcarpent/pybind11-stubgen.git
-        python "%CD%\pybind11-stubgen\pybind11_stubgen\__init__.py" -o %CONDA_PREFIX%\Lib\site-packages\eigenpy eigenpy --boost-python --ignore-invalid signature --no-setup-py --root-module-suffix ""
-        if errorlevel 1 exit 1
-
         :: Testing
         ctest --output-on-failure -C Release -V
         if errorlevel 1 exit 1
diff --git a/python/CMakeLists.txt b/python/CMakeLists.txt
index b23c49a..6e769cc 100644
--- a/python/CMakeLists.txt
+++ b/python/CMakeLists.txt
@@ -61,7 +61,7 @@ if(GENERATE_PYTHON_STUBS)
   load_stubgen()
 
   generate_stubs(${CMAKE_CURRENT_BINARY_DIR} ${PROJECT_NAME}
-                 ${ABSOLUTE_PYTHON_SITELIB} ${PYWRAP})
+                 ${ABSOLUTE_PYTHON_SITELIB} ${PYWRAP}) ${PROJECT_NAME}
 endif(GENERATE_PYTHON_STUBS)
 
 # --- INSTALL SCRIPTS
-- 
GitLab