Skip to content

Conversation

@Mersoltane
Copy link
Collaborator

1. amigo/init.py

  • Added DLL directory paths for Windows to load required libraries (MKL, MS-MPI, OpenBLAS)
  • Uses environment variables for flexibility (OPENBLAS_DLL_DIR, MSMPI_BIN)
  • Now properly exports MemoryLocation enum from the compiled extension

2. amigo/model.py:

  • Updated _build_module() to:
  • Add venv Library path to CMAKE_PREFIX_PATH for MKL detection
  • Pass BLAS/LAPACK library hints to CMake on Windows
  • Pass MS-MPI include/library paths to CMake on Windows
  • Generate CMakeLists.txt with C++17 standard and MSVC /permissive- flag

3. cmake/amigoAddModule.cmake:

  • Fixed output directory for multi-config generators (Visual Studio)
  • Now properly places .pyd files in the source directory instead of Release/Debug subdirectories

4. amigo/amigo.cpp (already existed, no changes needed):

  • Already had MemoryLocation enum properly defined - just needed rebuilding
  1. Updated the requirements.txt

@Mersoltane
Copy link
Collaborator Author

I actually found an efficient way to do instead:

  • Instead of passing library paths from Python at build time, the main amigoConfig.cmake now properly exports BLAS/LAPACK/MPI settings that were found during installation.

  • Module builds (amigoAddModule.cmake) inherit these cached paths automatically, eliminating redundant find_package() calls.

  • Removed duplicate dependency declarations between requirements.txt and pyproject.toml.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants