add -latomic flag to lockfree tests for riscv64
Boost does not implement atomic functions for RISC-V, and depend that on compiler. For 16-byte atomic ops, the compiler must link against libatomic.
This commit is contained in:
parent
064431c6de
commit
28c9b15a36
15
boost.spec
15
boost.spec
@ -2,7 +2,7 @@
|
|||||||
|
|
||||||
Name: boost
|
Name: boost
|
||||||
Version: 1.78.0
|
Version: 1.78.0
|
||||||
Release: 16
|
Release: 17
|
||||||
Summary: The free peer-reviewed portable C++ source libraries
|
Summary: The free peer-reviewed portable C++ source libraries
|
||||||
License: Boost Software License 1.0
|
License: Boost Software License 1.0
|
||||||
URL: http://www.boost.org
|
URL: http://www.boost.org
|
||||||
@ -74,6 +74,9 @@ BuildRequires: libquadmath-devel libquadmath-static
|
|||||||
BuildRequires: python3-numpy
|
BuildRequires: python3-numpy
|
||||||
# optional library for regex
|
# optional library for regex
|
||||||
BuildRequires: libicu-devel
|
BuildRequires: libicu-devel
|
||||||
|
%ifarch riscv64
|
||||||
|
BuildRequires: libatomic
|
||||||
|
%endif
|
||||||
|
|
||||||
Obsoletes: boost-signals < 1.69.0
|
Obsoletes: boost-signals < 1.69.0
|
||||||
|
|
||||||
@ -301,7 +304,12 @@ cd status
|
|||||||
../b2 %{?_smp_mflags} %{opt_feature} cxxflags="$RPM_OPT_FLAGS" %{boost_macros} \
|
../b2 %{?_smp_mflags} %{opt_feature} cxxflags="$RPM_OPT_FLAGS" %{boost_macros} \
|
||||||
--include-tests=algorithm,graph,intrusive,dynamic_bitset,property_map,crc,lexical_cast,range \
|
--include-tests=algorithm,graph,intrusive,dynamic_bitset,property_map,crc,lexical_cast,range \
|
||||||
--exclude-tests=mpi,graph_parallel
|
--exclude-tests=mpi,graph_parallel
|
||||||
../b2 %{?_smp_mflags} %{opt_feature} cxxflags="$RPM_OPT_FLAGS" %{boost_macros} \
|
%ifarch riscv64
|
||||||
|
LINKFLAGS='linkflags="-Wl,-latomic"'
|
||||||
|
%else
|
||||||
|
LINKFLAGS=
|
||||||
|
%endif
|
||||||
|
../b2 %{?_smp_mflags} %{opt_feature} cxxflags="$RPM_OPT_FLAGS" $LINKFLAGS %{boost_macros} \
|
||||||
--include-tests=bimap,circular_buffer,container,heap,icl,lockfree,logic,multi_array,multi_index,poly_collection,property_tree,ptr_container,sort \
|
--include-tests=bimap,circular_buffer,container,heap,icl,lockfree,logic,multi_array,multi_index,poly_collection,property_tree,ptr_container,sort \
|
||||||
--exclude-tests=container_hash
|
--exclude-tests=container_hash
|
||||||
|
|
||||||
@ -453,6 +461,9 @@ find libs -name example -exec cp {} boost-example --parents -r \;
|
|||||||
%{_libdir}/*.a
|
%{_libdir}/*.a
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Mon Aug 14 2023 laokz <zhangkai@iscas.ac.cn> - 1.78.0-17
|
||||||
|
- add -latomic flag to lockfree tests for riscv64
|
||||||
|
|
||||||
* Thu Aug 10 2023 herengui <herengui@kylinsec.com.cn> - 1.78.0-16
|
* Thu Aug 10 2023 herengui <herengui@kylinsec.com.cn> - 1.78.0-16
|
||||||
- add loongarch64 patch
|
- add loongarch64 patch
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user