mirror of
https://github.com/badaix/snapcast.git
synced 2025-04-28 17:57:05 +02:00
Iclude boost as system headers to suppress warnings
This commit is contained in:
parent
06f1c7d32f
commit
0b1b1e38bb
7 changed files with 24 additions and 71 deletions
|
@ -11,8 +11,9 @@ set(CLIENT_SOURCES
|
|||
|
||||
set(CLIENT_LIBRARIES ${CMAKE_THREAD_LIBS_INIT} ${ATOMIC_LIBRARY} common)
|
||||
|
||||
set(CLIENT_INCLUDE ${Boost_INCLUDE_DIR} ${CMAKE_SOURCE_DIR}/client
|
||||
${CMAKE_SOURCE_DIR})
|
||||
include_directories(${CMAKE_SOURCE_DIR} ${CMAKE_SOURCE_DIR}/client)
|
||||
|
||||
include_directories(SYSTEM ${Boost_INCLUDE_DIR})
|
||||
|
||||
if(MACOSX)
|
||||
# Bonjour
|
||||
|
@ -44,20 +45,20 @@ elseif(NOT ANDROID)
|
|||
if(AVAHI_FOUND)
|
||||
list(APPEND CLIENT_SOURCES browseZeroConf/browse_avahi.cpp)
|
||||
list(APPEND CLIENT_LIBRARIES ${AVAHI_LIBRARIES})
|
||||
list(APPEND CLIENT_INCLUDE ${AVAHI_INCLUDE_DIRS})
|
||||
include_directories(${AVAHI_INCLUDE_DIRS})
|
||||
endif(AVAHI_FOUND)
|
||||
|
||||
# ALSA
|
||||
if(ALSA_FOUND)
|
||||
list(APPEND CLIENT_SOURCES player/alsa_player.cpp)
|
||||
list(APPEND CLIENT_LIBRARIES ${ALSA_LIBRARIES})
|
||||
list(APPEND CLIENT_INCLUDE ${ALSA_INCLUDE_DIRS})
|
||||
include_directories(${ALSA_INCLUDE_DIRS})
|
||||
endif(ALSA_FOUND)
|
||||
|
||||
if(PULSE_FOUND)
|
||||
list(APPEND CLIENT_SOURCES player/pulse_player.cpp)
|
||||
list(APPEND CLIENT_LIBRARIES ${PULSE_LIBRARIES})
|
||||
list(APPEND CLIENT_INCLUDE ${PULSE_INCLUDE_DIRS})
|
||||
include_directories(${PULSE_INCLUDE_DIRS})
|
||||
endif(PULSE_FOUND)
|
||||
endif(MACOSX)
|
||||
|
||||
|
@ -79,10 +80,10 @@ else()
|
|||
# Tremor (fixed-point) or libvorbis (floating-point)
|
||||
if(TREMOR_FOUND)
|
||||
list(APPEND CLIENT_LIBRARIES ${TREMOR_LIBRARIES})
|
||||
list(APPEND CLIENT_INCLUDE ${TREMOR_INCLUDE_DIRS})
|
||||
include_directories(${TREMOR_INCLUDE_DIRS})
|
||||
elseif(VORBIS_FOUND)
|
||||
list(APPEND CLIENT_LIBRARIES ${VORBIS_LIBRARIES})
|
||||
list(APPEND CLIENT_INCLUDE ${VORBIS_INCLUDE_DIRS})
|
||||
include_directories(${VORBIS_INCLUDE_DIRS})
|
||||
link_directories(${VORBIS_LIBRARY_DIRS})
|
||||
endif(TREMOR_FOUND)
|
||||
|
||||
|
@ -90,32 +91,31 @@ else()
|
|||
if(OGG_FOUND)
|
||||
list(APPEND CLIENT_SOURCES decoder/ogg_decoder.cpp)
|
||||
list(APPEND CLIENT_LIBRARIES ${OGG_LIBRARIES})
|
||||
list(APPEND CLIENT_INCLUDE ${OGG_INCLUDE_DIRS})
|
||||
include_directories(${OGG_INCLUDE_DIRS})
|
||||
link_directories(${OGG_LIBRARY_DIRS})
|
||||
endif(OGG_FOUND)
|
||||
|
||||
if(FLAC_FOUND)
|
||||
list(APPEND CLIENT_SOURCES decoder/flac_decoder.cpp)
|
||||
list(APPEND CLIENT_LIBRARIES ${FLAC_LIBRARIES})
|
||||
list(APPEND CLIENT_INCLUDE ${FLAC_INCLUDE_DIRS})
|
||||
include_directories(${FLAC_INCLUDE_DIRS})
|
||||
link_directories(${FLAC_LIBRARY_DIRS})
|
||||
endif(FLAC_FOUND)
|
||||
|
||||
if(OPUS_FOUND)
|
||||
list(APPEND CLIENT_SOURCES decoder/opus_decoder.cpp)
|
||||
list(APPEND CLIENT_LIBRARIES ${OPUS_LIBRARIES})
|
||||
list(APPEND CLIENT_INCLUDE ${OPUS_INCLUDE_DIRS})
|
||||
include_directories(${OPUS_INCLUDE_DIRS})
|
||||
link_directories(${OPUS_LIBRARY_DIRS})
|
||||
endif(OPUS_FOUND)
|
||||
|
||||
if(SOXR_FOUND)
|
||||
list(APPEND CLIENT_LIBRARIES ${SOXR_LIBRARIES})
|
||||
list(APPEND CLIENT_INCLUDE ${SOXR_INCLUDE_DIRS})
|
||||
include_directories(${SOXR_INCLUDE_DIRS})
|
||||
link_directories(${SOXR_LIBRARY_DIRS})
|
||||
endif(SOXR_FOUND)
|
||||
endif()
|
||||
|
||||
include_directories(${CLIENT_INCLUDE})
|
||||
if(ANDROID)
|
||||
add_executable(libsnapclient.so ${CLIENT_SOURCES})
|
||||
target_link_libraries(libsnapclient.so ${CLIENT_LIBRARIES} log OpenSLES)
|
||||
|
|
|
@ -27,18 +27,10 @@
|
|||
|
||||
// 3rd party headers
|
||||
#ifdef SUPPORTS_VOLUME_SCRIPT
|
||||
#pragma GCC diagnostic push
|
||||
#pragma GCC diagnostic ignored "-Wpragmas"
|
||||
#pragma GCC diagnostic ignored "-Wunused-result"
|
||||
#pragma GCC diagnostic ignored "-Wunused-parameter"
|
||||
#pragma GCC diagnostic ignored "-Wmissing-braces"
|
||||
#pragma GCC diagnostic ignored "-Wnarrowing"
|
||||
#pragma GCC diagnostic ignored "-Wc++11-narrowing"
|
||||
#include <boost/process/args.hpp>
|
||||
#include <boost/process/async.hpp>
|
||||
#include <boost/process/child.hpp>
|
||||
#include <boost/process/exe.hpp>
|
||||
#pragma GCC diagnostic pop
|
||||
#endif
|
||||
|
||||
// standard headers
|
||||
|
|
|
@ -33,9 +33,11 @@ set(SERVER_SOURCES
|
|||
|
||||
set(SERVER_LIBRARIES ${CMAKE_THREAD_LIBS_INIT} ${ATOMIC_LIBRARY} common)
|
||||
|
||||
set(SERVER_INCLUDE ${Boost_INCLUDE_DIR} ${CMAKE_SOURCE_DIR}/server
|
||||
${CMAKE_SOURCE_DIR})
|
||||
include_directories(${CMAKE_SOURCE_DIR} ${CMAKE_SOURCE_DIR}/server)
|
||||
|
||||
include_directories(SYSTEM ${Boost_INCLUDE_DIR})
|
||||
|
||||
|
||||
if(ANDROID)
|
||||
find_package(vorbis REQUIRED CONFIG)
|
||||
list(APPEND SERVER_LIBRARIES boost::boost)
|
||||
|
@ -52,7 +54,7 @@ else()
|
|||
if(AVAHI_FOUND)
|
||||
list(APPEND SERVER_SOURCES publishZeroConf/publish_avahi.cpp)
|
||||
list(APPEND SERVER_LIBRARIES ${AVAHI_LIBRARIES})
|
||||
list(APPEND SERVER_INCLUDE ${AVAHI_INCLUDE_DIRS})
|
||||
include_directories(${AVAHI_INCLUDE_DIRS})
|
||||
endif(AVAHI_FOUND)
|
||||
|
||||
if(BONJOUR_FOUND)
|
||||
|
@ -67,7 +69,7 @@ else()
|
|||
list(APPEND SERVER_SOURCES encoder/ogg_encoder.cpp)
|
||||
list(APPEND SERVER_LIBRARIES ${VORBIS_LIBRARIES} ${VORBISENC_LIBRARIES}
|
||||
${OGG_LIBRARIES})
|
||||
list(APPEND SERVER_INCLUDE ${OGG_INCLUDE_DIRS} ${VORBIS_INCLUDE_DIRS}
|
||||
include_directories(${OGG_INCLUDE_DIRS} ${VORBIS_INCLUDE_DIRS}
|
||||
${VORBISENC_INCLUDE_DIRS})
|
||||
link_directories(${VORBIS_LIBRARY_DIRS})
|
||||
link_directories(${VORBISENC_LIBRARY_DIRS})
|
||||
|
@ -80,38 +82,38 @@ else()
|
|||
if(FLAC_FOUND)
|
||||
list(APPEND SERVER_SOURCES encoder/flac_encoder.cpp)
|
||||
list(APPEND SERVER_LIBRARIES ${FLAC_LIBRARIES})
|
||||
list(APPEND SERVER_INCLUDE ${FLAC_INCLUDE_DIRS})
|
||||
include_directories(${FLAC_INCLUDE_DIRS})
|
||||
link_directories(${FLAC_LIBRARY_DIRS})
|
||||
endif(FLAC_FOUND)
|
||||
|
||||
if(OPUS_FOUND)
|
||||
list(APPEND SERVER_SOURCES encoder/opus_encoder.cpp)
|
||||
list(APPEND SERVER_LIBRARIES ${OPUS_LIBRARIES})
|
||||
list(APPEND SERVER_INCLUDE ${OPUS_INCLUDE_DIRS})
|
||||
include_directories(${OPUS_INCLUDE_DIRS})
|
||||
link_directories(${OPUS_LIBRARY_DIRS})
|
||||
endif(OPUS_FOUND)
|
||||
|
||||
if(ALSA_FOUND)
|
||||
list(APPEND SERVER_SOURCES streamreader/alsa_stream.cpp)
|
||||
list(APPEND SERVER_LIBRARIES ${ALSA_LIBRARIES})
|
||||
list(APPEND SERVER_INCLUDE ${ALSA_INCLUDE_DIRS})
|
||||
include_directories(${ALSA_INCLUDE_DIRS})
|
||||
endif(ALSA_FOUND)
|
||||
|
||||
if(JACK_FOUND)
|
||||
list(APPEND SERVER_SOURCES streamreader/jack_stream.cpp)
|
||||
list(APPEND SERVER_LIBRARIES ${JACK_LIBRARIES})
|
||||
list(APPEND SERVER_INCLUDE ${JACK_INCLUDE_DIRS})
|
||||
include_directories(${JACK_INCLUDE_DIRS})
|
||||
endif(JACK_FOUND)
|
||||
|
||||
if(EXPAT_FOUND)
|
||||
list(APPEND SERVER_LIBRARIES ${EXPAT_LIBRARIES})
|
||||
list(APPEND SERVER_INCLUDE ${EXPAT_INCLUDE_DIRS})
|
||||
include_directories(${EXPAT_INCLUDE_DIRS})
|
||||
link_directories(${EXPAT_LIBRARY_DIRS})
|
||||
endif(EXPAT_FOUND)
|
||||
|
||||
if(SOXR_FOUND)
|
||||
list(APPEND SERVER_LIBRARIES ${SOXR_LIBRARIES})
|
||||
list(APPEND SERVER_INCLUDE ${SOXR_INCLUDE_DIRS})
|
||||
include_directories(${SOXR_INCLUDE_DIRS})
|
||||
link_directories(${SOXR_LIBRARY_DIRS})
|
||||
endif(SOXR_FOUND)
|
||||
endif()
|
||||
|
@ -119,7 +121,6 @@ endif()
|
|||
# list(APPEND SERVER_LIBRARIES Boost::boost)
|
||||
list(APPEND SERVER_LIBRARIES OpenSSL::Crypto OpenSSL::SSL)
|
||||
|
||||
include_directories(${SERVER_INCLUDE})
|
||||
if(ANDROID)
|
||||
add_executable(libsnapserver.so ${SERVER_SOURCES})
|
||||
target_link_libraries(libsnapserver.so ${SERVER_LIBRARIES} log)
|
||||
|
|
|
@ -28,13 +28,7 @@
|
|||
#include <boost/asio/ssl.hpp>
|
||||
#include <boost/beast/core.hpp>
|
||||
#include <boost/beast/ssl.hpp>
|
||||
|
||||
#pragma GCC diagnostic push
|
||||
#if defined(__GNUC__) && !defined(__clang__)
|
||||
#pragma GCC diagnostic ignored "-Wmaybe-uninitialized"
|
||||
#endif
|
||||
#include <boost/beast/websocket.hpp>
|
||||
#pragma GCC diagnostic pop
|
||||
|
||||
// standard headers
|
||||
#include <deque>
|
||||
|
|
|
@ -23,23 +23,8 @@
|
|||
#include "control_session.hpp"
|
||||
|
||||
// 3rd party headers
|
||||
#pragma GCC diagnostic push
|
||||
#if defined(__GNUC__) && !defined(__clang__)
|
||||
#pragma GCC diagnostic ignored "-Wmaybe-uninitialized"
|
||||
#endif
|
||||
#include <boost/asio/strand.hpp>
|
||||
#pragma GCC diagnostic pop
|
||||
|
||||
#pragma GCC diagnostic push
|
||||
#if defined(__clang__)
|
||||
#pragma GCC diagnostic ignored "-Wunknown-warning-option"
|
||||
#pragma GCC diagnostic ignored "-Wdeprecated-copy-with-user-provided-copy"
|
||||
#pragma GCC diagnostic ignored "-Wdeprecated-copy"
|
||||
#elif defined(__GNUC__)
|
||||
#pragma GCC diagnostic ignored "-Wmaybe-uninitialized"
|
||||
#endif
|
||||
#include <boost/beast/core.hpp>
|
||||
#pragma GCC diagnostic pop
|
||||
#include <boost/beast/ssl.hpp>
|
||||
#include <boost/beast/websocket.hpp>
|
||||
|
||||
|
|
|
@ -24,14 +24,7 @@
|
|||
|
||||
// 3rd party headers
|
||||
#include <boost/asio/strand.hpp>
|
||||
#pragma GCC diagnostic push
|
||||
#ifdef __clang__
|
||||
#pragma GCC diagnostic ignored "-Wunknown-warning-option"
|
||||
#pragma GCC diagnostic ignored "-Wdeprecated-copy-with-user-provided-copy"
|
||||
#pragma GCC diagnostic ignored "-Wdeprecated-copy"
|
||||
#endif
|
||||
#include <boost/beast/core.hpp>
|
||||
#pragma GCC diagnostic pop
|
||||
#include <boost/beast/ssl.hpp>
|
||||
#include <boost/beast/websocket.hpp>
|
||||
|
||||
|
|
|
@ -24,19 +24,7 @@
|
|||
#include "server_settings.hpp"
|
||||
|
||||
// 3rd party headers
|
||||
#pragma GCC diagnostic push
|
||||
#pragma GCC diagnostic ignored "-Wpragmas"
|
||||
#pragma GCC diagnostic ignored "-Wunused-result"
|
||||
#pragma GCC diagnostic ignored "-Wunused-parameter"
|
||||
#pragma GCC diagnostic ignored "-Wmissing-braces"
|
||||
#pragma GCC diagnostic ignored "-Wnarrowing"
|
||||
#pragma GCC diagnostic ignored "-Wc++11-narrowing"
|
||||
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
|
||||
#if !defined(__clang__)
|
||||
#pragma GCC diagnostic ignored "-Wmaybe-uninitialized"
|
||||
#endif
|
||||
#include <boost/process.hpp>
|
||||
#pragma GCC diagnostic pop
|
||||
#include <boost/asio/any_io_executor.hpp>
|
||||
|
||||
// standard headers
|
||||
|
|
Loading…
Add table
Reference in a new issue