12 Commits

Author SHA1 Message Date
Dylan Baker
348d8610db Set the encoding parameter for all open() calls that write in text mode
This was generated with a regex search/replace in vscode using:
`(open\(.*, 'w\+?')` -> `$1, encoding='utf-8')`

This should silence a bunch of warnings, and seems to fix issues seen in
the Windows CI. This seems to likely be to a "helpful feature" in
msbuild that treats certain text in stdout/stderr as errors, which it
sometimes decides that the warning about not having the encoding set
triggers.
2026-05-01 11:18:47 -04:00
Dylan Baker
e991c4d454 Use SPDX-License-Identifier consistently
This replaces all of the Apache blurbs at the start of each file with an
`# SPDX-License-Identifier: Apache-2.0` string. It also fixes existing
uses to be consistent in capitalization, and to be placed above any
copyright notices.

This removes nearly 3000 lines of boilerplate from the project (only
python files), which no developer cares to look at.

SPDX is in common use, particularly in the Linux kernel, and is the
recommended format for Meson's own `project(license: )` field
2023-12-13 15:19:21 -05:00
Jussi Pakkanen
1205172fd4 Autodetect installer path location. 2023-05-25 17:17:30 -04:00
Josh Soref
b5c1c93ea8 packaging: fix options hostArchitectures attribute
This is used by the meson.pkg but is an optional attribute:

https://developer.apple.com/library/archive/documentation/DeveloperTools/Reference/DistributionDefinitionRef/Chapters/Distribution_XML_Ref.html#//apple_ref/doc/uid/TP40005370-CH100-SW41

Found by https://www.check-spelling.dev/

Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2023-04-11 19:21:05 -04:00
HiPhish
439a61affa Change "can not" to "cannot" throughout project
The word "cannot" expresses inability to do something whereas "can not"
expresses the ability to refrain from doing something.
2023-04-11 17:10:01 +03:00
Eli Schwartz
258cd5d583 packaging: rework how pyinstaller gets its instructions
Make use of pyinstaller hooks by creating a hook that updates how the
`mesonbuild` import functions.

This is more or less the same as passing a bajillion arguments to
pyinstaller's CLI, but allows the logic to be self-contained (and
reusable). It becomes more obvious what parts of the process pertain to
pyinstaller, and which parts pertain to MSI/pkg creation.
2022-03-30 02:06:52 +03:00
Jussi Pakkanen
5aeed25617 Remove temp files that the macOS installer builder leaves hanging. 2021-10-24 03:04:37 +03:00
Dylan Baker
4d7031437c pylint: turn on superflous-parens
We have a lot of these. Some of them are harmless, if unidiomatic, such
as `if (condition)`, others are potentially dangerous `assert(...)`, as
`assert(condtion)` works as expected, but `assert(condition, message)`
will result in an assertion that never triggers, as what you're actually
asserting is `bool(tuple[2])`, which will always be true.
2021-08-31 16:28:54 -04:00
Eli Schwartz
59d4f771d2 editorconfig: add setting to trim trailing whitespace
and clean up all outstanding issues

Skip 'test cases/common/141 special characters/meson.build' since it
intentionally uses trailing newlines.
2021-08-15 09:36:18 -04:00
Eli Schwartz
409aae51d6 misc formatting lint fixes, drop unneeded f-string 2021-08-15 09:36:18 -04:00
Jussi Pakkanen
d53ea7da2d Fix macpkg generator import path. [skip ci] 2021-06-07 21:29:01 +03:00
Jussi Pakkanen
5eeddd682f Add a script to create macOS installer packages. 2021-05-18 20:47:05 +03:00