[Rpm-maint] [rpm-software-management/rpm] Regression: --define '_target_os linux' does not work since version 4.20.0 (Issue #3866)
Aditya Garg
notifications at github.com
Fri Jul 18 13:21:52 UTC 2025
AdityaGarg8 created an issue (rpm-software-management/rpm#3866)
**Describe the bug**
In case I build rpm packages on macOS, I can not longer set the target os to linux since version 4.20.0
**To Reproduce**
Steps to reproduce the behavior:
1. Create a sample spec file in macOS
2. Run `rpmbuild -bb --define '_target_os linux' "/path/to/specfile.spec"`
Please link or attach the packages or spec files involved.
```spec
Name: apple-firmware
Version: ${ver}
Release: 1
Summary: Wi-Fi and Bluetooth firmware for T2 Macs
License: Proprietary
BuildArch: noarch
Source1: firmware.tar
%description
Wi-Fi and Bluetooth firmware for T2 Macs
%prep
tar -xf %{SOURCE1}
%build
%install
mkdir -p %{buildroot}/usr/lib/firmware/brcm
install -m 644 brcm* %{buildroot}/usr/lib/firmware/brcm/
%posttrans
modprobe -r brcmfmac_wcc || true
modprobe -r brcmfmac || true
modprobe brcmfmac || true
modprobe -r hci_bcm4377 || true
modprobe hci_bcm4377 || true
%files
/usr/lib/firmware/brcm/*
```
**Expected behavior**
`rpm -qp /path/to/file.rpm --qf '%{OS}\n'` should show linux
**Output**
`rpm -qp /path/to/file.rpm --qf '%{OS}\n'` is showing darwin on macOS
**Environment**
- OS / Distribution: macOS Sequoia
- Version: rpm-4.20.1
--
Reply to this email directly or view it on GitHub:
https://github.com/rpm-software-management/rpm/issues/3866
You are receiving this because you are subscribed to this thread.
Message ID: <rpm-software-management/rpm/issues/3866 at github.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.rpm.org/pipermail/rpm-maint/attachments/20250718/403d447d/attachment.htm>
More information about the Rpm-maint
mailing list