Commit graph

553 commits

Author SHA1 Message Date
Egbert de Pauw
00952b89af
Merge 9bd1631103 into 364c776ff1 2024-10-21 10:05:59 +13:00
Salvador Cuñat
f81cf77886 Make libraw support build optional
Build in by default if libraw is found, but make it optional for builds
were it's not needed, like smtk2ssrf or subsurface-downloader.

Signed-off-by: Salvador Cuñat <salvador.cunat@gmail.com>
2024-09-30 22:22:39 +13:00
Michael Keller
6418d3acbc Update Version in docker Tag, Clean up Dependencies.
Signed-off-by: Michael Keller <github@ike.ch>
2024-09-27 09:47:40 +12:00
dependabot[bot]
9873c86192 build(deps): bump ubuntu in /scripts/docker/android-build-container
Bumps ubuntu from 22.04 to 24.04.

---
updated-dependencies:
- dependency-name: ubuntu
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-09-27 09:47:40 +12:00
Dirk Hohndel
09f59211ed build-system: de-clutter output of get-version.sh
In certain situations git merge-base would report errors if the branch
you are working in is older than the latest CICD builds. This simply
hides those pointless errors.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2024-09-21 11:03:53 +12:00
Michael Keller
cb6766c1d4 CICD: Add libraw to the MXE build container.
In support of #3954.

Also update MXE to the latest version.

Signed-off-by: Michael Keller <github@ike.ch>
2024-09-15 18:46:36 +12:00
Dirk Hohndel
a5effbe0a6 macOS: reorder build of dependencies
libcurl needs openssl.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2024-09-09 15:15:38 -07:00
Egbertdepauw
c5e5535f51 qt6: Make subsurface buildable with Qt6 on Macos
Building on macos with the Qt6 framework.

made changes to several files to make it possible to build subsurface
desktop with the Qt 6.5.x and higher framework.

Tested versions: 6.5.2, 6.6.3, 6.7.2

code builds and googlemaps works, made some adjustments to get panning
and zooming with mouse or trackpad working.

See issue #3577 "Build Fails, macOS" for build details.

Signed-off-by: Egbertdepauw <egbert@despaankamer.nl>
2024-08-27 13:51:37 +02:00
Berthold Stoeger
b95ac3f79c core: turn C dive-table into an owning table
This is a humongous commit, because it touches all parts of the
code. It removes the last user of our horrible TABLE macros, which
simulate std::vector<> in a very clumsy way.

Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
2024-08-13 19:28:30 +02:00
Michael Keller
009e8a32bb Fix Windows versioning as well.
Signed-off-by: Michael Keller <github@ike.ch>
2024-08-02 01:28:37 +12:00
Michael Keller
2b7900b68d CICD: Make Version Information SemVer Compliant.
Make the version information used throughout the application and build
process compliant with the SemVer specifications, so that it can be
processed with libraries.

Signed-off-by: Michael Keller <github@ike.ch>
2024-07-30 11:05:10 +12:00
rmultan
ae734603b9 Fix MacOS build & update INSTALL.md
Fix build for Apple silicon Mac.
Update INSTALL.md with relevant
instructions.

Signed-off-by: rmultan <multan.rafal.k@gmail.com>
2024-07-29 23:48:20 +12:00
Michael Keller
c2c5faeaad Add the change for MacOS builds with Qt6 as well.
Signed-off-by: Michael Keller <github@ike.ch>
2024-06-02 09:42:14 +12:00
jme
88acef7f0f release build google maps
After the Mac QT upgrade to 5.15.13 google maps stopped working because a debug plugin was built and not deployed.   This changes forces a release build.   It may or may not be the best alternative, but if nothing else it's a starting point for discussion with people who know more about qmake than I do.

Signed-off-by: jme <32236882+notrege@users.noreply.github.com>
2024-06-02 09:42:14 +12:00
Michael Keller
dd50ab0106 Fix incorrect script references.
Signed-off-by: Michael Keller <mikeller@042.ch>
2024-05-13 12:39:09 +12:00
Michael Keller
0d6b572a9f Fix script permissions.
Signed-off-by: Michael Keller <mikeller@042.ch>
2024-05-13 12:32:07 +12:00
=Michael Keller
6fc8310705 CICD: Improve Workflows.
Make multiple improvements to the existing workflows:
- create a shared custom action to deal with version number tracking
  and generation;
- use this action to add the branch name to the version for pull
  request builds;
- create a shared workflow for all debian-ish builds to avoid re-use
  by copy / paste;
- remove potential security risks by eliminating the use of
  pre-evaluated expressions (`${{ ... }}`) inside scripts;
- update outdated GitHub action versions;
- improve the consistency by renaming scripts acording to have a `.sh`
  extension;
- improve naming of generated artefacts for pull requests to include
  the correct version.

@dirkh: Unfortunately this is potentially going to break builds when it is
merged, as there is no good way to 'test' a merge build short of
merging.
We'll just have to deal with the fallout of it in a follow-up pull
request.

Signed-off-by: Michael Keller <github@ike.ch>
2024-05-13 10:19:59 +12:00
=Michael Keller
306dad575c CICD: Update the AppImage Build to Use ubuntu 16.04.
Update the linux AppImage build to use ubuntu 16.04, and simplify it to
a single workflow running on a vanilla docker image.

This still uses the upload-artifact@v3 Action that will be EOL in
November 2024, because v4 relies on node 20 which has an unmet glibc
dependency in ubuntu 16.04. But this workflow can be updated to run on
ubuntu 18.04 by a simple search / replace and disabling some 16.04
specific PPAs.

@dirkh, @probonopd: I have moved this here from #4183 to be able to
review and discuss it without the noise of the workflow cleanup.

The workflow now also publishes the AppImage as an artifact on pull
request builds, available under Checks / Details / Summary.

Signed-off-by: Michael Keller <github@ike.ch>
2024-05-12 13:52:12 +12:00
=Michael Keller
a83349015a CICD: Improve the GitHub Actions for Linux.
Do a few things:
- add a build for Debian trixie (as discussed in #4182);
- add a build for Ubuntu 24.04;
- rename the build definitions to match the build names;
- update the artifact uploads to use a non-deprecated version of the
  action, and name the artifact appropriately;
- remove a stale workflow file.

Signed-off-by: Michael Keller <github@ike.ch>
2024-05-11 12:51:33 +12:00
Michael Keller
d92777a3ff Packaging: Cleanup Windows Build Scripts.
Do some housekeeping and cleanup on the build scripts for Windows:
- remove Windows 32bit builds as support for this has been removed from
  the mxe container;
- fix some warnings in the smtk2ssrf installer configuration;
- sanitise the output colour of the smtk2ssrf build script;
- add a docker based build script for the Windows installers;
- remove outdated and deprecated documentation and scripts.

Signed-off-by: Michael Keller <mikeller@042.ch>
2024-04-26 07:42:59 -07:00
Michael Keller
d49092ac70 CICD: Add Script to Find the Changeset ID for a CICD Release Number.
Add a script that finds the changeset ID in the subsurface repository
that a given CICD release was built from.
The option '-c' can be used to check out the changeset, if one is found.

Signed-off-by: Michael Keller <mikeller@042.ch>
2024-04-20 10:46:28 +07:00
Berthold Stoeger
5ac64ab2cd cleanup: replace Q_FOREACH and foreach by range base for
Q_FOREACH and foreach are anachronisms.

Range based for may cause a performance regression: it can
lead to a copy of shared containers (one reason why Qt's
COW containers are broken). However, as long as there is no
user noticeable delay, there is no point in analyzing each case.
And also no point in slapping an 'asConst' on every container
that is looped over.

Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
2024-03-24 17:53:19 +01:00
Dirk Hohndel
fbbbbb997e build-system: sort Usage message and add missing options
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2024-02-07 15:00:56 -08:00
Michael Keller
9cdb9f7989 CICD: Add a File Containing the Release Title to CICD Releases.
Add a file containing the release title (derived from the pull request
title / commit message) to CICD releases - this is so that it will be
able to pick this up by the process updating the release pages on our
webserver, and show a list of the last few changes for each release.

Signed-off-by: Michael Keller <mikeller@042.ch>
2024-01-31 15:18:21 -08:00
Robert C. Helling
4fdaf3e8de Downloader: Install perl modules and set up environment
Signed-off-by: Robert C. Helling <helling@lmu.de>
2024-01-27 15:38:41 -08:00
Michael Keller
05ef933ff7 CICD: Move Windows Build to New Container.
Move the GitHub Action that builds the Windows artefacts to use the new
subsurface/mxe-build:3.1.0 container.
Also rename references to the old container in scripts and
documantation.

Signed-off-by: Michael Keller <github@ike.ch>
2024-01-24 00:05:26 +13:00
Michael Keller
c1bfded4a7 CICD: Add GitHub Action to build the Windows (MXE) Builder Docker Image.
Add a GitHub action that builds the docker image to run builds for the
Windows (MXE) version of Subsurface.
Also update the MXE image Dockerfile to the latest version of MXE, and
add a patch to use a current version of mdbtools.
Configure GitHub actions that do not build docker images to not trigger
on changes to the contents of `scripts/docker/`.

Signed-off-by: Michael Keller <github@ike.ch>
2024-01-20 21:30:12 -08:00
Michael Keller
6dd5922d15 CICD: Improve the Android Docker Image Build.
Introduce proper reuse of intermediary stages in the multi-stage build.

Signed-off-by: Michael Keller <github@ike.ch>
2024-01-19 16:14:35 -08:00
Michael Keller
6c8afabedf CICD: Improve the Release Note Generation
Use .md suffix to get the files displayed as markdown.
Ignore generated artefacts.

Signed-off-by: Michael Keller <mikeller@042.ch>
2024-01-15 17:32:57 -08:00
Alexander Wilms
c92ebd1f3b Change AppStream metainfo file extension and path
The legacy /usr/share/appdata/*.appdata.xml path has been superseded by
/usr/share/metainfo/*.metainfo.xml

https://freedesktop.org/software/appstream/docs/chap-Metadata.html#spec-component-location

Signed-off-by: Alexander Wilms <f.alexander.wilms@gmail.com>
2024-01-14 15:59:29 -08:00
Salvador Cuñat
5bae033f07 [scripts - docker] Fix build instructions
Current instruction to get the installer out the container will fail
with bash complaining about cp being a binary. Then would fail too
because subsurface-installer.exe doesn't exist any more.

Proposed instruction should work.

Signed-off-by: Salvador Cuñat <salvador.cunat@gmail.com>
2024-01-10 21:10:31 -08:00
Dirk Hohndel
7d918aeef1 CICD: gracefully handle non merge pushes
Also improve the spacing of the merge text a tiny bit.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2024-01-10 19:24:36 -08:00
Dirk Hohndel
eb4f3121bc CICD: clean up the noisy scripts
This all is way too verbose now that it apparently is working.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2024-01-10 19:14:25 -08:00
Dirk Hohndel
8fb504941e the path confusion is vert annoying
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2024-01-10 16:58:08 -08:00
Dirk Hohndel
5b2d1a4506 build-system: get the buildnr file from the right directory
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2024-01-10 13:44:06 -08:00
Dirk Hohndel
ca5f7fa4bf build-system: correctly test that branch was created
That '-b' was exactly the wrong thing to do here...

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2024-01-10 13:44:06 -08:00
Dirk Hohndel
744257149f build-system: push to origin instead of explicit URL
Otherwise we don't use the embedded credentials and the push fails.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2024-01-10 13:44:06 -08:00
Dirk Hohndel
c0c447a5b6 build-system: don't discard the get-or-create-build-nr script output
That was the whole point of the previous change.
Also, run the build number creation on a pull request as well (at least for a
while) so we don't need to create new releases in order to test that part of
the process).

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2024-01-10 13:44:06 -08:00
Dirk Hohndel
30efede730 build-system: small changes for better debugging
In order to make it easier to see what's happening inside get-atomic-buildnr.sh
write the result to a file that can be read by the caller. Not quite as
elegant, but hopefully more practical to see what's going wrong when no new
build number is created.

Make sure that post-releasenotes is successfull by actually posting a release
artifact (apparently the gh release action otherwise quietly fails).

Try to ensure we find the Android APK when uploading to the release.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2024-01-10 11:54:44 -08:00
Dirk Hohndel
14e715be6e build-system: assemble release notes using gh CLI
Instead of using a thirdparty action and painfully passing things around,
simply use the GitHub CLI (gh) and assemble the release notes on the fly.

This makes for much simpler and much easier to maintain code.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2024-01-09 17:14:42 -08:00
Dirk Hohndel
13603a0878 build-system: avoid output that confuses the script
The get-or-create-buildnr.sh script writes a nice message to stdout which is useful
when using it interactively - but it broke the scripting; so redirect that output.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2024-01-08 21:38:38 -08:00
Dirk Hohndel
7286a76233 build-system: simplify GitHub Actions
Move both code and the release note text into files that can be shared between
multiple actions.

This should make the actions smaller and easier to read and since this is used
in several actions it should make things much easier to maintain.

In order to test this without too much unnecessary noise, this commit only
changes the android workflow - the others will be changed in a later commit
once his has been tested and works (again, this can really only be tested by
merging the PR into master).

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2024-01-08 17:51:54 -08:00
Dirk Hohndel
4527abe936 build-system: helper script for atomic build number
This way we don't have to replicate the same code in several .yml files for
GitHub Actions.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2024-01-08 17:51:54 -08:00
Michael Keller
b5efaf661c CICD: Improve Location of Scripts for the Android Build Environment.
Move around the scripts required for the setup of the build environment
for android to satisfy docker's requirement of locality.
This allows the removal of an extra copy step, and avoids the creation
of extra artefacts, while still providing the same functionality.

Signed-off-by: Michael Keller <github@ike.ch>
2024-01-08 23:05:44 +13:00
Michael Keller
7d751a8160 Re-activated the GitHub action to build and publish the docker image.
Signed-off-by: Michael Keller <github@ike.ch>
2024-01-06 20:16:57 -08:00
Michael Keller
8e8c69f749 Added git configuration for the new CICD build setup.
Signed-off-by: Michael Keller <github@ike.ch>
2024-01-06 20:16:57 -08:00
Michael Keller
e8dd3389a7 CICD: Update the android Build Docker Image.
Update the android build docker image:
- rebase on ubuntu 22.04;
- add tooling required to sign APKs;
- changes to make the container re-usable;
- change to a multi-stage build to keep the image size smaller;
- generic improvements to the Dockerfile

Also update the example script for how to use the container.

Signed-off-by: Michael Keller <github@ike.ch>
2024-01-06 20:16:57 -08:00
Dirk Hohndel
aea2f36de2 rename variable in get-version script
Yeah... that looks better. Thanks @mikeller.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2024-01-06 10:55:24 -08:00
Dirk Hohndel
62477d8c65 Complete redesign of Subsurface version numbers
- for now all versions start with v6.0
- CICD builds use the monolithic build number as patch level, e.g. v6.0.12345
- local builds use the following algorithm
  - find the newest commit with a CICD build number that is included in the
    working tree
  - count the number of commits in the working tree since that commit
  - if there are no commits since the last CICD build, the local build version
    will be v6.0.12345-local
  - if there are N commits since the last CICD build, it will be
    v6.0.12345-N-local
- test builds in the CICD that don't create artifacts simply use a dummy release
  in order to not incorrectly increment the build number and also not to waste
  time and resources by manually checking out the nightly-build repo for each of
  these builds.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2024-01-06 10:55:24 -08:00
Dirk Hohndel
8a2dd8db74 Finally remove some of the Travis related scripts
These haven't been used in many years.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2024-01-06 10:55:24 -08:00