From f7ea7061dd30fdd0319b7176a583d7873a2926e6 Mon Sep 17 00:00:00 2001 From: Filipe Coelho Date: Fri, 1 Feb 2019 18:11:47 +0100 Subject: [PATCH] Improve travis CI setup (#823) Signed-off-by: falkTX --- .travis.yml | 44 +++++-- .travis/before_install.sh | 11 +- .travis/install.sh | 114 +++++++++++++------ .travis/script-linux-strict.sh | 33 ++++++ .travis/script-linux.sh | 2 +- source/Makefile.mk | 2 + source/backend/engine/CarlaEngineOscSend.cpp | 27 ++++- source/backend/plugin/CarlaPluginLV2.cpp | 10 +- source/bridges-ui/CarlaBridgeToolkitQt.cpp | 25 ++-- source/bridges-ui/Makefile | 3 + source/discovery/carla-discovery.cpp | 48 ++++---- source/libjack/Makefile | 1 + source/utils/CarlaOscUtils.hpp | 6 +- 13 files changed, 230 insertions(+), 96 deletions(-) mode change 100755 => 100644 .travis/before_install.sh create mode 100755 .travis/script-linux-strict.sh diff --git a/.travis.yml b/.travis.yml index 873bf5bd2..5ab6f2da7 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,18 +1,46 @@ -os: - - linux +language: + - cpp sudo: required dist: trusty -languages: c++ -compiler: gcc +matrix: + include: + # linux with default, builds native and bridges + - os: linux + compiler: gcc + env: + - TARGET="linux" + + # linux with macOS cross-compilation + - os: linux + compiler: gcc + env: + - TARGET="macos" + + # linux with win32 cross-compilation + - os: linux + compiler: gcc + env: + - TARGET="win32" + + # linux with win64 cross-compilation + - os: linux + compiler: gcc + env: + - TARGET="win64" + + # linux with gcc 8, strict build + - os: linux + compiler: gcc + env: + - TARGET="linux-strict" before_install: - sh ${TRAVIS_BUILD_DIR}/.travis/before_install.sh + install: - sh ${TRAVIS_BUILD_DIR}/.travis/install.sh + script: - - sh ${TRAVIS_BUILD_DIR}/.travis/script-linux.sh - - sh ${TRAVIS_BUILD_DIR}/.travis/script-macos.sh - - sh ${TRAVIS_BUILD_DIR}/.travis/script-win32.sh - - sh ${TRAVIS_BUILD_DIR}/.travis/script-win64.sh + - sh ${TRAVIS_BUILD_DIR}/.travis/script-${TARGET}.sh diff --git a/.travis/before_install.sh b/.travis/before_install.sh old mode 100755 new mode 100644 index 73c1026a1..00c95cfbc --- a/.travis/before_install.sh +++ b/.travis/before_install.sh @@ -2,9 +2,14 @@ set -e -sudo add-apt-repository ppa:kxstudio-debian/kxstudio -y -sudo add-apt-repository ppa:kxstudio-debian/mingw -y -sudo add-apt-repository ppa:kxstudio-debian/toolchain -y +sudo add-apt-repository -y ppa:kxstudio-debian/kxstudio +sudo add-apt-repository -y ppa:kxstudio-debian/mingw +sudo add-apt-repository -y ppa:kxstudio-debian/toolchain + +if [ "${TARGET}" = "linux-strict" ]; then + sudo add-apt-repository -y ppa:ubuntu-toolchain-r/test +fi + sudo apt-get update -qq sudo apt-get install kxstudio-repos sudo apt-get update -qq diff --git a/.travis/install.sh b/.travis/install.sh index 7615b1d24..8382d3f6d 100755 --- a/.travis/install.sh +++ b/.travis/install.sh @@ -2,30 +2,83 @@ set -e -sudo apt-get install -y \ - g++-multilib \ - pkg-config \ - pyqt5-dev-tools \ - python3-pyqt5.qtsvg \ - python3-rdflib \ - libgtk2.0-dev \ - libgtk-3-dev \ - libqt4-dev \ - qtbase5-dev \ - libasound2-dev \ - libpulse-dev \ - libmagic-dev \ - libgl1-mesa-dev \ - libx11-dev \ - libx11-6:i386 \ - liblo-static \ - fluidsynth-static \ - apple-x86-setup \ - mingw32-x-gcc \ - mingw32-x-pkgconfig \ - mingw64-x-gcc \ - mingw64-x-pkgconfig \ - wine-rt-dev +if [ "${TARGET}" = "linux" ]; then + sudo apt-get install -y \ + g++-multilib \ + pkg-config \ + pyqt5-dev-tools \ + python3-pyqt5.qtsvg \ + python3-rdflib \ + libgtk2.0-dev \ + libgtk-3-dev \ + libqt4-dev \ + qtbase5-dev \ + libasound2-dev \ + libpulse-dev \ + libmagic-dev \ + libgl1-mesa-dev \ + libx11-dev \ + libx11-6:i386 \ + liblo-static \ + fluidsynth-static \ + mingw32-x-gcc \ + mingw32-x-pkgconfig \ + mingw64-x-gcc \ + mingw64-x-pkgconfig \ + wine-rt-dev + + # Fix for 32bit bridge link + sudo ln -s /usr/lib/i386-linux-gnu/libX11.so.6 /usr/lib/i386-linux-gnu/libX11.so + +elif [ "${TARGET}" = "linux-strict" ]; then + sudo apt-get install -y \ + g++-8 \ + pkg-config \ + pyqt5-dev-tools \ + python3-pyqt5.qtsvg \ + python3-rdflib \ + libgtk2.0-dev \ + libgtk-3-dev \ + libqt4-dev \ + qtbase5-dev \ + libasound2-dev \ + libpulse-dev \ + libmagic-dev \ + libgl1-mesa-dev \ + libx11-dev \ + libx11-6:i386 \ + liblo-static \ + fluidsynth-static + +elif [ "${TARGET}" = "macos" ]; then + sudo apt-get install -y \ + pkg-config \ + apple-x86-setup + +# mkdir /tmp/osx-macports-pkgs +# cd /tmp/osx-macports-pkgs +# wget https://launchpad.net/~kxstudio-team/+archive/ubuntu/builds/+files/apple-macports-flac_1.2.1-1_all.deb +# wget https://launchpad.net/~kxstudio-team/+archive/ubuntu/builds/+files/apple-macports-libiconv_1.14-0_all.deb +# wget https://launchpad.net/~kxstudio-team/+archive/ubuntu/builds/+files/apple-macports-liblo_0.26-1_all.deb +# wget https://launchpad.net/~kxstudio-team/+archive/ubuntu/builds/+files/apple-macports-libogg_1.3.0-1_all.deb +# wget https://launchpad.net/~kxstudio-team/+archive/ubuntu/builds/+files/apple-macports-libsndfile_1.0.25-0_all.deb +# wget https://launchpad.net/~kxstudio-team/+archive/ubuntu/builds/+files/apple-macports-libvorbis_1.3.3-0_all.deb +# cd ~ +# rm -r /tmp/osx-macports-pkgs + +elif [ "${TARGET}" = "win32" ]; then + sudo apt-get install -y \ + mingw32-x-gcc \ + mingw32-x-pkgconfig + +elif [ "${TARGET}" = "win64" ]; then + sudo apt-get install -y \ + mingw32-x-gcc \ + mingw32-x-pkgconfig \ + mingw64-x-gcc \ + mingw64-x-pkgconfig + +fi # mingw32-x-fluidsynth # mingw32-x-fftw @@ -37,16 +90,3 @@ sudo apt-get install -y \ # mingw64-x-liblo # mingw64-x-mxml # mingw64-x-zlib - -mkdir /tmp/osx-macports-pkgs -cd /tmp/osx-macports-pkgs -wget https://launchpad.net/~kxstudio-team/+archive/ubuntu/builds/+files/apple-macports-flac_1.2.1-1_all.deb -wget https://launchpad.net/~kxstudio-team/+archive/ubuntu/builds/+files/apple-macports-libiconv_1.14-0_all.deb -wget https://launchpad.net/~kxstudio-team/+archive/ubuntu/builds/+files/apple-macports-liblo_0.26-1_all.deb -wget https://launchpad.net/~kxstudio-team/+archive/ubuntu/builds/+files/apple-macports-libogg_1.3.0-1_all.deb -wget https://launchpad.net/~kxstudio-team/+archive/ubuntu/builds/+files/apple-macports-libsndfile_1.0.25-0_all.deb -wget https://launchpad.net/~kxstudio-team/+archive/ubuntu/builds/+files/apple-macports-libvorbis_1.3.3-0_all.deb -cd ~ -rm -r /tmp/osx-macports-pkgs - -sudo ln -s /usr/lib/i386-linux-gnu/libX11.so.6 /usr/lib/i386-linux-gnu/libX11.so diff --git a/.travis/script-linux-strict.sh b/.travis/script-linux-strict.sh new file mode 100755 index 000000000..61b341c3f --- /dev/null +++ b/.travis/script-linux-strict.sh @@ -0,0 +1,33 @@ +#!/bin/bash + +set -e + +# Preparation +export CC=gcc-8 +export CXX=g++-8 +export PKG_CONFIG_PATH=/opt/kxstudio/lib/pkgconfig:${PKG_CONFIG_PATH} +unset CFLAGS +unset CXXFLAGS +unset LDFLAGS + +# Start clean +make distclean >/dev/null + +# Print available features +make features + +# Build things that we skip strict tests for +make -C source/modules/audio_decoder +make -C source/modules/dgl +make -C source/modules/hylia +make -C source/modules/rtaudio +make -C source/modules/rtmidi +make -C source/modules/sfzero +make -C source/modules/water +make -C source/theme all qt4 qt5 + +# FIXME +make -C source/libjack + +# Build native stuff +make TESTBUILD=true diff --git a/.travis/script-linux.sh b/.travis/script-linux.sh index 196d28297..8d9f81d24 100755 --- a/.travis/script-linux.sh +++ b/.travis/script-linux.sh @@ -3,7 +3,7 @@ set -e # Preparation -_FLAGS="-I/opt/kxstudio/include -Werror" +_FLAGS="-Werror" export CFLAGS="${_FLAGS}" export CXXFLAGS="${_FLAGS}" export LDFLAGS="-L/opt/kxstudio/lib" diff --git a/source/Makefile.mk b/source/Makefile.mk index 13707e91a..6c6e565b5 100644 --- a/source/Makefile.mk +++ b/source/Makefile.mk @@ -571,11 +571,13 @@ LINK := ln -sf # --------------------------------------------------------------------------------------------------------------------- ifneq ($(DEBUG),true) +ifneq ($(TESTBUILD),true) ifneq (,$(wildcard $(CWD)/native-plugins/external/Makefile.mk)) EXTERNAL_PLUGINS = true BASE_FLAGS += -DHAVE_EXTERNAL_PLUGINS include $(CWD)/native-plugins/external/Makefile.mk endif endif +endif # --------------------------------------------------------------------------------------------------------------------- diff --git a/source/backend/engine/CarlaEngineOscSend.cpp b/source/backend/engine/CarlaEngineOscSend.cpp index 2f8b616e6..0e5444156 100644 --- a/source/backend/engine/CarlaEngineOscSend.cpp +++ b/source/backend/engine/CarlaEngineOscSend.cpp @@ -209,7 +209,12 @@ void CarlaEngine::oscSend_control_set_parameter_ranges1(const uint pluginId, con char targetPath[std::strlen(pData->oscData->path)+24]; std::strcpy(targetPath, pData->oscData->path); std::strcat(targetPath, "/set_parameter_ranges1"); - try_lo_send(pData->oscData->target, targetPath, "iifff", static_cast(pluginId), static_cast(index), def, min, max); + try_lo_send(pData->oscData->target, targetPath, "iifff", + static_cast(pluginId), + static_cast(index), + static_cast(def), + static_cast(min), + static_cast(max)); } void CarlaEngine::oscSend_control_set_parameter_ranges2(const uint pluginId, const uint32_t index, const float step, const float stepSmall, const float stepLarge) const noexcept @@ -226,7 +231,12 @@ void CarlaEngine::oscSend_control_set_parameter_ranges2(const uint pluginId, con char targetPath[std::strlen(pData->oscData->path)+24]; std::strcpy(targetPath, pData->oscData->path); std::strcat(targetPath, "/set_parameter_ranges2"); - try_lo_send(pData->oscData->target, targetPath, "iifff", static_cast(pluginId), static_cast(index), step, stepSmall, stepLarge); + try_lo_send(pData->oscData->target, targetPath, "iifff", + static_cast(pluginId), + static_cast(index), + static_cast(step), + static_cast(stepSmall), + static_cast(stepLarge)); } void CarlaEngine::oscSend_control_set_parameter_midi_cc(const uint pluginId, const uint32_t index, const int16_t cc) const noexcept @@ -269,12 +279,16 @@ void CarlaEngine::oscSend_control_set_parameter_value(const uint pluginId, const CARLA_SAFE_ASSERT_RETURN(pluginId <= pData->curPluginCount,); CARLA_SAFE_ASSERT_RETURN(index < 50,); CARLA_SAFE_ASSERT_RETURN(index != PARAMETER_NULL,); - carla_debug("CarlaEngine::oscSend_control_set_parameter_value(%i, %i:%s, %f)", pluginId, index, (index < 0) ? InternalParameterIndex2Str(static_cast(index)) : "(none)", value); + carla_debug("CarlaEngine::oscSend_control_set_parameter_value(%i, %i:%s, %f)", pluginId, index, + (index < 0) ? InternalParameterIndex2Str(static_cast(index)) : "(none)", value); char targetPath[std::strlen(pData->oscData->path)+21]; std::strcpy(targetPath, pData->oscData->path); std::strcat(targetPath, "/set_parameter_value"); - try_lo_send(pData->oscData->target, targetPath, "iif", static_cast(pluginId), index, value); + try_lo_send(pData->oscData->target, targetPath, "iif", + static_cast(pluginId), + index, + static_cast(value)); } void CarlaEngine::oscSend_control_set_default_value(const uint pluginId, const uint32_t index, const float value) const noexcept @@ -289,7 +303,10 @@ void CarlaEngine::oscSend_control_set_default_value(const uint pluginId, const u char targetPath[std::strlen(pData->oscData->path)+19]; std::strcpy(targetPath, pData->oscData->path); std::strcat(targetPath, "/set_default_value"); - try_lo_send(pData->oscData->target, targetPath, "iif", static_cast(pluginId), static_cast(index), value); + try_lo_send(pData->oscData->target, targetPath, "iif", + static_cast(pluginId), + static_cast(index), + static_cast(value)); } void CarlaEngine::oscSend_control_set_current_program(const uint pluginId, const int32_t index) const noexcept diff --git a/source/backend/plugin/CarlaPluginLV2.cpp b/source/backend/plugin/CarlaPluginLV2.cpp index d05b4f5d0..7cc62501a 100644 --- a/source/backend/plugin/CarlaPluginLV2.cpp +++ b/source/backend/plugin/CarlaPluginLV2.cpp @@ -1015,7 +1015,7 @@ public: } else { - rindex -= fRdfDescriptor->PortCount; + rindex -= static_cast(fRdfDescriptor->PortCount); if (rindex < static_cast(fRdfDescriptor->ParameterCount)) { @@ -1198,7 +1198,7 @@ public: if (pData->param.data[parameterId].rindex >= static_cast(fRdfDescriptor->PortCount)) { - const uint32_t rparamId = pData->param.data[parameterId].rindex - fRdfDescriptor->PortCount; + const uint32_t rparamId = static_cast(pData->param.data[parameterId].rindex) - fRdfDescriptor->PortCount; CARLA_SAFE_ASSERT_UINT2_RETURN(rparamId < fRdfDescriptor->ParameterCount, rparamId, fRdfDescriptor->PortCount,); @@ -1218,10 +1218,10 @@ public: lv2_atom_forge_bool(&fAtomForge, fixedValue > 0.5f); break; case LV2_PARAMETER_INT: - lv2_atom_forge_int(&fAtomForge, fixedValue + 0.5f); + lv2_atom_forge_int(&fAtomForge, static_cast(fixedValue + 0.5f)); break; case LV2_PARAMETER_LONG: - lv2_atom_forge_long(&fAtomForge, fixedValue + 0.5f); + lv2_atom_forge_long(&fAtomForge, static_cast(fixedValue + 0.5f)); break; case LV2_PARAMETER_FLOAT: lv2_atom_forge_float(&fAtomForge, fixedValue); @@ -1391,7 +1391,7 @@ public: lv2_atom_forge_urid(&fAtomForge, getCustomURID(fFilePathURI)); lv2_atom_forge_key(&fAtomForge, kUridPatchValue); - lv2_atom_forge_path(&fAtomForge, path, std::strlen(path)); + lv2_atom_forge_path(&fAtomForge, path, static_cast(std::strlen(path))); lv2_atom_forge_pop(&fAtomForge, &forgeFrame); diff --git a/source/bridges-ui/CarlaBridgeToolkitQt.cpp b/source/bridges-ui/CarlaBridgeToolkitQt.cpp index 2e611c33c..971dc654b 100644 --- a/source/bridges-ui/CarlaBridgeToolkitQt.cpp +++ b/source/bridges-ui/CarlaBridgeToolkitQt.cpp @@ -256,17 +256,21 @@ private: #endif }; +// ------------------------------------------------------------------------- + +#if defined(__GNUC__) && (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 6)) +# pragma GCC diagnostic push +# pragma GCC diagnostic ignored "-Wzero-as-null-pointer-constant" +#endif + #if (QT_VERSION >= QT_VERSION_CHECK(5, 0, 0)) # include "CarlaBridgeToolkitQt5.moc" #else -# if defined(__GNUC__) && (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 6)) -# pragma GCC diagnostic push -# pragma GCC diagnostic ignored "-Wzero-as-null-pointer-constant" -# endif # include "CarlaBridgeToolkitQt4.moc" -# if defined(__GNUC__) && (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 6)) -# pragma GCC diagnostic pop -# endif +#endif + +#if defined(__GNUC__) && (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 6)) +# pragma GCC diagnostic pop #endif // ------------------------------------------------------------------------- @@ -282,12 +286,13 @@ CARLA_BRIDGE_UI_END_NAMESPACE // ------------------------------------------------------------------------- -#if QT_VERSION >= QT_VERSION_CHECK(5, 0, 0) -# include "resources.qt5.cpp" -#else // missing declaration int qInitResources(); int qCleanupResources(); + +#if QT_VERSION >= QT_VERSION_CHECK(5, 0, 0) +# include "resources.qt5.cpp" +#else # include "resources.qt4.cpp" #endif diff --git a/source/bridges-ui/Makefile b/source/bridges-ui/Makefile index d859cee84..db2a23460 100644 --- a/source/bridges-ui/Makefile +++ b/source/bridges-ui/Makefile @@ -56,8 +56,11 @@ endif ifeq ($(TESTBUILD),true) BUILD_GTK2_FLAGS += -isystem /usr/include/glib-2.0 +BUILD_GTK2_FLAGS += -isystem /usr/include/gtk-2.0 BUILD_GTK3_FLAGS += -isystem /usr/include/glib-2.0 +BUILD_GTK3_FLAGS += -isystem /usr/include/gtk-3.0 BUILD_QT4_FLAGS += -isystem /usr/include/qt4 +BUILD_QT5_FLAGS += -isystem /usr/include/qt5 BUILD_QT5_FLAGS += -isystem /usr/include/x86_64-linux-gnu/qt5 endif diff --git a/source/discovery/carla-discovery.cpp b/source/discovery/carla-discovery.cpp index 5f71b3b31..4dc7decc0 100644 --- a/source/discovery/carla-discovery.cpp +++ b/source/discovery/carla-discovery.cpp @@ -221,12 +221,12 @@ static void do_ladspa_check(lib_t& libHandle, const char* const filename, const } uint hints = 0x0; - int audioIns = 0; - int audioOuts = 0; - int audioTotal = 0; - int parametersIns = 0; - int parametersOuts = 0; - int parametersTotal = 0; + uint audioIns = 0; + uint audioOuts = 0; + uint audioTotal = 0; + uint parametersIns = 0; + uint parametersOuts = 0; + uint parametersTotal = 0; if (LADSPA_IS_HARD_RT_CAPABLE(descriptor->Properties)) hints |= PLUGIN_IS_RTSAFE; @@ -479,13 +479,13 @@ static void do_dssi_check(lib_t& libHandle, const char* const filename, const bo } uint hints = 0x0; - int audioIns = 0; - int audioOuts = 0; - int audioTotal = 0; - int midiIns = 0; - int parametersIns = 0; - int parametersOuts = 0; - int parametersTotal = 0; + uint audioIns = 0; + uint audioOuts = 0; + uint audioTotal = 0; + uint midiIns = 0; + uint parametersIns = 0; + uint parametersOuts = 0; + uint parametersTotal = 0; if (LADSPA_IS_HARD_RT_CAPABLE(ldescriptor->Properties)) hints |= PLUGIN_IS_RTSAFE; @@ -1116,11 +1116,11 @@ static void do_vst_check(lib_t& libHandle, const char* const filename, const boo // get everything else uint hints = 0x0; - int audioIns = effect->numInputs; - int audioOuts = effect->numOutputs; - int midiIns = 0; - int midiOuts = 0; - int parameters = effect->numParams; + uint audioIns = static_cast(std::max(0, effect->numInputs)); + uint audioOuts = static_cast(std::max(0, effect->numOutputs)); + uint midiIns = 0; + uint midiOuts = 0; + uint parameters = static_cast(std::max(0, effect->numParams)); if (effect->flags & effFlagsHasEditor) hints |= PLUGIN_HAS_CUSTOM_UI; @@ -1154,8 +1154,8 @@ static void do_vst_check(lib_t& libHandle, const char* const filename, const boo midiIns = 1; } - float* bufferAudioIn[std::max(1, audioIns)]; - float* bufferAudioOut[std::max(1, audioOuts)]; + float* bufferAudioIn[std::max(1U, audioIns)]; + float* bufferAudioOut[std::max(1U, audioOuts)]; if (audioIns == 0) { @@ -1163,7 +1163,7 @@ static void do_vst_check(lib_t& libHandle, const char* const filename, const boo } else { - for (int j=0; j < audioIns; ++j) + for (uint j=0; j < audioIns; ++j) { bufferAudioIn[j] = new float[kBufferSize]; carla_zeroFloats(bufferAudioIn[j], kBufferSize); @@ -1176,7 +1176,7 @@ static void do_vst_check(lib_t& libHandle, const char* const filename, const boo } else { - for (int j=0; j < audioOuts; ++j) + for (uint j=0; j < audioOuts; ++j) { bufferAudioOut[j] = new float[kBufferSize]; carla_zeroFloats(bufferAudioOut[j], kBufferSize); @@ -1236,9 +1236,9 @@ static void do_vst_check(lib_t& libHandle, const char* const filename, const boo if (gVstNeedsIdle) effect->dispatcher(effect, DECLARE_VST_DEPRECATED(effIdle), 0, 0, nullptr, 0.0f); - for (int j=0; j < audioIns; ++j) + for (uint j=0; j < audioIns; ++j) delete[] bufferAudioIn[j]; - for (int j=0; j < audioOuts; ++j) + for (uint j=0; j < audioOuts; ++j) delete[] bufferAudioOut[j]; } diff --git a/source/libjack/Makefile b/source/libjack/Makefile index fe29759ce..80d8767e2 100644 --- a/source/libjack/Makefile +++ b/source/libjack/Makefile @@ -48,6 +48,7 @@ OBJS = \ TARGET = $(BINDIR)/jack/libjack.so.0 else OBJS = +TARGET = endif # ---------------------------------------------------------------------------------------------------------------------- diff --git a/source/utils/CarlaOscUtils.hpp b/source/utils/CarlaOscUtils.hpp index 31e715381..0280270b3 100644 --- a/source/utils/CarlaOscUtils.hpp +++ b/source/utils/CarlaOscUtils.hpp @@ -1,6 +1,6 @@ /* * Carla OSC utils - * Copyright (C) 2012-2014 Filipe Coelho + * Copyright (C) 2012-2019 Filipe Coelho * * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU General Public License as @@ -128,7 +128,7 @@ void osc_send_control(const CarlaOscData& oscData, const int32_t index, const fl char targetPath[std::strlen(oscData.path)+9]; std::strcpy(targetPath, oscData.path); std::strcat(targetPath, "/control"); - try_lo_send(oscData.target, targetPath, "if", index, value); + try_lo_send(oscData.target, targetPath, "if", index, static_cast(value)); } static inline @@ -209,7 +209,7 @@ void osc_send_sample_rate(const CarlaOscData& oscData, const float sampleRate) n char targetPath[std::strlen(oscData.path)+13]; std::strcpy(targetPath, oscData.path); std::strcat(targetPath, "/sample-rate"); - try_lo_send(oscData.target, targetPath, "f", sampleRate); + try_lo_send(oscData.target, targetPath, "f", static_cast(sampleRate)); } static inline