The Qt based implementation apparently got broken at some point and now fails
to connect to rfcomm dive computers like the Shearwater Petrel.
This uses the libdivecomputer rfcomm backend. Tested to work with bluez on
Linux as well as with the native Windows implementation.
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Number 3 overall committer with currently 9% of total commits and 27% of all
commits in the last three years.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
We no longer use libusb to access USB devices on Android, therefore
there's no point including libusb in our build. Also, we have never even
attempted to run the tests on Android, so let's not even pretend to
support building them.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
WARNING: multi directory commit, needed to secure it builds.
move the core/exportfuncs.* to backend-shared.
update backend-shared/CMakeLists.txt to generate backend-shared lib
update CMakeLists.txt to include backend-shared lib in link process.
update ios project to reflect new directory
Signed-off-by: Jan Iversen <jan@casacondor.com>
WARNING: multi directory commit, needed to secure it builds.
leaving the shared backend sources in core, imposes a severe limitation,
that they cannot make use of e.g. qt-models, because that is created
after core (first library to be created).
The shared backend uses functionality from core and qt-models, so it
must be created when those are available and before desktop-widgets
or mobile-widgets are created.
Make a new root directory "backend-shared" with empty CMakeLists.txt
Signed-off-by: Jan Iversen <jan@casacondor.com>
In order to make the central CMakeLists cleaner and more consistent
add a CMakeLists.txt to mobile-widgets, like in other root directories.
Signed-off-by: Jan Iversen <jan@casacondor.com>
In order to make the central CMakeLists cleaner and more consistent
add a CMakeLists.txt to map-widget, like in other root directories.
Signed-off-by: Jan Iversen <jan@casacondor.com>
qmlprofile.* is part of profile-widget, and are now defined in the
the corresponding CMakeLists.txt, and thereby making the central
CMakeLists.txt cleaner.
Signed-off-by: Jan Iversen <jan@casacondor.com>
Add -DSUBSURFACE_MOBILE_DESKTOP to CMake, allowing the
C++ part to be different when compiling for a device or
for the desktop.
Signed-off-by: Jan Iversen <jan@casacondor.com>
In the future we might want to use undo-commands for mobile as
well (even if not implementing undo).
Therefore, move the undo-command source from desktop-widgets
to their own commands top-level folder.
Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
Kirigami 5.62 uses QtQuick.Controls 2.5, which were introduced in
Qt 5.12 (see https://doc.qt.io/qt-5/qtquickcontrols-index.html)
update CMakeList.txt to demand min. 5.12 when building SUBSURFACE-MOBILE
update INSTALL text
Signed-off-by: Jan Iversen <jan@casacondor.com>
The AppImage works - I just need to figure out how to post releases. For now
it'a available on the Actions page as Artifact.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This is one of the side effects of switching to Kirigami 5.62 - but since
we build our mobile versions with Qt 5.12 and Qt 5.13, this really isn't
an issue.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This is working around a Qt Bug https://bugreports.qt.io/browse/QTBUG-69494
which prevents correct rendering of the OnePlus fonts.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This allows calling ctest from the main build directory instead of having to
change one level down. As a bonus the unittests now show up in my KDevelop so I
can directly run them from the IDE.
Signed-off-by: Rolf Eike Beer <eike@sf-mail.de>
The oldest version tested on TravisCI is Qt 5.5, which is also what is in
Ubuntu 16.04. Drop all the older cruft, noone should use that anymore.
Signed-off-by: Rolf Eike Beer <eike@sf-mail.de>
Printing never worked, none of this was ever included in test builds. Also, now
that there are official releases of QtWebKit again, this just doesn't seem worth
carrying along anymore.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
CMake will do the expansion internally itself. Not doing it here is not only
less code, it also makes sure one does not accidentially get a double expansion.
Signed-off-by: Rolf Eike Beer <eike@sf-mail.de>
Update CMakeLists.txt to test if the CMAKE_SYSTEM_PROCESSOR variable is
either armv6l or armv7l. If so, add libGLESv2 to the list of libraries
to be linked to support openGL on embedded systems.
Update INSTALL file to list the packages needed to be installed on
Raspian Stretch or Ubuntu Mate to successfully compile subsurface from
source.
Signed-off-by: Doug Junkins <junkins@foghead.com>
With commit 0d8fc7ef970e of qt-android-cmake, the buildtools version
is automatically detected. So do not try to pass it any more, as
this breaks the build.
Signed-off-by: Jan Mulder <jlmulder@xs4all.nl>
With a recent change to the qt-android-cmake project we are now using
the toolchain file bundled with the NDK, and that forces all cmake
modules to be part of the NDK tree - which breaks the way we find our Qt
installation. This is a hack to work around this as it undoes this
setting, which I'm sure is well intentioned to prevent host system
issues in this cross build scenario.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
On both Mac and Linux cmake 3.12 complained that there were "no sources given
to target" for the Subsurface-mobile target, which made no sense at all (easy
enough to add debug output to ensure there were, in fact, sources given in the
call to add_executable()). But splitting this across two lines like this seems
to make it work both for older and newer cmake versions.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Turns out that Jan found an issue with the latest Kirigami, so let's go back to
the known good one.
This reverts commit 17ec95e70c.
Suggested-by: Jan Mulder <jlmulder@xs4all.nl>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Update to the master of today, and no issues detected on mobile-on-desktop
and Android.
Only, the ugly border is back as the magic hack of 0b16b547ae failed
due to the patch file that errored. So that is fixed too.
Signed-off-by: Jan Mulder <jlmulder@xs4all.nl>
Use correct format, create script to update the version and release date in the
appdata.
[Dirk Hohndel: call said script during the build process]
Signed-off-by: Alexander Wilms <f.alexander.wilms@gmail.com>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
In a previous commit all override-modifiers were thrown out owing
to warning floods caused by the inconsistent-missing-override
flag on clang.
Re-adding overrides is now very painful because it's an all-or-nothing
thing. Let's disable the warning for now. If we reastablished good
coverage with override, we might think about re-enabling the warning.
Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
Move few mobile only functions from mobile-helper to mobile-main
remove subsurface-mobile-helper
file structure is now subsurface-*-main.cpp + subsurface-helper.cpp
Signed-off-by: Jan Iversen <jani@apache.org>
add subsurface-helper.cpp to share functions between mobile and desktop
move mobile qml registrations to a shared function (avoiding differences in registrations)
Target is to replace current subsurface-desktop-main + subsurface-desktop-helper and
subsurface-mobile-main + subsurface-mobile-helper with
subsurface-*-main + subsurface-helper
Signed-off-by: Jan Iversen <jani@apache.org>
remove mapWidget entries from subsurface.qrc, and
add reference to map-widget.qrc in CMakelist.txt
Android uses the same CMakelist.txt
Signed-off-by: Jan Iversen <jani@apache.org>
Instead of always adding -O2 for CMAKE_C_FLAGS_DEBUG and
CMAKE_CXX_FLAGS_DEBUG allow the user to pass a custom value
via GCC_OPTIMIZATION_FLAGS.
Passing -DGCC_OPTIMIZATION_FLAGS:STRING=-O0 would disable
all optimizations.
Suggested-by: Robert C. Helling <helling@atdotde.de>
Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
Resolves ERROR: no file at "/usr/lib/libgit2.dylib" when building on MacOS.
[Dirk Hohndel: SOB in PR #1201 - copying it into the commit for consistenty]
Signed-off-by: Allen Hall <revenant83@hotmail.com>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Cleanup only. It seems a little weird to first define a
CMAKE_MODULE_PATH search path and then explicitly include
files including a hard coded path instead of letting the
include command search for the modules we like to include.
Signed-off-by: Jan Mulder <jlmulder@xs4all.nl>
For a long time, I did not realize that a lot of qt-models are only
used in the mobile app, or only used in the desktop application.
This commit splits the qt-models in 3 parts. Used in both mobile and
desktop, used in desktop only, used in mobile only.
There is no other code change in here, other than cmake changes.
To me, this gives at least developers more insight where code is
actually used, and there is a small benefit in footpoint.
Signed-off-by: Jan Mulder <jlmulder@xs4all.nl>
This commit consists of the following 3 parts:
1. There are 2 source files added, adapt our build process
accordingly.
2. Due to a change in icon and kirigami QML prefixes, we need to
adapt for this as well. Changed mobile-resources.qrc for that.
When this would not be changed, the icons will not be found.
3. To further prepare for the future, abandon the iconName
property in favour of the new icon grouped property, which
can have more attributes than only the name. But currently
it is only a syntactic change.
Tested on Android device, and no visible changes.
Signedoff-by: Jan Mulder <jlmulder@xs4all.nl
Explicitly turning of automoc and friends for every single auto
generated file seems a rather dumb approach...
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
The -O0 default is useless owing to extremely convoluted assembly.
Moreover, many warnings depending on data analysis are ineffective
with -O0.
Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
It just doesn't seem to make sense. Why would you do that.
Allowing this options makes things more complicated as we need to
test for that in various places.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
The native Windows build does not use the MXE tools
and call such as `i686-w64-mingw32.shared-objcopy`
can fail.
Attempt to first find if the program exists using
`find_program()` and only then call it.
Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
The objcopy calls to strip the debug symbols out of
subsurface.exe need to happen before the installer is
created (staged).
Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
I only ran into this a couple of times and can't figure out why it
picked the order in which it tried to build things - but hard coding the
dependency seems to have fixed it (then again, since I didn't always run
into this, I'm not sure).
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This reverts commit 893ff019dbabf356a477da0bdf7d954123759018.
Thanks to the amazing support from Marco Martin the theming issue in
Kirigami master has been fixed.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Different flavors of Linux put this in different subdirectories. Just
have cmake find the plugin for us.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
With this change, when running Subsurface from the build directory, it
should find a googlemaps plugin that was installed into the
install_root.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This is some very early and hacky code to be able to access BLE-enabled
dive computers that use the GATT protocol to send packets back and forth
(which seems to be pretty much all of them: a vendor-specific GATT
service with a write characteristic and a notification characteristic
for reading).
For testing only. But it does successfully let me download dives from
my EON Steel and my Scubapro G2.
NOTE! There are several very hacky pieces in here, including just
"knowing" that the write characteristic is the first one, and the
notification characteristic is second. The code should actually check
the properties rather than have those kinds of hardcoded assumptions.
It also checks "vendor specific" by looking at the UUID string
representation, and knowing that the standard ones start with zero.
Crazily, there doesn't seem to be any normal way to test for this,
although I guess that maybe the uuid.minimumSize() function could be
used.
There are other nasty corners. Don't complain, send me patches.
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
The *_VERSION_STRING variable has been deprecated in Qt since 5.1.0. Use
the non-deprecated variable instead (which is not a string).
Qt 5.9.0 has a bug in the deprecated variable. Since it's deprecated,
it's probably not going to be fixed until 5.9.1. See
https://bugreports.qt.io/browse/QTBUG-60936
Signed-off-by: Thiago Macieira <thiago@macieira.org>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
The used cmake toolkit for building the Android Subsurface-mobile app
(qt-android-cmake) recently moved away from compiling with Ant in favor
of Gradle. The most recent Android SDK will not support Ant any more.
This calls for the addition of the Android SDK BUILDTOOLS_REVISION define
to the cmake of Subsurface-mobile. Without this, the build will fail.
The value has to be set to an existing directory in
.../android-sdk/build-tools/
Signed-off-by: Jan Mulder <jlmulder@xs4all.nl>