Instead of having to change the version number and the build year in all
those files manually, we let cmake do the work by replacing the
respective values in templates.
This commit removes all qmake-related build-files from the system. We
have now migrated to cmake and are no longer maintaining qmake anyways
and therefore there is no reason to keep it.
Removing it also clearly states to any potential user/programmer that
this project is no longer intended to be compiled with qmake.
Given that the .pri files no longer exist, the mumble-version.py script
had to be adapted to read the version from the CMakeLists.txt file
instead.
Furthermore a few of the submodules support cmake natively and therefore
we no longer need the src/buid-directory approach in order to build
them. The respective build dirs have been removed and the src-dirs have
been renamed.
This commit removes all qmake-related build-files from the system. We
have now migrated to cmake and are no longer maintaining qmake anyways
and therefore there is no reason to keep it.
Removing it also clearly states to any potential user/programmer that
this project is no longer intended to be compiled with qmake.
Given that the .pri files no longer exist, the mumble-version.py script
had to be adapted to read the version from the CMakeLists.txt file
instead.
Furthermore a few of the submodules support cmake natively and therefore
we no longer need the src/buid-directory approach in order to build
them. The respective build dirs have been removed and the src-dirs have
been renamed.
'ALSA_ERRCHECK' is an unsafe function-like macro that should be replaced with a function. 'avail' is used uninitialized whenever 'bOk' is false which is undefined behavior.
A prominent feature of PulseAudio is automatic sample rate management. Mumble always wants 48000 Hz sample rate yet will often tell PulseAudio to sample at a different rate, such as 44100 Hz, and then resample internally reducing audio quality and wasting CPU time.
Instead of checking for the variable CMAKE_CONFIGURATION_TYPES, we now
use the dedicated property GENERATOR_IS_MULTI_CONFIG in order to
determine whether the used generator is a multi-config generator and
therefore does not respect the CMAKE_BUILD_TYPE variable.
If the user uses -Ddebug-dependency-search=OFF, then the find_pkg
function will not perform its searches using the QUIET flag causing a
lot of (valuable) information to be printed to the screen.
Instead of only printing the Mumble version that is being built, the
architecture that cmake is currently configuring for is displayed as
well.
In order to make this information more visible, they are surrounded by a
row of hashtags.
This change should make it more obvious to users if they happen to build
the wrong version/architecture (as can easily happen on Windows).
With the old qmake buildsystem we used to set QT_NO_CAST_FROM_ASCII (for
the Mumble client) in order to avoid problems with character encodings
in our Strings. This was not done in the new cmake system yet.
Instead of the aforementioned macro, this commit sets
QT_RESTRICTED_CAST_FROM_ASCII instead in order to be able to
automatically convert direct String literals to QString as these usually
don't contain any problematic characters (non-ASCII) in the first place.
And this allows to e.g. compare a QString against a String literal or do
something like
QString myString = "This is a test";
which we know to be unproblematic.
Note however that (quote from Qt's docs)
"Using this macro together with source strings outside the 7-bit range,
non-literals, or literals with embedded NUL characters is undefined."
With the old qmake buildsystem we used to set QT_NO_CAST_FROM_ASCII (for
the Mumble client) in order to avoid problems with character encodings
in our Strings. This was not done in the new cmake system yet.
Instead of the aforementioned macro, this commit sets (for all targets)
QT_RESTRICTED_CAST_FROM_ASCII instead in order to be able to
automatically convert direct String literals to QString as these usually
don't contain any problematic characters (non-ASCII) in the first place.
And this allows to e.g. compare a QString against a String literal or do
something like
QString myString = "This is a test";
which we know to be unproblematic.
Note however that (quote from Qt's docs)
"Using this macro together with source strings outside the 7-bit range,
non-literals, or literals with embedded NUL characters is undefined."
This feature optionally allows users to display the set volume
adjustments next to the user's/listener's name.
It will only be shown if it is not equal to 0 dB (aka: it is actually
having an effect).
By default this option is enabled since it is only visible if volume
adjustments are set up anyways.
This feature optionally allows users to display the set volume
adjustments next to the user's/listener's name.
It will only be shown if it is not equal to 0 dB (aka: it is actually
having an effect).
By default this option is enabled since it is only visible if volume
adjustments are set up anyways.
Axel is a CLI download utility that'll open multiple concurrent streams
and thereby increasing the overall download speed.
Ref.: https://www.linuxjournal.com/content/speed-your-downloads-axel
Using axel to download the environment seems to be up to 5x faster than
using wget.
Axel is a CLI download utility that'll open multiple concurrent streams
and thereby increasing the overall download speed.
Ref.: https://www.linuxjournal.com/content/speed-your-downloads-axel
Using axel to download the environment seems to be up to 5x faster than
using wget.
In order for the UI to not pop-up in the middle of the MainWindow (or
any other default location) after you have placed it carefully the last
time, this commit makes the UI's position to be saved and restored.
For cases in which there is no position set yet, it will be positioned
to the right of the initial position of the MainWindow.
Note that the UI's position is only saved if it is visible at the time
Mumble is closed which is used as an indication that the user is
actually using it (and has thus placed it explicitly).
In order for the UI to not pop-up in the middle of the MainWindow (or
any other default location) after you have placed it carefully the last
time, this commit makes the UI's position to be saved and restored.
For cases in which there is no position set yet, it will be positioned
to the right of the initial position of the MainWindow.
Note that the UI's position is only saved if it is visible at the time
Mumble is closed which is used as an indication that the user is
actually using it (and has thus placed it explicitly).
Since LGTM does not provide a recent enough cmake version, it can no
longer build our repository without falling back to the old qmake system
that'll be removed in the future.
Thus we no longer require LGTM to run as CI.
Since LGTM does not provide a recent enough cmake version, it can no
longer build our repository without falling back to the old qmake system
that'll be removed in the future.
Thus we no longer require LGTM to run as CI.
This PR fixes 2 raceconditions that both occur due to the MainWindow::serverDisconnected being able to trigger while certain client-server communication is still happening (unfinished).
The effects of these are
Loss of server-specific shortcuts due to them being saved from emory before having been loaded into it in the first place (due to msgServerSync not having been called yet)
Loss of ChannelListeners due to them being saved before their synchronisation with the server being done (and therefore again not having been loaded into memory yet but being saved from there).
The processing of ChannelListeners was delayed until the next iteration
of the Qt event loop since it was thought that msgServerSync was running
in another thread. Given that this function already accesses the DB,
this can't be though.
Thus the delay is unnecessary and was therefore removed.
As ChannelListeners are only synchronised with the server once
msgServerSync has been received, there is still a racecondition for them
even though we only save them if the ServerSync has happened yet.
The connection could be terminated before the answer of the server for
the request to add the respective listeners reaches the client. In that
case the listeners would be erased by the call to
ChannelListener::saveToDB().
Thus this commit introduces yet another flag indicating whether the
listeners have synchronised with the server yet.
Server-specific shortcuts are read into memory in
MainWindow::msgServerSync and are saved into the DB again in
MainWindow::serverDisconnected.
If however the disconnect function runs before the server
synchronization has finished, the shortcut list in memory is empty and
by writing that into the DB all existing server-specific shortcuts are
lost (overwritten).
This commit adds checks before saving the shortcuts (and
ChannelListeners) so that saving only occurs if the synchronization has
happened before and thus the shortcuts have been loaded in the first
place.
This fixes the loader not being able to load the DLL due to the missing symbol.
Previously, the function was defined and exported only when "QT_NO_DEBUG" was not defined (i.e. release builds).
This was probably the case due to:
- Our old environment not providing debug libraries.
- The DLL + loader idea only making sense when Mumble is installed. See PR #1684 for further info.
Before this commit the MacOS packaging script failed on copying Codecs
if the respective directory already existed (e.g. because the packaging
script has been run before).
Furthermore the script called a function to delete a directory (tree)
on a file. This error never surfaced before because usually when this
script is run, the respective file doesn't exist yet.
Both issues are fixed by this commit. It is now possible to run the
packaging script multiple times consecutively without it erroring on
already existing files.
This feature of AzurePipelines has only been introduced recently.
However it turned out that on average the caching of the environment
takes significantly more time than simply downloading it on every run.
Thus this commit disables environment caching again.
Whe using CONFIG+=no-manual-plugin with the old qmake buildsystem or
-Dmanual-plugin=OFF with the new cmake one, there were compile errors
due to the ManualPlugin being referenced in other files without include
guards.
This commit makes sure that in case the manual plugin is not included,
other code won't reference it either.
Fixes#4422
Whe using CONFIG+=no-manual-plugin with the old qmake buildsystem or
-Dmanual-plugin=OFF with the new cmake one, there were compile errors
due to the ManualPlugin being referenced in other files without include
guards.
This commit makes sure that in case the manual plugin is not included,
other code won't reference it either.
Fixes#4422
This feature of AzurePipelines has only been introduced recently.
However it turned out that on average the caching of the environment
takes significantly more time than simply downloading it on every run.
Thus this commit disables environment caching again.
Commit bdb12c6 added a regression for servers built with QT older than version
5.15. After this commit these servers do not server intermediate certificates
anymore. This happens because the QSslConfiguration is retrieved before adding
the CA certificates to the socket and is reinserted into the socket again after
adding the CA certificates, thereby overwriting the CA certificates added in
between.
This commit fixes that by retrieving the QSslConfiguration just after setting
the CA certificates in case an older QT version than 5.15 is used.
Commit bdb12c6 added a regression for servers built with QT older than version
5.15. After this commit these servers do not serve intermediate certificates
anymore. This happens because the QSslConfiguration is retrieved before adding
the CA certificates to the socket and is reinserted into the socket again after
adding the CA certificates, thereby overwriting the CA certificates added in
between.
This commit fixes that by retrieving the QSslConfiguration just after setting
the CA certificates in case an older QT version than 5.15 is used.