Commit graph

911 commits

Author SHA1 Message Date
rc-swag
9e7fe64f67
feat(windows): apply review suggestions
Co-authored-by: Marc Durdin <marc@durdin.net>
2025-11-26 21:38:35 +10:00
rc-swag
4c4b0be456 feat(windows): audit _WIN64 macro 2025-11-25 16:01:52 +10:00
rc-swag
c4b6d06e43 feat(windows): combine start host 64 process functions
also removed sentry references. Fixed the manifest
references.
2025-11-25 12:42:15 +10:00
rc-swag
bc927bc4c3 feat(windows): fix version rc files to display correct
fix the version.rc files to display the correct description
and file name for keymanhp.*.exe fix version rc files to display correct
Also fix up the Keymanengine arm64 version names.
2025-11-24 13:54:02 +10:00
rc-swag
33cdb0f54c feat(windows): fix manifest for each host 2025-11-24 13:52:51 +10:00
rc-swag
0375dea3d6 feat(windows): remove custom built sentry.arm64.dll 2025-11-24 13:46:17 +10:00
rc-swag
ad34a44c9f chore(windows): Merge branch 'epic/win-arm' into feat/windows/11905/keymanx64-keymanarm64 2025-11-21 18:36:13 +10:00
Keyman Server
248d4205f0
Merge branch 'epic/win-arm' into auto/A19S16-merge-master-into-win-arm 2025-11-20 11:09:43 +01:00
rc-swag
6e5fb1cefe feat(windows): copy sentry arm build to bin folder 2025-11-20 11:28:05 +10:00
rc-swag
c059627aa5 feat(windows): link keymanarm64.dll correctly 2025-11-19 14:07:21 +10:00
Marc Durdin
edca16f508 change(windows): include map2pdb generation for relevant Delphi projects
Adds a call to map2pdb for Delphi projects, if map2pdb is an executable
on the path. This way, we get .pdb files we can use for debugging and
for performance profiling. This also replaces tds2dbg.

If map2dbg is available, then the build and install actions will copy
the PDB to be alongside the corresponding executable, making most debug
actions relatively seamless for finding symbols.

Also fixes up setup.exe in Windows and Developer to extend setup.exe to
a 512-byte boundary after map2pdb patches the PE.

Relates-to: #14787
Build-bot: skip release:developer,windows
Test-bot: skip
2025-11-13 14:48:18 +01:00
Marc Durdin
54642dc86d fix(windows): disable OutputDebugString from DllMain
Following investigation, it seems that OutputDebugString can trigger a
loader lock as it throws an exception which can be handled by a global
exception handler, which may try and load/unload DLLs or perform other
unsafe tasks (e.g. StackWalk). The safest solution is to remove the
debug string logging altogether from code paths that run from DllMain.

It would be nice to further simplify DllMain but that would be a
significant amount of additional work.
2025-11-13 14:47:39 +01:00
rc-swag
80d789c706 feat(windows): update keymanhp to v2022 and engine.sln 2025-11-03 12:53:12 +10:00
rc-swag
d2b9c7d1fe chore(windows): Merge branch 'epic/win-arm' into feat/windows/11905/keymanx64-keymanarm64 2025-11-03 09:59:10 +10:00
Marc Durdin
6ed0d6b280 chore(windows): upgrade VC++ projects to v143 (VS2022)
Test-bot: skip
Build-bot: skip release:developer,windows
2025-10-31 13:28:25 +01:00
Marc Durdin
9e1fe8e6de chore(windows): upgrade VC++ projects to v143 (VS2022)
Test-bot: skip
Build-bot: skip release:developer,windows
2025-10-30 16:31:45 +01:00
rc-swag
ccad218351 chore(windows): Merge branch 'epic/win-arm' into feat/windows/11905/keymanx64-keymanarm64
# Keyman Conventional Commit suggestions:
#
# - Link to a Sentry issue with git trailer:
#     Fixes: _MODULE_-_ID_
# - Give credit to co-authors:
#     Co-authored-by: _Name_ <_email_>
# - Use imperative, present tense ('attach' not 'attaches', 'attached' etc)
# - Don't include a period at the end of the title
# - Always include a blank line before trailers
# - More: https://github.com/keymanapp/keyman/wiki/Pull-Request-and-Commit-workflow-notes
2025-10-28 16:51:53 +10:00
rc-swag
d52b48cbbb feat(windows): handle arm64 complier environment
Update the build.bat to handle configuring the build
environment with vsdevcmd correctly for arm64 2019 doesn't
work very well so have to have pretty weird if statement.
also checked in some missed updates to function name change
2025-10-28 16:40:42 +10:00
Keyman Server
664b4b2082
Merge branch 'epic/win-arm' into chore/A19S14-merge-master-into-win-arm 2025-10-24 11:14:58 +02:00
rc-swag
472c8e2027 feat(windows): add keymanarm64.def update gitignore 2025-10-22 22:20:48 +10:00
rc-swag
9a7cb42fc7 feat(windows): add keymanarm64.def 2025-10-20 16:03:39 +10:00
rc-swag
6cc66379e1 chore(windows): Merge branch 'epic/win-arm' into feat/windows/11905/keymanx64-keymanarm64 2025-10-17 14:08:16 +10:00
rc-swag
ecec5e49f4 refactor(windows): address review comments 2025-10-15 10:58:42 +10:00
rc-swag
1340c4f9e5 feat(windows): add arm64 to wxs and core build
Add cross-arm64 and cross-x64 build
Add the arm64 binaries to the wxs installers with guids
update build.sh files
2025-10-14 16:00:40 +10:00
Marc Durdin
03cd865c09
Apply suggestions from code review
Co-authored-by: rc-swag <58423624+rc-swag@users.noreply.github.com>
2025-10-13 10:37:35 +02:00
Marc Durdin
c99e0c01c4 chore(windows): address warnings 2025-10-08 15:08:04 +02:00
Marc Durdin
50ffbb2722 fix(windows): osk: handle simulated left Control event when AltGr pressed
When a European layout is active, and the user presses AltGr, Windows
generates a simulated VK_LCONTROL event alongside the VK_RMENU event.
This was causing the OSK to show LCtrl as depressed alongside RAlt, so
the OSK would show the wrong modifier layer, which was unhelpful and
confusing to the end user.

It is possible to detect the simulated VK_LCONTROL in the WH_KEYBOARD_LL
hook, because the scan code generated is 0x21D, instead of 0x1D.
Warning: this is not a documented value. (But, this 0x21D scan code is
not passed to the WM_KEYDOWN event!) Therefore, we use Keyman's existing
kmnLowLevelKeyboardProc to pass modifier key events on to the visual
keyboard.

This patch handles only this specific scenario, by watching for that
specific scan code in the new handler in the UfrmOSKOnScreenKeyboard
module, together with some minor refactoring so that it fits neatly.

A future improvement would be to have all modifier key processing go
through this new handler, and eliminate the timer-based polling of the
keyboard. However, there is some additional risk around missing events,
leading to 'stuck modifiers'.

Fixes: #14890
Build-bot: skip release:windows
2025-10-08 14:32:40 +02:00
rc-swag
f73e16cfce feat(windows): update binary names and kmtip
Update the binary arm names to match the spec.
Also updated kmtip project to build arm64 dll
2025-10-02 16:45:36 +10:00
rc-swag
5ac167977b Merge branch 'epic/win-arm' into feat/windows/11905/keymanx64-keymanarm64 2025-10-01 14:11:23 +10:00
rc-swag
32e95fa444 refactor(windows): rename keymanx64 proj keymanhp
Fixes:#11905
2025-10-01 11:44:08 +10:00
rc-swag
d8dda66eaf refactor(windows): rename keymanx64 proj keymanhp
Fixes:#11905
2025-09-30 15:33:16 +10:00
rc-swag
ae441f16b5 feat(windows): add sentry.arm64.dll and lib 2025-09-30 13:12:34 +10:00
Marc Durdin
ad9ab53c72 feat(windows): improve startup time by caching locale names
This was flagged years ago as a potential performance hotspot: each
locale is loaded at process start for any kmcomapi-involved process,
which takes quite a long time. This refactor moves the locale
enumeration out of kmcomapi and into the build process, so we have a
static list of locales put into locale/index.xml.

This includes a minor breaking change to Keyman Engine API on Windows:
`MessageFromID(id, locale)` now only allows the three ids
SKUILanguageName, SKUILanguageNameWithEnglish, and SKLanguageCode, for
performance reasons. At this point, only SKUILanguageNameWithEnglish is
actually used anywhere in Keyman, and it is unlikely that any other
consumers are requesting alternate IDs.

Fixes: #14787
Build-bot: skip release:windows
2025-09-19 14:11:37 +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
rc-swag
1c41bdb669 modify dll base address for 64bit arm and x64 2025-07-31 17:45:54 +10:00
rc-swag
99d9d68e66 Initial addition of arm64 configuration 2025-07-31 16:30:23 +10:00
rc-swag
ad962172e9 fix(windows): remove dead code 2025-07-28 16:54:37 +10:00
rc-swag
f38145eaa2
Merge branch 'master' into fix/windows/14342/invalid-data-type-for-regkey 2025-07-25 10:58:55 +10:00
rc-swag
3c311a5aaa fix(windows): free the correct object KeyboardToggleReg 2025-07-24 16:59:41 +10:00
Eberhard Beilharz
e4c1867583
maint(windows): remove another (unused) include of win/zip.inc.sh
Addresses code review comment.
2025-07-21 10:26:32 +02:00
rc-swag
314c606aec fix(windows): add check a fix for registry datatypes
Fixes: #14342
The Windows system level keyboard hotkeys controlled in
registry have sometimes been incorrectly written as
a DWORD datatype. There 106 events in sentry for just
July. When opening the Windows setting dialog and the registry
has DWORDS it will show unassinged in the dialog if apply
is pressed it will convert the keys to REG_SZ.
This fix follows a similar pattern it will check the data
type of the registry key if it is DWORD it will remove it
and add a new key of the same name as REG_SZ and set it to
the unassigned value.

Fixes: KEYMAN-WINDOWS-4NK
2025-07-15 16:27:14 +10:00
rc-swag
6345a0b9b3
fix(windows): review comment
Co-authored-by: Eberhard Beilharz <ermshiperete@users.noreply.github.com>
2025-07-01 15:13:02 +10:00
rc-swag
82649634e5 chore(windows): Merge branch 'master' into feat/windows/13918/human-readble-msg-413-err 2025-06-27 14:54:04 +10:00
Marc Durdin
156bdcdd8a maint(common): rename and move builder_if_release_build_level 2025-06-16 06:45:42 +10:00
Marc Durdin
f3136d5ab2 maint(developer): skip signature check on buildLevel build 2025-06-16 05:54:33 +10:00
Marc Durdin
870d37f56b maint(developer): only copy .dbg/.pdb on release buildLevel 2025-06-16 05:40:30 +10:00
rc-swag
7ad4ba8527 feat(windows): Fix error checking order 2025-06-06 15:54:32 +10:00
rc-swag
770506c331 feat(windows): tweak diagnositc error message 2025-06-06 11:14:26 +10:00
rc-swag
0de78e808f feat(windows): don't send logs with diagnostics 2025-06-06 10:29:14 +10:00