Pass -fno-strict-aliasing to cm_sha2.c
This commit is contained in:
parent
6a3c645d91
commit
2da4c96178
1
.gitignore
vendored
1
.gitignore
vendored
@ -8,3 +8,4 @@
|
||||
/cmake-2.8.11.tar.gz
|
||||
/cmake-2.8.11.1.tar.gz
|
||||
/cmake-2.8.11.2.tar.gz
|
||||
/cmake-*/
|
||||
|
19
cmake-strict_aliasing.patch
Normal file
19
cmake-strict_aliasing.patch
Normal file
@ -0,0 +1,19 @@
|
||||
diff -up cmake-2.8.11/Source/CMakeLists.txt\~ cmake-2.8.11/Source/CMakeLists.txt
|
||||
--- cmake-2.8.11/Source/CMakeLists.txt~ 2013-05-15 19:38:13.000000000 +0200
|
||||
+++ cmake-2.8.11/Source/CMakeLists.txt 2013-07-25 16:35:01.200389140 +0200
|
||||
@@ -308,6 +308,13 @@ if(APPLE)
|
||||
cmLocalXCodeGenerator.h)
|
||||
endif()
|
||||
|
||||
+# GCC shows strict aliasing warnings with cm_sha2.c. Turn off the
|
||||
+# corresponding optimizations.
|
||||
+if(CMAKE_COMPILER_IS_GNUCXX OR CMAKE_COMPILER_IS_GNUCC)
|
||||
+ set_source_files_properties(cm_sha2.c PROPERTIES
|
||||
+ COMPILE_FLAGS "-fno-strict-aliasing")
|
||||
+endif()
|
||||
+
|
||||
|
||||
if (WIN32)
|
||||
set(SRCS ${SRCS}
|
||||
|
||||
Diff finished. Thu Jul 25 16:35:18 2013
|
@ -13,7 +13,7 @@
|
||||
|
||||
Name: cmake
|
||||
Version: 2.8.11.2
|
||||
Release: 1%{?dist}
|
||||
Release: 2%{?dist}
|
||||
Summary: Cross-platform make system
|
||||
|
||||
Group: Development/Tools
|
||||
@ -43,6 +43,8 @@ Patch3: cmake-FindPostgreSQL.patch
|
||||
Patch4: cmake-2.8.11-rc1-IM_pkgconfig_hints.patch
|
||||
# Add FindLua52.cmake
|
||||
Patch5: cmake-2.8.11-rc4-lua-5.2.patch
|
||||
# Add -fno-strict-aliasing when compiling cm_sha2.c
|
||||
Patch6: cmake-strict_aliasing.patch
|
||||
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
|
||||
|
||||
BuildRequires: gcc-gfortran
|
||||
@ -97,6 +99,7 @@ The %{name}-gui package contains the Qt based GUI for CMake.
|
||||
%patch3 -p1
|
||||
%patch4 -p1
|
||||
%patch5 -p1
|
||||
%patch6 -p1
|
||||
|
||||
|
||||
%build
|
||||
@ -193,6 +196,10 @@ update-mime-database %{_datadir}/mime &> /dev/null || :
|
||||
|
||||
|
||||
%changelog
|
||||
* Thu Jul 25 2013 Petr Machata <pmachata@redhat.com> - 2.8.11.2-2
|
||||
- Pass -fno-strict-aliasing to cm_sha2.c to avoid strict aliasing
|
||||
problems that GCC warns about.
|
||||
|
||||
* Tue Jul 9 2013 Orion Poplawski <orion@cora.nwra.com> - 2.8.11.2-1
|
||||
- Update to 2.8.11.2 release
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user