Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

static libraries that need to be linked with whole-archive downstream

Open
#101 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
5/5
Estimated time
Over a week
Newbie friendliness
35/100
Issue type
Feature
Clarity
Mostly clear
Activity status
Stale
Tech stack
cmake
Domain
build-system

Research direction

Start by reviewing the CPS file model and the linked CMake discussion about whole-archive linking. Determine how a static library can express whole-archive semantics for downstream consumers, and define the accepted representation and expected linker behavior as the completion criteria.

Written by the indexing model from the issue text.

Description

enhancement

is there a way for a CPS file that describes a static library, to model where a library should be linked as a "whole archive" downstream?

the end result is that the consumer passes something like the following to the linker:

-Wl,--whole-archive -foobar -Wl,--no-whole-archive

I think CMake has a related feature
https://discourse.cmake.org/t/automatically-wrapping-a-static-library-in-whole-archive-no-whole-archive-when-used-during-linking/5883/2

but I think it requires a proxy interface target to model this, e.g.

add_library(L INTERFACE)
target_link_libraries(L INTERFACE "$<LINK_LIBRARY:WHOLE_ARCHIVE,internal_L>")
Dominant language
Python
Stars
191
Forks
14
PR merge metrics
No merged PRs in 30d

Getting set up

This project ships no dev container, Dockerfile or contributing guide, so setting up is up to you: start from its README, and see our first-contribution guide for the general steps.

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from cps-org/cps

All issues in cps-org/cps

Similar issues

More Python issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.