Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Wrong parameters from dpkg-buildflags for LDFLAGS on Forky #1106

Copy link
Copy link

Description

@Paebbels
Issue body actions

I'm building CPython on my own CI infrastructure for Forky (Debian 14, testing). Currently the output of dpkg-buildflags --get LDLAGS is broken, because:

  • it contains a space and breaks further concatenations in the Dockerfile e.g. with ,--strip-all
  • it emits a compiler flag appended to linker flags.

The output I see is:
LDFLAGS="-Wl,-z-relro -fcf-protection,--strip-all"

When debugging the output from dpkg-buildflags, I get
LDFLAGS="-Wl,-z-relro -fcf-protection"

Looking at the outputs of make, I noticed -fcf-protection close to other compiler flags, which is correct. Thus, -fcf-protection seems to be applied two times.

Workaround:
LDFLAGS="${LDFLAGS%% *}"

I'm not sure who is responsible for dpkg-buildflags and where to report it.
I just wanted to inform docker-library of a potential future problem for upcoming Forky - if not fixed until then.


I checked Forky and Trixie images from Docker Hub:

CFLAGS LDFLAGS
Debian 13, Trixie -g -O2 ..... -fcf-protection -Wl,-z,relro
Debian 14, Forky -g -O2 ..... -fcf-protection -Wl,-z,relro -fcf-protection

Documentation for -fcf-protection: https://gcc.gnu.org/onlinedocs/gcc-15.2.0/gcc/Instrumentation-Options.html#index-fcf-protection

This option is not a linker option.


/cc @skoehler

Reactions are currently unavailable

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      Morty Proxy This is a proxified and sanitized view of the page, visit original site.