Hello community, here is the log from the commit of package gnuradio for openSUSE:Factory checked in at 2017-05-24 16:50:34 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/gnuradio (Old) and /work/SRC/openSUSE:Factory/.gnuradio.new (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "gnuradio" Wed May 24 16:50:34 2017 rev:23 rq:497746 version:3.7.11 Changes: -------- --- /work/SRC/openSUSE:Factory/gnuradio/gnuradio.changes 2017-03-28 15:24:34.237610642 +0200 +++ /work/SRC/openSUSE:Factory/.gnuradio.new/gnuradio.changes 2017-05-24 16:51:16.730855275 +0200 @@ -1,0 +2,7 @@ +Mon May 22 20:27:27 UTC 2017 - [email protected] + +- Add patches to fix builds on Factory + + 0001-gr-fec-switch-possible-C-11-code-from-constexpr-to-j.patch + + CMake-set-C++-standard-to-c++11-and-C-standard-to-C99.diff + +------------------------------------------------------------------- New: ---- 0001-gr-fec-switch-possible-C-11-code-from-constexpr-to-j.patch CMake-set-C++-standard-to-c++11-and-C-standard-to-C99.diff ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ gnuradio.spec ++++++ --- /var/tmp/diff_new_pack.upAFIw/_old 2017-05-24 16:51:17.270779271 +0200 +++ /var/tmp/diff_new_pack.upAFIw/_new 2017-05-24 16:51:17.274778708 +0200 @@ -29,6 +29,8 @@ Source1: %{name}-rpmlintrc # http://www.nathanwest.us/grc_to_37.sh Source2: grc_to_37.sh +Patch0: CMake-set-C++-standard-to-c++11-and-C-standard-to-C99.diff +Patch1: 0001-gr-fec-switch-possible-C-11-code-from-constexpr-to-j.patch BuildRequires: alsa-devel BuildRequires: boost-devel BuildRequires: cmake @@ -185,6 +187,11 @@ %prep %setup -q +# Workaround for Tumbleweed until GNURadio 3.8 is released +%if 0%{?suse_version} > 1320 +%patch0 -p1 +%patch1 -p1 +%endif # remove buildtime from documentation sed -i 's|^HTML_TIMESTAMP = YES|HTML_TIMESTAMP = NO|' docs/doxygen/Doxyfile.in sed -i 's|^HTML_TIMESTAMP = YES|HTML_TIMESTAMP = NO|' docs/doxygen/Doxyfile.swig_doc.in ++++++ 0001-gr-fec-switch-possible-C-11-code-from-constexpr-to-j.patch ++++++ >From cee483f7851f13e797b75d08934b5d779aca5d49 Mon Sep 17 00:00:00 2001 From: Michael Dickens <[email protected]> Date: Fri, 10 Mar 2017 12:35:05 -0500 Subject: [PATCH] gr-fec: switch possible C++11 code from 'constexpr' to just 'const'. --- gr-fec/include/gnuradio/fec/polar_decoder_common.h | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/gr-fec/include/gnuradio/fec/polar_decoder_common.h b/gr-fec/include/gnuradio/fec/polar_decoder_common.h index 13b25ea19..c160f4b87 100644 --- a/gr-fec/include/gnuradio/fec/polar_decoder_common.h +++ b/gr-fec/include/gnuradio/fec/polar_decoder_common.h @@ -28,10 +28,6 @@ #include <gnuradio/fec/generic_decoder.h> #include <gnuradio/fec/polar_common.h> -#ifndef BOOST_CONSTEXPR_OR_CONST -#define BOOST_CONSTEXPR_OR_CONST const -#endif - namespace gr { namespace fec { namespace code { @@ -68,7 +64,7 @@ namespace gr { bool set_frame_size(unsigned int frame_size){return false;}; private: - static BOOST_CONSTEXPR_OR_CONST float D_LLR_FACTOR; + static const float D_LLR_FACTOR; unsigned int d_frozen_bit_counter; protected: -- 2.12.0 ++++++ CMake-set-C++-standard-to-c++11-and-C-standard-to-C99.diff ++++++ diff --git a/CMakeLists.txt b/CMakeLists.txt index 0ac65fe..0d8b63f 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -56,31 +56,33 @@ IF (NOT MSVC) SET(CMAKE_C_FLAGS_DEBUG "${CMAKE_C_FLAGS_DEBUG} -O2") ENDIF() -# Set C/C++ standard for all targets -# NOTE: Starting with cmake v3.1 this should be used: -# set(CMAKE_C_STANDARD 90) -# set(CMAKE_CXX_STANDARD 98) - -IF(CMAKE_CXX_COMPILER_ID STREQUAL "GNU") - SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++98") -ELSEIF(CMAKE_CXX_COMPILER_ID STREQUAL "Clang") - SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++98") -ELSEIF(CMAKE_CXX_COMPILER_ID STREQUAL "MSVC") - SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++98") -ELSE() - message(warning "C++ standard could not be set because compiler is not GNU, Clang or MSVC.") -ENDIF() +# Configure C++ and C standards +IF(CMAKE_VERSION VERSION_LESS "3.1") + IF(CMAKE_CXX_COMPILER_ID STREQUAL "GNU") + SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11") + ELSEIF(CMAKE_CXX_COMPILER_ID STREQUAL "Clang") + SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11") + ELSEIF(CMAKE_CXX_COMPILER_ID STREQUAL "MSVC") + SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11") + ELSE() + MESSAGE(warning "C++ standard could not be set because compiler is not GNU, Clang or MSVC.") + ENDIF() -IF(CMAKE_C_COMPILER_ID STREQUAL "GNU") - SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -std=gnu99") -ELSEIF(CMAKE_C_COMPILER_ID STREQUAL "Clang") - SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -std=gnu99") -ELSEIF(CMAKE_C_COMPILER_ID STREQUAL "MSVC") - SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -std=c11") + IF(CMAKE_C_COMPILER_ID STREQUAL "GNU") + SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -std=gnu99") + ELSEIF(CMAKE_C_COMPILER_ID STREQUAL "Clang") + SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -std=gnu99") + ELSEIF(CMAKE_C_COMPILER_ID STREQUAL "MSVC") + SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -std=c11") + ELSE() + MESSAGE(warning "C standard could not be set because compiler is not GNU, Clang or MSVC.") + ENDIF() ELSE() - message(warning "C standard could not be set because compiler is not GNU, Clang or MSVC.") + SET(CMAKE_C_STANDARD 99) + SET(CMAKE_CXX_STANDARD 11) ENDIF() + # Set cmake policies. # This will suppress developer warnings during the cmake process that can occur # if a newer cmake version than the minimum is used.
