Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.
RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.

Bug 2061720

Summary: libpmemobj-cpp-1.11-1.module+el8.6.0+14043+a2e27587 fails to build if clang is installed
Product: Red Hat Enterprise Linux 8 Reporter: Kamil Dudka <kdudka>
Component: libpmemobj-cppAssignee: Bryan Gurney <bgurney>
Status: CLOSED ERRATA QA Contact: xiaoli feng <xifeng>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 8.6CC: bgurney, kdudka, lmiksik, revers, xifeng, xzhou
Target Milestone: rcKeywords: Regression, Triaged
Target Release: 8.6Flags: xifeng: needinfo-
xifeng: needinfo-
pm-rhel: mirror+
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of:
: 2062769 (view as bug list) Environment:
Last Closed: 2022-05-10 14:25:21 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: 2062769    

Description Kamil Dudka 2022-03-08 12:05:56 UTC
Description:
libpmemobj-cpp-1.11-1.module+el8.6.0+14043+a2e27587 fails to build if clang is installed.  This is a regression compared to libpmemobj-cpp-1.9-1.module+el8.4.0+10588+24dee5ba where it worked fine.


Version-Release number of selected component (if applicable):
libpmemobj-cpp-1.11-1.module+el8.6.0+14043+a2e27587


Steps to Reproduce:
# brew mock-config --target module-a2e27587eb8cf2b4 --arch x86_64 > /etc/default.cfg
# mock --init
# mock --install http://download.eng.bos.redhat.com/brewroot/vol/rhel-8/packages/pmdk/1.11.1/1.module+el8.6.0+14043+a2e27587/x86_64/libpmem-1.11.1-1.module+el8.6.0+14043+a2e27587.x86_64.rpm http://download.eng.bos.redhat.com/brewroot/vol/rhel-8/packages/pmdk/1.11.1/1.module+el8.6.0+14043+a2e27587/x86_64/libpmem-devel-1.11.1-1.module+el8.6.0+14043+a2e27587.x86_64.rpm http://download.eng.bos.redhat.com/brewroot/vol/rhel-8/packages/pmdk/1.11.1/1.module+el8.6.0+14043+a2e27587/x86_64/libpmemobj-1.11.1-1.module+el8.6.0+14043+a2e27587.x86_64.rpm http://download.eng.bos.redhat.com/brewroot/vol/rhel-8/packages/pmdk/1.11.1/1.module+el8.6.0+14043+a2e27587/x86_64/libpmemobj-devel-1.11.1-1.module+el8.6.0+14043+a2e27587.x86_64.rpm
# mock --install clang
# brew download-build -a src libpmemobj-cpp-1.11-1.module+el8.6.0+14043+a2e27587
# mock --no-clean --rebuild libpmemobj-cpp-1.11-1.module+el8.6.0+14043+a2e27587.src.rpm


Actual results:
[...]
[ 25%] Linking CXX executable self_relative_ptr_atomic_pmem
cd /builddir/build/BUILD/libpmemobj-cpp-1.11/build/tests && /usr/bin/cmake -E cmake_link_script CMakeFiles/self_relative_ptr_atomic_pmem.dir/link.txt --verbose=1
/usr/bin/c++ -O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -fexceptions -fstack-protector-strong -grecord-gcc-switches -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -m64 -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -Wall -Wpointer-arith -Wunused-macros -Wsign-conversion -Wsign-compare -fno-common -g -ggdb -DDEBUG -Wl,-z,relro  -Wl,-z,now -specs=/usr/lib/rpm/redhat/redhat-hardened-ld -rdynamic CMakeFiles/self_relative_ptr_atomic_pmem.dir/self_relative_ptr_atomic/self_relative_ptr_atomic_pmem.cpp.o -o self_relative_ptr_atomic_pmem  -lpmemobj -lpthread libtest_backtrace.a libvalgrind_internal.a -latomic 
make[2]: Leaving directory '/builddir/build/BUILD/libpmemobj-cpp-1.11/build'
make[1]: Leaving directory '/builddir/build/BUILD/libpmemobj-cpp-1.11/build'


RPM build errors:
/usr/bin/ld: cannot find /usr/lib64/libatomic.so.1.2.0
collect2: error: ld returned 1 exit status
make[2]: *** [tests/CMakeFiles/self_relative_ptr_atomic_pmem.dir/build.make:102: tests/self_relative_ptr_atomic_pmem] Error 1
make[1]: *** [CMakeFiles/Makefile2:8754: tests/CMakeFiles/self_relative_ptr_atomic_pmem.dir/all] Error 2
make: *** [Makefile:149: all] Error 2
error: Bad exit status from /var/tmp/rpm-tmp.q2i8Dw (%build)
    Bad exit status from /var/tmp/rpm-tmp.q2i8Dw (%build)


Expected results:
Successful build.


Additional info:
This bug prevents the package from being automatically scanned by Covscan.

Comment 1 Bryan Gurney 2022-03-08 14:27:20 UTC
I know what needs to be done: the libpmemobj-cpp.spec file needs to have this added: "BuildRequires: libatomic"

I relayed this to Kamil, who reports that adding this into the buildroot seems to fix the problem.

Comment 18 errata-xmlrpc 2022-05-10 14:25:21 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory (pmdk:1_fileformat_v6 bug fix and enhancement update), and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHEA-2022:1943