* 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
Move mac-specific build scripts and functions into our established
patterns for scripts under resources/build:
* new mac/mac.inc.sh for mac-specific functions, from mac-utils.inc.sh,
utils.inc.sh, builder-basic.inc.sh
* move other mac-specific scripts into mac/
Relates-to: #14065
Build-bot: build
Test-bot: skip
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
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
Because we don't know if mac BSD cp or GNU cp will be first on the path,
where there is ambiguity (e.g. with -R flag), we will use the macOS cp
command in /bin to ensure that we have consistent results. The
alternative would be to fixup each instance of the cp parameters so that
they work consistently with either cp command, but given these scripts
can run only on macOS, that seems unnecessary.
This replaces the earlier change in 97c6331b5.
shellHelperFunctions.sh currently needs build-utils.sh sourced first in
order to parse. As we are planning to merge these two scripts, I am okay
with this for now. But we need to make sure that prerequisite is met for
now.
I ran the following command to find scripts that referenced
shellHelperFunctions.sh but not build-utils.sh:
grep -L build-utils.sh $(grep -lR shellHelperFunctions --include='*.sh' .)
The following files were found:
./mac/bashHelperFunctions.sh
./mac/setup/build.sh
./resources/build/history/history-utils.sh
* bashHelperFunctions.sh has only a comment reference, so it's okay.
* mac/setup/build.sh I have reworked to include build-utils.sh.
* history-utils.sh is used only by ios/tools/prepRelease.sh, and that
script already includes build-utils.sh.
Fixes up scripts (except under /linux) to use `#!/usr/bin/env bash`
instead of `#!/bin/bash` or `#!/bin/sh` so that we don't end up with
the ancient version of bash supplied with macOS.
This became urgent with this PR, because of bash-4.xisms in
build-utils.sh, for example on line 572:
```
if [[ -v _builder_params[$e] ]]; then
```
Fixes#5700.
Adds support for arm64 (M1) to textinputsource in the Keyman app. All
other executables are already fat with support for both x86_64 and
arm64.
The installer did not work on downlevel versions
of macOS as the compile in Script Editor produced
a 10.15-compatible version. Now we build the app
directly from source with osacompile and bundle
that instead.
First steps towards a clean install script
for Keyman for Mac. Some steps still out-
of-order for now, particularly opening
System Preferences to allow Keyman before
Keyman has run for first time.