Commit graph

1873 commits

Author SHA1 Message Date
Eberhard Beilharz
ae1c816afb
Merge pull request #7874 from keymanapp/chore/linux/shellcheckwarnings
chore(linux): Remove some shellcheck warnings
2022-12-07 09:02:48 +01:00
Eberhard Beilharz
531cf174fa
Merge pull request #7873 from keymanapp/chore/linux/removebionic
chore(linux): Remove building for Bionic
2022-12-07 09:02:33 +01:00
Eberhard Beilharz
8a14372e0a
chore(linux): Improve package build
During package builds on Debian servers the build often failed
with an error related to X11 when running the tests. This change
skips the tests in `linux/ibus-keyman/src/test` when building
packages, similar to the way we already do it for the tests in
`linux/ibus-keyman/tests`.
2022-12-07 09:00:52 +01:00
Eberhard Beilharz
5413247e59 chore(linux): Remove some shellcheck warnings 2022-12-06 11:28:30 +01:00
Eberhard Beilharz
353c6a066a chore(linux): Remove building for Bionic 2022-12-06 11:26:46 +01:00
Eberhard Beilharz
5cf88878da docs(linux): Move Linux documentation
This change moves the Linux developer documentation to the new location
`docs/linux` as discussed in our planning meeting.
2022-12-05 18:07:10 +01:00
Eberhard Beilharz
b42061a732 chore(linux): Update debian changelog
(cherry picked from commit ec46a34509)
2022-12-01 20:41:50 +01:00
Eberhard Beilharz
c06e32186a
chore(linux): Cleanup previous commit
- fix debug output in case surrounding-text is not supported
- conditionally set prefilter flag if ibus supports it. We can now
  uncomment the check because beta branch got merged which added the
  variable to autotools.
2022-11-30 19:14:01 +01:00
Eberhard Beilharz
e1305a7f5d
refactor(linux): Update ibusimcontext.c
This change adds the upstream changes to ibusimcontext.c to our
test ibusimcontext.c file up to commit
506ac9993d5166196b7c4e9bfa9fb0f9d3792ffa plus our two prefilter
commits.
2022-11-30 19:14:01 +01:00
Eberhard Beilharz
d0734ceef4
Merge pull request #7833 from keymanapp/chore/linux/DebUploadScript
chore(linux): Fix upload-to-debian script
2022-11-29 10:48:27 +01:00
Eberhard Beilharz
f54ea7a7f2
Merge pull request #7804 from keymanapp/refactor/linux/kbdOptions
refactor(linux): Refactor setting keyboard options ⚙️
2022-11-29 10:48:02 +01:00
Eberhard Beilharz
16c91e695a
chore(linux): Use flag for beta phase
This addresses code review comments.
2022-11-29 08:57:41 +01:00
Eberhard Beilharz
0f2c9972c6
refactor(linux): Fix more memory leaks
Turns out there are more things we need to clean out if we run
into an error condition in the c'tor. Easiest is to call the
destroy method.
2022-11-28 16:46:55 +01:00
Eberhard Beilharz
8b4d3e09ed
Apply suggestions from code review
Co-authored-by: Marc Durdin <marc@durdin.net>
2022-11-28 16:40:02 +01:00
Eberhard Beilharz
e834c3c467
chore(linux): Update debian changelog
(cherry picked from commit 0ecc03dbac)
2022-11-28 12:31:48 +01:00
Eberhard Beilharz
7bec18615f
chore(linux): Fix upload-to-debian script
While we're in beta phase we need to modify `changelog` in beta
branch instead of `master`.
2022-11-28 12:28:01 +01:00
Eberhard Beilharz
61d5d69a12
refactor(linux): Address code review comments 2022-11-25 17:31:32 +01:00
Darcy Wong
fded9721e2 chore(common): Merge branch 'beta' into chore/common/beta-b16s2 2022-11-25 07:58:23 +07:00
Eberhard Beilharz
35b678a931
refactor(linux): Fix failing tests 2022-11-24 19:16:14 +01:00
Eberhard Beilharz
ddd8e5b08c
refactor(linux): Address code review comments 2022-11-24 17:00:11 +01:00
Eberhard Beilharz
afd5fc86f1
refactor(linux): Refactor setting keyboard options
- set keyboard options in a call to `km_kbp_state_options_update`
  separate from setting the environment options
- output status value if method fails
- if any of the methods fails we now return NULL
- split setting the options in multiple methods

Fixes #7717.
2022-11-23 19:05:54 +01:00
Eberhard Beilharz
5da4f17dd1
refactor(linux): Don't free consts
(cherry picked from commit b0b605709a)
2022-11-23 18:21:01 +01:00
Eberhard Beilharz
0f0ab06f53
refactor(linux): Use consts instead of strings
This refactoring makes use of the already defined strings.
It also simplifies setting the values by directly specifying an
UTF-16 string.

Motivated by the changes in PR #7667.

(cherry picked from commit 31340b5b51)
2022-11-23 18:20:52 +01:00
Eberhard Beilharz
1f7d6682a8
chore(linux): Update autotools configuration
This fixes some deprecation warnings:
- "The macro `AC_GNU_SOURCE' is obsolete"
- "The macro `AM_DISABLE_STATIC' is obsolete"
- "The macro `AC_ISC_POSIX' is obsolete"
- "The macro `AC_HEADER_STDC' is obsolete"
- "The macro `AM_PROG_LIBTOOL' is obsolete"
2022-11-23 08:46:41 +01:00
Eberhard Beilharz
a958f1a369
Merge pull request #7792 from keymanapp/fix/linux/7774_buildWithOldIbus
fix(linux): Allow to build without patched ibus version
2022-11-23 08:42:36 +01:00
Eberhard Beilharz
c1871fdd70
fix(linux): Improve compiler warning if ibus not patched
Co-authored-by: Marc Durdin <marc@durdin.net>
2022-11-23 08:42:25 +01:00
Darcy Wong
f69fd9ccfe
Merge pull request #7789 from keymanapp/chore/common/whatsnew-b16s2
chore(common): Update whatsnew for 16.0
2022-11-23 07:39:54 +07:00
Darcy Wong
2001f98d86
Apply suggestions from code review
Co-authored-by: Marc Durdin <marc@durdin.net>
2022-11-23 07:39:24 +07:00
Eberhard Beilharz
a2ec10d432
Merge pull request #7783 from keymanapp/fix/linux/warning
fix(linux): Revert "fix(linux): Fix a warning"
2022-11-22 19:51:45 +01:00
Eberhard Beilharz
bb54946a8a
fix(linux): Fix warning
Commit acab920de8 didn't really fix
the warning. https://stackoverflow.com/a/2524675/1836776 suggests
to use `%zu` which is what this change does now.
2022-11-22 18:47:11 +01:00
Eberhard Beilharz
da765f1625
fix(linux): Allow to build without patched ibus version
This change makes it possible to compile even when the updated
ibus version is not installed. Of course ordered output won't work
in that case, but at least it will compile and the rest of Keyman
will work.

Fixes #7774.
2022-11-22 18:05:46 +01:00
Darcy Wong
c584f0cb45 chore(common): Add notes about bugfixes 2022-11-22 10:50:21 +07:00
Eberhard Beilharz
812c7c33b9
fix(linux): Revert "fix(linux): Fix a warning"
This reverts commit acab920de8.

I'm confused - now we're getting the same warning again - claiming
that `size_t` is defined as `long unsigned int` and so we have to
use `%lu`!? Is this related to the platform we're compiling on?
This time, the warning we get is when compiling for x86_64:

```
engine.c: In function ‘get_current_context_text’:
engine.c:224:15: warning: format ‘%u’ expects argument of type ‘unsigned int’, but argument 5 has type ‘size_t’ {aka ‘long unsigned int’} [-Wformat=]
  224 |     g_message("%s: current context is:%u:%lu:%s:", __FUNCTION__, km_kbp_context_length(context), buf_size, current_context_utf8);
      |               ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~                ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
      |                                                                  |
      |                                                                  size_t {aka long unsigned int}
engine.c:224:40: note: format string is defined here
  224 |     g_message("%s: current context is:%u:%lu:%s:", __FUNCTION__, km_kbp_context_length(context), buf_size, current_context_utf8);
      |                                       ~^
      |                                        |
      |                                        unsigned int
      |                                       %lu

```

Reverting the previous fix for now.
2022-11-21 16:12:00 +01:00
Eberhard Beilharz
9891239cf0
feat(linux): Add symbols file
Debian/lintian recommends to add a symbols file which allows to
check for API changes. The package build on Jenkins now has an
additional build step that will compare the API of the newly
built package with the committed symbols file and will fail the
build if the API changed and we didn't update the symbols file
yet. The current symbols file gets stored as build artifact, so
it can easily be copied from Jenkins.

During the build of the binary package this check is also run but
won't fail the build.
2022-11-21 12:38:23 +01:00
Darcy Wong
cd27527646
Merge branch 'beta' into chore/common/crowdin-update-zhcn 2022-11-18 16:47:28 +07:00
Eberhard Beilharz
363e41c98f
Merge pull request #7746 from keymanapp/fix/linux/warning
fix(linux): Fix a warning
2022-11-18 08:42:02 +01:00
Eberhard Beilharz
a4abcdb831
Merge pull request #7730 from keymanapp/fix/linux/7722_replaceSharedKeyboard
fix(linux): Fix installation if shared kbd already installed
2022-11-18 08:41:46 +01:00
Darcy Wong
53debd015b
Merge pull request #7715 from keymanapp/chore/common/crowdin-update-ff-ng
chore(common): Update crowin strings for Fulfulde
2022-11-18 14:20:54 +07:00
Eberhard Beilharz
acab920de8
fix(linux): Fix a warning
`size_t` is defined as `unsigned int`, not as a long.
2022-11-17 19:26:28 +01:00
Eberhard Beilharz
a2ce5e50d8
fix(linux): Output warning if keyboard already installed in shared
This change outputs a warning if the user tries to install a
keyboard (to his home directory) and the keyboard is already
installed in the shared area, and vice versa.
2022-11-17 16:45:11 +01:00
Eberhard Beilharz
c670977779
Merge pull request #7731 from keymanapp/feat/linux/7725_bcp47tag
feat(linux): Add optional bcp47 parameter to km-package-install
2022-11-17 15:43:25 +01:00
Eberhard Beilharz
5c63d58978
feat(linux): Add -l as short version of --bcp47 parameter 2022-11-17 10:23:11 +01:00
Eberhard Beilharz
960e579e3f
Merge pull request #7733 from keymanapp/fix/linux/lintian
fix(linux): Fix lintian warnings
2022-11-17 10:14:43 +01:00
Eberhard Beilharz
b71f5ba143
fix(linux): Remove autom4te.cache from source package
This directory is unnecessary as it contains log files and cached
files, and it produces several lintian warnings.
2022-11-16 19:25:07 +01:00
Eberhard Beilharz
108e849459
fix(linux): Fix lintian warnings 2022-11-16 18:45:34 +01:00
Eberhard Beilharz
f9b8766f3a
fix(linux): Ignore dbus exception when testing for fcitx
Fixes KEYMAN-LINUX-3H.
2022-11-16 16:08:25 +01:00
Eberhard Beilharz
fd6083fd43
feat(linux): Add optional bcp47 parameter to km-package-install
This change adds a `--bcp47 <TAG>` parameter to km-package-install.
This allows to specify a language tag which will be used to install
the keyboard for that language.

Closes #7725.
2022-11-16 16:00:32 +01:00
Eberhard Beilharz
1d5b169aca
fix(linux): Allow to install local kbd if shared installed
This is similar to PR #7730 but implements things for
km-package-install.
2022-11-16 15:59:39 +01:00
Eberhard Beilharz
d16d29dccd
Merge pull request #7728 from keymanapp/fix/linux/7723_CrashBcp47
fix(linux): Don't crash if `und` is specified without `fonipa`
2022-11-16 15:38:43 +01:00
Eberhard Beilharz
309d68375b
fix(linux): Fix installation if shared kbd already installed
Fixes #7722.
2022-11-16 12:26:18 +01:00