Skip to content

Make it installable on Windows#75

Open
Young-Sook wants to merge 6 commits intoBiocPy:masterfrom
Young-Sook:installable-on-windows
Open

Make it installable on Windows#75
Young-Sook wants to merge 6 commits intoBiocPy:masterfrom
Young-Sook:installable-on-windows

Conversation

@Young-Sook
Copy link
Copy Markdown

Hi,

I used an AI model to make it installable on Windows. It's working pretty well on my side.

Below is the summary of the fixes:

  1. lib/src/rdswrapper.cpp — Updated for new rds2cpp API The upstream rds2cpp library had breaking API changes: Attributes: Changed from a struct with .names/.values vectors to std::vector where each Attribute has a SymbolIndex name + unique_ptr value. Attribute names now require a lookup into a global symbols table. StringVector::data: Changed from vector to vector where String has an optional value (supports missing/NA strings). RdaFile: contents (a PairList-like struct with .tag_names, .has_tag, .data) was replaced by objects (a vector with .name as SymbolIndex and .value). The RdsReader class now carries a const std::vectorrds2cpp::Symbol* pointer to resolve symbol names. Added #include .

  2. lib/CMakeLists.txt — Added zlib for Windows The byteme library conditionally includes gzip support only when zlib.h is available (#if __has_include("zlib.h")). On Windows, zlib isn't typically installed. Added CMake logic to auto-fetch and build zlib from source via FetchContent when the system zlib isn't found.

  3. setup.py — Fixed Windows file copy The old code copied _core.dll → _core.pyd, but the actual CMake output is named lib_rds_parser. pybind11 appends ABI tags (e.g. lib_rds_parser.cp312-win_amd64.pyd), so a glob pattern is now used to find the built file.

  4. setup.cfg — Added Windows platform Changed platforms = Mac, Linux to platforms = Mac, Linux, Windows.

Thanks,
Youngsook

@jkanche
Copy link
Copy Markdown
Member

jkanche commented Apr 23, 2026

Hi @Young-Sook, thank you for contributing and testing the changes for windows users. This has been on our backlog for quite a while, so i appreciate the help.

I'm working on #74 that brings in the newer changes to the rds2cpp library. this should mostly take care of (1). I'll finish this over the weekend and take a deeper look at the PR.

after a quick look, It would be nice to

  1. enable tests on windows in github actions
  2. update the build action to also generate windows specific wheels so that users don't have to build from source.

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