Bug 2317847 - RPM-specific flags embedded in sipconfig
Summary: RPM-specific flags embedded in sipconfig
Keywords:
Status: NEW
Alias: None
Product: Fedora
Classification: Fedora
Component: sip
Version: 42
Hardware: All
OS: Linux
unspecified
medium
Target Milestone: ---
Assignee: Than Ngo
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks: 1225692
TreeView+ depends on / blocked
 
Reported: 2024-10-10 14:32 UTC by Scott K Logan
Modified: 2025-02-26 13:12 UTC (History)
3 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed:
Type: ---
Embargoed:


Attachments (Terms of Use)
Patch to drop -specs= from captured flags (768 bytes, patch)
2024-10-10 14:33 UTC, Scott K Logan
no flags Details | Diff
Patch to drop -specs= from captured flags (3.49 KB, patch)
2024-10-10 14:38 UTC, Scott K Logan
no flags Details | Diff

Description Scott K Logan 2024-10-10 14:32:46 UTC
Hello -

We're facing an issue where non-RPM builds using sip fail because RPM-specific compiler and linker flags are embedded in sipconfig.py. This is probably not a problem for downstream RPM builds which use sip because the necessary environment variables are defined.

Specifically, we see the following compilation failure message:
```
g++: fatal error: environment variable ‘RPM_ARCH’ not defined
```

This seems to be caused by the inclusion of one or more RPM-specific `-specs=...` flags in the captured compile flags in sipconfig.py. I don't have a full understanding of why these flags need to be captured and used when compiling downstream code using sip, but I don't think these flags should be present.

We were able to work around the problem by specifically removing the `-specs=...` flags from the captured flags during sip's build. I've attached a patch which does this, which I hope can be used to arrive at an acceptable solution.

Reproducible: Always

Comment 1 Scott K Logan 2024-10-10 14:33:36 UTC
Created attachment 2051403 [details]
Patch to drop -specs= from captured flags

Comment 2 Scott K Logan 2024-10-10 14:38:13 UTC
Created attachment 2051405 [details]
Patch to drop -specs= from captured flags

Comment 3 Aoife Moloney 2025-02-26 13:12:58 UTC
This bug appears to have been reported against 'rawhide' during the Fedora Linux 42 development cycle.
Changing version to 42.


Note You need to log in before you can comment on or make changes to this bug.