diff --git a/.travis.yml b/.travis.yml index 5ab6f2da7..02f815239 100644 --- a/.travis.yml +++ b/.travis.yml @@ -36,6 +36,12 @@ matrix: env: - TARGET="linux-strict" + # linux with gcc 8, strict build, using juce + - os: linux + compiler: gcc + env: + - TARGET="linux-juce-strict" + before_install: - sh ${TRAVIS_BUILD_DIR}/.travis/before_install.sh diff --git a/.travis/before_install.sh b/.travis/before_install.sh index 00c95cfbc..1dc73ca75 100644 --- a/.travis/before_install.sh +++ b/.travis/before_install.sh @@ -6,7 +6,7 @@ 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 +if [ "${TARGET}" = "linux-strict" ] || [ "${TARGET}" = "linux-juce-strict" ]; then sudo add-apt-repository -y ppa:ubuntu-toolchain-r/test fi diff --git a/.travis/install.sh b/.travis/install.sh index 8382d3f6d..7095d3b03 100755 --- a/.travis/install.sh +++ b/.travis/install.sh @@ -50,6 +50,26 @@ elif [ "${TARGET}" = "linux-strict" ]; then liblo-static \ fluidsynth-static +elif [ "${TARGET}" = "linux-juce-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 \ + libfreetype6-dev \ + libmagic-dev \ + libgl1-mesa-dev \ + libx11-dev \ + libxext-dev \ + liblo-static \ + fluidsynth-static + elif [ "${TARGET}" = "macos" ]; then sudo apt-get install -y \ pkg-config \ diff --git a/.travis/script-linux-juce-strict.sh b/.travis/script-linux-juce-strict.sh new file mode 100755 index 000000000..f21af18cf --- /dev/null +++ b/.travis/script-linux-juce-strict.sh @@ -0,0 +1,36 @@ +#!/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/juce_audio_basics +make -C source/modules/juce_audio_devices +make -C source/modules/juce_audio_processors +make -C source/modules/juce_core +make -C source/modules/juce_data_structures +make -C source/modules/juce_events +make -C source/modules/juce_graphics +make -C source/modules/juce_gui_basics +make -C source/modules/sfzero +make -C source/modules/water +make -C source/theme all qt4 qt5 + +# Build native stuff +make TESTBUILD=true USING_JUCE=true diff --git a/.travis/script-linux-strict.sh b/.travis/script-linux-strict.sh index 0bbf93dad..ae6e9e19b 100755 --- a/.travis/script-linux-strict.sh +++ b/.travis/script-linux-strict.sh @@ -23,8 +23,11 @@ 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/modules/water all posix32 make -C source/theme all qt4 qt5 # Build native stuff make TESTBUILD=true + +# Build 32bit bridges +make TESTBUILD=true posix32 diff --git a/source/backend/plugin/CarlaPluginVST2.cpp b/source/backend/plugin/CarlaPluginVST2.cpp index f6a7976ba..8c0bcaedc 100644 --- a/source/backend/plugin/CarlaPluginVST2.cpp +++ b/source/backend/plugin/CarlaPluginVST2.cpp @@ -2279,7 +2279,7 @@ public: // --------------------------------------------------------------- // initialize plugin (part 1) - sCurrentUniqueId = uniqueId; + sCurrentUniqueId = static_cast(uniqueId); sLastCarlaPluginVST2 = this; try { diff --git a/source/includes/lv2/atom-forge.h b/source/includes/lv2/atom-forge.h index a3f5c23b5..5a2935bab 100644 --- a/source/includes/lv2/atom-forge.h +++ b/source/includes/lv2/atom-forge.h @@ -296,7 +296,7 @@ lv2_atom_forge_raw(LV2_Atom_Forge* forge, const void* data, uint32_t size) if (forge->sink) { out = forge->sink(forge->handle, data, size); } else { - out = (LV2_Atom_Forge_Ref)forge->buf + forge->offset; + out = (LV2_Atom_Forge_Ref)((uint32_t)forge->buf + forge->offset); uint8_t* mem = forge->buf + forge->offset; if (forge->offset + size > forge->size) { return 0; diff --git a/source/jackbridge/JackBridge1.cpp b/source/jackbridge/JackBridge1.cpp index 850816e54..9766f7d2c 100644 --- a/source/jackbridge/JackBridge1.cpp +++ b/source/jackbridge/JackBridge1.cpp @@ -1273,7 +1273,9 @@ jack_port_t* jackbridge_port_register(jack_client_t* client, const char* port_na return jack_port_register(client, port_name, port_type, flags, buffer_size); #else if (getBridgeInstance().port_register_ptr != nullptr) - return getBridgeInstance().port_register_ptr(client, port_name, port_type, flags, buffer_size); + return getBridgeInstance().port_register_ptr(client, port_name, port_type, + static_cast(flags), + static_cast(buffer_size)); #endif return nullptr; } @@ -1613,7 +1615,9 @@ void jackbridge_port_get_latency_range(jack_port_t* port, uint32_t mode, jack_la return jack_port_get_latency_range(port, static_cast(mode), range); #else if (getBridgeInstance().port_get_latency_range_ptr != nullptr) - return getBridgeInstance().port_get_latency_range_ptr(port, static_cast(mode), range); + return getBridgeInstance().port_get_latency_range_ptr(port, + static_cast(mode), + range); #endif range->min = 0; range->max = 0; @@ -1626,7 +1630,9 @@ void jackbridge_port_set_latency_range(jack_port_t* port, uint32_t mode, jack_la jack_port_set_latency_range(port, static_cast(mode), range); #else if (getBridgeInstance().port_set_latency_range_ptr != nullptr) - getBridgeInstance().port_set_latency_range_ptr(port, static_cast(mode), range); + getBridgeInstance().port_set_latency_range_ptr(port, + static_cast(mode), + range); #endif } @@ -1651,7 +1657,8 @@ const char** jackbridge_get_ports(jack_client_t* client, const char* port_name_p return jack_get_ports(client, port_name_pattern, type_name_pattern, flags); #else if (getBridgeInstance().get_ports_ptr != nullptr) - return getBridgeInstance().get_ports_ptr(client, port_name_pattern, type_name_pattern, flags); + return getBridgeInstance().get_ports_ptr(client, port_name_pattern, type_name_pattern, + static_cast(flags)); #endif return nullptr; } diff --git a/source/jackbridge/JackBridge2.cpp b/source/jackbridge/JackBridge2.cpp index 383de512f..386cb06b0 100644 --- a/source/jackbridge/JackBridge2.cpp +++ b/source/jackbridge/JackBridge2.cpp @@ -121,7 +121,7 @@ void* jackbridge_shm_map(void* shm, uint64_t size) noexcept #ifdef JACKBRIDGE_DUMMY return nullptr; #else - return carla_shm_map(*(carla_shm_t*)shm, size); + return carla_shm_map(*(carla_shm_t*)shm, static_cast(size)); #endif }