Commit graph

356 commits

Author SHA1 Message Date
Eberhard Beilharz
cef3160c74
Merge pull request #15928 from keymanapp/maint/core/15905_build
maint(core): exclude `.configured` files from source tarball 🏗️

In the source tarball we don't want to include `.configured` files so that a build will call `npm i` first.

Fixes: #15905
Follows: #15926
2026-05-11 18:19:52 +02:00
Eberhard Beilharz
e6ae3d92a8
chore(linux): Merge remote-tracking branch 'origin/master' into chore/linux/projectparam 2026-05-11 18:12:03 +02:00
Eberhard Beilharz
c70ad66366
Merge pull request #15924 from keymanapp/chore/linux/debianbuilder
chore(linux): make `debian.sh` a builder script 🏗️

This change modifies `debian.sh` so that it is a full builder script. This allows further cleanup in `package-build.inc.sh`.

Follows: #15916
2026-05-11 18:07:24 +02:00
Eberhard Beilharz
1f02bc02f6
chore(linux): address code review comments
Some checks failed
Keyman Build Summary / Summarize build status checks (push) Has been cancelled
- make `verify_source.sh` a full builder script
- make options for `launchpad.sh` less confusing
- reference `--help` in `packaging.md`
- run new script as part of Ubuntu packaging workflow

Co-authored-by: Marc Durdin <marc@durdin.net>
2026-05-08 19:11:18 +02:00
Eberhard Beilharz
327be78de7
Apply suggestions from code review
Some checks failed
Keyman Build Summary / Summarize build status checks (push) Has been cancelled
Co-authored-by: Marc Durdin <marc@durdin.net>
2026-05-08 09:57:43 +02:00
Eberhard Beilharz
69db9e9a37
maint(core): exclude .configured files from source tarball 🏗️
In the source tarball we don't want to include `.configured` files so
that a build will call `npm i` first.

Fixes: #15905
Follows: #15926
Test-bot: skip
2026-05-07 19:06:26 +02:00
Eberhard Beilharz
e03c37cacd
chore(linux): Merge branch 'maint/linux/sourcepkg' into chore/linux/checksource 2026-05-07 19:02:54 +02:00
Eberhard Beilharz
14e097ab95
maint(linux): fix source tarball used for packaging
The source tarball we upload to downloads.keyman.com contains all files
necessary to run `${KEYMAN_ROOT}/build.sh`, i.e. it contains all projects
that can be build on Linux. However, that is not the command used when
building Debian packages. There we limit the build to the `linux`
subfolder. Therefore we only need a subset of the files. Using the full
tarball causes some lintian errors.

This change creates and uploads a second tarball on release builds that
contains only the files needed for Debian packaging. The file is named
`keyman_$VERSION.pkg.tar.xz`.

Build-bot: skip
Test-bot: skip
2026-05-07 18:46:20 +02:00
Eberhard Beilharz
b0cc243e1d
chore(linux): remove --project parameter
The option to be able to specify a project for some linux scripts was
left over from older Keyman versions where Keyman was split over several
source packages. The current Keyman version builds multiple binary
Debian packages from just one source package, so this option is no longer
needed. This change gets rid of it.

Build-bot: skip
Test-bot: skip
2026-05-07 16:56:30 +02:00
Eberhard Beilharz
c825fb25f8
chore(linux): make debian.sh a builder script
This change modifies `debian.sh` so that it is a full builder script. This
allows further cleanup in `package-build.inc.sh`.

Follows: #15916
Build-bot: skip
Test-bot: skip
2026-05-07 16:55:00 +02:00
Eberhard Beilharz
2c8f878f1d
chore(linux): add verification for source tarball and source package
This change adds a new GitHub action that verifies that Keyman can build
from the source package. Also check that source package used for Launchpad
and Debian/Ubuntu packaging doesn't produce lintian errors. Previously
lintian errors did go unnoticed because they didn't stop the build.

Also refactor `launchpad.sh` script to be a proper builder script, and add
some new parameters to allow skipping some steps in the script.

Build-bot: skip
Test-bot: skip
2026-05-06 19:03:12 +02:00
Eberhard Beilharz
a3ea01451e
chore(linux): use xz compression for source tarballs
Using the xz compression instead of gzip greatly reduces the size of the
tarball.

Follows: #15566
Test-bot: skip
2026-02-06 17:37:34 +01:00
Eberhard Beilharz
9322a8adcb
Apply suggestions from code review
Co-authored-by: Marc Durdin <marc@durdin.net>
2026-02-06 17:13:35 +01:00
Eberhard Beilharz
f981469298
chore(linux): add unit tests for new functions in package-build.inc.sh
This addresses code review comments. Also improve variable naming and
documentation for these new functions.
2026-02-06 17:02:27 +01:00
Eberhard Beilharz
1b4e254963
fix(linux): include missing artifacts in source tarball
With this change it's possible to build Keyman from the source tarball
by running `./build.sh` from the Keyman root directory.

When building Keyman as part of the Ubuntu/Debian packaging, we don't use
the toplevel `build.sh` file but instead call the build scripts in the
subdirectories. This omits building some components that are currently
not needed for running Keyman for Linux. The `dist.sh` script only
includes the necessary files in this case, distinguished by the `origdist`
parameter. This results in a significantly smaller tarball (2.5MB vs 51MB).

This change also enhances the `generate_tar_ignore_list` function so that
it is now possible to add `build` to the exclude list to ignore all
`build` subdirectories.

Fixes: #15544
Build-bot: skip
Test-bot: skip
2026-02-05 17:56:15 +01:00
Eberhard Beilharz
7102bed1e5
maint(linux): remove EOL Ubuntu 25.04 Plucky
Support for Ubuntu 25.04 Plucky ends on 15th January 2026 after which
it is no longer possible to upload and build on Launchpad. This change
removes Plucky.

Fixes: #14955
Test-bot: skip
2026-01-13 18:04:57 +01:00
Eberhard Beilharz
9d2b17613c
chore(linux): add manual test for localization
This change adds a manual test that allows to see if all strings are
localizable. It also fixes the `update-template` target in the
`Makefile`.

Build-bot: skip
Test-bot: skip
2025-12-15 19:05:58 +01:00
Marc Durdin
8f95d84014
Merge pull request #15114 from keymanapp/maint/resources/builder-timing
maint(resources): add build timing report to builder
2025-11-14 14:24:11 +01:00
Eberhard Beilharz
e56619911d
chore(linux): add support for Ubuntu 26.04 LTS Resolute
Build-bot: skip
Test-bot: skip
2025-11-11 11:28:20 +01:00
Marc Durdin
c573709ee6 maint(resources): add build timing report to builder
This is enabled automatically for CI builds, and can be enabled with
`--timing` parameter otherwise. Also, adds `builder_launch`,
documentation to come.

Test-bot: skip
2025-11-10 11:03:45 +01:00
Eberhard Beilharz
c1c0c1f926
maint(linux): improve upload-to-debian script 🍒🍒
- directly get PR# from `gh pr create`
- add `Build-bot: skip` trailers
- 🍒-pick of the improved 🍒-pick #14785

Cherry-pick-of: #14785
Build-bot: skip
Test-bot: skip
2025-09-19 15:45:07 +02:00
Eberhard Beilharz
a3ec6bed17
Merge pull request #14598 from keymanapp/maint/linux/packaging
This change creates a temporary worktree for creating Debian packages. This will allow us to work from a clean state of the source repo. Also exclude any generated patch directories (`.pc`).
2025-09-01 15:11:48 +02:00
Eberhard Beilharz
6e2049b788
Merge pull request #14639 from keymanapp/maint/linux/14563_tarignore
This generates the `--tar-ignore`s to avoid having to manually maintain the list when adding new files or folders for other platforms. Instead now we have a list of files and directories to include, and a list of exceptions to exclude from the includes. From that we generate the tar-ignore list.

Fixes: #14563
2025-09-01 15:05:12 +02:00
Eberhard Beilharz
c8bea7496f
maint(linux): remove residues of previous runs on startup 2025-08-29 12:33:06 +02:00
Eberhard Beilharz
a1287739b4
maint(linux): more doc comments 2025-08-29 12:15:56 +02:00
Eberhard Beilharz
906b6a45fc
maint(linux): add doc comments 2025-08-29 09:57:25 +02:00
Eberhard Beilharz
537ffcff9d
Update linux/scripts/dist.sh
Co-authored-by: Marc Durdin <marc@durdin.net>
2025-08-29 09:39:15 +02:00
Eberhard Beilharz
3dbb7e56c7
Merge pull request #14572 from keymanapp/refactor/linux/launchpad 2025-08-28 19:14:52 +02:00
Eberhard Beilharz
2754e4bef4
maint(linux): generate tar-ignore in dist.sh
This generates the `--tar-ignore`s to avoid having to manually maintain
the list when adding new files or folders for other platforms. Instead
now we have a list of files and directories to include, and a list of
exceptions to exclude from the includes. From that we generate the
tar-ignore list.

Fixes: #14563
Test-bot: skip
2025-08-28 18:41:29 +02:00
Eberhard Beilharz
f9c23a5fba
refactor(linux): clarify missing quotes around ${SIM}
Addresses code review comment.
2025-08-28 17:18:15 +02:00
Eberhard Beilharz
cf273a27d9
maint(linux): address code review comments 2025-08-28 16:48:08 +02:00
Eberhard Beilharz
5d8b20dad6
Apply suggestion from @mcdurdin
Co-authored-by: Marc Durdin <marc@durdin.net>
2025-08-28 15:48:22 +02:00
Eberhard Beilharz
4b5faef475
Merge pull request #14603 from keymanapp/refactor/linux/packaging-tests 2025-08-27 12:05:56 +02:00
Eberhard Beilharz
6cf43ddace
maint(linux): address code review comments 2025-08-25 17:47:45 +02:00
Eberhard Beilharz
488c0a684e
refactor(linux): use bash testing framework for packaging tests 2025-08-25 17:35:27 +02:00
Eberhard Beilharz
d201802e75
maint(linux): ignore generate patch directories
During a package build a  patch directory (`.pc`) might get created.
That can't and shouldn't be part of the source package. This change
excludes any `.pc` directories.

Build-bot: skip
Test-bot: skip
2025-08-25 15:54:54 +02:00
Eberhard Beilharz
525d54ab65
maint(linux): preserve created package files
Copy the generated files before removing the worktree so that they
are still available for reference.
2025-08-25 15:38:49 +02:00
Eberhard Beilharz
66b6a69909
maint(linux): create temporary worktree for packaging
This change creates a temporary worktree for creating Debian packages.
This will allow us to work from a clean state of the source repo. Also
exclude any generated patch directories (`.pc`).

Build-bot: skip
Test-bot: skip
2025-08-25 15:22:14 +02:00
Eberhard Beilharz
3c4264387c
refactor(linux): allow to run launchpad.sh from any directory
Previously the assumption was that `launchpad.sh` would be run from the
`linux` directory. This change sets the directory at the beginning of
the script, allowing it to be run from any directory. Also specify full
path to `launchpad.sh` in the TC build script.

Build-bot: skip
Test-bot: skip
2025-08-20 17:53:57 +02:00
Eberhard Beilharz
5efab30415
refactor(linux): remove shellcheck warnings and reformat
Build-bot: skip
Test-bot: skip
2025-08-20 17:14:35 +02:00
Marc Durdin
0d27ac91f7 maint(mac): use mac_ prefix for functions in mac.inc.sh
* Also renames resources/environment.sh to resources/build/mac/xcode-environment.inc.sh.
* Adds a few more exclusions to linux/scripts/dist.sh

Fixes: #14478
Test-bot: skip
Build-bot: build
2025-08-20 05:40:32 +02:00
Marc Durdin
f394245636 maint(common): consolidate builder scripts
Clarifies the confusing builder.inc.sh / build-utils.sh distinction by
giving the scripts more appropriate names. Most build scripts should use
builder-full.inc.sh; some helper scripts can use builder-basic.inc.sh.
Documented in resources/build/README.md.

Renames:
* resources/build/builder.inc.sh to resources/build/builder-full.inc.sh
* resources/build/build-utils.sh to resources/build/builder-basic.inc.sh

Other changes:
* Moves Android-specific functions out of builder-basic.inc.sh and into
  android/build.sh.
* Renames functions in builder-basic.inc.sh

More functions may be moved from builder-basic.inc.sh into utils.inc.sh
or other scripts in the future.

Fixes: #14065
Build-bot: build all
Test-bot: skip
2025-08-02 08:11:24 +10:00
Marc Durdin
65158a0526 maint(common): rename shellHelperFunctions.sh to utils.inc.sh
Adds documentation for various functions, removes unused functions (a
couple of simple, very lightly used functions were unDRYed; these could
go back the other way across all shell scripts if necessary). TODO items
noted for follow-up refactoring.

Fixes: #14275
Relates-to: #14269
Build-bot: build all
Test-bot: skip
2025-08-02 06:58:40 +10:00
Eberhard Beilharz
169490e3fa
maint(linux): remove Oracular from launchpad builds
Ubuntu 24.10 Oracular is EOL, so we remove it from our launchpad builds.

Test-bot: skip
2025-07-09 11:21:00 +02:00
Eberhard Beilharz
38f43d84cf
refactor(common): some reformattings in shellHelperFunctions.sh
Also always include `jq.inc.sh`. The include file already has everything
we did here.

Test-bot: skip
2025-07-07 18:44:28 +02:00
Eberhard Beilharz
10e21cb433
maint(linux): sudo not required for removing temporary files 🍒
Since we have write access to the directory we don't need `sudo` for
removing the temporary dependency files if we pass `-f` to `rm`.

Cherry-pick-of: commit 4f27f6e256
Cherry-pick-of: #14085
Test-bot: skip
2025-05-30 11:12:56 +02:00
Eberhard Beilharz
3cb9fe2a65
fix(linux): fix variable replacements
This fixes the version numbers in `km-config` which broke with #13854.
This also fixes opening the download page in `km-config` because that
uses a version number in the URL.

Fixes: #14031
Follow-up-of: #13854
2025-05-22 16:20:18 +02:00
Eberhard Beilharz
1e8f692410
Merge pull request #13754 from keymanapp/chore/common/13399_tc-config 2025-05-15 16:32:53 +02:00
Eberhard Beilharz
6f8cba7815
Merge pull request #13913 from keymanapp/maint/linux/sourcepkg
Until now we accidentally included three files `linux/keyman_build_deps*` in the source package that get created during installing dependencies. This change deletes the files after installing the dependencies before we create the source package.
2025-05-15 16:28:08 +02:00
Eberhard Beilharz
8ef92c7d1b
Merge pull request #13912 from keymanapp/maint/linux/logging 2025-05-15 16:27:21 +02:00