From d104a975a749d3ac822ca1cc277c5a903047fdae Mon Sep 17 00:00:00 2001 From: Brad Bell Date: Sat, 18 Jan 2025 04:15:34 -0700 Subject: [PATCH] Fix two bugs (should not be necessary one version > 20250000.0). --- cppad.spec | 36 ++++++++++++++++++++++++++++++++++++ 1 file changed, 36 insertions(+) diff --git a/cppad.spec b/cppad.spec index b33f4aa..be19055 100644 --- a/cppad.spec +++ b/cppad.spec @@ -136,6 +136,38 @@ mv CppAD-%{version}/build/html html mv CppAD-%{version}/COPYING COPYING mv CppAD-%{version}/uw_copy_040507.html uw_copy_040507.html # +# fix bug +# should not be needed once version > 20250000.0 +cat << EOF > temp.sed +/setup_random(size_t& not_used)/! b end +: loop +N +/\\n *}/! b loop +s|^|# if ! CPPAD_IS_SAME_UNSIGNED_INT_SIZE_T\\n| +s|$|\\n# endif| +# +: end +EOF +sed -i.bak CppAD-%{version}/include/cppad/local/play/player.hpp -f temp.sed +# +# fix bug +# should not be needed once version > 20250000.0 +cat << EOF > temp.sed +/CHECK_CXX_SOURCE_COMPILES/! b end +s|^| SET(CMAKE_REQUIRED_DEFINITIONS "" )\\ + SET(CMAKE_REQUIRED_INCLUDES "" )\\ + SET(CMAKE_REQUIRED_LIBRARIES "" )\\ + IF( cppad_cxx_flags )\\ + SET(CMAKE_REQUIRED_FLAGS "\${cppad_cxx_flags} \${CMAKE_CXX_FLAGS}" )\\ + ELSE( cppad_cxx_flags )\\ + SET(CMAKE_REQUIRED_FLAGS "" )\\ + ENDIF( cppad_cxx_flags )\\ +| +# +: end +EOF +sed -i.bak CppAD-%{version}/cmake/compile_source_test.cmake -f temp.sed +# # ---------------------------------------------------------------------------- # cppad_lib: replace soversion number and ensure build type is release sed -i.bak CppAD-%{version}/cppad_lib/CMakeLists.txt \ @@ -280,6 +312,10 @@ make %{?_smp_mflags} check # This enables one to check that the necessary files are installed. # ---------------------------------------------------------------------------- %changelog +* Sat Jan 18 2025 Brad Bell - 20250000.0-1 +- This fixes two bugs and will not be necessary +- once the upstream source advances to 20250000.1. + * Thu Jan 16 2025 Fedora Release Engineering - 20250000.0-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_42_Mass_Rebuild