Bug 1543803

Summary: kabi-dw: Does not use Fedora build flags
Product: [Fedora] Fedora Reporter: Florian Weimer <fweimer>
Component: kabi-dwAssignee: Zamir SUN <sztsian>
Status: CLOSED ERRATA QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 28CC: fweimer, skozina, sztsian
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: kabi-dw-0-0.7.20180308gitb8863d0.fc28 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2018-03-30 12:51:09 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 1539083    

Description Florian Weimer 2018-02-09 11:07:14 UTC
kabi-dw-0-0.5.20180130git545535a.fc28 does not use the Fedora build flags as defined in redhat-rpm-config.

More information about RPM macros to set CFLAGS and LDFLAGS is available here:
https://src.fedoraproject.org/rpms/redhat-rpm-config/blob/master/f/buildflags.md

Comment 1 Zamir SUN 2018-02-11 03:11:28 UTC
Patch sent upstream.
https://github.com/skozina/kabi-dw/pull/5

Comment 2 Stanislav Kozina 2018-02-12 10:21:37 UTC
Upstream accepted the changes.

Comment 3 Zamir SUN 2018-02-13 12:12:36 UTC
Hi Florian,

> https://src.fedoraproject.org/rpms/redhat-rpm-config/blob/master/f/
> buildflags.md

From the document, I understand I should use %set_build_flags to set CFLAGS and LDFLAGS. However, it won't build on my environment. It shows the following error

$ rpmbuild -ba kabi-dw.spec 
Executing(%prep): /bin/sh -e /var/tmp/rpm-tmp.gXVRyD
+ umask 022
+ cd /home/zsun/rpmbuild/BUILD
+ cd /home/zsun/rpmbuild/BUILD
+ rm -rf kabi-dw-05c38df0dfc2e0e3eeb605a34234a1bf77c7ea7b
+ /usr/bin/gzip -dc /home/zsun/rpmbuild/SOURCES/kabi-dw-05c38df.tar.gz
+ /usr/bin/tar -xof -
+ STATUS=0
+ '[' 0 -ne 0 ']'
+ cd kabi-dw-05c38df0dfc2e0e3eeb605a34234a1bf77c7ea7b
+ /usr/bin/chmod -Rf a+rX,u+w,g-w,o-w .
+ exit 0
Executing(%build): /bin/sh -e /var/tmp/rpm-tmp.aOdvlA
+ umask 022
+ cd /home/zsun/rpmbuild/BUILD
+ cd kabi-dw-05c38df0dfc2e0e3eeb605a34234a1bf77c7ea7b
+ %set_build_flags
/var/tmp/rpm-tmp.aOdvlA: line 31: fg: no job control
error: Bad exit status from /var/tmp/rpm-tmp.aOdvlA (%build)


RPM build errors:
    Bad exit status from /var/tmp/rpm-tmp.aOdvlA (%build)

My spec file is https://zsun.fedorapeople.org/pub/bugs/1543803/kabi-dw.spec
And the log mentioned in the error message is
https://zsun.fedorapeople.org/pub/bugs/1543803/rpm-tmp.aOdvlA

$ rpm -q rpm-build
rpm-build-4.14.1-1.fc27.x86_64
$ rpm -q redhat-rpm-config
redhat-rpm-config-70-1.fc27.noarch

So can you point me how can I solve this?

Comment 4 Florian Weimer 2018-02-13 13:20:50 UTC
You need a newer rawhide compose, or build in Koji.  (It's been a while since the last successful rawhide compose.)

Comment 5 Fedora End Of Life 2018-02-20 15:30:54 UTC
This bug appears to have been reported against 'rawhide' during the Fedora 28 development cycle.
Changing version to '28'.

Comment 6 Zamir SUN 2018-02-22 02:47:23 UTC
Now blocking by some building issue.
https://github.com/skozina/kabi-dw/issues/6

Comment 7 Zamir SUN 2018-03-08 05:12:35 UTC
The build issue should be fixed now by
https://github.com/skozina/kabi-dw/pull/7

Comment 8 Stanislav Kozina 2018-03-11 18:06:06 UTC
Can we just close this bug then?

Comment 9 Zamir SUN 2018-03-12 05:34:20 UTC
(In reply to Stanislav Kozina from comment #8)
> Can we just close this bug then?

Hi Stanislav,

Not actually. Can you review the PR in comment 7? After the PR in comment 1 merged, I found some more problem, so I send the PR in comment 7 to fix it. This will be fully fixed by the new PR. Once you merged it I will build and close this bug.

Thanks!

Comment 10 Stanislav Kozina 2018-03-12 11:43:56 UTC
Ah, thanks for reminder. The changes in PR7 look good, I've merged them. Thanks!

Comment 11 Fedora Update System 2018-03-12 14:03:56 UTC
kabi-dw-0-0.6.20180308gitb8863d0.fc28 has been submitted as an update to Fedora 28. https://bodhi.fedoraproject.org/updates/FEDORA-2018-69920a3bbe

Comment 12 Fedora Update System 2018-03-12 17:17:10 UTC
kabi-dw-0-0.6.20180308gitb8863d0.fc28 has been pushed to the Fedora 28 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2018-69920a3bbe

Comment 13 Fedora Update System 2018-03-16 13:40:29 UTC
kabi-dw-0-0.7.20180308gitb8863d0.fc28 has been submitted as an update to Fedora 28. https://bodhi.fedoraproject.org/updates/FEDORA-2018-69920a3bbe

Comment 14 Fedora Update System 2018-03-16 14:41:57 UTC
kabi-dw-0-0.7.20180308gitb8863d0.fc28 has been pushed to the Fedora 28 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2018-69920a3bbe

Comment 15 Fedora Update System 2018-03-30 12:51:09 UTC
kabi-dw-0-0.7.20180308gitb8863d0.fc28 has been pushed to the Fedora 28 stable repository. If problems still persist, please make note of it in this bug report.