diff --git a/.gitignore b/.gitignore index 604ca28..c7f5d9f 100644 --- a/.gitignore +++ b/.gitignore @@ -63,6 +63,7 @@ doc/pyvenv.cfg # pyenv /.python-version +/.venv pyvenv.cfg /man/ diff --git a/README.rst b/README.rst index 43e7158..ee43e6e 100644 --- a/README.rst +++ b/README.rst @@ -42,4 +42,84 @@ To build the wheels for all the plugins:: etc/scripts/build-plugins.sh +To override the platform tag (e.g., for Apple Silicon) set +``SCANCODE_PLUGINS_PLAT_NAME`` and optionally ``SCANCODE_PLUGINS_PYTHON_TAG``:: + + SCANCODE_PLUGINS_PLAT_NAME=macosx_15_0_arm64 \ + SCANCODE_PLUGINS_PYTHON_TAG=py3 \ + etc/scripts/build-plugins.sh + The dirs/ directory will contain all the built wheels. + +To build Linux manylinux2014 x86_64 wheels in Docker:: + + docker build --platform linux/amd64 \ + -f etc/docker/scancode-linux-x86_64.Dockerfile \ + -t scancode-linux-x86_64:latest . + + docker run --rm --platform linux/amd64 \ + -v "$(pwd)":/work/scancode-plugins \ + -w /work/scancode-plugins \ + scancode-linux-x86_64:latest \ + bash -lc etc/scripts/build-linux-x86_64.sh + +To collect the multi-arch wheel set for publishing (default: ModelMonster +packages on linux/x86_64, linux/aarch64, and macos/arm64):: + + etc/scripts/copy-wheels.sh --target /tmp/wheels + +To prepare a GitHub Pages style tree (`dist/` under repo root):: + + etc/scripts/copy-wheels.sh \ + --layout repo \ + --target /tmp/scancode-plugins-pages \ + --base-url https://ospoco.github.io/scancode-plugins/dist/ + + +ModelMonster wheel workflow (local dev) +--------------------------------------- + +This fork (`ospoco/scancode-plugins`) is used to produce and publish the +wheel set consumed by ModelMonster (`mm`) for Python 3.14: + +- linux/x86_64 (`manylinux2014_x86_64`) +- linux/aarch64 (`manylinux2014_aarch64`) +- macOS/arm64 (`macosx_15_0_arm64`) + +The default publish set is the 7 plugin packages used by `mm`: + +- extractcode_7z +- extractcode_libarchive +- typecode_libmagic +- textcode_pdf2text +- scancode_ctags +- scancode_dwarfdump +- scancode_readelf + +Recommended build order: + +1. Build/update macOS arm64 plugin wheels on an Apple Silicon machine. +2. Build Linux x86_64 wheels with `etc/scripts/build-linux-x86_64.sh`. +3. Build Linux aarch64 wheels with `etc/scripts/build-linux-aarch64.sh`. +4. Assemble publishable artifacts: + + :: + + etc/scripts/copy-wheels.sh --target /tmp/wheels + +5. For GitHub Pages publishing layout: + + :: + + etc/scripts/copy-wheels.sh \ + --layout repo \ + --target /tmp/scancode-plugins-pages \ + --base-url https://ospoco.github.io/scancode-plugins/dist/ + +Expected result for the default ModelMonster set: + +- 21 wheels total (7 packages x 3 platform tags) +- `index.html` generated next to the wheels + +The top-level `dist/` directory in this repo is a build output location and is +ignored by Git. Use `copy-wheels.sh` output as the publish artifact. diff --git a/binary-analysis/scancode-ctags-linux/src/scancode_ctags/bin/ctags b/binary-analysis/scancode-ctags-linux/src/scancode_ctags/bin/ctags old mode 100644 new mode 100755 index 5f2bc63..6bc1910 Binary files a/binary-analysis/scancode-ctags-linux/src/scancode_ctags/bin/ctags and b/binary-analysis/scancode-ctags-linux/src/scancode_ctags/bin/ctags differ diff --git a/binary-analysis/scancode-ctags-macosx/setup.cfg b/binary-analysis/scancode-ctags-macosx/setup.cfg index 3b0d575..7f15a66 100644 --- a/binary-analysis/scancode-ctags-macosx/setup.cfg +++ b/binary-analysis/scancode-ctags-macosx/setup.cfg @@ -4,4 +4,4 @@ license_files = README.rst [aliases] -release = clean --all bdist_wheel --plat-name macosx_10_14_x86_64 --python-tag py3 +release = clean --all bdist_wheel --plat-name macosx_15_0_arm64 --python-tag py3 diff --git a/binary-analysis/scancode-ctags-macosx/src/scancode_ctags/bin/ctags b/binary-analysis/scancode-ctags-macosx/src/scancode_ctags/bin/ctags old mode 100644 new mode 100755 index 6bf7f96..c18152e Binary files a/binary-analysis/scancode-ctags-macosx/src/scancode_ctags/bin/ctags and b/binary-analysis/scancode-ctags-macosx/src/scancode_ctags/bin/ctags differ diff --git a/binary-analysis/scancode-ctags-macosx/src/scancode_ctags/lib/libjansson.4.dylib b/binary-analysis/scancode-ctags-macosx/src/scancode_ctags/lib/libjansson.4.dylib new file mode 100644 index 0000000..3355839 Binary files /dev/null and b/binary-analysis/scancode-ctags-macosx/src/scancode_ctags/lib/libjansson.4.dylib differ diff --git a/binary-analysis/scancode-ctags-macosx/src/scancode_ctags/lib/libpcre2-8.0.dylib b/binary-analysis/scancode-ctags-macosx/src/scancode_ctags/lib/libpcre2-8.0.dylib new file mode 100644 index 0000000..7fe6728 Binary files /dev/null and b/binary-analysis/scancode-ctags-macosx/src/scancode_ctags/lib/libpcre2-8.0.dylib differ diff --git a/binary-analysis/scancode-ctags-macosx/src/scancode_ctags/lib/libyaml-0.2.dylib b/binary-analysis/scancode-ctags-macosx/src/scancode_ctags/lib/libyaml-0.2.dylib new file mode 100644 index 0000000..a1dcfd1 Binary files /dev/null and b/binary-analysis/scancode-ctags-macosx/src/scancode_ctags/lib/libyaml-0.2.dylib differ diff --git a/binary-analysis/scancode-ctags-macosx/src/scancode_ctags/licenses/jansson/INSTALL_RECEIPT.json b/binary-analysis/scancode-ctags-macosx/src/scancode_ctags/licenses/jansson/INSTALL_RECEIPT.json new file mode 100644 index 0000000..0d4e0d5 --- /dev/null +++ b/binary-analysis/scancode-ctags-macosx/src/scancode_ctags/licenses/jansson/INSTALL_RECEIPT.json @@ -0,0 +1,39 @@ +{ + "homebrew_version": "5.0.11-36-gb5c9928", + "used_options": [], + "unused_options": [], + "built_as_bottle": true, + "poured_from_bottle": true, + "loaded_from_api": true, + "installed_as_dependency": true, + "installed_on_request": false, + "changed_files": [ + "lib/pkgconfig/jansson.pc" + ], + "time": 1770149151, + "source_modified_time": 1769288097, + "compiler": "clang", + "aliases": [], + "runtime_dependencies": [], + "source": { + "spec": "stable", + "versions": { + "stable": "2.15.0", + "head": null, + "version_scheme": 0, + "compatibility_version": null + }, + "path": "/Users/van/Library/Caches/Homebrew/api/formula.jws.json", + "tap_git_head": "c62cffdc8d8b07d242d457f1ac1e3123b8630ea0", + "tap": "homebrew/core" + }, + "arch": "arm64", + "built_on": { + "os": "Macintosh", + "os_version": "macOS 26", + "cpu_family": "dunno", + "xcode": "26.2", + "clt": "26.2.0.0.1.1764812424", + "preferred_perl": "5.34" + } +} \ No newline at end of file diff --git a/binary-analysis/scancode-ctags-macosx/src/scancode_ctags/licenses/jansson/LICENSE b/binary-analysis/scancode-ctags-macosx/src/scancode_ctags/licenses/jansson/LICENSE new file mode 100644 index 0000000..418ee6a --- /dev/null +++ b/binary-analysis/scancode-ctags-macosx/src/scancode_ctags/licenses/jansson/LICENSE @@ -0,0 +1,43 @@ +# License + +This project is licensed under the MIT license, except where otherwise noted. +The full text of the MIT license is included below. + +## MIT License + +Copyright (c) 2009-2024 Petri Lehtinen + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. + +## Exceptions + +### `src/dtoa.c` + +Copyright (c) 1991, 2000, 2001 by Lucent Technologies. + +Permission to use, copy, modify, and distribute this software for any +purpose without fee is hereby granted, provided that this entire notice +is included in all copies of any software which is or includes a copy +or modification of this software and in all copies of the supporting +documentation for such software. + +THIS SOFTWARE IS BEING PROVIDED "AS IS", WITHOUT ANY EXPRESS OR IMPLIED +WARRANTY. IN PARTICULAR, NEITHER THE AUTHOR NOR LUCENT MAKES ANY +REPRESENTATION OR WARRANTY OF ANY KIND CONCERNING THE MERCHANTABILITY +OF THIS SOFTWARE OR ITS FITNESS FOR ANY PARTICULAR PURPOSE. diff --git a/binary-analysis/scancode-ctags-macosx/src/scancode_ctags/licenses/jansson/README.rst b/binary-analysis/scancode-ctags-macosx/src/scancode_ctags/licenses/jansson/README.rst new file mode 100644 index 0000000..5a77324 --- /dev/null +++ b/binary-analysis/scancode-ctags-macosx/src/scancode_ctags/licenses/jansson/README.rst @@ -0,0 +1,70 @@ +Jansson README +============== + +.. |tests| image:: https://github.com/akheron/jansson/workflows/tests/badge.svg +.. |appveyor| image:: https://ci.appveyor.com/api/projects/status/lmhkkc4q8cwc65ko + +|tests| |appveyor| + +Jansson_ is a C library for encoding, decoding and manipulating JSON +data. Its main features and design principles are: + +- Simple and intuitive API and data model + +- `Comprehensive documentation`_ + +- No dependencies on other libraries + +- Full Unicode support (UTF-8) + +- Extensive test suite + +Jansson is licensed under the `MIT license`_; see LICENSE in the +source distribution for details. + +Compilation and Installation +---------------------------- + +If you obtained a ``jansson-X.Y.tar.*`` tarball from GitHub Releases, just use +the standard autotools commands:: + + $ ./configure + $ make + $ make install + +To run the test suite, invoke:: + + $ make check + +If the source has been checked out from a Git repository, the ``configure`` +script has to be generated first. The easiest way is to use autoreconf:: + + $ autoreconf -i + + +Documentation +------------- + +Documentation is available at http://jansson.readthedocs.io/en/latest/. + +The documentation source is in the ``doc/`` subdirectory. To generate +HTML documentation, invoke:: + + $ make html + +Then, point your browser to ``doc/_build/html/index.html``. Sphinx_ +1.0 or newer is required to generate the documentation. + + +Community +--------- + +* `Documentation `_ +* `Issue tracker `_ +* `Mailing list `_ +* `Wiki `_ contains some development documentation + +.. _Jansson: http://www.digip.org/jansson/ +.. _`Comprehensive documentation`: http://jansson.readthedocs.io/en/latest/ +.. _`MIT license`: http://www.opensource.org/licenses/mit-license.php +.. _Sphinx: http://sphinx.pocoo.org/ diff --git a/binary-analysis/scancode-ctags-macosx/src/scancode_ctags/licenses/libyaml/INSTALL_RECEIPT.json b/binary-analysis/scancode-ctags-macosx/src/scancode_ctags/licenses/libyaml/INSTALL_RECEIPT.json new file mode 100644 index 0000000..972574f --- /dev/null +++ b/binary-analysis/scancode-ctags-macosx/src/scancode_ctags/licenses/libyaml/INSTALL_RECEIPT.json @@ -0,0 +1,46 @@ +{ + "homebrew_version": "4.3.20-36-gf0be97f", + "used_options": [ + + ], + "unused_options": [ + + ], + "built_as_bottle": true, + "poured_from_bottle": true, + "loaded_from_api": true, + "installed_as_dependency": true, + "installed_on_request": false, + "changed_files": [ + "lib/pkgconfig/yaml-0.1.pc" + ], + "time": 1741625856, + "source_modified_time": 1591046390, + "compiler": "clang", + "aliases": [ + + ], + "runtime_dependencies": [ + + ], + "source": { + "spec": "stable", + "versions": { + "stable": "0.2.5", + "head": null, + "version_scheme": 0 + }, + "path": "/Users/van/Library/Caches/Homebrew/api/formula.jws.json", + "tap_git_head": "92e863ffae35ef982e48fbecffe4defb665f2469", + "tap": "homebrew/core" + }, + "arch": "arm64", + "built_on": { + "os": "Macintosh", + "os_version": "macOS 15", + "cpu_family": "dunno", + "xcode": "16.0", + "clt": "16.0.0.0.1.1724870825", + "preferred_perl": "5.34" + } +} \ No newline at end of file diff --git a/binary-analysis/scancode-ctags-macosx/src/scancode_ctags/licenses/libyaml/License b/binary-analysis/scancode-ctags-macosx/src/scancode_ctags/licenses/libyaml/License new file mode 100644 index 0000000..3d82c28 --- /dev/null +++ b/binary-analysis/scancode-ctags-macosx/src/scancode_ctags/licenses/libyaml/License @@ -0,0 +1,20 @@ +Copyright (c) 2017-2020 Ingy döt Net +Copyright (c) 2006-2016 Kirill Simonov + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/binary-analysis/scancode-ctags-macosx/src/scancode_ctags/licenses/libyaml/ReadMe.md b/binary-analysis/scancode-ctags-macosx/src/scancode_ctags/licenses/libyaml/ReadMe.md new file mode 100644 index 0000000..2dfcc44 --- /dev/null +++ b/binary-analysis/scancode-ctags-macosx/src/scancode_ctags/licenses/libyaml/ReadMe.md @@ -0,0 +1,46 @@ +## LibYAML - A C library for parsing and emitting YAML. + +To build and install the library, run: + + $ ./configure + $ make + # make install + +Required packages: + +- gcc +- libtool +- make + +If you checked the source code from the Git repository, run + + $ ./bootstrap + $ ./configure + $ make + # make install + +Required packages: + +- autoconf +- libtool +- make + +For more information, check the [LibYAML +homepage](https://github.com/yaml/libyaml). + +Discuss LibYAML with the maintainers in IRC #libyaml irc.freenode.net. + +You may also use the [YAML-Core mailing +list](http://lists.sourceforge.net/lists/listinfo/yaml-core). + +Submit bug reports and feature requests to the [LibYAML bug +tracker](https://github.com/yaml/libyaml/issues/new). + +This project was developed for Python Software Foundation as a part of Google +Summer of Code under the mentorship of Clark Evans. + +The LibYAML module was written by Kirill Simonov . +It is currently maintained by the YAML community. + +LibYAML is released under the MIT license. +See the file LICENSE for more details. diff --git a/binary-analysis/scancode-ctags-macosx/src/scancode_ctags/licenses/pcre2/AUTHORS.md b/binary-analysis/scancode-ctags-macosx/src/scancode_ctags/licenses/pcre2/AUTHORS.md new file mode 100644 index 0000000..ced81e6 --- /dev/null +++ b/binary-analysis/scancode-ctags-macosx/src/scancode_ctags/licenses/pcre2/AUTHORS.md @@ -0,0 +1,208 @@ +PCRE2 Authorship and Contributors +================================= + +Copyright +--------- + +Please see the file [LICENCE](./LICENCE.md) in the PCRE2 distribution for +copyright details. + + +Maintainers +----------- + +The PCRE and PCRE2 libraries were authored and maintained by Philip Hazel. + +Since 2024, the contributors with administrator access to the project are now +Nicholas Wilson and Zoltán Herczeg. See the file [SECURITY](./SECURITY.md) for +GPG keys. + +Both administrators are volunteers acting in a personal capacity. + + + + + + + + + + + + + + + + + + +
NameRole
+ + Nicholas Wilson
+ `nicholas@nicholaswilson.me.uk`
+ Currently of Microsoft Research Cambridge, UK + +
+ + * General project administration & maintenance + * Release management + * Code maintenance + +
+ + Zoltán Herczeg
+ `hzmester@freemail.hu`
+ Currently of the University of Szeged, Hungary + +
+ + * Code maintenance + * Ownership of `sljit` and PCRE2's JIT + +
+ + +Contributors +------------ + +Many others have participated and contributed to PCRE2 over its history. + +The maintainers are grateful for all contributions and participation over the +years. We apologise for any names we have forgotten. + +We are especially grateful to Philip Hazel, creator of PCRE and PCRE2, and +maintainer from 1997 to 2024. + +All names listed alphabetically. + +### Contributors to PCRE2 + +This list includes names up until the PCRE2 10.47 release. New names will be +added from the Git history on each release. + + Scott Bell + Carlo Marcelo Arenas Belón + Edward Betts + Jan-Willem Blokland + Ross Burton + Dmitry Cherniachenko + Alexey Chupahin + Jessica Clarke + Alejandro Colomar + Jeremie Courreges-Anglas + Addison Crump + Alex Dowad + Daniel Engberg + Marco Feuerstein + Daniel Richard G + Isaac Oscar Gariano + David Gaussmann + Andrey Gorbachev + Jordan Griege + Jason Hood + Bumsu Hyeon + Roy Ivy + Nobuhiro Iwamatsu + Martin Joerg + Guillem Jover + Ralf Junker + Ayesh Karunaratne + Michael Kaufmann + Yunho Kim + Joshua Kinard + David Korczynski + Uwe Korn + Jonas Kvinge + Kristian Larsson + Kai Lu + Behzod Mansurov + B. Scott Michel + Greg Minshall + Nathan Moinvaziri + Mike Munday + Marc Mutz + Fabio Pagani + Christian Persch + Alex Reinking + Joshua Rogers + Tristan Ross + William A Rowe Jr + Rocco Ruscitti + David Seifert + Yaakov Selkowitz + Rich Siegel + Karl Skomski + Maciej Sroczyński + Wolfgang Stöggl + Thomas Tempelmann + Greg Thain + Lucas Trzesniewski + Theodore Tsirpanis + Aaron M. Ucko + Matthew Vernon + Rémi Verschelde + Thomas Voss + Ezekiel Warren + Carl Weaver + Chris Wilson + Amin Yahyaabadi + Joe Zhang + +### Contributors to PCRE1 + +These people contributed either by sending patches or reporting serious issues. + + Irfan Adilovic + Alexander Barkov + Daniel Bergström + David Burgess + Ross Burton + David Byron + Fred Cox + Christian Ehrlicher + Tom Fortmann + Lionel Fourquaux + Mike Frysinger + Daniel Richard G + Dair Gran + "Graycode" (Red Hat Product Security) + Viktor Griph + Wen Guanxing + Robin Houston + Martin Jerabek + Peter Kankowski + Stephen Kelly + Yunho Kim + Joshua Kinard + Carsten Klein + Evgeny Kotkov + Ronald Landheer-Cieslak + Alan Lehotsky + Dmitry V. Levin + Nuno Lopes + Kai Lu + Giuseppe Maxia + Dan Mooney + Marc Mutz + Markus Oberhumer + Sheri Pierce + Petr Pisar + Ari Pollak + Bob Rossi + Ruiger Rill + Michael Shigorin + Rich Siegel + Craig Silverstein (C++ wrapper) + Karl Skomski + Paul Sokolovsky + Stan Switzer + Ian Taylor + Mark Tetrode + Jeff Trawick + Steven Van Ingelgem + Lawrence Velazquez + Jiong Wang + Stefan Weber + Chris Wilson + +Thanks go to Jeffrey Friedl for testing and debugging assistance. diff --git a/binary-analysis/scancode-ctags-macosx/src/scancode_ctags/licenses/pcre2/COPYING b/binary-analysis/scancode-ctags-macosx/src/scancode_ctags/licenses/pcre2/COPYING new file mode 100644 index 0000000..c233950 --- /dev/null +++ b/binary-analysis/scancode-ctags-macosx/src/scancode_ctags/licenses/pcre2/COPYING @@ -0,0 +1,5 @@ +PCRE2 LICENCE + +Please see the file LICENCE in the PCRE2 distribution for licensing details. + +End diff --git a/binary-analysis/scancode-ctags-macosx/src/scancode_ctags/licenses/pcre2/INSTALL_RECEIPT.json b/binary-analysis/scancode-ctags-macosx/src/scancode_ctags/licenses/pcre2/INSTALL_RECEIPT.json new file mode 100644 index 0000000..30b253f --- /dev/null +++ b/binary-analysis/scancode-ctags-macosx/src/scancode_ctags/licenses/pcre2/INSTALL_RECEIPT.json @@ -0,0 +1,43 @@ +{ + "homebrew_version": "4.6.18-7-gbca9ba8", + "used_options": [], + "unused_options": [], + "built_as_bottle": true, + "poured_from_bottle": true, + "loaded_from_api": true, + "installed_as_dependency": true, + "installed_on_request": false, + "changed_files": [ + "bin/pcre2-config", + "lib/pkgconfig/libpcre2-16.pc", + "lib/pkgconfig/libpcre2-32.pc", + "lib/pkgconfig/libpcre2-8.pc", + "lib/pkgconfig/libpcre2-posix.pc" + ], + "time": 1767796276, + "source_modified_time": 1760960108, + "compiler": "clang", + "aliases": [], + "runtime_dependencies": [], + "source": { + "spec": "stable", + "versions": { + "stable": "10.47", + "head": null, + "version_scheme": 0, + "compatibility_version": null + }, + "path": "/Users/van/Library/Caches/Homebrew/api/formula.jws.json", + "tap_git_head": "9a7c8abebc88f7eac4be163547e90ceba1f93241", + "tap": "homebrew/core" + }, + "arch": "arm64", + "built_on": { + "os": "Macintosh", + "os_version": "macOS 26", + "cpu_family": "dunno", + "xcode": "26.0", + "clt": "26.0.0.0.1.1756965055", + "preferred_perl": "5.34" + } +} \ No newline at end of file diff --git a/binary-analysis/scancode-ctags-macosx/src/scancode_ctags/licenses/pcre2/README b/binary-analysis/scancode-ctags-macosx/src/scancode_ctags/licenses/pcre2/README new file mode 100644 index 0000000..593bab2 --- /dev/null +++ b/binary-analysis/scancode-ctags-macosx/src/scancode_ctags/licenses/pcre2/README @@ -0,0 +1,1005 @@ +README file for PCRE2 (Perl-compatible regular expression library) +================================================================== + +PCRE2 is a re-working of the original PCRE1 library to provide an entirely new +API. Since its initial release in 2015, there has been further development of +the code and it now differs from PCRE1 in more than just the API. There are new +features, and the internals have been improved. The original PCRE1 library is +now obsolete and no longer maintained. The latest release of PCRE2 is available +in .tar.gz, tar.bz2, or .zip form from this GitHub repository: + +https://github.com/PCRE2Project/pcre2/releases + +There is a mailing list for discussion about the development of PCRE2 at +pcre2-dev@googlegroups.com. You can subscribe by sending an email to +pcre2-dev+subscribe@googlegroups.com. + +You can access the archives and also subscribe or manage your subscription +here: + +https://groups.google.com/g/pcre2-dev + +Please read the NEWS file if you are upgrading from a previous release. The +contents of this README file are: + + The PCRE2 APIs + Documentation for PCRE2 + Building PCRE2 on non-Unix-like systems + Building PCRE2 without using autotools + Building PCRE2 using autotools + Retrieving configuration information + Shared libraries + Cross-compiling using autotools + Making new tarballs + Testing PCRE2 + Character tables + File manifest + + +The PCRE2 APIs +-------------- + +PCRE2 is written in C, and it has its own API. There are three sets of +functions, one for the 8-bit library, which processes strings of bytes, one for +the 16-bit library, which processes strings of 16-bit values, and one for the +32-bit library, which processes strings of 32-bit values. Unlike PCRE1, there +are no C++ wrappers. + +The distribution does contain a set of C wrapper functions for the 8-bit +library that are based on the POSIX regular expression API (see the pcre2posix +man page). These are built into a library called libpcre2-posix. Note that this +just provides a POSIX calling interface to PCRE2; the regular expressions +themselves still follow Perl syntax and semantics. The POSIX API is restricted, +and does not give full access to all of PCRE2's facilities. + +The header file for the POSIX-style functions is called pcre2posix.h. The +official POSIX name is regex.h, but I did not want to risk possible problems +with existing files of that name by distributing it that way. To use PCRE2 with +an existing program that uses the POSIX API, pcre2posix.h will have to be +renamed or pointed at by a link (or the program modified, of course). See the +pcre2posix documentation for more details. + + +Documentation for PCRE2 +----------------------- + +If you install PCRE2 in the normal way on a Unix-like system, you will end up +with a set of man pages whose names all start with "pcre2". The one that is +just called "pcre2" lists all the others. In addition to these man pages, the +PCRE2 documentation is supplied in two other forms: + + 1. There are files called doc/pcre2.txt, doc/pcre2grep.txt, and + doc/pcre2test.txt in the source distribution. The first of these is a + concatenation of the text forms of all the section 3 man pages except the + listing of pcre2demo.c and those that summarize individual functions. The + other two are the text forms of the section 1 man pages for the pcre2grep + and pcre2test commands. These text forms are provided for ease of scanning + with text editors or similar tools. They are installed in + /share/doc/pcre2, where is the installation prefix + (defaulting to /usr/local). + + 2. A set of files containing all the documentation in HTML form, hyperlinked + in various ways, and rooted in a file called index.html, is distributed in + doc/html and installed in /share/doc/pcre2/html. + + +Building PCRE2 on non-Unix-like systems +--------------------------------------- + +For a non-Unix-like system, please read the file NON-AUTOTOOLS-BUILD, though if +your system supports the use of "configure" and "make" you may be able to build +PCRE2 using autotools in the same way as for many Unix-like systems. This file +also contains useful information on building for some unusual Unix environments +(such as EBCDIC mainframes). + +PCRE2 can also be configured using CMake, which can be run in various ways +(command line, GUI, etc). This creates Makefiles, solution files, etc. The file +NON-AUTOTOOLS-BUILD has information about CMake. + +PCRE2 has been compiled on many different operating systems. It should be +straightforward to build PCRE2 on any system that has a C99 or later compiler +and library. + + +Building PCRE2 without using autotools +-------------------------------------- + +The use of autotools (in particular, libtool) is problematic in some +environments, even some that are Unix or Unix-like. See the NON-AUTOTOOLS-BUILD +file for ways of building PCRE2 without using autotools. + + +Building PCRE2 using autotools +------------------------------ + +The following instructions assume the use of the widely used "configure; make; +make install" (autotools) process. + +If you have downloaded and unpacked a PCRE2 release tarball, run the +"configure" command from the PCRE2 directory, with your current directory set +to the directory where you want the files to be created. This command is a +standard GNU "autoconf" configuration script, for which generic instructions +are supplied in the file INSTALL. + +The files in the GitHub repository do not contain "configure". If you have +downloaded the PCRE2 source files from GitHub, before you can run "configure" +you must run the shell script called autogen.sh. This runs a number of +autotools to create a "configure" script (you must of course have the autotools +commands installed in order to do this). + +Most commonly, people build PCRE2 within its own distribution directory, and in +this case, on many systems, just running "./configure" is sufficient. However, +the usual methods of changing standard defaults are available. For example: + +CFLAGS='-O2 -Wall' ./configure --prefix=/opt/local + +This command specifies that the C compiler should be run with the flags '-O2 +-Wall' instead of the default, and that "make install" should install PCRE2 +under /opt/local instead of the default /usr/local. + +If you want to build in a different directory, just run "configure" with that +directory as current. For example, suppose you have unpacked the PCRE2 source +into /source/pcre2/pcre2-xxx, but you want to build it in +/build/pcre2/pcre2-xxx: + +cd /build/pcre2/pcre2-xxx +/source/pcre2/pcre2-xxx/configure + +PCRE2 is written in C and is normally compiled as a C library. However, it is +possible to build it as a C++ library, though the provided building apparatus +does not have any features to support this. + +There are some optional features that can be included or omitted from the PCRE2 +library. They are also documented in the pcre2build man page. + +. By default, both shared and static libraries are built. You can change this + by adding one of these options to the "configure" command: + + --disable-shared + --disable-static + + Setting --disable-shared ensures that PCRE2 libraries are built as static + libraries. The binaries that are then created as part of the build process + (for example, pcre2test and pcre2grep) are linked statically with one or more + PCRE2 libraries, but may also be dynamically linked with other libraries such + as libc. If you want these binaries to be fully statically linked, you can + set LDFLAGS like this: + + LDFLAGS=--static ./configure --disable-shared + + Note the two hyphens in --static. Of course, this works only if static + versions of all the relevant libraries are available for linking. See also + "Shared libraries" below. + + Shared libraries are compiled with symbol versioning enabled on platforms that + support this, but this can be disabled by adding --disable-symvers. + +. By default, only the 8-bit library is built. If you add --enable-pcre2-16 to + the "configure" command, the 16-bit library is also built. If you add + --enable-pcre2-32 to the "configure" command, the 32-bit library is also + built. If you want only the 16-bit or 32-bit library, use --disable-pcre2-8 + to disable building the 8-bit library. + +. If you want to include support for just-in-time (JIT) compiling, which can + give large performance improvements on certain platforms, add --enable-jit to + the "configure" command. This support is available only for certain hardware + architectures. If you try to enable it on an unsupported architecture, there + will be a compile time error. If in doubt, use --enable-jit=auto, which + enables JIT only if the current hardware is supported. + +. If you are enabling JIT under SELinux environment you may also want to add + --enable-jit-sealloc, which enables the use of an executable memory allocator + that is compatible with SELinux. Warning: this allocator is experimental! + It does not support fork() operation and may crash when no disk space is + available. This option has no effect if JIT is disabled. + +. If you do not want to make use of the default support for UTF-8 Unicode + character strings in the 8-bit library, UTF-16 Unicode character strings in + the 16-bit library, or UTF-32 Unicode character strings in the 32-bit + library, you can add --disable-unicode to the "configure" command. This + reduces the size of the libraries. It is not possible to configure one + library with Unicode support, and another without, in the same configuration. + It is also not possible to use --enable-ebcdic (see below) with Unicode + support, so if this option is set, you must also use --disable-unicode. + + When Unicode support is available, the use of a UTF encoding still has to be + enabled by setting the PCRE2_UTF option at run time or starting a pattern + with (*UTF). When PCRE2 is compiled with Unicode support, its input can only + either be ASCII or UTF-8/16/32, even when running on EBCDIC platforms. + + As well as supporting UTF strings, Unicode support includes support for the + \P, \p, and \X sequences that recognize Unicode character properties. + However, only a subset of Unicode properties are supported; see the + pcre2pattern man page for details. Escape sequences such as \d and \w in + patterns do not by default make use of Unicode properties, but can be made to + do so by setting the PCRE2_UCP option or starting a pattern with (*UCP). + +. You can build PCRE2 to recognize either CR or LF or the sequence CRLF, or any + of the preceding, or any of the Unicode newline sequences, or the NUL (zero) + character as indicating the end of a line. Whatever you specify at build time + is the default; the caller of PCRE2 can change the selection at run time. The + default newline indicator is a single LF character (the Unix standard). You + can specify the default newline indicator by adding --enable-newline-is-cr, + --enable-newline-is-lf, --enable-newline-is-crlf, + --enable-newline-is-anycrlf, --enable-newline-is-any, or + --enable-newline-is-nul to the "configure" command, respectively. + +. By default, the sequence \R in a pattern matches any Unicode line ending + sequence. This is independent of the option specifying what PCRE2 considers + to be the end of a line (see above). However, the caller of PCRE2 can + restrict \R to match only CR, LF, or CRLF. You can make this the default by + adding --enable-bsr-anycrlf to the "configure" command (bsr = "backslash R"). + +. In a pattern, the escape sequence \C matches a single code unit, even in a + UTF mode. This can be dangerous because it breaks up multi-code-unit + characters. You can build PCRE2 with the use of \C permanently locked out by + adding --enable-never-backslash-C (note the upper case C) to the "configure" + command. When \C is allowed by the library, individual applications can lock + it out by calling pcre2_compile() with the PCRE2_NEVER_BACKSLASH_C option. + +. PCRE2 has a counter that limits the depth of nesting of parentheses in a + pattern. This limits the amount of system stack that a pattern uses when it + is compiled. The default is 250, but you can change it by setting, for + example, + + --with-parens-nest-limit=500 + +. PCRE2 has a counter that can be set to limit the amount of computing resource + it uses when matching a pattern. If the limit is exceeded during a match, the + match fails. The default is ten million. You can change the default by + setting, for example, + + --with-match-limit=500000 + + on the "configure" command. This is just the default; individual calls to + pcre2_match() or pcre2_dfa_match() can supply their own value. There is more + discussion in the pcre2api man page (search for pcre2_set_match_limit). + +. There is a separate counter that limits the depth of nested backtracking + (pcre2_match()) or nested function calls (pcre2_dfa_match()) during a + matching process, which indirectly limits the amount of heap memory that is + used, and in the case of pcre2_dfa_match() the amount of stack as well. This + counter also has a default of ten million, which is essentially "unlimited". + You can change the default by setting, for example, + + --with-match-limit-depth=5000 + + There is more discussion in the pcre2api man page (search for + pcre2_set_depth_limit). + +. You can also set an explicit limit on the amount of heap memory used by + the pcre2_match() and pcre2_dfa_match() interpreters: + + --with-heap-limit=500 + + The units are kibibytes (units of 1024 bytes). This limit does not apply when + the JIT optimization (which has its own memory control features) is used. + There is more discussion on the pcre2api man page (search for + pcre2_set_heap_limit). + +. In the 8-bit library, the default maximum compiled pattern size is around + 64 kibibytes. You can increase this by adding --with-link-size=3 to the + "configure" command. PCRE2 then uses three bytes instead of two for offsets + to different parts of the compiled pattern. In the 16-bit library, + --with-link-size=3 is the same as --with-link-size=4, which (in both + libraries) uses four-byte offsets. Increasing the internal link size reduces + performance in the 8-bit and 16-bit libraries. In the 32-bit library, the + link size setting is ignored, as 4-byte offsets are always used. + +. Lookbehind assertions in which one or more branches can match a variable + number of characters are supported only if there is a maximum matching length + for each top-level branch. There is a limit to this maximum that defaults to + 255 characters. You can alter this default by a setting such as + + --with-max-varlookbehind=100 + + The limit can be changed at runtime by calling pcre2_set_max_varlookbehind(). + Lookbehind assertions in which every branch matches a fixed number of + characters (not necessarily all the same) are not constrained by this limit. + +. For speed, PCRE2 uses four tables for manipulating and identifying characters + whose code point values are less than 256. By default, it uses a set of + tables for ASCII encoding that is part of the distribution. If you specify + + --enable-rebuild-chartables + + a program called pcre2_dftables is compiled and run in the default C locale + when you obey "make". It builds a source file called pcre2_chartables.c. If + you do not specify this option, pcre2_chartables.c is created as a copy of + pcre2_chartables.c.dist. See "Character tables" below for further + information. + +. It is possible to compile PCRE2 for use on systems that use EBCDIC as their + character code (as opposed to ASCII/Unicode) by specifying + + --enable-ebcdic --disable-unicode + + This automatically implies --enable-rebuild-chartables (see above), in order + to ensure that you have the correct default character tables for your system's + codepage. There is an exception when you set --enable-ebcdic-ignoring-compiler + (see below), which allows using a default set of EBCDIC 1047 character tables + rather than forcing use of --enable-rebuild-chartables. + + When PCRE2 is built with EBCDIC support, it always operates in EBCDIC. It + cannot support both EBCDIC and ASCII or UTF-8/16/32. + + There is a second option, --enable-ebcdic-nl25, which specifies that the code + value for the EBCDIC NL character is 0x25 instead of the default 0x15. + + There is a third option, --enable-ebcdic-ignoring-compiler, which disregards + the compiler's codepage for determining the numeric value of C character + constants such as 'z', and instead forces PCRE2 to use numeric constants for + the EBCDIC 1047 codepage instead. + +. If you specify --enable-debug, additional debugging code is included in the + build. This option is intended for use by the PCRE2 maintainers. + +. In environments where valgrind is installed, if you specify + + --enable-valgrind + + PCRE2 will use valgrind annotations to mark certain memory regions as + unaddressable. This allows it to detect invalid memory accesses, and is + mostly useful for debugging PCRE2 itself. + +. In environments where the gcc compiler is used and lcov is installed, if you + specify + + --enable-coverage + + the build process implements a code coverage report for the test suite. The + report is generated by running "make coverage". If ccache is installed on + your system, it must be disabled when building PCRE2 for coverage reporting. + You can do this by setting the environment variable CCACHE_DISABLE=1 before + running "make" to build PCRE2. There is more information about coverage + reporting in the "pcre2build" documentation. + +. When JIT support is enabled, pcre2grep automatically makes use of it, unless + you add --disable-pcre2grep-jit to the "configure" command. + +. There is support for calling external programs during matching in the + pcre2grep command, using PCRE2's callout facility with string arguments. This + support can be disabled by adding --disable-pcre2grep-callout to the + "configure" command. There are two kinds of callout: one that generates + output from inbuilt code, and another that calls an external program. The + latter has special support for Windows and VMS; otherwise it assumes the + existence of the fork() function. This facility can be disabled by adding + --disable-pcre2grep-callout-fork to the "configure" command. + +. The pcre2grep program currently supports only 8-bit data files, and so + requires the 8-bit PCRE2 library. It is possible to compile pcre2grep to use + libz and/or libbz2, in order to read .gz and .bz2 files (respectively), by + specifying one or both of + + --enable-pcre2grep-libz + --enable-pcre2grep-libbz2 + + Of course, the relevant libraries must be installed on your system. + +. The default starting size (in bytes) of the internal buffer used by pcre2grep + can be set by, for example: + + --with-pcre2grep-bufsize=51200 + + The value must be a plain integer. The default is 20480. The amount of memory + used by pcre2grep is actually three times this number, to allow for "before" + and "after" lines. If very long lines are encountered, the buffer is + automatically enlarged, up to a fixed maximum size. + +. The default maximum size of pcre2grep's internal buffer can be set by, for + example: + + --with-pcre2grep-max-bufsize=2097152 + + The default is either 1048576 or the value of --with-pcre2grep-bufsize, + whichever is the larger. + +. It is possible to compile pcre2test so that it links with the libreadline + or libedit libraries, by specifying, respectively, + + --enable-pcre2test-libreadline or --enable-pcre2test-libedit + + If this is done, when pcre2test's input is from a terminal, it reads it using + the readline() function. This provides line-editing and history facilities. + Note that libreadline is GPL-licensed, so if you distribute a binary of + pcre2test linked in this way, there may be licensing issues. These can be + avoided by linking with libedit (which has a BSD licence) instead. + + Enabling libreadline causes the -lreadline option to be added to the + pcre2test build. In many operating environments with a system-installed + readline library this is sufficient. However, in some environments (e.g. if + an unmodified distribution version of readline is in use), it may be + necessary to specify something like LIBS="-lncurses" as well. This is + because, to quote the readline INSTALL, "Readline uses the termcap functions, + but does not link with the termcap or curses library itself, allowing + applications which link with readline the option to choose an appropriate + library." If you get error messages about missing functions tgetstr, tgetent, + tputs, tgetflag, or tgoto, this is the problem, and linking with the ncurses + library should fix it. + +. The C99 standard defines formatting modifiers z and t for size_t and + ptrdiff_t values, respectively. By default, PCRE2 uses these modifiers in + environments other than Microsoft Visual Studio versions earlier than 2013 + when __STDC_VERSION__ is defined and has a value greater than or equal to + 199901L (indicating C99). However, there is at least one environment that + claims to be C99 but does not support these modifiers. If + --disable-percent-zt is specified, no use is made of the z or t modifiers. + Instead of %td or %zu, %lu is used, with a cast for size_t values. + +. There is a special option called --enable-fuzz-support for use by people who + want to run fuzzing tests on PCRE2. If set, it causes an extra library + called libpcre2-fuzzsupport.a to be built, but not installed. This contains + a single function called LLVMFuzzerTestOneInput() whose arguments are a + pointer to a string and the length of the string. When called, this function + tries to compile the string as a pattern, and if that succeeds, to match + it. This is done both with no options and with some random options bits that + are generated from the string. Setting --enable-fuzz-support also causes an + executable called pcre2fuzzcheck-{8,16,32} to be created. This is normally + run under valgrind or used when PCRE2 is compiled with address sanitizing + enabled. It calls the fuzzing function and outputs information about what it + is doing. The input strings are specified by arguments: if an argument + starts with "=" the rest of it is a literal input string. Otherwise, it is + assumed to be a file name, and the contents of the file are the test string. + +. Releases before 10.30 could be compiled with --disable-stack-for-recursion, + which caused pcre2_match() to use individual blocks on the heap for + backtracking instead of recursive function calls (which use the stack). This + is now obsolete because pcre2_match() was refactored always to use the heap + (in a much more efficient way than before). This option is retained for + backwards compatibility, but has no effect other than to output a warning. + +The "configure" script builds the following files for the basic C library: + +. Makefile the makefile that builds the library +. src/config.h build-time configuration options for the library +. src/pcre2.h the public PCRE2 header file +. pcre2-config script that shows the building settings such as CFLAGS + that were set for "configure" +. libpcre2-8.pc ) +. libpcre2-16.pc ) data for the pkg-config command +. libpcre2-32.pc ) +. libpcre2-posix.pc ) +. libtool script that builds shared and/or static libraries + +Versions of config.h and pcre2.h are distributed in the src directory of PCRE2 +tarballs under the names config.h.generic and pcre2.h.generic. These are +provided for those who have to build PCRE2 without using "configure" or CMake. +If you use "configure" or CMake, the .generic versions are not used. + +The "configure" script also creates config.status, which is an executable +script that can be run to recreate the configuration, and config.log, which +contains compiler output from tests that "configure" runs. + +Once "configure" has run, you can run "make". This builds whichever of the +libraries libpcre2-8, libpcre2-16 and libpcre2-32 are configured, and a test +program called pcre2test. If you enabled JIT support with --enable-jit, another +test program called pcre2_jit_test is built as well. If the 8-bit library is +built, libpcre2-posix, pcre2posix_test, and the pcre2grep command are also +built. Running "make" with the -j option may speed up compilation on +multiprocessor systems. + +The command "make check" runs all the appropriate tests. Details of the PCRE2 +tests are given below in a separate section of this document. The -j option of +"make" can also be used when running the tests. + +You can use "make install" to install PCRE2 into live directories on your +system. The following are installed (file names are all relative to the + that is set when "configure" is run): + + Commands (bin): + pcre2test + pcre2grep (if 8-bit support is enabled) + pcre2-config + + Libraries (lib): + libpcre2-8 (if 8-bit support is enabled) + libpcre2-16 (if 16-bit support is enabled) + libpcre2-32 (if 32-bit support is enabled) + libpcre2-posix (if 8-bit support is enabled) + + Configuration information (lib/pkgconfig): + libpcre2-8.pc + libpcre2-16.pc + libpcre2-32.pc + libpcre2-posix.pc + + Header files (include): + pcre2.h + pcre2posix.h + + Man pages (share/man/man{1,3}): + pcre2grep.1 + pcre2test.1 + pcre2-config.1 + pcre2.3 + pcre2*.3 (lots more pages, all starting "pcre2") + + HTML documentation (share/doc/pcre2/html): + index.html + *.html (lots more pages, hyperlinked from index.html) + + Text file documentation (share/doc/pcre2): + AUTHORS + COPYING + ChangeLog + LICENCE + NEWS + README + SECURITY + pcre2.txt (a concatenation of the man(3) pages) + pcre2test.txt the pcre2test man page + pcre2grep.txt the pcre2grep man page + pcre2-config.txt the pcre2-config man page + +If you want to remove PCRE2 from your system, you can run "make uninstall". +This removes all the files that "make install" installed. However, it does not +remove any directories, because these are often shared with other programs. + + +Retrieving configuration information +------------------------------------ + +Running "make install" installs the command pcre2-config, which can be used to +recall information about the PCRE2 configuration and installation. For example: + + pcre2-config --version + +prints the version number, and + + pcre2-config --libs8 + +outputs information about where the 8-bit library is installed. This command +can be included in makefiles for programs that use PCRE2, saving the programmer +from having to remember too many details. Run pcre2-config with no arguments to +obtain a list of possible arguments. + +The pkg-config command is another system for saving and retrieving information +about installed libraries. Instead of separate commands for each library, a +single command is used. For example: + + pkg-config --libs libpcre2-16 + +The data is held in *.pc files that are installed in a directory called +/lib/pkgconfig. + + +Shared libraries +---------------- + +The default distribution builds PCRE2 as shared libraries and static libraries, +as long as the operating system supports shared libraries. Shared library +support relies on the "libtool" script which is built as part of the +"configure" process. + +The libtool script is used to compile and link both shared and static +libraries. They are placed in a subdirectory called .libs when they are newly +built. The programs pcre2test and pcre2grep are built to use these uninstalled +libraries (by means of wrapper scripts in the case of shared libraries). When +you use "make install" to install shared libraries, pcre2grep and pcre2test are +automatically re-built to use the newly installed shared libraries before being +installed themselves. However, the versions left in the build directory still +use the uninstalled libraries. + +To build PCRE2 using static libraries only you must use --disable-shared when +configuring it. For example: + +./configure --prefix=/usr/gnu --disable-shared + +Then run "make" in the usual way. Similarly, you can use --disable-static to +build only shared libraries. Note, however, that when you build only static +libraries, binary programs such as pcre2test and pcre2grep may still be +dynamically linked with other libraries (for example, libc) unless you set +LDFLAGS to --static when running "configure". + + +Cross-compiling using autotools +------------------------------- + +You can specify CC and CFLAGS in the normal way to the "configure" command, in +order to cross-compile PCRE2 for some other host. However, you should NOT +specify --enable-rebuild-chartables, because if you do, the pcre2_dftables.c +source file is compiled and run on the local host, in order to generate the +inbuilt character tables (the pcre2_chartables.c file). This will probably not +work, because pcre2_dftables.c needs to be compiled with the local compiler, +not the cross compiler. + +When --enable-rebuild-chartables is not specified, pcre2_chartables.c is +created by making a copy of pcre2_chartables.c.dist, which is a default set of +tables that assumes ASCII code. Cross-compiling with the default tables should +not be a problem. + +If you need to modify the character tables when cross-compiling, you should +move pcre2_chartables.c.dist out of the way, then compile pcre2_dftables.c by +hand and run it on the local host to make a new version of +pcre2_chartables.c.dist. See the pcre2build section "Creating character tables +at build time" for more details. + + +Making new tarballs +------------------- + +The command "make dist" creates three PCRE2 tarballs, in tar.gz, tar.bz2, and +zip formats. The command "make distcheck" does the same, but then does a trial +build of the new distribution to ensure that it works. + +If you have modified any of the man page sources in the doc directory, you +should first run the maint/UpdateAlways script before making a distribution. +This script creates the .txt and HTML forms of the documentation from the man +pages. + + +Testing PCRE2 +------------- + +To test the basic PCRE2 library on a Unix-like system, run the RunTest script. +There is another script called RunGrepTest that tests the pcre2grep command. +When the 8-bit library is built, a test program for the POSIX wrapper, called +pcre2posix_test, is compiled, and when JIT support is enabled, a test program +called pcre2_jit_test is built. The scripts and the program tests are all run +when you obey "make check". For other environments, see the instructions in +NON-AUTOTOOLS-BUILD. + +The RunTest script runs the pcre2test test program (which is documented in its +own man page) on each of the relevant testinput files in the testdata +directory, and compares the output with the contents of the corresponding +testoutput files. RunTest places its output in directories +testoutput{8,16,32}{,-jit,-dfa}. Other files whose names begin with "test" are +used as working files in some tests. + +Some tests are relevant only when certain build-time options were selected. For +example, the tests for UTF-8/16/32 features are run only when Unicode support +is available. RunTest outputs a comment when it skips a test. + +Many (but not all) of the tests that are not skipped are run twice if JIT +support is available. On the second run, JIT compilation is forced. This +testing can be suppressed by putting "-nojit" on the RunTest command line. + +The entire set of tests is run once for each of the 8-bit, 16-bit and 32-bit +libraries that are enabled. If you want to run just one set of tests, call +RunTest with either the -8, -16 or -32 option. + +If valgrind is installed, you can run the tests under it by putting "-valgrind" +on the RunTest command line. To run pcre2test on just one or more specific test +files, give their numbers as arguments to RunTest, for example: + + RunTest 2 7 11 + +You can also specify ranges of tests such as 3-6 or 3- (meaning 3 to the +end), or a number preceded by ~ to exclude a test. For example: + + Runtest 3-15 ~10 + +This runs tests 3 to 15, excluding test 10, and just ~13 runs all the tests +except test 13. Whatever order the arguments are in, the tests are always run +in numerical order. + +You can also call RunTest with the single argument "list" to cause it to output +a list of tests. + +The test sequence starts with "test 0", which is a special test that has no +input file, and whose output is not checked. This is because it will be +different on different hardware and with different configurations. The test +exists in order to exercise some of pcre2test's code that would not otherwise +be run. + +Tests 1 and 2 can always be run, as they expect only plain text strings (not +UTF) and make no use of Unicode properties. The first test file can be fed +directly into the perltest.sh script to check that Perl gives the same results. +The only difference you should see is in the first few lines, where the Perl +version is given instead of the PCRE2 version. The second set of tests check +auxiliary functions, error detection, and run-time flags that are specific to +PCRE2. It also uses the debugging flags to check some of the internals of +pcre2_compile(). + +If you build PCRE2 with a locale setting that is not the standard C locale, the +character tables may be different (see next paragraph). In some cases, this may +cause failures in the second set of tests. For example, in a locale where the +isprint() function yields TRUE for characters in the range 128-255, the use of +[:isascii:] inside a character class defines a different set of characters, and +this shows up in this test as a difference in the compiled code, which is being +listed for checking. For example, where the comparison test output contains +[\x00-\x7f] the test might contain [\x00-\xff], and similarly in some other +cases. This is not a bug in PCRE2. + +Test 3 checks pcre2_maketables(), the facility for building a set of character +tables for a specific locale and using them instead of the default tables. The +script uses the "locale" command to check for the availability of the "fr_FR", +"french", or "fr" locale, and uses the first one that it finds. If the "locale" +command fails, or if its output doesn't include "fr_FR", "french", or "fr" in +the list of available locales, the third test cannot be run, and a comment is +output to say why. If running this test produces an error like this: + + ** Failed to set locale "fr_FR" + +it means that the given locale is not available on your system, despite being +listed by "locale". This does not mean that PCRE2 is broken. There are three +alternative output files for the third test, because three different versions +of the French locale have been encountered. The test passes if its output +matches any one of them. + +Tests 4 and 5 check UTF and Unicode property support, test 4 being compatible +with the perltest.sh script, and test 5 checking PCRE2-specific things. + +Tests 6 and 7 check the pcre2_dfa_match() alternative matching function, in +non-UTF mode and UTF-mode with Unicode property support, respectively. + +Test 8 checks some internal offsets and code size features, but it is run only +when Unicode support is enabled. The output is different in 8-bit, 16-bit, and +32-bit modes and for different link sizes, so there are different output files +for each mode and link size. + +Tests 9 and 10 are run only in 8-bit mode, and tests 11 and 12 are run only in +16-bit and 32-bit modes. These are tests that generate different output in +8-bit mode. Each pair are for general cases and Unicode support, respectively. + +Test 13 checks the handling of non-UTF characters greater than 255 by +pcre2_dfa_match() in 16-bit and 32-bit modes. + +Test 14 contains some special UTF and UCP tests that give different output for +different code unit widths. + +Test 15 contains a number of tests that must not be run with JIT. They check, +among other non-JIT things, the match-limiting features of the interpretive +matcher. + +Test 16 is run only when JIT support is not available. It checks that an +attempt to use JIT has the expected behaviour. + +Test 17 is run only when JIT support is available. It checks JIT complete and +partial modes, match-limiting under JIT, and other JIT-specific features. + +Tests 18 and 19 are run only in 8-bit mode. They check the POSIX interface to +the 8-bit library, without and with Unicode support, respectively. + +Test 20 checks the serialization functions by writing a set of compiled +patterns to a file, and then reloading and checking them. + +Tests 21 and 22 test \C support when the use of \C is not locked out, without +and with UTF support, respectively. Test 23 tests \C when it is locked out. + +Tests 24 and 25 test the experimental pattern conversion functions, without and +with UTF support, respectively. + +Test 26 checks Unicode property support using tests that were generated +automatically from the Unicode data tables. These are the archived version of +the tests from Unicode 15. + +Test 27 checks Unicode property support using tests that are generated +automatically from the currently-used Unicode data tables. + +Test 28 tests EBCDIC support, and is only run when PCRE2 is specifically +compiled for EBCDIC. Test 29 tests EBCDIC when NL has been configured to be +0x25. + + +Character tables +---------------- + +For speed, PCRE2 uses four tables for manipulating and identifying characters +whose code point values are less than 256. By default, a set of tables that is +built into the library is used. The pcre2_maketables() function can be called +by an application to create a new set of tables in the current locale. This are +passed to PCRE2 by calling pcre2_set_character_tables() to put a pointer into a +compile context. + +The source file called pcre2_chartables.c contains the default set of tables. +By default, this is created as a copy of pcre2_chartables.c.dist, which +contains tables for ASCII coding. However, if --enable-rebuild-chartables is +specified for ./configure, a new version of pcre2_chartables.c is built by the +program pcre2_dftables (compiled from pcre2_dftables.c), which uses the ANSI C +character handling functions such as isalnum(), isalpha(), isupper(), +islower(), etc. to build the table sources. This means that the default C +locale that is set for your system will control the contents of these default +tables. You can change the default tables by editing pcre2_chartables.c and +then re-building PCRE2. If you do this, you should take care to ensure that the +file does not get automatically re-generated. The best way to do this is to +move pcre2_chartables.c.dist out of the way and replace it with your customized +tables. + +When the pcre2_dftables program is run as a result of specifying +--enable-rebuild-chartables, it uses the default C locale that is set on your +system. It does not pay attention to the LC_xxx environment variables. In other +words, it uses the system's default locale rather than whatever the compiling +user happens to have set. If you really do want to build a source set of +character tables in a locale that is specified by the LC_xxx variables, you can +run the pcre2_dftables program by hand with the -L option. For example: + + ./pcre2_dftables -L pcre2_chartables.c.special + +The second argument names the file where the source code for the tables is +written. The first two 256-byte tables provide lower casing and case flipping +functions, respectively. The next table consists of a number of 32-byte bit +maps which identify certain character classes such as digits, "word" +characters, white space, etc. These are used when building 32-byte bit maps +that represent character classes for code points less than 256. The final +256-byte table has bits indicating various character types, as follows: + + 1 white space character + 2 letter + 4 lower case letter + 8 decimal digit + 16 alphanumeric or '_' + +You can also specify -b (with or without -L) when running pcre2_dftables. This +causes the tables to be written in binary instead of as source code. A set of +binary tables can be loaded into memory by an application and passed to +pcre2_compile() in the same way as tables created dynamically by calling +pcre2_maketables(). The tables are just a string of bytes, independent of +hardware characteristics such as endianness. This means they can be bundled +with an application that runs in different environments, to ensure consistent +behaviour. + +See also the pcre2build section "Creating character tables at build time". + + +File manifest +------------- + +The distribution should contain the files listed below. + +(A) Source files for the PCRE2 library functions and their headers are found in + the src directory: + + src/pcre2_dftables.c auxiliary program for building pcre2_chartables.c + when --enable-rebuild-chartables is specified + + src/pcre2_chartables.c.dist a default set of character tables that assume + ASCII coding; unless --enable-rebuild-chartables is + specified, used by copying to pcre2_chartables.c + src/pcre2_chartables.c.ebcdic-1047-{nl15,nl25} a default set of character + tables for EBCDIC 1047; used if + --enable-ebcdic-ignoring-compiler is specified + without --enable-rebuild-chartables + + src/pcre2posix.c ) + src/pcre2_auto_possess.c ) + src/pcre2_chkdint.c ) + src/pcre2_compile.c ) + src/pcre2_compile_cgroup.c ) + src/pcre2_compile_class.c ) + src/pcre2_config.c ) + src/pcre2_context.c ) + src/pcre2_convert.c ) + src/pcre2_dfa_match.c ) + src/pcre2_error.c ) + src/pcre2_extuni.c ) + src/pcre2_find_bracket.c ) + src/pcre2_jit_compile.c ) + src/pcre2_maketables.c ) sources for the functions in the library, + src/pcre2_match.c ) and some internal functions that they use + src/pcre2_match_data.c ) + src/pcre2_match_next.c ) + src/pcre2_newline.c ) + src/pcre2_ord2utf.c ) + src/pcre2_pattern_info.c ) + src/pcre2_script_run.c ) + src/pcre2_serialize.c ) + src/pcre2_string_utils.c ) + src/pcre2_study.c ) + src/pcre2_substitute.c ) + src/pcre2_substring.c ) + src/pcre2_tables.c ) + src/pcre2_ucd.c ) + src/pcre2_valid_utf.c ) + src/pcre2_xclass.c ) + + src/pcre2_fuzzsupport.c function for (optional) fuzzing support + + src/config.h.in template for config.h, when built by "configure" + src/pcre2.h.in template for pcre2.h when built by "configure" + src/pcre2posix.h header for the external POSIX wrapper API + src/pcre2_compile.h header for internal use + src/pcre2_internal.h header for internal use + src/pcre2_intmodedep.h a mode-specific internal header + src/pcre2_jit_char_inc.h header used by JIT + src/pcre2_jit_match_inc.h header used by JIT + src/pcre2_jit_misc_inc.h header used by JIT + src/pcre2_jit_simd_inc.h header used by JIT + src/pcre2_printint_inc.h debugging function that is used by pcre2test + src/pcre2_ucp.h header for Unicode property handling + src/pcre2_ucptables_inc.h header with Unicode data tables + src/pcre2_util.h header for internal utils + + deps/sljit/sljit_src/* source files for the JIT compiler + +(B) Source files for programs that use PCRE2: + + src/pcre2demo.c simple demonstration of coding calls to PCRE2 + src/pcre2grep.c source of a grep utility that uses PCRE2 + src/pcre2test.c comprehensive test program + src/pcre2test_inc.h header used by pcre2test + src/pcre2_jit_test.c JIT test program + src/pcre2posix_test.c POSIX wrapper API test program + +(C) Auxiliary files: + + AUTHORS.md information about the authors of PCRE2 + ChangeLog log of changes to the code + HACKING some notes about the internals of PCRE2 + INSTALL generic installation instructions + LICENCE.md conditions for the use of PCRE2 + COPYING the same, using GNU's standard name + SECURITY.md information on reporting vulnerabilities + Makefile.in ) template for Unix Makefile, which is built by + ) "configure" + Makefile.am ) the automake input that was used to create + ) Makefile.in + NEWS important changes in this release + NON-AUTOTOOLS-BUILD notes on building PCRE2 without using autotools + README this file + RunTest a Unix shell script for running tests + RunGrepTest a Unix shell script for pcre2grep tests + RunTest.bat a Windows batch file for running tests + RunGrepTest.bat a Windows batch file for pcre2grep tests + aclocal.m4 m4 macros (generated by "aclocal") + m4/* m4 macros (used by autoconf) + configure a configuring shell script (built by autoconf) + configure.ac ) the autoconf input that was used to build + ) "configure" and config.h + doc/*.3 man page sources for PCRE2 + doc/*.1 man page sources for pcre2grep and pcre2test + doc/html/* HTML documentation + doc/pcre2.txt plain text version of the man pages + doc/pcre2-config.txt plain text documentation of pcre2-config script + doc/pcre2grep.txt plain text documentation of grep utility program + doc/pcre2test.txt plain text documentation of test program + libpcre2-8.pc.in template for libpcre2-8.pc for pkg-config + libpcre2-16.pc.in template for libpcre2-16.pc for pkg-config + libpcre2-32.pc.in template for libpcre2-32.pc for pkg-config + libpcre2-posix.pc.in template for libpcre2-posix.pc for pkg-config + ar-lib ) + config.guess ) + config.sub ) + depcomp ) helper tools generated by libtool and + compile ) automake, used internally by ./configure + install-sh ) + ltmain.sh ) + missing ) + test-driver ) + perltest.sh Script for running a Perl test program + pcre2-config.in source of script which retains PCRE2 information + testdata/testinput* test data for main library tests + testdata/testoutput* expected test results + testdata/grep* input and output for pcre2grep tests + testdata/* other supporting test files + src/libpcre2-8.sym ) + src/libpcre2-16.sym ) symbol version scripts for the GNU and Sun linkers + src/libpcre2-32.sym ) + src/libpcre2-posix.sym ) + +(D) Auxiliary files for CMake support + + cmake/COPYING-CMAKE-SCRIPTS + cmake/FindEditline.cmake + cmake/FindReadline.cmake + cmake/pcre2-config.cmake.in + cmake/PCRE2CheckVscript.cmake + cmake/PCRE2UseSystemExtensions.cmake + cmake/PCRE2WarningAsError.cmake + src/config-cmake.h.in + CMakeLists.txt + +(E) Auxiliary files for building PCRE2 "by hand" + + src/pcre2.h.generic ) a version of the public PCRE2 header file + ) for use in non-"configure" environments + src/config.h.generic ) a version of config.h for use in non-"configure" + ) environments + +(F) Auxiliary files for building PCRE2 using other build systems + + BUILD.bazel ) files used by the Bazel + MODULE.bazel ) build system + build.zig file used by zig's build system + +(G) Auxiliary files for building PCRE2 under OpenVMS + + vms/configure.com ) + vms/openvms_readme.txt ) These files were contributed by a PCRE2 user. + vms/pcre2.h_patch ) + vms/stdint.h ) + +============================= +Last updated: 15 October 2025 +============================= + diff --git a/binary-analysis/scancode-ctags-macosx/src/scancode_ctags/licenses/universal-ctags/COPYING b/binary-analysis/scancode-ctags-macosx/src/scancode_ctags/licenses/universal-ctags/COPYING new file mode 100644 index 0000000..60549be --- /dev/null +++ b/binary-analysis/scancode-ctags-macosx/src/scancode_ctags/licenses/universal-ctags/COPYING @@ -0,0 +1,340 @@ + GNU GENERAL PUBLIC LICENSE + Version 2, June 1991 + + Copyright (C) 1989, 1991 Free Software Foundation, Inc. + 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + Everyone is permitted to copy and distribute verbatim copies + of this license document, but changing it is not allowed. + + Preamble + + The licenses for most software are designed to take away your +freedom to share and change it. By contrast, the GNU General Public +License is intended to guarantee your freedom to share and change free +software--to make sure the software is free for all its users. This +General Public License applies to most of the Free Software +Foundation's software and to any other program whose authors commit to +using it. (Some other Free Software Foundation software is covered by +the GNU Library General Public License instead.) You can apply it to +your programs, too. + + When we speak of free software, we are referring to freedom, not +price. Our General Public Licenses are designed to make sure that you +have the freedom to distribute copies of free software (and charge for +this service if you wish), that you receive source code or can get it +if you want it, that you can change the software or use pieces of it +in new free programs; and that you know you can do these things. + + To protect your rights, we need to make restrictions that forbid +anyone to deny you these rights or to ask you to surrender the rights. +These restrictions translate to certain responsibilities for you if you +distribute copies of the software, or if you modify it. + + For example, if you distribute copies of such a program, whether +gratis or for a fee, you must give the recipients all the rights that +you have. You must make sure that they, too, receive or can get the +source code. And you must show them these terms so they know their +rights. + + We protect your rights with two steps: (1) copyright the software, and +(2) offer you this license which gives you legal permission to copy, +distribute and/or modify the software. + + Also, for each author's protection and ours, we want to make certain +that everyone understands that there is no warranty for this free +software. If the software is modified by someone else and passed on, we +want its recipients to know that what they have is not the original, so +that any problems introduced by others will not reflect on the original +authors' reputations. + + Finally, any free program is threatened constantly by software +patents. We wish to avoid the danger that redistributors of a free +program will individually obtain patent licenses, in effect making the +program proprietary. To prevent this, we have made it clear that any +patent must be licensed for everyone's free use or not licensed at all. + + The precise terms and conditions for copying, distribution and +modification follow. + + GNU GENERAL PUBLIC LICENSE + TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION + + 0. This License applies to any program or other work which contains +a notice placed by the copyright holder saying it may be distributed +under the terms of this General Public License. The "Program", below, +refers to any such program or work, and a "work based on the Program" +means either the Program or any derivative work under copyright law: +that is to say, a work containing the Program or a portion of it, +either verbatim or with modifications and/or translated into another +language. (Hereinafter, translation is included without limitation in +the term "modification".) Each licensee is addressed as "you". + +Activities other than copying, distribution and modification are not +covered by this License; they are outside its scope. The act of +running the Program is not restricted, and the output from the Program +is covered only if its contents constitute a work based on the +Program (independent of having been made by running the Program). +Whether that is true depends on what the Program does. + + 1. You may copy and distribute verbatim copies of the Program's +source code as you receive it, in any medium, provided that you +conspicuously and appropriately publish on each copy an appropriate +copyright notice and disclaimer of warranty; keep intact all the +notices that refer to this License and to the absence of any warranty; +and give any other recipients of the Program a copy of this License +along with the Program. + +You may charge a fee for the physical act of transferring a copy, and +you may at your option offer warranty protection in exchange for a fee. + + 2. You may modify your copy or copies of the Program or any portion +of it, thus forming a work based on the Program, and copy and +distribute such modifications or work under the terms of Section 1 +above, provided that you also meet all of these conditions: + + a) You must cause the modified files to carry prominent notices + stating that you changed the files and the date of any change. + + b) You must cause any work that you distribute or publish, that in + whole or in part contains or is derived from the Program or any + part thereof, to be licensed as a whole at no charge to all third + parties under the terms of this License. + + c) If the modified program normally reads commands interactively + when run, you must cause it, when started running for such + interactive use in the most ordinary way, to print or display an + announcement including an appropriate copyright notice and a + notice that there is no warranty (or else, saying that you provide + a warranty) and that users may redistribute the program under + these conditions, and telling the user how to view a copy of this + License. (Exception: if the Program itself is interactive but + does not normally print such an announcement, your work based on + the Program is not required to print an announcement.) + +These requirements apply to the modified work as a whole. If +identifiable sections of that work are not derived from the Program, +and can be reasonably considered independent and separate works in +themselves, then this License, and its terms, do not apply to those +sections when you distribute them as separate works. But when you +distribute the same sections as part of a whole which is a work based +on the Program, the distribution of the whole must be on the terms of +this License, whose permissions for other licensees extend to the +entire whole, and thus to each and every part regardless of who wrote it. + +Thus, it is not the intent of this section to claim rights or contest +your rights to work written entirely by you; rather, the intent is to +exercise the right to control the distribution of derivative or +collective works based on the Program. + +In addition, mere aggregation of another work not based on the Program +with the Program (or with a work based on the Program) on a volume of +a storage or distribution medium does not bring the other work under +the scope of this License. + + 3. You may copy and distribute the Program (or a work based on it, +under Section 2) in object code or executable form under the terms of +Sections 1 and 2 above provided that you also do one of the following: + + a) Accompany it with the complete corresponding machine-readable + source code, which must be distributed under the terms of Sections + 1 and 2 above on a medium customarily used for software interchange; or, + + b) Accompany it with a written offer, valid for at least three + years, to give any third party, for a charge no more than your + cost of physically performing source distribution, a complete + machine-readable copy of the corresponding source code, to be + distributed under the terms of Sections 1 and 2 above on a medium + customarily used for software interchange; or, + + c) Accompany it with the information you received as to the offer + to distribute corresponding source code. (This alternative is + allowed only for noncommercial distribution and only if you + received the program in object code or executable form with such + an offer, in accord with Subsection b above.) + +The source code for a work means the preferred form of the work for +making modifications to it. For an executable work, complete source +code means all the source code for all modules it contains, plus any +associated interface definition files, plus the scripts used to +control compilation and installation of the executable. However, as a +special exception, the source code distributed need not include +anything that is normally distributed (in either source or binary +form) with the major components (compiler, kernel, and so on) of the +operating system on which the executable runs, unless that component +itself accompanies the executable. + +If distribution of executable or object code is made by offering +access to copy from a designated place, then offering equivalent +access to copy the source code from the same place counts as +distribution of the source code, even though third parties are not +compelled to copy the source along with the object code. + + 4. You may not copy, modify, sublicense, or distribute the Program +except as expressly provided under this License. Any attempt +otherwise to copy, modify, sublicense or distribute the Program is +void, and will automatically terminate your rights under this License. +However, parties who have received copies, or rights, from you under +this License will not have their licenses terminated so long as such +parties remain in full compliance. + + 5. You are not required to accept this License, since you have not +signed it. However, nothing else grants you permission to modify or +distribute the Program or its derivative works. These actions are +prohibited by law if you do not accept this License. Therefore, by +modifying or distributing the Program (or any work based on the +Program), you indicate your acceptance of this License to do so, and +all its terms and conditions for copying, distributing or modifying +the Program or works based on it. + + 6. Each time you redistribute the Program (or any work based on the +Program), the recipient automatically receives a license from the +original licensor to copy, distribute or modify the Program subject to +these terms and conditions. You may not impose any further +restrictions on the recipients' exercise of the rights granted herein. +You are not responsible for enforcing compliance by third parties to +this License. + + 7. If, as a consequence of a court judgment or allegation of patent +infringement or for any other reason (not limited to patent issues), +conditions are imposed on you (whether by court order, agreement or +otherwise) that contradict the conditions of this License, they do not +excuse you from the conditions of this License. If you cannot +distribute so as to satisfy simultaneously your obligations under this +License and any other pertinent obligations, then as a consequence you +may not distribute the Program at all. For example, if a patent +license would not permit royalty-free redistribution of the Program by +all those who receive copies directly or indirectly through you, then +the only way you could satisfy both it and this License would be to +refrain entirely from distribution of the Program. + +If any portion of this section is held invalid or unenforceable under +any particular circumstance, the balance of the section is intended to +apply and the section as a whole is intended to apply in other +circumstances. + +It is not the purpose of this section to induce you to infringe any +patents or other property right claims or to contest validity of any +such claims; this section has the sole purpose of protecting the +integrity of the free software distribution system, which is +implemented by public license practices. Many people have made +generous contributions to the wide range of software distributed +through that system in reliance on consistent application of that +system; it is up to the author/donor to decide if he or she is willing +to distribute software through any other system and a licensee cannot +impose that choice. + +This section is intended to make thoroughly clear what is believed to +be a consequence of the rest of this License. + + 8. If the distribution and/or use of the Program is restricted in +certain countries either by patents or by copyrighted interfaces, the +original copyright holder who places the Program under this License +may add an explicit geographical distribution limitation excluding +those countries, so that distribution is permitted only in or among +countries not thus excluded. In such case, this License incorporates +the limitation as if written in the body of this License. + + 9. The Free Software Foundation may publish revised and/or new versions +of the General Public License from time to time. Such new versions will +be similar in spirit to the present version, but may differ in detail to +address new problems or concerns. + +Each version is given a distinguishing version number. If the Program +specifies a version number of this License which applies to it and "any +later version", you have the option of following the terms and conditions +either of that version or of any later version published by the Free +Software Foundation. If the Program does not specify a version number of +this License, you may choose any version ever published by the Free Software +Foundation. + + 10. If you wish to incorporate parts of the Program into other free +programs whose distribution conditions are different, write to the author +to ask for permission. For software which is copyrighted by the Free +Software Foundation, write to the Free Software Foundation; we sometimes +make exceptions for this. Our decision will be guided by the two goals +of preserving the free status of all derivatives of our free software and +of promoting the sharing and reuse of software generally. + + NO WARRANTY + + 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY +FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN +OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES +PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED +OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS +TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE +PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, +REPAIR OR CORRECTION. + + 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING +WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR +REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, +INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING +OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED +TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY +YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER +PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE +POSSIBILITY OF SUCH DAMAGES. + + END OF TERMS AND CONDITIONS + + How to Apply These Terms to Your New Programs + + If you develop a new program, and you want it to be of the greatest +possible use to the public, the best way to achieve this is to make it +free software which everyone can redistribute and change under these terms. + + To do so, attach the following notices to the program. It is safest +to attach them to the start of each source file to most effectively +convey the exclusion of warranty; and each file should have at least +the "copyright" line and a pointer to where the full notice is found. + + + Copyright (C) 19yy + + This program is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + + +Also add information on how to contact you by electronic and paper mail. + +If the program is interactive, make it output a short notice like this +when it starts in an interactive mode: + + Gnomovision version 69, Copyright (C) 19yy name of author + Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'. + This is free software, and you are welcome to redistribute it + under certain conditions; type `show c' for details. + +The hypothetical commands `show w' and `show c' should show the appropriate +parts of the General Public License. Of course, the commands you use may +be called something other than `show w' and `show c'; they could even be +mouse-clicks or menu items--whatever suits your program. + +You should also get your employer (if you work as a programmer) or your +school, if any, to sign a "copyright disclaimer" for the program, if +necessary. Here is a sample; alter the names: + + Yoyodyne, Inc., hereby disclaims all copyright interest in the program + `Gnomovision' (which makes passes at compilers) written by James Hacker. + + , 1 April 1989 + Ty Coon, President of Vice + +This General Public License does not permit incorporating your program into +proprietary programs. If your program is a subroutine library, you may +consider it more useful to permit linking proprietary applications with the +library. If this is what you want to do, use the GNU Library General +Public License instead of this License. diff --git a/binary-analysis/scancode-ctags-macosx/src/scancode_ctags/licenses/universal-ctags/INSTALL_RECEIPT.json b/binary-analysis/scancode-ctags-macosx/src/scancode_ctags/licenses/universal-ctags/INSTALL_RECEIPT.json new file mode 100644 index 0000000..68abb4c --- /dev/null +++ b/binary-analysis/scancode-ctags-macosx/src/scancode_ctags/licenses/universal-ctags/INSTALL_RECEIPT.json @@ -0,0 +1,62 @@ +{ + "homebrew_version": "5.0.12-17-g3c02613", + "used_options": [], + "unused_options": [], + "built_as_bottle": true, + "poured_from_bottle": true, + "loaded_from_api": true, + "installed_as_dependency": false, + "installed_on_request": true, + "changed_files": [], + "time": 1770149153, + "source_modified_time": 1761398124, + "compiler": "clang", + "aliases": [], + "runtime_dependencies": [ + { + "full_name": "jansson", + "version": "2.15.0", + "revision": 0, + "bottle_rebuild": 0, + "pkg_version": "2.15.0", + "declared_directly": true + }, + { + "full_name": "libyaml", + "version": "0.2.5", + "revision": 0, + "bottle_rebuild": 0, + "pkg_version": "0.2.5", + "declared_directly": true + }, + { + "full_name": "pcre2", + "version": "10.47", + "revision": 0, + "bottle_rebuild": 0, + "pkg_version": "10.47", + "declared_directly": true + } + ], + "source": { + "spec": "stable", + "versions": { + "stable": "6.2.1", + "head": null, + "version_scheme": 0, + "compatibility_version": null + }, + "path": "/Users/van/Library/Caches/Homebrew/api/formula.jws.json", + "tap_git_head": "c62cffdc8d8b07d242d457f1ac1e3123b8630ea0", + "tap": "homebrew/core" + }, + "arch": "arm64", + "built_on": { + "os": "Macintosh", + "os_version": "macOS 26", + "cpu_family": "dunno", + "xcode": "26.2", + "clt": "26.2.0.0.1.1764812424", + "preferred_perl": "5.34" + } +} \ No newline at end of file diff --git a/binary-analysis/scancode-ctags-macosx/src/scancode_ctags/licenses/universal-ctags/README.md b/binary-analysis/scancode-ctags-macosx/src/scancode_ctags/licenses/universal-ctags/README.md new file mode 100644 index 0000000..958a278 --- /dev/null +++ b/binary-analysis/scancode-ctags-macosx/src/scancode_ctags/licenses/universal-ctags/README.md @@ -0,0 +1,134 @@ +# Universal Ctags + +[![Coverity Scan Build Status](https://scan.coverity.com/projects/4355/badge.svg)](https://scan.coverity.com/projects/4355) +[![Coverage Status](https://coveralls.io/repos/universal-ctags/ctags/badge.svg?branch=master&service=github)](https://coveralls.io/github/universal-ctags/ctags?branch=master) +[![Build status](https://ci.appveyor.com/api/projects/status/6hk2p5lv6jsrd9o7/branch/master?svg=true)](https://ci.appveyor.com/project/universalctags/ctags/branch/master) +[![RTD build status](https://readthedocs.org/projects/ctags/badge)](https://docs.ctags.io) +[![CircleCI Build Status](https://dl.circleci.com/status-badge/img/gh/universal-ctags/ctags/tree/master.svg?style=svg)](https://dl.circleci.com/status-badge/redirect/gh/universal-ctags/ctags/tree/master) +![GitHub Actions/VALGRIND](https://github.com/universal-ctags/ctags/workflows/run%20units%20target%20under%20VALGRIND/badge.svg) +[![Gurubase](https://img.shields.io/badge/Gurubase-Ask%20Universal%20Ctags%20Guru-006BFF)](https://gurubase.io/g/universal-ctags) + +[Universal Ctags](https://ctags.io/) (abbreviated as u-ctags) is a *maintained* +implementation of `ctags`. +`ctags` generates an index (or tag) file of language objects found in source +files for programming languages. +This index makes it easy for text editors and other tools to locate the indexed +items. + +[Exuberant Ctags](http://ctags.sourceforge.net/) (e-ctags) maintained by Darren +Hiebert, the ancestor of Universal Ctags, improved traditional `ctags` with +multi-language support, the ability for the user to define new languages +searched by regular expressions (called optlib in Universal Ctags), and the +ability to generate emacs-style TAGS files. +But the activity of the project unfortunately stalled. + +Universal Ctags has the objective of continuing the development of Exuberant +Ctags. +Reza Jelveh initially created a personal fork of +Exuberant Ctags on GitHub. +As interest and participation grew, it was decided to move development to a +dedicated project as Universal Ctags. +The goal of this project is to maintain a common/unified working space where +people interested in making ctags better can work together. + +Some of the major features of Universal Ctags are: + +* more numbers of improved language support + * new extended C/C++ language parser, etc. +* fully extended optlib (a feature to define a new language parser from a + command line) +* interactive mode (experimental) + +## The latest build and package ## + +If you want to try the latest Universal Ctags without building it yourself... + +### Windows +Daily builds are available at the [ctags-win32](https://github.com/universal-ctags/ctags-win32) project. +Go to the [releases](https://github.com/universal-ctags/ctags-win32/releases) page to download zip packages. + +### Unix-like +Nightly builds are available at the [ctags-nightly-build](https://github.com/universal-ctags/ctags-nightly-build) project. +Go to the [releases](https://github.com/universal-ctags/ctags-nightly-build/releases) page to download tarball archives. + +### Mac +Recent builds are available via the [`universal-ctags` Homebrew formula](https://formulae.brew.sh/formula/universal-ctags). + +### Snap +Go to [ctags-snap](https://github.com/universal-ctags/ctags-snap) and +clone the `ctags-snap` repo. Then, follow instructions to build the +snap package of Universal Ctags. Snapcraft will automatically fetch the source +code from GitHub. + +## How to build and install ## + +To build with Autotools (Autoconf and Automake) on GNU/Linux, OSX, or Windows 10 WSL, +``` + $ git clone https://github.com/universal-ctags/ctags.git + $ cd ctags + $ ./autogen.sh + $ ./configure # use --prefix=/where/you/want to override installation directory, defaults to /usr/local + $ make + $ make install # may require extra privileges depending on where to install +``` + +GNU make is assumed as the `make` command. + +See +[`docs/autotools.rst`](https://github.com/universal-ctags/ctags/blob/master/docs/autotools.rst) +for more information. + +To build on Windows, see +[`docs/windows.rst`](https://github.com/universal-ctags/ctags/blob/master/docs/windows.rst) +for more information. + +To build on OSX, see +[`docs/osx.rst`](https://github.com/universal-ctags/ctags/blob/master/docs/osx.rst) +for more information. + +## Manual ## +The primary documents of Universal Ctags are man pages. +Users should first consult the +[ctags(1)](https://docs.ctags.io/en/latest/man/ctags.1.html), and [other man +pages](https://docs.ctags.io/en/latest/man-pages.html) if necessary. + +[Universal Ctags Hacking Guide](https://docs.ctags.io), which also includes the +man pages, is primarily for developers and provides additional information to +the man pages, including experimental features. + +See also `*/README.md` on this repository. + +## Differences from exuberant-ctags ## + +You may be interested in how Universal Ctags is different from Exuberant Ctags. +See +[ctags-incompatibilities(7)](https://docs.ctags.io/en/latest/man/ctags-incompatibilities.7.html) +and [Introduced changes](https://docs.ctags.io/en/latest/news.html) for details. + +The most significant incompatible changes: + +* Universal Ctags doesn't load `~/.ctags` and `./.ctags` at starting up time. + Instead, it loads `~/.ctags.d/*.ctags` and `./.ctags.d/*.ctags`. + +* Universal Ctags is more strict about characters that can be + used in kind letters and kind names than Exuberant-ctags. + + - The letter must be an alphabetical character (`[a-zA-EG-Z]`). + `F` is reserved for `file` kind. + + - The first character of the name must be alphabetic, and + the rest characters must be alphanumeric (`[a-zA-Z][a-zA-Z0-9]*`). + + The detailed background is explained in + [#1737](https://github.com/universal-ctags/ctags/pull/1737). + + If you want to reuse your `.ctags` written for Exuberant-ctags, + you must review kind letters and names defined with `--regex-=...` + options. When updating the definitions, using `--kinddef-=...` option + is appreciated. + +## [CVE-2022-4515](https://access.redhat.com/security/cve/CVE-2022-4515) ## +It is not affected to Universal Ctags. +It was fixed in [e00c55d7a0204dc1d0ae316141323959e1e16162](https://github.com/universal-ctags/ctags/commit/e00c55d7a0204dc1d0ae316141323959e1e16162) in 2016. Thanks to the reporter. + +Pull-requests are welcome! diff --git a/binary-analysis/scancode-dwarfdump-linux/src/scancode_dwarfdump/bin/dwarfdump2 b/binary-analysis/scancode-dwarfdump-linux/src/scancode_dwarfdump/bin/dwarfdump2 index b5bb1b2..72d6060 100755 Binary files a/binary-analysis/scancode-dwarfdump-linux/src/scancode_dwarfdump/bin/dwarfdump2 and b/binary-analysis/scancode-dwarfdump-linux/src/scancode_dwarfdump/bin/dwarfdump2 differ diff --git a/binary-analysis/scancode-dwarfdump-linux/src/scancode_dwarfdump/bin/libelf.so b/binary-analysis/scancode-dwarfdump-linux/src/scancode_dwarfdump/bin/libelf.so deleted file mode 100644 index 75ec04b..0000000 Binary files a/binary-analysis/scancode-dwarfdump-linux/src/scancode_dwarfdump/bin/libelf.so and /dev/null differ diff --git a/binary-analysis/scancode-dwarfdump-linux/src/scancode_dwarfdump/bin/libelf.so b/binary-analysis/scancode-dwarfdump-linux/src/scancode_dwarfdump/bin/libelf.so new file mode 120000 index 0000000..db6b658 --- /dev/null +++ b/binary-analysis/scancode-dwarfdump-linux/src/scancode_dwarfdump/bin/libelf.so @@ -0,0 +1 @@ +libelf.so.0 \ No newline at end of file diff --git a/binary-analysis/scancode-dwarfdump-linux/src/scancode_dwarfdump/bin/libelf.so.0 b/binary-analysis/scancode-dwarfdump-linux/src/scancode_dwarfdump/bin/libelf.so.0 index 75ec04b..f080702 100644 Binary files a/binary-analysis/scancode-dwarfdump-linux/src/scancode_dwarfdump/bin/libelf.so.0 and b/binary-analysis/scancode-dwarfdump-linux/src/scancode_dwarfdump/bin/libelf.so.0 differ diff --git a/binary-analysis/scancode-dwarfdump-linux/src/scancode_dwarfdump/bin/libelf.so.0.8.10 b/binary-analysis/scancode-dwarfdump-linux/src/scancode_dwarfdump/bin/libelf.so.0.8.10 index 75ec04b..3731a7c 100644 Binary files a/binary-analysis/scancode-dwarfdump-linux/src/scancode_dwarfdump/bin/libelf.so.0.8.10 and b/binary-analysis/scancode-dwarfdump-linux/src/scancode_dwarfdump/bin/libelf.so.0.8.10 differ diff --git a/binary-analysis/scancode-dwarfdump-linux/src/scancode_dwarfdump/bin/nm-new b/binary-analysis/scancode-dwarfdump-linux/src/scancode_dwarfdump/bin/nm-new index 148d882..37679dd 100755 Binary files a/binary-analysis/scancode-dwarfdump-linux/src/scancode_dwarfdump/bin/nm-new and b/binary-analysis/scancode-dwarfdump-linux/src/scancode_dwarfdump/bin/nm-new differ diff --git a/binary-analysis/scancode-dwarfdump-macosx/setup.cfg b/binary-analysis/scancode-dwarfdump-macosx/setup.cfg index 3b0d575..7f15a66 100644 --- a/binary-analysis/scancode-dwarfdump-macosx/setup.cfg +++ b/binary-analysis/scancode-dwarfdump-macosx/setup.cfg @@ -4,4 +4,4 @@ license_files = README.rst [aliases] -release = clean --all bdist_wheel --plat-name macosx_10_14_x86_64 --python-tag py3 +release = clean --all bdist_wheel --plat-name macosx_15_0_arm64 --python-tag py3 diff --git a/binary-analysis/scancode-dwarfdump-macosx/src/scancode_dwarfdump/bin/dwarfdump2 b/binary-analysis/scancode-dwarfdump-macosx/src/scancode_dwarfdump/bin/dwarfdump2 index 1095733..408a900 100755 Binary files a/binary-analysis/scancode-dwarfdump-macosx/src/scancode_dwarfdump/bin/dwarfdump2 and b/binary-analysis/scancode-dwarfdump-macosx/src/scancode_dwarfdump/bin/dwarfdump2 differ diff --git a/binary-analysis/scancode-dwarfdump-macosx/src/scancode_dwarfdump/lib/libdwarf.2.dylib b/binary-analysis/scancode-dwarfdump-macosx/src/scancode_dwarfdump/lib/libdwarf.2.dylib new file mode 100644 index 0000000..53bf0e4 Binary files /dev/null and b/binary-analysis/scancode-dwarfdump-macosx/src/scancode_dwarfdump/lib/libdwarf.2.dylib differ diff --git a/binary-analysis/scancode-dwarfdump-macosx/src/scancode_dwarfdump/licenses/dwarfutils/AUTHORS b/binary-analysis/scancode-dwarfdump-macosx/src/scancode_dwarfdump/licenses/dwarfutils/AUTHORS new file mode 100644 index 0000000..17adebc --- /dev/null +++ b/binary-analysis/scancode-dwarfdump-macosx/src/scancode_dwarfdump/licenses/dwarfutils/AUTHORS @@ -0,0 +1,3 @@ +David Anderson +Carlos Alberto Enciso +Vincent Torri diff --git a/binary-analysis/scancode-dwarfdump-macosx/src/scancode_dwarfdump/licenses/dwarfutils/COPYING b/binary-analysis/scancode-dwarfdump-macosx/src/scancode_dwarfdump/licenses/dwarfutils/COPYING new file mode 100644 index 0000000..664ae63 --- /dev/null +++ b/binary-analysis/scancode-dwarfdump-macosx/src/scancode_dwarfdump/licenses/dwarfutils/COPYING @@ -0,0 +1,25 @@ + COPYING + August 6 2023 + +The source code in the libdwarf directory is LGPL version +2.1. See libdwarf/LIBDWARFCOPYRIGHT libdwarf/LGPL.txt A +few of files use the two-clause BSD copyright ("FreeBSD +License"). + +The source code in the dwarfdump directory is +generally GPL version 2. See dwarfdump/COPYING +dwarfdump/DWARFDUMPCOPYRIGHT dwarfdump/GPL.txt a + +A few files in some directories may have the 3-clause +BSD copyright. + +The source code in the dwarfgen directory generally has +the two-clause BSD copyright. See dwarfgen/COPYING + +Various files begin with a copyright and a notice +saying the file is PUBLIC DOMAIN (sometimes spelled +public domain). Such files can be copied, modified, +and used by anyone for any purpose without attribution +or restriction. Example source code is marked as public +domain as we expect many people will use such as a starting +point in their code. diff --git a/binary-analysis/scancode-dwarfdump-macosx/src/scancode_dwarfdump/licenses/dwarfutils/INSTALL_RECEIPT.json b/binary-analysis/scancode-dwarfdump-macosx/src/scancode_dwarfdump/licenses/dwarfutils/INSTALL_RECEIPT.json new file mode 100644 index 0000000..9d7ef99 --- /dev/null +++ b/binary-analysis/scancode-dwarfdump-macosx/src/scancode_dwarfdump/licenses/dwarfutils/INSTALL_RECEIPT.json @@ -0,0 +1,41 @@ +{ + "homebrew_version": "5.0.12-62-g024ad4f", + "used_options": [], + "unused_options": [], + "built_as_bottle": true, + "poured_from_bottle": true, + "loaded_from_api": true, + "installed_as_dependency": false, + "installed_on_request": true, + "changed_files": [ + "lib/pkgconfig/libdwarf.pc" + ], + "time": 1770149155, + "source_modified_time": 1769797320, + "compiler": "clang", + "aliases": [ + "libdwarf" + ], + "runtime_dependencies": [], + "source": { + "spec": "stable", + "versions": { + "stable": "2.3.0", + "head": null, + "version_scheme": 1, + "compatibility_version": null + }, + "path": "/Users/van/Library/Caches/Homebrew/api/formula.jws.json", + "tap_git_head": "c62cffdc8d8b07d242d457f1ac1e3123b8630ea0", + "tap": "homebrew/core" + }, + "arch": "arm64", + "built_on": { + "os": "Macintosh", + "os_version": "macOS 26", + "cpu_family": "dunno", + "xcode": "26.2", + "clt": "26.2.0.0.1.1764812424", + "preferred_perl": "5.34" + } +} \ No newline at end of file diff --git a/binary-analysis/scancode-dwarfdump-macosx/src/scancode_dwarfdump/licenses/dwarfutils/README b/binary-analysis/scancode-dwarfdump-macosx/src/scancode_dwarfdump/licenses/dwarfutils/README new file mode 100644 index 0000000..a861da0 --- /dev/null +++ b/binary-analysis/scancode-dwarfdump-macosx/src/scancode_dwarfdump/licenses/dwarfutils/README @@ -0,0 +1,2 @@ +### Nothing here. +### See README.md diff --git a/binary-analysis/scancode-dwarfdump-macosx/src/scancode_dwarfdump/licenses/dwarfutils/README.md b/binary-analysis/scancode-dwarfdump-macosx/src/scancode_dwarfdump/licenses/dwarfutils/README.md new file mode 100644 index 0000000..038a132 --- /dev/null +++ b/binary-analysis/scancode-dwarfdump-macosx/src/scancode_dwarfdump/licenses/dwarfutils/README.md @@ -0,0 +1,476 @@ +# This is libdwarf README.md + +Updated 28 January 2026 + +## Goal +Libdwarf has been focused for years +on both providing access to DWARF2 through +DWARF5 data in a portable +way while also detecting and reporting +if the DWARF is corrupted and avoiding +run-time crashes or memory leakage regardless +how corrupted the DWARF being read may be. +The intent is to provide ABI independent +access to DWARF data and ensure that data +returned by the library is meaningful. + +When the DWARF6 standard is released by the DWARF committee +support will be added (as soon as +reasonably possible) to libdwarf for all +changes/additions while continuing to support +previous versions. + +Libdwarf reads files from disk, it does not +read running programs or running shared objects. + +See REQUIREMENTS below for information +on what libraries are needed. + +## github actions +ci runs builds on Linux, Freebsd, msys2, and MacOS +using configure,cmake, and meson. + +[![ci](https://github.com/davea42/libdwarf-code/actions/workflows/test.yml/badge.svg)](https://github.com/davea42/libdwarf-code/actions/workflows/test.yml) + +[![OpenSSF Best Practices](https://bestpractices.coreinfrastructure.org/projects/7275/badge)](https://bestpractices.coreinfrastructure.org/projects/7275) + + Version 2.3.0 Released 1 February 2026. + Version 2.2.0 Released 10 October 2025. + Version 2.1.0 Released 20 July 2025. + Version 2.0.0 Released 20 May 2025. + Version 0.12.0 Released 2 April 2025. + Version 0.11.1 Released 1 December 2024. + Version 0.11.0 Released 15 August 2024. + Version 0.10.1 Released 1 July 2024. + Version 0.9.2 Released 2 April 2024. + Version 0.9.1 Released 27 January 2024. + +## NOTE on build failing as strdup() missing + +If certain gcc build options are used (for example +-std=c99 ) gcc turns off some extensions. +Beginning in v2.2.0 the build systems define _GNU_SOURCE +so that the GNU extionsions are still visible. +In CMakeLists.txt, for example, one wants (in appropriate +CMakeLists.txt) + + target_compile_definitions(dwarf PRIVATE _GNU_SOURCE) + target_compile_definitions(dwarfp PRIVATE _GNU_SOURCE) + target_compile_definitions(dwarfdump PRIVATE _GNU_SOURCE) + +## NOTE on linking against libdwarf.a + +If you are linking code against a static +library libdwarf.a You must arrange to define the +macro LIBDWARF_STATIC in compiling your code that +does a #include "libdwarf.h". +See also READMEwin-msys2.md + +## REQUIREMENTS from a libdwarf.tar.xz + +Mentioning some that might not be automatically +in your base OS release. Restricting attention +here to just building libdwarf and dwarfdump. + +Nothing in the project requires or references +elf.h, libelf.h, or libelf as of 29 June 2023, +version 0.8.0. + +If the objects you work with do not have +section content compressed +with zlib(libz) or libzstd +neither those libraries nor their header files +are required for building/using +libdwarf/dwarfdump. + +No libraries other than libc are needed to build or +use libdwarf or dwarfdump. + + Ubuntu: + sudo apt install xz pkgconf zlib1g zlib1g-dev libzstd1 + sudo apt install libzstd-dev + + # Use of libzstd1 is new in 0.4.3 + # zlib1g zlib1g-dev libzstd1 are all optional but + # are required to read any DWARF data in compressed + # sections. libzstd1 was used by many linux system utilities + # in Ubuntu 20.04. + optional add: cmake meson ninja doxygen + + FreeBSD: + pkg install bash xz python3 gmake liblz4 zstd + # libzstd is likely in /usr/local/lib and zstd.h + # in /usr/local/include and the compiler may not look there + # by default. All will still build fine without it and + # without lzib too, though compressed DWARF sections + # may not be readable. + # example: + CPPFLAGS="-I/usr/local/include/" LDFLAGS="-L/usr/local/lib" ./configure + optional add: binutils cmake meson ninja doxygen + + Ensure that all the needed programs are in $PATH, + including python3. + # candidate command to make python3 visible (as root) + # something like: + cd /usr/local/bin ; ln -s python3.9 python3 + +## BUILDING from a libdwarf.tar.xz + +This is always recommended as it's not necessary +to have GNU autotools installed. +These examples show doing a build in a directory +different than the source as that is generally +recommended practice. + +### GNU configure/autotools build + +Note: if you get a build failure that mentions +something about test/ and missing .Po object files +add --disable-dependency-tracking to the configure +command. + + rm -rf /tmp/build + mkdir /tmp/build + cd /tmp + tar xf /libdwarf-0.4.2.tar.xz + cd /tmp/build + /tmp/libdwarf-0.4.2/configure + make + make check + +### cmake build + +READMEcmake.md has details on the available cmake options. + +We suggest that you will find meson a more satisfactory +tool. + +### meson build + + meson 0.45.1 on Ubuntu 18.04 fails. + meson 0.55.2 on Ubuntu 20.04 works. + meson 0.60.3 on Freebsd 12.2 and Freebsd 13.0 works. + +See READMEwin-msys2.md for the mingw64 msys2 packages to install +and the command(s) to do that in msys2. +The tools listed there are also for msys2 meson and +autotools/configure. + +The msys2 meson ninja install not only installs libdwarf-0.dll +and dwarfdump.exe it updates the executables in +the build tree linking to that dll so all such +executables in the build tree work too. + +For example (all build environments): + + meson /tmp/libdwarf-0.4.2 + ninja + ninja install + ninja test + +For a faster build, adding additional checks: + + export CFLAGS="-g -pipe" + export CXXFLAGS="-g -pipe" + meson /tmp/libdwarf-0.4.2 -Ddwarfexample=true + ninja -j8 + ninja install + ninja test + +To build a libdwarf that does not refer to or link with +decompression libraries zstd or zlib, add the meson +option "-Ddecompression=false" + +## BUILDING example showing simple builds: + +This checks for the existence critical executables +such as cmake,meson,and ninja and only runs builds +that could work. Useful in any supported +environment. + + sh scripts/allsimplebuilds.sh + +## BUILDING on linux from a git clone with configure/autotools + +Ignore this section if using meson (or cmake). + +This is not recommended as it requires you have more +software installed. + +For Ubuntu configure, install additional packages: + + autoconf + automake + libtool + pkg-config + +For FreeBSD configure, install additional packages: + autoconf + automake + libtool + pkgconf + +Here we assume the source is in a directory named +/path/to/code + +For example, on Ubuntu 20.04 +``` + sudo apt-get install autoconf libtool pkg-config +``` + +Note: if you get a build failure that mentions +something about test/ and missing .Po object files +add --disable-dependency-tracking to the configure +command. + +Using the source/build directories from above as examples, +do : + + # Standard Linux Build + cd /path/to/code + sh autogen.sh + cd /tmp/build + /path/to/code/configure + make + make check + +## BUILDING on MacOS from a git clone configure + /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)" + brew install autoconf automake libtool + # Then use the Standard Linux Build lines above. + +### Options to meson on Linux/Unix + +For the basic configuration options list , do: + meson configure /path/to/code + +To set options and show the resulting actual options: + + # Here just setting one option. + meson setup -Ddwarfexample=true . /home/davea/dwarf/code + meson configure . + +The meson configure output is very wide (just letting you know). + +### Options to configure/autotools on Linux/Unix + +For the full options list , do: + + /path/to/code/configure --help + +By default configure compiles and uses libdwarf.a. +With `--enable-shared --disable-static" +appended to the configure step, +libdwarf.so is built and the runtimes +built will reference libdwarf.so. + +As of version 0.9.1 the configure option +"--disable-decompression" tells the build to compile +libdwarf and dwarfdump with no reference to the zlib or +zstd libraries. + +If you get a build failure that mentions +something about test/ and missing .Po object files +add --disable-dependency-tracking to the configure +command. With that option do not assume you can +alter source files and have make rebuild all +necessary. + +See: +https://www.gnu.org/savannah-checkouts/gnu/automake/history/automake-history.html#Dependency-Tracking-Evolution + + +Other options of possible interest: + + --enable-wall to turn on compiler diagnostics + --enable-dwarfexample to compile the example programs. + + configure -h shows the options available. + +Sanity checking: + +gcc has some checks that can be done at runtime. +-fsanitize=undefined is turned on for +configure by --enable-sanitize + +### Options to meson on linux MacOS Windows (Msys2) + +As of 0.9.0 meson builds default to be +shared-library builds. +These options go on the meson setup command line. +the default can be explicitly chosen with: + + --default-library shared + +A static libdwarf (archive) libdwarf.a can be built with + + --default-library static + +By default compiler warnings are errors. Add the following +to let compilations continue: + + -Dwerror=false + +By default compiles look for C/C++ language issues. +Add the following to add gcc -fsanitize checking +in the build to catch various memory errors +(the generated code is larger and slower than normal). + + -Dsanitize=true + + +### Options to configure on Windows (Msys2) + +All libdwarf builds are automatically shared object (dll) +builds. No static libdwarf.a can be built. +If you need static libdwarf.a use meson or cmake. + +Has the same meson setup reporting as on Linux (above). + +See READMEwin-msys2.md + +### Distributing via configure/autotools + +When ready to create a new source distribution do +a build and then + + make distcheck + +# INCOMPATIBILITIES. Changes to interfaces + +### Post 0.11.0 + +See libdwarf.pdf or the libdwarf html +documentation and look for the Changes section. +See below for links to the documents. +Since May 2021 we follow the Semantic Versioning standard. + +### Comparing libdwarf-0.11.0 to libdwarf-0.9.1 + +Added dwarf_get_ranges_baseaddress() to the API. + +### Comparing libdwarf-0.9.1 to libdwarf-0.9.0 + +Altered the type of the return value of +dwarf_die_abbrev_code() and dwarf_get_section_count() +from int to Dwarf_Unsigned for consistency (should always +have been this way). + +### Comparing libdwarf-0.9.0 to libdwarf-0.8.0 + +New interfaces allow full support for +Mach-O (Apple) universal binaries: +dwarf_init_path_a(), dwarf_init_path_dl_a(), and +dwarf_get_universalbinary_count(). + +### Comparing libdwarf-0.8.0 to libdwarf-0.7.0 + +The default build (with meson) is shared-library. +to build with static (archive) libdwarf +add + + --default-library static + +to the meson command line (applies to meson +builds in Linux,Macos, and Windows-mingw). + +On Windows-mingw one can build static libdwarf +when using cmake or meson (configure will +not allow a static libdwarf to be built +on Windows). + +See Options to meson on Windows (Msys2) above. + +### Comparing libdwarf-0.7.0 to libdwarf-0.6.0 +struct Dwarf\_Obj\_Access\_Methods\_a\_s changed +for extended ELF so the library can handle section count values +larger than 16bits. +dwarf\_dnames\_abbrev\_by\_code() and +dwarf\_dnames\_abbrev\_form\_by\_index() +were removed from the API, better alternatives +already existed. + +### Comparing libdwarf-0.6.0 to libdwarf-0.5.0 +The dealloc required by dwarf\_offset\_list() +was wrong, use dwarf\_dealloc(dbg, offsetlistptr, DW_DLA_UARRAY). +The function dwarf\_dietype\_offset() has a revised +argument list so it can work correctly with DWARF4. +dwarf\_get\_pubtypes() and similar changed +to eliminate messy code duplication. +Fixed memory leaks and treatment of DW\_FORM\_strx3 +and DW\_FORM\_addrx3. + +### Comparing libdwarf-0.5.0 to libdwarf-0.4.2 +dwarf\_get\_globals() is compatible but it now +returns data from .debug\_names in addition +to .debug\_pubnames (either or both +could be in an object file). +New function dwarf\_global\_tag\_number() +makes the data from .debug\_names a bit +more useful (if a library user wants it). +Three new functions were added to enable +printing of the .debug_addr section +independent of other sections +and the new dwarfdump option --print-debug-addr +prints that section. + +### Comparing libdwarf-0.4.2 to libdwarf-0.4.1 +No incompatibilities. + +### Comparing libdwarf-0.4.1 to libdwarf-0.4.0 +Added a new function dwarf\_suppress\_debuglink\_crc() +which speeds up gnu debuglink (only use it if +you are sure the debuglink name-check alone is sufficient). + +### Comparing libdwarf-0.4.0 to libdwarf-0.3.4 +A few dealloc() functions changed name to have +a consistent pattern for all such. +Access to the DWARF5 .debug\_names section +is now fully implemented. + +See the Recent Changes section in +libdwarf.pdf (in the release). + +[dwhtml]: https://www.prevanders.net/libdwarfdoc/index.html +[dwpdf]: https://www.prevanders.net/libdwarf.pdf + +Or see the latest online html version [dwhtml] for the details.. +Or see (via download) the latest pdf html version [dwpdf]. + +Notice the table of contents at the right edge of the html page. + +## Reading DWARF from memory + +If one has DWARF bytes in memory or in a +kind of file system libdwarf cannot understand +one should use + + dwarf_object_init_b() + ...call libdwarf functions... + dwarf_object_finish() + +and create source to provide +functions and data for the three struct +types: + + struct Dwarf_Obj_Access_Interface_a_s + struct Dwarf_Obj_Access_Methods_a_s + struct Dwarf_Obj_Access_Section_a_s + +These functions and structs now seem complete +(unlike the earlier libdwarf versions), hence +the name and content changes. + +For a worked out example of reading DWARF direct from memory +with no file system involved +see + + src/bin/dwarfexample/jitreader.c + +and see the html [dwhtml] (www.prevanders.net/libdwarfdoc/index.html). + +The latest pdf is [dwpdf] (www.prevanders.net/libdwarf.pdf) + +[![Packaging status](https://repology.org/badge/vertical-allrepos/libdwarf.svg?exclude_unsupported=1)](https://repology.org/project/libdwarf/versions) + +David Anderson. diff --git a/binary-analysis/scancode-readelf-linux/src/scancode_readelf/bin/c++filt b/binary-analysis/scancode-readelf-linux/src/scancode_readelf/bin/c++filt index 5f57fda..7b8bb68 100755 Binary files a/binary-analysis/scancode-readelf-linux/src/scancode_readelf/bin/c++filt and b/binary-analysis/scancode-readelf-linux/src/scancode_readelf/bin/c++filt differ diff --git a/binary-analysis/scancode-readelf-linux/src/scancode_readelf/bin/readelf b/binary-analysis/scancode-readelf-linux/src/scancode_readelf/bin/readelf index 82dd805..8ca768c 100755 Binary files a/binary-analysis/scancode-readelf-linux/src/scancode_readelf/bin/readelf and b/binary-analysis/scancode-readelf-linux/src/scancode_readelf/bin/readelf differ diff --git a/binary-analysis/scancode-readelf-macosx/setup.cfg b/binary-analysis/scancode-readelf-macosx/setup.cfg index 3b0d575..7f15a66 100644 --- a/binary-analysis/scancode-readelf-macosx/setup.cfg +++ b/binary-analysis/scancode-readelf-macosx/setup.cfg @@ -4,4 +4,4 @@ license_files = README.rst [aliases] -release = clean --all bdist_wheel --plat-name macosx_10_14_x86_64 --python-tag py3 +release = clean --all bdist_wheel --plat-name macosx_15_0_arm64 --python-tag py3 diff --git a/binary-analysis/scancode-readelf-macosx/src/scancode_readelf/bin/c++filt b/binary-analysis/scancode-readelf-macosx/src/scancode_readelf/bin/c++filt old mode 100644 new mode 100755 index 63eb838..623d819 Binary files a/binary-analysis/scancode-readelf-macosx/src/scancode_readelf/bin/c++filt and b/binary-analysis/scancode-readelf-macosx/src/scancode_readelf/bin/c++filt differ diff --git a/binary-analysis/scancode-readelf-macosx/src/scancode_readelf/bin/readelf b/binary-analysis/scancode-readelf-macosx/src/scancode_readelf/bin/readelf old mode 100644 new mode 100755 index 1cc347b..9f6e759 Binary files a/binary-analysis/scancode-readelf-macosx/src/scancode_readelf/bin/readelf and b/binary-analysis/scancode-readelf-macosx/src/scancode_readelf/bin/readelf differ diff --git a/binary-analysis/scancode-readelf-macosx/src/scancode_readelf/lib/libzstd.1.dylib b/binary-analysis/scancode-readelf-macosx/src/scancode_readelf/lib/libzstd.1.dylib new file mode 100644 index 0000000..36c0c81 Binary files /dev/null and b/binary-analysis/scancode-readelf-macosx/src/scancode_readelf/lib/libzstd.1.dylib differ diff --git a/binary-analysis/scancode-readelf-macosx/src/scancode_readelf/licenses/binutils/COPYING b/binary-analysis/scancode-readelf-macosx/src/scancode_readelf/licenses/binutils/COPYING new file mode 100644 index 0000000..623b625 --- /dev/null +++ b/binary-analysis/scancode-readelf-macosx/src/scancode_readelf/licenses/binutils/COPYING @@ -0,0 +1,340 @@ + GNU GENERAL PUBLIC LICENSE + Version 2, June 1991 + + Copyright (C) 1989, 1991 Free Software Foundation, Inc. + 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA + Everyone is permitted to copy and distribute verbatim copies + of this license document, but changing it is not allowed. + + Preamble + + The licenses for most software are designed to take away your +freedom to share and change it. By contrast, the GNU General Public +License is intended to guarantee your freedom to share and change free +software--to make sure the software is free for all its users. This +General Public License applies to most of the Free Software +Foundation's software and to any other program whose authors commit to +using it. (Some other Free Software Foundation software is covered by +the GNU Library General Public License instead.) You can apply it to +your programs, too. + + When we speak of free software, we are referring to freedom, not +price. Our General Public Licenses are designed to make sure that you +have the freedom to distribute copies of free software (and charge for +this service if you wish), that you receive source code or can get it +if you want it, that you can change the software or use pieces of it +in new free programs; and that you know you can do these things. + + To protect your rights, we need to make restrictions that forbid +anyone to deny you these rights or to ask you to surrender the rights. +These restrictions translate to certain responsibilities for you if you +distribute copies of the software, or if you modify it. + + For example, if you distribute copies of such a program, whether +gratis or for a fee, you must give the recipients all the rights that +you have. You must make sure that they, too, receive or can get the +source code. And you must show them these terms so they know their +rights. + + We protect your rights with two steps: (1) copyright the software, and +(2) offer you this license which gives you legal permission to copy, +distribute and/or modify the software. + + Also, for each author's protection and ours, we want to make certain +that everyone understands that there is no warranty for this free +software. If the software is modified by someone else and passed on, we +want its recipients to know that what they have is not the original, so +that any problems introduced by others will not reflect on the original +authors' reputations. + + Finally, any free program is threatened constantly by software +patents. We wish to avoid the danger that redistributors of a free +program will individually obtain patent licenses, in effect making the +program proprietary. To prevent this, we have made it clear that any +patent must be licensed for everyone's free use or not licensed at all. + + The precise terms and conditions for copying, distribution and +modification follow. + + GNU GENERAL PUBLIC LICENSE + TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION + + 0. This License applies to any program or other work which contains +a notice placed by the copyright holder saying it may be distributed +under the terms of this General Public License. The "Program", below, +refers to any such program or work, and a "work based on the Program" +means either the Program or any derivative work under copyright law: +that is to say, a work containing the Program or a portion of it, +either verbatim or with modifications and/or translated into another +language. (Hereinafter, translation is included without limitation in +the term "modification".) Each licensee is addressed as "you". + +Activities other than copying, distribution and modification are not +covered by this License; they are outside its scope. The act of +running the Program is not restricted, and the output from the Program +is covered only if its contents constitute a work based on the +Program (independent of having been made by running the Program). +Whether that is true depends on what the Program does. + + 1. You may copy and distribute verbatim copies of the Program's +source code as you receive it, in any medium, provided that you +conspicuously and appropriately publish on each copy an appropriate +copyright notice and disclaimer of warranty; keep intact all the +notices that refer to this License and to the absence of any warranty; +and give any other recipients of the Program a copy of this License +along with the Program. + +You may charge a fee for the physical act of transferring a copy, and +you may at your option offer warranty protection in exchange for a fee. + + 2. You may modify your copy or copies of the Program or any portion +of it, thus forming a work based on the Program, and copy and +distribute such modifications or work under the terms of Section 1 +above, provided that you also meet all of these conditions: + + a) You must cause the modified files to carry prominent notices + stating that you changed the files and the date of any change. + + b) You must cause any work that you distribute or publish, that in + whole or in part contains or is derived from the Program or any + part thereof, to be licensed as a whole at no charge to all third + parties under the terms of this License. + + c) If the modified program normally reads commands interactively + when run, you must cause it, when started running for such + interactive use in the most ordinary way, to print or display an + announcement including an appropriate copyright notice and a + notice that there is no warranty (or else, saying that you provide + a warranty) and that users may redistribute the program under + these conditions, and telling the user how to view a copy of this + License. (Exception: if the Program itself is interactive but + does not normally print such an announcement, your work based on + the Program is not required to print an announcement.) + +These requirements apply to the modified work as a whole. If +identifiable sections of that work are not derived from the Program, +and can be reasonably considered independent and separate works in +themselves, then this License, and its terms, do not apply to those +sections when you distribute them as separate works. But when you +distribute the same sections as part of a whole which is a work based +on the Program, the distribution of the whole must be on the terms of +this License, whose permissions for other licensees extend to the +entire whole, and thus to each and every part regardless of who wrote it. + +Thus, it is not the intent of this section to claim rights or contest +your rights to work written entirely by you; rather, the intent is to +exercise the right to control the distribution of derivative or +collective works based on the Program. + +In addition, mere aggregation of another work not based on the Program +with the Program (or with a work based on the Program) on a volume of +a storage or distribution medium does not bring the other work under +the scope of this License. + + 3. You may copy and distribute the Program (or a work based on it, +under Section 2) in object code or executable form under the terms of +Sections 1 and 2 above provided that you also do one of the following: + + a) Accompany it with the complete corresponding machine-readable + source code, which must be distributed under the terms of Sections + 1 and 2 above on a medium customarily used for software interchange; or, + + b) Accompany it with a written offer, valid for at least three + years, to give any third party, for a charge no more than your + cost of physically performing source distribution, a complete + machine-readable copy of the corresponding source code, to be + distributed under the terms of Sections 1 and 2 above on a medium + customarily used for software interchange; or, + + c) Accompany it with the information you received as to the offer + to distribute corresponding source code. (This alternative is + allowed only for noncommercial distribution and only if you + received the program in object code or executable form with such + an offer, in accord with Subsection b above.) + +The source code for a work means the preferred form of the work for +making modifications to it. For an executable work, complete source +code means all the source code for all modules it contains, plus any +associated interface definition files, plus the scripts used to +control compilation and installation of the executable. However, as a +special exception, the source code distributed need not include +anything that is normally distributed (in either source or binary +form) with the major components (compiler, kernel, and so on) of the +operating system on which the executable runs, unless that component +itself accompanies the executable. + +If distribution of executable or object code is made by offering +access to copy from a designated place, then offering equivalent +access to copy the source code from the same place counts as +distribution of the source code, even though third parties are not +compelled to copy the source along with the object code. + + 4. You may not copy, modify, sublicense, or distribute the Program +except as expressly provided under this License. Any attempt +otherwise to copy, modify, sublicense or distribute the Program is +void, and will automatically terminate your rights under this License. +However, parties who have received copies, or rights, from you under +this License will not have their licenses terminated so long as such +parties remain in full compliance. + + 5. You are not required to accept this License, since you have not +signed it. However, nothing else grants you permission to modify or +distribute the Program or its derivative works. These actions are +prohibited by law if you do not accept this License. Therefore, by +modifying or distributing the Program (or any work based on the +Program), you indicate your acceptance of this License to do so, and +all its terms and conditions for copying, distributing or modifying +the Program or works based on it. + + 6. Each time you redistribute the Program (or any work based on the +Program), the recipient automatically receives a license from the +original licensor to copy, distribute or modify the Program subject to +these terms and conditions. You may not impose any further +restrictions on the recipients' exercise of the rights granted herein. +You are not responsible for enforcing compliance by third parties to +this License. + + 7. If, as a consequence of a court judgment or allegation of patent +infringement or for any other reason (not limited to patent issues), +conditions are imposed on you (whether by court order, agreement or +otherwise) that contradict the conditions of this License, they do not +excuse you from the conditions of this License. If you cannot +distribute so as to satisfy simultaneously your obligations under this +License and any other pertinent obligations, then as a consequence you +may not distribute the Program at all. For example, if a patent +license would not permit royalty-free redistribution of the Program by +all those who receive copies directly or indirectly through you, then +the only way you could satisfy both it and this License would be to +refrain entirely from distribution of the Program. + +If any portion of this section is held invalid or unenforceable under +any particular circumstance, the balance of the section is intended to +apply and the section as a whole is intended to apply in other +circumstances. + +It is not the purpose of this section to induce you to infringe any +patents or other property right claims or to contest validity of any +such claims; this section has the sole purpose of protecting the +integrity of the free software distribution system, which is +implemented by public license practices. Many people have made +generous contributions to the wide range of software distributed +through that system in reliance on consistent application of that +system; it is up to the author/donor to decide if he or she is willing +to distribute software through any other system and a licensee cannot +impose that choice. + +This section is intended to make thoroughly clear what is believed to +be a consequence of the rest of this License. + + 8. If the distribution and/or use of the Program is restricted in +certain countries either by patents or by copyrighted interfaces, the +original copyright holder who places the Program under this License +may add an explicit geographical distribution limitation excluding +those countries, so that distribution is permitted only in or among +countries not thus excluded. In such case, this License incorporates +the limitation as if written in the body of this License. + + 9. The Free Software Foundation may publish revised and/or new versions +of the General Public License from time to time. Such new versions will +be similar in spirit to the present version, but may differ in detail to +address new problems or concerns. + +Each version is given a distinguishing version number. If the Program +specifies a version number of this License which applies to it and "any +later version", you have the option of following the terms and conditions +either of that version or of any later version published by the Free +Software Foundation. If the Program does not specify a version number of +this License, you may choose any version ever published by the Free Software +Foundation. + + 10. If you wish to incorporate parts of the Program into other free +programs whose distribution conditions are different, write to the author +to ask for permission. For software which is copyrighted by the Free +Software Foundation, write to the Free Software Foundation; we sometimes +make exceptions for this. Our decision will be guided by the two goals +of preserving the free status of all derivatives of our free software and +of promoting the sharing and reuse of software generally. + + NO WARRANTY + + 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY +FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN +OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES +PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED +OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS +TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE +PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, +REPAIR OR CORRECTION. + + 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING +WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR +REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, +INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING +OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED +TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY +YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER +PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE +POSSIBILITY OF SUCH DAMAGES. + + END OF TERMS AND CONDITIONS + + How to Apply These Terms to Your New Programs + + If you develop a new program, and you want it to be of the greatest +possible use to the public, the best way to achieve this is to make it +free software which everyone can redistribute and change under these terms. + + To do so, attach the following notices to the program. It is safest +to attach them to the start of each source file to most effectively +convey the exclusion of warranty; and each file should have at least +the "copyright" line and a pointer to where the full notice is found. + + + Copyright (C) + + This program is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program; if not, write to the Free Software + Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA + + +Also add information on how to contact you by electronic and paper mail. + +If the program is interactive, make it output a short notice like this +when it starts in an interactive mode: + + Gnomovision version 69, Copyright (C) year name of author + Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'. + This is free software, and you are welcome to redistribute it + under certain conditions; type `show c' for details. + +The hypothetical commands `show w' and `show c' should show the appropriate +parts of the General Public License. Of course, the commands you use may +be called something other than `show w' and `show c'; they could even be +mouse-clicks or menu items--whatever suits your program. + +You should also get your employer (if you work as a programmer) or your +school, if any, to sign a "copyright disclaimer" for the program, if +necessary. Here is a sample; alter the names: + + Yoyodyne, Inc., hereby disclaims all copyright interest in the program + `Gnomovision' (which makes passes at compilers) written by James Hacker. + + , 1 April 1989 + Ty Coon, President of Vice + +This General Public License does not permit incorporating your program into +proprietary programs. If your program is a subroutine library, you may +consider it more useful to permit linking proprietary applications with the +library. If this is what you want to do, use the GNU Library General +Public License instead of this License. diff --git a/binary-analysis/scancode-readelf-macosx/src/scancode_readelf/licenses/binutils/COPYING.LIB b/binary-analysis/scancode-readelf-macosx/src/scancode_readelf/licenses/binutils/COPYING.LIB new file mode 100644 index 0000000..778d0bb --- /dev/null +++ b/binary-analysis/scancode-readelf-macosx/src/scancode_readelf/licenses/binutils/COPYING.LIB @@ -0,0 +1,482 @@ + GNU LIBRARY GENERAL PUBLIC LICENSE + Version 2, June 1991 + + Copyright (C) 1991 Free Software Foundation, Inc. + 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA + Everyone is permitted to copy and distribute verbatim copies + of this license document, but changing it is not allowed. + +[This is the first released version of the library GPL. It is + numbered 2 because it goes with version 2 of the ordinary GPL.] + + Preamble + + The licenses for most software are designed to take away your +freedom to share and change it. By contrast, the GNU General Public +Licenses are intended to guarantee your freedom to share and change +free software--to make sure the software is free for all its users. + + This license, the Library General Public License, applies to some +specially designated Free Software Foundation software, and to any +other libraries whose authors decide to use it. You can use it for +your libraries, too. + + When we speak of free software, we are referring to freedom, not +price. Our General Public Licenses are designed to make sure that you +have the freedom to distribute copies of free software (and charge for +this service if you wish), that you receive source code or can get it +if you want it, that you can change the software or use pieces of it +in new free programs; and that you know you can do these things. + + To protect your rights, we need to make restrictions that forbid +anyone to deny you these rights or to ask you to surrender the rights. +These restrictions translate to certain responsibilities for you if +you distribute copies of the library, or if you modify it. + + For example, if you distribute copies of the library, whether gratis +or for a fee, you must give the recipients all the rights that we gave +you. You must make sure that they, too, receive or can get the source +code. If you link a program with the library, you must provide +complete object files to the recipients so that they can relink them +with the library, after making changes to the library and recompiling +it. And you must show them these terms so they know their rights. + + Our method of protecting your rights has two steps: (1) copyright +the library, and (2) offer you this license which gives you legal +permission to copy, distribute and/or modify the library. + + Also, for each distributor's protection, we want to make certain +that everyone understands that there is no warranty for this free +library. If the library is modified by someone else and passed on, we +want its recipients to know that what they have is not the original +version, so that any problems introduced by others will not reflect on +the original authors' reputations. + + Finally, any free program is threatened constantly by software +patents. We wish to avoid the danger that companies distributing free +software will individually obtain patent licenses, thus in effect +transforming the program into proprietary software. To prevent this, +we have made it clear that any patent must be licensed for everyone's +free use or not licensed at all. + + Most GNU software, including some libraries, is covered by the ordinary +GNU General Public License, which was designed for utility programs. This +license, the GNU Library General Public License, applies to certain +designated libraries. This license is quite different from the ordinary +one; be sure to read it in full, and don't assume that anything in it is +the same as in the ordinary license. + + The reason we have a separate public license for some libraries is that +they blur the distinction we usually make between modifying or adding to a +program and simply using it. Linking a program with a library, without +changing the library, is in some sense simply using the library, and is +analogous to running a utility program or application program. However, in +a textual and legal sense, the linked executable is a combined work, a +derivative of the original library, and the ordinary General Public License +treats it as such. + + Because of this blurred distinction, using the ordinary General +Public License for libraries did not effectively promote software +sharing, because most developers did not use the libraries. We +concluded that weaker conditions might promote sharing better. + + However, unrestricted linking of non-free programs would deprive the +users of those programs of all benefit from the free status of the +libraries themselves. This Library General Public License is intended to +permit developers of non-free programs to use free libraries, while +preserving your freedom as a user of such programs to change the free +libraries that are incorporated in them. (We have not seen how to achieve +this as regards changes in header files, but we have achieved it as regards +changes in the actual functions of the Library.) The hope is that this +will lead to faster development of free libraries. + + The precise terms and conditions for copying, distribution and +modification follow. Pay close attention to the difference between a +"work based on the library" and a "work that uses the library". The +former contains code derived from the library, while the latter only +works together with the library. + + Note that it is possible for a library to be covered by the ordinary +General Public License rather than by this special one. + + GNU LIBRARY GENERAL PUBLIC LICENSE + TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION + + 0. This License Agreement applies to any software library which +contains a notice placed by the copyright holder or other authorized +party saying it may be distributed under the terms of this Library +General Public License (also called "this License"). Each licensee is +addressed as "you". + + A "library" means a collection of software functions and/or data +prepared so as to be conveniently linked with application programs +(which use some of those functions and data) to form executables. + + The "Library", below, refers to any such software library or work +which has been distributed under these terms. A "work based on the +Library" means either the Library or any derivative work under +copyright law: that is to say, a work containing the Library or a +portion of it, either verbatim or with modifications and/or translated +straightforwardly into another language. (Hereinafter, translation is +included without limitation in the term "modification".) + + "Source code" for a work means the preferred form of the work for +making modifications to it. For a library, complete source code means +all the source code for all modules it contains, plus any associated +interface definition files, plus the scripts used to control compilation +and installation of the library. + + Activities other than copying, distribution and modification are not +covered by this License; they are outside its scope. The act of +running a program using the Library is not restricted, and output from +such a program is covered only if its contents constitute a work based +on the Library (independent of the use of the Library in a tool for +writing it). Whether that is true depends on what the Library does +and what the program that uses the Library does. + + 1. You may copy and distribute verbatim copies of the Library's +complete source code as you receive it, in any medium, provided that +you conspicuously and appropriately publish on each copy an +appropriate copyright notice and disclaimer of warranty; keep intact +all the notices that refer to this License and to the absence of any +warranty; and distribute a copy of this License along with the +Library. + + You may charge a fee for the physical act of transferring a copy, +and you may at your option offer warranty protection in exchange for a +fee. + + 2. You may modify your copy or copies of the Library or any portion +of it, thus forming a work based on the Library, and copy and +distribute such modifications or work under the terms of Section 1 +above, provided that you also meet all of these conditions: + + a) The modified work must itself be a software library. + + b) You must cause the files modified to carry prominent notices + stating that you changed the files and the date of any change. + + c) You must cause the whole of the work to be licensed at no + charge to all third parties under the terms of this License. + + d) If a facility in the modified Library refers to a function or a + table of data to be supplied by an application program that uses + the facility, other than as an argument passed when the facility + is invoked, then you must make a good faith effort to ensure that, + in the event an application does not supply such function or + table, the facility still operates, and performs whatever part of + its purpose remains meaningful. + + (For example, a function in a library to compute square roots has + a purpose that is entirely well-defined independent of the + application. Therefore, Subsection 2d requires that any + application-supplied function or table used by this function must + be optional: if the application does not supply it, the square + root function must still compute square roots.) + +These requirements apply to the modified work as a whole. If +identifiable sections of that work are not derived from the Library, +and can be reasonably considered independent and separate works in +themselves, then this License, and its terms, do not apply to those +sections when you distribute them as separate works. But when you +distribute the same sections as part of a whole which is a work based +on the Library, the distribution of the whole must be on the terms of +this License, whose permissions for other licensees extend to the +entire whole, and thus to each and every part regardless of who wrote +it. + +Thus, it is not the intent of this section to claim rights or contest +your rights to work written entirely by you; rather, the intent is to +exercise the right to control the distribution of derivative or +collective works based on the Library. + +In addition, mere aggregation of another work not based on the Library +with the Library (or with a work based on the Library) on a volume of +a storage or distribution medium does not bring the other work under +the scope of this License. + + 3. You may opt to apply the terms of the ordinary GNU General Public +License instead of this License to a given copy of the Library. To do +this, you must alter all the notices that refer to this License, so +that they refer to the ordinary GNU General Public License, version 2, +instead of to this License. (If a newer version than version 2 of the +ordinary GNU General Public License has appeared, then you can specify +that version instead if you wish.) Do not make any other change in +these notices. + + Once this change is made in a given copy, it is irreversible for +that copy, so the ordinary GNU General Public License applies to all +subsequent copies and derivative works made from that copy. + + This option is useful when you wish to copy part of the code of +the Library into a program that is not a library. + + 4. You may copy and distribute the Library (or a portion or +derivative of it, under Section 2) in object code or executable form +under the terms of Sections 1 and 2 above provided that you accompany +it with the complete corresponding machine-readable source code, which +must be distributed under the terms of Sections 1 and 2 above on a +medium customarily used for software interchange. + + If distribution of object code is made by offering access to copy +from a designated place, then offering equivalent access to copy the +source code from the same place satisfies the requirement to +distribute the source code, even though third parties are not +compelled to copy the source along with the object code. + + 5. A program that contains no derivative of any portion of the +Library, but is designed to work with the Library by being compiled or +linked with it, is called a "work that uses the Library". Such a +work, in isolation, is not a derivative work of the Library, and +therefore falls outside the scope of this License. + + However, linking a "work that uses the Library" with the Library +creates an executable that is a derivative of the Library (because it +contains portions of the Library), rather than a "work that uses the +library". The executable is therefore covered by this License. +Section 6 states terms for distribution of such executables. + + When a "work that uses the Library" uses material from a header file +that is part of the Library, the object code for the work may be a +derivative work of the Library even though the source code is not. +Whether this is true is especially significant if the work can be +linked without the Library, or if the work is itself a library. The +threshold for this to be true is not precisely defined by law. + + If such an object file uses only numerical parameters, data +structure layouts and accessors, and small macros and small inline +functions (ten lines or less in length), then the use of the object +file is unrestricted, regardless of whether it is legally a derivative +work. (Executables containing this object code plus portions of the +Library will still fall under Section 6.) + + Otherwise, if the work is a derivative of the Library, you may +distribute the object code for the work under the terms of Section 6. +Any executables containing that work also fall under Section 6, +whether or not they are linked directly with the Library itself. + + 6. As an exception to the Sections above, you may also compile or +link a "work that uses the Library" with the Library to produce a +work containing portions of the Library, and distribute that work +under terms of your choice, provided that the terms permit +modification of the work for the customer's own use and reverse +engineering for debugging such modifications. + + You must give prominent notice with each copy of the work that the +Library is used in it and that the Library and its use are covered by +this License. You must supply a copy of this License. If the work +during execution displays copyright notices, you must include the +copyright notice for the Library among them, as well as a reference +directing the user to the copy of this License. Also, you must do one +of these things: + + a) Accompany the work with the complete corresponding + machine-readable source code for the Library including whatever + changes were used in the work (which must be distributed under + Sections 1 and 2 above); and, if the work is an executable linked + with the Library, with the complete machine-readable "work that + uses the Library", as object code and/or source code, so that the + user can modify the Library and then relink to produce a modified + executable containing the modified Library. (It is understood + that the user who changes the contents of definitions files in the + Library will not necessarily be able to recompile the application + to use the modified definitions.) + + b) Accompany the work with a written offer, valid for at + least three years, to give the same user the materials + specified in Subsection 6a, above, for a charge no more + than the cost of performing this distribution. + + c) If distribution of the work is made by offering access to copy + from a designated place, offer equivalent access to copy the above + specified materials from the same place. + + d) Verify that the user has already received a copy of these + materials or that you have already sent this user a copy. + + For an executable, the required form of the "work that uses the +Library" must include any data and utility programs needed for +reproducing the executable from it. However, as a special exception, +the source code distributed need not include anything that is normally +distributed (in either source or binary form) with the major +components (compiler, kernel, and so on) of the operating system on +which the executable runs, unless that component itself accompanies +the executable. + + It may happen that this requirement contradicts the license +restrictions of other proprietary libraries that do not normally +accompany the operating system. Such a contradiction means you cannot +use both them and the Library together in an executable that you +distribute. + + 7. You may place library facilities that are a work based on the +Library side-by-side in a single library together with other library +facilities not covered by this License, and distribute such a combined +library, provided that the separate distribution of the work based on +the Library and of the other library facilities is otherwise +permitted, and provided that you do these two things: + + a) Accompany the combined library with a copy of the same work + based on the Library, uncombined with any other library + facilities. This must be distributed under the terms of the + Sections above. + + b) Give prominent notice with the combined library of the fact + that part of it is a work based on the Library, and explaining + where to find the accompanying uncombined form of the same work. + + 8. You may not copy, modify, sublicense, link with, or distribute +the Library except as expressly provided under this License. Any +attempt otherwise to copy, modify, sublicense, link with, or +distribute the Library is void, and will automatically terminate your +rights under this License. However, parties who have received copies, +or rights, from you under this License will not have their licenses +terminated so long as such parties remain in full compliance. + + 9. You are not required to accept this License, since you have not +signed it. However, nothing else grants you permission to modify or +distribute the Library or its derivative works. These actions are +prohibited by law if you do not accept this License. Therefore, by +modifying or distributing the Library (or any work based on the +Library), you indicate your acceptance of this License to do so, and +all its terms and conditions for copying, distributing or modifying +the Library or works based on it. + + 10. Each time you redistribute the Library (or any work based on the +Library), the recipient automatically receives a license from the +original licensor to copy, distribute, link with or modify the Library +subject to these terms and conditions. You may not impose any further +restrictions on the recipients' exercise of the rights granted herein. +You are not responsible for enforcing compliance by third parties to +this License. + + 11. If, as a consequence of a court judgment or allegation of patent +infringement or for any other reason (not limited to patent issues), +conditions are imposed on you (whether by court order, agreement or +otherwise) that contradict the conditions of this License, they do not +excuse you from the conditions of this License. If you cannot +distribute so as to satisfy simultaneously your obligations under this +License and any other pertinent obligations, then as a consequence you +may not distribute the Library at all. For example, if a patent +license would not permit royalty-free redistribution of the Library by +all those who receive copies directly or indirectly through you, then +the only way you could satisfy both it and this License would be to +refrain entirely from distribution of the Library. + +If any portion of this section is held invalid or unenforceable under any +particular circumstance, the balance of the section is intended to apply, +and the section as a whole is intended to apply in other circumstances. + +It is not the purpose of this section to induce you to infringe any +patents or other property right claims or to contest validity of any +such claims; this section has the sole purpose of protecting the +integrity of the free software distribution system which is +implemented by public license practices. Many people have made +generous contributions to the wide range of software distributed +through that system in reliance on consistent application of that +system; it is up to the author/donor to decide if he or she is willing +to distribute software through any other system and a licensee cannot +impose that choice. + +This section is intended to make thoroughly clear what is believed to +be a consequence of the rest of this License. + + 12. If the distribution and/or use of the Library is restricted in +certain countries either by patents or by copyrighted interfaces, the +original copyright holder who places the Library under this License may add +an explicit geographical distribution limitation excluding those countries, +so that distribution is permitted only in or among countries not thus +excluded. In such case, this License incorporates the limitation as if +written in the body of this License. + + 13. The Free Software Foundation may publish revised and/or new +versions of the Library General Public License from time to time. +Such new versions will be similar in spirit to the present version, +but may differ in detail to address new problems or concerns. + +Each version is given a distinguishing version number. If the Library +specifies a version number of this License which applies to it and +"any later version", you have the option of following the terms and +conditions either of that version or of any later version published by +the Free Software Foundation. If the Library does not specify a +license version number, you may choose any version ever published by +the Free Software Foundation. + + 14. If you wish to incorporate parts of the Library into other free +programs whose distribution conditions are incompatible with these, +write to the author to ask for permission. For software which is +copyrighted by the Free Software Foundation, write to the Free +Software Foundation; we sometimes make exceptions for this. Our +decision will be guided by the two goals of preserving the free status +of all derivatives of our free software and of promoting the sharing +and reuse of software generally. + + NO WARRANTY + + 15. BECAUSE THE LIBRARY IS LICENSED FREE OF CHARGE, THERE IS NO +WARRANTY FOR THE LIBRARY, TO THE EXTENT PERMITTED BY APPLICABLE LAW. +EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR +OTHER PARTIES PROVIDE THE LIBRARY "AS IS" WITHOUT WARRANTY OF ANY +KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE +IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR +PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE +LIBRARY IS WITH YOU. SHOULD THE LIBRARY PROVE DEFECTIVE, YOU ASSUME +THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION. + + 16. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN +WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY +AND/OR REDISTRIBUTE THE LIBRARY AS PERMITTED ABOVE, BE LIABLE TO YOU +FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR +CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE +LIBRARY (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING +RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A +FAILURE OF THE LIBRARY TO OPERATE WITH ANY OTHER SOFTWARE), EVEN IF +SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH +DAMAGES. + + END OF TERMS AND CONDITIONS + + Appendix: How to Apply These Terms to Your New Libraries + + If you develop a new library, and you want it to be of the greatest +possible use to the public, we recommend making it free software that +everyone can redistribute and change. You can do so by permitting +redistribution under these terms (or, alternatively, under the terms of the +ordinary General Public License). + + To apply these terms, attach the following notices to the library. It is +safest to attach them to the start of each source file to most effectively +convey the exclusion of warranty; and each file should have at least the +"copyright" line and a pointer to where the full notice is found. + + + Copyright (C) + + This library is free software; you can redistribute it and/or + modify it under the terms of the GNU Library General Public + License as published by the Free Software Foundation; either + version 2 of the License, or (at your option) any later version. + + This library is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + Library General Public License for more details. + + You should have received a copy of the GNU Library General Public + License along with this library; if not, write to the Free + Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, + MA 02110-1301, USA + +Also add information on how to contact you by electronic and paper mail. + +You should also get your employer (if you work as a programmer) or your +school, if any, to sign a "copyright disclaimer" for the library, if +necessary. Here is a sample; alter the names: + + Yoyodyne, Inc., hereby disclaims all copyright interest in the + library `Frob' (a library for tweaking knobs) written by James Random Hacker. + + , 1 April 1990 + Ty Coon, President of Vice + +That's all there is to it! diff --git a/binary-analysis/scancode-readelf-macosx/src/scancode_readelf/licenses/binutils/INSTALL_RECEIPT.json b/binary-analysis/scancode-readelf-macosx/src/scancode_readelf/licenses/binutils/INSTALL_RECEIPT.json new file mode 100644 index 0000000..5dbce7a --- /dev/null +++ b/binary-analysis/scancode-readelf-macosx/src/scancode_readelf/licenses/binutils/INSTALL_RECEIPT.json @@ -0,0 +1,62 @@ +{ + "homebrew_version": "4.6.20-133-g08c0afe", + "used_options": [], + "unused_options": [], + "built_as_bottle": true, + "poured_from_bottle": true, + "loaded_from_api": true, + "installed_as_dependency": false, + "installed_on_request": true, + "changed_files": [], + "time": 1767796298, + "source_modified_time": 1762732800, + "compiler": "clang", + "aliases": [], + "runtime_dependencies": [ + { + "full_name": "lz4", + "version": "1.10.0", + "revision": 0, + "bottle_rebuild": 1, + "pkg_version": "1.10.0", + "declared_directly": false + }, + { + "full_name": "xz", + "version": "5.8.2", + "revision": 0, + "bottle_rebuild": 0, + "pkg_version": "5.8.2", + "declared_directly": false + }, + { + "full_name": "zstd", + "version": "1.5.7", + "revision": 0, + "bottle_rebuild": 1, + "pkg_version": "1.5.7", + "declared_directly": true + } + ], + "source": { + "spec": "stable", + "versions": { + "stable": "2.45.1", + "head": null, + "version_scheme": 0, + "compatibility_version": null + }, + "path": "/Users/van/Library/Caches/Homebrew/api/formula.jws.json", + "tap_git_head": "9a7c8abebc88f7eac4be163547e90ceba1f93241", + "tap": "homebrew/core" + }, + "arch": "arm64", + "built_on": { + "os": "Macintosh", + "os_version": "macOS 26", + "cpu_family": "dunno", + "xcode": "26.1", + "clt": "26.1.0.0.1.1761104275", + "preferred_perl": "5.34" + } +} \ No newline at end of file diff --git a/binary-analysis/scancode-readelf-macosx/src/scancode_readelf/licenses/binutils/README b/binary-analysis/scancode-readelf-macosx/src/scancode_readelf/licenses/binutils/README new file mode 100644 index 0000000..eb0e436 --- /dev/null +++ b/binary-analysis/scancode-readelf-macosx/src/scancode_readelf/licenses/binutils/README @@ -0,0 +1,47 @@ + README for GNU development tools + +This directory contains various GNU compilers, assemblers, linkers, +debuggers, etc., plus their support routines, definitions, and documentation. + +If you are receiving this as part of a GDB release, see the file gdb/README. +If with a binutils release, see binutils/README; if with a libg++ release, +see libg++/README, etc. That'll give you info about this +package -- supported targets, how to use it, how to report bugs, etc. + +It is now possible to automatically configure and build a variety of +tools with one command. To build all of the tools contained herein, +run the ``configure'' script here, e.g.: + + ./configure + make + +To install them (by default in /usr/local/bin, /usr/local/lib, etc), +then do: + make install + +(If the configure script can't determine your type of computer, give it +the name as an argument, for instance ``./configure sun4''. You can +use the script ``config.sub'' to test whether a name is recognized; if +it is, config.sub translates it to a triplet specifying CPU, vendor, +and OS.) + +If you have more than one compiler on your system, it is often best to +explicitly set CC in the environment before running configure, and to +also set CC when running make. For example (assuming sh/bash/ksh): + + CC=gcc ./configure + make + +A similar example using csh: + + setenv CC gcc + ./configure + make + +Much of the code and documentation enclosed is copyright by +the Free Software Foundation, Inc. See the file COPYING or +COPYING.LIB in the various directories, for a description of the +GNU General Public License terms under which you can copy the files. + +REPORTING BUGS: Again, see gdb/README, binutils/README, etc., for info +on where and how to report problems. diff --git a/binary-analysis/scancode-readelf-macosx/src/scancode_readelf/licenses/zstd/COPYING b/binary-analysis/scancode-readelf-macosx/src/scancode_readelf/licenses/zstd/COPYING new file mode 100644 index 0000000..ecbc059 --- /dev/null +++ b/binary-analysis/scancode-readelf-macosx/src/scancode_readelf/licenses/zstd/COPYING @@ -0,0 +1,339 @@ + GNU GENERAL PUBLIC LICENSE + Version 2, June 1991 + + Copyright (C) 1989, 1991 Free Software Foundation, Inc., + 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA + Everyone is permitted to copy and distribute verbatim copies + of this license document, but changing it is not allowed. + + Preamble + + The licenses for most software are designed to take away your +freedom to share and change it. By contrast, the GNU General Public +License is intended to guarantee your freedom to share and change free +software--to make sure the software is free for all its users. This +General Public License applies to most of the Free Software +Foundation's software and to any other program whose authors commit to +using it. (Some other Free Software Foundation software is covered by +the GNU Lesser General Public License instead.) You can apply it to +your programs, too. + + When we speak of free software, we are referring to freedom, not +price. Our General Public Licenses are designed to make sure that you +have the freedom to distribute copies of free software (and charge for +this service if you wish), that you receive source code or can get it +if you want it, that you can change the software or use pieces of it +in new free programs; and that you know you can do these things. + + To protect your rights, we need to make restrictions that forbid +anyone to deny you these rights or to ask you to surrender the rights. +These restrictions translate to certain responsibilities for you if you +distribute copies of the software, or if you modify it. + + For example, if you distribute copies of such a program, whether +gratis or for a fee, you must give the recipients all the rights that +you have. You must make sure that they, too, receive or can get the +source code. And you must show them these terms so they know their +rights. + + We protect your rights with two steps: (1) copyright the software, and +(2) offer you this license which gives you legal permission to copy, +distribute and/or modify the software. + + Also, for each author's protection and ours, we want to make certain +that everyone understands that there is no warranty for this free +software. If the software is modified by someone else and passed on, we +want its recipients to know that what they have is not the original, so +that any problems introduced by others will not reflect on the original +authors' reputations. + + Finally, any free program is threatened constantly by software +patents. We wish to avoid the danger that redistributors of a free +program will individually obtain patent licenses, in effect making the +program proprietary. To prevent this, we have made it clear that any +patent must be licensed for everyone's free use or not licensed at all. + + The precise terms and conditions for copying, distribution and +modification follow. + + GNU GENERAL PUBLIC LICENSE + TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION + + 0. This License applies to any program or other work which contains +a notice placed by the copyright holder saying it may be distributed +under the terms of this General Public License. The "Program", below, +refers to any such program or work, and a "work based on the Program" +means either the Program or any derivative work under copyright law: +that is to say, a work containing the Program or a portion of it, +either verbatim or with modifications and/or translated into another +language. (Hereinafter, translation is included without limitation in +the term "modification".) Each licensee is addressed as "you". + +Activities other than copying, distribution and modification are not +covered by this License; they are outside its scope. The act of +running the Program is not restricted, and the output from the Program +is covered only if its contents constitute a work based on the +Program (independent of having been made by running the Program). +Whether that is true depends on what the Program does. + + 1. You may copy and distribute verbatim copies of the Program's +source code as you receive it, in any medium, provided that you +conspicuously and appropriately publish on each copy an appropriate +copyright notice and disclaimer of warranty; keep intact all the +notices that refer to this License and to the absence of any warranty; +and give any other recipients of the Program a copy of this License +along with the Program. + +You may charge a fee for the physical act of transferring a copy, and +you may at your option offer warranty protection in exchange for a fee. + + 2. You may modify your copy or copies of the Program or any portion +of it, thus forming a work based on the Program, and copy and +distribute such modifications or work under the terms of Section 1 +above, provided that you also meet all of these conditions: + + a) You must cause the modified files to carry prominent notices + stating that you changed the files and the date of any change. + + b) You must cause any work that you distribute or publish, that in + whole or in part contains or is derived from the Program or any + part thereof, to be licensed as a whole at no charge to all third + parties under the terms of this License. + + c) If the modified program normally reads commands interactively + when run, you must cause it, when started running for such + interactive use in the most ordinary way, to print or display an + announcement including an appropriate copyright notice and a + notice that there is no warranty (or else, saying that you provide + a warranty) and that users may redistribute the program under + these conditions, and telling the user how to view a copy of this + License. (Exception: if the Program itself is interactive but + does not normally print such an announcement, your work based on + the Program is not required to print an announcement.) + +These requirements apply to the modified work as a whole. If +identifiable sections of that work are not derived from the Program, +and can be reasonably considered independent and separate works in +themselves, then this License, and its terms, do not apply to those +sections when you distribute them as separate works. But when you +distribute the same sections as part of a whole which is a work based +on the Program, the distribution of the whole must be on the terms of +this License, whose permissions for other licensees extend to the +entire whole, and thus to each and every part regardless of who wrote it. + +Thus, it is not the intent of this section to claim rights or contest +your rights to work written entirely by you; rather, the intent is to +exercise the right to control the distribution of derivative or +collective works based on the Program. + +In addition, mere aggregation of another work not based on the Program +with the Program (or with a work based on the Program) on a volume of +a storage or distribution medium does not bring the other work under +the scope of this License. + + 3. You may copy and distribute the Program (or a work based on it, +under Section 2) in object code or executable form under the terms of +Sections 1 and 2 above provided that you also do one of the following: + + a) Accompany it with the complete corresponding machine-readable + source code, which must be distributed under the terms of Sections + 1 and 2 above on a medium customarily used for software interchange; or, + + b) Accompany it with a written offer, valid for at least three + years, to give any third party, for a charge no more than your + cost of physically performing source distribution, a complete + machine-readable copy of the corresponding source code, to be + distributed under the terms of Sections 1 and 2 above on a medium + customarily used for software interchange; or, + + c) Accompany it with the information you received as to the offer + to distribute corresponding source code. (This alternative is + allowed only for noncommercial distribution and only if you + received the program in object code or executable form with such + an offer, in accord with Subsection b above.) + +The source code for a work means the preferred form of the work for +making modifications to it. For an executable work, complete source +code means all the source code for all modules it contains, plus any +associated interface definition files, plus the scripts used to +control compilation and installation of the executable. However, as a +special exception, the source code distributed need not include +anything that is normally distributed (in either source or binary +form) with the major components (compiler, kernel, and so on) of the +operating system on which the executable runs, unless that component +itself accompanies the executable. + +If distribution of executable or object code is made by offering +access to copy from a designated place, then offering equivalent +access to copy the source code from the same place counts as +distribution of the source code, even though third parties are not +compelled to copy the source along with the object code. + + 4. You may not copy, modify, sublicense, or distribute the Program +except as expressly provided under this License. Any attempt +otherwise to copy, modify, sublicense or distribute the Program is +void, and will automatically terminate your rights under this License. +However, parties who have received copies, or rights, from you under +this License will not have their licenses terminated so long as such +parties remain in full compliance. + + 5. You are not required to accept this License, since you have not +signed it. However, nothing else grants you permission to modify or +distribute the Program or its derivative works. These actions are +prohibited by law if you do not accept this License. Therefore, by +modifying or distributing the Program (or any work based on the +Program), you indicate your acceptance of this License to do so, and +all its terms and conditions for copying, distributing or modifying +the Program or works based on it. + + 6. Each time you redistribute the Program (or any work based on the +Program), the recipient automatically receives a license from the +original licensor to copy, distribute or modify the Program subject to +these terms and conditions. You may not impose any further +restrictions on the recipients' exercise of the rights granted herein. +You are not responsible for enforcing compliance by third parties to +this License. + + 7. If, as a consequence of a court judgment or allegation of patent +infringement or for any other reason (not limited to patent issues), +conditions are imposed on you (whether by court order, agreement or +otherwise) that contradict the conditions of this License, they do not +excuse you from the conditions of this License. If you cannot +distribute so as to satisfy simultaneously your obligations under this +License and any other pertinent obligations, then as a consequence you +may not distribute the Program at all. For example, if a patent +license would not permit royalty-free redistribution of the Program by +all those who receive copies directly or indirectly through you, then +the only way you could satisfy both it and this License would be to +refrain entirely from distribution of the Program. + +If any portion of this section is held invalid or unenforceable under +any particular circumstance, the balance of the section is intended to +apply and the section as a whole is intended to apply in other +circumstances. + +It is not the purpose of this section to induce you to infringe any +patents or other property right claims or to contest validity of any +such claims; this section has the sole purpose of protecting the +integrity of the free software distribution system, which is +implemented by public license practices. Many people have made +generous contributions to the wide range of software distributed +through that system in reliance on consistent application of that +system; it is up to the author/donor to decide if he or she is willing +to distribute software through any other system and a licensee cannot +impose that choice. + +This section is intended to make thoroughly clear what is believed to +be a consequence of the rest of this License. + + 8. If the distribution and/or use of the Program is restricted in +certain countries either by patents or by copyrighted interfaces, the +original copyright holder who places the Program under this License +may add an explicit geographical distribution limitation excluding +those countries, so that distribution is permitted only in or among +countries not thus excluded. In such case, this License incorporates +the limitation as if written in the body of this License. + + 9. The Free Software Foundation may publish revised and/or new versions +of the General Public License from time to time. Such new versions will +be similar in spirit to the present version, but may differ in detail to +address new problems or concerns. + +Each version is given a distinguishing version number. If the Program +specifies a version number of this License which applies to it and "any +later version", you have the option of following the terms and conditions +either of that version or of any later version published by the Free +Software Foundation. If the Program does not specify a version number of +this License, you may choose any version ever published by the Free Software +Foundation. + + 10. If you wish to incorporate parts of the Program into other free +programs whose distribution conditions are different, write to the author +to ask for permission. For software which is copyrighted by the Free +Software Foundation, write to the Free Software Foundation; we sometimes +make exceptions for this. Our decision will be guided by the two goals +of preserving the free status of all derivatives of our free software and +of promoting the sharing and reuse of software generally. + + NO WARRANTY + + 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY +FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN +OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES +PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED +OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS +TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE +PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, +REPAIR OR CORRECTION. + + 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING +WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR +REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, +INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING +OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED +TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY +YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER +PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE +POSSIBILITY OF SUCH DAMAGES. + + END OF TERMS AND CONDITIONS + + How to Apply These Terms to Your New Programs + + If you develop a new program, and you want it to be of the greatest +possible use to the public, the best way to achieve this is to make it +free software which everyone can redistribute and change under these terms. + + To do so, attach the following notices to the program. It is safest +to attach them to the start of each source file to most effectively +convey the exclusion of warranty; and each file should have at least +the "copyright" line and a pointer to where the full notice is found. + + + Copyright (C) + + This program is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License along + with this program; if not, write to the Free Software Foundation, Inc., + 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. + +Also add information on how to contact you by electronic and paper mail. + +If the program is interactive, make it output a short notice like this +when it starts in an interactive mode: + + Gnomovision version 69, Copyright (C) year name of author + Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'. + This is free software, and you are welcome to redistribute it + under certain conditions; type `show c' for details. + +The hypothetical commands `show w' and `show c' should show the appropriate +parts of the General Public License. Of course, the commands you use may +be called something other than `show w' and `show c'; they could even be +mouse-clicks or menu items--whatever suits your program. + +You should also get your employer (if you work as a programmer) or your +school, if any, to sign a "copyright disclaimer" for the program, if +necessary. Here is a sample; alter the names: + + Yoyodyne, Inc., hereby disclaims all copyright interest in the program + `Gnomovision' (which makes passes at compilers) written by James Hacker. + + , 1 April 1989 + Ty Coon, President of Vice + +This General Public License does not permit incorporating your program into +proprietary programs. If your program is a subroutine library, you may +consider it more useful to permit linking proprietary applications with the +library. If this is what you want to do, use the GNU Lesser General +Public License instead of this License. \ No newline at end of file diff --git a/binary-analysis/scancode-readelf-macosx/src/scancode_readelf/licenses/zstd/INSTALL_RECEIPT.json b/binary-analysis/scancode-readelf-macosx/src/scancode_readelf/licenses/zstd/INSTALL_RECEIPT.json new file mode 100644 index 0000000..b3455a5 --- /dev/null +++ b/binary-analysis/scancode-readelf-macosx/src/scancode_readelf/licenses/zstd/INSTALL_RECEIPT.json @@ -0,0 +1,59 @@ +{ + "homebrew_version": "4.4.21-62-g27a9032", + "used_options": [ + + ], + "unused_options": [ + + ], + "built_as_bottle": true, + "poured_from_bottle": true, + "loaded_from_api": true, + "installed_as_dependency": true, + "installed_on_request": true, + "changed_files": [ + "lib/pkgconfig/libzstd.pc" + ], + "time": 1741198360, + "source_modified_time": 1739923464, + "compiler": "clang", + "aliases": [ + "pzstd" + ], + "runtime_dependencies": [ + { + "full_name": "lz4", + "version": "1.10.0", + "revision": 0, + "pkg_version": "1.10.0", + "declared_directly": true + }, + { + "full_name": "xz", + "version": "5.6.4", + "revision": 0, + "pkg_version": "5.6.4", + "declared_directly": true + } + ], + "source": { + "spec": "stable", + "versions": { + "stable": "1.5.7", + "head": null, + "version_scheme": 0 + }, + "path": "/Users/van/Library/Caches/Homebrew/api/formula.jws.json", + "tap_git_head": "056318f4642987c0b8cac201a20740d5013961c7", + "tap": "homebrew/core" + }, + "arch": "arm64", + "built_on": { + "os": "Macintosh", + "os_version": "macOS 15", + "cpu_family": "dunno", + "xcode": "16.2", + "clt": "16.2.0.0.1.1733547573", + "preferred_perl": "5.34" + } +} \ No newline at end of file diff --git a/binary-analysis/scancode-readelf-macosx/src/scancode_readelf/licenses/zstd/LICENSE b/binary-analysis/scancode-readelf-macosx/src/scancode_readelf/licenses/zstd/LICENSE new file mode 100644 index 0000000..7580028 --- /dev/null +++ b/binary-analysis/scancode-readelf-macosx/src/scancode_readelf/licenses/zstd/LICENSE @@ -0,0 +1,30 @@ +BSD License + +For Zstandard software + +Copyright (c) Meta Platforms, Inc. and affiliates. All rights reserved. + +Redistribution and use in source and binary forms, with or without modification, +are permitted provided that the following conditions are met: + + * Redistributions of source code must retain the above copyright notice, this + list of conditions and the following disclaimer. + + * Redistributions in binary form must reproduce the above copyright notice, + this list of conditions and the following disclaimer in the documentation + and/or other materials provided with the distribution. + + * Neither the name Facebook, nor Meta, nor the names of its contributors may + be used to endorse or promote products derived from this software without + specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND +ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED +WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE +DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR +ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES +(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; +LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON +ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS +SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. diff --git a/binary-analysis/scancode-readelf-macosx/src/scancode_readelf/licenses/zstd/README.md b/binary-analysis/scancode-readelf-macosx/src/scancode_readelf/licenses/zstd/README.md new file mode 100644 index 0000000..d91ef5d --- /dev/null +++ b/binary-analysis/scancode-readelf-macosx/src/scancode_readelf/licenses/zstd/README.md @@ -0,0 +1,237 @@ +

Zstandard

+ +__Zstandard__, or `zstd` as short version, is a fast lossless compression algorithm, +targeting real-time compression scenarios at zlib-level and better compression ratios. +It's backed by a very fast entropy stage, provided by [Huff0 and FSE library](https://github.com/Cyan4973/FiniteStateEntropy). + +Zstandard's format is stable and documented in [RFC8878](https://datatracker.ietf.org/doc/html/rfc8878). Multiple independent implementations are already available. +This repository represents the reference implementation, provided as an open-source dual [BSD](LICENSE) OR [GPLv2](COPYING) licensed **C** library, +and a command line utility producing and decoding `.zst`, `.gz`, `.xz` and `.lz4` files. +Should your project require another programming language, +a list of known ports and bindings is provided on [Zstandard homepage](https://facebook.github.io/zstd/#other-languages). + +**Development branch status:** + +[![Build Status][travisDevBadge]][travisLink] +[![Build status][CircleDevBadge]][CircleLink] +[![Build status][CirrusDevBadge]][CirrusLink] +[![Fuzzing Status][OSSFuzzBadge]][OSSFuzzLink] + +[travisDevBadge]: https://api.travis-ci.com/facebook/zstd.svg?branch=dev "Continuous Integration test suite" +[travisLink]: https://travis-ci.com/facebook/zstd +[CircleDevBadge]: https://circleci.com/gh/facebook/zstd/tree/dev.svg?style=shield "Short test suite" +[CircleLink]: https://circleci.com/gh/facebook/zstd +[CirrusDevBadge]: https://api.cirrus-ci.com/github/facebook/zstd.svg?branch=dev +[CirrusLink]: https://cirrus-ci.com/github/facebook/zstd +[OSSFuzzBadge]: https://oss-fuzz-build-logs.storage.googleapis.com/badges/zstd.svg +[OSSFuzzLink]: https://bugs.chromium.org/p/oss-fuzz/issues/list?sort=-opened&can=1&q=proj:zstd + +## Benchmarks + +For reference, several fast compression algorithms were tested and compared +on a desktop featuring a Core i7-9700K CPU @ 4.9GHz +and running Ubuntu 20.04 (`Linux ubu20 5.15.0-101-generic`), +using [lzbench], an open-source in-memory benchmark by @inikep +compiled with [gcc] 9.4.0, +on the [Silesia compression corpus]. + +[lzbench]: https://github.com/inikep/lzbench +[Silesia compression corpus]: https://sun.aei.polsl.pl//~sdeor/index.php?page=silesia +[gcc]: https://gcc.gnu.org/ + +| Compressor name | Ratio | Compression| Decompress.| +| --------------- | ------| -----------| ---------- | +| **zstd 1.5.6 -1** | 2.887 | 510 MB/s | 1580 MB/s | +| [zlib] 1.2.11 -1 | 2.743 | 95 MB/s | 400 MB/s | +| brotli 1.0.9 -0 | 2.702 | 395 MB/s | 430 MB/s | +| **zstd 1.5.6 --fast=1** | 2.437 | 545 MB/s | 1890 MB/s | +| **zstd 1.5.6 --fast=3** | 2.239 | 650 MB/s | 2000 MB/s | +| quicklz 1.5.0 -1 | 2.238 | 525 MB/s | 750 MB/s | +| lzo1x 2.10 -1 | 2.106 | 650 MB/s | 825 MB/s | +| [lz4] 1.9.4 | 2.101 | 700 MB/s | 4000 MB/s | +| lzf 3.6 -1 | 2.077 | 420 MB/s | 830 MB/s | +| snappy 1.1.9 | 2.073 | 530 MB/s | 1660 MB/s | + +[zlib]: https://www.zlib.net/ +[lz4]: https://lz4.github.io/lz4/ + +The negative compression levels, specified with `--fast=#`, +offer faster compression and decompression speed +at the cost of compression ratio. + +Zstd can also offer stronger compression ratios at the cost of compression speed. +Speed vs Compression trade-off is configurable by small increments. +Decompression speed is preserved and remains roughly the same at all settings, +a property shared by most LZ compression algorithms, such as [zlib] or lzma. + +The following tests were run +on a server running Linux Debian (`Linux version 4.14.0-3-amd64`) +with a Core i7-6700K CPU @ 4.0GHz, +using [lzbench], an open-source in-memory benchmark by @inikep +compiled with [gcc] 7.3.0, +on the [Silesia compression corpus]. + +Compression Speed vs Ratio | Decompression Speed +---------------------------|-------------------- +![Compression Speed vs Ratio](doc/images/CSpeed2.png "Compression Speed vs Ratio") | ![Decompression Speed](doc/images/DSpeed3.png "Decompression Speed") + +A few other algorithms can produce higher compression ratios at slower speeds, falling outside of the graph. +For a larger picture including slow modes, [click on this link](doc/images/DCspeed5.png). + + +## The case for Small Data compression + +Previous charts provide results applicable to typical file and stream scenarios (several MB). Small data comes with different perspectives. + +The smaller the amount of data to compress, the more difficult it is to compress. This problem is common to all compression algorithms, and reason is, compression algorithms learn from past data how to compress future data. But at the beginning of a new data set, there is no "past" to build upon. + +To solve this situation, Zstd offers a __training mode__, which can be used to tune the algorithm for a selected type of data. +Training Zstandard is achieved by providing it with a few samples (one file per sample). The result of this training is stored in a file called "dictionary", which must be loaded before compression and decompression. +Using this dictionary, the compression ratio achievable on small data improves dramatically. + +The following example uses the `github-users` [sample set](https://github.com/facebook/zstd/releases/tag/v1.1.3), created from [github public API](https://developer.github.com/v3/users/#get-all-users). +It consists of roughly 10K records weighing about 1KB each. + +Compression Ratio | Compression Speed | Decompression Speed +------------------|-------------------|-------------------- +![Compression Ratio](doc/images/dict-cr.png "Compression Ratio") | ![Compression Speed](doc/images/dict-cs.png "Compression Speed") | ![Decompression Speed](doc/images/dict-ds.png "Decompression Speed") + + +These compression gains are achieved while simultaneously providing _faster_ compression and decompression speeds. + +Training works if there is some correlation in a family of small data samples. The more data-specific a dictionary is, the more efficient it is (there is no _universal dictionary_). +Hence, deploying one dictionary per type of data will provide the greatest benefits. +Dictionary gains are mostly effective in the first few KB. Then, the compression algorithm will gradually use previously decoded content to better compress the rest of the file. + +### Dictionary compression How To: + +1. Create the dictionary + + `zstd --train FullPathToTrainingSet/* -o dictionaryName` + +2. Compress with dictionary + + `zstd -D dictionaryName FILE` + +3. Decompress with dictionary + + `zstd -D dictionaryName --decompress FILE.zst` + + +## Build instructions + +`make` is the officially maintained build system of this project. +All other build systems are "compatible" and 3rd-party maintained, +they may feature small differences in advanced options. +When your system allows it, prefer using `make` to build `zstd` and `libzstd`. + +### Makefile + +If your system is compatible with standard `make` (or `gmake`), +invoking `make` in root directory will generate `zstd` cli in root directory. +It will also create `libzstd` into `lib/`. + +Other available options include: +- `make install` : create and install zstd cli, library and man pages +- `make check` : create and run `zstd`, test its behavior on local platform + +The `Makefile` follows the [GNU Standard Makefile conventions](https://www.gnu.org/prep/standards/html_node/Makefile-Conventions.html), +allowing staged install, standard flags, directory variables and command variables. + +For advanced use cases, specialized compilation flags which control binary generation +are documented in [`lib/README.md`](lib/README.md#modular-build) for the `libzstd` library +and in [`programs/README.md`](programs/README.md#compilation-variables) for the `zstd` CLI. + +### cmake + +A `cmake` project generator is provided within `build/cmake`. +It can generate Makefiles or other build scripts +to create `zstd` binary, and `libzstd` dynamic and static libraries. + +By default, `CMAKE_BUILD_TYPE` is set to `Release`. + +#### Support for Fat (Universal2) Output + +`zstd` can be built and installed with support for both Apple Silicon (M1/M2) as well as Intel by using CMake's Universal2 support. +To perform a Fat/Universal2 build and install use the following commands: + +```bash +cmake -B build-cmake-debug -S build/cmake -G Ninja -DCMAKE_OSX_ARCHITECTURES="x86_64;x86_64h;arm64" +cd build-cmake-debug +ninja +sudo ninja install +``` + +### Meson + +A Meson project is provided within [`build/meson`](build/meson). Follow +build instructions in that directory. + +You can also take a look at [`.travis.yml`](.travis.yml) file for an +example about how Meson is used to build this project. + +Note that default build type is **release**. + +### VCPKG +You can build and install zstd [vcpkg](https://github.com/Microsoft/vcpkg/) dependency manager: + + git clone https://github.com/Microsoft/vcpkg.git + cd vcpkg + ./bootstrap-vcpkg.sh + ./vcpkg integrate install + ./vcpkg install zstd + +The zstd port in vcpkg is kept up to date by Microsoft team members and community contributors. +If the version is out of date, please [create an issue or pull request](https://github.com/Microsoft/vcpkg) on the vcpkg repository. + +### Conan + +You can install pre-built binaries for zstd or build it from source using [Conan](https://conan.io/). Use the following command: + +```bash +conan install --requires="zstd/[*]" --build=missing +``` + +The zstd Conan recipe is kept up to date by Conan maintainers and community contributors. +If the version is out of date, please [create an issue or pull request](https://github.com/conan-io/conan-center-index) on the ConanCenterIndex repository. + +### Visual Studio (Windows) + +Going into `build` directory, you will find additional possibilities: +- Projects for Visual Studio 2005, 2008 and 2010. + + VS2010 project is compatible with VS2012, VS2013, VS2015 and VS2017. +- Automated build scripts for Visual compiler by [@KrzysFR](https://github.com/KrzysFR), in `build/VS_scripts`, + which will build `zstd` cli and `libzstd` library without any need to open Visual Studio solution. + +### Buck + +You can build the zstd binary via buck by executing: `buck build programs:zstd` from the root of the repo. +The output binary will be in `buck-out/gen/programs/`. + +### Bazel + +You easily can integrate zstd into your Bazel project by using the module hosted on the [Bazel Central Repository](https://registry.bazel.build/modules/zstd). + +## Testing + +You can run quick local smoke tests by running `make check`. +If you can't use `make`, execute the `playTest.sh` script from the `src/tests` directory. +Two env variables `$ZSTD_BIN` and `$DATAGEN_BIN` are needed for the test script to locate the `zstd` and `datagen` binary. +For information on CI testing, please refer to `TESTING.md`. + +## Status + +Zstandard is currently deployed within Facebook and many other large cloud infrastructures. +It is run continuously to compress large amounts of data in multiple formats and use cases. +Zstandard is considered safe for production environments. + +## License + +Zstandard is dual-licensed under [BSD](LICENSE) OR [GPLv2](COPYING). + +## Contributing + +The `dev` branch is the one where all contributions are merged before reaching `release`. +If you plan to propose a patch, please commit into the `dev` branch, or its own feature branch. +Direct commit to `release` are not permitted. +For more information, please read [CONTRIBUTING](CONTRIBUTING.md). diff --git a/builtins/extractcode_7z-linux/src/extractcode_7z/bin/7z b/builtins/extractcode_7z-linux/src/extractcode_7z/bin/7z index 5ea1195..e516b64 100755 Binary files a/builtins/extractcode_7z-linux/src/extractcode_7z/bin/7z and b/builtins/extractcode_7z-linux/src/extractcode_7z/bin/7z differ diff --git a/builtins/extractcode_7z-linux/src/extractcode_7z/licenses/7zip/History.txt b/builtins/extractcode_7z-linux/src/extractcode_7z/licenses/7zip/History.txt new file mode 100644 index 0000000..4caf138 --- /dev/null +++ b/builtins/extractcode_7z-linux/src/extractcode_7z/licenses/7zip/History.txt @@ -0,0 +1,178 @@ +HISTORY of the 7-Zip +-------------------- + +This file contains information about changes for latest versions of 7-Zip. +The full changelog file can be downloaded here: +https://7-zip.org/history.txt + +25.01 2025-08-03 +------------------------- +- The code for handling symbolic links has been changed + to provide greater security when extracting files from archives. + Command line switch -snld20 can be used to bypass default security + checks when creating symbolic links. + + +25.00 2025-07-05 +------------------------- +- 7-Zip for Windows can now use more than 64 CPU threads for compression + to zip/7z/xz archives and for the 7-Zip benchmark. + If there are more than one processor group in Windows (on systems with more than + 64 cpu threads), 7-Zip distributes running CPU threads across different processor groups. +- bzip2 compression speed was increased by 15-40%. +- deflate (zip/gz) compression speed was increased by 1-3%. +- improved support for zip, cpio and fat archives. +- fixed some bugs and vulnerabilities. +- the bug was fixed : CVE-2025-53816 : 7-Zip could work incorrectly for some incorrect RAR archives. +- the bug was fixed : CVE-2025-53817 : 7-Zip could crash for some incorrect COM (Compound File) archives. + + +24.09 2024-11-29 +------------------------- +- The default dictionary size values for LZMA/LZMA2 compression methods were increased: + dictionary size compression level + v24.08 v24.09 v24.09 + 32-bit 64-bit + 8 MB 16 MB 16 MB -mx4 + 16 MB 32 MB 32 MB -mx5 : Normal + 32 MB 64 MB 64 MB -mx6 + 32 MB 64 MB 128 MB -mx7 : Maximum + 64 MB 64 MB 256 MB -mx8 + 64 MB 64 MB 256 MB -mx9 : Ultra + The default dictionary size values for 32-bit versions of LZMA/LZMA2 don't exceed 64 MB. +- 7-Zip now can calculate the following hash checksums: SHA-512, SHA-384, SHA3-256 and MD5. +- APM and HFS support was improved. +- If an archive update operation uses a temporary archive folder and + the archive is moved to the destination folder, 7-Zip shows the progress of moving + the archive file, as this operation can take a long time if the archive is large. +- The bug was fixed: 7-Zip File Manager didn't propagate Zone.Identifier stream + for extracted files from nested archives (if there is open archive inside another open archive). +- Some bugs were fixed. + + +24.08 2024-08-11 +------------------------- +- The bug in 7-Zip 24.00-24.07 was fixed: + For creating a zip archive: 7-Zip could write extra zero bytes after the end of the archive, + if a file included to archive cannot be compressed to a size smaller than original. + The created zip archive is correct except for the useless zero bytes after the end of the archive. + When unpacking such a zip archive, 7-Zip displays a warning: + "WARNING: There are data after the end of archive". +- The bug was fixed: there was a leak of GDI objects (internal resources in Windows) + in "Confirm File Replace" window, causing problems after 1600 displays of "Confirm File Replace" + window from same running 7-Zip process. +- Some optimizations for displaying file icons in 7-Zip File Manager and in "Confirm File Replace" window. +- Some bugs were fixed. + + +24.07 2024-06-19 +------------------------- +- The bug was fixed: 7-Zip could crash for some incorrect ZSTD archives. + + +24.06 2024-05-26 +------------------------- +- The bug was fixed: 7-Zip could not unpack some ZSTD archives. + + +24.05 2024-05-14 +------------------------- +- New switch -myv={MMNN} to set decoder compatibility version for 7z archive creating. + {MMNN} is 4-digit number that represents the version of 7-Zip without a dot. + If -myv={MMNN} switch is specified, 7-Zip will only use compression methods that can + be decoded by the specified version {MMNN} of 7-Zip and newer versions. + If -myv={MMNN} switch is not specified, -myv=2300 is used, and 7-Zip will only + use compression methods that can be decoded by 7-Zip 23.00 and newer versions. +- New switch -myfa={FilterID} to allow 7-Zip to use the specified filter method for 7z archive creating. +- New switch -myfd={FilterID} to disallow 7-Zip to use the specified filter method for 7z archive creating. +- Some bugs were fixed. + + +24.04 2024-04-05 +------------------------- +- New menu item in 7-Zip File Manager: "Tools / Delete Temporary Files...". + This menu item opens a window showing temporary folders and files + created by 7-Zip in the user's "Temp" folder on a Windows system. + In this window, the user can delete temporary files. + + +24.03 2024-03-23 +------------------------- +- 7-Zip now can use new RISCV filter for compression to 7z and xz archives. + RISCV filter can increase compression ratio for data containing executable + files compiled for RISC-V architecture. +- The speed for LZMA and LZMA2 decompression in ARM64 version for Windows + was increased by 20%-60%. +- 7-Zip GUI and 7-Zip File Manager can ask user permission to unpack RAR archives that + require big amount of memory, if the dictionary size in RAR archive is larger than 4 GB. +- new switch -smemx{size}g : to set allowed memory usage limit for RAR archive unpacking. + RAR archives can use dictionary up 64 GB. Default allowed limit for RAR unpacking is 4 GB. +- 7zg.exe (7-Zip GUI): -y switch disables user requests and messages. +- 7-Zip shows hash methods XXH64 and BLAKE2sp in context menu. +- -slmu switch : to show timestamps as UTC instead of LOCAL TIME. +- -slsl switch : in console 7-Zip for Windows : to show file paths with + linux path separator slash '/' instead of backslash separator '\'. +- 7-Zip supports .sha256 files that use backslash path separator '\'. +- Some bugs were fixed. + + +24.01 2024-01-31 +------------------------- +- 7-Zip now can unpack ZSTD archives (.zst filename extension). +- 7-Zip now can unpack ZIP, SquashFS and RPM archives that use ZSTD compression method. +- 7-Zip now supports fast hash algorithm XXH64 that is used in ZSTD. +- 7-Zip now can unpack RAR archives (that use larger than 4 GB dictionary) created by new WinRAR 7.00. +- 7-Zip now can unpack DMG archives that use XZ (ULMO/LZMA) compression method. +- 7-Zip now can unpack NTFS images with cluster size larger than 64 KB. +- 7-Zip now can unpack MBR and GPT images with 4 KB sectors. +- Speed optimizations for archive unpacking: rar, cab, wim, zip, gz. +- Speed optimizations for hash caclulation: CRC-32, CRC-64, BLAKE2sp. +- The bug was fixed: 7-Zip for Linux could fail for multivolume creation in some cases. +- Some bugs were fixed. + + +23.01 2023-06-20 +------------------------- +- The page "Language" in 7-Zip's menu Tools/Options now shows information + about selected translation, including the number of translated lines. +- Some bugs were fixed. + + +23.00 2023-05-07 +------------------------- +- 7-Zip now can use new ARM64 filter for compression to 7z and xz archives. + ARM64 filter can increase compression ratio for data containing executable + files compiled for ARM64 (AArch64) architecture. + Also 7-Zip now parses executable files (that have exe and dll filename extensions) + before compressing, and it selects appropriate filter for each parsed file: + - BCJ or BCJ2 filter for x86 executable files, + - ARM64 filter for ARM64 executable files. + Previous versions by default used x86 filter BCJ or BCJ2 for all exe/dll files. +- Default section size for BCJ2 filter was changed from 64 MiB to 240 MiB. + It can increase compression ratio for executable files larger than 64 MiB. +- UDF: support was improved. +- cpio: support for hard links. +- Some changes and optimizations in WIM creation code. +- When new 7-Zip creates multivolume archive, 7-Zip keeps in open state + only volumes that still can be changed. Previous versions kept all volumes + in open state until the end of the archive creation. +- 7-Zip for Linux and macOS now can reduce the number of simultaneously open files, + when 7-Zip opens, extracts or creates multivolume archive. It allows to avoid + the failures for cases with big number of volumes, bacause there is a limitation + for number of open files allowed for a single program in Linux and macOS. +- There are optimizations in code for 7-Zip's context menu in Explorer: + the speed of preparing of the menu showing was improved for cases when big number of + files were selected by external program for context menu that contains 7-Zip menu commands. +- There are changes in code for the drag-and-drop operations to and from 7-Zip File Manager. + And the drag-and-drop operation with right button of mouse now is supported for some cases. +- The bugs were fixed: + - ZIP archives: if multithreaded zip compression was performed with more than one + file to stdout stream (-so switch), 7-Zip didn't write "data descriptor" for some files. + - ext4 archives: 7-Zip couldn't correctly extract symbolic link to directory from ext4 archives. + - HFS and APFS archives: 7-Zip incorrectly decoded uncompressed blocks (64 KiB) in compressed forks. + - HFS : zlib without Adler supported + - Some another bugs were fixed. + + +== +End of document diff --git a/builtins/extractcode_7z-linux/src/extractcode_7z/licenses/7zip/License.txt b/builtins/extractcode_7z-linux/src/extractcode_7z/licenses/7zip/License.txt new file mode 100644 index 0000000..64ebf46 --- /dev/null +++ b/builtins/extractcode_7z-linux/src/extractcode_7z/licenses/7zip/License.txt @@ -0,0 +1,144 @@ + 7-Zip for Linux and macOS + ~~~~~~~~~~~~~~~~~~~~~~~~~ + License for use and distribution + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + + 7-Zip Copyright (C) 1999-2025 Igor Pavlov. + + The licenses for 7zz and 7zzs files are: + + - The "GNU LGPL" as main license for most of the code + - The "GNU LGPL" with "unRAR license restriction" for some code + - The "BSD 3-clause License" for some code + - The "BSD 2-clause License" for some code + + Redistributions in binary form must reproduce related license information from this file. + + Note: + You can use 7-Zip on any computer, including a computer in a commercial + organization. You don't need to register or pay for 7-Zip. + + +GNU LGPL information +-------------------- + + This library is free software; you can redistribute it and/or + modify it under the terms of the GNU Lesser General Public + License as published by the Free Software Foundation; either + version 2.1 of the License, or (at your option) any later version. + + This library is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + Lesser General Public License for more details. + + You can receive a copy of the GNU Lesser General Public License from + http://www.gnu.org/ + + + + +BSD 3-clause License in 7-Zip code +---------------------------------- + + The "BSD 3-clause License" is used for the following code in 7z.dll + 1) LZFSE data decompression. + That code was derived from the code in the "LZFSE compression library" developed by Apple Inc, + that also uses the "BSD 3-clause License". + 2) ZSTD data decompression. + that code was developed using original zstd decoder code as reference code. + The original zstd decoder code was developed by Facebook Inc, + that also uses the "BSD 3-clause License". + + Copyright (c) 2015-2016, Apple Inc. All rights reserved. + Copyright (c) Facebook, Inc. All rights reserved. + Copyright (c) 2023-2024 Igor Pavlov. + +Text of the "BSD 3-clause License" +---------------------------------- + +Redistribution and use in source and binary forms, with or without modification, +are permitted provided that the following conditions are met: + +1. Redistributions of source code must retain the above copyright notice, this + list of conditions and the following disclaimer. + +2. Redistributions in binary form must reproduce the above copyright notice, + this list of conditions and the following disclaimer in the documentation + and/or other materials provided with the distribution. + +3. Neither the name of the copyright holder nor the names of its contributors may + be used to endorse or promote products derived from this software without + specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND +ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED +WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE +DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR +ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES +(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; +LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON +ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS +SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +--- + + + + +BSD 2-clause License in 7-Zip code +---------------------------------- + + The "BSD 2-clause License" is used for the XXH64 code in 7-Zip. + + XXH64 code in 7-Zip was derived from the original XXH64 code developed by Yann Collet. + + Copyright (c) 2012-2021 Yann Collet. + Copyright (c) 2023-2024 Igor Pavlov. + +Text of the "BSD 2-clause License" +---------------------------------- + +Redistribution and use in source and binary forms, with or without modification, +are permitted provided that the following conditions are met: + +1. Redistributions of source code must retain the above copyright notice, this + list of conditions and the following disclaimer. + +2. Redistributions in binary form must reproduce the above copyright notice, + this list of conditions and the following disclaimer in the documentation + and/or other materials provided with the distribution. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND +ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED +WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE +DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR +ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES +(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; +LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON +ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS +SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +--- + + + + +unRAR license restriction +------------------------- + +The decompression engine for RAR archives was developed using source +code of unRAR program. +All copyrights to original unRAR code are owned by Alexander Roshal. + +The license for original unRAR code has the following restriction: + + The unRAR sources cannot be used to re-create the RAR compression algorithm, + which is proprietary. Distribution of modified unRAR sources in separate form + or as a part of other software is permitted, provided that it is clearly + stated in the documentation and source comments that the code may + not be used to develop a RAR (WinRAR) compatible archiver. + +-- diff --git a/builtins/extractcode_7z-linux/src/extractcode_7z/licenses/7zip/readme.txt b/builtins/extractcode_7z-linux/src/extractcode_7z/licenses/7zip/readme.txt new file mode 100644 index 0000000..78f5305 --- /dev/null +++ b/builtins/extractcode_7z-linux/src/extractcode_7z/licenses/7zip/readme.txt @@ -0,0 +1,100 @@ +7-Zip 25.01 for Linux and macOS +------------------------------- + +7-Zip is a file archiver for Windows/Linux/macOS. + +7-Zip Copyright (C) 1999-2025 Igor Pavlov. + +The main features of 7-Zip: + + - High compression ratio in the new 7z format + - Supported formats: + - Packing / unpacking: 7z, XZ, BZIP2, GZIP, TAR, ZIP and WIM. + - Unpacking only: APFS, AR, ARJ, Base64, CAB, CHM, CPIO, CramFS, DMG, EXT, FAT, GPT, HFS, + IHEX, ISO, LZH, LZMA, MBR, MSI, NSIS, NTFS, QCOW2, RAR, + RPM, SquashFS, UDF, UEFI, VDI, VHD, VHDX, VMDK, XAR, Z and ZSTD. + - Fast compression and decompression + - Strong AES-256 encryption in 7z and ZIP formats + +7-Zip is free software distributed under the GNU LGPL (except of some code with another license rules). +Read License.txt for more information about license. + +This distribution package contains the following files: + + 7zz - standalone console version of 7-Zip (version compiled for dynamic system library linking) + 7zzs - standalone console version of 7-Zip (version compiled with static system library linking) + readme.txt - this file + License.txt - license information + History.txt - History of 7-Zip + MANUAL - User's Manual in HTML format + + +7-Zip and p7zip +=============== +Now there are two different ports of 7-Zip for Linux/macOS: + +1) p7zip - another port of 7-Zip for Linux, made by an independent developer. + The latest version of p7zip now is 16.02, and that p7zip 16.02 is outdated now. + +2) 7-Zip for Linux/macOS - this package - it's new code with all changes from latest 7-Zip for Windows. + +These two ports are not identical. +Note also that some Linux specific things can be implemented better in p7zip than in new 7-Zip for Linux. + + +There are several main executables in 7-Zip and p7zip: + + 7zz (7-Zip) - standalone full version of 7-Zip that supports all formats. + + 7zzs (7-Zip) - standalone full version of 7-Zip that supports all formats (static library linking). + + + 7z (p7zip) - 7-Zip that requires 7z.so shared library, and it supports all formats via 7z.so. + + 7zr (p7zip) - standalone reduced version of 7-Zip that supports some 7-Zip's formats: + 7z, xz, lzma and split. + + 7za (p7zip) - standalone version of 7-Zip that supports some main formats: + 7z, xz, lzma, zip, bzip2, gzip, tar, cab, ppmd and split. + +7zzs is similar to 7zz, but 7zzs was compiled for static library linking, +so 7zzs does not use external shared library (".so") files. +You can use 7zzs, if 7zz does not work due to lack of required shared library (".so") files. + +The command line syntax for executables from p7zip is similar to 7zz syntax from this package. + +The manual of 7-Zip and p7zip can show `7z` in command examples. +But you can use `7zz`, `7zr`, `7za` instead of `7z` from examples. + + +Example commands +================ + +Note: 7-Zip supports filename wildcards in commands. +You must use the quotes for filenames, if you want to use 7-Zip parser for wildcards +instead of the parser of system shell. + +To create zip archive from all *.txt files in current directory: + ./7zz a archive.zip "*.txt" + +To list the contents of archive: + ./7zz l archive.zip + +To list the contents of archive with detailed technical information for each file: + ./7zz l archive.zip -slt + +To extract archive to current directory: + ./7zz x archive.zip + +To test archive and show the log for each file: + ./7zz t archive.zip -bb + +The benchmark command to test the performance of CPU with 7-Zip's LZMA code: + ./7zz b + +The benchmark command to test the performance of CPU with different compression, encryption +and hash methods from 7-Zip and with different number of threads: + ./7zz b "-mm=*" "-mmt=*" + +--- +End of document diff --git a/builtins/extractcode_7z-macosx/setup.cfg b/builtins/extractcode_7z-macosx/setup.cfg index ef9e33f..4cfbc3d 100755 --- a/builtins/extractcode_7z-macosx/setup.cfg +++ b/builtins/extractcode_7z-macosx/setup.cfg @@ -5,4 +5,4 @@ license_files = apache-2.0.LICENSE [aliases] -release = clean --all bdist_wheel --plat-name macosx_10_14_x86_64 --python-tag py3 +release = clean --all bdist_wheel --plat-name macosx_15_0_arm64 --python-tag py3 diff --git a/builtins/extractcode_7z-macosx/src/extractcode_7z/bin/7z b/builtins/extractcode_7z-macosx/src/extractcode_7z/bin/7z index c4d0ace..92beee3 100755 Binary files a/builtins/extractcode_7z-macosx/src/extractcode_7z/bin/7z and b/builtins/extractcode_7z-macosx/src/extractcode_7z/bin/7z differ diff --git a/builtins/extractcode_7z-macosx/src/extractcode_7z/bin/7z.so b/builtins/extractcode_7z-macosx/src/extractcode_7z/bin/7z.so index f000b0d..9ba9a89 100755 Binary files a/builtins/extractcode_7z-macosx/src/extractcode_7z/bin/7z.so and b/builtins/extractcode_7z-macosx/src/extractcode_7z/bin/7z.so differ diff --git a/builtins/extractcode_7z-macosx/src/extractcode_7z/licenses/p7zip/ChangeLog b/builtins/extractcode_7z-macosx/src/extractcode_7z/licenses/p7zip/ChangeLog index daabd8e..1895875 100755 --- a/builtins/extractcode_7z-macosx/src/extractcode_7z/licenses/p7zip/ChangeLog +++ b/builtins/extractcode_7z-macosx/src/extractcode_7z/licenses/p7zip/ChangeLog @@ -1,7 +1,82 @@ +Version 17.05 +============= -Version 16.02 +- add UTF-8 support for Client7z +- fix issue 130 + +Version 17.04 +============= + +- add lzip decompress +- update zstd 1.4.9 + +Version 17.03 +============= + + - add zstd to zip + - add hash algorithm + - XXHASH32 + - XXHASH64 + - MD2 + - MD4 + - MD5 + - sha384 + - sha512 + - add Lzfse to dmg + - add lz5 to 7z + - add lizard to 7z + - update lz4 to v1.9.3 + - add brotli to 7z + - update cmake build + - fix xz crc64 error + - use system local to select OEM code + - add rpm install + - fix lzma2 and flzma22 call the same algorithm + - add 7zr build + - fix tar format link file compress and decompress + +Version 17.02 ============= + - p7zip 17.02 is more like 7zip 17.01(only 7za and 7z),The difference from 7zip 17.01 + and older version p7zip is the following description + - Supports Fast lzma2 1.0.1 compression method + - Update Zstd method to 1.4.5 + - Add zstd method parameters in 7z format + ZSTD parameters NEW name: + strategy -> strat + fast -> fast + long -> long + WindowLog -> wlog + HashLog -> hlog + ChainLog -> clog + SearchLog -> slog + MinMatch -> slen + TargetLen -> tlen + OverlapLog -> ovlog + LdmHashLog -> ldmhlog + LdmSearchLength -> ldmslen + LdmBucketSizeLog -> ldmblog + LdmHashRateLog -> ldmhevery + - Fix symlink files contained inside tar and squashfs as regular file + - Add lz4 and Zstd decompress method to squashfs + +Version 17.01 +============= + + - Fix BUG CVE-2018-10115 + - Fix BUG CVE-2018-5996 + - Fix BUG CVE-2017-17969 + - Fix BUG CVE-2016-9296 + +Version 17.00 +============= + + - Supports Zstd 1.4.4 compression method + - Supports Lz4 1.9.2 compression method + +Version 16.02 +============= - From Windows version of 7-Zip 16.02: - The BUG in 16.00 - 16.01 was fixed: 7-Zip mistakenly reported the warning diff --git a/builtins/extractcode_7z-macosx/src/extractcode_7z/licenses/p7zip/INSTALL_RECEIPT.json b/builtins/extractcode_7z-macosx/src/extractcode_7z/licenses/p7zip/INSTALL_RECEIPT.json index ee14717..cb9c16d 100755 --- a/builtins/extractcode_7z-macosx/src/extractcode_7z/licenses/p7zip/INSTALL_RECEIPT.json +++ b/builtins/extractcode_7z-macosx/src/extractcode_7z/licenses/p7zip/INSTALL_RECEIPT.json @@ -1 +1,48 @@ -{"homebrew_version":"2.7.2","used_options":[],"unused_options":[],"built_as_bottle":true,"poured_from_bottle":false,"installed_as_dependency":false,"installed_on_request":true,"changed_files":["bin/7z","bin/7za","bin/7zr","INSTALL_RECEIPT.json","README","share/doc/p7zip/README","share/man/man1/7z.1","share/man/man1/7za.1","share/man/man1/7zr.1"],"time":null,"source_modified_time":1468488571,"HEAD":null,"stdlib":"libcxx","compiler":"clang","aliases":[],"runtime_dependencies":[],"source":{"path":"@@HOMEBREW_REPOSITORY@@/Library/Taps/homebrew/homebrew-core/Formula/p7zip.rb","tap":"homebrew/core","spec":"stable","versions":{"stable":"16.02","head":"","version_scheme":0}},"arch":"x86_64","built_on":{"os":"Macintosh","os_version":"macOS 10.14.6","cpu_family":"penryn","xcode":"11.3.1","clt":"11.3.1.0.1.1576735732"}} \ No newline at end of file +{ + "homebrew_version": "4.4.15-8-g798f91c", + "used_options": [ + + ], + "unused_options": [ + + ], + "built_as_bottle": true, + "poured_from_bottle": true, + "loaded_from_api": true, + "installed_as_dependency": false, + "installed_on_request": true, + "changed_files": [ + "bin/7z", + "bin/7za", + "bin/7zr" + ], + "time": 1736783488, + "source_modified_time": 1729152220, + "compiler": "clang", + "aliases": [ + + ], + "runtime_dependencies": [ + + ], + "source": { + "spec": "stable", + "versions": { + "stable": "17.06", + "head": null, + "version_scheme": 0 + }, + "path": "/Users/van/Library/Caches/Homebrew/api/formula.jws.json", + "tap_git_head": "837c370994539400f405d8c70dd7c8ed59e7c0b2", + "tap": "homebrew/core" + }, + "arch": "arm64", + "built_on": { + "os": "Macintosh", + "os_version": "macOS 15", + "cpu_family": "dunno", + "xcode": "16.2", + "clt": "16.2.0.0.1.1733547573", + "preferred_perl": "5.34" + } +} \ No newline at end of file diff --git a/builtins/extractcode_7z-macosx/src/extractcode_7z/licenses/p7zip/README b/builtins/extractcode_7z-macosx/src/extractcode_7z/licenses/p7zip/README index b3afa2c..01f0c77 100755 --- a/builtins/extractcode_7z-macosx/src/extractcode_7z/licenses/p7zip/README +++ b/builtins/extractcode_7z-macosx/src/extractcode_7z/licenses/p7zip/README @@ -1,7 +1,7 @@ - p7zip 16.02 + p7zip 17.05 =========== -Homepage : http://p7zip.sourceforge.net/ +Homepage : https://github.com/p7zip-project/p7zip p7zip is a port of the Windows programs 7z.exe and 7za.exe provided by 7-zip. @@ -182,12 +182,12 @@ INSTALL : -------- - edit install.sh to change DEST_HOME - ./install.sh : to install - Remark : you must be "root" to install 7za in the directory "@@HOMEBREW_PREFIX@@" + Remark : you must be "root" to install 7za in the directory "/usr/local" method 2 -------- - 7za is a stand-alone program, you can put this program where you want. - example : cp bin/7za @@HOMEBREW_PREFIX@@/bin/7za + example : cp bin/7za /usr/local/bin/7za - 7z needs its plugins. You must copy the file 7z, 7z.so and the directory Codecs in the same destination directory. diff --git a/builtins/extractcode_7z-macosx/src/extractcode_7z/licenses/p7zip/readme.txt b/builtins/extractcode_7z-macosx/src/extractcode_7z/licenses/p7zip/readme.txt index 4a6998c..d6732b6 100755 --- a/builtins/extractcode_7z-macosx/src/extractcode_7z/licenses/p7zip/readme.txt +++ b/builtins/extractcode_7z-macosx/src/extractcode_7z/licenses/p7zip/readme.txt @@ -1,4 +1,4 @@ -7-Zip 16.02 Sources +7-Zip 17.05 Sources ------------------- 7-Zip is a file archiver for Windows. @@ -123,7 +123,7 @@ Windows common files for Windows related code Bundle Modules that are bundles of other modules (files) - Alone 7za.exe: Standalone version of 7-Zip console that supports only 7z/xz/cab/zip/gzip/bzip2/tar. + Alone 7za.exe: Standalone version of 7-Zip console that supports only 7z/xz/cab/zip/gzip/bzip2/lzip/tar. Alone7z 7zr.exe: Standalone version of 7-Zip console that supports only 7z (reduced version) Fm Standalone version of 7-Zip File Manager Format7z 7za.dll: .7z support diff --git a/builtins/extractcode_7z-macosx/src/extractcode_7z/licenses/p7zip/src-history.txt b/builtins/extractcode_7z-macosx/src/extractcode_7z/licenses/p7zip/src-history.txt index 6b48c80..5b2605e 100755 --- a/builtins/extractcode_7z-macosx/src/extractcode_7z/licenses/p7zip/src-history.txt +++ b/builtins/extractcode_7z-macosx/src/extractcode_7z/licenses/p7zip/src-history.txt @@ -1,5 +1,16 @@ HISTORY of the 7-Zip source code + -------------------------------- +17.01 2020-05-13 +------------------------- + - Fix BUG CVE-2018-5996 + - Fix BUG CVE-2017-17969 + - Fix BUG CVE-2016-9296 + +-------------------------------- +17.00 2020-04-27 +------------------------- +- Add Zstd and Lz4 in to Compresssion Support list 16.02 2016-05-21 ------------------------- diff --git a/builtins/extractcode_libarchive-linux/src/extractcode_libarchive/lib/libarchive.so b/builtins/extractcode_libarchive-linux/src/extractcode_libarchive/lib/libarchive.so index ac94c8b..cd00eaa 100755 Binary files a/builtins/extractcode_libarchive-linux/src/extractcode_libarchive/lib/libarchive.so and b/builtins/extractcode_libarchive-linux/src/extractcode_libarchive/lib/libarchive.so differ diff --git a/builtins/extractcode_libarchive-linux/src/extractcode_libarchive/lib/libb2-la3511.so.1 b/builtins/extractcode_libarchive-linux/src/extractcode_libarchive/lib/libb2-la3511.so.1 index f749117..2dc5eed 100755 Binary files a/builtins/extractcode_libarchive-linux/src/extractcode_libarchive/lib/libb2-la3511.so.1 and b/builtins/extractcode_libarchive-linux/src/extractcode_libarchive/lib/libb2-la3511.so.1 differ diff --git a/builtins/extractcode_libarchive-linux/src/extractcode_libarchive/lib/libbz2-la3511.so.1.0 b/builtins/extractcode_libarchive-linux/src/extractcode_libarchive/lib/libbz2-la3511.so.1.0 index af2c9ad..d57d502 100755 Binary files a/builtins/extractcode_libarchive-linux/src/extractcode_libarchive/lib/libbz2-la3511.so.1.0 and b/builtins/extractcode_libarchive-linux/src/extractcode_libarchive/lib/libbz2-la3511.so.1.0 differ diff --git a/builtins/extractcode_libarchive-linux/src/extractcode_libarchive/lib/libexpat-la3511.so.1 b/builtins/extractcode_libarchive-linux/src/extractcode_libarchive/lib/libexpat-la3511.so.1 index da34ae5..4bdcf4e 100755 Binary files a/builtins/extractcode_libarchive-linux/src/extractcode_libarchive/lib/libexpat-la3511.so.1 and b/builtins/extractcode_libarchive-linux/src/extractcode_libarchive/lib/libexpat-la3511.so.1 differ diff --git a/builtins/extractcode_libarchive-linux/src/extractcode_libarchive/lib/liblz4-la3511.so.1 b/builtins/extractcode_libarchive-linux/src/extractcode_libarchive/lib/liblz4-la3511.so.1 index 64bfb16..8e303e2 100755 Binary files a/builtins/extractcode_libarchive-linux/src/extractcode_libarchive/lib/liblz4-la3511.so.1 and b/builtins/extractcode_libarchive-linux/src/extractcode_libarchive/lib/liblz4-la3511.so.1 differ diff --git a/builtins/extractcode_libarchive-linux/src/extractcode_libarchive/lib/liblzma-la3511.so.5 b/builtins/extractcode_libarchive-linux/src/extractcode_libarchive/lib/liblzma-la3511.so.5 index 94c4d7d..527c958 100755 Binary files a/builtins/extractcode_libarchive-linux/src/extractcode_libarchive/lib/liblzma-la3511.so.5 and b/builtins/extractcode_libarchive-linux/src/extractcode_libarchive/lib/liblzma-la3511.so.5 differ diff --git a/builtins/extractcode_libarchive-linux/src/extractcode_libarchive/lib/libz-la3511.so.1 b/builtins/extractcode_libarchive-linux/src/extractcode_libarchive/lib/libz-la3511.so.1 index 7e2c9e5..2385ce3 100755 Binary files a/builtins/extractcode_libarchive-linux/src/extractcode_libarchive/lib/libz-la3511.so.1 and b/builtins/extractcode_libarchive-linux/src/extractcode_libarchive/lib/libz-la3511.so.1 differ diff --git a/builtins/extractcode_libarchive-linux/src/extractcode_libarchive/lib/libzstd-la3511.so.1 b/builtins/extractcode_libarchive-linux/src/extractcode_libarchive/lib/libzstd-la3511.so.1 index 45150fd..5b90adb 100755 Binary files a/builtins/extractcode_libarchive-linux/src/extractcode_libarchive/lib/libzstd-la3511.so.1 and b/builtins/extractcode_libarchive-linux/src/extractcode_libarchive/lib/libzstd-la3511.so.1 differ diff --git a/builtins/extractcode_libarchive-macosx/setup.cfg b/builtins/extractcode_libarchive-macosx/setup.cfg index ef9e33f..4cfbc3d 100755 --- a/builtins/extractcode_libarchive-macosx/setup.cfg +++ b/builtins/extractcode_libarchive-macosx/setup.cfg @@ -5,4 +5,4 @@ license_files = apache-2.0.LICENSE [aliases] -release = clean --all bdist_wheel --plat-name macosx_10_14_x86_64 --python-tag py3 +release = clean --all bdist_wheel --plat-name macosx_15_0_arm64 --python-tag py3 diff --git a/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/lib/libarchive.dylib b/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/lib/libarchive.dylib index 32ffbc8..cec5ee6 100755 Binary files a/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/lib/libarchive.dylib and b/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/lib/libarchive.dylib differ diff --git a/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/lib/libb2.1.dylib b/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/lib/libb2.1.dylib index 47c1e83..e59d360 100755 Binary files a/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/lib/libb2.1.dylib and b/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/lib/libb2.1.dylib differ diff --git a/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/lib/liblz4.1.dylib b/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/lib/liblz4.1.dylib index e1fab8b..11a0d57 100755 Binary files a/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/lib/liblz4.1.dylib and b/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/lib/liblz4.1.dylib differ diff --git a/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/lib/liblzma.5.dylib b/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/lib/liblzma.5.dylib index 71f7ee3..90c38fb 100755 Binary files a/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/lib/liblzma.5.dylib and b/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/lib/liblzma.5.dylib differ diff --git a/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/lib/libzstd.1.dylib b/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/lib/libzstd.1.dylib index 9145a4d..36c0c81 100755 Binary files a/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/lib/libzstd.1.dylib and b/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/lib/libzstd.1.dylib differ diff --git a/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/licenses/libarchive/COPYING b/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/licenses/libarchive/COPYING index 1b97235..9d0bcf8 100755 --- a/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/licenses/libarchive/COPYING +++ b/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/licenses/libarchive/COPYING @@ -20,7 +20,7 @@ the actual statements in the files are controlling. libarchive/mtree.5 * The following source files are in the public domain: - libarchive/archive_getdate.c + libarchive/archive_parse_date.c * The following source files are triple-licensed with the ability to choose from CC0 1.0 Universal, OpenSSL or Apache 2.0 licenses: diff --git a/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/licenses/libarchive/INSTALL_RECEIPT.json b/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/licenses/libarchive/INSTALL_RECEIPT.json index 44e6e85..fb6df38 100755 --- a/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/licenses/libarchive/INSTALL_RECEIPT.json +++ b/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/licenses/libarchive/INSTALL_RECEIPT.json @@ -1 +1,72 @@ -{"homebrew_version":"2.7.1-22-g20ff74a","used_options":[],"unused_options":[],"built_as_bottle":true,"poured_from_bottle":false,"installed_as_dependency":false,"installed_on_request":true,"changed_files":["INSTALL_RECEIPT.json","lib/pkgconfig/libarchive.pc"],"time":null,"source_modified_time":1608946405,"HEAD":null,"stdlib":null,"compiler":"clang","aliases":[],"runtime_dependencies":[{"full_name":"libb2","version":"0.98.1"},{"full_name":"lz4","version":"1.9.3"},{"full_name":"xz","version":"5.2.5"},{"full_name":"zstd","version":"1.4.8"}],"source":{"path":"@@HOMEBREW_REPOSITORY@@/Library/Taps/homebrew/homebrew-core/Formula/libarchive.rb","tap":"homebrew/core","spec":"stable","versions":{"stable":"3.5.1","head":"","version_scheme":0}},"arch":"x86_64","built_on":{"os":"Macintosh","os_version":"macOS 10.14.6","cpu_family":"penryn","xcode":"11.3.1","clt":"11.3.1.0.1.1576735732"}} \ No newline at end of file +{ + "homebrew_version": "5.0.9-8-g2076aa1", + "used_options": [], + "unused_options": [], + "built_as_bottle": true, + "poured_from_bottle": true, + "loaded_from_api": true, + "installed_as_dependency": false, + "installed_on_request": true, + "changed_files": [ + "lib/pkgconfig/libarchive.pc" + ], + "time": 1767796618, + "source_modified_time": 1767609766, + "compiler": "clang", + "aliases": [], + "runtime_dependencies": [ + { + "full_name": "libb2", + "version": "0.98.1", + "revision": 0, + "bottle_rebuild": 0, + "pkg_version": "0.98.1", + "declared_directly": true + }, + { + "full_name": "lz4", + "version": "1.10.0", + "revision": 0, + "bottle_rebuild": 1, + "pkg_version": "1.10.0", + "declared_directly": true + }, + { + "full_name": "xz", + "version": "5.8.2", + "revision": 0, + "bottle_rebuild": 0, + "pkg_version": "5.8.2", + "declared_directly": true + }, + { + "full_name": "zstd", + "version": "1.5.7", + "revision": 0, + "bottle_rebuild": 1, + "pkg_version": "1.5.7", + "declared_directly": true + } + ], + "source": { + "spec": "stable", + "versions": { + "stable": "3.8.5", + "head": null, + "version_scheme": 0, + "compatibility_version": null + }, + "path": "/Users/van/Library/Caches/Homebrew/api/formula.jws.json", + "tap_git_head": "51194902d0fc95bfb5483fae80fe344d2e379fad", + "tap": "homebrew/core" + }, + "arch": "arm64", + "built_on": { + "os": "Macintosh", + "os_version": "macOS 26", + "cpu_family": "dunno", + "xcode": "26.2", + "clt": "26.2.0.0.1.1764812424", + "preferred_perl": "5.34" + } +} \ No newline at end of file diff --git a/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/licenses/libarchive/README.md b/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/licenses/libarchive/README.md index 56cd723..e9691f1 100755 --- a/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/licenses/libarchive/README.md +++ b/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/licenses/libarchive/README.md @@ -7,7 +7,7 @@ command-line tools that use the libarchive library. ## Questions? Issues? -* http://www.libarchive.org is the home for ongoing +* https://www.libarchive.org is the home for ongoing libarchive development, including documentation, and links to the libarchive mailing lists. * To report an issue, use the issue tracker at @@ -23,6 +23,7 @@ This distribution bundle includes the following major components: * **tar**: the 'bsdtar' program is a full-featured 'tar' implementation built on libarchive * **cpio**: the 'bsdcpio' program is a different interface to essentially the same functionality * **cat**: the 'bsdcat' program is a simple replacement tool for zcat, bzcat, xzcat, and such +* **unzip**: the 'bsdunzip' program is a simple replacement tool for Info-ZIP's unzip * **examples**: Some small example programs that you may find useful. * **examples/minitar**: a compact sample demonstrating use of libarchive. * **contrib**: Various items sent to me by third parties; please contact the authors with any questions. @@ -37,6 +38,7 @@ The top-level directory contains the following information files: * **configure** - configuration script, see INSTALL for details. If your copy of the source lacks a `configure` script, you can try to construct it by running the script in `build/autogen.sh` (or use `cmake`). The following files in the top-level directory are used by the 'configure' script: + * `Makefile.am`, `aclocal.m4`, `configure.ac` - used to build this distribution, only needed by maintainers * `Makefile.in`, `config.h.in` - templates used by configure script @@ -71,6 +73,7 @@ know about any errors or omissions you find. ## Supported Formats Currently, the library automatically detects and reads the following formats: + * Old V7 tar archives * POSIX ustar * GNU tar format (including GNU long filenames, long link names, and sparse files) @@ -79,18 +82,21 @@ Currently, the library automatically detects and reads the following formats: * POSIX octet-oriented cpio * SVR4 ASCII cpio * Binary cpio (big-endian or little-endian) + * PWB binary cpio * ISO9660 CD-ROM images (with optional Rockridge or Joliet extensions) * ZIP archives (with uncompressed or "deflate" compressed entries, including support for encrypted Zip archives) - * ZIPX archives (with support for bzip2, ppmd8, lzma and xz compressed entries) + * ZIPX archives (with support for bzip2, zstd, ppmd8, lzma and xz compressed entries) * GNU and BSD 'ar' archives * 'mtree' format - * 7-Zip archives + * 7-Zip archives (including archives that use zstandard compression) * Microsoft CAB format * LHA and LZH archives * RAR and RAR 5.0 archives (with some limitations due to RAR's proprietary status) + * WARC archives * XAR archives The library also detects and handles any of the following before evaluating the archive: + * uuencoded files * files with RPM wrapper * gzip compression @@ -102,6 +108,7 @@ The library also detects and handles any of the following before evaluating the * zstandard compression The library can create archives in any of the following formats: + * POSIX ustar * POSIX pax interchange format * "restricted" pax format, which will create ustar archives except for @@ -110,16 +117,22 @@ The library can create archives in any of the following formats: * Old V7 tar format * POSIX octet-oriented cpio * SVR4 "newc" cpio + * Binary cpio (little-endian) + * PWB binary cpio * shar archives * ZIP archives (with uncompressed or "deflate" compressed entries) + * ZIPX archives (with bzip2, zstd, lzma or xz compressed entries) * GNU and BSD 'ar' archives * 'mtree' format * ISO9660 format - * 7-Zip archives + * 7-Zip archives (including archives that use zstandard compression) + * WARC archives * XAR archives When creating archives, the result can be filtered with any of the following: + * uuencode + * base64 * gzip compression * bzip2 compression * compress/LZW compression @@ -178,19 +191,30 @@ questions we are asked about libarchive: libraries. This also reduces the size of statically-linked binaries in environments where that matters. -* The library is generally _thread safe_ depending on the platform: +* The library is generally _thread-safe_ depending on the platform: it does not define any global variables of its own. However, some platforms do not provide fully thread-safe versions of key C library functions. On those platforms, libarchive will use the non-thread-safe functions. Patches to improve this are of great interest to us. +* The function `archive_write_disk_header()` is _not_ thread safe on + POSIX machines and could lead to security issue resulting in world + writeable directories. Thus it must be mutexed by the calling code. + This is due to calling `umask(oldumask = umask(0))`, which sets the + umask for the whole process to 0 for a short time frame. + In case other thread calls the same function in parallel, it might + get interrupted by it and cause the executable to use umask=0 for the + remaining execution. + This will then lead to implicitly created directories to have 777 + permissions without sticky bit. + * In particular, libarchive's modules to read or write a directory tree do use `chdir()` to optimize the directory traversals. This can cause problems for programs that expect to do disk access from multiple threads. Of course, those modules are completely optional and you can use the rest of libarchive without them. -* The library is _not_ thread aware, however. It does no locking +* The library is _not_ thread-aware, however. It does no locking or thread management of any kind. If you create a libarchive object and need to access it from multiple threads, you will need to provide your own locking. @@ -221,4 +245,3 @@ questions we are asked about libarchive: appropriate. It has many advantages over other tar formats (including the legacy GNU tar format) and is widely supported by current tar implementations. - diff --git a/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/licenses/libb2/INSTALL_RECEIPT.json b/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/licenses/libb2/INSTALL_RECEIPT.json index 489f13d..9d5539e 100755 --- a/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/licenses/libb2/INSTALL_RECEIPT.json +++ b/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/licenses/libb2/INSTALL_RECEIPT.json @@ -1 +1,46 @@ -{"homebrew_version":"2.1.1-72-g193173f","used_options":[],"unused_options":[],"built_as_bottle":true,"poured_from_bottle":false,"installed_as_dependency":false,"installed_on_request":true,"changed_files":["INSTALL_RECEIPT.json","lib/pkgconfig/libb2.pc"],"time":null,"source_modified_time":1552232191,"HEAD":null,"stdlib":null,"compiler":"clang","aliases":[],"runtime_dependencies":[],"source":{"path":"@@HOMEBREW_REPOSITORY@@/Library/Taps/homebrew/homebrew-core/Formula/libb2.rb","tap":"homebrew/core","spec":"stable","versions":{"stable":"0.98.1","devel":"","head":"","version_scheme":0}}} \ No newline at end of file +{ + "homebrew_version": "3.6.6-34-gfaa9950", + "used_options": [ + + ], + "unused_options": [ + + ], + "built_as_bottle": true, + "poured_from_bottle": true, + "loaded_from_api": true, + "installed_as_dependency": true, + "installed_on_request": false, + "changed_files": [ + "lib/pkgconfig/libb2.pc" + ], + "time": 1677168557, + "source_modified_time": 1552232191, + "compiler": "clang", + "aliases": [ + + ], + "runtime_dependencies": [ + + ], + "source": { + "spec": "stable", + "versions": { + "stable": "0.98.1", + "head": null, + "version_scheme": 0 + }, + "path": "/opt/homebrew/Library/Taps/homebrew/homebrew-core/Formula/libb2.rb", + "tap_git_head": "9e5a23de71f24a17ee1b0652d3331f41fe639aa0", + "tap": "homebrew/core" + }, + "arch": "arm64", + "built_on": { + "os": "Macintosh", + "os_version": "macOS 13", + "cpu_family": "dunno", + "xcode": "14.1", + "clt": "14.1.0.0.1.1665256668", + "preferred_perl": "5.30" + } +} \ No newline at end of file diff --git a/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/licenses/lz4/INSTALL_RECEIPT.json b/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/licenses/lz4/INSTALL_RECEIPT.json index c2e3a21..c3e41a8 100755 --- a/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/licenses/lz4/INSTALL_RECEIPT.json +++ b/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/licenses/lz4/INSTALL_RECEIPT.json @@ -1 +1,46 @@ -{"homebrew_version":"2.5.10-43-g79c14e6","used_options":[],"unused_options":[],"built_as_bottle":true,"poured_from_bottle":false,"installed_as_dependency":false,"installed_on_request":true,"changed_files":["INSTALL_RECEIPT.json","NEWS","lib/pkgconfig/liblz4.pc"],"time":null,"source_modified_time":1605502775,"HEAD":null,"stdlib":null,"compiler":"clang","aliases":[],"runtime_dependencies":[],"source":{"path":"@@HOMEBREW_REPOSITORY@@/Library/Taps/homebrew/homebrew-core/Formula/lz4.rb","tap":"homebrew/core","spec":"stable","versions":{"stable":"1.9.3","head":"HEAD","version_scheme":0}},"arch":"x86_64","built_on":{"os":"Macintosh","os_version":"macOS 10.14.6","cpu_family":"penryn","xcode":"11.3.1","clt":"11.3.1.0.1.1576735732"}} \ No newline at end of file +{ + "homebrew_version": "4.3.16-28-gf17ee43", + "used_options": [ + + ], + "unused_options": [ + + ], + "built_as_bottle": true, + "poured_from_bottle": true, + "loaded_from_api": true, + "installed_as_dependency": true, + "installed_on_request": true, + "changed_files": [ + "lib/pkgconfig/liblz4.pc" + ], + "time": 1724783547, + "source_modified_time": 1721582989, + "compiler": "clang", + "aliases": [ + + ], + "runtime_dependencies": [ + + ], + "source": { + "spec": "stable", + "versions": { + "stable": "1.10.0", + "head": null, + "version_scheme": 0 + }, + "path": "/Users/van/Library/Caches/Homebrew/api/formula.jws.json", + "tap_git_head": "c919c773bafdd6a5a68238c8b7353ca57677ee5c", + "tap": "homebrew/core" + }, + "arch": "arm64", + "built_on": { + "os": "Macintosh", + "os_version": "macOS 14.4", + "cpu_family": "dunno", + "xcode": "15.3", + "clt": "15.3.0.0.1.1708646388", + "preferred_perl": "5.34" + } +} \ No newline at end of file diff --git a/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/licenses/lz4/LICENSE b/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/licenses/lz4/LICENSE index c221aeb..ba8a290 100755 --- a/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/licenses/lz4/LICENSE +++ b/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/licenses/lz4/LICENSE @@ -1,6 +1,6 @@ This repository uses 2 different licenses : - all files in the `lib` directory use a BSD 2-Clause license -- all other files use a GPLv2 license, unless explicitly stated otherwise +- all other files use a GPL-2.0-or-later license, unless explicitly stated otherwise Relevant license is reminded at the top of each source file, and with presence of COPYING or LICENSE file in associated directories. @@ -8,4 +8,5 @@ and with presence of COPYING or LICENSE file in associated directories. This model is selected to emphasize that files in the `lib` directory are designed to be included into 3rd party applications, while all other files, in `programs`, `tests` or `examples`, -receive more limited attention and support for such scenario. +are intended to be used "as is", as part of their intended scenarios, +with no intention to support 3rd party integration use cases. diff --git a/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/licenses/lz4/README.md b/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/licenses/lz4/README.md index bdb028c..5ee643f 100755 --- a/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/licenses/lz4/README.md +++ b/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/licenses/lz4/README.md @@ -26,10 +26,8 @@ LZ4 library is provided as open-source software using BSD 2-Clause license. |Branch |Status | |------------|---------| -|dev | [![Build Status][travisDevBadge]][travisLink] [![Build status][AppveyorDevBadge]][AppveyorLink] | +|dev | [![Build status][AppveyorDevBadge]][AppveyorLink] | -[travisDevBadge]: https://travis-ci.org/lz4/lz4.svg?branch=dev "Continuous Integration test suite" -[travisLink]: https://travis-ci.org/lz4/lz4 [AppveyorDevBadge]: https://ci.appveyor.com/api/projects/status/github/lz4/lz4?branch=dev&svg=true "Windows test suite" [AppveyorLink]: https://ci.appveyor.com/project/YannCollet/lz4-1lndh @@ -62,7 +60,7 @@ in single-thread mode. [zlib]: http://www.zlib.net/ [Zstandard]: http://www.zstd.net/ -LZ4 is also compatible and optimized for x32 mode, +LZ4 is also compatible and optimized for x32 mode (`-mx32`), for which it provides additional speed performance. @@ -83,7 +81,7 @@ It is compatible with parallel builds (`-j#`). [redirection]: https://www.gnu.org/prep/standards/html_node/Directory-Variables.html [command redefinition]: https://www.gnu.org/prep/standards/html_node/Utilities-in-Makefiles.html -Building LZ4 - Using vcpkg +### Building LZ4 - Using vcpkg You can download and install LZ4 using the [vcpkg](https://github.com/Microsoft/vcpkg) dependency manager: @@ -91,7 +89,7 @@ You can download and install LZ4 using the [vcpkg](https://github.com/Microsoft/ cd vcpkg ./bootstrap-vcpkg.sh ./vcpkg integrate install - vcpkg install lz4 + ./vcpkg.exe install lz4 The LZ4 port in vcpkg is kept up to date by Microsoft team members and community contributors. If the version is out of date, please [create an issue or pull request](https://github.com/Microsoft/vcpkg) on the vcpkg repository. @@ -118,3 +116,16 @@ many contributors have created versions of lz4 in multiple languages A list of known source ports is maintained on the [LZ4 Homepage]. [LZ4 Homepage]: http://www.lz4.org + +### Packaging status + +Most distributions are bundled with a package manager +which allows easy installation of both the `liblz4` library +and the `lz4` command line interface. + +[![Packaging status](https://repology.org/badge/vertical-allrepos/lz4.svg)](https://repology.org/project/lz4/versions) + + +### Special Thanks + +- Takayuki Matsuoka, aka @t-mat, for exceptional first-class support throughout the lifetime of this project diff --git a/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/licenses/xz/AUTHORS b/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/licenses/xz/AUTHORS index bda8797..f805a20 100755 --- a/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/licenses/xz/AUTHORS +++ b/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/licenses/xz/AUTHORS @@ -2,26 +2,57 @@ Authors of XZ Utils =================== - XZ Utils is developed and maintained by Lasse Collin - . + XZ Utils is developed and maintained by + Lasse Collin . Major parts of liblzma are based on code written by Igor Pavlov, - specifically the LZMA SDK . Without + specifically the LZMA SDK . Without this code, XZ Utils wouldn't exist. - The SHA-256 implementation in liblzma is based on the code found from - 7-Zip , which has a modified version of the SHA-256 - code found from Crypto++ . The SHA-256 code - in Crypto++ was written by Kevin Springle and Wei Dai. + The SHA-256 implementation in liblzma is based on code written by + Wei Dai in Crypto++ Library . - Some scripts have been adapted from gzip. The original versions - were written by Jean-loup Gailly, Charles Levert, and Paul Eggert. - Andrew Dudman helped adapting the scripts and their man pages for - XZ Utils. + A few scripts have been adapted from GNU gzip. The original + versions were written by Jean-loup Gailly, Charles Levert, and + Paul Eggert. Andrew Dudman helped adapting the scripts and their + man pages for XZ Utils. - The GNU Autotools-based build system contains files from many authors, - which I'm not trying to list here. + The initial version of the threaded .xz decompressor was written + by Sebastian Andrzej Siewior. - Several people have contributed fixes or reported bugs. Most of them - are mentioned in the file THANKS. + The initial version of the .lz (lzip) decoder was written + by Michał Górny. + + Architecture-specific CRC optimizations were contributed by + Ilya Kurdyukov, Chenxi Mao, and Xi Ruoyao. + + Other authors: + - Jonathan Nieder + - Joachim Henke + + Special author: Jia Tan was a co-maintainer in 2022-2024. He and + the team behind him inserted a backdoor (CVE-2024-3094) into + XZ Utils 5.6.0 and 5.6.1 releases. He suddenly disappeared when + this was discovered. + + Many people have contributed improvements or reported bugs. + Most of these people are mentioned in the file THANKS. + + The translations of the command line tools and man pages have been + contributed by many people via the Translation Project: + + - https://translationproject.org/domain/xz.html + - https://translationproject.org/domain/xz-man.html + + The authors of the translated man pages are in the header comments + of the man page files. In the source package, the authors of the + translations are in po/*.po and po4a/*.po files. + + Third-party code whose authors aren't listed here: + + - GNU getopt_long() in the 'lib' directory is included for + platforms that don't have a usable getopt_long(). + + - The build system files from GNU Autoconf, GNU Automake, + GNU Libtool, GNU Gettext, Autoconf Archive, and related files. diff --git a/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/licenses/xz/COPYING b/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/licenses/xz/COPYING index 20e60d5..ef33713 100755 --- a/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/licenses/xz/COPYING +++ b/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/licenses/xz/COPYING @@ -3,63 +3,68 @@ XZ Utils Licensing ================== Different licenses apply to different files in this package. Here - is a rough summary of which licenses apply to which parts of this - package (but check the individual files to be sure!): + is a summary of which licenses apply to which parts of this package: - - liblzma is in the public domain. + - liblzma is under the BSD Zero Clause License (0BSD). - - xz, xzdec, and lzmadec command line tools are in the public - domain unless GNU getopt_long had to be compiled and linked - in from the lib directory. The getopt_long code is under - GNU LGPLv2.1+. + - The command line tools xz, xzdec, lzmadec, and lzmainfo are + under 0BSD except that, on systems that don't have a usable + getopt_long, GNU getopt_long is compiled and linked in from the + 'lib' directory. The getopt_long code is under GNU LGPLv2.1+. - The scripts to grep, diff, and view compressed files have been - adapted from gzip. These scripts and their documentation are - under GNU GPLv2+. + adapted from GNU gzip. These scripts (xzgrep, xzdiff, xzless, + and xzmore) are under GNU GPLv2+. The man pages of the scripts + are under 0BSD; they aren't based on the man pages of GNU gzip. - - All the documentation in the doc directory and most of the - XZ Utils specific documentation files in other directories - are in the public domain. + - Most of the XZ Utils specific documentation that is in + plain text files (like README, INSTALL, PACKAGERS, NEWS, + and ChangeLog) are under 0BSD unless stated otherwise in + the file itself. The files xz-file-format.txt and + lzma-file-format.xt are in the public domain but may + be distributed under the terms of 0BSD too. - - Translated messages are in the public domain. + - Translated messages and man pages are under 0BSD except that + some old translations are in the public domain. - - The build system contains public domain files, and files that - are under GNU GPLv2+ or GNU GPLv3+. None of these files end up - in the binaries being built. + - Test files and test code in the 'tests' directory, and + debugging utilities in the 'debug' directory are under + the BSD Zero Clause License (0BSD). - - Test files and test code in the tests directory, and debugging - utilities in the debug directory are in the public domain. + - The GNU Autotools based build system contains files that are + under GNU GPLv2+, GNU GPLv3+, and a few permissive licenses. + These files don't affect the licensing of the binaries being + built. - - The extra directory may contain public domain files, and files - that are under various free software licenses. + - The 'extra' directory contains files that are under various + free software licenses. These aren't built or installed as + part of XZ Utils. - You can do whatever you want with the files that have been put into - the public domain. If you find public domain legally problematic, - take the previous sentence as a license grant. If you still find - the lack of copyright legally problematic, you have too many - lawyers. + The following command may be helpful in finding per-file license + information. It works on xz.git and on a clean file tree extracted + from a release tarball. - As usual, this software is provided "as is", without any warranty. + sh build-aux/license-check.sh -v - If you copy significant amounts of public domain code from XZ Utils + For the files under the BSD Zero Clause License (0BSD), if + a copyright notice is needed, the following is sufficient: + + Copyright (C) The XZ Utils authors and contributors + + If you copy significant amounts of 0BSD-licensed code from XZ Utils into your project, acknowledging this somewhere in your software is polite (especially if it is proprietary, non-free software), but - naturally it is not legally required. Here is an example of a good - notice to put into "about box" or into documentation: + it is not legally required by the license terms. Here is an example + of a good notice to put into "about box" or into documentation: This software includes code from XZ Utils . The following license texts are included in the following files: + - COPYING.0BSD: BSD Zero Clause License - COPYING.LGPLv2.1: GNU Lesser General Public License version 2.1 - COPYING.GPLv2: GNU General Public License version 2 - COPYING.GPLv3: GNU General Public License version 3 - Note that the toolchain (compiler, linker etc.) may add some code - pieces that are copyrighted. Thus, it is possible that e.g. liblzma - binary wouldn't actually be in the public domain in its entirety - even though it contains no copyrighted code from the XZ Utils source - package. - - If you have questions, don't hesitate to ask the author(s) for more - information. + If you have questions, don't hesitate to ask for more information. + The contact information is in the README file. diff --git a/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/licenses/xz/ChangeLog b/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/licenses/xz/ChangeLog index 37c0d95..bd7fad9 100755 --- a/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/licenses/xz/ChangeLog +++ b/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/licenses/xz/ChangeLog @@ -1,6947 +1,18975 @@ -commit 2327a461e1afce862c22269b80d3517801103c1b +commit 3d078b52adbff566ccfc51067dfbf742ecf3ef86 Author: Lasse Collin -Date: 2020-03-17 16:27:42 +0200 +Date: 2025-12-17 13:36:42 +0200 - Bump version and soname for 5.2.5. + Bump version and soname for 5.8.2 src/liblzma/Makefile.am | 2 +- src/liblzma/api/lzma/version.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) -commit 3be82d2f7dc882258caf0f0a69214e5916b2bdda +commit fb14afd5c9bf14d8c67ee11e4139885072071ddd Author: Lasse Collin -Date: 2020-03-17 16:26:04 +0200 +Date: 2025-12-17 13:36:35 +0200 - Update NEWS for 5.2.5. + Add NEWS for 5.8.2 - NEWS | 105 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ - 1 file changed, 105 insertions(+) + NEWS | 72 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ + 1 file changed, 72 insertions(+) -commit ab3e57539c7337f0653b13b75dbc5d03ade9700e +commit 590f4713b29f0236ab944487f40069355a515dbc Author: Lasse Collin -Date: 2020-03-16 21:57:21 +0200 +Date: 2025-12-16 11:30:35 +0200 - Translations: Rebuild cs.po to avoid incorrect fuzzy strings. + CMake: Bump maximum policy version to 4.2 - "make dist" updates the .po files and the fuzzy strings would - result in multiple very wrong translations. + CMP0186 is curious but we aren't affected. - po/cs.po | 592 ++++++++++++++++++++++++++++++++++----------------------------- - 1 file changed, 322 insertions(+), 270 deletions(-) + CMakeLists.txt | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) -commit 3a6f38309dc5d44d8a63ebb337b6b2028561c93e +commit 26d22ed16b6e38ce8ed45cb29076f454cd488762 Author: Lasse Collin -Date: 2020-03-16 20:01:37 +0200 +Date: 2025-12-10 19:20:05 +0200 - README: Update outdated sections. + tuklib_integer/CMake: Log a message about unaligned access check - README | 21 +++++++++++---------- - 1 file changed, 11 insertions(+), 10 deletions(-) + cmake/tuklib_integer.cmake | 8 ++++++++ + 1 file changed, 8 insertions(+) -commit 9cc0901798217e258e91c13cf6fda7ad42ba108c +commit f7381cf927576164c17be4e4c1edeec3cdaca7cf Author: Lasse Collin -Date: 2020-03-16 19:46:27 +0200 +Date: 2025-12-10 19:11:27 +0200 - README: Mention that translatable strings will change after 5.2.x. + tuklib_integer/CMake: Don't run unaligned access checks unnecessarily + + If the cache variable TUKLIB_FAST_UNALIGNED_ACCESS is already set, + the autodetection result isn't needed because the option() command + does nothing when the cache variable is already set. + + This is largely white space change to indent the if...endif block. - README | 74 +++--------------------------------------------------------------- - 1 file changed, 3 insertions(+), 71 deletions(-) + cmake/tuklib_integer.cmake | 226 +++++++++++++++++++++++---------------------- + 1 file changed, 117 insertions(+), 109 deletions(-) -commit cc163574249f6a4a66f3dc09d6fe5a71bee24fab +commit dc1a421ce35f10b9a0c00d1bd42f1fdac0c3e9eb Author: Lasse Collin -Date: 2020-03-16 19:39:45 +0200 +Date: 2025-12-10 16:49:55 +0200 - README: Mention that man pages can be translated. + tuklib_integer: Use CMAKE_C_COMPILER_ARCHITECTURE_ID when available + + CMake >= 4.1 sets CMAKE__COMPILER_ARCHITECTURE_ID on many + platforms. The list of possible values are documented. Use this + variable when available. On older CMake versions CMAKE_SYSTEM_PROCESSOR + is still used, thus the regexes have to include values like ^amd64 still. + + With old CMake versions, checking CMAKE_C_COMPILER_ARCHITECTURE_ID + is somewhat useful with MSVC because CMAKE_SYSTEM_PROCESSOR might + not match the target architecture. - README | 7 ++++--- - 1 file changed, 4 insertions(+), 3 deletions(-) + cmake/tuklib_integer.cmake | 13 ++++++++++++- + 1 file changed, 12 insertions(+), 1 deletion(-) -commit ca261994edc3f2d03d5589c037171c63471ee9dc +commit c690101dddd784b75224a8935f56cd163d3e90a3 Author: Lasse Collin -Date: 2020-03-16 17:30:39 +0200 +Date: 2025-12-10 16:49:55 +0200 - Translations: Add partial Danish translation. + tuklib_integer: Autodetect when -mstrict-align is used with GCC on ARM64 - I made a few minor white space changes without getting them - approved by the Danish translation team. + On ARM64, support for fast unaligned memory access was autodetected by + checking if __ARM_FEATURE_UNALIGNED is defined. However, at least GCC + versions up to 15.2.0 define the macro even when -mstrict-align has + been specified. Thus, autodetection with GCC doesn't work correctly, + and binaries built using -mstrict-align can be much slower than they + need to be, unless the user also passes --disable-unaligned-access + to configure or -DTUKLIB_FAST_UNALIGNED_ACCESS=OFF to cmake. + + See the GCC bug: + + https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111555 + + Workaround the issue by using heuristics with GCC on ARM64. + + With Clang, the detection using __ARM_FEATURE_UNALIGNED works. + It also works with GCC on 32-bit ARM. + + Fixes: e5f13a66567b ("tuklib_integer: Autodetect support for unaligned access on ARM.") - po/LINGUAS | 1 + - po/da.po | 896 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ - 2 files changed, 897 insertions(+) + cmake/tuklib_integer.cmake | 63 ++++++++++++++++++++++++++++++------- + m4/tuklib_integer.m4 | 78 +++++++++++++++++++++++++++++++++++----------- + 2 files changed, 110 insertions(+), 31 deletions(-) -commit 51cd5d051fc730d61411dee292e863582784e189 +commit d9b318f5b8a3524e90ac17471e79db7de012caf5 Author: Lasse Collin -Date: 2020-03-16 16:43:29 +0200 +Date: 2025-12-09 18:02:23 +0200 - Update INSTALL.generic from Automake 1.16.1. + CI: Update MSYS2 - INSTALL.generic | 321 ++++++++++++++++++++++++++++---------------------------- - 1 file changed, 162 insertions(+), 159 deletions(-) + .github/workflows/msys2.yml | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) -commit 69d694e5f1beae2bbfa3b6c348ec0ec5f14b5cd0 +commit 700e32f1b7dd6d674f12bbdabc35a3bc4a2860f5 Author: Lasse Collin -Date: 2020-03-15 15:27:22 +0200 +Date: 2025-12-09 18:02:05 +0200 - Update INSTALL for Windows and DOS and add preliminary info for z/OS. + CI: Update DragonFly BSD - INSTALL | 51 +++++++++++++++++++++++++++++++++++++++++---------- - 1 file changed, 41 insertions(+), 10 deletions(-) + .github/workflows/dragonflybsd.yml | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) -commit 2c3b1bb80a3ca7e09728fe4d7a1d8648a5cb9bca +commit a7b749389c64dfbee1c29d88e61e71186b472784 Author: Lasse Collin -Date: 2020-03-15 15:26:20 +0200 +Date: 2025-12-09 17:58:52 +0200 - Build: Update m4/ax_pthread.m4 from Autoconf Archive (again). + CI: Update Solaris - m4/ax_pthread.m4 | 219 +++++++++++++++++++++++++++++-------------------------- - 1 file changed, 117 insertions(+), 102 deletions(-) + .github/workflows/solaris.yml | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) -commit 74a5af180a6a6c4b8c90cefb37ee900d3fea7dc6 +commit e0b3c6ee0ab3243e48291e5f9b6333c3d052311d Author: Lasse Collin -Date: 2020-03-11 21:15:35 +0200 +Date: 2025-12-09 17:56:58 +0200 - xz: Never use thousand separators in DJGPP builds. - - DJGPP 2.05 added support for thousands separators but it's - broken at least under WinXP with Finnish locale that uses - a non-breaking space as the thousands separator. Workaround - by disabling thousands separators for DJGPP builds. + CI: Update NetBSD - src/xz/util.c | 14 ++++++++++++-- - 1 file changed, 12 insertions(+), 2 deletions(-) + .github/workflows/netbsd.yml | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) -commit ceba0d25e826bcdbf64bb4cb03385a2a66f8cbcb +commit fbc1046248cfe3c730437ba7d98dde89b0eced3e Author: Lasse Collin -Date: 2020-03-11 19:38:08 +0200 +Date: 2025-12-09 17:54:54 +0200 - DOS: Update dos/Makefile for DJGPP 2.05. - - It doesn't need -fgnu89-inline like 2.04beta did. + CI: Update OpenBSD - dos/Makefile | 4 +--- - 1 file changed, 1 insertion(+), 3 deletions(-) + .github/workflows/openbsd.yml | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) -commit 29e5bd71612253281fb22bbaa0a566990a74dcc3 +commit 8f0579ba5650bbbfa88a04adf8115b8fb4aff476 Author: Lasse Collin -Date: 2020-03-11 19:36:07 +0200 +Date: 2025-12-09 17:52:01 +0200 - DOS: Update instructions in dos/INSTALL.txt. + CI: Update FreeBSD - dos/INSTALL.txt | 59 ++++++++++++++++++++++++++++----------------------------- - 1 file changed, 29 insertions(+), 30 deletions(-) + .github/workflows/freebsd.yml | 4 +++- + 1 file changed, 3 insertions(+), 1 deletion(-) -commit 00a037ee9c8ee5a03cf9744e05570ae93d56b875 +commit f8424b0416266c393c84a315e3bdedbc19efa0a8 Author: Lasse Collin -Date: 2020-03-11 17:58:51 +0200 +Date: 2025-12-09 17:40:05 +0200 - DOS: Update config.h. - - The added defines assume GCC >= 4.8. + Update THANKS - dos/config.h | 8 ++++++++ - 1 file changed, 8 insertions(+) + THANKS | 1 + + 1 file changed, 1 insertion(+) -commit 4ec2feaefa310b4249eb41893caf526e5c51ee39 +commit c4340692d4490ff80e897d4840fadc033c46d81a Author: Lasse Collin -Date: 2020-03-11 22:37:54 +0200 +Date: 2025-12-09 13:01:36 +0200 - Translations: Add hu, zh_CN, and zh_TW. + Translations: Add src/xz/sandbox.c to POTFILES.in - I made a few white space changes to these without getting them - approved by the translation teams. (I tried to contact the hu and - zh_TW teams but didn't succeed. I didn't contact the zh_CN team.) - - po/LINGUAS | 3 + - po/hu.po | 985 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ - po/zh_CN.po | 963 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ - po/zh_TW.po | 956 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ - 4 files changed, 2907 insertions(+) - -commit b6ed09729ae408be4533a0ddbc7df3d6f566846a -Author: Lasse Collin -Date: 2020-03-11 14:33:30 +0200 - - Translations: Update vi.po to match the file from the TP. + There are no strings to translate in that file now, but it's good to + list it anyway in case translatable strings are added in the future. - The translated strings haven't been updated but word wrapping - is different. + Fixes: 374868d81d47 ("xz: Move sandboxing code to sandbox.c and improve Landlock sandbox.") - po/vi.po | 407 ++++++++++++++++++++++++++++----------------------------------- - 1 file changed, 179 insertions(+), 228 deletions(-) + po/POTFILES.in | 1 + + 1 file changed, 1 insertion(+) -commit 7c85e8953ced204c858101872a15183e4639e9fb +commit b8af36920b0857c0329f61414df5989093386db1 Author: Lasse Collin -Date: 2020-03-11 14:18:03 +0200 +Date: 2025-12-09 12:55:45 +0200 - Translations: Add fi and pt_BR, and update de, fr, it, and pl. + xz: Never translate "Failed to enable the sandbox" - The German translation isn't identical to the file in - the Translation Project but the changes (white space changes - only) were approved by the translator Mario Blättermann. + This was already the case in practice because I had forgotten to list + src/xz/sandbox.c in po/POTFILES.in. However, it seems better to never + translate this particular error message. It should almost never occur + and if it does, an untranslated message is should make it easier to + find bug reports about it. - po/LINGUAS | 2 + - po/de.po | 476 ++++++++++++++-------------- - po/fi.po | 974 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ - po/fr.po | 272 ++++++++-------- - po/it.po | 479 ++++++++++++---------------- - po/pl.po | 239 +++++++------- - po/pt_BR.po | 1001 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ - 7 files changed, 2697 insertions(+), 746 deletions(-) - -commit 7da3ebc67fb5414034685ec16c7a29dad03dfa9b -Author: Lasse Collin -Date: 2020-02-25 21:35:14 +0200 - - Update THANKS. - - THANKS | 1 + - 1 file changed, 1 insertion(+) + src/xz/sandbox.c | 24 +++++++++++++++--------- + 1 file changed, 15 insertions(+), 9 deletions(-) -commit 1acc48794364606c9091cae6fa56db75a1325114 +commit 5a7fc1af3d9ec115f796cba110eb78e63ff1df5c Author: Lasse Collin -Date: 2020-03-11 13:05:29 +0200 +Date: 2025-12-09 12:27:15 +0200 - Build: Add very limited experimental CMake support. - - This version matches CMake files in the master branch (commit - 265daa873c0d871f5f23f9b56e133a6f20045a0a) except that this omits - two source files that aren't in v5.2 and in the beginning of - CMakeLists.txt the first paragraph in the comment is slightly - different to point out possible issues in building shared liblzma. + Translations: Update the Swedish man page translations - CMakeLists.txt | 659 ++++++++++++++++++++++++++++++++++++++++++++ - cmake/tuklib_common.cmake | 49 ++++ - cmake/tuklib_cpucores.cmake | 175 ++++++++++++ - cmake/tuklib_integer.cmake | 102 +++++++ - cmake/tuklib_mbstr.cmake | 20 ++ - cmake/tuklib_physmem.cmake | 150 ++++++++++ - cmake/tuklib_progname.cmake | 19 ++ - 7 files changed, 1174 insertions(+) + po4a/sv.po | 15 +++++---------- + 1 file changed, 5 insertions(+), 10 deletions(-) -commit 9acc6abea1552803c74c1486fbb10af119550772 +commit 88531e5463d9f028387a11b78d53c9c269e6a3a0 Author: Lasse Collin -Date: 2020-02-27 20:24:27 +0200 +Date: 2025-12-09 12:26:24 +0200 - Build: Add support for --no-po4a option to autogen.sh. - - Normally, if po4a isn't available, autogen.sh will return - with non-zero exit status. The option --no-po4a can be useful - when one knows that po4a isn't available but wants autogen.sh - to still return with zero exit status. + Translations: Update the Romanian man page translations - autogen.sh | 11 ++++++++++- - 1 file changed, 10 insertions(+), 1 deletion(-) + po4a/ro.po | 18 +++++++----------- + 1 file changed, 7 insertions(+), 11 deletions(-) -commit c8853b31545db7bd0551be85949624b1261efd47 +commit 8a817277192e6379a8c6f2eefbaed65c6b7d92fa Author: Lasse Collin -Date: 2020-02-24 23:37:07 +0200 +Date: 2025-12-09 12:13:36 +0200 - Update m4/.gitignore. + Update THANKS - m4/.gitignore | 1 + + THANKS | 1 + 1 file changed, 1 insertion(+) -commit 901eb4a8c992354c3ea482f5bad60a1f8ad6fcc8 +commit 1ec43aa7810d159ed76a6188b17c0bb474ca5ab5 Author: Lasse Collin -Date: 2020-02-24 23:01:00 +0200 +Date: 2025-12-09 12:13:36 +0200 - liblzma: Remove unneeded from fastpos_tablegen.c. + CMake: Autodetect unaligned access support on LoongArch + + This still relies on CMAKE_SYSTEM_PROCESSOR. CMake 4.1 added more + CMAKE__COMPILER_ARCHITECTURE_ID values to detect the arch in + a more defined manner, but 4.1 is too new to require for now. - This file only generates fastpos_table.c. - It isn't built as a part of liblzma. + Thanks-to: Li Chenggang + Closes: https://github.com/tukaani-project/xz/pull/186 - src/liblzma/lzma/fastpos_tablegen.c | 1 - - 1 file changed, 1 deletion(-) + cmake/tuklib_integer.cmake | 81 ++++++++++++++++++++++++++++++++++++++++++++++ + 1 file changed, 81 insertions(+) -commit ac35c9585fb734b7a19785d490c152e0b8cd4663 +commit 7971566247914ec1854b125ff99c2a617f5c1e3a Author: Lasse Collin -Date: 2020-02-22 14:15:07 +0200 +Date: 2025-12-09 12:13:36 +0200 - Use defined(__GNUC__) before __GNUC__ in preprocessor lines. + Autotools: Autodetect unaligned access support on LoongArch + + According to [1] sections 7.4, 8.1, and 8.2, desktop and server + processors support fast unaligned access, but embedded systems likely + don't. + + It's important that TUKLIB_FAST_UNALIGNED_ACCESS isn't defined when + -mstrict-align is in use because it will result in slower binaries + even if running on a processor that supports fast unaligned access. + It's because compilers will translate multibyte memcpy() to multiple + byte-by-byte instructions instead of wider loads and stores. The + compression times from [2] show this well: + + Unaligned access CFLAGS Compression time + enabled -O2 -mno-strict-align 66.1 s + disabled -O2 -mno-strict-align 79.5 s + disabled -O2 -mstrict-align 79.9 s + enabled -O2 -mstrict-align 129.1 s - This should silence the equivalent of -Wundef in compilers that - don't define __GNUC__. + There currently (GCC 15.2) is no preprocessor macro on LoongArch + to detect if -mstrict-align or -mno-strict-align is in effect (the + default is -mno-strict-align). Use heuristics to detect which of the + flags is in effect. + + [1] https://github.com/loongson/la-softdev-convention/blob/v0.2/la-softdev-convention.adoc + [2] https://github.com/tukaani-project/xz/pull/186#issuecomment-3494570304 + + Thanks-to: Li Chenggang + Thanks-to: Xi Ruoyao + See: https://github.com/tukaani-project/xz/pull/186 - src/common/sysdefs.h | 3 ++- - src/liblzma/api/lzma.h | 5 +++-- - 2 files changed, 5 insertions(+), 3 deletions(-) + m4/tuklib_integer.m4 | 68 ++++++++++++++++++++++++++++++++++++++++++++++++++++ + 1 file changed, 68 insertions(+) -commit fb9cada7cfade1156d6277717280e05b5cd342d6 +commit 338f952c0039b153a1fbdf6a535c4bd6a61f33cd Author: Lasse Collin -Date: 2020-02-21 17:40:02 +0200 +Date: 2025-11-26 13:50:57 +0200 - liblzma: Add more uses of lzma_memcmplen() to the normal mode of LZMA. + xz: Silence clang -Wunreachable-code-break - This gives a tiny encoder speed improvement. This could have been done - in 2014 after the commit 544aaa3d13554e8640f9caf7db717a96360ec0f6 but - it was forgotten. + Fixes: a165d7df1964 ("xz: Add a new --filters-help option.") - src/liblzma/lzma/lzma_encoder_optimum_normal.c | 16 ++++++++++------ - 1 file changed, 10 insertions(+), 6 deletions(-) + src/xz/args.c | 1 - + 1 file changed, 1 deletion(-) -commit 6117955af0b9cef5acde7859e86f773692b5f43c +commit 723cee44d076281bce9c3d7bd2c17b0680bd8884 Author: Lasse Collin -Date: 2020-02-21 17:01:15 +0200 +Date: 2025-11-26 13:50:57 +0200 - Build: Add visibility.m4 from gnulib. + liblzma: Remove unwanted semicolons - Appears that this file used to get included as a side effect of - gettext. After the change to gettext version requirements this file - no longer got copied to the package and so the build was broken. + These didn't affect control flow. - m4/.gitignore | 1 - - m4/visibility.m4 | 77 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ - 2 files changed, 77 insertions(+), 1 deletion(-) + src/liblzma/common/vli_decoder.c | 2 +- + src/liblzma/lzma/lzma_common.h | 4 ++-- + src/liblzma/rangecoder/range_decoder.h | 6 +++--- + 3 files changed, 6 insertions(+), 6 deletions(-) -commit c2cc64d78c098834231f9cfd7d852c9cd8950d74 +commit 524f6a7384f15e52ec13c72adbdf18ddeecbc735 Author: Lasse Collin -Date: 2020-02-21 16:10:44 +0200 +Date: 2025-11-26 13:50:57 +0200 - xz: Silence a warning when sig_atomic_t is long int. + Tests: Remove an unwanted semicolon from a macro definition + + It didn't affect control flow. - It can be true at least on z/OS. + Fixes: fe3bd438fb11 ("Tests: Fix memory leaks in test_block_header.") - src/xz/signals.c | 2 +- + tests/test_block_header.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -commit b6314aa275b35c714e0a191d0b2e9b6106129ea9 +commit 0f41a28bfab98d1f5171ee5c9da6dfdc15f62549 Author: Lasse Collin -Date: 2020-02-21 15:59:26 +0200 +Date: 2025-11-26 13:50:57 +0200 - xz: Avoid unneeded access of a volatile variable. + Build: Use -Wextra-semi-stmt when supported - src/xz/signals.c | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) + CMakeLists.txt | 1 + + configure.ac | 1 + + 2 files changed, 2 insertions(+) -commit f772a1572f723e5dc7d2d32e1d4287ac7a0da55e +commit 91170c8cab72b94a697f5228f4df13483ef5be91 Author: Lasse Collin -Date: 2020-02-21 01:24:18 +0200 +Date: 2025-11-26 13:50:57 +0200 - tuklib_integer.m4: Optimize the check order. + CI: Add clang-cl - The __builtin byteswapping is the preferred one so check for it first. + Fixes: https://github.com/tukaani-project/xz/issues/18#issuecomment-3577456136 - m4/tuklib_integer.m4 | 56 +++++++++++++++++++++++++++------------------------- - 1 file changed, 29 insertions(+), 27 deletions(-) + .github/workflows/msvc.yml | 46 ++++++++++++++++++++++++++++++++++++++++++++++ + 1 file changed, 46 insertions(+) -commit 641042e63f665f3231c2fd1241fd3dddda3fb313 +commit a3c6cb09113de978b971cbdacf5c4890d4237c28 Author: Lasse Collin -Date: 2020-02-20 18:54:04 +0200 +Date: 2025-11-26 13:50:57 +0200 - tuklib_exit: Add missing header. + xz/Windows: Add a missing #include to fix the build with clang-cl - strerror() needs which happened to be included via - tuklib_common.h -> tuklib_config.h -> sysdefs.h if HAVE_CONFIG_H - was defined. This wasn't tested without config.h before so it - had worked fine. + Fixes: https://github.com/tukaani-project/xz/issues/18#issuecomment-1986829734 + Fixes: https://github.com/tukaani-project/xz/issues/18#issuecomment-3577456136 - src/common/tuklib_exit.c | 1 + - 1 file changed, 1 insertion(+) + src/xz/util.c | 4 ++++ + 1 file changed, 4 insertions(+) -commit dbd55a69e530fec9ae866aaf6c3ccc0b4daf1f1f +commit c410ccc62511ec95b20639defb10650ef9b75e8c Author: Lasse Collin -Date: 2020-02-16 11:18:28 +0200 +Date: 2025-11-25 21:05:37 +0200 - sysdefs.h: Omit the conditionals around string.h and limits.h. + xz: Check return value of sigaction() before calling raise() - string.h is used unconditionally elsewhere in the project and - configure has always stopped if limits.h is missing, so these - headers must have been always available even on the weirdest - systems. + Fixes: Coverity CID 456022 - src/common/sysdefs.h | 8 ++------ - 1 file changed, 2 insertions(+), 6 deletions(-) + src/xz/signals.c | 10 ++++++++-- + 1 file changed, 8 insertions(+), 2 deletions(-) -commit 9294909861e6d22b32418467e0e988f953a82264 +commit 6cc2da0a4b180b71cb6e781c897052def103ad3e Author: Lasse Collin -Date: 2020-02-15 15:07:11 +0200 +Date: 2025-11-02 12:57:00 +0200 - Build: Bump Autoconf and Libtool version requirements. + liblzma: Refactor a loop in lzma_filters_copy() - There is no specific reason for this other than blocking - the most ancient versions. These are still old: + Arguably it's nicer if i doesn't wrap around when the loop terminates. - Autoconf 2.69 (2012) - Automake 1.12 (2012) - gettext 0.19.6 (2015) - Libtool 2.4 (2010) + Fixes: Coverity CID 464589 + Fixes: 6d118a0b9def ("Add lzma_filters_copy().") - configure.ac | 4 ++-- + src/liblzma/common/filter_common.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) -commit bd09081bbdf552f730030d2fd0e5e39ccb3936af +commit 90b67853d57562c5ad4fdb3215ceb9b9bd3958bf Author: Lasse Collin -Date: 2020-02-15 03:08:32 +0200 +Date: 2025-11-02 12:17:50 +0200 - Build: Use AM_GNU_GETTEXT_REQUIRE_VERSION and require 0.19.6. + liblzma: Silence two Coverity warnings - This bumps the version requirement from 0.19 (from 2014) to - 0.19.6 (2015). + lzma_lzma_decoder_memusage() returns UINT64_MAX if lc/lp/pb aren't + valid. alone_decoder.c and lzip_decoder.c didn't check the return + value because in both it is known that lc/lp/pb are valid. Make them + call the _nocheck() variant instead which skips the validation (it + already existed for LZMA2's internal use). - Using only the old AM_GNU_GETTEXT_VERSION results in old - gettext infrastructure being placed in the package. By using - both macros we get the latest gettext files while the other - programs in the Autotools family can still see the old macro. + Fixes: Coverity CID 464658 + Fixes: Coverity CID 897069 - configure.ac | 6 +++++- - 1 file changed, 5 insertions(+), 1 deletion(-) + src/liblzma/common/alone_decoder.c | 6 ++++-- + src/liblzma/common/lzip_decoder.c | 3 ++- + src/liblzma/lzma/lzma_decoder.h | 11 ++++++----- + 3 files changed, 12 insertions(+), 8 deletions(-) -commit 1e5e08d86534aec7ca957982c7f6e90203c19e9f +commit be365b701024b9acbfef4035c6433a0fbb4be823 Author: Lasse Collin -Date: 2020-02-14 20:42:06 +0200 +Date: 2025-11-02 12:17:50 +0200 - Translations: Add German translation of the man pages. + liblzma: Fix a harmless read of shared variable without mutex - Thanks to Mario Blättermann. - - po4a/de.po | 5532 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ - po4a/po4a.conf | 2 +- - 2 files changed, 5533 insertions(+), 1 deletion(-) - -commit 4b1447809ffbc0d77c0ad456bd6b3afcf0b8623e -Author: Lasse Collin -Date: 2020-02-07 15:32:21 +0200 - - Build: Add support for translated man pages using po4a. + The partial_update_mode enumeration had three states, _DISABLED, + _START, and _ENABLED. Main thread changed it from _DISABLED to _START + while holding a mutex. Once set to _START, worker thread changed it + to _ENABLED without a mutex. Later main thread read it without a mutex, + so it could see either _START or _ENABLED. However, it made no + difference because the main thread checked for != _DISABLED, so + it didn't matter if it saw _START or _ENABLED. - The dependency on po4a is optional. It's never required to install - the translated man pages when xz is built from a release tarball. - If po4a is missing when building from xz.git, the translated man - pages won't be generated but otherwise the build will work normally. + Nevertheless, such things must not be done. It's clear it was a mistake + because there were two comments that directly contradicted each + other about how the variable was accessed. - The translations are only updated automatically by autogen.sh and - by "make mydist". This makes it easy to keep po4a as an optional - dependency and ensures that I won't forget to put updated - translations to a release tarball. + Split the enumeration into two booleans: - The translated man pages aren't installed if --disable-nls is used. + - partial_update_enabled: A worker thread locks the mutex to read + this variable and the main thread locks the mutex to change the + value. Because only the main thread modifies the variable, the + main thread can read the value without locking the mutex. + This variable replaces the _DISABLED -> _START transition. - The installation of translated man pages abuses Automake internals - by calling "install-man" with redefined dist_man_MANS and man_MANS. - This makes the hairy script code slightly less hairy. If it breaks - some day, this code needs to be fixed; don't blame Automake developers. + - partial_update_started is for worker thread's internal use and thus + needs no mutex. This replaces the _START -> _ENABLED transition. - Also, this adds more quotes to the existing shell script code in - the Makefile.am "-hook"s. + Fixes: Coverity CID 456025 + Fixes: bd93b776c1bd ("liblzma: Fix a deadlock in threaded decoder.") - Makefile.am | 4 ++++ - autogen.sh | 8 ++++--- - po4a/.gitignore | 2 ++ - po4a/po4a.conf | 14 +++++++++++ - po4a/update-po | 45 ++++++++++++++++++++++++++++++++++ - src/scripts/Makefile.am | 64 +++++++++++++++++++++++++++++++++++++------------ - src/xz/Makefile.am | 50 +++++++++++++++++++++++++++----------- - src/xzdec/Makefile.am | 55 ++++++++++++++++++++++++++++++++---------- - 8 files changed, 197 insertions(+), 45 deletions(-) + src/liblzma/common/stream_decoder_mt.c | 79 +++++++++++++++------------------- + 1 file changed, 34 insertions(+), 45 deletions(-) -commit 882fcfdcd86525cc5c6f6d0bf0230d0089206d13 +commit 2686554da0103580a472919220931c397b1d1f7a Author: Lasse Collin -Date: 2020-02-06 00:04:42 +0200 +Date: 2025-11-02 12:17:50 +0200 - Update THANKS (sync with the master branch). + CI: Add Coverity Scan + + Co-authored-by: Lasse Collin + Fixes: https://github.com/tukaani-project/xz/issues/198 - THANKS | 3 +++ - 1 file changed, 3 insertions(+) + .github/workflows/coverity.yml | 38 ++++++++++++++++++++++++++++++++++++++ + 1 file changed, 38 insertions(+) -commit 134bb7765815d5f265eb0bc9e6ebacd9ae4a52bc +commit 1b30734c9c08a3f628574d172f1a6034277a2163 Author: Lasse Collin -Date: 2020-02-05 22:35:06 +0200 +Date: 2025-11-25 13:55:35 +0200 - Update tests/.gitignore. + Change the sorting order in THANKS + + In short, sort the names with this command (-k1,1 isn't needed because + the lines with names start with " -"): + + LC_ALL=en_US.UTF-8 sort -k2,2 -k3,3 -k4,4 -k5,5 + + When THANKS was created, I wrote the names as "First Last" and attempted + to keep them sorted by last name / surname / family name. This works + with many names in THANKS, but it becomes complicated with names that + don't fit that pattern. For example, names that are written as + "Last First" can be manually sorted by family name, but only if one + knows which part of the name is the family name.[*] And of course, + the concept of first/last name doesn't apply to all names. + + [*] xz had a co-maintainer who could help me with such names, + but fortunately he isn't working on the project anymore. + + Adding the names in chronological order could have worked too, although + if something is contributed by multiple people, one would still have to + decide how to sort the names within the batch. Another downside would + be that if THANKS is updated in more than one work-in-progress branch, + merge conflicts would occur more often. + + Don't attempt to sort by last name. Let's be happy that people tend to + provide names that can be expressed in a reasonable number of printable + Unicode characters. In practice, people have been even nicer: if the + native language doesn't use a Latin script alphabet, people often provide + a transliterated name (only or in addition to the original spelling), + which is very much appreciated by those who don't know the native script. + + Treat the names as opaque strings or space-separated strings for sorting + purposes. This means that most names will now be sorted by first name. + There still are many choices how to sort: + + (1) LC_ALL=en_US.UTF-8 sort + + The project is in English, so this may sound like a logical choice. + However, spaces have a lower weight than letters, which results in + this order: + + - A Ba + - Ab C + - A Bc + - A Bd + + (2) LC_ALL=en_US.UTF-8 sort -k2,2 + + This first sorts by the first word and then by the rest of the + string. It's -k2,2 instead of -k1,1 to skip the leading dash. + + - A Ba + - A Bc + - A Bd + - Ab C + + I like this more than (1). One could add -k3,3 -k4,4 -k5,5 ... too. + With current THANKS it makes no difference but it might some day. + + NOTE: The ordering in en_US.UTF-8 can differ between libc versions + and operating systems. Luckily it's not a big deal in THANKS. + + (3) LC_ALL=en_US.UTF-8 sort -f -k2,2 + + Passing -f (--ignore-case) to sort affects sorting of single-byte + characters but not multibyte characters (GNU coreutils 9.9): + + No -f With -f LC_ALL=C + Aa A.A A.A + A.A Aa Aa + Ää Ää Ä.Ä + Ä.Ä Ä.Ä Ää + + In GNU coreutils, the THANKS file is sorted using "sort -f -k1,1". + There is also a basic check that the en_US.UTF-8 locale is + behaving as expected. + + (4) LC_ALL=C sort + + This sorts by byte order which in UTF-8 is the same as Unicode + code point order. With the strings in (1) and (2), this produces + the same result as in (2). The difference in (3) can be seen above. + + The results differ from en_US.UTF-8 when a name component starts + with a lower case ASCII letter (like "von" or "de"). Worse, any + non-ASCII characters sort after ASCII chars. These properties might + look weird in English language text, although it's good to remember + that en_US.UTF-8 sorting can appear weird too if one's native + language isn't English. + + The choice between (2) and (4) was difficult but I went with (2). + + ;-) - .gitignore | 4 ++++ - 1 file changed, 4 insertions(+) + THANKS | 414 ++++++++++++++++++++++++++++++++--------------------------------- + 1 file changed, 207 insertions(+), 207 deletions(-) -commit 6912472fafb656be8f4c5b4ac9ea28fea3065de4 +commit 8bb516887c1912106a72db96216cab46954e6190 Author: Lasse Collin -Date: 2020-02-05 22:28:51 +0200 +Date: 2025-11-23 20:39:28 +0200 - Update m4/.gitignore. + Landlock: Add missing #ifdefs + + The build was broken on distros that have an old . + + Fixes: 2b2652e914b1 ("Landlock: Workaround a bug in RHEL 9 kernel") - m4/.gitignore | 1 + - 1 file changed, 1 insertion(+) + src/common/my_landlock.h | 6 ++++++ + 1 file changed, 6 insertions(+) -commit 68c60735bbb6e51d4205ba8a9fde307bcfb22f8c +commit 23c95c6a7c374962103dbd35cb79fdd5a6fe8b52 Author: Lasse Collin -Date: 2020-02-05 20:47:38 +0200 +Date: 2025-11-23 20:13:50 +0200 - Update THANKS. + Update THANKS - THANKS | 1 + - 1 file changed, 1 insertion(+) + THANKS | 2 ++ + 1 file changed, 2 insertions(+) -commit e1beaa74bc7cb5a409d59b55870e01ae7784ce3a +commit 2b2652e914b1c38d4c009a8dcac11dfee9c7e008 Author: Lasse Collin -Date: 2020-02-05 20:33:50 +0200 +Date: 2025-11-23 20:13:49 +0200 - xz: Comment out annoying sandboxing messages. + Landlock: Workaround a bug in RHEL 9 kernel + + If one runs xz 5.8.0 or 5.8.1 from some other distribution in a container + on RHEL 9, xz will fail with the message "Failed to enable the sandbox". + + RHEL 9 kernel since 5.14.0-603.el9 (2025-07-30) claims to support + Landlock ABI version 6, but it lacks support for LANDLOCK_SCOPE_SIGNAL. + The issue is still present in 5.14.0-643.el9 (2025-11-22). Red Hat is + aware of the issue, but I don't know when it will be fixed. + + The sandbox is meant to be transparent to users, thus there isn't and + won't be a command line option to disable it. Instead, add a workaround + to keep xz working on the buggy RHEL 9 kernels. + + Reported-by: Richard W.M. Jones + Thanks-to: Pavel Raiskup + Tested-by: Orgad Shaneh + Tested-by: Richard W.M. Jones + Fixes: https://github.com/tukaani-project/xz/issues/199 + Link: https://issues.redhat.com/browse/RHEL-125143 + Link: https://bugzilla.redhat.com/show_bug.cgi?id=2407105 + Link: https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org/message/65BDSY56R5ZJRTUC4B6CIVCVLY4LG4ME/ - src/xz/file_io.c | 10 +++++++--- - 1 file changed, 7 insertions(+), 3 deletions(-) + src/common/my_landlock.h | 27 ++++++++++++++++++++++++++- + 1 file changed, 26 insertions(+), 1 deletion(-) -commit 8238192652290df78bd728b20e3f6542d1a2819e +commit ee75c76958dd891906745125590563ab64e85995 Author: Lasse Collin -Date: 2020-02-05 19:33:37 +0200 +Date: 2025-11-23 20:13:37 +0200 - Build: Workaround a POSIX shell detection problem on Solaris. + Landlock: Cache the ABI version - I don't know if the problem is in gnulib's gl_POSIX_SHELL macro - or if xzgrep does something that isn't in POSIX. The workaround - adds a special case for Solaris: if /usr/xpg4/bin/sh exists and - gl_cv_posix_shell wasn't overriden on the configure command line, - use that shell for xzgrep and other scripts. That shell is known - to work and exists on most Solaris systems. + In xz it can avoid up to two syscalls that query the ABI version. - configure.ac | 10 ++++++++++ - 1 file changed, 10 insertions(+) + src/common/my_landlock.h | 14 +++++++++++++- + 1 file changed, 13 insertions(+), 1 deletion(-) -commit 93a1f61e892e145607dd938e3b30098af19a1672 +commit f57b1716cd0853474980c90a892204dee9bdea1a Author: Lasse Collin -Date: 2020-02-03 22:03:50 +0200 +Date: 2025-11-03 14:52:45 +0200 - Build: Update m4/ax_pthread.m4 from Autoconf Archive. + Update THANKS - m4/ax_pthread.m4 | 398 ++++++++++++++++++++++++++++++++++++++----------------- - 1 file changed, 279 insertions(+), 119 deletions(-) + THANKS | 1 + + 1 file changed, 1 insertion(+) -commit d0daa21792ff861e5423bbd82aaa6c8ba9fa0462 +commit 211cde09236165dbd379644753337be1de64b151 Author: Lasse Collin -Date: 2020-02-01 19:56:18 +0200 +Date: 2025-11-03 12:41:31 +0200 - xz: Limit --memlimit-compress to at most 4020 MiB for 32-bit xz. + mythread.h: Fix the build on Emscripten when threading is disabled - See the code comment for reasoning. It's far from perfect but - hopefully good enough for certain cases while hopefully doing - nothing bad in other situations. + To make a non-threaded liblzma-only build work with WASI SDK, + and mythread_sigmask() were omitted from mythread.h in the commit + 81db3b889830. This broke non-threaded full build with Emscripten because + src/xz/signals.c needs mythread_sigmask() (liblzma-only build was fine). - At presets -5 ... -9, 4020 MiB vs. 4096 MiB makes no difference - on how xz scales down the number of threads. + If __wasm__ is defined, omit and mythread_sigmask() in + non-threaded builds only when __EMSCRIPTEN__ isn't defined. - The limit has to be a few MiB below 4096 MiB because otherwise - things like "xz --lzma2=dict=500MiB" won't scale down the dict - size enough and xz cannot allocate enough memory. With - "ulimit -v $((4096 * 1024))" on x86-64, the limit in xz had - to be no more than 4085 MiB. Some safety margin is good though. - - This is hack but it should be useful when running 32-bit xz on - a 64-bit kernel that gives full 4 GiB address space to xz. - Hopefully this is enough to solve this: - - https://bugzilla.redhat.com/show_bug.cgi?id=1196786 - - FreeBSD has a patch that limits the result in tuklib_physmem() - to SIZE_MAX on 32-bit systems. While I think it's not the way - to do it, the results on --memlimit-compress have been good. This - commit should achieve practically identical results for compression - while leaving decompression and tuklib_physmem() and thus - lzma_physmem() unaffected. + Reported-by: Marcus Tillmanns + Thanks-to: ChanTsune + Fixes: https://github.com/tukaani-project/xz/issues/161 + Fixes: 81db3b889830 ("mythread.h: Disable signal functions in builds targeting Wasm + WASI.") - src/xz/hardware.c | 32 +++++++++++++++++++++++++++++++- - src/xz/xz.1 | 21 ++++++++++++++++++++- - 2 files changed, 51 insertions(+), 2 deletions(-) + src/common/mythread.h | 3 ++- + 1 file changed, 2 insertions(+), 1 deletion(-) -commit 4433c2dc5727ee6aef570e001a5a024e0d94e609 +commit cbf50a99e3f0c2735fd573e166baf37df063b37b Author: Lasse Collin -Date: 2020-01-26 20:53:25 +0200 +Date: 2025-11-03 11:56:32 +0200 - xz: Set the --flush-timeout deadline when the first input byte arrives. - - xz --flush-timeout=2000, old version: - - 1. xz is started. The next flush will happen after two seconds. - 2. No input for one second. - 3. A burst of a few kilobytes of input. - 4. No input for one second. - 5. Two seconds have passed and flushing starts. - - The first second counted towards the flush-timeout even though - there was no pending data. This can cause flushing to occur more - often than needed. - - xz --flush-timeout=2000, after this commit: + Translations: Update the Serbian man page translations - 1. xz is started. - 2. No input for one second. - 3. A burst of a few kilobytes of input. The next flush will - happen after two seconds counted from the time when the - first bytes of the burst were read. - 4. No input for one second. - 5. No input for another second. - 6. Two seconds have passed and flushing starts. + The earlier bug fixes are now included in the Translation Project. - src/xz/coder.c | 6 +----- - src/xz/file_io.c | 6 +++++- - src/xz/mytime.c | 1 - - 3 files changed, 6 insertions(+), 7 deletions(-) + po4a/sr.po | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) -commit acc0ef3ac80f18e349c6d0252177707105c0a29c +commit 68d1591187512d8872615c8a904d43073440d93f Author: Lasse Collin -Date: 2020-01-26 20:19:19 +0200 +Date: 2025-11-02 19:40:55 +0200 - xz: Move flush_needed from mytime.h to file_pair struct in file_io.h. + xz: Silence a compiler warning when signals_block_count is unused + + Move the static variable signals_block_count to the #ifndef block + that already has the functions that need the variable. - src/xz/coder.c | 3 ++- - src/xz/file_io.c | 3 ++- - src/xz/file_io.h | 3 +++ - src/xz/mytime.c | 3 --- - src/xz/mytime.h | 4 ---- - 5 files changed, 7 insertions(+), 9 deletions(-) + src/xz/signals.c | 7 ++++--- + 1 file changed, 4 insertions(+), 3 deletions(-) -commit 4afe69d30b66812682a2016ee18441958019cbb2 +commit beca015891fbd22657663ec23809184dda0677cd Author: Lasse Collin -Date: 2020-01-26 14:49:22 +0200 +Date: 2025-11-02 17:45:20 +0200 - xz: coder.c: Make writing output a separate function. + xz: Silence a warning from Clang on glibc systems - The same code sequence repeats so it's nicer as a separate function. - Note that in one case there was no test for opt_mode != MODE_TEST, - but that was only because that condition would always be true, so - this commit doesn't change the behavior there. + Fixes: e8838b2f5922 ("xz: Look at resource limits when determining the default memlimit") - src/xz/coder.c | 30 +++++++++++++++++------------- - 1 file changed, 17 insertions(+), 13 deletions(-) + src/xz/hardware.c | 13 +++++++++++++ + 1 file changed, 13 insertions(+) -commit ec26f3ace5f9b260ca91508030f07465ae2f9f78 +commit 3e394278ed537575b5db43c09989c6ca99f762de Author: Lasse Collin -Date: 2020-01-26 14:13:42 +0200 +Date: 2025-11-02 14:37:52 +0200 - xz: Fix semi-busy-waiting in xz --flush-timeout. + Translations: Update the Serbian man page translations - When input blocked, xz --flush-timeout=1 would wake up every - millisecond and initiate flushing which would have nothing to - flush and thus would just waste CPU time. The fix disables the - timeout when no input has been seen since the previous flush. + Preserve the bug fixes made in 71ad5e82888f and 4f52e7387012 because + upstream hasn't included them. - src/xz/coder.c | 4 ++++ - src/xz/file_io.c | 15 +++++++++++---- - src/xz/file_io.h | 4 ++++ - 3 files changed, 19 insertions(+), 4 deletions(-) + po4a/sr.po | 17 ++++++----------- + 1 file changed, 6 insertions(+), 11 deletions(-) -commit 38915703241e69a64f133ff9a02ec9100c6019c6 +commit ace28e35732fc43f58ea1aac146fdb73084f2548 Author: Lasse Collin -Date: 2020-01-26 13:47:31 +0200 +Date: 2025-11-02 14:27:10 +0200 - xz: Refactor io_read() a bit. + Translations: Update the Korean man page translations - src/xz/file_io.c | 17 ++++++++--------- - 1 file changed, 8 insertions(+), 9 deletions(-) + po4a/ko.po | 17 ++++++----------- + 1 file changed, 6 insertions(+), 11 deletions(-) -commit f6d24245349cecfae6ec0d2366fa80716c9f6d37 +commit ffd14a099f0d8c92d4f74018d3a52bd2327df4db Author: Lasse Collin -Date: 2020-01-26 13:37:08 +0200 +Date: 2025-11-02 14:24:43 +0200 - xz: Update a comment in file_io.h. + Translations: Update the Italian man page translations - src/xz/file_io.h | 5 ++++- - 1 file changed, 4 insertions(+), 1 deletion(-) + po4a/it.po | 15 +++++---------- + 1 file changed, 5 insertions(+), 10 deletions(-) -commit 15b55d5c63d27f81776edb1abc05872a751fc674 +commit 6f3152874ee375b581aa858fccab7865dcbf6403 Author: Lasse Collin -Date: 2020-01-26 13:27:51 +0200 +Date: 2025-11-02 14:12:23 +0200 - xz: Move the setting of flush_needed in file_io.c to a nicer location. + Translations: Update the Ukrainian man page translations - src/xz/file_io.c | 6 ++---- - 1 file changed, 2 insertions(+), 4 deletions(-) + po4a/uk.po | 15 +++++---------- + 1 file changed, 5 insertions(+), 10 deletions(-) -commit 609c7067859146ffc62ac655f6ba53599c891801 +commit ef67e051d71938a23713d9782a3f0c470ac51b1e Author: Lasse Collin -Date: 2020-02-05 19:56:09 +0200 +Date: 2025-09-28 18:32:05 +0300 - xz: Enable Capsicum sandboxing by default if available. + liblzma: Fix build on old Linux/glibc on ARM64 - It has been enabled in FreeBSD for a while and reported to work fine. + getauxval() can be available even if HWCAP_CRC32 isn't #defined, so + both have to be checked. HWCAP_CRC32 was added in glibc 2.24 (2016). - Thanks to Xin Li. + Fixes: https://github.com/tukaani-project/xz/issues/190 - INSTALL | 6 ------ - configure.ac | 8 ++++---- - 2 files changed, 4 insertions(+), 10 deletions(-) + CMakeLists.txt | 7 +++++++ + configure.ac | 6 +++++- + src/liblzma/check/crc32_arm64.h | 5 +++-- + src/liblzma/check/crc_common.h | 3 ++- + 4 files changed, 17 insertions(+), 4 deletions(-) -commit 00517d125cc26ecece0eebb84c1c3975cd19bee0 +commit 71c2ede383f6dc6661b8a9d844f4bcf81c563643 Author: Lasse Collin -Date: 2019-12-31 22:41:45 +0200 +Date: 2025-10-31 14:36:26 +0200 - Rename unaligned_read32ne to read32ne, and similarly for the others. + CI: Update Solaris - src/common/tuklib_integer.h | 64 +++++++++++++++---------------- - src/liblzma/common/alone_encoder.c | 2 +- - src/liblzma/common/block_header_decoder.c | 2 +- - src/liblzma/common/block_header_encoder.c | 2 +- - src/liblzma/common/memcmplen.h | 9 ++--- - src/liblzma/common/stream_flags_decoder.c | 6 +-- - src/liblzma/common/stream_flags_encoder.c | 8 ++-- - src/liblzma/lz/lz_encoder_hash.h | 2 +- - src/liblzma/lzma/lzma_decoder.c | 2 +- - src/liblzma/lzma/lzma_encoder.c | 2 +- - src/liblzma/lzma/lzma_encoder_private.h | 3 +- - src/liblzma/simple/simple_decoder.c | 2 +- - src/liblzma/simple/simple_encoder.c | 2 +- - tests/test_block_header.c | 4 +- - tests/test_stream_flags.c | 6 +-- - 15 files changed, 54 insertions(+), 62 deletions(-) + .github/workflows/solaris.yml | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) -commit 52d89d8443c4a31a69c0701062f2c7711d82bbed +commit 02da8de0edddd31a3e9818c2200b97c446d6eb5b Author: Lasse Collin -Date: 2019-12-31 00:29:48 +0200 +Date: 2025-10-31 14:32:47 +0200 - Rename read32ne to aligned_read32ne, and similarly for the others. - - Using the aligned methods requires more care to ensure that - the address really is aligned, so it's nicer if the aligned - methods are prefixed. The next commit will remove the unaligned_ - prefix from the unaligned methods which in liblzma are used in - more places than the aligned ones. + CI: Update DragonFly BSD - src/common/tuklib_integer.h | 56 +++++++++++++++++++++--------------------- - src/liblzma/check/crc32_fast.c | 4 +-- - src/liblzma/check/crc64_fast.c | 4 +-- - 3 files changed, 32 insertions(+), 32 deletions(-) + .github/workflows/dragonflybsd.yml | 8 ++++---- + 1 file changed, 4 insertions(+), 4 deletions(-) -commit 850620468b57d49f16093e5870d1050886fcb37a +commit 75b18d325f6a993eac2d5f44c7aad941aa20df94 Author: Lasse Collin -Date: 2019-12-31 00:18:24 +0200 +Date: 2025-10-31 14:30:24 +0200 - Revise tuklib_integer.h and .m4. - - Add a configure option --enable-unsafe-type-punning to get the - old non-conforming memory access methods. It can be useful with - old compilers or in some other less typical situations but - shouldn't normally be used. - - Omit the packed struct trick for unaligned access. While it's - best in some cases, this is simpler. If the memcpy trick doesn't - work, one can request unsafe type punning from configure. - - Because CRC32/CRC64 code needs fast aligned reads, if no very - safe way to do it is found, type punning is used as a fallback. - This sucks but since it currently works in practice, it seems to - be the least bad option. It's never needed with GCC >= 4.7 or - Clang >= 3.6 since these support __builtin_assume_aligned and - thus fast aligned access can be done with the memcpy trick. - - Other things: - - Support GCC/Clang __builtin_bswapXX - - Cleaner bswap fallback macros - - Minor cleanups + CI: Update NetBSD - m4/tuklib_integer.m4 | 43 ++++ - src/common/tuklib_integer.h | 488 ++++++++++++++++++++++++-------------------- - 2 files changed, 314 insertions(+), 217 deletions(-) + .github/workflows/netbsd.yml | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) -commit a45badf0342666462cc6a7107a071418570ab773 +commit 0102072915f38e747ee55aa9c52351dfe81b8c14 Author: Lasse Collin -Date: 2019-12-29 22:51:58 +0200 +Date: 2025-10-31 14:21:37 +0200 - Tests: Hopefully fix test_check.c to work on EBCDIC systems. - - Thanks to Daniel Richard G. + CI: Update FreeBSD - tests/test_check.c | 9 +++++++-- - 1 file changed, 7 insertions(+), 2 deletions(-) + .github/workflows/freebsd.yml | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) -commit c9a8071e6690a8db8a485c075920df254e7c70ea +commit 83419783a67a6097c7d5ed5663734c04eb8c8b55 Author: Lasse Collin -Date: 2019-09-24 23:02:40 +0300 +Date: 2025-10-31 14:17:30 +0200 - Scripts: Put /usr/xpg4/bin to the beginning of PATH on Solaris. - - This adds a configure option --enable-path-for-scripts=PREFIX - which defaults to empty except on Solaris it is /usr/xpg4/bin - to make POSIX grep and others available. The Solaris case had - been documented in INSTALL with a manual fix but it's better - to do this automatically since it is needed on most Solaris - systems anyway. - - Thanks to Daniel Richard G. + CI: Update OpenBSD - INSTALL | 43 +++++++++++++++++++++++++++++++++++-------- - configure.ac | 26 ++++++++++++++++++++++++++ - src/scripts/xzdiff.in | 1 + - src/scripts/xzgrep.in | 1 + - src/scripts/xzless.in | 1 + - src/scripts/xzmore.in | 1 + - 6 files changed, 65 insertions(+), 8 deletions(-) + .github/workflows/openbsd.yml | 6 +++--- + 1 file changed, 3 insertions(+), 3 deletions(-) -commit aba140e2df3ff63ad124ae997de16d517b98ca50 +commit 3b5f5af9bcd9b5752608a099fcfab331c0c613b3 Author: Lasse Collin -Date: 2019-07-12 18:57:43 +0300 +Date: 2025-10-26 12:07:34 +0200 - Fix comment typos in tuklib_mbstr* files. + Update THANKS - src/common/tuklib_mbstr.h | 2 +- - src/common/tuklib_mbstr_fw.c | 2 +- - src/common/tuklib_mbstr_width.c | 2 +- - 3 files changed, 3 insertions(+), 3 deletions(-) + THANKS | 2 ++ + 1 file changed, 2 insertions(+) -commit 710f5bd769a5d2bd8684256c2727d15350ee2ab8 -Author: Lasse Collin -Date: 2019-07-12 18:30:46 +0300 +commit e8838b2f59221f46bf34c79431d286e8ac34fb8b +Author: Kirill A. Korinsky +Date: 2025-10-26 12:07:34 +0200 - Add missing include to tuklib_mbstr_width.c. + xz: Look at resource limits when determining the default memlimit - It didn't matter in XZ Utils because sysdefs.h - includes string.h anyway. + When no memory usage limits have been set by the user, the default + for multithreaded mode has been 1/4 of total RAM. If this limit is + too high and memory allocation fails, liblzma (and xz) fail. Perhaps + liblzma should handle it better by reducing the number of threads + and continuing with the amount of memory it can allocate, but currently + that isn't the case. + + If resource limits were set to about 1/4 of RAM or lower, then xz + could fail for the above reason. This commit makes xz look at + RLIMIT_DATA, RLIMIT_AS, and RLIMIT_VMEM when they are available, + and set the limit 64 MiB below the lowest of those limits. This is + more or less a hack just like the 1/4-of-RAM method is, but this is + simple and quick to implement. + + On Linux, there are other limits like cgroup v2 memory.max which + can still make xz fail. The same is likely possible with FreeBSD's + rctl(8). + + Co-authored-by: Lasse Collin + Thanks-to: Fangrui Song + Fixes: https://github.com/tukaani-project/xz/issues/195 + Closes: https://github.com/tukaani-project/xz/pull/196 - src/common/tuklib_mbstr_width.c | 1 + - 1 file changed, 1 insertion(+) + CMakeLists.txt | 3 +++ + configure.ac | 4 ++-- + src/xz/hardware.c | 59 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ + 3 files changed, 64 insertions(+), 2 deletions(-) -commit 0e491aa8cd72e0100cd15c1b9469cd57fae500b0 +commit 8d26b72915e0d373f898b55935505857c30dbdb3 Author: Lasse Collin -Date: 2019-06-25 23:15:21 +0300 +Date: 2025-10-01 12:46:26 +0300 - liblzma: Fix a buggy comment. + CI: Remove windows-2019 (which had VS 2019) + + GitHub has removed the runner image. + + A breakage with CLMUL CRC code occurred with VS 2019 but not 2022, + see b5a5d9e3f702. MS supports VS 2019 for a few more years, so it's + unfortunate that it can no longer be tested on GitHub. - src/liblzma/lz/lz_encoder_mf.c | 2 +- + .github/workflows/msvc.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -commit bfc245569f340a75bd71ad32a6beba786712683b +commit 32412bd2a42fda639765c3046e91f964e286b6d9 Author: Lasse Collin -Date: 2019-06-25 00:16:06 +0300 +Date: 2025-09-29 19:34:58 +0300 - configure.ac: Fix a typo in a comment. + Update THANKS - configure.ac | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) + THANKS | 3 +++ + 1 file changed, 3 insertions(+) -commit f18eee9d15a22c8449ef395a05f0eb637c4ad253 -Author: Lasse Collin -Date: 2019-06-25 00:08:13 +0300 +commit eaa150df9803c982adf28d4533c7a4264ea17757 +Author: Lakshmi-Surekha +Date: 2025-07-17 23:27:06 -0500 - Tests: Silence warnings from clang -Wassign-enum. + xz: Don't fsync() directories on AIX + + It fails with EBADF. - Also changed 999 to 99 so it fits even if lzma_check happened - to be 8 bits wide. + Fixes: https://github.com/tukaani-project/xz/issues/188 + Closes: https://github.com/tukaani-project/xz/pull/189 - tests/test_block_header.c | 3 ++- - tests/test_stream_flags.c | 2 +- - 2 files changed, 3 insertions(+), 2 deletions(-) + src/xz/file_io.c | 3 ++- + 1 file changed, 2 insertions(+), 1 deletion(-) -commit 25f74554723e8deabc66fed1abf0ec27a4ed19d5 +commit 61b114e92f53b7977aad69f8a7130fc25d8a80e5 Author: Lasse Collin -Date: 2019-06-24 23:52:17 +0300 +Date: 2025-09-29 18:37:19 +0300 - liblzma: Add a comment. + liblzma: Document that lzma_allocator.free(opaque, NULL) is possible + + It feels better to fix the docs than change the code because this + way newly-written applications will be forced to be compatible with + the lzma_allocator behavior of old liblzma versions. It can matter + if someone builds the application against an older liblzma version. + + Fixes: https://github.com/tukaani-project/xz/issues/183 - src/liblzma/common/stream_encoder_mt.c | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) + src/liblzma/api/lzma/base.h | 4 +++- + 1 file changed, 3 insertions(+), 1 deletion(-) -commit 44eb961f2a51d02420d017bc5ff470360663650c +commit 6d287a3ae90e1b990294f3d5264003d81e853c5e +Author: Simon Josefsson +Date: 2025-08-26 09:41:02 +0200 + + Update GPLv2 and LGPLv2.1 copies from gnu.org + + Closes: https://github.com/tukaani-project/xz/pull/194 + + COPYING.GPLv2 | 9 ++++----- + COPYING.LGPLv2.1 | 9 ++++----- + 2 files changed, 8 insertions(+), 10 deletions(-) + +commit 41a421dbadf13af2a59aaafa43836026b83340a7 Author: Lasse Collin -Date: 2019-06-24 23:45:21 +0300 +Date: 2025-05-24 12:07:13 +0300 - liblzma: Silence clang -Wmissing-variable-declarations. + tests/test_suffix.sh: Avoid variables in printf format string - src/liblzma/check/crc32_table.c | 3 +++ - src/liblzma/check/crc64_table.c | 3 +++ - 2 files changed, 6 insertions(+) + tests/test_suffix.sh | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) -commit 267afcd9955e668c1532b069230c21c348eb4f82 +commit a2c6aa8764a2e5248572d461305bd05c5950bf94 Author: Lasse Collin -Date: 2019-06-24 22:57:43 +0300 +Date: 2025-05-24 12:02:09 +0300 - xz: Silence a warning from clang -Wsign-conversion in main.c. + build-aux/manconv.sh: Add quotes - src/xz/main.c | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) + build-aux/manconv.sh | 8 ++++---- + 1 file changed, 4 insertions(+), 4 deletions(-) -commit 0e3c4002f809311ecef239b05e556d9c462b5703 +commit 8e4153253eea2b5a9466467b2ce0249e56277c9a Author: Lasse Collin -Date: 2019-06-24 22:47:39 +0300 +Date: 2025-05-24 12:01:35 +0300 - liblzma: Remove incorrect uses of lzma_attribute((__unused__)). + windows/build.bash: Add quotes - Caught by clang -Wused-but-marked-unused. + In this case they aren't needed but it's better style. - src/liblzma/common/alone_decoder.c | 3 +-- - src/liblzma/common/alone_encoder.c | 3 +-- - src/liblzma/lz/lz_decoder.c | 3 +-- - 3 files changed, 3 insertions(+), 6 deletions(-) + windows/build.bash | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) -commit cb708e8fa3405ec13a0ebfebbbf2793f927deab1 +commit 37a57a926dd1ae6cde1544d8487e27982d2db4a4 Author: Lasse Collin -Date: 2019-06-24 20:53:55 +0300 +Date: 2025-05-24 12:00:13 +0300 - Tests: Silence a warning from -Wsign-conversion. + po4a/update-po: Ensure that a glob won't expand to a command line option - tests/create_compress_files.c | 8 ++++---- - 1 file changed, 4 insertions(+), 4 deletions(-) + po4a/update-po | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) -commit c8cace3d6e965c0fb537591372bf71b9357dd76c +commit e3ba73034a3f8e414882af39d62f479e9717e061 Author: Lasse Collin -Date: 2019-06-24 20:45:49 +0300 +Date: 2025-05-24 11:57:23 +0300 - xz: Fix an integer overflow with 32-bit off_t. - - Or any off_t which isn't very big (like signed 64 bit integer - that most system have). A small off_t could overflow if the - file being decompressed had long enough run of zero bytes, - which would result in corrupt output. + liblzma: validate_map.sh: Catch some unlikely errors - src/xz/file_io.c | 11 +++++++++-- - 1 file changed, 9 insertions(+), 2 deletions(-) + src/liblzma/validate_map.sh | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +commit 067cecdea69067973e44dc1afb9be763faccecb2 +Author: Lasse Collin +Date: 2025-05-24 11:55:59 +0300 + + CI: Catch unsupported arguments in ci_build.bash -commit 65a42741e290fbcd85dfc5db8a62c4bce5f7712c + build-aux/ci_build.bash | 4 ++++ + 1 file changed, 4 insertions(+) + +commit 4fc6208abebfe6b8c8348c412b4bcc594ae11c88 Author: Lasse Collin -Date: 2019-06-24 00:57:23 +0300 +Date: 2025-05-13 20:42:26 +0300 - Tests: Remove a duplicate branch from tests/tests.h. + Scripts: Add shellcheck directives to silence warnings - The duplication was introduced about eleven years ago and - should have been cleaned up back then already. + Set also shell because the xz*.in files start with '#!@POSIX_SHELL@'. - This was caught by -Wduplicated-branches. + SC1003 and SC2016 are only info messages, not warnings. Several other + shellcheck info messages remain. They are safe to ignore, but I didn't + want to disable them now. + + Partially-fixes: https://github.com/tukaani-project/xz/issues/174 - tests/tests.h | 9 ++------- - 1 file changed, 2 insertions(+), 7 deletions(-) + src/scripts/xzdiff.in | 4 ++++ + src/scripts/xzgrep.in | 2 ++ + src/scripts/xzless.in | 2 ++ + src/scripts/xzmore.in | 2 ++ + 4 files changed, 10 insertions(+) -commit 5c4fb60e8df026e933afab0cfe0a8b55be20036c +commit 7844aff1a838362403b332c3a68d5732a192923a Author: Lasse Collin -Date: 2019-06-23 23:22:45 +0300 +Date: 2025-05-03 22:45:15 +0300 - tuklib_mbstr_width: Fix a warning from -Wsign-conversion. + Scripts: Silence two shellcheck warnings - src/common/tuklib_mbstr_width.c | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) + src/scripts/xzdiff.in | 2 +- + src/scripts/xzmore.in | 2 +- + 2 files changed, 2 insertions(+), 2 deletions(-) -commit 37df03ce52ce53710e1513387648763f8a744154 +commit 4d439aaeed5c991fbc1ff78d7616e179c30fca1d Author: Lasse Collin -Date: 2019-06-23 23:19:34 +0300 +Date: 2025-09-29 17:29:23 +0300 - xz: Fix some of the warnings from -Wsign-conversion. + Translations: Add Swedish man page translations - src/xz/args.c | 4 ++-- - src/xz/coder.c | 4 ++-- - src/xz/file_io.c | 5 +++-- - src/xz/message.c | 4 ++-- - src/xz/mytime.c | 4 ++-- - src/xz/options.c | 2 +- - src/xz/util.c | 4 ++-- - 7 files changed, 14 insertions(+), 13 deletions(-) + po4a/po4a.conf | 2 +- + po4a/sv.po | 3909 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ + 2 files changed, 3910 insertions(+), 1 deletion(-) -commit 7c65ae0f5f2e2431f88621e8fe6d1dc7907e30c1 +commit dd4a1b259936880e04669b43e778828b60619860 Author: Lasse Collin -Date: 2019-06-23 22:27:45 +0300 +Date: 2025-05-23 13:09:14 +0300 - tuklib_cpucores: Silence warnings from -Wsign-conversion. + CI: Add timeout-minutes + + Sometimes the VM workflows (like FreeBSD VM on Ubuntu) get stuck + and the default timeout is six hours. While at it, set a sensible + timeout for all workflows. - src/common/tuklib_cpucores.c | 10 +++++----- - 1 file changed, 5 insertions(+), 5 deletions(-) + .github/workflows/ci.yml | 1 + + .github/workflows/cifuzz.yml | 1 + + .github/workflows/dragonflybsd.yml | 1 + + .github/workflows/freebsd.yml | 1 + + .github/workflows/msvc.yml | 1 + + .github/workflows/msys2.yml | 1 + + .github/workflows/netbsd.yml | 1 + + .github/workflows/openbsd.yml | 1 + + .github/workflows/solaris.yml | 1 + + 9 files changed, 9 insertions(+) -commit a502dd1d000b598406637d452f535f4bbd43e2a4 +commit d660fe5d56a804b0ef3eea550fdcd51dbe17e45b Author: Lasse Collin -Date: 2019-06-23 21:40:47 +0300 +Date: 2025-05-23 12:25:36 +0300 - xzdec: Fix warnings from -Wsign-conversion. + liblzma: Fix grammar in API docs + + Fixes: a27920002dbc ("liblzma: Add generic support for input seeking (LZMA_SEEK).") - src/xzdec/xzdec.c | 2 +- + src/liblzma/api/lzma/base.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -commit a45d1a5374ceb22e23255b0b595b9e641e9860af +commit ab45bdf4322879dc2859b1f66f1f8cf89cdebe2c Author: Lasse Collin -Date: 2019-06-23 21:38:56 +0300 +Date: 2025-05-21 16:07:01 +0300 - liblzma: Fix warnings from -Wsign-conversion. - - Also, more parentheses were added to the literal_subcoder - macro in lzma_comon.h (better style but no functional change - in the current usage). + Update THANKS - src/liblzma/common/block_header_decoder.c | 2 +- - src/liblzma/delta/delta_decoder.c | 2 +- - src/liblzma/lzma/fastpos.h | 2 +- - src/liblzma/lzma/lzma2_decoder.c | 8 ++++---- - src/liblzma/lzma/lzma_common.h | 3 ++- - src/liblzma/lzma/lzma_decoder.c | 16 ++++++++-------- - src/liblzma/simple/arm.c | 6 +++--- - src/liblzma/simple/armthumb.c | 8 ++++---- - src/liblzma/simple/ia64.c | 2 +- - src/liblzma/simple/powerpc.c | 9 +++++---- - src/liblzma/simple/x86.c | 2 +- - 11 files changed, 31 insertions(+), 29 deletions(-) + THANKS | 1 + + 1 file changed, 1 insertion(+) -commit 4ff87ddf80ed7cb233444cddd86ab1940b5b55ec +commit f0239936532d40be05e75384c37fb8d6c1bb4ff6 Author: Lasse Collin -Date: 2019-06-23 19:33:55 +0300 +Date: 2025-05-21 16:07:01 +0300 - tuklib_integer: Silence warnings from -Wsign-conversion. + CMake: With symbol versioning, try to pass --undefined-version to linker + + Fixes: https://github.com/tukaani-project/xz/issues/180 + Fixes: https://bugs.gentoo.org/956119 - src/common/tuklib_integer.h | 6 +++--- - 1 file changed, 3 insertions(+), 3 deletions(-) + CMakeLists.txt | 22 ++++++++++++++++++++++ + 1 file changed, 22 insertions(+) -commit ed1a9d33984a3a37ae9a775a46859850d98ea4d0 +commit 377be0ea7a1d0ec3572a7f9a5f9ed42adeaa4503 Author: Lasse Collin -Date: 2019-06-20 19:40:30 +0300 +Date: 2025-05-21 16:07:01 +0300 - tuklib_integer: Fix usage of conv macros. + Build: With symbol versioning, try to pass --undefined-version to linker - Use a temporary variable instead of e.g. - conv32le(unaligned_read32ne(buf)) because the macro can - evaluate its argument multiple times. + Fixes: https://github.com/tukaani-project/xz/issues/180 + Fixes: https://bugs.gentoo.org/956119 - src/common/tuklib_integer.h | 12 ++++++++---- - 1 file changed, 8 insertions(+), 4 deletions(-) + configure.ac | 23 +++++++++++++++++++++++ + src/liblzma/Makefile.am | 2 ++ + 2 files changed, 25 insertions(+) -commit 612c88dfc08e2c572623954ecfde541d21c84882 +commit ff49c82176ca53646a1cbbbb4efc35a542745812 Author: Lasse Collin -Date: 2019-06-03 20:44:19 +0300 +Date: 2025-05-21 14:48:18 +0300 - Update THANKS. + CMake: Fix comments - THANKS | 1 + - 1 file changed, 1 insertion(+) + CMakeLists.txt | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) -commit 85da31d8b882b8b9671ab3e3d74d88bd945cd0bb +commit 71ad5e82888fdfa0fe11defa4f46cb0fc90dc326 Author: Lasse Collin -Date: 2019-06-03 20:41:54 +0300 +Date: 2025-05-21 13:14:04 +0300 - liblzma: Fix comments. + Translations: Update Serbian man page translations + + Compared to the file in the Translation Project, I still had to apply + a few fixes that were needed with the previous (5.7.1-dev1) version too: + + - Remove two extra '<' characters that break the build with po4a. - Thanks to Bruce Stark. + - Don't translate XZ_DEFAULTS and XZ_OPT environment variable names. - src/liblzma/common/alone_encoder.c | 4 ++-- - src/liblzma/common/block_util.c | 2 +- - src/liblzma/common/common.c | 2 +- - src/liblzma/common/filter_common.h | 2 +- - src/liblzma/common/filter_decoder.h | 2 +- - src/liblzma/common/filter_flags_encoder.c | 2 +- - 6 files changed, 7 insertions(+), 7 deletions(-) + po4a/sr.po | 70 ++++++++++++++++++++------------------------------------------ + 1 file changed, 22 insertions(+), 48 deletions(-) -commit 6a73a7889587aa394e236c7e9e4f870b44851036 +commit 31a983ad4774054074b300f55ff519484ff182c2 Author: Lasse Collin -Date: 2019-06-02 00:50:59 +0300 +Date: 2025-05-21 12:55:28 +0300 - liblzma: Fix one more unaligned read to use unaligned_read16ne(). + Update po/.gitignore - src/liblzma/lz/lz_encoder_hash.h | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) + po/.gitignore | 1 + + 1 file changed, 1 insertion(+) -commit ce59b34ec9ac344d62a57cad5f94f695f42cdaee +commit d9e70da25ac761544146bc2fbab6443e1a080bf4 Author: Lasse Collin -Date: 2019-06-01 21:41:55 +0300 +Date: 2025-05-21 12:54:42 +0300 - Update THANKS. + Translations: Update the Spanish translation - THANKS | 1 + - 1 file changed, 1 insertion(+) + po/es.po | 10 +++++----- + 1 file changed, 5 insertions(+), 5 deletions(-) -commit 94aa3fb568fe41dd4925a961966ed5cf8213bd1f +commit dbfb925c8198087afb3527e6c57b66fae1a980bb Author: Lasse Collin -Date: 2019-06-01 21:36:13 +0300 +Date: 2025-05-03 12:37:28 +0300 - liblzma: memcmplen: Use ctz32() from tuklib_integer.h. + Tests: Silence a warning from GCC 15.1 + + It was (probably) intentionally without the null terminator, but the test + works with null terminator too (the test still fails with xz <= 5.0.3), + so simply omit one character to silence the warning. + + tests/test_bcj_exact_size.c:30:32: error: initializer-string for array of ‘unsigned char’ truncates NUL terminator but destination lacks ‘nonstring’ attribute (17 chars into 16 available) [-Werror=unterminated-string-initialization] + 30 | const uint8_t in[16] = "0123456789ABCDEF"; + | ^~~~~~~~~~~~~~~~~~ - The same compiler-specific #ifdefs are already in tuklib_integer.h + Fixes: d8db706acb83 ("liblzma: Fix possibility of incorrect LZMA_BUF_ERROR.") + Fixes: https://github.com/tukaani-project/xz/issues/176 - src/liblzma/common/memcmplen.h | 10 +--------- - 1 file changed, 1 insertion(+), 9 deletions(-) + tests/test_bcj_exact_size.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) -commit 412791486dfb430219d8e30bcbebbfc57a99484a +commit 7c12726c51b2b7d77329dd72a29ecb1ec262b918 Author: Lasse Collin -Date: 2019-06-01 21:30:03 +0300 +Date: 2025-04-28 18:16:14 +0300 - tuklib_integer: Cleanup MSVC-specific code. + Update THANKS - src/common/tuklib_integer.h | 20 +++++++++----------- - 1 file changed, 9 insertions(+), 11 deletions(-) + THANKS | 2 ++ + 1 file changed, 2 insertions(+) -commit efbf6e5f0932e6c1a4250f91ee99059f449f2470 +commit 1bd7361a043bd652ee5d0ebafd23459c57f57993 Author: Lasse Collin -Date: 2019-06-01 19:01:21 +0300 +Date: 2025-04-25 17:32:03 +0300 + + Update THANKS + + THANKS | 1 + + 1 file changed, 1 insertion(+) + +commit 5cc2e479eb447a444f5ab005fc36b7f275c75eb5 +Author: Guillaume Outters +Date: 2025-04-25 02:55:08 +0200 - liblzma: Use unaligned_readXXne functions instead of type punning. + xz, xzdec: Capsicum sandbox: Fix incorrect use of cap_rights_clear() - Now gcc -fsanitize=undefined should be clean. + cap_rights_clear() with no additional arguments acts as a no-op, so + instead of removing all capability rights from STDIN_FILENO, the same + rights were allowed for STDIN_FILENO as were allowed for src_fd. - Thanks to Jeffrey Walton. + Fixes: a0eecc235d3b ("xz: Make Capsicum sandbox more strict with stdin and stdout.") + (The commit message says "stdout". It should have said "stderr".) - src/liblzma/common/memcmplen.h | 12 ++++++------ - src/liblzma/lzma/lzma_encoder_private.h | 2 +- - 2 files changed, 7 insertions(+), 7 deletions(-) + src/xz/sandbox.c | 2 +- + src/xzdec/xzdec.c | 2 +- + 2 files changed, 2 insertions(+), 2 deletions(-) -commit 29afef03486d461c23f57150ac5436684bff7811 +commit 56aa9a07968a6a73fada6f9b96122c5165829f3b Author: Lasse Collin -Date: 2019-06-01 18:41:16 +0300 +Date: 2025-04-22 21:12:50 +0300 - tuklib_integer: Improve unaligned memory access. + CI: Valgrind: Improve the skipping of traced child processes - Now memcpy() or GNU C packed structs for unaligned access instead - of type punning. See the comment in this commit for details. + Use --trace-children-skip instead of --trace-children-skip-by-arg + so that the skipping is only done based on the executable names. + (--trace-children-skip-by-arg can match other args than argv[0].) - Avoiding type punning with unaligned access is needed to - silence gcc -fsanitize=undefined. + Update the list of executables to skip to match what the scripts run. - New functions: unaliged_readXXne and unaligned_writeXXne where - XX is 16, 32, or 64. + Do not skip bash or sh. If Valgrind didn't trace the shell, then the + xz and xzdec programs run by the shell wouldn't be analyzed either. + + Fixes: 7e99856f66c0 ("CI: Speed up Valgrind job by using --trace-children-skip-by-arg=...") - src/common/tuklib_integer.h | 180 +++++++++++++++++++++++++++++++++++++++++--- - 1 file changed, 168 insertions(+), 12 deletions(-) + .github/workflows/ci.yml | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) -commit 596ed3de4485a4b1d83b5fe506ae9d0a172139b4 +commit f33da20b75a45caad25c9a4daf7906e4f056ce91 Author: Lasse Collin -Date: 2019-05-13 20:05:17 +0300 +Date: 2025-04-22 21:12:50 +0300 - liblzma: Avoid memcpy(NULL, foo, 0) because it is undefined behavior. - - I should have always known this but I didn't. Here is an example - as a reminder to myself: - - int mycopy(void *dest, void *src, size_t n) - { - memcpy(dest, src, n); - return dest == NULL; - } + CI: Valgrind: Test with static liblzma - In the example, a compiler may assume that dest != NULL because - passing NULL to memcpy() would be undefined behavior. Testing - with GCC 8.2.1, mycopy(NULL, NULL, 0) returns 1 with -O0 and -O1. - With -O2 the return value is 0 because the compiler infers that - dest cannot be NULL because it was already used with memcpy() - and thus the test for NULL gets optimized out. + If shared liblzma is built, tests/test_* and src/xz/xz are wrapper + scripts created by Libtool. The wrappers set library search path + so that the freshly-built shared library is found. - In liblzma, if a null-pointer was passed to memcpy(), there were - no checks for NULL *after* the memcpy() call, so I cautiously - suspect that it shouldn't have caused bad behavior in practice, - but it's hard to be sure, and the problematic cases had to be - fixed anyway. + With a static liblzma, no wrapper scripts are needed, and Libtool + places the real executables to the aforementioned locations. This + speeds up the tests under Valgrind dramatically. - Thanks to Jeffrey Walton. + Fixes: 6c095a98fbec ("ci: test Valgrind") - src/liblzma/common/common.c | 6 +++++- - src/liblzma/lz/lz_decoder.c | 12 +++++++++--- - src/liblzma/simple/simple_coder.c | 10 +++++++++- - 3 files changed, 23 insertions(+), 5 deletions(-) + .github/workflows/ci.yml | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) -commit b4b83555c576e1d845a2b98a193b23c021437804 +commit 5606fa89f91ca1d0d53e339d88f574fc731049c1 Author: Lasse Collin -Date: 2019-05-11 20:56:08 +0300 +Date: 2025-04-22 21:12:50 +0300 - Update THANKS. + CI: Add Ubuntu on ARM64 - THANKS | 1 + - 1 file changed, 1 insertion(+) + .github/workflows/ci.yml | 27 ++++++++++++++++----------- + 1 file changed, 16 insertions(+), 11 deletions(-) -commit 8d4906262b45557ed164cd74adb270e6ef7f6f03 +commit ec047a65a068087cc6f71133df414858f6886121 Author: Lasse Collin -Date: 2019-05-11 20:54:12 +0300 +Date: 2025-04-22 16:21:50 +0300 - xz: Update xz man page date. + Doxygen: Update the comment about tested versions - src/xz/xz.1 | 2 +- + doxygen/Doxyfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -commit 0d318402f8a022f707622c72f8f1894ea476cf89 -Author: Antoine Cœur -Date: 2019-05-08 13:30:57 +0800 +commit 4f86e77bef8918b0c64183590609357a275558d8 +Author: Lasse Collin +Date: 2025-04-22 16:21:50 +0300 - spelling + Doxygen: Set HAVE_DOT = NO + + Debian and Ubuntu have a patch that changes the upstream default to + HAVE_DOT = YES. Undo it to have more consistent results across distros. + + This was noticed in Ubuntu CI runner where "doxygen" tried to run "dot" + but that failed due to "dot" not being installed. "doxygen" still + finished with exit status 0 until the commit that turned warnings to + errors with WARN_AS_ERROR = FAIL_ON_WARNINGS. - Doxyfile.in | 2 +- - NEWS | 2 +- - src/liblzma/api/lzma/block.h | 2 +- - src/liblzma/api/lzma/hardware.h | 2 +- - src/liblzma/api/lzma/lzma12.h | 2 +- - src/liblzma/api/lzma/vli.h | 2 +- - src/liblzma/common/hardware_physmem.c | 2 +- - src/liblzma/common/index.c | 4 ++-- - src/liblzma/common/stream_encoder_mt.c | 2 +- - src/liblzma/common/vli_decoder.c | 2 +- - src/liblzma/lz/lz_decoder.c | 2 +- - src/scripts/xzgrep.in | 2 +- - src/xz/args.c | 2 +- - src/xz/coder.c | 4 ++-- - src/xz/main.c | 2 +- - src/xz/mytime.h | 2 +- - src/xz/private.h | 2 +- - src/xz/xz.1 | 2 +- - windows/build.bash | 2 +- - 19 files changed, 21 insertions(+), 21 deletions(-) + doxygen/Doxyfile | 4 ++++ + 1 file changed, 4 insertions(+) -commit aeb3be8ac4c4b06a745c3799b80b38159fb78b1a +commit ff96542d1c78f744d992be5890c95d90b2d19047 Author: Lasse Collin -Date: 2019-03-04 22:49:04 +0200 +Date: 2025-04-22 16:21:50 +0300 - README: Update translation instructions. + Doxygen: Treat warnings as errors - XZ Utils is now part of the Translation Project - . + Also set WARN_IF_UNDOCUMENTED = NO because even the API headers have + a few things that won't have their own docs. - README | 32 +++++++++++++------------------- - 1 file changed, 13 insertions(+), 19 deletions(-) + doxygen/Doxyfile | 2 ++ + 1 file changed, 2 insertions(+) -commit 0c238dc3feb0a3eea1e713feb8d338c8dfba9f74 +commit a6711d1c4ad681aad985372d01a7deb21b4a1b8b Author: Lasse Collin -Date: 2018-12-20 20:42:29 +0200 +Date: 2025-04-22 16:21:50 +0300 - Update THANKS. + Doxygen: Fix errors and some warnings in internal docs - THANKS | 1 + - 1 file changed, 1 insertion(+) + src/liblzma/check/crc32_fast.c | 2 +- + src/liblzma/check/crc64_fast.c | 2 +- + src/liblzma/common/outqueue.h | 1 + + src/xz/list.c | 2 ++ + src/xz/message.h | 4 ++++ + 5 files changed, 9 insertions(+), 2 deletions(-) -commit 3ca432d9cce4bf7e793de173dd22025b68611c42 +commit 8efd80adfcd65dfea086c1008452c6424b30b78c Author: Lasse Collin -Date: 2018-12-14 20:34:30 +0200 +Date: 2025-04-22 16:21:50 +0300 - xz: Fix a crash in progress indicator when in passthru mode. - - "xz -dcfv not_an_xz_file" crashed (all four options are - required to trigger it). It caused xz to call - lzma_get_progress(&strm, ...) when no coder was initialized - in strm. In this situation strm.internal is NULL which leads - to a crash in lzma_get_progress(). + CI: Use --disable-sandbox instead of --enable-sandbox=no - The bug was introduced when xz started using lzma_get_progress() - to get progress info for multi-threaded compression, so the - bug is present in versions 5.1.3alpha and higher. - - Thanks to Filip Palian for - the bug report. + It's the same thing, just a style difference. - src/xz/coder.c | 11 +++++++---- - src/xz/message.c | 18 ++++++++++++++++-- - src/xz/message.h | 3 ++- - 3 files changed, 25 insertions(+), 7 deletions(-) + build-aux/ci_build.bash | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) -commit fcc419e3c3f77a8b6fc5056a86b1b8abbe266e62 +commit a2e47c7a59d835ba80beef53b986d45e99ecd94a Author: Lasse Collin -Date: 2018-11-22 17:20:31 +0200 +Date: 2025-04-22 16:21:50 +0300 - xz: Update man page timestamp. + CI: Support Doxygen in ci_build.bash - src/xz/xz.1 | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) + build-aux/ci_build.bash | 4 ++++ + 1 file changed, 4 insertions(+) -commit 5a2fc3cd0194e55df329dd29f805299aaca5f32f -Author: Pavel Raiskup -Date: 2018-11-22 15:14:34 +0100 +commit 9048e724945a3dfbf86d7f97437113f27ea41c63 +Author: Lasse Collin +Date: 2025-04-22 16:21:50 +0300 - 'have have' typos + CI: Add Doxygen dependency to CMake builds on Ubuntu and macOS - src/xz/signals.c | 2 +- - src/xz/xz.1 | 2 +- - 2 files changed, 2 insertions(+), 2 deletions(-) + .github/workflows/ci.yml | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) -commit 7143b04fe49390807f355b1dad686a3d8c4dbdcf +commit d8e9dc63a6124336e72a849b8104ba60720f0fe2 Author: Lasse Collin -Date: 2018-07-27 18:10:44 +0300 +Date: 2025-04-22 16:21:50 +0300 - xzless: Rename unused variables to silence static analysers. - - In this particular case I don't see this affecting readability - of the code. - - Thanks to Pavel Raiskup. + CI: Support XZ_NLS=OFF with CMake - src/scripts/xzless.in | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) + build-aux/ci_build.bash | 1 + + 1 file changed, 1 insertion(+) -commit 273c33297bb69621045ed19665eaf8338bcf4a50 +commit ffa9fadecc85d21308aebac7b070fb5be791190f Author: Lasse Collin -Date: 2018-07-27 16:02:58 +0300 +Date: 2025-04-22 16:21:50 +0300 - liblzma: Remove an always-true condition from lzma_index_cat(). + CI: Revise MSYS2 + + Re-enable CLANG64 environment. Add CLANGARM64. Don't add MINGW64 + to slightly reduce the number of runner VMs needed. + + Install the required packages using the setup-msys2 action instead + of running the commands separately. + + Test Autotools and CMake in the same job to reduce the number of VMs. + This doesn't slow it down too much because the msys2-setup step is + needed by both. However, do only the full builds on ARM64 because + those runners seem to be slower. - This should help static analysis tools to see that newg - isn't leaked. + Test fewer build configurations. The point of testing on MSYS2 is to + catch Windows-related issues. It should be enough that the more unusual + build configurations are tested in ci.yml. - Thanks to Pavel Raiskup. + Run the build commands directly instead of using ci_build.bash. This + makes it easier to see what commands are run even if it is a little + more verbose now. + + Run the workflow automatically when commit are pushed to master. + With the fewer build variants it's not too slow. - src/liblzma/common/index.c | 4 ++-- - 1 file changed, 2 insertions(+), 2 deletions(-) + .github/workflows/msys2.yml | 197 +++++++++++++++++++++++++------------------- + 1 file changed, 110 insertions(+), 87 deletions(-) -commit 65b4aba6d06d2cd24ba9ad01fa389c238ad8f352 +commit 6f2aaa77daef7b408dc0d9c9a534373a30da7a50 Author: Lasse Collin -Date: 2018-05-19 21:23:25 +0300 +Date: 2025-04-22 16:21:50 +0300 - liblzma: Improve lzma_properties_decode() API documentation. + CI: Rename the MSYS2 workflow file - src/liblzma/api/lzma/filter.h | 7 ++++--- - 1 file changed, 4 insertions(+), 3 deletions(-) + .github/workflows/{windows-ci.yml => msys2.yml} | 0 + 1 file changed, 0 insertions(+), 0 deletions(-) -commit 531e78e5a253a3e2c4d4dd1505acaccee48f4083 +commit 09110ad4c74f3ee1b4b0355d92b703525eddd3ff Author: Lasse Collin -Date: 2019-05-01 16:52:36 +0300 +Date: 2025-04-22 16:21:50 +0300 - Update THANKS. + CI: Enable assertions on NetBSD + CMake - THANKS | 1 + - 1 file changed, 1 insertion(+) + .github/workflows/netbsd.yml | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) -commit 905de7e93528ca5a47039e7e1e5270163f9fc67e +commit 516b90f6e1beb243dd76adc82da0ee47e525f863 Author: Lasse Collin -Date: 2019-05-01 16:43:16 +0300 +Date: 2025-04-21 12:23:37 +0300 - Windows: Update VS version in windows/vs2019/config.h. + liblzma: Update lzma_lzip_decoder() docs about trailing data + + Don't say that the .lz format allows trailing data. According to the + lzip 1.25 manual, trailing data isn't part of the file format at all. + However, tools are still expected to behave as usefully as possible + when there is trailing data. + + Fix the description of lzip >= 1.20 behavior when some of the first + bytes of trailing data match the magic bytes. While the lzip 1.25 manual + recommends that none of the first four bytes in trailing data should + match the magic bytes, the default behavior of lzip 1.25 treats + trailing data as a corrupt member header only if two or three bytes + match the magic bytes; one matching byte isn't enough. + + Reported-by: Antonio Diaz Diaz + Link: https://www.mail-archive.com/xz-devel@tukaani.org/msg00702.html - windows/vs2019/config.h | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) + src/liblzma/api/lzma/container.h | 23 +++++++++++------------ + 1 file changed, 11 insertions(+), 12 deletions(-) -commit 0ffd30e172fd18cc619823b2a86448bf56a67e22 -Author: Julien Marrec -Date: 2019-04-25 17:44:06 +0200 +commit c330220d47dc09a5bab805d22654c8c0a73d21a9 +Author: Lasse Collin +Date: 2025-04-21 11:21:08 +0300 - Windows: Upgrade solution itself + Update THANKS - windows/vs2019/xz_win.sln | 7 +++++-- - 1 file changed, 5 insertions(+), 2 deletions(-) + THANKS | 1 + + 1 file changed, 1 insertion(+) -commit c2ef96685fc7ca36311649eeb2284b9808292040 -Author: Julien Marrec -Date: 2019-04-25 17:40:24 +0200 +commit 6cc7672c2238e7fc66bba33cff50cecd30411063 +Author: Lasse Collin +Date: 2025-04-17 20:36:33 +0300 - Windows: Upgrade solution with VS2019 + CI: Add DragonflyBSD - windows/vs2019/liblzma.vcxproj | 15 ++++++++------- - windows/vs2019/liblzma_dll.vcxproj | 15 ++++++++------- - 2 files changed, 16 insertions(+), 14 deletions(-) + .github/workflows/dragonflybsd.yml | 39 ++++++++++++++++++++++++++++++++++++++ + 1 file changed, 39 insertions(+) -commit 25fccaf00bea399d8aa026e5b8fa254ce196e6e0 -Author: Julien Marrec -Date: 2019-04-25 17:39:32 +0200 +commit 07dc50913725496bd89178539190292a66e18710 +Author: Lasse Collin +Date: 2025-04-17 20:36:33 +0300 - Windows: Duplicate windows/vs2017 before upgrading + CI: Update Solaris - windows/vs2019/config.h | 148 ++++++++++++++ - windows/vs2019/liblzma.vcxproj | 354 ++++++++++++++++++++++++++++++++++ - windows/vs2019/liblzma_dll.vcxproj | 383 +++++++++++++++++++++++++++++++++++++ - windows/vs2019/xz_win.sln | 48 +++++ - 4 files changed, 933 insertions(+) + .github/workflows/solaris.yml | 37 +++++++++++++++++++------------------ + 1 file changed, 19 insertions(+), 18 deletions(-) -commit 1424078d6328291c7c524b64328ce9660617cb24 +commit cfcaae1945c0c33df86477138746e68428972a53 Author: Lasse Collin -Date: 2019-01-13 17:29:23 +0200 +Date: 2025-04-17 20:36:33 +0300 - Windows/VS2017: Omit WindowsTargetPlatformVersion from project files. - - I understood that if a WTPV is specified, it's often wrong - because different VS installations have different SDK version - installed. Omitting the WTPV tag makes VS2017 default to - Windows SDK 8.1 which often is also missing, so in any case - people may need to specify the WTPV before building. But some - day in the future a missing WTPV tag will start to default to - the latest installed SDK which sounds reasonable: - - https://developercommunity.visualstudio.com/content/problem/140294/windowstargetplatformversion-makes-it-impossible-t.html + CI: Update OpenBSD - Thanks to "dom". + Use --disable-nls --enable-external-sha256 because those are used + in the xz Makefile in the OpenBSD ports tree. - windows/INSTALL-MSVC.txt | 4 ++++ - windows/vs2017/liblzma.vcxproj | 1 - - windows/vs2017/liblzma_dll.vcxproj | 1 - - 3 files changed, 4 insertions(+), 2 deletions(-) + .github/workflows/openbsd.yml | 46 +++++++++++++++++++++++-------------------- + 1 file changed, 25 insertions(+), 21 deletions(-) -commit b5be61cc06088bb07f488f9baf7d447ff47b37c1 +commit 5240fcfee3b1386029a26629d75f1465b9e85ca3 Author: Lasse Collin -Date: 2018-04-29 19:00:06 +0300 +Date: 2025-04-17 20:36:33 +0300 - Bump version and soname for 5.2.4. + CI: Update NetBSD + + For variety, use CMake and Ninja. - src/liblzma/Makefile.am | 2 +- - src/liblzma/api/lzma/version.h | 2 +- - 2 files changed, 2 insertions(+), 2 deletions(-) + .github/workflows/netbsd.yml | 43 +++++++++++++++++++++++++------------------ + 1 file changed, 25 insertions(+), 18 deletions(-) -commit c47fa6d06745bb2e99866e76b81ac7a9c5a8bfec +commit 85ff0cf0ce11b017af21c040330f6a0c09ef7f77 Author: Lasse Collin -Date: 2018-04-29 18:48:00 +0300 +Date: 2025-04-17 20:36:33 +0300 - extra/scanlzma: Fix compiler warnings. + CI: Update FreeBSD + + ARM64 was left commented out because it's slow under both + ubuntu-latest (x86-64) and ubuntu-24.04-arm (aarch64) hosts. - extra/scanlzma/scanlzma.c | 6 +++++- - 1 file changed, 5 insertions(+), 1 deletion(-) + .github/workflows/freebsd.yml | 61 +++++++++++++++++++++++++++++-------------- + 1 file changed, 42 insertions(+), 19 deletions(-) -commit 7b350fe21aa4fd6495a3b6188a40e3f1ae7c0edf +commit 907ac2215db1613312dc292219bac798d76394f4 Author: Lasse Collin -Date: 2018-04-29 18:15:37 +0300 +Date: 2025-04-11 17:25:53 +0300 - Add NEWS for 5.2.4. + CI: Specify only the main version of the standard GH actions - NEWS | 27 +++++++++++++++++++++++++++ - 1 file changed, 27 insertions(+) + .github/workflows/ci.yml | 4 ++-- + .github/workflows/msvc.yml | 2 +- + 2 files changed, 3 insertions(+), 3 deletions(-) -commit 5801591162a280aa52d156dfde42c531ec7fd8b6 +commit b0d0e624740b92415f78274702b5b5bfbffe4543 Author: Lasse Collin -Date: 2018-02-06 19:36:30 +0200 +Date: 2025-04-11 17:15:08 +0300 - Update THANKS. + CI: Add 'permissions' to ci.yml and msvc.yml - THANKS | 2 ++ - 1 file changed, 2 insertions(+) + .github/workflows/ci.yml | 2 ++ + .github/workflows/msvc.yml | 2 ++ + 2 files changed, 4 insertions(+) -commit c4a616f4536146f8906e1b4412eefeec07b28fae -Author: Ben Boeckel -Date: 2018-01-29 13:58:18 -0500 +commit 1edc14e8ca4fc1f25ee43f17f290c045df7f49e0 +Author: Sam James +Date: 2025-04-10 23:15:31 +0300 - nothrow: use noexcept for C++11 and newer + CI: Add CIFuzz + + xz is already part of OSS-Fuzz, but OSS-Fuzz provides & encourages [0] + its 'CIFuzz' service to test individual commits. - In C++11, the `throw()` specifier is deprecated and `noexcept` is - preffered instead. + [0] https://google.github.io/oss-fuzz/getting-started/continuous-integration/ + + Co-authored-by: Lasse Collin - src/liblzma/api/lzma.h | 6 +++++- - 1 file changed, 5 insertions(+), 1 deletion(-) + .github/workflows/cifuzz.yml | 54 ++++++++++++++++++++++++++++++++++++++++++++ + 1 file changed, 54 insertions(+) -commit 0b8947782ff3c5ef830a7f85412e44dcf3cdeb77 +commit 35e06c4c426c6cc3866a9003e87a122eb78bccf2 Author: Lasse Collin -Date: 2018-02-06 18:02:48 +0200 +Date: 2025-04-12 15:31:01 +0300 - liblzma: Remove incorrect #ifdef from range_common.h. + CMake: Don't check for optreset if using replacement getopt_long - In most cases it was harmless but it could affect some - custom build systems. + If had optreset but not getopt_long, xz used optreset while + the replacement getopt_long doesn't support optreset. I'm not aware of + any relevant system where bug is possible. Autotools build didn't have + this bug. - Thanks to Pippijn van Steenhoven. + Fixes: af66cd585902 ("CMake: Add support for replacement getopt_long (lib/getopt*).") - src/liblzma/rangecoder/range_common.h | 4 +--- - 1 file changed, 1 insertion(+), 3 deletions(-) + CMakeLists.txt | 6 ++++-- + 1 file changed, 4 insertions(+), 2 deletions(-) -commit 48f3b9f73ffea7f55d5678997aba0e79d2e82168 +commit 99f4b9db9dfc3dabad330df6242e4632c42393c6 Author: Lasse Collin -Date: 2018-01-10 22:10:39 +0200 +Date: 2025-04-17 18:33:10 +0300 - Update THANKS. + Update THANKS THANKS | 1 + 1 file changed, 1 insertion(+) -commit a3ce3e902342be37c626a561ce3d9ffcf27d0f94 +commit dd006a67e593cb5d3dec5180face7e3010fe78da +Author: Lasse Collin +Date: 2025-04-17 18:30:26 +0300 + + liblzma: Update the lzma_lzip_decoder() docs about sync flush marker + + src/liblzma/api/lzma/container.h | 15 +++++++-------- + 1 file changed, 7 insertions(+), 8 deletions(-) + +commit f59c5859600b5dfeaa618fcc04e9e3bb2b005f5c Author: Lasse Collin -Date: 2018-01-10 21:54:27 +0200 +Date: 2025-04-17 18:16:40 +0300 - tuklib_integer: New Intel C compiler needs immintrin.h. + xz: Don't mention lzip's sync flush marker on the man page - Thanks to Melanie Blower (Intel) for the patch. + The sync flush marker isn't valid in .lz files. The sync flush marker + may be used by lzlib, but the resulting streams are only meant to be + decoded by lzlib itself. lzlib's docs make this clear. + + Reported-by: Antonio Diaz Diaz + Link: https://www.mail-archive.com/xz-devel@tukaani.org/msg00700.html + Link: https://www.mail-archive.com/xz-devel@tukaani.org/msg00701.html - src/common/tuklib_integer.h | 11 +++++++++++ - 1 file changed, 11 insertions(+) + src/xz/xz.1 | 9 +-------- + 1 file changed, 1 insertion(+), 8 deletions(-) -commit 4505ca483985f88c6923c05a43b4327feaab83b1 +commit 49258439b4ead6866798c1ebf8a083ec9ec04520 Author: Lasse Collin -Date: 2017-09-24 20:04:24 +0300 +Date: 2025-04-17 18:15:48 +0300 - Update THANKS. + Update THANKS THANKS | 1 + 1 file changed, 1 insertion(+) -commit 1ef3cc226e3ce173575c218238b71a4eecabc470 +commit a69fbd3aaebc15dc5912e64724e5abfcef09bcdf Author: Lasse Collin -Date: 2017-09-16 20:36:20 +0300 +Date: 2025-04-10 20:13:07 +0300 - Windows: Fix paths in VS project files. + CI: MSVC: Use fewer runners for the same number of tests + + Using eight runners seems wasteful. Using only two runners isn't + much slower due to the runner startup overhead. - Some paths use slashes instead of backslashes as directory - separators... now it should work (I tested VS2013 version). + Also add a comment about the test that fails without b5a5d9e3f702. + + .github/workflows/msvc.yml | 66 ++++++++++++++++++++++++++++++++++++++-------- + 1 file changed, 55 insertions(+), 11 deletions(-) + +commit 8a300d1c4fc644af482fb679044794c3e3f6f3e5 +Author: Lasse Collin +Date: 2025-04-10 20:10:31 +0300 + + Update THANKS - windows/vs2013/liblzma.vcxproj | 12 ++++++------ - windows/vs2013/liblzma_dll.vcxproj | 24 ++++++++++++------------ - windows/vs2017/liblzma.vcxproj | 12 ++++++------ - windows/vs2017/liblzma_dll.vcxproj | 24 ++++++++++++------------ - 4 files changed, 36 insertions(+), 36 deletions(-) + THANKS | 1 + + 1 file changed, 1 insertion(+) -commit e775d2a8189d24f60470e6e49d8af881df3a1680 +commit b5a5d9e3f7022e546cdfd4ddc42fe4cc56839c05 Author: Lasse Collin -Date: 2017-09-16 12:54:23 +0300 +Date: 2025-04-07 22:36:58 +0300 - Windows: Add project files for VS2017. + liblzma: Disable CLMUL CRC on old MSVC targeting 32-bit x86 + + On GitHub runners, VS 2019 16.11 (MSVC 19.29.30158) results in + test failures. VS 2022 17.13 (MSVC 19.43.34808) works. + + In xz 5.6.x there was a #pragma-based workaround for MSVC builds for + 32-bit x86. Another method was thought to work with the new rewritten + CLMUL CRC. Apparently it doesn't. Keep it simple and disable CLMUL CRC + with any non-recent MSVC when building for 32-bit x86. - These files match the v5.2 branch (no file info decoder). + Fixes: 54eaea5ea49b ("liblzma: x86 CLMUL CRC: Rewrite") + Fixes: https://github.com/tukaani-project/xz/issues/171 + Reported-by: Andrew Murray - windows/vs2017/config.h | 148 ++++++++++++++ - windows/vs2017/liblzma.vcxproj | 355 ++++++++++++++++++++++++++++++++++ - windows/vs2017/liblzma_dll.vcxproj | 384 +++++++++++++++++++++++++++++++++++++ - windows/vs2017/xz_win.sln | 48 +++++ - 4 files changed, 935 insertions(+) + src/liblzma/check/crc_common.h | 16 +++++++++++++--- + 1 file changed, 13 insertions(+), 3 deletions(-) -commit 10e02e0fbb6e2173f8b41f6e39b7b570f47dd74d +commit c5fd88dfc3d2b4178dc6da65b02a63a4ef9280c5 Author: Lasse Collin -Date: 2017-09-16 12:39:43 +0300 +Date: 2025-04-07 22:36:58 +0300 - Windows: Move VS2013 files into windows/vs2013 directory. + liblzma: Remove MSVC hack from CLMUL CRC + + It's not enough with MSVC 19.29 (VS 2019) even if the hack was also + applied to the CRC32 code. The tests crash when built for 32-bit x86. - windows/{ => vs2013}/config.h | 0 - windows/{ => vs2013}/liblzma.vcxproj | 278 +++++++++++++++--------------- - windows/{ => vs2013}/liblzma_dll.vcxproj | 280 +++++++++++++++---------------- - windows/{ => vs2013}/xz_win.sln | 0 - 4 files changed, 279 insertions(+), 279 deletions(-) + src/liblzma/check/crc64_fast.c | 8 -------- + 1 file changed, 8 deletions(-) -commit 06eebd4543196ded36fa9b8b9544195b38b24ef2 +commit 49ba8c69ea7f928aded77bd856085c85a8d26156 Author: Lasse Collin -Date: 2017-08-14 20:08:33 +0300 +Date: 2025-04-07 22:36:52 +0300 - Fix or hide warnings from GCC 7's -Wimplicit-fallthrough. + CI: Test 32/64-bit x86 builds with Visual Studio 2019 and 2022 - src/liblzma/lzma/lzma_decoder.c | 6 ++++++ - src/xz/list.c | 2 ++ - 2 files changed, 8 insertions(+) + .github/workflows/msvc.yml | 45 +++++++++++++++++++++++++++++++++++++++++++++ + 1 file changed, 45 insertions(+) -commit ea4ea1dffafebaa8b2770bf3eca46900e4dd22dc -Author: Alexey Tourbin -Date: 2017-05-16 23:56:35 +0300 +commit 1176a19df6b1585b51131b0e2570e03f1fc14f46 +Author: Lasse Collin +Date: 2025-04-04 20:08:37 +0300 - Docs: Fix a typo in a comment in doc/examples/02_decompress.c. + Tests: Add fuzz_decode_stream_mt.options - doc/examples/02_decompress.c | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) + tests/ossfuzz/config/fuzz_decode_stream_mt.options | 4 ++++ + 1 file changed, 4 insertions(+) -commit eb2ef4c79bf405ea0d215f3b1df3d0eaf5e1d27b +commit c3cb1e53a114ac944f559fe7cac45dbf48cca156 Author: Lasse Collin -Date: 2017-05-23 18:34:43 +0300 +Date: 2025-04-03 15:06:07 +0300 - xz: Fix "xz --list --robot missing_or_bad_file.xz". - - It ended up printing an uninitialized char-array when trying to - print the check names (column 7) on the "totals" line. - - This also changes the column 12 (minimum xz version) to - 50000002 (xz 5.0.0) instead of 0 when there are no valid - input files. - - Thanks to kidmin for the bug report. + doc/SHA256SUMS: Add 5.8.1 - src/xz/list.c | 8 ++++++-- - 1 file changed, 6 insertions(+), 2 deletions(-) + doc/SHA256SUMS | 7 +++++++ + 1 file changed, 7 insertions(+) -commit 3ea5dbd9b0d79048e336e40cef3b6d814fb74e13 +commit a522a226545730551f7e7c2685fab27cf567746c Author: Lasse Collin -Date: 2017-04-24 19:48:47 +0300 +Date: 2025-04-03 14:34:43 +0300 - Build: Omit pre-5.0.0 entries from the generated ChangeLog. - - It makes ChangeLog significantly smaller. + Bump version and soname for 5.8.1 - Makefile.am | 3 ++- - 1 file changed, 2 insertions(+), 1 deletion(-) + src/liblzma/Makefile.am | 2 +- + src/liblzma/api/lzma/version.h | 2 +- + 2 files changed, 2 insertions(+), 2 deletions(-) -commit bae24675936df99064de1502593c006bd902594b +commit 1c462c2ad86ff85766928638431029cd0b0dc995 Author: Lasse Collin -Date: 2017-04-24 19:30:22 +0300 +Date: 2025-04-03 14:34:43 +0300 - Update the Git repository URL to HTTPS in ChangeLog. + Add NEWS for 5.8.1 - ChangeLog | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) + NEWS | 30 ++++++++++++++++++++++++++++++ + 1 file changed, 30 insertions(+) -commit 70f479211973b5361f4d7cb08ba5be69b4266e7a +commit 513cabcf7f5ce1c3ed0619e791393fc53d1dbbd0 Author: Lasse Collin -Date: 2017-04-19 22:17:35 +0300 +Date: 2025-04-03 14:34:43 +0300 - Update the home page URLs to HTTPS. + Tests: Call lzma_code() in smaller chunks in fuzz_common.h + + This makes it easy to crash fuzz_decode_stream_mt when tested + against the code from 5.8.0. + + Obviously this might make it harder to reach some other code path now. + The previous code has been in use since 2018 when fuzzing was added + in 106d1a663d4b ("Tests: Add a fuzz test program and a config file + for OSS-Fuzz."). - COPYING | 2 +- - README | 2 +- - configure.ac | 2 +- - doc/faq.txt | 4 ++-- - dos/config.h | 2 +- - src/common/common_w32res.rc | 2 +- - src/xz/xz.1 | 6 +++--- - src/xzdec/xzdec.1 | 4 ++-- - windows/README-Windows.txt | 2 +- - windows/config.h | 2 +- - 10 files changed, 14 insertions(+), 14 deletions(-) + tests/ossfuzz/fuzz_common.h | 31 ++++++++++++++++++++++++------- + 1 file changed, 24 insertions(+), 7 deletions(-) -commit 2a4b2fa75d06a097261a02ecd3cf2b6d449bf754 +commit 48440e24a25911ae59e8518b67a1e0f6f1c293bf Author: Lasse Collin -Date: 2017-03-30 22:01:54 +0300 +Date: 2025-04-03 14:34:43 +0300 - xz: Use POSIX_FADV_RANDOM for in "xz --list" mode. + Tests: Add a fuzzing target for the multithreaded .xz decoder - xz --list is random access so POSIX_FADV_SEQUENTIAL was clearly - wrong. + It doesn't seem possible to trigger the CVE-2025-31115 bug with this + fuzzing target at the moment. It's because the code in fuzz_common.h + passes the whole input buffer to lzma_code() at once. - src/xz/file_io.c | 10 ++++++++-- - 1 file changed, 8 insertions(+), 2 deletions(-) + tests/ossfuzz/fuzz_decode_stream_mt.c | 47 +++++++++++++++++++++++++++++++++++ + 1 file changed, 47 insertions(+) -commit eb25743ade39170cffd9566a1aae272098cce216 +commit 0c80045ab82c406858d9d5bcea9f48ebc3d0a81d Author: Lasse Collin -Date: 2017-03-30 19:47:45 +0300 +Date: 2025-04-03 14:34:42 +0300 - liblzma: Fix lzma_memlimit_set(strm, 0). + liblzma: mt dec: Fix lack of parallelization in single-shot decoding - The 0 got treated specially in a buggy way and as a result - the function did nothing. The API doc said that 0 was supposed - to return LZMA_PROG_ERROR but it didn't. + Single-shot decoding means calling lzma_code() by giving it the whole + input at once and enough output buffer space to store the uncompressed + data, and combining this with LZMA_FINISH and no timeout + (lzma_mt.timeout = 0). This way the file is decoded with a single + lzma_code() call if possible. - Now 0 is treated as if 1 had been specified. This is done because - 0 is already used to indicate an error from lzma_memlimit_get() - and lzma_memusage(). + The bug prevented the decoder from starting more than one worker thread + in single-shot mode. The issue was noticed when reviewing the code; + there are no bug reports. Thus maybe few have tried this mode. - In addition, lzma_memlimit_set() no longer checks that the new - limit is at least LZMA_MEMUSAGE_BASE. It's counter-productive - for the Index decoder and was actually needed only by the - auto decoder. Auto decoder has now been modified to check for - LZMA_MEMUSAGE_BASE. + Fixes: 64b6d496dc81 ("liblzma: Threaded decoder: Always wait for output if LZMA_FINISH is used.") - src/liblzma/api/lzma/base.h | 7 ++++++- - src/liblzma/common/auto_decoder.c | 3 +++ - src/liblzma/common/common.c | 6 ++++-- - 3 files changed, 13 insertions(+), 3 deletions(-) + src/liblzma/common/stream_decoder_mt.c | 11 +++++++++-- + 1 file changed, 9 insertions(+), 2 deletions(-) -commit ef36c6362f3f3853f21b8a6359bcd06576ebf207 +commit 8188048854e8d11071b8a50d093c74f4c030acc9 Author: Lasse Collin -Date: 2017-03-30 19:16:55 +0300 +Date: 2025-04-03 14:34:42 +0300 - liblzma: Similar memlimit fix for stream_, alone_, and auto_decoder. + liblzma: mt dec: Don't modify thr->in_size in the worker thread + + Don't set thr->in_size = 0 when returning the thread to the stack of + available threads. Not only is it useless, but the main thread may + read the value in SEQ_BLOCK_THR_RUN. With valid inputs, it made + no difference if the main thread saw the original value or 0. With + invalid inputs (when worker thread stops early), thr->in_size was + no longer modified after the previous commit with the security fix + ("Don't free the input buffer too early"). + + So while the bug appears harmless now, it's important to fix it because + the variable was being modified without proper locking. It's trivial + to fix because there is no need to change the value. Only main thread + needs to set the value in (in SEQ_BLOCK_THR_INIT) when starting a new + Block before the worker thread is activated. + + Fixes: 4cce3e27f529 ("liblzma: Add threaded .xz decompressor.") + Reviewed-by: Sebastian Andrzej Siewior + Thanks-to: Sam James - src/liblzma/api/lzma/container.h | 21 +++++++++++++++++---- - src/liblzma/common/alone_decoder.c | 5 +---- - src/liblzma/common/auto_decoder.c | 5 +---- - src/liblzma/common/stream_decoder.c | 5 +---- - 4 files changed, 20 insertions(+), 16 deletions(-) + src/liblzma/common/stream_decoder_mt.c | 6 ++++-- + 1 file changed, 4 insertions(+), 2 deletions(-) -commit 57616032650f03840480b696d7878acdd2065521 +commit d5a2ffe41bb77b918a8c96084885d4dbe4bf6480 Author: Lasse Collin -Date: 2017-03-30 18:58:18 +0300 +Date: 2025-04-03 14:34:42 +0300 - liblzma: Fix handling of memlimit == 0 in lzma_index_decoder(). + liblzma: mt dec: Don't free the input buffer too early (CVE-2025-31115) + + The input buffer must be valid as long as the main thread is writing + to the worker-specific input buffer. Fix it by making the worker + thread not free the buffer on errors and not return the worker thread to + the pool. The input buffer will be freed when threads_end() is called. + + With invalid input, the bug could at least result in a crash. The + effects include heap use after free and writing to an address based + on the null pointer plus an offset. - It returned LZMA_PROG_ERROR, which was done to avoid zero as - the limit (because it's a special value elsewhere), but using - LZMA_PROG_ERROR is simply inconvenient and can cause bugs. + The bug has been there since the first committed version of the threaded + decoder and thus affects versions from 5.3.3alpha to 5.8.0. - The fix/workaround is to treat 0 as if it were 1 byte. It's - effectively the same thing. The only weird consequence is - that then lzma_memlimit_get() will return 1 even when 0 was - specified as the limit. + As the commit message in 4cce3e27f529 says, I had made significant + changes on top of Sebastian's patch. This bug was indeed introduced + by my changes; it wasn't in Sebastian's version. - This fixes a very rare corner case in xz --list where a specific - memory usage limit and a multi-stream file could print the - error message "Internal error (bug)" instead of saying that - the memory usage limit is too low. + Thanks to Harri K. Koskinen for discovering and reporting this issue. + + Fixes: 4cce3e27f529 ("liblzma: Add threaded .xz decompressor.") + Reported-by: Harri K. Koskinen + Reviewed-by: Sebastian Andrzej Siewior + Thanks-to: Sam James - src/liblzma/api/lzma/index.h | 18 +++++++++++------- - src/liblzma/common/index_decoder.c | 4 ++-- - 2 files changed, 13 insertions(+), 9 deletions(-) + src/liblzma/common/stream_decoder_mt.c | 31 ++++++++++++++++++++++--------- + 1 file changed, 22 insertions(+), 9 deletions(-) -commit 3d566cd519017eee1a400e7961ff14058dfaf33c +commit c0c835964dfaeb2513a3c0bdb642105152fe9f34 Author: Lasse Collin -Date: 2016-12-30 13:26:36 +0200 +Date: 2025-04-03 14:34:42 +0300 - Bump version and soname for 5.2.3. + liblzma: mt dec: Simplify by removing the THR_STOP state + + The main thread can directly set THR_IDLE in threads_stop() which is + called when errors are detected. threads_stop() won't return the stopped + threads to the pool or free the memory pointed by thr->in anymore, but + it doesn't matter because the existing workers won't be reused after + an error. The resources will be cleaned up when threads_end() is + called (reinitializing the decoder always calls threads_end()). + + Reviewed-by: Sebastian Andrzej Siewior + Thanks-to: Sam James - src/liblzma/Makefile.am | 2 +- - src/liblzma/api/lzma/version.h | 2 +- - 2 files changed, 2 insertions(+), 2 deletions(-) + src/liblzma/common/stream_decoder_mt.c | 75 +++++++++++++--------------------- + 1 file changed, 29 insertions(+), 46 deletions(-) -commit 053e624fe33795e779ff736f16ce44a129c829b5 +commit 831b55b971cf579ee16a854f177c36b20d3c6999 Author: Lasse Collin -Date: 2016-12-30 13:25:10 +0200 +Date: 2025-04-03 14:34:42 +0300 - Update NEWS for 5.2.3. + liblzma: mt dec: Fix a comment + + Reviewed-by: Sebastian Andrzej Siewior + Thanks-to: Sam James - NEWS | 39 +++++++++++++++++++++++++++++++++++++++ - 1 file changed, 39 insertions(+) + src/liblzma/common/stream_decoder_mt.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) -commit cae412b2b77d7fd88d187ed7659331709311f80d +commit b9d168eee4fb6393b4fe207c0aeb5faee316ca1a Author: Lasse Collin -Date: 2015-04-01 14:45:25 +0300 +Date: 2025-04-03 14:34:30 +0300 - xz: Fix the Capsicum rights on user_abort_pipe. + liblzma: Add assertions to lzma_bufcpy() - src/xz/file_io.c | 6 +++++- - 1 file changed, 5 insertions(+), 1 deletion(-) + src/liblzma/common/common.c | 6 ++++++ + 1 file changed, 6 insertions(+) -commit 9ccbae41000572193b9a09e7102f9e84dc6d96de +commit c8e0a4897b4d0f906966f5d4d4f662221d64f3ae Author: Lasse Collin -Date: 2016-12-28 21:05:22 +0200 - - Mention potential sandboxing bugs in INSTALL. +Date: 2025-04-02 16:40:22 +0300 - INSTALL | 5 ++++- - 1 file changed, 4 insertions(+), 1 deletion(-) + DOS: Update Makefile to fix the build -commit e013a337d3de77cce24360dffe956ea2339489b6 -Author: Lasse Collin -Date: 2016-11-21 20:24:50 +0200 - - liblzma: Avoid multiple definitions of lzma_coder structures. - - Only one definition was visible in a translation unit. - It avoided a few casts and temp variables but seems that - this hack doesn't work with link-time optimizations in compilers - as it's not C99/C11 compliant. - - Fixes: - http://www.mail-archive.com/xz-devel@tukaani.org/msg00279.html - - src/liblzma/common/alone_decoder.c | 44 +++++---- - src/liblzma/common/alone_encoder.c | 34 ++++--- - src/liblzma/common/auto_decoder.c | 35 ++++--- - src/liblzma/common/block_decoder.c | 41 ++++---- - src/liblzma/common/block_encoder.c | 40 ++++---- - src/liblzma/common/common.h | 18 ++-- - src/liblzma/common/index_decoder.c | 33 ++++--- - src/liblzma/common/index_encoder.c | 16 ++-- - src/liblzma/common/stream_decoder.c | 50 +++++----- - src/liblzma/common/stream_encoder.c | 56 ++++++----- - src/liblzma/common/stream_encoder_mt.c | 124 ++++++++++++++----------- - src/liblzma/delta/delta_common.c | 25 ++--- - src/liblzma/delta/delta_decoder.c | 6 +- - src/liblzma/delta/delta_encoder.c | 12 ++- - src/liblzma/delta/delta_private.h | 4 +- - src/liblzma/lz/lz_decoder.c | 60 ++++++------ - src/liblzma/lz/lz_decoder.h | 13 ++- - src/liblzma/lz/lz_encoder.c | 57 +++++++----- - src/liblzma/lz/lz_encoder.h | 9 +- - src/liblzma/lzma/lzma2_decoder.c | 32 ++++--- - src/liblzma/lzma/lzma2_encoder.c | 51 +++++----- - src/liblzma/lzma/lzma_decoder.c | 27 +++--- - src/liblzma/lzma/lzma_encoder.c | 29 +++--- - src/liblzma/lzma/lzma_encoder.h | 9 +- - src/liblzma/lzma/lzma_encoder_optimum_fast.c | 3 +- - src/liblzma/lzma/lzma_encoder_optimum_normal.c | 23 ++--- - src/liblzma/lzma/lzma_encoder_private.h | 6 +- - src/liblzma/simple/arm.c | 2 +- - src/liblzma/simple/armthumb.c | 2 +- - src/liblzma/simple/ia64.c | 2 +- - src/liblzma/simple/powerpc.c | 2 +- - src/liblzma/simple/simple_coder.c | 61 ++++++------ - src/liblzma/simple/simple_private.h | 12 +-- - src/liblzma/simple/sparc.c | 2 +- - src/liblzma/simple/x86.c | 15 +-- - 35 files changed, 532 insertions(+), 423 deletions(-) - -commit 8e0f1af3dcaec00a3879cce8ad7441edc6359d1c -Author: Lasse Collin -Date: 2016-12-26 20:50:25 +0200 - - Document --enable-sandbox configure option in INSTALL. - - INSTALL | 25 +++++++++++++++++++++++++ - 1 file changed, 25 insertions(+) + dos/Makefile | 2 ++ + 1 file changed, 2 insertions(+) -commit ce2542d220de06acd618fd9f5c0a6683029fb4eb +commit 307c02ed698a69763ef1c9c0df4ff24727442118 Author: Lasse Collin -Date: 2015-03-31 22:19:34 +0300 +Date: 2025-03-29 12:41:32 +0200 - xz: Add support for sandboxing with Capsicum (disabled by default). - - In the v5.2 branch this feature is considered experimental - and thus disabled by default. + sysdefs.h: Avoid even with C11 compilers - The sandboxing is used conditionally as described in main.c. - This isn't optimal but it was much easier to implement than - a full sandboxing solution and it still covers the most common - use cases where xz is writing to standard output. This should - have practically no effect on performance even with small files - as fork() isn't needed. + Oracle Developer Studio 12.6 on Solaris 10 claims C11 support in + __STDC_VERSION__ and supports _Alignas. However, is missing. + We only need alignas, so define it to _Alignas with C11/C17 compilers. + If something included later, it shouldn't cause problems. - C and locale libraries can open files as needed. This has been - fine in the past, but it's a problem with things like Capsicum. - io_sandbox_enter() tries to ensure that various locale-related - files have been loaded before cap_enter() is called, but it's - possible that there are other similar problems which haven't - been seen yet. + Thanks to Ihsan Dogan for reporting the issue and testing the fix. - Currently Capsicum is available on FreeBSD 10 and later - and there is a port to Linux too. - - Thanks to Loganaden Velvindron for help. + Fixes: c0e7eaae8d6eef1e313c9d0da20ccf126ec61f38 - configure.ac | 41 +++++++++++++++++++++++++++ - src/xz/Makefile.am | 2 +- - src/xz/file_io.c | 81 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ - src/xz/file_io.h | 6 ++++ - src/xz/main.c | 18 ++++++++++++ - src/xz/private.h | 4 +++ - 6 files changed, 151 insertions(+), 1 deletion(-) + src/common/sysdefs.h | 4 +++- + 1 file changed, 3 insertions(+), 1 deletion(-) -commit 3ca1d5e6320111043e19434da881065fadafa0e4 +commit 7ce38b318339d6c01378a77585e08169ca3a604e Author: Lasse Collin -Date: 2015-03-31 21:12:30 +0300 +Date: 2025-03-29 12:32:05 +0200 - Fix bugs and otherwise improve ax_check_capsicum.m4. - - AU_ALIAS was removed because the new version is incompatible - with the old version. - - It no longer checks for separately. - It's enough to test for it as part of AC_CHECK_DECL. - The defines HAVE_CAPSICUM_SYS_CAPSICUM_H and - HAVE_CAPSICUM_SYS_CAPABILITY_H were removed as unneeded. - HAVE_SYS_CAPSICUM_H from AC_CHECK_HEADERS is enough. - - It no longer does a useless search for the Capsicum library - if the header wasn't found. - - Fixed a bug in ACTION-IF-FOUND (the first argument). Specifying - the argument omitted the default action but the given action - wasn't used instead. - - AC_DEFINE([HAVE_CAPSICUM]) is now always called when Capsicum - support is found. Previously it was part of the default - ACTION-IF-FOUND which a custom action would override. Now - the default action only prepends ${CAPSICUM_LIB} to LIBS. - - The documentation was updated. - - Since there as no serial number, "#serial 2" was added. + Update THANKS - m4/ax_check_capsicum.m4 | 103 ++++++++++++++++++++++++------------------------ - 1 file changed, 51 insertions(+), 52 deletions(-) + THANKS | 1 + + 1 file changed, 1 insertion(+) -commit 5f3a742b64197fe8bedb6f05fc6ce5d177d11145 +commit 688e51bde4c987589717b2be1a1fde9576c604fc Author: Lasse Collin -Date: 2015-03-31 19:20:24 +0300 +Date: 2025-03-29 12:21:51 +0200 - Add m4/ax_check_capsicum.m4 for detecting Capsicum support. - - The file was loaded from this web page: - https://github.com/google/capsicum-test/blob/dev/autoconf/m4/ax_check_capsicum.m4 - - Thanks to Loganaden Velvindron for pointing it out for me. + Translations: Update the Croatian translation - m4/ax_check_capsicum.m4 | 86 +++++++++++++++++++++++++++++++++++++++++++++++++ - 1 file changed, 86 insertions(+) + po/hr.po | 14 +++++++------- + 1 file changed, 7 insertions(+), 7 deletions(-) -commit d74377e62b4c649e40294dd441de72c0f092e67c +commit 173fb5c68b08a8c1369550267be258132b7760c6 Author: Lasse Collin -Date: 2015-10-12 20:29:09 +0300 +Date: 2025-03-25 18:23:57 +0200 - liblzma: Fix a memory leak in error path of lzma_index_dup(). - - lzma_index_dup() calls index_dup_stream() which, in case of - an error, calls index_stream_end() to free memory allocated - by index_stream_init(). However, it illogically didn't - actually free the memory. To make it logical, the tree - handling code was modified a bit in addition to changing - index_stream_end(). - - Thanks to Evan Nemerson for the bug report. + doc/SHA256SUMS: Add 5.8.0 - src/liblzma/common/index.c | 18 +++++++++--------- - 1 file changed, 9 insertions(+), 9 deletions(-) + doc/SHA256SUMS | 6 ++++++ + 1 file changed, 6 insertions(+) -commit f580732216dcf971f3f006fe8e01cd4979e1d964 +commit db9258e828bc2cd96e3954f1ddcc9d3530589025 Author: Lasse Collin -Date: 2016-10-24 18:53:25 +0300 +Date: 2025-03-25 15:18:32 +0200 - Update THANKS. + Bump version and soname for 5.8.0 + + Also remove the LZMA_UNSTABLE macro. - THANKS | 1 + - 1 file changed, 1 insertion(+) + src/liblzma/Makefile.am | 2 +- + src/liblzma/api/lzma/bcj.h | 2 -- + src/liblzma/api/lzma/version.h | 6 +++--- + src/liblzma/common/common.h | 2 -- + src/liblzma/liblzma_generic.map | 2 +- + src/liblzma/liblzma_linux.map | 2 +- + 6 files changed, 6 insertions(+), 10 deletions(-) -commit 88d7a7fd153bf1355cdf798ffdac7443d0169afc +commit bfb752a38f89ed03fc93d54f11c09f43fda64bc2 Author: Lasse Collin -Date: 2016-10-24 18:51:36 +0300 +Date: 2025-03-25 15:18:32 +0200 - tuklib_cpucores: Add support for sched_getaffinity(). - - It's available in glibc (GNU/Linux, GNU/kFreeBSD). It's better - than sysconf(_SC_NPROCESSORS_ONLN) because sched_getaffinity() - gives the number of cores available to the process instead of - the total number of cores online. - - As a side effect, this commit fixes a bug on GNU/kFreeBSD where - configure would detect the FreeBSD-specific cpuset_getaffinity() - but it wouldn't actually work because on GNU/kFreeBSD it requires - using -lfreebsd-glue when linking. Now the glibc-specific function - will be used instead. - - Thanks to Sebastian Andrzej Siewior for the original patch - and testing. + Add NEWS for 5.8.0 - m4/tuklib_cpucores.m4 | 30 +++++++++++++++++++++++++++++- - src/common/tuklib_cpucores.c | 9 +++++++++ - 2 files changed, 38 insertions(+), 1 deletion(-) + NEWS | 62 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ + 1 file changed, 62 insertions(+) -commit 51baf684376903dbeddd840582bfdf9fa91b311b +commit 6ccbb904da851eb0c174c8dbd43e84da31739720 Author: Lasse Collin -Date: 2016-06-30 20:27:36 +0300 +Date: 2025-03-25 15:18:31 +0200 - xz: Fix copying of timestamps on Windows. + Translations: Run "make -C po update-po" - xz used to call utime() on Windows, but its result gets lost - on close(). Using _futime() seems to work. + POT-Creation-Date is set to match the timestamp in 5.7.2beta which + in the Translation Project is known as 5.8.0-pre1. The strings + haven't changed since 5.7.1alpha but a few comments have. - Thanks to Martok for reporting the bug: - http://www.mail-archive.com/xz-devel@tukaani.org/msg00261.html + This is a very noisy commit, but this helps keeping the PO files + similar between the Git repository and stable release tarballs. - configure.ac | 2 +- - src/xz/file_io.c | 18 ++++++++++++++++++ - 2 files changed, 19 insertions(+), 1 deletion(-) + po/ca.po | 964 ++++++++++++++++++++++++++++++++++++++++++++--------------- + po/cs.po | 935 ++++++++++++++++++++++++++++++++++++++++++---------------- + po/da.po | 663 ++++++++++++++++++++++++++++++----------- + po/de.po | 7 +- + po/eo.po | 966 +++++++++++++++++++++++++++++++++++++++++++++--------------- + po/es.po | 7 +- + po/fi.po | 2 +- + po/fr.po | 916 +++++++++++++++++++++++++++++++++++++++++--------------- + po/hu.po | 966 +++++++++++++++++++++++++++++++++++++++++++++--------------- + po/ka.po | 7 +- + po/ko.po | 7 +- + po/nl.po | 7 +- + po/pl.po | 7 +- + po/pt_BR.po | 962 ++++++++++++++++++++++++++++++++++++++++++++--------------- + po/sr.po | 2 +- + po/sv.po | 7 +- + po/tr.po | 7 +- + po/uk.po | 7 +- + po/vi.po | 948 +++++++++++++++++++++++++++++++++++++++++++--------------- + po/zh_CN.po | 940 ++++++++++++++++++++++++++++++++++++++++++++-------------- + po/zh_TW.po | 2 +- + 21 files changed, 6209 insertions(+), 2120 deletions(-) -commit 1ddc479851139d6e8202e5835421bfe6578d9e07 +commit 891a5f057a6bb2dd2e3ce5e3bdd7a1f1ee03b800 Author: Lasse Collin -Date: 2016-06-16 22:46:02 +0300 +Date: 2025-03-25 15:18:31 +0200 - xz: Silence warnings from -Wlogical-op. + Translations: Run po4a/update-po + + Also remove the trivial obsolete messages like man page dates. - Thanks to Evan Nemerson. + This is a noisy commit, but this helps keeping the PO files similar + between the Git repository and stable release tarballs. - src/xz/file_io.c | 12 ++++++++++-- - 1 file changed, 10 insertions(+), 2 deletions(-) + po4a/fr.po | 82 +++++++++++++++++++++++++++++++++++++------------------ + po4a/pt_BR.po | 88 +++++++++++++++++++++++++++++++++++++++++------------------ + po4a/sr.po | 79 ++++++++++++++++++++++++++++++++++------------------- + 3 files changed, 167 insertions(+), 82 deletions(-) -commit be647ff5ed5a1c244a65722af6ce250259f3b14a +commit 4f52e7387012cb3510b01c937dd9b3a0c6a3ac6c Author: Lasse Collin -Date: 2016-04-10 20:55:49 +0300 +Date: 2025-03-25 15:18:31 +0200 - Build: Fix = to += for xz_SOURCES in src/xz/Makefile.am. + Translations: Partially fix overtranslation in Serbian man pages - Thanks to Christian Kujau. + Names of environment variables and some other strings must be present + in the original form. The translator couldn't be reached so I'm + changing some of the strings myself. In the "Robot mode" section, + occurrences in the middle of sentences weren't changed to reduce + the chance of grammar breakage, but I kept the translated strings in + parenthesis in the headings. It's not ideal, but now people shouldn't + need to look at the English man page to find the English strings. - src/xz/Makefile.am | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) + po4a/sr.po | 66 ++++++++++++++++++++++++++++++++++++++++++-------------------- + 1 file changed, 45 insertions(+), 21 deletions(-) -commit fb6d50c15343831f35305982cefa82053099191d +commit ff5d944749b99eb5ab35e2ebaf01d05a59e7169b Author: Lasse Collin -Date: 2016-04-10 20:54:17 +0300 +Date: 2025-03-25 15:18:31 +0200 - Build: Bump GNU Gettext version requirement to 0.19. - - It silences a few warnings and most people probably have - 0.19 even on stable distributions. - - Thanks to Christian Kujau. + liblzma: Count the extra bytes in LZMA/LZMA2 decoder memory usage - configure.ac | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) + src/liblzma/lz/lz_decoder.c | 3 ++- + 1 file changed, 2 insertions(+), 1 deletion(-) -commit 74f8dad9f912a2993768d93d108ea2b0b2c196e0 +commit 943b012d09f717f7b44284c4e4976ea41264c731 Author: Lasse Collin -Date: 2016-03-13 20:21:49 +0200 +Date: 2025-03-25 15:18:31 +0200 - liblzma: Disable external SHA-256 by default. + liblzma: Use SSE2 intrinsics instead of memcpy() in dict_repeat() + + SSE2 is supported on every x86-64 processor. The SSE2 code is used on + 32-bit x86 if compiler options permit unconditional use of SSE2. - This is the sane thing to do. The conflict with OpenSSL - on some OSes and especially that the OS-provided versions - can be significantly slower makes it clear that it was - a mistake to have the external SHA-256 support enabled by - default. + dict_repeat() copies short random-sized unaligned buffers. At least + on glibc, FreeBSD, and Windows (MSYS2, UCRT, MSVCRT), memcpy() is + clearly faster than byte-by-byte copying in this use case. Compared + to the memcpy() version, the new SSE2 version reduces decompression + time by 0-5 % depending on the machine and libc. It should never be + slower than the memcpy() version. - Those who want it can now pass --enable-external-sha256 to - configure. INSTALL was updated with notes about OSes where - this can be a bad idea. + However, on musl 1.2.5 on x86-64, the memcpy() version is the slowest. + Compared to the memcpy() version: - The SHA-256 detection code in configure.ac had some bugs that - could lead to a build failure in some situations. These were - fixed, although it doesn't matter that much now that the - external SHA-256 is disabled by default. + - The byte-by-version takes 6-7 % less time to decompress. + - The SSE2 version takes 16-18 % less time to decompress. - MINIX >= 3.2.0 uses NetBSD's libc and thus has SHA256_Init - in libc instead of libutil. Support for the libutil version - was removed. + The numbers are from decompressing a Linux kernel source tarball in + single-threaded mode on older AMD and Intel systems. The tarball + compresses well, and thus dict_repeat() performance matters more + than with some other files. - INSTALL | 36 ++++++++++++++++++++++ - configure.ac | 76 +++++++++++++++++++++++------------------------ - src/liblzma/check/check.h | 16 ++++------ - 3 files changed, 79 insertions(+), 49 deletions(-) + src/liblzma/lz/lz_decoder.c | 14 ++++++-- + src/liblzma/lz/lz_decoder.h | 87 ++++++++++++++++++++++++++++++++++++++++----- + 2 files changed, 90 insertions(+), 11 deletions(-) -commit ea7f6ff04cb5bb1498088eb09960a4c3f13dfe39 +commit bc14e4c94e788d42eeab984298391fc0ca46f969 Author: Lasse Collin -Date: 2016-03-10 20:27:05 +0200 +Date: 2025-03-25 15:18:31 +0200 - Update THANKS. + liblzma: Add "restrict" to a few functions in lz_decoder.h + + This doesn't make any difference in practice because compilers can + already see that writing through the dict->buf pointer cannot modify + the contents of *dict itself: The LZMA decoder makes a local copy of + the lzma_dict structure, and even if it didn't, the pointer to + lzma_dict in the LZMA decoder is already "restrict". + + It's nice to add "restrict" anyway. uint8_t is typically unsigned char + which can alias anything. Without the above conditions or "restrict", + compilers could need to assume that writing through dict->buf might + modify *dict. This would matter in dict_repeat() because the loops + refer to dict->buf and dict->pos instead of making local copies of + those members for the duration of the loops. If compilers had to + assume that writing through dict->buf can affect *dict, then compilers + would need to emit code that reloads dict->buf and dict->pos after + every write through dict->buf. - THANKS | 1 + - 1 file changed, 1 insertion(+) + src/liblzma/lz/lz_decoder.h | 7 ++++--- + 1 file changed, 4 insertions(+), 3 deletions(-) -commit d0e018016b311232e82d9a98dc68f1e3dabce794 +commit e82ee090c567e560f51a056775a17f534d159d65 Author: Lasse Collin -Date: 2016-03-10 20:26:49 +0200 +Date: 2025-03-25 15:18:30 +0200 - Build: Avoid SHA256_Init on FreeBSD and MINIX 3. - - On FreeBSD 10 and older, SHA256_Init from libmd conflicts - with libcrypto from OpenSSL. The OpenSSL version has - different sizeof(SHA256_CTX) and it can cause weird - problems if wrong SHA256_Init gets used. - - Looking at the source, MINIX 3 seems to have a similar issue but - I'm not sure. To be safe, I disabled SHA256_Init on MINIX 3 too. + liblzma: Define LZ_DICT_INIT_POS for initial dictionary position - NetBSD has SHA256_Init in libc and they had a similar problem, - but they already fixed it in 2009. - - Thanks to Jim Wilcoxson for the bug report that helped - in finding the problem. + It's more readable. - configure.ac | 27 +++++++++++++++++++++------ - 1 file changed, 21 insertions(+), 6 deletions(-) + src/liblzma/lz/lz_decoder.c | 4 ++-- + src/liblzma/lz/lz_decoder.h | 9 ++++++--- + 2 files changed, 8 insertions(+), 5 deletions(-) -commit 5daae123915f32a4ed6dc948b831533c2d1beec3 +commit 8e7cd0091e5239334437decbe1989662d45a2f47 Author: Lasse Collin -Date: 2015-11-08 20:16:10 +0200 +Date: 2025-03-25 15:18:30 +0200 - tuklib_physmem: Hopefully silence a warning on Windows. + Windows: Update README-Windows.txt about UCRT - src/common/tuklib_physmem.c | 3 ++- + windows/README-Windows.txt | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) -commit 491acc406e098167ccb7fce0728b94c2f32cff9f +commit 2c24292d341e505e5579fccac3bce5bc71d839ef Author: Lasse Collin -Date: 2015-11-04 23:17:43 +0200 +Date: 2025-03-25 15:18:15 +0200 - Update THANKS. + Update THANKS THANKS | 1 + 1 file changed, 1 insertion(+) -commit 8173ff8790ad3502d04e1c07d014cb84a3b8187b +commit 48053c90898fa191a216aefca01626520a7413f4 Author: Lasse Collin -Date: 2015-11-04 23:14:00 +0200 +Date: 2025-03-17 15:33:25 +0200 - liblzma: Make Valgrind happier with optimized (gcc -O2) liblzma. - - When optimizing, GCC can reorder code so that an uninitialized - value gets used in a comparison, which makes Valgrind unhappy. - It doesn't happen when compiled with -O0, which I tend to use - when running Valgrind. - - Thanks to Rich Prohaska. I remember this being mentioned long - ago by someone else but nothing was done back then. + Translations: Update the Italian translation - src/liblzma/lz/lz_encoder.c | 4 ++++ - 1 file changed, 4 insertions(+) + po/it.po | 32 ++++++++++++++++---------------- + 1 file changed, 16 insertions(+), 16 deletions(-) -commit 013de2b5ab8094d2c82a2771f3d143eeb656eda9 +commit 8d6f06a65f50358fad13567f5dd8af41ef1d2b58 Author: Lasse Collin -Date: 2015-11-03 20:55:45 +0200 +Date: 2025-03-17 15:28:56 +0200 - liblzma: Rename lzma_presets.c back to lzma_encoder_presets.c. + Translations: Update the Portuguese translation - It would be too annoying to update other build systems - just because of this. + The language tag in the Translation Project is pt, not pt_PT, + thus I changed the "Language:" line to pt. - src/liblzma/lzma/Makefile.inc | 2 +- - src/liblzma/lzma/{lzma_presets.c => lzma_encoder_presets.c} | 2 +- - 2 files changed, 2 insertions(+), 2 deletions(-) + po/pt.po | 1045 +++++++++++++++++++++++++++++++------------------------------- + 1 file changed, 526 insertions(+), 519 deletions(-) -commit a322f70ad96de88968c2c36e6a36bc08ae30bd20 +commit c3439b039f46fe547ad603e16dc3bd63c1ca9b0c Author: Lasse Collin -Date: 2015-11-03 20:47:07 +0200 +Date: 2025-03-14 13:02:21 +0200 - Build: Disable xzdec, lzmadec, and lzmainfo when they cannot be built. - - They all need decoder support and if that isn't available, - there's no point trying to build them. + Translations: Update the Italian translation - configure.ac | 3 +++ - 1 file changed, 3 insertions(+) + po/it.po | 1020 +++++++++++++++++++++++++++++++------------------------------- + 1 file changed, 516 insertions(+), 504 deletions(-) -commit 8ea49606cf6427e32319de7693eca9e43f1c8ad6 +commit 79b4ab8d79528dd633a84df2d29e63f5d13ccbdf Author: Lasse Collin -Date: 2015-11-03 20:35:19 +0200 +Date: 2025-03-12 20:48:39 +0200 - Build: Simplify $enable_{encoders,decoders} usage a bit. + Translations: Update the Italian man page translations + + Only trivial additions but this keeps the file in sync with the TP. - configure.ac | 6 ++++-- - 1 file changed, 4 insertions(+), 2 deletions(-) + po4a/it.po | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) -commit 42131a25e52bfe400acfa7df93469a96bb78bb78 +commit 515b6fc8557825e1335012b3b1c8cf71e2c38775 Author: Lasse Collin -Date: 2015-11-03 20:31:31 +0200 +Date: 2025-03-12 19:38:54 +0200 - Windows/MSVC: Update config.h. + Translations: Update the Italian man page translations - windows/config.h | 6 ++++++ - 1 file changed, 6 insertions(+) + po4a/it.po | 129 ++++++++++++++++++++++++++++++++++++------------------------- + 1 file changed, 77 insertions(+), 52 deletions(-) -commit e9184e87cc989d14c7413e6adb3eca98f6ae0290 +commit 333b7c0b776295f0941269b4e6cdb1a0ba5f6218 Author: Lasse Collin -Date: 2015-11-03 20:29:58 +0200 +Date: 2025-03-10 21:00:31 +0200 - DOS: Update config.h. + Translations: Update the Korean man page translations - dos/config.h | 6 ++++++ - 1 file changed, 6 insertions(+) + po4a/ko.po | 139 +++++++++++++++++++++++++++++++++++-------------------------- + 1 file changed, 80 insertions(+), 59 deletions(-) -commit 2296778f3c9a1e3a8699973b09dd3610b8baa402 +commit ae52ebd27dc0be5e1ba62fb0c45255d8563fcd88 Author: Lasse Collin -Date: 2015-11-03 20:29:33 +0200 +Date: 2025-03-10 20:56:57 +0200 - xz: Make xz buildable even when encoders or decoders are disabled. - - The patch is quite long but it's mostly about adding new #ifdefs - to omit code when encoders or decoders have been disabled. - - This adds two new #defines to config.h: HAVE_ENCODERS and - HAVE_DECODERS. + Translations: Update the German man page translations - configure.ac | 4 ++++ - src/xz/Makefile.am | 8 ++++++-- - src/xz/args.c | 16 ++++++++++++++++ - src/xz/coder.c | 33 +++++++++++++++++++++++++-------- - src/xz/main.c | 9 +++++++-- - src/xz/private.h | 5 ++++- - 6 files changed, 62 insertions(+), 13 deletions(-) + po4a/de.po | 102 ++++++++++++++++++++++++++++++++++++++----------------------- + 1 file changed, 63 insertions(+), 39 deletions(-) -commit 97a3109281e475d9cf1b5095237d672fa0ad25e5 +commit 1028e52c93d2292b44ff7bae8e721025d2f2c94d Author: Lasse Collin -Date: 2015-11-03 18:06:40 +0200 +Date: 2025-03-10 13:13:30 +0200 - Build: Build LZMA1/2 presets also when only decoder is wanted. + CMake: Fix tuklib_use_system_extensions - People shouldn't rely on the presets when decoding raw streams, - but xz uses the presets as the starting point for raw decoder - options anyway. - - lzma_encocder_presets.c was renamed to lzma_presets.c to - make it clear it's not used solely by the encoder code. - - src/liblzma/lzma/Makefile.inc | 6 +++++- - src/liblzma/lzma/{lzma_encoder_presets.c => lzma_presets.c} | 3 ++- - 2 files changed, 7 insertions(+), 2 deletions(-) - -commit dc6b78d7f0f6fe43e9d4215146e8581feb8090e7 -Author: Lasse Collin -Date: 2015-11-03 17:54:48 +0200 - - Build: Fix configure to handle LZMA1 dependency with LZMA2. + Revert back to a macro so that list(APPEND CMAKE_REQUIRED_DEFINITIONS) + will affect the calling scope. I had forgotten that while CMake + functions inherit the variables from the parent scope, the changes + to them are local unless using set(... PARENT_SCOPE). - Now it gives an error if LZMA1 encoder/decoder is missing - when LZMA2 encoder/decoder was requested. Even better would - be LZMA2 implicitly enabling LZMA1 but it would need more code. - - configure.ac | 5 ----- - 1 file changed, 5 deletions(-) - -commit 46d76c9cd3cb26a31f5ae6c3a8bbcf38e6da1add -Author: Lasse Collin -Date: 2015-11-03 17:41:54 +0200 - - Build: Don't omit lzma_cputhreads() unless using --disable-threads. + This also means that the commit message in 5bb77d0920dc is wrong. The + commit itself is still fine, making it clearer that -DHAVE_SYS_PARAM_H + is only needed for specific check_c_source_compiles() calls. - Previously it was omitted if encoders were disabled - with --disable-encoders. It didn't make sense and - it also broke the build. + Fixes: c1ea7bd0b60eed6ebcdf9a713ca69034f6f07179 - src/liblzma/common/Makefile.inc | 5 ++++- - 1 file changed, 4 insertions(+), 1 deletion(-) + cmake/tuklib_common.cmake | 7 +++++-- + 1 file changed, 5 insertions(+), 2 deletions(-) -commit 16d68f874d89f1e4a1919786a35bbaef7d71a077 +commit 80e48836024ec2d7cbd557575be6da3d1f055cba Author: Lasse Collin -Date: 2015-11-02 18:16:51 +0200 +Date: 2025-03-10 11:38:55 +0200 - liblzma: Fix a build failure related to external SHA-256 support. + INSTALL: Document -bmaxdata on AIX - If an appropriate header and structure were found by configure, - but a library with a usable SHA-256 functions wasn't, the build - failed. - - src/liblzma/check/check.h | 32 +++++++++++++++++++++++--------- - 1 file changed, 23 insertions(+), 9 deletions(-) - -commit d9311647fc1ab512a3394596221ab8039c00af6b -Author: Lasse Collin -Date: 2015-11-02 15:19:10 +0200 - - xz: Always close the file before trying to delete it. + This is based on a pull request and AIX docs. I haven't tested the + instructions myself. - unlink() can return EBUSY in errno for open files on some - operating systems and file systems. + Closes: https://github.com/tukaani-project/xz/pull/137 - src/xz/file_io.c | 25 ++++++++++++------------- - 1 file changed, 12 insertions(+), 13 deletions(-) + INSTALL | 5 +++++ + 1 file changed, 5 insertions(+) -commit f59c4183f3c9066626ce45dc3db4642fa603fa21 +commit ab319186b6d0454285ff4941a777ac95e580f60f Author: Lasse Collin -Date: 2015-10-12 21:08:42 +0300 +Date: 2025-03-10 11:37:19 +0200 - Update THANKS. + Update THANKS THANKS | 1 + 1 file changed, 1 insertion(+) -commit 35f189673e280c12e4c5129f9f97e54eef3bbc04 -Author: Lasse Collin -Date: 2015-10-12 21:07:41 +0300 +commit 4434671a04436038f88ab0feaa251cc8d7abb683 +Author: Collin Funk +Date: 2025-03-09 19:14:31 -0700 - Tests: Add tests for the two bugs fixed in index.c. + tuklib_physmem: Silence -Wsign-conversion on AIX + + Closes: https://github.com/tukaani-project/xz/pull/168 - tests/test_index.c | 30 ++++++++++++++++++++++++++++++ - 1 file changed, 30 insertions(+) + src/common/tuklib_physmem.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) -commit e10bfdb0fcaff12f3a6dadee51e0a022aadccb51 +commit 18bcaa4fafc935d89ffde94301fa6427907306bf Author: Lasse Collin -Date: 2015-10-12 20:45:15 +0300 +Date: 2025-03-09 22:10:38 +0200 - liblzma: Fix lzma_index_dup() for empty Streams. - - Stream Flags and Stream Padding weren't copied from - empty Streams. + Translations: Update the Romanian man page translations - src/liblzma/common/index.c | 11 ++++++----- - 1 file changed, 6 insertions(+), 5 deletions(-) + po4a/ro.po | 110 ++++++++++++++++++++++++++++++++++++------------------------- + 1 file changed, 66 insertions(+), 44 deletions(-) -commit 06f434bd8980f25ca23232eb7bb7df7e37dc8448 +commit 1e17b7f42fe2f9df279f44ad7043d3753cd00363 Author: Lasse Collin -Date: 2015-10-12 20:31:44 +0300 +Date: 2025-03-09 21:28:15 +0200 - liblzma: Add a note to index.c for those using static analyzers. + Translations: Update the Croatian translation - src/liblzma/common/index.c | 3 +++ - 1 file changed, 3 insertions(+) + po/hr.po | 19 +++++++++++-------- + 1 file changed, 11 insertions(+), 8 deletions(-) -commit 9815cdf6987ef91a85493bfcfd1ce2aaf3b47a0a +commit ff85e6130d5940896915cdbb99aa9ece9d41240b Author: Lasse Collin -Date: 2015-09-29 13:59:35 +0300 +Date: 2025-03-09 21:23:34 +0200 - Bump version and soname for 5.2.2. + Translations: Update the Romanian translation - src/liblzma/Makefile.am | 2 +- - src/liblzma/api/lzma/version.h | 2 +- - 2 files changed, 2 insertions(+), 2 deletions(-) + po/ro.po | 24 +++++++++++++----------- + 1 file changed, 13 insertions(+), 11 deletions(-) -commit cbe0cec8476bdd0416c7ca9bc83895c9bea1cf78 +commit a5bfb33f30f77e656723d365db8b06e089d3de61 Author: Lasse Collin -Date: 2015-09-29 13:57:28 +0300 +Date: 2025-03-09 21:11:34 +0200 - Update NEWS for 5.2.2. + Translations: Update the Ukrainian man page translations - NEWS | 18 ++++++++++++++++++ - 1 file changed, 18 insertions(+) + po4a/uk.po | 107 ++++++++++++++++++++++++++++++++++++------------------------- + 1 file changed, 64 insertions(+), 43 deletions(-) -commit 49427ce7eececdd18bbd35dab23c81910d083e1c -Author: Andre Noll -Date: 2015-05-28 15:50:00 +0200 +commit 5bb77d0920dcf949d8eb04eb19204b7b199e42df +Author: Lasse Collin +Date: 2025-03-09 14:43:07 +0200 - Fix typo in German translation. + CMake: Use cmake_push_check_state in tuklib_cpucores and tuklib_physmem - As pointed out by Robert Pollak, there's a typo in the German - translation of the compression preset option (-0 ... -9) help text. - "The compressor" translates to "der Komprimierer", and the genitive - form is "des Komprimierers". The old word makes no sense at all. + Now the changes to CMAKE_REQUIRED_DEFINITIONS are temporary and don't + leak to the calling code. - po/de.po | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) + cmake/tuklib_cpucores.cmake | 3 +++ + cmake/tuklib_physmem.cmake | 4 +++- + 2 files changed, 6 insertions(+), 1 deletion(-) -commit 608d6f06c940e7f28c25de005e8b99bdff42d27c -Author: Hauke Henningsen -Date: 2015-08-17 04:59:54 +0200 +commit c1ea7bd0b60eed6ebcdf9a713ca69034f6f07179 +Author: Lasse Collin +Date: 2025-03-09 14:06:35 +0200 - Update German translation, mostly wrt orthography + CMake: Revise tuklib_use_system_extensions - Provide an update of the German translation. - * A lot of compound words were previously written with spaces, while - German orthography is relatively clear in that the components - should not be separated. - * When referring to the actual process of (de)compression rather than the - concept, replace “(De-)Kompression” with “(De-)Komprimierung”. - Previously, both forms were used in this context and are now used in a - manner consistent with “Komprimierung” being more likely to refer to - a process. - * Consistently translate “standard input”/“output” - * Use “Zeichen” instead of false friend “Charakter” for “character” - * Insert commas around relative clauses (as required in German) - * Some other minor corrections - * Capitalize “ß” as “ẞ” - * Consistently start option descriptions in --help with capital letters + Define NetBSD and Darwin/macOS feature test macros. Autoconf defines + these too (and a few others). - Acked-By: Andre Noll + Define the macros on Windows except with MSVC. The _GNU_SOURCE macro + makes a difference with mingw-w64. - * Update after msgmerge + Use a function instead of a macro. Don't take the TARGET_OR_ALL argument + because there's always global effect because the global variable + CMAKE_REQUIRED_DEFINITIONS is modified. - po/de.po | 383 ++++++++++++++++++++++++++++++++------------------------------- - 1 file changed, 196 insertions(+), 187 deletions(-) + CMakeLists.txt | 2 +- + cmake/tuklib_common.cmake | 27 +++++++++++++++------------ + 2 files changed, 16 insertions(+), 13 deletions(-) -commit c8988414e5b67b8ef2fe0ba7b1ccdd0ec73c60d3 +commit 4243c45a48ef8c103d77b75d9f93d48adcb631db Author: Lasse Collin -Date: 2015-08-11 13:23:04 +0300 +Date: 2025-03-08 14:54:29 +0200 - Build: Minor Cygwin cleanup. - - Some tests used "cygwin*" and some used "cygwin". I changed - them all to use "cygwin". Shouldn't affect anything in practice. + doc/SHA256SUMS: Add 5.7.2beta - configure.ac | 6 +++--- - 1 file changed, 3 insertions(+), 3 deletions(-) + doc/SHA256SUMS | 3 +++ + 1 file changed, 3 insertions(+) -commit 85a6dfed53477906bfe9a7c0123dd412e391cb48 +commit cc7f2fc1cf9f3c63cbce90ee92bfbb004f98140b Author: Lasse Collin -Date: 2015-08-11 13:21:52 +0300 +Date: 2025-03-08 14:29:57 +0200 - Build: Support building of MSYS2 binaries. + Bump version and soname for 5.7.2beta - configure.ac | 16 +++++++++++----- - 1 file changed, 11 insertions(+), 5 deletions(-) + src/liblzma/Makefile.am | 2 +- + src/liblzma/api/lzma/version.h | 4 ++-- + src/liblzma/liblzma_generic.map | 2 +- + src/liblzma/liblzma_linux.map | 2 +- + 4 files changed, 5 insertions(+), 5 deletions(-) -commit 77f270be8432df2e4516a0c48814b6976d6618c5 +commit 62e44b36167de27541776dcf677ed04077c9fd19 Author: Lasse Collin -Date: 2015-08-09 21:06:26 +0300 +Date: 2025-03-08 14:24:38 +0200 - Windows: Define DLL_EXPORT when building liblzma.dll with MSVC. - - src/liblzma/common/common.h uses it to set __declspec(dllexport) - for the API symbols. - - Thanks to Adam Walling. + Add NEWS for 5.7.2beta - windows/liblzma_dll.vcxproj | 12 ++++++------ - 1 file changed, 6 insertions(+), 6 deletions(-) + NEWS | 35 +++++++++++++++++++++++++++++++++++ + 1 file changed, 35 insertions(+) -commit 8c975446c5903090a5a8493b5b96b71003056a88 +commit 70f1f203789433b5d7b8b22e1655abc465d659f7 Author: Lasse Collin -Date: 2015-08-09 21:02:20 +0300 +Date: 2025-03-08 14:23:00 +0200 - Windows: Omit unneeded header files from MSVC project files. + COPYING: Remove the note about old releases - windows/liblzma.vcxproj | 5 ----- - windows/liblzma_dll.vcxproj | 5 ----- - 2 files changed, 10 deletions(-) + COPYING | 19 ------------------- + 1 file changed, 19 deletions(-) -commit 119a00434954726ca58e4a578e6469f530fca30e +commit db9827dc38ff79de747a6fc7a99619e961dbc5e6 Author: Lasse Collin -Date: 2015-07-12 20:48:19 +0300 +Date: 2025-03-08 14:22:28 +0200 - liblzma: A MSVC-specific hack isn't needed with MSVC 2013 and newer. + xz: Update the man page about the environment variables again - src/liblzma/api/lzma.h | 18 +++++++++++++----- - 1 file changed, 13 insertions(+), 5 deletions(-) + src/xz/xz.1 | 22 +++++++++++----------- + 1 file changed, 11 insertions(+), 11 deletions(-) -commit d4e7c557fcab353539c9481a8d95cb04bcb15c7c +commit 99c584891bd1d946561cebded2226df9b83f1efb Author: Lasse Collin -Date: 2015-06-19 20:38:55 +0300 +Date: 2025-03-06 19:26:09 +0200 - Update THANKS. + liblzma: Edit spelling in a comment + + It was found with codespell. - THANKS | 2 ++ - 1 file changed, 2 insertions(+) + src/liblzma/api/lzma/container.h | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) -commit 98001740ca56c894a7bd32eb47e9857a8a7d878d +commit 7a234c8c05a8f64efde013cd6a6d31a90b7d0d28 Author: Lasse Collin -Date: 2015-06-19 20:21:30 +0300 +Date: 2025-03-06 19:14:23 +0200 - Windows: Update the docs. + xz: Update the man page about the environment variables - INSTALL | 29 ++++++++----- - windows/INSTALL-MSVC.txt | 47 ++++++++++++++++++++++ - windows/{INSTALL-Windows.txt => INSTALL-MinGW.txt} | 2 +- - 3 files changed, 67 insertions(+), 11 deletions(-) + src/xz/xz.1 | 26 ++++++++++++++++++++++++-- + 1 file changed, 24 insertions(+), 2 deletions(-) -commit 28195e4c877007cc760ecea1d17f740693d66873 +commit 808f05af3ef40730d40b3798666757bd866484f1 Author: Lasse Collin -Date: 2015-06-19 17:25:31 +0300 +Date: 2025-03-06 17:37:39 +0200 - Windows: Add MSVC project files for building liblzma. + Docs: Add a few TRANSLATORS comments to man pages - Thanks to Adam Walling for creating these files. + All translators know that --command-line-options must not be translated. + With some other strings it's not obvious when the untranslated string + must be preserved. These comments hopefully help. - windows/liblzma.vcxproj | 359 ++++++++++++++++++++++++++++++++++++++++ - windows/liblzma_dll.vcxproj | 388 ++++++++++++++++++++++++++++++++++++++++++++ - windows/xz_win.sln | 48 ++++++ - 3 files changed, 795 insertions(+) + src/scripts/xzmore.1 | 2 ++ + src/xz/xz.1 | 22 ++++++++++++++++++++++ + 2 files changed, 24 insertions(+) -commit 960440f3230dc628f6966d9f7614fc1b28baf44e +commit 051de255f00dda331e2a6fa189a6e7fe56a7c69b Author: Lasse Collin -Date: 2015-05-13 20:57:55 +0300 +Date: 2025-03-06 16:34:32 +0200 - Tests: Fix a memory leak in test_bcj_exact_size. + Scripts: Mark the LZMA Utils script aliases as deprecated + + The deprecated aliases are lzcmp, lzdiff, lzless, lzmore, + lzgrep, lzegrep, and lzfgrep. The commands that start with + the xz prefix have identical behavior, for example, both + lzgrep and xzgrep handle all supported file formats. - Thanks to Cristian Rodríguez. + This doesn't affect lzma, unlzma, lzcat, lzmadec, or lzmainfo. + The last release of LZMA Utils was made in 2008, but the lzma + compatibility alias for the gzip-like tool is still in common use. + Deprecating it would cause unnecessary breakage. - tests/test_bcj_exact_size.c | 1 + - 1 file changed, 1 insertion(+) + src/scripts/xzdiff.1 | 5 ++++- + src/scripts/xzgrep.1 | 6 +++++- + src/scripts/xzless.1 | 4 +++- + src/scripts/xzmore.1 | 4 +++- + 4 files changed, 15 insertions(+), 4 deletions(-) -commit 68cd35acafbdcdf4e8ea8b5bb843c736939d6f8b +commit 4941ea454c02cf15a64d6434a0778fc2a81282fc Author: Lasse Collin -Date: 2015-05-12 18:08:24 +0300 +Date: 2025-03-02 21:13:04 +0200 - Fix NEWS about threading in 5.2.0. - - Thanks to Andy Hochhaus. + Translations: Add Serbian man page translations - NEWS | 3 ++- - 1 file changed, 2 insertions(+), 1 deletion(-) + po4a/po4a.conf | 2 +- + po4a/sr.po | 3892 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ + 2 files changed, 3893 insertions(+), 1 deletion(-) -commit ff96ed6d25786728356017a13baf8c14731b4f1e +commit d142d96f24daa451edaabfca8594e202932b3c0b Author: Lasse Collin -Date: 2015-05-11 21:26:16 +0300 +Date: 2025-03-02 20:42:14 +0200 - xz: Document that threaded decompression hasn't been implemented yet. + Translations: Update Georgian translation - src/xz/xz.1 | 10 +++++++++- - 1 file changed, 9 insertions(+), 1 deletion(-) + po/ka.po | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) -commit 00d37b64a64ea8597fd2422d5187afd761ab9531 +commit 9b7e45d841195c8fd8d286e26f810df28c53dd16 Author: Lasse Collin -Date: 2015-04-20 20:20:29 +0300 +Date: 2025-02-28 21:07:21 +0200 - Update THANKS. + Update THANKS THANKS | 1 + 1 file changed, 1 insertion(+) -commit db190a832c49ca3aed6d69cc992fa5583cae7b11 -Author: Lasse Collin -Date: 2015-04-20 19:59:18 +0300 - - Revert "xz: Use pipe2() if available." - - This reverts commit 7a11c4a8e5e15f13d5fa59233b3172e65428efdd. - It is a problem when libc has pipe2() but the kernel is too - old to have pipe2() and thus pipe2() fails. In xz it's pointless - to have a fallback for non-functioning pipe2(); it's better to - avoid pipe2() completely. - - Thanks to Michael Fox for the bug report. - - configure.ac | 4 ++-- - src/xz/file_io.c | 9 +-------- - 2 files changed, 3 insertions(+), 10 deletions(-) - -commit eccd8155e107c5ada03d13e7730675cdf1a44ddc +commit 9351592710e0df3238b09d39c545a643c50ac88f Author: Lasse Collin -Date: 2015-03-29 22:14:47 +0300 +Date: 2025-02-22 16:04:58 +0200 - Update THANKS. + Update THANKS THANKS | 1 + 1 file changed, 1 insertion(+) -commit 25263fd9e7a8a913395cb93d7c104cd48c2b4a00 +commit 9023be7831faca2f28def55e16c39e3a42e1e262 Author: Lasse Collin -Date: 2015-03-29 22:13:48 +0300 +Date: 2025-02-19 16:33:52 +0200 - Fix the detection of installed RAM on QNX. - - The earlier version compiled but didn't actually work - since sysconf(_SC_PHYS_PAGES) always fails (or so I was told). - - Thanks to Ole André Vadla Ravnås for the patch and testing. + Translations: Update the Croatian translation - m4/tuklib_physmem.m4 | 6 +++--- - src/common/tuklib_physmem.c | 14 +++++++++++++- - 2 files changed, 16 insertions(+), 4 deletions(-) + po/hr.po | 6 +++--- + 1 file changed, 3 insertions(+), 3 deletions(-) -commit 4c544d2410903d38402221cb783ed85585b6a007 +commit 2eaf242c56e8c65db83d48b018fa44aeafeb33a5 Author: Lasse Collin -Date: 2015-03-27 22:39:07 +0200 +Date: 2025-02-17 21:46:15 +0200 - Fix CPU core count detection on QNX. - - It tried to use sysctl() on QNX but - - it broke the build because sysctl() needs -lsocket on QNX; - - sysctl() doesn't work for detecting the core count on QNX - even if it compiled. + Build: Fix out-of-tree builds when using the replacement getopt_long - sysconf() works. An alternative would have been to use - QNX-specific SYSPAGE_ENTRY(num_cpu) from . + Nowaways $(top_builddir)/lib/getopt.h depends on headers in + $(top_srcdir)/lib, so both have to be in the include path. + CMake-based build already did this. - Thanks to Ole André Vadla Ravnås. + Fixes: 7e884c00d0093c38339f17fb1d280eec493f42ca - m4/tuklib_cpucores.m4 | 15 +++++++++++---- - 1 file changed, 11 insertions(+), 4 deletions(-) + src/lzmainfo/Makefile.am | 6 ++++-- + src/xz/Makefile.am | 6 ++++-- + src/xzdec/Makefile.am | 6 ++++-- + 3 files changed, 12 insertions(+), 6 deletions(-) -commit e0ea6737b03e83ccaff4514d00e31bb926f8f0f3 +commit 41322b2c60cd2c67a1053cb40d27e573420185b7 Author: Lasse Collin -Date: 2015-03-07 22:05:57 +0200 +Date: 2025-02-17 18:25:52 +0200 - xz: size_t/uint32_t cleanup in options.c. + m4/getopt.m4: Remove an outdated comment - src/xz/options.c | 12 ++++++------ - 1 file changed, 6 insertions(+), 6 deletions(-) + m4/getopt.m4 | 3 --- + 1 file changed, 3 deletions(-) -commit 8bcca29a65335fd679c13814b70b35b68fa5daed +commit 03c23a4952bce1b50a1d213ca2d1c15acd76a489 Author: Lasse Collin -Date: 2015-03-07 22:04:23 +0200 - - xz: Fix a comment and silence a warning in message.c. +Date: 2025-02-17 18:11:58 +0200 - src/xz/message.c | 5 +++-- + Build: Allow forcing the use of the replacement getopt_long + + Now one can pass gl_replace_getopt=yes to configure to force the use + of GNU getopt_long from the lib directory. This only checks that the + value of gl_replace_getopt is non-empty, so one cannot force the + replacement to be disabled. + + Closes: https://github.com/tukaani-project/xz/pull/166 + + m4/getopt.m4 | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) -commit f243f5f44c6b19a7c289a0ec73a03ee08364cb5b +commit c23b837d15960ecc0d537f0260f389904e1e7f02 Author: Lasse Collin -Date: 2015-03-07 22:01:00 +0200 +Date: 2025-02-17 18:11:42 +0200 - liblzma: Silence more uint32_t vs. size_t warnings. + Update THANKS - src/liblzma/lz/lz_encoder.c | 2 +- - src/liblzma/lzma/lzma_encoder.c | 2 +- - 2 files changed, 2 insertions(+), 2 deletions(-) + THANKS | 1 + + 1 file changed, 1 insertion(+) -commit 7f0a4c50f4a374c40acf4b86848f301ad1e82d34 +commit 2672a38f1159babf9ba3cca429f644bb823a8bdd Author: Lasse Collin -Date: 2015-03-07 19:54:00 +0200 +Date: 2025-02-12 19:23:31 +0200 - xz: Make arg_count an unsigned int to silence a warning. - - Actually the value of arg_count cannot exceed INT_MAX - but it's nicer as an unsigned int. + Update THANKS - src/xz/args.h | 2 +- - src/xz/main.c | 2 +- - 2 files changed, 2 insertions(+), 2 deletions(-) + THANKS | 2 ++ + 1 file changed, 2 insertions(+) -commit f6ec46801588b1be29c07c9db98558b521304002 +commit 4fdcbfaf3f222299747c6a815762a74eeb1b0b23 Author: Lasse Collin -Date: 2015-03-07 19:33:17 +0200 +Date: 2025-02-11 12:13:41 +0200 - liblzma: Fix a warning in index.c. + Update THANKS - src/liblzma/common/index.c | 4 +++- - 1 file changed, 3 insertions(+), 1 deletion(-) + THANKS | 3 +++ + 1 file changed, 3 insertions(+) -commit a24518971cc621315af142dd3bb7614fab04ad27 +commit 0d553568f1af9a35779ecac41392a6c871786930 Author: Lasse Collin -Date: 2015-02-26 20:46:14 +0200 +Date: 2025-02-08 11:39:08 +0200 - Build: Fix a CR+LF problem when running autoreconf -fi on OS/2. + Translations: Update the Polish translation - build-aux/version.sh | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) + po/pl.po | 802 ++++++++++++++++++++++++++++++++++++--------------------------- + 1 file changed, 464 insertions(+), 338 deletions(-) -commit dec11497a71518423b5ff0e759100cf8aadf6c7b +commit 9f165076aebb3b5115d2b6520529db8fa11a6bdd Author: Lasse Collin -Date: 2015-02-26 16:53:44 +0200 +Date: 2025-02-07 19:12:03 +0200 - Bump version and soname for 5.2.1. + Docs: Update TODO a little - src/liblzma/Makefile.am | 2 +- - src/liblzma/api/lzma/version.h | 2 +- - 2 files changed, 2 insertions(+), 2 deletions(-) + TODO | 22 ++++------------------ + 1 file changed, 4 insertions(+), 18 deletions(-) -commit 29e39c79975ab89ee5dd671e97064534a9f3a649 +commit f5aa292c534f87b9dd588e667d1c65ed31e5f289 Author: Lasse Collin -Date: 2015-02-26 13:01:09 +0200 +Date: 2025-02-07 18:50:56 +0200 - Update NEWS for 5.2.1. + Add researcher credits of CVE-2022-1271 and CVE-2024-47611 to THANKS + + These are specific phrases that were included in the advisories and + NEWS. It's nice to have them in THANKS as well. - NEWS | 14 ++++++++++++++ - 1 file changed, 14 insertions(+) + THANKS | 4 ++++ + 1 file changed, 4 insertions(+) -commit 7a11c4a8e5e15f13d5fa59233b3172e65428efdd +commit 7cf463b5add70e3fb48a10de3965c8beb6c01ad9 Author: Lasse Collin -Date: 2015-02-22 19:38:48 +0200 +Date: 2025-02-07 18:43:00 +0200 - xz: Use pipe2() if available. + Update THANKS - configure.ac | 4 ++-- - src/xz/file_io.c | 9 ++++++++- - 2 files changed, 10 insertions(+), 3 deletions(-) + THANKS | 5 +++++ + 1 file changed, 5 insertions(+) -commit 117d962685c72682c63edc9bb765367189800202 +commit 6b7fe7e27b77038592e2c2e31df955059dda7d1d Author: Lasse Collin -Date: 2015-02-21 23:40:26 +0200 +Date: 2025-02-04 14:12:46 +0200 - liblzma: Fix a compression-ratio regression in LZMA1/2 in fast mode. + Docs: Update the "Translations" section in README - The bug was added in the commit - f48fce093b07aeda95c18850f5e086d9f2383380 and thus - affected 5.1.4beta and 5.2.0. Luckily the bug cannot - cause data corruption or other nasty things. + Make it clearer that translations cannot be accepted if they don't + come via the Translation Project. + + Column headings have been handled automatically for years and now --help + is autowrapped too, so the related instructions can be removed. - src/liblzma/lzma/lzma_encoder_optimum_fast.c | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) + README | 107 ++++++++++++++++++++++++----------------------------------------- + 1 file changed, 39 insertions(+), 68 deletions(-) -commit ae984e31c167d3bc52972ec422dd1ebd5f5d5719 +commit 2c7aee94936babf84b61b55420e503a0b2629ec1 Author: Lasse Collin -Date: 2015-02-21 23:00:19 +0200 +Date: 2025-02-04 13:23:53 +0200 - xz: Fix the fcntl() usage when creating a pipe for the self-pipe trick. + debug/translations.bash: Revise a little + + Make it work for out-of-tree builds without requiring one to specify + the location of the xz executable. + + Add xz --filters-help. - Now it reads the old flags instead of blindly setting O_NONBLOCK. - The old code may have worked correctly, but this is better. + Make the output shorter by reducing the number of xz -lvv test files. + + Show the value of LANGUAGE environment variable. + + Show the xz.git version using git describe --abbrev=8 instead of =4. - src/xz/file_io.c | 16 +++++++++++----- - 1 file changed, 11 insertions(+), 5 deletions(-) + debug/translation.bash | 24 +++++++++++------------- + 1 file changed, 11 insertions(+), 13 deletions(-) -commit 2205bb5853098aea36a56df6f5747037175f66b4 +commit c6b15e7045209002bbbf4979c48072af01c20d8d Author: Lasse Collin -Date: 2015-02-10 15:29:34 +0200 +Date: 2025-02-04 13:20:52 +0200 - Update THANKS. + Build: Use "git describe --abbrev=8" in snapshot tarball names + + 8 is more likely to be reproducible than the old 4 without being + excessively long for a small repository like this. - THANKS | 1 + - 1 file changed, 1 insertion(+) + Makefile.am | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) -commit d935b0cdf3db440269b9d952b2b281b18f8c7b08 +commit 0ce97987c5b27cfb6f98984e5fd7477880e0cf33 Author: Lasse Collin -Date: 2015-02-10 15:28:30 +0200 +Date: 2025-02-04 19:37:17 +0200 - tuklib_cpucores: Use cpuset_getaffinity() on FreeBSD if available. - - In FreeBSD, cpuset_getaffinity() is the preferred way to get - the number of available cores. - - Thanks to Rui Paulo for the patch. I edited it slightly, but - hopefully I didn't break anything. + Update THANKS - m4/tuklib_cpucores.m4 | 23 ++++++++++++++++++++++- - src/common/tuklib_cpucores.c | 18 ++++++++++++++++++ - 2 files changed, 40 insertions(+), 1 deletion(-) + THANKS | 2 ++ + 1 file changed, 2 insertions(+) -commit eb61bc58c20769cac4d05f363b9c0e8c9c71a560 +commit 353c33355cb12e5016d49052fd1e90d15568aa37 Author: Lasse Collin -Date: 2015-02-09 22:08:37 +0200 +Date: 2025-02-03 16:29:31 +0200 - xzdiff: Make the mktemp usage compatible with FreeBSD's mktemp. - - Thanks to Rui Paulo for the fix. + Translations: Update the Serbian translation - src/scripts/xzdiff.in | 7 ++++++- - 1 file changed, 6 insertions(+), 1 deletion(-) + po/sr.po | 805 ++++++++++++++++++++++++++++++++++++--------------------------- + 1 file changed, 458 insertions(+), 347 deletions(-) -commit b9a5b6b7a29029680af733082b6a46e0fc01623a +commit 887dc281885052bced32b3aa309506ea58a2e78e Author: Lasse Collin -Date: 2015-02-03 21:45:53 +0200 +Date: 2025-02-03 16:15:38 +0200 - Add a few casts to tuklib_integer.h to silence possible warnings. + Translations: Update Chinese (traditional) translation - I heard that Visual Studio 2013 gave warnings without the casts. + Since there are no spaces between words, the unsophisticated automatic + word wrapping code needs some help. Compared to the version in the + Translation Project, I added a few \t characters which the word + wrapping code interprets as zero width spaces (hopefully they are + placed correctly). These edits can be seen with this command: - Thanks to Gabi Davar. + grep -v ^# po/zh_TW.po | grep --color -F '\t' - src/common/tuklib_integer.h | 24 ++++++++++++------------ - 1 file changed, 12 insertions(+), 12 deletions(-) + po/zh_TW.po | 843 +++++++++++++++++++++++++++++++++--------------------------- + 1 file changed, 471 insertions(+), 372 deletions(-) -commit c45757135f40e4a0de730ba5fff0100219493982 +commit 0f1454cf5f460a4095f47f8f73f5a290e9777d7f Author: Lasse Collin -Date: 2015-01-26 21:24:39 +0200 +Date: 2025-02-03 16:12:44 +0200 - liblzma: Set LZMA_MEMCMPLEN_EXTRA depending on the compare method. + Update THANKS - src/liblzma/common/memcmplen.h | 15 ++++++++++----- - 1 file changed, 10 insertions(+), 5 deletions(-) + THANKS | 2 ++ + 1 file changed, 2 insertions(+) -commit 3c500174ed5485f550972a2a6109c361e875f069 +commit 23ea031820086d302a213be005a091df763b8a7b Author: Lasse Collin -Date: 2015-01-26 20:40:16 +0200 +Date: 2025-02-02 14:15:07 +0200 - Update THANKS. + Build: Update posix-shell.m4 from Gnulib + + Tabs have been converted to spaces and a "serial" number has been + added. The previous version was from 2008/2009. There are no functional + changes since then but now it's clearer that the copy in XZ Utils + isn't outdated. + + The new file was picked from the Gnulib commit + 81a4c1e3b7692e95c0806d948cbab9148ad85ef2. A later commit adds + a warranty disclaimer to the license, which obviously is fine, + but I didn't find a SPDX license identifier for the new license, + so for simplicity I used the earlier commit. - THANKS | 1 + - 1 file changed, 1 insertion(+) + m4/posix-shell.m4 | 31 ++++++++++++++++--------------- + 1 file changed, 16 insertions(+), 15 deletions(-) -commit fec88d41e672d9e197c9442aecf02bd0dfa6d516 +commit 84c33c0384aa4604ff7956f2fae6f83ea60ba96b Author: Lasse Collin -Date: 2015-01-26 20:39:28 +0200 +Date: 2025-02-02 12:51:03 +0200 - liblzma: Silence harmless Valgrind errors. + Build: Check for -fsanitize= also in $CC + + People may put -fsanitize in CC instead of CFLAGS so check both. + Landlock sandbox isn't compatible with sanitizers so it's nice + to catch the incompatible options at configure time. - Thanks to Torsten Rupp for reporting this. I had - forgotten to run Valgrind before the 5.2.0 release. + Don't attempt to do the same in CMakeLists.txt; the check for + CMAKE_C_FLAGS / CFLAGS shall be enough there. The extra flags from + the CC environment variable go into the undocumented internal variable + CMAKE_C_COMPILER_ARG1 (all flags from CC go into that same variable). + Peeking the internal variable merely for improved diagnostics isn't + worth it. + + Fixes: 88588b1246d8c26ffbc138b3e5c413c5f14c3179 - src/liblzma/lz/lz_encoder.c | 6 ++++++ - 1 file changed, 6 insertions(+) + configure.ac | 5 +++-- + 1 file changed, 3 insertions(+), 2 deletions(-) -commit a9b45badfec0928d20a27c7176c005fa637f7d1e +commit a7304ea4a7daede9789a8fe422b714e372737120 Author: Lasse Collin -Date: 2015-01-09 21:50:19 +0200 +Date: 2023-09-26 19:11:20 +0300 - xz: Fix comments. + Build: Remove the FIXME about -Werror checks - src/xz/file_io.c | 12 ++++++++---- - 1 file changed, 8 insertions(+), 4 deletions(-) + configure.ac | 7 ------- + 1 file changed, 7 deletions(-) -commit 541aee6dd4aa97a809aba281475a21b641bb89e2 +commit 1780bba74075da5e7764615bd323e95e19057dee Author: Lasse Collin -Date: 2015-01-09 21:35:06 +0200 +Date: 2023-09-26 19:10:51 +0300 - Update THANKS. + Build: If using a GCC compatible compiler, ensure that -Werror works + + The check can be skipped by passing SKIP_WERROR_CHECK=yes to configure. + It won't be documented anywhere else than in the error message. + + Ways to test: + + ./configure CC=gcc CFLAGS=-Wunused-macros + ./configure CC=clang CFLAGS=-Weverything + ./configure CC=clang CFLAGS=-Weverything SKIP_WERROR_CHECK=yes - THANKS | 1 + - 1 file changed, 1 insertion(+) + configure.ac | 26 ++++++++++++++++++++++++++ + 1 file changed, 26 insertions(+) -commit 4170edc914655310d2363baccf5e615e09b04911 +commit 3aca2daefbdedd7cc0fb75ddde6b714273b1cc1d Author: Lasse Collin -Date: 2015-01-09 21:34:06 +0200 +Date: 2025-02-02 14:30:15 +0200 - xz: Don't fail if stdout doesn't support O_NONBLOCK. - - This is similar to the case with stdin. - - Thanks to Brad Smith for the bug report and testing - on OpenBSD. + Update THANKS - src/xz/file_io.c | 36 +++++++++++++++--------------------- - 1 file changed, 15 insertions(+), 21 deletions(-) + THANKS | 4 ++++ + 1 file changed, 4 insertions(+) -commit 04bbc0c2843c50c8ad1cba42b937118e38b0508d +commit 186ff78ab40ceb07cde139506cab42a927ca99d2 Author: Lasse Collin -Date: 2015-01-07 19:18:20 +0200 +Date: 2025-02-01 12:49:09 +0200 - xz: Fix a memory leak in DOS-specific code. + Translations: Update Romanian translation - src/xz/file_io.c | 2 ++ - 1 file changed, 2 insertions(+) + po/ro.po | 12 ++++++------ + 1 file changed, 6 insertions(+), 6 deletions(-) -commit f0f1f6c7235ffa901cf76fe18e33749e200b3eea +commit 40a8ce3e10747ca5233610cc2cb704fc303c48e4 Author: Lasse Collin -Date: 2015-01-07 19:08:06 +0200 +Date: 2025-01-30 18:16:43 +0200 - xz: Don't fail if stdin doesn't support O_NONBLOCK. - - It's a problem at least on OpenBSD which doesn't support - O_NONBLOCK on e.g. /dev/null. I'm not surprised if it's - a problem on other OSes too since this behavior is allowed - in POSIX-1.2008. - - The code relying on this behavior was committed in June 2013 - and included in 5.1.3alpha released on 2013-10-26. Clearly - the development releases only get limited testing. + Translations: Update Korean man page translations - src/xz/file_io.c | 18 +++++++----------- - 1 file changed, 7 insertions(+), 11 deletions(-) + po4a/ko.po | 146 ++++++++++++++++++++++++------------------------------------- + 1 file changed, 56 insertions(+), 90 deletions(-) -commit d2d484647d9d9d679f03c75abb0404f67069271c +commit 1787f9bd18ea8798d64b636cdefe6d0fda9b8f72 Author: Lasse Collin -Date: 2015-01-06 20:30:15 +0200 +Date: 2025-01-30 18:15:52 +0200 - Tests: Don't hide unexpected error messages in test_files.sh. - - Hiding them makes no sense since normally there's no error - when testing the "good" files. With "bad" files errors are - expected and then it makes sense to keep the messages hidden. + Translations: Add Italian man page translations - tests/test_files.sh | 4 ++-- - 1 file changed, 2 insertions(+), 2 deletions(-) + po4a/it.po | 3876 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ + po4a/po4a.conf | 2 +- + 2 files changed, 3877 insertions(+), 1 deletion(-) -commit aae6a6aeda51cf94a47e39ad624728f9bee75e30 +commit 9b9182e561787a811fc0178489589f28c3e0174c Author: Lasse Collin -Date: 2014-12-30 11:17:16 +0200 +Date: 2025-01-29 22:18:29 +0200 - Update Solaris notes in INSTALL. - - Mention the possible "make check" failure on Solaris in the - Solaris-specific section of INSTALL. It was already in - section 4.5 but it is better mention it in the OS-specific - section too. + Translations: Update the Finnish translation - INSTALL | 4 ++++ - 1 file changed, 4 insertions(+) + po/fi.po | 13 +++++++------ + 1 file changed, 7 insertions(+), 6 deletions(-) -commit 7815112153178800a3521b9f31960e7cdc26cfba +commit 7d73ff7a9d8eab6270f0b1ff7d10c0aa6f5ba53f Author: Lasse Collin -Date: 2014-12-26 12:00:05 +0200 +Date: 2025-01-29 20:50:03 +0200 - Build: POSIX shell isn't required if scripts are disabled. + lzmainfo: Use tuklib_mbstr_wrap for --help text + + Some languages have so long strings that they need to be wrapped. - INSTALL | 3 ++- - configure.ac | 2 +- - 2 files changed, 3 insertions(+), 2 deletions(-) + CMakeLists.txt | 4 ++++ + src/lzmainfo/Makefile.am | 2 ++ + src/lzmainfo/lzmainfo.c | 36 ++++++++++++++++++++++++++---------- + 3 files changed, 32 insertions(+), 10 deletions(-) -commit a0cd05ee71d330b79ead6eb9222e1b24e1559d3a +commit c56eb4707627d700695813fccdddd1483eac4f21 Author: Lasse Collin -Date: 2014-12-21 20:48:37 +0200 +Date: 2025-01-29 20:00:06 +0200 - DOS: Update Makefile. + Translations: Update the Croatian translation - dos/Makefile | 1 + - 1 file changed, 1 insertion(+) + po/hr.po | 926 ++++++++++++++++++++++++++++++++++++--------------------------- + 1 file changed, 529 insertions(+), 397 deletions(-) -commit b85ee0905ec4ab7656d22e63519fdd3bedb21f2e +commit 69f4aec0a2442ab81f9ab66e5871a6546aefb0fc Author: Lasse Collin -Date: 2014-12-21 19:50:38 +0200 +Date: 2025-01-29 19:56:01 +0200 - Windows: Fix bin_i486 to bin_i686 in build.bash. + Translations: Update the Finnish translation - windows/build.bash | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) + po/fi.po | 911 +++++++++++++++++++++++++++++++++------------------------------ + 1 file changed, 483 insertions(+), 428 deletions(-) -commit cbafa710918195dbba3db02c3fab4f0538235206 +commit d49dde33cf5f488bb38b1f57e172c4e3343fb383 Author: Lasse Collin -Date: 2014-12-21 18:58:44 +0200 +Date: 2025-01-29 19:55:27 +0200 - Docs: Use lzma_cputhreads() in 04_compress_easy_mt.c. + Translations: Update the German man page translations - doc/examples/04_compress_easy_mt.c | 30 ++++++++++++++++++++++++++---- - 1 file changed, 26 insertions(+), 4 deletions(-) + po4a/de.po | 147 +++++++++++++++++++++++-------------------------------------- + 1 file changed, 55 insertions(+), 92 deletions(-) -commit 8dbb57238d372c7263cfeb3e7f7fd9a73173156a +commit 23b99fc4a1f35bec5d63ffd02b14cacbdce9fe3c Author: Lasse Collin -Date: 2014-12-21 18:56:44 +0200 +Date: 2025-01-29 19:55:17 +0200 - Docs: Update docs/examples/00_README.txt. + Translations: Update the German translation - doc/examples/00_README.txt | 4 ++++ - 1 file changed, 4 insertions(+) + po/de.po | 825 +++++++++++++++++++++++++++++++++++---------------------------- + 1 file changed, 460 insertions(+), 365 deletions(-) -commit 6060f7dc76fd6c2a8a1f8e85d0e4d86bb78273e6 +commit 7edab2bde0606b42229d9c04fe664069e38de3fb Author: Lasse Collin -Date: 2014-12-21 18:11:17 +0200 +Date: 2025-01-29 19:55:05 +0200 - Bump version and soname for 5.2.0. - - I know that soname != app version, but I skip AGE=1 - in -version-info to make the soname match the liblzma - version anyway. It doesn't hurt anything as long as - it doesn't conflict with library versioning rules. + Translations: Update the Turkish translation - src/liblzma/Makefile.am | 2 +- - src/liblzma/api/lzma/version.h | 6 +++--- - src/liblzma/liblzma.map | 2 +- - 3 files changed, 5 insertions(+), 5 deletions(-) + po/tr.po | 892 +++++++++++++++++++++++++++++++++++---------------------------- + 1 file changed, 490 insertions(+), 402 deletions(-) -commit 3e8bd1d15e417f2d588e9be50ce027ee3d48b2da +commit fac4d0fa5277d7a1f621707621ee9516f0bdbac5 Author: Lasse Collin -Date: 2014-12-21 18:05:03 +0200 +Date: 2025-01-29 19:54:36 +0200 - Avoid variable-length arrays in the debug programs. + Translations: Add the Dutch translation - debug/full_flush.c | 3 ++- - debug/sync_flush.c | 3 ++- - 2 files changed, 4 insertions(+), 2 deletions(-) + po/LINGUAS | 1 + + po/nl.po | 1268 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ + 2 files changed, 1269 insertions(+) -commit 72f7307cfdceb941aeb2bf30d424cc0d13621786 +commit abe5092f24b55dde9f7f78fac1bf810bce173273 Author: Lasse Collin -Date: 2014-12-21 18:01:45 +0200 +Date: 2025-01-29 19:53:50 +0200 - Build: Include 04_compress_easy_mt.c in the tarball. + Translations: Update the Georgian translation - Makefile.am | 1 + - 1 file changed, 1 insertion(+) + po/ka.po | 153 +++++++++++++++++++++++++++++++++++++++++++++++---------------- + 1 file changed, 115 insertions(+), 38 deletions(-) -commit 2cb82ff21c62def11f3683a8bb0aaf363102aaa0 +commit b97b23c78d8100eec363c3e999c511560366d347 Author: Lasse Collin -Date: 2014-12-21 18:00:38 +0200 +Date: 2025-01-29 19:53:21 +0200 - Fix build when --disable-threads is used. + Translations: Update the Spanish translation - src/common/mythread.h | 2 ++ - 1 file changed, 2 insertions(+) + po/es.po | 824 ++++++++++++++++++++++++++++++++++----------------------------- + 1 file changed, 450 insertions(+), 374 deletions(-) -commit 9b9e3536e458ef958f66b0e8982efc9d36de4d17 -Author: Adrien Nader -Date: 2014-12-21 15:56:15 +0100 +commit c68318cb49e0562bd22e88724ce85e76c6789a3a +Author: Lasse Collin +Date: 2025-01-29 19:53:06 +0200 - po/fr: improve wording for help for --lzma1/--lzma2. + Translations: Update the Korean translation - po/fr.po | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) + po/ko.po | 785 +++++++++++++++++++++++++++++++++++++-------------------------- + 1 file changed, 460 insertions(+), 325 deletions(-) -commit a8b6b569e7fadbf5b5b9139d53bc764015c15027 -Author: Adrien Nader -Date: 2014-12-21 15:55:48 +0100 +commit 153ee17f635962a474499f786ea1de1e1a2bb276 +Author: Lasse Collin +Date: 2025-01-29 19:52:42 +0200 - po/fr: missing line in translation of --extreme. + Translations: Update the Romanian man page translations - po/fr.po | 1 + - 1 file changed, 1 insertion(+) + po4a/ro.po | 141 +++++++++++++++++++++++-------------------------------------- + 1 file changed, 54 insertions(+), 87 deletions(-) -commit f168a6fd1a888cf4f0caaddcafcb21dadc6ab6e9 +commit 6ed308197e1f9d6c7a5cfe5aae301e75544017c4 Author: Lasse Collin -Date: 2014-12-21 14:32:33 +0200 +Date: 2025-01-29 19:51:59 +0200 - Update NEWS for 5.2.0. + Translations: Update the Romanian translation - NEWS | 65 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ - 1 file changed, 65 insertions(+) + po/ro.po | 818 +++++++++++++++++++++++++++++++++++---------------------------- + 1 file changed, 461 insertions(+), 357 deletions(-) -commit cec2ee863b3a88f4bf039cb00f73c4a4fc93a429 +commit 06028803e19219f642aa9abddd3525c43594ec6c Author: Lasse Collin -Date: 2014-12-21 14:32:22 +0200 +Date: 2025-01-29 19:50:50 +0200 - Update NEWS for 5.0.8. + Translations: Update the Ukrainian man page translations - NEWS | 12 ++++++++++++ - 1 file changed, 12 insertions(+) + po4a/uk.po | 142 +++++++++++++++++++++++-------------------------------------- + 1 file changed, 54 insertions(+), 88 deletions(-) -commit 42e97a32649bf53ce43be2258b902a417c6e7fa1 +commit 8cbaf896a65a53c1d1e7e2ffc80d6ea216b1e8df Author: Lasse Collin -Date: 2014-12-21 14:07:54 +0200 +Date: 2025-01-29 19:50:26 +0200 - xz: Fix a comment. + Translations: Update the Ukrainian translation - src/xz/options.c | 4 ++-- - 1 file changed, 2 insertions(+), 2 deletions(-) + po/uk.po | 813 ++++++++++++++++++++++++++++++++++++--------------------------- + 1 file changed, 460 insertions(+), 353 deletions(-) -commit 29b95d5d6665cedffa6a9d6d3d914f981e852182 +commit 81c352907b8048b97d9868947026701a49f377ef Author: Lasse Collin -Date: 2014-12-20 20:43:14 +0200 +Date: 2025-01-29 19:48:43 +0200 - Update INSTALL about the dependencies of the scripts. + Translations: Update the Swedish translation - INSTALL | 15 ++++++++++----- - 1 file changed, 10 insertions(+), 5 deletions(-) + po/sv.po | 847 ++++++++++++++++++++++++++++++++++----------------------------- + 1 file changed, 462 insertions(+), 385 deletions(-) -commit 3af91040bb42c21afbb81f5568c3313125e61192 +commit 999ce263718a52ba74245c3e2a416ab11494d1b1 Author: Lasse Collin -Date: 2014-12-20 20:42:33 +0200 +Date: 2025-01-28 16:33:32 +0200 - Windows: Update build instructions. + tuklib_physmem: Clean up disabled code - INSTALL | 15 +++++++++------ - windows/INSTALL-Windows.txt | 44 +++++++++++++++++++++----------------------- - 2 files changed, 30 insertions(+), 29 deletions(-) + src/common/tuklib_physmem.c | 9 +-------- + 1 file changed, 1 insertion(+), 8 deletions(-) -commit 0152f72bf6289d744823dc6c849538f3a139ad70 +commit 4d7e7c9d94f7a5ad4931a5bbd6ed9d00173fa1ab Author: Lasse Collin -Date: 2014-12-20 20:41:48 +0200 +Date: 2025-01-28 16:28:18 +0200 - Windows: Update the build script and README-Windows.txt. + Windows: Avoid an error message on broken pipe + + Also make xz not process more input files after a broken pipe has + been detected. This matches the behavior on POSIX. If all files + are being written to standard output, trying with the next file is + pointless when it's known that standard output won't accept more data. + + xzdec already stopped after the first error. It does so with all + errors, so it differs from xz: - The 32-bit build is now for i686 or newer because the - prebuilt MinGW-w64 toolchains include i686 code in the - executables even if one uses -march=i486. + $ xz -dc not_found_1 not_found_2 + xz: not_found_1: No such file or directory + xz: not_found_2: No such file or directory - The build script builds 32-bit SSE2 enabled version too. - Run-time detection of SSE2 support would be nice (on any OS) - but it's not implemented in XZ Utils yet. + $ xzdec not_found_1 not_found_2 + xzdec: not_found_1: No such file or directory + + Reported-by: Vincent Torri - windows/README-Windows.txt | 30 ++++++++++++++++-------------- - windows/build.bash | 23 ++++++++++++++--------- - 2 files changed, 30 insertions(+), 23 deletions(-) + src/xz/file_io.c | 13 +++++++++++++ + src/xzdec/xzdec.c | 11 ++++++++++- + 2 files changed, 23 insertions(+), 1 deletion(-) -commit 4a1f6133ee5533cee8d91e06fcc22443e5f1881a +commit 95b638480aa8203e547c709c651f421c22db1718 Author: Lasse Collin -Date: 2014-12-19 15:51:50 +0200 +Date: 2025-01-23 19:59:17 +0200 - Windows: Define TUKLIB_SYMBOL_PREFIX in config.h. - - It is to keep all symbols in the lzma_ namespace. + doc/SHA256SUMS: Add 5.6.4 and 5.7.1alpha - windows/config.h | 3 +++ - 1 file changed, 3 insertions(+) + doc/SHA256SUMS | 9 +++++++++ + 1 file changed, 9 insertions(+) -commit 7f7d093de79eee0c7dbfd7433647e46302f19f82 +commit cdae0df31e4c2dfb1e885941cd1998e5a2b6e39d Author: Lasse Collin -Date: 2014-12-16 21:00:09 +0200 +Date: 2025-01-23 11:50:42 +0200 - xz: Update the man page about --threads. + Bump version and soname for 5.7.1alpha - src/xz/xz.1 | 5 ----- - 1 file changed, 5 deletions(-) + src/liblzma/Makefile.am | 2 +- + src/liblzma/api/lzma/version.h | 2 +- + src/liblzma/liblzma_generic.map | 2 +- + src/liblzma/liblzma_linux.map | 2 +- + 4 files changed, 4 insertions(+), 4 deletions(-) -commit 009823448b82aa5f465668878a544c5842885407 +commit 4d2af2c43bae25ef4ef9cd88304471d4859aa322 Author: Lasse Collin -Date: 2014-12-16 20:57:43 +0200 +Date: 2025-01-23 11:48:43 +0200 - xz: Update the man page about --block-size. + Translations: Run po4a/update-po - src/xz/xz.1 | 41 +++++++++++++++++++++++++++++++++-------- - 1 file changed, 33 insertions(+), 8 deletions(-) + po4a/de.po | 64 +++++++++++++++++++++++++++++++++++++++++++++++++---------- + po4a/fr.po | 57 +++++++++++++++++++++++++++++++++++++++++++++++----- + po4a/ko.po | 64 +++++++++++++++++++++++++++++++++++++++++++++++++---------- + po4a/pt_BR.po | 57 +++++++++++++++++++++++++++++++++++++++++++++++----- + po4a/ro.po | 64 +++++++++++++++++++++++++++++++++++++++++++++++++---------- + po4a/uk.po | 64 +++++++++++++++++++++++++++++++++++++++++++++++++---------- + 6 files changed, 320 insertions(+), 50 deletions(-) -commit 7dddfbeb499e528940bc12047355c184644aafe9 -Author: Adrien Nader -Date: 2014-12-10 22:26:57 +0100 +commit ff0b825505e60e21b32e33c42f551c8f34ba393f +Author: Lasse Collin +Date: 2025-01-23 11:40:46 +0200 - po/fr: several more translation updates: reword and handle --ignore-check. + Add NEWS for 5.7.1alpha - po/fr.po | 50 ++++++++++++++++++++++++++------------------------ - 1 file changed, 26 insertions(+), 24 deletions(-) + NEWS | 107 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ + 1 file changed, 107 insertions(+) -commit 6eca5be40e04ddc4b738d493e4e56835956d8b69 -Author: Adrien Nader -Date: 2014-12-10 22:23:01 +0100 +commit f6cd3e3bfc8d1f5a76dd55170968bf4582b95baf +Author: Lasse Collin +Date: 2025-01-23 11:40:46 +0200 - po/fr: yet another place where my email address had to be updated. + Add NEWS for 5.6.4 - po/fr.po | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) + NEWS | 45 +++++++++++++++++++++++++++++++++++++++++++++ + 1 file changed, 45 insertions(+) -commit d1003673e92ba47edd6aeeb3dbea05c18269d0e7 -Author: Adrien Nader -Date: 2014-12-10 22:22:20 +0100 +commit b3af3297e4d6cf0eafb48155aa97bb06c82a9228 +Author: Lasse Collin +Date: 2025-01-23 11:40:46 +0200 - po/fr: fix several typos that have been around since the beginning. + NEWS: The security fix in 5.6.3 is known as CVE-2024-47611 - po/fr.po | 22 +++++++++++----------- - 1 file changed, 11 insertions(+), 11 deletions(-) + NEWS | 4 +++- + 1 file changed, 3 insertions(+), 1 deletion(-) -commit 4c5aa911a0df027e46171e368debc543d2fa72b2 -Author: Adrien Nader -Date: 2014-12-03 20:02:31 +0100 +commit a04b9dd0c7c74fabd8c393d2dc68a221276d6e29 +Author: Lasse Collin +Date: 2025-01-22 16:55:09 +0200 - po/fr: last batch of new translations for now. + windows/build.bash: Fix error message - Four new error messages. + Fixes: 1ee716f74085223c8fbcae1d5a384e6bf53c0f6a - po/fr.po | 16 ++++++++-------- - 1 file changed, 8 insertions(+), 8 deletions(-) + windows/build.bash | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) -commit 3e3099e36d27059499e7996fb38a62e8ab01d356 -Author: Adrien Nader -Date: 2014-12-03 20:01:32 +0100 +commit 4eae859ae8ad7072eaa74aeaee79a2c3c12c55cb +Author: Lasse Collin +Date: 2025-01-22 15:03:55 +0200 - po/fr: translations for --threads, --block-size and --block-list. + Windows: Disable MinGW-w64's stdio functions in size-optimized builds + + This only affects builds with UCRT. With legacy MSVCRT, the replacement + functions are always enabled. + + Omitting the MinGW-w64 replacements saves over 20 KiB per executable. + The downside is that --enable-small or XZ_SMALL=ON disables thousand + separator support in xz messages. If someone is OK with the slower + speed of slightly smaller builds, lack of thousand separators won't + matter. + + Don't override __USE_MINGW_ANSI_STDIO if it is already defined (via + CPPFLAGS or such method). - po/fr.po | 12 ++++++++---- - 1 file changed, 8 insertions(+), 4 deletions(-) + src/common/sysdefs.h | 30 +++++++++++++++++++++--------- + src/xz/util.c | 6 +++++- + 2 files changed, 26 insertions(+), 10 deletions(-) -commit e7d96a5933eec4e9d4a62569ee88df0ebb0f1d53 -Author: Adrien Nader -Date: 2014-12-03 20:00:53 +0100 +commit a831bc185bdd44c06847eae8df2d35cc281f65da +Author: Lasse Collin +Date: 2025-01-20 16:44:27 +0200 - po/fr: remove fuzzy marker for error messages that will be kept in English. + liblzma: Add raw ARM64, RISC-V, and x86 BCJ filter APIs - The following is a copy of a comment inside fr.po: + Put them behind the LZMA_UNSTABLE macro for now. - Note from translator on "file status flags". - The following entry is kept un-translated on purpose. It is difficult to - translate and should only happen in exceptional circumstances which means - that translating would: - - lose some of the meaning - - make it more difficult to look up in search engines; it might happen one - in - a million times, if we dilute the error message in 20 languages, it will be - almost impossible to find an explanation and support for the error. + These low-level special APIs might become useful in erofs-utils. - po/fr.po | 22 ++++++++++++++++------ - 1 file changed, 16 insertions(+), 6 deletions(-) + src/liblzma/api/lzma/bcj.h | 99 +++++++++++++++++++++++++++++++++++++++++ + src/liblzma/common/common.h | 2 + + src/liblzma/liblzma_generic.map | 10 +++++ + src/liblzma/liblzma_linux.map | 10 +++++ + src/liblzma/simple/arm64.c | 18 ++++++++ + src/liblzma/simple/riscv.c | 18 ++++++++ + src/liblzma/simple/x86.c | 24 ++++++++++ + 7 files changed, 181 insertions(+) -commit 46cbb9033af8a21fafe543302d6919746e0d72af -Author: Adrien Nader -Date: 2014-12-03 19:58:25 +0100 +commit 6f5cdd4534faf7db4b6c123651d6a606bc59b98c +Author: Lasse Collin +Date: 2025-01-20 16:31:49 +0200 - po/fr: several minor updates and better wording. + xz: Unify a few strings with liblzma - Meaning doesn't change at all: it's only for better wording and/or - formatting of a few strings. + Avoid having both "%s: foo" and "foo" as translatable strings + so that translators don't need to handle it twice. - po/fr.po | 14 +++++++------- - 1 file changed, 7 insertions(+), 7 deletions(-) + src/xz/options.c | 11 ++++++----- + src/xz/util.c | 4 ++-- + 2 files changed, 8 insertions(+), 7 deletions(-) -commit 7ce49d444f04e73145f79c832eb4d510594b074a -Author: Adrien Nader -Date: 2014-12-03 19:56:12 +0100 +commit 713fdaa8b06a83f18b06811aba7b9bd7b7cbf1cb +Author: Lasse Collin +Date: 2025-01-20 16:31:49 +0200 + + xz: Translate error messages from lzma_str_to_filters() + + liblzma doesn't use gettext but the messages are included in xz.pot, + so xz can translate the messages. - po/fr: update my email address and copyright years. + src/xz/coder.c | 9 +++------ + 1 file changed, 3 insertions(+), 6 deletions(-) - po/fr.po | 4 ++-- - 1 file changed, 2 insertions(+), 2 deletions(-) +commit f2e2b267cab8d7aa0b0a58c325546ee5070c0028 +Author: Lasse Collin +Date: 2025-01-20 16:31:49 +0200 + + liblzma: Mark string conversion messages as translatable -commit 214c553ebc3047cd720da1ce5c80cf7c38118d3c -Author: Adrien Nader -Date: 2014-11-26 10:08:26 +0100 + po/POTFILES.in | 1 + + src/liblzma/common/string_conversion.c | 96 ++++++++++++++++++++-------------- + 2 files changed, 59 insertions(+), 38 deletions(-) + +commit f49d7413d9a0d480ded6d448c1ef7475ae6cd1c9 +Author: Lasse Collin +Date: 2025-01-20 16:31:35 +0200 - fr.po: commit file after only "update-po" so actual is readable. + liblzma: Tweak a few error messages in lzma_str_to_filters() - po/fr.po | 311 ++++++++++++++++++++++++++++++++++++++++----------------------- - 1 file changed, 199 insertions(+), 112 deletions(-) + src/liblzma/common/string_conversion.c | 9 +++++---- + 1 file changed, 5 insertions(+), 4 deletions(-) -commit 1190c641af09cde85f8bd0fbe5c4906f4a29431b +commit da359c360e986b21cd8d7b888c6a80f56b9d49c7 Author: Lasse Collin -Date: 2014-12-02 20:04:07 +0200 +Date: 2025-01-19 20:11:54 +0200 - liblzma: Document how lzma_mt.block_size affects memory usage. + Update THANKS - src/liblzma/api/lzma/container.h | 4 ++++ - 1 file changed, 4 insertions(+) + THANKS | 1 + + 1 file changed, 1 insertion(+) -commit e4fc1d2f9571fba79ce383595be2ea2a9257def0 +commit f032373561cefaf07f92ffe3fbc471ec6770456e Author: Lasse Collin -Date: 2014-11-28 20:07:18 +0200 +Date: 2025-01-19 19:40:32 +0200 - Update INSTALL about a "make check" failure in test_scripts.sh. + Update THANKS - INSTALL | 24 +++++++++++++++++------- - 1 file changed, 17 insertions(+), 7 deletions(-) + THANKS | 1 + + 1 file changed, 1 insertion(+) -commit 34f9e40a0a0c3bd2c2730cdb9cd550bbb8a3f2fe +commit 51f038f8cbd5d8a95954c05bfcbbc32f2a313615 Author: Lasse Collin -Date: 2014-11-26 20:12:27 +0200 +Date: 2025-01-13 08:44:58 +0200 - Remove LZMA_UNSTABLE macro. + liblzma: memcmplen.h: Use 8-byte method on 64-bit unaligned archs + + Previously it was enabled only on x86-64 and ARM64 when also support + for unaligned access was detected or manually enabled at built time. + + In the default build configuration, the 8-byte method is now enabled + also on 64-bit RISC-V and 64-bit PowerPC (both endiannesses). It was + reported that on big endian POWER9, encoding time may reduce 12-13 %. + + This change only affects builds with GCC and Clang because the code + uses __builtin_ctzll or __builtin_clzll. + + Thanks to Marcus Comstedt for testing on POWER9. - src/liblzma/api/lzma/container.h | 4 ---- - src/liblzma/common/common.h | 2 -- - src/xz/private.h | 1 - - 3 files changed, 7 deletions(-) + src/liblzma/common/memcmplen.h | 3 +-- + 1 file changed, 1 insertion(+), 2 deletions(-) -commit 6d9c0ce9f2677b159e32b224aba5b535b304a705 +commit 96336b0110d47756a9fd2a103fbf0a99e905fbed Author: Lasse Collin -Date: 2014-11-26 20:10:33 +0200 +Date: 2025-01-12 13:06:17 +0200 - liblzma: Update lzma_stream_encoder_mt() API docs. + Update THANKS - src/liblzma/api/lzma/container.h | 5 +++-- - 1 file changed, 3 insertions(+), 2 deletions(-) + THANKS | 1 + + 1 file changed, 1 insertion(+) -commit 2301f3f05dd9742f42cda8f0f318864f5dc39ab3 +commit 150356207c8d6a3e0af465b676430d19d62f884c Author: Lasse Collin -Date: 2014-11-25 12:32:05 +0200 +Date: 2025-01-12 12:59:20 +0200 - liblzma: Verify the filter chain in threaded encoder initialization. + liblzma: Fix the encoder breakage on big endian ARM64 - This way an invalid filter chain is detected at the Stream - encoder initialization instead of delaying it to the first - call to lzma_code() which triggers the initialization of - the actual filter encoder(s). + When the 8-byte method was enabled for ARM64, a check for endianness + wasn't added. This broke the LZMA/LZMA2 encoder. Test suite caught it. + + Fixes: cd64dd70d5665b6048829c45772d08606f44672e + Co-authored-by: Marcus Comstedt - src/liblzma/common/stream_encoder_mt.c | 9 ++++++--- - 1 file changed, 6 insertions(+), 3 deletions(-) + src/liblzma/common/memcmplen.h | 9 +++++++-- + 1 file changed, 7 insertions(+), 2 deletions(-) -commit 107a263d5bb63cd3593fd6a5c938706539f84523 +commit b01b0958025a2da284b53a583f313f8140636cb5 Author: Lasse Collin -Date: 2014-11-17 19:11:49 +0200 +Date: 2025-01-12 11:04:27 +0200 - Build: Update m4/ax_pthread.m4 from Autoconf Archive. + Windows: Update manifest comments about long UTF-8 filenames - m4/ax_pthread.m4 | 71 +++++++++++++++++++++++++++++++++++++------------------- - 1 file changed, 47 insertions(+), 24 deletions(-) + src/common/w32_application.manifest.comments.txt | 23 +++++++++++++++-------- + 1 file changed, 15 insertions(+), 8 deletions(-) -commit b13a781833399ff5726cfc997f3cb2f0acbdbf31 +commit 0dfc67d37ebb038be8a9b17b536d1b561d52e81a Author: Lasse Collin -Date: 2014-11-17 18:52:21 +0200 +Date: 2025-01-12 10:47:58 +0200 - Build: Replace obsolete AC_HELP_STRING with AS_HELP_STRING. + Windows: Update build.bash and its README-Windows.txt to UCRT + + While MSVCRT builds are possible, UCRT works better with UTF-8. + A 32-bit build is included still but hopefully it's not actually + needed anymore. - configure.ac | 36 ++++++++++++++++++------------------ - m4/tuklib_integer.m4 | 2 +- - 2 files changed, 19 insertions(+), 19 deletions(-) + windows/README-Windows.txt | 17 ++++++++--------- + windows/build.bash | 20 ++++++++++++++------ + 2 files changed, 22 insertions(+), 15 deletions(-) -commit 542cac122ed3550148a2af0033af22b757491378 +commit 7b3eb2db6c4ba24b5eb438e58ab1ca57e14e59c2 Author: Lasse Collin -Date: 2014-11-17 18:43:19 +0200 +Date: 2025-01-10 13:11:40 +0200 - Build: Fix Autoconf warnings about escaped backquotes. + Translations: Update Serbian translation - Thanks to Daniel Richard G. for pointing out that it's - good to sometimes run autoreconf -fi with -Wall. + I rewrapped a few overlong lines. Those edits aren't in the + Translation Project. Automatic wrapping in the master branch + means that these strings need to be updated soon anyway. - configure.ac | 7 +++---- - 1 file changed, 3 insertions(+), 4 deletions(-) + po/sr.po | 346 ++++++++++++++++++++++----------------------------------------- + 1 file changed, 121 insertions(+), 225 deletions(-) -commit 7b03a15cea8cd4f19ed680b51c4bcbae3ce4142f +commit 950da11ce09c90412dcbca29689575037640667a Author: Lasse Collin -Date: 2014-11-10 18:54:40 +0200 +Date: 2025-01-08 19:26:29 +0200 - xzdiff: Use mkdir if mktemp isn't available. + Build: Use --sort=name in TAR_OPTIONS + + Use also LC_COLLATE=C to make the sorting locale-independent. + Sorting makes the file order reproducible. - src/scripts/xzdiff.in | 17 ++++++++++++++++- - 1 file changed, 16 insertions(+), 1 deletion(-) + Makefile.am | 3 ++- + 1 file changed, 2 insertions(+), 1 deletion(-) -commit f8c13e5e3609581d5dd9f8777985ca07f2390ad7 +commit 75d91d6b39ea3e2fae8f027dcec01be2dca9594d Author: Lasse Collin -Date: 2014-11-10 18:45:01 +0200 +Date: 2025-01-08 19:08:08 +0200 - xzdiff: Create a temporary directory to hold a temporary file. + xz: Workaround broken O_SEARCH in musl - This avoids the possibility of "File name too long" when - creating a temp file when the input file name is very long. + Testing with musl 1.2.5 and Linux 6.12, O_SEARCH doesn't result + in a file descriptor that works with fsync() although it should work. + See the added comment. - This also means that other users on the system can no longer - see the input file names in /tmp (or whatever $TMPDIR is) - since the temporary directory will have a generic name. This - usually doesn't matter since on many systems one can see - the arguments given to all processes anyway. + The same issue affected gzip --synchronous: - The number X chars to mktemp where increased from 6 to 10. + https://bugs.gnu.org/75405 - Note that with some shells temp files or dirs won't be used at all. + Thanks to Paul Eggert. - src/scripts/xzdiff.in | 10 +++++----- - 1 file changed, 5 insertions(+), 5 deletions(-) + src/xz/file_io.c | 11 +++++++++++ + 1 file changed, 11 insertions(+) -commit 7716dcf9df7f457500cb657314e7a9aea5fedb06 +commit ea92eae122a3ccefa61087f84fd99b417fc9ee3c Author: Lasse Collin -Date: 2014-11-10 15:38:47 +0200 +Date: 2025-01-07 21:34:33 +0200 - liblzma: Fix lzma_mt.preset in lzma_stream_encoder_mt_memusage(). + Revert "xz: O_SEARCH cannot be used for fsync()" - It read the filter chain from a wrong variable. This is a similar - bug that was fixed in 9494fb6d0ff41c585326f00aa8f7fe58f8106a5e. + This reverts commit 4014e2479c7b0273f15bd0c9c017c5fe859b0d8f. + + POSIX-conforming O_SEARCH should allow fsync(). - src/liblzma/common/stream_encoder_mt.c | 3 +-- - 1 file changed, 1 insertion(+), 2 deletions(-) + src/xz/file_io.c | 21 +++++++++++---------- + 1 file changed, 11 insertions(+), 10 deletions(-) -commit 230fa4a605542c84b4178a57381695a0af4e779b +commit 4014e2479c7b0273f15bd0c9c017c5fe859b0d8f Author: Lasse Collin -Date: 2014-11-10 14:49:55 +0200 +Date: 2025-01-05 21:43:11 +0200 - Update THANKS. + xz: O_SEARCH cannot be used for fsync() + + Opening a directory with O_SEARCH results in a file descriptor that can + be used with functions like openat(). Such a file descriptor cannot be + used with fsync(). Use O_RDONLY instead. + + In musl, O_SEARCH becomes Linux-specific O_PATH. A file descriptor + from O_PATH doesn't allow fsync(). + + Seems that it's not possible to fsync() a directory that has write + and search permissions but not read permission. + + Fixes: 2a9e91d796d091740489d951fa7780525e4275f1 - THANKS | 1 + - 1 file changed, 1 insertion(+) + src/xz/file_io.c | 21 ++++++++++----------- + 1 file changed, 10 insertions(+), 11 deletions(-) -commit 4e4ae08bc7c1711e399c9f2d26eb375d39d08101 +commit ad2b57cb477b753293c25a01fc24c7f84ee523c2 Author: Lasse Collin -Date: 2014-10-29 21:28:25 +0200 +Date: 2025-01-05 20:48:28 +0200 - Update .gitignore files. + CI: Make ctest show errors from failed tests - .gitignore | 2 ++ - m4/.gitignore | 3 +++ - 2 files changed, 5 insertions(+) + build-aux/ci_build.bash | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) -commit c923b140b27d1a055db6284e10fd546ad1a7fcdb +commit c405264c031aceaf68dfd1546d6337afcebd48e5 Author: Lasse Collin -Date: 2014-10-29 21:15:35 +0200 +Date: 2025-01-05 20:14:49 +0200 - Build: Prepare to support Automake's subdir-objects. + tuklib_mbstr_nonprint: Preserve the value of errno + + A typical use case is like this: - Due to a bug in Automake, subdir-objects won't be enabled - for now. + printf("%s: %s\n", tuklib_mask_nonprint(filename), strerror(errno)); - http://debbugs.gnu.org/cgi/bugreport.cgi?bug=17354 + tuklib_mask_nonprint() may call mbrtowc() and malloc() which may modify + errno. If errno isn't preserved, the error message might be wrong if + a compiler decides to call tuklib_mask_nonprint() before strerror(). - Thanks to Daniel Richard G. for the original patches. + Fixes: 40e573305535960574404d2eae848b248c95ea7e - configure.ac | 7 ++++++- - src/Makefile.am | 22 +++++++++++++++++++++- - src/liblzma/Makefile.am | 4 ++-- - src/lzmainfo/Makefile.am | 4 ++-- - src/xz/Makefile.am | 10 +++++----- - src/xzdec/Makefile.am | 8 ++++---- - 6 files changed, 40 insertions(+), 15 deletions(-) + src/common/tuklib_mbstr_nonprint.c | 17 ++++++++++++++--- + src/common/tuklib_mbstr_nonprint.h | 4 +++- + 2 files changed, 17 insertions(+), 4 deletions(-) -commit 08c2aa16bea0df82828f665d51fba2e0a5e8997f +commit 2a9e91d796d091740489d951fa7780525e4275f1 Author: Lasse Collin -Date: 2014-10-24 20:09:29 +0300 +Date: 2025-01-05 20:14:49 +0200 - Translations: Update the Italian translation. + xz: Use fsync() before deleting the input file, and add --no-sync + + xz's default behavior is to delete the input file after successful + compression or decompression (unless writing to standard output). + If the system crashes soon after the deletion, it is possible that + the newly written file has not yet hit the disk while the previous + delete operation might have. In that case neither the original file + nor the written file is available. + + Call fsync() on the file. On POSIX systems, sync also the directory + where the file was created. + + Add a new option --no-sync which disables fsync() usage. It can avoid + a (possibly significant) performance penalty when processing many + small files. It's fine to use --no-sync when one knows that the files + are easy to recreate or restore after a system crash. + + Using fsync() after every flush initiated by --flush-timeout was + considered. It wasn't implemented at least for now. + + - --flush-timeout is typically used when writing to stdout. If stdout + is a file, xz cannot (portably) sync the directory of the file. + One would need to create the output file first, sync the directory, + and then run xz with fsync() enabled. + + - If xz --flush-timeout output goes to a file, it's possible to use + a separate script to sync the file, for example, once per minute + while telling xz to flush more frequently. - Thanks to Milo Casagrande. + - Not supporting syncing with --flush-timeout was simpler. + + Portability notes: + + - On systems that lack O_SEARCH (like Linux), "xz dir/file" will now + fail if "dir" cannot be opened for reading. If "dir" still has + write and search permissions (like d-wx------ in "ls -l"), + previously xz would have been able to compress "dir/file" still. + Now it only works if using --no-sync (or --keep or --stdout). + + - and dirname() should be available on all POSIX systems, + and aren't needed on non-POSIX systems. + + - fsync() is available on all POSIX systems. The directory syncing + could be changed to fdatasync() although at least on ext4 it + doesn't seem to make a performance difference in xz's usage. + fdatasync() would need a build system check to support (old) + special cases, for example, MINIX 3.3.0 doesn't have fdatasync() + and Solaris 10 needs -lrt. + + - On native Windows, _commit() is used to replace fsync(). Directory + syncing isn't done and shouldn't be needed. (In Cygwin, fsync() on + directories is a no-op.) + + - DJGPP has fsync() for files. ;-) + + Using fsync() was considered somewhere around 2009 and again in 2016 but + those times the idea was rejected. For comparison, GNU gzip 1.7 (2016) + added the option --synchronous which enables fsync(). + + Co-authored-by: Sebastian Andrzej Siewior + Fixes: https://bugs.debian.org/814089 + Link: https://www.mail-archive.com/xz-devel@tukaani.org/msg00282.html + Closes: https://github.com/tukaani-project/xz/pull/151 - po/it.po | 452 ++++++++++++++++++++++++++++++++++++++------------------------- - 1 file changed, 275 insertions(+), 177 deletions(-) + src/xz/args.c | 14 ++++++ + src/xz/args.h | 2 +- + src/xz/file_io.c | 129 +++++++++++++++++++++++++++++++++++++++++++++++++++++-- + src/xz/file_io.h | 6 +++ + src/xz/message.c | 3 ++ + src/xz/sandbox.c | 5 ++- + src/xz/xz.1 | 24 ++++++++++- + 7 files changed, 177 insertions(+), 6 deletions(-) -commit 2f9f61aa83539c54ff6c118a2693890f0519b3dd +commit 2e28c7145747b3287283f13c9d2becd73a7c4a1f Author: Lasse Collin -Date: 2014-10-18 18:51:45 +0300 +Date: 2024-12-27 09:15:50 +0200 - Translations: Update the Polish translation. - - Thanks to Jakub Bogusz. + xz: Use "goto" for error handling in io_open_dest_real() - po/pl.po | 332 ++++++++++++++++++++++++++++++++++++++++----------------------- - 1 file changed, 214 insertions(+), 118 deletions(-) + src/xz/file_io.c | 20 +++++++++----------- + 1 file changed, 9 insertions(+), 11 deletions(-) -commit 4f9d233f67aea25e532824d11b7642cf7dee7a76 -Author: Andre Noll -Date: 2014-10-14 17:30:30 +0200 +commit 75107217670a97b7b772833669d88c3c2f188e37 +Author: Lasse Collin +Date: 2025-01-05 12:10:05 +0200 - l10n: de.po: Change translator email address. + liblzma: Always validate the first digit of a preset string + + lzma_str_to_filters() may call parse_lzma12_preset() in two ways. The + call from str_to_filters() detects the string type from the first + character(s) and as a side-effect it validates the first digit of + the preset string. So this change makes no difference there. + + However, the call from parse_options() doesn't pre-validate the string. + parse_lzma12_preset() will return an invalid value which is passed to + lzma_lzma_preset() which safely rejects it. The bug still affects the + the error message: + + $ xz --filters=lzma2:preset=X + xz: Error in --filters=FILTERS option: + xz: lzma2:preset=X + xz: ^ + xz: Unsupported preset + + After the fix: - Although the old address is still working, the new one should - be preferred. So this commit changes all three places in de.po - accordingly. + $ xz --filters=lzma2:preset=X + xz: Error in --filters=FILTERS option: + xz: lzma2:preset=X + xz: ^ + xz: Unsupported preset - Signed-off-by: Andre Noll + The ^ now correctly points to the X and not past it because the X itself + is the problematic character. + + Fixes: cedeeca2ea6ada5b0411b2ae10d7a859e837f203 - po/de.po | 6 +++--- - 1 file changed, 3 insertions(+), 3 deletions(-) + src/liblzma/common/string_conversion.c | 4 ++++ + 1 file changed, 4 insertions(+) -commit 00502b2bedad43f0cc167ac17ae0608837ee196b -Author: Andre Noll -Date: 2014-10-14 17:30:29 +0200 +commit 52ff32433734d03befd85a5bf00fba77d6501455 +Author: Lasse Collin +Date: 2025-01-05 11:40:34 +0200 - l10n: de.po: Update German translation + xz: Fix getopt_long argument type in --filters* + + Forgetting the argument (or not using = to separate the option from + the argument) resulted in lzma_str_to_filters() being called with NULL + as input string argument. The function handles it fine but xz passes + the NULL to printf() too: + + $ xz --filters + xz: Error in --filters=FILTERS option: + xz: (null) + xz: ^ + xz: Unexpected NULL pointer argument(s) to lzma_str_to_filters() + + Now it's correct: + + $ xz --filters + xz: option '--filters' requires an argument - Signed-off-by: Andre Noll + The --filters-help option doesn't take any arguments. + + Fixes: 9ded880a0221f4d1256845fc4ab957ffd377c760 + Fixes: d6af7f347077b22403133239592e478931307759 + Fixes: a165d7df1964121eb9df715e6f836a31c865beef - po/de.po | 531 +++++++++++++++++++++++++++++++++------------------------------ - 1 file changed, 281 insertions(+), 250 deletions(-) + src/xz/args.c | 22 +++++++++++----------- + 1 file changed, 11 insertions(+), 11 deletions(-) -commit 706b0496753fb609e69f1570ec603f11162189d1 -Author: Andre Noll -Date: 2014-10-14 17:30:28 +0200 +commit 2655c81b5e92278b0fd51f6537c1116f8349b02a +Author: Lasse Collin +Date: 2025-01-04 20:04:56 +0200 - l10n: de.po: Fix typo: Schießen -> Schließen. + xzdec: Don't leave Landlock file descriptor open for no reason - That's a funny one since "schießen" means to shoot :) + This fix is similar to 48ff3f06521ca326996ab9a04d1b342098960427. - Signed-off-by: Andre Noll + Fixes: d74fb5f060b76db709b50f5fd37490394e52f975 - po/de.po | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) + src/xzdec/xzdec.c | 2 ++ + 1 file changed, 2 insertions(+) -commit 7c32e6a935c3d7ee366abad1679bd5f322f0c7d4 +commit 35df4c2bc0500e60ba9d0d163d37a6d110d6841e Author: Lasse Collin -Date: 2014-10-09 19:42:26 +0300 +Date: 2025-01-04 20:02:18 +0200 - Update THANKS. + xz: Make --single-stream imply --keep + + Suggested by xx on #tukaani on 2024-04-12. - THANKS | 1 + - 1 file changed, 1 insertion(+) + src/xz/args.c | 3 +++ + src/xz/xz.1 | 9 ++++++++- + 2 files changed, 11 insertions(+), 1 deletion(-) -commit 076258cc458f1e705041ac7a729b15ffe8c5214a +commit 6f412814a8019700248229ce972530159a0d9872 Author: Lasse Collin -Date: 2014-10-09 19:41:51 +0300 +Date: 2025-01-04 19:57:07 +0200 - Add support for AmigaOS/AROS to tuklib_physmem(). + Update AUTHORS - Thanks to Fredrik Wikstrom. + The contributions have been rewritten. - m4/tuklib_physmem.m4 | 3 ++- - src/common/tuklib_physmem.c | 7 +++++++ - 2 files changed, 9 insertions(+), 1 deletion(-) + AUTHORS | 2 +- + src/liblzma/check/crc32_arm64.h | 1 - + src/liblzma/check/crc32_fast.c | 1 - + src/liblzma/check/crc_common.h | 1 - + 4 files changed, 1 insertion(+), 4 deletions(-) -commit efa7b0a210e1baa8e128fc98c5443a944c39ad24 +commit 5651d153031a7ee2581cdba9bff658031826cb50 Author: Lasse Collin -Date: 2014-10-09 18:42:14 +0300 +Date: 2025-01-04 15:02:16 +0200 - xzgrep: Avoid passing both -q and -l to grep. + xz: Avoid printf formats like %2$s - The behavior of grep -ql varies: - - GNU grep behaves like grep -q. - - OpenBSD grep behaves like grep -l. + It's a POSIX feature that isn't in standard C. It's not available on + Windows. Even MinGW-w64 with __USE_MINGW_ANSI_STDIO doesn't support + it even though it supports POSIX %'d for thousand separators. - POSIX doesn't make it 100 % clear what behavior is expected. - Anyway, using both -q and -l at the same time makes no sense - so both options simply should never be used at the same time. + Gettext's provides overrides for printf and other functions + which do support the %2$s formats. Translations use them. But xz should + work on Windows without too. - Thanks to Christian Weisgerber. + Fixes: 3e9177fd206d20d6d8acc7d203c25a9ae0549229 - src/scripts/xzgrep.in | 6 ++++-- - 1 file changed, 4 insertions(+), 2 deletions(-) + src/xz/message.c | 51 ++++++++++++++++++++++++++++++++------------------- + 1 file changed, 32 insertions(+), 19 deletions(-) -commit 9c5f76098c9986b48d2fc574a0b764f4cde0c538 -Author: Trần Ngọc Quân -Date: 2014-09-25 09:22:45 +0700 +commit 63b246c90e7677c617faab1d3f6fc5c643b5e7cf +Author: Lasse Collin +Date: 2025-01-04 14:41:37 +0200 - l10n: vi.po: Update Vietnamese translation + tuklib_mbstr_wrap: Add printf format attribute - Signed-off-by: Trần Ngọc Quân + It's supported by GCC 3.x already. - po/vi.po | 136 +++++++++++++++++++++++++++++++++++++++------------------------ - 1 file changed, 84 insertions(+), 52 deletions(-) + src/common/tuklib_common.h | 7 +++++++ + src/common/tuklib_mbstr_wrap.h | 1 + + 2 files changed, 8 insertions(+) -commit c4911f2db36d811896c73c008b4218d8fa9a4730 +commit a7313c01d9b8db71ffb61dc1dd7c4ea928824b4b Author: Lasse Collin -Date: 2014-09-25 18:38:48 +0300 +Date: 2025-01-04 13:44:12 +0200 - Build: Detect supported compiler warning flags better. + xz: Translate a Windows-specific string - Clang and nowadays also GCC accept any -Wfoobar option - but then may give a warning that an unknown warning option - was specified. To avoid adding unsupported warning options, - the options are now tested with -Werror. + Originally I thought that native Windows builds wouldn't be translated + but nowadays at least MSYS2 ships such binaries. + + src/xz/file_io.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit 00eb6073c088be9e7516dfc00a13ef520827b57c +Author: Lasse Collin +Date: 2025-01-02 15:32:10 +0200 + + xz: Use my_landlock.h - Thanks to Charles Diza. + A slightly silly thing is that xz may now query the ABI version up to + three times. We could call my_landlock_ruleset_attr_forbid_all() only + once and cache the result but it didn't seem worth doing. - configure.ac | 5 +++-- - 1 file changed, 3 insertions(+), 2 deletions(-) + CMakeLists.txt | 1 + + src/xz/sandbox.c | 72 ++++++++++---------------------------------------------- + 2 files changed, 13 insertions(+), 60 deletions(-) -commit 76e75522ed6f5c228d55587dee5a997893f6e474 +commit 0fc5a625d7cc4ad51fde9367de088b9ad3bd40f6 Author: Lasse Collin -Date: 2014-09-20 21:01:21 +0300 +Date: 2025-01-02 15:32:10 +0200 - Update NEWS for 5.0.7. + xzdec: Use my_landlock.h - NEWS | 11 +++++++++++ - 1 file changed, 11 insertions(+) + CMakeLists.txt | 1 + + src/xzdec/xzdec.c | 34 ++++++---------------------------- + 2 files changed, 7 insertions(+), 28 deletions(-) -commit d62028b4c1174fc67b6929f126f5eb24c018c700 +commit 38cb8ec9fd70d25fca6b473de44cf61586238552 Author: Lasse Collin -Date: 2014-09-20 19:42:56 +0300 +Date: 2025-01-02 15:32:10 +0200 - liblzma: Fix a portability problem in Makefile.am. - - POSIX supports $< only in inference rules (suffix rules). - Using it elsewhere is a GNU make extension and doesn't - work e.g. with OpenBSD make. + Add my_landlock.h with helper functions to use Linux Landlock - Thanks to Christian Weisgerber for the patch. + This supports up to Landlock ABI version 6. The current code in + xz and xzdec only support up to ABI version 4. - src/liblzma/Makefile.am | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) + src/Makefile.am | 1 + + src/common/my_landlock.h | 141 +++++++++++++++++++++++++++++++++++++++++++++++ + 2 files changed, 142 insertions(+) -commit c35de31d4283edad3e57d37ffe939406542cb7bb +commit 672da29bb3a209a727ae46c0df948d7eea69f2e2 Author: Lasse Collin -Date: 2014-09-14 21:54:09 +0300 +Date: 2025-01-01 18:46:50 +0200 - Bump the version number to 5.1.4beta. + liblzma: Silence warnings from "clang -Wimplicit-fallthrough" - src/liblzma/api/lzma/version.h | 4 ++-- - src/liblzma/liblzma.map | 2 +- - 2 files changed, 3 insertions(+), 3 deletions(-) + src/liblzma/lzma/lzma_decoder.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) -commit e9e097e22cacdaa23e5414fea7913535449cb340 +commit 1a8a1ad9a1e3179ce267baa551fb17b30624b4dd Author: Lasse Collin -Date: 2014-09-14 21:50:13 +0300 +Date: 2025-01-01 15:34:51 +0200 - Update NEWS for 5.0.6 and 5.1.4beta. + Build: Use -Wimplicit-fallthrough=5 when supported + + Now that we have the FALLTHROUGH macro, use the strictest mode with + GCC so that comment-based fallthrough markings are no longer accepted. + + In GCC, -Wextra includes -Wimplicit-fallthrough=3 and + -Wimplicit-fallthrough is the same as -Wimplicit-fallthrough=3. + Thus, the strict mode requires specifying -Wimplicit-fallthrough=5. + + Clang has -Wimplicit-fallthrough which is *not* enabled by -Wextra. + Clang doesn't have a variant that takes an argument. Thus we need + to check for -Wimplicit-fallthrough. Do it before checking for + -Wimplicit-fallthrough=5 so that the latter overrides the former + when using GCC. - NEWS | 50 ++++++++++++++++++++++++++++++++++++++++++++++++++ - 1 file changed, 50 insertions(+) + CMakeLists.txt | 2 ++ + configure.ac | 2 ++ + 2 files changed, 4 insertions(+) -commit 642f856bb8562ab66704b1e01ac7bc08b6d0a663 +commit 94adc996e45cc5cad9352cc3271d3a1a2f5c4c22 Author: Lasse Collin -Date: 2014-09-14 21:02:41 +0300 +Date: 2025-01-01 15:30:50 +0200 - Update TODO. + Replace "Fall through" comments with FALLTHROUGH - TODO | 38 ++++++++++++++++++++++++++++++++++---- - 1 file changed, 34 insertions(+), 4 deletions(-) + src/liblzma/common/alone_decoder.c | 3 +-- + src/liblzma/common/auto_decoder.c | 5 ++--- + src/liblzma/common/block_decoder.c | 6 ++---- + src/liblzma/common/block_encoder.c | 6 ++---- + src/liblzma/common/common.c | 2 +- + src/liblzma/common/file_info.c | 22 +++++++++------------- + src/liblzma/common/index_decoder.c | 9 +++------ + src/liblzma/common/index_encoder.c | 6 ++---- + src/liblzma/common/index_hash.c | 7 +++---- + src/liblzma/common/lzip_decoder.c | 14 +++++--------- + src/liblzma/common/stream_decoder.c | 16 ++++++---------- + src/liblzma/common/stream_decoder_mt.c | 25 +++++++++---------------- + src/liblzma/common/stream_encoder_mt.c | 10 ++++------ + src/liblzma/lzma/lzma2_encoder.c | 9 +++------ + src/xz/args.c | 2 +- + src/xz/list.c | 3 +-- + 16 files changed, 54 insertions(+), 91 deletions(-) -commit 6b5e3b9eff5b8cedb2aac5f524d4d60fc8a48124 +commit f31c3a6647b5a5d056324a9c83e6b2c940ebec22 Author: Lasse Collin -Date: 2014-08-05 22:32:36 +0300 +Date: 2025-01-01 15:08:51 +0200 - xz: Add --ignore-check. + sysdefs.h: Add FALLTHROUGH macro - src/xz/args.c | 7 +++++++ - src/xz/args.h | 1 + - src/xz/coder.c | 10 +++++++++- - src/xz/message.c | 2 ++ - src/xz/xz.1 | 19 +++++++++++++++++++ - 5 files changed, 38 insertions(+), 1 deletion(-) + src/common/sysdefs.h | 9 +++++++++ + 1 file changed, 9 insertions(+) -commit 9adbc2ff373f979c917cdfd3679ce0ebd59f1040 +commit e34dbd6a0ae7a560a5508d51fc0bd142c5a320dc Author: Lasse Collin -Date: 2014-08-05 22:15:07 +0300 +Date: 2025-01-01 15:06:15 +0200 - liblzma: Add support for LZMA_IGNORE_CHECK. + xzdec: Fix language in a comment - src/liblzma/api/lzma/container.h | 24 ++++++++++++++++++++++++ - src/liblzma/common/common.h | 1 + - src/liblzma/common/stream_decoder.c | 14 ++++++++++++-- - 3 files changed, 37 insertions(+), 2 deletions(-) + src/xzdec/xzdec.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) -commit 0e0f34b8e4f1c60ecaec15c2105982381cc9c3e6 +commit 16821252c504071f5c2012e415e59cbf5fb79820 Author: Lasse Collin -Date: 2014-08-05 22:03:30 +0300 +Date: 2025-01-02 13:35:48 +0200 - liblzma: Add support for lzma_block.ignore_check. + Windows: Make NLS require UCRT and gettext-runtime >= 0.23.1 - Note that this slightly changes how lzma_block_header_decode() - has been documented. Earlier it said that the .version is set - to the lowest required value, but now it says that the .version - field is kept unchanged if possible. In practice this doesn't - affect any old code, because before this commit the only - possible .version was 0. + Also remove the recently-added workaround from tuklib_gettext.h. + Requiring a new enough gettext-runtime is cleaner. I guess it's + mostly MSYS2 where xz is built with translation support, so once + MSYS2 has Gettext >= 0.23.1, this requirement shouldn't be a problem + in practice. - src/liblzma/api/lzma/block.h | 50 ++++++++++++++++++++++++------- - src/liblzma/common/block_buffer_encoder.c | 2 +- - src/liblzma/common/block_decoder.c | 18 ++++++++--- - src/liblzma/common/block_encoder.c | 2 +- - src/liblzma/common/block_header_decoder.c | 12 ++++++-- - src/liblzma/common/block_header_encoder.c | 2 +- - src/liblzma/common/block_util.c | 2 +- - 7 files changed, 68 insertions(+), 20 deletions(-) + CMakeLists.txt | 29 ++++++++++++++++++++++++++ + configure.ac | 29 ++++++++++++++++++++++++++ + src/common/tuklib_gettext.h | 51 --------------------------------------------- + 3 files changed, 58 insertions(+), 51 deletions(-) -commit 71e1437ab585b46f7a25f5a131557d3d1c0cbaa2 +commit aa1807ed942579f700a08ab091b796cf04e31aec Author: Lasse Collin -Date: 2014-08-04 19:25:58 +0300 +Date: 2025-01-02 11:52:17 +0200 - liblzma: Use lzma_memcmplen() in the BT3 match finder. + windows/build-with-cmake.bat: Fix ENABLE_NLS to XZ_NLS - I had missed this when writing the commit - 5db75054e900fa06ef5ade5f2c21dffdd5d16141. - - Thanks to Jun I Jin. + Fixes: 29f77c7b707f2458fb047e77497354b195e05b14 - src/liblzma/lz/lz_encoder_mf.c | 5 ++--- - 1 file changed, 2 insertions(+), 3 deletions(-) + windows/build-with-cmake.bat | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) -commit 41dc9ea06e1414ebe8ef52afc8fc15b6e3282b04 +commit ea21c76aa2406ba06ac154fe57741734c04f260f Author: Lasse Collin -Date: 2014-08-04 00:25:44 +0300 +Date: 2024-12-30 11:21:57 +0200 - Update THANKS. + Build: Use git log --pretty=medium when creating ChangeLog + + It's the default in git-log. Specifying it explicitly is good in case + a user has set format.pretty to a different value. - THANKS | 1 + - 1 file changed, 1 insertion(+) + Makefile.am | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) -commit 5dcffdbcc23a68abc3ac3539b30be71bc9b5af84 +commit 08050c0788ce5bac0ffd572e9784a2749c4a13df Author: Lasse Collin -Date: 2014-08-03 21:32:25 +0300 +Date: 2024-12-30 10:51:33 +0200 - liblzma: SHA-256: Optimize the Maj macro slightly. - - The Maj macro is used where multiple things are added - together, so making Maj a sum of two expressions allows - some extra freedom for the compiler to schedule the - instructions. - - I learned this trick from - . + Windows: Update MinGW-w64 + CMake instructions to recommend UCRT - src/liblzma/check/sha256.c | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) + windows/INSTALL-MinGW-w64_with_CMake.txt | 38 +++++++++++++++++++------------- + 1 file changed, 23 insertions(+), 15 deletions(-) -commit a9477d1e0c6fd0e47e637d051e7b9e2a5d9af517 +commit 653732bd6f06d8f465bf353bf6e1c16f1405b906 Author: Lasse Collin -Date: 2014-08-03 21:08:12 +0300 +Date: 2024-12-30 10:51:26 +0200 - liblzma: SHA-256: Optimize the way rotations are done. - - This looks weird because the rotations become sequential, - but it helps quite a bit on both 32-bit and 64-bit x86: - - - It requires fewer instructions on two-operand - instruction sets like x86. - - - It requires one register less which matters especially - on 32-bit x86. + xz man page: Describe the source file deletion in -z and -d options - I hope this doesn't hurt other archs. + The DESCRIPTION section always explained it, and the OPTIONS section + only described the differences to the default behavior. However, new + users in a hurry may skip reading DESCRIPTION. The default behavior + is a bit dangerous, thus it's good to repeat in --compress and + --decompress docs that source file is removed after successful operation. - I didn't invent this idea myself, but I don't remember where - I saw it first. + Fixes: https://github.com/tukaani-project/xz/issues/150 - src/liblzma/check/sha256.c | 17 +++++++++++------ - 1 file changed, 11 insertions(+), 6 deletions(-) + src/xz/xz.1 | 17 ++++++++++++++++- + 1 file changed, 16 insertions(+), 1 deletion(-) -commit 5a76c7c8ee9a0afbeedb1c211db9224260404347 +commit bb79f79b278fd4fb06a0bcd5ab3445c468f9baaf Author: Lasse Collin -Date: 2014-08-03 20:38:13 +0300 +Date: 2024-12-27 21:52:28 +0200 - liblzma: SHA-256: Remove the GCC #pragma that became unneeded. + Build: Set libtool -version-info so that it matches with CMake - The unrolling in the previous commit should avoid the - situation where a compiler may think that an uninitialized - variable might be accessed. - - src/liblzma/check/sha256.c | 5 ----- - 1 file changed, 5 deletions(-) + In the past, they haven't been in sync in development versions + although they (of course) have been in stable releases. -commit 9a096f8e57509775c331950b8351bbca77bdcfa8 + src/liblzma/Makefile.am | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit cf54f70e14c218faf5019ffa2fa769ed73772ee8 Author: Lasse Collin -Date: 2014-08-03 20:33:38 +0300 +Date: 2024-12-28 18:28:56 +0200 - liblzma: SHA-256: Unroll a little more. + CMake/macOS: Use GNU Libtool compatible shared library versioning + + Because this increases the Mach-O compatibility_version, this commit + shouldn't cause any ABI compatibility trouble for existing CMake users + on macOS. This is assuming that they won't later downgrade to an older + liblzma version that was built with CMake before this commit. - This way a branch isn't needed for each operation - to choose between blk0 and blk2, and still the code - doesn't grow as much as it would with full unrolling. + Meson allows customising the Mach-O versioning too. So the three + build systems can be configured to be compatible. - src/liblzma/check/sha256.c | 25 ++++++++++++++++--------- - 1 file changed, 16 insertions(+), 9 deletions(-) + CMakeLists.txt | 51 ++++++++++++++++++++++++++++++++++++++++++++++++--- + 1 file changed, 48 insertions(+), 3 deletions(-) -commit bc7650d87bf27f85f1a2a806dc2db1780e09e6a5 +commit 94e17916689d38bc09bf35e602ed6f6276034b59 Author: Lasse Collin -Date: 2014-08-03 19:56:43 +0300 +Date: 2024-12-28 14:49:45 +0200 - liblzma: SHA-256: Do the byteswapping without a temporary buffer. + CMake: Edit a comment - src/liblzma/check/sha256.c | 13 +------------ - 1 file changed, 1 insertion(+), 12 deletions(-) + CMakeLists.txt | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) -commit 544aaa3d13554e8640f9caf7db717a96360ec0f6 +commit 6b50590725aeae8a2aed06faa3238cb9f8771c1b Author: Lasse Collin -Date: 2014-07-25 22:38:28 +0300 +Date: 2024-12-28 20:39:49 +0200 - liblzma: Use lzma_memcmplen() in normal mode of LZMA. + version.sh: Omit an unwanted dot from development versions + + It printed 5.7.0.alpha instead of 5.7.0alpha. - Two locations were not changed yet because the simplest change - assumes that the initial "len" may be greater than "limit". + Fixes: e7a42cda7c827e016619e8cab15e2faf5d4181ae - src/liblzma/lzma/lzma_encoder_optimum_normal.c | 20 +++++--------------- - 1 file changed, 5 insertions(+), 15 deletions(-) + build-aux/version.sh | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) -commit f48fce093b07aeda95c18850f5e086d9f2383380 +commit f7a248f56e94310a080051c4a709c08514fa48b1 Author: Lasse Collin -Date: 2014-07-25 22:30:38 +0300 +Date: 2024-12-27 16:25:07 +0200 - liblzma: Simplify LZMA fast mode code by using memcmp(). + CMake: Remove a duplicate word from a comment - src/liblzma/lzma/lzma_encoder_optimum_fast.c | 11 +---------- - 1 file changed, 1 insertion(+), 10 deletions(-) + CMakeLists.txt | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) -commit 6bf5308e34e23dede5b301b1b9b4f131dacd9218 +commit 8b7c55d148f4a9b3702207164e862437ddffad33 Author: Lasse Collin -Date: 2014-07-25 22:29:49 +0300 +Date: 2024-12-27 16:23:12 +0200 - liblzma: Use lzma_memcmplen() in fast mode of LZMA. + INSTALL: Document CMAKE_DLL_NAME_WITH_SOVERSION - src/liblzma/lzma/lzma_encoder_optimum_fast.c | 6 +++--- - 1 file changed, 3 insertions(+), 3 deletions(-) + INSTALL | 19 +++++++++++++++++++ + 1 file changed, 19 insertions(+) -commit 353212137e51e45b105a3a3fc2e6879f1cf0d492 +commit 260d5d36203955a7148ae1ab05d0931c942028d5 Author: Lasse Collin -Date: 2014-07-25 21:16:23 +0300 +Date: 2024-12-26 21:27:18 +0200 - Update THANKS. + xz: Fix comments - THANKS | 1 + - 1 file changed, 1 insertion(+) + src/xz/file_io.c | 4 ++-- + src/xz/file_io.h | 4 ++-- + 2 files changed, 4 insertions(+), 4 deletions(-) -commit 5db75054e900fa06ef5ade5f2c21dffdd5d16141 -Author: Lasse Collin -Date: 2014-07-25 21:15:07 +0300 +commit bf6da9a573a780cd1a7fb1728ef55d09e58dad11 +Author: Dexter Castor Döpping +Date: 2024-12-22 13:44:03 +0100 - liblzma: Use lzma_memcmplen() in the match finders. + CMake: Disable unity builds project-wide - This doesn't change the match finder output. + liblzma and xz can't be compiled as a unity/jumbo build because of + redeclarations and type name reuse. The CMake documentation recommends + setting UNITY_BUILD to false in this case. + + This is especially important if we're compiled as a subproject and the + consumer wants to use CMAKE_UNITY_BUILD=ON for the rest of their code + base. + + Closes: https://github.com/tukaani-project/xz/pull/158 - src/liblzma/lz/lz_encoder.c | 13 ++++++++++++- - src/liblzma/lz/lz_encoder_mf.c | 33 +++++++++++---------------------- - 2 files changed, 23 insertions(+), 23 deletions(-) + CMakeLists.txt | 6 ++++++ + 1 file changed, 6 insertions(+) -commit e1c8f1d01f4a4e2136173edab2dc63c71ef038f4 +commit f8c328eed1bf0a0168132025a52116b7735f894c Author: Lasse Collin -Date: 2014-07-25 20:57:20 +0300 +Date: 2024-12-20 08:51:18 +0200 - liblzma: Add lzma_memcmplen() for fast memory comparison. - - This commit just adds the function. Its uses will be in - separate commits. + Windows: Workaround a UTF-8 issue in Gettext's libintl_setlocale() - This hasn't been tested much yet and it's perhaps a bit early - to commit it but if there are bugs they should get found quite - quickly. + See the comment. In this package, locale is set at program startup and + not changed later, so the point (2) in the comment isn't a problem. - Thanks to Jun I Jin from Intel for help and for pointing out - that string comparison needs to be optimized in liblzma. + Fixes: 46ee0061629fb075d61d83839e14dd193337af59 - configure.ac | 13 +++ - src/liblzma/common/Makefile.inc | 1 + - src/liblzma/common/memcmplen.h | 170 ++++++++++++++++++++++++++++++++++++++++ - 3 files changed, 184 insertions(+) + src/common/tuklib_gettext.h | 51 +++++++++++++++++++++++++++++++++++++++++++++ + 1 file changed, 51 insertions(+) -commit 765735cf52e5123586e74a51b9c073b5257f631f +commit 03533906093529701ba91081907d8977991997de Author: Lasse Collin -Date: 2014-07-12 21:10:09 +0300 +Date: 2024-12-20 06:50:36 +0200 - Update THANKS. + Revert "Windows: Use UTF-8 locale when active code page is UTF-8" + + This reverts commit 0d0b574cc45045d6150d397776340c068df59e2a. - THANKS | 1 + - 1 file changed, 1 insertion(+) + src/common/tuklib_gettext.h | 32 ++------------------------------ + 1 file changed, 2 insertions(+), 30 deletions(-) -commit 59da01785ef66c7e62f36e70ca808fd2824bb995 +commit 4b319e05afef4eab2fbafb6223f25d128ec99fce Author: Lasse Collin -Date: 2014-07-12 20:06:08 +0300 +Date: 2024-12-19 18:31:09 +0200 - Translations: Add Vietnamese translation. + xzdec: Use setlocale() instead of tuklib_gettext_setlocale() - Thanks to Trần Ngọc Quân. + xzdec isn't translated and doesn't need libintl on Windows even + when NLS is enabled, thus libintl_setlocale() cannot interfere + with the locale settings. Thus, standard setlocale() works perfectly. + + In the commit 78868b6e, the explanation in the commit message is wrong. + + Fixes: 78868b6ed63fa4c89f73e3dfed27abfb8b0d46db - po/LINGUAS | 1 + - po/vi.po | 1007 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ - 2 files changed, 1008 insertions(+) + src/xzdec/xzdec.c | 9 +++------ + 1 file changed, 3 insertions(+), 6 deletions(-) -commit 17215f751c354852700e7f8592ccf319570a0721 +commit 34b80e282ea76ec793eaedaef58a36c3913dec78 Author: Lasse Collin -Date: 2014-06-29 20:54:14 +0300 +Date: 2024-12-19 19:36:15 +0200 - xz: Update the help message of a few options. + Windows: Revert the setlocale(LC_ALL, ".UTF8") documentation + + Only leave the FindFileFirstA() notes from 20dfca81, reverting + the incorrect setlocale() notes. On Windows, Gettext's + overrides setlocale() with libintl_setlocale() wrapper. I hadn't + noticed this, and thus my conclusions were wrong. - Updated: --threads, --block-size, and --block-list - Added: --flush-timeout + Fixes: 20dfca8171dad4c64785ac61d5b68972c444877b - src/xz/message.c | 18 +++++++++++------- - 1 file changed, 11 insertions(+), 7 deletions(-) + src/common/w32_application.manifest.comments.txt | 21 +-------------------- + 1 file changed, 1 insertion(+), 20 deletions(-) -commit 96864a6ddf91ad693d102ea165f3d7918744d582 +commit 5794cda064ce980450eaa5a4e2c71bd317168ce4 Author: Lasse Collin -Date: 2014-06-18 22:07:06 +0300 +Date: 2024-12-18 17:49:05 +0200 - xz: Use lzma_cputhreads() instead of own copy of tuklib_cpucores(). + tuklib_mbstr_wrap: Silence a warning from Clang + + Fixes: ca529c3f41a4a19a59e2e252e6dd9255f130c634 - src/xz/Makefile.am | 1 - - src/xz/hardware.c | 12 +++++++++--- - 2 files changed, 9 insertions(+), 4 deletions(-) + src/common/tuklib_mbstr_wrap.c | 9 +++++++++ + 1 file changed, 9 insertions(+) -commit a115cc3748482e277f42a968baa3cd266f031dba +commit 16c9796ef970ae349c54fef9a346e394d7cc4c75 Author: Lasse Collin -Date: 2014-06-18 22:04:24 +0300 +Date: 2024-12-18 14:00:09 +0200 - liblzma: Add lzma_cputhreads(). + Update THANKS - src/liblzma/Makefile.am | 8 +++++++- - src/liblzma/api/lzma/hardware.h | 14 ++++++++++++++ - src/liblzma/common/Makefile.inc | 1 + - src/liblzma/common/hardware_cputhreads.c | 22 ++++++++++++++++++++++ - src/liblzma/liblzma.map | 1 + - 5 files changed, 45 insertions(+), 1 deletion(-) + THANKS | 2 ++ + 1 file changed, 2 insertions(+) -commit 3ce3e7976904fbab4e6482bafa442856f77a51fa +commit 3b5c8a1fcab385eed9cc95684223fddd7cf5a053 Author: Lasse Collin -Date: 2014-06-18 19:11:52 +0300 +Date: 2024-12-18 14:00:09 +0200 - xz: Check for filter chain compatibility for --flush-timeout. + Update TODO - This avoids LZMA_PROG_ERROR from lzma_code() with filter chains - that don't support LZMA_SYNC_FLUSH. + Fixes: 5f6dddc6c911df02ba660564e78e6de80947c947 - src/xz/coder.c | 30 +++++++++++++++++++++--------- - 1 file changed, 21 insertions(+), 9 deletions(-) + TODO | 3 --- + 1 file changed, 3 deletions(-) -commit 381ac14ed79e5d38809f251705be8b3193bba417 +commit 22a35e64ce3d331b668f15f858a7bb3da3acc78e Author: Lasse Collin -Date: 2014-06-13 19:21:54 +0300 +Date: 2024-12-18 14:00:09 +0200 - xzgrep: List xzgrep_expected_output in tests/Makefile.am. + lzmainfo: Use tuklib_mbstr_nonprint - tests/Makefile.am | 3 ++- - 1 file changed, 2 insertions(+), 1 deletion(-) + CMakeLists.txt | 3 +++ + src/lzmainfo/Makefile.am | 1 + + src/lzmainfo/lzmainfo.c | 16 ++++++++++------ + 3 files changed, 14 insertions(+), 6 deletions(-) -commit 4244b65b06d5ecaf6f9dd0387ac7e3166bd2364e +commit 03111595ee713e0f94fb4f4a19a15594d5149347 Author: Lasse Collin -Date: 2014-06-13 18:58:22 +0300 +Date: 2024-12-18 14:00:09 +0200 - xzgrep: Improve the test script. - - Now it should be close to the functionality of the original - version by Pavel Raiskup. + xzdec: Use tuklib_mbstr_nonprint - tests/Makefile.am | 3 ++- - tests/test_scripts.sh | 24 ++++++++++++++---------- - tests/xzgrep_expected_output | 39 +++++++++++++++++++++++++++++++++++++++ - 3 files changed, 55 insertions(+), 11 deletions(-) + CMakeLists.txt | 3 +++ + src/xzdec/Makefile.am | 2 ++ + src/xzdec/xzdec.c | 15 +++++++++++---- + 3 files changed, 16 insertions(+), 4 deletions(-) -commit 1e60f2c0a0ee6c18b02943ce56214799a70aac26 +commit d22f96921fd2f94d842f3cc2e5f729cb3cca5122 Author: Lasse Collin -Date: 2014-06-11 21:03:25 +0300 +Date: 2024-12-18 14:00:09 +0200 - xzgrep: Add a test for the previous fix. + xz: Use tuklib_mbstr_nonprint - This is a simplified version of Pavel Raiskup's - original patch. + Call tuklib_mask_nonprint() on filenames and also on a few other + strings from the command line too. + + The filename printed by "xz --robot --list" (in list.c) is also masked. + It's good to get rid of tabs and newlines which would desync the output + but masking other chars wouldn't be strictly necessary. It might matter + with sensible filenames if LC_CTYPE is "C" (when iswprint() might reject + non-ASCII chars) and a script wants to read a filename from xz's output. + Hopefully it's an unusual enough corner case to not be a real problem. - tests/test_scripts.sh | 26 ++++++++++++++++++++++---- - 1 file changed, 22 insertions(+), 4 deletions(-) + CMakeLists.txt | 2 ++ + src/xz/Makefile.am | 1 + + src/xz/coder.c | 19 ++++++++----- + src/xz/file_io.c | 81 ++++++++++++++++++++++++++++++++++-------------------- + src/xz/list.c | 32 +++++++++++++-------- + src/xz/main.c | 10 +++++-- + src/xz/message.c | 8 ++++-- + src/xz/options.c | 10 ++++--- + src/xz/private.h | 1 + + src/xz/suffix.c | 12 ++++---- + 10 files changed, 113 insertions(+), 63 deletions(-) -commit ceca37901783988204caaf40dff4623d535cc789 +commit 40e573305535960574404d2eae848b248c95ea7e Author: Lasse Collin -Date: 2014-06-11 20:43:28 +0300 +Date: 2024-12-18 14:00:09 +0200 - xzgrep: exit 0 when at least one file matches. + Add tuklib_mbstr_nonprint to mask non-printable characters + + Malicious filenames or other untrusted strings may affect the state of + the terminal when such strings are printed as part of (error) messages. + Add functions that mask such characters. - Mimic the original grep behavior and return exit_success when - at least one xz compressed file matches given pattern. + It's not enough to handle only single-byte control characters. + In multibyte locales, some control characters are multibyte too, for + example, terminals interpret C1 control characters (U+0080 to U+009F) + that are two bytes as UTF-8. - Original bugreport: - https://bugzilla.redhat.com/show_bug.cgi?id=1108085 + Instead of checking for control characters with iswcntrl(), this + uses iswprint() to detect printable characters. This is much stricter. + On Windows it's actually too strict as it rejects some characters that + definitely are printable. - Thanks to Pavel Raiskup for the patch. + Gnulib's quotearg would do a lot more but I hope this simpler method + is good enough here. + + Thanks to Ryan Colyer for the discussion about the problems of + the earlier single-byte-only method. + + Thanks to Christian Weisgerber for reporting a bug in an earlier + version of this code. + + Thanks to Jeroen Roovers for a typo fix. + + Closes: https://github.com/tukaani-project/xz/pull/118 - src/scripts/xzgrep.in | 15 +++++++++++++-- - 1 file changed, 13 insertions(+), 2 deletions(-) + src/Makefile.am | 2 + + src/common/tuklib_mbstr_nonprint.c | 151 +++++++++++++++++++++++++++++++++++++ + src/common/tuklib_mbstr_nonprint.h | 69 +++++++++++++++++ + 3 files changed, 222 insertions(+) -commit 8c19216baccb92d011694590df8a1262da2e980c +commit 36190c8c4bb13d1eab84a30f3650a5ec5ff0e402 Author: Lasse Collin -Date: 2014-06-09 21:21:24 +0300 +Date: 2024-12-18 11:33:09 +0200 - xz: Force single-threaded mode when --flush-timeout is used. + Translations: Add preliminary Georgian translation + + Most of the auto-wrapped strings are translated already. A few + strings have changed since this was created though. This file + isn't in the Translation Project *yet* because these strings + are still very new. + + Closes: https://github.com/tukaani-project/xz/pull/145 - src/xz/coder.c | 11 +++++++++++ - 1 file changed, 11 insertions(+) + po/LINGUAS | 1 + + po/ka.po | 1186 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ + 2 files changed, 1187 insertions(+) -commit 87f1a24810805187d7bbc8ac5512e7eec307ddf5 +commit 4a0c4f92b820b84ace625a95305a9d56cb662f4e Author: Lasse Collin -Date: 2014-05-25 22:05:39 +0300 +Date: 2024-10-30 20:50:20 +0200 - Update THANKS. + xz: Make one string simpler for translators + + Leading spaces in the string can get miscounted by translators. - THANKS | 1 + - 1 file changed, 1 insertion(+) + src/xz/list.c | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) -commit da1718f266fcfc091e7bf08aae1bc986d0e6cc6b +commit 3fcf547e926f6c0414b23459f7b43164f7e8c378 Author: Lasse Collin -Date: 2014-05-25 21:45:56 +0300 +Date: 2024-12-17 10:26:10 +0200 - liblzma: Use lzma_alloc_zero() in LZ encoder initialization. - - This avoids a memzero() call for a newly-allocated memory, - which can be expensive when encoding small streams with - an over-sized dictionary. - - To avoid using lzma_alloc_zero() for memory that doesn't - need to be zeroed, lzma_mf.son is now allocated separately, - which requires handling it separately in normalize() too. - - Thanks to Vincenzo Innocente for reporting the problem. + lzmainfo: Sync the translatable strings with xz - src/liblzma/lz/lz_encoder.c | 84 ++++++++++++++++++++++-------------------- - src/liblzma/lz/lz_encoder.h | 2 +- - src/liblzma/lz/lz_encoder_mf.c | 31 +++++++++------- - 3 files changed, 62 insertions(+), 55 deletions(-) + src/lzmainfo/lzmainfo.c | 20 ++++++++++++-------- + 1 file changed, 12 insertions(+), 8 deletions(-) -commit 28af24e9cf2eb259997c85dce13d4c97b3daa47a +commit 3e9177fd206d20d6d8acc7d203c25a9ae0549229 Author: Lasse Collin -Date: 2014-05-25 19:25:57 +0300 +Date: 2024-12-17 10:26:10 +0200 - liblzma: Add the internal function lzma_alloc_zero(). + xz: Use automatic word wrapping for help texts + + --long-help is now one line longer because --lzma1 is now on its + own line. - src/liblzma/common/common.c | 21 +++++++++++++++++++++ - src/liblzma/common/common.h | 6 ++++++ - 2 files changed, 27 insertions(+) + CMakeLists.txt | 2 + + src/xz/Makefile.am | 3 +- + src/xz/message.c | 482 ++++++++++++++++++++++++++++++++++------------------- + 3 files changed, 313 insertions(+), 174 deletions(-) -commit ed9ac85822c490e34b68c259afa0b385d21d1c40 +commit a0eecc9eb23ac583ccf442de3f5c106d4b09482d Author: Lasse Collin -Date: 2014-05-08 18:03:09 +0300 +Date: 2024-12-16 18:46:45 +0200 - xz: Fix uint64_t vs. size_t which broke 32-bit build. + po/Makevars: Add --keyword=W_:... to XGETTEXT_OPTIONS - Thanks to Christian Hesse. + The text was copied from tuklib_gettext.h. + + Also rearrange the --keyword options to be last on the line. - src/xz/coder.c | 2 +- + po/Makevars | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -commit d716acdae3fa7996f9e68a7bac012e6d8d13dd02 +commit ca529c3f41a4a19a59e2e252e6dd9255f130c634 Author: Lasse Collin -Date: 2014-05-04 11:09:11 +0300 +Date: 2024-12-16 18:43:52 +0200 - Docs: Update comments to refer to lzma/lzma12.h in example programs. + Add tuklib_mbstr_wrap for automatic word wrapping + + Automatic word wrapping makes translators' work easier and reduces + errors like misaligned columns or overlong lines. Right-to-left + languages and languages that don't use spaces between words will + still need extra effort. (xz hasn't been translated to any RTL + language so far.) - doc/examples/03_compress_custom.c | 6 +++--- - 1 file changed, 3 insertions(+), 3 deletions(-) + cmake/tuklib_mbstr.cmake | 4 + + m4/tuklib_mbstr.m4 | 2 +- + src/Makefile.am | 2 + + src/common/tuklib_gettext.h | 11 ++ + src/common/tuklib_mbstr_wrap.c | 285 +++++++++++++++++++++++++++++++++++++++++ + src/common/tuklib_mbstr_wrap.h | 203 +++++++++++++++++++++++++++++ + 6 files changed, 506 insertions(+), 1 deletion(-) -commit 4d5b7b3fda31241ca86ed35e08e73f776ee916e0 +commit 314b83cebad0244a0015a8abc6d8d086b581c215 Author: Lasse Collin -Date: 2014-05-04 11:07:17 +0300 +Date: 2024-12-17 17:57:18 +0200 - liblzma: Rename the private API header lzma/lzma.h to lzma/lzma12.h. - - It can be confusing that two header files have the same name. - The public API file is still lzma.h. + Build: Sort filenames to ASCII order in Makefile.am - src/liblzma/api/Makefile.am | 2 +- - src/liblzma/api/lzma.h | 2 +- - src/liblzma/api/lzma/{lzma.h => lzma12.h} | 2 +- - 3 files changed, 3 insertions(+), 3 deletions(-) + src/Makefile.am | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) -commit 1555a9c5664afc7893a2b75e9970105437f01ef1 +commit df399c52554dfdf60259ca2cce97adbcfff39dc0 Author: Lasse Collin -Date: 2014-04-25 17:53:42 +0300 +Date: 2024-10-21 18:51:24 +0300 - Build: Fix the combination of --disable-xzdec --enable-lzmadec. + tuklib_mbstr_width: Add tuklib_mbstr_width_mem() - In this case "make install" could fail if the man page directory - didn't already exist at the destination. If it did exist, a - dangling symlink was created there. Now the link is omitted - instead. This isn't the best fix but it's better than the old - behavior. + It's a new function split from tuklib_mbstr_width(). + It's useful with partial strings that aren't terminated with \0. - src/xzdec/Makefile.am | 10 +++++++++- - 1 file changed, 9 insertions(+), 1 deletion(-) + src/common/tuklib_mbstr.h | 17 +++++++++++++++++ + src/common/tuklib_mbstr_width.c | 8 ++++++++ + 2 files changed, 25 insertions(+) -commit 56056571df3377eaa6ae6233b3ccc5d72e81d43d +commit 51081efae4c52c226e96da95313916eba99f885f Author: Lasse Collin -Date: 2014-04-25 17:44:26 +0300 +Date: 2024-12-16 20:08:27 +0200 - Build: Add --disable-doc to configure. + tuklib_mbstr_width: Update a comment about shift states - INSTALL | 6 ++++++ - Makefile.am | 2 ++ - configure.ac | 6 ++++++ - 3 files changed, 14 insertions(+) + src/common/tuklib_mbstr_width.c | 11 ++++++++--- + 1 file changed, 8 insertions(+), 3 deletions(-) -commit 6de61d8721097a6214810841aa85b08e303ac538 +commit 7ff1b0ac53866877bdfd79acf5fee0269058c58b Author: Lasse Collin -Date: 2014-04-24 18:06:24 +0300 +Date: 2024-10-21 18:47:56 +0300 - Update INSTALL. + tuklib_mbstr_width: Don't mention shift states in the API docs - Add a note about failing "make check". The source of - the problem should be fixed in libtool (if it really is - a libtool bug and not mine) but I'm unable to spend time - on that for now. Thanks to Nelson H. F. Beebe for reporting - the issue. - - Add a note about a possible need to run "ldconfig" after - "make install". + It is assumed that this code won't be used with charsets that use + locking shift states. - INSTALL | 25 +++++++++++++++++++++++++ - 1 file changed, 25 insertions(+) + src/common/tuklib_mbstr.h | 8 ++------ + 1 file changed, 2 insertions(+), 6 deletions(-) -commit 54df428799a8d853639b753d0e6784694d73eb3e +commit 3c16105936320e4095dbe84fa9a33a4a6d46a597 Author: Lasse Collin -Date: 2014-04-09 17:26:10 +0300 +Date: 2024-10-21 18:41:41 +0300 - xz: Rename a variable to avoid a namespace collision on Solaris. - - I don't know the details but I have an impression that there's - no problem in practice if using GCC since people have built xz - with GCC (without patching xz), but renaming the variable cannot - hurt either. + tuklib_mbstr_width: Use stricter return value checking - Thanks to Mark Ashley. + This should make no difference in practice (at least if mbrtowc() + isn't broken). - src/xz/signals.c | 12 +++++++----- - 1 file changed, 7 insertions(+), 5 deletions(-) + src/common/tuklib_mbstr_width.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) -commit 5876ca27daa1429676b1160007d9688266907f00 +commit b797c44c42ea54fe1c52722a2fca0c9618575598 Author: Lasse Collin -Date: 2014-01-29 20:19:41 +0200 +Date: 2024-12-16 20:06:07 +0200 - Docs: Add example program for threaded encoding. + tuklib_mbstr_width: Change the behavior when wcwidth() is not available + + If wcwidth() isn't available (Windows), previously it was assumed + that one byte == one column in the terminal. Now it is assumed that + one multibyte character == one column. This works better with UTF-8. + Languages that only use single-width characters without any combining + characters should work correctly with this. - I didn't add -DLZMA_UNSTABLE to Makefile so one has to - specify it manually as long as LZMA_UNSTABLE is needed. + In xz, none of po/*.po contain combining characters and only ko.po, + zh_CN.po, and zh_TW.po contain fullwidth characters. Thus, "only" + those three translations in xz are broken on Windows with the + UTF-8 code page. Broken means that column headings in xz -lvv and + (only in the master branch) strings in --long-help are misaligned, + so it's not a huge problem. I don't know if those three languages + displayed perfectly before the UTF-8 change because I hadn't tested + translations with native Windows builds before. + + Fixes: 46ee0061629fb075d61d83839e14dd193337af59 - doc/examples/04_compress_easy_mt.c | 184 +++++++++++++++++++++++++++++++++++++ - doc/examples/Makefile | 3 +- - 2 files changed, 186 insertions(+), 1 deletion(-) + src/common/tuklib_mbstr_width.c | 13 +++++++++++-- + 1 file changed, 11 insertions(+), 2 deletions(-) -commit 9494fb6d0ff41c585326f00aa8f7fe58f8106a5e +commit 78868b6ed63fa4c89f73e3dfed27abfb8b0d46db Author: Lasse Collin -Date: 2014-01-29 20:13:51 +0200 +Date: 2024-12-18 14:23:13 +0200 - liblzma: Fix lzma_mt.preset not working with lzma_stream_encoder_mt(). + xzdec: Use setlocale() via tuklib_gettext_setlocale() + + xzdec isn't translated and didn't have locale-specific behavior + in the past. On Windows with UTF-8 in the application manifest, + setting the locale makes a difference though: - It read the filter chain from a wrong variable. + - Without any setlocale() call, non-ASCII filenames don't display + properly in Command Prompt unless one first uses "chcp 65001" + to set the console code page to UTF-8. + + - setlocale(LC_ALL, "") is enough to make non-ASCII filenames + print correctly in Command Prompt without using "chcp 65001", + assuming that the non-UTF-8 code page (like 850) supports + those non-ASCII characters. + + - setlocale(LC_ALL, ".UTF8") is even better because then mbrtowc() and + such functions use an UTF-8 locale instead of a legacy code page. + The tuklib_gettext_setlocale() macro takes care of this (without + enabling any translations). + + Fixes: 46ee0061629fb075d61d83839e14dd193337af59 - src/liblzma/common/stream_encoder_mt.c | 4 ++-- - 1 file changed, 2 insertions(+), 2 deletions(-) + src/xzdec/xzdec.c | 12 ++++++++++++ + 1 file changed, 12 insertions(+) -commit 673a4cb53de3a715685cb1b836da57a3c7dcd43c +commit 0d0b574cc45045d6150d397776340c068df59e2a Author: Lasse Collin -Date: 2014-01-20 11:20:40 +0200 +Date: 2024-12-17 14:59:37 +0200 - liblzma: Fix typo in a comment. + Windows: Use UTF-8 locale when active code page is UTF-8 + + XZ Utils 5.6.3 set the active code page to UTF-8 to fix CVE-2024-47611. + This wasn't paired with UCRT-specific setlocale(LC_ALL, ".UTF8"), thus + non-ASCII characters from translations became mojibake. + + Fixes: 46ee0061629fb075d61d83839e14dd193337af59 - src/liblzma/api/lzma/block.h | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) + src/common/tuklib_gettext.h | 32 ++++++++++++++++++++++++++++++-- + 1 file changed, 30 insertions(+), 2 deletions(-) -commit ad96a871a1470eb76d6233d3890ce9338047b7a3 +commit 20dfca8171dad4c64785ac61d5b68972c444877b Author: Lasse Collin -Date: 2014-01-12 19:38:43 +0200 +Date: 2024-12-17 15:01:29 +0200 - Windows: Add config.h for building liblzma with MSVC 2013. + Windows: Document the need for setlocale(LC_ALL, ".UTF8") - This is for building liblzma. Building xz tool too requires - a little more work. Maybe it will be supported, but for most - MSVC users it's enough to be able to build liblzma. + Also warn about unpaired surrogates and (somewhat UTF-8-specific) + MAX_PATH issue in FindFirstFileA(). - C99 support in MSVC 2013 is almost usable which is a big - improvement over earlier versions. It's "almost" because - there's a dumb bug that breaks mixed declarations after - an "if" statements unless the "if" statement uses braces: + Fixes: 46ee0061629fb075d61d83839e14dd193337af59 + + src/common/w32_application.manifest.comments.txt | 28 +++++++++++++++++++++++- + 1 file changed, 27 insertions(+), 1 deletion(-) + +commit 4e936f234056e5831013ed922145b666b04bb1e3 +Author: Lasse Collin +Date: 2024-12-18 14:12:22 +0200 + + xzdec: Call tuklib_progname_init() early enough - https://connect.microsoft.com/VisualStudio/feedback/details/808650/visual-studio-2013-c99-compiler-bug - https://connect.microsoft.com/VisualStudio/feedback/details/808472/c99-support-of-mixed-declarations-and-statements-fails-with-certain-types-and-constructs + If the early pledge() call on OpenBSD fails, it calls my_errorf() + which requires the "progname" variable. - Hopefully it will get fixed. Then liblzma should be - compilable with MSVC 2013 without patching. + Fixes: d74fb5f060b76db709b50f5fd37490394e52f975 - windows/config.h | 139 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ - 1 file changed, 139 insertions(+) + src/xzdec/xzdec.c | 6 +++--- + 1 file changed, 3 insertions(+), 3 deletions(-) -commit 3d5c090872fab4212b57c290e8ed4d02c78c1737 +commit 61feaf681bd793dc5c919732b44bca7dcf2ed1b8 Author: Lasse Collin -Date: 2014-01-12 17:41:14 +0200 +Date: 2024-12-15 19:08:32 +0200 - xz: Fix a comment. + CMake: Bump maximum policy version to 3.31 + + With CMake 3.31, there were a few warnings from + CMP0177 "install() DESTINATION paths are normalized". + These occurred because the install(FILES) command in + my_install_man_lang() is called with a DESTINATION path + that contains two consecutive slashes, for example, + "share/man//man1". Such a path is for the English man pages. + With translated man pages, the language code goes between + the slashes. The warning was probably triggered because the + extra slash gets removed by the normalization. - src/xz/coder.c | 4 ++-- - 1 file changed, 2 insertions(+), 2 deletions(-) + CMakeLists.txt | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) -commit 69fd4e1c932c7975476a0143c86e45d81b60d3f9 +commit b0bb84dd7bbdcc85243386a0051c7b2cb5fc6a18 Author: Lasse Collin -Date: 2014-01-12 17:04:33 +0200 +Date: 2024-12-15 18:35:27 +0200 - Windows: Add MSVC defines for inline and restrict keywords. + Update THANKS - src/common/sysdefs.h | 10 ++++++++++ - 1 file changed, 10 insertions(+) + THANKS | 1 + + 1 file changed, 1 insertion(+) -commit a19d9e8575ee6647cd9154cf1f20203f1330485f -Author: Lasse Collin -Date: 2014-01-12 16:44:52 +0200 +commit bee0c044d30a6ad3b3d94901c27e7519f6f46e27 +Author: Dexter Castor Döpping +Date: 2024-12-08 18:24:29 +0100 - liblzma: Avoid C99 compound literal arrays. + liblzma: Fix incorrect macro name in a comment - MSVC 2013 doesn't like them. Maybe they aren't so good - for readability either since many aren't used to them. + Fixes: 33b8a24b6646a9dbfd8358405aec466b13078559 + Closes: https://github.com/tukaani-project/xz/pull/155 - src/liblzma/lzma/lzma_encoder_presets.c | 8 +++++--- - 1 file changed, 5 insertions(+), 3 deletions(-) + src/liblzma/api/lzma/lzma12.h | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) -commit e28528f1c867b2ed4ac91195ad08efb9bb8a6263 +commit 2cfa1ad0a9eb62b1847cf13f9aee290158978a3a Author: Lasse Collin -Date: 2014-01-12 12:50:30 +0200 +Date: 2024-12-17 10:36:43 +0200 - liblzma: Remove a useless C99ism from sha256.c. + license-check.sh: Add an exception for doc/SHA256SUMS - Unsurprisingly it makes no difference in compiled output. + Fixes: 36b531022f24a2ab57a2dfb9e5052f1c176e9d9a - src/liblzma/check/sha256.c | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) + build-aux/license-check.sh | 1 + + 1 file changed, 1 insertion(+) -commit 5ad1effc45adfb7dabc9a98e79736077e6b7e2d5 +commit 36b531022f24a2ab57a2dfb9e5052f1c176e9d9a Author: Lasse Collin -Date: 2014-01-12 12:17:08 +0200 +Date: 2024-12-01 21:38:17 +0200 - xz: Fix use of wrong variable. + doc/SHA256SUMS: Add the list of SHA-256 hashes of release files + + The release files are signed but verifying the signatures cannot + catch certain types of attacks: + + 1. A malicious maintainer could make more than one variant of + a package. One could be for general distribution. Another + with malicious content could be targeted to specific users, + for example, distributing the malicious version on a mirror + controlled by the attacker. + + 2. If the signing key of an honest maintainer was compromised + without being detected, a similar situation as described + above could occur. - Since the only call to suffix_set() uses optarg - as the argument, fixing this bug doesn't change - the behavior of the program. + SHA256SUMS could be put on the project website but having it in + the Git repository makes it obvious that old lines aren't modified + when the file is updated. + + Hashes of uncompressed files are included too. This way tarballs + can be recompressed and the hashes can still be verified. - src/xz/suffix.c | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) + .gitattributes | 1 + + doc/SHA256SUMS | 218 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ + 2 files changed, 219 insertions(+) -commit 3e62c68d75b5a3fdd46dbb34bb335d73289860d5 +commit fe9e66993fdbcc2981c7361b9b034a451eb0fc42 Author: Lasse Collin -Date: 2014-01-12 12:11:36 +0200 +Date: 2024-11-30 12:05:59 +0200 - Fix typos in comments. + Docs: Remove .github/SECURITY.md + + One of the reasons to have this file in the xz repository was to + show vulnerability reporting info in the Security section on GitHub. + On 2024-11-25, I added SECURITY.md to the tukaani-project organization + on GitHub: + + https://github.com/tukaani-project/.github/blob/main/SECURITY.md + + GitHub shows that file in all projects in the organization unless + overridden by a project-specific SECURITY.md. Thus, removing + the file from the xz repo makes GitHub show the organization-wide + text instead. + + Maintaining a single copy for the whole GitHub organization makes + things simpler. It's also nicer to have fewer GitHub-specific files + in the xz repo. Information how to report bugs (including security + issues) is available in README and on the home page too. + + The OpenSSF Scorecard tool didn't find .github/SECURITY.md from the + xz repository. There was a suggestion to move the file to the top-level + directory where Scorecard should find it. However, Scorecard does find + the organization-wide SECURITY.md. Thus, the file isn't needed in the + xz repository to score points in the Scorecard game: + + https://scorecard.dev/viewer/?uri=github.com/tukaani-project/xz + + Closes: https://github.com/tukaani-project/xz/issues/148 + Closes: https://github.com/tukaani-project/xz/pull/149 - src/common/mythread.h | 2 +- - src/liblzma/check/crc32_fast.c | 2 +- - 2 files changed, 2 insertions(+), 2 deletions(-) + .github/SECURITY.md | 14 -------------- + 1 file changed, 14 deletions(-) -commit e90ea601fb72867ec04adf456cbe4bf9520fd412 +commit b36177273602ebc83e9cc58517f63a7b6af33f70 Author: Lasse Collin -Date: 2013-11-26 18:20:16 +0200 +Date: 2024-11-30 10:27:14 +0200 - Update THANKS. + Translations: Update the Chinese (traditional) translation - THANKS | 1 + - 1 file changed, 1 insertion(+) + po/zh_TW.po | 201 +++++++++++++++++++++++++----------------------------------- + 1 file changed, 84 insertions(+), 117 deletions(-) -commit b22e94d8d15764416354e04729382a7371ae2c30 +commit c15115f7ede492f20c91b08ba485f9426f60233f Author: Lasse Collin -Date: 2013-11-26 18:20:09 +0200 +Date: 2024-10-30 19:54:34 +0200 - liblzma: Document the need for block->check for lzma_block_header_decode(). + liblzma: Optimize the loop conditions in BCJ filters - Thanks to Tomer Chachamu. + Compilers cannot optimize the addition "i + 4" away since theoretically + it could overflow. - src/liblzma/api/lzma/block.h | 3 +++ - 1 file changed, 3 insertions(+) + src/liblzma/simple/arm.c | 4 +++- + src/liblzma/simple/arm64.c | 4 +++- + src/liblzma/simple/armthumb.c | 7 ++++++- + src/liblzma/simple/ia64.c | 4 +++- + src/liblzma/simple/powerpc.c | 4 +++- + src/liblzma/simple/sparc.c | 5 +++-- + 6 files changed, 21 insertions(+), 7 deletions(-) -commit d1cd8b1cb824b72421d1ee370e628024d2fcbec4 +commit 9f69e71e78621fd056f5eaaad7cdcd9279310fb5 Author: Lasse Collin -Date: 2013-11-12 16:38:57 +0200 +Date: 2024-11-25 16:26:54 +0200 - xz: Update the man page about --block-size and --block-list. + Update THANKS - src/xz/xz.1 | 24 +++++++++++++++--------- - 1 file changed, 15 insertions(+), 9 deletions(-) + THANKS | 1 + + 1 file changed, 1 insertion(+) -commit 76be7c612e6bcc38724488ccc3b8bcb1cfec9f0a -Author: Lasse Collin -Date: 2013-11-12 16:30:53 +0200 +commit 48ff3f06521ca326996ab9a04d1b342098960427 +Author: Mark Wielaard +Date: 2024-11-25 12:28:44 +0200 - Update THANKS. + xz: Landlock: Fix a file descriptor leak - THANKS | 1 + + src/xz/sandbox.c | 1 + 1 file changed, 1 insertion(+) -commit dd750acbe2259d75444ef0f8da2d4bacc90d7afc -Author: Lasse Collin -Date: 2013-11-12 16:29:48 +0200 +commit dbca3d078ec581600600abebbb18769d3d713914 +Author: Sam James +Date: 2024-10-02 03:04:03 +0100 - xz: Make --block-list and --block-size work together in single-threaded. + CI: update FreeBSD, NetBSD, OpenBSD, Solaris actions - Previously, --block-list and --block-size only worked together - in threaded mode. Boundaries are specified by --block-list, but - --block-size specifies the maximum size for a Block. Now this - works in single-threaded mode too. - - Thanks to James M Leddy for the original patch. + Checked the changes and they're all innocuous. This should hopefully + fix the "externally managed" pip error in these jobs that started + recently. - src/xz/coder.c | 90 ++++++++++++++++++++++++++++++++++++++++++++++++---------- - 1 file changed, 75 insertions(+), 15 deletions(-) + .github/workflows/freebsd.yml | 2 +- + .github/workflows/netbsd.yml | 2 +- + .github/workflows/openbsd.yml | 2 +- + .github/workflows/solaris.yml | 2 +- + 4 files changed, 4 insertions(+), 4 deletions(-) -commit ae222fe9805d0161d022d75ba8485dab8bf6d7d5 +commit a94b85bea3f04d8c1f4e2e6f648a9a15bc6ce58f Author: Lasse Collin -Date: 2013-10-26 13:26:14 +0300 +Date: 2024-10-01 12:17:39 +0300 - Bump the version number to 5.1.3alpha. + Add NEWS for 5.6.3 - src/liblzma/api/lzma/version.h | 2 +- - src/liblzma/liblzma.map | 2 +- - 2 files changed, 2 insertions(+), 2 deletions(-) + NEWS | 125 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ + 1 file changed, 125 insertions(+) -commit 2193837a6a597cd3bf4e9ddf49421a5697d8e155 +commit be4bf94446b6286a5dffdde85fc1d21448f4edff Author: Lasse Collin -Date: 2013-10-26 13:25:02 +0300 +Date: 2024-10-01 14:49:41 +0300 - Update NEWS for 5.1.3alpha. + cmake/tuklib_large_file_support.cmake: Add a missing include + + v5.2 didn't build with CMake. Other branches had + include(CMakePushCheckState) in top-level CMakeLists.txt + which made the build work. + + Fixes: 597f49b61475438a43a417236989b2acc968a686 - NEWS | 35 +++++++++++++++++++++++++++++++++++ - 1 file changed, 35 insertions(+) + cmake/tuklib_large_file_support.cmake | 1 + + 1 file changed, 1 insertion(+) -commit ed48e75e2763876173aef8902da407a8eb28854b +commit 1ebbe915d4e0d877154261b5f8103719a6722975 Author: Lasse Collin -Date: 2013-10-26 12:47:04 +0300 +Date: 2024-10-01 12:10:23 +0300 - Update TODO. + Update THANKS - TODO | 4 ---- - 1 file changed, 4 deletions(-) + THANKS | 2 ++ + 1 file changed, 2 insertions(+) -commit 841da0352d79a56a44796a4c39163429c9f039a3 +commit 74702ee00ecfd080d8ab11118cd25dbe6c437ec0 Author: Lasse Collin -Date: 2013-10-25 22:41:28 +0300 +Date: 2024-10-01 12:10:23 +0300 - xz: Document behavior of --block-list with threads. + Tests/Windows: Add the application manifest to the test programs - This needs to be updated before 5.2.0. + This ensures that the test programs get executed the same way as + the binaries that are installed. - src/xz/xz.1 | 24 +++++++++++++++++++++--- - 1 file changed, 21 insertions(+), 3 deletions(-) + CMakeLists.txt | 14 ++++++++++---- + tests/Makefile.am | 10 ++++++++++ + tests/tests.cmake | 33 ++++++++++++++++++++++++++++++++- + tests/tests_w32res.rc | 18 ++++++++++++++++++ + 4 files changed, 70 insertions(+), 5 deletions(-) -commit 56feb8665b78c1032aabd53c619c62af51defe64 +commit 7ddf2273e0e4654582ee65db19d44431bfdb5791 Author: Lasse Collin -Date: 2013-10-22 20:03:12 +0300 +Date: 2024-10-01 12:10:23 +0300 - xz: Document --flush-timeout=TIMEOUT on the man page. + license-check.sh: Add an exception for w32_application.manifest + + The file gets embedded as is into executables, thus it cannot + hold a license identifier. - src/xz/xz.1 | 37 ++++++++++++++++++++++++++++++++++++- - 1 file changed, 36 insertions(+), 1 deletion(-) + build-aux/license-check.sh | 1 + + 1 file changed, 1 insertion(+) -commit ba413da1d5bb3324287cf3174922acd921165971 +commit 46ee0061629fb075d61d83839e14dd193337af59 Author: Lasse Collin -Date: 2013-10-22 19:51:55 +0300 +Date: 2024-10-01 12:10:23 +0300 - xz: Take advantage of LZMA_FULL_BARRIER with --block-list. + Windows: Embed an application manifest in the EXE files - Now if --block-list is used in threaded mode, the encoder - won't need to flush at each Block boundary specified via - --block-list. This improves performance a lot, making - threading helpful with --block-list. + IMPORTANT: This includes a security fix to command line tool + argument handling. - The flush timer was reset after LZMA_FULL_FLUSH but since - LZMA_FULL_BARRIER doesn't flush, resetting the timer is - no longer done. - - src/xz/coder.c | 32 +++++++++++++++----------------- - 1 file changed, 15 insertions(+), 17 deletions(-) - -commit 0cd45fc2bc5537de287a0bc005e2d67467a92148 -Author: Lasse Collin -Date: 2013-10-02 20:05:23 +0300 - - liblzma: Support LZMA_FULL_FLUSH and _BARRIER in threaded encoder. + Some toolchains embed an application manifest by default to declare + UAC-compliance. Some also declare compatibility with Vista/8/8.1/10/11 + to let the app access features newer than those of Vista. + + We want all the above but also two more things: + + - Declare that the app is long path aware to support paths longer + than 259 characters (this may also require a registry change). - Now --block-list=SIZES works with in the threaded mode too, - although the performance is still bad due to the use of - LZMA_FULL_FLUSH instead of the new LZMA_FULL_BARRIER. + - Force the code page to UTF-8. This allows the command line tools + to access files whose names contain characters that don't exist + in the current legacy code page (except unpaired surrogates). + The UTF-8 code page also fixes security issues in command line + argument handling which can be exploited with malicious filenames. + See the new file w32_application.manifest.comments.txt. + + Thanks to Orange Tsai and splitline from DEVCORE Research Team + for discovering this issue. + + Thanks to Vijay Sarvepalli for reporting the issue to me. + + Thanks to Kelvin Lee for testing with MSVC and helping with + the required build system fixes. - src/liblzma/common/stream_encoder_mt.c | 55 ++++++++++++++++++++++++---------- - 1 file changed, 39 insertions(+), 16 deletions(-) + CMakeLists.txt | 18 +++ + src/Makefile.am | 4 +- + src/common/common_w32res.rc | 5 + + src/common/w32_application.manifest | 28 ++++ + src/common/w32_application.manifest.comments.txt | 178 +++++++++++++++++++++++ + 5 files changed, 232 insertions(+), 1 deletion(-) -commit 97bb38712f414fabecca908af2e38a12570293fd +commit dad153091552b52a41b95ec4981c6951f1cae487 Author: Lasse Collin -Date: 2013-10-02 12:55:11 +0300 +Date: 2024-09-29 14:46:52 +0300 - liblzma: Add LZMA_FULL_BARRIER support to single-threaded encoder. + Windows: Set DLL name accurately in StringFileInfo on Cygwin and MSYS2 - In the single-threaded encoder LZMA_FULL_BARRIER is simply - an alias for LZMA_FULL_FLUSH. + Now the information in the "Details" tab in the file properties + dialog matches the naming convention of Cygwin and MSYS2. This + is only a cosmetic change. - src/liblzma/api/lzma/base.h | 37 ++++++++++++++++++++++++++++++------- - src/liblzma/common/common.c | 17 +++++++++++++++-- - src/liblzma/common/common.h | 7 ++++++- - src/liblzma/common/stream_encoder.c | 4 +++- - 4 files changed, 54 insertions(+), 11 deletions(-) + src/liblzma/liblzma_w32res.rc | 10 +++++++++- + 1 file changed, 9 insertions(+), 1 deletion(-) -commit fef0c6b410c08e581c9178700a4e7599f0895ff9 +commit 8940ecb96fe9f0f2a9cfb8b66fe9ed31ffbea904 Author: Lasse Collin -Date: 2013-09-17 11:57:51 +0300 +Date: 2024-09-25 15:47:55 +0300 - liblzma: Add block_buffer_encoder.h into Makefile.inc. + common_w32res.rc: White space edits - This should have been in b465da5988dd59ad98fda10c2e4ea13d0b9c73bc. + LANGUAGE and VS_VERSION_INFO begin new statements so put an empty line + between them. - src/liblzma/common/Makefile.inc | 1 + - 1 file changed, 1 insertion(+) + src/common/common_w32res.rc | 15 ++++++++------- + 1 file changed, 8 insertions(+), 7 deletions(-) -commit 8083e03291b6d21c0f538163e187b4e8cd5594e4 +commit c3b9dad07d3fd9319f88386b7095019bcea45ce1 Author: Lasse Collin -Date: 2013-09-17 11:55:38 +0300 +Date: 2024-09-28 20:09:50 +0300 - xz: Add a missing test for TUKLIB_DOSLIKE. + CMake: Add the resource files to the Cygwin and MSYS2 builds + + Autotools-based build has always done this so this is for consistency. + + However, the CMake build won't create the DEF file when building + for Cygwin or MSYS2 because in that context it should be useless. + (If Cygwin or MSYS2 is used to host building of normal Windows + binaries then the DEF file is still created.) - src/xz/file_io.c | 2 ++ - 1 file changed, 2 insertions(+) + CMakeLists.txt | 16 ++++++++++------ + 1 file changed, 10 insertions(+), 6 deletions(-) -commit 6b44b4a775fe29ecc7bcb7996e086e3bc09e5fd0 +commit da4f275bd1c18b897e5c2dd0043546de3accce0a Author: Lasse Collin -Date: 2013-09-17 11:52:28 +0300 +Date: 2024-09-28 15:19:14 +0300 - Add native threading support on Windows. + CMake: Fix Windows resource file dependencies - Now liblzma only uses "mythread" functions and types - which are defined in mythread.h matching the desired - threading method. - - Before Windows Vista, there is no direct equivalent to - pthread condition variables. Since this package doesn't - use pthread_cond_broadcast(), pre-Vista threading can - still be kept quite simple. The pre-Vista code doesn't - use anything that wasn't already available in Windows 95, - so the binaries should run even on Windows 95 if someone - happens to care. + If common_w32res.rc is modified, the resource files need to be rebuilt. + In contrast, the liblzma*.map files truly are link dependencies. - INSTALL | 41 ++- - configure.ac | 118 ++++++-- - src/common/mythread.h | 513 ++++++++++++++++++++++++++------- - src/liblzma/common/stream_encoder_mt.c | 83 +++--- - src/xz/coder.c | 8 +- - windows/README-Windows.txt | 2 +- - windows/build.bash | 23 +- - 7 files changed, 573 insertions(+), 215 deletions(-) + CMakeLists.txt | 17 +++++++++-------- + 1 file changed, 9 insertions(+), 8 deletions(-) -commit ae0ab74a88d5b9b15845f1d9a24ade4349a54f9f +commit 1c673c0aac7f7dee8dda2c1140351c8417a71e47 Author: Lasse Collin -Date: 2013-09-11 14:40:35 +0300 +Date: 2024-09-29 01:20:03 +0300 - Build: Remove a comment about Automake 1.10 from configure.ac. + CMake: Checking for CYGWIN covers MSYS2 too - The previous commit supports silent rules and that requires - Automake 1.11. + On MSYS2, both CYGWIN and MSYS are set. - configure.ac | 2 -- - 1 file changed, 2 deletions(-) + CMakeLists.txt | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) -commit 72975df6c8c59aaf849138ab3606e8fb6970596a +commit 6aaa0173b839e28429d43a8b62d257ad2f3b4521 Author: Lasse Collin -Date: 2013-09-09 20:37:03 +0300 +Date: 2024-09-28 09:37:30 +0300 - Build: Create liblzma.pc in a src/liblzma/Makefile.am. - - Previously it was done in configure, but doing that goes - against the Autoconf manual. Autoconf requires that it is - possible to override e.g. prefix after running configure - and that doesn't work correctly if liblzma.pc is created - by configure. - - A potential downside of this change is that now e.g. - libdir in liblzma.pc is a standalone string instead of - being defined via ${prefix}, so if one overrides prefix - when running pkg-config the libdir won't get the new value. - I don't know if this matters in practice. - - Thanks to Vincent Torri. + Translations: Add the SPDX license identifier to pt_BR.po - configure.ac | 1 - - src/liblzma/Makefile.am | 20 ++++++++++++++++++++ - 2 files changed, 20 insertions(+), 1 deletion(-) + po/pt_BR.po | 2 ++ + 1 file changed, 2 insertions(+) -commit 1c2b6e7e8382ed390f53e140f160488bb2205ecc +commit dc7b9f24b737e4e55bcbbdde6754883f991c2cfb Author: Lasse Collin -Date: 2013-08-04 15:24:09 +0300 +Date: 2024-09-25 16:41:37 +0300 - Fix the previous commit which broke the build. + Windows/CMake: Use the correct resource file for lzmadec.exe - Apparently I didn't even compile-test the previous commit. + CMakeLists.txt was using xzdec_w32res.rc for both xzdec and lzmadec. - Thanks to Christian Hesse. + Fixes: 998d0b29536094a89cf385a3b894e157db1ccefe - src/common/tuklib_cpucores.c | 2 +- + CMakeLists.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -commit 124eb69c7857f618b4807588c51bc9ba21bf8691 +commit b834ae5f80911a3819d6cdb484f61b257174c544 Author: Lasse Collin -Date: 2013-08-03 13:52:58 +0300 +Date: 2024-09-25 21:29:59 +0300 - Windows: Add Windows support to tuklib_cpucores(). - - It is used for Cygwin too. I'm not sure if that is - a good or bad idea. - - Thanks to Vincent Torri. + Translations: Update the Brazilian Portuguese translation - m4/tuklib_cpucores.m4 | 19 +++++++++++++++++-- - src/common/tuklib_cpucores.c | 13 ++++++++++++- - 2 files changed, 29 insertions(+), 3 deletions(-) + po/pt_BR.po | 144 ++++++++++++++++++++++-------------------------------------- + 1 file changed, 53 insertions(+), 91 deletions(-) -commit eada8a875ce3fd521cb42e4ace2624d3d49c5f35 -Author: Anders F Bjorklund -Date: 2013-08-02 15:59:46 +0200 +commit eceb023d4c129fd63ee881a2d8696eaf52ad1532 +Author: Lasse Collin +Date: 2024-09-17 01:21:15 +0300 - macosx: separate liblzma package + Update THANKS - macosx/build.sh | 23 +++++++++++++++-------- - 1 file changed, 15 insertions(+), 8 deletions(-) + THANKS | 1 + + 1 file changed, 1 insertion(+) -commit be0100d01ca6a75899d051bee00acf17e6dc0c15 -Author: Anders F Bjorklund -Date: 2013-08-02 15:58:44 +0200 +commit 76cfd0a9bb33ae8e534b1f73f6359dc825589f2f +Author: Tobias Stoeckmann +Date: 2024-09-16 23:19:46 +0200 - macosx: set minimum to leopard + lzmainfo: Avoid integer overflow + + The MB output can overflow with huge numbers. Most likely these are + invalid .lzma files anyway, but let's avoid garbage output. + + lzmadec was adapted from LZMA Utils. The original code with this bug + was written in 2005, over 19 years ago. + + Co-authored-by: Lasse Collin + Closes: https://github.com/tukaani-project/xz/pull/144 - macosx/build.sh | 13 ++++++++----- - 1 file changed, 8 insertions(+), 5 deletions(-) + src/lzmainfo/lzmainfo.c | 5 ++--- + 1 file changed, 2 insertions(+), 3 deletions(-) -commit 416729e2d743f4b2fe9fd438eedeb98adce033c3 -Author: Anders F Bjorklund -Date: 2011-08-07 13:13:30 +0200 +commit 78355aebb7fb654302e5e33692ba109909dacaff +Author: Tobias Stoeckmann +Date: 2024-09-16 22:04:40 +0200 - move configurables into variables + xzdec: Remove unused short option -M + + "xzdec -M123" exited with exit status 1 without printing + any messages. The "M:" entry should have been removed when + the memory usage limiter support was removed from xzdec. + + Fixes: 792331bdee706aa852a78b171040ebf814c6f3ae + Closes: https://github.com/tukaani-project/xz/pull/143 + [ Lasse: Commit message edits ] - macosx/build.sh | 25 ++++++++++++++++++------- - 1 file changed, 18 insertions(+), 7 deletions(-) + src/xzdec/xzdec.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) -commit 16581080e5f29f9a4e49efece21c5bf572323acc +commit e5758db7bd75587a2499e0771907521a4aa86908 Author: Lasse Collin -Date: 2013-07-15 14:08:41 +0300 +Date: 2024-09-10 13:54:47 +0300 - Update THANKS. + Update THANKS THANKS | 1 + 1 file changed, 1 insertion(+) -commit 3e2b198ba37b624efd9c7caee2a435dc986b46c6 -Author: Lasse Collin -Date: 2013-07-15 14:08:02 +0300 +commit 80ffa38f56657257ed4d90d76f6bd2f2bcb8163c +Author: Firas Khalil Khana +Date: 2024-09-10 12:30:32 +0300 - Build: Fix the detection of missing CRC32. + Build: Fix a typo in autogen.sh - Thanks to Vincent Torri. + Fixes: e9be74f5b129fe8a5388d588e68b1b7f5168a310 + Closes: https://github.com/tukaani-project/xz/pull/141 - configure.ac | 2 +- + autogen.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -commit dee6ad3d5915422bc30a6821efeacaeb8ca8ef00 +commit 68c54e45d042add64a4cb44bfc87ca74d29b87e2 Author: Lasse Collin -Date: 2013-07-04 14:18:46 +0300 +Date: 2024-09-02 20:08:40 +0300 - xz: Add preliminary support for --flush-timeout=TIMEOUT. + Translations: Update Chinese (simplified) translation - When --flush-timeout=TIMEOUT is used, xz will use - LZMA_SYNC_FLUSH if read() would block and at least - TIMEOUT milliseconds has elapsed since the previous flush. + Differences to the zh_CN.po file from the Translation Project: - This can be useful in realtime-like use cases where the - data is simultanously decompressed by another process - (possibly on a different computer). If new uncompressed - input data is produced slowly, without this option xz could - buffer the data for a long time until it would become - decompressible from the output. + - Two uses of \v were fixed. - If TIMEOUT is 0, the feature is disabled. This is the default. + - Missing "OPTS" translation in --riscv[=OPTS] was copied from + previous lines. - This commit affects the compression side. Using xz for - the decompression side for the above purpose doesn't work - yet so well because there is quite a bit of input and - output buffering when decompressing. + - "make update-po" was run to remove line numbers from comments. + + po/zh_CN.po | 102 ++++++++++++++++++++++++------------------------------------ + 1 file changed, 40 insertions(+), 62 deletions(-) + +commit 2230692aa1bcebb586100183831e3daf1714d60a +Author: Lasse Collin +Date: 2024-09-02 19:40:50 +0300 + + Translations: Update the Catalan translation - The --long-help or man page were not updated yet. - The details of this feature may change. + Differences to the ca.po file from the Translation Project: + + - An overlong line translating --filters-help was wrapped. + + - "make update-po" was used to remove line numbers from the comments + to match the changes in fccebe2b4fd513488fc920e4dac32562ed3c7637 + and 093490b58271e9424ce38a7b1b38bcf61b9c86c6. xz.pot in the TP + is older than these commits. - src/xz/args.c | 7 +++++++ - src/xz/coder.c | 46 +++++++++++++++++++++++++++++++++++----------- - src/xz/file_io.c | 46 ++++++++++++++++++++++++++++++++++++---------- - 3 files changed, 78 insertions(+), 21 deletions(-) + po/ca.po | 171 ++++++++++++++++++++++++++------------------------------------- + 1 file changed, 69 insertions(+), 102 deletions(-) -commit fa381acaf9a29a8114e1c0a97de99bab9adb014e +commit 3e7723ce26f74c71919984a6180504b4548cbb7e Author: Lasse Collin -Date: 2013-07-04 13:41:03 +0300 +Date: 2024-08-22 14:06:16 +0300 - xz: Don't set src_eof=true after an I/O error because it's useless. + Update THANKS - src/xz/file_io.c | 3 --- - 1 file changed, 3 deletions(-) + THANKS | 1 + + 1 file changed, 1 insertion(+) -commit ea00545beace5b950f709ec21e46878e0f448678 +commit d3e0e679b2b8b428598bb8ba56a17715190814db Author: Lasse Collin -Date: 2013-07-04 13:25:11 +0300 +Date: 2024-08-22 14:06:16 +0300 - xz: Fix the test when to read more input. + CMake: Don't install lzmadec.1 symlinks if XZ_TOOL_LZMADEC=OFF - Testing for end of file was no longer correct after full flushing - became possible with --block-size=SIZE and --block-list=SIZES. - There was no bug in practice though because xz just made a few - unneeded zero-byte reads. + Thanks-to: 榆柳松 (ZhengSen Wang) + Fixes: fb50c6ba1d4c9405e5b12b5988b01a3002638c5d + Closes: https://github.com/tukaani-project/xz/pull/134 - src/xz/coder.c | 6 +++--- - 1 file changed, 3 insertions(+), 3 deletions(-) + CMakeLists.txt | 12 ++++++++++-- + 1 file changed, 10 insertions(+), 2 deletions(-) -commit 736903c64bef394c06685d79908e397bcb08b88f +commit acdf21033abe347d9a279e9fe757f90ed16c1dbb Author: Lasse Collin -Date: 2013-07-04 12:51:57 +0300 +Date: 2024-08-22 14:06:16 +0300 - xz: Move some of the timing code into mytime.[hc]. + CMake: Fix the build when XZ_TOOL_LZMADEC=OFF - This switches units from microseconds to milliseconds. - - New clock_gettime(CLOCK_MONOTONIC) will be used if available. - There is still a fallback to gettimeofday(). + Co-developed-by: 榆柳松 (ZhengSen Wang) + Fixes: fb50c6ba1d4c9405e5b12b5988b01a3002638c5d + Fixes: https://github.com/tukaani-project/xz/pull/134 - src/xz/Makefile.am | 2 ++ - src/xz/coder.c | 5 +++ - src/xz/message.c | 54 +++++++++------------------------ - src/xz/mytime.c | 89 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ - src/xz/mytime.h | 47 ++++++++++++++++++++++++++++ - src/xz/private.h | 1 + - 6 files changed, 158 insertions(+), 40 deletions(-) + CMakeLists.txt | 6 ++++-- + 1 file changed, 4 insertions(+), 2 deletions(-) -commit 24edf8d807e24ffaa1e793114d94cca3b970027d +commit 5e375987509fab484b7bef0b90be92f241c58c91 Author: Lasse Collin -Date: 2013-07-01 14:35:03 +0300 +Date: 2024-08-22 11:01:07 +0300 - Update THANKS. + Update THANKS THANKS | 1 + 1 file changed, 1 insertion(+) -commit c0627b3fceacfa1ed162f5f55235360ea26f569a -Author: Lasse Collin -Date: 2013-07-01 14:34:11 +0300 +commit 6cd7c8607843c337edfe2c472aa316602a393754 +Author: Yifeng Li +Date: 2024-08-22 02:18:49 +0000 - xz: Silence a warning seen with _FORTIFY_SOURCE=2. + liblzma: Fix x86-64 movzw compatibility in range_decoder.h + + Support for instruction "movzw" without suffix in "GNU as" was + added in commit [1] and stabilized in binutils 2.27, released + in August 2016. Earlier systems don't accept this instruction + without a suffix, making range_decoder.h's inline assembly + unable to build on old systems such as Ubuntu 16.04, creating + error messages like: + + lzma_decoder.c: Assembler messages: + lzma_decoder.c:371: Error: no such instruction: `movzw 2(%r11),%esi' + lzma_decoder.c:373: Error: no such instruction: `movzw 4(%r11),%edi' + lzma_decoder.c:388: Error: no such instruction: `movzw 6(%r11),%edx' + lzma_decoder.c:398: Error: no such instruction: `movzw (%r11,%r14,4),%esi' + + Change "movzw" to "movzwl" for compatibility. - Thanks to Christian Hesse. + [1] https://sourceware.org/git/?p=binutils-gdb.git;a=commit;h=c07315e0c610e0e3317b4c02266f81793df253d2 + + Suggested-by: Lasse Collin + Tested-by: Yifeng Li + Signed-off-by: Yifeng Li + Fixes: 3182a330c1512cc1f5c87b5c5a272578e60a5158 + Fixes: https://github.com/tukaani-project/xz/issues/121 + Closes: https://github.com/tukaani-project/xz/pull/136 - src/xz/file_io.c | 8 +++++++- - 1 file changed, 7 insertions(+), 1 deletion(-) + src/liblzma/rangecoder/range_decoder.h | 24 ++++++++++++------------ + 1 file changed, 12 insertions(+), 12 deletions(-) -commit 1936718bb38ee394bd89836fdd4eabc0beb02443 +commit bf901dee5d4c46609645e50311c0cb2dfdcf9738 Author: Lasse Collin -Date: 2013-06-30 19:40:11 +0300 +Date: 2024-07-19 20:02:43 +0300 - Update NEWS for 5.0.5. + Build: Comment that elf_aux_info(3) will be available on OpenBSD >= 7.6 - NEWS | 52 ++++++++++++++++++++++++++++++++++++++++++++++++++++ - 1 file changed, 52 insertions(+) + CMakeLists.txt | 2 +- + configure.ac | 17 +++++++++++------ + 2 files changed, 12 insertions(+), 7 deletions(-) -commit a37ae8b5eb6093a530198f109c6f7a538c80ecf0 +commit f7103c2c2a8fa51d1f308ba7387beeff20a0d4dd Author: Lasse Collin -Date: 2013-06-30 18:02:27 +0300 +Date: 2024-07-19 19:42:26 +0300 - Man pages: Use similar syntax for synopsis as in xz. + Revert "liblzma: Add ARM64 CRC32 instruction support detection on OpenBSD" - The man pages of lzmainfo, xzmore, and xzdec had similar - constructs as the man page of xz had before the commit - eb6ca9854b8eb9fbf72497c1cf608d6b19d2d494. Eric S. Raymond - didn't mention these man pages in his bug report, but - it's nice to be consistent. + This reverts commit dc03f6290f5b9bd3d50c7e12e58dee870889d599. + + OpenBSD 7.6 will support elf_aux_info(3), and the detection code used + on FreeBSD will work on OpenBSD 7.6 too. Keep things simpler and drop + the OpenBSD-specific sysctl() method. + + Thanks to Christian Weisgerber. - src/lzmainfo/lzmainfo.1 | 4 ++-- - src/scripts/xzmore.1 | 6 +++--- - src/xzdec/xzdec.1 | 10 +++++----- - 3 files changed, 10 insertions(+), 10 deletions(-) + CMakeLists.txt | 6 ------ + configure.ac | 9 --------- + src/liblzma/check/crc32_arm64.h | 15 --------------- + src/liblzma/check/crc_common.h | 1 - + 4 files changed, 31 deletions(-) -commit cdba9ddd870ae72fd6219a125662c20ec997f86c +commit 7c292dd0bf23cefcdf4b1509f3666322e08a7ede Author: Lasse Collin -Date: 2013-06-29 15:59:13 +0300 +Date: 2024-07-13 22:10:37 +0300 - xz: Use non-blocking I/O for the output file. - - Now both reading and writing should be without - race conditions with signals. - - They might still be signal handling issues left. - Signals are blocked during many operations to avoid - EINTR but it may cause problems e.g. if writing to - stderr blocks when trying to display an error message. + liblzma: Tweak a comment - src/xz/file_io.c | 57 ++++++++++++++++++++++++++++++++++++++++++++++++-------- - 1 file changed, 49 insertions(+), 8 deletions(-) + src/liblzma/simple/arm64.c | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) -commit e61a5c95da3fe31281d959e5e842885a8ba2b5bd +commit 6408edac5529d6ec0abf52794074f229c8362303 Author: Lasse Collin -Date: 2013-06-28 23:56:17 +0300 +Date: 2024-07-11 22:17:56 +0300 - xz: Fix return value type in io_write_buf(). - - It didn't affect the behavior of the code since -1 - becomes true anyway. + CMake: Bump maximum policy version to 3.30 - src/xz/file_io.c | 2 +- + CMakeLists.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -commit 9dc319eabb34a826f4945f91c71620f14a60e9e2 +commit 9231c39ffb518196d6664a86e5325e744621a21b Author: Lasse Collin -Date: 2013-06-28 23:48:05 +0300 +Date: 2024-07-06 15:13:19 +0300 - xz: Use the self-pipe trick to avoid a race condition with signals. + CMake: Require CMake 3.20 or later - It is possible that a signal to set user_abort arrives right - before a blocking system call is made. In this case the call - may block until another signal arrives, while the wanted - behavior is to make xz clean up and exit as soon as possible. - - After this commit, the race condition is avoided with the - input side which already uses non-blocking I/O. The output - side still uses blocking I/O and thus has the race condition. + This allows a few cleanups. - src/xz/file_io.c | 56 ++++++++++++++++++++++++++++++++++++++++++++------------ - src/xz/file_io.h | 8 ++++++++ - src/xz/signals.c | 5 +++++ - 3 files changed, 57 insertions(+), 12 deletions(-) + CMakeLists.txt | 78 ++++++++++++++++++++-------------------------------------- + 1 file changed, 27 insertions(+), 51 deletions(-) -commit 3541bc79d0cfabc0ad155c99bfdad1289f17fec3 +commit 028185dd4889e3d6235ff13560160ebca6985021 Author: Lasse Collin -Date: 2013-06-28 22:51:02 +0300 +Date: 2024-07-09 14:27:51 +0300 - xz: Use non-blocking I/O for the input file. + Update THANKS - src/xz/file_io.c | 156 +++++++++++++++++++++++++++++++++++++++---------------- - 1 file changed, 111 insertions(+), 45 deletions(-) + THANKS | 1 + + 1 file changed, 1 insertion(+) -commit 78673a08bed5066c81e8a8e90d20e670c28ecfd5 +commit baecfa142644eb5f5c6dd6f8e2f531c362fa3747 Author: Lasse Collin -Date: 2013-06-28 18:46:13 +0300 +Date: 2024-07-06 14:04:48 +0300 - xz: Remove an outdated NetBSD-specific comment. + xz: Remove the TODO comment about --recursive - Nowadays errno == EFTYPE is documented in open(2). + It won't be implemented. find + xargs is more flexible, for example, + it allows compressing small files in parallel. An example for that + has been included in the xz man page since 2010. - src/xz/file_io.c | 4 ---- - 1 file changed, 4 deletions(-) + src/xz/args.c | 1 - + 1 file changed, 1 deletion(-) -commit a616fdad34b48b2932ef03fb87309dcc8b829527 +commit f691d58fae82bd815c5f86ffad10fe9b6b59dad8 Author: Lasse Collin -Date: 2013-06-28 18:09:47 +0300 +Date: 2024-07-06 14:04:16 +0300 - xz: Fix error detection of fcntl(fd, F_SETFL, flags) calls. - - POSIX says that fcntl(fd, F_SETFL, flags) returns -1 on - error and "other than -1" on success. This is how it is - documented e.g. on OpenBSD too. On Linux, success with - F_SETFL is always 0 (at least accorinding to fcntl(2) - from man-pages 3.51). + Document --disable-loongarch-crc32 in INSTALL - src/xz/file_io.c | 8 ++++---- - 1 file changed, 4 insertions(+), 4 deletions(-) + INSTALL | 8 ++++++++ + 1 file changed, 8 insertions(+) -commit 4a08a6e4c61c65ab763ab314100a6d7a3bb89298 +commit b3e53122f42796aaebd767bab920cf7bedf69966 Author: Lasse Collin -Date: 2013-06-28 17:36:47 +0300 +Date: 2024-07-03 20:45:48 +0300 - xz: Fix use of wrong variable in a fcntl() call. + CMake: Link xz against Threads::Threads if using pthreads - Due to a wrong variable name, when writing a sparse file - to standard output, *all* file status flags were cleared - (to the extent the operating system allowed it) instead of - only clearing the O_APPEND flag. In practice this worked - fine in the common situations on GNU/Linux, but I didn't - check how it behaved elsewhere. + The liblzma target was recently changed to link against Threads::Threads + with the PRIVATE keyword. I had forgotten that xz itself depends on + pthreads too due to pthread_sigmask(). Thus, the build broke when + building shared liblzma and pthread_sigmask() wasn't in libc. - The original flags were still restored correctly. I still - changed the code to use a separate boolean variable to - indicate when the flags should be restored instead of - relying on a special value in stdout_flags. - - src/xz/file_io.c | 24 +++++++++++++----------- - 1 file changed, 13 insertions(+), 11 deletions(-) - -commit b790b435daa3351067f80a5973b647f8d55367a2 -Author: Lasse Collin -Date: 2013-06-28 14:55:37 +0300 - - xz: Fix assertion related to posix_fadvise(). + Thanks to Peter Seiderer for the bug report. - Input file can be a FIFO or something else that doesn't - support posix_fadvise() so don't check the return value - even with an assertion. Nothing bad happens if the call - to posix_fadvise() fails. + Fixes: ac05f1b0d7cda1e7ae79775a8dfecc54601d7f1c + Fixes: https://github.com/tukaani-project/xz/issues/129#issuecomment-2204522994 - src/xz/file_io.c | 10 ++-------- - 1 file changed, 2 insertions(+), 8 deletions(-) + CMakeLists.txt | 13 +++++++++++++ + 1 file changed, 13 insertions(+) -commit 84d2da6c9dc252f441deb7626c2522202b005d4d +commit 5742ec1fc7f2cf1c82cfe3477bb90594a4658374 Author: Lasse Collin -Date: 2013-06-26 13:30:57 +0300 +Date: 2024-07-02 22:49:33 +0300 - xz: Check the value of lzma_stream_flags.version in --list. - - It is a no-op for now, but if an old xz version is used - together with a newer liblzma that supports something new, - then this check becomes important and will stop the old xz - from trying to parse files that it won't understand. + Update THANKS - src/xz/list.c | 14 ++++++++++++++ - 1 file changed, 14 insertions(+) + THANKS | 1 + + 1 file changed, 1 insertion(+) -commit 9376f5f8f762296f2173d61af9101112c36f38c0 +commit 2d13d10357ecad243d7e4ff1de0e6b437c38a47a Author: Lasse Collin -Date: 2013-06-26 12:17:00 +0300 +Date: 2024-07-02 20:23:35 +0300 - Build: Require Automake 1.12 and use serial-tests option. - - It should actually still work with Automake 1.10 if - the serial-tests option is removed. Automake 1.13 started - using parallel tests by default and the option to get - the old behavior isn't supported before 1.12. - - At least for now, parallel tests don't improve anything - in XZ Utils but they hide the progress output from - test_compress.sh. + CMake: Improve NLS error messages - configure.ac | 4 +++- - 1 file changed, 3 insertions(+), 1 deletion(-) + CMakeLists.txt | 11 +++++++---- + 1 file changed, 7 insertions(+), 4 deletions(-) -commit b7e200d7bd0a3c7c171c13ad37d68296d6f73374 +commit 628d8d2c4fdf9e6a91c7bba7a743f400a94c2909 Author: Lasse Collin -Date: 2013-06-23 18:59:13 +0300 +Date: 2024-07-02 20:19:47 +0300 - Update THANKS. + CMake: Update the comment at the top of CMakeLists.txt + + While po/*.gmo files won't be used from the release tarball, + the generated translated man pages will be used still. Those + are text files and po4a has slightly more dependencies than + gettext tools so installing po4a might be a bit more challenging + in some situations. - THANKS | 1 + - 1 file changed, 1 insertion(+) + CMakeLists.txt | 17 +++++++---------- + 1 file changed, 7 insertions(+), 10 deletions(-) -commit 46540e4c10923e363741ff5aab99e79fc0ce6ee8 +commit b4b23c94fd4429abc663ced28d5cdc9cf7eb7507 Author: Lasse Collin -Date: 2013-06-23 18:57:23 +0300 +Date: 2024-07-02 20:12:40 +0300 - liblzma: Avoid a warning about a shadowed variable. + CMake: Drop support for pre-generated po/*.gmo files - On Mac OS X wait() is declared in that - we include one way or other so don't use "wait" as - a variable name. + When a release tarball is created using Autotools, the tarball includes + po/*.gmo files which are binary files generated from po/*.po. Other + tarball creation methods don't and won't create the .gmo files. - Thanks to Christian Kujau. + It feels clearer if CMake will never install pre-generated binary files + from the source package. If people are able to install CMake, they + likely are able to install gettext tools as well (assuming they want + translations). - src/liblzma/common/stream_encoder_mt.c | 4 ++-- - 1 file changed, 2 insertions(+), 2 deletions(-) + CMakeLists.txt | 66 +++++++++++++++++++--------------------------------------- + 1 file changed, 21 insertions(+), 45 deletions(-) -commit ebb501ec73cecc546c67117dd01b5e33c90bfb4a +commit fb99f8e8c50171b898cb79fe1dc703d5f91e4f0a Author: Lasse Collin -Date: 2013-06-23 17:36:47 +0300 +Date: 2024-07-02 19:14:50 +0300 - xz: Validate Uncompressed Size from Block Header in list.c. + CMake: Make XZ_NLS handling more robust + + If a user set XZ_NLS=ON but find_package(Intl) failed or CMake version + wasn't at least 3.20, the configuration would fail in a cryptic way. + + If XZ_NLS is enabled, require that CMake is new enough and that either + gettext tools or pre-generated .gmo files are available. Otherwise fail + the configuration. Previously missing gettext tools and .gmo files would + only result in a warning. - This affects only "xz -lvv". Normal decompression with xz - already detected if Block Header and Index had mismatched - Uncompressed Size fields. So this just makes "xz -lvv" - show such files as corrupt instead of showing the - Uncompressed Size from Index. + Missing man page translations are still only a warning. + + Thanks to Peter Seiderer for the bug report. + + Fixes: https://github.com/tukaani-project/xz/issues/129 + Closes: https://github.com/tukaani-project/xz/pull/130 - src/xz/list.c | 14 +++++++++++++- - 1 file changed, 13 insertions(+), 1 deletion(-) + CMakeLists.txt | 82 ++++++++++++++++++++++++++++++++-------------------------- + 1 file changed, 46 insertions(+), 36 deletions(-) -commit c09e91dd236d3cabee0fc48312b3dc8cceae41ab +commit ec6157570ea8a8e38158894e530d35416ff6a0f8 Author: Lasse Collin -Date: 2013-06-21 22:08:11 +0300 +Date: 2024-07-02 19:39:05 +0300 - Update THANKS. + CI: Add gettext as a dependency to CMake builds - THANKS | 2 ++ - 1 file changed, 2 insertions(+) + .github/workflows/ci.yml | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) -commit eb6ca9854b8eb9fbf72497c1cf608d6b19d2d494 +commit 24f0f7e399de03bb2ff675d97b723d14f17ed6ac Author: Lasse Collin -Date: 2013-06-21 22:04:45 +0300 +Date: 2024-07-02 18:43:56 +0300 - xz: Make the man page more friendly to doclifter. + CMake: Fix ENABLE_NLS comment too - Thanks to Eric S. Raymond. + Fixes: 29f77c7b707f2458fb047e77497354b195e05b14 - src/xz/xz.1 | 7 ++++--- - 1 file changed, 4 insertions(+), 3 deletions(-) + CMakeLists.txt | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) -commit 0c0a1947e6ad90a0a10b7a5c39f6ab99a0aa5c93 +commit a0df0676130bc565af0ec911e68a1d0fbc3ed0fb Author: Lasse Collin -Date: 2013-06-21 21:54:59 +0300 +Date: 2024-07-02 18:02:50 +0300 - xz: A couple of man page fixes. + CMake: The compile definition is ENABLE_NLS, not XZ_NLS - Now the interaction of presets and custom filter chains - is described correctly. Earlier it contradicted itself. + The CMake variables were renamed and accidentally also + the compile definition was renamed. As a result, translation + support wasn't actually enabled in the executables. - Thanks to DevHC who reported these issues on IRC to me - on 2012-12-14. + Fixes: 29f77c7b707f2458fb047e77497354b195e05b14 - src/xz/xz.1 | 35 +++++++++++++++++++++++------------ - 1 file changed, 23 insertions(+), 12 deletions(-) + CMakeLists.txt | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) -commit 2fcda89939c903106c429e109083d43d894049e0 +commit 45d08abc33ccc52d2f050dcec458badc2ce59d0b Author: Lasse Collin -Date: 2013-06-21 21:50:26 +0300 +Date: 2024-07-01 17:33:20 +0300 - xz: Fix interaction between preset and custom filter chains. - - There was somewhat illogical behavior when --extreme was - specified and mixed with custom filter chains. + Update AUTHORS and THANKS + + AUTHORS | 2 +- + THANKS | 1 + + 2 files changed, 2 insertions(+), 1 deletion(-) + +commit 7baf6835cfbf9c85ba37f9ffb7d4f87fb86a474e +Author: Xi Ruoyao +Date: 2024-06-28 13:36:43 +0300 + + liblzma: Speed up CRC32 calculation on 64-bit LoongArch - Before this commit, "xz -9 --lzma2 -e" was equivalent - to "xz --lzma2". After it is equivalent to "xz -6e" - (all earlier preset options get forgotten when a custom - filter chain is specified and the default preset is 6 - to which -e is applied). I find this less illogical. + The crc.w.{b/h/w/d}.w instructions in LoongArch can calculate the CRC32 + result for 1/2/4/8 bytes in a single operation. Using these is much + faster compared to the generic method. - This also affects the meaning of "xz -9e --lzma2 -7". - Earlier it was equivalent to "xz -7e" (the -e specified - before a custom filter chain wasn't forgotten). Now it - is "xz -7". Note that "xz -7e" still is the same as "xz -e7". + Optimized CRC32 is enabled unconditionally on 64-bit LoongArch because + the LoongArch specification says that CRC32 instructions shall be + implemented for 64-bit processors. Optimized CRC32 isn't enabled for + 32-bit LoongArch processors because not enough information is available + about them. - Hopefully very few cared about this in the first place, - so pretty much no one should even notice this change. + Co-authored-by: Lasse Collin - Thanks to Conley Moorhous. + Closes: https://github.com/tukaani-project/xz/pull/86 - src/xz/coder.c | 35 +++++++++++++++++++++-------------- - 1 file changed, 21 insertions(+), 14 deletions(-) + CMakeLists.txt | 25 ++++++++++++++ + configure.ac | 40 +++++++++++++++++++++++ + src/liblzma/check/Makefile.inc | 3 +- + src/liblzma/check/crc32_fast.c | 2 ++ + src/liblzma/check/crc32_loongarch.h | 65 +++++++++++++++++++++++++++++++++++++ + src/liblzma/check/crc_common.h | 15 +++++++++ + 6 files changed, 149 insertions(+), 1 deletion(-) -commit 97379c5ea758da3f8b0bc444d5f7fa43753ce610 +commit 0ed893668554fb0758003289f8a6af9bd08b89d1 Author: Lasse Collin -Date: 2013-04-27 22:07:46 +0300 +Date: 2024-06-28 14:20:49 +0300 - Build: Use -Wvla with GCC if supported. + liblzma: ARM64 CRC32: Align the buffer faster - Variable-length arrays are mandatory in C99 but optional in C11. - The code doesn't currently use any VLAs and it shouldn't in the - future either to stay compatible with C11 without requiring any - optional C11 features. + Instead of doing it byte by byte, use the 1/2/4-byte CRC32 instructions. - configure.ac | 1 + - 1 file changed, 1 insertion(+) + src/liblzma/check/crc32_arm64.h | 54 ++++++++++++++++++++++++++++++----------- + 1 file changed, 40 insertions(+), 14 deletions(-) -commit 8957c58609d3987c58aa72b96c436cf565cc4917 -Author: Lasse Collin -Date: 2013-04-15 19:29:09 +0300 +commit 7e99856f66c07852c4e0de7aa01951e9147d86b0 +Author: Sam James +Date: 2024-06-28 14:18:35 +0300 - xzdec: Improve the --help message. - - The options are now ordered in the same order as in xz's help - message. + CI: Speed up Valgrind job by using --trace-children-skip-by-arg=... - Descriptions were added to the options that are ignored. - I left them in parenthesis even if it looks a bit weird - because I find it easier to spot the ignored vs. non-ignored - options from the list that way. + This addresses the issue I mentioned in + 6c095a98fbec70b790253a663173ecdb669108c4 and speeds up the Valgrind + job a bit, because non-xz tools aren't run unnecessarily with + Valgrind by the script tests. - src/xzdec/xzdec.c | 10 +++++----- - 1 file changed, 5 insertions(+), 5 deletions(-) + .github/workflows/ci.yml | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) -commit ed886e1a92534a24401d0e99c11f1dcff3b5220a +commit 2402e8a1ae92676fa0d4cb1b761d7f62f005c098 Author: Lasse Collin -Date: 2013-04-05 19:25:40 +0300 - - Update THANKS. - - THANKS | 2 ++ - 1 file changed, 2 insertions(+) - -commit 5019413a055ce29e660dbbf15e02443cb5a26c59 -Author: Jeff Bastian -Date: 2013-04-03 13:59:17 +0200 +Date: 2024-06-25 16:00:22 +0300 - xzgrep: make the '-h' option to be --no-filename equivalent + Build: Prepend, not append, PTHREAD_CFLAGS to LIBS - * src/scripts/xzgrep.in: Accept the '-h' option in argument parsing. + It shouldn't make any difference because LIBS should be empty + at that point in configure. But prepending is the correct way + because in general the libraries being added might require other + libraries that come later on the command line. - src/scripts/xzgrep.in | 2 +- + configure.ac | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -commit 5ea900cb5ad862bca81316729f92357c1fc040ce +commit 7bb46f2b7b3989c1b589a247a251470f65e91cda Author: Lasse Collin -Date: 2013-03-23 22:25:15 +0200 +Date: 2024-06-25 14:24:29 +0300 - liblzma: Be less picky in lzma_alone_decoder(). + Build: Use AC_LINK_IFELSE to handle implicit function declarations - To avoid false positives when detecting .lzma files, - rare values in dictionary size and uncompressed size fields - were rejected. They will still be rejected if .lzma files - are decoded with lzma_auto_decoder(), but when using - lzma_alone_decoder() directly, such files will now be accepted. - Hopefully this is an OK compromise. + It's more robust in case the compiler allows pre-C99 implicit function + declarations. If an x86 intrinsic is missing and gets treated as + implicit function, the linking step will very probably fail. This + isn't the only way to workaround implicit function declarations but + it might be the simplest and cleanest. - This doesn't affect xz because xz still has its own file - format detection code. This does affect lzmadec though. - So after this commit lzmadec will accept files that xz or - xz-emulating-lzma doesn't. + The problem hasn't been observed in the wild. - NOTE: lzma_alone_decoder() still won't decode all .lzma files - because liblzma's LZMA decoder doesn't support lc + lp > 4. + There are a couple more AC_COMPILE_IFELSE uses in configure.ac. + Of these, Landlock check calls prctl() and in theory could have + the same problem. In practice it doesn't as the check program + looks for several other things too. However, it was changed to + AC_LINK_IFELSE still to look more correct. - Reported here: - http://sourceforge.net/projects/lzmautils/forums/forum/708858/topic/7068827 + Similarly, m4/tuklib_cpucores.m4 and m4/tuklib_physmem.m4 were + updated although they haven't given any trouble either. They + have worked all these years because those check programs rely + on specific headers and types: if headers or types are missing, + compilation will fail. Using the linker makes these checks more + similar to the ones in cmake/tuklib_*.cmake which always link. - src/liblzma/common/alone_decoder.c | 22 ++++++++++++++-------- - src/liblzma/common/alone_decoder.h | 5 +++-- - src/liblzma/common/auto_decoder.c | 2 +- - 3 files changed, 18 insertions(+), 11 deletions(-) + configure.ac | 8 ++++++-- + m4/tuklib_cpucores.m4 | 8 ++++---- + m4/tuklib_physmem.m4 | 17 +++++++++++------ + 3 files changed, 21 insertions(+), 12 deletions(-) -commit bb117fffa84604b6e3811b068c80db82bf7f7b05 +commit 35eb57355ad1c415a838d26192d5af84abb7cf39 Author: Lasse Collin -Date: 2013-03-23 21:55:13 +0200 +Date: 2024-06-24 23:35:59 +0300 - liblzma: Use lzma_block_buffer_bound64() in threaded encoder. + Build: Use AC_LINK_IFELSE instead of -Werror + + AC_COMPILE_IFELSE needed -Werror because Clang <= 14 would merely + warn about the unsupported attribute and implicit function declaration. + Changing to AC_LINK_IFELSE handles the implicit declaration because + the symbol __crc32d is unlikely to exist in libc. + + Note that the other part of the check is that #include + must work. If the header is missing, most compilers give an error + and the linking step won't be attempted. - Now it uses lzma_block_uncomp_encode() if the data doesn't - fit into the space calculated by lzma_block_buffer_bound64(). + Avoiding -Werror makes the check more robust in case CFLAGS contains + warning flags that break -Werror anyway (but this isn't the only check + in configure.ac that has this problem). Using AC_LINK_IFELSE also makes + the check more similar to how it is done in CMakeLists.txt. - src/liblzma/common/stream_encoder_mt.c | 66 +++++++++++++++++++++++++--------- - 1 file changed, 50 insertions(+), 16 deletions(-) + configure.ac | 12 +----------- + 1 file changed, 1 insertion(+), 11 deletions(-) -commit e572e123b55b29527e54ce5f0807f115481d78b9 +commit 5a728813c378cc3c4c9c95793762452418d08f1b Author: Lasse Collin -Date: 2013-03-23 21:51:38 +0200 +Date: 2024-06-24 23:34:34 +0300 - liblzma: Fix another deadlock in the threaded encoder. + Build: Sync the compile check changes from CMakeLists.txt - This race condition could cause a deadlock if lzma_end() was - called before finishing the encoding. This can happen with - xz with debugging enabled (non-debugging version doesn't - call lzma_end() before exiting). + It's nice to keep these in sync. The use of main() will later allow + AC_LINK_IFELSE usage too which may avoid the more fragile -Werror. - src/liblzma/common/stream_encoder_mt.c | 9 ++++++--- - 1 file changed, 6 insertions(+), 3 deletions(-) + configure.ac | 15 ++++++++------- + 1 file changed, 8 insertions(+), 7 deletions(-) -commit b465da5988dd59ad98fda10c2e4ea13d0b9c73bc +commit 5279828635a95abdef82e691fc4979d362780e63 Author: Lasse Collin -Date: 2013-03-23 19:17:33 +0200 +Date: 2024-06-24 20:14:43 +0300 - liblzma: Add lzma_block_uncomp_encode(). + CMake: Not experimental anymore + + While the CMake support has gotten a lot less testing than + the Autotools-based build, the supported features should now + be equal. The output may differ slightly, for example, + liblzma.pc may have + + Libs.private: -pthread -lpthread + + with Autotools on GNU/Linux. CMake doesn't put any options + in Libs.private because on modern glibc the pthread functions + are in libc. The options options aren't required to link static + liblzma into an application. - This also adds a new internal function - lzma_block_buffer_bound64() which is similar to - lzma_block_buffer_bound() but uses uint64_t instead - of size_t. + Autotools-based build doesn't generate or install + lib/cmake/liblzma-*.cmake files. This means that on most + platforms one cannot rely on + + find_package(liblzma 5.2.5 REQUIRED CONFIG) + + or such finding those files. - src/liblzma/api/lzma/block.h | 18 ++++++ - src/liblzma/common/block_buffer_encoder.c | 94 +++++++++++++++++++++---------- - src/liblzma/common/block_buffer_encoder.h | 24 ++++++++ - src/liblzma/liblzma.map | 1 + - 4 files changed, 106 insertions(+), 31 deletions(-) + CMakeLists.txt | 9 ++++++--- + 1 file changed, 6 insertions(+), 3 deletions(-) -commit 9e6dabcf22ef4679f4faaae15ebd5b137ae2fad1 +commit de215a0517645d16343f3a5336d3df884a4f665f Author: Lasse Collin -Date: 2013-03-05 19:14:50 +0200 +Date: 2024-06-25 16:11:13 +0300 - Avoid unneeded use of awk in xzless. - - Use "read" instead of "awk" in xzless to get the version - number of "less". The need for awk was introduced in - the commit db5c1817fabf7cbb9e4087b1576eb26f0747338e. + CMake: Use configure_file() to copy a file - Thanks to Ariel P for the patch. + I had missed this simpler method before. It does create a dependency + so that if .in.h changes the copying is done again. - src/scripts/xzless.in | 3 +-- - 1 file changed, 1 insertion(+), 2 deletions(-) + CMakeLists.txt | 17 +++++++---------- + 1 file changed, 7 insertions(+), 10 deletions(-) -commit e7b424d267a34803db8d92a3515528be2ed45abd +commit e620f35097c0ad20cd76d8258750aa706758ced9 Author: Lasse Collin -Date: 2012-12-14 20:13:32 +0200 +Date: 2024-06-25 15:51:48 +0300 - Make the progress indicator smooth in threaded mode. - - This adds lzma_get_progress() to liblzma and takes advantage - of it in xz. + CMake: Always add pthread flags into CMAKE_REQUIRED_LIBRARIES - lzma_get_progress() collects progress information from - the thread-specific structures so that fairly accurate - progress information is available to applications. Adding - a new function seemed to be a better way than making the - information directly available in lzma_stream (like total_in - and total_out are) because collecting the information requires - locking mutexes. It's waste of time to do it more often than - the up to date information is actually needed by an application. + It was weird to add CMAKE_THREAD_LIBS_INIT in CMAKE_REQUIRED_LIBRARIES + only if CLOCK_MONOTONIC is available. Alternative would be to remove + the thread libs from CMAKE_REQUIRED_LIBRARIES after the check for + pthread_condattr_setclock() but keeping the libs should be fine too. + Then it's ready in case more pthread functions were wanted some day. - src/liblzma/api/lzma/base.h | 22 +++++++++- - src/liblzma/common/common.c | 16 +++++++ - src/liblzma/common/common.h | 6 +++ - src/liblzma/common/stream_encoder_mt.c | 77 +++++++++++++++++++++++++++++++--- - src/liblzma/liblzma.map | 1 + - src/xz/message.c | 20 +++++---- - 6 files changed, 129 insertions(+), 13 deletions(-) + CMakeLists.txt | 6 ++++-- + 1 file changed, 4 insertions(+), 2 deletions(-) -commit 2ebbb994e367f55f2561aa7c9e7451703c171f2f -Author: Lasse Collin -Date: 2012-12-14 11:01:41 +0200 +commit 068a70e54932ca32ca2922aff5a67a62615c650b +Author: Sam James +Date: 2024-06-24 19:25:30 +0100 - liblzma: Fix mythread_sync for nested locking. + CMake: Tweak comments + + Co-authored-by: Lasse Collin - src/common/mythread.h | 5 +++-- - 1 file changed, 3 insertions(+), 2 deletions(-) + CMakeLists.txt | 15 +++++++-------- + 1 file changed, 7 insertions(+), 8 deletions(-) -commit 4c7e28705f6de418d19cc77324ef301f996e01ff +commit 3c95c93bca593bdd54ac5cc01526b12c82c78faa Author: Lasse Collin -Date: 2012-12-13 21:05:36 +0200 +Date: 2024-06-24 22:42:01 +0300 - xz: Mention --threads in --help. - - Thanks to Olivier Delhomme for pointing out that this - was still missing. + CMake: Edit white space for consistency - src/xz/message.c | 4 ++++ - 1 file changed, 4 insertions(+) + CMakeLists.txt | 26 +++++++++++++------------- + 1 file changed, 13 insertions(+), 13 deletions(-) -commit db5c1817fabf7cbb9e4087b1576eb26f0747338e -Author: Jonathan Nieder -Date: 2012-11-19 00:10:10 -0800 +commit 114cba69dbb96003e676c8c87a2e9943b12d065f +Author: Lasse Collin +Date: 2024-06-24 22:41:10 +0300 - xzless: Make "less -V" parsing more robust + CMake: Fix three checks if building with -flto - In v4.999.9beta~30 (xzless: Support compressed standard input, - 2009-08-09), xzless learned to parse ‘less -V’ output to figure out - whether less is new enough to handle $LESSOPEN settings starting - with “|-”. That worked well for a while, but the version string from - ‘less’ versions 448 (June, 2012) is misparsed, producing a warning: + In CMake, check_c_source_compiles() always links too. With + link-time optimization, unused functions may get omitted if + main() doesn't depend on them. Consider the following which + tries to check if somefunction() is available when + has been included: - $ xzless /tmp/test.xz; echo $? - /usr/bin/xzless: line 49: test: 456 (GNU regular expressions): \ - integer expression expected - 0 + #include + int foo(void) { return somefunction(); } + int main(void) { return 0; } - More precisely, modern ‘less’ lists the regexp implementation along - with its version number, and xzless passes the entire version number - with attached parenthetical phrase as a number to "test $a -gt $b", - producing the above confusing message. + LTO may omit foo() completely because the program as a whole doesn't + need it and then the program will link even if the symbol somefunction + isn't available in libc or other library being linked in, and then + the test may pass when it shouldn't. - $ less-444 -V | head -1 - less 444 - $ less -V | head -1 - less 456 (no regular expressions) + What happens if doesn't declare somefunction()? + Shouldn't the test fail in the compilation phase already? It should + but many compilers don't follow the C99 and later standards that + prohibit implicit function declarations. Instead such compilers + assume that somefunction() exists, compilation succeeds (with a + warning), and then linker with LTO omits the call to somefunction(). - So relax the pattern matched --- instead of expecting "less ", - look for a line of the form "less [ (extra parenthetical)]". - While at it, improve the behavior when no matching line is found --- - instead of producing a cryptic message, we can fall back on a LESSPIPE - setting that is supported by all versions of ‘less’. + Change the tests so that they are part of main(). If compiler accepts + implicitly declared functions, LTO cannot omit them because it has to + assume that they might have side effects and thus linking will fail. + On the other hand, if the functions/intrinsics being used are supported, + they might get optimized away but in that case it's fine because they + really are supported. - The implementation uses "awk" for simplicity. Hopefully that’s - portable enough. + It is fine to use __attribute__((target(...))) for main(). At least + it works with GCC 4.9 to 14.1 on x86-64. - Reported-by: Jörg-Volker Peetz - Signed-off-by: Jonathan Nieder + Reported-by: Sam James - src/scripts/xzless.in | 3 ++- - 1 file changed, 2 insertions(+), 1 deletion(-) + CMakeLists.txt | 19 ++++++++----------- + 1 file changed, 8 insertions(+), 11 deletions(-) -commit 65536214a31ecd33b6b03b68a351fb597d3703d6 +commit 78e882205e1f1e91df2af2cb7da00fe205dede99 Author: Lasse Collin -Date: 2012-10-03 15:54:24 +0300 +Date: 2024-06-24 21:19:14 +0300 - xz: Fix the note about --rsyncable on the man page. + CMake: Use MATCHES instead of multiple STREQUAL - src/xz/xz.1 | 17 +++++++++-------- - 1 file changed, 9 insertions(+), 8 deletions(-) + CMakeLists.txt | 11 ++++------- + 1 file changed, 4 insertions(+), 7 deletions(-) -commit 3d93b6354927247a1569caf22ad27b07e97ee904 +commit d3f20382fc1bd865eb70a65455d5022ed05caac8 Author: Lasse Collin -Date: 2012-09-28 20:11:09 +0300 +Date: 2024-06-24 21:06:18 +0300 - xz: Improve handling of failed realloc in xrealloc. - - Thanks to Jim Meyering. + CMake: Improve the comment about LIBS - src/xz/util.c | 14 ++++++++++++-- - 1 file changed, 12 insertions(+), 2 deletions(-) + CMakeLists.txt | 6 ++++++ + 1 file changed, 6 insertions(+) -commit ab225620664e235637833be2329935f9d290ba80 +commit 33ec377729a3889e58d98934b2777b2754a3e045 Author: Lasse Collin -Date: 2012-08-24 16:27:31 +0300 +Date: 2024-06-24 20:01:25 +0300 - A few typo fixes to comments and the xz man page. + CMake: Fix a typo in a message - Thanks to Jim Meyering. + It was spotted with codespell. - configure.ac | 2 +- - src/liblzma/check/sha256.c | 1 - - src/xz/xz.1 | 4 ++-- - 3 files changed, 3 insertions(+), 4 deletions(-) + CMakeLists.txt | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) -commit f3c1ec69d910175ffd431fd82968dd35cec806ed +commit 2a47be823cd6c717bc91fa29c7710c9b1ae0331f Author: Lasse Collin -Date: 2012-08-13 21:40:09 +0300 +Date: 2024-06-24 19:58:54 +0300 - xz: Add a warning to --help about alpha and beta versions. + Document CMake options in INSTALL - src/xz/message.c | 5 +++++ - 1 file changed, 5 insertions(+) + INSTALL | 115 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++----- + 1 file changed, 106 insertions(+), 9 deletions(-) -commit d8eaf9d8278c23c2cf2b7ca5562d4de570d3b5db +commit 3faf4e8079a46bd46e05cd1234365724a6a33802 Author: Lasse Collin -Date: 2012-08-02 17:13:30 +0300 +Date: 2024-06-24 17:18:44 +0300 - Build: Bump gettext version requirement to 0.18. + CI: Don't omit crc32 from the list with CMake anymore - Otherwise too old version of m4/lib-link.m4 gets included - when autoreconf -fi is run. - - configure.ac | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -commit 96e08902b09f0f304d4ff80c6e83ef7fff883f34 -Author: Lasse Collin -Date: 2012-07-17 18:29:08 +0300 - - Update THANKS. - - THANKS | 1 + - 1 file changed, 1 insertion(+) + XZ_CHECKS accepts it but works without too. -commit 3778db1be53e61ff285c573af5ee468803008456 -Author: Lasse Collin -Date: 2012-07-17 18:19:59 +0300 - - liblzma: Make the use of lzma_allocator const-correct. - - There is a tiny risk of causing breakage: If an application - assigns lzma_stream.allocator to a non-const pointer, such - code won't compile anymore. I don't know why anyone would do - such a thing though, so in practice this shouldn't cause trouble. - - Thanks to Jan Kratochvil for the patch. - - src/liblzma/api/lzma/base.h | 4 +++- - src/liblzma/api/lzma/block.h | 6 ++--- - src/liblzma/api/lzma/container.h | 9 +++++--- - src/liblzma/api/lzma/filter.h | 13 ++++++----- - src/liblzma/api/lzma/index.h | 16 ++++++------- - src/liblzma/api/lzma/index_hash.h | 4 ++-- - src/liblzma/common/alone_decoder.c | 6 ++--- - src/liblzma/common/alone_decoder.h | 2 +- - src/liblzma/common/alone_encoder.c | 8 +++---- - src/liblzma/common/auto_decoder.c | 6 ++--- - src/liblzma/common/block_buffer_decoder.c | 2 +- - src/liblzma/common/block_buffer_encoder.c | 4 ++-- - src/liblzma/common/block_decoder.c | 6 ++--- - src/liblzma/common/block_decoder.h | 2 +- - src/liblzma/common/block_encoder.c | 8 +++---- - src/liblzma/common/block_encoder.h | 2 +- - src/liblzma/common/block_header_decoder.c | 4 ++-- - src/liblzma/common/common.c | 10 ++++----- - src/liblzma/common/common.h | 20 +++++++++-------- - src/liblzma/common/easy_buffer_encoder.c | 4 ++-- - src/liblzma/common/filter_buffer_decoder.c | 3 ++- - src/liblzma/common/filter_buffer_encoder.c | 7 +++--- - src/liblzma/common/filter_common.c | 4 ++-- - src/liblzma/common/filter_common.h | 2 +- - src/liblzma/common/filter_decoder.c | 7 +++--- - src/liblzma/common/filter_decoder.h | 2 +- - src/liblzma/common/filter_encoder.c | 2 +- - src/liblzma/common/filter_encoder.h | 2 +- - src/liblzma/common/filter_flags_decoder.c | 2 +- - src/liblzma/common/index.c | 26 ++++++++++----------- - src/liblzma/common/index_decoder.c | 12 +++++----- - src/liblzma/common/index_encoder.c | 6 ++--- - src/liblzma/common/index_encoder.h | 2 +- - src/liblzma/common/index_hash.c | 6 +++-- - src/liblzma/common/outqueue.c | 4 ++-- - src/liblzma/common/outqueue.h | 5 +++-- - src/liblzma/common/stream_buffer_decoder.c | 2 +- - src/liblzma/common/stream_buffer_encoder.c | 3 ++- - src/liblzma/common/stream_decoder.c | 9 ++++---- - src/liblzma/common/stream_decoder.h | 5 +++-- - src/liblzma/common/stream_encoder.c | 10 ++++----- - src/liblzma/common/stream_encoder_mt.c | 16 ++++++------- - src/liblzma/delta/delta_common.c | 4 ++-- - src/liblzma/delta/delta_decoder.c | 6 ++--- - src/liblzma/delta/delta_decoder.h | 5 +++-- - src/liblzma/delta/delta_encoder.c | 6 ++--- - src/liblzma/delta/delta_encoder.h | 3 ++- - src/liblzma/delta/delta_private.h | 2 +- - src/liblzma/lz/lz_decoder.c | 8 +++---- - src/liblzma/lz/lz_decoder.h | 7 +++--- - src/liblzma/lz/lz_encoder.c | 19 ++++++++-------- - src/liblzma/lz/lz_encoder.h | 6 ++--- - src/liblzma/lzma/lzma2_decoder.c | 8 +++---- - src/liblzma/lzma/lzma2_decoder.h | 5 +++-- - src/liblzma/lzma/lzma2_encoder.c | 6 ++--- - src/liblzma/lzma/lzma2_encoder.h | 2 +- - src/liblzma/lzma/lzma_decoder.c | 8 +++---- - src/liblzma/lzma/lzma_decoder.h | 7 +++--- - src/liblzma/lzma/lzma_encoder.c | 7 +++--- - src/liblzma/lzma/lzma_encoder.h | 5 +++-- - src/liblzma/simple/arm.c | 8 ++++--- - src/liblzma/simple/armthumb.c | 8 ++++--- - src/liblzma/simple/ia64.c | 8 ++++--- - src/liblzma/simple/powerpc.c | 8 ++++--- - src/liblzma/simple/simple_coder.c | 10 ++++----- - src/liblzma/simple/simple_coder.h | 36 ++++++++++++++++++++---------- - src/liblzma/simple/simple_decoder.c | 2 +- - src/liblzma/simple/simple_decoder.h | 2 +- - src/liblzma/simple/simple_private.h | 3 ++- - src/liblzma/simple/sparc.c | 8 ++++--- - src/liblzma/simple/x86.c | 8 ++++--- - 71 files changed, 269 insertions(+), 219 deletions(-) - -commit d625c7cf824fd3b61c6da84f56179e94917ff603 -Author: Lasse Collin -Date: 2012-07-05 07:36:28 +0300 - - Tests: Remove tests/test_block.c that had gotten committed accidentally. - - tests/test_block.c | 52 ---------------------------------------------------- - 1 file changed, 52 deletions(-) - -commit 0b09d266cce72bc4841933b171e79551e488927c -Author: Lasse Collin -Date: 2012-07-05 07:33:35 +0300 - - Build: Include macosx/build.sh in the distribution. - - It has been in the Git repository since 2010 but probably - few people have seen it since it hasn't been included in - the release tarballs. :-( - - Makefile.am | 1 + - 1 file changed, 1 insertion(+) + build-aux/ci_build.bash | 10 +--------- + 1 file changed, 1 insertion(+), 9 deletions(-) -commit d6e0b23d4613b9f417893dd96cc168c8005ece3d +commit 1bf83cded2955282fe1a868f08c83d4e5d6dca4a Author: Lasse Collin -Date: 2012-07-05 07:28:53 +0300 +Date: 2024-06-24 17:39:54 +0300 - Build: Include validate_map.sh in the distribution. + CI: Workaround buggy config.guess on Ubuntu 22.04LTS and 24.04LTS - It's required by "make mydist". + Check for the wrong triplet from config.guess and override it with + the --build option on the configure command line. Then i386 assembly + autodetection will work. - Fix also the location of EXTRA_DIST+= so that those files - get distributed also if symbol versioning isn't enabled. + These Ubuntu versions (and as of writing, also Debian unstable) + ship config.guess version 2022-01-09 which contains a bug that + was fixed in version 2022-05-08. It results in a wrong configure + triplet when using CC="gcc -m32" to build i386 binaries. + + Upstream fix: + https://git.savannah.gnu.org/cgit/config.git/commit/?id=f56a7140386d08a531bcfd444d632b28c61a6329 + + More information: + https://mail.gnu.org/archive/html/config-patches/2022-05/msg00003.html - src/liblzma/Makefile.am | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) + build-aux/ci_build.bash | 9 +++++++++ + 1 file changed, 9 insertions(+) -commit 19de545d86097c3954d69ab5d12820387f6a09bc +commit dbcdabf68fee9ed694b68c3a82e6adbeff20b679 Author: Lasse Collin -Date: 2012-07-05 07:24:45 +0300 +Date: 2024-06-24 15:24:52 +0300 - Docs: Fix the name LZMA Utils -> XZ Utils in debug/README. + CI: Use CC="gcc -m32" to get i386 compiler on x86-64 + + The old method put it in CFLAGS which is a wrong place because + config.guess doesn't read CFLAGS. - debug/README | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) + .github/workflows/ci.yml | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) -commit 672eccf57c31a40dfb956b7662db06d43e18618e +commit 0c1e6d900bac127464fb30a854776e1810ab5f16 Author: Lasse Collin -Date: 2012-07-05 07:23:17 +0300 +Date: 2024-06-24 14:54:17 +0300 - Include debug/translation.bash in the distribution. + CI: Let CMake use the CC environment variable - Also fix the script name mentioned in README. + CC from environment is used to initialize CMAKE_C_COMPILER so + setting CMAKE_C_COMPILER explicitly isn't needed. + + The syntax in ci_build.bash was broken in case one wished to put + spaces in CC. - README | 4 ++-- - debug/Makefile.am | 3 +++ - 2 files changed, 5 insertions(+), 2 deletions(-) + build-aux/ci_build.bash | 4 ---- + 1 file changed, 4 deletions(-) -commit cafb523adac1caf305e70a04bc37f25602bf990c +commit a3d6eb797c1bd9b0425ef6754e475e43e62bf075 Author: Lasse Collin -Date: 2012-07-04 22:31:58 +0300 +Date: 2024-06-20 23:25:42 +0300 - xz: Document --block-list better. - - Thanks to Jonathan Nieder. + CMake: Add autodetection for 32-bit x86 CRC assembly usage - src/xz/xz.1 | 8 +++++++- - 1 file changed, 7 insertions(+), 1 deletion(-) + CMakeLists.txt | 33 ++++++++++++++++++--------------- + 1 file changed, 18 insertions(+), 15 deletions(-) -commit c7ff218528bc8f7c65e7ef73c6515777346c6794 +commit dbc14f213e5cf866f1f42b7c6381a91e1189908c Author: Lasse Collin -Date: 2012-07-04 20:01:49 +0300 +Date: 2024-06-20 23:00:59 +0300 - Bump the version number to 5.1.2alpha. + CMake: Move option(XZ_ASM_I386) downwards a few lines - src/liblzma/api/lzma/version.h | 2 +- - src/liblzma/liblzma.map | 2 +- - 2 files changed, 2 insertions(+), 2 deletions(-) + CMakeLists.txt | 16 ++++++++-------- + 1 file changed, 8 insertions(+), 8 deletions(-) -commit 8f3c1d886f93e6478ad509ff52102b2ce7faa999 +commit e5c2b07b489b155c1bebd5cb5e5b94325c2fef1a Author: Lasse Collin -Date: 2012-07-04 20:01:19 +0300 +Date: 2024-06-20 18:45:41 +0300 - Update NEWS for 5.1.2alpha. + DOS: Update Makefile and config.h for the CRC changes - NEWS | 41 +++++++++++++++++++++++++++++++++++++++++ - 1 file changed, 41 insertions(+) + dos/Makefile | 4 ++-- + dos/config.h | 3 +++ + 2 files changed, 5 insertions(+), 2 deletions(-) -commit 0d5fa05466e580fbc458820f87013ae7644e20e5 +commit fe77c4e130d62dc3f9c1de40a18c0c6caa5a4d88 Author: Lasse Collin -Date: 2012-07-04 19:58:23 +0300 +Date: 2024-06-23 15:35:35 +0300 - xz: Fix the version number printed by xz -lvv. + liblzma: Tidy up crc_common.h + + Prefix ARM64_RUNTIME_DETECTION with CRC_ and reorder it to be with + the other ARM64-specific lines. That macro isn't used outside this + file. - The decoder bug was fixed in 5.0.2 instead of 5.0.3. + ARM64 CLMUL implementation doesn't exist yet and thus CRC64_ARM64_CLMUL + isn't used anywhere yet. + + It's not ideal that the single-letter CRC utility macros are here + as they pollute the namespace of the LZ encoder files. Those could + be moved their own crc_macros.h like they were in 5.2.x but in practice + this is fine enough already. - src/xz/list.c | 6 +++--- - 1 file changed, 3 insertions(+), 3 deletions(-) + src/liblzma/check/crc_common.h | 62 ++++++++++++++++++++++++++++-------------- + 1 file changed, 42 insertions(+), 20 deletions(-) -commit df11317985a4165731dde12bb0f0028da0e7b77f +commit 7484d375384f551d475ff44a93590a225e0cb8f6 Author: Lasse Collin -Date: 2012-07-04 17:11:31 +0300 +Date: 2024-06-23 14:22:08 +0300 - Build: Add a comment to configure.ac about symbol versioning. + liblzma: Move lzma_crcXX_table[][] declarations to crc_common.h + + LZ encoder needs lzma_crc32_table[0] but otherwise those tables + are private to the CRC code. In contrast, the other things in + check.h are needed in several places. - configure.ac | 4 ++++ - 1 file changed, 4 insertions(+) + src/liblzma/check/check.h | 18 ------------------ + src/liblzma/check/crc32_small.c | 3 +++ + src/liblzma/check/crc_common.h | 18 ++++++++++++++++++ + src/liblzma/lz/lz_encoder_hash.h | 4 ++-- + 4 files changed, 23 insertions(+), 20 deletions(-) -commit bd9cc179e8be3ef515201d3ed9c7dd79ae88869d +commit 85b081f5d4598342b8c155a2c08697fb2adc372c Author: Lasse Collin -Date: 2012-07-04 17:06:49 +0300 +Date: 2024-06-19 18:38:22 +0300 - Update TODO. + liblzma: Make 32-bit x86 CRC assembly co-exist with CLMUL + + Now runtime detection of CLMUL support can pick between the CLMUL and + the generic assembly implementations. Whatever overhead this has for + builds that omit CLMUL completely isn't important because builds for + any non-ancient system is likely to include the CLMUL code too. + + Handle the CRC tables in crcXX_fast.c files because now these files + are built even when assembly code is used. + + If 32-bit x86 assembly is enabled then it will always be built even + if compiler flags were such that CLMUL would be allowed unconditionally. + That is, runtime detection will be used anyway. This keeps the build + rules simpler. + + In LZ encoder, build and use lzma_lz_hash_table[256] if CLMUL CRC + is used without runtime detection. Previously this wasn't needed + because crc32_table.c included the lzma_crc32_table[][] in the build + unless encoder support had been disabled. Including an 8 KiB table + was silly when only 1 KiB is actually used. So now liblzma is 7 KiB + smaller if CLMUL is enabled without runtime detection. - TODO | 12 ++++++++++-- - 1 file changed, 10 insertions(+), 2 deletions(-) + CMakeLists.txt | 8 ++------ + src/liblzma/check/Makefile.inc | 8 ++------ + src/liblzma/check/crc32_fast.c | 14 ++++++++++++- + src/liblzma/check/crc32_table.c | 42 --------------------------------------- + src/liblzma/check/crc32_x86.S | 14 +++++-------- + src/liblzma/check/crc64_fast.c | 18 +++++++++++++---- + src/liblzma/check/crc64_table.c | 37 ---------------------------------- + src/liblzma/check/crc64_x86.S | 14 +++++-------- + src/liblzma/check/crc_common.h | 18 +++++++++-------- + src/liblzma/check/crc_x86_clmul.h | 5 ----- + src/liblzma/lz/lz_encoder.c | 2 +- + src/liblzma/lz/lz_encoder_hash.h | 30 ++++++++++++++++++++-------- + 12 files changed, 74 insertions(+), 136 deletions(-) -commit 4a238dd9b22f462cac5e199828bf1beb0df05884 +commit 6667d503b5dc9826654e3d9ad505e1883ff6c388 Author: Lasse Collin -Date: 2012-07-04 17:05:46 +0300 +Date: 2024-06-19 17:44:41 +0300 - Document --enable-symbol-versions in INSTALL. + liblzma: CRC: Rename crcXX_generic to lzma_crcXX_generic + + This prepares for the possibility that lzma_crc32_generic and + lzma_crc64_generic are extern functions. - INSTALL | 5 +++++ - 1 file changed, 5 insertions(+) + src/liblzma/check/crc32_fast.c | 6 +++--- + src/liblzma/check/crc64_fast.c | 6 +++--- + 2 files changed, 6 insertions(+), 6 deletions(-) -commit 88ccf47205d7f3aa314d358c72ef214f10f68b43 +commit 1dca581ff20aa1cde61e9e5267d3aeb0af9b6845 Author: Lasse Collin -Date: 2012-07-03 21:16:39 +0300 +Date: 2024-06-20 22:55:22 +0300 - xz: Add incomplete support for --block-list. - - It's broken with threads and when also --block-size is used. + CMake: Define HAVE_CRC_X86_ASM when 32-bit x86 CRC assembly is used - src/xz/args.c | 78 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ - src/xz/args.h | 1 + - src/xz/coder.c | 48 ++++++++++++++++++++++++++++------ - src/xz/coder.h | 4 +++ - src/xz/main.c | 1 + - src/xz/message.c | 6 +++++ - src/xz/xz.1 | 23 +++++++++++++++-- - 7 files changed, 151 insertions(+), 10 deletions(-) + CMakeLists.txt | 3 +++ + 1 file changed, 3 insertions(+) -commit 972179cdcdf5d8949c48ee31737d87d3050b44af +commit f76837acb65676e541d8ee79cd62dbbf27280a62 Author: Lasse Collin -Date: 2012-07-01 18:44:33 +0300 +Date: 2024-05-10 16:00:26 +0300 - xz: Update the man page about the new field in --robot -lvv. + Build: Define HAVE_CRC_X86_ASM when 32-bit x86 CRC assembly is used + + This makes it easier to determine when the CRC tables are needed. - src/xz/xz.1 | 18 +++++++++++++++++- - 1 file changed, 17 insertions(+), 1 deletion(-) + configure.ac | 9 +++++++-- + 1 file changed, 7 insertions(+), 2 deletions(-) -commit 1403707fc64a70976aebe66f8d9a9bd12f73a2c5 +commit 9ce0866b070850da4dc837741ff055faa218bdd6 Author: Lasse Collin -Date: 2012-06-28 10:47:49 +0300 +Date: 2024-06-21 00:46:09 +0300 - liblzma: Check that the first byte of range encoded data is 0x00. - - It is just to be more pedantic and thus perhaps catch broken - files slightly earlier. + CI: Update to the new renamed options in CMakeLists.txt - src/liblzma/lzma/lzma_decoder.c | 8 ++++++-- - src/liblzma/rangecoder/range_decoder.h | 12 +++++++++--- - 2 files changed, 15 insertions(+), 5 deletions(-) + build-aux/ci_build.bash | 10 +++++----- + 1 file changed, 5 insertions(+), 5 deletions(-) -commit eccd8017ffe2c5de473222c4963ec53c62f7fda2 +commit 0232e66d5bc5b01a25a447c657e51747626488ab Author: Lasse Collin -Date: 2012-06-22 19:00:23 +0300 +Date: 2024-06-20 18:12:22 +0300 - Update NEWS from 5.0.4. + CMake: Add XZ_EXTERNAL_SHA256 - NEWS | 37 +++++++++++++++++++++++++++++++++++++ - 1 file changed, 37 insertions(+) + CMakeLists.txt | 121 ++++++++++++++++++++++++++++++++++++++++++++++++++++++--- + 1 file changed, 116 insertions(+), 5 deletions(-) -commit 2e6754eac26a431e8d340c28906f63bcd1e177e8 +commit 4535b80caead82a7ddf7feb988b8fbc773152522 Author: Lasse Collin -Date: 2012-06-22 14:34:03 +0300 +Date: 2024-06-20 18:12:21 +0300 - xz: Update man page date to match the latest update. + CMake: Move threading detection a few lines up + + It feels clearer this way, and when support for external SHA-256 + is added, this will keep the order of the library detection the + same as in configure.ac (check for pthreads before libmd) although + it shouldn't matter in practice. - src/xz/xz.1 | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) + CMakeLists.txt | 176 ++++++++++++++++++++++++++++----------------------------- + 1 file changed, 88 insertions(+), 88 deletions(-) -commit b3235a0b1af45d5e1244cbe3191516966c076fa0 +commit 94d062dbac34d366eb26625034200cc3457e6645 Author: Lasse Collin -Date: 2012-06-18 21:27:47 +0300 +Date: 2024-06-20 18:12:21 +0300 - Docs: Language fix to 01_compress_easy.c. + CMake: Move the sandbox code out of the liblzma section - Thanks to Jonathan Nieder. + Sandboxing is for the command line tools, not liblzma. + No functional changes. - doc/examples/01_compress_easy.c | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) + CMakeLists.txt | 214 ++++++++++++++++++++++++++++----------------------------- + 1 file changed, 107 insertions(+), 107 deletions(-) -commit f1675f765fe228cb5a5f904f853445a03e33cfe9 +commit 75ce4797d49621710e6da95d8cb91541028c6d68 Author: Lasse Collin -Date: 2012-06-14 20:15:30 +0300 +Date: 2024-06-20 18:12:21 +0300 - Fix the top-level Makefile.am for the new example programs. + CMake: Keep existing options in LIBS when adding -lrt + + This makes no difference yet because -lrt is currently the only option + that might be added to LIBS. - Makefile.am | 12 ++++++++++-- - 1 file changed, 10 insertions(+), 2 deletions(-) + CMakeLists.txt | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) -commit 3a0c5378abefaf86aa39a62a7c9682bdb21568a1 +commit 47aaa92516fd9609821d04e5e94ca6558e56d62b Author: Lasse Collin -Date: 2012-06-14 10:52:33 +0300 +Date: 2024-06-15 18:07:04 +0300 - Docs: Add new example programs. + CMake: Don't install scripts if the xz tool isn't built - These have more comments than the old examples and - human-readable error messages. More tutorial-like examples - are needed but these are a start. + The scripts need the xz tool. - doc/examples/00_README.txt | 27 ++++ - doc/examples/01_compress_easy.c | 297 ++++++++++++++++++++++++++++++++++++++ - doc/examples/02_decompress.c | 287 ++++++++++++++++++++++++++++++++++++ - doc/examples/03_compress_custom.c | 193 +++++++++++++++++++++++++ - doc/examples/Makefile | 23 +++ - 5 files changed, 827 insertions(+) + CMakeLists.txt | 11 +++++++++-- + tests/tests.cmake | 2 +- + 2 files changed, 10 insertions(+), 3 deletions(-) -commit 1bd2c2c553e30c4a73cfb82abc6908efd6be6b8d +commit fb50c6ba1d4c9405e5b12b5988b01a3002638c5d Author: Lasse Collin -Date: 2012-06-14 10:33:27 +0300 +Date: 2024-06-15 18:07:04 +0300 - Docs: Move xz_pipe_comp.c and xz_pipe_decomp.c to doc/examples_old. - - It is good to keep these around to so that if someone has - copied the decompressor bug from xz_pipe_decomp.c he has - an example how to easily fix it. + CMake: Add XZ_TOOL_XZDEC and XZ_TOOL_LZMADEC - doc/{examples => examples_old}/xz_pipe_comp.c | 0 - doc/{examples => examples_old}/xz_pipe_decomp.c | 0 - 2 files changed, 0 insertions(+), 0 deletions(-) + CMakeLists.txt | 15 ++++++++++++++- + 1 file changed, 14 insertions(+), 1 deletion(-) -commit 905f0ab5b5ce544d4b68a2ed6077df0f3d021292 +commit def767f7d18ccbd81cd5e5b46c8b6031f3a1de34 Author: Lasse Collin -Date: 2012-06-14 10:33:01 +0300 +Date: 2024-06-15 18:07:04 +0300 - Docs: Fix a bug in xz_pipe_decomp.c example program. + CMake: Add XZ_TOOL_LZMAINFO - doc/examples/xz_pipe_decomp.c | 10 +++++++++- - 1 file changed, 9 insertions(+), 1 deletion(-) + CMakeLists.txt | 4 +++- + 1 file changed, 3 insertions(+), 1 deletion(-) -commit 4bd1a3bd5fdf4870b2f96dd0b8a21657c8a58ad8 +commit 5600e370fb7e11eafabc6c3ef5bf6510e859f4f0 Author: Lasse Collin -Date: 2012-05-30 23:14:33 +0300 +Date: 2024-06-15 18:07:04 +0300 - Translations: Update the French translation. - - Thanks to Adrien Nader. + CMake: Add XZ_TOOL_XZ - po/fr.po | 148 ++++++++++++++++++++++++++++++++++----------------------------- - 1 file changed, 79 insertions(+), 69 deletions(-) + CMakeLists.txt | 4 +++- + 1 file changed, 3 insertions(+), 1 deletion(-) -commit d2e836f2f3a87df6fe6bb0589b037db51205d910 +commit 6a3c4aaa43a90da441e1156c5ffd2e6098f5521f Author: Lasse Collin -Date: 2012-05-29 23:42:37 +0300 +Date: 2024-06-15 18:07:04 +0300 - Translations: Update the German translation. + Windows: Drop Visual Studio 2013 support + + This simplifies things a little. Building liblzma with VS2013 probably + still worked but building the command line tools was not supported. - The previous only included the new strings in v5.0. + Microsoft ended support for VS2013 on 2024-04. - po/de.po | 229 +++++++++++++++++++++++++++++++++++++-------------------------- - 1 file changed, 133 insertions(+), 96 deletions(-) + CMakeLists.txt | 9 +++++++-- + src/common/sysdefs.h | 6 +----- + windows/INSTALL-MSVC.txt | 8 ++------ + 3 files changed, 10 insertions(+), 13 deletions(-) -commit c9a16151577ba459afd6e3528df23bc0ddb95171 +commit 5d5c92b26246936461a635dda1f95740d7de2058 Author: Lasse Collin -Date: 2012-05-29 22:26:27 +0300 +Date: 2024-06-15 18:07:04 +0300 - Translations: Update the German translation. + CMake: Add XZ_TOOL_SCRIPTS - po/de.po | 169 ++++++++++++++++++++++++++++++++++----------------------------- - 1 file changed, 91 insertions(+), 78 deletions(-) + CMakeLists.txt | 44 +++++++++++++++++++++++++++++--------------- + 1 file changed, 29 insertions(+), 15 deletions(-) -commit 1530a74fd48f8493372edad137a24541efe24713 +commit d274a2bc00d235f07e96aaf82c149794cfe82b12 Author: Lasse Collin -Date: 2012-05-29 22:14:21 +0300 +Date: 2024-06-15 18:07:04 +0300 - Translations: Update Polish translation. + CMake: Add XZ_DOC - po/pl.po | 283 +++++++++++++++++++++++++++++++++++++-------------------------- - 1 file changed, 165 insertions(+), 118 deletions(-) + CMakeLists.txt | 45 ++++++++++++++++++++++++--------------------- + 1 file changed, 24 insertions(+), 21 deletions(-) -commit d8db706acb8316f9861abd432cfbe001dd6d0c5c +commit 188143a50ade67253ed256608f50f78aa1380403 Author: Lasse Collin -Date: 2012-05-28 20:42:11 +0300 +Date: 2024-06-20 21:53:03 +0300 - liblzma: Fix possibility of incorrect LZMA_BUF_ERROR. - - lzma_code() could incorrectly return LZMA_BUF_ERROR if - all of the following was true: + CMake: Refactor XZ_SYMBOL_VERSIONING to match configure.ac - - The caller knows how many bytes of output to expect - and only provides that much output space. + Make the available options and their behavior match + --enable-symbol-versions in configure.ac. - - When the last output bytes are decoded, the - caller-provided input buffer ends right before - the LZMA2 end of payload marker. So LZMA2 won't - provide more output anymore, but it won't know it - yet and thus won't return LZMA_STREAM_END yet. + Don't enable symbol versions on Linux if not using glibc. Previously + the generic variant was selected on Microblaze or if using NVHPC + without checking that libc is glibc. - - A BCJ filter is in use and it hasn't left any - unfiltered bytes in the temp buffer. This can happen - with any BCJ filter, but in practice it's more likely - with filters other than the x86 BCJ. + Leave the cache variable to "auto" or "yes" if that was specified + instead of setting it to the autodetected value by default. A downside + is that one cannot easily see which variant the autodetection code + has selected. The same applies to XZ_SANDBOX and XZ_THREADS though. + + CMakeLists.txt | 125 ++++++++++++++++++++++++++++++++++----------------------- + 1 file changed, 75 insertions(+), 50 deletions(-) + +commit cc52ef8ed3b75a581262c587f6c06c213a550f86 +Author: Lasse Collin +Date: 2024-06-15 18:07:04 +0300 + + CMake: Use the same option list for XZ_THREADS as in configure.ac - Another situation where the bug can be triggered happens - if the uncompressed size is zero bytes and no output space - is provided. In this case the decompression can fail even - if the whole input file is given to lzma_code(). + Also clarify that "yes" will fail if no threading support is found. + If no threading is wanted, it has to be disabled manually. - A similar bug was fixed in XZ Embedded on 2011-09-19. + configure.ac doesn't behave this way at the moment. Instead it + assumes pthreads to be present if not targeting Windows. If pthreads + actually are missing, the build fails later. - src/liblzma/simple/simple_coder.c | 2 +- - tests/Makefile.am | 4 +- - tests/test_bcj_exact_size.c | 112 ++++++++++++++++++++++++++++++++++++++ - 3 files changed, 116 insertions(+), 2 deletions(-) + CMakeLists.txt | 18 ++++++++++-------- + 1 file changed, 10 insertions(+), 8 deletions(-) -commit 3f94b6d87f1b8f1c421ba548f8ebb83dca9c8cda +commit 37f7af3452bab0a34ce320c2ad532835f18752d9 Author: Lasse Collin -Date: 2012-05-28 15:38:32 +0300 +Date: 2024-06-15 18:07:04 +0300 - Update THANKS. + CMake: Use the same option list for XZ_SANDBOX as in configure.ac + + It's simpler to document this way. - THANKS | 1 + - 1 file changed, 1 insertion(+) + CMakeLists.txt | 20 ++++++++++---------- + 1 file changed, 10 insertions(+), 10 deletions(-) -commit 7769ea051d739a38a1640fd448cf5eb83cb119c6 +commit c715dec8e800b65145918cfb0ee9bbc90faa8aad Author: Lasse Collin -Date: 2012-05-28 15:37:43 +0300 +Date: 2024-06-15 18:07:04 +0300 - xz: Don't show a huge number in -vv when memory limit is disabled. + CMake: Fix indentation - src/xz/message.c | 12 +++++++++++- - 1 file changed, 11 insertions(+), 1 deletion(-) + CMakeLists.txt | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) -commit ec921105725e4d3ef0a683dd83eee6f24ab60ccd +commit ea379f2f180befabd2039342db8eaeb757fdd2b7 Author: Lasse Collin -Date: 2012-05-27 22:30:17 +0300 +Date: 2024-06-15 18:07:04 +0300 - xz: Document the "summary" lines of --robot -lvv. + CMake: Add warning options for GCC and Clang - This documents only the columns that are in v5.0. - The new columns added in the master branch aren't - necessarily stable yet. + The list was copied from configure.ac and should be kept in sync. + (Pretend that the deleted comment in CMakeLists.txt didn't exist.) + + There is no need to add equivalent of --enable-werror as CMake >= 3.24 + supports -DCMAKE_COMPILE_WARNING_AS_ERROR=ON. - src/xz/xz.1 | 19 +++++++++++++++++++ - 1 file changed, 19 insertions(+) + CMakeLists.txt | 64 +++++++++++++++++++++++++++++++++++++++++++++++++++++----- + 1 file changed, 59 insertions(+), 5 deletions(-) -commit 27d24eb0a9f6eed96d6a4594c2b0bf7a91d29f9a +commit 74223338197b7dfcd69f56df78b6502805a75f23 Author: Lasse Collin -Date: 2012-05-27 21:53:20 +0300 +Date: 2024-06-15 18:07:04 +0300 - xz: Fix output of verbose --robot --list modes. + CMake: Use \040 instead of \x20 for a space - It printed the filename in "filename (x/y)" format - which it obviously shouldn't do in robot mode. + This is for consistency with 4c81c9611f8b2e1ad65eb7fa166afc570c58607e + where \040 has to be used because \0x20F gets interpret at three hex + digits. Octals escapes are never longer than three digits. - src/xz/message.c | 2 +- + CMakeLists.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -commit ab25b82a91754d9388c89abddf806424671d9431 +commit e8854b6bdc956c46dc4232bd07c17163034a00f2 Author: Lasse Collin -Date: 2012-05-24 18:33:54 +0300 +Date: 2024-06-15 18:07:04 +0300 - Build: Upgrade m4/acx_pthread.m4 to the latest version. + CMake: Add XZ_ASSUME_RAM - m4/ax_pthread.m4 | 98 +++++++++++++++++++++++++++++++++++--------------------- - 1 file changed, 62 insertions(+), 36 deletions(-) + CMakeLists.txt | 4 +++- + 1 file changed, 3 insertions(+), 1 deletion(-) -commit d05d6d65c41a4bc83f162fa3d67c5d84e8751634 +commit e1127e75cb82e0385f02c995771d6fe1420f43c5 Author: Lasse Collin -Date: 2012-05-10 21:15:17 +0300 +Date: 2024-06-15 18:07:04 +0300 - Update THANKS. + CMake: Rename liblzma_INSTALL_CMAKEDIR to XZ_INSTALL_CMAKEDIR - THANKS | 1 + - 1 file changed, 1 insertion(+) + CMakeLists.txt | 6 +++--- + 1 file changed, 3 insertions(+), 3 deletions(-) -commit e077391982f9f28dbfe542bba8800e7c5b916666 +commit 96abfe98c15e431a50a6a31015c5bb05540ab2ff Author: Lasse Collin -Date: 2012-05-10 21:14:16 +0300 +Date: 2024-06-15 18:07:04 +0300 - Docs: Cleanup line wrapping a bit. + CMake: Refactor ADDITIONAL_CHECK_TYPES to XZ_CHECKS + + Now "crc32" is in the list too for completeness but it doesn't + actually have any effect. The description of the cache variable + says that "crc32 is always built" so it should be clear enough. - README | 12 ++++++------ - doc/history.txt | 49 +++++++++++++++++++++++++------------------------ - 2 files changed, 31 insertions(+), 30 deletions(-) + CMakeLists.txt | 14 +++++++------- + tests/tests.cmake | 17 ++++++++--------- + 2 files changed, 15 insertions(+), 16 deletions(-) -commit fc39849c350225c6a1cd7f6e6adff1020521eabc -Author: Benno Schulenberg -Date: 2012-03-13 22:04:04 +0100 +commit 679500ffe00ecb4f02292129e7529ab7392f3943 +Author: Lasse Collin +Date: 2024-06-15 18:07:04 +0300 - Fix a few typos and add some missing articles in some documents. + CMake: Rename the cache variable POSIX_SHELL to XZ_POSIX_SHELL - Also hyphenate several compound adjectives. - - Signed-off-by: Benno Schulenberg + We still need the variable POSIX_SHELL for configure_file() + but it doesn't need to be a cache variable. - AUTHORS | 6 +++--- - README | 42 ++++++++++++++++++++--------------------- - doc/faq.txt | 24 ++++++++++++------------ - doc/history.txt | 58 ++++++++++++++++++++++++++++----------------------------- - 4 files changed, 65 insertions(+), 65 deletions(-) + CMakeLists.txt | 7 ++++--- + 1 file changed, 4 insertions(+), 3 deletions(-) -commit 29fa0566d5df199cb9acb2d17bf7eea61acc7fa1 +commit e5c0eb2e50e5522a0a55e7ba83fe49b04c8a6eef Author: Lasse Collin -Date: 2012-04-29 11:51:25 +0300 +Date: 2024-06-15 18:07:04 +0300 - Windows: Update notes about static linking with MSVC. + CMake: Rename ENCODERS and DECODERS to use XZ_ prefix - windows/README-Windows.txt | 13 +++++++++---- - 1 file changed, 9 insertions(+), 4 deletions(-) + CMakeLists.txt | 34 +++++++++++++++++----------------- + tests/tests.cmake | 4 ++-- + 2 files changed, 19 insertions(+), 19 deletions(-) -commit aac1b31ea4e66cf5a7a8c116bdaa15aa45e6c56e +commit e7785e2061f95d44aa6c0856b09cc0fbad7d6154 Author: Lasse Collin -Date: 2012-04-19 15:25:26 +0300 +Date: 2024-06-15 18:07:04 +0300 - liblzma: Remove outdated comments. + CMake: Rename MATCH_FINDERS to XZ_MATCH_FINDERS - src/liblzma/simple/simple_coder.c | 3 --- - src/liblzma/simple/simple_private.h | 3 +-- - 2 files changed, 1 insertion(+), 5 deletions(-) + CMakeLists.txt | 6 +++--- + 1 file changed, 3 insertions(+), 3 deletions(-) -commit df14a46013bea70c0bd35be7821b0b9108f97de7 +commit 63294806b488a27a28a0960f6a257695dd2b569a Author: Lasse Collin -Date: 2012-04-19 14:17:52 +0300 +Date: 2024-06-15 18:07:04 +0300 - DOS: Link against DJGPP's libemu to support FPU emulation. - - This way xz should work on 386SX and 486SX. Floating point - only is needed for verbose output in xz. + CMake: Rename SYMBOL_VERSIONING to XZ_SYMBOL_VERSIONING - dos/Makefile | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) + CMakeLists.txt | 9 +++++---- + 1 file changed, 5 insertions(+), 4 deletions(-) -commit 03ed742a3a4931bb5c821357832083b26f577b13 +commit ad245b133675d285bca5d48123062e9d1e3f747e Author: Lasse Collin -Date: 2012-04-19 14:02:25 +0300 +Date: 2024-06-15 18:07:04 +0300 - liblzma: Fix Libs.private in liblzma.pc to include -lrt when needed. + CMake: Rename ENABLE_THREADS to XZ_THREADS - src/liblzma/liblzma.pc.in | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) + CMakeLists.txt | 24 +++++++++++------------- + 1 file changed, 11 insertions(+), 13 deletions(-) -commit 8c5b13ad59df70f49429bfdfd6ac120b8f892fda +commit 4250d4de32e66e558cc2ebe73b05255633c933ed Author: Lasse Collin -Date: 2012-04-19 13:58:55 +0300 +Date: 2024-06-15 18:07:04 +0300 - Docs: Update MINIX 3 information in INSTALL. + CMake: Rename ENABLE_SANDBOX to XZ_SANDBOX - INSTALL | 8 +++++--- - 1 file changed, 5 insertions(+), 3 deletions(-) + CMakeLists.txt | 23 +++++++++++------------ + 1 file changed, 11 insertions(+), 12 deletions(-) -commit c7376fc415a1566f38b2de4b516a17013d516a8b +commit 0fdcd0c582f1a38542cd647dde449d9447d5888d Author: Lasse Collin -Date: 2012-02-22 14:23:13 +0200 +Date: 2024-06-15 18:07:04 +0300 - Update THANKS. + CMake: Rename ENABLE_X86_ASM to XZ_ASM_I386 - THANKS | 1 + - 1 file changed, 1 insertion(+) + CMakeLists.txt | 10 +++++----- + 1 file changed, 5 insertions(+), 5 deletions(-) -commit cff070aba6281ba743d29a62b8c0c66e5da4b2a6 +commit e017d5526e316003fdb2a3f76acbb83443f14ddf Author: Lasse Collin -Date: 2012-02-22 14:02:34 +0200 +Date: 2024-06-15 18:07:04 +0300 - Fix exit status of xzgrep when grepping binary files. - - When grepping binary files, grep may exit before it has - read all the input. In this case, gzip -q returns 2 (eating - SIGPIPE), but xz and bzip2 show SIGPIPE as the exit status - (e.g. 141). This causes wrong exit status when grepping - xz- or bzip2-compressed binary files. + CMake: Rename CREATE_XZ_SYMLINKS to XZ_TOOL_SYMLINKS - The fix checks for the special exit status that indicates SIGPIPE. - It uses kill -l which should be supported everywhere since it - is in both SUSv2 (1997) and POSIX.1-2008. - - Thanks to James Buren for the bug report. + This only affects the names unxz and xzcat. The xz-prefixed script + symlinks (xzfgrep and such) are always created if scripts are enabled. - src/scripts/xzgrep.in | 3 ++- - 1 file changed, 2 insertions(+), 1 deletion(-) + CMakeLists.txt | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) -commit 41cafb2bf9beea915710ee68f05fe929cd17759c +commit 04cac14fcb9fb302c24e90b04ca4b77d3717b50c Author: Lasse Collin -Date: 2012-02-22 12:08:43 +0200 +Date: 2024-06-15 18:07:04 +0300 - Update THANKS. + CMake: Rename CREATE_LZMA_SYMLINKS to XZ_TOOL_LZMA_SYMLINKS + + Update the description too. + + It affects creation of not only the legacy lzma, unlzma, lzcat symlinks + but also lzgrep and other legacy names for the scripts. The last + LZMA Utils release was made in 2008 but these names are still used + in some places to handle .lzma files. - THANKS | 1 + - 1 file changed, 1 insertion(+) + CMakeLists.txt | 7 ++++--- + 1 file changed, 4 insertions(+), 3 deletions(-) -commit 2dcea03712fa881930d69ec9eff70855c3d126d9 +commit 612ccebf884eb1a9b6848e230c24f97a03fe917a Author: Lasse Collin -Date: 2012-02-22 12:00:16 +0200 +Date: 2024-06-15 18:07:04 +0300 - Fix compiling with IBM XL C on AIX. + CMake: Rename ALLOW_ARM64_CRC32 to XZ_ARM64_CRC32 + + Update description too. - INSTALL | 36 ++++++++++++++++++++++-------------- - configure.ac | 6 +++++- - 2 files changed, 27 insertions(+), 15 deletions(-) + CMakeLists.txt | 6 +++--- + 1 file changed, 3 insertions(+), 3 deletions(-) -commit 7db6bdf4abcf524115be2cf5659ed540cef074c5 +commit 3dcc12290d6dffbe7f10f501c141d325bad65901 Author: Lasse Collin -Date: 2012-01-10 17:13:03 +0200 +Date: 2024-06-15 18:07:04 +0300 - Tests: Fix a compiler warning with _FORTIFY_SOURCE. + CMake: Rename ALLOW_CLMUL_CRC to XZ_CLMUL_CRC - Reported here: - http://sourceforge.net/projects/lzmautils/forums/forum/708858/topic/4927385 + Update description too. - tests/create_compress_files.c | 3 ++- - 1 file changed, 2 insertions(+), 1 deletion(-) + CMakeLists.txt | 6 +++--- + 1 file changed, 3 insertions(+), 3 deletions(-) -commit 694952d545b6cf056547893ced69486eff9ece55 +commit 4b8faa72442da9aa1a356f5848aae798d8588a7d Author: Lasse Collin -Date: 2011-12-19 21:21:29 +0200 +Date: 2024-06-15 18:07:04 +0300 - Docs: Explain the stable releases better in README. + CMake: Rename ENABLE_DOXYGEN to XZ_DOXYGEN - README | 6 +++++- - 1 file changed, 5 insertions(+), 1 deletion(-) + CMakeLists.txt | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) -commit 418fe668b3c53a9a20020b6cc652aaf25c734b29 +commit b56273ae575bac350e50b0c689269dcab04b04b3 Author: Lasse Collin -Date: 2011-11-07 13:07:52 +0200 +Date: 2024-06-15 18:07:04 +0300 - xz: Show minimum required XZ Utils version in xz -lvv. - - Man page wasn't updated yet. + CMake: Rename LZIP_DECODER to XZ_LZIP_DECODER - src/xz/list.c | 63 +++++++++++++++++++++++++++++++++++++++++++++++++++++------ - 1 file changed, 57 insertions(+), 6 deletions(-) + CMakeLists.txt | 4 ++-- + tests/tests.cmake | 2 +- + 2 files changed, 3 insertions(+), 3 deletions(-) -commit 7081d82c37326bac97184e338345fa1c327e3580 +commit 2343992fcbe8b436da6df888be37713cccaff0ab Author: Lasse Collin -Date: 2011-11-04 17:57:16 +0200 +Date: 2024-06-15 18:07:04 +0300 - xz: Fix a typo in a comment. - - Thanks to Bela Lubkin. + CMake: Rename MICROLZMA_ENCODER/DECODER to XZ_MICROLZMA_ENCODER/DECODER - src/xz/args.c | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) + CMakeLists.txt | 8 ++++---- + tests/tests.cmake | 2 +- + 2 files changed, 5 insertions(+), 5 deletions(-) -commit 232fe7cd70ad258d6a37f17e860e0f1b1891eeb5 +commit 96f0a6632cc0598a26d93255b0c444df18dc7891 Author: Lasse Collin -Date: 2011-11-03 17:08:02 +0200 +Date: 2024-06-15 18:07:04 +0300 - Update THANKS. + CMake: Rename ENABLE_SMALL to XZ_SMALL - THANKS | 1 + - 1 file changed, 1 insertion(+) + CMakeLists.txt | 14 +++++++------- + 1 file changed, 7 insertions(+), 7 deletions(-) -commit 74d2bae4d3449c68453b0473dd3430ce91fd90c1 +commit 29f77c7b707f2458fb047e77497354b195e05b14 Author: Lasse Collin -Date: 2011-11-03 17:07:22 +0200 +Date: 2024-06-15 18:07:04 +0300 - xz: Fix xz on EBCDIC systems. + CMake: Rename ENABLE_NLS to XZ_NLS + + Also update the description to mention that this affects installation + of translated man pages too. - Thanks to Chris Donawa. + Prefixing the cache variables with the project name helps if + the package is used as a subproject in another package. + It also makes the package-specific options group more nicely + in ccmake and cmake-gui. - src/xz/coder.c | 5 ++++- - 1 file changed, 4 insertions(+), 1 deletion(-) + CMakeLists.txt | 28 +++++++++++++++------------- + 1 file changed, 15 insertions(+), 13 deletions(-) -commit 4ac4923f47cc0ef97dd9ca5cfcc44fc53eeab34a +commit ac05f1b0d7cda1e7ae79775a8dfecc54601d7f1c Author: Lasse Collin -Date: 2011-10-23 17:09:10 +0300 +Date: 2024-06-15 23:34:29 +0300 - Update THANKS. + CMake: Link Threads::Threads as PRIVATE to liblzma + + This way pthread options aren't passed to the linker when linking + against shared liblzma but they are still passed when linking against + static liblzma. (Also, one never needs the include path of the + threading library to use liblzma since liblzma's API headers + don't #include . But tends to be in the + default include path so here this change makes no difference.) + + One cannot mix target_link_libraries() calls that use the scope + (PRIVATE, PUBLIC, or INTERFACE) keyword and calls that don't use it. + The calls without the keyword are like PUBLIC except perhaps when + they aren't, or something like that... It seems best to always + specify a scope keyword as the meanings of those three keywords + at least are clear. - THANKS | 1 + - 1 file changed, 1 insertion(+) + CMakeLists.txt | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) -commit ab50ae3ef40c81e5bf613905ca3fd636548b75e7 +commit 82986d8c691a294c78b48d8391303e5c428b5437 Author: Lasse Collin -Date: 2011-10-23 17:08:14 +0300 +Date: 2024-06-16 19:39:32 +0300 - liblzma: Fix invalid free() in the threaded encoder. - - It was triggered if initialization failed e.g. due to - running out of memory. - - Thanks to Arkadiusz Miskiewicz. + CMake: Add empty lines - src/liblzma/common/outqueue.c | 4 ++++ - 1 file changed, 4 insertions(+) + CMakeLists.txt | 2 ++ + 1 file changed, 2 insertions(+) -commit 6b620a0f0813d28c3c544b4ff8cb595b38a6e908 +commit 2aecffe0f0e14f3ef635e8cd7b405420f2385de2 Author: Lasse Collin -Date: 2011-10-23 17:05:55 +0300 +Date: 2024-06-16 19:37:36 +0300 - liblzma: Fix a deadlock in the threaded encoder. + CMake: Use CMAKE_THREAD_LIBS_INIT in liblzma.pc only with pthreads - It was triggered when reinitializing the encoder, - e.g. when encoding two files. + This shouldn't make much difference in practice as on Windows + no flags are needed anyway and unitialized variable (when threading + is disabled) expands to empty. But it's clearer this way. - src/liblzma/common/stream_encoder_mt.c | 4 +++- - 1 file changed, 3 insertions(+), 1 deletion(-) + CMakeLists.txt | 8 +++++++- + 1 file changed, 7 insertions(+), 1 deletion(-) -commit bd52cf150ecd51e3ab63a9cc1a3cff6a77500178 +commit 664918bd3635ea8e773f06022286ecb0c485166c Author: Lasse Collin -Date: 2011-09-06 12:03:41 +0300 +Date: 2024-06-17 18:20:14 +0300 - Build: Fix "make check" on Windows. + Update THANKS - tests/Makefile.am | 7 +++++-- - windows/build.bash | 2 ++ - 2 files changed, 7 insertions(+), 2 deletions(-) + THANKS | 3 +++ + 1 file changed, 3 insertions(+) -commit 5c5b2256969ac473001b7d67615ed3bd0a54cc82 +commit 5ca96a93488d0f5a530c78b274cac317453807ff Author: Lasse Collin -Date: 2011-08-09 21:19:13 +0300 +Date: 2024-06-16 19:25:07 +0300 - Update THANKS. + CMake: Use native newlines in liblzma.pc + + vcpkg doesn't specify the newline type so it should be fine to + use native newlines in liblzma.pc on Windows. - THANKS | 2 ++ - 1 file changed, 2 insertions(+) + CMakeLists.txt | 4 +--- + 1 file changed, 1 insertion(+), 3 deletions(-) -commit 5b1e1f10741af9e4bbe4cfc3261fb7c7b04f7809 +commit ebd155c3a1b87411edae06d3bdaa9659ec057522 Author: Lasse Collin -Date: 2011-08-09 21:16:44 +0300 +Date: 2024-06-16 19:18:56 +0300 - Workaround unusual SIZE_MAX on SCO OpenServer. + CMake: Use relative paths in liblzma.pc if possible + + Now liblzma.pc can be relocatable only if using CMake >= 3.20 + but that should be OK as now we shouldn't get broken liblzma.pc + if CMAKE_INSTALL_LIBDIR or CMAKE_INSTALL_INCLUDEDIR contain an + absolute path. + + Thanks to Eli Schwartz. - src/common/sysdefs.h | 9 ++++++--- - 1 file changed, 6 insertions(+), 3 deletions(-) + CMakeLists.txt | 18 ++++++++++++++---- + 1 file changed, 14 insertions(+), 4 deletions(-) -commit e9ed88126eee86e2511fa42681a5c7104820cf0a +commit 7a366d93cfd74ce10201db400be8836199944e36 Author: Lasse Collin -Date: 2011-08-06 20:37:28 +0300 +Date: 2024-06-16 18:33:08 +0300 - Run the scripts with the correct shell in test_scripts.sh. + Revert "CMake: Set only "prefix" as an absolute path in liblzma.pc" - The scripts are now made executable in the build tree. - This way the scripts can be run like programs in - test_scripts.sh. Previously test_scripts.sh always - used sh but it's not correct if @POSIX_SHELL@ is set - to something else by configure. + This reverts commit 5d1c649ba9eb7a5b9371252ebfbc2911dc774e69. - Thanks to Jonathan Nieder for the patch. + While CMAKE_INSTALL_ tend to be relative paths, they don't need + to be. Thus the commit was broken. A fancier method is required. + + Thanks to Eli Schwartz for the bug report and explanation. - configure.ac | 8 ++++---- - tests/test_scripts.sh | 8 ++++---- - 2 files changed, 8 insertions(+), 8 deletions(-) + CMakeLists.txt | 6 +++--- + 1 file changed, 3 insertions(+), 3 deletions(-) -commit 1c673e5681720491a74fc4b2992e075f47302c22 +commit 30a2d5d51006301a3ddab5ef1f5ff0a9d74dce6f Author: Lasse Collin -Date: 2011-07-31 11:01:47 +0300 +Date: 2024-06-16 13:39:37 +0300 - Fix exit status of "xzdiff foo.xz bar.xz". - - xzdiff was clobbering the exit status from diff in a case - statement used to analyze the exit statuses from "xz" when - its operands were two compressed files. Save and restore - diff's exit status to fix this. + liblzma: CRC CLMUL: Omit is_arch_extension_supported() when not needed - The bug is inherited from zdiff in GNU gzip and was fixed - there on 2009-10-09. + On E2K the function compiles only due to compiler emulation but the + function is never used. It's cleaner to omit the function when it's + not needed even though it's a "static inline" function. - Thanks to Jonathan Nieder for the patch and - to Peter Pallinger for reporting the bug. + Thanks to Ilya Kurdyukov. - src/scripts/xzdiff.in | 2 ++ - tests/Makefile.am | 4 +++- - tests/test_scripts.sh | 54 +++++++++++++++++++++++++++++++++++++++++++++++++++ - 3 files changed, 59 insertions(+), 1 deletion(-) + src/liblzma/check/crc_x86_clmul.h | 4 ++++ + 1 file changed, 4 insertions(+) -commit 324cde7a864f4506c32ae7846d688c359a83fe65 +commit 54eaea5ea49bb8bca4286d4412f19ac73187489e Author: Lasse Collin -Date: 2011-06-16 12:15:29 +0300 +Date: 2024-06-16 13:21:34 +0300 - liblzma: Remove unneeded semicolon. + liblzma: x86 CLMUL CRC: Rewrite + + It's faster with both tiny and large buffers and doesn't require + disabling any sanitizers. With large buffers the extra speed is + from folding four 16-byte chunks in parallel. + + The 32-bit x86 with MSVC reportedly still needs a workaround. + Now the simpler "__asm mov ebx, ebx" trick is enough but it + needs to be in lzma_crc64() instead of crc64_arch_optimized(). + Thanks to Iouri Kharon for testing and the fix. + + Thanks to Ilya Kurdyukov for testing the speed with aligned and + unaligned buffers on a few x86 processors and on E2K v6. + + Thanks to Sam James for general feedback. + + Fixes: https://github.com/tukaani-project/xz/issues/112 + Fixes: https://github.com/tukaani-project/xz/issues/122 - src/liblzma/lz/lz_encoder_hash.h | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) + src/liblzma/check/crc64_fast.c | 8 + + src/liblzma/check/crc_x86_clmul.h | 437 ++++++++++++++++++++------------------ + 2 files changed, 237 insertions(+), 208 deletions(-) -commit 492c86345551a51a29bf18e55fe55a5e86f169ce +commit c0e7eaae8d6eef1e313c9d0da20ccf126ec61f38 Author: Lasse Collin -Date: 2011-05-28 19:24:56 +0300 +Date: 2024-06-01 14:44:04 +0300 - Build: Make configure print if symbol versioning is enabled or not. + sysdefs.h: Add alignas - configure.ac | 2 ++ - 1 file changed, 2 insertions(+) + src/common/sysdefs.h | 11 +++++++++++ + 1 file changed, 11 insertions(+) -commit fc4d4436969bd4d71b704d400a165875e596034a +commit 20014c261451381d5e2f58e63e7b1fbefd4df4bf Author: Lasse Collin -Date: 2011-05-28 16:43:26 +0300 +Date: 2024-06-11 12:47:59 +0300 - Don't call close(-1) in tuklib_open_stdxxx() on error. + liblzma: Use a single macro to select CLMUL CRC to build - Thanks to Jim Meyering. + This way it's clearer that two things cannot be selected + at the same time. - src/common/tuklib_open_stdxxx.c | 4 +++- - 1 file changed, 3 insertions(+), 1 deletion(-) + src/liblzma/check/crc32_fast.c | 2 +- + src/liblzma/check/crc64_fast.c | 2 +- + src/liblzma/check/crc_x86_clmul.h | 18 ++++++++++-------- + 3 files changed, 12 insertions(+), 10 deletions(-) -commit bd35d903a04c4d388adb4065b0fa271302380895 +commit d8fb0986171bd6a3066b236fc9a6b3d573c8e441 Author: Lasse Collin -Date: 2011-05-28 15:55:39 +0300 +Date: 2024-06-10 15:31:01 +0300 - liblzma: Use symbol versioning. - - Symbol versioning is enabled by default on GNU/Linux, - other GNU-based systems, and FreeBSD. - - I'm not sure how stable this is, so it may need - backward-incompatible changes before the next release. + liblzma: CRC32 CLMUL: Refactor the constants and simplify - The idea is that alpha and beta symbols are considered - unstable and require recompiling the applications that - use those symbols. Once a symbol is stable, it may get - extended with new features in ways that don't break - compatibility with older ABI & API. - - The mydist target runs validate_map.sh which should - catch some probable problems in liblzma.map. Otherwise - I would forget to update the map file for new releases. + By using modulus scaled constants, the final reduction can + be simplified. - Makefile.am | 1 + - configure.ac | 21 +++++++++ - src/liblzma/Makefile.am | 6 +++ - src/liblzma/liblzma.map | 105 ++++++++++++++++++++++++++++++++++++++++++++ - src/liblzma/validate_map.sh | 68 ++++++++++++++++++++++++++++ - 5 files changed, 201 insertions(+) + src/liblzma/check/crc_x86_clmul.h | 52 +++++++-------------------------------- + 1 file changed, 9 insertions(+), 43 deletions(-) -commit afbb244362c9426a37ce4eb9d54aab768da3adad +commit ef652ac391ff7e8cda656238dc5b5f83bc1554c2 Author: Lasse Collin -Date: 2011-05-28 09:46:46 +0300 +Date: 2024-06-10 15:12:48 +0300 - Translations: Update the Italian translation. + liblzma: CRC64 CLMUL: Refactor the constants - Thanks to Milo Casagrande. + Now it refers to crc_clmul_consts_gen.c. vfold8 was renamed to mu_p + and the p no longer has the lowest bit set (it makes no difference + as the output bits it affects are ignored). - po/it.po | 365 +++++++++++++++++++++++++++++++++++++-------------------------- - 1 file changed, 216 insertions(+), 149 deletions(-) + src/liblzma/check/crc_x86_clmul.h | 43 +++++++-------------------------------- + 1 file changed, 7 insertions(+), 36 deletions(-) -commit 79bef85e0543c0c3723281c3c817616c6cec343b +commit 9f5fc17e32bf5c7c6cfadf40c29a1dedb4cc03ac Author: Lasse Collin -Date: 2011-05-28 08:46:04 +0300 +Date: 2024-06-10 14:45:44 +0300 - Tests: Add a test file for the bug in the previous commit. + liblzma: Add crc_clmul_consts_gen.c + + It's a standalone program that prints the required constants. + It's won't be a part of the normal build of the package. - tests/files/README | 4 ++++ - tests/files/bad-1-block_header-6.xz | Bin 0 -> 72 bytes - 2 files changed, 4 insertions(+) + src/liblzma/check/Makefile.inc | 1 + + src/liblzma/check/crc_clmul_consts_gen.c | 160 +++++++++++++++++++++++++++++++ + 2 files changed, 161 insertions(+) -commit c0297445064951807803457dca1611b3c47e7f0f +commit 71b147aab7fe4a60ed57b697d5bb490f099894be Author: Lasse Collin -Date: 2011-05-27 22:25:44 +0300 +Date: 2024-05-09 21:44:03 +0300 - xz: Fix error handling in xz -lvv. + liblzma: Remove CRC_USE_GENERIC_FOR_SMALL_INPUTS - It could do an invalid free() and read past the end - of the uninitialized filters array. + It was already commented out. - src/xz/list.c | 21 ++++++--------------- - 1 file changed, 6 insertions(+), 15 deletions(-) + src/liblzma/check/crc32_fast.c | 21 --------------------- + src/liblzma/check/crc64_fast.c | 5 ----- + src/liblzma/check/crc_common.h | 14 -------------- + src/liblzma/check/crc_x86_clmul.h | 9 +-------- + 4 files changed, 1 insertion(+), 48 deletions(-) -commit 8bd91918ac50731f00b1a2a48072980572eb2ff9 +commit f99a7be40645f86959a5b180dfae948dd165e07c Author: Lasse Collin -Date: 2011-05-27 22:09:49 +0300 +Date: 2024-05-09 21:03:39 +0300 - liblzma: Handle allocation failures correctly in lzma_index_init(). + liblzma: Remove crc_attr_no_sanitize_address + + It's not enough to silence the address sanitizer. Also memory and + thread sanitizers would need to be silenced. They, at least currently, + aren't smart enough to see that the extra bytes are discarded from + the xmm registers by later instructions. - Thanks to Jim Meyering. + Valgrind is smarter, possibly because this kind of code isn't weird + to write in assembly. Agner Fog's optimizing_assembly.pdf even mentions + this idea of doing an aligned read and then discarding the extra + bytes. The sanitizers don't instrument assembly code but Valgrind + checks all code. + + It's better to change the implementation to avoid the sanitization + attributes which also look scary in the code. (Somehow they can look + more scary than __asm__ which is implictly unsanitized.) + + See also: + https://github.com/tukaani-project/xz/issues/112 + https://github.com/tukaani-project/xz/issues/122 - src/liblzma/common/index.c | 7 +++++-- - 1 file changed, 5 insertions(+), 2 deletions(-) + src/liblzma/check/crc_common.h | 9 --------- + src/liblzma/check/crc_x86_clmul.h | 3 --- + 2 files changed, 12 deletions(-) -commit fe00f95828ef5627721b57e054f7eb2d42a2c961 +commit ead4d151996f8a18bf9b07eb1e175c0a1590e562 Author: Lasse Collin -Date: 2011-05-24 00:23:46 +0300 +Date: 2024-06-10 15:37:49 +0300 - Build: Fix checking for system-provided SHA-256. + Revert "Build: Temporarily disable CRC CLMUL to silence OSS Fuzz" + + This reverts commit 9f1a6d6f9a258886933a22239a5b81af34b28199. - configure.ac | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) + configure.ac | 4 +--- + 1 file changed, 1 insertion(+), 3 deletions(-) -commit 21b45b9bab541f419712cbfd473ccc31802e0397 +commit 2178acf8a4d40a93e970cfcf9b807d5ef6c8da92 Author: Lasse Collin -Date: 2011-05-23 18:30:30 +0300 +Date: 2024-06-12 14:26:44 +0300 - Build: Set GZIP_ENV=-9n in top-level Makefile.am. + CMake: Prefer C11 with a fallback to C99 + + There is no need to make a similar change in configure.ac. + With Autoconf 2.72, the deprecated macro AC_PROG_CC_C99 + is an alias for AC_PROG_CC which prefers a C11 compiler. - Makefile.am | 3 +++ - 1 file changed, 3 insertions(+) + CMakeLists.txt | 17 +++++++++++------ + 1 file changed, 11 insertions(+), 6 deletions(-) -commit 48053e8a4550233af46359024538bff90c870ab1 +commit c97e9c12fef4d1093ee2a75236742481361f50f5 Author: Lasse Collin -Date: 2011-05-22 16:42:11 +0300 +Date: 2024-06-12 14:20:21 +0300 - Update NEWS for 5.0.3. + Update THANKS - NEWS | 32 ++++++++++++++++++++++++++++++++ - 1 file changed, 32 insertions(+) + THANKS | 4 ++++ + 1 file changed, 4 insertions(+) -commit bba37df2c9e54ad773e15ff00a09d2d6989fb3b2 +commit 89e9f12e03324b8a186e807b268f34f92d1b2f41 Author: Lasse Collin -Date: 2011-05-21 16:28:44 +0300 +Date: 2024-06-11 11:15:49 +0300 - Add French translation. + Tests: Improve the CRC32 test - It is known that the BCJ filter --help text is only - partially translated. + A similar one was already there for CRC64 but nowadays also CRC32 + has a CLMUL implementation, so it's good to test it better too. - po/LINGUAS | 1 + - po/fr.po | 864 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ - 2 files changed, 865 insertions(+) + tests/test_check.c | 17 +++++++++++++---- + 1 file changed, 13 insertions(+), 4 deletions(-) -commit 4161d7634965a7a287bf208dcd79f6185f448fe8 +commit c7164b1927e3fe7cdba70ee4687e1a590a81043b Author: Lasse Collin -Date: 2011-05-21 15:12:10 +0300 +Date: 2024-06-11 22:42:26 +0300 - xz: Translate also the string used to print the program name. - - French needs a space before a colon, e.g. "xz : foo error". + xz: Fix white space - src/xz/message.c | 6 +++++- - 1 file changed, 5 insertions(+), 1 deletion(-) + src/xz/list.c | 6 +++--- + 1 file changed, 3 insertions(+), 3 deletions(-) -commit b94aa0c8380cdb18cddb33440d625474c16643cf +commit 0a32d2072c598de281058b26dc08920fbf0cd2a1 Author: Lasse Collin -Date: 2011-05-21 15:08:44 +0300 +Date: 2024-06-11 21:59:09 +0300 - liblzma: Try to use SHA-256 from the operating system. + liblzma: Fix a typo in a comment - If the operating system libc or other base libraries - provide SHA-256, use that instead of our own copy. - Note that this doesn't use OpenSSL or libgcrypt or - such libraries to avoid creating dependencies to - other packages. + Thanks to Sam James for spotting it. - This supports at least FreeBSD, NetBSD, OpenBSD, Solaris, - MINIX, and Darwin. They all provide similar but not - identical SHA-256 APIs; everyone is a little different. - - Thanks to Wim Lewis for the original patch, improvements, - and testing. + Fixes: f644473a211394447824ea00518d0a214ff3f7f2 - configure.ac | 54 +++++++++++++++++++++++++++ - src/liblzma/check/Makefile.inc | 2 + - src/liblzma/check/check.h | 83 ++++++++++++++++++++++++++++++++++++++---- - 3 files changed, 131 insertions(+), 8 deletions(-) + src/liblzma/check/crc_x86_clmul.h | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) -commit f004128678d43ea10b4a6401aa184cf83252d6ec +commit afd9b4d282a10186808c3331dad4caf79c02d55f Author: Lasse Collin -Date: 2011-05-17 12:52:18 +0300 +Date: 2024-05-10 15:52:26 +0300 - Don't use clockid_t in mythread.h when clock_gettime() isn't available. - - Thanks to Wim Lewis for the patch. + liblzma: Fix a comment indentation - src/common/mythread.h | 2 ++ - 1 file changed, 2 insertions(+) + src/liblzma/check/crc_common.h | 6 +++--- + 1 file changed, 3 insertions(+), 3 deletions(-) -commit f779516f42ebd2db47a5b7d6143459bf7737cf2f +commit 50e6bff274568c568930e15094da8217e7d47d28 Author: Lasse Collin -Date: 2011-05-17 12:26:28 +0300 +Date: 2024-05-09 22:09:12 +0300 - Update THANKS. + liblzma: Fix white space - THANKS | 3 +++ - 1 file changed, 3 insertions(+) + src/liblzma/check/crc32_table.c | 10 +++++----- + src/liblzma/check/crc_x86_clmul.h | 6 +++--- + src/liblzma/check/sha256.c | 2 +- + 3 files changed, 9 insertions(+), 9 deletions(-) -commit 830ba587775bb562f6eaf05cad61bf669d1f8892 +commit caea7844d3824755d053b4743c4913d73ac2db3d Author: Lasse Collin -Date: 2011-05-17 12:21:33 +0300 +Date: 2024-06-01 14:25:29 +0300 - Update INSTALL with a note about linker problem on OpenSolaris x86. + tuklib: __STDC_VERSION__ in C23 is 202311 - INSTALL | 23 +++++++++++++++++------ - 1 file changed, 17 insertions(+), 6 deletions(-) + src/common/tuklib_common.h | 4 +--- + 1 file changed, 1 insertion(+), 3 deletions(-) -commit ec7106309c8060e9c646dba20c4f15689a0bbb04 -Author: Lasse Collin -Date: 2011-05-17 12:01:37 +0300 +commit 9e73918a4f14be754a23f74dda45ca431939a4a0 +Author: RainRat +Date: 2024-06-05 15:21:49 -0700 - Build: Fix initialization of enable_check_* variables in configure.ac. + Fix typos - This doesn't matter much in practice since it is unlikely - that anyone would have such environment variable names. - - Thanks to Wim Lewis. + Closes: https://github.com/tukaani-project/xz/pull/124 - configure.ac | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) + INSTALL | 2 +- + doc/examples/03_compress_custom.c | 2 +- + src/common/tuklib_integer.h | 2 +- + src/liblzma/api/lzma/container.h | 2 +- + src/xz/mytime.c | 2 +- + tests/test_filter_str.c | 2 +- + 6 files changed, 6 insertions(+), 6 deletions(-) -commit 4c6e146df99696920f12410fb17754412797ef36 +commit 04b23addf3733873667675df2439725f076c2f36 Author: Lasse Collin -Date: 2011-05-17 11:54:38 +0300 +Date: 2024-06-07 15:47:20 +0300 - Add underscores to attributes (__attribute((__foo__))). + tuklib_integer: Fix building on OpenBSD/sparc64 that uses GCC 4.2 + + GCC 4.2 doesn't have __builtin_bswap16() and friends so tuklib_integer.h + tries to use OS-specific byte swap methods instead. On OpenBSD those + macros are swap16/32/64 instead of bswap16/32/64 like on other *BSDs + and Darwin. + + An alternative to "#ifdef __OpenBSD__" could be "#ifdef swap16" as it + is a macro. But since OpenBSD seems to be a special case under this + special case of "*BSDs and Darwin", checking for __OpenBSD__ seems + the more conservative choice now. + + Thanks to Christian Weisgerber and Brad Smith who both submitted + the same patch a few hours apart. + + Co-authored-by: Christian Weisgerber + Co-authored-by: Brad Smith + Closes: https://github.com/tukaani-project/xz/pull/126 - src/liblzma/common/alone_decoder.c | 2 +- - src/liblzma/common/alone_encoder.c | 2 +- - src/liblzma/common/block_encoder.c | 2 +- - src/liblzma/common/common.c | 2 +- - src/liblzma/common/common.h | 2 +- - src/liblzma/common/index_decoder.c | 9 +++++---- - src/liblzma/common/index_encoder.c | 11 ++++++----- - src/liblzma/delta/delta_encoder.c | 2 +- - src/liblzma/lz/lz_decoder.c | 2 +- - src/liblzma/lz/lz_encoder.c | 2 +- - src/liblzma/simple/arm.c | 2 +- - src/liblzma/simple/armthumb.c | 2 +- - src/liblzma/simple/ia64.c | 2 +- - src/liblzma/simple/powerpc.c | 2 +- - src/liblzma/simple/simple_coder.c | 2 +- - src/liblzma/simple/sparc.c | 2 +- - src/lzmainfo/lzmainfo.c | 4 ++-- - src/xz/coder.c | 2 +- - src/xz/hardware.h | 2 +- - src/xz/message.c | 2 +- - src/xz/message.h | 18 +++++++++--------- - src/xz/options.c | 6 +++--- - src/xz/signals.c | 2 +- - src/xz/util.h | 6 +++--- - src/xzdec/xzdec.c | 6 +++--- - 25 files changed, 49 insertions(+), 47 deletions(-) + src/common/tuklib_integer.h | 12 +++++++++--- + 1 file changed, 9 insertions(+), 3 deletions(-) -commit 7a480e485938884ef3021b48c3b0b9f9699dc9b6 +commit dc03f6290f5b9bd3d50c7e12e58dee870889d599 Author: Lasse Collin -Date: 2011-05-01 12:24:23 +0300 +Date: 2024-06-07 15:06:59 +0300 - xz: Fix input file position when --single-stream is used. + liblzma: Add ARM64 CRC32 instruction support detection on OpenBSD - Now the following works as you would expect: + The C code is from Christian Weisgerber, I merely reordered the OSes. + Then I added the build system checks without testing them. - echo foo | xz > foo.xz - echo bar | xz >> foo.xz - ( xz -dc --single-stream ; xz -dc --single-stream ) < foo.xz + Also thanks to Brad Smith who submitted a similar patch on GitHub + a few hours after Christian had sent his via email. - Note that it doesn't work if the input is not seekable - or if there is Stream Padding between the concatenated - .xz Streams. + Co-authored-by: Christian Weisgerber + Closes: https://github.com/tukaani-project/xz/pull/125 - src/xz/coder.c | 1 + - src/xz/file_io.c | 15 +++++++++++++++ - src/xz/file_io.h | 13 +++++++++++++ - 3 files changed, 29 insertions(+) + CMakeLists.txt | 6 ++++++ + configure.ac | 9 +++++++++ + src/liblzma/check/crc32_arm64.h | 15 +++++++++++++++ + src/liblzma/check/crc_common.h | 1 + + 4 files changed, 31 insertions(+) -commit c29e6630c1450c630c4e7b783bdd76515db9004c +commit f5c2ae58ec68c665e62c790b842657afcb31474c Author: Lasse Collin -Date: 2011-05-01 12:15:51 +0300 - - xz: Print the maximum number of worker threads in xz -vv. +Date: 2024-06-05 13:55:43 +0300 - src/xz/coder.c | 4 ++++ - 1 file changed, 4 insertions(+) + Update THANKS -commit 0b77c4a75158ccc416b07d6e81df8ee0abaea720 + THANKS | 2 ++ + 1 file changed, 2 insertions(+) + +commit e5491dfab9c54dc7078a8d3d07fabb91d6e06418 Author: Lasse Collin -Date: 2011-04-19 10:44:48 +0300 +Date: 2024-06-05 13:42:47 +0300 - Build: Warn if no supported method to detect the number of CPU cores. + CMake: Include the "alpha" or "beta" suffix in PACKAGE_VERSION + + This way the version string gets into xzgrep and other scripts + in full and also into liblzma.pc. + + For the project() command, a suffixless string is required though. - configure.ac | 11 +++++------ - 1 file changed, 5 insertions(+), 6 deletions(-) + CMakeLists.txt | 16 +++++++++++++--- + 1 file changed, 13 insertions(+), 3 deletions(-) -commit e4622df9ab4982f8faa53d85b17be66216175a58 +commit 1d3c61575fda0be6b2d50c9e32a343349d5cd5c0 Author: Lasse Collin -Date: 2011-04-19 09:55:06 +0300 +Date: 2024-06-05 13:30:28 +0300 - Update THANKS. + CMake: Fix wrong version variable + + liblzma_VERSION has never existed in the repository. xz_VERSION from + the project() command was used for liblzma SOVERSION so use xz_VERSION + here too. + + The wrong variable did no harm in practice as PROJECT_VERSION + was used as the fallback. It has the same value as xz_VERSION. + + Fixes: 7e3493d40eac0c3fa3d5124097745a70e15c41f6 - THANKS | 1 + - 1 file changed, 1 insertion(+) + CMakeLists.txt | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit 5d1c649ba9eb7a5b9371252ebfbc2911dc774e69 +Author: Lasse Collin +Date: 2024-06-05 12:59:59 +0300 + + CMake: Set only "prefix" as an absolute path in liblzma.pc + + CMake provides variables that are relative to CMAKE_INSTALL_PREFIX + so use them instead of repeating the full path. -commit 9c1b05828a88eff54409760b92162c7cc2c7cff6 + CMakeLists.txt | 6 +++--- + 1 file changed, 3 insertions(+), 3 deletions(-) + +commit e0d6d05ce0d464e966c0669bbf869202a43cc2f7 Author: Lasse Collin -Date: 2011-04-19 09:20:44 +0300 +Date: 2024-06-04 23:59:29 +0300 - Fix portability problems in mythread.h. + CMake: Fix liblzma filename in Windows environments + + This is a mess because liblzma DLL outside Cygwin and MSYS2 + is liblzma.dll instead of lzma.dll to avoid a conflict with + lzma.dll from LZMA SDK. + + On Cygwin the name was "liblzma-5.dll" while "cyglzma-5.dll" + would have been correct (and match what Libtool produces). + MSYS2 likely was broken too as it uses the "msys-" prefix. - Use gettimeofday() if clock_gettime() isn't available - (e.g. Darwin). + This change has no effect with MinGW-w64 because with that + the "lib" prefix was correct already. - The test for availability of pthread_condattr_setclock() - and CLOCK_MONOTONIC was incorrect. Instead of fixing the - #ifdefs, use an Autoconf test. That way if there exists a - system that supports them but doesn't specify the matching - POSIX #defines, the features will still get detected. + With MSVC builds this is a small breaking change that requires developers + to adjust the library name when linking against liblzma. The liblzma.dll + name is kept as is but the import library and static library are now + lzma.lib instead of liblzma.lib. This is helpful when using pkgconf + because "pkgconf --msvc-syntax --libs liblzma" outputs "lzma.lib" + (it's converted from "-llzma" in liblzma.pc). It would be easy to + keep the liblzma.lib naming but the pkgconf compatibility seems worth + it in the long run. The lzma.lib name is compatible with MinGW-w64 + too as -llzma will find also lzma.lib. - Don't try to use pthread_sigmask() on OpenVMS. It doesn't - have that function. + vcpkg had been patching CMakeLists.txt this way since 2022 but I + learned this only recently. The reasoning for the patch makes sense, + and while this is a small breaking change with MSVC, it seems like + a decent compromise as it keeps the DLL name the same. - Guard mythread.h against being #included multiple times. + 2022 patch in vcpkg: https://github.com/microsoft/vcpkg/blob/0707a17ecf1466d64cf1a3c1ee18c8ff02aadb2d/ports/liblzma/win_output_name.patch + See the discussion: https://github.com/microsoft/vcpkg/pull/39024 + + Thanks to Vincent Torri for confirming the naming issue on Cygwin. - configure.ac | 7 +++++++ - src/common/mythread.h | 31 +++++++++++++++++++++++++++---- - 2 files changed, 34 insertions(+), 4 deletions(-) + CMakeLists.txt | 34 ++++++++++++++++++++++++++++++---- + 1 file changed, 30 insertions(+), 4 deletions(-) -commit 3de00cc75da7b0e7b65e84c62b5351e231f501e9 +commit e7a42cda7c827e016619e8cab15e2faf5d4181ae Author: Lasse Collin -Date: 2011-04-18 19:35:49 +0300 +Date: 2024-06-03 16:55:03 +0300 - Update THANKS. + Fix version.sh compatiblity with Solaris + + The ancient /bin/tr on Solaris doesn't support '\n'. + With /usr/xpg4/bin/tr it works but it might not be in PATH. + + Another problem was that sed was given input that didn't have a newline + at the end. Text files must end with a newline to be portable. + + Fix both problems: + + - Handle multiline input within sed itself to avoid one tr invocation. + The default sed even on Solaris does understand \n. + + - Use octals in tr -d. \012 works for ASCII "line feed", it's even + used as an example in the Solaris man page. But we must strip + also ASCII "carriage return" \015 and EBCDIC "next line" \025. + The EBCDIC case got handled with \n previously. Stripping \012 + and \015 on EBCDIC system won't matter as those control chars + won't be present in the string in the first place. + + An awk-based solution could be an alternative but it might need + special casing on Solaris to used nawk instead of awk. The changes + in this commit are smaller and should have a smaller risk for + regressions. It's also possible that version.sh will be dropped + entirely at some point. - THANKS | 2 ++ - 1 file changed, 2 insertions(+) + build-aux/version.sh | 5 ++--- + 1 file changed, 2 insertions(+), 3 deletions(-) -commit bd5002f5821e3d1b04f2f56989e4a19318e73633 -Author: Martin Väth -Date: 2011-04-15 04:54:49 -0400 +commit a61c9ab4751f2710dcd5459c7d74bbf20781f0f9 +Author: Lasse Collin +Date: 2024-06-03 17:07:11 +0300 - xzgrep: fix typo in $0 parsing - - Reported-by: Diego Elio Pettenò - Signed-off-by: Martin Väth - Signed-off-by: Mike Frysinger + CI: Don't require po4a on Solaris - src/scripts/xzgrep.in | 4 ++-- - 1 file changed, 2 insertions(+), 2 deletions(-) + .github/workflows/solaris.yml | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) -commit 6ef4eabc0acc49e1bb9dc68064706e19fa9fcf48 +commit 5229bdf5335ce18ed54beb7e646e39927663be86 Author: Lasse Collin -Date: 2011-04-12 12:48:31 +0300 +Date: 2024-06-03 15:08:15 +0300 - Bump the version number to 5.1.1alpha and liblzma soname to 5.0.99. + CI: Use set -e on Solaris too - src/liblzma/Makefile.am | 2 +- - src/liblzma/api/lzma/version.h | 2 +- - 2 files changed, 2 insertions(+), 2 deletions(-) + .github/workflows/solaris.yml | 1 + + 1 file changed, 1 insertion(+) -commit 9a4377be0d21e597c66bad6c7452873aebfb3c1c +commit afa938e429c1ce07d26d02999352fb014b62ff3d Author: Lasse Collin -Date: 2011-04-12 12:42:37 +0300 +Date: 2024-06-03 17:44:50 +0300 - Put the unstable APIs behind #ifdef LZMA_UNSTABLE. + CMake: Install liblzma.pc even with MSVC + + I had misunderstood that it wouldn't be useful with MSVC. + vcpkg had been installing liblzma.pc with custom rules since 2020, + years before liblzma.pc support was added to CMakeLists.txt. - This way people hopefully won't complain if these APIs - change and break code that used an older API. + See: + https://github.com/microsoft/vcpkg/blob/eb895b95aac6fd7485373702f29f508c42a180a0/ports/liblzma/portfile.cmake + https://github.com/microsoft/vcpkg/pull/39024#issuecomment-2145064670 - src/liblzma/api/lzma/container.h | 4 ++++ - src/liblzma/common/common.h | 2 ++ - src/xz/private.h | 2 ++ - 3 files changed, 8 insertions(+) + CMakeLists.txt | 8 +++----- + 1 file changed, 3 insertions(+), 5 deletions(-) -commit 3e321a3acd50002cf6fdfd259e910f56d3389bc3 -Author: Lasse Collin -Date: 2011-04-12 11:59:49 +0300 +commit 35f8649f08341639a627fd06350e938124ca3622 +Author: Sam James +Date: 2024-06-03 06:16:23 +0100 - Remove doubled words from documentation and comments. + ci: don't pin official GH actions via commit, just tag - Spot candidates by running these commands: - git ls-files |xargs perl -0777 -n \ - -e 'while (/\b(then?|[iao]n|i[fst]|but|f?or|at|and|[dt]o)\s+\1\b/gims)' \ - -e '{$n=($` =~ tr/\n/\n/ + 1); ($v=$&)=~s/\n/\\n/g; print "$ARGV:$n:$v\n"}' + There's no real value in doing it via commit for official GH actions. We + can keep using pinned commits for unofficial actions. It's hassle for no + gain. - Thanks to Jim Meyering for the original patch. + Maybe going forward we can limit this further by only being paranoid + for the jobs with any access to tokens. - doc/lzma-file-format.txt | 4 ++-- - src/liblzma/common/alone_encoder.c | 2 +- - src/liblzma/lzma/lzma2_encoder.c | 2 +- - src/xz/file_io.c | 2 +- - src/xz/xz.1 | 2 +- - windows/INSTALL-Windows.txt | 2 +- - 6 files changed, 7 insertions(+), 7 deletions(-) + .github/workflows/ci.yml | 4 ++-- + .github/workflows/freebsd.yml | 2 +- + .github/workflows/netbsd.yml | 2 +- + .github/workflows/openbsd.yml | 2 +- + .github/workflows/solaris.yml | 2 +- + .github/workflows/windows-ci.yml | 4 ++-- + 6 files changed, 8 insertions(+), 8 deletions(-) -commit d91a84b534b012d19474f2fda1fbcaef873e1ba4 -Author: Lasse Collin -Date: 2011-04-12 11:46:01 +0300 +commit e885dae37ff5b1dbc760dabc1e03e866a7302ef2 +Author: Christoph Junghans +Date: 2024-04-30 07:49:26 -0600 - Update NEWS. + ci: set -e on openbsd + + Closes: https://github.com/tukaani-project/xz/pull/116 - NEWS | 47 +++++++++++++++++++++++++++++++++++++++++++++-- - 1 file changed, 45 insertions(+), 2 deletions(-) + .github/workflows/openbsd.yml | 1 + + 1 file changed, 1 insertion(+) -commit 14e6ad8cfe0165c1a8beeb5b2a1536558b29b0a1 -Author: Lasse Collin -Date: 2011-04-12 11:45:40 +0300 +commit 21b02dd128cf9e8c76325ec124f70381862dcf19 +Author: Christoph Junghans +Date: 2024-04-30 07:48:58 -0600 - Update TODO. + ci: set -e on netbsd - TODO | 12 +++++++++++- - 1 file changed, 11 insertions(+), 1 deletion(-) + .github/workflows/netbsd.yml | 1 + + 1 file changed, 1 insertion(+) -commit 70e750f59793f9b5cd306a5adce9b8e427739e04 -Author: Lasse Collin -Date: 2011-04-12 11:08:55 +0300 +commit 8641f0c24c041136670c975b23408184b45431bc +Author: Christoph Junghans +Date: 2024-04-25 14:56:06 -0700 - xz: Update the man page about threading. + ci: actually fail on FreeBSD + + Without "set -e" the job will always be successful. + + See vmactions/freebsd-vm#72 - src/xz/xz.1 | 34 ++++++++++++++++++++-------------- - 1 file changed, 20 insertions(+), 14 deletions(-) + .github/workflows/freebsd.yml | 1 + + 1 file changed, 1 insertion(+) -commit 24e0406c0fb7494d2037dec033686faf1bf67068 -Author: Lasse Collin -Date: 2011-04-11 22:06:03 +0300 +commit ef616683ef11f11ffdfbe0624da33905e28a70f9 +Author: Andrew Murray +Date: 2024-04-25 09:24:46 +1000 - xz: Add support for threaded compression. + Updated actions + + Closes: https://github.com/tukaani-project/xz/pull/115 - src/xz/args.c | 3 +- - src/xz/coder.c | 202 +++++++++++++++++++++++++++++++++++---------------------- - 2 files changed, 125 insertions(+), 80 deletions(-) + .github/workflows/ci.yml | 4 ++-- + .github/workflows/windows-ci.yml | 6 +++--- + 2 files changed, 5 insertions(+), 5 deletions(-) -commit de678e0c924aa79a19293a8a6ed82e8cb6572a42 -Author: Lasse Collin -Date: 2011-04-11 22:03:30 +0300 +commit 57b440d316da9ac9cb312ee7e6890f5382556f10 +Author: Sam James +Date: 2024-06-03 02:49:40 +0100 - liblzma: Add lzma_stream_encoder_mt() for threaded compression. + ci: add po4a + + .github/workflows/netbsd.yml | 2 +- + .github/workflows/openbsd.yml | 3 ++- + 2 files changed, 3 insertions(+), 2 deletions(-) + +commit 08cdf4be9a673d78efe393b53dd73bf43c81dd95 +Author: Sam James +Date: 2024-04-13 21:02:04 +0100 + + ci: add Solaris - This is the simplest method to do threading, which splits - the uncompressed data into blocks and compresses them - independently from each other. There's room for improvement - especially to reduce the memory usage, but nevertheless, - this is a good start. + Inspired by https://github.com/RsyncProject/rsync/commit/3f2a38b01184cae9a931280b534acf5a3dae2e94. + + It runs on Solaris 5.11 via a VirtualBox VM. - configure.ac | 1 + - src/liblzma/api/lzma/container.h | 163 +++++ - src/liblzma/common/Makefile.inc | 7 + - src/liblzma/common/common.c | 9 +- - src/liblzma/common/common.h | 14 + - src/liblzma/common/outqueue.c | 180 ++++++ - src/liblzma/common/outqueue.h | 155 +++++ - src/liblzma/common/stream_encoder_mt.c | 1011 ++++++++++++++++++++++++++++++++ - 8 files changed, 1539 insertions(+), 1 deletion(-) + .github/workflows/solaris.yml | 31 +++++++++++++++++++++++++++++++ + 1 file changed, 31 insertions(+) -commit 25fe729532cdf4b8fed56a4519b73cf31efaec50 -Author: Lasse Collin -Date: 2011-04-11 21:15:07 +0300 +commit b69768c8bd1a34fde311935c551d061ba52d9a3f +Author: Sam James +Date: 2024-04-14 08:08:00 +0100 - liblzma: Add the forgotten lzma_lzma2_block_size(). + xz: list: suppress -Wformat-nonliteral for Solaris + + Solaris' GCC can't understand that our use is fine, unlike modern compilers: + ``` + list.c: In function 'print_totals_basic': + list.c:1191:4: error: format not a string literal, argument types not checked [-Werror=format-nonliteral] + uint64_to_str(totals.files, 0)); + ^~~~~~~~~~~~~ + cc1: all warnings being treated as errors + ``` + + It's presumably because of older gettext missing format attributes. - This should have been in 5eefc0086d24a65e136352f8c1d19cefb0cbac7a. + This is with `gcc (GCC) 7.3.0`. - src/liblzma/lzma/lzma2_encoder.c | 10 ++++++++++ - src/liblzma/lzma/lzma2_encoder.h | 2 ++ - 2 files changed, 12 insertions(+) + src/xz/list.c | 7 +++++++ + 1 file changed, 7 insertions(+) -commit 91afb785a1dee34862078d9bf844ef12b8cc3e35 +commit bb90e1f66d9beb490c4c99763e79519045968710 Author: Lasse Collin -Date: 2011-04-11 21:04:13 +0300 +Date: 2024-06-03 11:44:28 +0300 - liblzma: Document lzma_easy_(enc|dec)oder_memusage() better too. + license-check.sh: Fix reporting of unclear license info + + The main feature was broken because an old variable name hadn't + been updated to match the rest of the script. - src/liblzma/api/lzma/container.h | 9 +++++++++ - 1 file changed, 9 insertions(+) + build-aux/license-check.sh | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) -commit 4a9905302a9e4a1601ae09d650d3f08ce98ae9ee +commit b8d134e61ede9f4a296226d97f5c20721fb4e8e2 Author: Lasse Collin -Date: 2011-04-11 20:59:07 +0300 +Date: 2024-05-31 21:36:26 +0300 - liblzma: Document lzma_raw_(enc|dec)oder_memusage() better. - - It didn't mention the return value that is used if - an error occurs. + Update THANKS - src/liblzma/api/lzma/filter.h | 8 ++++++-- - 1 file changed, 6 insertions(+), 2 deletions(-) + THANKS | 3 +++ + 1 file changed, 3 insertions(+) -commit 0badb0b1bd649163322783b0bd9e590b4bc7a93d +commit 162587d3fb3fcedc6eee61eda3ccaaf60c80f0de Author: Lasse Collin -Date: 2011-04-11 19:28:18 +0300 +Date: 2024-05-29 17:47:13 +0300 - liblzma: Use memzero() to initialize supported_actions[]. + Translations: Run po4a/update-po - This is cleaner and makes it simpler to add new members - to lzma_action enumeration. + Now the files are in the new formatting without source file + line numbers. Future updates should keep the diffs much smaller. - src/liblzma/common/common.c | 6 ++---- - 1 file changed, 2 insertions(+), 4 deletions(-) + po4a/de.po | 1592 ++++++++++--------- + po4a/fr.po | 4450 +++++++++++++++++----------------------------------- + po4a/ko.po | 1592 ++++++++++--------- + po4a/pt_BR.po | 4817 ++++++++++++++++++--------------------------------------- + po4a/ro.po | 1592 ++++++++++--------- + po4a/uk.po | 1592 ++++++++++--------- + 6 files changed, 6114 insertions(+), 9521 deletions(-) -commit a7934c446a58e20268689899d2a39f50e571f251 +commit 50cd8ed002473c5cd53980e70a53e5e6ad646ffe Author: Lasse Collin -Date: 2011-04-11 19:26:27 +0300 +Date: 2024-05-29 17:44:53 +0300 - liblzma: API comment about lzma_allocator with threaded coding. + Translations: Run "make -C po update-po" + + In the past this wasn't done before releases; the Git repository + just contained the files from the Translation Project. But this + way it is clearer when comparing release tarballs against the + Git repository. In future releases this might no longer be necessary + within a stable branch as the .po files won't change so easily anymore + when creating a tarball. - src/liblzma/api/lzma/base.h | 18 +++++++++++++----- - 1 file changed, 13 insertions(+), 5 deletions(-) + po/ca.po | 567 +++++++++++++++++++++++++--------------- + po/cs.po | 821 +++++++++++++++++++++++++++++++++++++-------------------- + po/da.po | 809 +++++++++++++++++++++++++++++++++++--------------------- + po/de.po | 403 ++++++++++++++-------------- + po/eo.po | 403 ++++++++++++++-------------- + po/es.po | 403 ++++++++++++++-------------- + po/fi.po | 578 +++++++++++++++++++++++++--------------- + po/fr.po | 538 +++++++++++++++++++++++--------------- + po/hr.po | 403 ++++++++++++++-------------- + po/hu.po | 403 ++++++++++++++-------------- + po/it.po | 854 +++++++++++++++++++++++++++++++++++++++--------------------- + po/ko.po | 403 ++++++++++++++-------------- + po/pl.po | 403 ++++++++++++++-------------- + po/pt.po | 842 +++++++++++++++++++++++++++++++++++++++-------------------- + po/pt_BR.po | 567 +++++++++++++++++++++++++--------------- + po/ro.po | 403 ++++++++++++++-------------- + po/sr.po | 838 ++++++++++++++++++++++++++++++++++++++-------------------- + po/sv.po | 403 ++++++++++++++-------------- + po/tr.po | 567 +++++++++++++++++++++++++--------------- + po/uk.po | 403 ++++++++++++++-------------- + po/vi.po | 403 ++++++++++++++-------------- + po/zh_CN.po | 417 +++++++++++++++-------------- + po/zh_TW.po | 558 ++++++++++++++++++++++++--------------- + 23 files changed, 7257 insertions(+), 5132 deletions(-) -commit 5eefc0086d24a65e136352f8c1d19cefb0cbac7a +commit 16dbd865c8833462e1604a1e13f7effe55bb3fe6 Author: Lasse Collin -Date: 2011-04-11 19:16:30 +0300 +Date: 2024-05-29 18:03:04 +0300 - liblzma: Add an internal function lzma_mt_block_size(). - - This is based lzma_chunk_size() that was included in some - development version of liblzma. + Add NEWS for 5.6.2 - src/liblzma/common/filter_encoder.c | 46 ++++++++++++++++++------------------- - src/liblzma/common/filter_encoder.h | 4 ++-- - 2 files changed, 24 insertions(+), 26 deletions(-) + NEWS | 130 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ + 1 file changed, 130 insertions(+) -commit d1199274758049fc523d98c5b860ff814a799eec +commit a0eeb5f9369c43508610dcf00140edb8e2be92a6 Author: Lasse Collin -Date: 2011-04-11 13:59:50 +0300 +Date: 2024-05-29 18:03:04 +0300 - liblzma: Don't create an empty Block in lzma_stream_buffer_encode(). - - Empty Block was created if the input buffer was empty. - Empty Block wastes a few bytes of space, but more importantly - it triggers a bug in XZ Utils 5.0.1 and older when trying - to decompress such a file. 5.0.1 and older consider such - files to be corrupt. I thought that no encoder creates empty - Blocks when releasing 5.0.2 but I was wrong. + Add NEWS for 5.4.7 - src/liblzma/common/stream_buffer_encoder.c | 20 +++++++++++++------- - 1 file changed, 13 insertions(+), 7 deletions(-) + NEWS | 89 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ + 1 file changed, 89 insertions(+) -commit 3b22fc2c87ec85fcdd385c163b68fc49c97aa848 +commit 9b476fb93a9672f2e70b56e3e9c7e9cfedd6c162 Author: Lasse Collin -Date: 2011-04-11 13:28:40 +0300 +Date: 2024-05-29 18:03:04 +0300 - liblzma: Fix API docs to mention LZMA_UNSUPPORTED_CHECK. - - This return value was missing from the API comments of - four functions. + Add NEWS for 5.2.13 - src/liblzma/api/lzma/block.h | 1 + - src/liblzma/api/lzma/container.h | 3 +++ - 2 files changed, 4 insertions(+) + NEWS | 115 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ + 1 file changed, 115 insertions(+) -commit 71b9380145dccf001f22e66a06b9d508905c25ce +commit 9284f1aea31f0eb23e2ea72f7218b271e2234762 Author: Lasse Collin -Date: 2011-04-11 13:21:28 +0300 +Date: 2024-05-29 16:33:24 +0300 - liblzma: Validate encoder arguments better. + Build: Update po/*.po files only when needed + + When po/xz.pot doesn't exist, running "make" or "make dist" will + create it. Then the .po files will be updated but only if they + actually would change more than the POT-Creation-Date line. + Then the .gmo files would be generated from the .po files. + This is the case before and after this commit. - The biggest problem was that the integrity check type - wasn't validated, and e.g. lzma_easy_buffer_encode() - would create a corrupt .xz Stream if given an unsupported - Check ID. Luckily applications don't usually try to use - an unsupport Check ID, so this bug is unlikely to cause - many real-world problems. + However, "make dist" and thus "make mydist" did a forced update + to the files, updating them even if the only change was the + POT-Creation-Date line. This had pros and cons: It made it clear + that the .po file really is in sync with the recent strings in + the package. On the other hand, it added noise in form of changed + files in the source tree and distribution tarballs. It can be + ignored with something like "diff -I'^"POT-Creation-Date: '" but + it's still a minor annoyance *if* there's not enough value in + having the most recent timestamp. + + Setting DIST_DEPENDS_ON_UPDATE_PO = no means that such forced + update won't happen in "make dist" anymore. However, the "mydist" + target will use xz.pot-update target which is the same target that + is run when xz.pot doesn't exist at all yet. Thus "mydist" will + ensure that the translations are up to date, without noise from + changes that would affect only the POT-Creation-Date line. + + Note that po4a always uses msgmerge with --update, so POT-Creation-Date + in the man page translations is never the only change in .po files. + In that sense this commit makes the message translations behave more + similarly to the man page translations. + + Distribution tarballs will still have non-reproducible POT-Creation-Date + in po/xz.pot and po4a/xz-man.pot but those are just two files. Even they + could be made reproducible from a Git timestamp if desired. - src/liblzma/common/block_buffer_encoder.c | 18 ++++++++++++------ - src/liblzma/common/block_encoder.c | 5 +++++ - src/liblzma/common/stream_buffer_encoder.c | 3 +++ - 3 files changed, 20 insertions(+), 6 deletions(-) + Makefile.am | 3 ++- + po/Makevars | 6 +++++- + 2 files changed, 7 insertions(+), 2 deletions(-) -commit ec7e3dbad704268825fc48f0bdd4577bc46b4f13 +commit 4beba1cd62d7f8f7a6f1e899b68292d94c53b599 Author: Lasse Collin -Date: 2011-04-11 09:57:30 +0300 +Date: 2024-05-28 21:10:33 +0300 - xz: Move the description of --block-size in --long-help. + po4a/update-po: Disable wrapping in .pot and .po files + + The .po files from the Translation Project come with unwrapped + strings so this matches it. + + This may reduce the noise in diffs too. When the beginning of + a paragraph had changed, the rest of the lines got rewrapped + in msgsid. Now it's just one very long line that changes when + a paragraph has been edited. + + The --add-location=file option was removed as redundant. The line + numbers don't exist in the .pot file due to --porefs file and thus + they cannot get copied to the .po files either. - src/xz/message.c | 8 ++++---- - 1 file changed, 4 insertions(+), 4 deletions(-) + po4a/update-po | 15 +++++++++++---- + 1 file changed, 11 insertions(+), 4 deletions(-) -commit cd3086ff443bb282bdf556919c28b3e3cbed8169 +commit b14c130a58a649f9a73392eeb122cb252327c569 Author: Lasse Collin -Date: 2011-04-11 09:55:35 +0300 +Date: 2024-05-28 18:36:53 +0300 - Docs: Document --single-stream and --block-size. + Update contact info in README - src/xz/xz.1 | 38 ++++++++++++++++++++++++++++++++++++-- - 1 file changed, 36 insertions(+), 2 deletions(-) + README | 12 +++++++++--- + 1 file changed, 9 insertions(+), 3 deletions(-) -commit fb64a4924334e3c440865710990fe08090f2fed0 +commit 75f5f2e014b0ee646963f36bc6a9c840fb272353 Author: Lasse Collin -Date: 2011-04-11 09:27:57 +0300 +Date: 2024-05-28 13:25:07 +0300 - liblzma: Make lzma_stream_encoder_init() static (second try). + Translations: Use --package-name=xz-man with po4a - It's an internal function and it's not needed by - anything outside stream_encoder.c. + This is to match reality. See the added comment. - src/liblzma/common/Makefile.inc | 1 - - src/liblzma/common/easy_encoder.c | 1 - - src/liblzma/common/stream_encoder.c | 13 ++++++------- - src/liblzma/common/stream_encoder.h | 23 ----------------------- - 4 files changed, 6 insertions(+), 32 deletions(-) + po4a/update-po | 9 ++++++++- + 1 file changed, 8 insertions(+), 1 deletion(-) -commit a34730cf6af4d33a4057914e57227b6dfde6567e +commit eb217d016cfbbba1babc19a61095b3ea25898af6 Author: Lasse Collin -Date: 2011-04-11 08:31:42 +0300 +Date: 2024-05-28 13:03:40 +0300 - Revert "liblzma: Make lzma_stream_encoder_init() static." + Translations: Omit --package-name from po/Makevars - This reverts commit 352ac82db5d3f64585c07b39e4759388dec0e4d7. - I don't know what I was thinking. + This is closer to the reality in the po/*.po files. - src/liblzma/common/Makefile.inc | 1 + - src/liblzma/common/stream_encoder.c | 9 +++++---- - src/liblzma/common/stream_encoder.h | 23 +++++++++++++++++++++++ - 3 files changed, 29 insertions(+), 4 deletions(-) + po/Makevars | 3 +-- + 1 file changed, 1 insertion(+), 2 deletions(-) -commit 9f0a806aef7ea79718e3f1f2baf3564295229a27 +commit d28a4b2520adeeaa1b9e921bf42c7c1f36552c06 Author: Lasse Collin -Date: 2011-04-10 21:23:21 +0300 +Date: 2024-05-27 17:45:51 +0300 - Revise mythread.h. - - This adds: - - - mythread_sync() macro to create synchronized blocks + license-check.sh: Use '--' with slightly untrusted filenames - - mythread_cond structure and related functions - and macros for condition variables with timed - waiting using a relative timeout - - - mythread_create() to create a thread with all - signals blocked - - Some of these wouldn't need to be inline functions, - but I'll keep them this way for now for simplicity. - - For timed waiting on a condition variable, librt is - now required on some systems to use clock_gettime(). - configure.ac was updated to handle this. + Names from git ls-files should be safe but if one runs it on + a tree without the .git dir and there are extra files, it's + safer to have the end of arguments marked with '--'. - configure.ac | 1 + - src/common/mythread.h | 200 +++++++++++++++++++++++++++++++++++++++++++++----- - 2 files changed, 181 insertions(+), 20 deletions(-) + build-aux/license-check.sh | 6 +++--- + 1 file changed, 3 insertions(+), 3 deletions(-) -commit 352ac82db5d3f64585c07b39e4759388dec0e4d7 +commit fda0ec862a34094cf23fc25d0e0a95858c3a3ab5 Author: Lasse Collin -Date: 2011-04-10 20:37:36 +0300 +Date: 2024-05-27 17:41:37 +0300 - liblzma: Make lzma_stream_encoder_init() static. + license-check.sh: Use xargs -0 instead of -d - It's an internal function and it's not needed by - anything outside stream_encoder.c. + Neither are in POSIX but -0 is much more portable in practice. + + Despite the old comment, the grep usage should be portable already. - src/liblzma/common/Makefile.inc | 1 - - src/liblzma/common/stream_encoder.c | 9 ++++----- - src/liblzma/common/stream_encoder.h | 23 ----------------------- - 3 files changed, 4 insertions(+), 29 deletions(-) + build-aux/license-check.sh | 11 ++++++----- + 1 file changed, 6 insertions(+), 5 deletions(-) -commit 9e807fe3fe79618ac48f58207cf7082ea20a6928 +commit 9114267038deaecf4832a5cacb5acbe6591ac839 Author: Lasse Collin -Date: 2011-04-10 14:58:10 +0300 +Date: 2024-05-28 01:17:45 +0300 - DOS: Update the docs and include notes about 8.3 filenames. + Translations: Omit man page line numbers from .pot and .po files - dos/{README => INSTALL.txt} | 13 +---- - dos/README.txt | 123 ++++++++++++++++++++++++++++++++++++++++++++ - 2 files changed, 125 insertions(+), 11 deletions(-) + po4a/update-po | 5 +++++ + 1 file changed, 5 insertions(+) -commit ebd54dbd6e481d31e80757f900ac8109ad1423c6 +commit 093490b58271e9424ce38a7b1b38bcf61b9c86c6 Author: Lasse Collin -Date: 2011-04-10 13:09:42 +0300 +Date: 2024-05-28 01:06:30 +0300 - xz/DOS: Add experimental 8.3 filename support. - - This is incompatible with the 8.3 support patch made by - Juan Manuel Guerrero. I think this one is nicer, but - I need to get feedback from DOS users before saying - that this is the final version of 8.3 filename support. + Translations: Use the xgettext option --add-location=file - src/xz/suffix.c | 176 +++++++++++++++++++++++++++++++++++++++++++++++++++++--- - 1 file changed, 167 insertions(+), 9 deletions(-) + po/Makevars | 3 ++- + 1 file changed, 2 insertions(+), 1 deletion(-) -commit cd4fe97852bcaeffe674ee51b4613709292a0972 +commit fccebe2b4fd513488fc920e4dac32562ed3c7637 Author: Lasse Collin -Date: 2011-04-10 12:47:47 +0300 +Date: 2024-05-28 00:43:53 +0300 - xz/DOS: Be more careful with the destination file. + Translations: Use the msgmerge option --add-location=file - Try to avoid overwriting the source file if --force is - used and the generated destination filename refers to - the source file. This can happen with 8.3 filenames where - extra characters are ignored. + This way the PO file diffs are less noisy but the locations of the + strings are still present at file level, just without line numbers. - If the generated output file refers to a special file - like "con" or "prn", refuse to write to it even if --force - is used. + The option is available since gettext 0.19 (2014). + configure.ac requires 0.19.6. - src/xz/file_io.c | 35 +++++++++++++++++++++++++++++++++-- - 1 file changed, 33 insertions(+), 2 deletions(-) + po/Makevars | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) -commit 607f9f98ae5ef6d49f4c21c806d462bf6b3d6796 +commit f361d9ae85707a87eb28db400eb7229cec103d58 Author: Lasse Collin -Date: 2011-04-09 18:29:30 +0300 +Date: 2024-05-27 12:22:08 +0300 - Update THANKS. + Build: Use $(SHELL) instead of sh to run scripts in Makefile.am - THANKS | 1 + - 1 file changed, 1 insertion(+) + Makefile.am | 14 +++++++------- + 1 file changed, 7 insertions(+), 7 deletions(-) -commit fca396b37410d272b754843a5dc13847be443a3a +commit a26dece34793a09aac2476f954d162d03e9cf62b Author: Lasse Collin -Date: 2011-04-09 18:28:58 +0300 +Date: 2024-05-23 17:25:13 +0300 - liblzma: Add missing #ifdefs to filter_common.c. + Translations: Change the home page URLs in man page translations - Passing --disable-decoders to configure broke a few - encoders due to missing #ifdefs in filter_common.c. - - Thanks to Jason Gorski for the patch. + Since the source strings have changed, these would get marked as + fuzzy and the original string would be used instead. The original + and translated strings are identical in this case so it wouldn't + matter. But patching the translations helps still because then + po4a will show the correct translation percentage. - src/liblzma/common/filter_common.c | 6 +++--- - 1 file changed, 3 insertions(+), 3 deletions(-) + po4a/de.po | 8 ++++---- + po4a/fr.po | 4 ++-- + po4a/ko.po | 4 ++-- + po4a/pt_BR.po | 4 ++-- + po4a/ro.po | 8 ++++---- + po4a/uk.po | 8 ++++---- + 6 files changed, 18 insertions(+), 18 deletions(-) -commit b03f6cd3ebadd675f2cc9d518cb26fa860269447 +commit 24387c234b4eed1ef9a7eaa107391740b4095568 Author: Lasse Collin -Date: 2011-04-09 15:24:59 +0300 +Date: 2024-05-23 15:15:18 +0300 - xz: Avoid unneeded fstat() on DOS-like systems. + CMake: Add manual support for 32-bit x86 assembly files + + One has to pass -DENABLE_X86_ASM=ON to cmake to enable the + CRC assembly code. Autodetection isn't done. Looking at + CMAKE_SYSTEM_PROCESSOR might not work as it comes from uname + unless cross-compilation is done using a CMake toolchain file. + + On top of this, if the code is run on modern processors that support + the CLMUL instruction, then the C code should be faster (but then + one should also be using a x86-64 build if possible). - src/xz/file_io.c | 14 ++++++++------ - 1 file changed, 8 insertions(+), 6 deletions(-) + CMakeLists.txt | 34 +++++++++++++++++++++++++++++++--- + 1 file changed, 31 insertions(+), 3 deletions(-) -commit 335fe260a81f61ec99ff5940df733b4c50aedb7c +commit 0fb3c9c3f684f5a25bd425ed079a20a79f0c969d Author: Lasse Collin -Date: 2011-04-09 15:11:13 +0300 +Date: 2024-05-23 14:26:45 +0300 - xz: Minor internal changes to handling of --threads. + CMake: Rename USE_DOXYGEN to ENABLE_DOXYGEN - Now it always defaults to one thread. Maybe this - will change again if a threading method is added - that doesn't affect memory usage. + It's more consistent with the other option() uses. - src/xz/args.c | 4 ++-- - src/xz/hardware.c | 24 ++++++++++++------------ - src/xz/hardware.h | 9 ++++----- - 3 files changed, 18 insertions(+), 19 deletions(-) + CMakeLists.txt | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) -commit 9edd6ee895fbe71d245a173f48e511f154a99875 +commit 6bbec3bda02bf87d24fa095074456e723589921f Author: Lasse Collin -Date: 2011-04-08 17:53:05 +0300 +Date: 2024-05-22 15:21:53 +0300 - xz: Change size_t to uint32_t in a few places. + Mention license-check.sh in COPYING - src/xz/coder.c | 6 +++--- - src/xz/coder.h | 2 +- - 2 files changed, 4 insertions(+), 4 deletions(-) + COPYING | 6 ++++++ + 1 file changed, 6 insertions(+) -commit 411013ea4506a6df24d35a060fcbd73a57b73eb3 +commit 62733592a1cc6f0b41f46ef52e06d1a6fe1ff38a Author: Lasse Collin -Date: 2011-04-08 17:48:41 +0300 +Date: 2024-05-22 15:21:53 +0300 - xz: Fix a typo in a comment. + Use more confident language in COPYING - src/xz/coder.c | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) + COPYING | 8 ++++---- + 1 file changed, 4 insertions(+), 4 deletions(-) -commit b34c5ce4b22e8d7b81f9895d15054af41d17f805 +commit a119a4209e8827e1d7c2cfd30cb9f5a9b76f9dff Author: Lasse Collin -Date: 2011-04-05 22:41:33 +0300 +Date: 2024-05-22 15:21:53 +0300 - liblzma: Use TUKLIB_GNUC_REQ to check GCC version in sha256.c. + Build: Run license-check.sh in "mydist" and "dist-hook" + + In mydist the point is to check using the file list from the Git + repository. In dist-hook it is to check that the TARBALL_IGNORE + patterns work when the .git dir or the "git" command aren't available. + + Refuse to create a distribution tarball if license issues are found. - src/liblzma/check/sha256.c | 6 +++--- - 1 file changed, 3 insertions(+), 3 deletions(-) + Makefile.am | 2 ++ + 1 file changed, 2 insertions(+) -commit db33117cc85c17e0b897b5312bd5eb43aac41c03 +commit f3434ecfcb45154508752986f4fc670b8f0555dc Author: Lasse Collin -Date: 2011-04-05 17:12:20 +0300 +Date: 2024-05-22 15:21:53 +0300 - Build: Upgrade m4/acx_pthread.m4 to the latest version. + Add build-aux/license-check.sh - It was renamed to ax_pthread.m4 in Autoconf Archive. + This helps in spotting files that lack SPDX license identifier + and which haven't been explicitly white listed either. The script + requires the .git directory to be present as only the files that + are in the Git repository are checked. + + XZ Utils isn't FSFE REUSE compliant for now. - configure.ac | 2 +- - m4/{acx_pthread.m4 => ax_pthread.m4} | 170 ++++++++++++++++++----------------- - 2 files changed, 88 insertions(+), 84 deletions(-) + Makefile.am | 1 + + build-aux/license-check.sh | 174 +++++++++++++++++++++++++++++++++++++++++++++ + 2 files changed, 175 insertions(+) -commit 1039bfcfc098b69d56ecb39d198a092552eacf6d +commit 9ae2ebc1e504a1814b0788de95fb5c58c0328dde Author: Lasse Collin -Date: 2011-04-05 15:27:26 +0300 +Date: 2024-04-29 17:16:38 +0300 - xz: Use posix_fadvise() if it is available. + Add SPDX license identifiers to files under tests/ossfuzz - configure.ac | 3 +++ - src/xz/file_io.c | 15 +++++++++++++++ - 2 files changed, 18 insertions(+) + tests/ossfuzz/Makefile | 2 ++ + tests/ossfuzz/config/fuzz_decode_alone.options | 2 ++ + tests/ossfuzz/config/fuzz_decode_stream.options | 2 ++ + tests/ossfuzz/config/fuzz_encode_stream.options | 2 ++ + tests/ossfuzz/config/fuzz_lzma.dict | 2 ++ + tests/ossfuzz/config/fuzz_xz.dict | 2 ++ + 6 files changed, 12 insertions(+) -commit 1ef3cf44a8eb9512480af4482a5232ea08363b14 +commit 9000d70eb9815bd7f43ffddc1c3316c507aa0e05 Author: Lasse Collin -Date: 2011-04-05 15:13:29 +0300 +Date: 2024-04-29 17:16:06 +0300 - xz: Call lzma_end(&strm) before exiting if debugging is enabled. + Add SPDX license identifier to .codespellrc - src/xz/coder.c | 10 ++++++++++ - src/xz/coder.h | 5 +++++ - src/xz/main.c | 4 ++++ - 3 files changed, 19 insertions(+) + .codespellrc | 2 ++ + 1 file changed, 2 insertions(+) -commit bd432015d33dcade611d297bc01eb0700088ef6c +commit 903c16fcfa5bfad0cdb2a7383d941243bcb12e76 Author: Lasse Collin -Date: 2011-04-02 14:49:56 +0300 +Date: 2024-05-22 15:12:09 +0300 - liblzma: Fix a memory leak in stream_encoder.c. + Move entries po4a/.gitignore to the top level .gitignore - It leaks old filter options structures (hundred bytes or so) - every time the lzma_stream is reinitialized. With the xz tool, - this happens when compressing multiple files. + The po4a directory is in EXTRA_DIST and thus all files there + are included in the package. .gitignore doesn't belong in the + package so keep that file out of the po4a directory. - src/liblzma/common/stream_encoder.c | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) + .gitignore | 4 ++++ + po4a/.gitignore | 3 --- + 2 files changed, 4 insertions(+), 3 deletions(-) -commit 16889013214e7620d204b6e6c1bf9f3103a13655 +commit 56f1d5ed68e84ba5dfa328ea2291b8f46c995125 Author: Lasse Collin -Date: 2011-04-01 08:47:20 +0300 +Date: 2024-05-20 16:55:00 +0300 - Updated NEWS for 5.0.2. + Tests: Make the config.h grep patterns Meson compatible + + Now the test scripts detect both + + #define HAVE_DECODER_ARM + #define HAVE_DECODER_ARM 1 + + as support for the ARM filter without confusing it with these: + + #define HAVE_DECODER_ARM64 + #define HAVE_DECODER_ARM64 1 + + Previously only the ones ending with " 1" were accepted for + the macros where this kind of confusion was possible. + + This should help with Meson support because Meson's built-in + features produce config.h entries that are either + + #define FOO 1 + #define FOO 0 + + or: + + #define FOO + #undef FOO + + The former method has a benefit that one can use "#if FOO" and -Wundef + will catch if a #define is missing (for example, it helps catching + typos). But XZ Utils has to use the latter since it has been + convenient with Autoconf's default behavior.[*] While it's easy to + emulate the Autoconf style (#define FOO 1 vs. no #define at all) + in Meson, it results in clumsy code. Thus it's better to change + the few places in the tests where this difference matters. + + [*] While most checks in Autoconf default to the second style above, + a few things use the first style (like AC_CHECK_DECLS). The mix + of both styles is the most confusing as one has to remember which + macro needs #ifdef and which #if. Currently HAVE_VISIBILITY is + only such config.h entry that is 1 or 0. It comes unmodified + from Gnulib's visibility.m4. - NEWS | 18 ++++++++++++++++++ - 1 file changed, 18 insertions(+) + tests/test_compress.sh | 4 ++-- + tests/test_files.sh | 2 +- + 2 files changed, 3 insertions(+), 3 deletions(-) -commit 85cdf7dd4e97b078e7b929e47f55a7f1da36010f +commit 9d997d6f9d4f042412e45c7b7a23a14ad2e4f9aa Author: Lasse Collin -Date: 2011-03-31 15:06:58 +0300 +Date: 2024-05-20 16:55:00 +0300 - Update INSTALL with another note about IRIX. + CMake: Add comments - INSTALL | 4 ++++ - 1 file changed, 4 insertions(+) + tests/tests.cmake | 2 ++ + 1 file changed, 2 insertions(+) -commit c3f4995586873d6a4fb7e451010a128571a9a370 +commit d35368b33e54bad2f566df99fac29ffea38e34de Author: Lasse Collin -Date: 2011-03-31 12:22:55 +0300 +Date: 2024-05-20 16:55:00 +0300 - Tests: Add a new file to test empty LZMA2 streams. + CMake: Remove the note that some tests aren't run + + They are now in the common build configurations. - tests/files/README | 4 ++++ - tests/files/good-1-lzma2-5.xz | Bin 0 -> 52 bytes - 2 files changed, 4 insertions(+) + CMakeLists.txt | 2 -- + 1 file changed, 2 deletions(-) -commit 0d21f49a809dc2088da6cc0da7f948404df7ecfa +commit dc232d584619b2819a9c52d6ad5d8b5d56b392ba Author: Lasse Collin -Date: 2011-03-31 11:54:48 +0300 +Date: 2024-05-20 16:55:00 +0300 - liblzma: Fix decoding of LZMA2 streams having no uncompressed data. - - The decoder considered empty LZMA2 streams to be corrupt. - This shouldn't matter much with .xz files, because no encoder - creates empty LZMA2 streams in .xz. This bug is more likely - to cause problems in applications that use raw LZMA2 streams. + CMake: Add support for test_files.sh - src/liblzma/lzma/lzma2_decoder.c | 8 ++++---- - 1 file changed, 4 insertions(+), 4 deletions(-) + tests/tests.cmake | 20 ++++++++++++++++++++ + 1 file changed, 20 insertions(+) -commit 40277998cb9bad564ce4827aff152e6e1c904dfa +commit a7e9230af9d1f87f474fe38886eb977d4149dc9b Author: Lasse Collin -Date: 2011-03-24 01:42:49 +0200 +Date: 2024-05-20 16:55:00 +0300 - Scripts: Better fix for xzgrep. + Tests: Make test_files.sh more flexible - Now it uses "grep -q". + Add a new optional argument to specify the directory of the xz and + xzdec executables. - Thanks to Gregory Margo. + If ../config.h doesn't exist, assume that all encoders and decoders + are available. - src/scripts/xzgrep.in | 8 ++++++-- - 1 file changed, 6 insertions(+), 2 deletions(-) + tests/test_files.sh | 18 +++++++++++++----- + 1 file changed, 13 insertions(+), 5 deletions(-) -commit 2118733045ad0ca183a3f181a0399baf876983a6 +commit b40e6efbb48d740b9b5b303e59e344801cbb5bd8 Author: Lasse Collin -Date: 2011-03-24 01:22:18 +0200 +Date: 2024-05-20 16:55:00 +0300 - Updated THANKS. + CMake: Add support for test_compress.sh tests - THANKS | 1 + - 1 file changed, 1 insertion(+) + tests/tests.cmake | 26 ++++++++++++++++++++++++++ + 1 file changed, 26 insertions(+) -commit c7210d9a3fca6f31a57208bfddfc9ab20a2e097a +commit ac3222d2cb1ff3a15eb6d58f9ea9bc78e8bc3bb2 Author: Lasse Collin -Date: 2011-03-24 01:21:32 +0200 +Date: 2024-05-20 16:55:00 +0300 - Scripts: Fix xzgrep -l. + Tests: Make test_compress.sh more flexible + + Add a new optional second argument: directory of the xz and xzdec + executables. This is need with the CMake build where the binaries + end up in the top-level build directory. + + If ../config.h doesn't exist, assume that all encoders and decoders + are available. This will make this script usable from CMake in the + most common build configuration. - It didn't work at all. It tried to use the -q option - for grep, but it appended it after "--". This works - around it by redirecting to /dev/null. The downside - is that this can be slower with big files compared - to proper use of "grep -q". + NOTE: Since the existence of ../config.h is checked, the working + directory of the test script must be a subdir in the build tree! + Otherwise ../config.h would look outside the build tree. - Thanks to Gregory Margo. + Use the default check type instead of forcing CRC32 or CRC64. + Now the script doesn't need to check if CRC64 is available. - src/scripts/xzgrep.in | 4 ++-- - 1 file changed, 2 insertions(+), 2 deletions(-) + tests/test_compress.sh | 41 +++++++++++++++++++++++++++++------------ + 1 file changed, 29 insertions(+), 12 deletions(-) -commit 4eb83e32046a6d670862bc91c3d82530963b455e +commit 006040b29c83104403621e950ada0c8956c56b3d Author: Lasse Collin -Date: 2011-03-19 13:08:22 +0200 +Date: 2024-05-20 16:55:00 +0300 - Scripts: Add lzop (.lzo) support to xzdiff and xzgrep. + CMake: Prepare to support the test_*.sh tests + + This is a bit hacky since the scripts grep config.h to know which + features were built but the CMake build doesn't create config.h. + So instead those test scripts will be run only when all relevant + features have been enabled. - src/scripts/xzdiff.1 | 6 ++++-- - src/scripts/xzdiff.in | 22 ++++++++++++++-------- - src/scripts/xzgrep.1 | 11 +++++++---- - src/scripts/xzgrep.in | 5 +++-- - 4 files changed, 28 insertions(+), 16 deletions(-) + tests/tests.cmake | 49 +++++++++++++++++++++++++++++++++++++++++++++++++ + 1 file changed, 49 insertions(+) -commit 923b22483bd9356f3219b2b784d96f455f4dc499 +commit 6167607a6ea72fb74eefb943c4566e3cab528cd2 Author: Lasse Collin -Date: 2011-03-18 19:10:30 +0200 +Date: 2024-05-20 16:55:00 +0300 - xz: Add --block-size=SIZE. - - This uses LZMA_FULL_FLUSH every SIZE bytes of input. - - Man page wasn't updated yet. + Tests: test_suffix.sh: Add a comment - src/xz/args.c | 7 +++++++ - src/xz/coder.c | 50 ++++++++++++++++++++++++++++++++++++++++---------- - src/xz/coder.h | 3 +++ - src/xz/message.c | 4 ++++ - 4 files changed, 54 insertions(+), 10 deletions(-) + tests/test_suffix.sh | 3 +++ + 1 file changed, 3 insertions(+) -commit 57597d42ca1740ad506437be168d800a50f1a0ad +commit 4e9023857d287f624562156b60dc23d2b64c0f10 Author: Lasse Collin -Date: 2011-03-18 18:19:19 +0200 +Date: 2024-05-18 00:34:07 +0300 - xz: Add --single-stream. - - This can be useful when there is garbage after the - compressed stream (.xz, .lzma, or raw stream). + Fix typos - Man page wasn't updated yet. + Thanks to xx on #tukaani. - src/xz/args.c | 6 ++++++ - src/xz/coder.c | 11 +++++++++-- - src/xz/coder.h | 3 +++ - src/xz/message.c | 6 +++++- - 4 files changed, 23 insertions(+), 3 deletions(-) + src/common/mythread.h | 2 +- + src/common/tuklib_integer.h | 2 +- + src/liblzma/api/lzma/base.h | 2 +- + src/liblzma/common/filter_buffer_decoder.c | 2 +- + src/liblzma/common/filter_common.c | 2 +- + src/scripts/xzgrep.in | 2 +- + 6 files changed, 6 insertions(+), 6 deletions(-) -commit 96f94bc925d579a700147fa5d7793b64d69cfc18 +commit b14d08fbbc254485ace9ccfe7908674f608a62ae Author: Lasse Collin -Date: 2011-02-04 22:49:31 +0200 +Date: 2024-05-18 00:23:52 +0300 - xz: Clean up suffix.c. + liblzma: Fix white space - struct suffix_pair isn't needed in compresed_name() - so get rid of it there. + Thanks to xx on #tukaani. - src/xz/suffix.c | 44 ++++++++++++++++++++------------------------ - 1 file changed, 20 insertions(+), 24 deletions(-) + src/liblzma/simple/simple_coder.h | 8 ++++---- + 1 file changed, 4 insertions(+), 4 deletions(-) -commit 8930c7ae3f82bdae15aa129f01de08be23d7e8d7 +commit 9f1a6d6f9a258886933a22239a5b81af34b28199 Author: Lasse Collin -Date: 2011-02-04 11:29:47 +0200 +Date: 2024-05-15 23:14:17 +0300 - xz: Check if the file already has custom suffix when compressing. + Build: Temporarily disable CRC CLMUL to silence OSS Fuzz + + The code makes aligned 16-byte reads which may read up to 15 bytes + before the beginning or past the end of the buffer if the buffer + is misaligned. The unneeded bytes are then ignored. It cannot cross + page boundaries and thus cannot cause access violations. - Now "xz -S .test foo.test" refuses to compress the - file because it already has the suffix .test. The man - page had it documented this way already. + This inherently trips address sanitizer which was already disabled + with __attribute__((__no_sanitize_address__)). However, it also + trips memory sanitizer if the extra bytes are uninitialized because + memory sanitizer doesn't see that those bytes then get ignored by + byte shuffling in the xmm registers. + + The plan is to change the code so that all sanitizers pass but it's + not finished yet (performance shouldn't get worse) so as a temporary + measure to keep OSS Fuzz happy, the CLMUL CRC is now disabled even + though I think think the code is fine to use (and easy enough to review + the memory accesses in it too). - src/xz/suffix.c | 9 +++++++++ - 1 file changed, 9 insertions(+) + configure.ac | 4 +++- + 1 file changed, 3 insertions(+), 1 deletion(-) -commit 940d5852c6cf08abccc6befd9d1b5411c9076a58 +commit 142e670a413a7bce1a2647f1cf1f33f8ee2dbe88 Author: Lasse Collin -Date: 2011-02-02 23:01:51 +0200 +Date: 2024-05-13 17:15:04 +0300 - Updated THANKS. + xz: Document the static function get_chains_memusage() - THANKS | 1 + - 1 file changed, 1 insertion(+) + src/xz/coder.c | 14 ++++++++++++-- + 1 file changed, 12 insertions(+), 2 deletions(-) -commit 4ebe65f839613f27f127bab7b8c347d982330ee3 +commit 78e984399a64bfee5d11e7308e0bdbc1006db2ca Author: Lasse Collin -Date: 2011-02-02 23:00:33 +0200 +Date: 2024-05-13 17:07:22 +0300 - Translations: Add Polish translation. - - Thanks to Jakub Bogusz. + xz: Rename filters_memusage_max() to get_chains_memusage() - po/LINGUAS | 1 + - po/pl.po | 825 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ - 2 files changed, 826 insertions(+) + src/xz/coder.c | 14 ++++++-------- + 1 file changed, 6 insertions(+), 8 deletions(-) -commit fc1d292dca1925dfd17174f443f91a696ecd5bf8 +commit 54c3db0a83d3e67d89aba92a0957f2dce9b111a7 Author: Lasse Collin -Date: 2011-02-02 22:24:00 +0200 +Date: 2024-05-13 17:04:05 +0300 - Updated THANKS. + xz: Rename filter_memusages to chains_memusages - THANKS | 1 + - 1 file changed, 1 insertion(+) + src/xz/coder.c | 6 +++--- + 1 file changed, 3 insertions(+), 3 deletions(-) -commit 6dd061adfd2775428b079eb03d6fd47d7c0f1ffe -Merge: 9d542ce 5fbce0b +commit d9e1ae79ec90d6a7eafeaceaf0ece4f0c83d4417 Author: Lasse Collin -Date: 2011-02-06 20:13:01 +0200 +Date: 2024-05-12 22:26:30 +0300 + + xz: Simplify the memory usage scaling code + + This is closer to what it was before the --filtersX support was added, + just extended to support for scaling all filter chains. The method + before this commit was an extended version of the original too but + it was done in a more complex way for no clear reason. In case of + an error, the complex version printed fewer informative messages + (a good thing) but it's not a sigificant benefit. + + In the limit is too low even for single-threaded mode, the required + amount of memory is now reported like in 5.4.x instead of like in + 5.5.1alpha - 5.6.1 which showed the original non-scaled usage. It + had been a FIXME in the old code but it's not clear what message + makes the most sense. + + Fixes: 5f0c5a04388f8334962c70bc37a8c2ff8f605e0a - Merge commit '5fbce0b8d96dc96775aa0215e3581addc830e23d' + src/xz/coder.c | 163 ++++++++++++++++++++------------------------------------- + 1 file changed, 57 insertions(+), 106 deletions(-) -commit 5fbce0b8d96dc96775aa0215e3581addc830e23d +commit 0ee56983d198b776878432703de664049b1be32e Author: Lasse Collin -Date: 2011-01-28 20:16:57 +0200 +Date: 2024-05-13 12:14:00 +0300 - Update NEWS for 5.0.1. + xz: Edit comments - NEWS | 14 ++++++++++++++ - 1 file changed, 14 insertions(+) + src/xz/coder.h | 6 ++---- + 1 file changed, 2 insertions(+), 4 deletions(-) -commit 03ebd1bbb314f9f204940219a835c883bf442475 +commit ec82a49c3553f7206104582dbfb8b64fa433b491 Author: Lasse Collin -Date: 2011-01-26 12:19:08 +0200 +Date: 2024-05-13 12:03:51 +0300 - xz: Fix --force on setuid/setgid/sticky and multi-hardlink files. - - xz didn't compress setuid/setgid/sticky files and files - with multiple hard links even with --force. This bug was - introduced in 23ac2c44c3ac76994825adb7f9a8f719f78b5ee4. - - Thanks to Charles Wilson. + xz: Rename chain_idx to chain_num - src/xz/file_io.c | 15 +++++++-------- - 1 file changed, 7 insertions(+), 8 deletions(-) + src/xz/coder.c | 6 +++--- + 1 file changed, 3 insertions(+), 3 deletions(-) -commit 9d542ceebcbe40b174169c132ccfcdc720ca7089 -Merge: 4f2c69a 7bd0a5e +commit a731a6993c34bbbd55abaf9c166718682b1da24f Author: Lasse Collin -Date: 2011-01-19 11:45:35 +0200 +Date: 2024-05-12 22:29:11 +0300 - Merge branch 'v5.0' + xz: Edit coding style -commit 7bd0a5e7ccc354f7c2e95c8bc27569c820f6a136 + src/xz/coder.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit 32eb176b89243fce3112347fe43a8ad14a9fd2be Author: Lasse Collin -Date: 2011-01-18 21:25:24 +0200 +Date: 2024-05-12 22:16:05 +0300 - Updated THANKS. + xz: Edit comments + + Fixes: 5f0c5a04388f8334962c70bc37a8c2ff8f605e0a - THANKS | 1 + - 1 file changed, 1 insertion(+) + src/xz/coder.c | 8 ++------ + 1 file changed, 2 insertions(+), 6 deletions(-) -commit f71c4e16e913f660977526f0ef8d2acdf458d7c9 +commit b90339f4daa510d2b1b8c550f855a99667f1d004 Author: Lasse Collin -Date: 2011-01-18 21:23:50 +0200 +Date: 2024-05-12 21:57:49 +0300 - Add alloc_size and malloc attributes to a few functions. + xz: Fix grammar in a comment - Thanks to Cristian Rodríguez for the original patch. + Fixes: cb3111e3ed84152912b5138d690c8d9f00c6ef02 - src/common/sysdefs.h | 6 ++++++ - src/liblzma/common/common.h | 2 +- - src/xz/util.h | 5 +++-- - 3 files changed, 10 insertions(+), 3 deletions(-) + src/xz/coder.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) -commit 316cbe24465143edde8f6ffb7532834b7b2ea93f +commit 4c0bdaf13d651b22ba13bd93f8379724d6ccdc13 Author: Lasse Collin -Date: 2010-12-13 16:36:33 +0200 +Date: 2024-05-12 21:46:56 +0300 - Scripts: Fix gzip and bzip2 support in xzdiff. + xz: Rename filter_memusages to encoder_memusages - src/scripts/xzdiff.in | 12 ++++++------ + src/xz/coder.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) -commit 4f2c69a4e3e0aee2e37b0b1671d34086e20c8ac6 -Merge: adb89e6 9311774 +commit b54aa023e0ec291b06e976e5f094ab0549e7b09b Author: Lasse Collin -Date: 2010-12-12 23:13:22 +0200 +Date: 2024-05-12 21:42:05 +0300 + + xz: Edit coding style - Merge branch 'v5.0' + src/xz/coder.c | 8 ++++---- + 1 file changed, 4 insertions(+), 4 deletions(-) -commit 9311774c493c19deab51ded919dcd2e9c4aa2829 +commit 49f67d3d3f42b640a7dfc4ca04c8934f658e10ce Author: Lasse Collin -Date: 2010-12-12 21:23:55 +0200 +Date: 2024-05-12 21:31:02 +0300 + + xz: Rename filters_index to chain_num + + The reason is the same as in bd0782c1f13e52cd0fd8415208e30e47004a4c68. - Build: Enable ASM on DJGPP by default. + src/xz/args.c | 8 ++++---- + src/xz/coder.c | 8 ++++---- + src/xz/coder.h | 2 +- + 3 files changed, 9 insertions(+), 9 deletions(-) - configure.ac | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) +commit ff9e8b3d069ecfa52ec43dcdb198542d1692a492 +Author: Lasse Collin +Date: 2024-05-12 21:22:43 +0300 + + xz: Replace a few uint32_t with "unsigned" to reduce the number of casts + + These hold only tiny values. + + src/xz/args.c | 2 +- + src/xz/coder.c | 17 ++++++++--------- + src/xz/coder.h | 2 +- + 3 files changed, 10 insertions(+), 11 deletions(-) -commit 4a42aaee282fc73b482581684d65110506d5efdd +commit b5e6c1113b1ba02c282bd9163eccdb521c937a78 Author: Lasse Collin -Date: 2010-12-12 16:09:42 +0200 +Date: 2024-05-12 21:10:45 +0300 - Updated THANKS. + xz: Rename filters_used_mask to chains_used_mask + + The reason is the same as in bd0782c1f13e52cd0fd8415208e30e47004a4c68. - THANKS | 1 + - 1 file changed, 1 insertion(+) + src/xz/coder.c | 30 +++++++++++++++--------------- + 1 file changed, 15 insertions(+), 15 deletions(-) -commit ce56f63c41ee210e6308090eb6d49221fdf67d6c +commit 32500dfaadae2ea36fda2e17b49ae7d9ac1acf52 Author: Lasse Collin -Date: 2010-12-12 16:07:11 +0200 +Date: 2024-05-12 17:14:43 +0300 - Add missing PRIx32 and PRIx64 compatibility definitions. + xz: Move the setting of "check" in coder_set_compression_settings() - This fixes portability to systems that lack C99 inttypes.h. + It's more logical to do it in the beginning instead of in the middle + of the filter chain handling. - Thanks to Juan Manuel Guerrero. + Fixes: d6af7f347077b22403133239592e478931307759 - src/common/sysdefs.h | 9 +++++++++ - 1 file changed, 9 insertions(+) + src/xz/coder.c | 18 +++++++++--------- + 1 file changed, 9 insertions(+), 9 deletions(-) -commit e6baedddcf54e7da049ebc49183565b99facd4c7 +commit ad146b1f42bbb678175a503a45ce525e779f9b8b Author: Lasse Collin -Date: 2010-12-12 14:50:04 +0200 +Date: 2024-05-12 17:09:17 +0300 - DOS-like: Treat \ and : as directory separators in addition to /. + xz: Rename "filters" to "chains" + + The convention is that + + lzma_filter filters[LZMA_FILTERS_MAX + 1]; - Juan Manuel Guerrero had fixed this in his XZ Utils port - to DOS/DJGPP. The bug affects also Windows and OS/2. + contains the filters of a single filter chain. + It was so here as well before the commit + d6af7f347077b22403133239592e478931307759. + It changes "filters" to a ten-element array of filter chains. + It's clearer to call this array-of-arrays "chains". + + This also renames "filter_idx" to "chain_idx" which is used + as an index as in chains[chain_idx]. - src/xz/suffix.c | 33 +++++++++++++++++++++++++++++---- - 1 file changed, 29 insertions(+), 4 deletions(-) + src/xz/coder.c | 68 +++++++++++++++++++++++++++++----------------------------- + 1 file changed, 34 insertions(+), 34 deletions(-) -commit adb89e68d43a4cadb0c215b45ef7a75737c9c3ec -Merge: 7c24e0d b7afd3e +commit 5a4ae4e4d0105404184e9a82ee08f94e1b7783e0 Author: Lasse Collin -Date: 2010-12-07 18:53:04 +0200 +Date: 2024-05-12 16:56:15 +0300 + + xz: Clean up a comment - Merge branch 'v5.0' + src/xz/coder.c | 9 +++------ + 1 file changed, 3 insertions(+), 6 deletions(-) -commit b7afd3e22a8fac115b75c738d40d3eb1de7e286f +commit 2de80494ed9a4dc7db395a32a5efb770ce769804 Author: Lasse Collin -Date: 2010-12-07 18:52:04 +0200 +Date: 2024-05-12 16:52:09 +0300 - Translations: Fix Czech translation of "sparse file". - - Thanks to Petr Hubený and Marek Černocký. + xz: Add clarifying assertions - po/cs.po | 88 ++++++++++++++++++++++++++++++++-------------------------------- - 1 file changed, 44 insertions(+), 44 deletions(-) + src/xz/coder.c | 4 ++++ + 1 file changed, 4 insertions(+) -commit 7c24e0d1b8a2e86e9263b0d56d39621e01aed7af -Merge: b4d42f1 3e56470 +commit 1eaad004bf7748976324672db028e34f42802e61 Author: Lasse Collin -Date: 2010-11-15 14:33:01 +0200 +Date: 2024-05-10 20:23:33 +0300 + + xz: Add a clarifying assertion + + Fixes: 5f0c5a04388f8334962c70bc37a8c2ff8f605e0a - Merge branch 'v5.0' + src/xz/coder.c | 1 + + 1 file changed, 1 insertion(+) -commit 3e564704bc6f463cb2db11e3f3f0dbd71d85992e +commit 605094329b986244833c967c04963cacc41a868d Author: Lasse Collin -Date: 2010-11-15 14:28:26 +0200 +Date: 2024-05-12 16:47:17 +0300 - liblzma: Document the return value of lzma_lzma_preset(). + xz: Clarify a comment - src/liblzma/api/lzma/lzma.h | 3 +++ - 1 file changed, 3 insertions(+) + src/xz/coder.c | 4 +++- + 1 file changed, 3 insertions(+), 1 deletion(-) -commit 2964d8d691ed92abdcf214888d79ad6d79774735 -Author: Jonathan Nieder -Date: 2010-11-12 15:22:13 -0600 +commit 8fac2577f2dbb9491afd8500f60d004c9071df3b +Author: Lasse Collin +Date: 2024-05-12 16:28:25 +0300 - Simplify paths in generated API docs - - Currently the file list generated by Doxygen has src/ at the - beginning of each path. Paths like common/sysdefs.h and - liblzma/api/lzma.h are easier to read without such a prefix. + xz: Use the info collected in parse_block_list() - Builds from a separate build directory with - - mkdir build - cd build - ../configure - doxygen Doxyfile - - include an even longer prefix /home/someone/src/xz/src; this - patch has the nice side-effect of eliminating that prefix, too. - - Fixes: http://bugs.debian.org/572273 + This is slightly simpler and it avoids looping through + the opt_block_list array. - Doxyfile.in | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) + src/xz/coder.c | 95 ++++++++++++++++++++++++---------------------------------- + 1 file changed, 39 insertions(+), 56 deletions(-) -commit b4d42f1a7120e2cefeb2f14425efe2ca6db85416 -Author: Anders F Bjorklund -Date: 2010-11-05 12:56:11 +0100 +commit 81d350dab864b985b740742772f3b132d4c52914 +Author: Lasse Collin +Date: 2024-05-12 15:48:45 +0300 - add build script for macosx universal + xz: Remember the filter chains and the largest Block in parse_block_list() - macosx/build.sh | 92 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ - 1 file changed, 92 insertions(+) + src/xz/args.c | 18 ++++++++++++++++++ + src/xz/coder.c | 2 ++ + src/xz/coder.h | 13 +++++++++++++ + 3 files changed, 33 insertions(+) -commit 15ee6935abe4a2fc76639ee342ca2e69af3e0ad6 +commit 46ab56968f7dfdac187710a1223659d832fa1565 Author: Lasse Collin -Date: 2010-11-04 18:31:40 +0200 +Date: 2024-05-12 15:38:48 +0300 - Update the copies of GPLv2 and LGPLv2.1 from gnu.org. - - There are only a few white space changes. + xz: Update a comment and initialization of filters_used_mask + + src/xz/coder.c | 16 ++++++++-------- + 1 file changed, 8 insertions(+), 8 deletions(-) - COPYING.GPLv2 | 14 +++++++------- - COPYING.LGPLv2.1 | 16 +++++++--------- - 2 files changed, 14 insertions(+), 16 deletions(-) +commit e89293a0baeb8663707c6b4a74fbb310ec698a8f +Author: Lasse Collin +Date: 2024-05-12 15:08:10 +0300 + + xz: parse_block_list: Edit integer type casting + + src/xz/args.c | 5 ++--- + 1 file changed, 2 insertions(+), 3 deletions(-) -commit 8e355f7fdbeee6fe394eb02a28f267ce99a882a2 -Merge: 974ebe6 37c2565 +commit 87011e40c168255cd2edea129ee68c901770603b Author: Lasse Collin -Date: 2010-10-26 15:53:06 +0300 +Date: 2024-05-12 14:51:37 +0300 - Merge branch 'v5.0' + xz: Make filter_memusages a local variable -commit 37c25658efd25b034266daf87cd381d20d1df776 + src/xz/coder.c | 35 +++++++++++++++++++++-------------- + 1 file changed, 21 insertions(+), 14 deletions(-) + +commit 347b412a9374e0456bef9da0d7d79174c0b6f1a5 Author: Lasse Collin -Date: 2010-10-26 15:48:48 +0300 +Date: 2024-05-10 20:33:08 +0300 - Build: Copy the example programs to $docdir/examples. + xz: Remove unused code and simplify + + opt_mode == MODE_COMPRESS isn't possible when HAVE_ENCODERS isn't + defined. Thus, when *encoding*, the message about *decoder* memory + usage is possible to show only when both encoder and decoder have + been built. - The example programs by Daniel Mealha Cabrita were included - in the git repository, but I had forgot to add them to - Makefile.am. Thus, they didn't get included in the source - package at all by "make dist". + Since the message is shown only at V_DEBUG, skip the memusage + calculation if verbosity level isn't high enough. + + Fixes: 5f0c5a04388f8334962c70bc37a8c2ff8f605e0a - Makefile.am | 5 +++++ - windows/build.bash | 3 ++- - 2 files changed, 7 insertions(+), 1 deletion(-) + src/xz/coder.c | 16 ++++------------ + 1 file changed, 4 insertions(+), 12 deletions(-) -commit 974ebe63497bdf0d262e06474f0dd5a70b1dd000 +commit 31358c057c9de9d6aba96bae112b2d17942de7cb Author: Lasse Collin -Date: 2010-10-26 10:36:41 +0300 +Date: 2024-05-10 20:22:58 +0300 - liblzma: Rename a few variables and constants. + xz: Fix integer type from uint64_t to uint32_t - This has no semantic changes. I find the new names slightly - more logical and they match the names that are already used - in XZ Embedded. + lzma_options_lzma.dict_size is uint32_t so use it here too. - The name fastpos wasn't changed (not worth the hassle). + Fixes: 5f0c5a04388f8334962c70bc37a8c2ff8f605e0a - src/liblzma/lzma/fastpos.h | 55 +++++------ - src/liblzma/lzma/lzma2_encoder.c | 2 +- - src/liblzma/lzma/lzma_common.h | 45 ++++----- - src/liblzma/lzma/lzma_decoder.c | 58 +++++------ - src/liblzma/lzma/lzma_encoder.c | 56 +++++------ - src/liblzma/lzma/lzma_encoder_optimum_fast.c | 9 +- - src/liblzma/lzma/lzma_encoder_optimum_normal.c | 128 ++++++++++++------------- - src/liblzma/lzma/lzma_encoder_private.h | 16 ++-- - 8 files changed, 183 insertions(+), 186 deletions(-) + src/xz/coder.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) -commit 7c427ec38d016c0070a42315d752857e33792fc4 +commit 3f71e0f3a118e1012526f94fd640a626d30cb599 Author: Lasse Collin -Date: 2010-10-25 12:59:25 +0300 +Date: 2024-05-08 21:40:07 +0300 - Bump version 5.1.0alpha. + debug/translation.bash: Remove an outdated test command + + Since 5.3.5beta, "xz --lzma2=mf=bt4,nice=2" works even though bt4 needs + at least nice=4. It is rounded up internally by liblzma when needed. + + Fixes: 5cd9f0df78cc4f8a7807bf6104adea13034fbb45 - src/liblzma/api/lzma/version.h | 4 ++-- - 1 file changed, 2 insertions(+), 2 deletions(-) + debug/translation.bash | 1 - + 1 file changed, 1 deletion(-) -commit e45929260cd902036efd40c5610a8d0a50d5712b +commit b05a516830095a0e1937aeb31c937fb0400408b6 Author: Lasse Collin -Date: 2010-10-23 17:25:52 +0300 +Date: 2024-05-07 20:41:28 +0300 - Build: Fix mydist rule when .git doesn't exist. + Fix the date of NEWS for 5.4.5 - Makefile.am | 1 + - 1 file changed, 1 insertion(+) + NEWS | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) -commit 6e1326fcdf6b6209949be57cfe3ad4b781b65168 +commit 6d336aeb97b69c496ddc626af403f6f21c753658 Author: Lasse Collin -Date: 2010-10-23 14:15:35 +0300 +Date: 2024-05-07 16:21:15 +0300 - Add NEWS for 5.0.0. + Build: Update visibility.m4 from Gnulib + + This fixes the syntax of the "serial" line and renames + a temporary variable. - NEWS | 62 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ - 1 file changed, 62 insertions(+) + m4/visibility.m4 | 13 +++++++------ + 1 file changed, 7 insertions(+), 6 deletions(-) -commit b667a3ef6338a2c1db7b7706b1f6c99ea392221c +commit ab51e8ee610e2a893906859848f93d5cb0d5ba83 Author: Lasse Collin -Date: 2010-10-23 14:02:53 +0300 +Date: 2024-05-07 15:05:21 +0300 - Bump version to 5.0.0 and liblzma version-info to 5:0:0. + po4a/update-po: Delete the *.po.authors files + + These are temporary files that are needed only when running po4a. + The top-level Makefile.am puts the whole po4a directory into + distribution tarball (it's simpler) so deleting these temporary + files is needed to prevent them from getting into tarballs. + + po4a/update-po | 4 ++++ + 1 file changed, 4 insertions(+) + +commit e4780244a17420cc95d5498cd6e02ad10eac6e5f +Author: Lasse Collin +Date: 2024-05-07 13:12:17 +0300 + + xz: Edit comments and coding style + + src/xz/coder.c | 25 ++++++++++++------------- + 1 file changed, 12 insertions(+), 13 deletions(-) + +commit fe4d8b0c80eaeca3381be302eeb89aba871a7e7c +Author: Lasse Collin +Date: 2024-05-06 23:08:22 +0300 + + xz: Omit an incorrect comment + + It likely was a leftover from a development version of the code. + + Fixes: 183819bfd9efac8c184d9bf123325719b7eee30f + + src/xz/coder.c | 6 +----- + 1 file changed, 1 insertion(+), 5 deletions(-) + +commit 9bef5b8d17dd5e009d6a6b2becc2dc535da53937 +Author: Lasse Collin +Date: 2024-05-06 23:04:31 +0300 + + xz: Add braces to a for-statement and to an if-statement + + No functional changes. + + Fixes: 5f0c5a04388f8334962c70bc37a8c2ff8f605e0a + Fixes: 479fd58d60622331fcbe48fddf756927b9f80d9a + + src/xz/coder.c | 6 ++++-- + 1 file changed, 4 insertions(+), 2 deletions(-) + +commit de06b9f0c0a3f72569829ecadbc9c0a3ef099f57 +Author: Lasse Collin +Date: 2024-05-06 23:00:09 +0300 + + liblzma: Omit an unneeded array from the x86 filter + + Fixes: 6aa2a6deeba04808a0fe4461396e7fb70277f3d4 + + src/liblzma/simple/x86.c | 5 +---- + 1 file changed, 1 insertion(+), 4 deletions(-) + +commit 7da488cb933fdf51cfc14cb5810beb0766224380 +Author: Lasse Collin +Date: 2024-05-06 22:56:31 +0300 + + CMake: Add test_suffix.sh to the tests + + tests/tests.cmake | 13 +++++++++++++ + 1 file changed, 13 insertions(+) + +commit a805594ed0b4cbf7b81aa28ff46a8ab3c83c6876 +Author: Lasse Collin +Date: 2024-05-06 22:55:54 +0300 + + Test: Add CMake support to test_suffix.sh + + It needs to find the xz executable from a different directory + and work without config.h. + + tests/test_suffix.sh | 12 +++++++----- + 1 file changed, 7 insertions(+), 5 deletions(-) + +commit 50e19489387774bab3c4a988397d0d9c7a142a46 +Author: Lasse Collin +Date: 2024-05-06 20:45:34 +0300 + + Update INSTALL about MINIX 3 + + The latest stable is 3.3.0 and it's from 2014. + Don't mention the older versions in INSTALL. + 3.3.0 ships with Clang already. + + Testing with 3.4.0beta6 shows that tuklib_physmem + works too so omit comments about that from INSTALL. + Visibility warnigns weren't a problem either. + + Thus it's enough to mention the need for --disable-threads + as configure doesn't autodetect the lack of pthreads. + + INSTALL | 20 +++++++------------- + 1 file changed, 7 insertions(+), 13 deletions(-) + +commit 68d18aea1422a2b86b98b71d0b019233d84e01b0 +Author: Lasse Collin +Date: 2024-05-02 23:00:16 +0300 + + Windows: Remove the "doc/api" line from README-Windows.txt + + Fixes: 252aa1d67bc015eeba462803ab72edeb7744d864 + + windows/README-Windows.txt | 2 -- + 1 file changed, 2 deletions(-) + +commit 8ede961374613aa302a13571d662cfaea1cf91f7 +Author: Lasse Collin +Date: 2024-05-02 22:59:04 +0300 + + Build: Don't copy doc/api from source tree to distribution tarball + + It was copied if it existed. This was intentional when autogen.sh + still built liblzma API docs with Doxygen. + + Fixes: d3a77ebc04bf1db8d52de2d9b0f07877bc4fd139 + + Makefile.am | 5 ----- + 1 file changed, 5 deletions(-) + +commit 9a6761aa35ed84d30bd2fda2333a4fdf3f46ecdc +Author: Sam James +Date: 2024-05-02 13:26:40 +0100 + + ci: add SPDX headers + + I've checked over each of these and they're straightforward applications + of the relevant Github Actions. + + .github/workflows/freebsd.yml | 2 ++ + .github/workflows/netbsd.yml | 2 ++ + .github/workflows/openbsd.yml | 2 ++ + 3 files changed, 6 insertions(+) + +commit 81efe6119f86e3274e512c9eca5ec22b2196c2b3 +Author: Yaroslav Halchenko +Date: 2024-03-29 14:37:24 -0400 + + codespell: Ignore the THANKS file and debbugs.gnu.org URL + + This way "codespell -i 0" is silent. + + This is the first commit from + https://github.com/tukaani-project/xz/pull/93 + with trivial edits by Lasse Collin. + + .codespellrc | 6 +++++- + 1 file changed, 5 insertions(+), 1 deletion(-) + +commit 905bfc74fe2670fd9c39014803017ab53d325401 +Author: Lasse Collin +Date: 2024-04-30 14:37:11 +0300 + + Add .gitattributes to clean up git-archive output + + .gitattributes | 7 +++++++ + 1 file changed, 7 insertions(+) + +commit 3334c71d3d4294a4f6569df3ba9bcf2443dfa501 +Author: Lasse Collin +Date: 2024-04-19 12:11:09 +0300 + + xzdec: Support Landlock ABI version 4 + + This was added to xz in 02e3505991233901575b7eabc06b2c6c62a96899 + but I forgot to do the same in xzdec. + + The Landlock sandbox in xzdec could be stricter as now it's + active only for the last file being decompressed. In xz, + read-only sandbox is used for multi-file case. On the other hand, + xz doesn't go to the strictest mode when processing the last file + when more than one file was specified; xzdec does. + + src/xzdec/xzdec.c | 18 ++++++++++++++---- + 1 file changed, 14 insertions(+), 4 deletions(-) + +commit 278563ef8f2b8d98d7f2c85e1a64ec1bc21d26d8 +Author: Lasse Collin +Date: 2024-04-30 22:22:45 +0300 + + liblzma: Fix incorrect function type error from sanitizer + + Clang 17 with -fsanitize=address,undefined: + + src/liblzma/common/filter_common.c:366:8: runtime error: + call to function encoder_find through pointer to incorrect + function type 'const lzma_filter_coder *(*)(unsigned long)' + src/liblzma/common/filter_encoder.c:187: note: + encoder_find defined here + + Use a wrapper function to get the correct type neatly. + This reduces the number of casts needed too. + + This issue could be a problem with control flow integrity (CFI) + methods that check the function type on indirect function calls. + + Fixes: 3b34851de1eaf358cf9268922fa0eeed8278d680 + + src/liblzma/common/filter_decoder.c | 15 ++++++++++++--- + src/liblzma/common/filter_encoder.c | 17 +++++++++++++---- + 2 files changed, 25 insertions(+), 7 deletions(-) + +commit 77c8f60547decefca8f2d0c905d9c708c38ee8ff +Author: Lasse Collin +Date: 2024-04-30 21:41:11 +0300 + + xz: Avoid arithmetic on a null pointer + + It's undefined behavior. The result wasn't ever used as it occurred + in the last iteration of a loop. + + Clang 17 with -fsanitize=address,undefined: + + $ src/xz/xz --block-list=123 + src/xz/args.c:164:12: runtime error: applying non-zero offset 1 + to null pointer + + Fixes: 88ccf47205d7f3aa314d358c72ef214f10f68b43 + Co-authored-by: Sam James + + src/xz/args.c | 8 +++++++- + 1 file changed, 7 insertions(+), 1 deletion(-) + +commit 64503cc2b76a388ced4ec5f68234a07f0dcddcd5 +Author: Lasse Collin +Date: 2024-04-27 20:42:00 +0300 + + CMake: Support building liblzma API docs using Doxygen + + This is disabled by default to match the default in Autotools. + Use -DUSE_DOXYGEN=ON to enable Doxygen usage. + + This uses the update-doxygen script, thus this is under if(UNIX) + although Doxygen itself can run on Windows too. + + CMakeLists.txt | 40 +++++++++++++++++++++++++++++++--------- + 1 file changed, 31 insertions(+), 9 deletions(-) + +commit 0a7f5a80d8532a1d8cfa0a902c9d1ad7651eca37 +Author: Lasse Collin +Date: 2024-04-20 23:36:39 +0300 + + CMake: List API headers in LIBLZMA_API_HEADERS variable + + This way the same list will be usable in more than one location. + + CMakeLists.txt | 21 ++++++++++++--------- + 1 file changed, 12 insertions(+), 9 deletions(-) + +commit 541406bee3f09e9813103c6406b10fc6ab2e0d30 +Author: Lasse Collin +Date: 2024-04-19 15:16:42 +0300 + + PACKAGERS: Document the optional Doxygen usage + + Also add a note that packagers should check the licensing + of the Doxygen output. + + PACKAGERS | 19 ++++++++++--------- + 1 file changed, 10 insertions(+), 9 deletions(-) + +commit e21efdf96f39378fe417479f89e97046680406f5 +Author: Lasse Collin +Date: 2024-04-27 17:47:09 +0300 + + Build: Add --enable-doxygen to generate and install API docs + + It requires Doxygen. This option is disabled by default. + + INSTALL | 6 ++++++ + configure.ac | 10 +++++++++- + src/liblzma/api/Makefile.am | 19 +++++++++++++++++++ + 3 files changed, 34 insertions(+), 1 deletion(-) + +commit 0ece09a575d7e542bda8825808ddd6cf7de8cc4b +Author: Lasse Collin +Date: 2024-04-19 15:15:17 +0300 + + Doxygen: update-doxygen: Support out-of-tree builds + + Also, now $0 is used to refer to the script itself. + + doxygen/update-doxygen | 110 ++++++++++++++++++++++++++++++------------------- + 1 file changed, 68 insertions(+), 42 deletions(-) + +commit 2c519f641f266fd897edf680827d9c905f411440 +Author: Lasse Collin +Date: 2024-04-28 21:08:00 +0300 + + Doxygen: Simplify Doxyfile and add SPDX license identifier + + This omits all comments and a few non-default options that weren't + needed. Now it contains no copyrighted content from Doxygen itself. + + doxygen/Doxyfile | 2698 +----------------------------------------------------- + 1 file changed, 25 insertions(+), 2673 deletions(-) + +commit bdba39a57530d11b88440df8024002be3d09e4a1 +Author: Lasse Collin +Date: 2024-04-19 15:14:02 +0300 + + Doxygen: Don't strip JavaScript anymore + + The stripping method worked well with Doxygen 1.8 and 1.9 but + it doesn't work with Doxygen 1.10 anymore. Since we won't ship + pre-generated liblzma API docs anymore, the extra bloat and + extra license info of the JavaScript files won't affect the + upstream source package anymore. + + doxygen/update-doxygen | 21 --------------------- + 1 file changed, 21 deletions(-) + +commit d3a77ebc04bf1db8d52de2d9b0f07877bc4fd139 +Author: Lasse Collin +Date: 2024-04-19 17:26:41 +0300 + + Build: Remove old Doxygen rules from top-level Makefile.am + + Makefile.am | 12 ------------ + 1 file changed, 12 deletions(-) + +commit fd7faa4c338a42a6a40e854b837d285ae2e8c609 +Author: Lasse Collin +Date: 2024-04-19 15:10:06 +0300 + + Update COPYING to match the autogen.sh and mydist changes + + COPYING | 11 ----------- + 1 file changed, 11 deletions(-) + +commit b2bc55d8a0a9f2f59bfd4302067300e650f6baa3 +Author: Lasse Collin +Date: 2024-04-19 17:23:43 +0300 + + Build: Don't run update-doxygen as part of "make mydist" + + Makefile.am | 1 - + 1 file changed, 1 deletion(-) + +commit e9be74f5b129fe8a5388d588e68b1b7f5168a310 +Author: Lasse Collin +Date: 2024-04-19 15:09:48 +0300 + + autogen.sh: Don't generated Doxygen docs anymore + + autogen.sh | 18 +++--------------- + 1 file changed, 3 insertions(+), 15 deletions(-) + +commit 252aa1d67bc015eeba462803ab72edeb7744d864 +Author: Lasse Collin +Date: 2024-04-19 17:41:36 +0300 + + windows/build.bash: Omit Doxygen docs from the package + + They will be omitted from the source tarball and I don't want + to make Doxygen a dependency of build.bash. + + windows/build.bash | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +commit 634095364d87444d62d8ec54c134c0cd4705f5d7 +Author: Lasse Collin +Date: 2024-04-19 14:14:47 +0300 + + README: Don't mention PDF man pages anymore + + README | 6 +++--- + 1 file changed, 3 insertions(+), 3 deletions(-) + +commit dc684bf76ea23574ee9d88382057381e04e6089a +Author: Lasse Collin +Date: 2024-04-19 14:10:39 +0300 + + Build: Omit PDF man pages from the package + + pdf-local rule was added to create the PDFs still with "make pdf". + The install rules are missing but that likely doesn't matter at all. + + Makefile.am | 29 +++++++++++++++++++---------- + 1 file changed, 19 insertions(+), 10 deletions(-) + +commit e3531ab4125cbd5c01ebd3200791350960547189 +Author: Lasse Collin +Date: 2024-04-19 13:54:39 +0300 + + windows/build.bash: Don't copy PDF man pages to the package + + windows/README-Windows.txt | 2 +- + windows/build.bash | 2 +- + 2 files changed, 2 insertions(+), 2 deletions(-) + +commit 710a4573ef2cbd19c66318c3b2d1388e418e26c7 +Author: Lasse Collin +Date: 2024-04-28 01:34:50 +0300 + + Tests: test_index: Fix failures when features are disabled + + Fixes: cd88423e76d54eb72aea037364f3ebb21f122503 + + tests/test_index.c | 13 ++++++++----- + 1 file changed, 8 insertions(+), 5 deletions(-) + +commit aaff75c3486c4489ce88b0efb36b41cf138af7c3 +Author: Lasse Collin +Date: 2024-04-20 17:09:11 +0300 + + CMake: Keep the build working if the "tests" directory is missing + + This moves the tests section as is from CMakeLists.txt into + tests/tests.cmake. CMakeLists.txt now includes tests/tests.cmake + if the latter file exists. + + Now it's possible to delete the whole "tests" directory and + building with CMake will still work normally, just without + the tests. This way the tests are readily available for those + who want them, and those who won't run the tests anyway have + a straightforward way to ensure that nothing from the "tests" + directory can affect the build process. + + CMakeLists.txt | 76 ++--------------------------------------------- + tests/Makefile.am | 1 + + tests/tests.cmake | 88 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ + 3 files changed, 92 insertions(+), 73 deletions(-) + +commit a5f2aa5618fe9183706c9c514c3067985f6c338b +Author: Lasse Collin +Date: 2024-04-20 13:12:50 +0300 + + Tests: Remove x86 and SPARC BCJ tests + + These are very old but the exact test file isn't easy to reproduce + as it was compiled from a short C program (bcj_test.c) long ago. + These tests weren't very good anyway, just a little better than nothing. + + tests/Makefile.am | 7 ---- + tests/bcj_test.c | 64 --------------------------------- + tests/compress_prepared_bcj_sparc | Bin 1240 -> 0 bytes + tests/compress_prepared_bcj_x86 | Bin 1388 -> 0 bytes + tests/files/README | 8 ----- + tests/files/good-1-sparc-lzma2.xz | Bin 612 -> 0 bytes + tests/files/good-1-x86-lzma2.xz | Bin 716 -> 0 bytes + tests/test_compress_prepared_bcj_sparc | 4 --- + tests/test_compress_prepared_bcj_x86 | 4 --- + 9 files changed, 87 deletions(-) + +commit d879686469c9c4bf2a7c0bb6420ebe4530fc8f07 +Author: Lasse Collin +Date: 2024-04-27 18:30:40 +0300 + + Tests: test_index: Edit a misleading test + + tests/test_index.c | 7 +++++-- + 1 file changed, 5 insertions(+), 2 deletions(-) + +commit 612005bbdb0dea9dc09e9e2e9cc16a15c1480acd +Author: Lasse Collin +Date: 2024-04-27 16:46:01 +0300 + + Tests: test_index: Use minimal values to test integer overflow + + tests/test_index.c | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +commit 4ad88b2544c2aaf8de8f38af54587098cbe66c1d +Author: Lasse Collin +Date: 2024-04-27 15:13:39 +0300 + + Tests: test_index: Test lzma_index_buffer_decode() more + + tests/test_index.c | 29 ++++++++++++++++++++++++++--- + 1 file changed, 26 insertions(+), 3 deletions(-) + +commit 575b11b0d291e66c5fce31ce7a72f11436d57c83 +Author: Lasse Collin +Date: 2024-04-27 15:08:29 +0300 + + Tests: test_index: Test that *i = NULL is done on LZMA_PROG_ERROR + + On LZMA_DATA_ERROR from lzma_index_buffer_decode(), *i = NULL was + already done but this adds a test for that case too. + + tests/test_index.c | 31 +++++++++++++++++++++++++++---- + 1 file changed, 27 insertions(+), 4 deletions(-) + +commit 2c970debdb285823f01f75e875561d893345ac2b +Author: Lasse Collin +Date: 2024-04-27 15:01:25 +0300 + + Tests: test_index: Test lzma_index_buffer_encode() with empty output buf + + tests/test_index.c | 3 +++ + 1 file changed, 3 insertions(+) + +commit cd88423e76d54eb72aea037364f3ebb21f122503 +Author: Lasse Collin +Date: 2024-04-27 14:59:55 +0300 + + Tests: test_index: Replace if-statements with tuktest assertions + + tests/test_index.c | 22 +++++++++------------- + 1 file changed, 9 insertions(+), 13 deletions(-) + +commit 7f865577a6224fbbb5f5ca52574b62ea8ac9bf51 +Author: Lasse Collin +Date: 2024-04-27 14:56:16 +0300 + + Tests: test_index: Make it clear that my_alloc() has no integer overflows + + liblzma guarantees that the product of the allocation size arguments + will fit in size_t. + + Putting the pre-increment in the if-statement was clearly wrong + although in practice it didn't matter here as the function is + called only a couple of times. + + tests/test_index.c | 5 ++++- + 1 file changed, 4 insertions(+), 1 deletion(-) + +commit 12313a3b6596cdcf012e180597f84d231f8730d3 +Author: Lasse Collin +Date: 2024-04-27 14:51:52 +0300 + + Tests: test_index: Verify also iter.block.number_in_stream + + tests/test_index.c | 2 ++ + 1 file changed, 2 insertions(+) + +commit ad2654010d9d641ce1601beeff00630027e6bcd4 +Author: Lasse Collin +Date: 2024-04-27 14:51:06 +0300 + + Tests: test_index: Check cases that aren't a multiple of 4 bytes + + tests/test_index.c | 33 +++++++++++++++++++++++++-------- + 1 file changed, 25 insertions(+), 8 deletions(-) + +commit 2524fcf2b68b662035437cee8edbe80067c0c240 +Author: Lasse Collin +Date: 2024-04-27 14:40:25 +0300 + + Tests: test_index: Edit comments and white space + + tests/test_index.c | 18 +++++++++++------- + 1 file changed, 11 insertions(+), 7 deletions(-) + +commit 71eed2520e2eecae89bade9dceea16e56cfa2ea0 +Author: Lasse Collin +Date: 2024-04-27 14:33:38 +0300 + + liblzma: index_decoder: Fix missing initializations on LZMA_PROG_ERROR + + If the arguments to lzma_index_decoder() or lzma_index_buffer_decode() + were such that LZMA_PROG_ERROR was returned, the lzma_index **i + argument wasn't touched even though the API docs say that *i = NULL + is done if an error occurs. This obviously won't be done even now + if i == NULL but otherwise it is best to do it due to the wording + in the API docs. + + In practice this matters very little: The problem can occur only + if the functions are called with invalid arguments, that is, + the calling application must already have a bug. + + src/liblzma/common/index_decoder.c | 11 +++++++++++ + 1 file changed, 11 insertions(+) + +commit 0478473953f50716a2bc37b619b1c7dc2682b1ad +Author: Lasse Collin +Date: 2024-04-26 18:25:18 +0300 + + CMake: Bump maximum policy version to 3.29 + + CMakeLists.txt | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit a607e2b40d23f7d998dbaba76692aa30b4c3d9d3 +Author: Sam James +Date: 2024-04-13 22:30:44 +0100 + + ci: add NetBSD + + .github/workflows/netbsd.yml | 29 +++++++++++++++++++++++++++++ + 1 file changed, 29 insertions(+) + +commit 72c210336de26fb87a928160d025fa10a638d23b +Author: Sam James +Date: 2024-04-13 23:49:26 +0100 + + ci: add FreeBSD + + .github/workflows/freebsd.yml | 29 +++++++++++++++++++++++++++++ + 1 file changed, 29 insertions(+) + +commit b526ec2dbfb5889845ea60548c4f5b1f97d84ab2 +Author: Sam James +Date: 2024-04-13 23:16:08 +0100 + + ci: add OpenBSD + + .github/workflows/openbsd.yml | 31 +++++++++++++++++++++++++++++++ + 1 file changed, 31 insertions(+) + +commit c7ef767c49351743d8d011574abb9e200bf6b24f +Author: Sam James +Date: 2024-04-15 05:53:01 +0100 + + liblzma: outqueue: add header guard + + Reported by github's codeql. + + src/liblzma/common/outqueue.h | 5 +++++ + 1 file changed, 5 insertions(+) + +commit 55dcae3056d95cb2ddb8b560c12ba7596bc79f2c +Author: Sam James +Date: 2024-04-15 05:53:56 +0100 + + liblzma: easy_preset: add header guard + + Reported by github's codeql. + + src/liblzma/common/easy_preset.h | 5 +++++ + 1 file changed, 5 insertions(+) + +commit 4ffc60f32397371769b7d6b5e3ed8626292d58df +Author: Lasse Collin +Date: 2024-04-25 14:00:57 +0300 + + tuklib_integer: Rename bswapXX to byteswapXX + + The __builtin_bswapXX from GCC and Clang are preferred when + they are available. This can allow compilers to emit the x86 MOVBE + instruction instead of doing a load + byteswap as two instructions + (which would happen if the byteswapping is done in inline asm). + + bswap16, bswap32, and bswap64 exist in system headers on *BSDs + and Darwin. #defining bswap16 on NetBSD results in a warning about + macro redefinition. It's safest to avoid this namespace conflict + completely. + + No OS supported by tuklib_integer.h uses byteswapXX names and + a web search doesn't immediately find any obvious danger of + namespace conflicts. So let's try these still-pretty-short names + for the macros. + + Thanks to Sam James for pointing out the compiler warning on + NetBSD 10.0. + + src/common/tuklib_integer.h | 47 ++++++++++++++++++++------------------ + src/liblzma/check/crc32_fast.c | 4 ++-- + src/liblzma/check/crc32_tablegen.c | 2 +- + src/liblzma/check/crc64_fast.c | 4 ++-- + src/liblzma/check/crc64_tablegen.c | 2 +- + 5 files changed, 31 insertions(+), 28 deletions(-) + +commit 08ab0966a75b501aa7c717622223f0c13a113c75 +Author: Lasse Collin +Date: 2024-04-24 01:20:26 +0300 + + liblzma: API doc cleanups + + src/liblzma/api/lzma/container.h | 2 +- + src/liblzma/api/lzma/index.h | 6 +++--- + src/liblzma/api/lzma/vli.h | 5 ++--- + 3 files changed, 6 insertions(+), 7 deletions(-) + +commit 3ac8a9bb4cccbee88350696dc9c645c48d77c989 +Author: Lasse Collin +Date: 2024-04-23 16:35:33 +0300 + + Tests: test_filter_str: Add a few assertions + + tests/test_filter_str.c | 4 ++++ + 1 file changed, 4 insertions(+) + +commit 26c69be80523b05c84dea86c47c4ddd9a10945d7 +Author: Lasse Collin +Date: 2024-04-23 16:35:08 +0300 + + Tests: test_filter_str: Move one assertion and add a comment + + tests/test_filter_str.c | 6 ++++-- + 1 file changed, 4 insertions(+), 2 deletions(-) + +commit 4f6af853bc99904efb8b6c28a0af7b81a8476c1b +Author: Lasse Collin +Date: 2024-04-23 16:26:06 +0300 + + Tests: test_filter_str: Tweak comments and white space + + tests/test_filter_str.c | 3 +++ + 1 file changed, 3 insertions(+) + +commit c92663aa1bd576e0615498a4189acf0df12e84b9 +Author: Lasse Collin +Date: 2024-04-23 16:25:22 +0300 + + Tests: test_filter_str: Add missing RISC-V case + + Fixes: 89ea1a22f4ed3685b053b7260bc5acf6c75d1664 + + tests/test_filter_str.c | 3 +++ + 1 file changed, 3 insertions(+) + +commit b0366df1d7ed26268101f9303a001c91c0806dfc +Author: Lasse Collin +Date: 2024-04-22 22:23:32 +0300 + + Tests: test_filter_str: Test *error_pos more thoroughly + + tests/test_filter_str.c | 77 ++++++++++++++++++++++++++++++++++++++++++++++++- + 1 file changed, 76 insertions(+), 1 deletion(-) + +commit 70d12dd069bb9bb0d6bb1c8fafc4e6f77780263d +Author: Lasse Collin +Date: 2024-04-22 21:54:39 +0300 + + liblzma: lzma_str_to_filters: Set *error_pos on all errors + + The API docs clearly say that if error_pos isn't NULL then *error + is always set on any error. However, it wasn't touched if str == NULL + or filters == NULL or unsupported flags were specified. + + Fixes: cedeeca2ea6ada5b0411b2ae10d7a859e837f203 + + src/liblzma/common/string_conversion.c | 6 ++++++ + 1 file changed, 6 insertions(+) + +commit ed8e552395701fbf046027cebc8be4a6755b263f +Author: Lasse Collin +Date: 2024-04-22 20:31:25 +0300 + + liblzma: Clean up white space + + src/liblzma/lz/lz_encoder.h | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit 2f06920f20b1ad63b7953dc09569e1d424998849 +Author: Lasse Collin +Date: 2024-04-22 18:35:19 +0300 + + Tests: test_filter_flags: Edit comments and style + + tests/test_filter_flags.c | 13 +++++++++---- + 1 file changed, 9 insertions(+), 4 deletions(-) + +commit b101e1d1dbc81577c0c9aa0cb89cf2e46a15eb82 +Author: Lasse Collin +Date: 2024-04-22 16:39:44 +0300 + + Tests: Fix C99/C11 compatibility when features are disabled + + The array could become empty and then the initializer would be + simply {} which is allowed only in GNU-C and C23. + + tests/test_filter_flags.c | 18 ++++++++---------- + 1 file changed, 8 insertions(+), 10 deletions(-) + +commit f8f3a220ac8afcb8cb2812917d3b77e00c2eab0d +Author: Lasse Collin +Date: 2024-04-21 20:32:16 +0300 + + DOS: Omit useless defines from config.h + + dos/config.h | 12 ------------ + 1 file changed, 12 deletions(-) + +commit fc1921b04b8840caaa777c2bd5340d41b259da20 +Author: Lasse Collin +Date: 2024-04-21 20:27:50 +0300 + + Build: Omit useless checks for fcntl.h, limits.h, and sys/time.h + + configure.ac | 6 ------ + 1 file changed, 6 deletions(-) + +commit 6aa2a6deeba04808a0fe4461396e7fb70277f3d4 +Author: Lasse Collin +Date: 2024-04-19 22:04:21 +0300 + + liblzma: Silence a warning from Coverity static analysis + + It is logical why it cannot know for sure that the value has + to be at most 4 if it is less than 16. + + The x86 filter is based on a very old LZMA SDK version. Newer + ones have quite a different implementation for the same filter. + + Thanks to Sam James. + + src/liblzma/simple/x86.c | 12 +++++------- + 1 file changed, 5 insertions(+), 7 deletions(-) + +commit e89d3e83b4496d0b5410870634970c0aa9721d59 +Author: Lasse Collin +Date: 2024-04-19 23:18:19 +0300 + + Update .gitignore + + .gitignore | 21 ++++++++------------- + 1 file changed, 8 insertions(+), 13 deletions(-) + +commit 86fc4ee859709da0ff9617a1490f13ddac0a109b +Author: Lasse Collin +Date: 2024-04-19 20:53:24 +0300 + + Tests: test_lzip_decoder: Tweak coding style and comments + + tests/test_lzip_decoder.c | 58 +++++++++++++++++++++++------------------------ + 1 file changed, 28 insertions(+), 30 deletions(-) + +commit 38be573a279bd7b608ee7d8509ec10884e6fb0d5 +Author: Lasse Collin +Date: 2024-04-19 20:51:36 +0300 + + Tests: test_lzip_decoder: Remove redundant initializations + + tests/test_lzip_decoder.c | 6 ++---- + 1 file changed, 2 insertions(+), 4 deletions(-) + +commit d7e4bc53eacfab9f3de95d8252bdfdc9419079c9 +Author: Lasse Collin +Date: 2024-04-19 20:47:24 +0300 + + Tests: test_lzip_decoder: Remove unneeded tuktest_malloc() calls + + tests/test_lzip_decoder.c | 12 ++---------- + 1 file changed, 2 insertions(+), 10 deletions(-) + +commit eeca8f7c5baf1ad69606bb734d5001763466d58f +Author: Lasse Collin +Date: 2024-04-15 20:35:07 +0300 + + xz: Fix white space error. + + Thanks to xx on #tukaani. + + src/xz/args.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit 462ca9409940a19f743daee6b3bcc611277d0007 +Author: Sam James +Date: 2024-04-11 23:01:44 +0100 + + xz: add missing noreturn for message_filters_help + + Fixes: a165d7df1964121eb9df715e6f836a31c865beef + + src/xz/message.h | 1 + + 1 file changed, 1 insertion(+) + +commit 863f13d2828b99b0539ce73f9cf85bde32358034 +Author: Sam James +Date: 2024-04-11 19:34:04 +0100 + + xz: signals: suppress -Wsign-conversion on macOS + + On macOS, we get: + ``` + signals.c: In function 'signals_init': + signals.c:76:17: error: conversion to 'sigset_t' {aka 'unsigned int'} from 'int' may change the sign of the result [-Werror=sign-conversion] + 76 | sigaddset(&hooked_signals, sigs[i]); + | ^~~~~~~~~ + signals.c:81:17: error: conversion to 'sigset_t' {aka 'unsigned int'} from 'int' may change the sign of the result [-Werror=sign-conversion] + 81 | sigaddset(&hooked_signals, message_progress_sigs[i]); + | ^~~~~~~~~ + signals.c:86:9: error: conversion to 'sigset_t' {aka 'unsigned int'} from 'int' may change the sign of the result [-Werror=sign-conversion] + 86 | sigaddset(&hooked_signals, SIGTSTP); + | ^~~~~~~~~ + ``` + + We use `int` for `hooked_signals` but we can't just cast to whatever + `sigset_t` is because `sigset_t` is an opaque type. It's an unsigned int + on macOS. On macOS, `sigaddset` is implemented as a macro. + + Just suppress -Wsign-conversion for `signals_init` for macOS given + there's no real nice way of fixing this. + + src/xz/signals.c | 7 +++++++ + 1 file changed, 7 insertions(+) + +commit fcbd0d199933a69713cb293cbd7409a757d854cd +Author: Lasse Collin +Date: 2024-04-13 22:19:40 +0300 + + Tests: test_microlzma: Add a "FIXME?" about LZMA_FINISH handling + + tests/test_microlzma.c | 8 ++++++++ + 1 file changed, 8 insertions(+) + +commit 0fe2dfa68355d2b165544b2bc8babf77dcc2039e +Author: Lasse Collin +Date: 2024-04-13 18:05:31 +0300 + + Tests: test_microlzma: Tweak comments, coding style, and minor details + + A few lines were reordered, a few ARRAY_SIZE were changed to sizeof, + and a few uint32_t were changed to size_t. No real functional changes + were intended. + + tests/test_microlzma.c | 149 +++++++++++++++++++++++++++---------------------- + 1 file changed, 83 insertions(+), 66 deletions(-) + +commit 97f0ee0f1f903f4e7c4ea23e9b89d687025d2992 +Author: Ryan Carsten Schmidt +Date: 2024-04-12 19:31:13 -0500 + + CI: Use only the active CPUs on macOS + + hw.ncpu counts all CPUs including inactive ones. hw.activecpu counts + only the active CPUs. + + build-aux/ci_build.bash | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit 73f629e321b74f68c9954728fa4f19261afccf46 +Author: Sam James +Date: 2024-04-10 18:33:55 +0100 + + ci: rename ci_build.sh -> ci_build.bash + + We discussed the name and it's less cognitive load to just call it '.bash' + so you don't have an immediate question about if bashisms are OK. + + .github/workflows/ci.yml | 52 ++++++++++++++++---------------- + .github/workflows/windows-ci.yml | 20 ++++++------ + build-aux/{ci_build.sh => ci_build.bash} | 0 + 3 files changed, 36 insertions(+), 36 deletions(-) + +commit 8709407a9ef8e7e8aec117879400e4dd3e227ada +Author: Sam James +Date: 2024-04-10 17:42:23 +0100 + + ci: build in parallel by default + + build-aux/ci_build.sh | 2 ++ + 1 file changed, 2 insertions(+) + +commit 65bf7e0a1ca6386f17608e8afb84ac470c18d23f +Author: Sam James +Date: 2024-04-10 15:41:08 +0100 + + ci: default to -O2 + + We need this for when we're passing sanitizer flags or -gdwarf-4 for Clang + with Valgrind. Just always start with -O2 if CFLAGS isn't set in the + environment and append what was passed on the command line. + + build-aux/ci_build.sh | 3 ++- + 1 file changed, 2 insertions(+), 1 deletion(-) + +commit bc899f9e0700ad153bd65f4804c4de7515c8a847 +Author: Sam James +Date: 2024-04-10 15:17:47 +0100 + + ci: make automake's test runner verbose on failures + + This is a lot easier to work with than the save-logs thing the action + tries to do... + + build-aux/ci_build.sh | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit b5e3470442531717b2457b40ab412740296af1bc +Author: Sam James +Date: 2024-04-10 12:38:51 +0100 + + ci: make UBSAN abort on errors + + Unfortunately, UBSAN doesn't do this by default. See also the change + I made in Meson for this in October [0]. + + [0] https://github.com/mesonbuild/meson/commit/7b7d2e060b447de9c2642848847370a58711ac1c + + .github/workflows/ci.yml | 1 + + 1 file changed, 1 insertion(+) + +commit 6c095a98fbec70b790253a663173ecdb669108c4 +Author: Sam James +Date: 2024-04-10 11:43:10 +0100 + + ci: test Valgrind + + Using `--trace-children=yes` has a trade-off here, as it makes + `test_scripts.sh` pretty slow when calling various non-xz utilities. + + But I also feel like it's not useless to have Valgrind used there and it's + not easy to exclude Valgrind just for that one test... + + I did consider using AX_VALGRIND_CHECK [0][1] but I couldn't get it working + immediately with some conditionally-built tests and I wondered if it was + worth spending time on at least while we're debating xz's future build + system situation. + + [0] https://www.gnu.org/software/autoconf-archive/ax_valgrind_check.html + [1] https://tecnocode.co.uk/2014/12/23/automatically-valgrinding-code-with-ax_valgrind_check/ + + .github/workflows/ci.yml | 11 ++++++++++- + build-aux/ci_build.sh | 8 +++++--- + 2 files changed, 15 insertions(+), 4 deletions(-) + +commit 6286c1900c2d2ca33d9b1b397122c7bcdb9a4d59 +Author: Lasse Collin +Date: 2024-04-10 23:20:02 +0300 + + liblzma: CRC: Simplify table omission macros + + A macro is useful to prevent a single #if directive from + getting too ugly but only one macro is needed for all archs. + + src/liblzma/check/crc32_table.c | 10 ++++------ + src/liblzma/check/crc64_table.c | 4 ++-- + src/liblzma/check/crc_common.h | 5 +++-- + 3 files changed, 9 insertions(+), 10 deletions(-) + +commit 45da936c879acf4f053a3055665bf1b10ded4462 +Author: Lasse Collin +Date: 2024-04-10 23:09:40 +0300 + + liblzma: ARM64 CRC: Fix omission of CRC32 table + + The macro name had an odd typo so the table wasn't omitted + when it should have. + + Fixes: 1940f0ec28f08c0ac72c1413d9706fb82eabe6ad + + src/liblzma/check/crc32_table.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit 308a9af85400b0e2019f0f012c8354e831d06d65 +Author: Lasse Collin +Date: 2024-04-10 22:21:51 +0300 + + Build: If ARM64 feature detection func is found, stop looking for others + + This can speed up configure a tiny bit. + + Fixes: c5f6d79cc9515a7f22d7ea4860c6cc394b295732 + + configure.ac | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit fc43cecd32bf9d5f8caa599206b15c9569af1eb6 +Author: Lasse Collin +Date: 2024-04-10 22:04:27 +0300 + + liblzma: ARM64 CRC32: Change style of the macOS code to match FreeBSD + + I didn't test this but it shouldn't change any functionality. + + Fixes: 761f5b69a4c778c8bcb09279b845b07c28790575 + + src/liblzma/check/crc32_arm64.h | 7 ++++--- + 1 file changed, 4 insertions(+), 3 deletions(-) + +commit 1024cd4cd966b998fedec51e385e9ee9a49b3c57 +Author: Lasse Collin +Date: 2024-04-10 21:59:27 +0300 + + liblzma: ARM64 CRC32: Add error checking to FreeBSD-specific code + + Also add parenthesis to the return statement. + + I didn't test this. + + Fixes: 761f5b69a4c778c8bcb09279b845b07c28790575 + + src/liblzma/check/crc32_arm64.h | 6 ++++-- + 1 file changed, 4 insertions(+), 2 deletions(-) + +commit 2337f7021c860b026e3e849e60a9ae8d09ec0ea0 +Author: Lasse Collin +Date: 2024-04-10 21:56:33 +0300 + + liblzma: ARM64 CRC32: Use negation instead of subtracting from 8 + + Subtracting from 0 is negation, this just keeps warnings away. + + Fixes: 761f5b69a4c778c8bcb09279b845b07c28790575 + + src/liblzma/check/crc32_arm64.h | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit d8fffd01aa1a3c18e437a222abd34699e23ff5e7 +Author: Lasse Collin +Date: 2024-04-10 21:55:10 +0300 + + liblzma: ARM64 CRC32: Tweak coding style and comments + + src/liblzma/check/crc32_arm64.h | 10 +++++----- + 1 file changed, 5 insertions(+), 5 deletions(-) + +commit 780d2c236de0e4749655696c2e0c26fb7565afd3 +Author: Lasse Collin +Date: 2024-04-09 21:55:01 +0300 + + Update SECURITY.md. + + .github/SECURITY.md | 25 ++++++++----------------- + 1 file changed, 8 insertions(+), 17 deletions(-) + +commit 986865ea2f9d1f8dbef4a130926df106b0f6d41a +Author: Lasse Collin +Date: 2024-04-09 17:47:01 +0300 + + CI: Remove ifunc support. + + .github/workflows/ci.yml | 13 +++---------- + build-aux/ci_build.sh | 5 +---- + 2 files changed, 4 insertions(+), 14 deletions(-) + +commit 689ae2427342a2ea1206eb5ca08301baf410e7e0 +Author: Lasse Collin +Date: 2024-04-09 17:43:16 +0300 + + liblzma: Remove ifunc support. + + This is *NOT* done for security reasons even though the backdoor + relied on the ifunc code. Instead, the reason is that in this + project ifunc provides little benefits but it's quite a bit of + extra code to support it. The only case where ifunc *might* matter + for performance is if the CRC functions are used directly by an + application. In normal compression use it's completely irrelevant. + + CMakeLists.txt | 79 --------------------------------------- + INSTALL | 8 ---- + configure.ac | 79 --------------------------------------- + src/liblzma/check/crc32_fast.c | 48 +++--------------------- + src/liblzma/check/crc64_fast.c | 21 ----------- + src/liblzma/check/crc_common.h | 9 +---- + src/liblzma/check/crc_x86_clmul.h | 11 +----- + 7 files changed, 8 insertions(+), 247 deletions(-) + +commit 6b4c859059a7eb9b0547590c081668e14ecf8af6 +Author: Lasse Collin +Date: 2024-04-08 22:04:41 +0300 + + tests/files/README: Update the main heading. + + tests/files/README | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +commit 2a851e06b891ce894f918faff32a6cca6fdecee6 +Author: Lasse Collin +Date: 2024-04-08 22:02:45 +0300 + + tests/files/README: Explain how to recreate the ARM64 test files. + + tests/files/README | 15 ++++++++++++++- + 1 file changed, 14 insertions(+), 1 deletion(-) + +commit 3d09b721b94e18fe1f853a04799697f5de10b291 +Author: Lasse Collin +Date: 2024-04-08 21:51:55 +0300 + + debug: Add generator for the ARM64 test file data. + + debug/Makefile.am | 3 +- + debug/testfilegen-arm64.c | 116 ++++++++++++++++++++++++++++++++++++++++++++++ + 2 files changed, 118 insertions(+), 1 deletion(-) + +commit 31ef676567c9d6fcc4ec9fc833c312f7a7c21c48 +Author: Lasse Collin +Date: 2024-04-08 21:19:38 +0300 + + xz man page: Use .ft CR instead of CW to silence warnings from groff. + + src/xz/xz.1 | 32 ++++++++++++++++---------------- + 1 file changed, 16 insertions(+), 16 deletions(-) + +commit 780cbf29d5a88db2b546e9b7b019c4c33ca72685 +Author: Lasse Collin +Date: 2024-04-08 19:28:35 +0300 + + Fix NEWS for 5.6.0 and 5.6.1. + + NEWS | 6 ++++++ + 1 file changed, 6 insertions(+) + +commit bfd0c7c478e93a1911b845459549ff94587b6ea2 +Author: Lasse Collin +Date: 2024-04-08 19:22:26 +0300 + + Remove the XZ logo. + + COPYING | 5 - + COPYING.CC-BY-SA-4.0 | 427 --------------------------------------------------- + Makefile.am | 2 - + README | 2 - + doc/xz-logo.png | Bin 6771 -> 0 bytes + doxygen/Doxyfile | 6 +- + doxygen/footer.html | 13 -- + 7 files changed, 3 insertions(+), 452 deletions(-) + +commit 77a294d98a9d2d48f7e4ac273711518bf689f5c4 +Author: Lasse Collin +Date: 2024-04-08 18:27:39 +0300 + + Update maintainer and author info. + + The other maintainer suddenly disappeared. + + AUTHORS | 9 +++++++-- + README | 10 +++------- + THANKS | 1 - + src/liblzma/api/lzma.h | 2 +- + 4 files changed, 11 insertions(+), 11 deletions(-) + +commit 8dd03d4484ccf80022722a16d0ed9b37f2b58072 +Author: Lasse Collin +Date: 2024-04-08 18:05:32 +0300 + + Docs: Update .xz file format specification to 1.2.1. + + This only reverts the XZ URL changes. + + doc/xz-file-format.txt | 12 ++++++++---- + 1 file changed, 8 insertions(+), 4 deletions(-) + +commit 17aa2e1a796d3f758802df29afc89dcf335db567 +Author: Lasse Collin +Date: 2024-04-08 17:33:56 +0300 + + Update website URLs back to tukaani.org. + + The XZ projects were moved back to their original URLs. + + .github/SECURITY.md | 2 +- + CMakeLists.txt | 2 +- + COPYING | 3 +-- + README | 4 ++-- + configure.ac | 2 +- + doc/faq.txt | 2 +- + doc/lzma-file-format.txt | 12 ++++++------ + dos/config.h | 2 +- + src/liblzma/api/lzma.h | 2 +- + src/xz/xz.1 | 6 +++--- + src/xzdec/xzdec.1 | 4 ++-- + windows/README-Windows.txt | 2 +- + 12 files changed, 21 insertions(+), 22 deletions(-) + +commit 2739db981023373a2ddabc7b456c7e658bb4f582 +Author: Lasse Collin +Date: 2024-04-08 17:07:08 +0300 + + xzdec: Tweak coding style and comments. + + src/xzdec/xzdec.c | 32 +++++++++++++++++++++----------- + 1 file changed, 21 insertions(+), 11 deletions(-) + +commit 408b6adb2a07d07c6535f859571cca38837caaf3 +Author: Lasse Collin +Date: 2024-04-08 15:53:46 +0300 + + tests/ossfuzz: Tiny fix to a comment. + + tests/ossfuzz/fuzz_decode_stream.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit db4dd74a344580e0b81436598d9741a3454245b0 +Author: Lasse Collin +Date: 2024-04-09 18:22:16 +0300 + + Update THANKS. + + THANKS | 1 + + 1 file changed, 1 insertion(+) + +commit e93e13c8b3bec925c56e0c0b675d8000a0f7f754 +Author: Lasse Collin +Date: 2024-04-08 15:32:58 +0300 + + Remove the backdoor found in 5.6.0 and 5.6.1 (CVE-2024-3094). + + While the backdoor was inactive (and thus harmless) without inserting + a small trigger code into the build system when the source package was + created, it's good to remove this anyway: + + - The executable payloads were embedded as binary blobs in + the test files. This was a blatant violation of the + Debian Free Software Guidelines. + + - On machines that see lots bots poking at the SSH port, the backdoor + noticeably increased CPU load, resulting in degraded user experience + and thus overwhelmingly negative user feedback. + + - The maintainer who added the backdoor has disappeared. + + - Backdoors are bad for security. + + This reverts the following without making any other changes: + + 6e636819 Tests: Update two test files. + a3a29bbd Tests: Test --single-stream can decompress bad-3-corrupt_lzma2.xz. + 0b4ccc91 Tests: Update RISC-V test files. + 8c9b8b20 liblzma: Fix typos in crc32_fast.c and crc64_fast.c. + 82ecc538 liblzma: Fix false Valgrind error report with GCC. + cf44e4b7 Tests: Add a few test files. + 3060e107 Tests: Use smaller dictionary size in RISC-V test files. + e2870db5 Tests: Add two RISC-V Filter test files. + + The RISC-V test files also have real content that tests the filter + but the real content would fit into much smaller files. A generator + program would need to be available as well. + + Thanks to Andres Freund for finding and reporting it and making + it public quickly so others could act without a delay. + See: https://www.openwall.com/lists/oss-security/2024/03/29/4 + + src/liblzma/check/crc32_fast.c | 7 +++++-- + src/liblzma/check/crc64_fast.c | 4 +++- + src/liblzma/check/crc_common.h | 25 ------------------------- + tests/files/README | 27 --------------------------- + tests/files/bad-3-corrupt_lzma2.xz | Bin 512 -> 0 bytes + tests/files/bad-dict_size.lzma | Bin 41 -> 0 bytes + tests/files/good-1-riscv-lzma2-1.xz | Bin 7424 -> 0 bytes + tests/files/good-1-riscv-lzma2-2.xz | Bin 7432 -> 0 bytes + tests/files/good-2cat.xz | Bin 136 -> 0 bytes + tests/files/good-large_compressed.lzma | Bin 35421 -> 0 bytes + tests/files/good-small_compressed.lzma | Bin 258 -> 0 bytes + tests/test_files.sh | 11 ----------- + 12 files changed, 8 insertions(+), 66 deletions(-) + +commit f9cf4c05edd14dedfe63833f8ccbe41b55823b00 +Author: Lasse Collin +Date: 2024-03-30 14:36:28 +0200 + + CMake: Fix sabotaged Landlock sandbox check. + + It never enabled it. + + CMakeLists.txt | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit af071ef7702debef4f1d324616a0137a5001c14c +Author: Jia Tan +Date: 2024-03-26 01:50:02 +0800 + + Docs: Simplify SECURITY.md. + + .github/SECURITY.md | 8 +------- + 1 file changed, 1 insertion(+), 7 deletions(-) + +commit 0b99783d63f27606936bb79a16c52d0d70c0b56f +Author: Lasse Collin +Date: 2024-03-22 17:46:30 +0200 + + liblzma: memcmplen.h: Add a comment why subtraction is used. + + src/liblzma/common/memcmplen.h | 13 +++++++++++++ + 1 file changed, 13 insertions(+) + +commit 8a25ba024d55610c448c6e4f1400a00bae51b493 +Author: Lasse Collin +Date: 2024-03-15 17:43:39 +0200 + + INSTALL: Document arguments of --enable-symbol-versions. + + INSTALL | 43 +++++++++++++++++++++++++++++++++++++++---- + 1 file changed, 39 insertions(+), 4 deletions(-) + +commit 49324b711f9d42b3543bf2f3ae598eaa03360bd5 +Author: Lasse Collin +Date: 2024-03-15 17:15:50 +0200 + + Build: Use only the generic symbol versioning with NVIDIA HPC Compiler. + + This does the previous commit with CMake. + + AC_EGREP_CPP uses AC_REQUIRE so the outermost if-commands must + be changed to AS_IF to ensure that things wont break some day. + See 5a5bd7f871818029d5ccbe189f087f591258c294. + + configure.ac | 18 +++++++++++++----- + 1 file changed, 13 insertions(+), 5 deletions(-) + +commit c273123ed0ebaebf49994057a7fe98aae7f42c40 +Author: Lasse Collin +Date: 2024-03-15 16:36:35 +0200 + + CMake: Use only the generic symbol versioning with NVIDIA HPC Compiler. + + It doesn't support the __symver__ attribute or __asm__(".symver ..."). + The generic symbol versioning can still be used since it only needs + linker support. + + CMakeLists.txt | 7 ++++++- + 1 file changed, 6 insertions(+), 1 deletion(-) + +commit df7f487648d18a3992386a59b8a061edca862d17 +Author: Lasse Collin +Date: 2024-03-13 21:38:24 +0200 + + Update THANKS. + + THANKS | 1 + + 1 file changed, 1 insertion(+) + +commit 3217b82b3ec023bf8338249134a076bea0ea30ec +Author: Lasse Collin +Date: 2024-03-13 21:30:18 +0200 + + liblzma: Minor comment edits. + + src/liblzma/common/string_conversion.c | 4 ++-- + src/liblzma/delta/delta_decoder.c | 2 ++ + 2 files changed, 4 insertions(+), 2 deletions(-) + +commit 096bc0e3f8fb4bfc4d2f3f64a7f219401ffb4c31 +Author: Sergey Kosukhin +Date: 2024-03-13 13:07:13 +0100 + + liblzma: Fix building with NVHPC (NVIDIA HPC SDK). + + NVHPC compiler has several issues that make it impossible to + build liblzma: + - the compiler cannot handle unions that contain pointers that + are not the first members; + - the compiler cannot handle the assembler code in range_decoder.h + (LZMA_RANGE_DECODER_CONFIG has to be set to zero); + - the compiler fails to produce valid code for delta_decode if the + vectorization is enabled, which results in failed tests. + + This introduces NVHPC-specific workarounds that address the issues. + + src/liblzma/common/string_conversion.c | 6 ++++-- + src/liblzma/delta/delta_decoder.c | 3 +++ + src/liblzma/rangecoder/range_decoder.h | 1 + + 3 files changed, 8 insertions(+), 2 deletions(-) + +commit 2ad7fad67080e88fa7fc191f9d613d8b7add9c62 +Author: Lasse Collin +Date: 2024-03-13 21:17:10 +0200 + + CMake: Disable symbol versioning on non-glibc Linux. + + This better matches what configure.ac does. For example, musl has + only basic symbol versioning support: + + https://wiki.musl-libc.org/functional-differences-from-glibc.html#Symbol_versioning + + configure.ac tries to enable symbol versioning only with glibc + so now CMake does the same. + + CMakeLists.txt | 22 ++++++++++++++++++++-- + 1 file changed, 20 insertions(+), 2 deletions(-) + +commit 82f0c0d39eb2c026b1d96ee706f70ace868d4ed4 +Author: Lasse Collin +Date: 2024-03-13 20:32:46 +0200 + + CMake: Make symbol versioning configurable. + + CMakeLists.txt | 62 +++++++++++++++++++++++++++++++++++++++------------------- + 1 file changed, 42 insertions(+), 20 deletions(-) + +commit 45d33bfc45e4295b8ad743bc2ae61cc724f98076 +Author: Lasse Collin +Date: 2024-03-13 19:47:36 +0200 + + Build: Style tweaks to configure.ac. + + The AC_MSG_ERROR line is overlong anyway as are a few other + AC_MSG_ERROR lines already. + + configure.ac | 16 +++++++++------- + 1 file changed, 9 insertions(+), 7 deletions(-) + +commit f56ed6fac6619b56b005878d3b5210e2f0d721c0 +Author: Sergey Kosukhin +Date: 2024-03-12 20:03:49 +0100 + + Build: Let the users override the symbol versioning variant. + + There are cases when the users want to decide themselves whether + they want to have the generic (even on GNU/Linux) or the linux + (even if we do not recommend that) symbol versioning variant. + The former might be needed to circumvent compiler issues (i.e. + the compiler does not support all features that are required + for the linux versioning), the latter might help in overriding + the assumptions made in the configure script. + + configure.ac | 91 +++++++++++++++++++++++++++++++++--------------------------- + 1 file changed, 50 insertions(+), 41 deletions(-) + +commit a4f2e20d8466369b1bb277c66f75c9e4ba9cc378 +Author: Jia Tan +Date: 2024-03-09 11:27:27 +0800 + + Add NEWS for 5.6.1 + + NEWS | 26 ++++++++++++++++++++++++++ + 1 file changed, 26 insertions(+) + +commit f01be8ad754a905d8c418601767480ec11621b02 +Author: Jia Tan +Date: 2024-03-09 10:43:20 +0800 + + Translations: Add missing --riscv option to man page translations. + + po4a/de.po | 702 +++++++++++++++++++++++++++++----------------------------- + po4a/fr.po | 549 ++++++++++++++++++++++----------------------- + po4a/ko.po | 702 +++++++++++++++++++++++++++++----------------------------- + po4a/pt_BR.po | 641 +++++++++++++++++++++++++++-------------------------- + po4a/ro.po | 702 +++++++++++++++++++++++++++++----------------------------- + po4a/uk.po | 702 +++++++++++++++++++++++++++++----------------------------- + 6 files changed, 2024 insertions(+), 1974 deletions(-) + +commit 6e636819e8f070330d835fce46289a3ff72a7b89 +Author: Jia Tan +Date: 2024-03-09 10:18:29 +0800 + + Tests: Update two test files. + + The original files were generated with random local to my machine. + To better reproduce these files in the future, a constant seed was used + to recreate these files. + + tests/files/bad-3-corrupt_lzma2.xz | Bin 484 -> 512 bytes + tests/files/good-large_compressed.lzma | Bin 35430 -> 35421 bytes + 2 files changed, 0 insertions(+), 0 deletions(-) + +commit a3a29bbd5d86183fc7eae8f0182dace374e778d8 +Author: Jia Tan +Date: 2024-03-09 10:08:32 +0800 + + Tests: Test --single-stream can decompress bad-3-corrupt_lzma2.xz. + + The first stream in this file is valid, so this tests that xz properly + stops after decompressing it. + + tests/test_files.sh | 11 +++++++++++ + 1 file changed, 11 insertions(+) + +commit 0b4ccc91454dbcf0bf521b9bd51aa270581ee23c +Author: Jia Tan +Date: 2024-03-09 10:05:32 +0800 + + Tests: Update RISC-V test files. + + This increases code coverage and tests for possible shifting bugs. + + tests/files/good-1-riscv-lzma2-1.xz | Bin 7512 -> 7424 bytes + tests/files/good-1-riscv-lzma2-2.xz | Bin 7512 -> 7432 bytes + 2 files changed, 0 insertions(+), 0 deletions(-) + +commit 8c9b8b2063daa78ead9f648c2ec3c91e8615dffb +Author: Jia Tan +Date: 2024-03-09 09:52:32 +0800 + + liblzma: Fix typos in crc32_fast.c and crc64_fast.c. + + src/liblzma/check/crc32_fast.c | 4 ++-- + src/liblzma/check/crc64_fast.c | 3 +-- + 2 files changed, 3 insertions(+), 4 deletions(-) + +commit b93a8d7631d9517da63f03e0185455024a4609e8 +Author: Jia Tan +Date: 2024-03-09 09:49:55 +0800 + + Tests: Replace HAVE_MICROLZMA usage in CMake and Autotools builds. + + This reverts commit adaacafde6661496ca2814b1e94a3ba5186428cb. + + CMakeLists.txt | 15 ++++++++++----- + configure.ac | 9 ++------- + tests/Makefile.am | 9 ++++++--- + tests/test_microlzma.c | 12 ++++-------- + 4 files changed, 22 insertions(+), 23 deletions(-) + +commit 82ecc538193b380a21622aea02b0ba078e7ade92 +Author: Jia Tan +Date: 2024-03-09 09:20:57 +0800 + + liblzma: Fix false Valgrind error report with GCC. + + With GCC and a certain combination of flags, Valgrind will falsely + trigger an invalid write. This appears to be due to the omission of + instructions to properly save, set up, and restore the frame pointer. + + The IFUNC resolver is a leaf function since it only calls a function + that is inlined. So sometimes GCC omits the frame pointer instructions + in the resolver unless this optimization is explictly disabled. + + This fixes https://bugzilla.redhat.com/show_bug.cgi?id=2267598. + + src/liblzma/check/crc32_fast.c | 9 +++------ + src/liblzma/check/crc64_fast.c | 7 +++---- + src/liblzma/check/crc_common.h | 25 +++++++++++++++++++++++++ + 3 files changed, 31 insertions(+), 10 deletions(-) + +commit 3007e74ef250f0ce95d97ffbdf2282284f93764d +Author: Lasse Collin +Date: 2024-03-05 23:21:26 +0200 + + liblzma: Fix a typo in a comment in the RISC-V filter. + + src/liblzma/simple/riscv.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit 72d2933bfae514e0dbb123488e9f1eb7cf64175f +Author: Jia Tan +Date: 2024-03-05 00:34:46 +0800 + + liblzma: Use attribute no_profile_instrument_function with ifunc. + + Thanks to Sam James for determining this was the attribute needed to + workaround the GCC bug and for his version of the patch in Gentoo. + + src/liblzma/check/crc32_fast.c | 5 +++++ + src/liblzma/check/crc64_fast.c | 3 +++ + 2 files changed, 8 insertions(+) + +commit e5faaebbcf02ea880cfc56edc702d4f7298788ad +Author: Jia Tan +Date: 2024-03-05 00:27:31 +0800 + + Build: Require attribute no_profile_instrument_function for ifunc usage. + + Using __attribute__((__no_profile_instrument_function__)) on the ifunc + resolver works around a bug in GCC -fprofile-generate: + it adds profiling code even to ifunc resolvers which can make + the ifunc resolver crash at program startup. This attribute + was not introduced until GCC 7 and Clang 13, so ifunc won't + be used with prior versions of these compilers. + + This bug was brought to our attention by: + + https://bugs.gentoo.org/925415 + + And was reported to upstream GCC by: + + https://gcc.gnu.org/bugzilla/show_bug.cgi?id=11411 + + CMakeLists.txt | 7 +++++++ + configure.ac | 7 +++++++ + 2 files changed, 14 insertions(+) + +commit 7eeadd279a24c26ca7ff1292b7df802b89409eb7 +Author: Lasse Collin +Date: 2024-03-04 19:23:18 +0200 + + liblzma: Fix a comment in the RISC-V filter. + + src/liblzma/simple/riscv.c | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +commit 5f3d0595296cc3035eae9e7bb6c3ffb1e1267333 +Author: Lasse Collin +Date: 2024-02-29 16:35:52 +0200 + + CMake: Warn if translated man pages are missing. + + CMakeLists.txt | 9 +++++++++ + 1 file changed, 9 insertions(+) + +commit 4cd1042ee752d61370c685d0d8b20c1e935672f7 +Author: Lasse Collin +Date: 2024-02-29 16:35:52 +0200 + + CMake: Warn if gettext tools and pre-created .gmo files are missing. + + It's only done with CMake >= 3.20 and if library support + for translation was already found. + + Sort of fixes: https://github.com/tukaani-project/xz/issues/82 + + CMakeLists.txt | 25 +++++++++++++++++++++++++ + 1 file changed, 25 insertions(+) + +commit a94b42362c8e807f92236d6d63373f04991e3a50 +Author: Lasse Collin +Date: 2024-02-28 18:26:25 +0200 + + xz: Add comments. + + src/xz/coder.c | 10 ++++++++++ + 1 file changed, 10 insertions(+) + +commit bbf112e32307a75a54a9e170bc392811443d5c87 +Author: Jia Tan +Date: 2024-02-27 23:42:41 +0800 + + xz: Change logging level for thread reduction to highest verbosity only. + + Now that multi threaded encoding is the default, users do not need to + see a warning message everytime the number of threads is reduced. On + some machines, this could happen very often. It is not unreasonable for + users to need to set double verbose mode to see this kind of + information. + + To see these warning messages -vv or --verbose --verbose must be passed + to set xz into the highest possible verbosity mode. + + These warnings had caused automated testing frameworks to fail when they + expected no output to stderr. + + Thanks to Sebastian Andrzej Siewior for reporting this and for the + initial version of the patch. + + src/xz/coder.c | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +commit 649f6447441510d593a88475ad6df4bcdf74ce48 +Author: Lasse Collin +Date: 2024-02-26 23:06:13 +0200 + + Fix sorting in THANKS. + + THANKS | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +commit 1255b7d849bf53f196a842ef2a508ed0ff577eaa +Author: Jia Tan +Date: 2024-02-26 23:39:29 +0800 + + Update THANKS. + + THANKS | 1 + + 1 file changed, 1 insertion(+) + +commit eee579fff50099ba163c12305e81a4bd42b7dd53 +Author: Chien Wong +Date: 2024-02-25 21:38:13 +0800 + + xz: Add missing RISC-V on the filter list in the man page + + Signed-off-by: Chien Wong + + src/xz/xz.1 | 4 +++- + 1 file changed, 3 insertions(+), 1 deletion(-) + +commit 328c52da8a2bbb81307644efdb58db2c422d9ba7 +Author: Jia Tan +Date: 2024-02-26 23:02:06 +0800 + + Build: Fix Linux Landlock feature test in Autotools and CMake builds. + + The previous Linux Landlock feature test assumed that having the + linux/landlock.h header file was enough. The new feature tests also + requires that prctl() and the required Landlock system calls are + supported. + + CMakeLists.txt | 25 ++++++++++++++++++++++--- + configure.ac | 27 ++++++++++++++++++++++++++- + src/xz/sandbox.c | 2 +- + src/xz/sandbox.h | 2 +- + src/xzdec/xzdec.c | 8 ++++---- + 5 files changed, 54 insertions(+), 10 deletions(-) + +commit eb8ad59e9bab32a8d655796afd39597ea6dcc64d +Author: Jia Tan +Date: 2024-02-26 20:06:10 +0800 + + Tests: Add test_microlzma to .gitignore and CMakeLists.txt. + + .gitignore | 1 + + CMakeLists.txt | 1 + + 2 files changed, 2 insertions(+) + +commit 9eed1b9a3ae140e93a82febc05a0181e9a4f5093 +Author: Jia Tan +Date: 2024-02-26 19:56:25 +0800 + + Tests: Correct license header in test_microlzma.c. + + tests/test_microlzma.c | 5 ++--- + 1 file changed, 2 insertions(+), 3 deletions(-) + +commit 8bf9f72ee1c05b9e205a72807e8a9e304785673d +Author: Jia Tan +Date: 2024-02-25 21:41:55 +0800 + + Fix typos in NEWS and CMakeLists. + + CMakeLists.txt | 2 +- + NEWS | 2 +- + 2 files changed, 2 insertions(+), 2 deletions(-) + +commit 5d8d915ebe2e345820a0f54d1baf8d7d4824c0c7 +Author: Jia Tan +Date: 2024-02-24 16:30:06 +0800 + + Bump version and soname for 5.7.0alpha. + + Like 5.5.0alpha, 5.7.0alpha won't be released, it's just to mark that + the branch is not stable. + + Once again there is no API/ABI stability for new features in devel + versions. The major soname won't be bumped even if API/ABI of new + features breaks between devel releases. + + src/liblzma/Makefile.am | 2 +- + src/liblzma/api/lzma/version.h | 6 +++--- + src/liblzma/liblzma_generic.map | 2 +- + src/liblzma/liblzma_linux.map | 2 +- + 4 files changed, 6 insertions(+), 6 deletions(-) + +commit a18fb1edef0d0aac12a09eed05e9c448c777af7b +Author: Jia Tan +Date: 2024-02-24 15:50:36 +0800 + + Add NEWS for 5.6.0. + + NEWS | 143 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ + 1 file changed, 143 insertions(+) + +commit 24355c5280bc95e3d594432d60bb8432aa6af173 +Author: Jia Tan +Date: 2024-02-22 22:27:01 +0800 + + Translations: Remove obsolete and fuzzy matches from some translations. + + The French and Brazilian Portuguese man page translations have not been + updated since the switch from public domain to 0BSD. The old GPLv2 + strings have now been removed from these files. + + po4a/fr.po | 4702 +++++++++++++++++++++++++++++++++++++---------------- + po4a/pt_BR.po | 4987 ++++++++++++++++++++++++++++++++++++++++----------------- + 2 files changed, 6832 insertions(+), 2857 deletions(-) + +commit 02ca4a7d7b703e2ec63e00b70feec825e919dbc1 +Author: Jia Tan +Date: 2024-02-21 00:31:54 +0800 + + Translations: Patch man pages to avoid fuzzy matches. + + This will be fixed in the next round of translations, but this avoids + having a fuzzy match or not fixing the English version. + + po4a/de.po | 2 +- + po4a/ko.po | 2 +- + po4a/ro.po | 2 +- + po4a/uk.po | 2 +- + 4 files changed, 4 insertions(+), 4 deletions(-) + +commit 898aad9fc711e03452d24d9e2c5b7f77a6f9ce64 +Author: Jia Tan +Date: 2024-02-21 00:30:43 +0800 + + xzmore: Fix typo in xzmore.1. + + Thanks to Yuri Chornoivan. + + src/scripts/xzmore.1 | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit 5631aa206c8d16b4eeab85a46b8b698f4fc4cdba +Author: Jia Tan +Date: 2024-02-24 12:12:16 +0800 + + Translations: Update the Vietnamese translation. + + po/vi.po | 505 ++++++++++++++++++++++++++++++++++++++------------------------- + 1 file changed, 309 insertions(+), 196 deletions(-) + +commit a65fd7ce9d6228e87faf61dc56a35984d0088248 +Author: Jia Tan +Date: 2024-02-24 12:06:40 +0800 + + Translations: Update the Esperanto translation. + + po/eo.po | 502 ++++++++++++++++++++++++++++++++++++++------------------------- + 1 file changed, 306 insertions(+), 196 deletions(-) + +commit cf44e4b7f5dfdbf8c78aef377c10f71e274f63c0 +Author: Jia Tan +Date: 2024-02-23 23:09:59 +0800 + + Tests: Add a few test files. + + tests/files/README | 19 +++++++++++++++++++ + tests/files/bad-3-corrupt_lzma2.xz | Bin 0 -> 484 bytes + tests/files/bad-dict_size.lzma | Bin 0 -> 41 bytes + tests/files/good-2cat.xz | Bin 0 -> 136 bytes + tests/files/good-large_compressed.lzma | Bin 0 -> 35430 bytes + tests/files/good-small_compressed.lzma | Bin 0 -> 258 bytes + 6 files changed, 19 insertions(+) + +commit 39f4a1a86ad80b2d064b812cee42668e6c8b8c73 +Author: Jia Tan +Date: 2024-02-23 20:58:36 +0800 + + Tests: Add MicroLZMA test. + + tests/Makefile.am | 4 +- + tests/test_microlzma.c | 548 +++++++++++++++++++++++++++++++++++++++++++++++++ + 2 files changed, 551 insertions(+), 1 deletion(-) + +commit adaacafde6661496ca2814b1e94a3ba5186428cb +Author: Jia Tan +Date: 2024-02-23 20:57:59 +0800 + + Build: Define HAVE_MICROLZMA when it is configured. + + CMakeLists.txt | 4 ++++ + configure.ac | 9 +++++++-- + 2 files changed, 11 insertions(+), 2 deletions(-) + +commit eea78216d27182ca917bf00e02feaab058a4d21e +Author: Jia Tan +Date: 2024-02-23 20:27:15 +0800 + + xz: Fix Capsicum sandbox compile error. + + user_abort_pipe[] was still being used instead of the parameters. + + src/xz/sandbox.c | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +commit 32b0a3ce19224f9074d01a4ffbc1655b05fcb82d +Author: Jia Tan +Date: 2024-02-23 16:12:32 +0800 + + Build: Fix ARM64 CRC32 instruction feature test. + + Old versions of Clang reported the unsupported function attribute and + __crc32d() function as warnings instead of errors, so the feature test + passed when it shouldn't have, causing a compile error at build time. + -Werror was added to this feature test to fix this. The change is not + needed for CMake because check_c_source_compiles() also performs + linking and the error is caught then. + + Thanks to Sebastian Andrzej Siewior for reporting this. + + configure.ac | 10 ++++++++++ + 1 file changed, 10 insertions(+) + +commit 4c81c9611f8b2e1ad65eb7fa166afc570c58607e +Author: Lasse Collin +Date: 2024-02-22 19:16:35 +0200 + + CMake: Add LOCALEDIR to the windres workaround. + + LOCALEDIR may contain spaces like in "C:\Program Files". + + CMakeLists.txt | 16 +++++++++++----- + 1 file changed, 11 insertions(+), 5 deletions(-) + +commit de4337fd89ca7db5feb97b5c40143404f6e22986 +Author: Lasse Collin +Date: 2024-02-22 15:18:25 +0200 + + xz: Landlock: Fix error message if input file is a directory. + + If xz is given a directory, it should look like this: + + $ xz /usr/bin + xz: /usr/bin: Is a directory, skipping + + The Landlock rules didn't allow opening directories for reading: + + $ xz /usr/bin + xz: /usr/bin: Permission denied + + The simplest fix was to allow opening directories for reading. + While it's a bit silly to allow it solely for the error message, + it shouldn't make the sandbox significantly weaker. + + The single-file use case (like when called from GNU tar) is + still as strict as possible: all Landlock restrictions are + enabled before (de)compression starts. + + src/xz/sandbox.c | 15 ++++++++++++++- + 1 file changed, 14 insertions(+), 1 deletion(-) + +commit 120da10ae139ea52ca4275452adf8eda02d07cc8 +Author: Lasse Collin +Date: 2024-02-22 14:41:29 +0200 + + liblzma: Disable branchless C version in range decoder. + + Thanks to Sebastian Andrzej Siewior and Sam James for + benchmarking on various systems. + + src/liblzma/rangecoder/range_decoder.h | 13 ++++++++++--- + 1 file changed, 10 insertions(+), 3 deletions(-) + +commit 00440f52be9ac2c7438c7b0cb1082f12399632c6 +Author: Lasse Collin +Date: 2024-02-21 17:41:32 +0200 + + INSTALL: Clarify that --disable-assembler affects only 32-bit x86. + + INSTALL | 18 +++++++++--------- + 1 file changed, 9 insertions(+), 9 deletions(-) + +commit 11405be84ea294497e12d03d7219f607063f4a00 +Author: Lasse Collin +Date: 2024-02-19 18:41:37 +0200 + + Windows: build.bash: Include COPYING.0BSD in the package. + + windows/build.bash | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit c27cf64e3e27f4968431d65be7098a12a3a80d30 +Author: Lasse Collin +Date: 2024-02-18 17:59:46 +0200 + + Windows: build.bash: include liblzma-crt-mixing.txt in the package. + + windows/build.bash | 6 ++++-- + 1 file changed, 4 insertions(+), 2 deletions(-) + +commit 8d38941baed05de4ff7cc775de14833108f62184 +Author: Lasse Collin +Date: 2024-02-18 17:17:43 +0200 + + Windows: Major update to Windows build instructions. + + INSTALL | 68 ++++----- + windows/INSTALL-MSVC.txt | 23 +-- + windows/INSTALL-MinGW-w64_with_Autotools.txt | 49 +++++++ + windows/INSTALL-MinGW-w64_with_CMake.txt | 203 +++++++++++++++++++++++++++ + windows/INSTALL-MinGW.txt | 138 ------------------ + windows/README-Windows.txt | 2 + + windows/build-with-cmake.bat | 35 +++++ + windows/liblzma-crt-mixing.txt | 70 +++++++++ + 8 files changed, 404 insertions(+), 184 deletions(-) + +commit 4b5b0d352348ff510ffb50a3b5b71788857d37a1 +Author: Lasse Collin +Date: 2024-02-18 15:15:04 +0200 + + Windows: Update windows/README-Windows.txt. + + It's for binary packages built with windows/build.bash. + + windows/README-Windows.txt | 104 ++++++++++++++++++--------------------------- + 1 file changed, 41 insertions(+), 63 deletions(-) + +commit 1ee716f74085223c8fbcae1d5a384e6bf53c0f6a +Author: Lasse Collin +Date: 2024-02-18 15:15:04 +0200 + + Windows: Update windows/build.bash. + + Support for the old MinGW was dropped. Only MinGW-w64 with GCC + is supported now. + + The script now supports also cross-compilation from GNU/Linux + (tests are not run). MSYS2 and also the old MSYS 1.0.11 work + for building on Windows. The i686 and x86_64 toolchains must + be in PATH to build both 32-bit and 64-bit versions. + + Parallel builds are done if "nproc" from GNU coreutils is available. + + MinGW-w64 runtime copyright information file was renamed from + COPYING-Windows.txt to COPYING.MinGW-w64-runtime.txt which + is the filename used by MinGW-w64 itself. Its existence + is now mandatory, it's checked at the beginning of the script. + + The file TODO is no longer copied to the package. + + windows/build.bash | 191 +++++++++++++++++++++++++++++++---------------------- + 1 file changed, 112 insertions(+), 79 deletions(-) + +commit 60462e42609a1d961868a1d1ebecc713c6d27e2e +Author: Jia Tan +Date: 2024-02-20 23:32:22 +0800 + + Translations: Update the Romanian man page translations. + + po4a/ro.po | 1715 +++++++++++++++++++++++++++++++----------------------------- + 1 file changed, 875 insertions(+), 840 deletions(-) + +commit 10d733e5b8929c642e00891cfa9ead9c2cdd2e05 +Author: Jia Tan +Date: 2024-02-20 23:30:25 +0800 + + Translations: Update the Korean man page translations. + + po4a/ko.po | 6 +++--- + 1 file changed, 3 insertions(+), 3 deletions(-) + +commit 797a34b72ac6baff237d7a546fa941d8f78f2f62 +Author: Jia Tan +Date: 2024-02-20 21:03:53 +0800 + + Translations: Update the Spanish translation. + + po/es.po | 6 +++--- + 1 file changed, 3 insertions(+), 3 deletions(-) + +commit 5c3751d019f023e091df9a653e2bb1f6ea8b0d49 +Author: Jia Tan +Date: 2024-02-20 20:18:07 +0800 + + Translations: Update the Romanian translation. + + po/ro.po | 470 ++++++++++++++++++++++++++++++--------------------------------- + 1 file changed, 227 insertions(+), 243 deletions(-) + +commit e2d31154ecc750935436e8b62c6b073b2cfa84e3 +Author: Jia Tan +Date: 2024-02-20 20:15:50 +0800 + + Translations: Update the Croatian translation. + + po/hr.po | 648 ++++++++++++++++++++++++++++++++++----------------------------- + 1 file changed, 355 insertions(+), 293 deletions(-) + +commit 704500f994d5ac271bfcfd592275c5a7da4dc8d2 +Author: Jia Tan +Date: 2024-02-20 20:05:44 +0800 + + Translations: Update the German man page translations. + + po4a/de.po | 1696 +++++++++++++++++++++++++++++++----------------------------- + 1 file changed, 873 insertions(+), 823 deletions(-) + +commit 1cfd3dca3fef321b06db73c3c9e13f347c2e2f5f +Author: Jia Tan +Date: 2024-02-20 19:58:25 +0800 + + Translations: Update the German translation. + + po/de.po | 427 +++++++++++++++++++++++++++++++++------------------------------ + 1 file changed, 225 insertions(+), 202 deletions(-) + +commit 28b9b3f16cc7c6e5b42e691994569c17f4561c9a +Author: Jia Tan +Date: 2024-02-20 19:56:52 +0800 + + Translations: Update the Hungarian translation. + + po/hu.po | 556 ++++++++++++++++++++++++++++++++++++++------------------------- + 1 file changed, 338 insertions(+), 218 deletions(-) + +commit 00b06cd0af6ad2ee93d3006bf80417db060c2b04 +Author: Lasse Collin +Date: 2024-02-19 16:48:05 +0200 + + CMake: Fix building of lzmainfo when translations are enabled. + + CMakeLists.txt | 2 ++ + 1 file changed, 2 insertions(+) + +commit b0d1422b6037bfea6f6723683bd82a8e6d77026c +Author: Lasse Collin +Date: 2024-02-19 13:38:42 +0200 + + CMake: Don't assume that -fvisibility=hidden is supported outside Windows. + + The original code was good enough for supporting GNU/Linux + and a few others but it wasn't very portable. + + CMake doesn't support Solaris Studio's -xldscope=hidden. + If it ever does, things should still work with this commit + as Solaris Studio supports not only its own __global but also + the GNU C __attribute__((visibility("default"))). Support for the + attribute was added in 2007 to Sun Studio 12 compiler version 5.9. + + CMakeLists.txt | 26 ++++++++++++++++++++++---- + 1 file changed, 22 insertions(+), 4 deletions(-) + +commit 2ced9d34bef4dce52ecbbf84d0903ab0aae1442c +Author: Lasse Collin +Date: 2024-02-19 12:20:59 +0200 + + CMake: Revise the component splitting. + + CMakeLists.txt | 57 +++++++++++++++++++++++++++++++-------------------------- + 1 file changed, 31 insertions(+), 26 deletions(-) + +commit 426bdc709c169d39b31dec410016779de117ef69 +Author: Lasse Collin +Date: 2024-02-17 21:45:07 +0200 + + CMake: Update the main comment and document CMAKE_BUILD_TYPE=Release. + + CMakeLists.txt | 79 ++++++++++++++++++++++++++++++++++++++++++++++------------ + 1 file changed, 63 insertions(+), 16 deletions(-) + +commit 4430e075f7ccfc47972d6ca0aa1c3779fc265e10 +Author: Lasse Collin +Date: 2024-02-17 21:27:48 +0200 + + CMake: Use -O2 instead of -O3 in CMAKE_BUILD_TYPE=Release. + + -O3 doesn't seem useful for speed but it makes the code bigger. + CMake makes is difficult for users to simply override the + optimization level: CFLAGS / CMAKE_C_FLAGS aren't helpful because + they go before CMAKE_C_FLAGS_RELEASE. Of course, users can override + CMAKE_C_FLAGS_RELEASE directly but then they have to remember to + add also -DNDEBUG to disable assertions. + + This commit changes -O3 to -O2 in CMAKE_C_FLAGS_RELEASE if and only if + CMAKE_C_FLAGS_RELEASE cache variable doesn't already exist. So if + a custom value is passed on the command line (or reconfiguring an + already-configured build), the cache variable won't be modified. + + CMakeLists.txt | 19 +++++++++++++++++++ + 1 file changed, 19 insertions(+) + +commit 025eb6d7879e4c4e8cb29716b371e0f4c1aea660 +Author: Lasse Collin +Date: 2024-02-18 14:59:52 +0200 + + CMake: Handle symbol versioning on MicroBlaze specially. + + This is to match configure.ac. + + CMakeLists.txt | 23 +++++++++++++++++++---- + 1 file changed, 19 insertions(+), 4 deletions(-) + +commit 2edd1a35b2507d1ce68b52dbaebe23c4850a74ce +Author: Lasse Collin +Date: 2024-02-17 22:18:12 +0200 + + CMake: Keep build working even if lib/*.[ch] are removed. + + CMakeLists.txt | 7 ++++++- + 1 file changed, 6 insertions(+), 1 deletion(-) + +commit d753e2ce4715552884afadc4ed6fbf8ccca6efac +Author: Lasse Collin +Date: 2024-02-17 18:10:40 +0200 + + CMake: Install documentation. + + CMakeLists.txt | 32 ++++++++++++++++++++++++++++++++ + 1 file changed, 32 insertions(+) + +commit 7a0405bea9cb0df9318b70f779f82b2c473e98ac +Author: Lasse Collin +Date: 2024-02-17 15:35:35 +0200 + + CMake: Bump maximum policy version to 3.28. + + CMP0154 doesn't affect us since we don't use FILE_SET. + + CMakeLists.txt | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit c2264ffbe3892d28930b89b0123efc369cabc143 +Author: Lasse Collin +Date: 2024-02-17 15:35:35 +0200 + + CMake: Build lzmainfo. + + CMakeLists.txt | 54 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ + 1 file changed, 54 insertions(+) + +commit 998d0b29536094a89cf385a3b894e157db1ccefe +Author: Lasse Collin +Date: 2024-02-17 15:35:35 +0200 + + CMake: Build lzmadec. + + CMakeLists.txt | 76 ++++++++++++++++++++++++++++++++-------------------------- + 1 file changed, 42 insertions(+), 34 deletions(-) + +commit 74e8bc7417a0f37ca7ed5ee0127d33c69b3100b9 +Author: Lasse Collin +Date: 2024-02-17 15:35:35 +0200 + + CMake: Add test_scripts.sh to the tests. + + In contrast to Automake, skipping of this test when decoders + are disabled is handled at CMake side instead of test_scripts.sh + because CMake-build doesn't create config.h. + + CMakeLists.txt | 14 ++++++++++++++ + tests/test_scripts.sh | 13 ++++++++----- + 2 files changed, 22 insertions(+), 5 deletions(-) + +commit 4808f238a731befcd46c2117c62a1caaf4403989 +Author: Lasse Collin +Date: 2024-02-17 15:35:35 +0200 + + CMake: Install scripts. + + Compared to the Autotools-based build, this has simpler handling + for the shell (@POSIX_SHELL@) and extra PATH entry for the scripts + (configure has --enable-path-for-scripts=PREFIX). The simpler + metho should be enough for non-ancient systems and Solaris. + + CMakeLists.txt | 83 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++- + 1 file changed, 82 insertions(+), 1 deletion(-) + +commit 3462362ebd94d835c664e94ad8f414cfe7590ca7 +Author: Lasse Collin +Date: 2024-02-17 15:35:35 +0200 + + Scripts: Use @PACKAGE_VERSION@ instead of @VERSION@. + + PACKAGE_VERSION was already used in liblzma.pc.in. + This way only one version @foo@ is used. + + src/scripts/xzdiff.in | 2 +- + src/scripts/xzgrep.in | 2 +- + src/scripts/xzless.in | 2 +- + src/scripts/xzmore.in | 2 +- + 4 files changed, 4 insertions(+), 4 deletions(-) + +commit 67610c245ba6c68cf65991693bab9312b7dc987b +Author: Lasse Collin +Date: 2024-02-17 15:35:35 +0200 + + CMake: Simplify symlink creation and install translated man pages. + + It helps that cmake_install.cmake doesn't parallelize installation + so symlinks can be created so that the target is always known to + exist (a requirement on Windows in some cases). + + This bumps the minimum CMake version from 3.13 to 3.14 to use + file(CREATE_LINK ...). It could be made to work on 3.13 by + calling "cmake -E create_symlink" but it's uglier code and + slower in "make install". 3.14 should be a reasonable version + to require nowadays, especially since the Autotools build + is still the primary build system for most OSes. + + CMakeLists.txt | 195 +++++++++++++++++++++++++++++---------------------------- + 1 file changed, 98 insertions(+), 97 deletions(-) + +commit 50cc1d8a5a8154428bf240c7e4972e32b17d99bf +Author: Lasse Collin +Date: 2024-02-17 15:35:35 +0200 + + CMake: Add support for building and installing xz with translations. + + If gettext tools are available, the .po files listed in po/LINGUAS + are converted using msgfmt. This allows building with translations + directly from xz.git without Autotools. + + If gettext tools aren't available, the Autotools-created .gmo files + in the "po" directory will be used. This allows CMake-based build + to use translations from Autotools-generated tarball. + + If translation support is found (Intl_FOUND) but both the + gettext tools and the pre-generated .gmo files are missing, + then "make" will fail. + + CMakeLists.txt | 68 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++-- + 1 file changed, 66 insertions(+), 2 deletions(-) + +commit 746c471643009947f94a3494a1148f74c7381b56 +Author: Lasse Collin +Date: 2024-02-19 11:58:33 +0200 + + liblzma: Remove commented-out code. + + src/liblzma/rangecoder/range_decoder.h | 3 --- + 1 file changed, 3 deletions(-) + +commit 4ce300ce0884c6e552de2af9ae8050b47b01f0e7 +Author: Lasse Collin +Date: 2024-02-17 23:07:35 +0200 + + xz: Delete old commented-out code. + + src/xz/message.c | 19 ------------------- + 1 file changed, 19 deletions(-) + +commit cae9a5e0bf422e6c5e64180805904f7ed02dc3aa +Author: Lasse Collin +Date: 2024-02-17 23:07:35 +0200 + + xz: Use stricter pledge(2) and Landlock sandbox. + + This makes these sandboxing methods stricter when no files are + created or deleted. That is, it's a middle ground between the + initial sandbox and the strictest single-file-to-stdout sandbox: + this allows opening files for reading but output has to go to stdout. + + src/xz/main.c | 46 +++++++++++++++++++++++++++++++++------------- + src/xz/sandbox.c | 32 ++++++++++++++++++++++++++++++++ + src/xz/sandbox.h | 4 ++++ + 3 files changed, 69 insertions(+), 13 deletions(-) + +commit 02e3505991233901575b7eabc06b2c6c62a96899 +Author: Lasse Collin +Date: 2024-02-17 23:07:35 +0200 + + xz: Support Landlock ABI version 4. + + Linux 6.7 added support for ABI version 4 which restricts + TCP connections which xz won't need and thus those can be + forbidden now. Since the ABI version is handled at runtime, + supporting version 4 won't cause any compatibility issues. + + Note that new enough kernel headers are required to get + version 4 support enabled at build time. + + src/xz/sandbox.c | 25 ++++++++++++++++++++----- + 1 file changed, 20 insertions(+), 5 deletions(-) + +commit 374868d81d473ab56556a1cfd6b1b36a1fab348b +Author: Lasse Collin +Date: 2024-02-17 23:07:35 +0200 + + xz: Move sandboxing code to sandbox.c and improve Landlock sandbox. + + Landlock is now always used just like pledge(2) is: first in more + permissive mode and later (under certain common conditions) in + a strict mode that doesn't allow opening more files. + + I put pledge(2) first in sandbox.c because it's the simplest API + to use and still somewhat fine-grained for basic applications. + So it's the simplest thing to understand for anyone reading sandbox.c. + + CMakeLists.txt | 2 + + src/xz/Makefile.am | 2 + + src/xz/file_io.c | 170 +----------------------------- + src/xz/file_io.h | 6 -- + src/xz/main.c | 50 +++------ + src/xz/private.h | 6 +- + src/xz/sandbox.c | 295 +++++++++++++++++++++++++++++++++++++++++++++++++++++ + src/xz/sandbox.h | 39 +++++++ + 8 files changed, 357 insertions(+), 213 deletions(-) + +commit 7312dfbb02197c7f990c7a3cefd027a9387d1473 +Author: Lasse Collin +Date: 2024-02-17 23:07:35 +0200 + + xz: Tweak comments. + + src/xz/main.c | 4 +++- + 1 file changed, 3 insertions(+), 1 deletion(-) + +commit c701a5909ad9882469fbab4fab5d2d5556d3ba78 +Author: Lasse Collin +Date: 2024-02-17 23:07:35 +0200 + + xz: Fix message_init() description. + + Also explicitly initialize progress_automatic to make it clear + that it can be read before message_init() sets it. Static variable + was initialized to false by default already so this is only for + clarity. + + src/xz/main.c | 3 ++- + src/xz/message.c | 2 +- + src/xz/message.h | 5 ++++- + 3 files changed, 7 insertions(+), 3 deletions(-) + +commit 9466306719f3b76e92fac4e55fbfd89ec92295fa +Author: Lasse Collin +Date: 2024-02-17 19:35:47 +0200 + + Build: Makefile.am: Sort EXTRA_DIST. + + Dirs first, then files in case-sensitive ASCII order. + + Makefile.am | 14 +++++++------- + 1 file changed, 7 insertions(+), 7 deletions(-) + +commit f3440e78c9517db75bfa52e1a378fad60b073bbe +Author: Lasse Collin +Date: 2024-02-17 19:25:05 +0200 + + Build: Don't install TODO. + + Makefile.am | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit a7a3b62e2ab03c82b2bd5c78da1d1fb8b8490381 +Author: Jia Tan +Date: 2024-02-18 01:09:11 +0800 + + Translations: Update the Korean man page translations. + + po4a/ko.po | 1707 +++++++++++++++++++++++++++++++----------------------------- + 1 file changed, 871 insertions(+), 836 deletions(-) + +commit 9b315db2d5e74700f3dc0755eb86c27947c0b393 +Author: Jia Tan +Date: 2024-02-18 01:08:32 +0800 + + Translations: Update the Korean translation. + + po/ko.po | 423 +++++++++++++++++++++++++++++++++------------------------------ + 1 file changed, 223 insertions(+), 200 deletions(-) + +commit 56246607dff177b0410d140fcca4a42c865723dc +Author: Lasse Collin +Date: 2024-02-17 16:23:14 +0200 + + Build: Install translated lzmainfo man pages. + + All other translated man pages were being installed but + lzmainfo had been forgotten. + + src/lzmainfo/Makefile.am | 26 ++++++++++++++++++++++++++ + 1 file changed, 26 insertions(+) + +commit f1d6b88aefcced538403c5c2606ba57065b16e70 +Author: Lasse Collin +Date: 2024-02-17 16:01:32 +0200 + + liblzma: Avoid implementation-defined behavior in the RISC-V filter. + + GCC docs promise that it works and a few other compilers do + too. Clang/LLVM is documented source code only but unsurprisingly + it behaves the same as others on x86-64 at least. But the + certainly-portable way is good enough here so use that. + + src/liblzma/simple/riscv.c | 30 ++++++++++++++++++++++-------- + 1 file changed, 22 insertions(+), 8 deletions(-) + +commit 843ddc5f617b91ae132d6bab0f2f2d9c9fcd214a +Author: Lasse Collin +Date: 2024-02-17 15:48:28 +0200 + + liblzma: Wrap a line exceeding 80 chars. + + src/liblzma/rangecoder/range_decoder.h | 3 ++- + 1 file changed, 2 insertions(+), 1 deletion(-) + +commit e9053c907250c70d98b319d95fa54cb94fc76869 +Author: Sebastian Andrzej Siewior +Date: 2024-02-16 21:50:15 +0100 + + liblzma/rangecoder: Exclude x32 from the x86-64 optimisation. + + The x32 port has a x86-64 ABI in term of all registers but uses only + 32bit pointer like x86-32. The assembly optimisation fails to compile on + x32. Given the state of x32 I suggest to exclude it from the + optimisation rather than trying to fix it. + + Signed-off-by: Sebastian Andrzej Siewior + + src/liblzma/rangecoder/range_decoder.h | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit 3d198fb13b87f8803442e5799d465f7434a70555 +Author: Jia Tan +Date: 2024-02-17 21:05:07 +0800 + + Translations: Update the Spanish translation. + + po/es.po | 427 +++++++++++++++++++++++++++++++++------------------------------ + 1 file changed, 226 insertions(+), 201 deletions(-) + +commit cf278bfe60a25b54b3786f06503bc61272970820 +Author: Jia Tan +Date: 2024-02-17 20:43:29 +0800 + + Translations: Update the Swedish translation. + + po/sv.po | 434 +++++++++++++++++++++++++++++++++------------------------------ + 1 file changed, 230 insertions(+), 204 deletions(-) + +commit b0f1a41be50560cc6cb528e8e96b02b2067c52c2 +Author: Jia Tan +Date: 2024-02-17 20:41:38 +0800 + + Translations: Update the Polish translation. + + po/pl.po | 424 +++++++++++++++++++++++++++++++++------------------------------ + 1 file changed, 224 insertions(+), 200 deletions(-) + +commit d74ed48b30c631b6a4c7e7858b06828293bf8520 +Author: Jia Tan +Date: 2024-02-17 20:41:02 +0800 + + Translations: Update the Ukrainian translation. + + po/uk.po | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit 711e22d5c5f3bac39ac904efb3ede874a66e2045 +Author: Lasse Collin +Date: 2024-02-16 17:53:34 +0200 + + Translations: Use the same sentence in xz.pot-header that the TP uses. + + po/xz.pot-header | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit fb5f6aaf18584672d0fee5dbe41fd30fc6bf5422 +Author: Jia Tan +Date: 2024-02-16 22:53:46 +0800 + + Fix typos discovered by codespell. + + AUTHORS | 2 +- + NEWS | 2 +- + src/liblzma/rangecoder/range_decoder.h | 4 ++-- + 3 files changed, 4 insertions(+), 4 deletions(-) + +commit c64723bbb094e29b4edd98f6fcce866e1b569b42 +Author: Jia Tan +Date: 2024-02-16 22:52:41 +0800 + + Translations: Update the Ukrainian man page translations. + + po4a/uk.po | 1710 +++++++++++++++++++++++++++++++----------------------------- + 1 file changed, 873 insertions(+), 837 deletions(-) + +commit 2895195ed0f68b245c7bd568c126ba6e685fa1d6 +Author: Jia Tan +Date: 2024-02-16 22:51:04 +0800 + + Translations: Update the Ukrainian translation. + + po/uk.po | 466 ++++++++++++++++++++++++++++++--------------------------------- + 1 file changed, 225 insertions(+), 241 deletions(-) + +commit 4c20781f4c8f04879b64d631a4f44b4909147bde +Author: Lasse Collin +Date: 2024-02-15 22:32:52 +0200 + + Translations: Omit the generic copyright line from man page headers. + + po4a/update-po | 1 + + 1 file changed, 1 insertion(+) + +commit 4323bc3e0c1e1d2037d5e670a3bf6633e8a3031e +Author: Jia Tan +Date: 2024-02-15 22:26:43 +0800 + + Update m4/.gitignore. + + m4/.gitignore | 1 + + 1 file changed, 1 insertion(+) + +commit 5394a1665b7a108a54cb8b4ef3ebe59d3dbcca3a +Author: Lasse Collin +Date: 2024-02-14 21:11:49 +0200 + + Tests: tuktest.h: Treat Clang separately from GCC. + + Don't assume that Clang defines __GNUC__ as the extensions + are available in clang-cl as well (and possibly in some other + Clang variants?). + + tests/tuktest.h | 6 +++--- + 1 file changed, 3 insertions(+), 3 deletions(-) + +commit cce7330b9f23485a0879422e0c3395a7065439ac +Author: Lasse Collin +Date: 2024-02-14 21:11:03 +0200 + + Tests: tuktest.h: Add a missing word to a comment. + + tests/tuktest.h | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +commit 5dd8fc9452a3373cedc27379067ce638f992c741 +Author: Lasse Collin +Date: 2024-02-14 21:10:10 +0200 + + Tests: tuktest.h: Fix the comment about STest. + + tests/tuktest.h | 3 ++- + 1 file changed, 2 insertions(+), 1 deletion(-) + +commit 6f1790254a03c5edf0f2976f773220f070450acd +Author: Jia Tan +Date: 2024-02-15 01:53:40 +0800 + + Bump version for 5.5.2beta. + + src/liblzma/api/lzma/version.h | 4 ++-- + src/liblzma/liblzma_generic.map | 2 +- + src/liblzma/liblzma_linux.map | 2 +- + 3 files changed, 4 insertions(+), 4 deletions(-) + +commit 924fdeedf48113fb1e0646d86bd89a356d21a055 +Author: Lasse Collin +Date: 2024-02-14 19:46:11 +0200 + + liblzma: Fix validate_map.sh. + + Adding the SPDX license identifier changed the line numbers. + + src/liblzma/validate_map.sh | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit 22140a2df6161b0110e6b4afa5ea0a07c5b60b01 +Author: Lasse Collin +Date: 2024-02-14 19:38:34 +0200 + + Build: Start the generated ChangeLog from around 5.4.0 instead of 5.2.0. + + Makefile.am | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit 0b8cefa136c21d403a01b78517f4decb50172bdb +Author: Lasse Collin +Date: 2024-02-14 19:27:46 +0200 + + Fixed NEWS for 5.5.2beta. + + NEWS | 8 ++++++-- + 1 file changed, 6 insertions(+), 2 deletions(-) + +commit a4557bad96361d93ea171ed859ac5a696fca824f +Author: Lasse Collin +Date: 2024-02-14 19:21:45 +0200 + + liblzma: Silence warnings in --enable-small build. + + src/liblzma/lzma/lzma_decoder.c | 2 ++ + src/liblzma/rangecoder/range_decoder.h | 1 + + 2 files changed, 3 insertions(+) + +commit 38edf473236d00b3e100dc4c4f0bf43a4993fed2 +Author: Lasse Collin +Date: 2024-02-14 19:15:58 +0200 + + Build: Install COPYING.0BSD as part of docs. + + Makefile.am | 1 + + 1 file changed, 1 insertion(+) + +commit b74e10bd839bcdc239afb5300ffaee195f34c217 +Author: Lasse Collin +Date: 2024-02-14 19:14:05 +0200 + + Docs: List COPYING.0BSD in README. + + README | 1 + + 1 file changed, 1 insertion(+) + +commit dfdb60ffe933a1f1497d300dbb4513ed17ec6f0e +Author: Lasse Collin +Date: 2024-02-14 19:11:48 +0200 + + Docs: Include doc/examples/11_file_info.c in tarballs. + + It was added in 2017 in c2e29f06a7d1e3ba242ac2fafc69f5d6e92f62cd + but it never got into any release tarballs because it was + forgotten to be added to Makefile.am. + + Makefile.am | 1 + + 1 file changed, 1 insertion(+) + +commit 160b6862646d95dfdbd73ab7f1031ede0f54992d +Author: Lasse Collin +Date: 2024-02-14 19:05:58 +0200 + + liblzma: Silence a warning. + + src/liblzma/rangecoder/range_decoder.h | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit eeedd4d0925ea417add04ceb42a6c0829244b50c +Author: Lasse Collin +Date: 2024-02-14 18:32:27 +0200 + + Add NEWS for 5.5.2beta. + + NEWS | 60 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ + 1 file changed, 60 insertions(+) + +commit 8af7db854f903068d72a9a0d21103cb0c5027fa8 +Author: Lasse Collin +Date: 2024-02-13 14:32:47 +0200 + + xz: Mention lzmainfo if trying to use 'lzma --list'. + + This kind of fixes the problem reported here: + https://bugs.launchpad.net/ubuntu/+source/xz-utils/+bug/1291020 + + src/xz/list.c | 16 ++++++++++++++-- + 1 file changed, 14 insertions(+), 2 deletions(-) + +commit 0668907ff736e4cd16738c10d39a2bc9e851aefb +Author: Lasse Collin +Date: 2024-02-14 14:58:36 +0200 + + liblzma: Add comments. + + src/liblzma/lzma/lzma_decoder.c | 9 +++++++++ + src/liblzma/rangecoder/range_decoder.h | 11 +++++++++-- + 2 files changed, 18 insertions(+), 2 deletions(-) + +commit 109f1913d4824c8214d5bbd38ebebf62c37572da +Author: Lasse Collin +Date: 2024-02-13 17:00:17 +0200 + + Scripts: Add lz4 support to xzgrep and xzdiff. + + src/scripts/xzdiff.1 | 8 +++++--- + src/scripts/xzdiff.in | 14 +++++++++----- + src/scripts/xzgrep.1 | 6 ++++-- + src/scripts/xzgrep.in | 1 + + 4 files changed, 19 insertions(+), 10 deletions(-) + +commit de55485cb23af56c5adbe3239b935c957ff8ac4f +Author: Lasse Collin +Date: 2024-02-13 14:05:13 +0200 + + liblzma: Choose the range decoder variants using a bitmask macro. + + src/liblzma/rangecoder/range_decoder.h | 64 ++++++++++++++++++++++++++++------ + 1 file changed, 53 insertions(+), 11 deletions(-) + +commit 0709c2b2d7c1d8f437b003f691880fd7810e5be5 +Author: Lasse Collin +Date: 2024-02-13 11:38:10 +0200 + + xz: Fix outdated threading related info on the man page. + + src/xz/xz.1 | 22 ++++++++++++++-------- + 1 file changed, 14 insertions(+), 8 deletions(-) + +commit 3182a330c1512cc1f5c87b5c5a272578e60a5158 +Author: Lasse Collin +Date: 2024-02-12 17:09:10 +0200 + + liblzma: Range decoder: Add x86-64 inline assembly. + + It's compatible with GCC and Clang. + + src/liblzma/rangecoder/range_decoder.h | 491 +++++++++++++++++++++++++++++++++ + 1 file changed, 491 insertions(+) + +commit cba2edc991dffba7cd4891dbc1bd26cb950cf053 +Author: Lasse Collin +Date: 2024-02-12 17:09:10 +0200 + + liblzma: Range decoder: Add branchless C code. + + It's used only for basic bittrees and fixed-size reverse bittree + because those showed a clear benefit on x86-64 with GCC and Clang. + The other methods were more mixed and thus are commented out but + they should be tested on other archs. + + src/liblzma/rangecoder/range_decoder.h | 76 ++++++++++++++++++++++++++++++++++ + 1 file changed, 76 insertions(+) + +commit e290a72d6dee71faf3a90c9678b2f730083666a7 +Author: Lasse Collin +Date: 2024-02-12 17:09:10 +0200 + + liblzma: Clarify a comment. + + src/liblzma/lzma/lzma_decoder.c | 9 ++++++--- + 1 file changed, 6 insertions(+), 3 deletions(-) + +commit 5e04706b91ca90d6befd4da24a588a55e631d4a9 +Author: Lasse Collin +Date: 2024-02-12 17:09:10 +0200 + + liblzma: LZMA decoder: Optimize loop comparison. + + But now it needs one more local variable. + + src/liblzma/lzma/lzma_decoder.c | 5 ++--- + src/liblzma/rangecoder/range_decoder.h | 10 +++++++++- + 2 files changed, 11 insertions(+), 4 deletions(-) + +commit 88276f9f2cb4871c7eb86952d93d07c1cf6caa66 +Author: Lasse Collin +Date: 2024-02-12 17:09:10 +0200 + + liblzma: Optimize literal_subcoder() macro slightly. + + src/liblzma/lzma/lzma_common.h | 22 ++++++++++++---------- + src/liblzma/lzma/lzma_decoder.c | 12 ++++++------ + src/liblzma/lzma/lzma_encoder.c | 6 +++--- + src/liblzma/lzma/lzma_encoder_optimum_normal.c | 2 +- + src/liblzma/lzma/lzma_encoder_private.h | 4 ++-- + 5 files changed, 24 insertions(+), 22 deletions(-) + +commit 5938f6de4d8ec9656776cd69e78ddfd6c3ad84e5 +Author: Lasse Collin +Date: 2024-02-12 17:09:10 +0200 + + liblzma: LZ decoder: Add unlikely(). + + src/liblzma/lz/lz_decoder.h | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit 9c252e3ed086c6b72590b2531586c42596d4a9d9 +Author: Lasse Collin +Date: 2024-02-12 17:09:10 +0200 + + liblzma: LZ decoder: Remove a useless unlikely(). + + src/liblzma/lz/lz_decoder.h | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit f3872a59475456c5d365cad9f1c5be514cfa54b5 +Author: Lasse Collin +Date: 2024-02-12 17:09:10 +0200 + + liblzma: Optimize LZ decoder slightly. + + Now extra buffer space is reserved so that repeating bytes for + any single match will never need to copy from two places (both + the beginning and the end of the buffer). This simplifies + dict_repeat() and helps a little with speed. + + This seems to reduce .lzma decompression time about 2 %, so + with .xz and CRC it could be slightly less. The small things + add up still. + + src/liblzma/lz/lz_decoder.c | 43 ++++++++++++----- + src/liblzma/lz/lz_decoder.h | 101 +++++++++++++++++++++------------------- + src/liblzma/lzma/lzma_decoder.c | 4 +- + 3 files changed, 88 insertions(+), 60 deletions(-) + +commit eb518446e578acf079abae5f1ce28db7b6e59bc1 +Author: Lasse Collin +Date: 2024-02-12 17:09:10 +0200 + + liblzma: LZMA decoder: Get rid of next_state[]. + + It's not completely obvious if this is better in the decoder. + It should be good if compiler can avoid creating a branch + (like using CMOV on x86). + + This also makes lzma_encoder.c use the new macros. + + src/liblzma/lzma/lzma_common.h | 14 ++++++++++++++ + src/liblzma/lzma/lzma_decoder.c | 30 ++++++++---------------------- + src/liblzma/lzma/lzma_encoder.c | 4 ++-- + 3 files changed, 24 insertions(+), 24 deletions(-) + +commit e0c0ee475c0800c08291ae45e0d66aa00d5ce604 +Author: Lasse Collin +Date: 2024-02-12 17:09:10 +0200 + + liblzma: LZMA decoder improvements. + + This adds macros for bittree decoding which prepares the code + for alternative C versions and inline assembly. + + src/liblzma/lzma/lzma_decoder.c | 264 ++++++++++----------------------- + src/liblzma/rangecoder/range_common.h | 4 + + src/liblzma/rangecoder/range_decoder.h | 142 ++++++++++++++++-- + 3 files changed, 210 insertions(+), 200 deletions(-) + +commit de5c5e417645ad8906ef914bc059d08c1462fc29 +Author: Jia Tan +Date: 2024-02-12 17:09:10 +0200 + + liblzma: Creates Non-resumable and Resumable modes for lzma_decoder. + + The new decoder resumes the first decoder loop in the Resumable mode. + Then, the code executes in Non-resumable mode until it detects that it + cannot guarantee to have enough input/output to decode another symbol. + + The Resumable mode is how the decoder has always worked. Before decoding + every input bit, it checks if there is enough space and will save its + location to be resumed later. When the decoder has more input/output, + it jumps back to the correct sequence in the Resumable mode code. + + When the input/output buffers are large, the Resumable mode is much + slower than the Non-resumable because it has more branches and is harder + for the compiler to optimize since it is in a large switch block. + + Early benchmarking shows significant time improvement (8-10% on gcc and + clang x86) by using the Non-resumable code as much as possible. + + src/liblzma/lz/lz_decoder.h | 14 +- + src/liblzma/lzma/lzma_decoder.c | 720 ++++++++++++++++++++++++++++------------ + 2 files changed, 521 insertions(+), 213 deletions(-) + +commit e446ab7a18abfde18f8d1cf02a914df72b1370e3 +Author: Jia Tan +Date: 2024-02-12 17:09:10 +0200 + + liblzma: Creates separate "safe" range decoder mode. + + The new "safe" range decoder mode is the same as old range decoder, but + now the default behavior of the range decoder will not check if there is + enough input or output to complete the operation. When the buffers are + close to fully consumed, the "safe" operations must be used instead. This + will improve speed because it will reduce the number of branches needed + for most of the range decoder operations. + + src/liblzma/lzma/lzma_decoder.c | 108 ++++++++------------------------- + src/liblzma/rangecoder/range_decoder.h | 77 +++++++++++++++++------ + 2 files changed, 82 insertions(+), 103 deletions(-) + +commit 7f6d9ca329ff3e01d4b0be7366eb4f5c93da41b9 +Author: Lasse Collin +Date: 2024-02-12 17:09:10 +0200 + + doxygen/footer.html: Add missing closing tags and don't open a new tab. + + The footer template from Doxygen has the closing + as Doxygen doesn't add them otherwise. + + target="_blank" was omitted as it's not useful here but + it can be slightly annoying as one cannot just go back + in the browser history. + + Since the footer links to the license file in the same + directory and not to CC website, the rel attributes + can be omitted. + + doxygen/footer.html | 6 ++++-- + 1 file changed, 4 insertions(+), 2 deletions(-) + +commit 26d1527d34d52b0f5d632d4fb636fb33d0867e92 +Author: Lasse Collin +Date: 2024-02-13 13:19:10 +0200 + + Tweak the expressions in AUTHORS. + + AUTHORS | 31 +++++++++++++++++++++++-------- + 1 file changed, 23 insertions(+), 8 deletions(-) + +commit d231d56580175fa040fdd3c6207a58243ce6217b +Author: Lasse Collin +Date: 2024-02-13 13:07:33 +0200 + + Translations: Add the man page translators into man page header comment. + + It looked odd to only have the original English authors listed + in the header comments of the translated files. + + po4a/.gitignore | 1 + + po4a/po4a.conf | 14 +++++++------- + po4a/update-po | 18 ++++++++++++++++++ + 3 files changed, 26 insertions(+), 7 deletions(-) + +commit 6d35fcb936474fca1acaebfd9502c097b6fde88e +Author: Lasse Collin +Date: 2024-02-12 17:09:10 +0200 + + Translations: Translate also messages of lzmainfo. + + lzmainfo has had translation support since 2009 at least but + it was never added to po/POTFILES.in so the messages weren't + translated. It's a very rarely needed tool so it's not too bad. + + This also adds src/xz/mytime.c to po/POTFILES.in although there + are no translatable strings. It's simpler this way so that it + won't be forgotten if strings were ever added to that file. + + po/POTFILES.in | 2 ++ + 1 file changed, 2 insertions(+) + +commit a9f369dd54b05f9ac4e00ead9d765d04fc259868 +Author: Lasse Collin +Date: 2024-02-12 17:09:10 +0200 + + Translations: Add custom .pot header with SPDX license identifier. + + The same is used for both po/xz.pot and po4a/xz-man.pot. + + Makefile.am | 1 + + po/xz.pot-header | 7 +++++++ + po4a/update-po | 8 ++++++++ + 3 files changed, 16 insertions(+) + +commit 469cd6653bb96e83c5cf1031c204d34566b15f44 +Author: Lasse Collin +Date: 2024-02-12 17:09:10 +0200 + + Translations: po4a/update-po: Add copyright notice to xz-man.pot. + + All man pages are under 0BSD now so this is simple now. + + po4a/update-po | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit 28ce45e38fbed4b5f54f2013e38dab47d22bf699 +Author: Lasse Collin +Date: 2024-02-12 17:09:10 +0200 + + Update COPYING about the man pages of the scripts. + + COPYING | 6 +++--- + 1 file changed, 3 insertions(+), 3 deletions(-) + +commit e48287bf51afd5184ea74de1dcade9e153f873f7 +Author: Lasse Collin +Date: 2024-02-12 17:09:10 +0200 + + xzdiff, xzgrep, and xzmore: Rewrite the man pages. + + The main reason is a kind of silly one: + + xz-man.pot contains strings from all man pages in XZ Utils. + The man pages of xzdiff, xzgrep, and xzmore were under GPLv2 + and the rest under 0BSD. Thus xz-man.pot contained strings + under two licences. po4a creates the translated man pages + from the combined 0BSD+GPLv2 xz-man.pot. + + I haven't liked this mixing in xz-man.pot but the + Translation Project requires that all man pages must be + in the same .pot file. So a separate xz-man-gpl.pot + wasn't an option. + + Since these man pages are short, rewriting them was quick enough. + Now xz-man.pot is entirely under 0BSD and marking the per-file + licenses is simpler. + + As a bonus, some wording hopefully is now slightly better + although it's perhaps a matter of taste. + + NOTE: In xzgrep.1, the EXIT STATUS section was written by me + in the commit d796b6d7fdb8b7238b277056cf9146cce25db604 so that's + why that section could be taken as is from the old xzgrep.1. + + src/scripts/xzdiff.1 | 94 ++++++++++++++++++++++++----------------- + src/scripts/xzgrep.1 | 116 ++++++++++++++++++++++++++++++++------------------- + src/scripts/xzmore.1 | 79 ++++++++++++++++++++--------------- + 3 files changed, 173 insertions(+), 116 deletions(-) + +commit 3e551b111b8ae8150f1a1040364dbafc034f22be +Author: Lasse Collin +Date: 2024-02-12 17:09:10 +0200 + + xzless: Update man page slightly. + + The xz tool can decompress three file formats and xzless + has always supported uncompressed files too. + + src/scripts/xzless.1 | 8 ++++---- + 1 file changed, 4 insertions(+), 4 deletions(-) + +commit 40f36da2262d13d6e1ba8449caa855512ae626d7 +Author: Lasse Collin +Date: 2024-02-12 17:09:10 +0200 + + Translations: Change po/Makevars to add a copyright notice to po/xz.pot. + + po/Makevars | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +commit 24192854e2ea5c06997431a98bda3c36c5da1497 +Author: Lasse Collin +Date: 2024-02-12 17:09:10 +0200 + + Translations: Update po/Makevars to use the template from gettext 0.22.4. + + Also add SPDX license identifier now that there is a known license. + + po/Makevars | 51 ++++++++++++++++++++++++++++++++++++++++++++++----- + 1 file changed, 46 insertions(+), 5 deletions(-) + +commit b94154957370116480b43bcabca25fc52deb9853 +Author: Lasse Collin +Date: 2024-02-12 17:09:10 +0200 + + liblzma: Include the SPDX license identifier 0BSD to generated files. + + Perhaps the generated files aren't even copyrightable but + using the same license for them as for the rest of the liblzma + keeps things more consistent for tools that look for license info. + + src/liblzma/check/crc32_table_be.h | 4 +++- + src/liblzma/check/crc32_table_le.h | 4 +++- + src/liblzma/check/crc32_tablegen.c | 16 ++++++++++------ + src/liblzma/check/crc64_table_be.h | 4 +++- + src/liblzma/check/crc64_table_le.h | 4 +++- + src/liblzma/check/crc64_tablegen.c | 8 +++++--- + src/liblzma/lz/lz_encoder_hash_table.h | 4 +++- + src/liblzma/lzma/fastpos_table.c | 4 +++- + src/liblzma/lzma/fastpos_tablegen.c | 12 +++++++----- + src/liblzma/rangecoder/price_table.c | 4 +++- + src/liblzma/rangecoder/price_tablegen.c | 12 +++++++----- + 11 files changed, 50 insertions(+), 26 deletions(-) + +commit 8e4ec794836bc1701d8c9bd5e347b8ce8cc5bbb4 +Author: Lasse Collin +Date: 2024-02-12 17:09:10 +0200 + + liblzma: Fix compilation of price_tablegen.c. + + It is built and run only manually so this didn't matter + unless one wanted to regenerate the price_table.c. + + src/liblzma/rangecoder/price_tablegen.c | 5 +++++ + src/liblzma/rangecoder/range_common.h | 5 ++++- + 2 files changed, 9 insertions(+), 1 deletion(-) + +commit e99bff3ffbcdf2634fd5bd13887627ec7dbfecaf +Author: Lasse Collin +Date: 2024-02-12 17:09:10 +0200 + + Add SPDX license identifiers to GPL, LGPL, and FSFULLR files. + + extra/scanlzma/scanlzma.c | 2 ++ + lib/Makefile.am | 2 ++ + lib/getopt-cdefs.h | 2 ++ + lib/getopt-core.h | 2 ++ + lib/getopt-ext.h | 2 ++ + lib/getopt-pfx-core.h | 2 ++ + lib/getopt-pfx-ext.h | 2 ++ + lib/getopt.c | 2 ++ + lib/getopt.in.h | 2 ++ + lib/getopt1.c | 2 ++ + lib/getopt_int.h | 2 ++ + m4/ax_pthread.m4 | 2 ++ + m4/getopt.m4 | 2 ++ + m4/posix-shell.m4 | 2 ++ + m4/visibility.m4 | 2 ++ + src/scripts/xzdiff.1 | 3 +-- + src/scripts/xzdiff.in | 1 + + src/scripts/xzgrep.1 | 3 +-- + src/scripts/xzgrep.in | 1 + + src/scripts/xzless.in | 1 + + src/scripts/xzmore.1 | 3 +-- + src/scripts/xzmore.in | 1 + + 22 files changed, 37 insertions(+), 6 deletions(-) + +commit 22af94128b89a131f5e58ae69bee5e50227c15da +Author: Lasse Collin +Date: 2024-02-12 17:09:10 +0200 + + Add SPDX license identifier into 0BSD source code files. + + .github/workflows/ci.yml | 2 ++ + .github/workflows/windows-ci.yml | 2 ++ + CMakeLists.txt | 2 ++ + Makefile.am | 3 +-- + autogen.sh | 1 + + build-aux/ci_build.sh | 3 ++- + build-aux/manconv.sh | 3 ++- + build-aux/version.sh | 3 ++- + cmake/remove-ordinals.cmake | 2 ++ + cmake/tuklib_common.cmake | 4 ++++ + cmake/tuklib_cpucores.cmake | 4 ++++ + cmake/tuklib_integer.cmake | 4 ++++ + cmake/tuklib_large_file_support.cmake | 4 ++++ + cmake/tuklib_mbstr.cmake | 4 ++++ + cmake/tuklib_physmem.cmake | 4 ++++ + cmake/tuklib_progname.cmake | 4 ++++ + configure.ac | 4 +++- + debug/Makefile.am | 3 +-- + debug/crc32.c | 2 ++ + debug/full_flush.c | 2 ++ + debug/hex2bin.c | 2 ++ + debug/known_sizes.c | 2 ++ + debug/memusage.c | 2 ++ + debug/repeat.c | 2 ++ + debug/sync_flush.c | 2 ++ + debug/translation.bash | 1 + + doc/examples/01_compress_easy.c | 2 ++ + doc/examples/02_decompress.c | 2 ++ + doc/examples/03_compress_custom.c | 2 ++ + doc/examples/04_compress_easy_mt.c | 2 ++ + doc/examples/11_file_info.c | 2 ++ + doc/examples/Makefile | 3 +-- + dos/Makefile | 2 ++ + dos/config.h | 2 ++ + doxygen/update-doxygen | 3 ++- + extra/7z2lzma/7z2lzma.bash | 3 ++- + m4/tuklib_common.m4 | 8 ++++++-- + m4/tuklib_cpucores.m4 | 8 ++++++-- + m4/tuklib_integer.m4 | 8 ++++++-- + m4/tuklib_mbstr.m4 | 8 ++++++-- + m4/tuklib_physmem.m4 | 8 ++++++-- + m4/tuklib_progname.m4 | 8 ++++++-- + po/POTFILES.in | 2 ++ + po4a/po4a.conf | 2 ++ + po4a/update-po | 3 ++- + src/Makefile.am | 3 +-- + src/common/common_w32res.rc | 2 ++ + src/common/mythread.h | 2 ++ + src/common/sysdefs.h | 2 ++ + src/common/tuklib_common.h | 2 ++ + src/common/tuklib_config.h | 2 ++ + src/common/tuklib_cpucores.c | 2 ++ + src/common/tuklib_cpucores.h | 2 ++ + src/common/tuklib_exit.c | 2 ++ + src/common/tuklib_exit.h | 2 ++ + src/common/tuklib_gettext.h | 2 ++ + src/common/tuklib_integer.h | 2 ++ + src/common/tuklib_mbstr.h | 2 ++ + src/common/tuklib_mbstr_fw.c | 2 ++ + src/common/tuklib_mbstr_width.c | 2 ++ + src/common/tuklib_open_stdxxx.c | 2 ++ + src/common/tuklib_open_stdxxx.h | 2 ++ + src/common/tuklib_physmem.c | 2 ++ + src/common/tuklib_physmem.h | 2 ++ + src/common/tuklib_progname.c | 2 ++ + src/common/tuklib_progname.h | 2 ++ + src/liblzma/Makefile.am | 3 +-- + src/liblzma/api/Makefile.am | 3 +-- + src/liblzma/api/lzma.h | 2 ++ + src/liblzma/api/lzma/base.h | 2 ++ + src/liblzma/api/lzma/bcj.h | 2 ++ + src/liblzma/api/lzma/block.h | 2 ++ + src/liblzma/api/lzma/check.h | 2 ++ + src/liblzma/api/lzma/container.h | 2 ++ + src/liblzma/api/lzma/delta.h | 2 ++ + src/liblzma/api/lzma/filter.h | 2 ++ + src/liblzma/api/lzma/hardware.h | 2 ++ + src/liblzma/api/lzma/index.h | 2 ++ + src/liblzma/api/lzma/index_hash.h | 2 ++ + src/liblzma/api/lzma/lzma12.h | 2 ++ + src/liblzma/api/lzma/stream_flags.h | 2 ++ + src/liblzma/api/lzma/version.h | 2 ++ + src/liblzma/api/lzma/vli.h | 2 ++ + src/liblzma/check/Makefile.inc | 4 ++-- + src/liblzma/check/check.c | 2 ++ + src/liblzma/check/check.h | 2 ++ + src/liblzma/check/crc32_arm64.h | 2 ++ + src/liblzma/check/crc32_fast.c | 2 ++ + src/liblzma/check/crc32_small.c | 2 ++ + src/liblzma/check/crc32_table.c | 2 ++ + src/liblzma/check/crc32_tablegen.c | 2 ++ + src/liblzma/check/crc32_x86.S | 2 ++ + src/liblzma/check/crc64_fast.c | 2 ++ + src/liblzma/check/crc64_small.c | 2 ++ + src/liblzma/check/crc64_table.c | 2 ++ + src/liblzma/check/crc64_tablegen.c | 2 ++ + src/liblzma/check/crc64_x86.S | 2 ++ + src/liblzma/check/crc_common.h | 2 ++ + src/liblzma/check/crc_x86_clmul.h | 2 ++ + src/liblzma/check/sha256.c | 2 ++ + src/liblzma/common/Makefile.inc | 3 +-- + src/liblzma/common/alone_decoder.c | 2 ++ + src/liblzma/common/alone_decoder.h | 2 ++ + src/liblzma/common/alone_encoder.c | 2 ++ + src/liblzma/common/auto_decoder.c | 2 ++ + src/liblzma/common/block_buffer_decoder.c | 2 ++ + src/liblzma/common/block_buffer_encoder.c | 2 ++ + src/liblzma/common/block_buffer_encoder.h | 2 ++ + src/liblzma/common/block_decoder.c | 2 ++ + src/liblzma/common/block_decoder.h | 2 ++ + src/liblzma/common/block_encoder.c | 2 ++ + src/liblzma/common/block_encoder.h | 2 ++ + src/liblzma/common/block_header_decoder.c | 2 ++ + src/liblzma/common/block_header_encoder.c | 2 ++ + src/liblzma/common/block_util.c | 2 ++ + src/liblzma/common/common.c | 2 ++ + src/liblzma/common/common.h | 2 ++ + src/liblzma/common/easy_buffer_encoder.c | 2 ++ + src/liblzma/common/easy_decoder_memusage.c | 2 ++ + src/liblzma/common/easy_encoder.c | 2 ++ + src/liblzma/common/easy_encoder_memusage.c | 2 ++ + src/liblzma/common/easy_preset.c | 2 ++ + src/liblzma/common/easy_preset.h | 2 ++ + src/liblzma/common/file_info.c | 2 ++ + src/liblzma/common/filter_buffer_decoder.c | 2 ++ + src/liblzma/common/filter_buffer_encoder.c | 2 ++ + src/liblzma/common/filter_common.c | 2 ++ + src/liblzma/common/filter_common.h | 2 ++ + src/liblzma/common/filter_decoder.c | 2 ++ + src/liblzma/common/filter_decoder.h | 2 ++ + src/liblzma/common/filter_encoder.c | 2 ++ + src/liblzma/common/filter_encoder.h | 2 ++ + src/liblzma/common/filter_flags_decoder.c | 2 ++ + src/liblzma/common/filter_flags_encoder.c | 2 ++ + src/liblzma/common/hardware_cputhreads.c | 2 ++ + src/liblzma/common/hardware_physmem.c | 2 ++ + src/liblzma/common/index.c | 2 ++ + src/liblzma/common/index.h | 2 ++ + src/liblzma/common/index_decoder.c | 2 ++ + src/liblzma/common/index_decoder.h | 2 ++ + src/liblzma/common/index_encoder.c | 2 ++ + src/liblzma/common/index_encoder.h | 2 ++ + src/liblzma/common/index_hash.c | 2 ++ + src/liblzma/common/lzip_decoder.c | 2 ++ + src/liblzma/common/lzip_decoder.h | 2 ++ + src/liblzma/common/memcmplen.h | 2 ++ + src/liblzma/common/microlzma_decoder.c | 2 ++ + src/liblzma/common/microlzma_encoder.c | 2 ++ + src/liblzma/common/outqueue.c | 2 ++ + src/liblzma/common/outqueue.h | 2 ++ + src/liblzma/common/stream_buffer_decoder.c | 2 ++ + src/liblzma/common/stream_buffer_encoder.c | 2 ++ + src/liblzma/common/stream_decoder.c | 2 ++ + src/liblzma/common/stream_decoder.h | 2 ++ + src/liblzma/common/stream_decoder_mt.c | 2 ++ + src/liblzma/common/stream_encoder.c | 2 ++ + src/liblzma/common/stream_encoder_mt.c | 2 ++ + src/liblzma/common/stream_flags_common.c | 2 ++ + src/liblzma/common/stream_flags_common.h | 2 ++ + src/liblzma/common/stream_flags_decoder.c | 2 ++ + src/liblzma/common/stream_flags_encoder.c | 2 ++ + src/liblzma/common/string_conversion.c | 2 ++ + src/liblzma/common/vli_decoder.c | 2 ++ + src/liblzma/common/vli_encoder.c | 2 ++ + src/liblzma/common/vli_size.c | 2 ++ + src/liblzma/delta/Makefile.inc | 3 +-- + src/liblzma/delta/delta_common.c | 2 ++ + src/liblzma/delta/delta_common.h | 2 ++ + src/liblzma/delta/delta_decoder.c | 2 ++ + src/liblzma/delta/delta_decoder.h | 2 ++ + src/liblzma/delta/delta_encoder.c | 2 ++ + src/liblzma/delta/delta_encoder.h | 2 ++ + src/liblzma/delta/delta_private.h | 2 ++ + src/liblzma/liblzma.pc.in | 3 +-- + src/liblzma/liblzma_generic.map | 2 ++ + src/liblzma/liblzma_linux.map | 2 ++ + src/liblzma/liblzma_w32res.rc | 2 ++ + src/liblzma/lz/Makefile.inc | 3 +-- + src/liblzma/lz/lz_decoder.c | 2 ++ + src/liblzma/lz/lz_decoder.h | 2 ++ + src/liblzma/lz/lz_encoder.c | 2 ++ + src/liblzma/lz/lz_encoder.h | 2 ++ + src/liblzma/lz/lz_encoder_hash.h | 2 ++ + src/liblzma/lz/lz_encoder_mf.c | 2 ++ + src/liblzma/lzma/Makefile.inc | 3 +-- + src/liblzma/lzma/fastpos.h | 2 ++ + src/liblzma/lzma/fastpos_tablegen.c | 2 ++ + src/liblzma/lzma/lzma2_decoder.c | 2 ++ + src/liblzma/lzma/lzma2_decoder.h | 2 ++ + src/liblzma/lzma/lzma2_encoder.c | 2 ++ + src/liblzma/lzma/lzma2_encoder.h | 2 ++ + src/liblzma/lzma/lzma_common.h | 2 ++ + src/liblzma/lzma/lzma_decoder.c | 2 ++ + src/liblzma/lzma/lzma_decoder.h | 2 ++ + src/liblzma/lzma/lzma_encoder.c | 2 ++ + src/liblzma/lzma/lzma_encoder.h | 2 ++ + src/liblzma/lzma/lzma_encoder_optimum_fast.c | 2 ++ + src/liblzma/lzma/lzma_encoder_optimum_normal.c | 2 ++ + src/liblzma/lzma/lzma_encoder_presets.c | 2 ++ + src/liblzma/lzma/lzma_encoder_private.h | 2 ++ + src/liblzma/rangecoder/Makefile.inc | 3 +-- + src/liblzma/rangecoder/price.h | 2 ++ + src/liblzma/rangecoder/price_tablegen.c | 2 ++ + src/liblzma/rangecoder/range_common.h | 2 ++ + src/liblzma/rangecoder/range_decoder.h | 2 ++ + src/liblzma/rangecoder/range_encoder.h | 2 ++ + src/liblzma/simple/Makefile.inc | 3 +-- + src/liblzma/simple/arm.c | 2 ++ + src/liblzma/simple/arm64.c | 2 ++ + src/liblzma/simple/armthumb.c | 2 ++ + src/liblzma/simple/ia64.c | 2 ++ + src/liblzma/simple/powerpc.c | 2 ++ + src/liblzma/simple/riscv.c | 2 ++ + src/liblzma/simple/simple_coder.c | 2 ++ + src/liblzma/simple/simple_coder.h | 2 ++ + src/liblzma/simple/simple_decoder.c | 2 ++ + src/liblzma/simple/simple_decoder.h | 2 ++ + src/liblzma/simple/simple_encoder.c | 2 ++ + src/liblzma/simple/simple_encoder.h | 2 ++ + src/liblzma/simple/simple_private.h | 2 ++ + src/liblzma/simple/sparc.c | 2 ++ + src/liblzma/simple/x86.c | 2 ++ + src/liblzma/validate_map.sh | 1 + + src/lzmainfo/Makefile.am | 3 +-- + src/lzmainfo/lzmainfo.c | 2 ++ + src/lzmainfo/lzmainfo_w32res.rc | 2 ++ + src/scripts/Makefile.am | 3 +-- + src/xz/Makefile.am | 3 +-- + src/xz/args.c | 2 ++ + src/xz/args.h | 2 ++ + src/xz/coder.c | 2 ++ + src/xz/coder.h | 2 ++ + src/xz/file_io.c | 2 ++ + src/xz/file_io.h | 2 ++ + src/xz/hardware.c | 2 ++ + src/xz/hardware.h | 2 ++ + src/xz/list.c | 2 ++ + src/xz/list.h | 2 ++ + src/xz/main.c | 2 ++ + src/xz/main.h | 2 ++ + src/xz/message.c | 2 ++ + src/xz/message.h | 2 ++ + src/xz/mytime.c | 2 ++ + src/xz/mytime.h | 2 ++ + src/xz/options.c | 2 ++ + src/xz/options.h | 2 ++ + src/xz/private.h | 2 ++ + src/xz/signals.c | 2 ++ + src/xz/signals.h | 2 ++ + src/xz/suffix.c | 2 ++ + src/xz/suffix.h | 2 ++ + src/xz/util.c | 2 ++ + src/xz/util.h | 2 ++ + src/xz/xz_w32res.rc | 2 ++ + src/xzdec/Makefile.am | 3 +-- + src/xzdec/lzmadec_w32res.rc | 2 ++ + src/xzdec/xzdec.c | 2 ++ + src/xzdec/xzdec_w32res.rc | 2 ++ + tests/Makefile.am | 3 +-- + tests/bcj_test.c | 2 ++ + tests/code_coverage.sh | 1 + + tests/create_compress_files.c | 2 ++ + tests/ossfuzz/fuzz_common.h | 2 ++ + tests/ossfuzz/fuzz_decode_alone.c | 2 ++ + tests/ossfuzz/fuzz_decode_stream.c | 2 ++ + tests/ossfuzz/fuzz_encode_stream.c | 2 ++ + tests/test_bcj_exact_size.c | 2 ++ + tests/test_block_header.c | 2 ++ + tests/test_check.c | 2 ++ + tests/test_compress.sh | 1 + + tests/test_compress_generated_abc | 1 + + tests/test_compress_generated_random | 1 + + tests/test_compress_generated_text | 1 + + tests/test_compress_prepared_bcj_sparc | 1 + + tests/test_compress_prepared_bcj_x86 | 1 + + tests/test_files.sh | 1 + + tests/test_filter_flags.c | 2 ++ + tests/test_filter_str.c | 2 ++ + tests/test_hardware.c | 2 ++ + tests/test_index.c | 2 ++ + tests/test_index_hash.c | 2 ++ + tests/test_lzip_decoder.c | 2 ++ + tests/test_memlimit.c | 2 ++ + tests/test_scripts.sh | 1 + + tests/test_stream_flags.c | 2 ++ + tests/test_suffix.sh | 1 + + tests/test_vli.c | 2 ++ + tests/tests.h | 2 ++ + tests/tuktest.h | 2 ++ + windows/build.bash | 3 ++- + 290 files changed, 588 insertions(+), 58 deletions(-) + +commit 23de53421ea258cde6a3c33a038b1e9d08f771d1 +Author: Lasse Collin +Date: 2024-02-12 23:25:54 +0200 + + liblzma: Sync the AUTHORS fix about SHA-256 to lzma.h. + + src/liblzma/api/lzma.h | 10 ++++------ + 1 file changed, 4 insertions(+), 6 deletions(-) + +commit 689e0228baeb95232430e90d628379db89583d71 +Author: Lasse Collin +Date: 2024-02-12 17:09:10 +0200 + + Change most public domain parts to 0BSD. + + Translations and doc/xz-file-format.txt and doc/lzma-file-format.txt + were not touched. + + COPYING.0BSD was added. + + .github/workflows/ci.yml | 3 - + .github/workflows/windows-ci.yml | 3 - + CMakeLists.txt | 3 - + COPYING | 112 ++++++++++++++----------- + COPYING.0BSD | 11 +++ + Makefile.am | 3 - + PACKAGERS | 11 +-- + autogen.sh | 3 - + build-aux/ci_build.sh | 3 - + build-aux/manconv.sh | 3 - + build-aux/version.sh | 3 - + cmake/remove-ordinals.cmake | 3 - + cmake/tuklib_common.cmake | 3 - + cmake/tuklib_cpucores.cmake | 3 - + cmake/tuklib_integer.cmake | 3 - + cmake/tuklib_large_file_support.cmake | 3 - + cmake/tuklib_mbstr.cmake | 3 - + cmake/tuklib_physmem.cmake | 3 - + cmake/tuklib_progname.cmake | 3 - + configure.ac | 3 - + debug/Makefile.am | 3 - + debug/crc32.c | 3 - + debug/full_flush.c | 3 - + debug/hex2bin.c | 3 - + debug/known_sizes.c | 3 - + debug/memusage.c | 3 - + debug/repeat.c | 3 - + debug/sync_flush.c | 3 - + debug/translation.bash | 3 - + doc/examples/01_compress_easy.c | 3 - + doc/examples/02_decompress.c | 3 - + doc/examples/03_compress_custom.c | 3 - + doc/examples/04_compress_easy_mt.c | 3 - + doc/examples/11_file_info.c | 3 - + doc/examples/Makefile | 3 - + dos/Makefile | 3 - + doxygen/update-doxygen | 3 - + extra/7z2lzma/7z2lzma.bash | 3 - + m4/tuklib_common.m4 | 3 - + m4/tuklib_cpucores.m4 | 3 - + m4/tuklib_integer.m4 | 3 - + m4/tuklib_mbstr.m4 | 3 - + m4/tuklib_physmem.m4 | 3 - + m4/tuklib_progname.m4 | 3 - + po4a/update-po | 3 - + src/Makefile.am | 3 - + src/common/common_w32res.rc | 3 - + src/common/mythread.h | 3 - + src/common/sysdefs.h | 3 - + src/common/tuklib_common.h | 3 - + src/common/tuklib_cpucores.c | 3 - + src/common/tuklib_cpucores.h | 3 - + src/common/tuklib_exit.c | 3 - + src/common/tuklib_exit.h | 3 - + src/common/tuklib_gettext.h | 3 - + src/common/tuklib_integer.h | 3 - + src/common/tuklib_mbstr.h | 3 - + src/common/tuklib_mbstr_fw.c | 3 - + src/common/tuklib_mbstr_width.c | 3 - + src/common/tuklib_open_stdxxx.c | 3 - + src/common/tuklib_open_stdxxx.h | 3 - + src/common/tuklib_physmem.c | 3 - + src/common/tuklib_physmem.h | 3 - + src/common/tuklib_progname.c | 3 - + src/common/tuklib_progname.h | 3 - + src/liblzma/Makefile.am | 3 - + src/liblzma/api/Makefile.am | 3 - + src/liblzma/api/lzma.h | 13 ++- + src/liblzma/api/lzma/base.h | 3 - + src/liblzma/api/lzma/bcj.h | 3 - + src/liblzma/api/lzma/block.h | 3 - + src/liblzma/api/lzma/check.h | 3 - + src/liblzma/api/lzma/container.h | 3 - + src/liblzma/api/lzma/delta.h | 3 - + src/liblzma/api/lzma/filter.h | 3 - + src/liblzma/api/lzma/hardware.h | 3 - + src/liblzma/api/lzma/index.h | 3 - + src/liblzma/api/lzma/index_hash.h | 3 - + src/liblzma/api/lzma/lzma12.h | 3 - + src/liblzma/api/lzma/stream_flags.h | 3 - + src/liblzma/api/lzma/version.h | 3 - + src/liblzma/api/lzma/vli.h | 3 - + src/liblzma/check/Makefile.inc | 3 - + src/liblzma/check/check.c | 3 - + src/liblzma/check/check.h | 3 - + src/liblzma/check/crc32_arm64.h | 3 - + src/liblzma/check/crc32_fast.c | 3 - + src/liblzma/check/crc32_small.c | 3 - + src/liblzma/check/crc32_table.c | 3 - + src/liblzma/check/crc32_tablegen.c | 3 - + src/liblzma/check/crc32_x86.S | 3 - + src/liblzma/check/crc64_fast.c | 3 - + src/liblzma/check/crc64_small.c | 3 - + src/liblzma/check/crc64_table.c | 3 - + src/liblzma/check/crc64_tablegen.c | 3 - + src/liblzma/check/crc64_x86.S | 3 - + src/liblzma/check/crc_common.h | 3 - + src/liblzma/check/crc_x86_clmul.h | 3 - + src/liblzma/check/sha256.c | 3 - + src/liblzma/common/Makefile.inc | 3 - + src/liblzma/common/alone_decoder.c | 3 - + src/liblzma/common/alone_decoder.h | 3 - + src/liblzma/common/alone_encoder.c | 3 - + src/liblzma/common/auto_decoder.c | 3 - + src/liblzma/common/block_buffer_decoder.c | 3 - + src/liblzma/common/block_buffer_encoder.c | 3 - + src/liblzma/common/block_buffer_encoder.h | 3 - + src/liblzma/common/block_decoder.c | 3 - + src/liblzma/common/block_decoder.h | 3 - + src/liblzma/common/block_encoder.c | 3 - + src/liblzma/common/block_encoder.h | 3 - + src/liblzma/common/block_header_decoder.c | 3 - + src/liblzma/common/block_header_encoder.c | 3 - + src/liblzma/common/block_util.c | 3 - + src/liblzma/common/common.c | 3 - + src/liblzma/common/common.h | 3 - + src/liblzma/common/easy_buffer_encoder.c | 3 - + src/liblzma/common/easy_decoder_memusage.c | 3 - + src/liblzma/common/easy_encoder.c | 3 - + src/liblzma/common/easy_encoder_memusage.c | 3 - + src/liblzma/common/easy_preset.c | 3 - + src/liblzma/common/easy_preset.h | 3 - + src/liblzma/common/file_info.c | 3 - + src/liblzma/common/filter_buffer_decoder.c | 3 - + src/liblzma/common/filter_buffer_encoder.c | 3 - + src/liblzma/common/filter_common.c | 3 - + src/liblzma/common/filter_common.h | 3 - + src/liblzma/common/filter_decoder.c | 3 - + src/liblzma/common/filter_decoder.h | 3 - + src/liblzma/common/filter_encoder.c | 3 - + src/liblzma/common/filter_encoder.h | 3 - + src/liblzma/common/filter_flags_decoder.c | 3 - + src/liblzma/common/filter_flags_encoder.c | 3 - + src/liblzma/common/hardware_cputhreads.c | 3 - + src/liblzma/common/hardware_physmem.c | 3 - + src/liblzma/common/index.c | 3 - + src/liblzma/common/index.h | 3 - + src/liblzma/common/index_decoder.c | 3 - + src/liblzma/common/index_decoder.h | 3 - + src/liblzma/common/index_encoder.c | 3 - + src/liblzma/common/index_encoder.h | 3 - + src/liblzma/common/index_hash.c | 3 - + src/liblzma/common/lzip_decoder.c | 3 - + src/liblzma/common/lzip_decoder.h | 3 - + src/liblzma/common/memcmplen.h | 3 - + src/liblzma/common/microlzma_decoder.c | 3 - + src/liblzma/common/microlzma_encoder.c | 3 - + src/liblzma/common/outqueue.c | 3 - + src/liblzma/common/outqueue.h | 3 - + src/liblzma/common/stream_buffer_decoder.c | 3 - + src/liblzma/common/stream_buffer_encoder.c | 3 - + src/liblzma/common/stream_decoder.c | 3 - + src/liblzma/common/stream_decoder.h | 3 - + src/liblzma/common/stream_decoder_mt.c | 3 - + src/liblzma/common/stream_encoder.c | 3 - + src/liblzma/common/stream_encoder_mt.c | 3 - + src/liblzma/common/stream_flags_common.c | 3 - + src/liblzma/common/stream_flags_common.h | 3 - + src/liblzma/common/stream_flags_decoder.c | 3 - + src/liblzma/common/stream_flags_encoder.c | 3 - + src/liblzma/common/string_conversion.c | 3 - + src/liblzma/common/vli_decoder.c | 3 - + src/liblzma/common/vli_encoder.c | 3 - + src/liblzma/common/vli_size.c | 3 - + src/liblzma/delta/Makefile.inc | 3 - + src/liblzma/delta/delta_common.c | 3 - + src/liblzma/delta/delta_common.h | 3 - + src/liblzma/delta/delta_decoder.c | 3 - + src/liblzma/delta/delta_decoder.h | 3 - + src/liblzma/delta/delta_encoder.c | 3 - + src/liblzma/delta/delta_encoder.h | 3 - + src/liblzma/delta/delta_private.h | 3 - + src/liblzma/liblzma.pc.in | 3 - + src/liblzma/liblzma_w32res.rc | 3 - + src/liblzma/lz/Makefile.inc | 3 - + src/liblzma/lz/lz_decoder.c | 3 - + src/liblzma/lz/lz_decoder.h | 3 - + src/liblzma/lz/lz_encoder.c | 3 - + src/liblzma/lz/lz_encoder.h | 3 - + src/liblzma/lz/lz_encoder_hash.h | 3 - + src/liblzma/lz/lz_encoder_mf.c | 3 - + src/liblzma/lzma/Makefile.inc | 3 - + src/liblzma/lzma/fastpos.h | 3 - + src/liblzma/lzma/fastpos_tablegen.c | 3 - + src/liblzma/lzma/lzma2_decoder.c | 3 - + src/liblzma/lzma/lzma2_decoder.h | 3 - + src/liblzma/lzma/lzma2_encoder.c | 3 - + src/liblzma/lzma/lzma2_encoder.h | 3 - + src/liblzma/lzma/lzma_common.h | 3 - + src/liblzma/lzma/lzma_decoder.c | 3 - + src/liblzma/lzma/lzma_decoder.h | 3 - + src/liblzma/lzma/lzma_encoder.c | 3 - + src/liblzma/lzma/lzma_encoder.h | 3 - + src/liblzma/lzma/lzma_encoder_optimum_fast.c | 3 - + src/liblzma/lzma/lzma_encoder_optimum_normal.c | 3 - + src/liblzma/lzma/lzma_encoder_presets.c | 3 - + src/liblzma/lzma/lzma_encoder_private.h | 3 - + src/liblzma/rangecoder/Makefile.inc | 3 - + src/liblzma/rangecoder/price.h | 3 - + src/liblzma/rangecoder/price_tablegen.c | 3 - + src/liblzma/rangecoder/range_common.h | 3 - + src/liblzma/rangecoder/range_decoder.h | 3 - + src/liblzma/rangecoder/range_encoder.h | 3 - + src/liblzma/simple/Makefile.inc | 3 - + src/liblzma/simple/arm.c | 3 - + src/liblzma/simple/arm64.c | 3 - + src/liblzma/simple/armthumb.c | 3 - + src/liblzma/simple/ia64.c | 3 - + src/liblzma/simple/powerpc.c | 3 - + src/liblzma/simple/riscv.c | 3 - + src/liblzma/simple/simple_coder.c | 3 - + src/liblzma/simple/simple_coder.h | 3 - + src/liblzma/simple/simple_decoder.c | 3 - + src/liblzma/simple/simple_decoder.h | 3 - + src/liblzma/simple/simple_encoder.c | 3 - + src/liblzma/simple/simple_encoder.h | 3 - + src/liblzma/simple/simple_private.h | 3 - + src/liblzma/simple/sparc.c | 3 - + src/liblzma/simple/x86.c | 3 - + src/liblzma/validate_map.sh | 3 - + src/lzmainfo/Makefile.am | 3 - + src/lzmainfo/lzmainfo.1 | 4 +- + src/lzmainfo/lzmainfo.c | 3 - + src/lzmainfo/lzmainfo_w32res.rc | 3 - + src/scripts/Makefile.am | 3 - + src/scripts/xzless.1 | 4 +- + src/xz/Makefile.am | 3 - + src/xz/args.c | 3 - + src/xz/args.h | 3 - + src/xz/coder.c | 3 - + src/xz/coder.h | 3 - + src/xz/file_io.c | 3 - + src/xz/file_io.h | 3 - + src/xz/hardware.c | 3 - + src/xz/hardware.h | 3 - + src/xz/list.c | 3 - + src/xz/list.h | 3 - + src/xz/main.c | 3 - + src/xz/main.h | 3 - + src/xz/message.c | 3 - + src/xz/message.h | 3 - + src/xz/mytime.c | 3 - + src/xz/mytime.h | 3 - + src/xz/options.c | 3 - + src/xz/options.h | 3 - + src/xz/private.h | 3 - + src/xz/signals.c | 3 - + src/xz/signals.h | 3 - + src/xz/suffix.c | 3 - + src/xz/suffix.h | 3 - + src/xz/util.c | 3 - + src/xz/util.h | 3 - + src/xz/xz.1 | 4 +- + src/xz/xz_w32res.rc | 3 - + src/xzdec/Makefile.am | 3 - + src/xzdec/lzmadec_w32res.rc | 3 - + src/xzdec/xzdec.1 | 4 +- + src/xzdec/xzdec.c | 3 - + src/xzdec/xzdec_w32res.rc | 3 - + tests/Makefile.am | 3 - + tests/bcj_test.c | 3 - + tests/code_coverage.sh | 3 - + tests/create_compress_files.c | 3 - + tests/files/README | 3 +- + tests/ossfuzz/fuzz_common.h | 3 - + tests/ossfuzz/fuzz_decode_alone.c | 3 - + tests/ossfuzz/fuzz_decode_stream.c | 3 - + tests/ossfuzz/fuzz_encode_stream.c | 3 - + tests/test_bcj_exact_size.c | 3 - + tests/test_block_header.c | 3 - + tests/test_check.c | 3 - + tests/test_compress.sh | 3 - + tests/test_files.sh | 3 - + tests/test_filter_flags.c | 3 - + tests/test_filter_str.c | 3 - + tests/test_hardware.c | 3 - + tests/test_index.c | 3 - + tests/test_index_hash.c | 3 - + tests/test_lzip_decoder.c | 3 - + tests/test_memlimit.c | 3 - + tests/test_scripts.sh | 3 - + tests/test_stream_flags.c | 3 - + tests/test_suffix.sh | 3 - + tests/test_vli.c | 3 - + tests/tests.h | 3 - + tests/tuktest.h | 3 - + windows/README-Windows.txt | 11 +-- + windows/build.bash | 3 - + 288 files changed, 100 insertions(+), 911 deletions(-) + +commit 76946dc4336c831fe2cc26696a035d807dd3cf13 +Author: Lasse Collin +Date: 2024-02-09 17:20:31 +0200 + + Fix SHA-256 authors. + + The initial commit 5d018dc03549c1ee4958364712fb0c94e1bf2741 + in 2007 had a comment in sha256.c that the code is based on + Crypto++ Library 5.5.1. In 2009 the Authors list in sha256.c + and the AUTHORS file was updated with information that the + code had come from Crypto++ but via 7-Zip. I know I had viewed + 7-Zip's SHA-256 code but back then the C code has been identical + enough with Crypto++, so I don't why I thought the author info + would need that extra step via 7-Zip for this single file. + + Another error is that I had mixed sha.* and shacal2.* files + when checking for author info in Crypto++. The shacal2.* files + aren't related to liblzma's sha256.c and thus Kevin Springle's + code in Crypto++ isn't either. + + AUTHORS | 6 ++---- + src/liblzma/check/sha256.c | 14 ++++---------- + 2 files changed, 6 insertions(+), 14 deletions(-) + +commit 21d9cbae9eecca28ce373d3d9464defd2cf5d851 +Author: Lasse Collin +Date: 2024-02-09 17:20:31 +0200 + + Remove macosx/build.sh. + + It was last updated in 2013. + + Makefile.am | 1 - + macosx/build.sh | 113 -------------------------------------------------------- + 2 files changed, 114 deletions(-) + +commit eac2c3c67f9113a225fb6667df862edd30366931 +Author: Lasse Collin +Date: 2024-02-09 17:20:31 +0200 + + Doc: Remove doc/examples_old. + + It was good to keep these around in parallel with the newer examples + but I think it's OK to remove the old ones at this point. + + Makefile.am | 5 -- + doc/examples_old/xz_pipe_comp.c | 127 -------------------------------------- + doc/examples_old/xz_pipe_decomp.c | 123 ------------------------------------ + 3 files changed, 255 deletions(-) + +commit 89ea1a22f4ed3685b053b7260bc5acf6c75d1664 +Author: Jia Tan +Date: 2024-02-13 22:38:58 +0800 + + Tests: Add RISC-V filter support in a few places. + + tests/test_filter_flags.c | 6 ++++++ + tests/test_filter_str.c | 6 ++++++ + 2 files changed, 12 insertions(+) + +commit 45663443eb2b377e6171529380fee312f1adcdf4 +Author: Jia Tan +Date: 2024-02-13 22:37:07 +0800 + + liblzma: Fix build error if only RISC-V BCJ filter is enabled. + + If any other BCJ filter was enabled for encoding or decoding, then this + was not a problem. + + src/liblzma/common/string_conversion.c | 4 +++- + 1 file changed, 3 insertions(+), 1 deletion(-) + +commit 2f15597d677bc35743c777d4cf3bfa698b478681 +Author: Jia Tan +Date: 2024-02-13 22:56:24 +0800 + + Translations: Update the Korean translation. + + po/ko.po | 526 ++++++++++++++++++++++++++++++++++----------------------------- + 1 file changed, 284 insertions(+), 242 deletions(-) + +commit df873143ad1615c6d6aaa1bf8808b1676091dfe3 +Author: Jia Tan +Date: 2024-02-13 01:55:53 +0800 + + Translations: Update the Korean man page translations. + + po4a/ko.po | 1375 ++++++++++++++++++++++++++++++++++-------------------------- + 1 file changed, 770 insertions(+), 605 deletions(-) + +commit b3f415eddb150341865a1af47959c3baba076b33 +Author: Jia Tan +Date: 2024-02-13 01:53:33 +0800 + + Translations: Update the Chinese (simplified) translation. + + po/zh_CN.po | 424 ++++++++++++++++++++++++++++++++++++++---------------------- + 1 file changed, 268 insertions(+), 156 deletions(-) + +commit 9860d418d296eb3c721e5384fb367c0499b579c8 +Author: Lasse Collin +Date: 2024-02-09 23:21:01 +0200 + + xzless: Use ||- in LESSOPEN with with "less" 451 and newer. + + src/scripts/xzless.in | 9 ++++++++- + 1 file changed, 8 insertions(+), 1 deletion(-) + +commit fd0692b0525e6c26b496492be9e2c865cab734f8 +Author: Lasse Collin +Date: 2024-02-09 23:00:05 +0200 + + xzless: Use --show-preproc-errors with "less" 632 and newer. + + This makes "less" show a warning if a decompression error occurred. + + src/scripts/xzless.in | 11 +++++++++-- + 1 file changed, 9 insertions(+), 2 deletions(-) + +commit adb073da76a920b5a81e6b32254f4ddb054dc57a +Author: Jia Tan +Date: 2024-02-09 23:59:54 +0800 + + liblzma: Fix typo discovered by codespell. + + src/liblzma/check/crc32_arm64.h | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit 55d9fc883d221cbace951a370f1fb144698f8c2e +Author: Jia Tan +Date: 2024-02-09 20:01:06 +0800 + + Translations: Update the Swedish translation. + + po/sv.po | 420 ++++++++++++++++++++++++++++++++++++++------------------------- + 1 file changed, 254 insertions(+), 166 deletions(-) + +commit 55ba4a1ea321499c805eedfa811ffde690bae311 +Author: Jia Tan +Date: 2024-02-08 20:09:04 +0800 + + Translations: Update the Spanish translation. + + po/es.po | 22 +++++++++++----------- + 1 file changed, 11 insertions(+), 11 deletions(-) + +commit 7f2293cd804a89d3c3b2d3ed573560ca9e1520ae +Author: Jia Tan +Date: 2024-02-07 21:34:35 +0800 + + Translations: Update the Spanish translation. + + po/es.po | 419 ++++++++++++++++++++++++++++++++++++++------------------------- + 1 file changed, 253 insertions(+), 166 deletions(-) + +commit f4af2036bc625739d6d33d9e1fede583a25c3828 +Author: Jia Tan +Date: 2024-02-07 21:28:32 +0800 + + Translations: Update the Polish translation. + + po/pl.po | 411 ++++++++++++++++++++++++++++++++++++++------------------------- + 1 file changed, 249 insertions(+), 162 deletions(-) + +commit e5e93bb816043c559cddf03a3b7ba13bec353ee4 +Author: Jia Tan +Date: 2024-02-07 19:40:12 +0800 + + Translations: Update the German translation. + + po/de.po | 396 ++++++++++++++++++++++++++++++++++++++------------------------- + 1 file changed, 242 insertions(+), 154 deletions(-) + +commit 28f18ff8e26902762fb007c13be235b4ac1ac071 +Author: Jia Tan +Date: 2024-02-07 19:27:25 +0800 + + Translations: Update the German man page translations. + + po4a/de.po | 1353 +++++++++++++++++++++++++++++++++--------------------------- + 1 file changed, 752 insertions(+), 601 deletions(-) + +commit cabfbc7947da05aa5dfe39bec9759e076f940e3c +Author: Jia Tan +Date: 2024-02-06 23:44:06 +0800 + + Translations: Update the Romanian translation. + + po/ro.po | 416 ++++++++++++++++++++++++++++++++++++++------------------------- + 1 file changed, 252 insertions(+), 164 deletions(-) + +commit bf20c94f5d748cea2147779f4fa7e2fd2eb8555e +Author: Jia Tan +Date: 2024-02-06 23:45:02 +0800 + + Translations: Update the Romanian man page translations. + + po4a/ro.po | 1759 +++++++++++++++++++++++++++++++++--------------------------- + 1 file changed, 966 insertions(+), 793 deletions(-) + +commit 7c25ec9feb0241e4affb7432681cc4f5696f3a96 +Author: Jia Tan +Date: 2024-02-07 20:56:57 +0800 + + Translations: Update the Ukrainian translation. + + po/uk.po | 397 ++++++++++++++++++++++++++++++++++++++------------------------- + 1 file changed, 242 insertions(+), 155 deletions(-) + +commit b3523250e9eef10b017473754c1e1c9e31f10374 +Author: Jia Tan +Date: 2024-02-06 23:30:03 +0800 + + Translations: Update the Ukrainian man page translations. + + po4a/uk.po | 1363 ++++++++++++++++++++++++++++++++++-------------------------- + 1 file changed, 764 insertions(+), 599 deletions(-) + +commit a5c177f514f4c90e0d2f6045636fca6c2e80a20d +Author: Jia Tan +Date: 2024-02-02 01:39:28 +0800 + + Update AUTHORS. + + AUTHORS | 3 ++- + 1 file changed, 2 insertions(+), 1 deletion(-) + +commit 7f68a68c19d0ae57bd0e802be0ea8f974e41299f +Author: Jia Tan +Date: 2024-02-02 01:38:51 +0800 + + liblzma: Update Authors list in crc32_arm64.h. + + src/liblzma/check/crc32_arm64.h | 1 + + 1 file changed, 1 insertion(+) + +commit 97f9ba50b84e67b3dcb5b17dd5d3e1d14f9ad1d0 +Author: Jia Tan +Date: 2024-02-01 16:07:03 +0800 + + liblzma: Check HAVE_USABLE_CLMUL before omitting CRC32 table. + + This was split from the prior commit so it could be easily applied to + the 5.4 branch. + + Closes: https://github.com/tukaani-project/xz/pull/77 + + src/liblzma/check/crc32_table.c | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +commit ca9015f4dead2c97b48f5a6933631b0a448b65b9 +Author: Jia Tan +Date: 2024-02-01 16:06:29 +0800 + + liblzma: Check HAVE_USABLE_CLMUL before omitting CRC64 table. + + If liblzma is configured with --disable-clmul-crc + CFLAGS="-msse4.1 -mpclmul", then it will fail to compile because the + generic version must be used but the CRC tables were not included. + + src/liblzma/check/crc64_table.c | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +commit 2f1552a91c825e87013925e1a67a0930e7aef592 +Author: Jia Tan +Date: 2024-01-23 18:02:13 +0800 + + liblzma: Only use ifunc in crcXX_fast.c if its needed. + + The code was using HAVE_FUNC_ATTRIBUTE_IFUNC instead of CRC_USE_IFUNC. + With ARM64, ifunc is incompatible because it requires non-inline + function calls for runtime detection. + + src/liblzma/check/crc32_fast.c | 6 +++--- + src/liblzma/check/crc64_fast.c | 6 +++--- + 2 files changed, 6 insertions(+), 6 deletions(-) + +commit 30a25f3742287697bc57a1bef86c19ecf5129322 +Author: Jia Tan +Date: 2024-01-22 22:08:45 +0800 + + Docs: Add --disable-arm64-crc32 description to INSTALL. + + INSTALL | 12 +++++++++++- + 1 file changed, 11 insertions(+), 1 deletion(-) + +commit 1940f0ec28f08c0ac72c1413d9706fb82eabe6ad +Author: Jia Tan +Date: 2024-01-22 21:36:09 +0800 + + liblzma: Omit CRC tables when not needed with ARM64 optimizations. + + This is similar to the existing x86-64 CLMUL conditions to omit the + tables. They were slightly refactored to improve readability. + + src/liblzma/check/crc32_table.c | 18 +++++++++++++++--- + src/liblzma/check/crc64_table.c | 7 ++++++- + src/liblzma/check/crc_common.h | 5 ++++- + 3 files changed, 25 insertions(+), 5 deletions(-) + +commit 761f5b69a4c778c8bcb09279b845b07c28790575 +Author: Jia Tan +Date: 2024-01-22 20:54:56 +0800 + + liblzma: Rename crc32_aarch64.h to crc32_arm64.h. + + Even though the proper name for the architecture is aarch64, this + project uses ARM64 throughout. So the rename is for consistency. + + Additionally, crc32_arm64.h was slightly refactored for the following + changes: + + * Added MSVC, FreeBSD, and macOS support in + is_arch_extension_supported(). + + * crc32_arch_optimized() now checks the size when aligning the + buffer. + + * crc32_arch_optimized() loop conditions were slightly modified to + avoid both decrementing the size and incrementing the buffer + pointer. + + * Use the intrinsic wrappers defined in because GCC and + Clang name them differently. + + * Minor spacing and comment changes. + + CMakeLists.txt | 2 +- + src/liblzma/check/Makefile.inc | 2 +- + src/liblzma/check/crc32_aarch64.h | 109 ---------------------------------- + src/liblzma/check/crc32_arm64.h | 119 ++++++++++++++++++++++++++++++++++++++ + src/liblzma/check/crc32_fast.c | 3 +- + src/liblzma/check/crc64_fast.c | 3 - + 6 files changed, 122 insertions(+), 116 deletions(-) + +commit 455a08609caa3223066a717fb01bfa42c5dba47d +Author: Jia Tan +Date: 2024-01-22 20:49:30 +0800 + + liblzma: Refactor crc_common.h. + + The CRC_GENERIC is now split into CRC32_GENERIC and CRC64_GENERIC, since + the ARM64 optimizations will be different between CRC32 and CRC64. + + For the same reason, CRC_ARCH_OPTIMIZED is split into + CRC32_ARCH_OPTIMIZED and CRC64_ARCH_OPTIMIZED. + + ifunc will only be used with x86-64 CLMUL because the runtime detection + methods needed with ARM64 are not compatible with ifunc. + + src/liblzma/check/crc32_fast.c | 8 +-- + src/liblzma/check/crc64_fast.c | 8 +-- + src/liblzma/check/crc_common.h | 108 ++++++++++++++++++++++++++++------------- + 3 files changed, 82 insertions(+), 42 deletions(-) + +commit 61908e816049af7a9f43ea804a57ee8570e2e644 +Author: Jia Tan +Date: 2024-01-22 00:42:28 +0800 + + CMake: Add support for ARM64 CRC32 instruction detection. + + CMakeLists.txt | 50 ++++++++++++++++++++++++++++++++++++++++++++++++++ + 1 file changed, 50 insertions(+) + +commit c5f6d79cc9515a7f22d7ea4860c6cc394b295732 +Author: Jia Tan +Date: 2024-01-22 00:36:47 +0800 + + Build: Add support for ARM64 CRC32 instruction detection. + + This adds --enable-arm64-crc32/--disable-arm64-crc32 (enabled by + default) for using the ARM64 CRC32 instruction. This can be disabled if + one knows the binary will never need to run on an ARM64 machine + with this instruction extension. + + configure.ac | 52 ++++++++++++++++++++++++++++++++++++++++++++++++++++ + 1 file changed, 52 insertions(+) + +commit 849d0f282a6a890c5cf5a0e0f02980b12d9ebb0f +Author: Chenxi Mao +Date: 2024-01-09 17:23:11 +0800 + + Speed up CRC32 calculation on ARM64 + + The CRC32 instructions in ARM64 can calculate the CRC32 result + for 8 bytes in a single operation, making the use of ARM64 + instructions much faster compared to the general CRC32 algorithm. + + Optimized CRC32 will be enabled if ARM64 has CRC extension + running on Linux. + + Signed-off-by: Chenxi Mao + + CMakeLists.txt | 1 + + src/liblzma/check/Makefile.inc | 3 +- + src/liblzma/check/crc32_aarch64.h | 109 ++++++++++++++++++++++++++++++++++++++ + src/liblzma/check/crc32_fast.c | 5 +- + src/liblzma/check/crc64_fast.c | 5 +- + src/liblzma/check/crc_common.h | 16 +++--- + 6 files changed, 130 insertions(+), 9 deletions(-) + +commit b43c3e48bf6097095eef36d44cdbec811074940a +Author: Jia Tan +Date: 2024-01-26 19:05:51 +0800 + + Bump version number for 5.5.1alpha. + + src/liblzma/api/lzma/version.h | 2 +- + src/liblzma/liblzma_generic.map | 2 +- + src/liblzma/liblzma_linux.map | 2 +- + 3 files changed, 3 insertions(+), 3 deletions(-) + +commit c7a7ae1500ea90bd3c2d54533e4f433933eb598f +Author: Jia Tan +Date: 2024-01-26 19:00:52 +0800 + + Add NEWS for 5.5.1alpha + + NEWS | 80 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ + 1 file changed, 80 insertions(+) + +commit 0ef8192e8d5af4e6200d5d4aee22d1f177f7a2df +Author: Jia Tan +Date: 2024-01-26 18:54:24 +0800 + + Add NEWS for 5.4.6. + + NEWS | 22 ++++++++++++++++++++++ + 1 file changed, 22 insertions(+) + +commit 93de7e751d17731315a899264f2a7239d7d2d316 +Author: Lasse Collin +Date: 2024-01-24 20:00:57 +0200 + + Move doc/logo/xz-logo.png to "doc" and Doxygen footer to "doxygen". + + The footer isn't a complete HTML file so having it in the doxygen + directory is a tiny bit clearer. + + Makefile.am | 2 +- + doc/{logo => }/xz-logo.png | Bin + doxygen/Doxyfile | 4 ++-- + doc/logo/copyright.html => doxygen/footer.html | 0 + 4 files changed, 3 insertions(+), 3 deletions(-) + +commit 00fa01698df51c58ae2acf8c7fa4e1fb159f75a9 +Author: Jia Tan +Date: 2024-01-09 17:05:01 +0800 + + README: Add COPYING.CC-BY-SA-4.0 entry to section 1.1. + + The Overall documentation section (1.1) table spacing had to be adjusted + since the filename was very long. + + README | 38 ++++++++++++++++++++------------------ + 1 file changed, 20 insertions(+), 18 deletions(-) + +commit e280470040b27c5e58d78b25b9e2bb71fc6c3882 +Author: Jia Tan +Date: 2024-01-09 16:56:16 +0800 + + Build: Add the logo and license to the release. + + Makefile.am | 2 ++ + 1 file changed, 2 insertions(+) + +commit b1ee6cf259bb49ce91abe9f622294524e37edf4c +Author: Jia Tan +Date: 2024-01-09 16:44:42 +0800 + + COPYING: Add the license for the XZ logo. + + COPYING | 5 + + COPYING.CC-BY-SA-4.0 | 427 +++++++++++++++++++++++++++++++++++++++++++++++++++ + 2 files changed, 432 insertions(+) + +commit 31293ae7074802cc7286089a89c7b552d930c97f +Author: Jia Tan +Date: 2024-01-09 16:40:56 +0800 + + Doxygen: Added the XZ logo and copyright information. + + The PROJECT_LOGO field is now used to include the XZ logo. The footer + of each page now lists the copyright information instead of the default + footer. The license is also copied to statisfy the copyright and so the + link in the documentation can be local. + + doc/logo/copyright.html | 11 +++++++++++ + doc/logo/xz-logo.png | Bin 0 -> 6771 bytes + doxygen/Doxyfile | 6 +++--- + 3 files changed, 14 insertions(+), 3 deletions(-) + +commit 6daa4d0ea46a8441f21f609149f3633158bf4704 +Author: Lasse Collin +Date: 2024-01-23 18:29:28 +0200 + + xz: Use threaded mode by defaut (as if --threads=0 was used). + + This hopefully does more good than bad: + + + It's faster by default. + + + Only the threaded compressor creates files that + can be decompressed in threaded mode. + + - Compression ratio is worse, usually not too much though. + When it matters, -T1 must be used. + + - Memory usage increases. + + - Scripts that assume single-threaded mode but don't use -T1 will + possibly use too much resources, for example, if they run + multiple xz processes in parallel to compress multiple files. + + - Output from single-threaded and multi-threaded compressors + differ but such changes could happen for other reasons too + (they just haven't happened since 5.0.0). + + src/xz/hardware.c | 6 +++++- + src/xz/message.c | 4 ++-- + src/xz/xz.1 | 9 +++++++++ + 3 files changed, 16 insertions(+), 3 deletions(-) + +commit a2dd2dc8e5307a7280bb99868bc478560facba2c +Author: Jia Tan +Date: 2024-01-23 23:52:49 +0800 + + CI: Use RISC-V filter when building with BCJ support. + + build-aux/ci_build.sh | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +commit 3060e1070b2421b26c0e17794c1307ec5622f11d +Author: Jia Tan +Date: 2024-01-23 23:52:14 +0800 + + Tests: Use smaller dictionary size in RISC-V test files. + + tests/files/good-1-riscv-lzma2-1.xz | Bin 7512 -> 7512 bytes + tests/files/good-1-riscv-lzma2-2.xz | Bin 7516 -> 7512 bytes + 2 files changed, 0 insertions(+), 0 deletions(-) + +commit 44ff2fa5c94dc345c4dd69195a19fc5238df60b3 +Author: Jia Tan +Date: 2024-01-23 23:50:57 +0800 + + Tests: Skip RISC-V test files if decoder was not built. + + tests/test_files.sh | 5 +++++ + 1 file changed, 5 insertions(+) + +commit 6133a3f30049d3beaf7d22535b1e5d38e109be4e +Author: Lasse Collin +Date: 2024-01-23 16:11:54 +0200 + + xz: Man page: Add more examples of LZMA2 options with BCJ filters. + + src/xz/xz.1 | 38 +++++++++++++++++++++++++++++++------- + 1 file changed, 31 insertions(+), 7 deletions(-) + +commit 50255feeaabcc7e7db22b858a6bd64a9b5b4f16d +Author: Lasse Collin +Date: 2024-01-23 00:09:48 +0200 + + liblzma: RISC-V filter: Use byte-by-byte access. + + Not all RISC-V processors support fast unaligned access so + it's better to read only one byte in the main loop. This can + be faster even on x86-64 when compared to reading 32 bits at + a time as half the time the address is only 16-bit aligned. + + The downside is larger code size on archs that do support + fast unaligned access. + + src/liblzma/simple/riscv.c | 114 +++++++++++++++++++++++++++++++++------------ + 1 file changed, 84 insertions(+), 30 deletions(-) + +commit db5eb5f563e8baa8d912ecf576f53391ff861596 +Author: Jia Tan +Date: 2024-01-22 23:33:39 +0800 + + xz: Update xz -lvv for RISC-V filter. + + Version 5.6.0 will be shown, even though upcoming alphas and betas + will be able to support this filter. 5.6.0 looks nicer in the output and + people shouldn't be encouraged to use an unstable version in production + in any way. + + src/xz/list.c | 10 ++++++++++ + 1 file changed, 10 insertions(+) + +commit e2870db5be1503e6a489fc3d47daf950d6f62723 +Author: Jia Tan +Date: 2024-01-22 23:33:39 +0800 + + Tests: Add two RISC-V Filter test files. + + These test files achieve 100% code coverage in + src/liblzma/simple/riscv.c. They contain all of the instructions that + should be filtered and a few cases that should not. + + tests/files/README | 8 ++++++++ + tests/files/good-1-riscv-lzma2-1.xz | Bin 0 -> 7512 bytes + tests/files/good-1-riscv-lzma2-2.xz | Bin 0 -> 7516 bytes + 3 files changed, 8 insertions(+) + +commit b26a89869315ece2f6d9d10d32d45f672550f245 +Author: Jia Tan +Date: 2024-01-22 23:33:39 +0800 + + xz: Update message in --long-help for RISC-V Filter. + + src/xz/message.c | 1 + + 1 file changed, 1 insertion(+) + +commit 283f778908873eca61388029fc418fa800c9d7d7 +Author: Jia Tan +Date: 2024-01-22 23:33:39 +0800 + + xz: Update the man page for the RISC-V Filter. + + A special note was added to suggest using four-byte alignment when the + compressed instruction extension is not present in a RISC-V binary. + + src/xz/xz.1 | 3 ++- + 1 file changed, 2 insertions(+), 1 deletion(-) + +commit ac3691ccca051d67f60b4a3b05b88e511d0b1b28 +Author: Jia Tan +Date: 2024-01-22 23:33:39 +0800 + + Tests: Add RISC-V Filter test in test_compress.sh. + + tests/test_compress.sh | 1 + + 1 file changed, 1 insertion(+) + +commit 2959dbc7358efcf421ce51bc9cd7eae8fdd8fec4 +Author: Jia Tan +Date: 2024-01-22 23:33:39 +0800 + + liblzma: Update string_conversion.c to support RISC-V Filter. + + src/liblzma/common/string_conversion.c | 5 +++++ + 1 file changed, 5 insertions(+) + +commit 34372a5adbe5a7f6bf29498410ba3a463a720966 +Author: Jia Tan +Date: 2024-01-22 23:33:39 +0800 + + CMake: Support RISC-V BCJ Filter for encoding and decoding. + + CMakeLists.txt | 1 + + 1 file changed, 1 insertion(+) + +commit 440a2eccb082dc13400c09e22308a58fef85146c +Author: Jia Tan +Date: 2024-01-22 23:33:39 +0800 + + liblzma: Add RISC-V BCJ filter. + + The new Filter ID is 0x0B. + + Thanks to Chien Wong for the initial version of the Filter, + the xz CLI updates, and the Autotools build system modifications. + + Thanks to Igor Pavlov for his many contributions to the design of + the filter. + + configure.ac | 4 +- + src/liblzma/api/lzma/bcj.h | 5 + + src/liblzma/common/filter_common.c | 9 + + src/liblzma/common/filter_decoder.c | 8 + + src/liblzma/common/filter_encoder.c | 10 + + src/liblzma/simple/Makefile.inc | 4 + + src/liblzma/simple/riscv.c | 688 ++++++++++++++++++++++++++++++++++++ + src/liblzma/simple/simple_coder.h | 9 + + src/xz/args.c | 7 + + 9 files changed, 742 insertions(+), 2 deletions(-) + +commit 5540f4329bbdb4deb4850d4af48b18ad074bba19 +Author: Jia Tan +Date: 2024-01-19 23:08:14 +0800 + + Docs: Update .xz file format specification to 1.2.0. + + The new RISC-V filter was added to the specification, in addition to + updating the specification URL. + + doc/xz-file-format.txt | 29 +++++++++++++++++------------ + 1 file changed, 17 insertions(+), 12 deletions(-) + +commit 22d86192f8cf00902a1f90ee2a83ca600794459b +Author: Jia Tan +Date: 2024-01-19 23:08:14 +0800 + + xz: Update website URLs in the man pages. + + src/xz/xz.1 | 6 +++--- + src/xzdec/xzdec.1 | 4 ++-- + 2 files changed, 5 insertions(+), 5 deletions(-) + +commit 6b63c4c6139fa1bb21b570521d3d2b4a608bc34d +Author: Jia Tan +Date: 2024-01-19 23:08:14 +0800 + + liblzma: Update website URL. + + dos/config.h | 2 +- + src/liblzma/api/lzma.h | 6 +++--- + 2 files changed, 4 insertions(+), 4 deletions(-) + +commit fce4758018f3a3589236f3fe7999fd9dd08c77e9 +Author: Jia Tan +Date: 2024-01-19 23:08:14 +0800 + + Docs: Update website URLs. + + .github/SECURITY.md | 2 +- + COPYING | 3 ++- + README | 4 ++-- + doc/faq.txt | 2 +- + doc/lzma-file-format.txt | 18 +++++++++--------- + windows/README-Windows.txt | 3 ++- + 6 files changed, 17 insertions(+), 15 deletions(-) + +commit c26812c5b2c8a2a47f43214afe6b0b840c73e4f5 +Author: Jia Tan +Date: 2024-01-19 23:08:14 +0800 + + Build: Update website URL. + + CMakeLists.txt | 2 +- + configure.ac | 2 +- + 2 files changed, 2 insertions(+), 2 deletions(-) + +commit fbb3ce541ef79cad1710e88a27a5babb5f6f8e5b +Author: Lasse Collin +Date: 2024-01-11 15:01:50 +0200 + + liblzma: CRC: Add a comment to crc_x86_clmul.h about BUILDING_ macros. + + src/liblzma/check/crc_x86_clmul.h | 6 ++++++ + 1 file changed, 6 insertions(+) + +commit 4f518c1b6b7b7ce5dcefea81acd44d7a086a8882 +Author: Lasse Collin +Date: 2024-01-11 15:22:36 +0200 + + liblzma: CRC: Remove crc_always_inline, use lzma_always_inline instead. + + Now crc_simd_body() in crc_x86_clmul.h is only called once + in a translation unit, we no longer need to be so cautious + about ensuring the always-inline behavior. + + src/liblzma/check/crc_common.h | 20 -------------------- + src/liblzma/check/crc_x86_clmul.h | 2 +- + 2 files changed, 1 insertion(+), 21 deletions(-) + +commit 35c03ec6bf66f1b159964c9721a2dce0e2859b20 +Author: Lasse Collin +Date: 2024-01-11 14:39:46 +0200 + + liblzma: CRC: Update CLMUL comments to more generic wording. + + src/liblzma/check/crc32_fast.c | 16 ++++++++-------- + src/liblzma/check/crc64_fast.c | 10 +++++----- + 2 files changed, 13 insertions(+), 13 deletions(-) + +commit 66f080e8016129576536482ac377e2ecac7a2b90 +Author: Lasse Collin +Date: 2024-01-10 18:23:31 +0200 + + liblzma: Rename arch-specific CRC functions and macros. + + CRC_CLMUL was split to CRC_ARCH_OPTIMIZED and CRC_X86_CLMUL. + CRC_ARCH_OPTIMIZED is defined when an arch-optimized version is used. + Currently the x86 CLMUL implementations are the only arch-optimized + versions, and these also use the CRC_x86_CLMUL macro to tell when + crc_x86_clmul.h needs to be included. + + is_clmul_supported() was renamed to is_arch_extension_supported(). + crc32_clmul() and crc64_clmul() were renamed to + crc32_arch_optimized() and crc64_arch_optimized(). + This way the names make sense with arch-specific non-CLMUL + implementations as well. + + src/liblzma/check/crc32_fast.c | 13 +++++++------ + src/liblzma/check/crc64_fast.c | 13 +++++++------ + src/liblzma/check/crc_common.h | 9 ++++++--- + src/liblzma/check/crc_x86_clmul.h | 21 +++++++++++---------- + 4 files changed, 31 insertions(+), 25 deletions(-) + +commit 3dbed75b0b9c7087c76fe687acb5cf582cd57b99 +Author: Lasse Collin +Date: 2024-01-10 18:19:21 +0200 + + liblzma: Fix a comment in crc_common.h. + + src/liblzma/check/crc_common.h | 3 ++- + 1 file changed, 2 insertions(+), 1 deletion(-) + +commit 419f55f9dfc2df8792902b8953d50690121afeea +Author: Lasse Collin +Date: 2023-10-20 23:35:10 +0300 + + liblzma: Avoid extern lzma_crc32_clmul() and lzma_crc64_clmul(). + + A CLMUL-only build will have the crcxx_clmul() inlined into + lzma_crcxx(). Previously a jump to the extern lzma_crcxx_clmul() + was needed. Notes about shared liblzma on ELF platforms: + + - On platforms that support ifunc and -fvisibility=hidden, this + was silly because CLMUL-only build would have that single extra + jump instruction of extra overhead. + + - On platforms that support neither -fvisibility=hidden nor linker + version script (liblzma*.map), jumping to lzma_crcxx_clmul() + would go via PLT so a few more instructions of overhead (still + not a big issue but silly nevertheless). + + There was a downside with static liblzma too: if an application only + needs lzma_crc64(), static linking would make the linker include the + CLMUL code for both CRC32 and CRC64 from crc_x86_clmul.o even though + the CRC32 code wouldn't be needed, thus increasing code size of the + executable (assuming that -ffunction-sections isn't used). + + Also, now compilers are likely to inline crc_simd_body() + even if they don't support the always_inline attribute + (or MSVC's __forceinline). Quite possibly all compilers + that build the code do support such an attribute. But now + it likely isn't a problem even if the attribute wasn't supported. + + Now all x86-specific stuff is in crc_x86_clmul.h. If other archs + The other archs can then have their own headers with their own + is_clmul_supported() and crcxx_clmul(). + + Another bonus is that the build system doesn't need to care if + crc_clmul.c is needed. + + is_clmul_supported() stays as inline function as it's not needed + when doing a CLMUL-only build (avoids a warning about unused function). + + CMakeLists.txt | 7 +- + configure.ac | 1 - + src/liblzma/check/Makefile.inc | 6 +- + src/liblzma/check/crc32_fast.c | 9 ++- + src/liblzma/check/crc64_fast.c | 9 ++- + src/liblzma/check/crc_common.h | 64 ---------------- + src/liblzma/check/{crc_clmul.c => crc_x86_clmul.h} | 86 ++++++++++++++++++---- + 7 files changed, 91 insertions(+), 91 deletions(-) + +commit e3833e297dfb5021a197bda34ba2a795e30aaf8a +Author: Lasse Collin +Date: 2023-10-21 00:06:52 +0300 + + liblzma: crc_clmul.c: Add crc_attr_target macro. + + This reduces the number of the complex #if directives. + + src/liblzma/check/crc_clmul.c | 30 ++++++++++++++++-------------- + 1 file changed, 16 insertions(+), 14 deletions(-) + +commit d164ac0e62904126f7920c25f9a2875c8cd28b97 +Author: Lasse Collin +Date: 2023-10-20 22:49:48 +0300 + + liblzma: Simplify existing cases with lzma_attr_no_sanitize_address. + + src/liblzma/check/crc_clmul.c | 12 +++--------- + 1 file changed, 3 insertions(+), 9 deletions(-) + +commit 9523c1300d22fa715765c181cf991d14d6112fb1 +Author: Lasse Collin +Date: 2023-10-20 21:53:35 +0300 + + liblzma: #define crc_attr_no_sanitize_address in crc_common.h. + + src/liblzma/check/crc_common.h | 10 ++++++++++ + 1 file changed, 10 insertions(+) + +commit 93d144f0930821590524247bd174afd38003d7f0 +Author: Lasse Collin +Date: 2023-10-20 23:25:14 +0300 + + liblzma: CRC: Add empty lines. + + And remove one too. + + src/liblzma/check/crc32_fast.c | 2 ++ + src/liblzma/check/crc64_fast.c | 3 +++ + src/liblzma/check/crc_clmul.c | 1 - + 3 files changed, 5 insertions(+), 1 deletion(-) + +commit 0c7e854ffd27f1cec2e9b0e61601d6f90bfa10ae +Author: Lasse Collin +Date: 2023-10-20 23:19:33 +0300 + + liblzma: crc_clmul.c: Tidy up the location of MSVC pragma. + + It makes no difference in practice. + + src/liblzma/check/crc_clmul.c | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +commit 15cf3f04f270d707a5c91cc0208b23b6db42b774 +Author: Lasse Collin +Date: 2023-12-20 21:16:24 +0200 + + Update THANKS. + + THANKS | 1 + + 1 file changed, 1 insertion(+) + +commit cd64dd70d5665b6048829c45772d08606f44672e +Author: Lasse Collin +Date: 2023-12-20 21:15:16 +0200 + + liblzma: Use 8-byte method in memcmplen.h on ARM64. + + It requires fast unaligned access to 64-bit integers + and a fast instruction to count leading zeros in + a 64-bit integer (__builtin_ctzll()). This perhaps + should be enabled on some other archs too. + + Thanks to Chenxi Mao for the original patch: + https://github.com/tukaani-project/xz/pull/75 (the first commit) + According to the numbers there, this may improve encoding + speed by about 3-5 %. + + This enables the 8-byte method on MSVC ARM64 too which + should work but wasn't tested. + + src/liblzma/common/memcmplen.h | 18 ++++++++++-------- + 1 file changed, 10 insertions(+), 8 deletions(-) + +commit 12c90c00f05e19da3c0c91d8cd8e0d0d45965606 +Author: Lasse Collin +Date: 2023-12-20 21:01:06 +0200 + + liblzma: Check also for __clang__ in memcmplen.h. + + This change hopefully makes no practical difference as Clang + likely was detected via __GNUC__ or _MSC_VER already. + + src/liblzma/common/memcmplen.h | 3 ++- + 1 file changed, 2 insertions(+), 1 deletion(-) + +commit 133c5851eb917c6d99d0b623c1689c8518e65f38 +Author: Jia Tan +Date: 2023-12-21 21:39:08 +0800 + + Translations: Update the French translation. + + po/fr.po | 632 +++++++++++++++++++++++++++++++++++++-------------------------- + 1 file changed, 370 insertions(+), 262 deletions(-) + +commit 710cbc186cad0ac601c38bd6bf31167648a5581e +Author: Jia Tan +Date: 2023-12-21 16:39:53 +0800 + + xz: Add a comment to Capsicum sandbox setup. + + This comment is repeated in xzdec.c to help remind us why all the + capabilities are removed from stdin in certain situations. + + src/xz/file_io.c | 1 + + 1 file changed, 1 insertion(+) + +commit 4e1c695676bafbaecc9fb307f6ee94138ae72c12 +Author: Jia Tan +Date: 2023-12-20 22:19:19 +0800 + + Docs: Update --enable-sandbox option in INSTALL. + + xzdec now also uses the sandbox when its configured. + + INSTALL | 17 ++++++++++------- + 1 file changed, 10 insertions(+), 7 deletions(-) + +commit ebddf20214143a8e002ab897e95e880bb4c5ac44 +Author: Jia Tan +Date: 2023-12-20 22:39:13 +0800 + + CMake: Move sandbox detection outside of xz section. + + The sandbox is now enabled for xzdec as well, so it no longer belongs + in just the xz section. xz and xzdec are always built, except for older + MSVC versions, so there isn't a need to conditionally show the sandbox + configuration. CMake will do a little unecessary work on older MSVC + versions that can't build xz or xzdec, but this is a very small + downside. + + CMakeLists.txt | 178 +++++++++++++++++++++++++++++++-------------------------- + 1 file changed, 98 insertions(+), 80 deletions(-) + +commit 5feb09266fd2928ec0a4dcb98c1dc7f053111316 +Author: Jia Tan +Date: 2023-12-20 22:43:44 +0800 + + Build: Allow sandbox to be configured for just xzdec. + + If xz is disabled, then xzdec can still use the sandbox. + + configure.ac | 10 +++++----- + 1 file changed, 5 insertions(+), 5 deletions(-) + +commit d74fb5f060b76db709b50f5fd37490394e52f975 +Author: Jia Tan +Date: 2023-12-19 21:18:28 +0800 + + xzdec: Add sandbox support for Pledge, Capsicum, and Landlock. + + A very strict sandbox is used when the last file is decompressed. The + likely most common use case of xzdec is to decompress a single file. + The Pledge sandbox is applied to the entire process with slightly more + relaxed promises, until the last file is processed. + + Thanks to Christian Weisgerber for the initial patch adding Pledge + sandboxing. + + src/xzdec/xzdec.c | 146 +++++++++++++++++++++++++++++++++++++++++++++++++++--- + 1 file changed, 139 insertions(+), 7 deletions(-) + +commit b34b6a9912d6165e34ba0db151b7f9941d2e06d5 +Author: Jia Tan +Date: 2023-12-20 21:31:34 +0800 + + liblzma: Initialize lzma_lz_encoder pointers with NULL. + + This fixes the recent change to lzma_lz_encoder that used memzero + instead of the NULL constant. On some compilers the NULL constant + (always 0) may not equal the NULL pointer (this only needs to guarentee + to not point to valid memory address). + + Later code compares the pointers to the NULL pointer so we must + initialize them with the NULL pointer instead of 0 to guarentee + code correctness. + + src/liblzma/lz/lz_encoder.c | 6 +++++- + 1 file changed, 5 insertions(+), 1 deletion(-) + +commit 183a62f0b540ff4d23cc19b2b6bc2525f0bd64df +Author: Jia Tan +Date: 2023-12-16 20:51:38 +0800 + + liblzma: Set all values in lzma_lz_encoder to NULL after allocation. + + The first member of lzma_lz_encoder doesn't necessarily need to be set + to NULL since it will always be set before anything tries to use it. + However the function pointer members must be set to NULL since other + functions rely on this NULL value to determine if this behavior is + supported or not. + + This fixes a somewhat serious bug, where the options_update() and + set_out_limit() function pointers are not set to NULL. This seems to + have been forgotten since these function pointers were added many years + after the original two (code() and end()). + + The problem is that by not setting this to NULL we are relying on the + memory allocation to zero things out if lzma_filters_update() is called + on a LZMA1 encoder. The function pointer for set_out_limit() is less + serious because there is not an API function that could call this in an + incorrect way. set_out_limit() is only called by the MicroLZMA encoder, + which must use LZMA1 where set_out_limit() is always set. Its currently + not possible to call set_out_limit() on an LZMA2 encoder at this time. + + So calling lzma_filters_update() on an LZMA1 encoder had undefined + behavior since its possible that memory could be manipulated so the + options_update member pointed to a different instruction sequence. + + This is unlikely to be a bug in an existing application since it relies + on calling lzma_filters_update() on an LZMA1 encoder in the first place. + For instance, it does not affect xz because lzma_filters_update() can + only be used when encoding to the .xz format. + + This is fixed by using memzero() to set all members of lzma_lz_encoder + to NULL after it is allocated. This ensures this mistake will not occur + here in the future if any additional function pointers are added. + + src/liblzma/lz/lz_encoder.c | 4 +--- + 1 file changed, 1 insertion(+), 3 deletions(-) + +commit 1a1bb381db7a20cf86cb45a350e5cca35224d017 +Author: Jia Tan +Date: 2023-12-16 20:30:55 +0800 + + liblzma: Tweak a comment. + + src/liblzma/lz/lz_encoder.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit 55810780e04f759747b02683fb8020b8cd022a85 +Author: Jia Tan +Date: 2023-12-16 20:28:21 +0800 + + liblzma: Make parameter names in function definition match declaration. + + lzma_raw_encoder() and lzma_raw_encoder_init() used "options" as the + parameter name instead of "filters" (used by the declaration). "filters" + is more clear since the parameter represents the list of filters passed + to the raw encoder, each of which contains filter options. + + src/liblzma/common/filter_encoder.c | 8 ++++---- + 1 file changed, 4 insertions(+), 4 deletions(-) + +commit 5dad6f628af742bab826819760deb677597445f7 +Author: Jia Tan +Date: 2023-12-16 20:18:47 +0800 + + liblzma: Improve lzma encoder init function consistency. + + lzma_encoder_init() did not check for NULL options, but + lzma2_encoder_init() did. This is more of a code style improvement than + anything else to help make lzma_encoder_init() and lzma2_encoder_init() + more similar. + + src/liblzma/lzma/lzma_encoder.c | 3 +++ + 1 file changed, 3 insertions(+) + +commit e1b1a9d6370b788bd6078952c6c201e12bc27cbf +Author: Jia Tan +Date: 2023-12-16 11:20:20 +0800 + + Docs: Update repository URL in Changelog. + + ChangeLog | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit f9b82bc64a9405e486575c65c1729229eb0a8198 +Author: Jia Tan +Date: 2023-12-15 16:56:31 +0800 + + CI: Update Upload Artifact Action. + + .github/workflows/ci.yml | 2 +- + .github/workflows/windows-ci.yml | 2 +- + 2 files changed, 2 insertions(+), 2 deletions(-) + +commit d0b24efe6cdc47db5b0fdf6306f70a2e0e63e49e +Author: Jia Tan +Date: 2023-12-07 21:48:07 +0800 + + Tests: Silence -Wsign-conversion warning on GCC version < 10. + + Since GCC version 10, GCC no longer complains about simple implicit + integer conversions with Arithmetic operators. + + For instance: + + uint8_t a = 5; + uint32_t b = a + 5; + + Give a warning on GCC 9 and earlier but this: + + uint8_t a = 5; + uint32_t b = (a + 5) * 2; + + Gives a warning with GCC 10+. + + tests/test_block_header.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit 4a972a8ee3ed88ac14067c1d2f15b78988e5dae8 +Author: Jia Tan +Date: 2023-12-06 18:39:03 +0800 + + Update THANKS. + + THANKS | 1 + + 1 file changed, 1 insertion(+) + +commit ee2f48350099201694a7586e41d7aa2f09fc74da +Author: Jia Tan +Date: 2023-12-06 18:30:25 +0800 + + Tests: Minor cleanups to OSS-Fuzz files. + + Most of these fixes are small typos and tweaks. A few were caused by bad + advice from me. Here is the summary of what is changed: + + - Author line edits + + - Small comment changes/additions + + - Using the return value in the error messages in the fuzz targets' + coder initialization code + + - Removed fuzz_encode_stream.options. This set a max length, which may + prevent some worthwhile code paths from being properly exercised. + + - Removed the max_len option from fuzz_decode_stream.options for the + same reason as fuzz_encode_stream. The alone decoder fuzz target still + has this restriction. + + - Altered the dictionary contents for fuzz_lzma.dict. Instead of keeping + the properties static and varying the dictionary size, the properties + are varied and the dictionary size is kept small. The dictionary size + doesn't have much impact on the code paths but the properties do. + + Closes: https://github.com/tukaani-project/xz/pull/73 + + tests/ossfuzz/Makefile | 3 ++ + tests/ossfuzz/config/fuzz_decode_stream.options | 1 - + tests/ossfuzz/config/fuzz_lzma.dict | 34 +++++++++++----------- + tests/ossfuzz/fuzz_common.h | 16 +++++------ + tests/ossfuzz/fuzz_decode_alone.c | 15 +++++----- + tests/ossfuzz/fuzz_decode_stream.c | 15 +++++----- + tests/ossfuzz/fuzz_encode_stream.c | 38 +++++++++++++++---------- + 7 files changed, 66 insertions(+), 56 deletions(-) + +commit 483bb90eec7c83e1c2bcd06287714afd62d8c17d +Author: Maksym Vatsyk +Date: 2023-12-05 16:31:09 +0100 + + Tests: Add fuzz_encode_stream ossfuzz target. + + This fuzz target handles .xz stream encoding. The first byte of input + is used to dynamically set the preset level in order to increase the + fuzz coverage of complex critical code paths. + + tests/ossfuzz/config/fuzz_encode_stream.options | 2 + + tests/ossfuzz/fuzz_encode_stream.c | 79 +++++++++++++++++++++++++ + 2 files changed, 81 insertions(+) + +commit 7ca8c9869df82756c3128c4fcf1058da4d18aa48 +Author: Maksym Vatsyk +Date: 2023-12-04 17:23:24 +0100 + + Tests: Add fuzz_decode_alone OSS-Fuzz target + + This fuzz target that handles LZMA alone decoding. A new fuzz + dictionary .dict was also created with common LZMA header values to + help speed up the discovery of valid headers. + + tests/ossfuzz/config/fuzz_decode_alone.options | 3 ++ + tests/ossfuzz/config/fuzz_lzma.dict | 22 ++++++++++++++ + tests/ossfuzz/fuzz_decode_alone.c | 41 ++++++++++++++++++++++++++ + 3 files changed, 66 insertions(+) + +commit 37581a77ad5a49615325b1d1925fdc402b1e1d5a +Author: Maksym Vatsyk +Date: 2023-12-04 17:21:29 +0100 + + Tests: Update OSS-Fuzz Makefile. + + All .c files can be built as separate fuzz targets. This simplifies + the Makefile by allowing us to use wildcards instead of having a + Makefile target for each fuzz target. + + tests/ossfuzz/Makefile | 13 +++++++++---- + 1 file changed, 9 insertions(+), 4 deletions(-) + +commit 28ce6a1c2a74866c51f7996a6869679c236d3c94 +Author: Maksym Vatsyk +Date: 2023-12-04 17:20:08 +0100 + + Tests: Move common OSS-Fuzz target code to .h file. + + tests/ossfuzz/fuzz_common.h | 56 ++++++++++++++++++++++++++++++++++++ + tests/ossfuzz/fuzz_decode_stream.c | 59 ++++++++++---------------------------- + 2 files changed, 71 insertions(+), 44 deletions(-) + +commit bf0521ea1591c25b9d510c1b8be86073e9d847c6 +Author: Maksym Vatsyk +Date: 2023-12-04 17:18:20 +0100 + + Tests: Rename OSS-Fuzz files. + + tests/ossfuzz/config/fuzz.options | 2 -- + tests/ossfuzz/config/fuzz_decode_stream.options | 3 +++ + tests/ossfuzz/config/{fuzz.dict => fuzz_xz.dict} | 0 + tests/ossfuzz/{fuzz.c => fuzz_decode_stream.c} | 0 + 4 files changed, 3 insertions(+), 2 deletions(-) + +commit 685094b8e1c1aa1bf934de0366ca42ef599d25f7 +Author: Jia Tan +Date: 2023-11-30 23:10:43 +0800 + + Update THANKS. + + THANKS | 1 + + 1 file changed, 1 insertion(+) + +commit 3b3023e00b0071e10f589bbc3674e0ec432b8add +Author: Kian-Meng Ang +Date: 2023-11-30 23:01:19 +0800 + + Tests: Fix typos + + tests/test_index.c | 2 +- + tests/test_lzip_decoder.c | 4 ++-- + 2 files changed, 3 insertions(+), 3 deletions(-) + +commit 424d46ead8cbc0da57f406b76926ec4ed47437f5 +Author: Kian-Meng Ang +Date: 2023-11-30 22:59:47 +0800 + + xz: Fix typo + + src/xz/file_io.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit 35558adf9c45e5597f2c8dbd969885dd484038d2 +Author: Jia Tan +Date: 2023-11-30 20:41:00 +0800 + + Update THANKS. + + THANKS | 1 + + 1 file changed, 1 insertion(+) + +commit fd170e8557727bed6bec0518c16415064d972e4e +Author: Jia Tan +Date: 2023-11-22 21:20:12 +0800 + + CI: Test musl libc builds on Ubuntu runner. + + .github/workflows/ci.yml | 19 +++++++++++++++++-- + 1 file changed, 17 insertions(+), 2 deletions(-) + +commit db2b4aa068a492c0013279a4ed43803e8ff9bb3e +Author: Jia Tan +Date: 2023-11-22 21:12:15 +0800 + + CI: Allow ci_build.sh to set a different C compiler. + + build-aux/ci_build.sh | 11 ++++++++++- + 1 file changed, 10 insertions(+), 1 deletion(-) + +commit ff7badef53c2cd698d4b72b945f34dfd0835e13c +Author: Jia Tan +Date: 2023-11-24 21:19:12 +0800 + + CMake: Use consistent indentation with check_c_source_compiles(). + + CMakeLists.txt | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +commit d4af167570f2c14b002ee18a39d5b1e7e5a892b1 +Author: Jia Tan +Date: 2023-11-22 20:33:36 +0800 + + CMake: Change __attribute__((__ifunc__())) detection. + + This renames ALLOW_ATTR_IFUNC to USE_ATTR_IFUNC and applies the ifunc + detection changes that were made to the Autotools build. + + Fixes: https://github.com/tukaani-project/xz/issues/70 + + CMakeLists.txt | 53 +++++++++++++++++++++++++++++++++++++++++++++-------- + 1 file changed, 45 insertions(+), 8 deletions(-) + +commit 20ecee40a0053fd16371ef0628046bf45e548d72 +Author: Jia Tan +Date: 2023-11-24 20:19:11 +0800 + + Docs: Update INSTALL for --enable_ifunc change. + + INSTALL | 16 ++++++++-------- + 1 file changed, 8 insertions(+), 8 deletions(-) + +commit ffb456593d695d70052a2f71c7a2e6269217d194 +Author: Jia Tan +Date: 2023-11-21 20:56:55 +0800 + + Build: Change --enable-ifunc handling. + + Some compilers support __attribute__((__ifunc__())) even though the + dynamic linker does not. The compiler is able to create the binary + but it will fail on startup. So it is not enough to just test if + the attribute is supported. + + The default value for enable_ifunc is now auto, which will attempt + to compile a program using __attribute__((__ifunc__())). There are + additional checks in this program if glibc is being used or if it + is running on FreeBSD. + + Setting --enable-ifunc will skip this test and always enable + __attribute__((__ifunc__())), even if is not supported. + + configure.ac | 61 +++++++++++++++++++++++++++++++++++++++++++----------------- + 1 file changed, 44 insertions(+), 17 deletions(-) + +commit 12b89bcc9915090eb42ae638e565af44b6832a23 +Author: Lasse Collin +Date: 2023-11-23 17:39:10 +0200 + + xz: Tweak a comment. + + src/xz/util.c | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +commit 2ab2e4b5a542eab93902985ce4e642719a8b7a4e +Author: Jia Tan +Date: 2023-11-23 22:13:39 +0800 + + xz: Use is_tty() in message.c. + + src/xz/message.c | 7 +------ + 1 file changed, 1 insertion(+), 6 deletions(-) + +commit 584e3a258f32d579b1d07f99b4dc6e856c10ac7e +Author: Jia Tan +Date: 2023-11-23 22:04:35 +0800 + + xz: Create separate is_tty() function. + + The new is_tty() will report if a file descriptor is a terminal or not. + On POSIX systems, it is a wrapper around isatty(). However, the native + Windows implementation of isatty() will return true for all character + devices, not just terminals. So is_tty() has a special case for Windows + so it can use alternative Windows API functions to determine if a file + descriptor is a terminal. + + This fixes a bug with MSVC and MinGW-w64 builds that refused to read from + or write to non-terminal character devices because xz thought it was a + terminal. For instance: + + xz foo -c > /dev/null + + would fail because /dev/null was assumed to be a terminal. + + src/xz/util.c | 30 +++++++++++++++++++++++------- + src/xz/util.h | 14 ++++++++++++++ + 2 files changed, 37 insertions(+), 7 deletions(-) + +commit 6b05f827f50e686537e9a23c49c5aa4c0aa6b23d +Author: Jia Tan +Date: 2023-11-22 20:39:41 +0800 + + tuklib_integer: Fix typo discovered by codespell. + + Based on internet dictionary searches, 'choise' is an outdated spelling + of 'choice'. + + src/common/tuklib_integer.h | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit 659aca0d695807c0762d4101765189e4e33d1e2c +Author: Lasse Collin +Date: 2023-11-17 19:35:19 +0200 + + xz: Move the check for --suffix with --format=raw a few lines earlier. + + Now it reads from argv[] instead of args->arg_names. + + src/xz/args.c | 44 ++++++++++++++++++++++---------------------- + 1 file changed, 22 insertions(+), 22 deletions(-) + +commit ca278eb2b7f5a4940f5ab18955297b398d423824 +Author: Jia Tan +Date: 2023-11-17 20:35:11 +0800 + + Tests: Create test_suffix.sh. + + This tests some complicated interactions with the --suffix= option. + The suffix option must be used with --format=raw, but can optionally + be used to override the default .xz suffix. + + This test also verifies some recent bugs have been correctly solved + and to hopefully avoid further regressions in the future. + + tests/Makefile.am | 2 + + tests/test_suffix.sh | 189 +++++++++++++++++++++++++++++++++++++++++++++++++++ + 2 files changed, 191 insertions(+) + +commit 2a732aba22da1b0d4a1241cb32280ed010ba03ce +Author: Jia Tan +Date: 2023-11-17 20:19:26 +0800 + + xz: Fix a bug with --files and --files0 in raw mode without a suffix. + + The following command caused a segmentation fault: + + xz -Fraw --lzma1 --files=foo + + when foo was a valid file. The usage of --files or --files0 was not + being checked when compressing or decompressing in raw mode without a + suffix. The suffix checking code was meant to validate that all files + to be processed are "-" (if not writing to standard out), meaning the + data is only coming from standard in. In this case, there were no file + names to check since --files and --files0 store their file name in a + different place. + + Later code assumed the suffix was set and caused a segmentation fault. + Now, the above command results in an error. + + src/xz/args.c | 5 +++++ + 1 file changed, 5 insertions(+) + +commit 299920bab9ae258a247366339264e8aefca9e3ce +Author: Jia Tan +Date: 2023-11-17 20:04:58 +0800 + + Tests: Fix typo in a comment. + + tests/test_files.sh | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit f481523baac946fa3bc13d79186ffaf0c0b818a7 +Author: Jia Tan +Date: 2023-11-15 23:40:13 +0800 + + xz: Refactor suffix test with raw format. + + The previous version set opt_stdout, but this caused an issue with + copying an input file to standard out when decompressing an unknown file + type. The following needs to result in an error: + + echo foo | xz -df + + since -c, --stdout is not used. This fixes the previous error by not + setting opt_stdout. + + src/xz/args.c | 38 +++++++++++++------------------------- + 1 file changed, 13 insertions(+), 25 deletions(-) + +commit 837ea40b1c9d4998cac4500b55171bf33e0c31a6 +Author: Jia Tan +Date: 2023-11-14 20:27:46 +0800 + + xz: Move suffix check after stdout mode is detected. + + This fixes a bug introduced in cc5aa9ab138beeecaee5a1e81197591893ee9ca0 + when the suffix check was initially moved. This caused a situation that + previously worked: + + echo foo | xz -Fraw --lzma1 | wc -c + + to fail because the old code knew that this would write to standard out + so a suffix was not needed. + + src/xz/args.c | 16 ++++++++-------- + 1 file changed, 8 insertions(+), 8 deletions(-) + +commit d4f4a4d040ef47a5e82dffd0f067e92716606ddf +Author: Jia Tan +Date: 2023-11-14 20:27:04 +0800 + + xz: Detect when all data will be written to standard out earlier. + + If the -c, --stdout argument is not used, then we can still detect when + the data will be written to standard out if all of the provided + filenames are "-" (denoting standard in) or if no filenames are + provided. + + src/xz/args.c | 21 +++++++++++++++++++++ + 1 file changed, 21 insertions(+) + +commit 2ade7246e7ba729a91460d2fab0f4c7b89d3998b +Author: Jia Tan +Date: 2023-11-09 01:21:53 +0800 + + liblzma: Add missing comments to lz_encoder.h. + + src/liblzma/lz/lz_encoder.h | 6 +++++- + 1 file changed, 5 insertions(+), 1 deletion(-) + +commit 5fe1450603dc625340b8b7866fb4a83ff748ad06 +Author: Jia Tan +Date: 2023-11-01 20:18:30 +0800 + + Add NEWS for 5.4.5. + + NEWS | 74 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ + 1 file changed, 74 insertions(+) + +commit 46007049cd42e606543dbe650feb17bdf4469c29 +Author: Lasse Collin +Date: 2023-10-31 21:41:09 +0200 + + liblzma: Fix compilation of fastpos_tablegen.c. + + The macro lzma_attr_visibility_hidden has to be defined to make + fastpos.h usable. The visibility attribute is irrelevant to + fastpos_tablegen.c so simply #define the macro to an empty value. + + fastpos_tablegen.c is never built by the included build systems + and so the problem wasn't noticed earlier. It's just a standalone + program for generating fastpos_table.c. + + Fixes: https://github.com/tukaani-project/xz/pull/69 + Thanks to GitHub user Jamaika1. + + src/liblzma/lzma/fastpos_tablegen.c | 2 ++ + 1 file changed, 2 insertions(+) + +commit 148e20607e95781558bdfc823ecba07b7af4b590 +Author: Jia Tan +Date: 2023-10-31 21:51:40 +0800 + + Build: Fix text wrapping in an output message. + + configure.ac | 9 +++++---- + 1 file changed, 5 insertions(+), 4 deletions(-) + +commit 8c36ab79cbf23104ce7a3d533d5ac98cd492e57c +Author: Lasse Collin +Date: 2023-10-30 18:09:53 +0200 + + liblzma: Add a note why crc_always_inline exists for now. + + Solaris Studio is a possible example (not tested) which + supports the always_inline attribute but might not get + detected by the common.h #ifdefs. + + src/liblzma/check/crc_common.h | 5 +++++ + 1 file changed, 5 insertions(+) + +commit e7a86b94cd247435ac96bc79ba528b690b9ca388 +Author: Lasse Collin +Date: 2023-10-22 17:59:11 +0300 + + liblzma: Use lzma_always_inline in memcmplen.h. + + src/liblzma/common/memcmplen.h | 3 +-- + 1 file changed, 1 insertion(+), 2 deletions(-) + +commit dcfe5632992fb7f06f921da13fcdd84f83d0d285 +Author: Lasse Collin +Date: 2023-10-30 17:43:03 +0200 + + liblzma: #define lzma_always_inline in common.h. + + src/liblzma/common/common.h | 17 +++++++++++++++++ + 1 file changed, 17 insertions(+) + +commit 41113fe30a47f6fd3e30cb4494dd538e86212edf +Author: Lasse Collin +Date: 2023-10-22 17:15:32 +0300 + + liblzma: Use lzma_attr_visibility_hidden on private extern declarations. + + These variables are internal to liblzma and not exposed in the API. + + src/liblzma/check/check.h | 7 +++++++ + src/liblzma/common/stream_flags_common.h | 3 +++ + src/liblzma/lz/lz_encoder_hash.h | 1 + + src/liblzma/lzma/fastpos.h | 1 + + src/liblzma/rangecoder/price.h | 1 + + 5 files changed, 13 insertions(+) + +commit a2f5ca706acc6f7715b8d260a8c6ed50d7717478 +Author: Lasse Collin +Date: 2023-10-22 17:08:39 +0300 + + liblzma: #define lzma_attr_visibility_hidden in common.h. + + In ELF shared libs: + + -fvisibility=hidden affects definitions of symbols but not + declarations.[*] This doesn't affect direct calls to functions + inside liblzma as a linker can replace a call to lzma_foo@plt + with a call directly to lzma_foo when -fvisibility=hidden is used. + + [*] It has to be like this because otherwise every installed + header file would need to explictly set the symbol visibility + to default. + + When accessing extern variables that aren't defined in the + same translation unit, compiler assumes that the variable has + the default visibility and thus indirection is needed. Unlike + function calls, linker cannot optimize this. + + Using __attribute__((__visibility__("hidden"))) with the extern + variable declarations tells the compiler that indirection isn't + needed because the definition is in the same shared library. + + About 15+ years ago, someone told me that it would be good if + the CRC tables would be defined in the same translation unit + as the C code of the CRC functions. While I understood that it + could help a tiny amount, I didn't want to change the code because + a separate translation unit for the CRC tables was needed for the + x86 assembly code anyway. But when visibility attributes are + supported, simply marking the extern declaration with the + hidden attribute will get identical result. When there are only + a few affected variables, this is trivial to do. I wish I had + understood this back then already. + + src/liblzma/common/common.h | 11 +++++++++++ + 1 file changed, 11 insertions(+) + +commit 2c7ee92e44e1e66f0a427555233eb22c78f6c4f8 +Author: Lasse Collin +Date: 2023-09-30 22:54:28 +0300 + + liblzma: Refer to MinGW-w64 instead of MinGW in the API headers. + + MinGW (formely a MinGW.org Project, later the MinGW.OSDN Project + at ) has GCC 9.2.0 as the + most recent GCC package (released 2021-02-02). The project might + still be alive but majority of people have switched to MinGW-w64. + Thus it seems clearer to refer to MinGW-w64 in our API headers too. + Building with MinGW is likely to still work but I haven't tested it + in the recent years. + + src/liblzma/api/lzma.h | 4 ++-- + src/liblzma/api/lzma/version.h | 2 +- + 2 files changed, 3 insertions(+), 3 deletions(-) + +commit 597f49b61475438a43a417236989b2acc968a686 +Author: Lasse Collin +Date: 2023-09-27 00:58:17 +0300 + + CMake: Use -D_FILE_OFFSET_BITS=64 if (and only if) needed. + + A CMake option LARGE_FILE_SUPPORT is created if and only if + -D_FILE_OFFSET_BITS=64 affects sizeof(off_t). + + This is needed on many 32-bit platforms and even with 64-bit builds + with MinGW-w64 to get support for files larger than 2 GiB. + + CMakeLists.txt | 7 ++++- + cmake/tuklib_large_file_support.cmake | 52 +++++++++++++++++++++++++++++++++++ + 2 files changed, 58 insertions(+), 1 deletion(-) + +commit 1bc548b8210366e44ba35b0b11577a8e328c1228 +Author: Lasse Collin +Date: 2023-09-30 02:14:25 +0300 + + CMake: Generate and install liblzma.pc if not using MSVC. + + Autotools based build uses -pthread and thus adds it to Libs.private + in liblzma.pc. CMake doesn't use -pthread at all if pthread functions + are available in libc so Libs.private doesn't get -pthread either. + + CMakeLists.txt | 21 +++++++++++++++++++++ + 1 file changed, 21 insertions(+) + +commit 2add71966f891d315105d6245f724ed4f43a4eff +Author: Lasse Collin +Date: 2023-09-30 01:13:13 +0300 + + CMake: Rearrange the PACKAGE_ variables. + + The windres workaround now replaces spaces with \x20 so + the package name isn't repeated. + + These changes will help with creation of liblzma.pc. + + CMakeLists.txt | 26 +++++++++++++++----------- + 1 file changed, 15 insertions(+), 11 deletions(-) + +commit a7d1b2825c49dc83f1910eeb8ba0f1dfbd886d91 +Author: Lasse Collin +Date: 2023-09-29 20:46:11 +0300 + + liblzma: Add Cflags.private to liblzma.pc.in for MSYS2. + + It properly adds -DLZMA_API_STATIC when compiling code that + will be linked against static liblzma. Having it there on + systems other than Windows does no harm. + + See: https://www.msys2.org/docs/pkgconfig/ + + src/liblzma/liblzma.pc.in | 1 + + 1 file changed, 1 insertion(+) + +commit 80e0750e3996c1c659e972ce9cf789ca2e99f702 +Author: Lasse Collin +Date: 2023-09-27 22:46:20 +0300 + + CMake: Create liblzma.def when building liblzma.dll with MinGW-w64. + + CMakeLists.txt | 20 ++++++++++++++++++++ + cmake/remove-ordinals.cmake | 26 ++++++++++++++++++++++++++ + 2 files changed, 46 insertions(+) + +commit 08d12595f486890cf601b87f36ee0ddbce57728e +Author: Lasse Collin +Date: 2023-10-26 21:44:42 +0300 + + CMake: Change one CMAKE_CURRENT_SOURCE_DIR to CMAKE_CURRENT_LIST_DIR. + + In this case they have identical values. + + CMakeLists.txt | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit e67aaf698de75c73443a5ec786781cbf2034461d +Author: Lasse Collin +Date: 2023-10-01 19:10:57 +0300 + + CMake/Windows: Fix the import library filename. + + Both PREFIX and IMPORT_PERFIX have to be set to "" to get + liblzma.dll and liblzma.dll.a. + + CMakeLists.txt | 1 + + 1 file changed, 1 insertion(+) + +commit 88588b1246d8c26ffbc138b3e5c413c5f14c3179 +Author: Lasse Collin +Date: 2023-10-25 19:13:25 +0300 + + Build: Detect -fsanitize= in CFLAGS and incompatible build options. + + Now configure will fail if -fsanitize= is found in CFLAGS + and sanitizer-incompatible ifunc or Landlock sandboxing + would be used. These are incompatible with one or more sanitizers. + It's simpler to reject all -fsanitize= uses instead of trying to + pass those that might not cause problems. + + CMake-based build was updated similarly. It lets the configuration + finish (SEND_ERROR instead of FATAL_ERROR) so that both error + messages can be seen at once. + + CMakeLists.txt | 29 +++++++++++++++++++++++++++++ + configure.ac | 37 +++++++++++++++++++++++++++++++++---- + 2 files changed, 62 insertions(+), 4 deletions(-) + +commit 5e3d890f8862a7d4fbef5e38e11b6c9fbd98f468 +Author: Jia Tan +Date: 2023-10-24 00:50:08 +0800 + + CI: Disable sandboxing in fsanitize=address,undefined job. + + The sandboxing on Linux now supports Landlock, which restricts all + supported filesystem actions after xz opens the files it needs. The + sandbox is only enabled when one file is input and we are writing to + standard out. With fsanitize=address,undefined, the instrumentation + needs to read additional files after the sandbox is in place. This + forces all xz based test to fail, so the sandbox must instead be + disabled. + + .github/workflows/ci.yml | 8 ++++++-- + 1 file changed, 6 insertions(+), 2 deletions(-) + +commit b1408987ea832e2760e478ae960a636df17a1363 +Author: Jia Tan +Date: 2023-10-24 00:15:39 +0800 + + CI: Allow disabling the sandbox in ci_build.sh. + + build-aux/ci_build.sh | 5 ++++- + 1 file changed, 4 insertions(+), 1 deletion(-) + +commit 91c435cf1c7a1e893706d4d716dfd361621ed824 +Author: Lasse Collin +Date: 2023-10-11 19:47:44 +0300 + + CMake: Don't shadow the cache entry ENABLE_THREADS with a normal variable. + + Using set(ENABLE_THREADS "posix") is confusing because it sets + a new normal variable and leaves the cache entry with the same + name unchanged. The intent wasn't to change the cache entry so + this switches to a different variable name. + + CMakeLists.txt | 10 +++++++--- + 1 file changed, 7 insertions(+), 3 deletions(-) + +commit fa1609eb9393ecd30decfed4891c907829f06710 +Author: Lasse Collin +Date: 2023-10-09 22:28:49 +0300 + + Docs: Update INSTALL about sandboxing support. + + INSTALL | 7 ++++++- + 1 file changed, 6 insertions(+), 1 deletion(-) + +commit 8276c7f41c671eee4aa3239490658b23dcfd3021 +Author: Lasse Collin +Date: 2023-10-09 22:07:52 +0300 + + xz: Support basic sandboxing with Linux Landlock (ABI versions 1-3). + + It is enabled only when decompressing one file to stdout, + similar to how Capsicum is used. + + Landlock was added in Linux 5.13. + + CMakeLists.txt | 12 +++++++++++- + configure.ac | 11 ++++++++--- + src/xz/file_io.c | 58 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ + src/xz/main.c | 19 +++++++++++++++++++ + src/xz/private.h | 3 ++- + 5 files changed, 98 insertions(+), 5 deletions(-) + +commit 3a1e9fd031b9320d769d63b503ef4e82e1b6ea8c +Author: Lasse Collin +Date: 2023-10-09 21:12:31 +0300 + + CMake: Edit threading related messages. + + It's mostly to change from "thread method" to "threading method". + + CMakeLists.txt | 19 ++++++++++--------- + 1 file changed, 10 insertions(+), 9 deletions(-) + +commit bf011352528ae3539ea7b780b45b96736ee57a99 +Author: Lasse Collin +Date: 2023-10-09 20:59:24 +0300 + + CMake: Use FATAL_ERROR if user-supplied options aren't understood. + + This way typos are caught quickly and compounding error messages + are avoided (a single typo could cause more than one error). + + This keeps using SEND_ERROR when the system is lacking a feature + (like threading library or sandboxing method). This way the whole + configuration log will be generated in case someone wishes to + report a problem upstream. + + CMakeLists.txt | 28 ++++++++++++++-------------- + 1 file changed, 14 insertions(+), 14 deletions(-) + +commit 3f53870c249945d657ca3d75e0993e6267d71f75 +Author: Lasse Collin +Date: 2023-10-09 18:37:32 +0300 + + CMake: Add sandboxing support. + + CMakeLists.txt | 50 +++++++++++++++++++++++++++++++++++++++++++++++++- + 1 file changed, 49 insertions(+), 1 deletion(-) + +commit 2e2cd11535ad77364cf021297e0b3f162fa3a3d0 +Author: Lasse Collin +Date: 2023-10-09 18:13:08 +0300 + + Simplify detection of Capsicum support. + + This removes support for FreeBSD 10.0 and 10.1 which used + instead of . Support for + FreeBSD 10.1 ended on 2016-12-31. So now FreeBSD >= 10.2 is + required to enable Capsicum support. + + This also removes support for Capsicum on Linux (libcaprights) + which seems to have been unmaintained since 2017 and Linux 4.11: + https://github.com/google/capsicum-linux + + configure.ac | 4 +-- + m4/ax_check_capsicum.m4 | 85 ------------------------------------------------- + src/xz/Makefile.am | 2 +- + src/xz/file_io.c | 14 +++----- + src/xz/private.h | 2 +- + 5 files changed, 9 insertions(+), 98 deletions(-) + +commit c57858b60e186d020b2dbaf7aabd9b32c71da824 +Author: Lasse Collin +Date: 2023-09-25 01:46:36 +0300 + + xz/Windows: Allow clock_gettime with POSIX threads. + + If winpthreads are used for threading, it's OK to use clock_gettime() + from winpthreads too. + + src/xz/mytime.c | 9 ++++++--- + 1 file changed, 6 insertions(+), 3 deletions(-) + +commit dd32f628bb5541ef4e8ce66966ef456a1934084c +Author: Lasse Collin +Date: 2023-09-25 01:39:26 +0300 + + mythread.h: Make MYTHREAD_POSIX compatible with MinGW-w64's winpthreads. + + This might be almost useless but it doesn't need much extra code either. + + src/common/mythread.h | 23 ++++++++++++++++++++++- + 1 file changed, 22 insertions(+), 1 deletion(-) + +commit 680e52cdd086e92691d8a0bca2c98815565f60ca +Author: Lasse Collin +Date: 2023-09-23 03:06:36 +0300 + + CMake: Check for clock_gettime() even on Windows. + + This mirrors configure.ac although currently MinGW-w64 builds + don't use clock_gettime() even if it is found. + + CMakeLists.txt | 44 +++++++++++++++++++++----------------------- + 1 file changed, 21 insertions(+), 23 deletions(-) + +commit 1c1a8c3ee4dad0064dbe63b8dbc4ac4bc679f419 +Author: Lasse Collin +Date: 2023-09-23 03:23:32 +0300 + + Build: Check for clock_gettime() even if not using POSIX threads. + + See the new comment in the code. + + This also makes the check for clock_gettime() run with MinGW-w64 + with which we don't want to use clock_gettime(). The previous + commit already took care of this situation. + + configure.ac | 31 ++++++++++++++++++------------- + 1 file changed, 18 insertions(+), 13 deletions(-) + +commit 46fd991cd2808ef62554853864c946232e7547f0 +Author: Lasse Collin +Date: 2023-09-24 22:58:53 +0300 + + xz/Windows: Ensure that clock_gettime() isn't used with MinGW-w64. + + This commit alone doesn't change anything in the real-world: + + - configure.ac currently checks for clock_gettime() only + when using pthreads. + + - CMakeLists.txt doesn't check for clock_gettime() on Windows. + + So clock_gettime() wasn't used with MinGW-w64 before either. + + clock_gettime() provides monotonic time and it's better than + gettimeofday() in this sense. But clock_gettime() is defined + in winpthreads, and liblzma or xz needs nothing else from + winpthreads. By avoiding clock_gettime(), we avoid the dependency on + libwinpthread-1.dll or the need to link against the static version. + + As a bonus, GetTickCount64() and MinGW-w64's gettimeofday() can be + faster than clock_gettime(CLOCK_MONOTONIC, &tv). The resolution + is more than good enough for the progress indicator in xz. + + src/xz/mytime.c | 9 +++++++-- + 1 file changed, 7 insertions(+), 2 deletions(-) + +commit cdb4d91f2464b50c985ef7b9517314ea237ddda7 +Author: Lasse Collin +Date: 2023-09-24 00:21:22 +0300 + + xz/Windows: Use GetTickCount64() with MinGW-w64 if using Vista threads. + + src/xz/mytime.c | 14 +++++++++++--- + 1 file changed, 11 insertions(+), 3 deletions(-) + +commit 988e09f27b9b04a43d45d10f92782e0092ee27a9 +Author: Jia Tan +Date: 2023-10-20 19:17:46 +0800 + + liblzma: Move is_clmul_supported() back to crc_common.h. + + This partially reverts creating crc_clmul.c + (8c0f9376f58c0696d5d6719705164d35542dd891) where is_clmul_supported() + was moved, extern'ed, and renamed to lzma_is_clmul_supported(). This + caused a problem when the function call to lzma_is_clmul_supported() + results in a call through the PLT. ifunc resolvers run very early in + the dynamic loading sequence, so the PLT may not be setup properly at + this point. Whether the PLT is used or not for + lzma_is_clmul_supported() depened upon the compiler-toolchain used and + flags. + + In liblzma compiled with GCC, for instance, GCC will go through the PLT + for function calls internal to liblzma if the version scripts and + symbol visibility hiding are not used. If lazy-binding is disabled, + then it would have made any program linked with liblzma fail during + dynamic loading in the ifunc resolver. + + src/liblzma/check/crc32_fast.c | 2 +- + src/liblzma/check/crc64_fast.c | 2 +- + src/liblzma/check/crc_clmul.c | 45 ------------------------------------ + src/liblzma/check/crc_common.h | 52 +++++++++++++++++++++++++++++++++++++++--- + 4 files changed, 51 insertions(+), 50 deletions(-) + +commit 105c7ca90d4152942e0798580a37f736d02faa22 +Author: Jia Tan +Date: 2023-10-19 16:23:32 +0800 + + Build: Remove check for COND_CHECK_CRC32 in check/Makefile.inc. + + Currently crc32 is always enabled, so COND_CHECK_CRC32 must always be + set. Because of this, it makes the recent change to conditionally + compile check/crc_clmul.c appear wrong since that file has CLMUL + implementations for both CRC32 and CRC64. + + src/liblzma/check/Makefile.inc | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +commit 139757170468f0f1fafdf0a8ffa74363d1ea1d0c +Author: Jia Tan +Date: 2023-10-19 16:09:01 +0800 + + CMake: Add ALLOW_CLMUL_CRC option to enable/disable CLMUL. + + The option is enabled by default, but will only be visible to a user + listing cache variables or using a CMake GUI application if the + immintrin.h header file is found. + + This mirrors our Autotools build --disable-clmul-crc functionality. + + CMakeLists.txt | 44 +++++++++++++++++++++++++------------------- + 1 file changed, 25 insertions(+), 19 deletions(-) + +commit c60b25569d414bb73b705977a4dd342f8f9f1965 +Author: Jia Tan +Date: 2023-10-19 00:22:50 +0800 + + liblzma: Fix -fsanitize=address failure with crc_clmul functions. + + After forcing crc_simd_body() to always be inlined it caused + -fsanitize=address to fail for lzma_crc32_clmul() and + lzma_crc64_clmul(). The __no_sanitize_address__ attribute was added + to lzma_crc32_clmul() and lzma_crc64_clmul(), but not removed from + crc_simd_body(). ASAN and inline functions behavior has changed over + the years for GCC specifically, so while strictly required we will + keep __attribute__((__no_sanitize_address__)) on crc_simd_body() in + case this becomes a requirement in the future. + + Older GCC versions refuse to inline a function with ASAN if the + caller and callee do not agree on sanitization flags + (https://gcc.gnu.org/bugzilla/show_bug.cgi?id=89124#c3). If the + function was forced to be inlined, it will not compile if the callee + function has __no_sanitize_address__ but the caller doesn't. + + src/liblzma/check/crc_clmul.c | 6 ++++++ + 1 file changed, 6 insertions(+) + +commit 9a78971261bc67622cbd7dae02f6966968ac1393 +Author: Lasse Collin +Date: 2023-10-14 20:16:13 +0300 + + tuklib_integer: Update the CMake test for fast unaligned access. + + cmake/tuklib_integer.cmake | 69 ++++++++++++++++++++++++++++++++++++---------- + 1 file changed, 54 insertions(+), 15 deletions(-) + +commit 2f81ac852bc5aafc91c8e2adc66b5114761703c4 +Author: Lasse Collin +Date: 2023-09-23 23:28:48 +0300 + + Build: Enabled unaligned access by default on PowerPC64LE and some RISC-V. + + PowerPC64LE wasn't tested but it seems like a safe change. + POWER8 supports unaligned access in little endian mode. Testing + on godbolt.org shows that GCC uses unaligned access by default. + + The RISC-V macro __riscv_misaligned_fast is very new and not + in any stable compiler release yet. + + Documentation in INSTALL was updated to match. + + Documentation about an autodetection bug when using ARM64 GCC + with -mstrict-align was added to INSTALL. + + CMake files weren't updated yet. + + INSTALL | 39 +++++++++++++++++++++++++++++++++++++-- + m4/tuklib_integer.m4 | 34 +++++++++++++++++++++++++++------- + 2 files changed, 64 insertions(+), 9 deletions(-) + +commit c8f715f1bca4c30db814fcf1fd2fe88b8992ede2 +Author: Lasse Collin +Date: 2023-10-14 17:56:59 +0300 + + tuklib_integer: Revise unaligned reads and writes on strict-align archs. + + In XZ Utils context this doesn't matter much because + unaligned reads and writes aren't used in hot code + when TUKLIB_FAST_UNALIGNED_ACCESS isn't #defined. + + src/common/tuklib_integer.h | 256 ++++++++++++++++++++++++++++++++------------ + 1 file changed, 189 insertions(+), 67 deletions(-) + +commit 6828242735cbf61b93d140383336e1e51a006f2d +Author: Lasse Collin +Date: 2023-09-23 02:21:49 +0300 + + tuklib_integer: Add missing write64be and write64le fallback functions. + + src/common/tuklib_integer.h | 34 ++++++++++++++++++++++++++++++++++ + 1 file changed, 34 insertions(+) + +commit 1c8884f0af28b3a4690bb573cdf3240a8ec73416 +Author: Jia Tan +Date: 2023-10-18 19:57:10 +0800 + + liblzma: Set the MSVC optimization fix to only cover lzma_crc64_clmul(). + + After testing a 32-bit Release build on MSVC, only lzma_crc64_clmul() + has the bug. crc_simd_body() and lzma_crc32_clmul() do not need the + optimizations disabled. + + src/liblzma/check/crc_clmul.c | 30 +++++++++++++++--------------- + 1 file changed, 15 insertions(+), 15 deletions(-) + +commit 5ce0f7a48bdf5c3b45430850a4487307afac6143 +Author: Lasse Collin +Date: 2023-10-18 14:30:00 +0300 + + liblzma: CRC_USE_GENERIC_FOR_SMALL_INPUTS cannot be used with ifunc. + + src/liblzma/check/crc_common.h | 4 +++- + 1 file changed, 3 insertions(+), 1 deletion(-) + +commit 27735380491bb5ce0d0f41d5244d89c1d0825f6b +Author: Lasse Collin +Date: 2023-10-17 21:53:11 +0300 + + liblzma: Include common.h in crc_common.h. + + crc_common.h depends on common.h. The headers include common.h except + when there is a reason to not do so. + + src/liblzma/check/crc_clmul.c | 1 - + src/liblzma/check/crc_common.h | 3 +++ + 2 files changed, 3 insertions(+), 1 deletion(-) + +commit e13b7947b92355c334edd594295d3a2c99c4bca1 +Author: Jia Tan +Date: 2023-10-18 01:23:26 +0800 + + liblzma: Add include guards to crc_common.h. + + src/liblzma/check/crc_common.h | 5 +++++ + 1 file changed, 5 insertions(+) + +commit 40abd88afcc61a8157fcd12d78d491caeb8e12be +Author: Jia Tan +Date: 2023-10-18 22:50:25 +0800 + + liblzma: Add the crc_always_inline macro to crc_simd_body(). + + Forcing this to be inline has a significant speed improvement at the + cost of a few repeated instructions. The compilers tested on did not + inline this function since it is large and is used twice in the same + translation unit. + + src/liblzma/check/crc_clmul.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit a5966c276bd6fa975f0389f8a8dc61393de750b0 +Author: Jia Tan +Date: 2023-10-18 22:48:19 +0800 + + liblzma: Create crc_always_inline macro. + + This macro must be used instead of the inline keyword. On MSVC, it is + a replacement for __forceinline which is an MSVC specific keyword that + should not be used with inline (it will issue a warning if it is). + + It does not use a build system check to determine if + __attribute__((__always_inline__)) since all compilers that can use + CLMUL extensions (except the special case for MSVC) should support this + attribute. If this assumption is incorrect then it will result in a bug + report instead of silently producing slow code. + + src/liblzma/check/crc_common.h | 15 +++++++++++++++ + 1 file changed, 15 insertions(+) + +commit 96b663f67c0e738a99ba8f35d9f4ced9add74544 +Author: Jia Tan +Date: 2023-10-14 13:23:23 +0800 + + liblzma: Refactor CRC comments. + + A detailed description of the three dispatch methods was added. Also, + duplicated comments now only appear in crc32_fast.c or were removed from + both crc32_fast.c and crc64_fast.c if they appeared in crc_clmul.c. + + src/liblzma/check/crc32_fast.c | 64 +++++++++++++++++++++++++++++------------- + src/liblzma/check/crc64_fast.c | 61 ++++++---------------------------------- + 2 files changed, 53 insertions(+), 72 deletions(-) + +commit 8c0f9376f58c0696d5d6719705164d35542dd891 +Author: Jia Tan +Date: 2023-10-14 12:17:57 +0800 + + liblzma: Create crc_clmul.c. + + Both crc32_clmul() and crc64_clmul() are now exported from + crc32_clmul.c as lzma_crc32_clmul() and lzma_crc64_clmul(). This + ensures that is_clmul_supported() (now lzma_is_clmul_supported()) is + not duplicated between crc32_fast.c and crc64_fast.c. + + Also, it encapsulates the complexity of the CLMUL implementations into a + single file and reduces the complexity of crc32_fast.c and crc64_fast.c. + Before, CLMUL code was present in crc32_fast.c, crc64_fast.c, and + crc_common.h. + + During the conversion, various cleanups were applied to code (thanks to + Lasse Collin) including: + + - Require using semicolons with MASK_/L/H/LH macros. + - Variable typing and const handling improvements. + - Improvements to comments. + - Fixes to the pragmas used. + - Removed unneeded variables. + - Whitespace improvements. + - Fixed CRC_USE_GENERIC_FOR_SMALL_INPUTS handling. + - Silenced warnings and removed the need for some #pragmas + + CMakeLists.txt | 6 +- + configure.ac | 6 +- + src/liblzma/check/Makefile.inc | 3 + + src/liblzma/check/crc32_fast.c | 120 +----------- + src/liblzma/check/crc64_fast.c | 128 +------------ + src/liblzma/check/crc_clmul.c | 414 +++++++++++++++++++++++++++++++++++++++++ + src/liblzma/check/crc_common.h | 190 +------------------ + 7 files changed, 444 insertions(+), 423 deletions(-) + +commit a3ebc2c516b09616638060806c841bd4bcf7bce3 +Author: Jia Tan +Date: 2023-10-14 10:23:03 +0800 + + liblzma: Define CRC_USE_IFUNC in crc_common.h. + + When ifunc is supported, we can define a simpler macro instead of + repeating the more complex check in both crc32_fast.c and crc64_fast.c. + + src/liblzma/check/crc32_fast.c | 3 +-- + src/liblzma/check/crc64_fast.c | 3 +-- + src/liblzma/check/crc_common.h | 5 +++++ + 3 files changed, 7 insertions(+), 4 deletions(-) + +commit f1cd9d7194f005cd66ec03c6635ceae75f90ef17 +Author: Hans Jansen +Date: 2023-10-12 19:37:01 +0200 + + liblzma: Added crc32_clmul to crc32_fast.c. + + src/liblzma/check/crc32_fast.c | 247 ++++++++++++++++++++++++++++++++++++++-- + src/liblzma/check/crc32_table.c | 19 +++- + 2 files changed, 255 insertions(+), 11 deletions(-) + +commit 93e6fb08b22c7c13be2dd1e7274fe78413436254 +Author: Hans Jansen +Date: 2023-10-12 19:23:40 +0200 + + liblzma: Moved CLMUL CRC logic to crc_common.h. + + crc64_fast.c was updated to use the code from crc_common.h instead. + + src/liblzma/check/crc64_fast.c | 257 ++--------------------------------------- + src/liblzma/check/crc_common.h | 230 +++++++++++++++++++++++++++++++++++- + 2 files changed, 240 insertions(+), 247 deletions(-) + +commit 233885a437f8b55a5c8442984ebc0aaa579e92de +Author: Hans Jansen +Date: 2023-10-12 19:07:50 +0200 + + liblzma: Rename crc_macros.h to crc_common.h. + + CMakeLists.txt | 2 +- + src/liblzma/check/Makefile.inc | 2 +- + src/liblzma/check/crc32_fast.c | 2 +- + src/liblzma/check/crc64_fast.c | 2 +- + src/liblzma/check/{crc_macros.h => crc_common.h} | 2 +- + 5 files changed, 5 insertions(+), 5 deletions(-) + +commit 37947d4a7565b87e4cec8b89229d35b0a3f8d2cd +Author: Gabriela Gutierrez +Date: 2023-09-26 15:55:13 +0000 + + CI: Bump and ref actions by commit SHA in windows-ci.yml + + Referencing actions by commit SHA in GitHub workflows guarantees you are using an immutable version. Actions referenced by tags and branches are more vulnerable to attacks, such as the tag being moved to a malicious commit or a malicious commit being pushed to the branch. + + It's important to make sure the SHA's are from the original repositories and not forks. + + For reference: + + https://github.com/msys2/setup-msys2/releases/tag/v2.20.1 + https://github.com/msys2/setup-msys2/commit/27b3aa77f672cb6b3054121cfd80c3d22ceebb1d + + https://github.com/actions/checkout/releases/tag/v4.1.0 + https://github.com/actions/checkout/commit/8ade135a41bc03ea155e62e844d188df1ea18608 + + https://github.com/actions/upload-artifact/releases/tag/v3.1.3 + https://github.com/actions/upload-artifact/commit/a8a3f3ad30e3422c9c7b888a15615d19a852ae32 + + Signed-off-by: Gabriela Gutierrez + + .github/workflows/windows-ci.yml | 6 +++--- + 1 file changed, 3 insertions(+), 3 deletions(-) + +commit f28cc9bd481ce493da11f98c18526d324211599a +Author: Gabriela Gutierrez +Date: 2023-09-26 14:35:08 +0000 + + CI: Bump and ref actions by commit SHA in ci.yml + + Referencing actions by commit SHA in GitHub workflows guarantees you are using an immutable version. Actions referenced by tags and branches are more vulnerable to attacks, such as the tag being moved to a malicious commit or a malicious commit being pushed to the branch. + + It's important to make sure the SHA's are from the original repositories and not forks. + + For reference: + + https://github.com/actions/checkout/releases/tag/v4.1.0 + https://github.com/actions/checkout/commit/8ade135a41bc03ea155e62e844d188df1ea18608 + + https://github.com/actions/upload-artifact/releases/tag/v3.1.3 + https://github.com/actions/upload-artifact/commit/a8a3f3ad30e3422c9c7b888a15615d19a852ae32 + + Signed-off-by: Gabriela Gutierrez + + .github/workflows/ci.yml | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +commit f74f1740067b75042497edbfa6ea457ff75484b9 +Author: Jia Tan +Date: 2023-10-12 20:12:18 +0800 + + Build: Update visibility.m4 from Gnulib. + + Updating from version 6 -> 8 from upstream. Declarations for variables + and function bodies were added to avoid unnecessary failures with + -Werror. + + m4/visibility.m4 | 9 +++++++-- + 1 file changed, 7 insertions(+), 2 deletions(-) + +commit 5c4bca521e6fb435898a0012b3276eee70a6dadf +Author: Lasse Collin +Date: 2023-10-06 19:36:35 +0300 + + Update THANKS. + + THANKS | 1 + + 1 file changed, 1 insertion(+) + +commit d91cb6e884c73d0b05d7e7d68ad4e6eb29f4b44b +Author: Lasse Collin +Date: 2023-10-06 18:55:57 +0300 + + CMake/Windows: Fix when the windres workaround is applied. + + CMake doesn't set WIN32 on CYGWIN but the workaround is + probably needed on Cygwin too. Same for MSYS and MSYS2. + + The workaround must not be used with Clang that is acting in + MSVC mode. This fixes it by checking for the known environments + that need the workaround instead of using "NOT MSVC". + + Thanks to Martin Storsjö. + https://github.com/tukaani-project/xz/commit/0570308ddd9c0e39e85597ebc0e31d4fc81d436f#commitcomment-129098431 + + CMakeLists.txt | 6 +++--- + 1 file changed, 3 insertions(+), 3 deletions(-) + +commit 01e34aa1171b04f8b28960b1cc6135a903e0c13d +Author: Jia Tan +Date: 2023-09-29 22:11:54 +0800 + + CI: Disable CLANG64 MSYS2 environment until bug is resolved. + + lld 17.0.1 searches for libraries to link first in the toolchain + directories before the local directory when building. The is a problem + for us because liblzma.a is installed in MSYS2 CLANG64 by default and + xz.exe will thus use the installed library instead of the one being + built. + + This causes tests to fail when they are expecting features to be + disabled. More importantly, it will compile xz.exe with an incorrect + liblzma and could cause unexpected behavior by being unable to update + liblzma code in static builds. The CLANG64 environment can be tested + again once this is fixed. + + Link to bug: https://github.com/llvm/llvm-project/issues/67779. + + .github/workflows/windows-ci.yml | 8 +++++--- + 1 file changed, 5 insertions(+), 3 deletions(-) + +commit 30d0c35327f3639cb11224872aa58fdbf0b1526e +Author: Jia Tan +Date: 2023-09-29 20:14:39 +0800 + + CMake: Rename xz and man page symlink custom targets. + + The Ninja Generator for CMake cannot have a custom target and its + BYPRODUCTS have the same name. This has prevented Ninja builds on + Unix-like systems since the xz symlinks were introduced in + 80a1a8bb838842a2be343bd88ad1462c21c5e2c9. + + CMakeLists.txt | 6 +++--- + 1 file changed, 3 insertions(+), 3 deletions(-) + +commit 506d03127a8565442b028ec991e1578124fd3025 +Author: Jia Tan +Date: 2023-09-29 19:58:44 +0800 + + CMake: Specify LINKER_LANGUAGE for libgnu target to fix Ninja Generator. + + CMake is unable to guess the linker language for just a header file so + it must be explicitly set. + + CMakeLists.txt | 6 ++++++ + 1 file changed, 6 insertions(+) + +commit 0570308ddd9c0e39e85597ebc0e31d4fc81d436f +Author: Lasse Collin +Date: 2023-09-27 19:54:35 +0300 + + CMake: Fix Windows build with Clang/LLVM 17. + + llvm-windres 17.0.0 has more accurate emulation of GNU windres, so + the hack for GNU windres must now be used with llvm-windres too. + + LLVM 16.0.6 has the old behavior and there likely won't be more + 16.x releases. So we can simply check for >= 17.0.0. + + See also: + https://github.com/llvm/llvm-project/commit/2bcc0fdc58a220cb9921b47ec8a32c85f2511a47 + + CMakeLists.txt | 26 ++++++++++++++------------ + 1 file changed, 14 insertions(+), 12 deletions(-) + +commit 5a9af95f85a7e5d4f9c10cb8cf737651a921f1d1 +Author: Lasse Collin +Date: 2023-09-26 21:47:13 +0300 + + liblzma: Update a comment. + + The C standards don't allow an empty translation unit which can be + avoided by declaring something, without exporting any symbols. + + When I committed f644473a211394447824ea00518d0a214ff3f7f2 I had + a feeling that some specific toolchain somewhere didn't like + empty object files (assembler or maybe "ar" complained) but + I cannot find anything to confirm this now. Quite likely I + remembered nonsense. I leave this here as a note to my future self. :-) + + src/liblzma/check/crc64_table.c | 3 +-- + 1 file changed, 1 insertion(+), 2 deletions(-) + +commit 8ebaf3f665ddc7e4f19c613005050dde5ccbe499 +Author: Jia Tan +Date: 2023-09-27 00:02:11 +0800 + + liblzma: Avoid compiler warning without creating extra symbol. + + When the generic fast crc64 method is used, then we omit + lzma_crc64_table[][]. Similar to + d9166b52cf3458a4da3eb92224837ca8fc208d79, we can avoid compiler warnings + with -Wempty-translation-unit (Clang) or -pedantic (GCC) by creating a + never used typedef instead of an extra symbol. + + src/liblzma/check/crc64_table.c | 3 +-- + 1 file changed, 1 insertion(+), 2 deletions(-) + +commit 092d21db2e5eea19fe079264ce48c178989c7606 +Author: Lasse Collin +Date: 2023-09-26 17:24:15 +0300 + + Build: Update the comment about -Werror usage in checks. + + configure.ac | 10 ++++++++-- + 1 file changed, 8 insertions(+), 2 deletions(-) + +commit a37a2763383e6c204fe878e1416dd35e7711d3a9 +Author: Lasse Collin +Date: 2023-09-26 15:00:43 +0300 + + Build: Fix __attribute__((ifunc(...))) detection with clang -Wall. + + Now if user-supplied CFLAGS contains -Wall -Wextra -Wpedantic + the two checks that need -Werror will still work. + + At CMake side there is add_compile_options(-Wall -Wextra) + but it didn't affect the -Werror tests. So with both Autotools + and CMake only user-supplied CFLAGS could make the checks fail + when they shouldn't. + + This is not a full fix as things like -Wunused-macros in + user-supplied CFLAGS will still cause problems with both + GCC and Clang. + + CMakeLists.txt | 8 ++++++++ + configure.ac | 8 ++++++++ + 2 files changed, 16 insertions(+) + +commit 9c42f936939b813f25d0ff4e99c3eb9c2d17a0d2 +Author: Lasse Collin +Date: 2023-09-26 13:51:31 +0300 + + Build: Fix underquoted AC_LANG_SOURCE. + + It made no practical difference in this case. + + configure.ac | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit 9f1444a8a5c0e724b2c7ef83424f642f07a95982 +Author: Lasse Collin +Date: 2023-09-26 13:14:37 +0300 + + Build: Silence two Autoconf warnings. + + There were two uses of AC_COMPILE_IFELSE that didn't use + AC_LANG_SOURCE and Autoconf warned about these. The omission + had been intentional but it turned out that this didn't do + what I thought it would. + + Autoconf 2.71 manual gives an impression that AC_LANG_SOURCE + inserts all #defines that have been made with AC_DEFINE so + far (confdefs.h). The idea was that omitting AC_LANG_SOURCE + would mean that only the exact code included in the + AC_COMPILE_IFELSE call would be compiled. + + With C programs this is not true: the #defines get added without + AC_LANG_SOURCE too. There seems to be no neat way to avoid this. + Thus, with the C language at least, adding AC_LANG_SOURCE makes + no other difference than silencing a warning from Autoconf. The + generated "configure" remains identical. (Docs of AC_LANG_CONFTEST + say that the #defines have been inserted since Autoconf 2.63b and + that AC_COMPILE_IFELSE uses AC_LANG_CONFTEST. So the behavior is + documented if one also reads the docs of macros that one isn't + calling directly.) + + Any extra code, including #defines, can cause problems for + these two tests because these tests must use -Werror. + CC=clang CFLAGS=-Weverything is the most extreme example. + It enables -Wreserved-macro-identifier which warns about + #define __EXTENSIONS__ 1 because it begins with two underscores. + It's possible to write a test file that passes -Weverything but + it becomes impossible when Autoconf inserts confdefs.h. + + So this commit adds AC_LANG_SOURCE to silence Autoconf warnings. + A different solution is needed for -Werror tests. + + configure.ac | 9 ++++----- + 1 file changed, 4 insertions(+), 5 deletions(-) + +commit 519e47c2818acde571fadc79551294527fe6cc22 +Author: Jia Tan +Date: 2023-09-26 01:17:11 +0800 + + CMake: Remove accidental extra newline. + + CMakeLists.txt | 1 - + 1 file changed, 1 deletion(-) + +commit bbb42412da6a02705ba3e668e90840c2683e4e67 +Author: Jia Tan +Date: 2023-09-26 00:47:26 +0800 + + Build: Remove Gnulib dependency from tests. + + The tests do not use any Gnulib replacements so they do not need to link + libgnu.a or have /lib in the include path. + + tests/Makefile.am | 7 +------ + 1 file changed, 1 insertion(+), 6 deletions(-) + +commit d265f6b75691c6c8fa876eb5320c3ff5aed17dfa +Author: Jia Tan +Date: 2023-09-26 00:43:43 +0800 + + CMake: Remove /lib from tests include path. + + The tests never included anything from /lib, so this was not needed. + + CMakeLists.txt | 1 - + 1 file changed, 1 deletion(-) + +commit 9fb5de41f2fb654ca952d4bda15cf3777c2b720f +Author: Jia Tan +Date: 2023-09-24 22:10:41 +0800 + + Scripts: Change quoting style from `...' to '...'. + + src/scripts/xzdiff.in | 2 +- + src/scripts/xzgrep.in | 2 +- + 2 files changed, 2 insertions(+), 2 deletions(-) + +commit eaebdef4d4de3c088b0905f42626b74e0d23abf3 +Author: Jia Tan +Date: 2023-09-24 22:10:18 +0800 + + xz: Change quoting style from `...' to '...'. + + src/xz/args.c | 6 +++--- + src/xz/file_io.c | 2 +- + src/xz/main.c | 4 ++-- + src/xz/message.c | 14 +++++++------- + src/xz/options.c | 2 +- + src/xz/suffix.c | 2 +- + src/xz/util.c | 6 +++--- + 7 files changed, 18 insertions(+), 18 deletions(-) + +commit f6667702bf075a05fbe336dbf3576ad1a82ec645 +Author: Jia Tan +Date: 2023-09-24 22:09:47 +0800 + + liblzma: Change quoting style from `...' to '...'. + + This was done for both internal and API headers. + + src/liblzma/api/lzma/base.h | 18 +++++++++--------- + src/liblzma/api/lzma/container.h | 10 +++++----- + src/liblzma/api/lzma/filter.h | 6 +++--- + src/liblzma/api/lzma/index.h | 8 ++++---- + src/liblzma/api/lzma/lzma12.h | 2 +- + src/liblzma/lz/lz_encoder.h | 2 +- + src/liblzma/rangecoder/range_decoder.h | 2 +- + 7 files changed, 24 insertions(+), 24 deletions(-) + +commit be012b8097a4eaee335b51357d6befa745f753ce +Author: Jia Tan +Date: 2023-09-24 22:09:16 +0800 + + Build: Change quoting style from `...' to '...'. + + configure.ac | 18 +++++++++--------- + dos/config.h | 6 +++--- + m4/getopt.m4 | 2 +- + m4/tuklib_progname.m4 | 2 +- + windows/build.bash | 2 +- + 5 files changed, 15 insertions(+), 15 deletions(-) + +commit ce162db07f03495bd333696e66883c8f36abdc1e +Author: Jia Tan +Date: 2023-09-24 22:05:02 +0800 + + Docs: Change quoting style from `...' to '...'. + + These days the ` and ' do not look symmetric. This quoting style has + been changed in various apps over the years including the GNU tools. + + INSTALL | 6 +++--- + doc/examples/01_compress_easy.c | 2 +- + doc/examples/11_file_info.c | 16 ++++++++-------- + 3 files changed, 12 insertions(+), 12 deletions(-) + +commit db17656721e43939bfa4ec13506e7c76f4b86da6 +Author: Jia Tan +Date: 2023-09-24 21:25:01 +0800 + + lib: Silence -Wsign-conversion in getopt.c. + + lib/getopt.c | 6 +++--- + 1 file changed, 3 insertions(+), 3 deletions(-) + +commit a6234f677d66888f435010bc0b67de6a32fefcf6 +Author: Jia Tan +Date: 2023-09-24 20:48:52 +0800 + + Build: Update getopt.m4 from Gnulib. + + This file was modified from upstream since we do not need to replace + getopt() and can avoid complexity and feature tests. + + m4/getopt.m4 | 79 ++++++++++++++++++++++++++++++------------------------------ + 1 file changed, 39 insertions(+), 40 deletions(-) + +commit 84808b68f1075e8603a8ef95d361a61fdc6a5b10 +Author: Jia Tan +Date: 2023-09-26 00:09:53 +0800 + + CMake: Add /lib to include path. + + CMakeLists.txt | 5 +++++ + 1 file changed, 5 insertions(+) + +commit 01804a0b4b64e0f33568e947e0579263808c59d3 +Author: Jia Tan +Date: 2023-09-24 20:36:34 +0800 + + CMake: Update libgnu target with new header files. + + CMakeLists.txt | 5 +++++ + 1 file changed, 5 insertions(+) + +commit d34558388fe1d8929f6478d61dc322eb4f2900af +Author: Jia Tan +Date: 2023-09-23 00:47:52 +0800 + + lib: Update Makefile.am for new header files. + + lib/Makefile.am | 12 +++++++++++- + 1 file changed, 11 insertions(+), 1 deletion(-) + +commit 52bf644bdf536e20fcc743b712cede135e05eec5 +Author: Jia Tan +Date: 2023-09-24 20:34:03 +0800 + + lib: Update getopt1.c from Gnulib. + + The only difference was maintaining the conditional inclusion for + config.h. + + lib/getopt1.c | 56 ++++++++++++++++++++++---------------------------------- + 1 file changed, 22 insertions(+), 34 deletions(-) + +commit 7e884c00d0093c38339f17fb1d280eec493f42ca +Author: Jia Tan +Date: 2023-09-23 03:27:00 +0800 + + lib: Update getopt.in.h from Gnulib with modifications. + + We can still avoid modifying the contents of this file during + configuration to simplify the build systems. Gnulib added replacements + for inclusions guards for Cygwin. Cygwin should not need getopt_long + replacement so this feature can be omitted. + + is conditionally included to avoid MSVC since it is not + available. + + The definition for _GL_ARG_NONNULL was also copied into this file from + Gnulib since this stage is usually done during gnulib-tool. + + lib/getopt.in.h | 228 +++++++------------------------------------------------- + 1 file changed, 29 insertions(+), 199 deletions(-) + +commit cff05f82066ca3ce9425dafdb086325a8eef8de3 +Author: Jia Tan +Date: 2023-09-23 00:31:55 +0800 + + lib: Update getopt_int.h from Gnulib. + + lib/getopt_int.h | 109 ++++++++++++++++++++++++------------------------------- + 1 file changed, 48 insertions(+), 61 deletions(-) + +commit 04bd86a4b010d43c6a016a3857ecb38dc1d5b024 +Author: Jia Tan +Date: 2023-09-23 00:27:23 +0800 + + lib: Update getopt.c from Gnulib with modifications. + + The code maintains the prior modifications of conditionally including + config.h and disabling NLS support. + + _GL_UNUSED is repalced with the simple cast to void trick. _GL_UNUSED + is only used for these two parameters so its simpler than having to + define it. + + lib/getopt.c | 1134 +++++++++++++++++++--------------------------------------- + 1 file changed, 377 insertions(+), 757 deletions(-) + +commit 56b42be7287844db20b3a3bc1372c6ae8c040d63 +Author: Jia Tan +Date: 2023-09-23 00:18:56 +0800 + + lib: Add getopt-cdefs.h for getopt_long update. + + This was modified slightly from Gnulib. In Gnulib, it expects the + @HAVE_SYS_CDEFS_H@ to be replaced. Instead, we can set HAVE_SYS_CDEFS_H + on systems that have it and avoid copying another file into the build + directory. Since we are not using gnulib-tool, copying extra files + requires extra build system updates (and special handling with CMake) so + we should avoid when possible. + + lib/getopt-cdefs.h | 70 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ + 1 file changed, 70 insertions(+) + +commit 9834e591a4cf9dc2f49e42e26bf28d1d247bc196 +Author: Jia Tan +Date: 2023-09-23 00:15:25 +0800 + + lib: Copy new header files from Gnulib without modification. + + The getopt related files have changed from Gnulib by splitting up + getopt.in.h into more modular header files. We could have kept + everything in just getopt.in.h, but this will help us continue to update + in the future. + + lib/getopt-core.h | 96 +++++++++++++++++++++++++++++++++++++++++++++++++++ + lib/getopt-ext.h | 77 +++++++++++++++++++++++++++++++++++++++++ + lib/getopt-pfx-core.h | 66 +++++++++++++++++++++++++++++++++++ + lib/getopt-pfx-ext.h | 70 +++++++++++++++++++++++++++++++++++++ + 4 files changed, 309 insertions(+) + +commit 5b7a6f06e93d99d6635a740fd2e12fab66096c93 +Author: Lasse Collin +Date: 2023-09-22 21:16:52 +0300 + + Windows: Update the version requirement comments from Win95 to W2k. + + windows/README-Windows.txt | 10 ++++------ + windows/build.bash | 6 +++--- + 2 files changed, 7 insertions(+), 9 deletions(-) + +commit e582f8e0fee46e7cd967f42f465d6bb608b73bc1 +Author: Lasse Collin +Date: 2023-09-22 21:12:54 +0300 + + tuklib_physmem: Comment out support for Windows versions older than 2000. + + src/common/tuklib_physmem.c | 20 +++++++++----------- + 1 file changed, 9 insertions(+), 11 deletions(-) + +commit 7d73d1f0e08f96c4ab7aac91b958e37a3dadf07a +Author: Lasse Collin +Date: 2023-09-24 16:32:32 +0300 + + sysdefs.h: Update the comment about __USE_MINGW_ANSI_STDIO. + + src/common/sysdefs.h | 10 +++++++++- + 1 file changed, 9 insertions(+), 1 deletion(-) + +commit 2a9929af0ab7e6c0ab725565034afe3293e51d71 +Author: Lasse Collin +Date: 2023-09-22 02:33:29 +0300 + + xz: Windows: Don't (de)compress to special files like "con" or "nul". + + Before this commit, the following writes "foo" to the + console and deletes the input file: + + echo foo | xz > con_xz + xz --suffix=_xz --decompress con_xz + + It cannot happen without --suffix because names like con.xz + are also special and so attempting to decompress con.xz + (or compress con to con.xz) will already fail when opening + the input file. + + Similar thing is possible when compressing. The following + writes to "nul" and the input file "n" is deleted. + + echo foo | xz > n + xz --suffix=ul n + + Now xz checks if the destination is a special file before + continuing. DOS/DJGPP version had a check for this but + Windows (and OS/2) didn't. + + src/xz/file_io.c | 35 ++++++++++++++++++++++++++++------- + 1 file changed, 28 insertions(+), 7 deletions(-) + +commit 01311b81f03cce1c0ce847a3d556f84dbd439343 +Author: Lasse Collin +Date: 2023-09-21 20:42:52 +0300 + + CMake: Wrap two overlong lines that are possible to wrap. + + CMakeLists.txt | 6 ++++-- + 1 file changed, 4 insertions(+), 2 deletions(-) + +commit 152d0771ddd0cffcac9042ad1a66f110d228eee2 +Author: Lasse Collin +Date: 2023-09-21 20:36:31 +0300 + + CMake: Add a comment about threads on Cygwin. + + CMakeLists.txt | 1 + + 1 file changed, 1 insertion(+) + +commit 6df988cceffaa3100b428ed816fad334935b27bf +Author: Lasse Collin +Date: 2023-09-12 23:53:25 +0300 + + MSVC: Remove Visual Studio project files and update INSTALL-MSVC.txt. + + CMake is now the preferred build file generator when building + with MSVC. + + windows/INSTALL-MSVC.txt | 37 ++-- + windows/vs2013/config.h | 157 --------------- + windows/vs2013/liblzma.vcxproj | 363 --------------------------------- + windows/vs2013/liblzma_dll.vcxproj | 398 ------------------------------------ + windows/vs2013/xz_win.sln | 48 ----- + windows/vs2017/config.h | 157 --------------- + windows/vs2017/liblzma.vcxproj | 363 --------------------------------- + windows/vs2017/liblzma_dll.vcxproj | 398 ------------------------------------ + windows/vs2017/xz_win.sln | 48 ----- + windows/vs2019/config.h | 157 --------------- + windows/vs2019/liblzma.vcxproj | 364 --------------------------------- + windows/vs2019/liblzma_dll.vcxproj | 399 ------------------------------------- + windows/vs2019/xz_win.sln | 51 ----- + 13 files changed, 12 insertions(+), 2928 deletions(-) + +commit edd563daf0da1d00018684614803c77ab62efcd6 +Author: Lasse Collin +Date: 2023-09-21 19:17:40 +0300 + + CMake: Require VS2015 or later for building xzdec. + + xzdec might build with VS2013 but it hasn't been tested. + It was never supported before and VS2013 is old anyway + so for simplicity only liblzma is supported with VS2013. + + CMakeLists.txt | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit daea64d158a7151ca6c255a0e4554c6d521cd589 +Author: Lasse Collin +Date: 2023-09-12 23:43:49 +0300 + + CMake: Allow building xz with Visual Studio 2015 and later. + + Building the command line tools xz and xzdec with the combination + of CMake + Visual Studio 2015/2017/2019/2022 works now. + + VS2013 update 2 should still be able to build liblzma. + VS2013 cannot build the xz command line tool because xz + needs snprintf() that roughly conforms to C99. + VS2013 is old and no extra code will be added to support it. + + Thanks to Kelvin Lee and Jia Tan for testing. + + CMakeLists.txt | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit 8c2d197c940d246849b2ec48109bb22e54036927 +Author: Lasse Collin +Date: 2023-09-12 23:34:31 +0300 + + MSVC: #define inline and restrict only when needed. + + This also drops the check for _WIN32 as that shouldn't be needed. + + src/common/sysdefs.h | 13 ++++++++----- + 1 file changed, 8 insertions(+), 5 deletions(-) + +commit af66cd585902045e5689a0418103ec81f19f1d0a +Author: Lasse Collin +Date: 2023-09-12 22:16:56 +0300 + + CMake: Add support for replacement getopt_long (lib/getopt*). + + Thanks to Jia Tan for the initial work. I added the libgnu target + and made a few related minor edits. + + CMakeLists.txt | 54 +++++++++++++++++++++++++++++++++++++++++++++++------- + 1 file changed, 47 insertions(+), 7 deletions(-) + +commit e3288fdb45c580cb849f6799cf419c4922004ae5 +Author: Lasse Collin +Date: 2023-09-12 21:12:34 +0300 + + CMake: Bump maximum policy version to 3.27. + + There are several new policies. CMP0149 may affect the Windows SDK + version that CMake will choose by default. The new behavior is more + predictable, always choosing the latest SDK version by default. + + The other new policies shouldn't affect this package. + + CMakeLists.txt | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit aff1b479c7b168652bd20305ceed4317d5db6661 +Author: Lasse Collin +Date: 2023-09-12 20:55:10 +0300 + + lib/getopt*.c: Include only HAVE_CONFIG_H is defined. + + The CMake-based build doesn't use config.h. + + Up-to-date getopt_long in Gnulib is LGPLv2 so at some + point it could be included in XZ Utils too but for now + this commit is enough to make CMake-based build possible. + + lib/getopt.c | 4 +++- + lib/getopt1.c | 4 +++- + 2 files changed, 6 insertions(+), 2 deletions(-) + +commit aa0cd585d2ed1455d35732798e0d90e3520e8ba5 +Author: Lasse Collin +Date: 2023-09-08 19:08:57 +0300 + + Doxygen: Add more C macro names to PREDEFINED. + + doxygen/Doxyfile | 7 +++++-- + 1 file changed, 5 insertions(+), 2 deletions(-) + +commit ee7709bae53637e1765ce142ef102914f1423cb5 +Author: Lasse Collin +Date: 2023-09-11 18:47:26 +0300 + + liblzma: Move a few __attribute__ uses in function declarations. + + The API headers have many attributes but these were left + as is for now. + + src/liblzma/common/common.c | 6 ++++-- + src/liblzma/common/common.h | 8 ++++---- + src/liblzma/common/memcmplen.h | 3 ++- + 3 files changed, 10 insertions(+), 7 deletions(-) + +commit 217958d88713b5dc73d366d24dd64b2b311b86fe +Author: Lasse Collin +Date: 2023-09-11 19:03:35 +0300 + + xz, xzdec, lzmainfo: Use tuklib_attr_noreturn. + + For compatibility with C23's [[noreturn]], tuklib_attr_noreturn + must be at the beginning of declaration (before "extern" or + "static", and even before any GNU C's __attribute__). + + This commit also moves all other function attributes to + the beginning of function declarations. "extern" is kept + at the beginning of a line so the attributes are listed on + separate lines before "extern" or "static". + + src/lzmainfo/lzmainfo.c | 6 ++++-- + src/xz/coder.c | 3 ++- + src/xz/hardware.h | 3 ++- + src/xz/message.h | 30 +++++++++++++++++------------- + src/xz/options.c | 3 ++- + src/xz/util.h | 8 ++++---- + src/xzdec/xzdec.c | 9 ++++++--- + 7 files changed, 37 insertions(+), 25 deletions(-) + +commit 18a66fbac031c98f9c2077fc88846e4d07849197 +Author: Lasse Collin +Date: 2023-09-11 18:53:31 +0300 + + Remove incorrect uses of __attribute__((__malloc__)). + + xrealloc() is obviously incorrect, modern GCC docs even + mention realloc() as an example where this attribute + cannot be used. + + liblzma's lzma_alloc() and lzma_alloc_zero() would be + correct uses most of the time but custom allocators + may use a memory pool or otherwise hold the pointer + so aliasing issues could happen in theory. + + The xstrdup() case likely was correct but I removed it anyway. + Now there are no __malloc__ attributes left in the code. + The allocations aren't in hot paths so this should make + no practical difference. + + src/liblzma/common/common.c | 4 ++-- + src/liblzma/common/common.h | 4 ++-- + src/xz/util.h | 4 ++-- + 3 files changed, 6 insertions(+), 6 deletions(-) + +commit 74b0e900c92d5b222b36f474f1efa431f8e262f7 +Author: Lasse Collin +Date: 2023-09-08 18:41:25 +0300 + + Build: Omit -Wc99-c11-compat since it warns about _Noreturn. + + configure.ac | 1 - + 1 file changed, 1 deletion(-) + +commit 90c94dddfd57b7d744bfad64c54e10d15778144b +Author: Lasse Collin +Date: 2023-09-08 18:19:26 +0300 + + tuklib: Update tuklib_attr_noreturn for C11/C17 and C23. + + This makes no difference for GCC or Clang as they support + GNU C's __attribute__((__noreturn__)) but this helps with MSVC: + + - VS 2019 version 16.7 and later support _Noreturn if the + options /std:c11 or /std:c17 are used. This gets handled + with the check for __STDC_VERSION__ >= 201112. + + - When MSVC isn't in C11/C17 mode, __declspec(noreturn) is used. + + C23 will deprecate _Noreturn (and ) + for [[noreturn]]. This commit anticipates that but + the final __STDC_VERSION__ value isn't known yet. + + src/common/tuklib_common.h | 22 +++++++++++++++++++++- + src/common/tuklib_exit.h | 4 ++-- + 2 files changed, 23 insertions(+), 3 deletions(-) + +commit 189f72581329ab281ad6af37f60135910cb1b146 +Author: Lasse Collin +Date: 2023-09-11 17:22:44 +0300 + + Update THANKS. + + THANKS | 1 + + 1 file changed, 1 insertion(+) + +commit 79334e7f20f2bf9e0de095835b48868f1238f584 +Author: Lasse Collin +Date: 2023-09-05 22:42:10 +0300 + + MSVC: xz: Make file_io.c and file_io.h compatible with MSVC. + + Thanks to Kelvin Lee for the original patches + and testing the modifications I made. + + src/xz/file_io.c | 26 ++++++++++++++++++++++++++ + src/xz/file_io.h | 10 ++++++++++ + 2 files changed, 36 insertions(+) + +commit c660b8d78b7bda43b12b285550d8c70e8ccec698 +Author: Lasse Collin +Date: 2023-09-05 21:33:35 +0300 + + MSVC: xz: Use GetTickCount64() to implement mytime_now(). + + It's available since Windows Vista. + + src/xz/mytime.c | 11 +++++++++-- + 1 file changed, 9 insertions(+), 2 deletions(-) + +commit 5c6f892d411670e3060f4bc309402617a209e57c +Author: Kelvin Lee +Date: 2023-09-05 15:05:09 +0300 + + MSVC: xz: Use _stricmp() instead of strcasecmp() in suffix.c. + + src/xz/suffix.c | 10 ++++++++-- + 1 file changed, 8 insertions(+), 2 deletions(-) + +commit e241051f50044259d174e8b4633dd9a1c4478408 +Author: Kelvin Lee +Date: 2023-09-05 15:01:10 +0300 + + MSVC: xz: Use _isatty() from to implement isatty(). + + src/xz/message.c | 5 +++++ + src/xz/util.c | 5 +++++ + 2 files changed, 10 insertions(+) + +commit d14bba8fc2be02a9fed8c9bcaaf61103451755f8 +Author: Kelvin Lee +Date: 2023-09-05 15:10:31 +0300 + + MSVC: xz: Use _fileno() instead of fileno(). + + src/xz/private.h | 4 ++++ + 1 file changed, 4 insertions(+) + +commit c4edd367678e6a38c42b149856159bf417da7fe1 +Author: Kelvin Lee +Date: 2023-09-05 15:00:07 +0300 + + MSVC: xzdec: Use _fileno and _setmode. + + src/xzdec/xzdec.c | 4 ++++ + 1 file changed, 4 insertions(+) + +commit cfd1054b9b539ee92524901e95d7bb5a1fe670a0 +Author: Kelvin Lee +Date: 2023-09-05 14:37:50 +0300 + + MSVC: Don't #include . + + lib/getopt.c | 4 +++- + lib/getopt.in.h | 4 +++- + src/xz/private.h | 5 ++++- + src/xzdec/xzdec.c | 5 ++++- + 4 files changed, 14 insertions(+), 4 deletions(-) + +commit adef92f23563a2cc088b31ddee9040ecc96bc996 +Author: Lasse Collin +Date: 2023-09-19 14:03:45 +0300 + + Update THANKS. + + THANKS | 1 + + 1 file changed, 1 insertion(+) + +commit 953e775941a25bfcfa353f802b13e66acb1edf2c +Author: Jia Tan +Date: 2023-09-14 21:13:23 +0800 + + CI: Enable CLMUL in address sanitization test. + + The crc64_clmul() function should be ignored by the address sanitizer + now so these builds should still pass. + + .github/workflows/ci.yml | 12 ++++-------- + 1 file changed, 4 insertions(+), 8 deletions(-) + +commit f167e79bc98f3f56af2e767b83aa81c2d2b9ed77 +Author: Lasse Collin +Date: 2023-09-14 16:35:46 +0300 + + Update THANKS. + + THANKS | 1 + + 1 file changed, 1 insertion(+) + +commit 4f44ef86758a41a8ec814096f4cb6ee6de04c82e +Author: Lasse Collin +Date: 2023-09-14 16:34:07 +0300 + + liblzma: Mark crc64_clmul() with __attribute__((__no_sanitize_address__)). + + Thanks to Agostino Sarubbo. + Fixes: https://github.com/tukaani-project/xz/issues/62 + + src/liblzma/check/crc64_fast.c | 8 ++++++++ + 1 file changed, 8 insertions(+) + +commit 7379bb3eed428c0ae734d0cc4a1fd04359d53f08 +Author: Jia Tan +Date: 2023-09-12 22:36:12 +0800 + + CMake: Fix time.h checks not running on second CMake run. + + If CMake was configured more than once, HAVE_CLOCK_GETTIME and + HAVE_CLOCK_MONOTONIC would not be set as compile definitions. The check + for librt being needed to provide HAVE_CLOCK_GETTIME was also + simplified. + + CMakeLists.txt | 18 ++++++++++-------- + 1 file changed, 10 insertions(+), 8 deletions(-) + +commit 5d691fe58286b92d704c0dc5cd0c4df22881c6c6 +Author: Jia Tan +Date: 2023-09-12 22:34:06 +0800 + + CMake: Fix unconditionally defining HAVE_CLOCK_MONOTONIC. + + If HAVE_CLOCK_GETTIME was defined, then HAVE_CLOCK_MONOTONIC was always + added as a compile definition even if the check for it failed. + + CMakeLists.txt | 8 +++----- + 1 file changed, 3 insertions(+), 5 deletions(-) + +commit eccf12866527b8d24c7d7f92f755142be8ef9b11 +Author: Lasse Collin +Date: 2023-08-31 19:50:05 +0300 + + xz: Refactor thousand separator detection and disable it on MSVC. + + Now the two variations of the format strings are created with + a macro, and the whole detection code can be easily disabled + on platforms where thousand separator formatting is known to + not work (MSVC has no support, and on DJGPP 2.05 it can have + problems in some cases). + + src/xz/util.c | 89 ++++++++++++++++++++++++++++++----------------------------- + 1 file changed, 45 insertions(+), 44 deletions(-) + +commit f7093cd9d130477c234b40aeda613964171f8f21 +Author: Lasse Collin +Date: 2023-08-31 18:14:43 +0300 + + xz: Fix a too relaxed assertion and remove uses of SSIZE_MAX. + + SSIZE_MAX isn't readily available on MSVC. Removing it means + that there is one thing less to worry when porting to MSVC. + + src/xz/file_io.c | 5 ++--- + src/xz/file_io.h | 4 ++-- + 2 files changed, 4 insertions(+), 5 deletions(-) + +commit 74c3449d8b816a724b12ebce7417e00fb597309a +Author: Jia Tan +Date: 2023-08-28 23:14:45 +0800 + + Tests: Improve invalid unpadded size check in test_lzma_index_append(). + + This check was extended to test the code added to fix a failing assert + in ae5c07b22a6b3766b84f409f1b6b5c100469068a. + + tests/test_index.c | 26 +++++++++++++++++++++++--- + 1 file changed, 23 insertions(+), 3 deletions(-) + +commit 2544274a8b8a27f4ea6c457d2c4c32eb1e4cd336 +Author: Jia Tan +Date: 2023-08-28 21:54:41 +0800 + + Tests: Improve comments in test_index.c. + + tests/test_index.c | 6 +++--- + 1 file changed, 3 insertions(+), 3 deletions(-) + +commit 49be29d6380b94e6fb26e511dd2cdbd9afce0f8b +Author: Jia Tan +Date: 2023-08-28 21:52:54 +0800 + + Update THANKS. + + THANKS | 1 + + 1 file changed, 1 insertion(+) + +commit 721e3d9f7a82f59f32795d5fb97e0210d1aa839a +Author: Jia Tan +Date: 2023-08-28 21:50:16 +0800 + + liblzma: Update assert in vli_ceil4(). + + The argument to vli_ceil4() should always guarantee the return value + is also a valid lzma_vli. Thus the highest three valid lzma_vli values + are invalid arguments. All uses of the function ensure this so the + assert is updated to match this. + + src/liblzma/common/index.h | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit ae5c07b22a6b3766b84f409f1b6b5c100469068a +Author: Jia Tan +Date: 2023-08-28 21:31:25 +0800 + + liblzma: Add overflow check for Unpadded size in lzma_index_append(). + + This was not a security bug since there was no path to overflow + UINT64_MAX in lzma_index_append() or when it calls index_file_size(). + The bug was discovered by a failing assert() in vli_ceil4() when called + from index_file_size() when unpadded_sum (the sum of the compressed size + of current Stream and the unpadded_size parameter) exceeds LZMA_VLI_MAX. + + Previously, the unpadded_size parameter was checked to be not greater + than UNPADDED_SIZE_MAX, but no check was done once compressed_base was + added. + + This could not have caused an integer overflow in index_file_size() when + called by lzma_index_append(). The calculation for file_size breaks down + into the sum of: + + - Compressed base from all previous Streams + - 2 * LZMA_STREAM_HEADER_SIZE (size of the current Streams header and + footer) + - stream_padding (can be set by lzma_index_stream_padding()) + - Compressed base from the current Stream + - Unpadded size (parameter to lzma_index_append()) + + The sum of everything except for Unpadded size must be less than + LZMA_VLI_MAX. This is guarenteed by overflow checks in the functions + that can set these values including lzma_index_stream_padding(), + lzma_index_append(), and lzma_index_cat(). The maximum value for + Unpadded size is enforced by lzma_index_append() to be less than or + equal UNPADDED_SIZE_MAX. Thus, the sum cannot exceed UINT64_MAX since + LZMA_VLI_MAX is half of UINT64_MAX. + + Thanks to Joona Kannisto for reporting this. + + src/liblzma/common/index.c | 6 ++++++ + 1 file changed, 6 insertions(+) + +commit 1057765aaabfe0f1397b8094531846655376ae38 +Author: Jia Tan +Date: 2023-08-28 22:18:29 +0800 + + Translations: Update the Esperanto translation. + + po/eo.po | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +commit f2e94d064f305bb8ad77ca70f91d93e55f5cf856 +Author: Jia Tan +Date: 2023-08-26 20:10:23 +0800 + + Translations: Update the Esperanto translation. + + po/eo.po | 47 +++++++++++++++++++++++++++++------------------ + 1 file changed, 29 insertions(+), 18 deletions(-) + +commit 2b871f4dbffe3801d0da3f89806b5935f758d5f3 +Author: Jia Tan +Date: 2023-08-09 20:55:36 +0800 + + Docs: Update INSTALL for --enable-threads method win95. + + The Autotools build allows win95 threads and --enable-small together now + if the compiler supports __attribute__((__constructor__)). + + INSTALL | 6 ++++-- + 1 file changed, 4 insertions(+), 2 deletions(-) + +commit 356ad5b26b4196f085ce3afa1869154ca81faad8 +Author: Jia Tan +Date: 2023-08-09 20:54:15 +0800 + + CMake: Conditionally allow win95 threads and --enable-small. + + CMakeLists.txt | 28 ++++++++++++++++++++-------- + 1 file changed, 20 insertions(+), 8 deletions(-) + +commit de574404c4c2f87aca049f232c38526e3ce092aa +Author: Jia Tan +Date: 2023-08-09 20:35:16 +0800 + + Build: Conditionally allow win95 threads and --enable-small. + + When the compiler supports __attribute__((__constructor__)) + mythread_once() is never used, even with --enable-small. A configuration + with win95 threads and --enable-small will compile and be thread safe so + it can be allowed. + + This isn't a very common configuration since MSVC does not support + __attribute__((__constructor__)), but MINGW32 and CLANG32 environments + for MSYS2 can use win95 threads and have + __attribute__((__constructor__)) support. + + configure.ac | 21 +++++++++++++-------- + 1 file changed, 13 insertions(+), 8 deletions(-) + +commit 6bf33b704cd31dccf25e68480464aa22d3fcad5a +Author: Jamaika1 +Date: 2023-08-08 14:07:59 +0200 + + mythread.h: Fix typo error in Vista threads mythread_once(). + + The "once_" variable was accidentally referred to as just "once". This + prevented building with Vista threads when + HAVE_FUNC_ATTRIBUTE_CONSTRUCTOR was not defined. + + src/common/mythread.h | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit 80cb961e5380a3878246d41341ff91378ca59e05 +Author: Jia Tan +Date: 2023-08-04 22:17:11 +0800 + + codespell: Add .codespellrc to set default options. + + The .codespellrc allows setting default options to avoid false positive + matches, set additional dictionaries, etc. For now, codespell can be + used locally before committing doc and comment changes. + + It should help prevent silly errors and fix up commits in the future. + + .codespellrc | 24 ++++++++++++++++++++++++ + 1 file changed, 24 insertions(+) + +commit cd678a6077358935249b64a4a16fe8d17434f9c9 +Author: Jia Tan +Date: 2023-08-03 20:10:21 +0800 + + Tests: Style fixes to test_lzip_decoder.c. + + tests/test_lzip_decoder.c | 36 ++++++++++++++++++++++++------------ + 1 file changed, 24 insertions(+), 12 deletions(-) + +commit 1cac5ed4fa45c9861d745b02d80575cb2ff01d81 +Author: Jia Tan +Date: 2023-08-03 15:56:20 +0800 + + Translations: Update the Chinese (simplified) translation. + + po/zh_CN.po | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit 16068f6c30b888cdb873f6285af941d00f95741d +Author: Lasse Collin +Date: 2023-08-02 17:15:12 +0300 + + xz: Omit an empty paragraph on the man page. + + src/xz/xz.1 | 1 - + 1 file changed, 1 deletion(-) + +commit 9ae4371b5106189486e850ce777e40f7b6021c0b +Author: Jia Tan +Date: 2023-08-02 20:30:07 +0800 + + Add NEWS for 5.4.4. + + NEWS | 43 +++++++++++++++++++++++++++++++++++++++++++ + 1 file changed, 43 insertions(+) + +commit e8c2203b2c76466d8d3387c5212b46151de8e605 +Author: Lasse Collin +Date: 2023-08-02 15:19:43 +0300 + + build-aux/manconv.sh: Fix US-ASCII and UTF-8 output. + + groff defaults to SGR escapes. Using -P-c passes -c to grotty + which restores the old behavior. Perhaps there is a better way to + get pure plain text output but this works for now. + + build-aux/manconv.sh | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +commit 9a706167b0d903d92fd134895acb4bc6a5e3e688 +Author: Lasse Collin +Date: 2023-08-01 19:10:43 +0300 + + Update THANKS. + + THANKS | 1 + + 1 file changed, 1 insertion(+) + +commit 33e25a0f5650754c38bed640deedefe3b4fec5ef +Author: Lasse Collin +Date: 2023-08-01 18:22:24 +0300 + + Update THANKS. + + THANKS | 1 + + 1 file changed, 1 insertion(+) + +commit 81db3b889830132334d1f2129bdc93177ac2ca7d +Author: ChanTsune <41658782+ChanTsune@users.noreply.github.com> +Date: 2023-08-01 18:17:17 +0300 + + mythread.h: Disable signal functions in builds targeting Wasm + WASI. + + signal.h in WASI SDK doesn't currently provide sigprocmask() + or sigset_t. liblzma doesn't need them so this change makes + liblzma and xzdec build against WASI SDK. xz doesn't build yet + and the tests don't either as tuktest needs setjmp() which + isn't (yet?) implemented in WASI SDK. + + Closes: https://github.com/tukaani-project/xz/pull/57 + See also: https://github.com/tukaani-project/xz/pull/56 + + (The original commit was edited a little by Lasse Collin.) + + src/common/mythread.h | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit 71c638c611324e606d324c8189fef8fe79db6991 +Author: Jia Tan +Date: 2023-08-01 21:58:51 +0800 + + Add newline to end of .gitignore. + + Newline was accidentally removed in commit + 01cbb7f023ee7fda8ddde04bd17cf7d3c2418706. + + .gitignore | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit 42df7c7aa1cca385e509eb33c65136e61890f0bf +Author: Dimitri Papadopoulos Orfanos <3234522+DimitriPapadopoulos@users.noreply.github.com> +Date: 2023-07-31 14:02:21 +0200 + + Docs: Fix typos found by codespell + + CMakeLists.txt | 4 ++-- + NEWS | 2 +- + configure.ac | 2 +- + src/liblzma/api/lzma/container.h | 4 ++-- + src/liblzma/api/lzma/filter.h | 2 +- + src/liblzma/api/lzma/lzma12.h | 4 ++-- + src/liblzma/common/block_buffer_encoder.c | 2 +- + src/liblzma/common/common.h | 2 +- + src/liblzma/common/file_info.c | 2 +- + src/liblzma/common/lzip_decoder.c | 2 +- + src/liblzma/common/stream_decoder_mt.c | 8 ++++---- + src/liblzma/common/string_conversion.c | 6 +++--- + src/liblzma/lz/lz_encoder.h | 2 +- + src/liblzma/lzma/lzma_encoder.c | 4 ++-- + src/xz/hardware.c | 4 ++-- + tests/test_filter_flags.c | 4 ++-- + tests/test_index.c | 2 +- + tests/test_vli.c | 2 +- + 18 files changed, 29 insertions(+), 29 deletions(-) + +commit 01cbb7f023ee7fda8ddde04bd17cf7d3c2418706 +Author: Jia Tan +Date: 2023-07-26 20:26:23 +0800 + + Update .gitignore. + + .gitignore | 4 ++++ + 1 file changed, 4 insertions(+) + +commit f97a1afd564c48ad9cb94682e10972a72e11fa08 +Author: Jia Tan +Date: 2023-07-28 22:03:08 +0800 + + CMake: Conditionally allow the creation of broken symlinks. + + The CMake build will try to create broken symlinks on Unix and Unix-like + platforms. Cygwin and MSYS2 are Unix-like, but may not be able to create + broken symlinks. The value of the CYGWIN or MSYS environment variables + determine if broken symlinks are valid. + + The default for MSYS2 does not allow for broken symlinks, so the CMake + build has been broken for MSYS2 since commit + 80a1a8bb838842a2be343bd88ad1462c21c5e2c9. + + CMakeLists.txt | 82 +++++++++++++++++++++++++++++++++++++++++++++++++++++----- + 1 file changed, 75 insertions(+), 7 deletions(-) + +commit 7190f4cc7c9ade5b9b3675d0cbfa3b6d6ec9cb4f +Author: Jia Tan +Date: 2023-07-28 21:56:48 +0800 + + CI: Fix windows-ci dependency installation. + + All of the MSYS2 environments need make, and it does not come with the + toolchain package. The toolchain package will install the needed + compiler toolchains since without this package CMake cannot properly + generate the Makefiles. + + .github/workflows/windows-ci.yml | 6 +++--- + 1 file changed, 3 insertions(+), 3 deletions(-) + +commit a048f472cd9a2245265cb292853cbbcdd4f02001 +Author: Jia Tan +Date: 2023-07-28 21:54:22 +0800 + + CI: Update ci_build.sh CMake to always make Unix Makefiles. + + The default for many of the MSYS2 environments is for CMake to create + Ninja build files. This would complicate the build script since we would + need a different command to run the tests. Its simpler to always use + Unix Makefiles so that "make test" is always a usable target for + testing. + + build-aux/ci_build.sh | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +commit 7870396a0ca945473aa0d1d790f4cbef456610bd +Author: Jia Tan +Date: 2023-07-25 20:17:23 +0800 + + CI: Test CMake builds and test framework with MSYS2. + + .github/workflows/windows-ci.yml | 32 ++++++++++++++++++++------------ + 1 file changed, 20 insertions(+), 12 deletions(-) + +commit 6497d1f8875cb7e3007f714336cc09c06fed235b +Author: Jia Tan +Date: 2023-07-25 20:14:53 +0800 + + CI: Windows CI rename system matrix variable -> msys2_env. + + Calling the MSYS2 environment "system" was a bit vague and should be + more specific. + + .github/workflows/windows-ci.yml | 15 +++++---------- + 1 file changed, 5 insertions(+), 10 deletions(-) + +commit 785e4121d9b2921ad36bd3af1cf61fa20a9265bd +Author: Jia Tan +Date: 2023-07-24 23:11:45 +0800 + + CI: Add Clang64 MSYS2 environment to Windows CI. + + .github/workflows/windows-ci.yml | 1 + + 1 file changed, 1 insertion(+) + +commit d9166b52cf3458a4da3eb92224837ca8fc208d79 +Author: Jia Tan +Date: 2023-07-24 21:43:44 +0800 + + liblzma: Prevent an empty translation unit in Windows builds. + + To workaround Automake lacking Windows resource compiler support, an + empty source file is compiled to overwrite the resource files for static + library builds. Translation units without an external declaration are + not allowed by the C standard and result in a warning when used with + -Wempty-translation-unit (Clang) or -pedantic (GCC). + + src/liblzma/Makefile.am | 6 +++++- + 1 file changed, 5 insertions(+), 1 deletion(-) + +commit db5019d691f980d622fb56fdcf383af2c3519c98 +Author: Jia Tan +Date: 2023-07-22 18:37:56 +0800 + + Translations: Update the Vietnamese translation. + + po/vi.po | 45 ++++++++++++++++++++++++++++----------------- + 1 file changed, 28 insertions(+), 17 deletions(-) + +commit f3a055f762ba5b71b746fc2d44a6ababde2c61b5 +Author: Jia Tan +Date: 2023-07-22 14:55:42 +0800 + + CI: Add Windows runner for Autotools builds with MSYS2. + + Only a subset of the tests run by the Linux and MacOS Autotools builds + are run. The most interesting tests are the ones that disable threads, + encoders, and decoders. + + The Windows runner will only be run manually since these tests will + likely take much longer than the Linux and MacOS runners. This runner + should be used before merging any large features and before releases. + + Currently the clang64 environment fails to due to a warning and + -Werror is enabled for the CI tests. This is still an early version + since the CMake build can be done for MSVC and optionally each of the + MSYS2 environments. GitHub does not allow manually running the CI tests + unless the workflow is checked on the default branch so checking in a + minimum version is a good idea. + + Thanks to Arthur S for the original proposing the original patch. + + Closes: https://github.com/tukaani-project/xz/pull/34 + + .github/workflows/windows-ci.yml | 119 +++++++++++++++++++++++++++++++++++++++ + 1 file changed, 119 insertions(+) + +commit 556536a3525df9e5ed78b8c7057991cfa9edfac8 +Author: Jia Tan +Date: 2023-07-21 22:11:01 +0800 + + CI: Add argument to ci_build.sh to pass flags to autogen.sh. + + build-aux/ci_build.sh | 9 +++++++-- + 1 file changed, 7 insertions(+), 2 deletions(-) + +commit 39a32d36fc465c4e70f13192eea380e518ba6e8a +Author: Jia Tan +Date: 2023-07-21 18:05:44 +0800 + + Tests: Skip .lz files in test_files.sh if not configured. + + Previously if the lzip decoder was not configured then test_files.sh + would pass the lzip tests instead of skipping them. + + tests/test_files.sh | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit 194d12724b30fe42789d12a0184f9d412c449347 +Author: Jia Tan +Date: 2023-07-20 22:11:13 +0800 + + Tests: Add ARM64 filter test to test_compress.sh. + + tests/test_compress.sh | 1 + + 1 file changed, 1 insertion(+) + +commit d850365c444368102c69beaddf849ed463c33467 +Author: Jia Tan +Date: 2023-07-20 20:30:05 +0800 + + Translations: Update the Croatian translation. + + po/hr.po | 49 ++++++++++++++++++++++++++++++------------------- + 1 file changed, 30 insertions(+), 19 deletions(-) + +commit 24049eb7acf6d42a60f00efe4e7289fe8e1797fe +Author: Jia Tan +Date: 2023-07-20 20:28:32 +0800 + + Translations: Update the Korean man page translations. + + po4a/ko.po | 1255 ++++++++++++++++++++++++++++++------------------------------ + 1 file changed, 629 insertions(+), 626 deletions(-) + +commit 4d4a4fa07de6cb9d913fb2f97712fddda2527b49 +Author: Jia Tan +Date: 2023-07-20 20:25:24 +0800 + + Translations: Update the Korean translation. + + po/ko.po | 45 ++++++++++++++++++++++++++++----------------- + 1 file changed, 28 insertions(+), 17 deletions(-) + +commit 237f06d9c55cf438a7538a598354bcf103f23711 +Author: Jia Tan +Date: 2023-07-20 20:24:05 +0800 + + Translations: Update the Polish translation. + + po/pl.po | 47 +++++++++++++++++++++++++++++------------------ + 1 file changed, 29 insertions(+), 18 deletions(-) + +commit 80c2c832136656d5ac7a1bca8bc42d95e13d281a +Author: Jia Tan +Date: 2023-07-20 20:22:23 +0800 + + Translations: Update the German man page translations. + + po4a/de.po | 1255 ++++++++++++++++++++++++++++++------------------------------ + 1 file changed, 629 insertions(+), 626 deletions(-) + +commit fdbde14503ca03069d3649aa51926f5f796b89d8 +Author: Jia Tan +Date: 2023-07-20 20:18:44 +0800 + + Translations: Update the German translation. + + po/de.po | 47 +++++++++++++++++++++++++++++------------------ + 1 file changed, 29 insertions(+), 18 deletions(-) + +commit 9f3bf5ff5b2b5cf0b252a2bf381238ca49dc4101 +Author: Jia Tan +Date: 2023-07-20 20:17:10 +0800 + + Translations: Update the Chinese (simplified) translation. + + po/zh_CN.po | 47 +++++++++++++++++++++++++++++------------------ + 1 file changed, 29 insertions(+), 18 deletions(-) + +commit 376938c588011567c74f1d5a160c0ccce6336d46 +Author: Jia Tan +Date: 2023-07-20 20:15:47 +0800 + + Translations: Update the Swedish translation. + + po/sv.po | 47 +++++++++++++++++++++++++++++------------------ + 1 file changed, 29 insertions(+), 18 deletions(-) + +commit 26b0bc6eb82c84559936a7c7080de5c71c8276f8 +Author: Jia Tan +Date: 2023-07-20 20:14:00 +0800 + + Translations: Update the Ukrainian man page translations. + + po4a/uk.po | 1253 ++++++++++++++++++++++++++++++------------------------------ + 1 file changed, 628 insertions(+), 625 deletions(-) + +commit 2d02c8b7640b54f3c5aa1c8b5990ba56f322393b +Author: Jia Tan +Date: 2023-07-20 20:09:15 +0800 + + Translations: Update the Ukrainian translation. + + po/uk.po | 45 ++++++++++++++++++++++++++++----------------- + 1 file changed, 28 insertions(+), 17 deletions(-) + +commit f881018b503fd334331c24a09075429558abbce1 +Author: Jia Tan +Date: 2023-07-20 20:06:57 +0800 + + Translations: Update the Spanish translation. + + po/es.po | 47 +++++++++++++++++++++++++++++------------------ + 1 file changed, 29 insertions(+), 18 deletions(-) + +commit 791fe6d3ffd6877fa5f852be69d9251397dfaa31 +Author: Jia Tan +Date: 2023-07-20 20:05:19 +0800 + + Translations: Update the Romanian translation. + + po/ro.po | 48 ++++++++++++++++++++++++++++++------------------ + 1 file changed, 30 insertions(+), 18 deletions(-) + +commit 8827e90704f699fe08bb5bed56b1717a2bc0eb77 +Author: Jia Tan +Date: 2023-07-20 20:02:56 +0800 + + Translations: Update the Romanian man page translations. + + po4a/ro.po | 1254 ++++++++++++++++++++++++++++++------------------------------ + 1 file changed, 629 insertions(+), 625 deletions(-) + +commit 0184d344fa4f215cd345bb131db9068e077c69b8 +Author: Jia Tan +Date: 2023-07-19 23:36:00 +0800 + + liblzma: Suppress -Wunused-function warning. + + Clang 16.0.0 and earlier have a bug that the ifunc resolver function + triggers the -Wunused-function warning. The resolver function is static + and only "used" by the __attribute__((__ifunc()__)). + + At this time, the bug is still unresolved, but has been reported: + https://github.com/llvm/llvm-project/issues/63957 + + This is not a problem in GCC. + + src/liblzma/check/crc64_fast.c | 10 ++++++++++ + 1 file changed, 10 insertions(+) + +commit 43845fa70fc751736c44c18f4cee42d49bfd1392 +Author: Jia Tan +Date: 2023-07-18 22:52:25 +0800 + + liblzma: Reword lzma_str_list_filters() documentation. + + This further improves the documentation from commit + f36ca7982f6bd5e9827219ed4f3c5a1fbf5d7bdf. The previous wording of + "supported options" was slightly misleading since the options that are + printed are the ones that are relevant for encoding/decoding. It is not + about which options can or must be specified. + + src/liblzma/api/lzma/filter.h | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit 818701ba1c9dff780b7fbf28f9ab8eb11a25dd67 +Author: Jia Tan +Date: 2023-07-18 22:49:57 +0800 + + liblzma: Improve comment in string_conversion.c. + + The comment used "flag" when referring to decoder options. Just + referring to them as options is more clear and consistent. + + src/liblzma/common/string_conversion.c | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +commit b6b7d065853cd4c3f5b8d9be8aea0b6dcb0fe090 +Author: Lasse Collin +Date: 2023-07-18 17:37:33 +0300 + + xz: Translate the second "%s: " in message.c since French needs "%s : ". + + This string is used to print a filename when using "xz -v" and + stderr isn't a terminal. + + src/xz/message.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit be644042c3066d8e7a2834f989671ba74d27f749 +Author: Lasse Collin +Date: 2023-07-18 14:35:33 +0300 + + xz: Make "%s: %s" translatable because French needs "%s : %s". + + src/xz/args.c | 5 ++++- + src/xz/coder.c | 8 ++++---- + src/xz/file_io.c | 8 ++++---- + src/xz/list.c | 11 ++++++----- + 4 files changed, 18 insertions(+), 14 deletions(-) + +commit 97fd5cb669ee0afc48d2087675ab166aff89eaa2 +Author: Lasse Collin +Date: 2023-07-18 13:57:54 +0300 + + liblzma: Tweak #if condition in memcmplen.h. + + Maybe ICC always #defines _MSC_VER on Windows but now + it's very clear which code will get used. + + src/liblzma/common/memcmplen.h | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +commit 40392c19f71985852d75997f109dea97177d6f3f +Author: Lasse Collin +Date: 2023-07-18 13:49:43 +0300 + + liblzma: Omit unnecessary parenthesis in a preprocessor directive. + + src/liblzma/common/memcmplen.h | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +commit abc1d5601b7e419ebc28a1ab4b268613b52e6f98 +Author: Jia Tan +Date: 2023-07-18 00:51:48 +0800 + + xz: Update Authors list in a few files. + + src/xz/args.c | 3 ++- + src/xz/args.h | 3 ++- + src/xz/coder.c | 3 ++- + src/xz/coder.h | 3 ++- + src/xz/message.c | 3 ++- + 5 files changed, 10 insertions(+), 5 deletions(-) + +commit 289034a168878baa9df6ff6e159110aade69cba5 +Author: Jia Tan +Date: 2023-07-14 23:20:33 +0800 + + Docs: Add a new section to INSTALL for Tests. + + The new Tests section describes basic information about the tests, how + to run them, and important details when cross compiling. We have had a + few questions about how to compile the tests without running them, so + hopefully this information will help others with the same question in the + future. + + Fixes: https://github.com/tukaani-project/xz/issues/54 + + INSTALL | 81 +++++++++++++++++++++++++++++++++++++++++++++++++++-------------- + 1 file changed, 64 insertions(+), 17 deletions(-) + +commit 1119e5f5a519b0ab71c81fc4dc84c0cc72abe513 +Author: Jia Tan +Date: 2023-07-14 21:10:27 +0800 + + Docs: Update README. + + This adds an entry to "Other implementations of the .xz format" for + XZ for Java. + + README | 4 ++++ + 1 file changed, 4 insertions(+) + +commit f99e2e4e53b7ea89e4eef32ddd4882e0416357c9 +Author: Jia Tan +Date: 2023-07-13 23:32:10 +0800 + + xz: Fix typo in man page. + + The Memory limit information section described three output + columns when it actually has six. This was reworded to + "multiple" to make it more future proof. + + src/xz/xz.1 | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit f907705eb1f6c5edaafc9668a34c51a989932f1d +Author: Jia Tan +Date: 2023-07-13 21:46:12 +0800 + + xz: Minor clean up for coder.c + + * Moved max_block_list_size from a global to local variable. + * Reworded error message in validate_block_list_filter(). + * Removed helper function filter_chain_error(). + * Changed 1 << X to 1U << X in many places + + src/xz/coder.c | 53 +++++++++++++++++++++-------------------------------- + 1 file changed, 21 insertions(+), 32 deletions(-) + +commit 9adc9e56157ecbf2948e5036df8567809b9ae177 +Author: Jia Tan +Date: 2023-07-13 21:26:47 +0800 + + xz: Update man page Authors and date. + + src/xz/xz.1 | 5 +++-- + 1 file changed, 3 insertions(+), 2 deletions(-) + +commit c12e429f2635da8d8f5749e5f733f451baca6945 +Author: Jia Tan +Date: 2023-06-20 20:32:59 +0800 + + xz: Add a section to man page for robot mode --filters-help. + + src/xz/xz.1 | 32 ++++++++++++++++++++++++++++++-- + 1 file changed, 30 insertions(+), 2 deletions(-) + +commit e10f2db5d10300c16fa482a136ed31c1aa6e8e8d +Author: Jia Tan +Date: 2023-06-19 23:11:41 +0800 + + xz: Slight reword in xz man page for consistency. + + Changed will print => prints in xz --robot --version description to + match --robot --info-memory description. + + src/xz/xz.1 | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit f5dc172a402fa946f3c45a16929d7fe14c9f5e81 +Author: Jia Tan +Date: 2023-06-19 23:07:10 +0800 + + xz: Reorder robot mode subsections in the man page. + + The order is now consistent with the order the command line arguments + are documented earlier in the man page. The new order is: + 1. --list + 2. --info-memory + 3. --version + + Instead of the previous order: + 1. --version + 2. --info-memory + 3. --list + + src/xz/xz.1 | 192 ++++++++++++++++++++++++++++++------------------------------ + 1 file changed, 96 insertions(+), 96 deletions(-) + +commit 9628be23aef2784249fd9f3199799d785d2ec5cc +Author: Jia Tan +Date: 2023-05-13 00:46:50 +0800 + + xz: Update man page for new --filters-help option. + + src/xz/xz.1 | 10 ++++++++++ + 1 file changed, 10 insertions(+) + +commit a165d7df1964121eb9df715e6f836a31c865beef +Author: Jia Tan +Date: 2023-05-13 00:44:41 +0800 + + xz: Add a new --filters-help option. + + The --filters-help can be used to help create filter chains with the + --filters and --filtersX options. The message in --long-help is too + short to fully explain the syntax to construct complex filter chains. + + In --robot mode, xz will only print the output from liblzma function + lzma_str_list_filters. + + src/xz/args.c | 8 ++++++++ + src/xz/message.c | 30 ++++++++++++++++++++++++++++++ + src/xz/message.h | 5 +++++ + 3 files changed, 43 insertions(+) + +commit 95f1a414b156ee35d3e71862a14915fdd138f913 +Author: Jia Tan +Date: 2023-04-21 20:28:11 +0800 + + xz: Update the man page for --block-list and --filtersX + + The --block-list option description needed updating since the new + --filtersX option changes how it can be used. The new entry for + --filters1=FILTERS ... --filter9=FILTERS was created right after + the --filters option. + + src/xz/xz.1 | 106 +++++++++++++++++++++++++++++++++++++++++++++--------------- + 1 file changed, 80 insertions(+), 26 deletions(-) + +commit 47a63cad2aa778280e0c1926b7159427ea028cb1 +Author: Jia Tan +Date: 2023-04-21 19:50:14 +0800 + + xz: Update --long-help for the new --filtersX option. + + src/xz/message.c | 12 ++++++++++-- + 1 file changed, 10 insertions(+), 2 deletions(-) + +commit 8b9913a13daca2550d02dfdcdc9be15f55ca4d13 +Author: Jia Tan +Date: 2023-06-17 20:46:21 +0800 + + xz: Ignore filter chains that are set but never used in --block-list. + + If a filter chain is set but not used in --block-list, it introduced + unexpected behavior such as requiring an unneeded amount of memory to + compress, reducing the number of threads in multi-threaded encoding, and + printing an incorrect amount of memory needed to decompress. + + This also renames filters_init_mask => filters_used_mask. A filter is + assumed to be used if it is specified in --filtersX until + coder_set_compression_settings() determines which filters are referenced + in --block-list. + + src/xz/coder.c | 66 ++++++++++++++++++++++++++++++++++++++++++---------------- + 1 file changed, 48 insertions(+), 18 deletions(-) + +commit 183819bfd9efac8c184d9bf123325719b7eee30f +Author: Jia Tan +Date: 2023-05-13 20:11:13 +0800 + + xz: Set the Block size for mt encoding correctly. + + When opt_block_size is not used, the Block size for mt encoder is + derived from the minimum of the largest Block specified by + --block-list and the recommended Block size on all filter chains + calculated by lzma_mt_block_size(). This avoids using unnecessary + memory and ensures that all Blocks are large enough for the most memory + needy filter chain. + + src/xz/coder.c | 68 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++- + 1 file changed, 67 insertions(+), 1 deletion(-) + +commit afb2dbec3d857b026486b75e42a4728e12d234cb +Author: Jia Tan +Date: 2023-05-11 00:09:41 +0800 + + xz: Validate --flush-timeout for all specified filter chains. + + src/xz/coder.c | 24 ++++++++++++++++-------- + 1 file changed, 16 insertions(+), 8 deletions(-) + +commit 5f0c5a04388f8334962c70bc37a8c2ff8f605e0a +Author: Jia Tan +Date: 2023-05-13 19:54:33 +0800 + + xz: Allows --block-list filters to scale down memory usage. + + Previously, only the default filter chain could have its memory usage + adjusted. The filter chains specified with --filtersX were not checked + for memory usage. Now, all used filter chains will be adjusted if + necessary. + + src/xz/coder.c | 269 +++++++++++++++++++++++++++++++++++++++++++++------------ + 1 file changed, 214 insertions(+), 55 deletions(-) + +commit 479fd58d60622331fcbe48fddf756927b9f80d9a +Author: Jia Tan +Date: 2023-05-10 21:50:33 +0800 + + xz: Do not include block splitting if encoders are disabled. + + The block splitting logic and split_block() function are not needed if + encoders are disabled. This will help slightly reduce the binary size + when built without encoders and allow split_block() to use functions + that require encoders being enabled. + + src/xz/coder.c | 29 ++++++++++++++++++++--------- + 1 file changed, 20 insertions(+), 9 deletions(-) + +commit f86ede22500f7ae024ec3ec3f3489ab5a857a3b3 +Author: Jia Tan +Date: 2023-05-10 22:38:59 +0800 + + xz: Free filters[] in debug mode. + + This will only free filter chains created with --filters1-9 since the + default filter chain may be set from a static function variable. The + complexity to free the default filter chain is not worth the burden on + code maintenance. + + src/xz/coder.c | 10 ++++++++++ + 1 file changed, 10 insertions(+) + +commit f281cd0d692ac0c70fc7669b80dddb863ea947e1 +Author: Jia Tan +Date: 2023-05-13 19:28:23 +0800 + + xz: Add a message if --block-list is used outside of xz compresssion. + + --block-list is only supported with compression in xz format. This avoids + silently ignoring when --block-list is unused. + + src/xz/args.c | 11 +++++++++++ + 1 file changed, 11 insertions(+) + +commit d6af7f347077b22403133239592e478931307759 +Author: Jia Tan +Date: 2023-04-18 20:29:09 +0800 + + xz: Create command line options for filters[1-9]. + + The new command line options are meant to be combined with --block-list. + They work as an optional extension to --block-list to specify a custom + filter chain for each block listed. The new options allow the creation + of up to 9 reusable filter chains. For instance: + + xz --block-list=1:10MiB,3:5MiB,,2:5MiB,1:0 --filters1=delta--lzma2 \ + --filters2=x86--lzma2 --filters3=arm64--lzma2 + + Will create the following blocks: + 1. A block of size 10 MiB with filter chain delta, lzma2. + 2. A block of size 5 MiB with filter chain arm64, lzma2. + 3. A block of size 5 MiB with filter chain arm64, lzma2. + 4. A block of size 5 MiB with filter chain x86, lzma2. + 5. A block containing the rest of the file contents with filter chain + delta, lzma2. + + src/xz/args.c | 82 ++++++++++++++++++++++--- + src/xz/coder.c | 188 ++++++++++++++++++++++++++++++++++++++++++--------------- + src/xz/coder.h | 20 +++++- + 3 files changed, 230 insertions(+), 60 deletions(-) + +commit 072d29250113268536719ad0e040ab8a66fb6435 +Author: Jia Tan +Date: 2023-05-13 19:36:09 +0800 + + xz: Use lzma_filters_free() in forget_filter_chain(). + + This is a little cleaner than the previous implementation of + forget_filter_chain(). It is also more consistent since + lzma_str_to_filters() will always terminate the filter chain so there + is no need to terminate it later in coder_set_compression_settings(). + + src/xz/coder.c | 18 ++++++++++-------- + 1 file changed, 10 insertions(+), 8 deletions(-) + +commit 3d21da5cff4b511633cb6e0d8a1090485c0c1059 +Author: Jia Tan +Date: 2023-04-17 22:22:45 +0800 + + xz: Separate string to filter conversion into a helper function. + + Converting from string to filter will also need to be done for block + specific filter chains. + + src/xz/coder.c | 33 ++++++++++++++++++++------------- + 1 file changed, 20 insertions(+), 13 deletions(-) + +commit a6583726e5f950278f96abcf79c04f1056810be6 +Author: Jia Tan +Date: 2023-01-06 00:03:35 +0800 + + Tests: Use new --filters option in test_compress.sh + + tests/test_compress.sh | 20 ++++++++++---------- + 1 file changed, 10 insertions(+), 10 deletions(-) + +commit 5f3b898d07cc9b7160c7c88b3120b7edabb8a5b0 +Author: Jia Tan +Date: 2023-01-06 00:03:06 +0800 + + xz: Update --long-help and man page for new --filters option. + + src/xz/message.c | 6 ++++++ + src/xz/xz.1 | 41 ++++++++++++++++++++++++++++++++++++----- + 2 files changed, 42 insertions(+), 5 deletions(-) + +commit 9ded880a0221f4d1256845fc4ab957ffd377c760 +Author: Jia Tan +Date: 2023-01-06 00:02:29 +0800 + + xz: Add --filters option to CLI. + + The --filters option uses the new lzma_str_to_filters() function + to convert a string into a full filter chain. Using this option + will reset all previous filters set by --preset, --[filter], or + --filters. + + src/xz/args.c | 9 +++++++-- + src/xz/coder.c | 50 ++++++++++++++++++++++++++++++++++++++++++++++++-- + src/xz/coder.h | 3 +++ + 3 files changed, 58 insertions(+), 4 deletions(-) + +commit 2c189bb00af73dc7ba1a67a9d274d5be03ee3a88 +Author: Jia Tan +Date: 2023-07-14 21:30:25 +0800 + + Tests: Improve feature testing for skipping. + + Fixed a bug where test_compress_* would all fail if arm64 or armthumb + filters were enabled for compression but arm was disabled. Since the + grep tests only checked for "define HAVE_ENCODER_ARM", this would match + on HAVE_ENCODER_ARM64 or HAVE_ENCODER_ARMTHUMB. + + Now the config.h feature test requires " 1" at the end to prevent the + prefix problem. have_feature() was also updated for this even though + there were known current bugs affecting it. This is just in case future + features have a similar prefix problem. + + tests/test_compress.sh | 4 ++-- + tests/test_files.sh | 2 +- + 2 files changed, 3 insertions(+), 3 deletions(-) + +commit 80a6b9bcad016c99c9ba3f3eeb4a619fcadfd357 +Author: Jia Tan +Date: 2023-07-10 20:56:28 +0800 + + Translations: Update the Chinese (traditional) translation. + + po/zh_TW.po | 659 ++++++++++++++++++++++++++++++++++-------------------------- + 1 file changed, 377 insertions(+), 282 deletions(-) + +commit 17f8844e6fc355abf997d77637a7447c4f7bbcbd +Author: Jia Tan +Date: 2023-07-08 21:24:19 +0800 + + liblzma: Remove non-portable empty initializer. + + Commit 78704f36e74205857c898a351c757719a6c8b666 added an empty + initializer {} to prevent a warning. The empty initializer is a GNU + extension and results in a build failure on MSVC. The -wpedantic flag + warns about empty initializers. + + src/liblzma/common/stream_encoder_mt.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit 3aca4f629cd577f0c54f594d5d88722edf0b0413 +Author: Jia Tan +Date: 2023-07-08 20:03:59 +0800 + + Translations: Update the Vietnamese translation. + + po/vi.po | 620 +++++++++++++++++++++++++++++++++++---------------------------- + 1 file changed, 349 insertions(+), 271 deletions(-) + +commit 66bdcfa85fef2911cc80f5f30fed3f9610faccb4 +Author: Jia Tan +Date: 2023-06-28 20:46:31 +0800 + + Tests: Fix memory leaks in test_index. + + Several tests were missing calls to lzma_index_end() to clean up the + lzma_index structs. The memory leaks were discovered by using + -fsanitize=address with GCC. + + tests/test_index.c | 11 +++++++++++ + 1 file changed, 11 insertions(+) + +commit fe3bd438fb119f9bad3f08dc29d331e4956196e1 +Author: Jia Tan +Date: 2023-06-28 20:43:29 +0800 + + Tests: Fix memory leaks in test_block_header. + + test_block_header was not properly freeing the filter options between + calls to lzma_block_header_decode(). The memory leaks were discovered by + using -fsanitize=address with GCC. + + tests/test_block_header.c | 38 ++++++++++++++++++++++---------------- + 1 file changed, 22 insertions(+), 16 deletions(-) + +commit 78704f36e74205857c898a351c757719a6c8b666 +Author: Jia Tan +Date: 2023-06-28 20:31:11 +0800 + + liblzma: Prevent uninitialzed warning in mt stream encoder. + + This change only impacts the compiler warning since it was impossible + for the wait_abs struct in stream_encode_mt() to be used before it was + initialized since mythread_condtime_set() will always be called before + mythread_cond_timedwait(). + + Since the mythread.h code is different between the POSIX and + Windows versions, this warning was only present on Windows builds. + + Thanks to Arthur S for reporting the warning and providing an initial + patch. + + src/liblzma/common/stream_encoder_mt.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit e3356a204c5ae02db3ec4552b6c1be354e9b6142 +Author: Jia Tan +Date: 2023-06-28 20:22:38 +0800 + + liblzma: Prevent warning for MSYS2 Windows build. + + In lzma_memcmplen(), the header file is only included if + _MSC_VER and _M_X64 are both defined but _BitScanForward64() was + previously used if _M_X64 was defined. GCC for MSYS2 defines _M_X64 but + not _MSC_VER so _BitScanForward64() was used without including + . + + Now, lzma_memcmplen() will use __builtin_ctzll() for MSYS2 GCC builds as + expected. + + src/liblzma/common/memcmplen.h | 6 ++++-- + 1 file changed, 4 insertions(+), 2 deletions(-) + +commit 45e250a9e9f3c3e8e8af2983366b170bf54f890e +Author: Jia Tan +Date: 2023-06-28 21:01:22 +0800 + + CI: Add test with -fsanitize=address,undefined. + + ci_build.sh was updated to accept disabling of __attribute__ ifunc + and CLMUL. This will allow -fsanitize=address to pass because ifunc + is incompatible with -fsanitize=address. The CLMUL implementation has + optimizations that potentially read past the buffer and mask out the + unwanted bytes. + + This test will only run on Autotools Linux. + + .github/workflows/ci.yml | 23 +++++++++++++++++++---- + build-aux/ci_build.sh | 8 +++++++- + 2 files changed, 26 insertions(+), 5 deletions(-) + +commit 596ee722cd7ddf0afae584fc06365adc0e735977 +Author: Jia Tan +Date: 2023-06-28 20:16:04 +0800 + + CI: Upgrade checkout action from v2 to v3. + + .github/workflows/ci.yml | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit 86118ea320f867e09e98a8682cc08cbbdfd640e2 +Author: Jia Tan +Date: 2023-06-27 23:38:32 +0800 + + Update THANKS. + + THANKS | 1 + + 1 file changed, 1 insertion(+) + +commit 3d1fdddf92321b516d55651888b9c669e254634e +Author: Jia Tan +Date: 2023-06-27 17:27:09 +0300 + + Docs: Document the configure option --disable-ifunc in INSTALL. + + INSTALL | 8 ++++++++ + 1 file changed, 8 insertions(+) + +commit b4cf7a2822e8d30eb2b12a1a07fd04383b10ade3 +Author: Lasse Collin +Date: 2023-06-27 17:24:49 +0300 + + Minor tweaks to style and comments. + + CMakeLists.txt | 8 ++++---- + configure.ac | 9 +++++---- + 2 files changed, 9 insertions(+), 8 deletions(-) + +commit 23fb9e3a329117c2968c1e7388b6ef07c782dba1 +Author: Lasse Collin +Date: 2023-06-27 17:19:49 +0300 + + CMake: Rename CHECK_ATTR_IFUNC to ALLOW_ATTR_IFUNC. + + It's so that there's a clear difference in wording compared + to liblzma's integrity check types. + + CMakeLists.txt | 6 +++--- + 1 file changed, 3 insertions(+), 3 deletions(-) + +commit ee44863ae88e377a5df10db007ba9bfadde3d314 +Author: Lasse Collin +Date: 2023-06-27 17:05:23 +0300 + + liblzma: Add ifunc implementation to crc64_fast.c. + + The ifunc method avoids indirection via the function pointer + crc64_func. This works on GNU/Linux and probably on FreeBSD too. + The previous __attribute((__constructor__)) method is kept for + compatibility with ELF platforms which do support ifunc. + + The ifunc method has some limitations, for example, building + liblzma with -fsanitize=address will result in segfaults. + The configure option --disable-ifunc must be used for such builds. + + Thanks to Hans Jansen for the original patch. + Closes: https://github.com/tukaani-project/xz/pull/53 + + src/liblzma/check/crc64_fast.c | 35 ++++++++++++++++++++++++++--------- + 1 file changed, 26 insertions(+), 9 deletions(-) + +commit b72d21202402a603db6d512fb9271cfa83249639 +Author: Hans Jansen +Date: 2023-06-22 19:49:30 +0200 + + Add ifunc check to CMakeLists.txt + + CMake build system will now verify if __attribute__((__ifunc__())) can be + used in the build system. If so, HAVE_FUNC_ATTRIBUTE_IFUNC will be + defined to 1. + + CMakeLists.txt | 19 +++++++++++++++++++ + 1 file changed, 19 insertions(+) + +commit 23b5c36fb71904bfbe16bb20f976da38dadf6c3b +Author: Hans Jansen +Date: 2023-06-22 19:46:55 +0200 + + Add ifunc check to configure.ac + + configure.ac will now verify if __attribute__((__ifunc__())) can be used in + the build system. If so, HAVE_FUNC_ATTRIBUTE_IFUNC will be defined to 1. + + configure.ac | 28 ++++++++++++++++++++++++++++ + 1 file changed, 28 insertions(+) + +commit dbb3a536ed9873ffa0870321f6873e564c6a9da8 +Author: Jia Tan +Date: 2023-06-07 00:18:30 +0800 + + CI: Add apt update command before installing dependencies. + + Without the extra command, all of the CI tests were automatically + failing because the Ubuntu servers could not be reached properly. + + .github/workflows/ci.yml | 8 ++++++-- + 1 file changed, 6 insertions(+), 2 deletions(-) + +commit 6bcd516812331de42b347922913230895bebad34 +Author: Jia Tan +Date: 2023-06-07 00:10:38 +0800 + + Update THANKS. + + THANKS | 1 + + 1 file changed, 1 insertion(+) + +commit 0d94ba69220d894d2a86081821d2d7a89df5a10b +Author: Benjamin Buch +Date: 2023-06-06 15:32:45 +0200 + + CMake: Protects against double find_package + + Boost iostream uses `find_package` in quiet mode and then again uses + `find_package` with required. This second call triggers a + `add_library cannot create imported target "ZLIB::ZLIB" because another + target with the same name already exists.` + + This can simply be fixed by skipping the alias part on secondary + `find_package` runs. + + CMakeLists.txt | 16 +++++++++------- + 1 file changed, 9 insertions(+), 7 deletions(-) + +commit 045d7aae286ecd2ce163be9e0d9041343a03f89a +Author: Jia Tan +Date: 2023-05-31 20:26:42 +0800 + + Translations: Update the Esperanto translation. + + po/eo.po | 185 +++++++++++++++++++++++++++++++-------------------------------- + 1 file changed, 92 insertions(+), 93 deletions(-) + +commit b0cc7c2dcefe4cbc4e1e697598c14fb687ed0b78 +Author: Jia Tan +Date: 2023-05-31 20:25:00 +0800 + + Translations: Update the Croatian translation. + + po/hr.po | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit af045ef6f848f02cd14c9ad195a5f87bb0c02dce +Author: Jia Tan +Date: 2023-05-31 20:15:53 +0800 + + Translations: Update the Chinese (simplified) translation. + + po/zh_CN.po | 317 ++++++++++++++++++++++++++++++------------------------------ + 1 file changed, 157 insertions(+), 160 deletions(-) + +commit e6b92d5817fe91ad27a0f7f57bd0f2144311e383 +Author: Jia Tan +Date: 2023-05-17 23:12:13 +0800 + + Translations: Update German translation of man pages. + + po4a/de.po | 52 ++++++++++++---------------------------------------- + 1 file changed, 12 insertions(+), 40 deletions(-) + +commit 592961ccdbba39c7d60fe37e36764232feb57c60 +Author: Jia Tan +Date: 2023-05-17 23:09:18 +0800 + + Translations: Update the German translation. + + po/de.po | 189 +++++++++++++++++++++++++++++++-------------------------------- + 1 file changed, 94 insertions(+), 95 deletions(-) + +commit 13572cb2c391f5b7503e333c6e05b20bd5bbb524 +Author: Jia Tan +Date: 2023-05-17 20:30:01 +0800 + + Translations: Update the Croatian translation. + + po/hr.po | 187 +++++++++++++++++++++++++++++++-------------------------------- + 1 file changed, 93 insertions(+), 94 deletions(-) + +commit 4e6e425ea8f097c6fb43e69cc9540294dca3680d +Author: Jia Tan +Date: 2023-05-17 20:26:54 +0800 + + Translations: Update Korean translation of man pages. + + po4a/ko.po | 3015 ++++++++++++------------------------------------------------ + 1 file changed, 568 insertions(+), 2447 deletions(-) + +commit d5ef1f6faf7c270f60093629257150085ecf19ca +Author: Jia Tan +Date: 2023-05-17 20:13:01 +0800 + + Translations: Update the Korean translation. + + po/ko.po | 319 +++++++++++++++++++++++++++++++-------------------------------- + 1 file changed, 158 insertions(+), 161 deletions(-) + +commit e22d0b0f2e301e7906d0106689d967ed84362028 +Author: Jia Tan +Date: 2023-05-16 23:49:09 +0800 + + Translations: Update the Spanish translation. + + po/es.po | 319 +++++++++++++++++++++++++++++++-------------------------------- + 1 file changed, 158 insertions(+), 161 deletions(-) + +commit f50da74d52d01f6cfd826a921249e289cf671678 +Author: Jia Tan +Date: 2023-05-16 23:47:23 +0800 + + Translations: Update the Romanian translation. + + po/ro.po | 195 ++++++++++++++++++++++++++++++++------------------------------- + 1 file changed, 98 insertions(+), 97 deletions(-) + +commit 4b9ad60a7305e9841b7cb4ea611bdf5fa7271696 +Author: Jia Tan +Date: 2023-05-16 23:45:43 +0800 + + Translations: Update Romanian translation of man pages. + + po4a/ro.po | 19 ++++++++++--------- + 1 file changed, 10 insertions(+), 9 deletions(-) + +commit cb6fd57f889c5d9fab36ae8c9e10083a5fe32dea +Author: Jia Tan +Date: 2023-05-16 23:43:51 +0800 + + Translations: Update Ukrainian translation of man pages. + + po4a/uk.po | 12 ++++++------ + 1 file changed, 6 insertions(+), 6 deletions(-) + +commit c3e8fcbc2db4861f92ad15606c995bd255803c52 +Author: Jia Tan +Date: 2023-05-16 23:37:54 +0800 + + Translations: Update the Ukrainian translation. + + po/uk.po | 321 +++++++++++++++++++++++++++++++-------------------------------- + 1 file changed, 159 insertions(+), 162 deletions(-) + +commit 27b81b84fcedbc55aa6e6b21004c44070b15b038 +Author: Jia Tan +Date: 2023-05-16 23:07:35 +0800 + + Translations: Update the Polish translation. + + po/pl.po | 316 +++++++++++++++++++++++++++++++-------------------------------- + 1 file changed, 155 insertions(+), 161 deletions(-) + +commit 8024ad636a65ed6ea95c94d57255be4c6724d6ed +Author: Jia Tan +Date: 2023-05-16 22:52:14 +0800 + + Translations: Update the Swedish translation. + + po/sv.po | 319 +++++++++++++++++++++++++++++++-------------------------------- + 1 file changed, 158 insertions(+), 161 deletions(-) + +commit 6699a29673f227c4664826db485ed9f7596320d2 +Author: Jia Tan +Date: 2023-05-16 21:21:38 +0800 + + Translations: Update the Esperanto translation. + + po/eo.po | 34 +++++++++++++++++----------------- + 1 file changed, 17 insertions(+), 17 deletions(-) + +commit f36ca7982f6bd5e9827219ed4f3c5a1fbf5d7bdf +Author: Jia Tan +Date: 2023-05-13 21:21:54 +0800 + + liblzma: Slightly rewords lzma_str_list_filters() documentation. + + Reword "options required" to "supported options". The previous may have + suggested that the options listed were all required anytime a filter is + used for encoding or decoding. The reword makes this more clear that + adjusting the options is optional. + + src/liblzma/api/lzma/filter.h | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit 3374a5359e52f1671d8f831d65827d5020fe2595 +Author: Jia Tan +Date: 2023-05-11 23:49:23 +0800 + + liblzma: Adds lzma_nothrow to MicroLZMA API functions. + + None of the liblzma functions may throw an exception, so this + attribute should be applied to all liblzma API functions. + + src/liblzma/api/lzma/container.h | 5 +++-- + 1 file changed, 3 insertions(+), 2 deletions(-) + +commit 8f236574986e7c414c0ea059f441982d1387e6a4 +Author: Jia Tan +Date: 2023-05-09 20:20:06 +0800 + + liblzma: Exports lzma_mt_block_size() as an API function. + + The lzma_mt_block_size() was previously just an internal function for + the multithreaded .xz encoder. It is used to provide a recommended Block + size for a given filter chain. + + This function is helpful to determine the maximum Block size for the + multithreaded .xz encoder when one wants to change the filters between + blocks. Then, this determined Block size can be provided to + lzma_stream_encoder_mt() in the lzma_mt options parameter when + intializing the coder. This requires one to know all the filter chains + they are using before starting to encode (or at least the filter chain + that will need the largest Block size), but that isn't a bad limitation. + + src/liblzma/api/lzma/container.h | 28 ++++++++++++++++++++++++++++ + src/liblzma/common/filter_encoder.c | 16 ++++++++++------ + src/liblzma/common/filter_encoder.h | 6 +----- + src/liblzma/common/stream_encoder_mt.c | 20 +++++++++----------- + src/liblzma/liblzma_generic.map | 5 +++++ + src/liblzma/liblzma_linux.map | 5 +++++ + src/liblzma/lzma/lzma2_encoder.c | 3 +++ + 7 files changed, 61 insertions(+), 22 deletions(-) + +commit d0f33d672a4da7985ebb5ba8d829f885de49c171 +Author: Jia Tan +Date: 2023-05-08 22:58:09 +0800 + + liblzma: Creates IS_ENC_DICT_SIZE_VALID() macro. + + This creates an internal liblzma macro to test if the dictionary size + is valid for encoding. + + src/liblzma/lz/lz_encoder.c | 4 +--- + src/liblzma/lz/lz_encoder.h | 8 ++++++++ + 2 files changed, 9 insertions(+), 3 deletions(-) + +commit c247d06e1f6cada9a76f4f6225cbd97ea760f52f +Author: Jia Tan +Date: 2023-05-02 20:39:56 +0800 + + Add NEWS for 5.4.3. + + NEWS | 10 ++++++++++ + 1 file changed, 10 insertions(+) + +commit 77050b78364ffb6b0f129e742b7c31602d725c08 +Author: Jia Tan +Date: 2023-05-02 20:39:37 +0800 + + Add NEWS for 5.2.12. + + NEWS | 14 ++++++++++++++ + 1 file changed, 14 insertions(+) + +commit 713e15e43eb6279a7ab4bbad3d1325ebfdcf09a0 +Author: Jia Tan +Date: 2023-05-04 20:38:52 +0800 + + Translations: Update the Croatian translation. + + po/hr.po | 6 +++--- + 1 file changed, 3 insertions(+), 3 deletions(-) + +commit 9ad64bdf309844b6ca6c3e8a4dfb6dbaedda0ca9 +Author: Jia Tan +Date: 2023-05-04 20:30:25 +0800 + + tuklib_integer.h: Reverts previous commit. + + Previous commit 6be460dde07113fe3f08f814b61ddc3264125a96 would cause an + error if the integer size was 32 bit. + + src/common/tuklib_integer.h | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +commit 6be460dde07113fe3f08f814b61ddc3264125a96 +Author: Jia Tan +Date: 2023-05-04 19:25:20 +0800 + + tuklib_integer.h: Changes two other UINT_MAX == UINT32_MAX to >=. + + src/common/tuklib_integer.h | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +commit 44c0c5eae990a22ef04e9b88c1a15838a0d00878 +Author: Lasse Collin +Date: 2023-05-03 22:46:42 +0300 + + tuklib_integer.h: Fix a recent copypaste error in Clang detection. + + Wrong line was changed in 7062348bf35c1e4cbfee00ad9fffb4a21aa6eff7. + Also, this has >= instead of == since ints larger than 32 bits would + work too even if not relevant in practice. + + src/common/tuklib_integer.h | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +commit 2cf5ae5b5b279b0b2e69ca4724e7bd705865fe68 +Author: Jia Tan +Date: 2023-04-25 20:06:15 +0800 + + CI: Adds a build and test for small configuration. + + .github/workflows/ci.yml | 5 +++++ + 1 file changed, 5 insertions(+) + +commit 16b81a057a87c2f18e6ed6447f003af0cbdcfe43 +Author: Jia Tan +Date: 2023-04-25 20:05:26 +0800 + + CI: ci_build.sh allows configuring small build. + + build-aux/ci_build.sh | 7 ++++++- + 1 file changed, 6 insertions(+), 1 deletion(-) + +commit 78ccd93951f9e988d447bcdd70b24f6df5448d1d +Author: Jia Tan +Date: 2023-04-20 20:15:00 +0800 + + Update THANKS. + + THANKS | 1 + + 1 file changed, 1 insertion(+) + +commit f41df2ac2fed347d3f107f3533e76e000d29c6cb +Author: Jia Tan +Date: 2023-04-19 22:22:16 +0800 + + Windows: Include when needed. + + Legacy Windows did not need to #include to use the MSVC + intrinsics. Newer versions likely just issue a warning, but the MSVC + documentation says to include the header file for the intrinsics we use. + + GCC and Clang can "pretend" to be MSVC on Windows, so extra checks are + needed in tuklib_integer.h to only include when it will is + actually needed. + + src/common/tuklib_integer.h | 6 ++++++ + src/liblzma/common/memcmplen.h | 10 ++++++++++ + 2 files changed, 16 insertions(+) + +commit 7062348bf35c1e4cbfee00ad9fffb4a21aa6eff7 +Author: Jia Tan +Date: 2023-04-19 21:59:03 +0800 + + tuklib_integer: Use __builtin_clz() with Clang. + + Clang has support for __builtin_clz(), but previously Clang would + fallback to either the MSVC intrinsic or the regular C code. This was + discovered due to a bug where a new version of Clang required the + header file in order to use the MSVC intrinsics. + + Thanks to Anton Kochkov for notifying us about the bug. + + src/common/tuklib_integer.h | 6 +++--- + 1 file changed, 3 insertions(+), 3 deletions(-) + +commit 3938718ce3773c90755785c0df8777f133b7ae29 +Author: Lasse Collin +Date: 2023-04-14 18:42:33 +0300 + + liblzma: Update project maintainers in lzma.h. + + AUTHORS was updated earlier, lzma.h was simply forgotten. + + src/liblzma/api/lzma.h | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit 2a89670ab295e377f8b44f5bda6d198deb8ea285 +Author: Jia Tan +Date: 2023-04-13 20:45:19 +0800 + + liblzma: Cleans up old commented out code. + + src/liblzma/common/alone_encoder.c | 11 ----------- + 1 file changed, 11 deletions(-) + +commit 0fbb2b87a7b5a1dd9d0f4a5e84ac7919557dbe81 +Author: Jia Tan +Date: 2023-04-07 20:46:41 +0800 + + Docs: Add missing word to SECURITY.md. + + .github/SECURITY.md | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit fb9c50f38a17bf37581de4034b36c8df8ec90a87 +Author: Jia Tan +Date: 2023-04-07 20:43:22 +0800 + + Update THANKS. + + THANKS | 1 + + 1 file changed, 1 insertion(+) + +commit 537c6cd8a9db0dd6b13683e64ddac2943190d715 +Author: Jia Tan +Date: 2023-04-07 20:42:12 +0800 + + Docs: Minor edits to SECURITY.md. + + .github/SECURITY.md | 25 ++++++++++++++++++++----- + 1 file changed, 20 insertions(+), 5 deletions(-) + +commit 6549df8dd53f358345957e232648fdb699930074 +Author: Gabriela Gutierrez +Date: 2023-04-07 12:08:30 +0000 + + Docs: Create SECURITY.md + + Signed-off-by: Gabriela Gutierrez + + .github/SECURITY.md | 14 ++++++++++++++ + 1 file changed, 14 insertions(+) + +commit d0faa85df5a5d253a4625d45313cf5e9277e6cd2 +Author: Jia Tan +Date: 2023-03-28 22:48:24 +0800 + + CI: Tests for disabling threading on CMake builds. + + .github/workflows/ci.yml | 3 --- + build-aux/ci_build.sh | 4 ++-- + 2 files changed, 2 insertions(+), 5 deletions(-) + +commit 8be5cc3b1359d88b4b30a39067466c0ae0bfbc4d +Author: Jia Tan +Date: 2023-03-28 22:45:42 +0800 + + CI: Removes CMakeCache.txt between builds. + + If the cache file is not removed, CMake will not reset configurations + back to their default values. In order to make the tests independent, it + is simplest to purge the cache. Unfortunatly, this will slow down the + tests a little and repeat some checks. + + build-aux/ci_build.sh | 2 ++ + 1 file changed, 2 insertions(+) + +commit 2cb6028fc31de082b7f927632363bb1426b61aaa +Author: Jia Tan +Date: 2023-03-28 22:32:40 +0800 + + CMake: Update liblzma-config.cmake generation. + + Now that the threading is configurable, the liblzma CMake package only + needs the threading library when using POSIX threads. + + CMakeLists.txt | 33 ++++++++++++++++++++++----------- + 1 file changed, 22 insertions(+), 11 deletions(-) + +commit 4d7fac0b07cc722825ba8d7838c558827e635611 +Author: Jia Tan +Date: 2023-03-28 22:25:33 +0800 + + CMake: Allows setting thread method. + + The thread method is now configurable for the CMake build. It matches + the Autotools build by allowing ON (pick the best threading method), + OFF (no threading), posix, win95, and vista. If both Windows and + posix threading are both available, then ON will choose Windows + threading. Windows threading will also not use: + + target_link_libraries(liblzma Threads::Threads) + + since on systems like MinGW-w64 it would link the posix threads + without purpose. + + CMakeLists.txt | 144 +++++++++++++++++++++++++++++++++++++++++---------------- + 1 file changed, 104 insertions(+), 40 deletions(-) + +commit 20cd905d898c1494dee42b78530769bb9c9f8076 +Author: Jia Tan +Date: 2023-03-24 23:05:48 +0800 + + CI: Runs CMake feature tests. + + Now, CMake will run similar feature disable tests that the Autotools + version did before. In order to do this without repeating lines in + ci.yml, it now makes sense to use the GitHub Workflow matrix to create + a loop. + + .github/workflows/ci.yml | 169 +++++++++++++++-------------------------------- + 1 file changed, 55 insertions(+), 114 deletions(-) + +commit 4fabdb269f1fc5624b3b94a170c4efb329d1d229 +Author: Jia Tan +Date: 2023-03-24 20:35:11 +0800 + + CI: ci_build.sh allows CMake features to be configured. + + Also included various clean ups for style and helper functions for + repeated work. + + build-aux/ci_build.sh | 233 +++++++++++++++++++++++++++++++------------------- + 1 file changed, 143 insertions(+), 90 deletions(-) + +commit cf3d1f130e50cf63da4bb1031771605f6f443b6a +Author: Jia Tan +Date: 2023-03-24 20:06:33 +0800 + + CI: Change ci_build.sh to use bash instead of sh. + + This script is only meant to be run as part of the CI build/test process + on machines that are known to have bash (Ubuntu and MacOS). If this + assumption changes in the future, then the bash specific commands will + need to be replaced with a more portable option. For now, it is + convenient to use bash commands. + + build-aux/ci_build.sh | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit ddfe164368e779c40d061aa4ccc376129e92f8e1 +Author: Jia Tan +Date: 2023-03-24 20:05:59 +0800 + + CMake: Only build xzdec if decoders are enabled. + + CMakeLists.txt | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit 116e81f002c503d3c3cd12726db8f9116e58ef25 +Author: Jia Tan +Date: 2023-03-22 15:42:04 +0800 + + Build: Removes redundant check for LZMA1 filter support. + + src/liblzma/lzma/Makefile.inc | 5 +---- + 1 file changed, 1 insertion(+), 4 deletions(-) + +commit 0ba234f692772595329d225462d391fe2c199d0a +Author: Lasse Collin +Date: 2023-03-23 15:14:29 +0200 + + CMake: Bump maximum policy version to 3.26. + + It adds only one new policy related to FOLDERS which we don't use. + This makes it clear that the code is compatible with the policies + up to 3.26. + + CMakeLists.txt | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit b0891684b4436aed31510fddcbb218d513bd5489 +Author: Jia Tan +Date: 2023-03-21 23:36:00 +0800 + + CMake: Conditionally build xz list.* files if decoders are enabled. + + CMakeLists.txt | 9 +++++++-- + 1 file changed, 7 insertions(+), 2 deletions(-) + +commit 2c1a830efb61d9d65906a09c9ee3ce27c2c49227 +Author: Jia Tan +Date: 2023-02-25 11:46:50 +0800 + + CMake: Allow configuring features as cache variables. + + This allows users to change the features they build either in + CMakeCache.txt or by using a CMake GUI. The sources built for + liblzma are affected by this too, so only the necessary files + will be compiled. + + CMakeLists.txt | 528 ++++++++++++++++++++++++++++++++++++++++++--------------- + 1 file changed, 391 insertions(+), 137 deletions(-) + +commit 8be136f667aaeb8f9e16fbd57a83cb282f0c27ff +Author: Lasse Collin +Date: 2023-03-21 14:07:51 +0200 + + Build: Add a comment that AC_PROG_CC_C99 is needed for Autoconf 2.69. + + It's obsolete in Autoconf >= 2.70 and just an alias for AC_PROG_CC + but Autoconf 2.69 requires AC_PROG_CC_C99 to get a C99 compiler. + + configure.ac | 3 +++ + 1 file changed, 3 insertions(+) + +commit 53cc475f2652d9e390ca002018dfd0af0626ef80 +Author: Lasse Collin +Date: 2023-03-21 14:04:37 +0200 + + Build: configure.ac: Use AS_IF and AS_CASE where required. + + This makes no functional difference in the generated configure + (at least with the Autotools versions I have installed) but this + change might prevent future bugs like the one that was just + fixed in the commit 5a5bd7f871818029d5ccbe189f087f591258c294. + + configure.ac | 30 +++++++++++++++--------------- + 1 file changed, 15 insertions(+), 15 deletions(-) + +commit 3b8890a40233b6c783bb101ec14405e786871775 +Author: Lasse Collin +Date: 2023-03-21 13:12:03 +0200 + + Update THANKS. + + THANKS | 1 + + 1 file changed, 1 insertion(+) + +commit 5a5bd7f871818029d5ccbe189f087f591258c294 +Author: Lasse Collin +Date: 2023-03-21 13:11:49 +0200 + + Build: Fix --disable-threads breaking the building of shared libs. + + This is broken in the releases 5.2.6 to 5.4.2. A workaround + for these releases is to pass EGREP='grep -E' as an argument + to configure in addition to --disable-threads. + + The problem appeared when m4/ax_pthread.m4 was updated in + the commit 6629ed929cc7d45a11e385f357ab58ec15e7e4ad which + introduced the use of AC_EGREP_CPP. AC_EGREP_CPP calls + AC_REQUIRE([AC_PROG_EGREP]) to set the shell variable EGREP + but this was only executed if POSIX threads were enabled. + Libtool code also has AC_REQUIRE([AC_PROG_EGREP]) but Autoconf + omits it as AC_PROG_EGREP has already been required earlier. + Thus, if not using POSIX threads, the shell variable EGREP + would be undefined in the Libtool code in configure. + + ax_pthread.m4 is fine. The bug was in configure.ac which called + AX_PTHREAD conditionally in an incorrect way. Using AS_CASE + ensures that all AC_REQUIREs get always run. + + Thanks to Frank Busse for reporting the bug. + Fixes: https://github.com/tukaani-project/xz/issues/45 + + configure.ac | 16 ++++++++-------- + 1 file changed, 8 insertions(+), 8 deletions(-) + +commit dfe1710784c0a3c3a90c17b80c9e1fe19b5fce06 +Author: Lasse Collin +Date: 2023-03-19 22:45:59 +0200 + + liblzma: Silence -Wsign-conversion in SSE2 code in memcmplen.h. + + Thanks to Christian Hesse for reporting the issue. + Fixes: https://github.com/tukaani-project/xz/issues/44 + + src/liblzma/common/memcmplen.h | 3 ++- + 1 file changed, 2 insertions(+), 1 deletion(-) + +commit f0c580c5fc38bf49a184b48d76c1d8c057d499ce +Author: Jia Tan +Date: 2023-03-18 22:10:57 +0800 + + Add NEWS for 5.4.2. + + NEWS | 48 ++++++++++++++++++++++++++++++++++++++++++++++++ + 1 file changed, 48 insertions(+) + +commit af4925e6043113ec9b5f9c0cf13abf2a18ccb1f6 +Author: Jia Tan +Date: 2023-03-18 22:10:12 +0800 + + Add NEWS for 5.2.11. + + NEWS | 27 +++++++++++++++++++++++++++ + 1 file changed, 27 insertions(+) + +commit 5a7b930efa7f9849d8da8397e8e5d8638f92be40 +Author: Lasse Collin +Date: 2023-03-18 16:00:54 +0200 + + Update the copy of GNU GPLv3 from gnu.org to COPYING.GPLv3. + + COPYING.GPLv3 | 8 ++++---- + 1 file changed, 4 insertions(+), 4 deletions(-) + +commit b473a92891f7e991398a3b5eff305f6f2b6d7293 +Author: Lasse Collin +Date: 2023-03-18 15:51:57 +0200 + + Change a few HTTP URLs to HTTPS. + + The xz man page timestamp was intentionally left unchanged. + + INSTALL | 2 +- + README | 8 ++++---- + configure.ac | 2 +- + dos/INSTALL.txt | 4 ++-- + src/liblzma/api/lzma.h | 8 ++++---- + src/liblzma/check/sha256.c | 2 +- + src/xz/xz.1 | 2 +- + windows/INSTALL-MinGW.txt | 10 +++++----- + 8 files changed, 19 insertions(+), 19 deletions(-) + +commit 8b2f6001b4f412c259a7883427f2f2c8cea98ea8 +Author: Jia Tan +Date: 2023-03-18 00:40:28 +0800 + + CMake: Fix typo in a comment. + + CMakeLists.txt | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit 76e2315e14c399c15cc90e7930fd4d3d086b0227 +Author: Lasse Collin +Date: 2023-03-17 18:36:22 +0200 + + Windows: build.bash: Copy liblzma API docs to the output package. + + windows/build.bash | 3 ++- + 1 file changed, 2 insertions(+), 1 deletion(-) + +commit 133cf55edc5ce92952d2709abd992e48ef1f45ee +Author: Lasse Collin +Date: 2023-03-17 08:53:38 +0200 + + Windows: Add microlzma_*.c to the VS project files. + + These should have been included in 5.3.2alpha already. + + windows/vs2013/liblzma.vcxproj | 2 ++ + windows/vs2013/liblzma_dll.vcxproj | 2 ++ + windows/vs2017/liblzma.vcxproj | 2 ++ + windows/vs2017/liblzma_dll.vcxproj | 2 ++ + windows/vs2019/liblzma.vcxproj | 2 ++ + windows/vs2019/liblzma_dll.vcxproj | 2 ++ + 6 files changed, 12 insertions(+) + +commit 75c9ca450fab6982fda9286b168081c9d54126cd +Author: Lasse Collin +Date: 2023-03-17 08:43:51 +0200 + + CMake: Add microlzma_*.c to the build. + + These should have been included in 5.3.2alpha already. + + CMakeLists.txt | 2 ++ + 1 file changed, 2 insertions(+) + +commit 0cc3313bd4e569c51e686e5aab8c40c35241d34b +Author: Lasse Collin +Date: 2023-03-17 08:41:36 +0200 + + Build: Update comments about unaligned access to mention 64-bit. + + cmake/tuklib_integer.cmake | 7 +++---- + m4/tuklib_integer.m4 | 4 ++-- + 2 files changed, 5 insertions(+), 6 deletions(-) + +commit 5e57e3301319f20c35f8111dea73fa58403b96b1 +Author: Lasse Collin +Date: 2023-03-17 00:02:30 +0200 + + Tests: Update .gitignore. + + .gitignore | 3 ++- + 1 file changed, 2 insertions(+), 1 deletion(-) + +commit 0007394d54e21bf30abb9a5e09cbc1e8d44a73ac +Author: Lasse Collin +Date: 2023-03-14 20:04:03 +0200 + + po4a/update-po: Display the script name consistently in error messages. + + po4a/update-po | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit 509157c80c500426ec853bd992d684ebafc8500c +Author: Jia Tan +Date: 2023-03-17 01:30:36 +0800 + + Doc: Rename Doxygen HTML doc directory name liblzma => api. + + When the docs are installed, calling the directory "liblzma" is + confusing since multiple other files in the doc directory are for + liblzma. This should also make it more natural for distros when they + package the documentation. + + .gitignore | 2 +- + Makefile.am | 18 +++++++++--------- + PACKAGERS | 4 ++-- + doxygen/Doxyfile | 2 +- + doxygen/update-doxygen | 18 +++++++++--------- + 5 files changed, 22 insertions(+), 22 deletions(-) + +commit fd90e2f4c29180b44e33c7ef726f94e4eae54ed3 +Author: Jia Tan +Date: 2023-03-16 22:07:15 +0800 + + liblzma: Remove note from lzma_options_bcj about the ARM64 exception. + + This was left in by mistake since an early version of the ARM64 filter + used a different struct for its options. + + src/liblzma/api/lzma/bcj.h | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit 4f50763b981f9056c5f1763dfb26cfa4a26a181d +Author: Jia Tan +Date: 2023-03-16 21:44:02 +0800 + + CI: Add doxygen as a dependency. + + Autogen now requires --no-doxygen or having doxygen installed to run + without errors. + + .github/workflows/ci.yml | 5 ++--- + 1 file changed, 2 insertions(+), 3 deletions(-) + +commit f68f4b27f62f53fdac570885a1f4f23367ce6599 +Author: Lasse Collin +Date: 2023-03-15 19:19:13 +0200 + + COPYING: Add a note about the included Doxygen-generated HTML. + + COPYING | 11 +++++++++++ + 1 file changed, 11 insertions(+) + +commit 8979308528c1f45cb9ee52d511f05232b4ad90a1 +Author: Jia Tan +Date: 2023-03-16 21:41:09 +0800 + + Doc: Update PACKAGERS with details about liblzma API docs install. + + PACKAGERS | 22 ++++++++++++++++------ + 1 file changed, 16 insertions(+), 6 deletions(-) + +commit 55ba6e93004842ae0a0792214a23504267ad8f43 +Author: Jia Tan +Date: 2023-03-16 21:38:32 +0800 + + liblzma: Add set lzma.h as the main page for Doxygen documentation. + + The \mainpage command is used in the first block of comments in lzma.h. + This changes the previously nearly empty index.html to use the first + comment block in lzma.h for its contents. + + lzma.h is no longer documented separately, but this is for the better + since lzma.h only defined a few macros that users do not need to use. + The individual API header files all have a disclaimer that they should + not be #included directly, so there should be no confusion on the fact + that lzma.h should be the only header used by applications. + + Additionally, the note "See ../lzma.h for information about liblzma as + a whole." was removed since lzma.h is now the main page of the + generated HTML and does not have its own page anymore. So it would be + confusing in the HTML version and was only a "nice to have" when + browsing the source files. + + src/liblzma/api/lzma.h | 1 + + src/liblzma/api/lzma/base.h | 2 -- + src/liblzma/api/lzma/bcj.h | 2 -- + src/liblzma/api/lzma/block.h | 2 -- + src/liblzma/api/lzma/check.h | 2 -- + src/liblzma/api/lzma/container.h | 2 -- + src/liblzma/api/lzma/delta.h | 2 -- + src/liblzma/api/lzma/filter.h | 2 -- + src/liblzma/api/lzma/hardware.h | 2 -- + src/liblzma/api/lzma/index.h | 2 -- + src/liblzma/api/lzma/index_hash.h | 4 +--- + src/liblzma/api/lzma/lzma12.h | 2 -- + src/liblzma/api/lzma/stream_flags.h | 2 -- + src/liblzma/api/lzma/version.h | 2 -- + src/liblzma/api/lzma/vli.h | 2 -- + 15 files changed, 2 insertions(+), 29 deletions(-) + +commit 16f21255597f6a57e5692780f962cdc090f62b8c +Author: Jia Tan +Date: 2023-03-16 21:37:32 +0800 + + Build: Generate doxygen documentation in autogen.sh. + + Another command line option (--no-doxygen) was added to disable + creating the doxygen documenation in cases where it not wanted or + if the doxygen tool is not installed. + + autogen.sh | 35 +++++++++++++++++++++++++++++------ + 1 file changed, 29 insertions(+), 6 deletions(-) + +commit 1321852a3be7196bd7fcfd146221a5669e46407c +Author: Jia Tan +Date: 2023-03-16 21:35:55 +0800 + + Build: Create doxygen/update-doxygen script. + + This is a helper script to generate the Doxygen documentation. It can be + run in 'liblzma' or 'internal' mode by setting the first argument. It + will default to 'liblzma' mode and only generate documentation for the + liblzma API header files. + + The helper script will be run during the custom mydist hook when we + create releases. This hook already alters the source directory, so its + fine to do it here too. This way, we can include the Doxygen generated + files in the distrubtion and when installing. + + In 'liblzma' mode, the JavaScript is stripped from the .html files and + the .js files are removed. This avoids license hassle from jQuery and + other libraries that Doxygen 1.9.6 puts into jquery.js in minified form. + + Makefile.am | 1 + + doxygen/update-doxygen | 111 +++++++++++++++++++++++++++++++++++++++++++++++++ + 2 files changed, 112 insertions(+) + +commit b1216a7772952d2fe7fe9c6acfcbd98d30abbc7b +Author: Jia Tan +Date: 2023-03-16 21:34:36 +0800 + + Build: Install Doxygen docs and include in distribution if generated. + + Added a install-data-local target to install the Doxygen documentation + only when it has been generated. In order to correctly remove the docs, + a corresponding uninstall-local target was added. + + If the doxygen docs exist in the source tree, they will also be included + in the distribution now too. + + Makefile.am | 18 ++++++++++++++++++ + 1 file changed, 18 insertions(+) + +commit c97d12f300b2a94c9f54a44c8931c8bc08cf0a73 +Author: Lasse Collin +Date: 2023-03-16 21:23:48 +0800 + + Doxygen: Refactor Doxyfile.in to doxygen/Doxyfile. + + Instead of having Doxyfile.in configured by Autoconf, the Doxyfile + can have the tags that need to be configured piped into the doxygen + command through stdin with the overrides after Doxyfile's contents. + + Going forward, the documentation should be generated in two different + modes: liblzma or internal. + + liblzma is useful for most users. It is the documentation for just + the liblzma API header files. This is the default. + + internal is for people who want to understand how xz and liblzma work. + It might be useful for people who want to contribute to the project. + + .gitignore | 3 +- + Makefile.am | 1 - + configure.ac | 40 --- + Doxyfile.in => doxygen/Doxyfile | 721 +++++++++++++++++++++++++--------------- + 4 files changed, 456 insertions(+), 309 deletions(-) + +commit 1b7661faa4bbf4a54c6b75900b5059835c382a0f +Author: Jia Tan +Date: 2023-02-28 23:22:36 +0800 + + Tests: Remove unused macros and functions. + + tests/tests.h | 75 ----------------------------------------------------------- + 1 file changed, 75 deletions(-) + +commit af55191102f01e76de658c881299f0909ca0feda +Author: Jia Tan +Date: 2022-12-29 21:52:15 +0800 + + liblzma: Defines masks for return values from lzma_index_checks(). + + src/liblzma/api/lzma/index.h | 23 +++++++++++++++++++++++ + tests/test_index.c | 22 +++++++++++----------- + 2 files changed, 34 insertions(+), 11 deletions(-) + +commit 8f38cdd9ab71e2a9d5a9787550222b7578243b73 +Author: Jia Tan +Date: 2023-01-12 22:29:07 +0800 + + Tests: Refactors existing lzma_index tests. + + Converts the existing lzma_index tests into tuktests and covers every + API function from index.h except for lzma_file_info_decoder, which can + be tested in the future. + + tests/test_index.c | 2036 ++++++++++++++++++++++++++++++++++++++-------------- + 1 file changed, 1492 insertions(+), 544 deletions(-) + +commit 717aa3651ce582807f379d8654c2516e1594df77 +Author: Lasse Collin +Date: 2023-03-11 18:42:08 +0200 + + xz: Simplify the error-label in Capsicum sandbox code. + + Also remove unneeded "sandbox_allowed = false;" as this code + will never be run more than once (making it work with multiple + input files isn't trivial). + + src/xz/file_io.c | 27 ++++++++++++--------------- + 1 file changed, 12 insertions(+), 15 deletions(-) + +commit a0eecc235d3ba8ad3453da98b46c7bc3e644de75 +Author: Lasse Collin +Date: 2023-03-07 19:59:23 +0200 + + xz: Make Capsicum sandbox more strict with stdin and stdout. + + src/xz/file_io.c | 8 ++++++++ + 1 file changed, 8 insertions(+) + +commit 916448d624aaf55cef0fc3e53754affb8c4f309d +Author: Jia Tan +Date: 2023-03-08 23:08:46 +0800 + + Revert: "Add warning if Capsicum sandbox system calls are unsupported." + + The warning causes the exit status to be 2, so this will cause problems + for many scripted use cases for xz. The sandbox usage is already very + limited already, so silently disabling this allows it to be more usable. + + src/xz/file_io.c | 10 ++++------ + 1 file changed, 4 insertions(+), 6 deletions(-) + +commit 01587dda2a8f13fef7e12fd624e6d05da5f9624f +Author: Jia Tan +Date: 2023-03-07 20:02:22 +0800 + + xz: Fix -Wunused-label in io_sandbox_enter(). + + Thanks to Xin Li for recommending the fix. + + src/xz/file_io.c | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +commit 5fb936786601a1cd013a5d436adde65982b1e13c +Author: Jia Tan +Date: 2023-03-06 21:37:45 +0800 + + xz: Add warning if Capsicum sandbox system calls are unsupported. + + The warning is only used when errno == ENOSYS. Otherwise, xz still + issues a fatal error. + + src/xz/file_io.c | 2 ++ + 1 file changed, 2 insertions(+) + +commit 61ee82cb1232a402c82282bbae42821f2b952b0d +Author: Jia Tan +Date: 2023-03-06 21:27:53 +0800 + + xz: Skip Capsicum sandbox system calls when they are unsupported. + + If a system has the Capsicum header files but does not actually + implement the system calls, then this would render xz unusable. Instead, + we can check if errno == ENOSYS and not issue a fatal error. + + src/xz/file_io.c | 22 +++++++++++++++++----- + 1 file changed, 17 insertions(+), 5 deletions(-) + +commit f070722b57ba975a0dff36492d766f03026b1d21 +Author: Jia Tan +Date: 2023-03-06 21:08:26 +0800 + + xz: Reorder cap_enter() to beginning of capsicum sandbox code. + + cap_enter() puts the process into the sandbox. If later calls to + cap_rights_limit() fail, then the process can still have some extra + protections. + + src/xz/file_io.c | 6 +++--- + 1 file changed, 3 insertions(+), 3 deletions(-) + +commit f1ab1f6b339d16a53ac53efeb97779ecd2bae70f +Author: Jia Tan +Date: 2023-02-24 23:46:23 +0800 + + liblzma: Clarify lzma_lzma_preset() documentation in lzma12.h. + + lzma_lzma_preset() does not guarentee that the lzma_options_lzma are + usable in an encoder even if it returns false (success). If liblzma + is built with default configurations, then the options will always be + usable. However if the match finders hc3, hc4, or bt4 are disabled, then + the options may not be usable depending on the preset level requested. + + The documentation was updated to reflect this complexity, since this + behavior was unclear before. + + src/liblzma/api/lzma/lzma12.h | 5 +++++ + 1 file changed, 5 insertions(+) + +commit 4b7fb3bf41a0ca4c97fad3799949a2aa61b13b99 +Author: Lasse Collin +Date: 2023-02-27 18:38:35 +0200 + + CMake: Require that the C compiler supports C99 or a newer standard. + + Thanks to autoantwort for reporting the issue and suggesting + a different patch: + https://github.com/tukaani-project/xz/pull/42 + + CMakeLists.txt | 8 ++++++++ + 1 file changed, 8 insertions(+) + +commit 9aa7fdeb04c486d2700967090956af88fdccab7e +Author: Jia Tan +Date: 2023-02-24 18:10:37 +0800 + + Tests: Small tweak to test-vli.c. + + The static global variables can be disabled if encoders and decoders + are not built. If they are not disabled and -Werror is used, it will + cause an usused warning as an error. + + tests/test_vli.c | 2 ++ + 1 file changed, 2 insertions(+) + +commit 3cf72c4bcba5370f07477c9b9b62ae33069ef9a9 +Author: Jia Tan +Date: 2023-02-06 21:46:43 +0800 + + liblzma: Replace '\n' -> newline in filter.h documentation. + + The '\n' renders as a newline when the comments are converted to html + by Doxygen. + + src/liblzma/api/lzma/filter.h | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit 002006be62d77c706565fa6ec828bea64be302da +Author: Jia Tan +Date: 2023-02-06 21:45:37 +0800 + + liblzma: Shorten return description for two functions in filter.h. + + Shorten the description for lzma_raw_encoder_memusage() and + lzma_raw_decoder_memusage(). + + src/liblzma/api/lzma/filter.h | 8 ++------ + 1 file changed, 2 insertions(+), 6 deletions(-) + +commit 463d9359b8595f01d44ada1739d75aeb87f36524 +Author: Jia Tan +Date: 2023-02-06 21:44:45 +0800 + + liblzma: Reword a few lines in filter.h + + src/liblzma/api/lzma/filter.h | 10 +++++----- + 1 file changed, 5 insertions(+), 5 deletions(-) + +commit 01441df92c0fd6a6c02fe5ac27982a54ce887cc0 +Author: Jia Tan +Date: 2023-02-06 21:35:06 +0800 + + liblzma: Improve documentation in filter.h. + + All functions now explicitly specify parameter and return values. + The notes and code annotations were moved before the parameter and + return value descriptions for consistency. + + Also, the description above lzma_filter_encoder_is_supported() about + not being able to list available filters was removed since + lzma_str_list_filters() will do this. + + src/liblzma/api/lzma/filter.h | 226 ++++++++++++++++++++++++++---------------- + 1 file changed, 143 insertions(+), 83 deletions(-) + +commit 805b45cd60bfd5da3d3d89077de3789df179b324 +Author: Lasse Collin +Date: 2023-02-23 20:46:16 +0200 + + Update THANKS. + + THANKS | 1 + + 1 file changed, 1 insertion(+) + +commit 30e95bb44c36ae26b2ab12a94343b215fec285e7 +Author: Lasse Collin +Date: 2023-02-21 22:57:10 +0200 + + liblzma: Avoid null pointer + 0 (undefined behavior in C). + + In the C99 and C17 standards, section 6.5.6 paragraph 8 means that + adding 0 to a null pointer is undefined behavior. As of writing, + "clang -fsanitize=undefined" (Clang 15) diagnoses this. However, + I'm not aware of any compiler that would take advantage of this + when optimizing (Clang 15 included). It's good to avoid this anyway + since compilers might some day infer that pointer arithmetic implies + that the pointer is not NULL. That is, the following foo() would then + unconditionally return 0, even for foo(NULL, 0): + + void bar(char *a, char *b); + + int foo(char *a, size_t n) + { + bar(a, a + n); + return a == NULL; + } + + In contrast to C, C++ explicitly allows null pointer + 0. So if + the above is compiled as C++ then there is no undefined behavior + in the foo(NULL, 0) call. + + To me it seems that changing the C standard would be the sane + thing to do (just add one sentence) as it would ensure that a huge + amount of old code won't break in the future. Based on web searches + it seems that a large number of codebases (where null pointer + 0 + occurs) are being fixed instead to be future-proof in case compilers + will some day optimize based on it (like making the above foo(NULL, 0) + return 0) which in the worst case will cause security bugs. + + Some projects don't plan to change it. For example, gnulib and thus + many GNU tools currently require that null pointer + 0 is defined: + + https://lists.gnu.org/archive/html/bug-gnulib/2021-11/msg00000.html + + https://www.gnu.org/software/gnulib/manual/html_node/Other-portability-assumptions.html + + In XZ Utils null pointer + 0 issue should be fixed after this + commit. This adds a few if-statements and thus branches to avoid + null pointer + 0. These check for size > 0 instead of ptr != NULL + because this way bugs where size > 0 && ptr == NULL will likely + get caught quickly. None of them are in hot spots so it shouldn't + matter for performance. + + A little less readable version would be replacing + + ptr + offset + + with + + offset != 0 ? ptr + offset : ptr + + or creating a macro for it: + + #define my_ptr_add(ptr, offset) \ + ((offset) != 0 ? ((ptr) + (offset)) : (ptr)) + + Checking for offset != 0 instead of ptr != NULL allows GCC >= 8.1, + Clang >= 7, and Clang-based ICX to optimize it to the very same code + as ptr + offset. That is, it won't create a branch. So for hot code + this could be a good solution to avoid null pointer + 0. Unfortunately + other compilers like ICC 2021 or MSVC 19.33 (VS2022) will create a + branch from my_ptr_add(). + + Thanks to Marcin Kowalczyk for reporting the problem: + https://github.com/tukaani-project/xz/issues/36 + + src/liblzma/common/block_decoder.c | 5 ++++- + src/liblzma/common/block_encoder.c | 7 +++++-- + src/liblzma/common/common.c | 20 ++++++++++++++------ + src/liblzma/common/index_decoder.c | 13 ++++++++++--- + src/liblzma/common/index_encoder.c | 11 +++++++++-- + src/liblzma/common/index_hash.c | 13 ++++++++++--- + src/liblzma/common/lzip_decoder.c | 6 +++++- + src/liblzma/delta/delta_decoder.c | 7 ++++++- + src/liblzma/delta/delta_encoder.c | 12 ++++++++++-- + src/liblzma/simple/simple_coder.c | 6 ++++-- + 10 files changed, 77 insertions(+), 23 deletions(-) + +commit fa9065fac54194fe0407fc7f0cc9633fdce13c21 +Author: Jia Tan +Date: 2023-02-07 00:00:44 +0800 + + liblzma: Adjust container.h for consistency with filter.h. + + src/liblzma/api/lzma/container.h | 20 +++++++++----------- + 1 file changed, 9 insertions(+), 11 deletions(-) + +commit 00a721b63d82dfb658dca8d8cb599d8a245c663f +Author: Jia Tan +Date: 2023-02-07 00:00:09 +0800 + + liblzma: Fix small typos and reword a few things in filter.h. + + src/liblzma/api/lzma/container.h | 13 ++++++------- + 1 file changed, 6 insertions(+), 7 deletions(-) + +commit 5b1c171d4ffe89ef18fa31509bb0185d6fd11d39 +Author: Jia Tan +Date: 2023-02-06 23:42:08 +0800 + + liblzma: Convert list of flags in lzma_mt to bulleted list. + + src/liblzma/api/lzma/container.h | 9 ++++++--- + 1 file changed, 6 insertions(+), 3 deletions(-) + +commit dbd47622eb99fefb3538a22baec3def002aa56f5 +Author: Jia Tan +Date: 2023-01-26 23:17:41 +0800 + + liblzma: Fix typo in documentation in container.h + + lzma_microlzma_decoder -> lzma_microlzma_encoder + + src/liblzma/api/lzma/container.h | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit 14cd30806d69e55906073745bcce3ee50e0ec942 +Author: Jia Tan +Date: 2023-01-26 23:16:34 +0800 + + liblzma: Improve documentation for container.h + + Standardizing each function to always specify parameters and return + values. Also moved the parameters and return values to the end of each + function description. + + src/liblzma/api/lzma/container.h | 146 +++++++++++++++++++++++++-------------- + 1 file changed, 93 insertions(+), 53 deletions(-) + +commit c9c8bfae3502842dcead85eeb2b951b437c2cd88 +Author: Jia Tan +Date: 2023-02-22 20:59:41 +0800 + + CMake: Add LZIP decoder test to list of tests. + + CMakeLists.txt | 1 + + 1 file changed, 1 insertion(+) + +commit b9f171dd00a3cc32b6d41ea8e082cf545640ec2a +Author: Lasse Collin +Date: 2023-02-17 20:56:49 +0200 + + Update THANKS. + + THANKS | 1 + + 1 file changed, 1 insertion(+) + +commit 2ee86d20e49985b903b78ebcfa3fa672e73e93aa +Author: Lasse Collin +Date: 2023-02-17 20:48:28 +0200 + + Build: Use only the generic symbol versioning on MicroBlaze. + + On MicroBlaze, GCC 12 is broken in sense that + __has_attribute(__symver__) returns true but it still doesn't + support the __symver__ attribute even though the platform is ELF + and symbol versioning is supported if using the traditional + __asm__(".symver ...") method. Avoiding the traditional method is + good because it breaks LTO (-flto) builds with GCC. + + See also: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=101766 + + For now the only extra symbols in liblzma_linux.map are the + compatibility symbols with the patch that spread from RHEL/CentOS 7. + These require the use of __symver__ attribute or __asm__(".symver ...") + in the C code. Compatibility with the patch from CentOS 7 doesn't + seem valuable on MicroBlaze so use liblzma_generic.map on MicroBlaze + instead. It doesn't require anything special in the C code and thus + no LTO issues either. + + An alternative would be to detect support for __symver__ + attribute in configure.ac and CMakeLists.txt and fall back + to __asm__(".symver ...") but then LTO would be silently broken + on MicroBlaze. It sounds likely that MicroBlaze is a special + case so let's treat it as a such because that is simpler. If + a similar issue exists on some other platform too then hopefully + someone will report it and this can be reconsidered. + + (This doesn't do the same fix in CMakeLists.txt. Perhaps it should + but perhaps CMake build of liblzma doesn't matter much on MicroBlaze. + The problem breaks the build so it's easy to notice and can be fixed + later.) + + Thanks to Vincent Fazio for reporting the problem and proposing + a patch (in the end that solution wasn't used): + https://github.com/tukaani-project/xz/pull/32 + + configure.ac | 12 ++++++++++-- + 1 file changed, 10 insertions(+), 2 deletions(-) + +commit d831072cceca458d94d2d5da201862f6d43a417b +Author: Lasse Collin +Date: 2023-02-16 21:09:00 +0200 + + liblzma: Very minor API doc tweaks. + + Use "member" to refer to struct members as that's the term used + by the C standard. + + Use lzma_options_delta.dist and such in docs so that in Doxygen's + HTML output they will link to the doc of the struct member. + + Clean up a few trailing white spaces too. + + src/liblzma/api/lzma/block.h | 6 +++--- + src/liblzma/api/lzma/delta.h | 6 +++--- + src/liblzma/api/lzma/index.h | 10 +++++----- + src/liblzma/api/lzma/stream_flags.h | 6 +++--- + 4 files changed, 14 insertions(+), 14 deletions(-) + +commit f029daea39c215fd7d5cb6b6798818b055cf5b22 +Author: Jia Tan +Date: 2023-02-17 00:54:33 +0800 + + liblzma: Adjust spacing in doc headers in bcj.h. + + src/liblzma/api/lzma/bcj.h | 14 +++++++------- + 1 file changed, 7 insertions(+), 7 deletions(-) + +commit a5de68bac2bb7e1b9119e6cea7d761a22ea73e9c +Author: Jia Tan +Date: 2023-02-17 00:44:44 +0800 + + liblzma: Adjust documentation in bcj.h for consistent style. + + src/liblzma/api/lzma/bcj.h | 43 ++++++++++++++++++++++--------------------- + 1 file changed, 22 insertions(+), 21 deletions(-) + +commit efa498c13b883810497e0ea8a169efd6f48f5026 +Author: Jia Tan +Date: 2023-02-17 00:36:05 +0800 + + liblzma: Rename field => member in documentation. + + Also adjusted preset value => preset level. + + src/liblzma/api/lzma/base.h | 18 +++++++-------- + src/liblzma/api/lzma/block.h | 44 ++++++++++++++++++------------------- + src/liblzma/api/lzma/container.h | 26 +++++++++++----------- + src/liblzma/api/lzma/delta.h | 12 +++++----- + src/liblzma/api/lzma/index.h | 30 ++++++++++++------------- + src/liblzma/api/lzma/lzma12.h | 28 +++++++++++------------ + src/liblzma/api/lzma/stream_flags.h | 32 +++++++++++++-------------- + 7 files changed, 95 insertions(+), 95 deletions(-) + +commit 718b22a6c5e3ee5de123323ea798872381f9320e +Author: Lasse Collin +Date: 2023-02-16 17:59:50 +0200 + + liblzma: Silence a warning from MSVC. + + It gives C4146 here since unary minus with unsigned integer + is still unsigned (which is the intention here). Doing it + with substraction makes it clearer and avoids the warning. + + Thanks to Nathan Moinvaziri for reporting this. + + src/liblzma/check/crc64_fast.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit 87c53553fa7d50f777b4edfa99f2083628f590fe +Author: Jia Tan +Date: 2023-02-16 21:04:54 +0800 + + liblzma: Improve documentation for stream_flags.h + + Standardizing each function to always specify parameters and return + values. Also moved the parameters and return values to the end of each + function description. + + A few small things were reworded and long sentences broken up. + + src/liblzma/api/lzma/stream_flags.h | 76 ++++++++++++++++++++++--------------- + 1 file changed, 46 insertions(+), 30 deletions(-) + +commit 13d99e75a543e9e5f8633cc241eae55b91a3b242 +Author: Jia Tan +Date: 2023-02-14 21:50:16 +0800 + + liblzma: Improve documentation in lzma12.h. + + All functions now explicitly specify parameter and return values. + + src/liblzma/api/lzma/lzma12.h | 32 +++++++++++++++++++++++--------- + 1 file changed, 23 insertions(+), 9 deletions(-) + +commit 43ec344c868f930e96879eb9e49212cce92a9884 +Author: Jia Tan +Date: 2023-01-27 22:44:06 +0800 + + liblzma: Improve documentation in check.h. + + All functions now explicitly specify parameter and return values. + Also moved the note about SHA-256 functions not being exported to the + top of the file. + + src/liblzma/api/lzma/check.h | 41 ++++++++++++++++++++++++++++------------- + 1 file changed, 28 insertions(+), 13 deletions(-) + +commit 9c71db4e884fd49aea3d1e711036bff45ca66487 +Author: Jia Tan +Date: 2023-02-08 21:33:52 +0800 + + liblzma: Improve documentation in index.h + + All functions now explicitly specify parameter and return values. + + src/liblzma/api/lzma/index.h | 177 ++++++++++++++++++++++++++++++------------- + 1 file changed, 126 insertions(+), 51 deletions(-) + +commit 421f2f2e160720f6009e3b6a125cafe2feaa9419 +Author: Jia Tan +Date: 2023-02-08 20:35:32 +0800 + + liblzma: Reword a comment in index.h. + + src/liblzma/api/lzma/index.h | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +commit b67539484981351d501b68de5e925425e50c59b1 +Author: Jia Tan +Date: 2023-02-08 20:30:23 +0800 + + liblzma: Omit lzma_index_iter's internal field from Doxygen docs. + + Add \private above this field and its sub-fields since it is not meant + to be modified by users. + + src/liblzma/api/lzma/index.h | 9 ++++++++- + 1 file changed, 8 insertions(+), 1 deletion(-) + +commit 0c9e4fc2ad6d88d54f299240fcc5a2ce7d695d96 +Author: Jia Tan +Date: 2023-01-21 21:32:03 +0800 + + liblzma: Fix documentation for LZMA_MEMLIMIT_ERROR. + + LZMA_MEMLIMIT_ERROR was missing the "<" character needed to put + documentation after a member. + + src/liblzma/api/lzma/base.h | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit 816fec125aa74bcef46512c73acc6d9e5a700d15 +Author: Jia Tan +Date: 2023-01-21 00:29:38 +0800 + + liblzma: Improve documentation for base.h. + + Standardizing each function to always specify params and return values. + Also fixed a small grammar mistake. + + src/liblzma/api/lzma/base.h | 30 +++++++++++++++++++++++++----- + 1 file changed, 25 insertions(+), 5 deletions(-) + +commit 862dacef1a4e7e1b28d465956fa4244ed01df154 +Author: Jia Tan +Date: 2023-02-14 00:12:34 +0800 + + liblzma: Add one more missing [out] annotation in vli.h + + src/liblzma/api/lzma/vli.h | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit 867b08ae4254bf55dd1f7fd502cc618231b92f75 +Author: Jia Tan +Date: 2023-02-14 00:08:33 +0800 + + liblzma: Minor improvements to vli.h. + + Added [out] annotations to parameters that are pointers and can have + their value changed. Also added a clarification to lzma_vli_is_valid. + + src/liblzma/api/lzma/vli.h | 13 +++++++------ + 1 file changed, 7 insertions(+), 6 deletions(-) + +commit 90d0e628ff11e5030bcc4fc000bca056adda6603 +Author: Jia Tan +Date: 2023-02-10 21:38:02 +0800 + + liblzma: Add comments for macros in delta.h. + + Document LZMA_DELTA_DIST_MIN and LZMA_DELTA_DIST_MAX for completeness + and to avoid Doxygen warnings. + + src/liblzma/api/lzma/delta.h | 8 ++++++++ + 1 file changed, 8 insertions(+) + +commit 9255fffdb13e59874bf7f95c370c410ad3a7e114 +Author: Jia Tan +Date: 2023-02-10 21:35:23 +0800 + + liblzma: Improve documentation in index_hash.h. + + All functions now explicitly specify parameter and return values. + Also reworded the description of lzma_index_hash_init() for readability. + + src/liblzma/api/lzma/index_hash.h | 36 +++++++++++++++++++++++++++--------- + 1 file changed, 27 insertions(+), 9 deletions(-) + +commit 1dbe12b90cff79bb51923733ac0840747b4b4131 +Author: Lasse Collin +Date: 2023-02-07 19:07:45 +0200 + + xz: Improve the comment about start_time in mytime.c. + + start_time is relative to an arbitary point in time, it's not + time of day, so using it for anything else than time differences + wouldn't make sense. + + src/xz/mytime.c | 15 ++++++++++----- + 1 file changed, 10 insertions(+), 5 deletions(-) + +commit 7673ef5aa80c1af7fb693360dd82f527b46c2c56 +Author: Jia Tan +Date: 2023-02-04 21:06:35 +0800 + + Build: Adjust CMake version search regex. + + Now, the LZMA_VERSION_MAJOR, LZMA_VERSION_MINOR, and LZMA_VERSION_PATCH + macros do not need to be on consecutive lines in version.h. They can be + separated by more whitespace, comments, or even other content, as long + as they appear in the proper order (major, minor, patch). + + CMakeLists.txt | 2 ++ + 1 file changed, 2 insertions(+) + +commit b8bce89be7fb5bffe5fef4a2782ca9b2b107eaac +Author: Jia Tan +Date: 2023-02-04 12:01:23 +0800 + + xz: Add a comment clarifying the use of start_time in mytime.c. + + src/xz/mytime.c | 5 +++++ + 1 file changed, 5 insertions(+) + +commit 912af91b10a18fb9bb3167247ecaaefca8248ee9 +Author: Jia Tan +Date: 2023-01-26 09:50:21 +0800 + + liblzma: Improve documentation for version.h. + + Specified parameter and return values for API functions and documented + a few more of the macros. + + src/liblzma/api/lzma/version.h | 29 ++++++++++++++++++++++------- + 1 file changed, 22 insertions(+), 7 deletions(-) + +commit 850adec171203cd22b57d016084d713f72ae5307 +Author: Jia Tan +Date: 2023-02-03 22:52:55 +0800 + + Docs: Omit SIGTSTP not handled from TODO. + + TODO | 4 ---- + 1 file changed, 4 deletions(-) + +commit 2c78a83c6faec70154d9eb78022a618ed62cdcb3 +Author: Jia Tan +Date: 2023-02-03 00:33:32 +0800 + + liblzma: Fix bug in lzma_str_from_filters() not checking filters[] length. + + The bug is only a problem in applications that do not properly terminate + the filters[] array with LZMA_VLI_UNKNOWN or have more than + LZMA_FILTERS_MAX filters. This bug does not affect xz. + + src/liblzma/common/string_conversion.c | 7 +++++++ + 1 file changed, 7 insertions(+) + +commit e01f01b9af1c074463b92694a16ecc16a31907c0 +Author: Jia Tan +Date: 2023-02-03 00:32:47 +0800 + + Tests: Create test_filter_str.c. + + Tests lzma_str_to_filters(), lzma_str_from_filters(), and + lzma_str_list_filters() API functions. + + CMakeLists.txt | 1 + + tests/Makefile.am | 2 + + tests/test_filter_str.c | 593 ++++++++++++++++++++++++++++++++++++++++++++++++ + 3 files changed, 596 insertions(+) + +commit 8dfc029e7a4ce45809c30313dc0e502f0d22be26 +Author: Jia Tan +Date: 2023-01-22 08:49:00 +0800 + + liblzma: Fix typos in comments in string_conversion.c. + + src/liblzma/common/string_conversion.c | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +commit 54ad83c1ae2180dcc0cb2445b181dc1e9732a5d6 +Author: Jia Tan +Date: 2023-02-03 00:20:20 +0800 + + liblzma: Clarify block encoder and decoder documentation. + + Added a few sentences to the description for lzma_block_encoder() and + lzma_block_decoder() to highlight that the Block Header must be coded + before calling these functions. + + src/liblzma/api/lzma/block.h | 15 +++++++++++---- + 1 file changed, 11 insertions(+), 4 deletions(-) + +commit f680e771b3eb2a46310fe85b3e000ac3a1a0640f +Author: Jia Tan +Date: 2023-02-03 00:12:24 +0800 + + Update lzma_block documentation for lzma_block_uncomp_encode(). + + src/liblzma/api/lzma/block.h | 3 +++ + 1 file changed, 3 insertions(+) + +commit 504cf4af895fd45aad0c56eb3b49d90acd54465b +Author: Jia Tan +Date: 2023-02-03 00:11:37 +0800 + + liblzma: Minor edits to lzma_block header_size documentation. + + src/liblzma/api/lzma/block.h | 3 ++- + 1 file changed, 2 insertions(+), 1 deletion(-) + +commit 115b720fb521f99aa832d06b2c12b7f8c6c50680 +Author: Jia Tan +Date: 2023-02-03 00:11:07 +0800 + + liblzma: Enumerate functions that read version in lzma_block. + + src/liblzma/api/lzma/block.h | 13 +++++++++++-- + 1 file changed, 11 insertions(+), 2 deletions(-) + +commit 85ea0979adcf808a3830aefbe7a4ec884e542ea1 +Author: Jia Tan +Date: 2023-02-03 00:10:34 +0800 + + liblzma: Clarify comment in block.h. + + src/liblzma/api/lzma/block.h | 3 ++- + 1 file changed, 2 insertions(+), 1 deletion(-) + +commit 1f7ab90d9ce224230a04de6b921ad6e2029023a8 +Author: Jia Tan +Date: 2023-02-03 00:07:23 +0800 + + liblzma: Improve documentation for block.h. + + Standardizing each function to always specify params and return values. + Output pointer parameters are also marked with doxygen style [out] to + make it clear. Any note sections were also moved above the parameter and + return sections for consistency. + + src/liblzma/api/lzma/block.h | 96 ++++++++++++++++++++++++++++++++++---------- + 1 file changed, 75 insertions(+), 21 deletions(-) + +commit c563a4bc554a96bd0b6aab3c139715b7ec8f6ca3 +Author: Jia Tan +Date: 2023-02-01 23:38:30 +0800 + + liblzma: Clarify a comment about LZMA_STR_NO_VALIDATION. + + The flag description for LZMA_STR_NO_VALIDATION was previously confusing + about the treatment for filters than cannot be used with .xz format + (lzma1) without using LZMA_STR_ALL_FILTERS. Now, it is clear that + LZMA_STR_NO_VALIDATION is not a super set of LZMA_STR_ALL_FILTERS. + + src/liblzma/api/lzma/filter.h | 5 +++-- + 1 file changed, 3 insertions(+), 2 deletions(-) + +commit 315c64c7e18acc59a745b68148188a73e998252b +Author: Jia Tan +Date: 2023-02-01 21:43:33 +0800 + + CI: Update .gitignore for artifacts directory in build-aux. + + The workflow action for our CI pipeline can only reference artifacts in + the source directory, so we should ignore these files if the ci_build.sh + is run locally. + + .gitignore | 1 + + 1 file changed, 1 insertion(+) + +commit 2c1341f4fa06e7f487d61142aa354c433e17ec7f +Author: Jia Tan +Date: 2023-02-01 21:36:46 +0800 + + CI: Add quotes around variables in a few places. + + build-aux/ci_build.sh | 6 +++--- + 1 file changed, 3 insertions(+), 3 deletions(-) + +commit 3a401b0e0c7a2658af7801dd0690256ef24149e0 +Author: Jia Tan +Date: 2023-02-01 21:36:22 +0800 + + CI: Upload test logs as artifacts if a test fails. + + .github/workflows/ci.yml | 60 ++++++++++++++++++++++++++++++++++-------------- + build-aux/ci_build.sh | 31 ++++++++++++++++++++----- + 2 files changed, 68 insertions(+), 23 deletions(-) + +commit 610dde15a88f12cc540424eb3eb3ed61f3876f74 +Author: Lasse Collin +Date: 2023-01-27 20:02:49 +0200 + + xz: Use clock_gettime() even if CLOCK_MONOTONIC isn't available. + + mythread.h and thus liblzma already does it. + + src/xz/mytime.c | 11 ++++++++--- + src/xz/private.h | 3 +-- + 2 files changed, 9 insertions(+), 5 deletions(-) + +commit 2e02877288f6576cd4595e9ac7684f867cd47d68 +Author: Lasse Collin +Date: 2023-01-27 19:41:19 +0200 + + po4a/po4a.conf: Sort the language identifiers in alphabetical order. + + po4a/po4a.conf | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit ff592c616eda274215b485cf1b8d34f060c9f3be +Author: Lasse Collin +Date: 2023-01-26 18:29:17 +0200 + + xz: Add SIGTSTP handler for progress indicator time keeping. + + This way, if xz is stopped the elapsed time and estimated time + remaining won't get confused by the amount of time spent in + the stopped state. + + This raises SIGSTOP. It's not clear to me if this is the correct way. + POSIX and glibc docs say that SIGTSTP shouldn't stop the process if + it is orphaned but this commit doesn't attempt to handle that. + + Search for SIGTSTP in section 2.4.3: + + https://pubs.opengroup.org/onlinepubs/9699919799/functions/V2_chap02.html + + src/xz/mytime.c | 56 +++++++++++++++++++++++++++++++++++++++++++++++++++++++- + src/xz/mytime.h | 6 ++++++ + src/xz/private.h | 12 ++++++++++++ + src/xz/signals.c | 17 ++++++++++++++++- + 4 files changed, 89 insertions(+), 2 deletions(-) + +commit 3b1c8ac8d1d553cbb1fb22b545d2b1424c752b76 +Author: Jia Tan +Date: 2023-01-27 20:14:51 +0800 + + Translations: Add Brazilian Portuguese translation of man pages. + + Thanks to Rafael Fontenelle. + + po4a/po4a.conf | 2 +- + po4a/pt_BR.po | 3677 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ + 2 files changed, 3678 insertions(+), 1 deletion(-) + +commit a15a7552f9f67c4e402f5d2967324e0ccfd6fccc +Author: Lasse Collin +Date: 2023-01-26 17:51:06 +0200 + + Build: Avoid different quoting style in --enable-doxygen doc. + + configure.ac | 10 +++++----- + 1 file changed, 5 insertions(+), 5 deletions(-) + +commit af5a4bd5afc089d9697756dded38feafaa987ae4 +Author: Lasse Collin +Date: 2023-01-26 17:39:46 +0200 + + tuklib_physmem: Check for __has_warning before GCC version. + + Clang can be configured to fake a too high GCC version so + this way it's more robust. + + src/common/tuklib_physmem.c | 6 +++--- + 1 file changed, 3 insertions(+), 3 deletions(-) + +commit f35d98e20609e0be6a04ae2604bfb7cb9d5bd5e4 +Author: Jia Tan +Date: 2023-01-24 20:48:50 +0800 + + liblzma: Fix documentation in filter.h for lzma_str_to_filters() + + The previous documentation for lzma_str_to_filters() was technically + correct, but misleading. lzma_str_to_filters() returns NULL on success, + which is in practice always defined to 0. This is the same value as + LZMA_OK, but lzma_str_to_filters() does not return lzma_ret so we should + be more clear. + + src/liblzma/api/lzma/filter.h | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit 2f78ecc5939b3d97ddfc2a6bd31b50108a28d0a2 +Author: Lasse Collin +Date: 2023-01-23 23:44:58 +0200 + + Revert "tuklib_common: Define __has_warning if it is not defined." + + This reverts commit 82e3c968bfa10e3ff13333bd9cbbadb5988d6766. + + Macros in the reserved namespace (_foo or __foo) shouldn't be #defined + without a very good reason. Here the alternative would have been + to #define tuklib_has_warning(str) to an approriate value. + + Also the tuklib_* files should stay namespace clean if possible. + + src/common/tuklib_common.h | 7 ------- + 1 file changed, 7 deletions(-) + +commit 8366cf8738e8b7bb74c967d07bf0fd2a1878e575 +Author: Lasse Collin +Date: 2023-01-23 23:38:34 +0200 + + tuklib_physmem: Clean up the way -Wcast-function-type is silenced on Windows. + + __has_warning and other __has_foo macros are meant to become + compiler-agnostic so it's not good to check for __clang__ with it. + + This also relied on tuklib_common.h for #defining __has_warning + which was confusing as #defining reserved macros is generally + not a good idea. + + src/common/tuklib_physmem.c | 17 +++++++++++++---- + 1 file changed, 13 insertions(+), 4 deletions(-) + +commit 683a3c7e2fcd922200c31078e5c9dd1348e90941 +Author: Lasse Collin +Date: 2023-01-24 00:05:38 +0200 + + xz: Flip the return value of suffix_is_set to match the documentation. + + Also edit style to match the existing coding style in the project. + + src/xz/args.c | 6 +++--- + src/xz/suffix.c | 2 +- + src/xz/suffix.h | 1 + + 3 files changed, 5 insertions(+), 4 deletions(-) + +commit cc5aa9ab138beeecaee5a1e81197591893ee9ca0 +Author: Jia Tan +Date: 2023-01-07 21:55:06 +0800 + + xz: Refactor duplicated check for custom suffix when using --format=raw + + src/xz/args.c | 8 ++++++++ + src/xz/suffix.c | 26 ++++++++------------------ + src/xz/suffix.h | 7 +++++++ + 3 files changed, 23 insertions(+), 18 deletions(-) + +commit 9663141274e01592a281a7f2df5d7a31a1dac8bf +Author: Jia Tan +Date: 2023-01-20 21:53:14 +0800 + + liblzma: Set documentation on all reserved fields to private. + + This prevents the reserved fields from being part of the generated + Doxygen documentation. + + src/liblzma/api/lzma/base.h | 17 +++++++++++++++ + src/liblzma/api/lzma/block.h | 43 +++++++++++++++++++++++++++++++++++++ + src/liblzma/api/lzma/container.h | 24 +++++++++++++++++++++ + src/liblzma/api/lzma/delta.h | 12 +++++++++++ + src/liblzma/api/lzma/index.h | 27 +++++++++++++++++++++++ + src/liblzma/api/lzma/lzma12.h | 22 +++++++++++++++++++ + src/liblzma/api/lzma/stream_flags.h | 28 ++++++++++++++++++++++++ + 7 files changed, 173 insertions(+) + +commit 6327a045f34d48fc5afc58ba0d32a82c94403049 +Author: Jia Tan +Date: 2022-12-20 21:39:59 +0800 + + Doxygen: Update Doxyfile.in from 1.4.7 to 1.8.17. + + A few Doxygen tags were obsolete from 1.4.7. Version 1.8.17 released + in 2019, so this should be compatible with resonable modern distros. + The purpose of Doxygen these days is for docs on the website, so it + doesn't necessarily have to work for everyone. Just when the maintainers + want to update the docs. + + Doxyfile.in | 2523 ++++++++++++++++++++++++++++++++++++++++++++--------------- + 1 file changed, 1893 insertions(+), 630 deletions(-) + +commit bbf71b69ebf9d0d62a0af150a5c37d193b8159ad +Author: Jia Tan +Date: 2023-01-03 20:37:30 +0800 + + Doxygen: Make Doxygen only produce liblzma API documentation by default. + + Doxygen is now configurable in autotools only with + --enable-doxygen=[api|all]. The default is "api", which will only + generate HTML output for liblzma API functions. The LaTex documentation + output was also disabled. + + Doxyfile.in | 18 +++++++++--------- + configure.ac | 39 +++++++++++++++++++++++++++++++++++++++ + 2 files changed, 48 insertions(+), 9 deletions(-) + +commit 6fcf4671b6047113c583a0919fc850987a4ec5f4 +Author: Jia Tan +Date: 2022-12-21 23:59:43 +0800 + + liblzma: Highlight liblzma API headers should not be included directly. + + This improves the generated Doxygen HTML files to better highlight + how to properly use the liblzma API header files. + + src/liblzma/api/lzma/base.h | 5 +++-- + src/liblzma/api/lzma/bcj.h | 5 +++-- + src/liblzma/api/lzma/block.h | 5 +++-- + src/liblzma/api/lzma/check.h | 5 +++-- + src/liblzma/api/lzma/container.h | 5 +++-- + src/liblzma/api/lzma/delta.h | 5 +++-- + src/liblzma/api/lzma/filter.h | 5 +++-- + src/liblzma/api/lzma/hardware.h | 5 +++-- + src/liblzma/api/lzma/index.h | 5 +++-- + src/liblzma/api/lzma/index_hash.h | 5 +++-- + src/liblzma/api/lzma/lzma12.h | 5 +++-- + src/liblzma/api/lzma/stream_flags.h | 5 +++-- + src/liblzma/api/lzma/version.h | 5 +++-- + src/liblzma/api/lzma/vli.h | 5 +++-- + 14 files changed, 42 insertions(+), 28 deletions(-) + +commit b43ff180fb2e372adce876bfa155fc9bcf0c3db4 +Author: Jia Tan +Date: 2023-01-19 20:35:09 +0800 + + tuklib_physmem: Silence warning from -Wcast-function-type on MinGW-w64. + + tuklib_physmem depends on GetProcAddress() for both MSVC and MinGW-w64 + to retrieve a function address. The proper way to do this is to cast the + return value to the type of function pointer retrieved. Unfortunately, + this causes a cast-function-type warning, so the best solution is to + simply ignore the warning. + + src/common/tuklib_physmem.c | 9 +++++++++ + 1 file changed, 9 insertions(+) + +commit 82e3c968bfa10e3ff13333bd9cbbadb5988d6766 +Author: Jia Tan +Date: 2023-01-19 20:32:40 +0800 + + tuklib_common: Define __has_warning if it is not defined. + + clang supports the __has_warning macro to determine if the version of + clang compiling the code supports a given warning. If we do not define + it for other compilers, it may cause a preprocessor error. + + src/common/tuklib_common.h | 7 +++++++ + 1 file changed, 7 insertions(+) + +commit b2ba1a489df451cdcd93b2334e319dd06778de19 +Author: Jia Tan +Date: 2023-01-18 22:11:05 +0800 + + CI: Reorder 32-bit build first for Linux autotool builds. + + The 32-bit build needs to be first so the configure cache only needs to + be reset one time. The 32-bit build sets the CFLAGS env variable, so any + build using that flag after will fail unless the cache is reset. + + .github/workflows/ci.yml | 17 ++++++++++++----- + 1 file changed, 12 insertions(+), 5 deletions(-) + +commit dd1c1135741057c91e8d018be9ec4d43968b0e64 +Author: Jia Tan +Date: 2023-01-18 21:51:43 +0800 + + CI: Enable --config-cache in autotool builds. + + If CFLAGS are set in a build, the cache must be cleared with + "make distclean", or by deleting the cache file. + + build-aux/ci_build.sh | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit d3e11477053764c003eec2daa5198c747d70ff69 +Author: Jia Tan +Date: 2023-01-16 21:35:45 +0800 + + xz: Add missing comment for coder_set_compression_settings() + + src/xz/coder.h | 3 ++- + 1 file changed, 2 insertions(+), 1 deletion(-) + +commit 123255b6ed15f4428b2aa92e4962015a5362f6bf +Author: Jia Tan +Date: 2023-01-16 20:55:10 +0800 + + xz: Do not set compression settings with raw format in list mode. + + Calling coder_set_compression_settings() in list mode with verbose mode + on caused the filter chain and memory requirements to print. This was + unnecessary since the command results in an error and not consistent + with other formats like lzma and alone. + + src/xz/args.c | 3 ++- + 1 file changed, 2 insertions(+), 1 deletion(-) + +commit 571919c47b9ff5171ede84378620ed0a9aeb98c0 +Author: Jia Tan +Date: 2023-01-13 20:37:06 +0800 + + Translations: Update the Brazilian Portuguese translation. + + po/pt_BR.po | 603 ++++++++++++++++++++++++++++++++++-------------------------- + 1 file changed, 344 insertions(+), 259 deletions(-) + +commit 81cb02e2c22bbc036cdfaa2d2c4176f6bd60d3cf +Author: Jia Tan +Date: 2023-01-12 23:43:06 +0800 + + CI: Disable shared and nls from various jobs in autotool runners. + + Disabling shared library generation and linking should help speed up the + runners. The shared library is still being tested in the 32 bit build + and the full feature. + + Disabling nls is to check for any unexpected warnings or errors. + + .github/workflows/ci.yml | 56 ++++++++++++++++++++++++------------------------ + 1 file changed, 28 insertions(+), 28 deletions(-) + +commit 58a052198a7bcaf6e958f87fad72e69e19a2579b +Author: Jia Tan +Date: 2023-01-12 23:39:19 +0800 + + CI: Reorder the 32-bit job in the Ubuntu runner. + + Run the 32 bit job sooner since this is a more interesting test than + some of the later jobs. + + .github/workflows/ci.yml | 10 +++++----- + 1 file changed, 5 insertions(+), 5 deletions(-) + +commit 4110a998b83459fe2bc9bc1bec30ad68afa8f797 +Author: Jia Tan +Date: 2023-01-12 23:09:03 +0800 + + CI: Allow disabling Native Language Support. + + build-aux/ci_build.sh | 9 ++++++++- + 1 file changed, 8 insertions(+), 1 deletion(-) + +commit 0dec634e705b5bf89a37c5d62d71e8511d480058 +Author: Jia Tan +Date: 2023-01-12 23:02:20 +0800 + + CI: Only run autogen.sh if it has not already run. + + build-aux/ci_build.sh | 11 ++++++++--- + 1 file changed, 8 insertions(+), 3 deletions(-) + +commit 32287dc8def94df4546e903495d14c132bd54cc4 +Author: Jia Tan +Date: 2023-01-12 22:58:36 +0800 + + CI: Allow disabling shared library in autotools builds. + + build-aux/ci_build.sh | 9 ++++++++- + 1 file changed, 8 insertions(+), 1 deletion(-) + +commit 77d1ebcc99ddd82a300d1838f608150221931dcd +Author: Jia Tan +Date: 2023-01-12 22:44:18 +0800 + + CI: Improve Usage readability and add -h option. + + build-aux/ci_build.sh | 15 +++++++++++++-- + 1 file changed, 13 insertions(+), 2 deletions(-) + +commit a8bb8358d10b059274f3cf993d9b8f490bafb268 +Author: Lasse Collin +Date: 2023-01-12 13:04:05 +0200 + + Build: Omit -Wmissing-noreturn from the default warnings. + + It's not that important. It can be annoying in builds that + disable many features since in those cases the tests programs + will correctly trigger this warning with Clang. + + configure.ac | 1 - + 1 file changed, 1 deletion(-) + +commit 52dc033d0bde0d19e3912303c6c74bae559d6498 +Author: Lasse Collin +Date: 2023-01-12 06:05:58 +0200 + + xz: Use ssize_t for the to-be-ignored return value from write(fd, ptr, 1). + + It makes no difference here as the return value fits into an int + too and it then gets ignored but this looks better. + + src/xz/file_io.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit b1a6d180a363d57b2b1c89526ff3f0782bf863d3 +Author: Lasse Collin +Date: 2023-01-12 06:01:12 +0200 + + xz: Silence warnings from -Wsign-conversion in a 32-bit build. + + src/common/tuklib_mbstr_fw.c | 2 +- + src/xz/list.c | 4 ++-- + 2 files changed, 3 insertions(+), 3 deletions(-) + +commit 31c21c734b7c7d7428a3da7402a2cb7bc2587339 +Author: Lasse Collin +Date: 2023-01-12 05:38:48 +0200 + + liblzma: Silence another warning from -Wsign-conversion in a 32-bit build. + + It doesn't warn on a 64-bit system because truncating + a ptrdiff_t (signed long) to uint32_t is diagnosed under + -Wconversion by GCC and -Wshorten-64-to-32 by Clang. + + src/liblzma/lz/lz_encoder_mf.c | 7 ++++--- + 1 file changed, 4 insertions(+), 3 deletions(-) + +commit 37fbdfb7263522c11c7ad2685413d6295532581d +Author: Lasse Collin +Date: 2023-01-12 04:46:45 +0200 + + liblzma: Silence a warning from -Wsign-conversion in a 32-bit build. + + src/common/mythread.h | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +commit 5ce6ddc221d0bfb57d810d845bb65fb0aac0b008 +Author: Lasse Collin +Date: 2023-01-12 04:17:24 +0200 + + Build: Make configure add more warning flags for GCC and Clang. + + -Wstrict-aliasing was removed from the list since it is enabled + by -Wall already. + + A normal build is clean with these on GNU/Linux x86-64 with + GCC 12.2.0 and Clang 14.0.6. + + configure.ac | 36 +++++++++++++++++++++++++++++++----- + 1 file changed, 31 insertions(+), 5 deletions(-) + +commit bfc3a0a8ac16de90049c1b1ba1445a7626d0230c +Author: Lasse Collin +Date: 2023-01-12 04:14:18 +0200 + + Tests: Fix warnings from clang --Wassign-enum. + + Explicitly casting the integer to lzma_check silences the warning. + Since such an invalid value is needed in multiple tests, a constant + INVALID_LZMA_CHECK_ID was added to tests.h. + + The use of 0x1000 for lzma_block.check wasn't optimal as if + the underlying type is a char then 0x1000 will be truncated to 0. + However, in these test cases the value is ignored, thus even with + such truncation the test would have passed. + + tests/test_block_header.c | 6 +++--- + tests/test_check.c | 2 +- + tests/test_stream_flags.c | 8 ++++---- + tests/tests.h | 9 +++++++++ + 4 files changed, 17 insertions(+), 8 deletions(-) + +commit 49245bb31e215ad455a1ab85e4ed6783152dc522 +Author: Lasse Collin +Date: 2023-01-12 03:51:07 +0200 + + Tests: Silence warnings from -Wsign-conversion. + + Note that assigning an unsigned int to lzma_check doesn't warn + on GNU/Linux x86-64 since the enum type is unsigned on that + platform. The enum can be signed on some other platform though + so it's best to use enumeration type lzma_check in these situations. + + tests/test_check.c | 6 +++--- + tests/test_stream_flags.c | 10 +++++----- + 2 files changed, 8 insertions(+), 8 deletions(-) + +commit 3f13bf6b9e8624cbe6d6e3e82d6c98a3ed1ad571 +Author: Lasse Collin +Date: 2023-01-12 03:19:59 +0200 + + liblzma: Silence warnings from clang -Wconditional-uninitialized. + + This is similar to 2ce4f36f179a81d0c6e182a409f363df759d1ad0. + The actual initialization of the variables is done inside + mythread_sync() macro. Clang doesn't seem to see that + the initialization code inside the macro is always executed. + + src/liblzma/common/stream_decoder_mt.c | 8 +++++--- + src/liblzma/common/stream_encoder_mt.c | 2 +- + 2 files changed, 6 insertions(+), 4 deletions(-) + +commit 6c886cc5b3c90c6a75e6be8b1278ec2261e452a6 +Author: Lasse Collin +Date: 2023-01-12 03:11:40 +0200 + + Fix warnings from clang -Wdocumentation. + + src/liblzma/check/check.h | 4 ---- + src/liblzma/lz/lz_encoder_mf.c | 4 ++-- + src/xz/options.c | 4 ++-- + 3 files changed, 4 insertions(+), 8 deletions(-) + +commit a0e7fb1c1ea658b67f30517f5d1975efd0226dba +Author: Lasse Collin +Date: 2023-01-12 03:04:28 +0200 + + Tests: test_lzip_decoder: Remove trailing white-space. + + tests/test_lzip_decoder.c | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +commit c0f8d6782f29e219fd496dd23f6a033270509d5c +Author: Lasse Collin +Date: 2023-01-12 03:03:55 +0200 + + Tests: test_lzip_decoder: Silence warnings from -Wsign-conversion. + + tests/test_lzip_decoder.c | 13 +++++++------ + 1 file changed, 7 insertions(+), 6 deletions(-) + +commit 62efd48a825e8f439e84c85e165d8774ddc68fd2 +Author: Jia Tan +Date: 2023-01-11 23:58:16 +0800 + + Add NEWS for 5.4.1. + + NEWS | 70 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ + 1 file changed, 70 insertions(+) + +commit d1561c47ec8cd3844a785d3741dc932f9b9c5790 +Author: Jia Tan +Date: 2023-01-11 22:46:48 +0800 + + xz: Fix warning -Wformat-nonliteral on clang in message.c. + + clang and gcc differ in how they handle -Wformat-nonliteral. gcc will + allow a non-literal format string as long as the function takes its + format arguments as a va_list. + + src/xz/message.c | 9 +++++++++ + 1 file changed, 9 insertions(+) + +commit 8c0f115cc489331c48df77beca92fe378039d919 +Author: Jia Tan +Date: 2023-01-11 20:58:31 +0800 + + Tests: Fix test_filter_flags copy/paste error. + + tests/test_filter_flags.c | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +commit 25035813d1d596fde692addc33e7f715f1fe55eb +Author: Jia Tan +Date: 2023-01-11 20:42:29 +0800 + + Tests: Fix type-limits warning in test_filter_flags. + + This only occurs in test_filter_flags when the BCJ filters are not + configured and built. In this case, ARRAY_SIZE() returns 0 and causes a + type-limits warning with the loop variable since an unsigned number will + always be >= 0. + + tests/test_filter_flags.c | 13 ++++++++++--- + 1 file changed, 10 insertions(+), 3 deletions(-) + +commit 0b8fa310cf56fec55663f62340e49e8e1441594f +Author: Lasse Collin +Date: 2023-01-10 22:14:03 +0200 + + liblzma: CLMUL CRC64: Work around a bug in MSVC, second attempt. + + This affects only 32-bit x86 builds. x86-64 is OK as is. + + I still cannot easily test this myself. The reporter has tested + this and it passes the tests included in the CMake build and + performance is good: raw CRC64 is 2-3 times faster than the + C version of the slice-by-four method. (Note that liblzma doesn't + include a MSVC-compatible version of the 32-bit x86 assembly code + for the slice-by-four method.) + + Thanks to Iouri Kharon for figuring out a fix, testing, and + benchmarking. + + src/liblzma/check/crc64_fast.c | 18 ++++++++++++++++++ + 1 file changed, 18 insertions(+) + +commit 765354b50c2886fc0d294d6be3b207f7ae2ada70 +Author: Jia Tan +Date: 2023-01-11 01:18:50 +0800 + + Tests: Fix unused function warning in test_block_header. + + One of the global arrays of filters was only used in a test that + required both encoders and decoders to be configured in the build. + + tests/test_block_header.c | 4 ++++ + 1 file changed, 4 insertions(+) + +commit 7c23c05befdcc73231c0d6632a7d943dbeaea1aa +Author: Jia Tan +Date: 2023-01-11 01:08:03 +0800 + + Tests: Fix unused function warning in test_index_hash. + + test_index_hash does not use fill_index_hash() unless both encoders + and decoders are configured in the build. + + tests/test_index_hash.c | 4 +--- + 1 file changed, 1 insertion(+), 3 deletions(-) + +commit 57464bb4ebd6c00dc8b19803f05ea55ddd0826f6 +Author: Jia Tan +Date: 2023-01-11 00:54:45 +0800 + + CI/CD: Add 32-bit build and test steps to Ubuntu autotools runner. + + If all goes well, Mac autotools and Linux and Mac CMake will be added + later for 32-bit builds. + + .github/workflows/ci.yml | 7 ++++++- + 1 file changed, 6 insertions(+), 1 deletion(-) + +commit 923eb689a4b863b6cca8df6360d4962aae994edf +Author: Jia Tan +Date: 2023-01-11 00:51:01 +0800 + + CI/CD: Enables warnings as errors in autotool build. + + This will help us catch warnings and potential bugs in builds that are + not often tested by us. + + build-aux/ci_build.sh | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit feae5528a30c006b6e2f96a95116e20b983703fc +Author: Jia Tan +Date: 2023-01-11 00:48:35 +0800 + + CI/CD: Add -f argument to set CFLAGS in ci_build.sh. + + For now, the suggested option is for -m32 only, but this can be updated + later if other flags are deemed useful. + + build-aux/ci_build.sh | 8 ++++++-- + 1 file changed, 6 insertions(+), 2 deletions(-) + +commit cfabb62a4874c146e7d6f30445637602545bc054 +Author: Lasse Collin +Date: 2023-01-10 12:47:16 +0200 + + Revert "liblzma: CLMUL CRC64: Workaround a bug in MSVC (VS2015-2022)." + + This reverts commit 36edc65ab4cf10a131f239acbd423b4510ba52d5. + + It was reported that it wasn't a good enough fix and MSVC + still produced (different kind of) bad code when building + for 32-bit x86 if optimizations are enabled. + + Thanks to Iouri Kharon. + + src/liblzma/check/crc64_fast.c | 6 ------ + 1 file changed, 6 deletions(-) + +commit 0b64215170dd3562f207ef26f794755bcd600526 +Author: Lasse Collin +Date: 2023-01-10 11:56:11 +0200 + + sysdefs.h: Don't include strings.h anymore. + + On some platforms src/xz/suffix.c may need for + strcasecmp() but suffix.c includes the header when it needs it. + + Unless there is an old system that otherwise supports enough C99 + to build XZ Utils but doesn't have C89/C90-compatible , + there should be no need to include in sysdefs.h. + + src/common/sysdefs.h | 6 ------ + 1 file changed, 6 deletions(-) + +commit ec2fc39fe4f4e6e242b3a669585049763968cdeb +Author: Lasse Collin +Date: 2023-01-10 11:23:41 +0200 + + xz: Include in suffix.c if needed for strcasecmp(). + + SUSv2 and POSIX.1‐2017 declare only a few functions in . + Of these, strcasecmp() is used on some platforms in suffix.c. + Nothing else in the project needs (at least if + building on a modern system). + + sysdefs.h currently includes if HAVE_STRINGS_H is + defined and suffix.c relied on this. + + Note that dos/config.h doesn't #define HAVE_STRINGS_H even though + DJGPP does have strings.h. It isn't needed with DJGPP as strcasecmp() + is also in in DJGPP. + + src/xz/suffix.c | 3 +++ + 1 file changed, 3 insertions(+) + +commit 7049c4a76c805ad27d6cf4ee119a2ef2a7add59f +Author: Lasse Collin +Date: 2023-01-10 10:05:13 +0200 + + sysdefs.h: Fix a comment. + + src/common/sysdefs.h | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit 194a5fab69277d9e804a6113b5f676b8666b3a61 +Author: Lasse Collin +Date: 2023-01-10 10:04:06 +0200 + + sysdefs.h: Don't include memory.h anymore even if it were available. + + It quite probably was never needed, that is, any system where memory.h + was required likely couldn't compile XZ Utils for other reasons anyway. + + XZ Utils 5.2.6 and later source packages were generated using + Autoconf 2.71 which no longer defines HAVE_MEMORY_H. So the code + being removed is no longer used anyway. + + src/common/sysdefs.h | 8 ++------ + 1 file changed, 2 insertions(+), 6 deletions(-) + +commit 5e34774c31d1b7509b5cb77a3be9973adec59ea0 +Author: Lasse Collin +Date: 2023-01-10 08:29:32 +0200 + + CMake: Fix appending to CMAKE_RC_FLAGS. + + It's a string, not a list. It only worked when the variable was empty. + + Thanks to Iouri Kharon. + + CMakeLists.txt | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit 6e652ceb18c615c578c869db300fa0756788b4e0 +Author: Lasse Collin +Date: 2023-01-10 00:33:14 +0200 + + Windows: Update INSTALL-MSVC.txt to recommend CMake over project files. + + windows/INSTALL-MSVC.txt | 19 ++++++++++++------- + 1 file changed, 12 insertions(+), 7 deletions(-) + +commit 6b117d3b1fe91eb26d533ab16a2e552f84148d47 +Author: Lasse Collin +Date: 2023-01-09 23:41:25 +0200 + + CMake: Fix windres issues again. + + At least on some systems, GNU windres needs --use-temp-file + in addition to the \x20 hack to avoid spaces in the command line + argument. Hovever, that \x20 syntax is broken with llvm-windres + version 15.0.0 (results in "XZx20Utils") but luckily it works + with a regular space. Thus it is best to limit the workarounds + to GNU toolchain on Windows. + + CMakeLists.txt | 35 +++++++++++++++++++++++------------ + 1 file changed, 23 insertions(+), 12 deletions(-) + +commit 0c210ca7f489e971e94e1ddc72b0b0806e3c7935 +Author: Lasse Collin +Date: 2023-01-06 22:53:38 +0200 + + Tests: test_filter_flags: Clean up minor issues. + + Here are the list of the most significant issues addressed: + - Avoid using internal common.h header. It's not good to copy the + constants like this but common.h cannot be included for use outside + of liblzma. This is the quickest thing to do that could be fixed later. + + - Omit the INIT_FILTER macro. Initialization should be done with just + regular designated initializers. + + - Use start_offset = 257 for BCJ tests. It demonstrates that Filter + Flags encoder and decoder don't validate the options thoroughly. + 257 is valid only for the x86 filter. This is a bit silly but + not a significant problem in practice because the encoder and + decoder initialization functions will catch bad alignment still. + Perhaps this should be fixed but it's not urgent and doesn't need + to be in 5.4.x. + + - Various tweaks to comments such as filter id -> Filter ID + + tests/test_filter_flags.c | 153 +++++++++++++++++++++++----------------------- + 1 file changed, 78 insertions(+), 75 deletions(-) + +commit 5c9fdd3bf53a9655f5eb2807d662b3af0d5e1865 +Author: Jia Tan +Date: 2022-12-29 23:33:33 +0800 + + Tests: Refactors existing filter flags tests. + + Converts the existing filter flags tests into tuktests. + + tests/test_filter_flags.c | 655 ++++++++++++++++++++++++++++++++-------------- + 1 file changed, 457 insertions(+), 198 deletions(-) + +commit 36edc65ab4cf10a131f239acbd423b4510ba52d5 +Author: Lasse Collin +Date: 2023-01-09 12:22:05 +0200 + + liblzma: CLMUL CRC64: Workaround a bug in MSVC (VS2015-2022). + + I haven't tested with MSVC myself and there doesn't seem to be + information about the problem online, so I'm relying on the bug report. + + Thanks to Iouri Kharon for the bug report and the patch. + + src/liblzma/check/crc64_fast.c | 6 ++++++ + 1 file changed, 6 insertions(+) + +commit 790a12a95a78ff82d8c6d4efe3b789851ca9470d +Author: Lasse Collin +Date: 2023-01-09 11:27:24 +0200 + + CMake: Fix a copypaste error in xzdec Windows resource file handling. + + It was my mistake. Thanks to Iouri Kharon for the bug report. + + CMakeLists.txt | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +commit 0e1545fea39c0514c7b7032a0a3592a9a33d2848 +Author: Lasse Collin +Date: 2023-01-08 00:32:29 +0200 + + Tests: tuktest.h: Support tuktest_malloc(0). + + It's not needed in XZ Utils at least for now. It's good to support + it still because if such use is needed later, it wouldn't be + caught on GNU/Linux since malloc(0) from glibc returns non-NULL. + + tests/tuktest.h | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +commit 69d5d78c6904668eb09a131da86276beec3281f8 +Author: Lasse Collin +Date: 2023-01-08 00:24:23 +0200 + + Update THANKS. + + THANKS | 1 + + 1 file changed, 1 insertion(+) + +commit dd38655f80c113c9db73b9ed370dc900e1c4dc41 +Author: Lasse Collin +Date: 2023-01-07 21:57:11 +0200 + + CMake: Update cmake_minimum_required from 3.13...3.16 to 3.13...3.25. + + The changes listed on cmake-policies(7) for versions 3.17 to 3.25 + shouldn't affect this project. + + CMakeLists.txt | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit a890a637bee9193d5b690aefa9a59eba5b8532ae +Author: Lasse Collin +Date: 2023-01-07 19:50:35 +0200 + + Update THANKS. + + THANKS | 1 + + 1 file changed, 1 insertion(+) + +commit 6e38e595dd56ac1800478cef1f6f754d0eba0d2e +Author: Lasse Collin +Date: 2023-01-07 19:50:03 +0200 + + CMake/Windows: Add resource files to xz.exe and xzdec.exe. + + The command line tools cannot be built with MSVC for now but + they can be built with MinGW-w64. + + Thanks to Iouri Kharon for the bug report and the original patch. + + CMakeLists.txt | 16 ++++++++++++++++ + 1 file changed, 16 insertions(+) + +commit 443dfebced041adc88f10d824188eeef5b5821a9 +Author: Lasse Collin +Date: 2023-01-07 19:48:52 +0200 + + CMake/Windows: Add a workaround for windres from GNU binutils. + + Thanks to Iouri Kharon for the bug report and the original patch. + + CMakeLists.txt | 21 ++++++++++++++++++++- + 1 file changed, 20 insertions(+), 1 deletion(-) + +commit ceb805011747d04a915f3f39e4bed9eed151c634 +Author: Lasse Collin +Date: 2023-01-07 19:31:15 +0200 + + Build: Require that _mm_set_epi64x() is usable to enable CLMUL support. + + VS2013 doesn't have _mm_set_epi64x() so this way CLMUL gets + disabled with VS2013. + + Thanks to Iouri Kharon for the bug report. + + CMakeLists.txt | 3 ++- + configure.ac | 8 ++++++-- + 2 files changed, 8 insertions(+), 3 deletions(-) + +commit 8d372bd94066b1a5b0570b2550f83c2868486adf +Author: Jia Tan +Date: 2023-01-07 21:05:15 +0800 + + CI/CD: Split CMake Linux and MacOS build phase to build and test. + + The phase split was only done for Autotools before, so should also + apply to CMake. + + .github/workflows/ci.yml | 8 ++++++-- + 1 file changed, 6 insertions(+), 2 deletions(-) + +commit 747c7f2b34bd498f6702c6875500a26b06201772 +Author: Jia Tan +Date: 2023-01-07 11:16:55 +0800 + + CI/CD: Reduce job runners to 4 instead of using matrix strategy. + + The old version used too many runners that resulted in unnecessary + dependency downloads. Now, the runners are reused for the different + configurations for each OS and build system. + + .github/workflows/ci.yml | 95 ++++++++++++++++++++++++++++++++++++++++++------ + 1 file changed, 83 insertions(+), 12 deletions(-) + +commit 4de35fd6b58d46fc887c78faf163f6a37b790c45 +Author: Jia Tan +Date: 2023-01-07 10:07:20 +0800 + + CI/CD: Add new -p (PHASE) argument to ci_build.sh + + The new PHASE argument can be build, test, or all. all is the default. + This way, the CI/CD script can differentiate between the build and test + phases to make it easier to track down errors when they happen. + + build-aux/ci_build.sh | 140 +++++++++++++++++++++++++++----------------------- + 1 file changed, 76 insertions(+), 64 deletions(-) + +commit 6fd39664de47801e670a16617863196bfbde4755 +Merge: 78e0561d fc0c7884 +Author: Jia Tan +Date: 2023-01-07 00:10:50 +0800 + + Merge pull request #7 from tukaani-project/tuktest_index_hash + + Tuktest index hash + +commit fc0c788469159f634f09ff23c8cef6925c91da57 +Author: Lasse Collin +Date: 2023-01-06 17:58:48 +0200 + + Tests: test_index_hash: Add an assert_uint_eq(). + + tests/test_index_hash.c | 3 +++ + 1 file changed, 3 insertions(+) + +commit d550304f5343b3a082da265107cd820e0d81dc71 +Author: Lasse Collin +Date: 2023-01-06 17:55:06 +0200 + + Tests: test_index_hash: Fix a memory leak. + + tests/test_index_hash.c | 2 ++ + 1 file changed, 2 insertions(+) + +commit 02608f74ea1f2d2d56585711ff241c34b4ad0937 +Author: Lasse Collin +Date: 2023-01-06 17:53:03 +0200 + + Tests: test_index_hash: Don't treat pointers as booleans. + + tests/test_index_hash.c | 6 +++--- + 1 file changed, 3 insertions(+), 3 deletions(-) + +commit 056766c8601a3808bea1761f6cc833197a35a3e0 +Author: Lasse Collin +Date: 2023-01-06 17:51:41 +0200 + + Tests: test_index_hash: Fix a typo in a comment. + + tests/test_index_hash.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit 873e684028ba9738f071c5236db7d452ed797b4c +Author: Lasse Collin +Date: 2023-01-06 17:44:29 +0200 + + Tests: test_index_hash: Avoid the variable name "index". + + It can trigger warnings from -Wshadow on some systems. + + tests/test_index_hash.c | 16 ++++++++-------- + 1 file changed, 8 insertions(+), 8 deletions(-) + +commit d1f24c35874eeba8432d75aa77b06c50375ed937 +Author: Lasse Collin +Date: 2023-01-06 17:35:50 +0200 + + Tests: test_index_hash: Use the word "Record" instead of "entry". + + tests/test_index_hash.c | 102 ++++++++++++++++++++++++------------------------ + 1 file changed, 51 insertions(+), 51 deletions(-) + +commit b93f7c5cbb02b42024ac866fc0af541de3d816e2 +Author: Lasse Collin +Date: 2023-01-06 17:35:05 +0200 + + Tests: test_index_hash: Tweak comments and style. + + The words defined in the .xz file format specification + begin with capital letter to emphasize that they have + a specific meaning. + + tests/test_index_hash.c | 62 ++++++++++++++++++++++++++----------------------- + 1 file changed, 33 insertions(+), 29 deletions(-) + +commit c48b24fc06d98569adb72f13c2e8e5ff30bb8036 +Author: Lasse Collin +Date: 2023-01-06 17:17:37 +0200 + + Tests: test_index_hash: Use INDEX_INDICATOR constant instead of 0. + + tests/test_index_hash.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit 78e0561dfebaa9d5e34558de537efcda890e0629 +Author: Jia Tan +Date: 2023-01-06 20:43:31 +0800 + + Style: Change #if !defined() to #ifndef in mythread.h. + + src/common/mythread.h | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit e834e1e934ed0af673598d8c0c34afb2af56bee0 +Author: Jia Tan +Date: 2023-01-06 20:35:55 +0800 + + Build: Add missing stream_decoder_mt.c to .vcxproj files. + + The line in the .vcxproj files for building with was missing in 5.4.0. + Thank to Hajin Jang for reporting the issue. + + windows/vs2013/liblzma.vcxproj | 1 + + windows/vs2013/liblzma_dll.vcxproj | 1 + + windows/vs2017/liblzma.vcxproj | 1 + + windows/vs2017/liblzma_dll.vcxproj | 1 + + windows/vs2019/liblzma.vcxproj | 1 + + windows/vs2019/liblzma_dll.vcxproj | 1 + + 6 files changed, 6 insertions(+) + +commit 84f9687cbae972c2c342e10bf69f8ec8f70ae111 +Author: Jia Tan +Date: 2023-01-05 20:57:25 +0800 + + liblzma: Remove common.h include from common/index.h. + + common/index.h is needed by liblzma internally and tests. common.h will + include and define many things that are not needed by the tests. Also, + this prevents include order problems because common.h will redefine + LZMA_API resulting in a warning. + + src/liblzma/common/index.c | 1 + + src/liblzma/common/index.h | 9 +++++++-- + src/liblzma/common/index_decoder.h | 1 + + src/liblzma/common/stream_buffer_encoder.c | 1 + + 4 files changed, 10 insertions(+), 2 deletions(-) + +commit 7657ce1c3c4abff7560336a7b687d98e0e2bd14f +Author: Lasse Collin +Date: 2023-01-04 22:40:54 +0200 + + Update THANKS. + + THANKS | 1 + + 1 file changed, 1 insertion(+) + +commit aafd67fba045ab99683971263a5a26fb2a6e8ce2 +Author: Lasse Collin +Date: 2023-01-04 18:40:28 +0200 + + Tests: Adjust style in test_compress.sh. + + tests/test_compress.sh | 12 +++++++----- + 1 file changed, 7 insertions(+), 5 deletions(-) + +commit 52380678f42364daa4510f92f6d3b18ec98c3638 +Author: Jia Tan +Date: 2023-01-04 23:58:58 +0800 + + Tests: Replace non portable shell parameter expansion + + The shell parameter expansion using # and ## is not supported in + Solaris 10 Bourne shell (/bin/sh). Even though this is POSIX, it is not fully + portable, so we should avoid it. + + tests/create_compress_files.c | 2 +- + tests/test_compress.sh | 20 +++++++++++++------- + tests/test_compress_prepared_bcj_sparc | 2 +- + tests/test_compress_prepared_bcj_x86 | 2 +- + 4 files changed, 16 insertions(+), 10 deletions(-) + +commit d0eb345bb7d148a62883ee299adec2b74a0f6f3b +Author: Jia Tan +Date: 2023-01-03 21:02:38 +0800 + + Translations: Add Korean translation of man pages. + + Thanks to Seong-ho Cho + + po4a/ko.po | 5552 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ + po4a/po4a.conf | 2 +- + 2 files changed, 5553 insertions(+), 1 deletion(-) + +commit c4145978d95ebf1690c778d354e15f7c2823d7a8 +Author: Jia Tan +Date: 2023-01-03 20:47:27 +0800 + + Translations: Update the Esperanto translation. + + po/eo.po | 620 ++++++++++++++++++++++++++++++++++----------------------------- + 1 file changed, 332 insertions(+), 288 deletions(-) + +commit 4103a2e78ac60b00c888485cd967a5fe5d1b917c +Author: Lasse Collin +Date: 2023-01-02 17:20:47 +0200 + + Bump version and soname for 5.5.0alpha. + + 5.5.0alpha won't be released, it's just to mark that + the branch is not for stable 5.4.x. + + Once again there is no API/ABI stability for new features + in devel versions. The major soname won't be bumped even + if API/ABI of new features breaks between devel releases. src/liblzma/Makefile.am | 2 +- - src/liblzma/api/lzma/version.h | 8 ++++---- - 2 files changed, 5 insertions(+), 5 deletions(-) + src/liblzma/api/lzma/version.h | 4 ++-- + 2 files changed, 3 insertions(+), 3 deletions(-) + +commit 73c9e6d6b970ccc3d5ad61dcaa21cba050e5df0a +Author: Lasse Collin +Date: 2023-01-02 17:05:07 +0200 + + Build: Fix config.h comments. + + configure.ac | 2 +- + m4/tuklib_progname.m4 | 2 +- + 2 files changed, 2 insertions(+), 2 deletions(-) + +commit bb740e3b117f1a3c65152d01e5755523a908ecb1 +Author: Jia Tan +Date: 2023-01-02 22:33:48 +0800 + + Build: Only define HAVE_PROGRAM_INVOCATION_NAME if it is set to 1. + + HAVE_DECL_PROGRAM_INVOCATION_NAME is renamed to + HAVE_PROGRAM_INVOCATION_NAME. Previously, + HAVE_DECL_PROGRAM_INVOCATION_NAME was always set when + building with autotools. CMake would only set this when it was 1, and the + dos/config.h did not define it. The new macro definition is consistent + across build systems. + + cmake/tuklib_progname.cmake | 5 ++--- + m4/tuklib_progname.m4 | 5 ++++- + src/common/tuklib_progname.c | 2 +- + src/common/tuklib_progname.h | 2 +- + 4 files changed, 8 insertions(+), 6 deletions(-) + +commit 064cd385a716abc78d93a3612411a82d69ceb221 +Author: Jia Tan +Date: 2022-12-29 00:30:52 +0800 + + Adds test_index_hash to .gitignore. + + .gitignore | 1 + + 1 file changed, 1 insertion(+) + +commit 3959162baec074511d83ba0fec1284c3ed724799 +Author: Jia Tan +Date: 2022-12-29 00:25:18 +0800 + + Tests: Creates test_index_hash.c + + Tests all API functions exported from index_hash.h. Does not have a + dedicated test for lzma_index_hash_end. + + CMakeLists.txt | 2 + + tests/Makefile.am | 3 + + tests/test_index_hash.c | 379 ++++++++++++++++++++++++++++++++++++++++++++++++ + 3 files changed, 384 insertions(+) + +commit f16e12d5e755d371247202fcccbcccd1ec16b2cf +Author: Jia Tan +Date: 2022-08-17 20:20:16 +0800 + + liblzma: Add NULL check to lzma_index_hash_append. + + This is for consistency with lzma_index_append. + + src/liblzma/common/index_hash.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit 203b008eb220208981902e0db541c02d1c1c9f5e +Author: Jia Tan +Date: 2022-08-17 17:59:51 +0800 + + liblzma: Replaced hardcoded 0x0 index indicator byte with macro + + src/liblzma/common/index.h | 3 +++ + src/liblzma/common/index_decoder.c | 2 +- + src/liblzma/common/index_encoder.c | 2 +- + src/liblzma/common/index_hash.c | 2 +- + src/liblzma/common/stream_decoder.c | 3 ++- + src/liblzma/common/stream_decoder_mt.c | 2 +- + 6 files changed, 9 insertions(+), 5 deletions(-) + +commit dfecda875211f737d0db92dc1d3c58a3a2afb0c0 +Author: Lasse Collin +Date: 2022-12-30 20:10:08 +0200 + + Tests: test_check: Test corner cases of CLMUL CRC64. + + tests/test_check.c | 27 +++++++++++++++++++++++++++ + 1 file changed, 27 insertions(+) + +commit ce96bb20435212fe797d6d84738fb9fd4ea13cc7 +Author: Lasse Collin +Date: 2022-12-30 19:36:49 +0200 + + Tests: Clarify a comment in test_lzip_decoder.c. + + tests/test_lzip_decoder.c | 8 ++++++-- + 1 file changed, 6 insertions(+), 2 deletions(-) + +commit 2fcba17fc4d7eda8fc60567169cf2a0e6fcfb2f8 +Author: Jia Tan +Date: 2022-12-29 01:55:19 +0800 + + xz: Includes and conditionally in mytime.c. + + Previously, mytime.c depended on mythread.h for to be included. + + src/xz/mytime.c | 4 +++- + 1 file changed, 3 insertions(+), 1 deletion(-) + +commit f82294c8318a7a0990583d51ac5c7de682ad36ef +Author: Jia Tan +Date: 2022-12-29 01:15:27 +0800 + + liblzma: Includes sys/time.h conditionally in mythread + + Previously, was always included, even if mythread only used + clock_gettime. is still needed even if clock_gettime is not used + though because struct timespec is needed for mythread_condtime. + + src/common/mythread.h | 8 +++++++- + 1 file changed, 7 insertions(+), 1 deletion(-) + +commit 74dae7d30091e906d6a92a57952dea4354473f9b +Author: Jia Tan +Date: 2022-12-29 01:10:53 +0800 + + Build: No longer require HAVE_DECL_CLOCK_MONOTONIC to always be set. + + Previously, if threading was enabled HAVE_DECL_CLOCK_MONOTONIC would always + be set to 0 or 1. However, this macro was needed in xz so if xz was not + built with threading and HAVE_DECL_CLOCK_MONOTONIC was not defined but + HAVE_CLOCK_GETTIME was, it caused a warning during build. Now, + HAVE_DECL_CLOCK_MONOTONIC has been renamed to HAVE_CLOCK_MONOTONIC and + will only be set if it is 1. + + CMakeLists.txt | 8 +++----- + configure.ac | 5 ++++- + src/common/mythread.h | 4 ++-- + src/xz/mytime.c | 5 ++--- + 4 files changed, 11 insertions(+), 11 deletions(-) + +commit 7339e39dc060df6eda74a2c5b69961befc3d5d24 +Author: Jia Tan +Date: 2022-12-28 01:14:07 +0800 + + Translations: Add Ukrainian translations of man pages. + + Thanks to Yuri Chornoivan + + po4a/po4a.conf | 2 +- + po4a/uk.po | 3676 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ + 2 files changed, 3677 insertions(+), 1 deletion(-) + +commit 9f05c27a58ce8cd7803079aa295e41c24665ce6e +Author: Jia Tan +Date: 2022-12-23 00:34:48 +0800 + + CI/CD: Create initial version of CI/CD workflow. + + The CI/CD workflow will only execute on Ubuntu and MacOS latest version. + The workflow will attempt to build with autotools and CMake and execute + the tests. The workflow will run for all pull requests and pushes done + to the master branch. + + .github/workflows/ci.yml | 72 ++++++++++++++++++++++++ + build-aux/ci_build.sh | 141 +++++++++++++++++++++++++++++++++++++++++++++++ + 2 files changed, 213 insertions(+) + +commit 1275ebfba74230dbd028049141423c79c8b83b8f +Author: Jia Tan +Date: 2022-12-22 23:14:53 +0800 + + liblzma: Update documentation for lzma_filter_encoder. + + src/liblzma/common/filter_encoder.c | 7 +++++-- + 1 file changed, 5 insertions(+), 2 deletions(-) + +commit 7c9ff5f1667a16733163b75dfd4b509662c387f4 +Author: Jia Tan +Date: 2022-12-21 21:12:03 +0800 + + Tests: Adds lzip decoder tests + + .gitignore | 1 + + tests/Makefile.am | 2 + + tests/test_lzip_decoder.c | 471 ++++++++++++++++++++++++++++++++++++++++++++++ + 3 files changed, 474 insertions(+) + +commit 799ead162de63b8400733603d3abcd2e1977bdca +Author: Jia Cheong Tan +Date: 2022-12-20 22:05:21 +0800 + + Doxygen: Update .gitignore for generating docs for in source build. + + In source builds are not recommended, but we should still ignore + the generated artifacts. + + .gitignore | 2 ++ + 1 file changed, 2 insertions(+) + +commit 5f7ce42a16b1e86ca8408b5c670c25e2a12acc4e +Author: Jia Tan +Date: 2022-12-20 20:46:44 +0800 + + liblzma: Fix lzma_microlzma_encoder() return value. + + Using return_if_error on lzma_lzma_lclppb_encode was improper because + return_if_error is expecting an lzma_ret value, but + lzma_lzma_lclppb_encode returns a boolean. This could result in + lzma_microlzma_encoder, which would be misleading for applications. + + src/liblzma/common/microlzma_encoder.c | 3 ++- + 1 file changed, 2 insertions(+), 1 deletion(-) + +commit 8ace358d65059152d9a1f43f4770170d29d35754 +Author: Jia Tan +Date: 2022-12-16 20:58:55 +0800 + + CMake: Update .gitignore for CMake artifacts from in source build. + + In source builds are not recommended, but we can make it easier + by ignoring the generated artifacts from CMake. + + .gitignore | 23 +++++++++++++++++++++++ + 1 file changed, 23 insertions(+) + +commit 8fd225a2c149f30aeac377e68eb5abf6b28300ad +Author: Lasse Collin +Date: 2022-12-16 18:30:02 +0200 + + liblzma: Update authors list in arm64.c. + + src/liblzma/simple/arm64.c | 1 + + 1 file changed, 1 insertion(+) + +commit b69da6d4bb6bb11fc0cf066920791990d2b22a06 +Author: Lasse Collin +Date: 2022-12-13 20:37:17 +0200 + + Bump version to 5.4.0 and soname to 5.4.0. + + src/liblzma/Makefile.am | 2 +- + src/liblzma/api/lzma/version.h | 6 +++--- + src/liblzma/liblzma_generic.map | 2 +- + src/liblzma/liblzma_linux.map | 2 +- + 4 files changed, 6 insertions(+), 6 deletions(-) diff --git a/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/licenses/xz/INSTALL_RECEIPT.json b/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/licenses/xz/INSTALL_RECEIPT.json index 158e7e6..89f1935 100755 --- a/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/licenses/xz/INSTALL_RECEIPT.json +++ b/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/licenses/xz/INSTALL_RECEIPT.json @@ -1 +1,39 @@ -{"homebrew_version":"2.2.10-75-gf527f03","used_options":[],"unused_options":[],"built_as_bottle":true,"poured_from_bottle":false,"installed_as_dependency":false,"installed_on_request":true,"changed_files":["INSTALL_RECEIPT.json","lib/pkgconfig/liblzma.pc"],"time":null,"source_modified_time":1584455505,"HEAD":null,"stdlib":null,"compiler":"clang","aliases":[],"runtime_dependencies":[],"source":{"path":"@@HOMEBREW_REPOSITORY@@/Library/Taps/homebrew/homebrew-core/Formula/xz.rb","tap":"homebrew/core","spec":"stable","versions":{"stable":"5.2.5","devel":"","head":"","version_scheme":0}}} \ No newline at end of file +{ + "homebrew_version": "5.0.6-31-gab36f6e", + "used_options": [], + "unused_options": [], + "built_as_bottle": true, + "poured_from_bottle": true, + "loaded_from_api": true, + "installed_as_dependency": true, + "installed_on_request": true, + "changed_files": [ + "lib/pkgconfig/liblzma.pc" + ], + "time": 1767796327, + "source_modified_time": 1765971771, + "compiler": "clang", + "aliases": [], + "runtime_dependencies": [], + "source": { + "spec": "stable", + "versions": { + "stable": "5.8.2", + "head": null, + "version_scheme": 1, + "compatibility_version": null + }, + "path": "/Users/van/Library/Caches/Homebrew/api/formula.jws.json", + "tap_git_head": "9a7c8abebc88f7eac4be163547e90ceba1f93241", + "tap": "homebrew/core" + }, + "arch": "arm64", + "built_on": { + "os": "Macintosh", + "os_version": "macOS 26", + "cpu_family": "dunno", + "xcode": "26.1", + "clt": "26.1.0.0.1.1761104275", + "preferred_perl": "5.34" + } +} \ No newline at end of file diff --git a/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/licenses/xz/README b/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/licenses/xz/README index 26e0b5c..4167167 100755 --- a/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/licenses/xz/README +++ b/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/licenses/xz/README @@ -10,6 +10,7 @@ XZ Utils 2. Version numbering 3. Reporting bugs 4. Translations + 4.1. Testing translations 5. Other implementations of the .xz format 6. Contact information @@ -67,24 +68,25 @@ XZ Utils 1.1. Overall documentation - README This file + README This file - INSTALL.generic Generic install instructions for those not familiar - with packages using GNU Autotools - INSTALL Installation instructions specific to XZ Utils - PACKAGERS Information to packagers of XZ Utils + INSTALL.generic Generic install instructions for those not + familiar with packages using GNU Autotools + INSTALL Installation instructions specific to XZ Utils + PACKAGERS Information to packagers of XZ Utils - COPYING XZ Utils copyright and license information - COPYING.GPLv2 GNU General Public License version 2 - COPYING.GPLv3 GNU General Public License version 3 - COPYING.LGPLv2.1 GNU Lesser General Public License version 2.1 + COPYING XZ Utils copyright and license information + COPYING.0BSD BSD Zero Clause License + COPYING.GPLv2 GNU General Public License version 2 + COPYING.GPLv3 GNU General Public License version 3 + COPYING.LGPLv2.1 GNU Lesser General Public License version 2.1 - AUTHORS The main authors of XZ Utils - THANKS Incomplete list of people who have helped making - this software - NEWS User-visible changes between XZ Utils releases - ChangeLog Detailed list of changes (commit log) - TODO Known bugs and some sort of to-do list + AUTHORS The main authors of XZ Utils + THANKS Incomplete list of people who have helped making + this software + NEWS User-visible changes between XZ Utils releases + ChangeLog Detailed list of changes (commit log) + TODO Known bugs and some sort of to-do list Note that only some of the above files are included in binary packages. @@ -94,9 +96,9 @@ XZ Utils The command-line tools are documented as man pages. In source code releases (and possibly also in some binary packages), the man pages - are also provided in plain text (ASCII only) and PDF formats in the - directory "doc/man" to make the man pages more accessible to those - whose operating system doesn't provide an easy way to view man pages. + are also provided in plain text (ASCII only) format in the directory + "doc/man" to make the man pages more accessible to those whose + operating system doesn't provide an easy way to view man pages. 1.3. Documentation for liblzma @@ -113,8 +115,8 @@ XZ Utils Since the liblzma API has similarities to the zlib API, some people may find it useful to read the zlib docs and tutorial too: - http://zlib.net/manual.html - http://zlib.net/zlib_how.html + https://zlib.net/manual.html + https://zlib.net/zlib_how.html 2. Version numbering @@ -202,9 +204,47 @@ XZ Utils https://translationproject.org/html/translators.html - Several strings will change in a future version of xz so if you - wish to start a new translation, look at the code in the xz git - repostiory instead of a 5.2.x release. + Updates to translations won't be accepted by methods that bypass + the Translation Project because there is a risk of duplicate work: + translation updates made in the xz repository aren't seen by the + translators in the Translation Project. If you have found bugs in + a translation, please report them to the Language-Team address + which can be found near the beginning of the PO file. + + If you find language problems in the original English strings, + feel free to suggest improvements. Ask if something is unclear. + + +4.1. Testing translations + + Testing can be done by installing xz into a temporary directory. + + If building from Git repository (not tarball), generate the + Autotools files: + + ./autogen.sh + + Create a subdirectory for the build files. The tmp-build directory + can be deleted after testing. + + mkdir tmp-build + cd tmp-build + ../configure --disable-shared --enable-debug --prefix=$PWD/inst + + Edit the .po file in the po directory. Then build and install to + the "tmp-build/inst" directory, and use translations.bash to see + how some of the messages look. Repeat these steps if needed: + + make -C po update-po + make -j"$(nproc)" install + bash ../debug/translation.bash | less + bash ../debug/translation.bash | less -S # For --list outputs + + To test other languages, set the LANGUAGE environment variable + before running translations.bash. The value should match the PO file + name without the .po suffix. Example: + + export LANGUAGE=fi 5. Other implementations of the .xz format @@ -213,22 +253,29 @@ XZ Utils 7-Zip and the p7zip port of 7-Zip support the .xz format starting from the version 9.00alpha. - http://7-zip.org/ - http://p7zip.sourceforge.net/ + https://7-zip.org/ + https://p7zip.sourceforge.net/ XZ Embedded is a limited implementation written for use in the Linux kernel, but it is also suitable for other embedded use. https://tukaani.org/xz/embedded.html + XZ for Java is a complete implementation written in pure Java. + + https://tukaani.org/xz/java.html + 6. Contact information ---------------------- - If you have questions, bug reports, patches etc. related to XZ Utils, - contact Lasse Collin (in Finnish or English). - I'm sometimes slow at replying. If you haven't got a reply within two - weeks, assume that your email has got lost and resend it or use IRC. + XZ Utils in general: + - Home page: https://tukaani.org/xz/ + - Email to maintainer(s): xz@tukaani.org + - IRC: #tukaani on Libera Chat + - GitHub: https://github.com/tukaani-project/xz + + Lead maintainer: + - Email: Lasse Collin + - IRC: Larhzu on Libera Chat - You can join us on the Gitter chat channel at https://gitter.im/aboutcode-org/discuss - or also can use your favorite IRC client at https://web.libera.chat/?#aboutcode . \ No newline at end of file diff --git a/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/licenses/xz/THANKS b/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/licenses/xz/THANKS index 4301f20..e1c21eb 100755 --- a/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/licenses/xz/THANKS +++ b/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/licenses/xz/THANKS @@ -3,129 +3,252 @@ Thanks ====== Some people have helped more, some less, but nevertheless everyone's help -has been important. :-) In alphabetical order: - - Mark Adler - - H. Peter Anvin - - Jeff Bastian - - Nelson H. F. Beebe - - Karl Berry +has been important. :-) + - Adam Borowski + - Adam Walling + - Adrien Nader + - Agostino Sarubbo + - Alexander Bluhm + - Alexander M. Greenham + - Alexander Neumann + - Alexandre Sauvé + - Alexey Tourbin - Anders F. Björklund - - Emmanuel Blot - - Melanie Blower - - Martin Blumenstingl + - Andraž 'ruskie' Levstik + - Andre Noll + - Andreas K. Hüttel + - Andreas Müller + - Andreas Schwab + - Andreas Zieringer + - Andrej Skenderija + - Andres Freund + - Andrew Dudman + - Andrew Murray + - Antoine Cœur + - Anton Kochkov + - Antonio Diaz Diaz + - Arkadiusz Miskiewicz + - Asgeir Storesund Nilsen + - Aziz Chaudhry + - Bela Lubkin - Ben Boeckel - - Jakub Bogusz - - Maarten Bosmans - - Trent W. Buck - - James Buren - - David Burklund + - Benjamin Buch + - Benno Schulenberg + - Bernhard Reutner-Fischer + - Bert Wesarg + - Bhargava Shastry + - Bill Glessner + - Bjarni Ingi Gislason + - Boud Roukema + - Brad Smith + - Bruce Stark + - Cary Lewis + - Charles Wilson + - Chenxi Mao + - Chien Wong + - Chris Donawa + - Chris McCrohan + - Christian Hesse + - Christian Kujau + - Christian von Roques + - Christian Weisgerber + - Christoph Junghans + - Collin Funk + - Conley Moorhous + - Cristian Rodríguez + - Cristiano Ceglia + - Dan Shechter + - Dan Stromberg + - Dan Weiss + - Daniel Leonard - Daniel Mealha Cabrita - - Milo Casagrande - - Marek Černocký - - Tomer Chachamu - - Antoine Cœur + - Daniel Packard + - Daniel Richard G. + - David Burklund + - Denis Excoffier + - Derwin McGeary + - Dexter Castor Döpping + - Diederik de Haas + - Diego Elio Pettenò + - Dimitri Papadopoulos Orfanos + - Dirk Müller + - Douglas Thor + - Ed Maste + - Elbert Pol + - Eli Schwartz + - Elijah Almeida Coimbra + - Émilie Labbé + - Emmanuel Blot + - Eric Lindblad + - Eric S. Raymond + - Étienne Mollier + - Evan Nemerson + - Fangrui Song + - Felix Collin + - Filip Palian + - Firas Khalil Khana + - François Etcheverry + - Frank Busse + - Frank Prochnow + - Fredrik Wikstrom - Gabi Davar - - Chris Donawa - - Andrew Dudman - - Markus Duft - - İsmail Dönmez - - Robert Elz + - Gabriela Gutierrez - Gilles Espinasse - - Denis Excoffier - - Michael Felt - - Michael Fox - - Mike Frysinger - - Daniel Richard G. - - Bill Glessner + - Gregory Margo + - Guillaume Outters + - Guiorgy Potskhishvili + - H. Peter Anvin + - Hajin Jang + - Hans Jansen + - Harri K. Koskinen + - Hin-Tak Leung + - H.J. Lu + - Hongbo Ni + - Igor Pavlov + - İhsan Doğan + - Ilya Kurdyukov + - Iouri Kharon + - İsmail Dönmez + - Ivan A. Melnikov + - Jakub Bogusz + - James Buren + - James M Leddy + - Jan Kratochvil + - Jan Terje Hansen - Jason Gorski - - Juan Manuel Guerrero - - Diederik de Haas + - Jeff Bastian + - Jeffrey Walton + - Jeroen Roovers + - Jim Meyering + - Jim Wilcoxson - Joachim Henke - - Christian Hesse - - Vincenzo Innocente - - Peter Ivanov + - John Paul Adrian Glaubitz + - Jonathan Nieder + - Jonathan Stott + - Joona Kannisto - Jouk Jansen + - Juan Manuel Guerrero + - Jukka Salmi + - Julien Marrec - Jun I Jin + - Kai Pastor + - Karl Beldan + - Karl Berry + - Keith Patton + - Kelvin Lee + - Kevin R. Bulgrien + - Kian-Meng Ang + - Kim Jinyeong + - Kirill A. Korinsky - Kiyoshi Kanazawa - - Per Øyvind Karlsen - - Thomas Klausner - - Richard Koch - - Ville Koskinen - - Jan Kratochvil - - Christian Kujau - - Stephan Kulow - - Peter Lawler - - James M Leddy - - Hin-Tak Leung - - Andraž 'ruskie' Levstik - - Cary Lewis - - Wim Lewis - - Xin Li - - Eric Lindblad + - Lars Wirzenius + - Li Chenggang + - Lizandro Heredia + - Loganaden Velvindron - Lorenzo De Liso - - Bela Lubkin - - Gregory Margo - - Julien Marrec + - Lukas Braune + - Maarten Bosmans + - Maksym Vatsyk + - Marcin Kowalczyk + - Marcus Comstedt + - Marcus Tillmanns + - Marek Černocký + - Mark Adler + - Mark Wielaard + - Markus Duft + - Markus Rickert + - Martin Blumenstingl - Martin Matuška - - Jim Meyering - - Arkadiusz Miskiewicz - - Conley Moorhous - - Rafał Mużyło - - Adrien Nader - - Evan Nemerson - - Hongbo Ni - - Jonathan Nieder - - Andre Noll + - Martin Storsjö + - Martin Väth + - Mathieu Vachon + - Matthew Good + - Matthieu Rakotojaona + - Melanie Blower + - Michael Felt + - Michael Fox + - Michał Górny + - Mike Frysinger + - Mikko Pouru + - Milo Casagrande + - Mohammed Adnène Trojette + - Nathan Moinvaziri + - Nelson H. F. Beebe + - Nicholas Jackson + - Ole André Vadla Ravnås + - Orange Tsai + - Orgad Shaneh + - Patrick J. Volkerding + - Paul Eggert + - Paul Townsend + - Pavel Raiskup + - Per Øyvind Karlsen + - Peter Ivanov + - Peter Lawler - Peter O'Gorman - - Filip Palian - Peter Pallinger - - Rui Paulo - - Igor Pavlov - - Diego Elio Pettenò - - Elbert Pol - - Mikko Pouru + - Peter Seiderer + - Pierre-Yves Martin + - Pilorz Wojciech + - Pippijn van Steenhoven + - Rafał Mużyło + - Rainer Müller + - Ralf Wildenhues - Rich Prohaska - - Trần Ngọc Quân - - Pavel Raiskup - - Ole André Vadla Ravnås + - Richard Koch + - Richard W.M. Jones + - Robert Elz - Robert Readman - - Bernhard Reutner-Fischer - - Eric S. Raymond - - Cristian Rodríguez - - Christian von Roques - - Torsten Rupp - - Jukka Salmi - - Alexandre Sauvé - - Benno Schulenberg - - Andreas Schwab - - Bhargava Shastry - - Dan Shechter - - Stuart Shelton + - Roel Bouckaert + - Ron Desmond + - Ruarí Ødegaard + - Rui Paulo + - Ryan Colyer + - Ryan Young + - Sam James + - Scott McAllister + - Sean Fenian - Sebastian Andrzej Siewior - - Brad Smith - - Bruce Stark - - Pippijn van Steenhoven - - Jonathan Stott - - Dan Stromberg + - Sergey Kosukhin + - Simon Josefsson + - Siteshwar Vashisht + - Steffen Nurpmeso + - Stephan Kulow + - Stephen Sachs + - Stuart Shelton + - Taiki Tsunekawa + - Thomas Klausner + - Tobias Lahrmann Hansen + - Tobias Stoeckmann + - Tomasz Gajc + - Tomer Chachamu + - Torsten Rupp + - Trần Ngọc Quân + - Trent W. Buck + - Victoria Alexia + - Vijay Sarvepalli + - Ville Koskinen + - Ville Skyttä + - Vincent Cruz + - Vincent Fazio + - Vincent Lefevre - Vincent Torri - - Paul Townsend - - Mohammed Adnène Trojette - - Alexey Tourbin - - Loganaden Velvindron - - Patrick J. Volkerding - - Martin Väth - - Adam Walling - - Jeffrey Walton - - Christian Weisgerber - - Bert Wesarg - - Fredrik Wikstrom - - Jim Wilcoxson - - Ralf Wildenhues - - Charles Wilson - - Lars Wirzenius - - Pilorz Wojciech - - Ryan Young - - Andreas Zieringer + - Vincent Wixsom + - Vincenzo Innocente + - Vitaly Chikunov + - Wim Lewis + - Xi Ruoyao + - Xin Li + - Yifeng Li + - 榆柳松 (ZhengSen Wang) + +Companies: + - Google + - Sandfly Security + +Other credits: + - cleemy desu wayo working with Trend Micro Zero Day Initiative + - Orange Tsai and splitline from DEVCORE Research Team Also thanks to all the people who have participated in the Tukaani project. diff --git a/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/licenses/zstd/CHANGELOG b/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/licenses/zstd/CHANGELOG index 8609256..92df0f4 100755 --- a/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/licenses/zstd/CHANGELOG +++ b/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/licenses/zstd/CHANGELOG @@ -1,3 +1,250 @@ +V1.5.7 (Feb 2025) +fix: compression bug in 32-bit mode associated with long-lasting sessions +api: new method `ZSTD_compressSequencesAndLiterals()` (#4217, #4232) +api: `ZSTD_getFrameHeader()` works on skippable frames (#4228) +perf: substantial compression speed improvements (up to +30%) on small data, by @TocarIP (#4144) and @cyan4973 (#4165) +perf: improved compression speed (~+5%) for dictionary compression at low levels (#4170) +perf: much faster speed for `--patch-from` at high compression levels (#4276) +perf: higher `--patch-from` compression ratios, notably at high levels (#4288) +perf: better speed for binaries on Windows (@pps83) and when compiled with Visual Studio (@MessyHack) +perf: slight compression ratio improvement thanks to better block boundaries (#4136, #4176, #4178) +perf: slight compression ratio improvement for `dfast`, aka levels 3 and 4 (#4171) +perf: runtime bmi2 detection enabled on x86 32-bit mode (#4251) +cli: multi-threading as default CLI setting, by @daniellerozenblit +cli: new `--max` command (#4290) +build: improve `msbuild` version autodetection, support VS2022, by @ManuelBlanc +build: fix `meson` build by @artem and @Victor-C-Zhang, and on Windows by @bgilbert +build: compatibility with Apple Framework, by @Treata11 +build: improve icc/icx compatibility, by @josepho0918 and @luau-project +build: improve compatibility with Android NDK, by Adenilson Cavalcanti +portability: linux kernel branch, with improved support for Sequence producers (@embg, @gcabiddu, @cyan4973) +portability: improved qnx compatibility, suggested by @rainbowball +portability: improved install script for FreeBSD, by @sunpoet +portability: fixed test suite compatibility with gnu hurd, by @diegonc +doc: clarify specification, by @elasota +misc: improved tests/decodecorpus validation tool (#4102), by antmicro + +V1.5.6 (Mar 2024) +api: Promote `ZSTD_c_targetCBlockSize` to Stable API by @felixhandte +api: new `ZSTD_d_maxBlockSize` experimental parameter, to reduce streaming decompression memory, by @terrelln +perf: improve performance of param `ZSTD_c_targetCBlockSize`, by @Cyan4973 +perf: improved compression of arrays of integers at high compression, by @Cyan4973 +lib: reduce binary size with selective build-time exclusion, by @felixhandte +lib: improved huffman speed on small data and linux kernel, by @terrelln +lib: accept dictionaries with partial literal tables, by @terrelln +lib: fix CCtx size estimation with external sequence producer, by @embg +lib: fix corner case decoder behaviors, by @Cyan4973 and @aimuz +lib: fix zdict prototype mismatch in static_only mode, by @ldv-alt +lib: fix several bugs in magicless-format decoding, by @embg +cli: add common compressed file types to `--exclude-compressed`` by @daniellerozenblit +cli: fix mixing `-c` and `-o` commands with `--rm`, by @Cyan4973 +cli: fix erroneous exclusion of hidden files with `--output-dir-mirror` by @felixhandte +cli: improved time accuracy on BSD, by @felixhandte +cli: better errors on argument parsing, by @KapJI +tests: better compatibility with older versions of `grep`, by @Cyan4973 +tests: lorem ipsum generator as default backup content, by @Cyan4973 +build: cmake improvements by @terrelln, @sighingnow, @gjasny, @JohanMabille, @Saverio976, @gruenich, @teo-tsirpanis +build: bazel support, by @jondo2010 +build: fix cross-compiling for AArch64 with lld by @jcelerier +build: fix Apple platform compatibility, by @nidhijaju +build: fix Visual 2012 and lower compatibility, by @Cyan4973 +build: improve win32 support, by @DimitriPapadopoulos +build: better C90 compliance for zlibWrapper, by @emaste +port: make: fat binaries on macos, by @mredig +port: ARM64EC compatibility for Windows, by @dunhor +port: QNX support by @klausholstjacobsen +port: MSYS2 and Cygwin makefile installation and test support, by @QBos07 +port: risc-v support validation in CI, by @Cyan4973 +port: sparc64 support validation in CI, by @Cyan4973 +port: AIX compatibility, by @likema +port: HP-UX compatibility, by @likema +doc: Improved specification accuracy, by @elasota +bug: Fix and deprecate ZSTD_generateSequences (#3981) + +v1.5.5 (Apr 2023) +fix: fix rare corruption bug affecting the high compression mode, reported by @danlark1 (#3517, @terrelln) +perf: improve mid-level compression speed (#3529, #3533, #3543, @yoniko and #3552, @terrelln) +lib: deprecated bufferless block-level API (#3534) by @terrelln +cli: mmap large dictionaries to save memory, by @daniellerozenblit +cli: improve speed of --patch-from mode (~+50%) (#3545) by @daniellerozenblit +cli: improve i/o speed (~+10%) when processing lots of small files (#3479) by @felixhandte +cli: zstd no longer crashes when requested to write into write-protected directory (#3541) by @felixhandte +cli: fix decompression into block device using -o, reported by @georgmu (#3583) +build: fix zstd CLI compiled with lzma support but not zlib support (#3494) by @Hello71 +build: fix cmake does no longer require 3.18 as minimum version (#3510) by @kou +build: fix MSVC+ClangCL linking issue (#3569) by @tru +build: fix zstd-dll, version of zstd CLI that links to the dynamic library (#3496) by @yoniko +build: fix MSVC warnings (#3495) by @embg +doc: updated zstd specification to clarify corner cases, by @Cyan4973 +doc: document how to create fat binaries for macos (#3568) by @rickmark +misc: improve seekable format ingestion speed (~+100%) for very small chunk sizes (#3544) by @Cyan4973 +misc: tests/fullbench can benchmark multiple files (#3516) by @dloidolt + +v1.5.4 (Feb 2023) +perf: +20% faster huffman decompression for targets that can't compile x64 assembly (#3449, @terrelln) +perf: up to +10% faster streaming compression at levels 1-2 (#3114, @embg) +perf: +4-13% for levels 5-12 by optimizing function generation (#3295, @terrelln) +pref: +3-11% compression speed for `arm` target (#3199, #3164, #3145, #3141, #3138, @JunHe77 and #3139, #3160, @danlark1) +perf: +5-30% faster dictionary compression at levels 1-4 (#3086, #3114, #3152, @embg) +perf: +10-20% cold dict compression speed by prefetching CDict tables (#3177, @embg) +perf: +1% faster compression by removing a branch in ZSTD_fast_noDict (#3129, @felixhandte) +perf: Small compression ratio improvements in high compression mode (#2983, #3391, @Cyan4973 and #3285, #3302, @daniellerozenblit) +perf: small speed improvement by better detecting `STATIC_BMI2` for `clang` (#3080, @TocarIP) +perf: Improved streaming performance when `ZSTD_c_stableInBuffer` is set (#2974, @Cyan4973) +cli: Asynchronous I/O for improved cli speed (#2975, #2985, #3021, #3022, @yoniko) +cli: Change `zstdless` behavior to align with `zless` (#2909, @binhdvo) +cli: Keep original file if `-c` or `--stdout` is given (#3052, @dirkmueller) +cli: Keep original files when result is concatenated into a single output with `-o` (#3450, @Cyan4973) +cli: Preserve Permissions and Ownership of regular files (#3432, @felixhandte) +cli: Print zlib/lz4/lzma library versions with `-vv` (#3030, @terrelln) +cli: Print checksum value for single frame files with `-lv` (#3332, @Cyan4973) +cli: Print `dictID` when present with `-lv` (#3184, @htnhan) +cli: when `stderr` is *not* the console, disable status updates, but preserve final summary (#3458, @Cyan4973) +cli: support `--best` and `--no-name` in `gzip` compatibility mode (#3059, @dirkmueller) +cli: support for `posix` high resolution timer `clock_gettime()`, for improved benchmark accuracy (#3423, @Cyan4973) +cli: improved help/usage (`-h`, `-H`) formatting (#3094, @dirkmueller and #3385, @jonpalmisc) +cli: Fix better handling of bogus numeric values (#3268, @ctkhanhly) +cli: Fix input consists of multiple files _and_ `stdin` (#3222, @yoniko) +cli: Fix tiny files passthrough (#3215, @cgbur) +cli: Fix for `-r` on empty directory (#3027, @brailovich) +cli: Fix empty string as argument for `--output-dir-*` (#3220, @embg) +cli: Fix decompression memory usage reported by `-vv --long` (#3042, @u1f35c, and #3232, @zengyijing) +cli: Fix infinite loop when empty input is passed to trainer (#3081, @terrelln) +cli: Fix `--adapt` doesn't work when `--no-progress` is also set (#3354, @terrelln) +api: Support for Block-Level Sequence Producer (#3333, @embg) +api: Support for in-place decompression (#3432, @terrelln) +api: New `ZSTD_CCtx_setCParams()` function, set all parameters defined in a `ZSTD_compressionParameters` structure (#3403, @Cyan4973) +api: Streaming decompression detects incorrect header ID sooner (#3175, @Cyan4973) +api: Window size resizing optimization for edge case (#3345, @daniellerozenblit) +api: More accurate error codes for busy-loop scenarios (#3413, #3455, @Cyan4973) +api: Fix limit overflow in `compressBound` and `decompressBound` (#3362, #3373, Cyan4973) reported by @nigeltao +api: Deprecate several advanced experimental functions: streaming (#3408, @embg), copy (#3196, @mileshu) +bug: Fix corruption that rarely occurs in 32-bit mode with wlog=25 (#3361, @terrelln) +bug: Fix for block-splitter (#3033, @Cyan4973) +bug: Fixes for Sequence Compression API (#3023, #3040, @Cyan4973) +bug: Fix leaking thread handles on Windows (#3147, @animalize) +bug: Fix timing issues with cmake/meson builds (#3166, #3167, #3170, @Cyan4973) +build: Allow user to select legacy level for cmake (#3050, @shadchin) +build: Enable legacy support by default in cmake (#3079, @niamster) +build: Meson build script improvements (#3039, #3120, #3122, #3327, #3357, @eli-schwartz and #3276, @neheb) +build: Add aarch64 to supported architectures for zstd_trace (#3054, @ooosssososos) +build: support AIX architecture (#3219, @qiongsiwu) +build: Fix `ZSTD_LIB_MINIFY` build macro, which now reduces static library size by half (#3366, @terrelln) +build: Fix Windows issues with Multithreading translation layer (#3364, #3380, @yoniko) and ARM64 target (#3320, @cwoffenden) +build: Fix `cmake` script (#3382, #3392, @terrelln and #3252 @Tachi107 and #3167 @Cyan4973) +doc: Updated man page, providing more details for `--train` mode (#3112, @Cyan4973) +doc: Add decompressor errata document (#3092, @terrelln) +misc: Enable Intel CET (#2992, #2994, @hjl-tools) +misc: Fix `contrib/` seekable format (#3058, @yhoogstrate and #3346, @daniellerozenblit) +misc: Improve speed of the one-file library generator (#3241, @wahern and #3005, @cwoffenden) + +v1.5.3 (dev version, unpublished) + +v1.5.2 (Jan, 2022) +perf: Regain Minimal memset()-ing During Reuse of Compression Contexts (@Cyan4973, #2969) +build: Build Zstd with `noexecstack` on All Architectures (@felixhandte, #2964) +doc: Clarify Licensing (@terrelln, #2981) + +v1.5.1 (Dec, 2021) +perf: rebalanced compression levels, to better match the intended speed/level curve, by @senhuang42 +perf: faster huffman decoder, using x64 assembly, by @terrelln +perf: slightly faster high speed modes (strategies fast & dfast), by @felixhandte +perf: improved binary size and faster compilation times, by @terrelln +perf: new row64 mode, used notably in level 12, by @senhuang42 +perf: faster mid-level compression speed in presence of highly repetitive patterns, by @senhuang42 +perf: minor compression ratio improvements for small data at high levels, by @cyan4973 +perf: reduced stack usage (mostly useful for Linux Kernel), by @terrelln +perf: faster compression speed on incompressible data, by @bindhvo +perf: on-demand reduced ZSTD_DCtx state size, using build macro ZSTD_DECODER_INTERNAL_BUFFER, at a small cost of performance, by @bindhvo +build: allows hiding static symbols in the dynamic library, using build macro, by @skitt +build: support for m68k (Motorola 68000's), by @cyan4973 +build: improved AIX support, by @Helflym +build: improved meson unofficial build, by @eli-schwartz +cli : custom memory limit when training dictionary (#2925), by @embg +cli : report advanced parameters information when compressing in very verbose mode (`-vv`), by @Svetlitski-FB + +v1.5.0 (May 11, 2021) +api: Various functions promoted from experimental to stable API: (#2579-2581, @senhuang42) + `ZSTD_defaultCLevel()` + `ZSTD_getDictID_fromCDict()` +api: Several experimental functions have been deprecated and will emit a compiler warning (#2582, @senhuang42) + `ZSTD_compress_advanced()` + `ZSTD_compress_usingCDict_advanced()` + `ZSTD_compressBegin_advanced()` + `ZSTD_compressBegin_usingCDict_advanced()` + `ZSTD_initCStream_srcSize()` + `ZSTD_initCStream_usingDict()` + `ZSTD_initCStream_usingCDict()` + `ZSTD_initCStream_advanced()` + `ZSTD_initCStream_usingCDict_advanced()` + `ZSTD_resetCStream()` +api: ZSTDMT_NBWORKERS_MAX reduced to 64 for 32-bit environments (@Cyan4973) +perf: Significant speed improvements for middle compression levels (#2494, @senhuang42 @terrelln) +perf: Block splitter to improve compression ratio, enabled by default for high compression levels (#2447, @senhuang42) +perf: Decompression loop refactor, speed improvements on `clang` and for `--long` modes (#2614 #2630, @Cyan4973) +perf: Reduced stack usage during compression and decompression entropy stage (#2522 #2524, @terrelln) +bug: Improve setting permissions of created files (#2525, @felixhandte) +bug: Fix large dictionary non-determinism (#2607, @terrelln) +bug: Fix non-determinism test failures on Linux i686 (#2606, @terrelln) +bug: Fix various dedicated dictionary search bugs (#2540 #2586, @senhuang42 @felixhandte) +bug: Ensure `ZSTD_estimateCCtxSize*() `monotonically increases with compression level (#2538, @senhuang42) +bug: Fix --patch-from mode parameter bound bug with small files (#2637, @occivink) +bug: Fix UBSAN error in decompression (#2625, @terrelln) +bug: Fix superblock compression divide by zero bug (#2592, @senhuang42) +bug: Make the number of physical CPU cores detection more robust (#2517, @PaulBone) +doc: Improve `zdict.h` dictionary training API documentation (#2622, @terrelln) +doc: Note that public `ZSTD_free*()` functions accept NULL pointers (#2521, @animalize) +doc: Add style guide docs for open source contributors (#2626, @Cyan4973) +tests: Better regression test coverage for different dictionary modes (#2559, @senhuang42) +tests: Better test coverage of index reduction (#2603, @terrelln) +tests: OSS-Fuzz coverage for seekable format (#2617, @senhuang42) +tests: Test coverage for ZSTD threadpool API (#2604, @senhuang42) +build: Dynamic library built multithreaded by default (#2584, @senhuang42) +build: Move `zstd_errors.h` and `zdict.h` to `lib/` root (#2597, @terrelln) +build: Allow `ZSTDMT_JOBSIZE_MIN` to be configured at compile-time, reduce default to 512KB (#2611, @Cyan4973) +build: Single file library build script moved to `build/` directory (#2618, @felixhandte) +build: `ZBUFF_*()` is no longer built by default (#2583, @senhuang42) +build: Fixed Meson build (#2548, @SupervisedThinking @kloczek) +build: Fix excessive compiler warnings with clang-cl and CMake (#2600, @nickhutchinson) +build: Detect presence of `md5` on Darwin (#2609, @felixhandte) +build: Avoid SIGBUS on armv6 (#2633, @bmwiedmann) +cli: `--progress` flag added to always display progress bar (#2595, @senhuang42) +cli: Allow reading from block devices with `--force` (#2613, @felixhandte) +cli: Fix CLI filesize display bug (#2550, @Cyan4973) +cli: Fix windows CLI `--filelist` end-of-line bug (#2620, @Cyan4973) +contrib: Various fixes for linux kernel patch (#2539, @terrelln) +contrib: Seekable format - Decompression hanging edge case fix (#2516, @senhuang42) +contrib: Seekable format - New seek table-only API (#2113 #2518, @mdittmer @Cyan4973) +contrib: Seekable format - Fix seek table descriptor check when loading (#2534, @foxeng) +contrib: Seekable format - Decompression fix for large offsets, (#2594, @azat) +misc: Automatically published release tarballs available on Github (#2535, @felixhandte) + +v1.4.9 (Mar 1, 2021) +bug: Use `umask()` to Constrain Created File Permissions (#2495, @felixhandte) +bug: Make Simple Single-Pass Functions Ignore Advanced Parameters (#2498, @terrelln) +api: Add (De)Compression Tracing Functionality (#2482, @terrelln) +api: Support References to Multiple DDicts (#2446, @senhuang42) +api: Add Function to Generate Skippable Frame (#2439, @senhuang42) +perf: New Algorithms for the Long Distance Matcher (#2483, @mpu) +perf: Performance Improvements for Long Distance Matcher (#2464, @mpu) +perf: Don't Shrink Window Log when Streaming with a Dictionary (#2451, @terrelln) +cli: Fix `--output-dir-mirror` rejection of `..` -containing paths (#2512, @felixhandte) +cli: Allow Input From Console When `-f`/`--force` is Passed (#2466, @felixhandte) +cli: Improve Help Message (#2500, @senhuang42) +tests: Remove Flaky Tests (#2455, #2486, #2445, @Cyan4973) +tests: Correctly Invoke md5 Utility on NetBSD (#2492, @niacat) +tests: Avoid Using `stat -c` on NetBSD (#2513, @felixhandte) +build: Zstd CLI Can Now be Linked to Dynamic `libzstd` (#2457, #2454 @Cyan4973) +build: Hide and Avoid Using Static-Only Symbols (#2501, #2504, @skitt) +build: CMake: Enable Only C for lib/ and programs/ Projects (#2498, @concatime) +build: CMake: Use `configure_file()` to Create the `.pc` File (#2462, @lazka) +build: Fix Fuzzer Compiler Detection & Update UBSAN Flags (#2503, @terrelln) +build: Add Guards for `_LARGEFILE_SOURCE` and `_LARGEFILE64_SOURCE` (#2444, @indygreg) +build: Improve `zlibwrapper` Makefile (#2437, @Cyan4973) +contrib: Add `recover_directory` Program (#2473, @terrelln) +doc: Change License Year to 2021 (#2452 & #2465, @terrelln & @senhuang42) +doc: Fix Typos (#2459, @ThomasWaldmann) + v1.4.8 (Dec 18, 2020) hotfix: wrong alignment of an internal buffer @@ -268,7 +515,7 @@ misc: added /contrib/docker script by @gyscos v1.3.3 (Dec 21, 2017) perf: faster zstd_opt strategy (levels 16-19) -fix : bug #944 : multithreading with shared ditionary and large data, reported by @gsliepen +fix : bug #944 : multithreading with shared dictionary and large data, reported by @gsliepen cli : fix : content size written in header by default cli : fix : improved LZ4 format support, by @felixhandte cli : new : hidden command `-S`, to benchmark multiple files while generating one result per file diff --git a/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/licenses/zstd/INSTALL_RECEIPT.json b/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/licenses/zstd/INSTALL_RECEIPT.json index 245472f..b3455a5 100755 --- a/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/licenses/zstd/INSTALL_RECEIPT.json +++ b/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/licenses/zstd/INSTALL_RECEIPT.json @@ -1 +1,59 @@ -{"homebrew_version":"2.6.2-134-g24046c3","used_options":[],"unused_options":[],"built_as_bottle":true,"poured_from_bottle":false,"installed_as_dependency":false,"installed_on_request":true,"changed_files":["INSTALL_RECEIPT.json","lib/pkgconfig/libzstd.pc"],"time":null,"source_modified_time":1608338382,"HEAD":null,"stdlib":null,"compiler":"clang","aliases":["pzstd"],"runtime_dependencies":[],"source":{"path":"@@HOMEBREW_REPOSITORY@@/Library/Taps/homebrew/homebrew-core/Formula/zstd.rb","tap":"homebrew/core","spec":"stable","versions":{"stable":"1.4.8","head":"","version_scheme":0}},"arch":"x86_64","built_on":{"os":"Macintosh","os_version":"macOS 10.14.6","cpu_family":"penryn","xcode":"11.3.1","clt":"11.3.1.0.1.1576735732"}} \ No newline at end of file +{ + "homebrew_version": "4.4.21-62-g27a9032", + "used_options": [ + + ], + "unused_options": [ + + ], + "built_as_bottle": true, + "poured_from_bottle": true, + "loaded_from_api": true, + "installed_as_dependency": true, + "installed_on_request": true, + "changed_files": [ + "lib/pkgconfig/libzstd.pc" + ], + "time": 1741198360, + "source_modified_time": 1739923464, + "compiler": "clang", + "aliases": [ + "pzstd" + ], + "runtime_dependencies": [ + { + "full_name": "lz4", + "version": "1.10.0", + "revision": 0, + "pkg_version": "1.10.0", + "declared_directly": true + }, + { + "full_name": "xz", + "version": "5.6.4", + "revision": 0, + "pkg_version": "5.6.4", + "declared_directly": true + } + ], + "source": { + "spec": "stable", + "versions": { + "stable": "1.5.7", + "head": null, + "version_scheme": 0 + }, + "path": "/Users/van/Library/Caches/Homebrew/api/formula.jws.json", + "tap_git_head": "056318f4642987c0b8cac201a20740d5013961c7", + "tap": "homebrew/core" + }, + "arch": "arm64", + "built_on": { + "os": "Macintosh", + "os_version": "macOS 15", + "cpu_family": "dunno", + "xcode": "16.2", + "clt": "16.2.0.0.1.1733547573", + "preferred_perl": "5.34" + } +} \ No newline at end of file diff --git a/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/licenses/zstd/LICENSE b/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/licenses/zstd/LICENSE index a793a80..7580028 100755 --- a/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/licenses/zstd/LICENSE +++ b/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/licenses/zstd/LICENSE @@ -2,7 +2,7 @@ BSD License For Zstandard software -Copyright (c) 2016-present, Facebook, Inc. All rights reserved. +Copyright (c) Meta Platforms, Inc. and affiliates. All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: @@ -14,9 +14,9 @@ are permitted provided that the following conditions are met: this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. - * Neither the name Facebook nor the names of its contributors may be used to - endorse or promote products derived from this software without specific - prior written permission. + * Neither the name Facebook, nor Meta, nor the names of its contributors may + be used to endorse or promote products derived from this software without + specific prior written permission. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED diff --git a/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/licenses/zstd/README.md b/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/licenses/zstd/README.md index dcca766..d91ef5d 100755 --- a/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/licenses/zstd/README.md +++ b/builtins/extractcode_libarchive-macosx/src/extractcode_libarchive/licenses/zstd/README.md @@ -4,23 +4,21 @@ __Zstandard__, or `zstd` as short version, is a fast lossless compression algori targeting real-time compression scenarios at zlib-level and better compression ratios. It's backed by a very fast entropy stage, provided by [Huff0 and FSE library](https://github.com/Cyan4973/FiniteStateEntropy). -The project is provided as an open-source dual [BSD](LICENSE) and [GPLv2](COPYING) licensed **C** library, +Zstandard's format is stable and documented in [RFC8878](https://datatracker.ietf.org/doc/html/rfc8878). Multiple independent implementations are already available. +This repository represents the reference implementation, provided as an open-source dual [BSD](LICENSE) OR [GPLv2](COPYING) licensed **C** library, and a command line utility producing and decoding `.zst`, `.gz`, `.xz` and `.lz4` files. Should your project require another programming language, -a list of known ports and bindings is provided on [Zstandard homepage](http://www.zstd.net/#other-languages). +a list of known ports and bindings is provided on [Zstandard homepage](https://facebook.github.io/zstd/#other-languages). **Development branch status:** [![Build Status][travisDevBadge]][travisLink] -[![Build status][AppveyorDevBadge]][AppveyorLink] [![Build status][CircleDevBadge]][CircleLink] [![Build status][CirrusDevBadge]][CirrusLink] [![Fuzzing Status][OSSFuzzBadge]][OSSFuzzLink] -[travisDevBadge]: https://travis-ci.org/facebook/zstd.svg?branch=dev "Continuous Integration test suite" -[travisLink]: https://travis-ci.org/facebook/zstd -[AppveyorDevBadge]: https://ci.appveyor.com/api/projects/status/xt38wbdxjk5mrbem/branch/dev?svg=true "Windows test suite" -[AppveyorLink]: https://ci.appveyor.com/project/YannCollet/zstd-p0yf0 +[travisDevBadge]: https://api.travis-ci.com/facebook/zstd.svg?branch=dev "Continuous Integration test suite" +[travisLink]: https://travis-ci.com/facebook/zstd [CircleDevBadge]: https://circleci.com/gh/facebook/zstd/tree/dev.svg?style=shield "Short test suite" [CircleLink]: https://circleci.com/gh/facebook/zstd [CirrusDevBadge]: https://api.cirrus-ci.com/github/facebook/zstd.svg?branch=dev @@ -31,37 +29,35 @@ a list of known ports and bindings is provided on [Zstandard homepage](http://ww ## Benchmarks For reference, several fast compression algorithms were tested and compared -on a server running Arch Linux (`Linux version 5.5.11-arch1-1`), -with a Core i9-9900K CPU @ 5.0GHz, +on a desktop featuring a Core i7-9700K CPU @ 4.9GHz +and running Ubuntu 20.04 (`Linux ubu20 5.15.0-101-generic`), using [lzbench], an open-source in-memory benchmark by @inikep -compiled with [gcc] 9.3.0, +compiled with [gcc] 9.4.0, on the [Silesia compression corpus]. [lzbench]: https://github.com/inikep/lzbench -[Silesia compression corpus]: http://sun.aei.polsl.pl/~sdeor/index.php?page=silesia +[Silesia compression corpus]: https://sun.aei.polsl.pl//~sdeor/index.php?page=silesia [gcc]: https://gcc.gnu.org/ | Compressor name | Ratio | Compression| Decompress.| | --------------- | ------| -----------| ---------- | -| **zstd 1.4.5 -1** | 2.884 | 500 MB/s | 1660 MB/s | -| zlib 1.2.11 -1 | 2.743 | 90 MB/s | 400 MB/s | -| brotli 1.0.7 -0 | 2.703 | 400 MB/s | 450 MB/s | -| **zstd 1.4.5 --fast=1** | 2.434 | 570 MB/s | 2200 MB/s | -| **zstd 1.4.5 --fast=3** | 2.312 | 640 MB/s | 2300 MB/s | -| quicklz 1.5.0 -1 | 2.238 | 560 MB/s | 710 MB/s | -| **zstd 1.4.5 --fast=5** | 2.178 | 700 MB/s | 2420 MB/s | -| lzo1x 2.10 -1 | 2.106 | 690 MB/s | 820 MB/s | -| lz4 1.9.2 | 2.101 | 740 MB/s | 4530 MB/s | -| **zstd 1.4.5 --fast=7** | 2.096 | 750 MB/s | 2480 MB/s | -| lzf 3.6 -1 | 2.077 | 410 MB/s | 860 MB/s | -| snappy 1.1.8 | 2.073 | 560 MB/s | 1790 MB/s | - -[zlib]: http://www.zlib.net/ -[LZ4]: http://www.lz4.org/ +| **zstd 1.5.6 -1** | 2.887 | 510 MB/s | 1580 MB/s | +| [zlib] 1.2.11 -1 | 2.743 | 95 MB/s | 400 MB/s | +| brotli 1.0.9 -0 | 2.702 | 395 MB/s | 430 MB/s | +| **zstd 1.5.6 --fast=1** | 2.437 | 545 MB/s | 1890 MB/s | +| **zstd 1.5.6 --fast=3** | 2.239 | 650 MB/s | 2000 MB/s | +| quicklz 1.5.0 -1 | 2.238 | 525 MB/s | 750 MB/s | +| lzo1x 2.10 -1 | 2.106 | 650 MB/s | 825 MB/s | +| [lz4] 1.9.4 | 2.101 | 700 MB/s | 4000 MB/s | +| lzf 3.6 -1 | 2.077 | 420 MB/s | 830 MB/s | +| snappy 1.1.9 | 2.073 | 530 MB/s | 1660 MB/s | + +[zlib]: https://www.zlib.net/ +[lz4]: https://lz4.github.io/lz4/ The negative compression levels, specified with `--fast=#`, -offer faster compression and decompression speed in exchange for some loss in -compression ratio compared to level 1, as seen in the table above. +offer faster compression and decompression speed +at the cost of compression ratio. Zstd can also offer stronger compression ratios at the cost of compression speed. Speed vs Compression trade-off is configurable by small increments. @@ -124,14 +120,27 @@ Dictionary gains are mostly effective in the first few KB. Then, the compression ## Build instructions +`make` is the officially maintained build system of this project. +All other build systems are "compatible" and 3rd-party maintained, +they may feature small differences in advanced options. +When your system allows it, prefer using `make` to build `zstd` and `libzstd`. + ### Makefile If your system is compatible with standard `make` (or `gmake`), invoking `make` in root directory will generate `zstd` cli in root directory. +It will also create `libzstd` into `lib/`. Other available options include: - `make install` : create and install zstd cli, library and man pages -- `make check` : create and run `zstd`, tests its behavior on local platform +- `make check` : create and run `zstd`, test its behavior on local platform + +The `Makefile` follows the [GNU Standard Makefile conventions](https://www.gnu.org/prep/standards/html_node/Makefile-Conventions.html), +allowing staged install, standard flags, directory variables and command variables. + +For advanced use cases, specialized compilation flags which control binary generation +are documented in [`lib/README.md`](lib/README.md#modular-build) for the `libzstd` library +and in [`programs/README.md`](programs/README.md#compilation-variables) for the `zstd` CLI. ### cmake @@ -141,6 +150,18 @@ to create `zstd` binary, and `libzstd` dynamic and static libraries. By default, `CMAKE_BUILD_TYPE` is set to `Release`. +#### Support for Fat (Universal2) Output + +`zstd` can be built and installed with support for both Apple Silicon (M1/M2) as well as Intel by using CMake's Universal2 support. +To perform a Fat/Universal2 build and install use the following commands: + +```bash +cmake -B build-cmake-debug -S build/cmake -G Ninja -DCMAKE_OSX_ARCHITECTURES="x86_64;x86_64h;arm64" +cd build-cmake-debug +ninja +sudo ninja install +``` + ### Meson A Meson project is provided within [`build/meson`](build/meson). Follow @@ -163,6 +184,17 @@ You can build and install zstd [vcpkg](https://github.com/Microsoft/vcpkg/) depe The zstd port in vcpkg is kept up to date by Microsoft team members and community contributors. If the version is out of date, please [create an issue or pull request](https://github.com/Microsoft/vcpkg) on the vcpkg repository. +### Conan + +You can install pre-built binaries for zstd or build it from source using [Conan](https://conan.io/). Use the following command: + +```bash +conan install --requires="zstd/[*]" --build=missing +``` + +The zstd Conan recipe is kept up to date by Conan maintainers and community contributors. +If the version is out of date, please [create an issue or pull request](https://github.com/conan-io/conan-center-index) on the ConanCenterIndex repository. + ### Visual Studio (Windows) Going into `build` directory, you will find additional possibilities: @@ -176,20 +208,26 @@ Going into `build` directory, you will find additional possibilities: You can build the zstd binary via buck by executing: `buck build programs:zstd` from the root of the repo. The output binary will be in `buck-out/gen/programs/`. +### Bazel + +You easily can integrate zstd into your Bazel project by using the module hosted on the [Bazel Central Repository](https://registry.bazel.build/modules/zstd). + ## Testing -You can run quick local smoke tests by executing the `playTest.sh` script from the `src/tests` directory. -Two env variables `$ZSTD_BIN` and `$DATAGEN_BIN` are needed for the test script to locate the zstd and datagen binary. -For information on CI testing, please refer to TESTING.md +You can run quick local smoke tests by running `make check`. +If you can't use `make`, execute the `playTest.sh` script from the `src/tests` directory. +Two env variables `$ZSTD_BIN` and `$DATAGEN_BIN` are needed for the test script to locate the `zstd` and `datagen` binary. +For information on CI testing, please refer to `TESTING.md`. ## Status -Zstandard is currently deployed within Facebook. It is used continuously to compress large amounts of data in multiple formats and use cases. +Zstandard is currently deployed within Facebook and many other large cloud infrastructures. +It is run continuously to compress large amounts of data in multiple formats and use cases. Zstandard is considered safe for production environments. ## License -Zstandard is dual-licensed under [BSD](LICENSE) and [GPLv2](COPYING). +Zstandard is dual-licensed under [BSD](LICENSE) OR [GPLv2](COPYING). ## Contributing diff --git a/builtins/fetchcode_container/src/fetchcode_container/bin/skopeo b/builtins/fetchcode_container/src/fetchcode_container/bin/skopeo index 2861079..4d8d97e 100755 Binary files a/builtins/fetchcode_container/src/fetchcode_container/bin/skopeo and b/builtins/fetchcode_container/src/fetchcode_container/bin/skopeo differ diff --git a/builtins/textcode_pdf2text-linux/src/textcode_pdf2text/bin/pdf2text b/builtins/textcode_pdf2text-linux/src/textcode_pdf2text/bin/pdf2text new file mode 100755 index 0000000..025bd00 Binary files /dev/null and b/builtins/textcode_pdf2text-linux/src/textcode_pdf2text/bin/pdf2text differ diff --git a/builtins/textcode_pdf2text-linux/src/textcode_pdf2text/bin/pdftotext b/builtins/textcode_pdf2text-linux/src/textcode_pdf2text/bin/pdftotext index e5ca93f..fa8a136 100755 Binary files a/builtins/textcode_pdf2text-linux/src/textcode_pdf2text/bin/pdftotext and b/builtins/textcode_pdf2text-linux/src/textcode_pdf2text/bin/pdftotext differ diff --git a/builtins/textcode_pdf2text-macosx/pdf2text.ABOUT b/builtins/textcode_pdf2text-macosx/pdf2text.ABOUT index 214ac10..1245ad2 100755 --- a/builtins/textcode_pdf2text-macosx/pdf2text.ABOUT +++ b/builtins/textcode_pdf2text-macosx/pdf2text.ABOUT @@ -1,9 +1,9 @@ about_resource: . -version: 4.03 +version: 4.06 homepage_url: http://www.xpdfreader.com/ name: pdf2text owner: Glyph & Cog, LLC. -download_url: https://dl.xpdfreader.com/xpdf-4.03.tar.gz +download_url: https://dl.xpdfreader.com/xpdf-4.06.tar.gz copyright: Copyright (c) Glyph & Cog, LLC. license_expression: gpl-2.0 OR gpl-3.0 notice_file: pdf2text.NOTICE diff --git a/builtins/textcode_pdf2text-macosx/pdf2text.NOTICE b/builtins/textcode_pdf2text-macosx/pdf2text.NOTICE index a9a8dab..682c38c 100755 --- a/builtins/textcode_pdf2text-macosx/pdf2text.NOTICE +++ b/builtins/textcode_pdf2text-macosx/pdf2text.NOTICE @@ -1,11 +1,11 @@ Xpdf ==== -version 4.03 -2021-jan-28 +version 4.06 +2025-nov-13 The Xpdf software and documentation are -copyright 1996-2021 Glyph & Cog, LLC. +copyright 1996-2025 Glyph & Cog, LLC. Email: xpdf@xpdfreader.com WWW: http://www.xpdfreader.com/ diff --git a/builtins/textcode_pdf2text-macosx/setup.cfg b/builtins/textcode_pdf2text-macosx/setup.cfg index 4cc9f93..77b5d7b 100755 --- a/builtins/textcode_pdf2text-macosx/setup.cfg +++ b/builtins/textcode_pdf2text-macosx/setup.cfg @@ -9,4 +9,4 @@ license_files = textcode-pdf2text.ABOUT [aliases] -release = clean --all bdist_wheel --plat-name macosx_10_14_x86_64 --python-tag py3 +release = clean --all bdist_wheel --plat-name macosx_15_0_arm64 --python-tag py3 diff --git a/builtins/textcode_pdf2text-macosx/src/textcode_pdf2text/bin/pdf2text b/builtins/textcode_pdf2text-macosx/src/textcode_pdf2text/bin/pdf2text new file mode 100755 index 0000000..3726ba9 Binary files /dev/null and b/builtins/textcode_pdf2text-macosx/src/textcode_pdf2text/bin/pdf2text differ diff --git a/builtins/textcode_pdf2text-macosx/src/textcode_pdf2text/bin/pdftotext b/builtins/textcode_pdf2text-macosx/src/textcode_pdf2text/bin/pdftotext index 8130839..4c04547 100755 Binary files a/builtins/textcode_pdf2text-macosx/src/textcode_pdf2text/bin/pdftotext and b/builtins/textcode_pdf2text-macosx/src/textcode_pdf2text/bin/pdftotext differ diff --git a/builtins/textcode_pdf2text-macosx/src/textcode_pdf2text/lib/libfontconfig.1.dylib b/builtins/textcode_pdf2text-macosx/src/textcode_pdf2text/lib/libfontconfig.1.dylib new file mode 100644 index 0000000..95e5ec0 Binary files /dev/null and b/builtins/textcode_pdf2text-macosx/src/textcode_pdf2text/lib/libfontconfig.1.dylib differ diff --git a/builtins/textcode_pdf2text-macosx/src/textcode_pdf2text/lib/libfreetype.6.dylib b/builtins/textcode_pdf2text-macosx/src/textcode_pdf2text/lib/libfreetype.6.dylib new file mode 100644 index 0000000..0687d83 Binary files /dev/null and b/builtins/textcode_pdf2text-macosx/src/textcode_pdf2text/lib/libfreetype.6.dylib differ diff --git a/builtins/textcode_pdf2text-macosx/src/textcode_pdf2text/lib/libintl.8.dylib b/builtins/textcode_pdf2text-macosx/src/textcode_pdf2text/lib/libintl.8.dylib new file mode 100644 index 0000000..50b0756 Binary files /dev/null and b/builtins/textcode_pdf2text-macosx/src/textcode_pdf2text/lib/libintl.8.dylib differ diff --git a/builtins/textcode_pdf2text-macosx/src/textcode_pdf2text/lib/libpng16.16.dylib b/builtins/textcode_pdf2text-macosx/src/textcode_pdf2text/lib/libpng16.16.dylib new file mode 100644 index 0000000..690a76f Binary files /dev/null and b/builtins/textcode_pdf2text-macosx/src/textcode_pdf2text/lib/libpng16.16.dylib differ diff --git a/builtins/textcode_pdf2text-macosx/src/textcode_pdf2text/licenses/CHANGES b/builtins/textcode_pdf2text-macosx/src/textcode_pdf2text/licenses/CHANGES index f2dccc0..2ecce38 100755 --- a/builtins/textcode_pdf2text-macosx/src/textcode_pdf2text/licenses/CHANGES +++ b/builtins/textcode_pdf2text-macosx/src/textcode_pdf2text/licenses/CHANGES @@ -2740,3 +2740,278 @@ Check for invalid AcroForm ListBox field top index. [Thanks to Chengbin for the bug report.] Check for invalid mesh shading parameters. [Thanks to Chengbin for the bug report.] + +4.04 (2022-apr-18) +------------------ +When closing a file, save the current page number in ~/.xpdf.pages, + and restore it next time the file is opened. This can be disabled + with "savePageNumbers no" in your xpdfrc file. +Allow the tab list to be reordered, using drag-and-drop. +Added a document information dialog, with metadata and fonts, to xpdf. +Pdftohtml now generates HTML links for URI links anchored on text. +Added the useTrueTypeUnicodeMapping xpdfrc setting. +Added the 'enableXFA' xpdfrc setting back: if set to 'no', xpdf will + not read an XFA form, meaning all form info comes from the AcroForm. +Add support for long paths on Windows 10. +Added the "-formfields" option to pdftohtml. +Added the "-embedbackground" and "-embedfonts" options to pdftohtml. +Added the "-vstretch" option to pdftohtml. +Added the "-verbose" flag to pdfimages, pdftohtml, pdftopng, pdftoppm, + pdftops, and pdftotext. +Added the showAttachmentsPane, showLayersPane, and showOutlinePane + commands. +Added the 'openFile2' command to xpdf. +Added the showMenuBar, hideMenuBar, and toggleMenuBar commands to + xpdf. +Rearrange file names in the tab list to "foo.pdf [/full/path/]", to + improve the usability of the (narrow) tab list. +Added the 'imageMaskAntialias' xpdfrc setting. +Added the '-table' switch to pdftohtml. +Fixed a couple of progression order bugs in the JPEG 2000 decoder. + [Thanks to shellway for the bug reports.] +Fixed a problem with subsampled pixel index computations in the JPEG + 2000 decoder. [Thanks to shellway for the bug report.] +Fixed a couple of memory leaks triggered by fuzzed PDF files. [Thanks + to shellway for the bug report.] +Changed pdftohtml to generate spans with 'class=' instead of 'id=', so + there aren't duplicate ids. Also removed the unused id in the + background img element. +Optimized SplashOutputDev::drawTilingPattern for the case where the + tile is much larger than the area being drawn (i.e., the clipping + bbox). In this case, we can render just the needed portion of the + tile. +Added a missing zero check for precinct size in the JPEG 2000 decoder. + [Thanks to shellway for the bug report.] +Added a missing null check in the XFA form scanner. [Thanks to Taolaw + for the bug report.] +Deal with xref streams that include a free entry with gen=0xffffffff. +Fixed a problematic corner case in looking up XObject resources. + [Thanks to shellway for the bug report.] +The unicodeRemapping config command wasn't correctly handling unsorted + remapping files. +Improved handling of RTL text in the text extractor. +Extended the saveTabState/loadTabState commands to save/restore + display mode, zoom, rotation, and scroll position for each tab. +Added support for Qt6. +Added a missing bounds check on stream DecodeParms arrays. [Thanks to + minipython for the bug report.] +Fixed an integer overflow check in XRef::readXRefTable. [Thanks to + yangshufan for the bug report.] +The builtin Latin1 encoding was mapping 'endash' instead of + 'softhyphen' to 0xad. [Thanks to Jach Fong for the bug report.] +Fixed a bug in PSOutputDev::checkPageSlice() when built without + SPLASH_CMYK. [Thanks to irfanariq for the bug report.] +Added missing array length and type checks in Gfx::doForm(). [Thanks + to shaohua for the bug report.] +Fixed an integer overflow security hole in the JBIG2 decoder. +Substitute Helvetica for undefined fonts and bad font objects. +Added an integer overflow check in JPXStream. (JPXStream issue) + [Thanks to Shin Ando @ Ricera Security for the bug report.] +The DCT (JPEG) decoder was allowing the 'interleaved' flag to be + changed after the first scan of the image. (CVE-2022-24106) [Thanks + to Shin Ando @ Ricera Security for the bug report.] + +4.05 (2024-feb-08) +------------------ +Added the '-overwrite' option to pdftohtml. +Added the 'ignoreWrongSizeToUnicode' xpdfrc setting. +Added the loadSession and saveSession commands, and the 'Load last + session' menu item. +Added code to automatically save and restore the xpdf session under + control of a session manager. This has not been thoroughly tested + yet. +Added the zoomScaleFactor xpdfrc setting. +Added the zoomValues xpdfrc setting. +Added a 'smart case' option for search in xpdf. +Added the '-custom' flag to pdfinfo. +Added a color/gray/mono switch to the 'save image' dialog. +Added the separateRotatedText xpdfrc setting. +Added the '-meta' flag to pdftohtml. +Added the allowLinksToChangeZoom xpdfrc setting. +Added the 'uses JavaScript' output to pdfinfo. +Implemented pattern stroking of text. Also fixed the various + combinations of filling/stroking with color/pattern + clipping, some + of which weren't being handled correctly. +Pdftops now (re)compresses any uncompressed or RLE-compressed images. +On an out-of-memory error, the command line tools now exit with an + "out of memory" message, rather than an exception message. +Add code to pdfimages to extract images from tiling patterns. +Pdftops can now embed external 8-bit OpenType CFF fonts. +Fixed a corner case in the text extractor related to characters drawn + at extremely large coordinates. [Thanks to elvadisas for the bug + report.] +Fixed an integer overflow in the transparency group code. [Thanks to + elvadisas for the bug report.] +Modify Annots::Annots() to skip annotations that have been turned into + AcroFormFields -- invalid Widget-type annots will now be rendered as + annots. +Added a missing integer overflow check in the JBIG2 decoder. [Thanks + to sangjun for the bug report.] +Added some sanity checks to the JBIG2 decoder. [Thanks to sangjun and + ycdxsb for the bug reports.] +Tiling patterns that use non-Normal blend modes can't be cached. +Fixed a bitmap size sanity check in the JBIG2 decoder. [Thanks to Han + Zheng (NCNIPC of China, Hexhive), for the bug report.] +Fixed a missing bounds check in FoFiType1C::convertToOpenType (used in + pdftohtml). [Thanks to cyth for the bug report.] +Fixed a use-after-free bug in pdftohtml. [Thanks to FeRDNYC for the + bug report.] +Merged aconf2.h into aconf.h; corrected the cmake config settings for + paths; added the BASE14_FONT_DIR config option. [Thanks to FeRDNYC + for the suggestions.] +Fixed a missing check for a zero-length index in the CFF (Type1C) font + parser. [Thanks to Yuhang Huang (NCNIPC of China), Han Zheng + (NCNIPC of China, Hexhive), Wanying Cao, Jiayu Zhao (NCNIPC of + China) for the bug report.] +Add an object loop check to Catalog::countPageTree(). +The DCT decoder wasn't checking for an SOF before the first SOS. + [Thanks to cyth for the bug report.] +The inline image decoder was skipping to end-of-stream in the wrong + stream object. [Thanks to cyth for the bug report.] +Fixed a bug in the JPEG 2000 decoder when nLayers > 1 and the + 'termination on each coding pass' flag is set. +Removed the #pragma interface/implementation stuff (which is outdated + and useless at this point). +Fixed a bug in the ICCBased color space parser that was allowing the + number of components to be zero. (CVE-2023-2662) [Thanks to + huckleberry for the bug report.] +Added checks for PDF object loops in AcroForm::scanField() + (CVE-2018-7453, CVE-2018-16369, CVE-2022-36561, CVE-2022-41844), + Catalog::readPageLabelTree2() (CVE-2023-2663), and + Catalog::readEmbeddedFileTree() (CVE-2023-2664). +The zero-width character problem can also happen if the page size is + very large -- that needs to be limited too, the same way as + character position coordinates. (CVE-2023-3044) [Thanks to jlinliu + for the bug report.] +Add some missing bounds check code in DCTStream. [Thanks to Jiahao + Liu for the bug report.] +Fix a deadlock when an object stream's length field is contained in + another object stream. (CVE-2023-3436) [Thanks to Jiahao Liu for + the bug report.] +Correctly handle tiling patterns with negative step values. +Ignore overprint in soft masks (to match Adobe's behavior). + +4.06 (2025-nov-14) +------------------ +Added the reverseVideoMode, normalVideoMode, and toggleVideoMode + commands; added the view -> reverse video menu item. +Added a '%t' escape to include the currently selected text in the + argument to xpdf's 'run' command. +Added the '-listonly' flag to pdfimages. +Changed the default from Level 2 to Level 3 PostScript. +Use the XDG config and state file directories on Linux. This means + that ~/.config/xpdf/xpdfrc will be checked first, but ~/.xpdfrc will + still be checked. The session and pages file will *only* be used if + they are in ~/.local/state/xpdf/session and + ~/.local/state/xpdf/pages. (XDG support can be disabled at compile + time with 'cmake -DUSE_XDG=OFF'.) +Added the '-u' option to pdfimages. +Added the 'initialMaximized' xpdfrc setting. +Added the 'discardCoveredText' xpdfrc setting. +Added a file:close menu item to Xpdf. +Added the 'preferXFAFieldValues' xpdfrc setting. +Added the '-J' option to pdfimages to dump JPEG 2000 images. +Modified pdftohtml to generate a nicer index page; add the '-noframe' + option to generate the previous-style index page. +Added support to pdftohtml for internal links (i.e., links to pages in + the same document). +Tweaked the antialiasing code to make the output look a little + lighter, and hopefully nicer. +The command line tools should print version info ('pdftotext -v' etc) + to stdout, not stderr. +Added support for AIS (alpha is shape) for soft masked images drawn in + knockout transparency groups. +Tweaked the code that determines a font's ascent metric, trying (yet + again) to make it a little more robust to bogus values in the + FontDescriptor. +On Linux systems (and anything else that uses fontconfig) look for the + Base-14 fonts under the newer Nimbus names via fontconfig (in + addition to checking for the older gs font names in 'standard' + directories). +Pdftohtml now treats text drawn before a full-page fill as invisible. +Added Thai.unicodeRemap to the Thai language support packge: it maps + old Microsoft private use area Thai diacritics to correct Unicode + values. +Tweak the way invisible (OCR) text is handled in the output from + pdftohtml. +Tweaked the appearance of the tab pane in the sidebar. +Fixed a missing bounds check (not exploitable) in + GfxFont::readFontDescriptor(). [Thanks to Sangbin Kim for the bug + report.] +Don't allow negative object or generation numbers in indirect + references. (CVE-2024-2971) [Thanks to Song Jiaxuan (Huazhong + University of Science and Technology) for the bug report.] +Extended the XRef/Parser object loop detector to catch loops that + involve object streams. (CVE-2024-3247) [Thanks to Zhijie Zhang, + from Institute of Information Engineering, Chinese Academy of + Sciences for the bug report.] +Extended the Catalog::readFileAttachmentAnnots object loop detector to + handle another case. (CVE-2024-3248) [Thanks to Wang Dawei and Zhou + Geng, from Zhongguancun Laboratory for the bug report.] +Added a missing zero check to the size argument in + UnicodeRemapping::map(). (CVE-2024-3900) [Thanks to Sangbin Kim, + from Korea University Sejong campus for the bug report.] +Fixed a bounds check in FoFiType1::parse() that was being optimized + away by modern compilers. (CVE-2024-4141) [Thanks to Wu JieCong for + the bug report.] +If the XRefStm link in the trailer is invalid, just ignore it rather + than triggering the repair code. +Extended the resource object loop detector in PSOutputDev to handle + another case. (CVE-2024-4568) [Thanks to Ximing Fan, from School of + Cyber Science and Engineering, Sichuan University, China for the bug + report.] +Fixed a missing object type check that could lead to an out-of-bounds + array write in Annots::loadFormFieldRefs(). (CVE-2024-4976) [Thanks + to Vladislav Shevchenko (HSE university, Moscow) for the bug + report.] +Increased the size of the inter-packet data buffer for the arithmetic + decoder used by the JPX decoder. +Added another object loop check for patterns. (CVE-2024-7866) [Thanks + to xiaobaozidi for the bug report.] +Check for unreasoanbly large page box coordinates, to avoid integer + overflows. (CVE-2024-7867) [Thanks to xiaobaozidi for the bug + report.] +DCTStream::getBlock() was missing a check for the case where + DCTStream::prepare() failed due to invalid headers. (CVE-2024-7868) + [Thanks to KMFL for the bug report.] +Added a check for the case where a stream has a large number of + invalid filters, which was causing a stack overflow. [Thanks to + Michael Lynch of mtlynch.io for the bug report.] +Fixed a bug in WebFont.cc that caused a read of one element past the + end of an array. [Thanks to Mohammad Hussam Alzeyyat / mhzcyber for + the bug report.] +Added a missing mutex to protect the Annots object when using + multithreaded rendering in Xpdf. +Fixed incorrect integer overflow checking in + PostScriptFunction::exec(), which led to an out-of-bounds array + write. (CVE-2025-2574) [Thanks to Erik Viken for the bug report.] +Fixed the object loop check in AcroForm::scanField(). [Thanks to Erik + Viken for the bug report.] +Fixed the object loop check in Catalog::readPageLabelTree2(). [Thanks + to Erik Viken for the bug report.] +Added a missing bounds check in JBIG2Stream::readHalftoneRegionSeg(). + [Thanks to Erik Viken for the bug report.] +Added a missing parsed value check in + GfxGouraudTriangleShading::parse(). (CVE-2025-3154) [Thanks to Erik + Viken for the bug report.] +Added a cache for the tiling pattern tile, to handle the case where + the same tiling pattern is used multiple times in different fill + operations. +Ignore a bogus encoding for non-embedded Symbol and ZapfDingbats + fonts. +Fixed an signed/unsigned conversion problem in Splash::fillChar(). + [Thanks to Erik Viken for the bug report.] +Fixed the object loop check in Catalog::countPageTree(). [Thanks to + Gipoco for the bug report.] +Added some checking for the annotation matrix in Gfx::drawAnnot(). + [Thanks to Sofia Aberegg for the bug report.] +Removed Qt4 support from the cmake scripts. Xpdf has required Qt5/6 + for a while, but the cmake scripts weren't properly updated. +Added an object loop check for CMaps. (CVE-2025-11896) [Thanks + to landw (GitHub: Landw-hub) for the bug report.] +Fixed two uninitialized fields in StandardSecurityHandler - this is + not an exploitable bug. [Thanks to Aldo Ristori (GitHub: Kaldreic) + for the bug report.] +Fixed an unitialized value bug in JBIG2Stream::readSymbolDictSeg - + this is not an exploitable bug. [Thanks to Aldo Ristori (GitHub: + Kaldreic) for the bug report.] diff --git a/builtins/textcode_pdf2text-macosx/src/textcode_pdf2text/licenses/README b/builtins/textcode_pdf2text-macosx/src/textcode_pdf2text/licenses/README index e5a1142..ad39741 100755 --- a/builtins/textcode_pdf2text-macosx/src/textcode_pdf2text/licenses/README +++ b/builtins/textcode_pdf2text-macosx/src/textcode_pdf2text/licenses/README @@ -1,11 +1,11 @@ Xpdf ==== -version 4.03 -2021-jan-28 +version 4.06 +2025-nov-14 The Xpdf software and documentation are -copyright 1996-2021 Glyph & Cog, LLC. +copyright 1996-2025 Glyph & Cog, LLC. Email: xpdf@xpdfreader.com WWW: http://www.xpdfreader.com/ @@ -154,6 +154,7 @@ Xpdf uses the following libraries: * libpng [http://www.libpng.com/pub/png/libpng.html] (used by pdftohtml and pdftopng) * zlib [http://zlib.net/] (used by pdftohtml) +* Qt [https://www.qt.io/] Acknowledgments diff --git a/builtins/textcode_pdf2text-macosx/src/textcode_pdf2text/licenses/fontconfig/AUTHORS b/builtins/textcode_pdf2text-macosx/src/textcode_pdf2text/licenses/fontconfig/AUTHORS new file mode 100644 index 0000000..5ef8885 --- /dev/null +++ b/builtins/textcode_pdf2text-macosx/src/textcode_pdf2text/licenses/fontconfig/AUTHORS @@ -0,0 +1,3 @@ +Keith Packard +Patrick Lam + diff --git a/builtins/textcode_pdf2text-macosx/src/textcode_pdf2text/licenses/fontconfig/COPYING b/builtins/textcode_pdf2text-macosx/src/textcode_pdf2text/licenses/fontconfig/COPYING new file mode 100644 index 0000000..cd5fca1 --- /dev/null +++ b/builtins/textcode_pdf2text-macosx/src/textcode_pdf2text/licenses/fontconfig/COPYING @@ -0,0 +1,200 @@ +fontconfig/COPYING + +Copyright © 2000,2001,2002,2003,2004,2006,2007 Keith Packard +Copyright © 2005 Patrick Lam +Copyright © 2007 Dwayne Bailey and Translate.org.za +Copyright © 2009 Roozbeh Pournader +Copyright © 2008,2009,2010,2011,2012,2013,2014,2015,2016,2017,2018,2019,2020 Red Hat, Inc. +Copyright © 2008 Danilo Šegan +Copyright © 2012 Google, Inc. + + +Permission to use, copy, modify, distribute, and sell this software and its +documentation for any purpose is hereby granted without fee, provided that +the above copyright notice appear in all copies and that both that +copyright notice and this permission notice appear in supporting +documentation, and that the name of the author(s) not be used in +advertising or publicity pertaining to distribution of the software without +specific, written prior permission. The authors make no +representations about the suitability of this software for any purpose. It +is provided "as is" without express or implied warranty. + +THE AUTHOR(S) DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, +INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO +EVENT SHALL THE AUTHOR(S) BE LIABLE FOR ANY SPECIAL, INDIRECT OR +CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, +DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER +TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR +PERFORMANCE OF THIS SOFTWARE. + + +-------------------------------------------------------------------------------- +fontconfig/fc-case/CaseFolding.txt + +© 2019 Unicode®, Inc. +Unicode and the Unicode Logo are registered trademarks of Unicode, Inc. in the U.S. and other countries. +For terms of use, see http://www.unicode.org/terms_of_use.html + + +-------------------------------------------------------------------------------- +fontconfig/src/fcatomic.h + +/* + * Mutex operations. Originally copied from HarfBuzz. + * + * Copyright © 2007 Chris Wilson + * Copyright © 2009,2010 Red Hat, Inc. + * Copyright © 2011,2012,2013 Google, Inc. + * + * Permission is hereby granted, without written agreement and without + * license or royalty fees, to use, copy, modify, and distribute this + * software and its documentation for any purpose, provided that the + * above copyright notice and the following two paragraphs appear in + * all copies of this software. + * + * IN NO EVENT SHALL THE COPYRIGHT HOLDER BE LIABLE TO ANY PARTY FOR + * DIRECT, INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES + * ARISING OUT OF THE USE OF THIS SOFTWARE AND ITS DOCUMENTATION, EVEN + * IF THE COPYRIGHT HOLDER HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH + * DAMAGE. + * + * THE COPYRIGHT HOLDER SPECIFICALLY DISCLAIMS ANY WARRANTIES, INCLUDING, + * BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE. THE SOFTWARE PROVIDED HEREUNDER IS + * ON AN "AS IS" BASIS, AND THE COPYRIGHT HOLDER HAS NO OBLIGATION TO + * PROVIDE MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS. + * + * Contributor(s): + * Chris Wilson + * Red Hat Author(s): Behdad Esfahbod + * Google Author(s): Behdad Esfahbod + */ + + +-------------------------------------------------------------------------------- +fontconfig/src/fcfoundry.h + +/* + Copyright © 2002-2003 by Juliusz Chroboczek + + Permission is hereby granted, free of charge, to any person obtaining a copy + of this software and associated documentation files (the "Software"), to deal + in the Software without restriction, including without limitation the rights + to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + copies of the Software, and to permit persons to whom the Software is + furnished to do so, subject to the following conditions: + + The above copyright notice and this permission notice shall be included in + all copies or substantial portions of the Software. + + THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN + THE SOFTWARE. +*/ + + +-------------------------------------------------------------------------------- +fontconfig/src/fcmd5.h + +/* + * This code implements the MD5 message-digest algorithm. + * The algorithm is due to Ron Rivest. This code was + * written by Colin Plumb in 1993, no copyright is claimed. + * This code is in the public domain; do with it what you wish. + * + * Equivalent code is available from RSA Data Security, Inc. + * This code has been tested against that, and is equivalent, + * except that you don't need to include two pages of legalese + * with every copy. + * + * To compute the message digest of a chunk of bytes, declare an + * MD5Context structure, pass it to MD5Init, call MD5Update as + * needed on buffers full of bytes, and then call MD5Final, which + * will fill a supplied 16-byte array with the digest. + */ + + +-------------------------------------------------------------------------------- +fontconfig/src/fcmutex.h + +/* + * Atomic int and pointer operations. Originally copied from HarfBuzz. + * + * Copyright © 2007 Chris Wilson + * Copyright © 2009,2010 Red Hat, Inc. + * Copyright © 2011,2012,2013 Google, Inc. + * + * Permission is hereby granted, without written agreement and without + * license or royalty fees, to use, copy, modify, and distribute this + * software and its documentation for any purpose, provided that the + * above copyright notice and the following two paragraphs appear in + * all copies of this software. + * + * IN NO EVENT SHALL THE COPYRIGHT HOLDER BE LIABLE TO ANY PARTY FOR + * DIRECT, INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES + * ARISING OUT OF THE USE OF THIS SOFTWARE AND ITS DOCUMENTATION, EVEN + * IF THE COPYRIGHT HOLDER HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH + * DAMAGE. + * + * THE COPYRIGHT HOLDER SPECIFICALLY DISCLAIMS ANY WARRANTIES, INCLUDING, + * BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE. THE SOFTWARE PROVIDED HEREUNDER IS + * ON AN "AS IS" BASIS, AND THE COPYRIGHT HOLDER HAS NO OBLIGATION TO + * PROVIDE MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS. + * + * Contributor(s): + * Chris Wilson + * Red Hat Author(s): Behdad Esfahbod + * Google Author(s): Behdad Esfahbod + */ + + +-------------------------------------------------------------------------------- +fontconfig/src/ftglue.[ch] + +/* ftglue.c: Glue code for compiling the OpenType code from + * FreeType 1 using only the public API of FreeType 2 + * + * By David Turner, The FreeType Project (www.freetype.org) + * + * This code is explicitely put in the public domain + * + * ========================================================================== + * + * the OpenType parser codes was originally written as an extension to + * FreeType 1.x. As such, its source code was embedded within the library, + * and used many internal FreeType functions to deal with memory and + * stream i/o. + * + * When it was 'salvaged' for Pango and Qt, the code was "ported" to FreeType 2, + * which basically means that some macro tricks were performed in order to + * directly access FT2 _internal_ functions. + * + * these functions were never part of FT2 public API, and _did_ change between + * various releases. This created chaos for many users: when they upgraded the + * FreeType library on their system, they couldn't run Gnome anymore since + * Pango refused to link. + * + * Very fortunately, it's possible to completely avoid this problem because + * the FT_StreamRec and FT_MemoryRec structure types, which describe how + * memory and stream implementations interface with the rest of the font + * library, have always been part of the public API, and never changed. + * + * What we do thus is re-implement, within the OpenType parser, the few + * functions that depend on them. This only adds one or two kilobytes of + * code, and ensures that the parser can work with _any_ version + * of FreeType installed on your system. How sweet... ! + * + * Note that we assume that Pango doesn't use any other internal functions + * from FreeType. It used to in old versions, but this should no longer + * be the case. (crossing my fingers). + * + * - David Turner + * - The FreeType Project (www.freetype.org) + * + * PS: This "glue" code is explicitely put in the public domain + */ diff --git a/builtins/textcode_pdf2text-macosx/src/textcode_pdf2text/licenses/fontconfig/INSTALL_RECEIPT.json b/builtins/textcode_pdf2text-macosx/src/textcode_pdf2text/licenses/fontconfig/INSTALL_RECEIPT.json new file mode 100644 index 0000000..7a740f7 --- /dev/null +++ b/builtins/textcode_pdf2text-macosx/src/textcode_pdf2text/licenses/fontconfig/INSTALL_RECEIPT.json @@ -0,0 +1,73 @@ +{ + "homebrew_version": "4.6.10-77-g6cb3473", + "used_options": [], + "unused_options": [], + "built_as_bottle": true, + "poured_from_bottle": true, + "loaded_from_api": true, + "installed_as_dependency": true, + "installed_on_request": false, + "changed_files": [ + ".bottle/etc/fonts/conf.d/README", + ".bottle/etc/fonts/fonts.conf", + "lib/pkgconfig/fontconfig.pc" + ], + "time": 1758996912, + "source_modified_time": 1751431594, + "compiler": "clang", + "aliases": [], + "runtime_dependencies": [ + { + "full_name": "libpng", + "version": "1.6.50", + "revision": 0, + "bottle_rebuild": 0, + "pkg_version": "1.6.50", + "declared_directly": false + }, + { + "full_name": "freetype", + "version": "2.14.1", + "revision": 1, + "bottle_rebuild": 0, + "pkg_version": "2.14.1_1", + "declared_directly": true + }, + { + "full_name": "libunistring", + "version": "1.3", + "revision": 0, + "bottle_rebuild": 1, + "pkg_version": "1.3", + "declared_directly": false + }, + { + "full_name": "gettext", + "version": "0.26", + "revision": 0, + "bottle_rebuild": 0, + "pkg_version": "0.26", + "declared_directly": true + } + ], + "source": { + "spec": "stable", + "versions": { + "stable": "2.17.1", + "head": null, + "version_scheme": 0 + }, + "path": "/Users/van/Library/Caches/Homebrew/api/formula.jws.json", + "tap_git_head": "49b612d86a5672c1a7b52fe8add45ac9ad597960", + "tap": "homebrew/core" + }, + "arch": "arm64", + "built_on": { + "os": "Macintosh", + "os_version": "macOS 26", + "cpu_family": "dunno", + "xcode": "26.0", + "clt": "26.0.0.0.1.1756965055", + "preferred_perl": "5.34" + } +} \ No newline at end of file diff --git a/builtins/textcode_pdf2text-macosx/src/textcode_pdf2text/licenses/fontconfig/NEWS b/builtins/textcode_pdf2text-macosx/src/textcode_pdf2text/licenses/fontconfig/NEWS new file mode 100644 index 0000000..bdc3b54 --- /dev/null +++ b/builtins/textcode_pdf2text-macosx/src/textcode_pdf2text/licenses/fontconfig/NEWS @@ -0,0 +1,2930 @@ + Fontconfig + Font configuration and customization library + Version 2.17.1 + 2025-07-02 + + +Check INSTALL for compilation and installation instructions. +Report bugs to https://gitlab.freedesktop.org/fontconfig/fontconfig/issues/new. + +2.17.1 + +Akira TAGOH (3): + Fix a heap buffer overflow + meson: Add 'noinstall' to default-hinting, default-sub-pixel-rendering, bitmap-conf build options + Bump the libtool version + +2.17 + +Akira TAGOH (48): + ci: Add a subproject test case for meson + test: Set sys-root to WINEPATH for MinGW + ci: Correct reference to not trigger fetching a branch for main + ci: clean up and add changelog to the release note through changelog API + meson: don't try to call run_command for gperf on --wrap-mode=forcefallback + Make sure that the debugging facilities are initialized at loading config phase + Add FcConfigPerferAppFont() to allow changing the order of application fonts + conf.d/65-nonlatin.conf: Rename Lohit Oriya to Lohit Odia + ci: disable meson static fontations build tentatively + conf.d/65-nonlatin.conf: drop the leading extra white spaces + ci: quote pip's requirement specifier in the build script + ci: Add -O option to the build script for convenience + ci: add installation test + Add a test case for FcPtrList + Improve performance of FcPtrListIterInitAtLast + test: make sure we have fcstdint.h before building test programs + Drop FcDefaultFini() from FcFini() to fix memory leaks + test: do not free FcFontSet From FcConfigGetFonts + Drop the configuration path migration code + Drop FcObjectFini() from FcFini() to fix memory leaks + Free the mutex object only when all cache objects isn't referenced + Free the mutex object only when there are no references to the default FcConfig instance + Increase a reference count for default FcConfig instance with FcInit() + conf.d: Add a conf to guess a generic-family for substitution + test: add a pattern test + test: add a test scenario for 48-guessfamily.conf + test-crbug1004254: hold FcConfig during running a test in a thread + Simplify FcConfigFini() + Revert "test-crbug1004254: hold FcConfig during running a test in a thread" + Call FcMutexUnlock only when valid instance is available + Fix a memory leak in default_langs + Avoid possibly invalid access on MT + Add bitmap-conf build option to choose default bitmap conf + doc: rewrite check-missing-doc in Python + Do not hardcode a cache version + Add default font paths for Android in configure script + meson: Fix additional-fonts-dirs build option that not taking effect + meson: rename meson_options.txt to meson.options + Allow dotfiles to scan for caching + Trim trailing newline in string in cache + Fix a crash with broken cache + ci: cleanup builddir + Do not fallback decoding with UTF-16BE if no iconv support + Fix padding with "und" in pattern elements + ci: fix pipeline fail of subproject build on forked project + ci: add some usage text to build script + Bump libtool version for autotools build + Fix release script + +Albert Lee (1): + Avoid conflict between dgettext macro and declaration in fcint.h + +ComixHe (1): + fix: Skip empty entries in XDG_DATA_DIRS parsing + +Dominik Röttsches (40): + [Fontations] Factor out fcpat.c - add Fontations dependencies + Add FcPatternObjectGet* impl for CharSet and LangSet + [Fontations] Improve resolution of Rust crate features + [Fontations] Roll Skrifa, Read-Fonts, Font-Types + [Fontations] Pattern Bindings for CharSet and LangSet + [Fontations] Container and local download of testfiles + Add Pytest status to Meson Summary + Add Roboto Flex to font downloading script + Migrate pytest testcase 431 to pre-downloaded fonts + [Fontations] Enable fc-query indexing through Fontations + Revert "ci: disable meson static fontations build tentatively" + [Fontations] Fix Rust edition, do not require extern crate + [Fontations] Add support for "foundry" pattern element + [Fontations] Add support for "version" pattern element + [Fontations] Clippy fix for foundries mapping + [Fontations] Add attributes weight, width, slant to Pattern + Cargo build improvements + [Fontations] Iterate over TrueType collections and named instances + Amend license headers + [Fontations] Process and append font capabilities to Pattern + Speculative fix for uninitialised value used in FcFontSort + [Fontations] Add charset pattern element + [Fontations] Add langset pattern element + [Fontations] Add fontwrapper, filename and symbol elements to pattern + [Fontations] Add woff wrapper and filename if file is woff or woff2 + [Fontations] Roll Fontations, Skrifa to 0.31.3 + [Fontations] Match name id append order to FreeType indexer + Sort test pattern elements + [Fontations] Add pixel size information + [Fontations] Fix size element and enable more element tests + [Fontations] Add spacing property + [Fontations] No style element for variable instance + [Fontations] Remove pattern filter from tests + Parse foundry from OS/2 for table version 0 + [Fontations] Assorted fixes to match FreeType indexing + [Fontations] Do not combine bindings into one crate + Make "retry:" label conditional on ICONV + [Fontations] Clarify import of FcLangSet + Rename FcFreeTypeLangSet to FcLangSetFromCharset + [Fontations] Fix downstream build of indexing with Fontations + +Federico Gallo Herosa (2): + fccharset.c Avoid use-after-free warning + fccharset.c Avoid use-after-free warning + +Sam James (1): + configure.ac: drop -fno-strict-aliasing + +Thomas Anderson (1): + Fix heap buffer underflow in FcConfigXdgDataDirs + +Tom Anderson (1): + Fix use-after-free in FcConfigGetPrgname + +Xi Ruoyao (1): + meson: don't force installation of a static library + +2.16.2 + +Akira TAGOH (12): + meson: do not require libintl if nls feature is disabled + ci: Add back Android build in a common way + ci: drop Language to make sure they are applied as default style + ci: Change the default build system to meson + ci: Stop on fail anyway + ci: default to clean-build + ci: detect OS from os-release if no FC_DISTRO_NAME is set + ci: add missing dependency of pytest + ci: Set more timeout for pytest + ci: fix too many open files on test + ci: add missing dependency of requests + meson: Use Requires.private instead of Requires + +Dominik Röttsches (2): + Upgrade bindgen in Fontations enabled Rust builds + [Fontations] Add internal PatternBuilder abstraction + +Kacper Michajłow (1): + meson: don't force build of a shared library + +Thomas Devoogdt (1): + meson.build: define a 'c' standard for the project (C99 and C11) + +2.16.1 + +Akira TAGOH (10): + meson: create fc_cachedir at the installation time + meson: set WORDS_BIGENDIAN + ci: get back MinGW build to rawhide + meson: make sure config.h contains config-fixups.h for OSX + Reformatting with clang-format + ci: Add a workflow to check the coding style + ci: workaround conflict between systemd and systemd-standalone-sysusers + conf.d: Add Adwaita Sans as system-ui + ci: disable job tentatively + ci: Add a release workflow + +Dominik Röttsches (1): + [Fontations] Allow linkage to internals in tests + +Thomas Devoogdt (1): + meson.build: explicitly check for pthread support + +2.16 + +Akira TAGOH (69): + Publish docs to GitLab pages + doc: default index for fontconfig-devel to index.html + Update URLs for docs + doc: Fix a typo of the summary for FcFontSetSort + Clean up .uuid files with fc-cache -f too + Fix undesired unref of FcConfig on Win32 + meson.build: Fix a typo in POT names + meson.build: Add missing --msgid-bugs-address + Sort out bitmap related config files + Add test cases for 70-no-bitmap-and-emoji.conf and 70-no-bitmap-except-emoji.conf + meson: Add missing checkup + Add a missing dependency for CI on FreeBSD + meson: try to figure out libintl dependency + ci: Fix a typo in build script + ci: Add config.log for artifacts + ci: Add missing dependencies + ci: Disable cache update + meson: Fix build fail with NLS enabled on BSD + meson: Add libxml2 support + ci: Add libxml2 build for meson + meson: Workaround an exception + ci: Workaround an error with libxml2 on Android + meson: Add iconv checkup for all platforms + Fix incompatible pointer type on MinGW + meson: Use c_shared_args to take care of --default-library=both on Win32 + ci: Fix a typo + ci: disable iconv for MSVC + ci: build with expat on MSVC + doc: Use sans-serif instead of sans + Do not add merge commits into NEWS file + doc: Fix a typo + meson: Enable run-test.sh for non-Win32 + test/wrapper-script.sh: don't add a path when executable already has a path name. + meson: Add missing the unit testing with json-c + test-conf: Fix compiler warnings + Fix test case for reproducible builds + ci: Use md5 if md5sum isn't available. + ci: normalize path to avoid miscalculation of cache name + ci: Add Fedora 40 and remove Fedora 38 + More information when no writable cache directories + Fix a memory leak in _get_real_paths_from_prefix + Set FcTypeVoid if no valid types to convert + Add FcConfigSetFontSetFilter + Improve hinting detection for fonthashint object + Accept integer for pixelsize + Fix a memory leak in fc-list/fc-query/fc-scan + Add got.orth for Gothic language + Add cop.orth for Coptic language + Add foreign automake option to avoid an error on autotools bootstrap + ci: rebase ci-templates + ci: Add Fedora 41 and drop 39 + ci: run check-merge-request on merge request pipelines only + ci: Add FreeBSD 14.1 and drop 13.2 + ci: build mingw on f40 only + meson: Add install_tag for install targets + meson: Add docs into dist + meson: Add autotools files into dist + doc: generate fontconfig-devel.html as one big file + ci: Fix a fail on pages deployment + ci: Fix pages deployment again + fc-case: Correct the license header of fccase.h + Use proper postscriptname for named instance if any + Replace hardcoded path in man pages to url link + Allow comma as a delimiter in postscriptname and ignore it on matching + Deal with glob string properly + Another fix of glob string for Win32 + ci: Enable meson dist + Fix misleading-indentation warning + Bump the libtool version + +Andreas Falkenhahn (1): + Do not prefix cache_base with a "/". Doing so will lead to FcStrBuildFilename() composing paths that contain double slashes, e.g. in FcDirCacheProcess(). If FcDirCacheBasenameMD5() returns a cache_base that is prefixed with a "/", the call to FcStrBuildFilename() in FcDirCacheProcess() will compose a path that contains double slashes and this double-slashed path will then be passed to FcDirCacheOpenFile(). This won't cause any harm on Linux because Linux just ignores multiple slashes in paths but on other operating systems multiple slashes in paths are not allowed so FcDirCacheOpenFile() will fail on those platforms because of the double slash in the path. + +Andrey Prokopyuk (2): + Fix qsort nullpointer issue + Fix FcSerialize null pointer usage + +Christoph Reiter (1): + meson: fix config relocation on Windows + +Dan Yeaw (1): + Fix invalid escape character \s + +Dominik Röttsches (6): + Remove redundant leaf assignment in fcfreetype.c + Move Mac OS image to an up-to-date Mac OS 15 Sequoia image on ARM + Update Windows image to gstreamer image from stable + Allow building Rust targets in CI + [Fontations] Build bindgen targets, basic Rust test + Refactor exclusive language logic into separate file + +Florian "sp1rit"​ (1): + meson: added default font dirs for android + +Kenny Levinsen (2): + Unlock on allocation failure in FcCacheInsert + Ensure config is locked during retry in FcConfigReference + +Ryan Schmidt (1): + Fix wording in README.md + +Sam James (2): + build: detect-and-use `-lm` for `fabs` in fcmatch + fontconfig: mark _FcPatternIter as may_alias + +Xavier Claessens (2): + Meson: Fix build with clang-cl by using cc.preprocess() + meson: Add missing dep on generated header + +2.15 + +Akira TAGOH (39): + Do not change the order of orth files + Convert tabs to spaces + Convert more tabs to spaces in docs + src/meson.build: Store correct paths to fontconfig.pc. + Fix a typo in description for HAVE_STDATOMIC_PRIMITIVES + Report more detailed logs instead of assertion. + Add some missing constant names for weight. + Adujst indentation between programlisting in fontconfig-user.sgml + Bump version to 2.14.2 + Clean up unused code + Add another test case for flatpak + Update 65-nonlatin.conf for macOS + Change the order of the properties to the order of fontconfig cache format + Add missing property descriptions + Add namedinstance property + Remove the problematic language from code and doc + Fix a typo + Fix a typo for FcCharSetDelChar doc + Fix a typo in scalable property + Use 'outline' instead of 'scalable' for bitmaps + Add more docs about selectfont + Rework CI implementation + Fix a typo + Rework CI implementation v2 + Apply a fix of ci-templates + Fix uninitialized memory access when failing memory allocation. + Create a symlink with relative path + Fix an error of "initializer element is not constant" + Update CaseFolding.txt to Unicode 15.1 + Update the encoding table for Simplified Chinese + Retry to decode strings in the name table as UTF-16BE in some cases. + Work around decoding strings in Macintosh encoding for the name table. + Add iconv detection for meson build + .gitlab-ci: Update + CI: Update + CI: static build only for rawhide + Use memmove instead of memcpy + Rename README to NEWS and add README.md + Update so version + +Ben Wagner (1): + Fix leak of `reason` in _FcConfigParse when not complaining + +Jean Abou Samra (2): + Ignore LC_CTYPE if set to "UTF-8" + Some doc clarifications + +Khaled Hosny (2): + Add FC_FONT_WRAPPER + Detect standalone CFF fonts for FC_FONT_WRAPPER + +Mike FABIAN (3): + Add anp.orth, bhb.orth, hif.orth, mag.orth, raj.orth, and the.orth + Add {agr,ayc,bem,ckb,cmn,dsb,hak,lij,lzh,mfe,mhr,miq,mjw,mnw,nan,nhn,niu,rif,sgs,shn,szl,tcy,tpi,unm,wae,yue,yuw}.orth + Change index type to 16 bit and bump cache version to 9 + +Ondrej Balaz (1): + Expand ~ in glob + +Sefa Eyeoglu (1): + Add optional 11-lcdfilter-none configuration + +Tom Anderson (2): + Fix filepaths added when scanning with sysroot + Fix false-positive CFI failure + +Vitaly Lysenkov (1): + In fcfreetype.c, `GetScriptTags`: fix `use_of_uninitialized_value` and return the correct number of parsed tags in case the font file contains less tags than indicated. + +Xavier Claessens (1): + meson: Support any compiler with gcc or msvc argument syntax + +lilinjie (1): + fix typo + +msizanoen1 (1): + Reload MM/VF metadata for each font face in font collection + +pell (1): + fixed typos in fc-conflist.sgml + +xiota (1): + Add aliases for Helvetica LT Std + +2.14.2 + +Akira TAGOH (13): + Fix the build issue on meson when -g option is added to c_args + Store artifacts for meson windows CI + Add FC_DESKTOP_NAME property + Add --with-default-sub-pixel-rendering option + Update po-conf/POTFILES.in + Ignore null pointer on Fc*Destroy functions + Convert tabs to spaces + Convert more tabs to spaces in docs + src/meson.build: Store correct paths to fontconfig.pc. + Fix a typo in description for HAVE_STDATOMIC_PRIMITIVES + Report more detailed logs instead of assertion. + Add some missing constant names for weight. + Adujst indentation between programlisting in fontconfig-user.sgml + +Christopher Degawa (1): + meson: modify gperf test to remove sh dependency + +Jason Francis (1): + meson: Update freetype2 git repository to upstream + +Jean Abou Samra (1): + Ignore LC_CTYPE if set to "UTF-8" + +Ondrej Balaz (1): + Expand ~ in glob + +lilinjie (1): + fix typo + +2.14.1 + +Akira TAGOH (6): + Use the latest stable release image for CI for mingw + Real fix of 91114d18c + Fix test cases for wrong use of remap-dir + Add back sort command + Add config files to enable/disable antialias + Enable 10-sub-pixel-rgb.conf by default + +Alan Coopersmith (1): + Bump the cache version to 8 in doc/fontconfig-user.sgml + +Jeremy Huddleston Sequoia (3): + meson: Fix linking libexpat on darwin + meson: Use fc_templatedir and fc_baseconfigdir are used when installing configs + meson: Use fc_configdir where appropriate during build + +NorwayFun (4): + add Georgian + add Georgian + po: add Georgian translation + po: Add Georgian translation + +Sam James (1): + configure.ac: allow disabling docbook + +Taylor R Campbell (1): + Avoid misuse of ctype(3) + +Tim-Philipp Müller (7): + meson: add 'default-hinting' option + meson: add 'default-fonts-dirs' option + meson: add 'additional-fonts-dirs' option + meson: add 'cache-dir' option + meson: add 'template-dir', 'baseconfig-dir', 'config-dir', and 'xml-dir' options + ci: update windows image to a 2022-server based one + ci: update macOS image + +Xavier Claessens (3): + meson: Do not run fc-cache when installing into a DESTDIR + meson: Fix configuration warnings + link_confs.py: Fix prepending DESTDIR to absolute path + +2.14 + +Alan Coopersmith (1): + Update address for reporting msgid bugs from bugzilla to gitlab + +2.13.96 (2.14 RC6) + +Akira TAGOH (2): + Add a missing file 48-spacing.conf + Merge branch 'main' of ssh://gitlab.freedesktop.org/fontconfig/fontconfig + +2.13.95 (2.14 RC5) + +Akira TAGOH (18): + Do not set different score to non-string values + Enable 11-lcdfilter-default.conf by default + Bump the cache version to 8 + Reflect matching results to binding in FcPattern + Fix a memory leak when trying to open a non-existing file + Fix score estimation for postscriptname + Resolves symlinks against + Add the option to not build fontconfig cache during installation + conf.d/60-latin.conf: Make Noto default. + Fix some testcase fails for 14c265a1 + Fix the issue fail to obtain the style name + Apply the change made by 23e46d1 again + Initialize variable + Add more description for fc-conflist.1 and FcConfigFileInfoIterInit.3 + Update CaseFolding.txt to Unicode 14 + Add an user font directory for Win32 to the default font path + Add test/wrapper-script.sh to the archive + Fix possible memory leaks in FcPatternObjectAddWithBinding + +Alex Richardson (3): + fcint: add casts to allow building with stricter compilers + Add support for C11 stdatomic atomics + FcCharSetPutLeaf(): Fix missing move of new_leaves contents + +Behdad Esfahbod (1): + If a varfont has 'opsz' axis, set FC_SIZE on default instant pattern + +Ben Wagner (6): + Add memory order constraints to C11 atomics + Free local FcCache lock on contention + Extend test thread args lifetime + Fix warning about os2->achVendID cannot be NULL + Back FcSerialize with open addressing hash table. + Actually skip leading spaces in style name + +Francesco Pretto (1): + WIN32: Fix pGetSystemWindowsDirectory found initialized during FcConfigParseAndLoadFromMemory + +Mehdi Sabwat (1): + fcstat: add support for wasm-emscripten + +Nirbheek Chauhan (1): + meson: Remove summary() from version_compare() block + +Pierre Ducroquet (5): + Add a configuration to switch to monospace if spacing=100 is requested + Reference the new configuration file + Remove configuration file from POTFILES + It seems this qual doesn't work on integers + Always add the family name from spacing=100 + +Ryan Gonzalez (1): + Ensure config.h is always included before stdlib headers + +Ryan Schmidt (5): + Avoid PCRE syntax when using grep + Remove Bugzilla references + Fix run-test.sh to work with BSD mktemp + Restore fcatomic compatibility with Mac OS X 10.4. + Fix FC_DEFAULT_FONTS on macOS and with BSD sed + +2.13.94 (2.14 RC4) + +Akira TAGOH (10): + Add back fullname property at scan matching phase + Overwrite symlinks for config files + Fix missing element for WINDOWSFONTDIR in meson + Refactoring configure.ac to add element around font paths + Fix build fail when missing docbook and/or disabling doc-build + ci: Update CA cert related thing for Python on Windows + Add support for XDG_DATA_DIRS + Better wording for comments in config + Revert constructing fullname property from family and style properties + Fix score evaluation for multiple values in properties + +Albert Astals Cid (1): + Fix potential memory leak in _get_real_paths_from_prefix + +Ben Wagner (11): + Skip leading whitespace in style name. + Remove abort from FcCompareSize. + Add line between licenses in COPYING. + Portable trap conditions in run-test.sh. + Fix leaks in fcxml.c, fc-match.c, and tests. + Fix wild frees and leak of fs in test-conf. + Always run-test-conf, but skip if not built. + Fix test-conf string to integer conversion. + Test all not_eq for family names. + Clean up test-family-matching test. + Fix stack use after scope in FcConfigCompareValue + +Carmina16 (1): + ie.orth: Corrected; mistaken source replaced + +Heiko Becker (1): + Handle absolute sysconfdir when installing symlinks + +Jacko Dirks (1): + fccfg.c: lock_config: Fix potential memory leak + +Szunti (3): + Fix locale dependent behaviour in run-test.sh + Check qual and compare for family tests + Fix stripping whitespace from end of family in FcPatternAddFullname + +Tim-Philipp Müller (6): + meson: remove unused stdin_wrapper.py script + fcformat: fix compiler warnings with clang on Android + ci: add meson android aarch64 build + meson: error out in script if gperf preprocessing failed + meson: fix cross-compilation issues with gperf header file preprocessing + meson: fix subproject build regression + +Xavier Claessens (3): + Meson: Fallback to gperf subproject on all platforms + Meson: Do not wrap fccache insallation script + Windows: Fix symlink privilege error detection + +ratijas (1): + Fix closing tag bracket typo in doc/fontconfig-user.sgml + +2.13.93 (2.14 RC3) + +Akira TAGOH (48): + Affect FC_FONT_HAS_HINT property to score on matcher + Do not return FcFalse from FcConfigParseAndLoad*() if complain is set to false + Warn as well if no directory name for cachedir provided + Take effect sysroot functionality to the default config file + Read latest cache in paths + Fix a memory leak caused by the previous commit + Use FcConfigReference/Destroy appropriately instead of FcConfigGetCurrent + Fix potential race condition in FcConfigSetCurrent and FcConfigReference + Fix gcc warnings with -Wpointer-sign + Don't add a value for FC_FULLNAME in meta face + Fix a test fail when no bwrap was available + Add proper fullname for named-instances + Fix the process substitution doesn't work with FONTCONFIG_FILE + Fix memory leaks + Fix assertion in FcFini() + Set exact boolean value to color property + Fix assertion in FcCacheFini() again + Fix errors on shellcheck + Fix cache conflicts on OSTree based system + Drop unmaintained files + Drop elements with its namespace from conf + Add FC_ORDER property into cache + Drop Bitstream Vera fonts from 60-latin.conf + Fix a typo in doc/confdir.sgml.in + Fix empty XDG_CACHE_HOME Behavior + Fix build issues regarding formatter for Win32 + Add some tweaks into runtest.sh to see progress + Integrate python scripts to autotools build + Make sure a minimum version of python + Make more clearer the license terms + Add CONFIGDIR to the fallback config where can be specified by --with-configdir + fc-scan: add --sysroot option + Construct fullname from family and style + Add fullname later once FcConfigSubstitute() is done + Update meson.build + Add Regular style when no meta data available to guess a style + Make sure a combination of family and familylang is available + Split up a code again coming from different copyright notice + Update COPYING + Use memcpy instead of strcpy + Evaluate mingw64_env to setup properly on CI + Add examples section in fc-match(1) + Drop duplicated BUILT_SOURCES in doc/Makefile.am + Initialize shell variables to be sure + Update README that missed changes mistakenly + new-version.sh: update version in meson.build + Update version in meson.build to sync up with configure.ac + new-version.sh: commit meson.build when bumpping + +Alan Coopersmith (1): + Fix some typos/spelling errors + +Ben Wagner (2): + Replace FT_UNUSED with FC_UNUSED. + Fix fc_atomic_ptr_get and use. + +Chun-wei Fan (2): + meson: Look for FreeType using CMake too + meson: Don't use .def files for Visual Studio builds + +James Lee (1): + Fix 'meson install' when cross compiling + +Jan Tojnar (4): + conf: Add JoyPixels emoji font + Correct reset-dirs in DTD + Drop elements with its namespace from fonts.conf.in + Turn unknown attributes into warning + +Jonathan Kew (1): + Set name_mapping to NULL after freeing + +Mathieu Duponchelle (1): + Some build fixes to support compilation with MSVC on Windows + +Matthias Clasen (17): + Avoid a crash in FcPatternHash with ranges + Special-case some of the string walking code + Add a hash function for families + Use a hash table for family matching + Add a shortcut for FcQualAny matching + Speed up fonthashint matching + Speed up FcConfigCompareValue + Speed up FcConfigCompareValue + Speed up FcCompareLang and FcCompareBool + Use a hash table for families in FcConfigSubstitute + Use __builtin_expect in a few places + Fixup: Promote ints to ranges when appropriate + Add FC_LIKELY and FC_UNLIKELY macros + Use FC_UNLIKELY + Fixup: Handle patterns without family + Fix up FC_LIKELY macros + Fix a problem in FcConfigSubstitute + +Nicolas Mailhot (1): + Use an URN for DTD ID + +Niklas Guertler (3): + Allow multiple default system font directories in the fallback config, and set them to the default dirs on Darwin. + Add XML tags to default values for FC_DEFAULT_FONTS on non-Darwin systems + Increased timeout for meson tests to 600sec to make tests work on Darwin + +Nirbheek Chauhan (2): + fcatomic: Fix EXC_BAD_ACCESS on iOS ARM64 + meson: Fix build failure with gcc10 on mingw + +Szunti (1): + Add missing return type for FcFontSet* functions + +Tim-Philipp Müller (8): + doc: fix FcPatternFilter documentation + Use FC_PATH_MAX to fix build on Windows + Fix build on Windows some more + fccompat: fix build on Windows without unistd.h + Guard dirent.h includes + Add Meson build system + meson: print configuration summary() + ci: allow meson mingw build to fail + +Xavier Claessens (3): + meson: Fix build when 'tools' option is disabled + meson: Use version comparison function + meson: Fix build failure when compiler is not in PATH + +xiota (1): + Add Courier Std aliases. Fixes #262. + +2.13.92 (2.14 RC2) + +Akira TAGOH (18): + Fix a typo on masking face id + Don't clean up pre-built docs if no docbook installed. + Fix obtaining real path from pre-defined names for Win32 + Fix a crash when running with FC_DEBUG=256 + Improve the performance a bit + Fix a typo + Add English name first into a cache + FcConfigParseAndLoad*() should returns false on config errors + Clean up temporary directory for tests + Add docs for missing properties + Fix the fail on fc-cache + Fix memory leaks + Fix a memory leak in FcFreeTypeQuery*() + Add 35-lang-normalize.conf + Add FC_FONT_HAS_HINT property to see if font has hinting or not. + Fix failing the check of prep table in some fonts + Fix the fails of make check when SOURCE_DATE_EPOCH is set + Improve the performance a bit + +Egmont Koblinger (1): + Fix the linear interpolation during weight mapping + +2.13.91 (2.14 RC1) + +Akira TAGOH (74): + Fix the build issue with --enable-static + Fix the issue that '~' wasn't extracted to the proper homedir + Add a test case for d1f48f11 + Fix CI + Add more prefix support in element + Update fonts.dtd for last commit + Update docs for 1aa8b700 + add missing the case of prefix="default" as documented + Fix test case + CI: Add more logs + Do not update mtime when removing .uuid file + Do not try updating mtime when unlink was failed + Do not run a test case for .uuid deletion + Drop Mitra Mono from 65-nonlatin.conf + Enable bubblewrap test case + Use FC_PATH_MAX instead of PATH_MAX + Use Rachana instead of Meera for Malayalam + Add doc for description element and update fonts.dtd + Fix FcFontList doesn't return a font with FC_COLOR=true + Add a test case for FcFontList + Warn when constant name is used for unexpected object + covscan fix: get rid of unnecessary condition check + Don't call unlink_dirs if basedir is null + covscan: fix compiler warnings + Fix a dereference of a null pointer + Fix a crash with invalid matrix element + Add system-ui generic family + Fix misleading summary in docs for FcStrStrIgnoreCase + Fix build issue on Win32. + autogen.sh: Make AUTORECONF_FLAGS overwritable + Ifdef'ed unnecessary code for Win32 + Fix make check on cross-compiled env + Add build test for MinGW + Fix make distcheck error + Update requirement for gettext + Correct configure option to cross-compile + Install wine for CI on MinGW + Don't test bind-mount thing for MinGW + Reset errno to do error handling properly + Add FcDirCacheCreateUUID doc back to pass make check + Drop a line to include uuid.h + Fix make check fail on run-test-conf.sh + Add new element remap-dir instead of extending dir element + Trim the last slash + Update testcase + Update deps to run CI + Drop unnecessary line to include uuid.h + Fix a typo + Add reset-dirs element + Add salt attribute to dir and remap-dir elements + Update doc for salt + trivial testcase update + Add back if !OS_WIN32 line + Fix build issues on MinGW + Use alternative function for realpath on Win32 + Fix make check fail on MinGW again + Add more data to artifacts for debugging purpose + Don't share fonts and cache dir for testing + Don't warn if path can't be converted with prefix + Add some debugging output + Oops, Terminate string + fc-cache: Show font directories to generate cache with -v + Allow overriding salt with new one coming later + Don't show salt in debugging message if salt is null + Fix unexpected cache name by double-slash in path + Fallback uuid-based name to read a cache if no MD5-based cache available + No need to remap for uuid based + Update the test case that is looking for uuid based on host + Distribute archive in xz instead of bz2 + Update CaseFolding.txt to Unicode 12.1 + fc-validate: returns an error code when missing some glyphs + Correct the comment for FC_LANG in fontconfig.h + Fix a typo in the description of FcWeightFromOpenTypeDouble + Fix endianness on generating MD5 cache name + +Behdad Esfahbod (1): + Fix name-table language code mapping for Mongolian + +Ben Wagner (1): + Better document sysroot. + +Chris McDonald (2): + Respect sysroot option for file path passed to stat + Lowered temporary rooted_dir variable inside loop + +Jon Turney (1): + Only use test wrapper-script if host is MinGW + +Keith Packard (6): + Do not remove UUID file when a scanned directory is empty + Fetch FONTCONFIG_SYSROOT in FcConfigCreate + Remove '-u' option from run-test-conf.sh + Add delays to test-bz106632, check UptoDate separately + Remove UUID-related tests + Replace UUID file mechanism with per-directory 'map' attribute [v2] + +Robert Yang (1): + src/fccache.c: Fix define for HAVE_POSIX_FADVISE + +2.13.1 + +Akira TAGOH (48): + Use the builtin uuid for OSX + Fix the build issue again on MinGW with enabling nls + Add uuid to Requires.private in .pc only when pkgconfig macro found it + Allow the constant names in the range + Do not override locale if already set by app + Add the value of the constant name to the implicit object in the pattern + Add a testcase for FcNameParse + Leave the locale setting to applications + call setlocale + Fix make check fail when srcdir != builddir. + Do not ship fcobjshash.h + Fix typo in doc + Change the emboldening logic again + Bug 43367 - RFE: iterator to peek objects in FcPattern + Add a testrunner for conf + Add a test case for 90-synthetic.conf + Bug 106497 - better error description when problem reading font configuration + Bug 106459 - fc-cache doesn't use -y option for .uuid files + Fix leaks + Fix -Wstringop-truncation warning + Fix double-free + Add a test case for bz#106618 + Update CaseFolding.txt to Unicode 11 + Remove .uuid when no font files exists on a directory + Fix the leak of file handle + Fix memory leak + Fix memory leaks + Fix memory leak + Fix memory leak + Fix memory leak + Fix unterminated string issue + Fix array access in a null pointer dereference + Fix access in a null pointer dereference + do not pass null pointer to memcpy + Fix dereferencing null pointer + Fix a typo + Fix possibly dereferencing a null pointer + Fix allocating insufficient memory for terminating null of the string + Make a call fail on ENOMEM + Allocate sufficient memory to terminate with null + Drop the redundant code + Fix memory leak + Fix the build issue with gperf + Fix missing closing bracket in FcStrIsAbsoluteFilename() + Update the issue tracker URL + Fix distcheck fail + Add .gitlab-ci.yml + Bump the libtool revision + +Alexander Larsson (3): + Add FcCacheAllocate() helper + Cache: Rewrite relocated paths in earlier + Cache: Remove alias_table + +Behdad Esfahbod (4): + Minor: fix warnings + Fix name scanning + Share name-mapping across instances + Use FT_HAS_COLOR + +Chris Lamb (1): + Ensure cache checksums are deterministic + +Matthieu Herrb (1): + FcCacheFindByStat(): fix checking of nanoseconds field. + +Tom Anderson (7): + Fix undefined-shift UBSAN errors + Use realfilename for FcOpen in _FcConfigParse + Add FONTCONFIG_SYSROOT environment variable + Fix CFI builds + Fix heap use-after-free + Return canonicalized paths from FcConfigRealFilename + Fix build with CFLAGS="-std=c11 -D_GNU_SOURCE" + +2.13 + +Akira TAGOH (4): + Add Simplified Chinese translations + Fix a build issue on MinGW with enabling nls + Initialize an array explicitly + Bump the libtool revision + +2.12.93 (2.13 RC3) + +Akira TAGOH (12): + trivial fix + Add files to enable ITS support in gettext + Use the native ITS support in gettext + Remove POTFILES.in until new release of gettext is coming... + export GETTEXTDATADIR to refer the local .its/.loc file instead of using --its option + clean up + Do not add cflags and libs coming from pkg-config file. + Revert some removal from 7ac6af6 + Take effects on dir, cachedir, acceptfont, and rejectfont only when loading + Do not mix up font dirs into the list of config dirs + Ensure the user config dir is available in the list of config dirs on the fallback config + Add missing files to ship + +Alexander Larsson (1): + FcHashTableAddInternal: Compare against the right key + +Behdad Esfahbod (5): + Remove hack for OS/2 weights 1..9 + Support FC_WIDTH as double as well + Fix leak + Use FT_Done_MM_Var if available + Fix undefined-behavior signed shifts + +Olivier Crête (1): + Fix cross-compilation by passing CPPFLAGS to CPP + +Tom Anderson (1): + Allow overriding symbol visibility. + +2.12.92 (2.13 RC2) + +Akira TAGOH (13): + cleanup files + Update .uuid only when -r is given but not -f. + Returns false if key is already available in the table + Add missing doc of FcDirCacheCreateUUID + Replace uuid in the table properly when -r + Add a test case for uuid creation + Do not update mtime with creating .uuid + Disable uuid related code on Win32 + Try to get current instance of FcConfig as far as possible + do not check the existence of itstool on win32 + Fix the mis-ordering of ruleset evaluation in a file with include element + Fix compiler warnings + Add FcReadLink to wrap up readlink impl. + +Alexander Larsson (1): + fchash: Fix replace + +Behdad Esfahbod (7): + Don't crash + Remove a debug abort() + Minor + Set font-variations settings for standard axes in variable fonts + Let pattern FC_FONT_VARIATIONS override standard axis variations + Put back accidentally removed code + Add FcWeightTo/FromOpenTypeDouble() + +2.12.91 (2.13 RC1) + +Akira TAGOH (37): + und_zsye.orth: polish to get for NotoEmoji-Regular.ttf + Revert "Keep the same behavior to the return value of FcConfigParseAndLoad" + Fix again to keep the same behavior to the return value of FcConfigParseAndLoad + cleanup + Fix a compiler warning + Update libtool revision + Bump version to 2.12.6 + doc: trivial update + Add the ruleset description support + workaround to avoid modifying by gettextize + missing an open parenthesis + another workaround to avoid modifying by gettextize... + Validate cache more carefully + Allow autoreconf through autopoint for gettext things + Correct debugging messages to load/scan config + Add the check of PCF_CONFIG_OPTION_LONG_FAMILY_NAMES back + Use uuid-based cache filename if uuid is assigned to dirs + Add new API to find out a font from current search path + Replace the font path in FcPattern to what it is actually located. + Replace the original path to the new one + Replace the path of subdirs in caches as well + Don't call FcStat when the alias has already been added + Destroy the alias and UUID tables when all of caches is unloaded + cleanup + abstract hash table functions + update + Fix memory leak + Fix a typo + Don't call FcStat when the alias has already been added + Add a testcase for bind-mounted cachedir + cleanup + Use smaller prime for hash size + Fix the testcase for env not enabled PCF_CONFIG_OPTION_LONG_FAMILY_NAMES in freetype + thread-safe functions in fchash.c + Fix distcheck error + Fix "make check" fail again + Bump the libtool revision + +Alban Browaeys (1): + Fixes cleanup + +Alexander Kanavin (1): + src/fcxml.c: avoid double free() of filename + +Bastien Nocera (1): + conf: Prefer system emoji fonts to third-party ones + +Behdad Esfahbod (76): + Minor + Remove stray printf() + [fc-query] Fix linking order + Instead of loading glyphs (with FreeType), just check loca table + Don't even check loca for glyph outline detection + Check for non-empty outline for U+0000..U+001F + Add back code for choosing strike, and cleanup + Minor: adjust debug output + Remove unnecessary check + Remove a few unused blanks parameters + Remove check that cannot fail + Remove use of psnames for charset construction + Remove unused variable + Remove fc-glyphname + Remove blanks facility from the library + Remove blanks support from fc-scan + Mark more parameters FC_UNUSED + Move variables to narrower scope and indent + Remove unneeded check + Use multiplication instead of division + Use inline functions instead of macros for a couple of things + Simplify advance-width calculations + Inline FcFreeTypeCheckGlyph() + Call FT_Get_Advance() only as long as we need to determine font width type + Minor + Update documentation for removal of blanks + Merge branch 'faster' + Add FcFreeTypeQueryAll() + Document FcFreeTypeQueryAll() + Accept NULL in for spacing in FcFreeTypeCharSetAndSpacing() + Remove FcCompareSize() + Rename FcCompareSizeRange() to FcCompareRange() + Rewrite FcCompareRange() + In FcSubstituteDefault(), handle size range + Check instance-index before accessing array + Indent + [varfonts] Add FC_FONT_VARIATIONS + [varfonts] Add FC_VARIABLE + [varfonts] Change id argument in FcFreeTypeQuery* to unsigned int + Print ranges as closed as opposed to half-open + [varfonts] Change FC_WEIGHT and FC_WIDTH into ranges + [varfonts] Query varfonts if id >> 16 == 0x8000 + Fix instance-num handling in collections + [varfonts] Query variable font in FcFreeTypeQueryAll() + [varfonts] Fetch optical-size for named instances + In RenderPrepare(), handle ranges smartly + [fc-query] Remove --ignore-blanks / -b + [fc-match/fc-list/fc-query/fc-scan] Add --brief that is like --verbose without charset + Add separate match compare function for size + Fix range comparision operators implementation + Adjust emboldening logic + [varfonts] Map from OpenType to Fontconfig weight values + Add FcDontCare value to FcBool + Implement more config bool operations for boolean types + Fix possible div-by-zero + [varfonts] Use fvar data even if there's no variation in it + Minor + Revert "[varfonts] Use fvar data even if there's no variation in it" + [varfonts] Minor + [varfonts] Comment + [varfonts] Don't set style for variable-font pattern + [varfonts] Skip named-instance that is equivalent to base font + [varfonts] Do not set postscriptname for varfont pattern + [varfonts] Don't reopen face for each named instance + Separate charset and spacing code + [varfonts] Reuse charset for named instances + Move whitespace-trimming code to apply to all name-table strings + Fix whitespace-trimming loop and empty strings... + Whitespace + Don't convert nameds to UTF-8 unless we are going to use them + Simplify name-table platform mathcing logic + Use binary-search for finding name table entries + [varfonts] Share lang across named-instances + Merge branch 'varfonts2' + Require freetype >= 2.8.1 + Remove assert + +David Kaspar [Dee'Kej] (1): + conf.d: Drop aliases for (URW)++ fonts + +Florian Müllner (1): + build: Remove references to deleted file + +2.12.6 + +Akira TAGOH (4): + und_zsye.orth: polish to get for NotoEmoji-Regular.ttf + Revert "Keep the same behavior to the return value of FcConfigParseAndLoad" + Fix again to keep the same behavior to the return value of FcConfigParseAndLoad + Update libtool revision + +Behdad Esfahbod (2): + Minor + [fc-query] Fix linking order + +David Kaspar [Dee'Kej] (1): + conf.d: Drop aliases for (URW)++ fonts + +Florian Müllner (1): + build: Remove references to deleted file + +2.12.5 + +Akira TAGOH (17): + Add FcPatternGetWithBinding() to obtain the binding type of the value in FcPattern. + Add FcConfigParseAndLoadFromMemory() to load a configuration from memory. + Bug 101726 - Sans config pulls in Microsoft Serifed font + Fix gcc warnings with enabling libxml2 + Add und-zsye.orth to support emoji in lang + Add more code points to und-zsye.orth + Keep the same behavior to the return value of FcConfigParseAndLoad + Do not ship fcobjshash.gperf in archive + Accept 4 digit script tag in FcLangNormalize(). + Fix to work the debugging option on fc-validate + Add und_zmth.orth to support Math in lang + Polish und_zmth.orth for Libertinus Math + Polish und_zmth.orth more for Cambria Math and Minion Math + Update similar to emoji's + fc-blanks: fall back to the static data available in repo if downloaded data is corrupted + Update docs + Update libtool versioning + +Behdad Esfahbod (14): + Pass --pic to gperf + Add generic family matching for "emoji" and "math" + [fc-query] Support listing named instances + Add Twitter Color Emoji + Add EmojiOne Mozilla font + [fc-lang] Allow using ".." instead of "-" in ranges + Minor + Remove unneeded codepoints + Adjust color emoji config some more + Ignore 'und-' prefix for in FcLangCompare + Minor + Fix sign-difference compare warning + Fix warning + Fix weight mapping + +2.12.4 + +Akira TAGOH (5): + Force regenerate fcobjshash.h when updating Makefile + Fix the build failure when srcdir != builddir and have gperf 3.1 or later installed + Add a testcase for Bug#131804 + Update libtool revision + Fix distcheck error + +Florent Rougon (6): + FcCharSetHash(): use the 'numbers' values to compute the hash + fc-lang: gracefully handle the case where the last language initial is < 'z' + Fix an off-by-one error in FcLangSetIndex() + Fix erroneous test on language id in FcLangSetPromote() + FcLangSetCompare(): fix bug when two charsets come from different "buckets" + FcCharSetFreezeOrig(), FcCharSetFindFrozen(): use all buckets of freezer->orig_hash_table + +Helmut Grohne (1): + fix cross compilation + +Jan Alexander Steffens (heftig) (1): + Fix testing PCF_CONFIG_OPTION_LONG_FAMILY_NAMES (CFLAGS need to be right) + +Josselin Mouette (1): + Treat C.UTF-8 and C.utf8 locales as built in the C library. + +Masamichi Hosoda (1): + Bug 99360 - Fix cache file update on MinGW + +2.12.3 + +Akira TAGOH (1): + Fix make check fail with freetype-2.7.1 and 2.8 with PCF_CONFIG_OPTION_LONG_FAMILY_NAMES enabled. + +2.12.2 + +Akira TAGOH (8): + Don't call perror() if no changes happens in errno + Fix FcCacheOffsetsValid() + Fix the build issue with gperf 3.1 + Fix the build issue on GNU/Hurd + Update a bit for the changes in FreeType 2.7.1 + Add the description of FC_LANG envvar to the doc + Bug 101202 - fontconfig FTBFS if docbook-utils is installed + Update libtool revision + +Alan Coopersmith (1): + Correct cache version info in doc/fontconfig-user.sgml + +Khem Raj (1): + Avoid conflicts with integer width macros from TS 18661-1:2014 + +Masamichi Hosoda (2): + Fix PostScript font alias name + Update aliases for URW June 2016 + +2.12.1 + +Akira TAGOH (6): + Add --with-default-hinting to configure + Update CaseFolding.txt to Unicode 9.0 + Check python installed in autogen.sh + Fix some errors related to python3 + Bug 96676 - Check range of FcWeightFromOpenType argument + Update libtool revision + +Tobias Stoeckmann (1): + Properly validate offsets in cache files. + +2.12 + +Akira TAGOH (8): + Modernize fc-blanks.py + Update URL + Bug 95477 - FcAtomicLock fails when SELinux denies link() syscall with EACCES + 45-latin.conf: Add some Windows fonts to categorize them properly + Correct one for the previous change + Bug 95481 - Build fails on Android due to broken lconv struct + Add the static raw data to generate fcblanks.h + Remove unused code + +Erik de Castro Lopo (1): + Fix a couple of minor memory leaks + +Petr Filipsky (1): + Fix memory leak in FcDirCacheLock + +2.11.95 (2.12 RC5) + +Akira TAGOH (22): + Add one more debugging option to see transformation on font-matching + Fix a crash when no objects are available after filtering + No need to be public + mark as private at this moment + Don't return FcFalse even when no fonts dirs is configured + Add a warning for blank in fonts.conf + Fix a memory leak in FcFreeTypeQueryFace + Update CaseFolding.txt to Unicode 8.0 + Bug 90867 - Memory Leak during error case in fccharset + Fix the broken cache more. + Fail on make runtime as needed instead of configure if no python installed + Use long long to see the same size between LP64 and LLP64 + Fix build issue on MinGW + Use int64_t instead of long long + Fix compiler warnings on MinGW + Fix assertion on 32bit arch + remomve unnecessary code + Bug 93075 - Possible fix for make check failure on msys/MinGW... + Avoid an error message on testing when no fonts.conf installed + Add hintstyle templates and make hintslight default + Revert "Workaround another race condition issue" + Update libtool revision + +Behdad Esfahbod (6): + Revert changes made to FcConfigAppFontAddDir() recently + Call FcFreeTypeQueryFace() from fcdir.c, instead of FcFreeTypeQuery() + [GX] Support instance weight, width, and style name + [GX] Enumerate all named-instances in TrueType GX fonts + Improve OpenType to Fontconfig weight mapping + [GX] Improve weight mapping + +Patrick Haller (1): + Optimizations in FcStrSet + +2.11.94 (2.12 RC4) + +Akira TAGOH (16): + Remove the dead code + Bug 89617 - FcConfigAppFontAddFile() returns false on any font file + Fix unknown attribute in Win32 + Fix SIGFPE + Fix a typo for the latest cache version + Fix a typo in fontconfig-user.sgml + Drop unmaintained code + Observe blanks to compute correct languages in fc-query/fc-scan + Add missing description for usage + Make FC_SCALE deprecated + Bug 90148 - Don't warn if cachedir isn't specified + Fix memory leaks after FcFini() + Fix a typo + Fix a crash + Detect the overflow for the object ID + Revert the previous change + +Behdad Esfahbod (11): + Fix bitmap scaling + Add su[pport for symbol fonts + Write ranges using a [start finish) format + Only set FC_SIZE for scalable fonts if OS/2 version 5 is present + Add bitmap-only font size as Double, not Range + Accept Integer for FC_SIZE + Don't set FC_SIZE for bitmap fonts + Fix compiler warnings + Simplify FcRange + Reduce number of places that cache version is specified to 1 + Bump cache version number to 6, because of recent FcRange changes + +Руслан Ижбулатов (1): + W32: Support cache paths relative to the root directory + +2.11.93 (2.12 RC3) + +Akira TAGOH (18): + Fix a typo in docs + Add pkg.m4 to git + Fix a build fail on some non-POSIX platforms + ifdef'd the unnecessary code for win32 + Fix pointer cast warning on win32 + filter can be null + Copy the real size of struct dirent + Rework again to copy the struct dirent + Hardcode the blanks in the library + Update the script to recognize the escaped space + Fix a build issue when $(srcdir) != $(builddir) + Don't add FC_LANG when it has "und" + Fix the array allocation + Improve the performance on searching blanks + Fix a segfault when OOM happened. + Fix a bug in the previous change forFcBlanksIsMember() + Fix an infinite loop in FcBlanksIsMember() + Fix a trivial bug for dist + +Alan Coopersmith (1): + Fix configure to work with Solaris Studio compilers + +Behdad Esfahbod (3): + Fix symbol cmap handling + Remove dead code after previous commit + Simplify some more + +Michael Haubenwallner (1): + Ensure config.h is included first, bug#89336. + +2.11.92 (2.12 RC2) + +Akira TAGOH (1): + Add missing docs + +2.11.91 (2.12 RC1) + +Akira TAGOH (28): + Bug 71287 - size specific design selection support in OS/2 table version 5 + Fix a build issue with freetype <2.5.1 + Fix missing docs + Fix a typo + Fix fc-cache fail with -r + Rebase ja.orth against Joyo kanji characters + Allow the modification on FcTypeVoid with FcTypeLangSet and FcTypeCharSet + Workaround another race condition issue + Read the config files and fonts on the sysroot when --sysroot is given to fc-cache + Fix a segfault + Update CaseFolding.txt to Unicode 7.0 + Don't read/write from/to the XDG dirs if the home directory is disabled + Rework for 5004e8e01f5de30ad01904e57ea0eda006ab3a0c + Fix a crash when no sysroot is given and failed to load the default fonts.conf + Fix a gcc warning + Don't add duplicate lang + fallback to the another method to lock when link() failed + Increase the refcount in FcConfigSetCurrent() + Fix the memory leak in fc-cat + Note FcConfigSetCurrent() increases the refcount in document + Add FcRangeGetDouble() + Revert "Bug 73291 - poppler does not show fl ligature" + Update aliases for new URW fonts + Returns False if no fonts found + fc-cache: make a fail if no fonts processed on a given path + fc-cache: Add an option to raise an error if no fonts found + Bump the cache version to 5 + Fix a typo + +Behdad Esfahbod (39): + Remove unused code + Simplify hash code + Further simplify hash code + Rewrite hashing to use FT_Stream directly + Allow passing NULL for file to FcFreeTypeQueryFace() + [ko.orth] Remove U+3164 HANGUL FILLER + Deprecate FC_HASH and don't compute it + Remove unused FcHash code now that FC_HASH is deprecated + Update list of blanks to Unicode 6.3.0 + Update blanks to Unicode 7.0 + Change charset parse/unparse format to be human readable + Minor + Fix charset unparse after recent changes + Comments + Remove HASH from matching priorities + Fixup previous commit + Update mingw32 MemoryBarrier from HarfBuzz + More mingw32 MemoryBarrier() fixup + Symlinks fix for DESTDIR + Revert "Symlinks fix for DESTDIR" + Call FcInitDebug from FcFreeTypeQueryFace + Decode MacRoman encoding in name table without iconv + Ouch, fix buffer + Use lang=und instead of lang=xx for "undetermined" + Remove unused regex code + Improve / cleanup namelang matching + Add FC_WEIGHT_DEMILIGHT + Change DemiLight from 65 to 55 + Linearly interpolate weight values + Export recently added API + Remove unneeded FcPublic + Fix assertion failure + If OS/2 table says weight is 1 to 9, multiply by 100 + Trebuchet MS is a sans-serif font, not serif + Fix previous commit + Revert "[fcmatch] When matching, reserve score 0 for when elements don't exist" + Fix buffer overflow in copying PS name + Add FC_COLOR + Treat color fonts as scalable + +Nick Alcock (1): + Generate documentation for FcWeight* functions. + +2.11.1 + +Akira TAGOH (31): + do not build test-migration for Win32 + Fix build issue on Debian/kFreeBSD 7.0 + Update ax_pthread.m4 to the latest version + Fix the dynamic loading issue on NetBSD + Use stat() if there are no d_type in struct dirent + Fix a build issue on Solaris 10 + Change the default weight on match to FC_WEIGHT_NORMAL + Warn if no nor elements in + Correct DTD + Re-scan font directories only when it contains subdirs + Fix typo + Bug 72086 - Check for gperf in autogen.sh + Simplify to validate the availability of posix_fadvise + Simplify to validate the availability of scandir + Fix a typo + Fix a build issue on platforms where doesn't support readlink() + Improve the performance issue on rescanning directories + Bug 73686 - confdir is not set correctly in fontconfig.pc + Update zh_hk.orth + clean up the unused files + Add missing license headers + Update the use of autotools' macro + Fix a crash issue when empty strings are set to the BDF properties + Add a doc for FcDirCacheRescan + Add missing #include in fcstat.c + Fix incompatible API on AIX with random_r and initstate_r + Fallback to lstat() in case the filesystem doesn't support d_type in struct dirent + Update doc to include the version info of `since when' + Bug 73291 - poppler does not show fl ligature + Add README describes the criteria to add/modify the orthography files + Fix autoconf warning, warning: AC_COMPILE_IFELSE was called before AC_USE_SYSTEM_EXTENSIONS + +Alan Coopersmith (3): + Leave room for null terminators in arrays + Avoid memory leak when NULL path passed to FcStrBuildFilename + Avoid null pointer dereference in FcNameParse if malloc fails + +Behdad Esfahbod (1): + Bug 72380 - Never drop first font when trimming + +Frederic Crozat (2): + Fix inversion between Tinos and Cousine in the comment + Add metric aliases for additional Google ChromeOS fonts + +Jehan (1): + Defaulting to LOCAL_APPDATA_FONTCONFIG_CACHE for Win32 build + +Ross Burton (1): + fc-cache: --sysroot option takes an argument + +2.11 + +Akira TAGOH (15): + Do not create a config dir for migration when no config files nor dirs + Add a test case of the migration for config place + Fix memory leaks in FcFreeTypeQueryFace + Bug 68955 - Deprecate / remove FC_RASTERIZER + Copy all values from the font to the pattern if the pattern doesn't have the element + Fix a crash when FcPattern is set to null on FcFontSetList() and FcFontList() + Add the description of -q option to the man page + avoid reading config.h twice + clean up + Add the relative path for to fonts.conf if the parent path is same to fonts.conf + Workaround the race condition issue on updating cache + exit with the error code when FcNameParse() failed + Add missing doc for FcStrListFirst and fix a typo + Bump libtool revision + Update CaseFolding.txt to Unicode 6.3 + +Jan Alexander Steffens (heftig) (1): + Further changes to 30-metric-aliases.conf + +W. Trevor King (1): + doc/fccharset.fncs: Describe the map format in more detail + +2.10.95 (2.11 RC5) + +Akira TAGOH (2): + Fix a typo + Fix a crash + +2.10.94 (2.11 RC4) + +Akira TAGOH (25): + Bug 64906 - FcNameParse() should ignore leading whitespace in parameters + Fix a comparison of constant warning with clang + Fix a shift count overflow on 32bit box + Fix a incompatible pointer warning on NetBSD + Add FcTypeUnknown to FcType to avoid comparison of constant -1 + Fix the behavior of intermixed tests end edits in match + Ignore scandir() check on mingw + Use INT_MAX instead of unreliable hardcoding value + Add FC_UNUSED to FC_ASSERT_STATIC macro to avoid compiler warning + Rework to apply the intermixed test and edit elements in one-pass + trivial code optimization + Correct fontconfig.pc to add certain dependencies for build + Correct fontconfig.pc to add certain dependencies for static build + Fix wrong edit position + Bug 67809 - Invalid read/write with valgrind when assigning something twice + warn deprecated only when migration failed + Bug 67845 - Match on FC_SCALABLE + Bug 16818 - fontformat in match pattern is not respected? + Bug 68340 - More metric compat fonts + Bug 63399 - Add default aliases for Georgia, Garamond, Palatino Linotype, Trebuchet MS + Fix a typo + Fix a crash when non-builtin objects are edited + Fix a wrong edit position when 'kind' is different + Bug 68587 - copy qu.orth to quz.orth + Add quz.orth to Makefile.am + +Behdad Esfahbod (2): + Minor + Fix assertion + +2.10.93 (2.11 RC3) + +Akira TAGOH (10): + Bug 62980 - matching native fonts with even :lang=en + Ensure closing fp on error + Obtain fonts data via FT_Face instead of opening a file directly + Revert the previous change and rework to not export freetype API outside fcfreetype.c + documented FC_HASH and FC_POSTSCRIPT_NAME + Bug 63329 - make check fails: .. contents:: :depth: 2 + Use the glob matching for filename + Bug 63452 - conf.d/README outdated + Fix missing OSAtomicCompareAndSwapPtrBarrier() on Mac OS X 10.4 + Bug 63922 - FcFreeTypeQueryFace fails on postscripts fonts loaded from memory + +Sebastian Freundt (1): + build-chain, replace INCLUDES directive by AM_CPPFLAGS + +2.10.92 (2.11 RC2) + +Akira TAGOH (33): + Fix the build fail on MinGW + Bug 50497 - RFE: Add OpenType feature tags support + Improve FcGetPrgname() to work on BSD + Better fix for 2fe5ddfd + Add missing file descriptor to F_DUPFD_CLOEXEC + Fix mkstemp absence for some platform + Fix installation on MinGW32 + Add another approach to FC_PRGNAME for Solaris 10 or before + remove the unnecessary code + Bug 59385 - Do the right thing for intermixed edit and test elements + Bug 23757 - Add mode="delete" to + Modernize configure.ac + Use AM_MISSING_PROG instead of hardcoding missing + Revert "test: Use SH_LOG_COMPILER and AM_TESTS_ENVIRONMENT" + Use AM_MISSING_PROG instead of hardcoding missing + Bug 50733 - Add font-file hash? + Bug 60312 - DIST_SUBDIRS should never appear in a conditional + Update _FcMatchers definition logic + Bump the cache version to 4 + Add Culmus foundry to the vendor list + Bug 60748 - broken conf.d/10-autohint.conf and conf.d/10-unhinted.conf + Bug 60783 - Add Liberation Sans Narrow to 30-metric-aliases.conf + Fix a typo + Fix a crash when the object is non-builtin object + Fix broken sort order with FcFontSort() + Fix a memory leak + Bug 59456 - Adding a --sysroot like option to fc-cache + Do not copy FC_*LANG_OBJECT even if it's not available on the pattern + Fix a SIGSEGV on FcPatternGet* with NULL pattern + Bug 38737 - Wishlist: support FC_POSTSCRIPT_NAME + Minor cleanup + Bump libtool revision + Minor fix + +Behdad Esfahbod (12): + Resepct $NOCONFIGURE + Ensure we find the uninstalled fontconfig header + Copy all values from pattern to font if the font doesn't have the element + Minor + Bug 59379 - FC_PRGNAME + Remove unused checks for common functions + Minor + Fix fc-cache crash caused by looking up NULL object incorrectly + Fix FC_PRGNAME default + Fix readlink failure + Accept digits as part of OpenType script tags + Fix crash with FcConfigSetCurrent(NULL) + +Christoph J. Thompson (1): + Use the PKG_INSTALLDIR macro. + +Colin Walters (1): + build: Only use PKG_INSTALLDIR if available + +Quentin Glidic (2): + test: Use SH_LOG_COMPILER and AM_TESTS_ENVIRONMENT + Use LOG_COMPILER and AM_TESTS_ENVIRONMENT + +2.10.91 (2.11 RC1) + +Akira TAGOH (19): + Fix a potability issue about stdint.h + Fix build issues on clean tree + Do not show the deprecation warning if it is a symlink + Fix a typo + Fix the wrong estimation for the memory usage information in fontconfig + Remove the duplicate null-check + Remove the dead code + clean up + Fix a typo that accessing to the out of array + Fix a memory leak + Check the system font to be initialized + Missing header file for _mkdir declaration + Clean up the unused variable + Bug 47705 - Using O_CLOEXEC + missing header file to declare _mkdir + Fix a build fail on mingw + Fix a typo in the manpages template + Bug 29312 - RFE: feature to indicate which characters are missing to satisfy the language support + Update the date in README properly + +Behdad Esfahbod (73): + Fix typo + Parse matrices of expressions + Fix compiler warnings + Fix unused-parameter warnings + Fix more warnings + Fix sign-compare warnings + Fix warning + Fix more warnings + Fixup from 4f6767470f52b287a2923e7e6d8de5fae1993f67 + Remove memory accounting and reporting + Allow target="font/pattern/default" in elements + Don't warn if an unknown element is used in an expression + Unbreak build when FC_ARCHITECTURE is defined + Remove unneeded stuff + Enable fcarch assert checks even when FC_ARCHITECTURE is explicitly given + Make tests run on Windows + Initialize matrix during name parsing + Adjust docs for recent changes + Warn if appears in + Make FC_DBG_OBJTYPES debug messages into warnings + Refuse to set value to unsupported types during config too + Add NULL check + Don't crash in FcPatternDestroy with NULL pattern + Don't crash in FcPatternFormat() with NULL pattern + Minor + Whitespace + Deprecate FcName(Un)RegisterObjectTypes / FcName(Un)RegisterConstants + Use a static perfect hash table for object-name lookup + Switch .gitignore to git.mk + Remove shared-str pool + Fix build stuff + Add build stuff for threadsafety primitives + Add thread-safety primitives + Make refcounts, patterns, charsets, strings, and FcLang thread-safe + Make FcGetDefaultLang and FcGetDefaultLangs thread-safe + Make FcInitDebug() idempotent + Make FcDefaultFini() threadsafe + Refactor; contain default config in fccfg.c + Minor + Make default-FcConfig threadsafe + Minor + Make FcCacheIsMmapSafe() threadsafe + Minor + Make cache refcounting threadsafe + Add a big cache lock + Make random-state initialization threadsafe + Make cache hash threadsafe + Make FcDirCacheDispose() threadsafe + Make fcobjs.c thread-safe + Warn about undefined/invalid attributes during config parsing + Fixup fcobjs.c + Remove FcSharedStr* + Fix compiler warnings + Minor + Fix build and warnings on win32 + Use CC_FOR_BUILD to generate source files + Fix more warnings. + Trying to fix distcheck + Fix build around true/false + Work around Sun CPP + Really fix cross-compiling and building of tools this time + Second try to make Sun CPP happy + Ugh, add Tools.mk + Minor + Don't use blanks for fc-query + Remove FcInit() calls from tools + Add 10-scale-bitmap-fonts.conf and enable by default + Oops, add the actual file + Fix pthreads setup + Fix memory corruption! + Add pthread test + Add atomic ops for Solaris + Make linker happy + +Jon TURNEY (1): + Fix build when srcdir != builddir + +2.10.2 + +Akira TAGOH (13): + Bug 53585 - Two highly-visible typos in src/fcxml.c + Fix for libtoolize's warnings + Bug 54138 - X_OK permission is invalid for win32 access(..) calls + Bug 52573 - patch required to build 2.10.x with oldish GNU C library headers + deal with warnings as errors for the previous change + Fix wrongly squashing for the network path on Win32. + Fix syntax errors in fonts.dtd. + autogen.sh: Add -I option to tell aclocal a place for external m4 files + Use automake variable instead of cleaning files in clean-local + Bug 56531 - autogen.sh fails due to missing 'm4' directory + Bug 57114 - regression on FcFontMatch with namelang + Update CaseFolding.txt to Unicode 6.2 + Bug 57286 - Remove UnBatang and Baekmuk Batang from monospace in 65-nonlatin.conf + +Behdad Esfahbod (1): + Fix N'ko orthography + +Jeremy Huddleston Sequoia (1): + Remove _CONFIG_FIXUPS_H_ guards, so multiple includes of "config.h" result in the correct values + +2.10.1 + +Akira TAGOH (2): + Fix a typo in fontconfig.pc + Install config files first + +2.10.0 + +Akira TAGOH (5): + Bug 34266 - configs silently ignored if libxml2 doesn't support SAX1 interface + Update CaseFolding.txt to Unicode 6.1 + Fix a build fail with gcc 2.95, not supporting the flexible array members. + Bump libtool revision + Update INSTALL + +2.9.92 (2.10 RC2) + +Akira TAGOH (9): + Bug 50835 - Deprecate FC_GLOBAL_ADVANCE + Fix a typo and build fail. + Fix a build fail on MINGW + Fix the fail of make install with --disable-shared on Win32 + clean up the lock file properly on even hardlink-not-supported filesystem. + Rename configure.in to configure.ac + Bug 18726 - RFE: help write locale-specific tests + Bump libtool revision + Update INSTALL + +Marius Tolzmann (2): + Fix newline in warning about deprecated config includes + Fix warning about deprecated, non-existent config includes + +2.9.91 (2.10 RC1) + +Akira TAGOH (60): + [doc] Update the path for cache files and the version. + [doc] Update for cachedir. + Revert "Fix a build fail on some environment." + Revert "Fix a build fail on some environment" + Fix a build issue due to the use of non-portable variables + Get rid of the prerequisites from the sufix rules + Bug 39914 - Please tag the cache directory with CACHEDIR.TAG + fc-cache: improvement of the fix for Bug#39914. + fcmatch: Set FcResultMatch at the end if the return value is valid. + Bug 47703 - SimSun default family + Bug 17722 - Don't overwrite user's configurations in default config + Fix a memory leak in FcDirScanConfig() + Bug 17832 - Memory leaks due to FcStrStaticName use for external patterns + fcpat: Increase the number of buckets in the shared string hash table + Fix the hardcoded cache file suffix + Move workaround macros for fat binaries into the separate header file + Bug 48020 - Fix for src/makealias on Solaris 10 + Bug 24729 - [ne_NP] Fix ortho file + doc: Add contains and not_contains operators and elements + Use AC_HELP_STRING instead of formatting manually + Use pkgconfig to check builddeps + Bug 29341 - Make some fontconfig paths configurable + Bug 22862 - ignores s + Bug 26830 - Add search for libiconv non-default directory + Bug 28491 - Allow matching on FC_FILE + Bug 48573 - platform without regex do not have also REG_XXX defines + Bug 27526 - Compatibility fix for old windows systems + Add --with-expat, --with-expat-includes and --with-expat-lib back. + doc: Fix a typo of the environment variable name. + Bug 25151 - Move cleanCacheDirectory() from fc-cache.c into + Rework to avoid adding the unexpected value to ICONV_CFLAGS and ICONV_LIBS + Fix a build issue again when no regex functions available + C++11 requires a space between literal and identifier + Bug 47721 - Add ChromeOS fonts to 30-metric-aliases.conf + Create CACHEDIR.TAG when fc-cache is run or only when the cache directory is created at the runtime. + Add --enable-iconv option to configure + Bug 27765 - FcMatch() returns style in wrong language + Disable iconv support anyway... + Bug 39278 - make usage of mmap optional + Output more verbose debugging log to show where to insert the element into the value list + fonts.conf: keeps same binding for alternatives + fcarch.c: get rid of the duplicate definition of FC_MAX + Bug 19128 - Handling whitespace in aliases + Bug 20411 - fontconfig doesn't match FreeDesktop directories specs + Correct the example + Bug 33644 - Fontconfig doesn't match correctly in + fcatomic: fallback to create a directory with FcAtomicLock + Move statfs/statvfs wrapper to fcstat.c and add a test for the mtime broken fs + Fix the build fail on Solaris + Fix a typo and polish the previous change + Fix the wrong estimation for the memory usage information in fontconfig + Bug 32853 - Export API to get the default language + fcdefault: fallback if the environment variables are empty + Add the default language to the pattern prior to do build the substitution + fcdefault: no need to set FC_LANG in FcDefaultSubstitute() anymore + fcdefault: Add the lang object at FcConfigSubstituteWithPat() only when kind is FcMatchPattern + Bug 50525 - superfluous whitespace in the style + Bump libtool revision + doc: Fix distcheck error again... + Generate bzip2-compressed tarball too + +Jeremy Huddleston (1): + fcarch: Check for architecture signature at compile time rather than configure time + +Keith Packard (3): + Use posix_fadvise to speed startup + Extra ',' in AC_ARG_WITH(arch causes arch to never be autodetected + Deal with architectures where ALIGNOF_DOUBLE < 4 + +Mark Brand (1): + fix building for WIN32 + +Mikhail Gusarov (2): + Move FcStat to separate compilation unit + Fix cache aging for fonts on FAT filesystem under Linux + +2.9 + +Akira TAGOH (28): + Add charset editing feature. + add some document for range and charset. + Add the range support in blank element + Add editing langset feature. + add some documents + Bug 24744 - No n'ko orthography + Remove the unnecessary comment in ks.orth + Bug 32965 - Asturian (ast-ES) language matching missing ḷḷḥ + Add a missing file + Bug 35517 - Remove Apple Roman cmap support + Bug 40452 - Running 'fc-match --all' core dumps when no fonts are installed + Get rid of the unexpected family name + Bug 44826 - must contain only a single + Bug 46169 - Pointer error in FcConfigGlobMatch + Do not update stream->pos when seeking is failed. + Bug 27385 - lcdfilter settings for freetype-2.3.12 not available in fontconfig-2.8.0 + Add brx.orth and sat.orth + Bug 41694 - FcCache functions have random-number-generator side effects + Bug 23336 - unable to display bitmap-only (SFNT) TrueType or OpenType + Check null value for given object to avoid possibly segfaulting + Bug 19128 - Handling whitespace in aliases + Fix distcheck error + Update the version info + Update to detect the uncommited changes properly + Fix a build issue + Fix a build fail on some environment + Fix a build fail on some environment. + Get rid of $< from Makefile.am + +Alan Coopersmith (1): + Fix compiler warnings + +Behdad Esfahbod (54): + [fc-cache] Document -r argument in man page + [doc] Fix typo + Bug 25508 configure assumes bash > 2.0 is on system + Update INSTALL + Add note about autogen.sh to INSTALL + Fix doc typo + More doc typo fixes + Bug 18886 installation crashes if fontconfig already installed + Bug 26157 Solaris/Sun C 5.8: compilation of 2.8.0 and 2.7.3 fails + Bug 25152 Don't sleep(2) if all caches were uptodate + Don't include unistd.h in fontconfig.h + Accept TT_PLATFORM_MICROSOFT, TT_MS_ID_SYMBOL_CS from name table + Whitespace + More whitespace + Remove all training whitespaces + Fix comment + Add fc-pattern cmdline tool + Bug 29338 - fc-pattern.sgml, open para tag + Add comments + Bug 29995 - fc-cat does not invoke FcFini() + Add new public API: FcCharSetDelChar() + [fc-lang] Support excluding characters + Bug 24729 - [ne_NP] Fix ortho file + Add more copyright owners + Cleanup copyright notices to replace "Keith Packard" with "the author(s)" + Fix returned value + Bug 28958 - lang=en matches other langs + Make most generated-files cross-compiling-safe + Make fc-arch stuff cross-compiling-safe + Bump version + Allow editing charset and lang in target="scan" + Add support for into the DTD + Skip elements with begin > end + Doc nit + Fix assertion failure on le32d4 + Remove AM_MAINTAINER_MODE + Update CaseFolding.txt to Unicode 6.0 + Remove --enable-maintainer-mode from autogen.sh + Bug 20113 - Uighur (ug) orthography incomplete + Bug 30566 - fcformat.c:interpret_enumerate() passes uninitialized idx to FcPatternGetLangSet() + Mark constant strings as constant + More doc typo fixes + Always define FcStat as a function + Fix warning + Bug 35587 - Add padding to make valgrind and glibc not hate each other + [.gitignore] Update + Bug 36577 - Updating cache with no-bitmaps disables bitmap fonts... + Bug 26718 - "fc-match sans file" doesn't work + Switch fc-match to use FcPatternFormat() + Switch fc-cat to use FcPatternFormat() + Fix stupid bug in FcFontSort() + Bug 41171 - Invalid use of memset + Fix parallel build + Add FcPublic to FcLangSetUnion and FcLangSetSubtract + +Brad Hards (1): + Documentation fixes + +Jeremy Huddleston (2): + fontconfig.pc: Add variables for confdir and cachedir + fontconfig.pc.in: Add sysconfdir, localstatedir, and PACKAGE + +Jinkyu Yi (1): + Bug 42423 - make default Korean font from Un to Nanum + +MINAMI Hirokazu (1): + Bug 43406 - typo of Japanese font name in conf.d/65-nonlatin.conf + +Mike Frysinger (9): + FcStrPlus: optimize a little + delete unused variables + FcStat: change to FcChar8 for first arg + fc-cat: fix pointer warning + FcName{,Get}Constant: constify string input + fc-{list,match}: constify format string + fix build warnings when using --with-arch + FcObjectValidType: tweak -1 checking + makealias: handle missing funcs better + +Parag Nemade (2): + Bug 25651 - Add ortho file for locale brx_IN + Bug 25650 - Add ortho file for locale sat_IN + +Pravin Satpute (4): + Bug 27195 - need updates to ks.orth file + Bug 43321 - Required corrections in urdu.orth file + Bug 25653 - Add ortho file for locale doi_IN + Bug 25652 - Add ortho file for locale mni_IN + +2.8 + +Behdad Esfahbod (24): + Clarify default confdir and cachedir better. + Move FcAlign to fcint.h + [fc-arch] Add FcAlign to arch signature + [int] Define MIN/MAX/ABS macros + Bump cache version up from 2 to 3 and fix FcLangSet caching/crash + Remove unused macros + [int] Remove fc_storage_type() in favor of direct access to v->type + [int] Remove fc_value_* macros that did nothing other than renaming + Enable automake silent rules + [int] Remove more unused macros + [xml] Remove unused code + [arch] Try to ensure proper FcLangSet alignment in arch + [lang] Fix serializing LangSet from older versions + Make sure fclang.h and fcarch.h are built + Remove bogus comment + [fc-glyphname] Cleanup Makefile.am + [src] Create fcglyphname.h automatically + [fc-glyphname] Rename internal arrays to prefix with _fc_ + Clean up Makefile's a bit + [fc-glyphname] Remove Adobe glyphlist + [fc-case] Update CaseFolding.txt to Unicode 5.2.0 + [fc-arch] Beautify the arch template + [fc-arch] Rename architecture names to better reflect what they are + Bump libtool revision in preparation for release + +2.7.3 + +Behdad Esfahbod (2): + Use default config in FcFileScan() and FcDirScan() + Bump libtool version in preparation for release + +Roozbeh Pournader (2): + Correct Ewe (ee) orthography to use U+025B (bug #20711) + Updated Arabic, Persian, and Urdu orthographies + +2.7.2 + +Behdad Esfahbod (6): + Improve charset printing + [ja.orth] Comment out FULLWIDTH YEN SIGN (#22942) + Bug 22037 - No Fonts installed on a default install on Windows Server 2003 + Bug 23419 - "contains" expression seems not working on the fontconfig rule + Revert "Fix FcNameUnparseLangSet()" and redo it + Bump libtool version for release + +Tor Lillqvist (3): + Fix MinGW compilation + Fix heap corruption on Windows in FcEndElement() + Use multi-byte codepage aware string function on Windows + +2.7.1 + +Behdad Esfahbod (16): + git-tag -s again + Fix win32 build + Replace spaces with tabs in conf files + Remove unused ftglue code + Add Inconsolata to monospace config (#22710) + Fix leak with string VStack objects + Improve libtool version parsing (#22122) + Use GetSystemWindowsDirectory() instead of GetWindowsDirectory() (#22037) + Remove unused macros + Fix FcNameUnparseLangSet() + Fix doc syntax (#22902) + TT_MS_ID_UCS_4 is really UTF-16BE, not UTF-32 + [doc] Add ~/fonts.conf.d to user docs + Hardcode /etc/fonts instead of @CONFDIR@ in docs (#22911) + Bump libtool versions that 2.7.0 (I forgot to do back then) + Update .gitignore + +Karl Tomlinson (1): + Don't change the order of names unnecessarily (#20128) + +2.7 + +Alexey Khoroshilov (1): + Use human-readable file names in the docs (bug #16278) + +Behdad Esfahbod (119): + Avoid C99ism in Win32 code (#16651) + [doc] Fix inaccuracy in FcFontRenderPrepare docs (#16985) + When canonizing filenames, squash // and remove final / (#bug 16286) + Add orth file for Maithili mai.orth (#15821) + Replace RCS Id tags with the file name + [doc] Fix signatures of FcPatternGetFTFace and FcPatternGetLangSet (#16272) + Update Thai default families (#16223) + Add ~/.fonts.conf.d to default config (#17100) + [fc-match] Fix list of getopt options in --help + Update man pages + Add fc-query (#13019) + Implement fc-list --verbose (#13015) + [doc] Add const decorator for FcPatternDuplicate() + Add FcPatternFilter() (#13016) + [doc] Document that a zero rescanInterval disables automatic checks (#17103) + Get rid of $Id$ tags + [doc] Fix signature of FcConfigHome() + Fix docs re 'orig' argument of FcPatternBuild and family + Update sr.orth to actul subset of Cyrillic used by Serbian (#17208) + Add Sindhi .orth file. (#17140) + Add WenQuanYi fonts to default conf (#17262, from Mandriva) + Handle -h and --help according to GNU Coding Standards (#17104) + Document when config can be NULL (#17105) + Add FcConfigReference() (#17124) + Document how to free return value of FcNameUnparse() + Don't leak FcValues string loaded through fcxml.c (#17661) + Don't call FcPatternGetCharSet in FcSortWalk unless we need to (#17361) + Fix two more doc typos + [.gitignore] Update + Cleanup symlinks in "make uninstall" (bug #18885) + [fccache] Consistently use FcStat() over stat() (bug #18195) + Consistently use FcStat() over stat() in all places + Use __builtin_popcount() when available (bug #17592) + Fix compile with old FreeType that doesn't have FT_Select_Size() (bug #17498) + Implement fc-list --quiet ala grep (bug #17141) + [65-fonts-persian.conf] Set foundry in target=scan instead of target=font + Don't use identifier named complex + Explicitly chmod() directories (bug #18934) + Remove special-casing of FC_FILE in FcPatternPrint() + [.gitignore] Update + Implement FcPatternFormat and use it in cmdline tools (bug #17107) + Fix comparison of family names to ignore leading space properly + [fcmatch.c] Fix debug formatting + [fcmatch] Use larger multipliers to enforce order + [fcmatch] When matching, reserve score 0 for when elements don't exist + [fcmatch] Move FcFontSetMatch() functionality into FcFontSetMatchInternal() + [doc] Note that fontset returned by FcConfigGetFonts should not be modified + Make FcCharSetMerge() public + Don't use FcCharSetCopy in FcCharSetMerge + Oops. Fix usage output. + Revive FcConfigScan() (bug #17121) + Add fc-scan too that runs FcFileScan/FcDirScan + Oops, fix FcPatternFilter + [fc-match] Accept list of elements like fc-list (bug #13017) + Cleanup all manpage.* files + [fcmatch] Fix crash when no fonts are available. + [fcfreetype] Fix typo in GB2312 encoding name string (#19845) + Add ICONV_LIBS to fontconfig.pc.in (#19606) + [win32] Fix usage of GetFullPathName() + [win32] Expand "APPSHAREFONTDIR" to ../share/fonts relative to binary location + [win32] Do not remove leading '\\' such that network paths work + [fccache] Make sure the cache is current when reusing from open caches + Update Sinhala orthography (#19288) + [cache] After writing cache to file, update the internal copy to reflect this + Further update Sinhala orthography (#19288) + [fcformat] Add support for width modifiers + [fcformat] Refactor and restructure code for upcoming changes + [fcformat] Add support for subexpressions + [fcformat] Add element filtering and deletion + [fcformat] Add conditionals + [fcformat] Add simple converters + [fcformat] Implement 'cescape', 'shescape', and 'xmlescape' converters + [FcStrBuf] better handle malloc failure + [fcformat] Add value-count syntax + [fcformat] Implement 'delete', 'escape', and 'translate' filter functions + [fcformat] Start adding builtins + [fcformat] Refactor code to avoid malloc + [fcformat] Add support for builtin formats + [fcformat] Support indexing simple tags + [fcformat] Support 'default value' for simple tags + [fcformat] Implement array enumeration + [fclang] Implement FcLangSetGetLangs() (#18846) + [fcformat] Enumerate langsets like we do arrays of values + [fcformat] Add a 'pkgkit' builtin that prints tags for font packages + [fcformat] Add list of undocumented language features + [fc-lang] Continue parsing after an "include" (#20179) + Fix Fanti (fat) orth file (#20390) + Fix Makefile's to not create target file in case of failure + [fcstr.c] Embed a static 64-byte buffer in FcStrBuf + [fcstr,fcxml] Don't copy FcStrBuf contents when we would free it soon + [fcxml] Don't allocate attr array if there are no attributes + [fcxml] Embed 8 static FcPStack objects in FcConfigParse + [fcxml] Embed 64 static FcVStack objects in FcConfigParse + [fcxml.c] Embed a static 64-byte attr buffer in FcPStack + Call git tools using "git cmd" instead of "git-cmd" syntax + Replace 'KEITH PACKARD' with 'THE AUTHOR(S)' in license text in all files + [fcformat] Fix default-value handling + Document FcPatternFormat() format + [Makefile.am] Don't clean ChangeLog in distclean + Revert "[conf] Disable hinting when emboldening (#19904)" (#20599) + [fc-lang] Fix bug in country map generation + [fcstr] Remove unused variable + [fc-lang] Make LangSet representation in the cache files stable + [fc-cache] Remove obsolete sentence from man page + Detect TrueType Collections by checking the font data header + Mark matchers array const (#21935) + Use/prefer WWS family/style (name table id 21/22) + Simplify FcValueSave() semantics + Add XXX note about Unicode Plane 16 + Always set *changed in FcCharsetMerge + [charset] Grow internal FcCharset arrays exponentially + Remove unused prototypes and function + [xml] Centralize FcExpr allocation + [xml] Mark more symbols static + [xml] Allocate FcExpr's in a pool in FcConfig + [xml] Intern more strings + Bug 22154 -- fontconfig.pc doesn't include libxml2 link flags + Fix distcheck + Remove keithp's GPG key id + +Benjamin Close (1): + Remove build manpage logfile if it exists + +Chris Wilson (1): + Reduce number of allocations during FcSortWalk(). + +Dan Nicholson (1): + Let make expand fc_cachedir/FC_CACHEDIR (bug #18675) + +Harald Fernengel (1): + Don't use variables named 'bool' (bug #18851) + +Harshula Jayasuriya (1): + Fix Sinhala coverage (bug #19288) + +Karl Tomlinson (1): + Change FcCharSetMerge API + +Mike FABIAN (1): + [conf] Disable hinting when emboldening (#19904) + +Peter (1): + Make sure alias files are built first (bug 16464) + +Rahul Bhalerao (1): + Add config for new Indic fonts (bug #17856) + +Roozbeh Pournader (60): + Correct Sindhi orthography to use Arabic script (bug #17140) + Remove Sinhala characters not in modern use (bug #19288) + Add Filipino orth, alias Tagalog to Filipino (bug #19846) + Split Mongolian orth to Mongolia and China (bug #19847) + Fix doubly encoded UTF-8 in comments (bug #19848) + Change Turkmen orth from Cyrillic to Latin (bug #19849) + Rename Venda from "ven" to "ve" (bug #19852) + Rename "ku" to "ku_am", add "ku_iq" (bug #19853). + Add Kashubian (csb) orth file (bug #19866) + Add Malay (ms) orthography (bug #19867) + Add Kinyarwanda (rw) orthography (bug #19868) + Add Upper Sorbian (hsb) orthography (bug #19870) + Add Berber orthographies in Latin and Tifinagh scripts (bug #19881) + Renamed az to az_az (bug #19889) + Rename Igbo from "ibo" to "ig" (bug #19892) + Remove punctuation symbols from Asturian orthography (bug #19893) + Add Chhattisgarhi (hne) orthography (bug #19891) + Use newly added Cyrillic letters for Kurdish (bug #20049) + Add Kurdish in Turkey (ku_tr) orthography (bug #19891) + Add Aragonese (an) orthography (bug #19891) + Add Haitian Creole (ht) orthography (bug #19891) + Ad Ganda (lg) orthography (bug #19891) + Add Limburgan (li) orthography (bug #19891) + Add Sardinian (sc) orthography (bug #19891) + Add Sidamo (sid) and Wolaitta (wal) orthographies (bug #19891) + Fix Bengali (bn) and Assamese (as) orthographies (bug #22924) + Remove Euro Sign from all orthographies (bug #19865) + Add Ottoman Turkish (ota) orthography (bug #20114) + Divide Panjabi (pa) to that of Pakistan and India (bug #19890) + Add Blin (byn) orthography (bug #19891) + Add Papiamento (pap_aw, pap_an) orthographies (bug #19891) + Add Crimean Tatar (crh) orthography (bug #19891) + Switch Uzbek (uz) orthography to Latin (bug #19851) + Update Azerbaijani in Latin (az_az) to present usage (bug #20173) + Rename Avaric orthography from 'ava' to 'av' (bug #20174) + Rename Bambara orthography from 'bam' to 'bm' (bug #20175) + Rename Fulah orthography from 'ful' to 'ff' (bug #20177) + Change Kashmiri (ks) orthography to Arabic script (bug #20200) + Tighten Central Khmer (km) orthography (bug #20202) + Remove digits and symbols from some Indic orthographies (bug #20204) + Add Divehi (dv) orthography (bug #20207) + Extend Crimean Tatar (crh) orthography (bug #19891) + Update Serbo-Croatian (sh) orthography (bug #20368) + Add Ewe (ee) orthography (bug #20386) + Add Herero (hz) orthograhy (bug #20387) + Add Akan (ak) and Fanti (fat) orthographies (bug #20390) + Added Quechua (qu) orthography (bug #20392) + Add Sango (sg) orthography (bug #20393) + Add Tahitian (ty) orthography (bug #20391) + Add Navajo (nv) orthography (bug #20395) + Add Rundi (rn) orthography (bug #20398) + Add Zhuang (za) orthography (bug #20399) + Add orthographies for Oshiwambo languages (bug #20401) + Add Shona (sn) orthography (bug #20394) + Add Sichuan Yi (ii) orthography (bug #20402) + Add Javanese (jv) orthography (bug #20403) + Add Nauru (na) orthography (bug #20418) + Add Kanuri (kr) orthography (bug #20438) + Add Sundanese (su) orthography (bug #20440) + Reorganize Panjabi/Punjabi and Lahnda orthographies (bug #19890) + +Serge van den Boom (1): + Correctly handle mmap() failure (#21062) + +2.6 + +2.5.93 (2.6 RC3) + +Alexey Khoroshilov (1): + Fix FcStrDirname documentation. (bug 16068) + +Behdad Esfahbod (1): + Persian conf update. (bug 16066). + +Evgeniy Stepanov (1): + Fix index/offset for 'decorative' matcher. Bug 15890. + +Glen Low (1): + Fix Win32 build error: install tries to run fc-cache locally (bug 15928). + +Keith Packard (8): + Call FcFini to make memory debugging easier + Fix a few memory tracking mistakes. + Add extended, caps, dunhill style mappings. + Freetype 2.3.5 (2007-jul-02) fixes indic font hinting. re-enable (bug 15822) + Add a copy of dolt.m4 to acinclude.m4. + Libs.private needs freetype libraries + Oops. Fix for bug 15928 used wrong path for installed fc-cache. + Ignore empty elements + +Neskie Manuel (1): + Add Secwepemctsin Orthography. Bug 15996. + +Sayamindu Dasgupta (1): + FcConfigUptoDate breaks if directory mtime is in the future. Bug 14424. + +2.5.92 (2.6 RC2) + +Carlo Bramini (1): + Add FreeType-dependent functions to fontconfig.def file. (bug 15415) + +Changwoo Ryu (1): + Korean font in the default config - replacing baekmuk with un (bug 13569) + +Dennis Schridde (1): + Proper config path for static libraries in win32 + +Eric Anholt (1): + Fix build with !ENABLE_DOCS and no built manpages. + +Frederic Crozat (1): + Merge some of Mandriva configuration into upstream configuration. Bug 13247 + +Keith Packard (11): + Use DOLT if available + Work around for bitmap-only TrueType fonts that are missing the glyf table. + Remove size and dpi values from bitmap fonts. Bug 8765. + Add some sample cursive and fantasy families. + Add --all flag to fc-match to show the untrimmed list. Bug 13018. + Remove doltcompile in distclean + Use of ":=" in src/Makefile.am is unportable (bug 14420) + Make fc-match behave better when style is unknown (bug 15332) + Deal with libtool 2.2 which doesn't let us use LT_ variables. (bug 15692) + Allow for RC versions in README update + git ignore doltcompile + +Ryan Schmidt (1): + fontconfig build fails if "head" is missing or unusable (bug 14304) + +Sylvain Pasche (1): + Fontconfig options for freetype sub-pixel filter configuration + +2.5.91 (2.6 RC1) + +Hongbo Zhao (1): + Not_contain should use strstr, not strcmp on strings. (bug 13632) + +Keith Packard (11): + Move conf.avail/README to conf.d/README (bug 13392) + Fix OOM failure case in FcPStackPush. + Remove freetype requirement for build-time applications. + Include fcftaliastail.h so that the freetype funcs are exported. + Eliminate references to freetype from utility Makefile.am's + Distribute new fcftint.h file + Create new-version.sh to help with releases, update INSTALL instructions + Distribute khmer font aliases + Add more files to .gitignore + new-version.sh was mis-editing files + git-tag requires space after -m flag + +2.5 + +Keith Packard (4): + Document several function return values (Bug 13145). + Document that Match calls FcFontRenderPrepare (bug 13162). + Document that FcConfigGetFonts returns the internal fontset (bug 13197) + Revert "Remove fcprivate.h, move the remaining macros to fcint.h." + +Tor Lillqvist (1): + Workaround for stat() brokenness in Microsoft's C library (bug 8526) + +2.4.92 (2.5 RC2) + +Behdad Esfahbod (14): + Make fc-match --sort call FcFontRenderPrepare. + Port fonts-persian.conf to new alias syntax with binding="same" + Fix trivial bugs in edit-sgml.c + Add FcGetLangs() and FcLangGetCharSet(). + Add/update config files from Fedora. + Split 40-generic.conf into 40-nonlatin.conf and 45-latin.conf + Use binding="same" in 30-urw-aliases.conf and remove duplicate entries. + Remove redundant/obsolete comments from conf files. + Remove 20-lohit-gujarati.conf. It's covered by 25-unhint-nonlatin.conf now. + Oops, fix Makefile.am. + Remove 25-unhint-nonlatin.conf from default configuration by not linking it. + Fix documented conf-file naming format in README + Remove list of available conf files from README. + Simplify/improve 30-metric-aliases.conf + +Keith Packard (25): + Also check configDirs mtimes in FcConfigUptoDate + Respect "binding" attribute in entries. + Correct documentation for FcAtomicLock (Bug 12947). + Remove fcprivate.h, move the remaining macros to fcint.h. + Correct documentation for FcConfigUptoDate (bug 12948). + Document skipping of fonts from FcFileScan/FcDirScan. + Make file_stat argument to FcDirCacheLoadFile optional. + Clean up exported names in fontconfig.h. + Track line numbers in sgml edit tool input. + Typo error in function name: Inverval -> interval + Don't check cache file time stamps when cleaning cache dir. + Use FcLangDifferentTerritory instead of FcLangDifferentCountry. + Verify documentation covers exposed symbols. + Document previously undocumented functions. (bug 12963) + Update documentation for FcStrCopyFilename (bug 12964). + Update documentation for stale FcConfigGetConfig function. + Have FcConfigSetCurrent accept the current configuration and simply return + Remove references to FcConfigParse and FcConfigLoad. + Replace incorrect documentation uses of 'char' with 'FcChar8' (bug 13002). + Fix formatting syntax in doc/fccache.fncs + Generate fccache.sgml, fcdircache.sgml and fclangset.sgml. + Formatting syntax mistake in doc/fclangset.fncs. + Link new function documentation into the fontconfig-devel.sgml + Ignore new generated documentation + Export FcConfig{G,S}etRescanInverval from .so, mark as deprecated. + +2.4.91 (2.5 RC1) + +Behdad Esfahbod (1): + Update CaseFolding.txt to Unicode 5.1.0 + +Dwayne Bailey (1): + Add/fix *.orth files for South African languages + +Hideki Yamane (1): + Handle Japanese fonts better. (debian bug #435971) + +Keith Packard (32): + rehash increment could be zero, causing rehash infinite loop. + Work around FreeType bug when glyph name buffer is too small. + Free temporary string in FcDirCacheUnlink (Bug #11758) + Fix ChangeLog generation to avoid circular make dependency + Store font directory mtime in cache file. + Comment about mmaping cache files was misleading. + Make FC_FULLNAME include all fullname entries, elide nothing. [bug 12827] + Remove unneeded call to access(2) in fc-cache. + Improve verbose messages from fc-cache. + Verbose message about cleaning directories was imprecise + Don't use X_OK bit when checking for writable directories (bug 12438) + Have fc-cache remove invalid cache files from cache directories. + FcConfigParseAndLoad doc was missing the last param. + Place language name in constant array instead of pointer. + Must not insert cache into hash table before completely validating. + Eliminate relocations for glyph name table. + Eliminate relocations from FcCodePageRange structure (bug 10982). + Leave generated headers out of distribution (bug 12734). + Move elements to the end of fonts.conf. + Add BRAILLE PATTERN BLANK to list of blank glyphs. + Replace makealias pattern with something supported by POSIX grep (bug 11083) + FcInit should return FcFalse when FcInitLoadConfigAndFonts fails. (bug 10976) + There is no U+1257 (bug 10899). + Spelling errors in documentation. (bug 10879). + Oops. Left debugging printf in previous commit. + Handle UltraBlack weight. + Fix parallel build in fontconfig/docs (bug 10481). + Distribute man source files for command line programs (bug 9678). + Ensure weight/slant values present even when style is supplied (bug 9313). + fontconfig needs configure option to use gnu iconv (bug 4083). + Match 'ultra' on word boundaries to detect ultra bold fonts. (bug 2511) + Build fix for Solaris 10 with GCC. + +Mike FABIAN (1): + Avoid crashes if config files contain junk. + +Stephan Kulow (1): + Make FcPatternDuplicate copy the binding instead of always using Strong. + +Tilman Sauerbeck (2): + Store FcNoticeFoundries in read-only memory. + Store FcVendorFoundries in read-only memory. + +2.4.2 + +Han-Wen Nienhuys: + FcStrCanonFileName buggy for mingw. (bug 8311) + More fixes for Win32 building (bug 8311) + +Kean Johnston: + Don't use varargs CPP macros in fccache.c. (bug 8733) + +Keith Packard: + Remove documentation for non-existant FcConfigNormalizeFontDir. + Build fontconfig.def from header files when needed. + Detect and use available random number generator (bug 8308) + Add sparc64 architecture string. + FcStrCanonAbsoluteFilename should be static. + Use explicit platform/nameid order when scanning ttf files. + Warn (and recover) from config file without elements. + Avoid writing uninitialized structure pad bytes to cache files. + Fix grep pattern in makealias to work on non-Gnu grep (bug 8368). + Add FcFreeTypeQueryFace external API. Bug #7311. + Segfault scanning non-font files. Disallow scan edit of user vars. (#8767) + Add space between type and formal in devel man pages (bug 8935) + +Mike FABIAN: + Do not clean cache files for different architectures + +Peter Breitenlohner: + A VPATH build of fontconfig-2.4.1 fails for various reasons. Bug 8933. + Use instead of when documenting fonts.conf. Bug 8935. + Fix fc-cat documentation (bug 8935). + + +2.4.1 + +Keith Packard: + Update installation notes for 2.4 base. + Add ppc64 signature. Bug 8227 + Add signatures for m68k and mipsel (thanks debian buildd) + Add warning flags to fc-cache build. Clean up warnings in fc-cache. + Reimplement FcConfigAppFontAddDir; function was lost in 2.4.0. + +2.4.0 + +David Turner: + Replace character discovery loop with simpler, faster version. + +James Cloos: + Move files from conf.d to conf.avail + Standardize conf.avail number prefixing convention + Support all five possibilities for sub-pixel + Move user and local conf file loading into conf.avail files + Number the remaining conf.avail files + Update Makefile.am to match conf.avail changes + Replace load of conf.d in fonts.conf.in + Make room for chunks from fonts.conf in conf.avail + Re-order old conf.d files + Move some section from fonts.conf into conf.avail files + Update Makefile.am files + Make conf.avail and conf.d work + +Keith Packard: + Create fc_cachedir at install time. Bug 8157. + Reference patterns in FcCacheCopySet. + Replace gnu-specific sed command with simple grep. + Attempt to fix makealias usage for build on Mac OS X. + Accept locale environment variables that do not contain territory. + Merge branch 'jhcloos' + Insert newly created caches into reference data structure. + Add XML headers to new conf files. Move link make commands to conf.avail dir + Rename conf.avail to conf.d + Fix conf.d directory sorting. + Include cachedir in fonts.dtd. + Don't display tests for DESTDIR on make install. + Split much of the configuration into separate files. Renumber files + +2.3.97 + +Carl Worth: + Rename FcPatternThawAll to FcPatternFini. + Add a configuration file that disables hinting for the Lohit Gujarati font + +Keith Packard: + Various GCC 4 cleanups for signed vs unsigned char + Finish INSTALL changes. .gitignore ChangeLog + Merge branch 'fc-2_4_branch' to master + Remove all .cvsignore files + Hide private functions in shared library. Export functionality for utilities. + Hide FreeType glue code from library ABI. + Can't typecheck values for objects with no known type. + Leave cache files mapped permanently. + Reference count cache objects. + Make cache reference counting more efficient. + Oops, fc-lang broke when I added cache referencing. + Correct reference count when sharing cache file objects. + Eliminate .so PLT entries for local symbols. (thanks to Arjan van de Ven) + Update architecture signatures for x86-64 and ppc. + Parallel build fix for fcalias.h and fcaliastail.h + Charset hashing depended on uniqueness of leaves. + +Patrick Lam: + file Makefile.am was initially added on branch fc-2_4_branch. + Modify config file to use Greek fonts before Asian fonts with Greek glyphs. + Use libtool -no-undefined flag on all platforms. + file ftglue.c was initially added on branch fc-2_4_branch. + 2005-11-23 Frederic Crozat : reviewed by: plam + file 10-fonts-persian.conf was initially added on branch fc-2_4_branch. + Sort directory entries while scanning them from disk; prevents Heisenbugs + file ln.orth was initially added on branch fc-2_4_branch. + Fix typos in orth files. Reported by Denis Jacquerye. + On Windows, unlink before rename. Reported by Tim Evans. + file fc-match.sgml was initially added on branch fc-2_4_branch. + +2.3.96 + +Keith Packard: + Make path names in cache files absolute (NB, cache format change) Stop + Eliminate pattern freezing + Add .gitignore + Construct short architecture name from architecture signature. + Write caches to first directory with permission. Valid cache in FcDirCacheOpen. + Eliminate NormalizeDir. Eliminate gratuitous stat/access calls per dir. + Add architecture to cache filename. + Eliminate global cache. Eliminate multi-arch cache code. + Fix up fc-cache and fc-cat for no global cache changes. + Eliminate ./ and ../ elements from font directory names when scanning. + Regenerate x86 line in fcarch.tmpl.h to match change in cache data. + Add x86-64 architecture and signature. + During test run, remove cache directory to avoid stale cache usage. + Add ppc architecture + Revert to original FcFontSetMatch algorithm to avoid losing fonts. + Rework cache files to use offsets for all data structures. + Fix build problems caused by cache rework. + FcCharSetSerialize was using wrong offset for leaves. Make fc-cat work. + Rework Object name database to unify typechecking and object lookup. + Skip broken caches. Cache files are auto-written, don't rewrite in fc-cache. + Fix fc-cat again. Sigh. + Use intptr_t instead of off_t inside FcCache structure. + Serialized value lists were only including one value. + Automatically remove invalid cache files. + With no args, fc-cat now dumps all directories. + Revert ABI changes from version 2.3 + Change $(pkgcachedir) to $(fc_cachedir) in fc-cat and fc-cache Makefile.am + Allow FcTypeLangSet to match either FcTypeLangSet or FcTypeString. + Remove stale architecture signatures. + Pass directory information around in FcCache structure. Freeze charsets. + Fix fc-lang to use new charset freezer API. + Fontset pattern references are relative to fontset, not array. + Add some ignores + Only rebuild caches for system fonts at make install time. + Fix memory leaks in fc-cache directory cleaning code. + Add @EXPAT_LIBS@ to Libs.private in fontconfig.pc (bug 7683) + Avoid #warning directives on non-GCC compilers. (bug 7683) + Chinese/Macau needs the Hong Kong orthography instead of Taiwan (bug 7884) + Add Assamese orthography (as.orth). Bug #8050 + Really only rebuild caches for system fonts at make install time. + Fonts matching lang not territory should satisfy sort pattern lang. + Prefer Bitstream Vera to DejaVu families. + Guess that mac roman names with lots of high bits are actually SJIS. + Document FC_DEBUG values (bug 6393). Document name \ escape syntax. + Move Free family names to bottom of respective aliases. (bug 7429) + Unify directory canonicalization into FcStrAddFilename. + Allow font caches to contain newer version numbers + Add FcMatchScan to resolve Delicious font matching issues (bug #6769) + Fix missing initialization/destruction of new 'scan' target subst list. + Don't segfault when string values can't be parsed as charsets or langsets. + Using uninitialized (and wrong) variable in FcStrCopyFilename. + Oops; missed the 60-delicious.conf file. + +Patrick Lam: + Keith Packard + 2006-04-27 Paolo Borelli (pborelli@katamail.com) reviewed by: plam + 2006-05-31 Yong Li (rigel863@gmail.com) reviewed by: plam, Bedhad Esfahbod + 2006-07-19 Jon Burgess (jburgess@uklinux.net) reviewed by: plam + 2006-08-04 Keith Packard (keithp@keithp.com) reviewed by: plam + +2.3.95 + +Match 'Standard Symbols L' for 'Symbol'. Add URW fonts as aliases for +all of the PostScript fonts. (reported by Miguel Rodriguez). Fix a +number of Coverity defects (Frederic Crozat). Speed up FcFontSort +(fix suggested by Kenichi Handa). Fix error with charsets. Survive +missing docbook2pdf. Compile on HP-UX, AIX, SGI and Windows (Cygwin, +MinGW). Fix intel compiler warnings. Fix multiarch support (don't +destroy multiarch files!) Require pkg-config. (Thanks Behdad; better +solution wanted for libxml2 detection!) Fix typos in orth files and +add orth for Lingala (reported by Denis Jacquerye). Remove debian/ +directory. Add a configuration file that disables hinting for the +Lohit Gujarati font (since the hinting distorts some glyphs quite +badly). Sort directory entries while scanning them from disk; +prevents Heisenbugs due to file ordering in a directory (due to Egmont +Koblinger). Fix Wine's problem with finding fonts. (Reported by +Bernhard Rosenkraenzer.) Fix the issues with GNU libiconv vs. libc +iconv (which especially appear on Solarii); patch by Behdad Esfahbod, +approach suggested by Tim Mooney. + +2.3.94 + +fc-cat can take directories as input and creates old-style fonts.cache +listings. +fc-cache takes -r --really-force which blows away all old caches and +regenerates. +Robustness fixes, integer overflow fixes (notably to cache handling +code), toast broken global cache files. +Change binary format to make it compatible with static langset +information (thanks to Takashi Iwai). +Open hashed caches before fonts.cache-2 (Takashi Iwai). +Fix FcFontSetMatch's algorithm, which used to unjustly kill fonts for +not declaring certain elements (Takashi Iwai). +Fix matching bug when multiple elements match; don't use +the sum of all scores, but the best score (James Su). +Make fc-lang more friendly to Windows systems. +Remove archaic chars from Georgian charset; add Euro character to +charsets for European languages. +Fix treatment of broken PCF fonts that don't declare family names. +Pass O_BINARY to open if appropriate (reported by Doodle). +Normalize font directories to the form in which they appear in +config files. +Add a record of the cached directory to the cache file. +Perf optimizations (Dirk Mueller; some reported by Michael Meeks.) +Don't loop infinitely on recursive symlinks. +Make 'make distcheck' work with automake 1.6.3. +Replace 'stamp' target with mkinstalldirs. +Don't stop scanning if a directory in fonts.conf doesn't exist, +because subsequent directories might exist. +Put directory names into global cache (reported by Ronny V. Vindenes). +Treat zh-hk fonts differently from zh-tw fonts. This patch may cause +fontconfig to treat A-X fonts differently from A-Y fonts; please mail +the fontconfig list if this causes any problems. +Fix for unaligned memory accesses (Andreas Schwab). +Fix treatment of cache directory as read from cache file; don't use +string equality to determine if we have the right file, use inode +equality. +Properly skip past dir caches that contain zero fonts, as occurs +in global caches (reported by Mike Fabian). +Print out full pathname in fc-match -v (reported by Frederic Crozat). +Fix bug where fc-match crashes when given __DUMMY__ property to +match on. + +2.3.93 + +Create cache files in /var/cache/fontconfig with hashed filenames, if +possible, for added FHS compliance. +Make fc-cat read both per-directory and global cache files. +Add config file for Persian fonts from Sharif FarsiWeb, Inc. +Major performance improvements by Dirk Mueller, Stephen Kulow, and Michael Matz at SuSE: in particular, speed up FcFontSetMatch, and inline many functions. +Fix treatment of globs in config files, broken since 2.3.2 and discovered by Mathias Clasen. +Don't use freetype internal headers (patch by Matthias Clasen). +Further space improvements: create langsets statically, so that they can live in .rodata. +Properly align mmapped data structures to make e.g. ia64 happy. +Bug fixes. + +2.3.92 + +Fix corrupted caches bugs from 2.3.91 (reported by Mike Fabian). +Store only basename in the cache, reconstitute on demand +(reported by James Cloos). +Change the rule for artificial emboldening in fonts.conf.in. This +enables the support for artificial emboldening included in cairo +(patch by Zhe Su). +Add FC_EMBEDDED_BITMAP object type to tell Xft/Cairo whether +to load embedded bitmaps or not (patch by Jinghua Luo). +Fix GCC4 warnings (some by Behdad Esfahbod). +Support localized font family and style names; this has been reported +to break old apps like xfd, but modern (gtk+/qt/mozilla) apps work +fine (patch by Zhe Su). +Prevent fc-list from escaping strings when printing them (reported by +Matthias Clasen). +Add valist sentinel markup for FcObjectSetBuild and +FcPatternBuild (patch by Marcus Meissner). +Add consts to variables so as to move arrays into .rodata (patch by +Ross Burton). +Modify config file to use Greek fonts before Asian fonts with +Greek glyphs. (patch by Simos Xenitellis). +Use libtool -no-undefined flag on all platforms (patch by Christian +Biesinger). + +2.3.91 + +Use libxml2 if requested or if expat not available. (Mathias Hasselmann) +Fix multi-arch cache files: compute the position for the +block to be added using info from OrigFile, not NewFile. (plam) +Cast results of sizeof() to unsigned int to get rid of +warnings on x86_64 (reported by Matthias Clasen). +Use FcAtomic to rewrite cache files; don't unlink the fonts.cache-2 +file even if there's no data to write; just write an empty cache file. +(Reported by Lubos Lunak) +Allocate room for the subdirectory names in each directory cache. +(Reported by James Cloos) + +2.3.90 + +Development release of mmap patch: load pattern information +directly from cache files. (Patrick Lam) + +2.3.2 + +Patch memory leaks in using iconv. (Reported by Chris Capoccia) +Patch memory leaks in fc-cache. (Reported by Chris Capoccia) +Fetch bitmap glyphs to get widths during font evaluation. (keithp) +Share strings through FcObjectStaticName (Ross Burton) +Windows build updates (Tor Lillqvist) + +2.3.1 + +Be more careful about broken GSUB/GPOS tables (Manish Singh) +Include debian packaging stuff in CVS (Josselin Mouette) +Add more conf.d examples (Keith Packard) +Make manuals build again (Keith Packard) +Johap -> Johab (Funda Wang) + +2.3.0 + +Fix memory leak of patterns rejected by configuration (#2518) + +Create prototype /etc/fonts/conf.d directory and populate it with a few +sample files. These samples are unused as the file names don't start with +numbers. + +Update documentation. + +2.2.99 + +Verify cache for FC_FILE and FC_FAMILY in every entry (#2219) + +Update blanks list from recent Unicode docs (#86) + +Various small build fixes (#280, #2278, + +Documentation fixes (#2085, #2284, #2285) + +Add polite typechecking to config file loader (#229) + +2.2.98 + +Share object name strings (Michael Meeks) + +Eliminate a couple of codepoints from Russian orthography (John Thacker) + +Add synthetic emboldening configuration changes (Jakub Pavelek) + +Change FcFontSetSort to ignore language after fonts with the requested +languages have been found. (Owen Taylor) + +Add some RedHat font configuration changes (Owen Tayler). + +Add full Unicode case folding support to case-ignoring string functions +(Keith Packard) + +Remove Han characters from Korean orthography (Tor Andersson) + +2.2.97 + +Fc-cache sleeps before exiting to ensure filesystem timestamps are well +ordered. + +Added Punjai orthography. + +The timestamp in fonts.conf is gone now. Too many problems. + +The default font path includes all of the X fonts; use selectfont/rejectfont +to eliminate bitmaps, as shown in the sample local.conf file. + + configuration elements may now reference a directory. Files +in that directory matching [0-9]* are loaded in UTF-8 collating sequence order. + + configuration added to control which fonts are used. + +fontformat font pattern elements built from the FT_Get_X11_Font_Format +function in newer versions of FreeType. + +'capability' list constructed from gsub/gpos and silf values in TrueType +files. + +Multi-lingual names (style, family, fullname) extracted and stored with +parallel lang properties marking language. + +2.2.96 + +Fix FcConfigUpToDate to actually check all font directories and eliminate +a typo which completely prevented it from working (Lubos Lunak +) + +Remove comma at end of FcResult enum definition for picky compilers. + +2.2.95 + +Add FcResultOutOfMemory so FcFontSetMatch can return accurate error. + +Replace MIN/MAX/ABS macros which happened to be in old FreeType releases +with FC_MIN/FC_MAX/FC_ABS macros owned by fontconfig. + +2.2.94 + +The 2.2.93 release was prepared with a broken libtool which created +the shared library without the '.so' in the file names. + +2.2.93 + +This is the third prerelease of fontconfig 2.3. Significant changes from +2.2.92 are: + + o Use new FreeType #include syntax + o use y_ppem field instead of 'height' in bitmap sizes rec - + FreeType changed the semantics. Still uses height for + older versions of FreeType + o Don't construct program manuals unless docbook is available + +2.2.92 + + o make distcheck work + +2.2.91 + + o Switch to SGML manuals + o Add FC_DUAL width spacing value + o Add FcFini to close out fontconfig and release all memory + +2.2 + +This is the third public release of fontconfig, a font configuration and +customization library. Fontconfig is designed to locate fonts within the +system and select them according to requirements specified by applications. + +Fontconfig is not a rasterization library, nor does it impose a particular +rasterization library on the application. The X-specific library +'Xft' uses fontconfig along with freetype to specify and rasterize fonts. + +Keith Packard +keithp@keithp.com diff --git a/builtins/textcode_pdf2text-macosx/src/textcode_pdf2text/licenses/fontconfig/README.md b/builtins/textcode_pdf2text-macosx/src/textcode_pdf2text/licenses/fontconfig/README.md new file mode 100644 index 0000000..83d0097 --- /dev/null +++ b/builtins/textcode_pdf2text-macosx/src/textcode_pdf2text/licenses/fontconfig/README.md @@ -0,0 +1,30 @@ +# Fontconfig + +Font configuration and customization library + +[[_TOC_]] + +## About Fontconfig + +Fontconfig can: + +* discover new fonts when installed automatically, removing a common source of configuration problems. +* perform font name substitution, so that appropriate alternative fonts can be selected if fonts are missing. +* identify the set of fonts required to completely cover a set of languages. +* have GUI configuration tools built as it uses an XML-based configuration file (though with autodiscovery, we believe this need is minimized). +* efficiently and quickly find the fonts you need among the set of fonts you have installed, even if you have installed thousands of fonts, while minimizing memory usage. +* be used in concert with the X Render Extension and [FreeType](https://www.freedesktop.org/wiki/Software/FreeType/) to implement high quality, anti-aliased and subpixel rendered text on a display. + +Fontconfig does not: + +* render the fonts themselves (this is left to FreeType or other rendering mechanisms) +* depend on the X Window System in any fashion, so that printer only applications do not have such dependencies + +## Documentation + +* [Fontconfig User Documentation](https://fontconfig.pages.freedesktop.org/fontconfig/fontconfig-user.html) +* [Fontconfig Developer Documentation](https://fontconfig.pages.freedesktop.org/fontconfig/fontconfig-devel/) + +## Bug reports + +If you have encountered any issues relating to Fontconfig, please file an issue in the [GitLab issue tracker](https://gitlab.freedesktop.org/fontconfig/fontconfig/issues). diff --git a/builtins/textcode_pdf2text-macosx/src/textcode_pdf2text/licenses/freetype/ChangeLog b/builtins/textcode_pdf2text-macosx/src/textcode_pdf2text/licenses/freetype/ChangeLog new file mode 100644 index 0000000..b58f346 --- /dev/null +++ b/builtins/textcode_pdf2text-macosx/src/textcode_pdf2text/licenses/freetype/ChangeLog @@ -0,0 +1,11077 @@ +2025-09-11 Werner Lemberg + + * Version 2.14.1 released. + ========================== + + Tag sources with `VER-2-14-1'. + + * docs/VERSION.TXT: Add entry for version 2.14.1. + * docs/CHANGES: Updated. + * docs/release, docs/README, builds/macs/README: Updated. + + * README, src/base/ftver.rc, builds/windows/vc2010/index.html, + builds/windows/visualc/index.html, builds/windows/visualce/index.html, + builds/wince/vc2005-ce/index.html, builds/wince/vc2008-ce/index.html, + docs/freetype-config.1: s/2.14.0/2.14.1/, s/2140/2141/. + + * include/freetype/freetype.h (FREETYPE_PATCH): Set to 1. + + * builds/unix/configure.raw (version_info): Set to 26:4:20. + * CMakeLists.txt (VERSION_PATCH): Set to 1. + +2025-09-10 Behdad Esfahbod + + [base] Fix return values of two Font Variation functions. + + * src/base/ftmm.c (FT_Set_Var_Design_Coordinates, + FT_Set_Var_Blend_Coordinates): Do it. + + Fixes issue #1355. + +2025-09-10 Werner Lemberg + + * src/autofit/afgsub.c (af_map_lookup): Fix handling of lookup type 7. + + Fixes issue #1356. + +2025-09-08 Alexei Podtelezhnikov + + * src/truetype/ttinterp.c (TT_Run_Context): Fix IUP tracking bits. + + Correctly fixes #1353 and #1349. + +2025-09-08 Alexei Podtelezhnikov + + Typo! + +2025-09-08 Alexei Podtelezhnikov + + * src/truetype/ttinterp.c (TT_Run_Context): Reset IUP tracking bits. + + Fixes #1353. + +2025-09-08 Behdad Esfahbod + + [autofit] Fix HarfBuzz calling. + + * src/autofit/afadjust.c (af_reverse_character_map_new) + [FT_CONFIG_OPTION_USE_HARFBUZZ]: Use `ft_hb_enabled`. + + Fixes issue #1354. + +2025-09-08 Werner Lemberg + + * docs/release: Use `sshpass` for SourceForge.net password. + +2025-09-08 Werner Lemberg + + * docs/release: Fix `scp` usage with OpenSSH version >= 9.0. + + Starting with this version, OpenSSH uses `scp` with the SFTP protocol as the + default. However, SFTP is disabled on savannah.gnu.org since January 2025. + +2025-09-06 Werner Lemberg + + * Version 2.14.0 released. + ========================== + + Tag sources with `VER-2-14-0'. + + * docs/VERSION.TXT: Add entry for version 2.14.0. + * docs/CHANGES: Updated. + * docs/release, docs/README, builds/macs/README: Updated. + + * README, src/base/ftver.rc, builds/windows/vc2010/index.html, + builds/windows/visualc/index.html, builds/windows/visualce/index.html, + builds/wince/vc2005-ce/index.html, builds/wince/vc2008-ce/index.html, + docs/freetype-config.1: s/2.13.3/2.14.0/, s/2133/2140/. + + * include/freetype/freetype.h (FREETYPE_MINOR): Set to 14. + (FREETYPE_PATCH): Set to 0. + + * builds/unix/configure.raw (version_info): Set to 26:3:20. + * CMakeLists.txt (VERSION_MINOR): Set to 14. + (VERSION_PATCH): Set to 0. + +2025-09-06 Werner Lemberg + + * builds/toplevel.mk (do-dist): Download shallow clone of `config.git`. + + No need for any other commit than the current one. + +2025-09-06 Werner Lemberg + + Update all copyright notices. + +2025-09-05 Werner Lemberg + + src/sfnt/ttload.c (tt_face_load_any): Correctly handle font containers. + + Reported as + + https://issues.oss-fuzz.com/issues/424613326 + +2025-09-05 Jouk Jansen + + Clean up OpenVMS support. + + This avoids cluttering the source code with VMS-specific changes. + + * include/freetype/internal/ftcalc.h [__VMS], src/base/ftcalc.c + [vms_auto64_source]: Remove. + + * builds/vms/patch_ftcalc.sed: New file. + + * vms_make.com: Change macro definitions while this script is running; we + use `GNU sed` to inject the necessary preprocessor code on the fly. + +2025-09-01 Alexei Podtelezhnikov + + * src/psaux/psauxmod.h (psaux_driver_class): Removed declaration. + +2025-08-29 Alexei Podtelezhnikov + + [base] Use const FT_Module_Class. + + This is intended to warn against modifying any fields in the class, + at compile-time and avoid crashes at run-time. + + * include/freetype/internal/ftobjs.h (FT_ModuleRec): Do it. + * src/base/ftobjs.c (Destroy_Module, FT_Add_Module): Updated. + +2025-08-27 Alexei Podtelezhnikov + + * src/base/ftobjs.c (FT_Load_Glyph): Reduces scope of 'ttface'. + +2025-08-25 Alexei Podtelezhnikov + + * src/truetype/ttinterp.c: Fix some builds. + +2025-08-23 Werner Lemberg + + * subprojects/*.wrap: Updated. + +2025-08-23 Werner Lemberg + + Updating `CHANGES` file; minor fixes elsewhere (mostly formatting). + +2025-08-20 Alexei Podtelezhnikov + + [truetype] Fix compilation without bytecode. + + Fixes #1351 and various warnings about unused variables. + + * src/truetype/ttinterp.c: Put the entire body under #ifdef. + * src/truetype/ttgload.c (TT_Process_Composite_Glyph): Relocate + some declarations. + * src/truetype/ttinterp.h: Remove some #ifdef conditions. + * src/truetype/ttobjs.c (tt_size_done): Modified. + +2025-08-14 Alexei Podtelezhnikov + + [truetype] Small fix in the incremental interface (again). + + Fixes #1299, last [-Wdangling-pointer=] warning. + + * src/truetype/ttgload.c (load_truetype_glyph): Restore original stream + on exit unconditionally. + +2025-08-14 Alexei Podtelezhnikov + + [truetype] Small fix in the incremental interface. + + Fixes #1299, last [-Wdangling-pointer=] warning. + + * src/truetype/ttgload.c (load_truetype_glyph): Restore original stream + on exit. + +2025-08-14 Alexei Podtelezhnikov + + * src/autofit/afgsub.c: Fix a warning. + + Fixes [-Wunused-function] warning without HarfBuzz. + +2025-08-11 Alexei Podtelezhnikov + + * */ftoption.h: Update C99 wording. + +2025-08-11 Alexei Podtelezhnikov + + * */ftoption.h: Note C99 compliance. + +2025-08-08 Behdad Esfahbod + + [ttgxvar] Fix caching of scalars when there are intermediate tuples. + + For example, with `GoogleSansFlex-Regular.ttf` at ROND=100, the 'Q' glyph + was misrendering. + + * src/truetype/ttgxvar.c (TT_Vary_Apply_Glyph_Deltas): Reset `tupleScalars` + earlier. + +2025-08-05 Jouk Jansen + + Improvements to OpenVMS support. + + * include/freetype/internal/ftcalc.h [__VMS]: Undefine `FT_MulFix`. + + * src/base/ftcalc.c [vms_auto64_source]: Define `FT_MulFix`. + + * vms_make.com: Also create 32bit version of the FreeType library. + +2025-08-04 Alexei Podtelezhnikov + + * docs/CHANGES: Mention 'ftmulti' improvements. + +2025-08-02 Alexei Podtelezhnikov + + [type1/MM] Correctly reset the default instance. + + Call T1_Set_MM_WeightVector, which actually sets default weights, + instead of TT_Set_MM_Blend, which just centers the axes. + + * src/type1/t1load.c (T1_Reset_MM_Blend): Do it. + +2025-08-01 Alexei Podtelezhnikov + + [truetype/v40] Fix ROUND_XY_TO_GRID handling. + + Fixes #1346. + + * src/truetype/ttgload.c (TT_Process_Composite_Component): Round + the x-position unless in backward_compatibility mode. + +2025-07-30 Alexei Podtelezhnikov + + * src/truetype/ttinterp.c (Ins_MDRP,MIRP): Small tweak. + +2025-07-30 Alexei Podtelezhnikov + + [truetype] Tweak size management. + + * include/freetype/internal/services/svmetric.h (FT_Size_Reset_Func): + Update typedef, do not return error. + * src/truetype/ttobjs.c (tt_size_reset_height): Move the PPem error + handling from here... + (tt_size_reset): ... to here to improve readability. + src/truetype/ttobjs.h (tt_size_reset_height): Update prototype. + +2025-07-30 Alexei Podtelezhnikov + + [truetype] Relocate color compensation (cont'd). + + * src/truetype/ttinterp.c (Inc_MDAR,MIAP,MDRP,MIRP): Fix forgotten + rounding. + +2025-07-29 Alexei Podtelezhnikov + + [truetype] Fix EVEN and ODD instructions. + + It is possible to have a fractional part after rounding when rounding + to half-grid or super-rounding. The specs call to ignore the fractional + part in that case. + + ^ src/truetype/ttinterp.c (Ins_EVEN, Ins_ODD): Fix mask. + +2025-07-28 Alexei Podtelezhnikov + + * src/truetype/ttinterp.c: Fix comments. + +2025-07-28 Alexei Podtelezhnikov + + * src/truetype/ttinterp.h (TT_Round_Func): Fix argument. + + Fixes #1347: function type mismatch. + +2025-07-27 Alexei Podtelezhnikov + + [truetype] Clean up size validation. + + Rely on non-zero ppem to validate the size object. + + * src/truetype/ttobjs.h (TT_Size_Merics): Remove the `valid` flag. + * src/truetype/ttobjs.c (tt_size_init,done,reset,reset_height): Updated. + * src/truetype/ttgload.c (TT_Load_Glyph): Check for non-zero ppem. + +2025-07-27 Alexei Podtelezhnikov + + [truetype] Relocate color compensation. + + The rounding color compensation, which is not used by FreeType, belongs + to GS. This is a more logical place for it, next to round_state. + + * src/truetype/ttobjs.h (TT_GraphicsState): Move compensations here... + (TT_Size_Metrics): ... from here. + * src/truetype/ttobjs.c (tt_size_init_bytecode): Updated. + * src/truetype/ttinterp.c (tt_default_graphics_state): Updated. + (Ins_ROUND,NROUND,EVEN,ODD): Updated. + (Round_*): Updated. + +2025-07-26 Alexei Podtelezhnikov + + [smooth] Remove usage of setjmp and longjmp. + + To support WASM targets with slow or unsupported setjmp and longjmp, + we eliminate these calls in favor of an error propagation model. + When gray_set_cell is out of cells, it raises an exception which is + later handled in gray_convert_glyph_inner. + This is a less invasive alternative to !385. + + * src/smooth/ftgrays.c (gray_set_cell): Raise the overflow exception + and redirect all work to `cell_null`. + (gray_move,line,conic,cubic_to): Return the exception. + (gray_convert_glyph, gray_convert_glyph_inner): Handle the exception. + +2025-07-05 Werner Lemberg + + [sfnt] Rewrite GPOS kerning support. (2/2) + + The previous code had a fundamental flaw: it didn't validate the necessary + parts of the 'GPOS' table before accessing it, causing crashes with + malformed data (since `TT_CONFIG_OPTION_GPOS_KERNING` is off by default, + standard fuzzers don't catch these problems). Additionally, it did a lot of + parsing while accessing kerning data, making it rather slow. + + The new implementation fixes this. After validation, offsets to the 'GPOS' + lookup subtables used in the 'kern' feature that correspond to 'simple' + kerning (i.e., similar to 'kern' table kerning) are stored in `TT_Face`; + this greatly simplifies and accelerates access to the kerning data. + + Testing with font `SF-Pro.ttf` version '1.00', the validation time for the + 'GPOS' table increases the start-up time of `FT_New_Face` by less than 1%, + while calls to `FT_Get_Kerning` become about 3.5 times faster. + + * include/freetype/internal (gpos_kerning_available): Replace with... + (gpos_lookups_kerning, num_gpos_lookups_kerning): ... these new fields. + Update callers. + + * src/ttgpos.c [TT_CONFIG_OPTION_GPOS_KERNING]: A new implementation. + +2025-07-05 Werner Lemberg + + [sfnt] Rewrite GPOS kerning support. (1/2) + + This commit removes the previous implementation. + +2025-07-05 Werner Lemberg + + [cff] Support GPOS kerning. + + * src/cff/cffdrivr.c (cff_get_kerning) [TT_CONFIG_OPTION_GPOS_KERNING]: Add + code similar to the one in `tt_get_kerning`. + +2025-07-05 Werner Lemberg + + * src/sfnt/ttkern.h (TT_FACE_HAS_KERNING): Remove macro. + + Given that we also support (limited) 'GPOS' table kerning if + `TT_CONFIG_OPTION_GPOS_KERNING` is defined, the name of this macro is + misleading since it only is true for 'kern' table kerning. + + * src/sfnt/sfobjs.c (sfn_load_face): Replace `TT_FACE_HAS_KERNING` with + plain code. + +2025-07-05 Werner Lemberg + + [autofit] Remove `globals->gsub_length`. + + We completely validate the accessed data from the 'GSUB' table, making this + field unnecessary. + + * src/autofit/afglobal.h (AF_FaceGlobalsRec): Remove `gsub_length` field. + + * src/autofit/afglobal.c (af_face_globals_new), src/autofit/afgsub.c + (af_parse_gsub): Updated. + +2025-07-01 Werner Lemberg + + * src/truetype/ttobjs.c (tt_size_init_bytecode): Correct previous fix. + + `FT_NEW_ARRAY` expects a signed value, not an unsigned one. + +2025-07-01 Werner Lemberg + + * src/autofit/afgsub.c: Include `tttables.h` and `afgsub.h`. + + This fixes 'make multi' compilation with clang. + + Reported as + + https://gitlab.freedesktop.org/freetype/freetype/-/merge_requests/381#note_2984610 + +2025-07-01 Werner Lemberg + + Various minor fixes. + + As reported by clang 19. + + * src/autofit/afadjust.c (adjustment_database): Make it static. + + * src/base/ftdbgmem.c (FT_MEM_SIZE_MIN): Remove unused macro. + + * src/psaux/psobjs.c (skip_procedure), src/truetype/ttinterp.c (Ins_IF, + Ins_ELSE, Ins_FDEF, Ins_IDEF): Add `default` clause. + +2025-07-01 Werner Lemberg + + More signedness fixes. + + As reported by clang 19. + + * src/autofit/afadjust.c (add_substitute): Make first argument unsigned. + Update all callers. + Other minor signedness fixes. + (af_reverse_character_map_new): Minor signedness fixes. + + * src/autofit/afgsub.c (af_hash_insert): Minor signedness fixes. + + * src/autofit/aflatin.c + (af_glyph_hints_apply_vertical_separation_adjustments): Make third + argument unsigned. + Update all callers. + Other minor signedness fixes. + (af_latin_hints_apply): Minor signedness fixes. + + * src/bdf/bdflib.c (bdf_parse_bitmap_): Minor signedness fix. + + * src/truetype/ttobjs.c (tt_size_init_bytecode): Minor signedness fix. + +2025-07-01 Werner Lemberg + + */*: Fix trivial signedness issues with format strings in trace messages. + + As reported with clang 19's `-Wformat` option. + +2025-07-01 Werner Lemberg + + Fix `make multi`. + + Reported as + + https://gitlab.freedesktop.org/freetype/freetype/-/merge_requests/381#note_2984253 + + * src/base/fthash.c: Include `ftobjs.h`. + * src/autofit/afgsub.c: Include `afglobal.h`. + +2025-06-30 Alexei Podtelezhnikov + + * MSBuild.sln: Minor. + +2025-06-29 Werner Lemberg + + [doc] Revise font variation API. + +2025-06-29 Werner Lemberg + + [doc] Use 'Adobe MM', 'TrueType GX', and 'OpenType Font Variations'. + +2025-06-26 Werner Lemberg + + Set minimum HarfBuzz version back to 2.0.0. + + Due to the new GSUB parsing we no longer need + `hb_ot_layout_lookup_get_glyph_alternates`. + + This partially reverts commit 5d2fd7608a9. + + * CMakeLists.txt (HARFBUZZ_MIN_VERSION), meson.build (harfbuzz_dep), + builds/unix/configure.raw (harfbuzz_pkg): Set version to 2.0.0. + + * src/autofit/ft-hb-decls.h: Remove entry for + `hb_ot_layout_lookup_get_glyph_alternates`. + +2025-06-26 Werner Lemberg + + [autofit] Speed up computation of `af_reverse_character_map_new`. (4/4) + + With this commit, the start-up time for creating the reverse character map + gets reduced from more than 300% to about 25% (as tested with `arial.ttf` + version 7.00). + + * src/autofit/afadjust.c [FT_CONFIG_OPTION_USE_HARFBUZZ]: Include + `afgsub.h`. + (add_substitute): New auxiliary function to recursively add elements to + the reverse cmap. + (af_reverse_character_map_new): New code that replaces the old code + removed in the previous commit. + +2025-06-26 Werner Lemberg + + [autofit] Speed up computation of `af_reverse_character_map_new`. (3/4) + + Rip out some HarfBuzz code of `af_reverse_character_map_new`. The new code + comes immediately in a follow-up commit, making it easier to follow the + changes. + + * src/autofit/afadjust.c (af_get_glyph_alternates_helper, + af_get_glyph_alternates): Remove. + (af_reverse_character_map_new): Remove code to create the `*map` hash. + +2025-06-26 Werner Lemberg + + [autofit] Speed up computation of `af_reverse_character_map_new`. (2/4) + + Create an array of GSUB lookup indices for `SingleSubst` and + `AlternateSubst` lookup types to exit early if we have different types. + + Also improve tracing. + + * src/autofit/afglobal.h (AF_FaceGlobals) [FT_CONFIG_OPTION_USE_HARFBUZZ]: + New fields `gsub_length`, `gsub`, and `gsub_lookups_single_alternate`. + + * src/autofit/afglobal.c [FT_CONFIG_OPTION_USE_HARFBUZZ]: Include + `afgsub.h`. + (af_face_globals_new) [FT_CONFIG_OPTION_USE_HARFBUZZ]: Call + `af_parse_gsub` to fill `gsub_lookups_single_alternate`. + (af_face_globals_free): Updated. + + * src/autofit/afadjust.c (af_get_glyph_alternates_helper): Exit early if we + possible. + (af_reverse_character_map_new): Trace GSUB lookup indices to be checked. + +2025-06-26 Werner Lemberg + + [autofit] Speed up computation of `af_reverse_character_map_new`. (1/4) + + Using HarfBuzz's API functions to construct the reverse map is too slow; we + have to call `hb_ot_layout_lookup_get_glyph_alternates` far too often + because it can only handle a single glyph at a time. For this reason we are + going to parse the GSUB table by ourselves. + + The new non-local functions are `af_parse_gsub` and `af_map_lookup`. + + * src/autofit/afgsub.c, src/autofit/afgsub.h: New files for parsing, + validating, and mapping the `SingleSubst` and `AlternateSubst` subtable + types of a GSUB table. + + * src/autofit/autofit.c, src/autofit/rules.mk (AUTOF_DRV_SRC): Updated. + +2025-06-26 Werner Lemberg + + [base] Add no-overwrite hash insert functions. + + * src/base/fthash.c (ft_hash_num_insert_no_overwrite, + ft_hash_str_insert_no_overwrite): New functions. + * include/freetype/internal/fthash.h: Updated. + +2025-06-26 Werner Lemberg + + [base] Add iterators for `FT_Hash`. + + * src/base/fthash.c (ft_hash_num_iterator, ft_hash_str_iterator): New + functions. + * include/freetype/internal/fthash.h: Updated. + +2025-06-24 Werner Lemberg + + [truetype] Add comment to explain heuristic limit for twilight points. + +2025-06-23 Alexei Podtelezhnikov + + [truetype] Restore non-persistent CVT and storage. + + According to specifications, CVT and storage area may or may not be + persistent after modifications by a glyf program. FreeType had always + reset them, which was broken by the last commit. + + * src/truetype/ttinterp.c (TT_Load_Context): Set CVT and storage here. + * src/truetype.ttobjs.c (tt_size_run_prep): Prioritize TT_Load_Context. + (tt_size_init_bytecode): Allocate but not set CVT and storage area. + +2025-06-22 Alexei Podtelezhnikov + + [truetype] Deduplicate 'codeRangeTable'. + + * src/truetype/ttinterp.c (TT_Load_Context, TT_Save_Context): Do not + copy 'codeRangeTable'. + * src/truetype/ttobjs.h (TT_Size): Remove 'codeRangeTable'. + (TT_CodeRange_Tag, TT_CodeRange, TT_DefArray): Moved to... + * src/truetype/ttinterp.h: ... this header.1 + +2025-06-22 Alexei Podtelezhnikov + + [truetype] Simplify bytecode allocations. + + To avoid repeated synchronization, some TT_Size allocations are moved + TT_ExecContext for good. The memory blocks are also consolidated. + + * src/truetype/ttinterp.c (TT_{Load,Save,Done}_Context): Remove + synchronization and stack management. + * src/truetype/ttobjs.c (tt_size_{init,done}_bytecode): Manage allocations + and assign them to the execution context. + (tt_size_run_prep): Updated. + +2025-06-22 Alexei Podtelezhnikov + + [truetype] Rework handling of rendering mode in bytecode. + + This replaces a large number of confusing boolean constructs that + describe the target rendering mode in the execution context with + the straight mode variable. It might fix some hidden bugs when + FT_LOAD_TARGET_XXX were used as flags, which they are not. + + The condition that triggers the CV program re-execution is simplified. + These events due the rendering mode change are rather rare and unexpected + and, therefore, should not be over-analyzed. In v40, all mode changes + now trigger the CV program. In v35, only switches to/from mono do. + + * src/truetype/ttinterp.h (TT_ExecContext): Replace 'grayscale', + 'grayscale_cleartype', 'subpixel_hinting_lean', and 'vertical_lcd_lean' + with the rendering 'mode'. + * src/truetype/ttinterp.c (Ins_GETINFO): Updated. + * src/truetype/ttgload.c (tt_loader_init): Replace 'prep' re-execution + trigger and update 'backward_compatibility' condition. + (tt_loader_set_pp): Updated. + +2025-06-21 Alexei Podtelezhnikov + + * src/truetype/{ttinterp.c,ttobjs.c}: Minor. + +2025-06-21 Alexei Podtelezhnikov + + [truetype] Clean up bytecode execution triggers. + + This avoids executing the CV program twice and cleans up the use of + 'fpgm' and 'prep' triggers + + * src/truetype/ttgload.c (tt_loader_init): Call 'tt_size_init_bytecode' + and 'tt_size_run_prep' explicitly and avoid the call repetition. + * src/truetype/ttobjs.c (tt_size_ready_bytecode): Removed as unused. + (tt_size_init, tt_size_init_bytecode, tt_size_done_bytecode): Remove some + 'fpgm' and 'prep' triggers and update. + (tt_size_run_fpgm, tt_size_run_prep): Do not set the pedantic flag here. + * src/truetype/ttobjs.h: Update signatures. + +2025-06-21 Alexei Podtelezhnikov + + * src/truetype/ttgload.c (tt_loader_init, load_sbit_image): Clean up. + +2025-06-21 Alexei Podtelezhnikov + + [truetype] Simplify twilight zone management. + + * include/freetype/internal/tttypes.h (TT_GlyphZone): Remove 'memory'. + * src/truetype/ttobjs.c (tt_glyphzone_done): Use 'memory' as argument. + (tt_glyphzone_new, tt_glyphzone_done): Allocate/free as a single block. + (tt_size_init_bytecode, tt_size_done_bytecode): Updated. + * src/truetype/ttobjs.h (tt_glyphzone_done): Updated signature. + +2025-06-19 Behdad Esfahbod + + [autofit] Really fix handling of `RTLD_DEFAULT`. + + This commit actually implements what commit 43ec023e1a7 describes. + + * src/autofit/ft-hb.c (FT_RTLD_FLAGS): New macro for `dlopen`; it uses + `RTLD_GLOBAL` only if `RTLD_DEFAULT` is available. + +2025-06-15 Alexei Podtelezhnikov + + [truetype] Revise twilight zone initiation. + + This assures that twilight zone is reset before each CV program + execution, including after the rendering mode switch. Fixes #1344. + + * src/truetype/ttobjs.c (tt_size_ready_bytecode): Relocate the GS + the twilight zone initiation from here... + (tt_size_run_prep): ... to this function, sho that it is always + done prior to the CV program execution. + * src/truetype/ttobjs.c (TT_Run_Context): Set twilight zone here... + (TT_Load_Context): ... rather than here, as it used to be. + +2025-06-13 Alexei Podtelezhnikov + + * src/base/ftrfork.c (FT_Raccess_Get_DataOffsets): Remove check. + + The highest (sign) attribute bit is reserved and should be zero. + It is harmless to omit this check however. Fixes #1342. + +2025-06-12 Werner Lemberg + + [autofit] Ignore virtual glyph indices from GSUB lookups. + + Reported as + + https://issues.chromium.org/issues/420401651 + + * src/autofit/afadjust.c (af_reverse_character_map_new): Implement it. + +2025-06-11 Alexei Podtelezhnikov + + [truetype] Clean up TT_GlyphZone. + + * include/freetype/internal/tttypes.h (TT_GlyphZone): Delete fields. + * src/truetype/ttobjs.c (tt_glyphzone_new, tt_glyphzone_done, + tt_size_init_bytecode): Updated. + +2025-06-11 Alexei Podtelezhnikov + + [truetype] Use FT_ARRAY_ZERO. + + * src/truetype/ttgxvar.c (TT_Vary_Apply_Glyph_Deltas): Updated. + * src/truetype/ttobjs.c (tt_check_trickyness_sfnt_ids, + tt_size_ready_bytecode): Updated. + +2025-06-11 Alexei Podtelezhnikov + + [truetype] Rearrange bytecode run. + + This is a minor change with large code rearrangements. + + * src/truetype/ttinterp.c (TT_RunIns): Just loop through instructions + and move all setup to... + (TT_Run_Context): ... here; relocated. + (Compute_Round): Replaced by simple assignment, removed. + +2025-06-11 Alexei Podtelezhnikov + + [truetype] Relocate the interpreter pointer. + + This reduces dereferencing when calling the interpreter. + + * include/freetype/internal/tttypes.h (TT_Face): Move it from here... + * src/truetype/ttinterp.h (TT_ExecContext): ... to here. + * src/truetype/ttobjs.c (tt_size_init_bytecode): Move its initialization + * src/truetype/ttinterp.c (TT_New_Context): ... to here. + (TT_Run_Context): Updated. + +2025-06-11 Alexei Podtelezhnikov + + [truetype] Clean up the loader initiation. + + * include/freetype/internal/tttypes.h (TT_LoaderRec): Remove unused field. + * src/truetype/ttgload.c (tt_loader_init): Refactor. + +2025-06-11 Alexei Podtelezhnikov + + [truetype] Modify bytecode initiation. + + This reduces the number of function calls and data copying events. + + * src/truetype/ttinterp.c (TT_Goto_CodeRange): Merge into... + (TT_Set_CodeRange): ... this function. + (TT_Load_Context): Do not set up any zones, copy GS, or prepare the + execution... + (TT_Run_Context): ... do this here instead.. + * src/truetype/ttinterp.c (TT_Set_CodeRange): Update signature. + * src/truetype/ttobjs.c (tt_size_run_fpgm, tt_size_run_prep): Call + TT_Run_Context. + * src/truetype/ttgload.c (TT_Hint_Glyph, tt_loader_init): Updated. + +2025-06-11 Alexei Podtelezhnikov + + [truetype] Modify the graphics state management. + + Instead of restoring persistent GS variables, we only save modifications + permitted by the CVT program. This reduces the context manipulations. + + * src/truetype/ttobjs.h (TT_GraphicsState): Reorder fields. + * src/truetype/ttobjs.c (tt_size_run_fpgm, tt_size_run_prep): + Do not alter the context. + + * src/truetype/ttgload.c (TT_Hint_Glyph): Do not reset GS. + (tt_loader_init): Fix potential issue in 'instruct_control' handling. + * src/truetype/ttinterp.c (TT_Run_Context): Fully reset GS. + (TT_Load_Conext): Rearrange and remove the 'size' check, already + performed in FT_Load_Glyph. + (TT_Save_Context): Save only modifiable GS parts. + (tt_default_graphics_state): Updated. + * src/truetype/ttinterp.h (TT_Run_Context): Update signature. + +2025-06-10 Werner Lemberg + + [gxvar] Really fix setting of named-instance to Regular. + + This fixes an ommission in commit cf06661c51. + + * src/truetype/ttgxvar.c (TT_Vary_Apply_Glyph_Deltas): Initialize `error`. + +2025-06-10 Werner Lemberg + + Two more link fixes. + +2025-06-10 Werner Lemberg + + Update links. + + Found with `linkchecker --check-extern index.html` running locally in the + 'freetype-web' repository. + +2025-06-07 Behdad Esfahbod + + Fix setting of named-instance to Regular + + Fixes https://gitlab.freedesktop.org/freetype/freetype/-/issues/1341 + + And more elaborate avoidance of loading face->blend if all coords + are zero. + +2025-06-04 Alexei Podtelezhnikov + + * src/type42/t42objs.c (T42_Size_Init): Fix uninitialized use. + + Found by Ozkan Sezer. + +2025-06-04 Ozkan Sezer + + [autofit] Fix `-Wunused-but-set-variable` warning in Windows builds. + + With this commit, the following warning gets removed. + + ``` + In file included from src/autofit/autofit.c:21:0: + src/autofit/ft-hb.c: In function 'ft_hb_funcs_init': + src/autofit/ft-hb.c:75:35: warning: + variable 'version_atleast' set but not used [-Wunused-but-set-variable] + ft_hb_version_atleast_func_t version_atleast = NULL; + ^~~~~~~~~~~~~~~ + ``` + + * src/autofit/ft-hb.c (ft_hb_funcs_init): Move `NULL` check of + `version_atleast` out of ifdefs. + +2025-06-04 Ozkan Sezer + + [build] Revise visibility attributes usage in autotools and CMake. + + * CMakeLists.txt: Set `C_VISIBILITY_PRESET` to hidden for non-Windows only. + Windows handles exports with `DLL_EXPORT` defined, and old MinGW + toolchains emit a lot of warnings about visibility attributes not being + supported in this configuration. + + * build/unix/configure.raw: Revise visibility attributes checks by compiling a + better test program with `-Werror` in `CFLAGS` so that warnings correctly + indicate unsupported configurations. + +2025-06-04 Ozkan Sezer + + * CMakeLists.txt: Add support for `FT_CONFIG_OPTION_USE_HARFBUZZ_DYNAMIC`. + + This commit introduces a new CMake option `FT_DYNAMIC_HARFBUZZ`. + +2025-06-03 Ozkan Sezer + + * src/autofit/ft-hb.c: Fix definition of `_GNU_SOURCE`. + + Commit 43ec023e1a730f defined the macro too late. + +2025-06-03 Werner Lemberg + + Replace 'www.freetype.org' with 'freetype.org'. + +2025-06-03 Ozkan Sezer + + * builds/unix/configure.raw: Fix HarfBuzz library detection for MinGW. + + Set `have_harfbuzz*` variables explicitly to dynamic for MinGW, since + Windows uses its own `LoadLibrary` call. + + This fixes a MinGW configuration error: + + ``` + checking for HARFBUZZ... no + checking for dlopen in -lc... no + checking for dlopen in -ldl... no + configure: error: harfbuzz support requested but library not found + ``` + +2025-06-03 Ozkan Sezer + + * builds/unix/configure.raw: Improve check for `dlopen`. + + Look for `dlopen` first in 'libc', then in 'libdl'. + +2025-06-03 Behdad Esfahbod + + * src/autofit/ft-hb.c: Fix usage of `RTLD_DEFAULT`. + + Using `RTLD_DEFAULT` we see whether the process already has HarfBuzz linked + in, and reuse it. If this symbol is not defined it is tempting to use + `RTLD_GLOBAL` instead, which would make the library available to the whole + process. However, without `RTLD_DEFAULT`, we would risk loading a second + HarfBuzz library, and if the linker mixes them up, probably giving symbols + from the new library to other clients, we might get into trouble. For this + reason, we do not pass `RTLD_GLOBAL` to `dlopen`; the default is + `RTLD_LOCAL`, and the rest of the process won't see the loaded HarfBuzz and + hopefully all be happy. + +2025-05-28 Werner Lemberg + + [sfnt] `FT_Load_Sfnt_Table` can now also load a font's table directory. + + Closes issue #1263. + + * src/sfnt/ttload.c (tt_face_load_any): Implement it. + +2025-05-28 Werner Lemberg + + [gzip] Update sources to zlib 1.13.1. + + Fixes issue #1294. + +2025-05-27 Vítor Ramos + + * src/base/ftobjs.c (FT_Load_Glyph): Loosen auto-hinting constraints. + + Fixes issue #1320. + +2025-05-27 Werner Lemberg + + Update `CHANGES` file. + +2025-05-27 Behdad Esfahbod + + [gxvar] Optimize out more bounds checking. + + Big win, ~20% in measured mega-var font, HarfBuzz's `benchmark-font` + 'glyph_h_advances' benchmark. + + * src/truetype/ttgxvar.c (TT_Vary_Apply_Glyph_Deltas): Implement it in + loops. + +2025-05-27 Behdad Esfahbod + + * src/truetype/ttgload.c (load_truetype_glyph): Use `IS_DEFAULT_INSTANCE`. + +2025-05-27 Behdad Esfahbod + + [gxvar] Set `doblend` to `FALSE` if at default location. + + * src/truetype/ttgxvar.c (tt_set_mm_blend, TT_Get_Var_Design): Do it. + +2025-05-27 Behdad Esfahbod + + [mm/gxvar] Always detect default instance and use optimized codepath. + + Even if it was explicitly set by either design or normalized APIs. + + Also update documentation. + + * src/truetype/ttgxvar.c (TT_Set_MM_Blend, TT_Set_Var_Design): Use value -2 + of `error` to indicate that we have a non-default instance. + (TT_Set_Named_Instance): Updated. + + * src/base/ftmm.c (FT_Set_Var_Design_Coordinates, + FT_Set_Var_Blend_Coordinates): Updated. + +2025-05-27 Alexei Podtelezhnikov + + Typo. + +2025-05-27 Alexei Podtelezhnikov + + * src/truetype/ttinterp.c (TT_Load_Context): Clean up. + +2025-05-26 Werner Lemberg + + [autofit] Fix integer overflow. + + Reported as + + https://issues.oss-fuzz.com/issues/420401635 + + * src/autofit/aflatin.c (af_latin_stretch_top_tilde, + af_latin_stretch_bottom_tilde): Use `SUB_LONG`. + +2025-05-26 Werner Lemberg + + [gxvar] Speed up handling of deltas in `ItemVariationStore`. (3/3) + + * src/base/ftcalc.c (FT_MulAddFix): Removed, no longer needed. + * include/freetype/internal/ftcalc.h: Updated. + +2025-05-26 Behdad Esfahbod + + [gxvar] Speed up handling of deltas in `ItemVariationStore`. (2/3) + + Do all math in fixed integer and do a single divide at the end. + + Also don't use an array to read deltas; just read them as we go, and skip + (branch-free) when scalar is 0. + + 30% speedup in measured mega-var font, HarfBuzz's `benchmark-font` + 'glyph_h_advances' benchmark. + +2025-05-26 Behdad Esfahbod + + [gxvar] Speed up handling of deltas in `ItemVariationStore`. (1/3) + + * src/truetype/ttgxvar.c (ft_mul_add_delta_scalar, ft_round_and_shift16): + New functions, reusing code from `ftcalc.c`. + +2025-05-26 Behdad Esfahbod + + Lift `FT_Int64` type to global (internal) FreeType use. + + * src/base/ftcalc.c (FT_Int64) [!FT_INT64]: Move declaration to... + * include/freetype/config/integer-types.h: ... this file. + (FT_UInt64) [!FT_INT64]: New structure. + (FT_INT64_ZERO): New macro. + +2025-05-26 Behdad Esfahbod + + [gxvar] Move scalar computation into its own function. + + * src/truetype/ttgxvar.c (tt_var_get_item_delta): Split off affected code + into... + (tt_calculate_scalar): ...this new function. + +2025-05-26 Werner Lemberg + + [autofit] Make the accent database work for more glyphs (again). + + See the added comment for an explanation. + + This partially undoes commit f68733d4a8. + + * src/autofit/afadjust.c (af_reverse_character_map_new): Always loop over all + elements of the adjustment database. + (in_range): Removed, no longer needed. + +2025-05-26 Alexei Podtelezhnikov + + [trueetype] Remove useless assignments. + + * src/truetype/ttobjs.c (tt_size_run_fpgm): Remove assignment that + is ignored and overridden later in 'Compute_Funcs'. + * src/truetype/ttinterp.c (TT_RunIns): Ditto. + (Ins_MIAP): Formatting. + +2025-05-25 Werner Lemberg + + [autofit] Minor code cleanup. + + * src/autofit/afadjust.c (af_reverse_character_map_new): Rename `result_set` + to `glyph_alternates` and move its clearing to... + (af_get_glyph_alternates): ...this function. + (af_get_glyph_alternates_helper): s/result/helper_result/. + +2025-05-25 Werner Lemberg + + [autofit] Speed up construction of reverse character map. (4/4) + + * src/autofit/afadjust.c (af_get_glyph_alternates): Move creation and + deletion of the `helper_result` set to... + (af_reverse_character_map_new): ...this function. + Gain for `arial.ttf` version 7.00: approx. 1%. + +2025-05-25 Werner Lemberg + + [autofit] Speed up construction of reverse character map. (3/4) + + * src/autofit/afadjust.c (af_reverse_character_map_new): Fold two loops into + one. + Gain for `arial.ttf` version 7.00: approx. 1%. + +2025-05-25 Werner Lemberg + + [autofit] Speed up construction of reverse character map. (2/4) + + This commit, together with the previous one, makes the startup of the + auto-hinter much faster. + + Note, though, that the startup time for handling the diacritic database is + still rather large. For example, loading `arial.ttf` version 7.00 followed + by auto-hinting a first Latin glyph is still approx. three times slower + than before the introduction of the database (this is because function + `hb_ot_layout_lookup_get_glyph_alternates` is called very often). + + * src/autofit/afshaper.c (scripts): Rename this array to... + (af_hb_scripts): ...this and export it. + (af_shaper_get_coverage_hb): Updated. + * src/autofit/afshaper.h: Updated. + + * src/autofit/afadjust.c (af_reverse_character_map_new): Pass the current + script to `hb_ot_layout_collect_lookups` to make HarfBuzz check less + lookups while searching for glyph alternates. + +2025-05-25 Werner Lemberg + + [autofit] Speed up construction of reverse character map. (1/4) + + Build reverse cmap for characters of the current script style only. + + * src/autofit/afadjust.c (in_range): New function. + (af_reverse_character_map_new): Pass `AF_StyleMetrics` instead of + `AF_FaceGlobals` so that we can access the current script style. + Use `in_range` to limit tested code points. + * src/autofit/afadjust.h: Updated. + * src/autofit/aflatin.c (af_latin_metrics_init): Updated. + +2025-05-25 Werner Lemberg + + [autofit] Avoid variable shadowing. + + * src/autofit/afadjust.c (af_reverse_character_map_new): Do it. + +2025-05-25 Werner Lemberg + + [autofit] Minor speedup of reverse charmap creation. + + * src/autofit/afglobal.h (AF_HAS_CMAP_ENTRY): New flag. + (AF_STYLE_MASK): Update value. + * src/autofit/afglobal.c (af_face_globals_compute_style_coverage): Set + `AF_HAS_CMAP_ENTRY`. + + * src/autofit/afadjust.c (af_reverse_character_map_new): For the creation of + the reverse map, change code to handle glyphs with cmap entries before + glyphs without cmap entries. Doing so avoids some code redundancy and + reduces the number of hash lookups. + +2025-05-25 Werner Lemberg + + [autofit] Whitespace. + +2025-05-25 Werner Lemberg + + [autofit] Use `FT_Offset`. + + * src/autofit/afadjust.c (af_adjustment_database_lookup, + af_reverse_character_map_new): Do it. + +2025-05-25 Werner Lemberg + + [autofit] Simplify return value of `af_adjustment_database_lookup`. + + * src/autofit/adfadjust.h (af_adjustment_database_lookup): Return integer. + (AF_AdjustmentDatabaseEntry): Move structure to... + * src/autofit/afadjust.c: ...this file. + (af_adjustment_database_lookup, af_reverse_character_map_new): Updated. + * src/autofit/aflatin.c + (af_glyph_hints_apply_vertical_separation_adjustments): Updated. + +2025-05-25 Werner Lemberg + + [autofit] Remove no longer used functions and structures. + + This is the clean-up from the previous commit. + + * src/autofit/afadjust.c (af_reverse_character_map_entry_compare, + af_reverse_character_map_lookup, af_reverse_character_map_expand): + Removed. + * src/autofit/afadjust.h: Updated. + * src/autofit/aftypes.h (AF_ReverseMapEntry, AF_ReverseCharacterMap): + Removed. + +2025-05-25 Werner Lemberg + + [autofit] Use a hash for handling vertical accent adjustments. + + This greatly simplifies the code. + + * src/autofit/afadjust.c (af_reverse_character_map_new): Implement it. + (af_reverse_character_map_done): Updated. + * src/autofit/afadjust.h: Updated. + + * src/autofit/aflatin.c + (af_glyph_hints_apply_vertical_separation_adjustments): Updated. + + * src/autofit/aftypes.h: Include `fthash.h`. + (AF_StyleMetrics): Change type of `reverse_charmap` to `FT_Hash`. + +2025-05-25 Werner Lemberg + + * src/autofit/aflatin.c (af_latin_hints_apply): Improve code legibility. + +2025-05-25 Werner Lemberg + + [autofit] Use `FT_LONG_MIN` and `FT_LONG_MAX` for `FT_Pos` variables. + + * src/autofit/aflatin.c (af_latin_metrics_init_blues, + af_compute_vertical_extrema, af_find_highest_contour, + af_find_second_highest_contour, af_find_lowest_contour, + af_find_second_lowest_contour, af_check_contour_horizontal_overlap): + Updated. + +2025-05-25 Werner Lemberg + + [autofit] Fix uninitialized variables. + + * src/autofit/aflatin.c (af_latin_stretch_top_tilde, + af_latin_stretch_bottom_tilde): Initialize `min_measurement`. + +2025-05-23 Behdad Esfahbod + + [ttmtx] Fix check for being non-default variation position. + + If user explicitly sets variations to `NULL` after it being set to something + else, `face->blend` will still be non-`NULL`. The intention here however is + correctly captured by `FT_IS_VARIATION`. + + * src/sfnt/ttmtx.c (tt_face_get_metrics): Use `FT_IS_VARIATION`. + +2025-05-23 Behdad Esfahbod + + [gxvar] Optimize loading of 'gvar' table. + + * src/truetype/ttgxvar.c (tt_var_load_item_variation_store, + tt_var_load_delta_set_index_mapping, ft_var_load_gvar): Use frames to + reduce bounds checking. + (TT_Vary_Apply_Glyph_Deltas): Better macro usage. + +2025-05-22 Behdad Esfahbod + + [mm] Short-circuit setting face to default instance if already is so. + + I found that in hb-ft I need to sometime reset the face to the default + instance. However, calling `FT_Set_Var_Design_Coordinates` with no coords + was still slowing down at least the glyph-advance code by processing + variations. + + Perhaps there's a better fix, but this handles the easy cases. + + * src/base/ftmm.c (FT_Set_Var_Design_Coordinates): Implement it. + +2025-05-22 Behdad Esfahbod + + * src/truetype/ttgxvar.c (TT_Vary_Apply_Glyph_Deltas): Fix allocation. + + Bug was introduced in commit 582de1a4b6f. + +2025-05-21 Werner Lemberg + + * src/truetype/ttgxvar.c (ft_var_apply_tuple): Remove redundant test. + + This was erroneously added in commit e6e9110a8. + +2025-05-21 ColdPaleLight + + [sdf] Skip neighbor comparison for pixels near edges. + + If the distance of the current pixel to the edge is less than or equal + to 0.5, skip further neighbor comparisons to avoid unnecessary + calculations. When the `USE_SQUARED_DISTANCES` macro is defined, + compare to 0.25 instead. + + * src/sdf/ftbsdf.c (compare_neighbor): Add early return for pixels + close to edges to avoid unnecessary neighbor checks. + +2025-05-21 Behdad Esfahbod (بهداد اسفهبد) + + [gxvar] Cache shared-tuple scalar values. + + GoogleSansFlex HB benchmark-font draw results: + + Before: 2.13ms + After: 1.65ms + Speedup: 22% + + * src/truetype/ttgxvar.h (GX_BlendRec): Add `tuplescalars` field. + + * src/truetype/ttgxvar.c (ft_var_load_gvar): Allocate `tuplescalars` array. + (tt_set_mm_blend): Set its values. + (TT_Vary_Apply_Glyph_Deltas): Use it. + (tt_done_blend): Deallocate it. + +2025-05-21 Behdad Esfahbod (بهداد اسفهبد) + + [gxvar] Reduce number of mallocs. + + 8% speed up in drawing GoogleSansFlex variable in HB benchmark-font. + + * src/truetype/ttgxvar.c (TT_Vary_Apply_Glyph_Deltas): Use an allocation + pool instead of individual allocations. + +2025-05-21 Behdad Esfahbod (بهداد اسفهبد) + + [gxvar] Another optimization in computing scalar. + + Another ~6% speedup in GoogleSansFlex var drawing. + + * src/truetype/ttgxvar.c (ft_var_apply_tuple): Test `ncv` for being zero. + +2025-05-21 Behdad Esfahbod (بهداد اسفهبد) + + [gxvar] Remove stale comment. + + The code *does* check against start/end! + +2025-05-21 Behdad Esfahbod (بهداد اسفهبد) + + * src/truetype/ttgxvar.c (ft_var_apply_tuple): Micro-optimize. + +2025-05-21 Behdad Esfahbod (بهداد اسفهبد) + + [gxvar] Inline two USHORT reads. + + Speeds up GoogleSansFlex variable glyph drawing by ~13%. + + Before: 2.95ms + After: 2.57ms + + * src/truetype/ttgxvar.c (TT_Vary_Apply_Glyph_Deltas): Do it. + +2025-05-21 Behdad Esfahbod (بهداد اسفهبد) + + [gxvar] Micro-optimize loop end condition. + + * src/truetype/ttgxvar.c (TT_Vary_Apply_Glyph_Deltas): Do it. + +2025-05-21 Behdad Esfahbod + + [truetype] Don't process `mvar` metrics if default instance. + + GoogleSansFlex default-instance HarfBuzz benchmark-font draw: + + Before: 0.610ms + After: 0.435ms + Speedup: 28% + + * src/truetype/ttobjs.c (tt_face_init) [TT_CONFIG_OPTION_GX_VAR_SUPPORT]: + Check `instance_index`. + +2025-05-21 Alexei Podtelezhnikov + + * src/truetype/ttinterp.c (Ins_MIRP,DELTAP,DELTAC): Minor. + +2025-05-20 Alexei Podtelezhnikov + + [truetype] Update bytecode error handling. + + * src/truetype/ttinterp.c (Ins_SHP,SHPIX,ALIGNRP): Return appropriate + error in case of stack underflow. + (Ins_IP): Ditto and remove redundant check. + +2025-05-19 Werner Lemberg + + * src/aflatin.c (af_latin_hint_edges): Refine fix for serif handling. + + Commit 11432424 (from 2025-May-12) was too aggressive; it is now restricted + to edges that are not too far away. + +2025-05-19 Werner Lemberg + + * src/afadjust.c (adjustment_database): Make it complete up to U+FFFF. + + Also fix two entries. + + This is for Unicode 17.0. + +2025-05-19 Werner Lemberg + + [autofit] Fix vertical adjustment of (mainly) double diacritics. + + The series of commits that introduced this adjustment support had some + flaws. + + - If there were two diacritics on top of a base glyph, and the upper + diacritic was a tilde, the vertical centering correction was incorrectly + applied to the lower, non-tilde glyph instead of the tilde. + + - The maximum value allowed to shift a glyph was too strict (and also not + handling rounding issues), causing some diacritics and combinations of + diacritics to be not shifted at all. + + * src/autofit/aflatin.c + (af_glyph_hints_apply_vertical_separation_adjustments): Correctly handle + vertical centering correction. + +2025-05-19 Werner Lemberg + + [autofit] Code hygiene. + + * src/autofit/aflatin.c + (af_glyph_hints_apply_vertical_separation_adjustments): Use more flag + variables and improve trace messages. + +2025-05-19 Werner Lemberg + + * src/autofit/aflatin.c (af_latin_hint_edges): Fix handling of serifs. + + This has been discovered while inspecting the auto-hinting results of + character 'Ễ' in font `arial.ttf` (version 7.00) at 13ppem. + +2025-05-19 Werner Lemberg + + [autofit] Minor. + + * src/autofit/aflatin.c (af_latin_hint_edges): Rename `has_serifs` to + `has_non_stem_edges` and make it of type `FT_Bool`. + +2025-05-19 Werner Lemberg + + [autofit] New algorithm for preventing hinting of tilde glyphs. + + The old algorithm removed segments from edges to make the auto-hinter ignore + a tilde. However, the implementation had two flaws. + + - Edge array elements were moved around without reordering them afterwards. + - The linking between edges and segments wasn't correctly updated for moved + edges, which could cause endless loops. + + Correcting both problems are non-trivial; additionally, a fix would make + the auto-hinter slower. + + For these reasons, a new, simpler approach is taken: A new flag allows + points to be tagged as being ignored, and if such a point is enountered, it + doesn't get added to a segment. + + Fixes issue #1333. + + * src/autofit/afhints.h (AF_FLAG_IGNORE): New macro. + + * src/autofit/aflatin.c (af_latin_hints_compute_segments, af_touch_contour): + Use it. + (af_remove_segments_containing_point, af_remove_top_points_from_edges, + af_remove_bottom_points_from_edges): Removed. + (af_latin_stretch_top_tilde): Call `af_touch_top_contours` and + `af_touch_bottom_contours` unconditionally. + (af_latin_hints_apply): Updated. + +2025-05-16 Alexei Podtelezhnikov + + * src/truetype/ttinterp.c (TT_DotFix14): Silence UBSAN. + +2025-05-16 Alexei Podtelezhnikov + + * src/truetype/ttinterp.c (Ins_DELTAP): Flip if-else. + +2025-05-15 Alexei Podtelezhnikov + + [truetype] Optimize DELTAP and DELTAC. + + * src/truetype/ttinterp.c (Ins_DELTAP,DELTAC): Perform PPEM range- + checking and manipulations outside the loop. + +2025-05-14 Alexei Podtelezhnikov + + * src/truetype/ttinterp.c (Compute_Funcs): Replace shifts. + +2025-05-14 Alexei Podtelezhnikov + + [truetype] Tighten code overflow checks. + + Fixes #1336. + + * src/truetype/ttinterp.c (Ins_NPUSHB,NPUSHW,PUSHB, PUSHW): + Tighten conditions. + +2025-05-14 Chris Liddell + + [type1] Fix memory leak on CharString error. + + In the event that a CharString retrieved via the incremental interface + caused an error, the memory for that CharString was not being freed. + + * src/type1/t1gload.c (T1_Parse_Glyph_And_Get_Char_String): Free charstring. + +2025-05-14 Werner Lemberg + + Whitespace, formatting, minor spelling fix. + +2025-05-14 Werner Lemberg + + Adminstrativa. + +2025-05-13 Alexei Podtelezhnikov + + [truetype] Finalize bytecode changes. + + * src/truetype/ttinterp.c: Formatting, minor. + (TT_Goto_CodeRange): Initialize 'iniRange' here... + (TT_RunIns): ... instead of here. + * docs/CHANGES: Updated. + +2025-05-13 Alexei Podtelezhnikov + + [truetype] Streamline backward compatibility. + + The 'backward_compatibility' is only set in v40: no need to check + the interpreter version again and again. In addition, we now track + IUP in its lower bits. After both IUPx and IUPy have been called, + 'backward_compatibility' becomes equal to 0x7. + + * src/truetype/ttinterp.h (TT_ExecContextRec): Wrap 'iup?_called' + into 'backward_compatibility'. + * src/truetype/ttinterp.c (Ins_INSTCTRL): Sync 'backward_compatibility'. + (Direct_Move, Direct_Move_X/Y, Move_Zp2_Point, + Ins_FLIPPT,FLIPRGON,FLIPRGOFF,SHPIX,DELTAP): Updated. + (TT_RunIns): Do not mess with IUP flags. + * src/truetype/ttgload.c (tt_loader_init): Set 'backward_compatibility'. + (TT_Hint_Glyph): Updated. + +2025-05-10 Alexei Podtelezhnikov + + [truetype] Optimize bytecode movements. + + Replacing FT_MulDiv with FT_MulFix gives large performance gains. + + * src/truetype/ttinterp.h (TT_ExecContextRec): Store "projected" + freedom vector. + * src/truetype/ttinterp.c (Compute_Funcs): Compute "projected" + freedom vector. + (Direct_Move, Direct_Move_Orig, Compute_Point_displacement): Use it. + +2025-05-10 Alexei Podtelezhnikov + + [truetype] Simplify stack access. + + * src/truetype/ttinterp.c (Ins_MINDEX,CINDEX): Use local stack pointers. + (Ins_DELTAP,DELTAC): Ditto; limit the number of pairs before looping. + +2025-05-10 Alexei Podtelezhnikov + + [truetype] Tweak bytecode looping. + + * src/truetype/ttinterp.c (Ins_FLIPPT,SHP,SHPIX,IP,ALIGNRP): Handle + counters and stack locally. + (TT_RunIns): Updated. + +2025-05-10 Alexei Podtelezhnikov + + [truetype] Tweak bytecode initiation. + + * src/truetype/ttinterp.c (TT_Load_Context): Init stack tops. + * src/truetype/ttinterp.h (TT_ExecContextRec): Document it and clean. + * src/truetype/ttobjs.c (tt_size_run_prep,fpgm): Updated. + * src/truetype/ttgload.c (tt_loader_init): Minor. + +2025-05-10 Alexei Podtelezhnikov + + [truetype] Modify stack handling. + + * src/truetype/ttinterp.c (Ins_GETVARIATION): Increment stack. + (Ins_NPUSHB,NPUSHW,PUSHB,PUSHW): Handle the code stack here, ... + (TT_RunIns): ... instead of here. Consolidate error handling. + (SkipCode): Remove preemptive check. + +2025-05-10 Alexei Podtelezhnikov + + [truetype] Modify bytecode steps. + + * src/truetype/ttinterp.h (TT_Exec_ContextRec): Remove 'step_ins'. + * src/truetype/ttinterp.c (TT_RunIns, Ins_Goto_CodeRange, + Ins_JMPR,ENDF,PUSHW,NPUSHW): Set and use zero increment 'length' instead. + (Ins_CALL,LOOPCALL,UNKNOWN): Updated. + +2025-05-10 Werner Lemberg + + [autofit] Add safety check for accent adjustments. + + This commit does two things. + + - Ignore accents that have too large heights. This situation can happen if + an accent outline is unexpectedly not the highest (or lowest) contour. + - Add a new adjustment flag `AF_ADJUST_NO_HEIGHT_CHECK` to override the + height check. + + * src/autofit/afadjust.h (AF_ADJUST_NO_HEIGHT_CHECK): New macro. + + * src/autofit/afadjust.c (adjustment_database): Updated. + + * src/autofit/aflatin.c (af_latin_hints_apply): Handle new flag. + (af_glyph_hints_apply_vertical_separation_adjustments): Check limit. + +2025-05-10 Werner Lemberg + + [autofit] Better handling of characters with attached diacritics. (3/3) + + Fixes issue #136. + + * src/autofit/afadjust.c (adjustment_database): Updated. + +2025-05-10 Werner Lemberg + + [autofit] Better handling of characters with attached diacritics. (2/3) + + * src/autofit/afadjust.h (AF_IGNORE_CAPITAL_TOP, AF_IGNORE_CAPITAL_BOTTOM, + AF_IGNORE_SMALL_TOP, AF_IGNORE_SMALL_BOTTOM): New macros. + + * src/autofit/afadjust.c (af_reverse_character_map_new) + [FT_DEBUG_LEVEL_TRACE]: Updated. + Also fix debugging strings of other flags. + + * src/autofit/afhints.h (AF_EDGE_NO_BLUE): New edge flag to make the + auto-hinter ignore the edge while assigning blue zones. + + * src/autofit/aflatin.c (af_latin_hints_compute_blue_edges): Use it. + (af_prevent_top_blue_alignment, af_prevent_bottom_blue_alignment, + af_latin_get_base_glyph_blues, af_latin_ignore_top, + af_latin_ignore_bottom): New functions. + (af_latin_hints_apply): Updated. + +2025-05-10 Werner Lemberg + + [autofit] Better handling of characters with attached diacritics. (1/3) + + Introduce blue zone properties that will be used to make the auto-hinter + ignore diacritics attached on the top or the bottom of a base character. + + * src/autofit/afblue.hin (AF_BLUE_PROPERTY_LATIN_CAPITAL_BOTTOM, + AF_BLUE_PROPERTY_LATIN_SMALL_BOTTOM): New properties. + * src/autofit/afblue.dat: Use them. + + * src/autofit/afblue.c, src/autofit/afblue.h: Rengenerated. + + * src/autofit/aflatin.h (AF_LATIN_IS_CAPITAL_BOTTOM_BLUE, + AF_LATIN_IS_SMALL_BOTTOM_BLUE, AF_LATIN_BLUE_BOTTOM, + AF_LATIN_BLUE_BOTTOM_SMALL): New macros. + + * src/autofit/aflatin.c (af_latin_metrics_init_blues)[FT_DEBUG_LEVEL_TRACE]: + Updated. + +2025-05-09 Alexei Podtelezhnikov + + * src/raster/ftraster.c (Line_Up): Use 64-bit calculations. + + Attempt to fix #1332. + +2025-05-09 Werner Lemberg + + [sfnt] Avoid allocation bomb in compressed SVG documents. + + Reported as + + https://issues.oss-fuzz.com/issues/416538625 + + * src/sfnt/ttsvg.c (MAX_SVG_SIZE): New macro. + (tt_face_load_svg_doc): Reject too large buffer. + +2025-05-08 Werner Lemberg + + * include/freetype/ttnameid.h (TT_UCR_*): Define with unsigned long. + (TT_UCR_PHAGSPA): Fix definition. + + Fixes issue #1300. + +2025-05-08 Werner Lemberg + + [doc] Mention that there is no rendering support for 'COLR' v1 tables. + + Handles issue #1319. + +2025-05-08 Alexei Podtelezhnikov + + * src/truetype/ttinterp.c (TT_DotFix14): Silence UBSAN. + +2025-05-07 Alexei Podtelezhnikov + + * src/cff/cffgload.c (cff_slot_load): Fix autohinter scaling. + + Fixes #1330. + +2025-05-05 Werner Lemberg + + [autofit] Avoid division by zero. + + Fixes issue #1331. + + * src/autofit/aflatin.c (af_latin_stretch_bottom_tilde): Don't divide by + zero. + +2025-05-04 Carlo Bramini + + Fix Cygwin visibility attributes. + + Reported as compilation warnings in #1329. + + * include/freetype/config/public-macros.h: Check __CYGWIN__. + * include/freetype/internal/compiler-macros.h: Ditto. + +2025-05-03 KatekovAnton + + * CMakeLists.txt: Fix cmake 4 error by specifying the policy version. + +2025-04-29 Werner Lemberg + + * docs/CHANGES: Updated. + +2025-04-29 Behdad Esfahbod (بهداد اسفهبد) + + Provide configuration option to dynamically load the HarfBuzz library. + + We now request HarfBuzz version 2.6.8 (published in June 2020) or newer to + simplify the setup; this version introduced function + `hb_ot_layout_lookup_get_glyph_alternates`, which we need for the adjustment + database of the auto-hinter. + + No CMake support yet for dynamic loading. + + * include/freetype/config/ftoption.h, devel/ftoption.h + (FT_CONFIG_OPTION_USE_HARFBUZZ_DYNAMIC): New configuration macro. + + * builds/unix/configure.raw: Implement `--with-harfbuzz=dynamic`. + This gets tested automatically if we can't link with `libharfbuzz`. + (ft_option_set, ft_option_unset): Refine. + Require at least HarfBuzz version 2.6.8. + + * meson.build: Do the same as `configure.raw`. + * meson_options.txt: Updated. + + * CMakeLists.txt: Require at least HarfBuzz version 2.6.8. + +2025-04-29 Behdad Esfahbod (بهداد اسفهبد) + + [autofit] Enable dynamic loading of HarfBuzz. (2/2) + + Handle the case where loading HarfBuzz dynamically fails. + + * src/autofit/ft-hb.c, src/autofit/ft-hb.h (ft_hb_enabled): New function. + + * src/autofit/afglobal.c (af_face_globals_new, af_face_globals_free): + Guard HarfBuzz functions with `ft_hb_enabled`. + + * src/autofit/aflatin.c (af_latin_metrics_init_widths, + af_latin_metrics_init_blues, af_latin_metrics_check_digits): Simplify + setup of `shaper_buf`. + Guard calls of `af_shaper_buf_create` with `ft_hb_enabled`. + + * src/autofit/afcjk.c (af_cjk_metrics_init_widths, + af_cjk_metrics_init_blues, af_cjk_metrics_check_digits): Dito. + + * src/autofit/afshaper.c: Guard all HarfBuzz function calls with + `ft_hb_enabled`. + +2025-04-29 Behdad Esfahbod (بهداد اسفهبد) + + [autofit] Enable dynamic loading of HarfBuzz. (1/2) + + This commit activates the mini-HarfBuzz header files and provides the + necessary infrastructure for dynamically loading HarfBuzz if + `FT_CONFIG_OPTION_USE_HARFBUZZ_DYNAMIC` is defined (this macro gets set up + in a follow-up commit). + + * src/autofit/ft-hb.c: New file, providing `ft_hb_funcs_init` and + `ft_hb_funcs_done` for loading HarfBuzz dynamically. The name of the + library is hold in the macro `FT_LIBHARFBUZZ`, which can be overridden. + + * src/autofit/ft-hb.h: Don't include `hb.h` but `ft-hb-types.h`. + (hb): Modified to handle both standard linking and dynamically + loading of HarfBuzz. + (HB_EXTERN): New macro to load `ft-hb-decls.h`. + + * src/autofit/afadjust.c [FT_CONFIG_OPTION_USE_HARFBUZZ]: For the sake of + dynamically loading the HarfBuzz library, replace the compile-time macro + `HB_VERSION_ATLEAST` with a call to the run-time function + `hb_version_atleast` where necessary – a follow-up commit will set the + minimum version of HarfBuzz to 2.6.8, which provides all necessary + functions needed by FreeType. + + * src/autofit/afmodule.h: Include `ft-hb.h`. + (AF_ModuleRec) [FT_CONFIG_OPTION_USE_HARFBUZZ_DYNAMIC]: Add `hb_funcs` + structure to hold pointers to the dynamically loaded HarfBuzz functions. + + * src/autofit/afmodule.c (af_autofitter_init, af_autofitter_done) + [FT_CONFIG_OPTION_USE_HARFBUZZ_DYNAMIC]: Call `ft_hb_funcs_init` and + `ft_hb_funcs_done`. + + * src/autofit/afshaper.h: Updated. + * src/autofit/autofit.c: Include `ft-hb.c`. + + * src/autofit/rules.mk (AUTOF_DRV_SRC, AUTOF_DRV_H): Updated. + +2025-04-29 Behdad Esfahbod (بهداد اسفهبد) + + [autofit] Some preparations for loading HarfBuzz dynamically. (4/4) + + Add 'mini' HarfBuzz declarations to make FreeType independent on HarfBuzz + header files. + + The files get activated in a follow-up commit. + + * src/autofit/ft-hb-decls.h, src/autofit/ft-hb-types.h: New files, holding + verbatim (or slightly massaged) entries from public HarfBuzz header files. + + * src/autofit/hb-script: New file. + A verbatim copy of a public HarfBuzz header file. + +2025-04-29 Behdad Esfahbod (بهداد اسفهبد) + + [autofit] Some preparations for loading HarfBuzz dynamically. (3/4) + + * src/autofit/afshaper.c: Move around code so that the non-HarfBuzz code is + present even if `FT_CONFIG_OPTION_USE_HARFBUZZ` is not defined. This is a + preliminary step to allow deactivation of HarfBuzz at run-time. + +2025-04-29 Behdad Esfahbod (بهداد اسفهبد) + + [autofit] Some preparations for loading HarfBuzz dynamically. (2/4) + + Pass `AF_FaceGlobals` to many functions, or provide it, tagged with + `FT_UNUSED`. We need this later on to access a dynamically linked HarfBuzz + library. + + * src/autofit/ft-hb-ft.h (ft_hb_ft_font_create): Use `globals` argument. + Drop unused `destroy` argument. + * src/autofit/ft-hb-ft.c (ft_hb_ft_face_create, ft_hb_ft_font_create): Use + `globals` argument. + Drop unused `destroy` argument. + (ft_hb_ft_face_create, ft_hb_ft_reference_table): Cast `user_data` to + `AF_FaceGlobals`. + + * src/autofit/afadjust.c (af_get_glyph_alternates_helper, + af_get_glyph_alternates): Add `globals` argument. + Update callers. + + * src/autofit/afshaper.c, src/autofit/afshaper.h (af_shaper_buf_create, + af_shaper_buf_destroy): Use `globals` argument. + + * src/autofit/afglobal.c (af_face_globals_new): Updated. + + * src/autofit/afcjk.c (af_cjk_metrics_init_widths, + af_cjk_metrics_init_blues, af_cjk_metrics_check_digits): Updated. + * src/autofit/aflatin.c (af_latin_metrics_init_widths, + af_latin_metrics_init_blues, af_latin_metrics_check_digits): Updated. + +2025-04-29 Behdad Esfahbod (بهداد اسفهبد) + + [autofit] Some preparations for loading HarfBuzz dynamically. (1/4) + + * src/autofit/ft-hb.h: New file, defining the `hb` macro. Later on, we + provide a different definition of this macro depending on a yet-to-come + configuration option to support dynamic loading of HarfBuzz functions. + + * src/autofit/afadjust.c, src/autofit/afglobal.c, src/autofit/afshaper.c, + stc/ft-hb-ft.c: Use it. + +2025-04-29 Behdad Esfahbod (بهداد اسفهبد) + + [autofit] Rename 'ft-hb' to 'ft-hb-ft'. + + Since it's a (shrinked) copy of 'hb-ft'. + + * src/autofit/afglobal.c (af_face_globals_new), src/autofit/afshaper.h, + src/autofit/autofit.c: Updated. + + * src/autofit/ft-hb.c, src/autofit/ft-hb.h: Renamed to... + * src/autofit/ft-hb-ft.c, src/autofit/ft-hb-ft.h: ...this; updated. + + * src/autofit/rules.mk (AUTOF_DRV_SRC): Updated. + +2025-04-29 Werner Lemberg + + * src/autofit/aflatin.c (af_latin_stretch_top_tilde): Don't divide by zero. + + Reported as + + https://issues.oss-fuzz.com/issues/414320186 + +2025-04-28 Werner Lemberg + + [autofit] Extend adjustment database with characters up to U+1FFF. + + This adds many pre-combined Latin glyphs, Cyrillic, Greek, and some + characters from other scripts (or rather, Unicode blocks). + + Fixes issues #112 and #471. + +2025-04-28 Werner Lemberg + + [autofit] Support diacritics with special vertical minima. + + This code catches situations like U+1F90 ('ᾐ'), where some fonts have + exactly the same vertical minimum for the lower accent as for the base + glyph. + + * src/autofit/aflatin.c (af_find_highest_contour, af_find_lowest_contour): + Handle it. + +2025-04-28 Werner Lemberg + + [autofit] More tilde stretch support. (3/3) + + The auto-hinter now supports up to four tilde glyphs (two above and two + below a base character). + + Note that diacritics above (or below) a tilde are now also ignored by the + auto-hinter. + + * src/autofit/afadjust.h (AF_ADJUST_TILDE_TOP2, AF_ADJUST_TILDE_BOTTOM2): + New macros. + * src/autofit/afadjust.c (af_reverse_character_map_new): Updated. + + * src/autofit/aflatin.c (af_remove_top_points_from_edges, + af_remove_bottom_points_from_edges): Make functions also handle all + contours higher (or lower) of the given one in the argument. + (af_touch_top_contours, af_touch_bottom_contours): New functions. + (af_latin_stretch_top_tilde, af_latin_stretch_bottom_tilde): Use it to + also handle all contours higher (or lower) than the tilde contour. + + * (af_latin_hints_apply): Handle more tilde glyphs. + +2025-04-28 Werner Lemberg + + [autofit] More tilde stretch support. (2/3) + + * src/autofit/aflatin.c (af_latin_stretch_top_tilde, + af_latin_stretch_bottom_tilde): Return vertical size difference between + stretched and original contour. + (af_latin_align_top_tilde, af_latin_align_bottom_tilde): Return applied + delta. + (af_latin_hints_apply): Updated; the return values are not used yet. + +2025-04-28 Werner Lemberg + + [autofit] More tilde stretch support. (1/3) + + Move some existing code that we soon need elsewhere into separate functions. + + * src/autofit/aflatin.c (af_move_contours_up, af_move_contours, down): New + functions. + (af_glyph_hints_apply_vertical_separation_adjustments): Use them. + (af_touch_contour): New function. + (af_latin_stretch_top_tilde, af_latin_stretch_bottom_tilde): Use it. + + (af_latin_remove_top_tilde_points_from_edges, + af_latin_remove_bottom_tilde_points_from_edges): Renamed to... + (af_remove_top_points_from_edges, af_remove_bottom_points_from_edges): + ...this. + Update callers. + +2025-04-28 Werner Lemberg + + [autofit] Support two below/above accents for vertical adjustment. (2/2) + + * src/autofit/afadjust.h (AF_ADJUST_UP2, AF_ADJUST_DOWN2): New macros. + * src/autofit/afadjust.c (af_reverse_character_map_new): Updated. + + * src/autofit/aflatin.c + (af_glyph_hints_apply_vertical_separation_adjustments): Implement it. + +2025-04-28 Werner Lemberg + + [autofit] Support two below/above accents for vertical adjustment. (1/2) + + Some variable renamings. + +2025-04-28 Werner Lemberg + + [autofit] Routines for finding the second highest/lowest contour. + + * src/autofit/aflatin.c (af_find_second_highest_contour, + af_find_second_lowest_contour): New functions. + +2025-04-28 Werner Lemberg + + [autofit] Use more functions to reduce code. + + * src/autofit/aflatin.c (af_find_highest_contour, af_find_lowest_contour): + Updated. + (af_glyph_hints_apply_vertical_separation_adjustments): Use + `af_compute_vertical_extrema`, `af_find_highest_contour`, and + `af_find_lowest_contour`. + (af_latin_hints_apply): Use `af_compute_vertical_extrema`, + +2025-04-28 Werner Lemberg + + * src/autofit/aflatin.c (af_compute_vertical_extrema): New function. + + To be used in a follow-up commit. + +2025-04-28 Werner Lemberg + + * src/autofit/aflatin.c: Some variable renaming. + +2025-04-28 Werner Lemberg + + [autofit] Avoid recomputation of highest and lowest contour. + + * src/autofit/aflatin.c (af_latin_hints_apply): Compute highest and lowest + contour in this function. + (af_latin_remove_top_tilde_points_from_edges, + af_latin_remove_bottom_tilde_points_from_edges, + af_latin_stretch_top_tilde, af_latin_stretch_bottom_tilde, + af_latin_align_top_tilde, af_latin_align_bottom_tilde): Updated. + +2025-04-28 Werner Lemberg + + * src/aflatin.c (af_latin_trace_height): Remove. + Update caller. + + The algorithm works fine. + +2025-04-28 Werner Lemberg + + [autofit] Support vertical stretching of tilde below base glyph. (2/2) + + * src/autofit/afadjust.h (AF_ADJUST_TILDE_BOTTOM): New macro. + * src/autofit/afadjust.c (af_reverse_character_map_new): Updated. + + * src/autofit/aflatin.c (af_find_lowest_contour, + af_latin_remove_bottom_tilde_points_from_edges, + af_latin_stretch_bottom_tilde, af_latin_align_bottom_tilde): New functions + in analogy to the top tilde versions. + (af_glyph_hints_apply_vertical_separation_adjustments): Add support in + analogy to the top tilde code. + (af_latin_hints_apply): Updated. + +2025-04-28 Werner Lemberg + + [autofit] Support vertical stretching of tilde below base glyph. (1/2) + + * src/autofit/aflatin.c (af_latin_remove_tilde_points_from_edges, + af_latin_stretch_tilde, af_latin_align_tilde): Rename to... + (af_latin_remove_top_tilde_points_from_edges, af_latin_stretch_top_tilde, + af_latin_align_top_tilde): ...this. + Update all callers. + (af_latin_hints_apply): Rename `is_tilde` to `is_top_tilde`. + +2025-04-28 Werner Lemberg + + [autofit] Allow vertical adjustment at the top and bottom simultaneously. + + This will be used to hint characters like U+1FB7 ('ᾷ'). + + * src/autofit/aflatin.c + (af_glyph_hints_apply_vertical_separation_adjustments): Implement it. + +2025-04-28 Werner Lemberg + + * src/autofit/afadjust.c (af_reverse_character_map_new): Update tracing. + +2025-04-28 Werner Lemberg + + [autofit] Indicate tilde handling with a flag macro, too. + + * src/autofit/afadjust.h (AF_ADJUST_TILDE_TOP): New macro. + (AF_AdjustmentDatabaseEntry): Remove field `apply_tilde`. + + * src/autofit/afadjust.c (adjustment_database, + af_reverse_character_map_new), src/autofit/aflatin.c + (af_glyph_hints_apply_vertical_separation_adjustments, + af_latin_hints_apply): Updated. + +2025-04-28 Werner Lemberg + + [aflatin] Convert adjustment database enum to macros. + + We are going to add more values, and we want to use combinations of them. + + * src/autofit/afadjust.h (AF_VerticalSeparationAdjustmentType): Replace + with... + (AF_ADJUST_UP, AF_ADJUST_DOWN, AF_ADJUST_NONE): ... new macros. + (AF_AdjustmentDatabaseEntry): Rename field + `vertical_separation_adjustment_type` to `flags`. + + * src/autofit/afadjust.c (af_reverse_character_map_new), + src/autofit/aflatin.c + (af_glyph_hints_apply_vertical_separation_adjustments): Updated. + +2025-04-28 Werner Lemberg + + [autofit] Shorten adjustment enum names. + + * src/autofit/afadjust.h (AF_VERTICAL_ADJUSTMENT_TOP_CONTOUR_UP, + AF_VERTICAL_ADJUSTMENT_BOTTOM_CONTOUR_DOWN, AF_VERTICAL_ADJUSTMENT_NONE): + Renamed to... + (AF_ADJUST_UP, AF_ADJUST_DOWN, AF_ADJUST_NONE): ...this. + + * src/autofit/afadjust.c (adjustment_database, + af_reverse_character_map_expand), src/autofit/aflatin.c + (af_glyph_hints_apply_vertical_separation_adjustments): Updated. + +2025-04-26 Werner Lemberg + + * src/autofit/afranges.c: Updated to Unicode 17.0. + + But no support for new scripts (volunteers welcomed). + +2025-04-26 Werner Lemberg + + * src/autofit/afranges.c: Updated to Unicode 16.0. + + But no support for new scripts (volunteers welcomed). + +2025-04-26 Werner Lemberg + + * src/autofit/afranges.c: Updated to Unicode 15.1. + + But no support for new scripts (volunteers welcomed). + +2025-04-26 Werner Lemberg + + * src/autofit/afranges.c: Updated to Unicode 14.0. + + But no support for new scripts (volunteers welcomed). + +2025-04-26 Werner Lemberg + + * src/autofit/afranges.c: Updated to Unicode 13.0. + + But no support for new scripts (volunteers welcomed). + +2025-04-26 Werner Lemberg + + * src/autofit/afranges.c: Updated to Unicode 12.0. + + But no support for new scripts (volunteers welcomed). + +2025-04-25 Alexei Podtelezhnikov + + * include/freetype/internal/ftcalc.h (FT_MulFix_64): Silence UBSAN. + +2025-04-22 Behdad Esfahbod + + * src/autofit/afadjust.c (af_get_glyph_alternates): Fix endless loop. + +2025-04-20 Werner Lemberg + + * src/afadjust.c: Fix test for newer HarfBuzz version (second try). + +2025-04-20 Werner Lemberg + + * src/afadjust.c: Fix test for newer HarfBuzz version. + +2025-04-20 Werner Lemberg + + [autofit] Request at least HarfBuzz 7.2.0 for diacritic support. (3/3) + + This version (from April 2023) added 'SingleSubst' support to + `hb_ot_layout_lookup_get_glyph_alternates`. + +2025-04-20 Werner Lemberg + + [autofit] Speed up creation of the adjustment database's reverse map. (2/3) + + Remove the old code and activate the new one. + +2025-04-20 Werner Lemberg + + [autofit] Speed up creation of the adjustment database's reverse map. (1/3) + + As it turns out, the original implementation using + `hb_ot_shape_glyphs_closure` is extremely slow if a font has a rich set of + OpenType features. For example, this function was called 66954 times while + loading font `arial.ttf` version 7.00, increasing FreeType's startup time by + a factor of 10, which is unacceptable. + + The new algorithm uses a completely different, more low-level approach, no + longer working with OpenType features but with OpenType lookups. It relies + on function `hb_ot_layout_lookup_get_glyph_alternates`, also replacing + recursion with a simple loop. In total, this brings the additional startup + time back to an acceptable range of a few percent. + + A side effect of the new approach is that it catches more alternate forms: + the old code didn't properly handle script-specific features. + + To make the change more readable, this commit only adds new code. + +2025-04-18 Werner Lemberg + + * src/autofit/afadjust.c (af_reverse_character_map_new): Check `map` limit. + + Reported as + + https://issues.chromium.org/issues/410925355 + +2025-04-18 Alexei Podtelezhnikov + + * include/freetype/internal/ftcalc.h: Fix fringe compilation. + +2025-04-18 Alexei Podtelezhnikov + + * src/base/ftcalc.c (ft_corner_orientation) [!FT_INT32]: Fix up. + +2025-04-17 Werner Lemberg + + [autofit] Don't access uninitialized memory. + + Reported as + + https://bugs.ghostscript.com/show_bug.cgi?id=708295 + + * src/autofit/aflatin.c + (af_glyph_hints_apply_vertical_separation_adjustments): Initialize all + array elements of `contour_y_minima` and `contour_y_maxima`. + +2025-04-17 Alexei Podtelezhnikov + + * src/truetype/ttinterp.c (TT_MulFix14,TT_DotFix14)[!FT_INT64]: Sync. + +2025-04-17 Alexei Podtelezhnikov + + * src/truetype/ttinterp.c (TT_DotFix14): Silence UBSAN. + +2025-04-17 Alexei Podtelezhnikov + + * src/base/ftcalc.c: Miscellaneous cleanups. + +2025-04-16 Werner Lemberg + + [autofit] Avoid crash. + + Reported as + + https://issues.oss-fuzz.com/issues/410811029 + + * src/autofit/aflatin.c (af_remove_segments_containing_point): Check + `edge->last`. + +2025-04-15 Alexei Podtelezhnikov + + [base, truetype] Silence UBSAN (cont'd). + + * src/truetype/ttinterp.c (TT_MulFix14, TT_DotFix14): Use MUL_INT64. + * include/freetype/internal/ftcalc.c (FT_MulFix): Ditto. + +2025-04-15 Werner Lemberg + + [autofit] Avoid unnecessary recomputation of HarfBuzz data. + + Call the functions once per font instead of once per glyph. + + * src/autofit/afadjust.c (af_all_glyph_variants): Move code to compute the + `feature_tags` and `type_3_lookup_indices` sets to... + (af_reverse_character_map_new): ...this function. + +2025-04-15 Werner Lemberg + + [autofit] Fix creation of the adjustment database's reverse map. + + Due to the way the reverse map array gets constructed with HarfBuzz, there + might be multiple, identical glyph index entries with different character + values in the array. As an example, an OpenType feature like 'unic' might + map lowercase glyph 'ae' to uppercase glyph 'AE', in addition to the already + present cmap entry for 'AE'. + + In most cases, this incorrect mapping is harmless (but still wrong). + However, there exist some lowercase/uppercase character pairs where the + diacritic for the uppercase character is on the other vertical side of the + base character as for the lowercase character. An example is U+0122 (LATIN + CAPITAL LETTER G WITH CEDILLA) and U+0123 (LATIN SMALL LETTER G WITH + CEDILLA): the former has the cedilla below, the latter above. A wrong + mapping would thus shift the base glyph 'G' up by a pixel instead of + shifting the cedilla down. + + We fix this by always giving precedence to cmap entries. + + * src/autofit/afadjust.c (af_reverse_character_map_entry_compare): Do a + secondary sort on the character code. + + (af_reverse_character_map_lookup): Adjust binary search to return the + first occurrence of an entry (i.e., the one with the lowest array index). + + (af_reverse_character_map_new)[FT_CONFIG_OPTION_USE_HARFBUZZ]: Implement + cmap priority. + +2025-04-15 Werner Lemberg + + [autofit] Reduce adjustment database lookups. + + This is also in preparation for a follow-up commit. + + * src/autofit/afadjust.h (af_lookup_vertical_separation_type, + af_lookup_tilde_correction_type): Replaced with... + (af_adjustment_database_lookup, af_reverse_character_map_lookup): + ... this. + + * src/autofit/afadjust.c (af_adjustment_database_lookup, + af_adjustment_database_lookup): Updated. + (af_lookup_vertical_separation_type, af_lookup_tilde_correction_type): + Removed. + (af_reverse_character_map_new)[FT_DEBUG_LEVEL_TRACE]: Updated. + + * src/autofit/aflatin.c + (af_glyph_hints_apply_vertical_separation_adjustments, + af_latin_hints_apply): Updated. + +2025-04-15 Werner Lemberg + + * src/afadjust.c (adjustment_database): Make it complete up to U+017F. + +2025-04-15 Werner Lemberg + + * src/autofit/afadjust.c (af_reverse_character_map_new): Add tracing code. + +2025-04-15 Werner Lemberg + + * src/afadjust.c: Minor fixes. + +2025-04-15 Werner Lemberg + + [autofit] Better vertical separation adjustment support. (2/2) + + * src/autofit/aflatin.c + (af_glyph_hints_apply_vertical_separation_adjustments): Handle diacritics + with more than a single contour. + +2025-04-15 Werner Lemberg + + [autofit] Better vertical separation adjustment support. (1/2) + + Test vertical maxima instead of vertical minima to identify the highest + contour (and vice versa to identify the lowest contour). Doing so will + allow support of diacritics that consist of more than a single outline. + + This works because of the topological constraints ensured by the adjustment + database. + + * src/autofit/aflatin.c (af_find_highest_contour, + af_glyph_hints_apply_vertical_separation_adjustments): Implement it. + +2025-04-15 Werner Lemberg + + [autofit] Use new y extrema arrays. + + * src/autofit/aflatin.c + (af_glyph_hints_apply_vertical_separation_adjustments): Implement it. + +2025-04-15 Werner Lemberg + + [autofit] Provide infrastructure for storing y extrema of contours. + + We need this for better positioning support of diacritics. + + * src/autofit/afhints.h (AF_GlyphHintsRec): New fields `contour_y_minima` + and `contour_y_maxima`, together with its embedded variants. + + * src/autofit/afhints.c (af_glyph_hints_done, af_glyph_hints_reload): Handle + new arrays. + +2025-04-15 Werner Lemberg + + [autofit] Avoid crash. + + Reported as + + https://issues.oss-fuzz.com/issues/410609442 + + * src/autofit/aflatin.c (af_remove_segments_containing_point): Check `edge`. + +2025-04-14 Werner Lemberg + + [autofit] Fix just introduced heap buffer overflow + + Reported as + + https://issues.oss-fuzz.com/issues/410393975 + + * src/autofit/afadjust.c [!FT_CONFIG_OPTION_USE_HARFBUZZ]: Synchronize with + HarfBuzz code. + +2025-04-14 Werner Lemberg + + * docs/CHANGES: Mention Craig's GSoC 2023 project. + +2025-04-14 Craig White + + [autofit] Add GSUB table handling to reverse character map generation. + + If HarfBuzz is enabled, the reverse character map generation now considers + GSUB entries when looking for glyphs that correspond to a code point. + + * src/autofit/afadjust.c (af_all_glyph_variants_helper, + af_all_glyph_variants) [FT_CONFIG_OPTION_USE_HARFBUZZ]: New functions. + + (af_reverse_character_map_new) [FT_CONFIG_OPTION_USE_HARFBUZZ]: Call new + code. + +2025-04-14 Craig White + + [autofit] Add tilde-unflattening algorithm. + + * src/autofit/aflatin.c (af_find_highest_contour, + af_remove_segments_containing_point, + af_latin_remove_tilde_points_from_edges, af_latin_stretch_tilde, + af_latin_align_tilde): New functions. + (af_latin_hints_apply): Call tilde-unflatting code if necessary. + +2025-04-14 Craig White + + [autofit] Implement vertical separation adjustment. + + * src/autofit/aflatin.c: Include `afadjust.h`. + (af_latin_metrics_init): Call `af_reverse_character_map_new`. + (af_latin_metrics_done): New function. + + (af_move_contour_vertically, af_check_contour_horizontal_overlap, + af_glyph_hints_apply_vertical_separation_adjustments): New functions. + + (af_latin_hints_apply): Call + `af_glyph_hints_apply_vertical_separation_adjustments`. + + (af_latin_writing_system_class): Updated. + + * src/autofit/aftypes.h (AF_StyleMetricsRec): Add `reverse_charmap` field. + +2025-04-14 Craig White + + [autofit] Add code for reverse charmaps and adjustment database lookup. + + * src/autofit/aftypes.h (AF_ReverseMapEntry, AF_ReverseCharacterMap): New + structures. + + * src/autofit/afadjust.c (af_adjustment_database_lookup, + af_reverse_character_map_entry_compare, af_reverse_character_map_lookup, + af_lookup_vertical_separation_type, af_lookup_tilde_correction_type, + af_reverse_character_map_expand, af_reverse_character_map_new, + af_reverse_character_map_done): New functions. + + * src/autofit/afadjust.c: Updated. + +2025-04-14 Craig White + + [autofit] Add adjustment database. + + * src/autofit/afadjust.c, src/autofit/afadjust.h: New files. + + * include/freetype/internal/fttrace.h: Add 'afadjust' component. + + * src/autofit/autofit.c: Include `afadjust.c`. + + * src/autofit/rules.mk (AUTOF_DRV_SRC): Add `afadjust.c`. + +2025-04-14 Craig White + + [base] Make `find_unicode_charmap` a base function. + + This is needed for forthcoming changes in the auto-hinter. + + * include/freetype/internal/ftobjs.h, src/base/ftobjs.c: Updated. + +2025-04-12 Alexei Podtelezhnikov + + * src/bdf/bdflib.c (hdigits): Removed. + + Fixes #1325. + +2025-04-12 Alexei Podtelezhnikov + + * include/freetype/internal/ftcalc.h (FT_MSB) [__CC_ARM]: Added. + +2025-04-12 Alexei Podtelezhnikov + + Typos in macros. + + * include/freetype/internal/ftcalc.h: s/_M_X86/_M_IX86/. + * src/truetype/ttinterp.c: s/_M_X86/_M_IX86/. + +2025-04-12 Alexei Podtelezhnikov + + * docs/CHANGES: Updated. + +2025-04-12 Alexei Podtelezhnikov + + [base, truetype] Silence UBSAN. + + * src/truetype/ttinterp.c (TT_MulFix14_64): Use unsigned multiplication. + * include/freetype/internal/ftcalc.h (FT_MulFix_64): Ditto. + +2025-04-12 Alexei Podtelezhnikov + + [base, truetype] Synchronize MulFix assembly. + + * include/freetype/internal/ftcalc.h (FT_MulFix_*), + src/truetype/ttinterp.c (TT_MulFix14_*): Synchronize routines. + +2025-04-10 Alexei Podtelezhnikov + + [truetype] Modernize bytecode projections. + + With 64-bit platforms widely available, it is more efficient to use + 64-bit variables readily. It results in noticeable 10% improvement + in glyph loading speed. + + * src/truetype/ttinterp.c (TT_MulFix14, TT_DotFix14) [FT_INT64]: + Prioritize available implementation with arguments adjusted based on + the use cases. + +2025-04-09 Alexei Podtelezhnikov + + [base] Update FT_MulFix inlining. + + Resolves inconsistencies in 64-bit multiplication discussed in !355. + Importantly, FT_MulFix arguments and return value is FT_Long, + whatever sizeof FT_Long is on 64-bit platforms: 8 bytes on Linux or + 4 bytes on Windows. + + * include/freetype/internal/ftcalc.h (FT_MulFix_x86_64): Removed. + (FT_MulFix_64): Generalize and prioritize the inline implementation + for all 64-bit platforms ifdef FT_INT64. + * src/base/ftcalc.c (FT_MulFix)[FT_INT64]: Call 'FT_MulFix_64'. + * src/base/ftbase.c: Include 'ftcalc.c' after the FT_MulFix callers + to enable its inlining. + +2025-04-09 Alexei Podtelezhnikov + + [base] Update FT_MulFix inlining. + Resolves inconsistencies in 64-bit multiplication discussed in !355. Importantly, FT_MulFix arguments and return value is FT_Long, whatever sizeof FT_Long is on 64-bit platforms: 8 bytes on Linux or 4 bytes on Windows. * include/freetype/internal/ftcalc.h (FT_MulFix_x86_64): Removed. (FT_MulFix_64): Generalize and prioritize the inline implementation + for all 64-bit platforms ifdef FT_INT64. * src/base/ftcalc.c (FT_MulFix)[FT_INT64]: Call 'FT_MulFix_64'. * src/base/ftbase.c: Include 'ftcalc.c' after the FT_MulFix callers to enable its inlining. + +2025-04-05 Graham Asher + + Missing header wrappers. + + * include/freetype/config/integer-types.h, src/smooth/ftgrays.h: + Add missing FT_BEGIN_HEADER and FT_END_HEADER. + * src/smooth/ftgrays.c: Cosmetics. + +2025-03-26 Alexei Podtelezhnikov + + [bdf] Clarify callback flow. + + * src/bdf/bdflib.c (bdf_line_func_t_): Modify callback prototype. + (bdf_parse_*_): Updated. + (bdf_load_font, bdf_readstream_): Delay callback initiation. + +2025-03-26 Alexei Podtelezhnikov + + * src/bdf/bdflib.c (bdf_readstream_): Relocate. + +2025-03-26 Alexei Podtelezhnikov + + * src/bdf/bdflib.c (bdf_is_atom_): Do not check tabs. + +2025-03-26 Alexei Podtelezhnikov + + * src/bdf/bdflib.c (_bdf_strncmp): Macro removed, callers updated. + +2025-02-26 Alexei Podtelezhnikov + + .gitlab-ci.yml: Minor. + +2025-02-26 Tim-Philipp Müller + + * .gitlab-ci.yml: Switch to arm64 runners for macOS CI. + +2025-02-25 Behdad Esfahbod + + [sfnt/CPAL] Return early if user requested currently-set palette + + Before, we were loading a palette (again and again) even if the + same was requested. Even if the font only had one palette... + + For a font like NotoColorEmoji that has over 5000 colors in its + palette, this was dominating the COLRv1 loading times for HarfBuzz + (and I believe all other clients) because they have to set the + palette to get access to the colors. + + * src/base/ftcolor.c (FT_Palette_Select): Check the current palette. + +2025-01-29 Alexei Podtelezhnikov + + * src/bdf/bdflib.c (bdf_parse_start_): Move setup of properties. + +2025-01-25 Alexei Podtelezhnikov + + [bdf] Treat all comments uniformly. + + * src/bdf/bdflib.c (bdf_parse_start_): Reject fonts with initial + COMMENTs. + (bdf_parse_properties_): Skip COMMENTs so that... + (bdf_add_property_): Do not make exception for COMMENT. + (bdf_parse_glyphs_, bdf_add_comments): Updated. + +2025-01-25 Alexei Podtelezhnikov + + * src/bdf/bdflib.c (BDF_SWIDTH_ADJ_): Remove clashing flag and update. + +2025-01-23 Alexei Podtelezhnikov + + * src/bdf/bdflib.c (bdf_atous_): Remove unnecessary checks. + +2025-01-23 Alexei Podtelezhnikov + + * src/bdf/bdflib.c (bdf_ato{i.ul.s.us}_]): Remove uncecessary checks. + +2025-01-23 Alexei Podtelezhnikov + + [bdf] Postpone font default char handling. + + * src/bdf/bdflib.c (bdf_parse_start_, bdf_add_property_): Delay handling + of the default char until... + * src/bdf/bdfdrivr.c (BDF_Face_Init): ... handles all other properties. + +2025-01-23 Alexei Podtelezhnikov + + [bdf] Postpone font spacing handling. + + * src/bdf/bdf.h (bdf_font_t): Remove `monowidth`. + * src/bdf/bdflib.c (bdf_parse_start_, bdf_add_property_): Delay handling + of the font spacing until... + * src/bdf/bdfdrivr.c (BDF_Face_Init): ... handles all other properties. + +2025-01-23 Alexei Podtelezhnikov + + [bdf] Postpone font ascent and descent handling. + + * src/bdf/bdflib.c (bdf_parse_start_, bdf_add_property_): Delay handling + of the font ascent and descent until... + * src/bdf/bdfdrivr.c (BDF_Face_Init): ... handles all other properties. + +2025-01-22 Alexei Podtelezhnikov + + * src/bdf/bdflib.c (bdf_parse_start_): Relax the header order. + + We now check that the header is complete in no specific order. + +2025-01-20 Chad Brokaw + + * src/truetype/ttgxvar.c (tt_face_vary_cvt): Fix all shared values. + + Applying cvar deltas to all shared points was incorrectly omitted. + Fixes #1314. + +2025-01-19 Alexei Podtelezhnikov + + * src/bdf/bdflib.c (bdf_parse_glyphs_): Fix tracing. + +2025-01-19 Alexei Podtelezhnikov + + [bdf] Tokenize input instead of listing. + + Instead of cumbersome field list mamangement, we will tokenize input + using custom `bdf_strtok_`. + + * src/bdf/bdflib.c (bdf_list_t_, bdf_list_init_, bdf_list_ensure_, + bdf_list_shift_, bdf_list_join_, bdf_list_split_, + bdf_set_default_spacing_): Removed. + (bdf_strtok_): New function which NUL-terminates the first token at + the delimiter position and returns the next token that follows + consequtive delimiters. + (bdf_parse_*_, bdf_load_font): Updated. + + * docs/CHANGES: Claim overall 75% performance improvement. + +2025-01-18 Alexei Podtelezhnikov + + * src/bdf/bdflib.c (bdf_parse_start_): Prevent another STARTPROPERTIES. + + Only one STARTPROPERTIES was permitted in the old flow preventing + leaks and overflows. + + See https://issues.oss-fuzz.com/issues/389968131 + https://issues.oss-fuzz.com/issues/390464875 + +2025-01-17 Alexei Podtelezhnikov + + * src/bdf/bdflib.c (bdf_parse_start_): Do not overwrite flags. + +2025-01-16 Alexei Podtelezhnikov + + * src/bdf/bdflib.c (bdf_readstream_): Skip all control characters. + + This agrees with specifications and makes the code a lot simpler. + +2025-01-16 Alexei Podtelezhnikov + + * src/bdf/bdflib.c (bdf_parse_start_): Reserve space for artificial properties. + +2025-01-15 Alexei Podtelezhnikov + + * src/bdf/bdflib.c (bdf_add_property_): Add extra protection. + + See https://issues.oss-fuzz.com/issues/389972472 + https://issues.oss-fuzz.com/issues/389968131 + +2025-01-15 Alexei Podtelezhnikov + + * src/bdf/bdflib.c: Clean up. + +2025-01-15 Alexei Podtelezhnikov + + [bdf] Use flags instead of options. + + * src/bdf/bdf.h (bdf_options_t): Removed. + (BDF_KEEP_COMMENTS, BDF_KEEP_UNENCODED, BDF_CORRECT_METRICS): Updated + to avoid collisions with the other parsing flags. + * src/bdf/bdfdrivr.c (BDF_Face_Init): Use default flags explicitly. + * src/bdf/bdflib.c (bdf_load_font): Use flags as an argument to + initialize the parser. + (bdf_set_fedault_spacing_): Default to BDF_PROPORTIONAL explicitly. + (bdf_parse_*_): Updated. + +2025-01-15 Alexei Podtelezhnikov + + [bdf] Adjust parsing flow and CHARS handling. + + * src/bdf/bdflib.c (bdf_readstream_): Remove CHARS exception. + (bdf_parse_glyphs_): Move glyphs allocation... + (bdf_parse_properties_): and missing ascent and descent handling... + (bdf_parse_start_): ...to here under CHARS. + +2025-01-15 Alexei Podtelezhnikov + + * src/bdf/bdflib.c (bdf_readstream_): Tweak variables and loop design. + +2025-01-13 Alexei Podtelezhnikov + + * src/bdf/bdflib.c (bdf_parse_glyphs_): Free unused glyph_name. + + See https://issues.oss-fuzz.com/issues/389330334. + +2025-01-13 Alexei Podtelezhnikov + + * src/bdf/bdflib.c (bdf_parse_glyphs_): Store glyph as soon as possible. + +2025-01-12 Alexei Podtelezhnikov + + * src/bdf/bdflib.c (bdf_parse_glyphs_): Avoid possible leak. + +2025-01-12 Alexei Podtelezhnikov + + [bdf] Speed up bitmap parsing. + + A dedicated parser of bitmap data with minimal error checking and + no string comparisons helps to improve performance. + + * src/bdf/bdflib.c (bdf_parse_bitmap_): New dedicated bitmap parser. + (bdf_parse_glyphs_): Pass to `bdf_parse_bitmap_` on BITMAP. + +2025-01-12 Alexei Podtelezhnikov + + * src/bdf/bdflib.c (a2i): Formatting. + +2025-01-11 Alexei Podtelezhnikov + + * src/bdf/bdflib.c (bdf_parse_*_): Minor improvements. + +2025-01-11 Alexei Podtelezhnikov + + * src/bdf/bdf.h (bdf_font_t): Correct `internal` type. + * src/bdf/bdflib.c (*): Update users. + +2025-01-10 Alexei Podtelezhnikov + + * builds/windows/ftsystem.c: Fix ancient condition. + +2025-01-10 Alexei Podtelezhnikov + + * src/bdf/bdflib.c (bdf_parse_start_): Fix tracing labels. + +2025-01-09 Alexei Podtelezhnikov + + * MSBuild.rsp: Force console color for mintty. + +2025-01-09 Heiko Lewin + + * CMakeLists.txt: Use modern IMPORTED targets. + + This resolves build problems with newer libPNG versions by switching + to using IMPORTED CMake targets for common libraries where provided. + To do this the required CMake version is raised to version 3.12. + Doing this seems justified as using IMPORTED targets is a cleaner + and more powerful solution that can leverage advanced and CMake-specific + features that may be utilized by the referred dependencies' CMake modules. + + Resolves #1311. + +2025-01-08 Alexei Podtelezhnikov + + [cff] Remove size/slot checks. + + After the previous commit, cff_glyph_load is no longer called + without first checking for valid size and glyph objects in + FT_Glyph_Load and these checks can be removed downstream. + + * src/cff/cffdrivr.c (cff_glyph_load): Remove `size` and `glyph` checks. + * src/cff/cffgload.c (cff_slot_load): Ditto. + +2025-01-08 Alexei Podtelezhnikov + + * src/cff/cffdrivr.c (cff_get_advances): Do only fast advances. + + Otherwise, let TT_Get_Advances fall back on cff_load_glyph to do + slow advances. This avoids unchecked access to cff_load_glyph and + this is how tt_get_advances is implemented. + +2025-01-04 Alexei Podtelezhnikov + + * src/truetype/ttgload.c (TT_Load_Glyph): Consolidate flag setting. + +2025-01-04 Alexei Podtelezhnikov + + Delay FT_GLYPH_FORMAT_OUTLINE assignmets. + + This assignmets used to be done prematurely before errors were checked + and outlines were actually loaded. Delaying the assignment provides + certain protection against careless usage of malformed input that + should now remain FT_GLYPH_FORMAT_NONE. + + * src/cff/cffgload.c (cff_slot_load): Ditto. + * src/cid/cidgload.c (cid_slot_load_glyph): Ditto. + * src/pfr/pfrobjs.c (pfr_slot_load): Ditto. + * src/truetype/ttgload.c (TT_Load_Glyph): Ditto. + * src/type1/t1gload.c (T1_Load_Glyph): Ditto. + +2025-01-03 Alexei Podtelezhnikov + + * builds/compiler/gcc-dev.mk: Silence some warnings. + +2025-01-02 Alexei Podtelezhnikov + + Remove superfluous outline zeroing. + + This is already done by `ft_glyphslot_clear`. + + * src/cff/cffgload.c (cff_slot_load): Do not zero outline fields. + * src/cid/cidgload.c (cid_slot_load_glyph: Ditto. + * src/pfr/pfrobjs.c (pfr_slot_load): Ditto. + * src/truetype/ttgload.c (load_sbit_image): Ditto. + * src/type1/t1gload.c (T1_Load_Glyph): Ditto. + +2025-01-02 Alexei Podtelezhnikov + + * src/truetype/ttobjs.c: Abbreviate tracing. + +2025-01-02 Alexei Podtelezhnikov + + * src/sfnt/ttsbit.c (tt_face_load_sbix_image): Refactor `flip`. + +2025-01-01 Alexei Podtelezhnikov + + [truetype] Consolidate bitmap strike handling. + + * src/truetype/ttgload.c (TT_Load_Glyph): Relocate omitted whitespace + strike handling from here... + (load_sbit_image): ... to here. + +2024-12-31 Alexei Podtelezhnikov + + [truetype] Ingnore FT_LOAD_NO_BITMAP in bitmap-only fonts. + + For consistency with other bitmap-only fonts, we should ignore this + flag of the font is not scalable. + + * src/truetype/ttgload.c (TT_Load_Glyph): Check if face is scalable + when checking for FT_LOAD_NO_BITMAP. + + * docs/CHANGES: Start new chapter wtith this change. + +2024-12-16 Ben Wagner + + [ftstroke] Fix invalid pointer assignement to `arc` + + In `FT_Stroker_ConicTo` and `FT_Stroker_CubicTo` there is a `bez_stack`. + `arc` is initialized with `arc = bez_stack` and is never set to point + into any different object. The main loop looks like `while ( arc >= + bez_stack )` which is depending on a later `arc -= 2` (or `arc -= 3`) to + make `arc` point to before `bez_stack`. However, using pointer + subtraction to make `arc` point outside the array is undefined behavior, + and attempting to use the value in the loop predicate is "very" + undefined behavior. (C99 "Additive operators" 6.5.6.8.) + + This particular undefined behavior was discovered as either hangs or + MemorySantizer issues after "[InstCombine] Infer nuw for gep inbounds + from base of object" [0]. With this change, clang can infer that `arc` + must always point into the `bez_stack` object and therefore cannot be at + a "negative index" so the predicate is always true. + + [0] https://github.com/llvm/llvm-project/commit/e21ab4d16b555c28ded307571d138f594f33e325 + + * src/base/ftstroke.c (FT_Stroker_ConicTo, FT_Stroker_CubicTo): test + loop exit condition (there are no more arcs to process) before + decrementing `arc` + + Fixes: #1307 + +2024-12-04 Ben Wagner + + [cff] Fix leak of cmap data + + When `sfnt->load_face` succeeds it has already loaded any (optional) + cmap data. As a result, a subsequent call to `sfnt->load_cmap` will + overwrite the cmap data pointer with a new copy of the data but not free + the old, leading to a leak. + + This is a fix for "* src/cff/cffobjs.c (cff_face_init): Better handling + of Type0 fonts.". This still allows the cmap to be missing but avoids + the leak by only calling `sfnt->load_cmap` when there is no `head` + table (the font data is not being loaded as OpenType/CFF). + + * src/cff/cffobjs.c (cff_face_init): Fix leak + + Fixes: #1306 + +2024-11-06 Honnesh Ramachandra + + * src/cff/cffobjs.c (cff_face_init): Better handling of Type0 fonts. + + This issue relates to the PDF specification and its usage of CFF-based + embedded Type0 fonts. For Type0 fonts containing CID-keyed descendant + CFF-based fonts, the glyph index is the CID present in the content stream. + As a result, there is no requirement for a 'cmap' table to be present in the + font since the glyph indices are derived directly from the CIDs. FreeType + throws an error when it doesn’t find a 'cmap' table for such an Open Type + font containing CFF outlines. This commit relaxes this requirement for a + 'cmap' table for such fonts. + +2024-10-18 suzuki toshiya + + Download the latest gnu-config files in `make dist`. + + * builds/toplevel.mk: In `make dist`, checkout gnu-config + git repository at savannah, copy the latest versions of + `config.guess` and `config.sub` to builds/unix/. Also + the latest version of `gitlog-to-changelog` is used to + generate `ChangeLog`. + +2024-10-16 Behdad Esfahbod + + Move generic destroy to later in the face and size destruction. + + * src/base/ftobjs.c (destroy_size, destroy_face): This is such that the + generic destroy can be used to call `FT_Done_Library`. For that to work, + it needs to call it *after* having removed the face from the respective + module. + +2024-10-14 Alexei Podtelezhnikov + + * src/truetype/ttgload.c (load_truetype_glyph): Rearrange. + +2024-10-14 suzuki toshiya + + * autogen.sh: Fix for Solaris 10. + + o Replace `test -e` by `test -d` (directory) and `-h` + (symlink), because pre-POSIX /bin/sh of Solaris 10 + does not support `test -e`. + o Replace the combination of `head` and `sed ...` by + single sed command `sed -n 1...p`. GNU libtoolize + with Solaris 10 /bin/sh complains "Broken Pipe" for + the closure of stdout by `head`. Let `sed` receive + all stdout and discard. + +2024-10-13 Alexei Podtelezhnikov + + * src/smooth/ftgrays.c (gray_convert_glyph): Clear stack pointers. + + Fixes a dangling pointer warning, see #1299. + +2024-10-13 suzuki toshiya + + apinames: Fix a buffer overrun for VMS platform. + + Some output formats may rewrite symbol names during the output, + like the concatenation of "64__" suffix on VMS. To estimate + sufficient size to store symbol name, pass the output format + info to `names_add`. For VMS, `names_add` allocates longer + buffer to append "64__". + + * apinames.c (SUFFIX_VMS_64ADDR): New macro of "64__". + (main): Pass the format info to `read_header_file`. + (read_header_file): Pass the format info to `names_add`. + (names_add): Receive the format info, and reserve the symbol + name buffer 4 byte longer in the case of VMS, to append the + suffix in `names_dump`. + +2024-10-13 suzuki toshiya + + apinames: Fix out-of-scope reference of a static array. + + * apinames.c (names_dump): For WATCOM_LBC format, the + DLL name with no suffix is constructed on a static + array temp[], but the scope is closed before use it. + The declaration of temp[] is moved to the wider + scope for the dumping part to refer it. + +2024-10-12 Alexei Podtelezhnikov + + * vms_make.com: Format rules. + + Use tabs in rules only à la Makefile. + +2024-10-12 Marian Klymov + + * meson.build: Define DLL_EXPORT for shared library only. + + Fixes #1298. + +2024-10-12 Benoit Pierre + + * meson.build: Minor improvements. + +2024-10-12 Benoit Pierre + + * meson.build: Fix `bzip2` option handling. + +2024-10-12 Benoit Pierre + + * meson.build: Add support for compiling with error strings. + * meson_options.txt: Document it. + +2024-10-10 suzuki toshiya + + Fix help message of apinames. + + * src/tools/apinames.c: The first header file must be + given after the options. All arguments after the + first header file are dealt as header files to be + parsed, regardless with their leading "-". + + For example, + "apinames include/freetype/freetype.h -dFREETYPE.DLL" + warns "unable to open -dFREETYPE.DLL". + + Thus, the "header1" must be given after the arguments + to be parsed as the options. + +2024-09-21 Jouk Jansen + + Minor fixes for OpenVMS. + + * vms_name.com: Suppress a warning with the latest Clang compiler. + + * builds/vms/apinames_vms.bash: Use absolute path to avoid dependency on the + environment. + +2024-09-07 Alexei Podtelezhnikov + + * src/sfnt/ttsbit.c (tt_face_load_sbix_image): Respect metrics_only. + + Also fixes recursive flip. + +2024-09-06 Alexei Podtelezhnikov + + * src/sfnt/ttsbit.c (tt_face_load_sbix_image): Tweak loop. + +2024-09-06 Andrew Murray + + [sfnt] Support sbix graphicType 'flip'. + + * src/sfnt/ttsbit.c (tt_face_load_sbix_image): Currently undocumented by + Apple, this flips the bitmap data horizontally. It is used on macOS in + Apple Color Emoji; 19.4d6e1; 2024-02-05 (file `Apple Color Emoji.ttc`). + + Fixes issue #1282. + +2024-09-05 suzuki toshiya + + Add `clang` to host compiler candidates in cross building. + + * builds/unix/configure.raw: In cross building, + `clang` is tried if there is no `gcc`, nor `cc`. + +2024-09-05 suzuki toshiya + + Improve the build rule for `apinames`. + + * builds/unix/configure.raw: copy `CFLAGS` & + `LDFLAGS` values to `CFLAGS_BUILD` & + `LDFLAGS_BUILD`, in a self-hosting case. + + * builds/unix/unix-cc.in: set `CCexe_CFLAGS` & + `CCexe_LDFLAGS` by `CFLAGS_BUILD` & + `LDFLAGS_BUILD`. + + In some confused environments, simple building + like `cc -o apinames apinames.c` is no longer + able to build an executable running on the host. + + The validity of `CC` is tested with consideration + of `CFLAGS` and `LDFLAGS`, thus, duplicating + `CFLAGS` & `LDFLAGS` to `CCexe_CFLAGS` & + `CCexe_LDFLAGS` (via XXX_BUILD) would be slightly + safer in a self-hosting build. + + Fixes the issue #1296. + +2024-08-26 Alexei Podtelezhnikov + + * src/sfnt/ttcmap.c (tt_cmap*_get_info): Remove casting. + +2024-08-25 Alexei Podtelezhnikov + + * include/freetype/ftimage.h (FT_Bitmap): Describe empty bitmap. + +2024-08-14 luz paz + + Fix various typos. + +2024-08-13 Alexei Podtelezhnikov + + * messon.build: Install `include/freetype/ftlogging.h`. + + Fixes #1292. + +2024-08-12 Werner Lemberg + + * Version 2.13.3 released. + ========================== + + Tag sources with `VER-2-13-3'. + + * docs/VERSION.TXT: Add entry for version 2.13.3. + * docs/CHANGES: Updated. + * docs/release, docs/README, builds/macs/README: Updated. + + * README, src/base/ftver.rc, builds/windows/vc2010/index.html, + builds/windows/visualc/index.html, builds/windows/visualce/index.html, + builds/wince/vc2005-ce/index.html, builds/wince/vc2008-ce/index.html, + docs/freetype-config.1: s/2.13.2/2.13.3/, s/2132/2133/. + + * include/freetype/freetype.h (FREETYPE_PATCH): Set to 3. + + * builds/unix/configure.raw (version_info): Set to 26:2:20. + * CMakeLists.txt (VERSION_PATCH): Set to 3. + +2024-08-12 Werner Lemberg + + * meson.build: Install `freetype2.m4`. + + Fixes #1290. + +2024-08-12 Werner Lemberg + + * src/*/*: Fix C++ compilation; fix clang warnings. + +2024-08-12 Werner Lemberg + + * subprojects/*.wrap: Updated. + +2024-08-12 Werner Lemberg + + Various minor documentation or formatting fixes. + +2024-08-07 Werner Lemberg + + tttables.h (FT_Get_CMap_Format): Minor documentation improvement. + +2024-08-05 Alexei Podtelezhnikov + + * src/truetype/ttgxvar.c (ft_var_readpacked*): Minor. + +2024-08-05 Alexei Podtelezhnikov + + * src/base/ftstream.c (FT_Stream_ReadFields): Switch to `FT_Offset`. + +2024-08-02 Alexei Podtelezhnikov + + * src/winfonts/winfnt.c (fnt_face_get_dll_font): Unwrap arithmetic. + +2024-08-02 Alexei Podtelezhnikov + + * src/base/ftstream.c (FT_Stream_ReadFields): Update condition. + +2024-08-02 Alexei Podtelezhnikov + + [truetype/GX] Use more robust conditions. + + * src/truetype/ttgxvar.c (ft_var_readpacked{points,deltas}): Rewrite + conditions to avoid undefined behavior. + +2024-07-31 Alexei Podtelezhnikov + + [truetype/GX] Read points and deltas more carefully. + + Hopefully fixes newly introduced buffer overflows: + https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=70807 + https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=70809 + + * src/truetype/ttgxvar.c (ft_var_readpacked{points,deltas}): Explicitly + check stream frame limits and modify run counting. + +2024-07-30 Alexei Podtelezhnikov + + [truetype/GX] Read stream more aggressively. + + With ample checks against the table size, we should be able to use + macros without the limit checks and functional calls. + + * src/truetype/ttgxvar.c (ft_var_readpacked{points,deltas}): + Use FT_NEXT_* instead of FT_GET_*. + +2024-07-29 Alexei Podtelezhnikov + + * src/sfnt/ttload.c (tt_face_load_name): Shorten dereference. + +2024-07-29 Alexei Podtelezhnikov + + * src/autofit/afmodule.c (af_autofitter_load_glyph): Shorten deref. + +2024-07-29 Alexei Podtelezhnikov + + [bdf,pcf,winfonts,sfnt] Remove barely used marcros. + + * include/freetype/internal/ftobjs.h (FT_FACE_SIZE, FT_SIZE_FACE): + Removed. + * src/bdf/bdfdrivr.c (BDF_Glyph_Load): Updated. + * src/pcf/pcfdrivr.c (PCF_Glyph_Load): Ditto. + * src/winfonts/winfnt.c (FNT_Load_Glyph): Ditto + * src/sfnt/ttbdf.c (tt_face_find_bdf_prop): Ditto. + +2024-07-27 Dan Rosser + + * include/freetype/internal/ftcalc.h (FT_MSB)[_M_ARM64EC]: Added. + +2024-07-19 Werner Lemberg + + * src/truetype/ttobjs.c (tt_size_run_prep): Correct scaling of CVT values. + + This reverts the scaling behaviour introduced in commit 37580053. + + Fixes issue #1005. + +2024-06-29 Philip Race + + * psobjs.c (ps_table_add): Check length before calling `FT_MEM_CPY`. + + Fixes issue #1280. + +2024-06-29 Don Olmstead + + CMakeLists.txt: Respect FT_DISABLE_ZLIB value + + The CMake build uses `find_package` to look for dependencies. Before calling `find_package` it looks to see if the dependency was disabled. If not the associated `_FOUND` variable will be set. This value is then checked to determine if the dependency is added. + + However `find_package(PNG)` calls `find_package(ZLIB)` within its find module. So in the case of `FT_DISABLE_ZLIB=TRUE` and `FT_DISABLE_PNG=FALSE` the `ZLIB_FOUND` value can be set and even though `FT_DISABLE_ZLIB` is turned on. + + Unset the value of `ZLIB_FOUND` after the call to `find_package(PNG)` so the value is only set when `FT_DISABLE_ZLIB` is turned off. + +2024-06-26 Werner Lemberg + + Make 'multi' build work again. + + * src/psaux/psobjs.c: Include `psft.h`. + + * src/sfnt/rules.mk (SFNT_DRV_SRC): Add `ttgpos.c`. + + Fixes issue #1284. + +2024-06-23 Alexei Podtelezhnikov + + * src/truetype/ttgload.c (load_truetype_glyph): Unsigned fix. + +2024-06-21 Alexei Podtelezhnikov + + Use unsigned tags `FT_Outline`. + + This change comes along with 2a7bb4596f56 ans is only meant to reduce + pointer casting in the code. + + * include/freetype/ftimage.h (FT_Outline): Do it. + * src/*: Update `FT_Outline` users. + +2024-06-21 Ben Wagner + + [ttgxvar] Avoid "applying zero offset to null pointer" + + In C it is undefined behavior to do arithmetic on a null pointer, including + adding zero. When using NotoSansKhmer[wdth,wght].ttf UBSAN produces a report + like + + ttgxvar.c:1052:31: runtime error: applying zero offset to null pointer + + when adding zero to `varData->deltaSet` (which is null) to produce `bytes`. + Protect against all the potential issues of this kind by returning early if + `varData->regionIdxCount == 0`. + + * src/truetype/ttgxvar.c (tt_var_get_item_delta): early return on no regions + +2024-06-21 Alexei Podtelezhnikov + + Use unsigned point and contour indexing in `FT_Outline`. + + This doubles the number or allowed points, see + https://github.com/harfbuzz/harfbuzz/issues/4752 + + Although it is hardly practical to use more than 32767 points, + other font engines seem to support it. + + * docs/CHANGES: Announce it. + * include/freetype/ftimage.h (FT_Outline): Do it and update limits. + * src/*: Update `FT_Outline` users. + +2024-06-20 Alexei Podtelezhnikov + + * src/pfr/pfrgload.c (pfr_glyph_curve_to): Avoid casting. + +2024-06-19 Alexei Podtelezhnikov + + * src/base/ftgloadr.c (FT_GlyphLoader_Prepare): Minor refactoring. + +2024-06-18 Alexei Podtelezhnikov + + [base, autofit, psaux] Remove unnecessary casting. + + * src/autofit/afhints.c (af_glyph_hints_reload): Remove (short) casting. + * src/base/ftgloadr.c (FT_GlyphLoader_Add): Ditto. + * src/psaux/psobjs.c ({t1,cff,ps}_builder_{add,close}_contour): Ditto. + +2024-06-18 Alexei Podtelezhnikov + + * include/freetype/ftimage.h: Explain standard types. + +2024-05-29 Ben Wagner + + [ttgxvar] Replace tabs with spaces + + Also clarify comments around conversion and clamping. + + * src/truetype/ttgxvar.c (ft_var_to_normalized): doit + +2024-05-27 Alexei Podtelezhnikov + + [truetype/GX] Consolidate memory allocations. + + * src/truetype/ttgxvar.c (tt_face_vary_cvt, TT_Vary_Apply_Glyph_Deltas): + Allocate and split bigger memory blocks, avoid unnecessary zeroing, + do not copy shared tuples, revise error exit paths. + +2024-05-26 Alexei Podtelezhnikov + + Whitespace. + +2024-05-24 Alexei Podtelezhnikov + + * src/truetype/ttgxvar.c (ft_var_apply_tuple): Reduce checks. + +2024-05-24 Alexei Podtelezhnikov + + Revert "[truetype] Reduce allocation scope." + + This reverts commit 9ff4153cbfd60491f11bb56905ce6e20e94d23c7. + +2024-05-23 Alexei Podtelezhnikov + + [truetype] Reduce allocation scope. + + * src/truetype/ttgxvar.c (TT_Vary_Apply_Glyph_Deltas): Reduce scope + of `points_org` and 'points_out`. + +2024-05-23 Alexei Podtelezhnikov (Алексей Подтележников) + + * .gitlab-ci.yml: Disable UWP compilation. + +2024-05-23 Alexei Podtelezhnikov + + * include/freetype/internal/ftmemory.h (FT_MEM_DUP): Fix g++ error. + +2024-05-21 Alexei Podtelezhnikov + + [cff, truetype] Validate variation axes immediately. + + Instead of validating variation axes in every access, OpenType specs + suggest that peak = 0 be used to tag invalid ranges. This implements + just that once during loading. + + * src/cff/cffload.c (cff_blend_build_vector): Move the range checks... + (cff_vstore_load): ... here. + * src/truetype/ttgxvar.c (tt_var_get_item_delta): Ditto... + (tt_var_load_item_variation_store): ... ditto. + +2024-05-21 Alexei Podtelezhnikov + + [cff, truetype] Rearrange variation range checks. + + This should achieve quicker results for common cases. + + * src/cff/cffload.c (cff_blend_build_vector): Rearrange conditionals. + * src/truetype/ttgxvar.c (tt_var_get_item_delta): Ditto. + +2024-05-21 Alexei Podtelezhnikov + + * src/truetype/ttgxvar.c (tt_var_get_item_delta): Align with specs. + +2024-05-21 Alexei Podtelezhnikov + + * src/truetype/ttgxvar.c (tt_var_get_item_delta): Minor refactoring. + +2024-05-21 Alexei Podtelezhnikov + + [cff] Optimize the blend vector computations. + + * src/cff/cffload.c (cff_blend_build_vector): Use FT_MulDiv and skip + multiplying by 1. + +2024-05-20 Alexei Podtelezhnikov + + [bdf] Use concise macros. + + * src/bdf/bdflib.c (bdf_create_property): Use FT_STRDUP. + (bdf_parse_glyphs_, bdf_parse_start_): Use FT_DUP for brevity. + +2024-05-20 Alexei Podtelezhnikov + + [cache] Use FT_DUP to duplicate data. + + * src/cache/ftcsbits.c (ftc_sbit_copy_bitmap): Use concise FT_MEM_DUP. + +2024-05-20 Alexei Podtelezhnikov + + [truetype, type1] Use FT_DUP to duplicate data. + + * src/truetype/ttgload.c (TT_Load_Simple_Glyph): Use concise FT_DUP. + * src/truetype/ttgxvar.c (TT_Get_MM_Var): Ditto. + * src/type1/t1load.c (parse_subrs): Ditto. + +2024-05-18 Alexei Podtelezhnikov + + * builds/windows/ftsystem.c: Use _WINRT_DLL to check for UWP. + + Fixes compilation using Windows GDK, reported by Erin Melucci. + +2024-05-13 Alexei Podtelezhnikov + + * include/freetype/ftmm.h: Include `freetype.h`. + + Reported by Ben Wagner, see !326. + +2024-05-13 Alexei Podtelezhnikov + + [type1/MM] Safer handle arrays of different types. + + * src/type1/t1load.c (parse_blend_design_map): Separately allocate... + (T1_Done_Blend): ... and free `design_points` and `blend_points`. + +2024-05-12 Alexei Podtelezhnikov + + * src/type1/t1load.c (parse_blend_design_map): Add risky cast. + +2024-05-12 Alexei Podtelezhnikov + + * docs/CHANGES: Mention the last commit. + +2024-05-12 Alexei Podtelezhnikov + + [type1/MM] Tighten headers. + + * include/freetype/internal/t1types.h: Host PS_DesignMap and PS_Blend. + * include/freetype/ftmm.h: Host and document TT_MAX_MM_XXX. + * include/freetype/t1tables.h: Remove them from here. + +2024-05-11 Alexei Podtelezhnikov + + * src/pshinter/pshrec.c (ps_hints_stem): Correct argument. + +2024-05-08 Ben Wagner + + [psaux] Fix location and type order in initializer + + `T1_FIELD_ZERO` is used to zero initialize a `T1_FieldRec`. + `T1_FIELD_ZERO` is currently initilizing `T1_FieldRec::location` with a + `T1_FieldType` and `T1_FieldRec::type` with a `T1_FieldLocation`. This + was detected with `-Wenum-conversion`. + + * include/freetype/internal/psaux.h (T1_FIELD_ZERO): correct order of + initalizers + +2024-05-08 Alexei Podtelezhnikov + + * include/freetype/internal/psaux.h: Fix g++ warning. + + Reported by Hin-Tak Leung. + +2024-05-08 Ben Wagner + + [colr] Avoid overflow in range checks + + In 32 bit builds `FT_ULong` is 32 bits and can silently overflow when a + large number is read into one and then it is summed or multiplied with + another number. Checks for range overflow must be written so that they + themselves do not overflow. Also ensure that the table_size is always the + first part of the range check and consistently use `<` or `<=`. + + * src/sfnt/ttcolr.c (tt_face_load_colr): Avoid overflow. + (find_base_glyph_v1_record): Remove old work-around. + + Bug: https://issues.chromium.org/issues/41495455 + Bug: https://issues.chromium.org/issues/40945818 + +2024-05-06 Werner Lemberg + + .mailmap: Fix entry for Ben Wagner. + +2024-05-06 Alexei Podtelezhnikov + + [sdf, bsdf] Use shared FT_SqrtFixed. + + FT_SqrtFixed (95b0fe2a6dff) is faster and does not overflow. + + * src/sdf/ftsdfcommin.h (square_root): Replace with a macro. + * src/sdf/ftsdfcommin.c (square_root): Remove function. + +2024-05-04 Alexei Podtelezhnikov + + * src/autofit/aflatin.c (af_latin_metrics_scale_dim): Remove FT_ABS. + + See + https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=68679 + +2024-05-03 Alexei Podtelezhnikov + + * src/sfnt/sfwoff2.c (woff2_open_font): Fix copy-paste typo. + +2024-05-03 Alexei Podtelezhnikov + + [woff,woff2] Limit the number of tables and use FT_MSB. + + The upper limit of 4095 is implied by the SFNT header format + where the multiplication by 16 would overflow without it. + + * src/sfnt/sfwoff.c (woff_open_font): Updated. + * src/sfnt/sfwoff2.c (woff2_open_font): Ditto. + +2024-05-02 Ben Wanger + + [woff2] Disallow zero table font entries + + The existing code already disallows zero table woff2 overall, but still + allows for individual CollectionFontEntry to create font instances with + zero tables. Such fonts are not useful so error early. + + This also fixes an MSAN discovered issue where if a CollectionFontEntry + numTables is zero then the sfnt_header was not fully initialized. + + * src/sfnt/sfwoff2.c (woff2_open_font): error on zero tables, always + initalize sfnt_header + + Fixes: https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=68384 + +2024-05-02 Alexei Podtelezhnikov + + [sfnt] Use faster macros in checksums. + + * src/truetype/ttobjs.c (tt_synth_sfnt_checksum): Use FT_NEXT_XXX. + * src/sfnt/sfwoff2.c (compute_ULong_sum): Use macros. + +2024-05-01 Alexei Podtelezhnikov + + * src/sfnt/sfwoff2.c (compute_ULong_sum): Clean up. + +2024-04-30 Alexei Podtelezhnikov + + * docs/CHANGES: Updated. + +2024-04-30 Alexei Podtelezhnikov + + * src/cache/ftccache.c (FTC_Cache_RemoveFaceID): Remove nodes instantly. + +2024-04-29 Alexei Podtelezhnikov + + [cache] Remove unused `node_reset`. + + * src/cache/ftcmru.h (FTC_MruListClassRec): Remove `node_reset` field. + * src/cache/ftcbasic.c (ftc_basic_{image,sbit}_family_class): Ditto. + * src/cache/ftcmanag.c (ftc_face_list_class): Ditto. + (ftc_size_node_reset): Remove function. + * src/cache/ftcglyph.h: Fix comment. + +2024-04-29 Alexei Podtelezhnikov + + * src/cache/ftcmru.c (FTC_MruList_New): Do not reset nodes. + + Resetting of the size nodes can crash, if a parent face purge happens + simultaneously and destroys the node. It is safer to create a new node. + Fixes #1270, reopened with a separate issue. + +2024-04-28 Alexei Podtelezhnikov + + * src/cache/ftcimage.c (ftc_inode_weight): Formatting. + +2024-04-28 Alexei Podtelezhnikov + + Document the SDF spread further. + +2024-04-23 Alexei Podtelezhnikov + + * include/freetype/ftdriver.h: s/truncated/clamped/. + +2024-04-23 Alexei Podtelezhnikov + + Improve SDF documentation. + +2024-04-21 Alexei Podtelezhnikov + + [cache] Minor tweaks. + + * src/cache/ftcimage.c (ftc_inode_free): Remove unnecessary check. + * src/cache/ftcmanag.c (FTC_Manager_Done): Do not zero before freeing. + +2024-04-21 Alexei Podtelezhnikov + + * src/cache/ftcbasic.c: Cosmetic harmonization. + +2024-04-20 Alexei Podtelezhnikov + + [cache] Reduce type mismatches. + + * src/cache/ftcbasic.c (FTC_BasicAttrRec): Match type of `load_flags` + to its main purpose in `FT_Load_Glyph`. + (FTC_ImageCache_Lookup{,Scaler},FTC_SBitCache_Lookup{,Scaler}): Updated. + +2024-04-19 Alexei Podtelezhnikov + + * src/cache/{ftcbasic.c,ftccmap.c}: Use FTC_INLINE. + +2024-04-19 Alexei Podtelezhnikov + + [cache] Tweak headers. + + * src/cache/ftccback.h: Include less and move `ftc_node_destroy`... + * src/cache/ftccache.h: ... to here. + * src/cache/ftcmanag.c: Include less. + +2024-04-19 Alexei Podtelezhnikov + + * src/cache/ftcglyph.c [!FTC_INLINE]: Fix compilation. + +2024-04-17 Alexei Podtelezhnikov + + [cache] Improve MRU list management. + + * src/cache/ftcmru.c (FTC_MruList_Remove): Cosmetic. + (FTC_MruList_New): Accept only valid changes. + * src/cache/ftcmanag.c (ftc_size_node_done): Simplify. + +2024-04-17 Alexei Podtelezhnikov + + [cache] Fix error handling. + + Manipulate the cache after a face is requested or a size is looked up + successfully. Fixes #1270. + + * src/cache/ftcmanag.c (ftc_size_node_init, ftc_size_node_reset, + ftc_face_node_init): Check for errors before accepting a change. + * src/cache/ftcmru.c (FTC_MruList_New): Do nothing if reset fails. + +2024-04-14 Alexei Podtelezhnikov + + [smooth] Switch to vertical bisections. + + With horizontal bisections, the smallest section is a whole single + scanline. Almost horizontal lines or other complex scanlines can + easily overflow the rendering pool. Switching to vertical bisections + splits the scanlines and should rule out the overflows. Fixes #1269. + + * src/smooth/ftgrays.c (gray_convert_glyph): Bisect vertically. + +2024-04-14 Alexei Podtelezhnikov + + * src/smooth/ftgrays.c (gray_convert_glyph): Refactor for convenience. + +2024-04-14 Alexei Podtelezhnikov + + [smooth] Store persistent clipping box. + + * src/smooth/ftgrays.c (gray_TWorker, gray_raster_render): Add and set + the new structure field. + (gray_convert_glyph): Use it. + +2024-03-08 Ben Wanger + + [colr] Ensure enough bytes for PaintColrLayers + + * src/sfnt/ttcolr.c (read_paint): check that there are five additional + bytes to be read when reading PaintColrLayers. + + Reported as + + https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=66566 + +2024-03-08 Ben Wagner + + Avoid n^2 scanning for binary data. + + When creating a CID parser the location of the 'StartData' or '/sfnts' + tokens needs to be known. However, the token parser requires that the + entire document be in memory and flattening the entire stream into memory is + to be avoided. + + To avoid forcing the entire stream into memory, previously this code would + scan through the stream looking for 'StartData' or '/sfnts' as strings. + However, these strings could have been in a comment or string token, so the + stream would be read into memory up to that point and the parser run to + check that these strings were actually tokens. This forced a parser restart + from the beginning each time; as a result, data with many 'StartData' + non-tokens would take n^2 time to check. + + * src/cid/cidparse.c (cid_parser_new): Change algorithm to make the initial + scan look for the last possible 'StartData' or '/sfnts' string in the + stream. The stream is read forward instead of backward as a typical normal + CID font will have one 'StartData' toward the beginning of the data and it + it much faster to read the data from beginning to end instead of end to + beginning. For memory-based fonts the limit is set to the end of the stream + since the stream is already in memory. Then the parser is run once to look + for 'StartData' or '/sfnts' tokens. If they are found the parser is re-set + to reflect this new information. + + Reported as + + https://issues.chromium.org/issues/40201695 + +2024-03-06 Alexei Podtelezhnikov + + * CMakeLists.txt: Bump required version to 3.5. + + Fixes #1267. + +2024-03-04 Jordan Williams + + meson: Use the standard dependency mechanism to find bzip2 + + This follows standard conventions in Meson by using the pkg-config file. + This change allows Conan to switch to the Meson build system. + +2024-02-29 Ben Wanger + + [cff, truetype] Always set up default variable instance. + + For default variable instances `cff_face_init` did not set the blend. This + mostly worked as later use of the unset blend produced the default + variation. However, if a user called `TT_Get_MM_Var` the blend would be + partially set up, but not fully. In particular the number of axes, the axis + definitions, and the instance locations would be set up, but not the current + instance location (`coords` and `normalizedcoords`). This could lead to the + default instances of CFF2 fonts erroring on any use of `blend`. + + Ensure the default variable instance is fully set up by always calling + `FT_Set_Named_Instance` on a variable face. + + * src/cff/cffobjs.c (cff_face_init): Call `FT_Set_Named_Instance` on + default instances. + * src/truetype/ttobjs.c (tt_face_init): Ditto. + + Fixes #1268. + +2024-02-23 Werner Lemberg + + * src/truetype/ttgxvar.c (ft_var_to_normalized): Integer overflow. + + Reported as + + https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=66543 + +2024-01-27 Alexei Podtelezhnikov + + Update all copyright notices. + +2024-01-27 Alexei Podtelezhnikov + + * src/sfnt/ttgpos.c (tt_gpos_get_glyph_class): Fix warning C4018. + +2024-01-27 David Saltzman + + Add support for kerning from 'GPOS' tables. + + This commit adds support for kerning from 'GPOS' tables, while maintaining + support for basic 'kern' tables. `FT_HAS_KERNING` will be true for a font + with either available and `FT_Get_Kerning` will still use the basic 'kern' + table data if avilable, otherwise check the GPOS 'kern' feature. + + This feature is disabled by default; it can be enabled with the + `TT_CONFIG_OPTION_GPOS_KERNING` flag. + + Only basic kerning (pair positioning with just an x advance) is supported + from the GPOS layout features; support for that was added to make the + existing `FT_Get_Kerning` API more consistently functional. FreeType does + not intend to extend itself to further GPOS functionality though; a + higher-level library like HarfBuzz can be used instead for that. + + * include/freetype/config/ftoption.h, include/devel/ftoption.h + (TT_CONFIG_OPTION_GPOS_KERNING): New configuration option. + + * include/freetype/internal/fttrace.h: Add `ttgpos` trace handler. + + * include/freetype/internal/sfnt.h (SFNT_Interface): Add `load_gpos` and + `get_gpos_kerning` fields. + (FT_DEFINE_SFNT_INTERFACE): Updated. + + * include/freetype/internal/tttypes.h: Include `fttypes.h`. + (TT_FaceRec) [TT_CONFIG_OPTION_GPOS_KERNING]: Add `gpos_table` and + `gpos_kerning_available` fields. + + * src/sfnt/ttgpos.c, src/sfnt/ttgpos.h: New files. + + * src/sfnt/sfdriver.c [TT_CONFIG_OPTION_GPOS_KERNING]: Include `ttgpos.h`. + (sfnt_interface): Updated. + + * src/sfnt/sfnt.c: Include `ttgpos.c`. + + * src/sfnt/sfobjs.c [TT_CONFIG_OPTION_GPOS_KERNING]: Include `ttgpos.h`. + (sfnt_load_face) [TT_CONFIG_OPTION_GPOS_KERNING]: Load and free GPOS kerning + data; check GPOS kerning availability. + + * src/truetype/ttdriver.c (tt_get_kerning): Use GPOS kerning if there's no + 'kern' table. + +2024-01-14 Alexei Podtelezhnikov + + [smooth] Remove SSE2. + + As a result of 7b308a29dd10, the regular 64-bit execution is now faster + than SSE2. The rendering speed of script fonts at 64 ppem or larger is + improved by about 3% without SSE2. See !314 for the testing results. + + * src/smooth/ftgrays.c (gray_render_conic)[FT_INT64]: Remove SSE2 code. + +2024-01-14 Alexei Podtelezhnikov + + * CMakeLists.txt: Accommodate MingGW. + + See https://github.com/StephanTLavavej/mingw-distro/issues/97. + +2024-01-08 Ozkan Sezer + + * src/sfnt/ttcolr.c (find_base_glyph_v1_record): Fix build in C90 mode. + +2024-01-07 Alexei Podtelezhnikov + + [base] Fix up Mac resource forks and dfonts. + + * src/base/ftobjs.c (IsMacResource): Assign `face_index`. + * src/base/ftmac.c (FT_New_Face_From_Suitcase): Ditto after rework. + +2024-01-05 Alexei Podtelezhnikov + + [sfnt] Restrict POST version 1.0. + + A font has surfaced with `post` version 1.0 and fewer than 258 glyphs. + Its glyphs did not correspond to their names. We now reject such `post` + strictly following specifications. + + * src/sfnt/ttpost.c (tt_face_get_ps_name): Check the number of glyphs + for version 1.0. + +2024-01-03 Alexei Podtelezhnikov + + * .gitlab-ci.yml: Use detached CI pipelines. + + See issue freedesktop/freedesktop#540. + +2024-01-02 Werner Lemberg + + [sfnt] Guard access in 'COLR' v1 glyph binary search. + + Reported as + + https://bugs.chromium.org/p/chromium/issues/detail?id=1505216 + + * src/sfnt/ttcolr.c (find_base_glyph_v1_record): Guard access of the search + pointer during binary search. The pointer needs to be checked as we go as + the test that compares number of v1 glyphs with table size at the time of + loading the table is not sufficient on its own. + + A scenario is possible in which the `BaseGlyphRecord` list extends into + non-`BaseGlyphRecord` parts of the 'COLR' v1 table (but passed the size + comparison check). Then, at those locations, invalid glyph ID values are + read and may provoke an invalid read due to reassigning min and max values + during the binary search. + +2023-12-18 Alexei Podtelezhnikov + + [ci] Add support for MSBuild on Windows. + + This adds msbuild job for VS2019 (x64). + + * .gitlab-ci.yml: Added "windows msbuild vs2019 amd64". + +2023-12-14 Skef Iterum + + [CFF] Extract `BlueValues` as `Fixed` rather than `Int`. + + This is a follow-up to commit 26a7f047, + + [cff] Make blend operator work with floats in private dicts. + + which addressed the 'party baseline' bug. However, the reporting user + indicated that the default location and some other points in design space + rendered OK, but other points in design space still had problems. The most + obvious issue being that the x-heights of lower-case letters did not align; + see + + https://github.com/adobe-fonts/source-serif/issues/121#issuecomment-1773794136 + + After some analysis we determined that this was due to an interaction + between `BlueValue` rounding and the zone-based algorithm. In short, for a + point to be considered in a zone it must fall within the bounds of the zone. + (There is a slop factor in some cases, but only a very small one.) In the + Adobe-contributed side of the code, point values are not integer-rounded, + instead they're kept as (some form of) fixed. Rounding just the `BlueValues` + means that points that need to be considered within a zone will fall outside + of it at some points in design space. + + The majority of this patch changes the storage and parsing of `BlueValues` + to keep them as `FT_Fixed`. No significant code changes were needed because + the values are converted to `Fixed` anyway when stored in `CF_BlueRec`. No + attempt was made to address problems in the older pshinter code beyond + converting the values from `FT_Fixed` to `FT_Short` when copying the private + dictionary. (However, as the point values are also rounded in that code, + the problem is much less likely to occur, although inconsistency between + rounding and truncation could cause an analogous problem.) + + * include/freetype/internal/cfftypes.h (CFF_PrivateRec): Use `FT_Fixed` for + `blue_values`, `other_blues`, `family_blues`, and `family_other_blues`. + + * src/cff/cffload.c (cff_blend_doBlend): Updated. + + * src/cff/cffobjs.c (CFF_fixedToInt): New macro. + (cff_make_private_dict): Use it. + + * src/cff/cffparse.h (cff_kind_delta_fixed): New enum value. + + * src/cff/cffparse.c (do_fixed): Updated. + (CFF_FIELD_DELTA, CFF_FIELD_DELTA_FIXED, CFF_DELTA_KIND): New set of macros, + replacing `CFF_FIELD_DELTA`. + (cff_parser_run): Updated to handle fixed-float deltas. + + * src/cff/cfftoken.h: Updated to use `CFF_FIELD_DELTA_FIXED` for blue + values. + + * src/psaux/psblues.c (cf2_blueToFixed): Removed, no longer needed. + (cf2_blues_init): Updated. + + * src/pxaux/psft.c, src/pxaux/psft.h (cf2_getBlueValues, cf2_getOtherBlues, + cf2_getFamilyBlues, cf2_getFamilyOtherBlues): Updated signatures. + + * src/psaux/psobjs.c (t1_make_subfont): Updated. + +2023-12-14 Skef Iterum + + [psaux] Improve tracing. + + * src/psaux/psintrp.c (cf2_doBlend, cf2_interpT2CharString [cf2_cmdBLEND]): + Show blended values. + +2023-12-14 Jouk Jansen + + * vms_make.com: Switch to `clang`. + + Also add proper bzip2 support. + +2023-12-14 Werner Lemberg + + * src/truetype/ttgxvar.c (ft_var_to_normalized): Fix undefined left-shift. + + Reported as + + https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=63723 + +2023-12-07 Alexei Podtelezhnikov + + [msbuild] Streamline the process. + + MSBuild.exe can now be fired from the root folder without options. + + * builds/windows/vc2010/freetype.sln: Relocated to... + * MSBuild.sln: ... here with minor changes. + * MSBuild.rsp: New file with command line options. + * docs/INSTALL: Reference `MSBuild.sln`. + +2023-12-02 Alexei Podtelezhnikov + + * src/raster/ftraster.c (Draw_Sweep): Swap stub conditions. + +2023-12-02 Alexei Podtelezhnikov + + * src/raster/ftmisc.h (FT_MulDiv): Remove unused copy. + +2023-11-28 Alexei Podtelezhnikov + + [raster] Speed up Bézier arches with extrema. + + While it is recommended to have an explicit point at each curve + extrema, they might be missing or outline could be rotated. This + leads to excessive bisections in raster to find them. This change + helps to decrease the number of bisections. The scanline + intersections remain monotonous, of course. + + * src/raster/ftraster.c (Conic_To, Cubic_To): Check that control + points cross the scanlines to bisect. + +2023-11-25 Alexei Podtelezhnikov + + * docs/*: Typos. + +2023-11-24 Alexei Podtelezhnikov + + [raster] Eliminate intensive flow checking. + + * src/raster/ftraster.c (Draw_Sweep): Pass the flow increment. + (Increment): Accept the flow increment. + +2023-11-23 Alexei Podtelezhnikov + + * src/raster/ftraster.c: Comments, defines, includes, cleanups. + +2023-11-21 Alexei Podtelezhnikov + + * src/raster/ftraster.c (FT_Outline_Get_CBox ) [STANDALONE_]: Removed. + +2023-11-21 Alexei Podtelezhnikov + + * src/raster/ftraster.c (Draw_Sweep): No-fault return. + (Render_Single_Pass): Updated. + +2023-11-21 Alexei Podtelezhnikov + + [raster] Sweep polishing. + + * src/raster/ftraster.c (*_Sweep_Span): Polish. + (*_Sweep_Drop): Restore tracing, polish. + (Draw_Sweep): Simplify the dropout processing loop. + +2023-11-21 Alexei Podtelezhnikov + + [raster] Rearrange dropout control. + + This reduces the code duplication. + + * src/raster/ftraster.c (Function_Sweep_Span): Change signature. + (Vertical_Sweep_Drop, Horizontal_Sweep_Drop): Focus on pixel setting + and move duplicated the dropout control logic to... + (Draw_Sweep): ... this function and refactor. + (Vertical_Sweep_Span, Horizontal_Sweep_Span): Minor. + +2023-11-21 Alexei Podtelezhnikov + + [raster] Use bitwise dropout mode interpretation. + + * src/raster/ftraster.c (Vertical_Sweep_Drop, Horizontal_Sweep_Drop, + Draw_Sweep, Render_GLyph): Interpret dropout mode using bit masks. + +2023-11-16 Alexei Podtelezhnikov + + * docs/CHANGES: Updated. + +2023-11-16 Alexei Podtelezhnikov + + [raster] Keep only bottom y-turns. + + This results in noticeable performance improvement. + + * src/raster/ftraster.c (Insert_Y_Turns): All bottom y-turns are still + sorted and stored; only the maximum top y-turn is recorded now. The + function is renamed. + (End_Profile): Updated accordingly. + (Convert_Glyph): Reserve space for the top value. + +2023-11-15 Alexei Podtelezhnikov + + * src/raster/ftraster.c (End_Profile): Reduce branching. + (InsNew): Tweak condition. + +2023-11-15 Alexei Podtelezhnikov + + * src/raster/ftraster.c (Draw_Sweep): Use more natural loop. + +2023-11-15 Alexei Podtelezhnikov + + [raster] Dissolve a loop. + + * src/raster/ftraster.c (End_Profile): Set initial `X` here... + (Draw_Sweep): ... instead of here; delay the `start` decrement. + +2023-11-15 Alexei Podtelezhnikov + + * src/raster/ftraster.c: Comments. + +2023-11-14 Alexei Podtelezhnikov + + [raster] Stylistic changes. + + * src/raster/ftraster.c (Line_To): Code it similar to curves; + shortcut the flat lines here... + (Line_Up): ... instead of here. + +2023-11-14 Alexei Podtelezhnikov + + [raster] Revise overshoot setting. + + * src/raster/ftraster.c (New_Profile, End_Profile): Deal with overshoots + locally. + (Line_To, Conic_To, Cubic_To): Update callers. + +2023-11-14 Alexei Podtelezhnikov + + * src/raster/ftraster.c (Conic_To, Cubic_To): Fix recent regression. + +2023-11-14 Alexei Podtelezhnikov + + * include/freetype/ftimage.h: Fix type and link. + +2023-11-14 Alexei Podtelezhnikov + + * src/raster/ftraster.c (Increment): Minor tweak. + +2023-11-13 Alexei Podtelezhnikov + + [raster] Get rid of the fresh flag. + + * src/raster/ftraster.c (black_TWorker): Remove the fresh flag. + (New_Profile): Set the starting scanline here based on the current + coordinate and initialize the joint crossing if necessary. + (Line_Up, Bezier_Up): Do not deal with fresh and joint starts at all. + (Line_Down, Bezier_Down): Simplify. + (Conic_To, Cubic_To): Update the current coordinate after each + subsection. + +2023-11-12 Alexei Podtelezhnikov + + [raster] Get rid of the joint flag. + + * src/raster/ftraster.c (Line_Up, Bezier_Up): Deal with the scanline + joints directly based on the initial y-coordinate. + (New_Profile, black_TWorker): Remove the boolean flag. + +2023-11-11 Alexei Podtelezhnikov + + * src/raster/ftraster.c (Line_Up, Bezier_Up): Check "between" earlier. + +2023-11-11 Alexei Podtelezhnikov + + * src/raster/ftraster.c (Line_Up): Updated and fixed up. + + This largely synchronizes the entries into `Line_Up` and `Bezier_Up`. + Minor bugs in the remainder calculations and accumulations are fixed. + +2023-11-10 Alexei Podtelezhnikov + + * src/raster/ftraster.c (End_Profile, Convert_Glyph): Clean up. + +2023-11-10 Alexei Podtelezhnikov + + * src/raster/ftraster.c (Bezier_Up): Improve joint and loop. + +2023-11-07 Alexei Podtelezhnikov + + [raster] Harmonize target bitmap navigation. + + * src/raster/ftraster.c (black_TWorker): Store signed maximum indexes + in both directions instead of unsigned dimensions of the original bitmap. + (*_Sweep_*, Render_Glyph, ft_black_render): Updated all users. + +2023-11-06 Alexei Podtelezhnikov + + * src/raster/ftraster.c (Bezier_Up): Improve flow. + +2023-11-06 Alexei Podtelezhnikov + + [raster] Reshuffle code for readability. + + * src/raster/ftraster.c (Render_Glyph): Setup the rendering pool here. + (ft_black_render): Setup the target bitmap helpers here. + +2023-11-04 Alexei Podtelezhnikov + + [raster] Improve profile accounting during sweeping. + + * src/raster/ftraster.c (TProfile): Get rid of `countL`. + (Draw_Sweep): Use `start` for countdown to activation. + (Horizontal_Sweep_Drop, Vertical_Sweep_Drop): Rely on `height` and + `offset` to verify profile ends for the stub detection. + +2023-11-04 Alexei Podtelezhnikov + + [raster] Consolidate profile increment to the next line. + + * src/raster/ftraster.c (s/Sort/Increment): Rename this function to + reflect its true purpose, delete exhausted profiles here... + (Draw_Sweep): ... instead of here. + +2023-11-04 Alexei Podtelezhnikov + + [raster] Instantly remove profiles from linked lists. + + * src/raster/ftraster.c (DelOld): Remove loopy function. + (Draw_Sweep): Implement instant profile removal. + +2023-11-03 Alexei Podtelezhnikov (Алексей Подтележников) + + [raster] Modify the split condition. + + While curving close to a pixel center, vertical and horizontal pass + might split the curve differently and cause a rare dropout. This + makes the split condition invariant of the sweep direction and more + robust. + + * src/raster/ftraster.c (Bezier_Up): Modify the split condition. + +2023-11-03 Alexei Podtelezhnikov (Алексей Подтележников) + + [raster] Remove the jitter exception. + + The jitter exception used to be applied when two neighboring pixels + were barely inside the outline. One the left one was turned on then, + which contradicts the OpenType specifications. Intended to remove + glitches, it caused disappearing lines and was softened by adding an + exception to the exception (#54589). + + * src/raster/ftraster.c (Vertical_Sweep_Span): Drop the jitter exception. + +2023-10-31 Alexei Podtelezhnikov + + [raster] Simplify dropout detection. + + * src/raster/ftrater.c (Draw_Sweep): Use a single dropout condition. + +2023-10-31 Alexei Podtelezhnikov + + [raster] Simplify sweeping entry and exit. + + * src/raster/ftraster.c (Draw_Sweep): Use y-turns to set the range, + correctly set the initial position, directly loop through y_turns, + and remove a 5-gray remnant at exit. + +2023-10-26 Alexei Podtelezhnikov + + [raster] Switch to routine Int instead of Short. + + This is mostly cosmetic and removes a few casts, plus Short is + promoted to Int in calculations anyway. + + * src/raster/ftraster.c (Vertical_Sweep_Init, Vertical_Sweep_Span, + Vertical_Sweep_Drop, Horizontal_Sweep_Init, Horizontal_Sweep_Span, + Horizontal_Sweep_Drop, Draw_Sweep): Mostly s/Short/Int/ and remove + casting. + +2023-10-24 Alexei Podtelezhnikov + + [raster] Increase the raster pool density. + + This only helps to delay the pool overflow and bisections to larger + sizes and benefits only very intricate glyphs at reasonable sizes. + + * src/raster/ftraster.c (TProfile): Use Int instead of Long or PLong + when it is sufficient. + (New_Profile, End_Profuile, Bezier_Up, Sort): Updated accordingly. + +2023-10-23 Alexei Podtelezhnikov + + [raster] Slightly improve the pool design. + + * src/raster/ftraster.c (TProfile): Include the variable array member + and repackage with pointers first. + (New_Profile): Advance the top using the variable array pointer. + +2023-10-22 Alexei Podtelezhnikov + + [raster] Clean up sweeping. + + * src/raster/ftraster.c (Draw_Sweep): Zero initialize the working + lists directly and remove unnecessary y-turn checks. + (Init_Linked): Removed. + +2023-10-22 Alexei Podtelezhnikov + + * src/raster/ftraster.c (Insert_Y_Turn): Improve flow. + +2023-10-22 Alexei Podtelezhnikov + + * src/pcf/pcfutil.c (BSWAP16): Limit clang support. + + These ancient builtins have been supported by clang since 2013. We + condition it somewhat stricter but still around 2017. This is more + portable than `__has_builtin`. Fixes #1260. + +2023-10-19 Alexei Podtelezhnikov + + [raster] Small optimizations. + + * src/raster/ftraster.c (New_Profile): Set important fields only and + delay setting `gProfile` until... + (End_Profile): ... it is checked to be valid here. + (Convert_Glyph): Updated. + +2023-10-18 Alexei Podtelezhnikov + + * src/raster/ftraster.c (Convert_Glyph): Remove redundant check. + +2023-10-18 Alexei Podtelezhnikov + + [raster] Fix linked profiles in contour loops. + + This fixes a subtle bug when the last profile in a contour was not + properly short-circuited if it was still empty at `End_Profile`. + We finalize all linking in `Finalize_Profile_List` now and do nothing + else there. The turns are added in `End_Profile`. + + * src/raster/ftraster.c (Insert_Y_Turn): Moved up unchanged. + (End_Profile): Take care of turns but set only preliminary linking. + (Finalize_Profile_Table): Take care of linking and null-termination. + (Convert_Glyph): Adjusted accordingly. + +2023-10-15 Alexei Podtelezhnikov + + * src/raster/ftraster.c: Improve tracing. + +2023-10-13 Alexei Podtelezhnikov + + [raster] Improve profile accounting. + + * src/raster/ftraster.c (End_Profile): Do not initiate next profile. + (New_Profile): Fully initiate new profile. + (Convert_Glyph): Clean up variables, initialize `fProfile` here. + +2023-10-13 Alexei Podtelezhnikov + + * src/raster/ftraster.c (Convert_Glyph): Fix null-dereference. + +2023-10-13 Alexei Podtelezhnikov + + [raster] Fix pool overflow checking. + + * src/raster/ftraster.c (New_Profile, End_Profile): Check for overflow + immediately. + (Convert_Glyph, Render_Single_Pass): Fix boundaries. + +2023-10-13 Alexei Podtelezhnikov + + [raster] Miscellaneous clean-ups. + + * src/raster/ftraster.c (New_Profile): Use NULL. + (End_Profile): Optimize variables. + (Convert_Glyph): Do not initialize `cProfile` yet. + (Render_Single_Pass): Tracing. + +2023-10-10 Alexei Podtelezhnikov + + * src/smooth/ftgrays.c: Move the sweep functions... + + ... out of the setjmp/longjmp scope for readability. + +2023-10-10 Alexei Podtelezhnikov + + * src/raster/ftraster.c: Tracing updates. + +2023-10-09 Zachary Zollman + + fix typo in FT_Outline_Decompose note + +2023-09-29 Alexei Podtelezhnikov + + * src/smooth/ftgrays.c (gray_render_conic) [SSE2]: Improve flow. + +2023-09-26 Alexei Podtelezhnikov + + * src/gxvalid/gxvcommn.h (GXV_USHORT_TO_SHORT): Removed. + +2023-09-25 Alexei Podtelezhnikov + + Comment typos. + +2023-09-25 Alexei Podtelezhnikov + + * src/base/ftcalc.c (FT_MOVE_SIGN): Enclose assignments. + +2023-09-21 Alexei Podtelezhnikov + + * include/freetype/internal/ftcalc.h (FT_MSB): Define for Solaris 11. + +2023-09-20 Alexei Podtelezhnikov + + [psaux] Use `FT_SqrtFixed`. + + * src/psaux/cffdecode.c : Call `FT_SqrtFixed`. + * src/psaux/psintrp.c : Ditto. + +2023-09-20 Alexei Podtelezhnikov + + [base] Reintroduce `FT_SqrtFixed`. + + The general square root calculations are not necessary in FreeType. + For vector normalization or length, FreeType uses special functions. + It is, however, required in the legacy CFF specifications. + + * src/base/ftcalc.c (FT_SqrtFixed): New function that uses either + Babylonian or bit-wise algorithm, whichever is faster for the given + situation. + * include/freetype/internal/ftcalc.h (FT_SqrtFixed): Declare it. + +2023-09-18 Alexei Podtelezhnikov + + * src/base/ftcalc.c /* FT_SqrtFixed */: Fix defunct overflow. + +2023-09-14 Alexei Podtelezhnikov + + * src/tools/apinames.c (read_header_file): Typos. + +2023-09-13 Alexei Podtelezhnikov + + Update 2 files + + - /src/base/ftcalc.c + - /include/freetype/internal/ftcalc.h + +2023-09-13 Ben Wagner + + [base] Fix typo to correct predicate for call + + * src/base/ftobj.c (FT_Get_Color_Glyph_Paint): check + `get_colr_glyph_paint` before calling `get_colr_glyph_paint` and not + `get_colr_layer` + +2023-09-12 Alexei Podtelezhnikov + + * src/psaux/cffdecode.c (cff_op_sqrt): Correct upper limit. + +2023-09-11 Alexei Podtelezhnikov + + * src/psaux/cffdecode.c (cff_op_sqrt): Improve initial guess. + +2023-09-11 Alexei Podtelezhnikov + + src/psaux/psintrp.c (cf2_escSQRT): Improve initial guess. + + The worst number of iterations decreased from 11 to 5. + +2023-09-11 Alexei Podtelezhnikov + + * src/type1/t1afm.c (t1_get_index): Restore `strlen` call. + + This reverts commit 8ed6d97446f2f3e5523da62eefbbf32ef7c1290e + and fixes + https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=62246 + +2023-09-10 Alexei Podtelezhnikov + + * src/cff/cffparse.c (CFF_Field_Handler): Some s/0/NULL/. + +2023-09-10 Alexei Podtelezhnikov + + [type1, cid, type42] Post-cleanup. + + * include/freetype/internal/psaux.h (T1_FIELD_ZERO): Terminating macro. + * src/cid/cidload.c (cid_parse_dict): Use while-loop. + * src/type1/t1load.c (parse_dict): Ditto. + * src/type42/t42parse.c (t42_parse_dict): Ditto. + +2023-09-09 Alexei Podtelezhnikov + + Update forgotten array termini. + + * src/cid/cidload.c (cid_field_records): Account for added `len`. + * src/type1/t1load.c (t1_keywords): Ditto. + * src/type42/t42parse.c (t42_keywords): Ditto. + +2023-09-09 Alexei Podtelezhnikov + + [type1, cid, type42] Streamline dictionary parsing. + + When matching the keywords, we avoid calculating their lengths by + checking the stored values. This itself is a sufficient pre-check + before diving into `memcmp`. Therefore, we remove explicit check of + the first characters. + + * include/freetype/internal/psaux.h (T1_FieldRec): Store length. + * src/cid/cidload.c (cid_parse_dict): Use `memcmp` and stored length. + * src/type1/t1load.c (parse_dict): Ditto. + * src/type42/t42parse.c (t42_parse_dict): Ditto. + +2023-09-09 Alexei Podtelezhnikov + + * src/type1/t1afm.c (t1_get_index): Avoid `strlen` call. + + Instead, we check the terminal zero. + +2023-09-08 Alexei Podtelezhnikov + + * src/type1/t1driver.c (t1_ps_get_font_value): Avoid redundant null. + +2023-09-08 Alexei Podtelezhnikov + + [cff, truetype] Improve prefix and suffix removal. + + * src/cff/cffobjs.c (remove_style): Rewrite using pointers. + (remove_subset_prefix): Unwrap loop and use `memmove`. + * src/truetype/ttobjs.c (tt_skip_pdffont_random_tag): Unwrap loop + and avoid `strlen`. + +2023-09-07 Alexei Podtelezhnikov + + * src/sfnt/ttpost.c (load_format_20): Micro-optimize. + +2023-09-05 Werner Lemberg + + [autofit] Fix synchronization mistake between FreeType and ttfautohint. + + Found by Behdad. + + * src/autofit/aflatin.c (af_latin_metrics_init_blues): Fix array size of + `blue_sorted`: FreeType doesn't have artificial blue zones. + +2023-09-04 Werner Lemberg + + [autofit] Fix typos. + + This also reduces the used heap size by a large factor. + + From Behdad. + + * src/autofit/afcjk.h (AF_CJKAxisRec): Use `AF_BLUE_STRINGSET_MAX_LEN`. + * src/autofit/aflatin.h (AF_LatinAxisRec): Ditto. + +2023-08-31 Alexei Podtelezhnikov + + * src/sfnt/ttpost.c (load_format_20): Rework tracing. + +2023-08-30 Alexei Podtelezhnikov + + [builds] Abbreviate the DLG submodule update. + + * autogen.sh, builds/toplevel.mk: Revise the command options. + +2023-08-29 Alexei Podtelezhnikov + + Comment added. + +2023-08-29 Alexei Podtelezhnikov + + * src/sfnt/ttpost.c (load_format_20): Permit long names. + + Fixes #1254. + +2023-08-27 Werner Lemberg + + [gzip] Update sources to zlib 1.13. + +2023-08-25 Werner Lemberg + + docs/release: Minor fixes. + +2023-08-25 Anurag Thakur + + docs/freetype-web.txt: New file. + +2023-08-25 Werner Lemberg + + * Version 2.13.2 released. + ========================== + + Tag sources with `VER-2-13-2'. + + * docs/VERSION.TXT: Add entry for version 2.13.2. + * docs/CHANGES: Updated. + * docs/release, docs/README, builds/macs/README: Updated. + + * README, src/base/ftver.rc, builds/windows/vc2010/index.html, + builds/windows/visualc/index.html, builds/windows/visualce/index.html, + builds/wince/vc2005-ce/index.html, builds/wince/vc2008-ce/index.html, + docs/freetype-config.1: s/2.13.1/2.13.2/, s/2131/2132/. + + * include/freetype/freetype.h (FREETYPE_PATCH): Set to 2. + + * builds/unix/configure.raw (version_info): Set to 26:1:20. + * CMakeLists.txt (VERSION_PATCH): Set to 2. + +2023-08-25 Alexei Podtelezhnikov + + * src/base/ftcalc.c (FT_MulAddFix): Simplify 32-bit rounding. + +2023-08-25 Werner Lemberg + + Fix clang warnings. + + * src/cffload.c (cff_blend_doBlend): Fix type of `sum`. + * src/truetype/ttgxvar.c (tt_var_load_item_variation_store): Fix type of + `word_delta_count`. + +2023-08-24 Werner Lemberg + + * subprojects/*.wrap: Updated. + +2023-08-24 Hugh McMaster + + builds/unix/configure.raw: Use variable to specify minimum Python version. + +2023-08-24 Alexei Podtelezhnikov + + * builds/toplevel.mk: Simplify version extraction. + +2023-08-22 Alexei Podtelezhnikov + + [base] Improve the matrix degeneracy check. + + Also fixes #1251. + + * src/base/ftcalc.c (FT_Matrix_Check): To avoid overflow, scale by shifting. + * include/freetype/internal/ftcalc.h (FT_Matrix_Check): Update description. + +2023-08-22 Werner Lemberg + + builds/toplevel.mk: Don't use `\#` in functions. + + The behaviour changed in GNU make 4.3, where `#` (without the backslash) + would be necessary. Using a variable instead the code works with both older + and newer GNU make versions. + + Fixes #1252. + +2023-08-19 Hugh McMaster + + builds/freetype.mk: Invoke `mkdocs` as a Python module + + FreeType's `refdoc` target currently allows users to override the + default Python path, which is useful for testing and development. + + In contrast, `mkdocs` is invoked via the default Python path. + + Invoking `mkdocs` via Python's module syntax allows for greater + flexibility, although there is no change for the default use case. + +2023-08-17 Ben Wagner + + [base] Avoid UB with memcpy + + `FT_NEW_ARRAY(p, 0)` sets `p` to `NULL`. `FT_Stream_ReadAt` with a + memory based stream uses `FT_MEM_COPY` which is `memcpy` which specifies + that it is undefined behavior for either the `src` or `dst` to be + `NULL`. Instead of forcing all callers work around calling + `FT_Stream_Read` when `buffer == NULL && count == 0` do the check in + `FT_StreamRead`. This allows any call with `count == 0` to succesfully + read zero bytes without UB. + + * src/base/ftstream.c (FT_Stream_ReadAt): skip `FT_MEM_COPY` when + `count == 0`. (FT_Stream_TryRead): ditto + + Fixes: #1250 + +2023-08-12 Werner Lemberg + + Fix warnings in tracing messages for 32bit compilation. + + Since we now require C99, use `%td` for `ptrdiff_t` and `%zu` for `size_t`. + +2023-08-04 Ben Wagner + + Avoid overflow in COLR bounds checks. + + The values read into `base_glyphs_offset_v1` and `layer_offset_v1` may + be in the range 0xFFFFFFFD-0xFFFFFFFF. On systems where `unsigned long` + is 32 bits adding 4 to such values will wrap and pass bounds checks but + accessing values at such offsets will be out of bounds. + + On the other hand `table_size` has already been tested to be at least + `COLRV1_HEADER_SIZE` (34) so it is safe to subtract 4 from it. + + * src/sfnt/ttcolr.c (tt_face_load_colr): subtract 4 from `table_size` + instead of adding 4 to font data offsets in bounds checks + + Fixes: https://crbug.com/1469348 + +2023-08-02 Alexei Podtelezhnikov + + * src/base/ftobjs.c (open_face_from_buffer): Silence `maybe-uninitialized`. + + We never call this function without a `driver_name` (#1245). + +2023-07-29 Alexei Podtelezhnikov + + [truetype] Reduce v40 footprint. + + * src/truetype/ttgload.c (TT_HInt_Glyph, tt_loader_set_pp, + tt_loader_init): Refactor code. + +2023-07-27 Alexei Podtelezhnikov + + [truetype] Remove Infinality for good (remaining bits). + + * src/truetype/ttobjs.h: Remove remaining fields. + * src/truetype/ttinterp.c: Do not initialize them. + * include/freetype/internal/tttypes.h: Remove descriptions. + +2023-07-27 Alexei Podtelezhnikov + + [truetype] Remove Infinality for good. + + Remove everything `#ifdef TT_SUPPORT_SUBPIXEL_HINTING_INFINALITY`, + which was undefined for a while now. + + * include/freetype/internal/tttypes.h: Ditto. + * src/truetype/truetype.c: Ditto. + * src/truetype/ttdriver.c: Ditto. + * src/truetype/ttgload.c: Ditto. + * src/truetype/ttinterp.c: Ditto. + * src/truetype/ttinterp.h: Ditto. + * src/truetype/ttobjs.c: Ditto. + * src/truetype/ttsubpix.[ch]: Remove files. + * src/truetype/rules.mk: Don't mention "ttsubpix.c". + +2023-07-21 Jouk Jansen + + * vms_make.com: Provide separate library compiled with C++. + + Some types on OpenVMS x86_64 (for example, `long') have different sizes + depending on whether compiled with either C or C++. In particular, + X-Windows applications crash if linked with the C++ version. + + This patch makes `vms_make.com` create a second version of the FreeType + library compiled with C++ if OpenVMS is running on the x86_64 platform. + +2023-07-21 Jouk Jansen + + * vms_make.com: Fix typos. + +2023-07-21 Jouk Jansen + + * src/smooth/ftgrays.c (FT_SSE2): Fix definition for VMS. + +2023-07-19 Jouk Jansen + + vms_make.com: Make use of additional libraries optional. + + Check whether `.olb` files are present. + + Also check for the HarfBuzz library. + +2023-07-19 Jouk Jansen + + vms_make.com: Add `/warn=noinfo` to `CFLAGS`. + + This reduces enormously the informationals while compiling on x86_64 (i.e., + which `.h` file is inluded form where). + +2023-07-18 Ben Wagner + + [woff2] Clean up on large brotli expansion + + * src/sfnt/sfwoff2.c (woff2_open_font): set error and goto cleanup + + Fixes: https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=60711 + +2023-07-16 Werner Lemberg + + [woff2] Avoid allocation bomb. + + This is a fix for commit 85167dbd5, reported as + + https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=60615 + + * src/sfnt/sfwoff2.c (MAX_SFNT_SIZE): New macro. + (woff2_open_font): Use it to limit the maximum size of an uncompressed WOFF2 + font. + +2023-07-14 Werner Lemberg + + [cff] Fix compiler warning. + + * src/cff/cffparse.c, src/cff/cffparse.h: Make `cff_parse_fixed` a local + function. + +2023-07-14 Ben Wagner + + [woff2] Remove sfnt size guess check + + In WOFF the `totalSfntSize` must be correct, however in WOFF2 this value + is now just a hint and a conforming implementation must not reject + otherwise valid data if the `totalSfntSize` turns out not to be exact. + + * src/sfnt/sfwoff2.c (woff2_open_font): remove check that uncompressed + woff2 data would fit in the sfnt size guess. + + Fixes: #1235 + +2023-07-14 Skef Iterum + + [cff] Make blend operator work with floats in private dicts. + + The CFF2 blend operator takes N default values and corresponding + sets of deltas and pushes N values specific to a designspace + location. CFF has a floating point numeric type and the FreeType + blending code was not converting those into its internal 16.16 + Fixed type format. + + Fixes #1243. + + * src/cff/cffparse.c (do_fixed): Handle floating point numbers. + Also fix scaling overflow check for integer-to-fixed conversion. + + * src/cff/cffload.c (cff_blend_doBlend): Updated. + +2023-07-08 Hin-Tak Leung + + * src/truetype/ttgload.c (TT_Hint_Glyph): More mostly cosmetic update. + + This is a follow-up to commit 49c74ac02, which creates a new local variable + "exec = loader->exec", and shortening a lot of "loader->exec". This commit + does two more such changes missed in that first commit. + +2023-07-06 Hugh McMaster + + [gzip] Don't compile internal zlib development files when using system zlib. + + `src/gzip/rules.mk` compiles the internal zlib sources even when using the + zlib development files provided by a host system. If the internal zlib + development files are not present, FreeType fails to build from source. + + This patch ensures the internal zlib development files are only + prerequisites when not using zlib development files on a host system. + + * src/gzip/rules.mk (GZIP_DRV_SRCS): Define conditionally. + +2023-06-24 Werner Lemberg + + * Version 2.13.1 released. + ========================== + + Tag sources with `VER-2-13-1'. + + * docs/VERSION.TXT: Add entry for version 2.13.1. + * docs/CHANGES: Updated. + * docs/release, docs/README, builds/macs/README: Updated. + + * README, src/base/ftver.rc, builds/windows/vc2010/index.html, + builds/windows/visualc/index.html, builds/windows/visualce/index.html, + builds/wince/vc2005-ce/index.html, builds/wince/vc2008-ce/index.html, + docs/freetype-config.1: s/2.13.0/2.13/1/, s/2130/2131/. + + * include/freetype/freetype.h (FREETYPE_PATCH): Set to 1. + + * builds/unix/configure.raw (version_info): Set to 26:0:20. + * CMakeLists.txt (VERSION_PATCH): Set to 1. + + * subprojects/libpng.wrap, subprojects/zlib.wrap, subprojects/dlg: Updated. + +2023-06-09 suzuki toshiya + + Comment fixes. + +2023-06-09 Werner Lemberg + + [sdf] Correct handling of empty glyphs. + + This is a refinement of commit 7b3ebb9. + + * src/sdf/ftsdfrend.c (ft_sdf_render): Goto 'Exit' instead of directly + returning. + (fd_bsdf_render): Ditto, also taking care of setting `FT_GLYPH_OWN_BITMAP` + correctly. + +2023-06-05 Ben Wagner + + Mark FT_Renderer_Class::raster_class as pointer to const + + The `FT_DEFINE_RASTER_FUNCS` macro declares a `const FT_Raster_Funcs`. + The address of the definition is taken and assigned to + `FT_Renderer_Class::raster_class` which is currently `FT_Raster_Funcs*`. + Until recently the `const` was cast away and with the removal of the + cast there are now warnings about dropping this `const`. Instead of + adding back the casts, make `FT_Renderer_Class::raster_class` a pointer + to const, as is done with pointers in other interfaces. + + * include/freetype/ftrender.h (FT_Renderer_Class_): mark `raster_class` + as const. + +2023-06-03 Ben Wagner + + Fix some `FT_Fixed` vs. `FT_Long` confusion. + + `FT_Fixed` and `FT_Long` are both typedef'ed to be `signed long`. However, + `FT_Fixed` implies that the lower 16 bits are being used to express + fractional values and so these two types should not be confused. + + * include/freetype/internal/services/svmm.h (FT_Set_MM_Blend_Func): Use + `FT_Fixed` for `coords`. Users are passing `FT_Fixed` and implementations + are taking `FT_Fixed`. + (FT_Get_MM_Blend_Func): Ditto. + + * src/autofit/afcjk.c (af_cjk_metrics_check_digits): Use `FT_Long` for + `advance` and `old_advance`. `advance`'s address is passed as `FT_Long*` to + `af_shaper_get_elem`, which writes the advance in em units (not fixed). The + exact value is not important here as it is only compared to check whether it + has changed. + + * src/autofit/aflatin.c (af_latin_metrics_check_digits): Ditto. + +2023-06-03 Ben Wagner + + */*: Remove many function pointer casts. + + In C it is undefined behavior to call a function through a function pointer + of a different type. This is now detected by the Control Flow Integrity + Sanitizer. All known issues have already been fixed. Prevent any + accidental re-introduction by removing function pointer casts when defining + services. The services will call the service functions through the function + pointers on the service. As a result the functions must have the same type + so there should be no need to cast. Removing the casts allows compilers to + warn about assignment to an incompatible function pointer type. + +2023-06-03 Werner Lemberg + + Minor formatting. + +2023-05-23 Werner Lemberg + + Replace `sprintf` with `snprintf`. + + Fixes #1233. + + * include/freetype/config/ftstdlib.h (ft_sprintf): Replace with... + (ft_snprintf): This new macro. + + * src/autofit/afhints.c (af_print_idx): Add argument to pass the buffer + size. + (af_glyph_hints_dump_points, af_glyph_hints_dump_segments, + af_glyph_hints_dump_edges): Updated. + + * src/bdf/bdflib.c (BUFSIZE): New macro. + (bdf_parse_properties_, bdf_parse_start_): Use `ft_snprintf`. + + * src/tools/ftrandom/ftrandom.c (do_test): Use `snprintf`. + +2023-05-23 Werner Lemberg + + docs/DEBUG: Formatting. + +2023-05-20 suzuki toshiya + + [doc] Type1 GX (sfnt-wrapped Type1) is not supported. + + * docs/formats.txt: Clarify the reference of Type1 GX, + and state that this format is not supported. This + is because the content `TYP1' table is not exactly same + with the Type1 font format specification; no eexec + encryption is used. For detail and concrete examples, + see the analysis on: + + https://gitlab.freedesktop.org/freetype/freetype/-/issues/1231 + +2023-05-19 Craig White + + Add missing end quote of a string in the example code of FT_Trace_Set_Level + +2023-05-19 Seigo Nonaka + + [truetype] Reduce heap allocation of `deltaSet` variation data. + + `deltaSet` is an array of packed integers that can be 32 bits, 16 bits, or + 8 bits. Before this change, these values were unpacked to 32-bit integers. + However, this can cause big heap allocations, e.g., around 500 KByte for + 'NotoSansCJK'. To reduce this amount, store the packed integers and unpack + them just before passing to the calculation. At calculation time, due to + the variable length of region indices, temporary heap allocations are + necessary. This heap allocation is not negligible and visible in `ftbench` + results. So, use stack-allocated arrays for short array calculations. + + Fixes #1230. + + * include/freetype/internal/ftmmtypes.h (GX_ItemVarDataRec): New fields + `wordDeltaCount` and `longWords`. + + * src/truetype/ttgxvar.c (tt_var_load_item_variation_store): Load packed + data. + (tt_var_get_item_delta): Unpack data before applying. + +2023-05-17 Jouk Jansen + + vms_make.com: Create shared executable for x86 version of OpenVMS. + +2023-05-15 Werner Lemberg + + Add new load flag `FT_LOAD_NO_SVG`. + + Modern color fonts often contain both an 'SVG' and 'COLR' table. FreeType + always preferred 'SVG' over 'COLR' (this was a design decision), however, + this might not be the right choice for the user. The new flags makes + FreeType ignore the 'SVG' table while loading a glyph. + + Fixes #1229. + + * include/freetype/freetype.h (FT_LOAD_NO_SVG): New macro. + + * src/base/ftobjs.c (FT_Load_Glyph), src/cff/cffgload.c (cff_slot_load), + src/truetype/ttgload.c (TT_Load_Glyph): Use it. + +2023-05-13 Werner Lemberg + + .mailmap: Updated. + +2023-05-13 Alexei Podtelezhnikov + + [cache] Merge functions. + + * src/cache/ftccache.c (FTC_Cache_Init): Merge into... + (ftc_cache_done): ... this function, with unnecessary checks removed. + +2023-05-13 Alexei Podtelezhnikov + + [cache] Minor casting and cosmetic updates. + + * src/cache/ftcglyph.c (ftc_gcache_{init,done}): Remove casting. + (FTC_GCache_Lookup): Cosmetic variable renaming. + * src/cache/ftcsbits.c (ftc_snode_compare): Formatting. + +2023-05-12 Werner Lemberg + + * include/freetype/ftcache.h: Typo, punctuation. + +2023-05-12 Alexei Podtelezhnikov + + * include/freetype/ftcache.h: Formatted and updated. + +2023-05-12 suzuki toshiya + + * include/freetype/internal/t1types.h: Fix the indentation. + +2023-05-11 Alexei Podtelezhnikov + + [cache] Revise the dynamic hash table accounting. + + Instead of counting entries relative to the middle of the hash table, + this switches to the absolute counter with the full index range mask. + As a result, some calculations become a bit simpler. The cache resizing + logic stays largely the same. + + * src/cache/ftccache.h (FTC_NODE_TOP_FOR_HASH): Revised with new counter. + * src/cache/ftccache.c (ftc_get_top_node_for_hash): Ditto. + (ftc_cache_resize): Simplify reallocations and stop their zeroing. + (ftc_cache_init): Stop over-allocating but keep zeroing initially. + (FTC_Cache_Clear, FTC_Cache_RemoveFaceID): Updated accordingly. + +2023-05-11 suzuki toshiya + + [t1cid] Set FT_FACE_FLAG_CID_KEYED. + + * cidobjs.c (cid_face_init): Set FT_FACE_FLAG_CID_KEYED. + + * cidriver.c (cid_get_is_cid): Comment about the case that + is_cid cannot guarantee the glyph collection specification. + +2023-05-09 Jouk Jansen + + * src/smooth/ftgrays.c (FT_SSE2): Don't define for VMS. + +2023-05-08 Werner Lemberg + + * src/cff/cffdrivr.c (cff_glyph_load): Fix guard for `size`. + + This was forgotten to change in commit 2b54eba36b (in May 2004). + + Reported as + + https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=58739 + +2023-05-08 Werner Lemberg + + Minor compiler warning fixes. + + * src/autofit/afcjk.c (af_cjk_get_standard_widths), src/autofit/aflatin.c + (af_latin_get_standard_widths): Use `FT_CALLBACK_DEF`. + + * src/cff/cffparse.c (cff_parser_run): Initialize and fix allocation of `q`. + +2023-05-08 Werner Lemberg + + * src/psaux/t1cmap.c: Signature fixes. + +2023-05-08 Werner Lemberg + + * src/bzip2/ftbzip2.c: Signature fixes. + +2023-05-08 Werner Lemberg + + [cache] Signature fixes. + + * src/cache/ftcglyph.c, src/cache/ftcglyph.h (FTC_GNode_Compare): Remove + redundant function. It is equivalent to `ftc_gnode_compare` and becomes + completely meaningless with fixed signatures. + Update all callers. + + * src/cache/ftcsbits.c, src/cache/ftcsbits.h (FTC_SNode_Compare): Remove + redundant function. It is equivalent to `ftc_snode_compare` and becomes + completely meaningless with fixed signatures. + Update all callers. + +2023-05-07 Werner Lemberg + + [sdf] Signature fixes. + +2023-05-07 Werner Lemberg + + * src/svg/ftsvg.c: Signature fixes. + +2023-05-07 Werner Lemberg + + [raster] Signature fixes. + +2023-05-07 Werner Lemberg + + [smooth] Signature fixes. + +2023-05-07 Werner Lemberg + + [pshinter] Signature fixes. + + * src/pshinter/pshrec.c (t1_hints_close, t1_hints_apply): New wrapper + functions. + (t1_hints_funcs_init): Use them. + (t2_hints_close, t2_hints_apply): New wrapper functions. + (t2_hints_funcs_init): Use them. + +2023-05-07 Werner Lemberg + + [autofit] Signature fixes. + +2023-05-07 Werner Lemberg + + * src/sfnt/ttcmap: Signature fixes. + +2023-05-07 Werner Lemberg + + * src/pcf/pcfdrivr.c: Signature fix. + +2023-05-07 Werner Lemberg + + * src/winfonts/winfnt.c: Signature fixes. + +2023-05-07 Werner Lemberg + + * src/type42/t42parse.c: Signature fixes. + +2023-05-07 Werner Lemberg + + [pfr] Signature fixes. + +2023-05-07 Werner Lemberg + + * src/cid/cidload.c: Signature fixes. + +2023-05-07 Werner Lemberg + + * src/cff/cffcmap.c: Signature fixes. + +2023-05-07 Werner Lemberg + + * src/type1/t1load.c: Signature fixes. + +2023-05-07 Werner Lemberg + + [truetype] Signature fixes. + +2023-05-07 Werner Lemberg + + [base] Signature fixes. + +2023-05-07 Werner Lemberg + + * src/type42/t42drivr.c: Clean up interface. + + Ensure that all driver functions use the signature of the service or driver. + This avoids pointer mismatches, which are technically undefined behaviour. + Recent compilers are more picky in catching them as part of Control Flow + Integrity tests. + +2023-05-07 Werner Lemberg + + * src/type1/*: Clean up interface. + + Ensure that all driver functions use the signature of the service or driver. + This avoids pointer mismatches, which are technically undefined behaviour. + Recent compilers are more picky in catching them as part of Control Flow + Integrity tests. + +2023-05-07 Werner Lemberg + + * src/truetype/*: Clean up interface. + + Ensure that all driver functions use the signature of the service or driver. + This avoids pointer mismatches, which are technically undefined behaviour. + Recent compilers are more picky in catching them as part of Control Flow + Integrity tests. + +2023-05-07 Werner Lemberg + + * src/sfnt/sfdriver.c, src/sfnt/ttbdf.c: Clean up interface. + + Ensure that all driver functions use the signature of the service or driver. + This avoids pointer mismatches, which are technically undefined behaviour. + Recent compilers are more picky in catching them as part of Control Flow + Integrity tests. + + * src/sfnt/sfdriver.c (sfnt_load_table): New wrapper function. + (sfnt_service_sfnt_table): Use it. + +2023-05-07 Werner Lemberg + + * src/psnames/psmodule.c: Use `FT_CALLBACK_DEF`. + +2023-05-07 Werner Lemberg + + * src/pfr/pfrdrivr.c: face -> pfrface, pfrface -> face. + +2023-05-07 Werner Lemberg + + * src/pcf/pcfdrivr.c: Clean up interface. + + Ensure that all driver functions use the signature of the service or driver. + This avoids pointer mismatches, which are technically undefined behaviour. + Recent compilers are more picky in catching them as part of Control Flow + Integrity tests. + +2023-05-07 Werner Lemberg + + * src/cid/cidriver.c: Clean up interface. + + Ensure that all driver functions use the signature of the service or driver. + This avoids pointer mismatches, which are technically undefined behaviour. + Recent compilers are more picky in catching them as part of Control Flow + Integrity tests. + +2023-05-07 Werner Lemberg + + * src/bdf/bdfdrivr.c: Clean up interface. + + Ensure that all driver functions use the signature of the service or driver. + This avoids pointer mismatches, which are technically undefined behaviour. + Recent compilers are more picky in catching them as part of Control Flow + Integrity tests. + +2023-05-07 Werner Lemberg + + * src/cff/*: Clean up interface. + + Ensure that all driver functions use the signature of the service or driver. + This avoids pointer mismatches, which are technically undefined behaviour. + Recent compilers are more picky in catching them as part of Control Flow + Integrity tests. + +2023-05-06 Werner Lemberg + + [truetype] Fix style name handling for variation fonts. + + * include/freetype/internal/tttypes.h (TT_FaceRec): New field + `non_var_style_name`. + + * src/sfnt/sfobjs.c (sfnt_load_face): Initialize `non_var_style_name`. + (sfnt_done_face): Free `non_var_style_name`. + + * src/truetype/ttgxvar.c (TT_Set_Named_Instance): Restore non-VF style name + if switching back to non-VF mode. + +2023-05-06 Werner Lemberg + + [truetype] Fix PostScript name handling for variation fonts. + + A variation font's PostScript name of a named instance is usually different + from the PostScript name of an unnamed instance. However, if a change + between a named instance and an unnamed instance with exactly the same + design axis values happened, it was possible that the PostScript name wasn't + correctly updated. + + This commit reorganizes the code to handle this issue within the top-level + API functions, using a new service to trigger recomputation of the + PostScript name. + + * include/freetype/internal/services/svmm.h (FT_Construct_PS_Name_Func): New + typedef. + (FT_Service_MultiMasters): New field `construct_ps_name`. + (FT_DEFINE_SERVICE_MULTIMASTERSREC): Updated. + + * src/base/ftmm.c (FT_Set_Var_Design_Coordinates, + FT_Set_MM_Blend_Coordinates, FT_Set_Var_Blend_Coordinates): Call + `mm->construct_ps_name` to handle `postscript_name`. + (FT_Set_Named_Instance): Call `mm->construct_ps_name` to handle + `postscript_name`. + Use shortcut. + * src/cff/cffdrivr.c (cff_construct_ps_name): New function. + (cff_service_multi_masters): Updated. + + * src/truetype/ttgxvar.c (tt_set_mm_blend): Don't handle `postscript_name`. + (TT_Set_MM_Blend): Simplify. + (TT_Set_Named_Instance): Return -1 if axis values haven't changed. + Don't set `face_index`. + (tt_construct_ps_name): New function. + + * src/truetype/ttgxvar.h: Updated. + + * src/truetype/ttdriver.c (tt_service_gx_multi_masters): Updated. + + * src/type1/t1driver.c (t1_service_multi_masters): Updated. + + * src/type1/t1load.c (T1_Set_MM_Blend): Simplify. + +2023-05-06 Werner Lemberg + + * include/freetype/internal/services/svmm.h: Minor changes. + +2023-05-06 Werner Lemberg + + [truetype] Fix deactivation of variation font handling. + + According to the documentation, the functions `FT_Set_Named_Instance`, + `FT_Set_MM_Design_Coordinates`, `FT_Set_Var_Design_Coordinates`, and + `FT_Set_Var_Blend_Coordinates` can unset the `FT_FACE_FLAG_VARIATION` flag. + (The same is true for `FT_Set_MM_WeightVector` but this information was + accidentally omitted from the documentation.) + + However, if a call of these functions didn't change the axis values this + could fail because internal shortcuts exited too early. + + This commit reorganizes the code to handle `FT_FACE_FLAG_VARIATION` in the + top-level API functions, also taking care of the issue at hand. + + * src/base/ftmm.c (FT_Set_MM_Design_Coordinates, FT_Set_MM_WeightVector, + FT_Set_Var_Design_Coordinates, FT_Set_MM_Blend_Coordinates, + FT_Set_Var_Blend_Coordinates): Handle `FT_FACE_FLAG_VARIATION`. + + * src/truetype/ttgxvar.c (TT_Set_MM_Blend, TT_Set_Var_Design, + TT_Set_Named_Instance) Don't handle `FT_FACE_FLAG_VARIATION`. + + * src/type1/t1load.c (T1_Set_MM_Blend, T1_Set_MM_WeightVector, + T1_Set_MM_Design): Ditto. + + * src/cff/cffobjs.c (cff_face_init): Use `FT_Set_Named_Instance` instead of + low-level functions. + + * src/truetype/ttobjs.c (tt_face_init): Ditto. + +2023-05-06 Werner Lemberg + + s/set_instance/set_named_instance/ + + * include/freetype/internal/services/svmm.h (FT_Set_Instance_Func): Renamed + to... + (FT_Set_Named_Instance_Func): ...this. + (FT_Service_MultiMasters): Rename `set_instance` to `set_named_instance`. + (FT_DEFINE_SERVICE_MULTIMASTERSREC): Updated. + + * src/base/ftmm.c (FT_Set_Named_Instance): Updated. + + * src/cff/cffdrivr.c (cff_set_instance): Renamed to... + (cff_set_named_instance): ...this. + (cff_service_multi_masters): Updated. + * src/cff/cffobjs.c (cff_face_init): Updated. + + * src/truetype/ttdriver.c (tt_service_gx_multi_masters): Updated. + + * src/type1/t1driver.c (t1_service_multi_masters): Updated. + +2023-05-06 Werner Lemberg + + New Variation Font function `FT_Get_Default_Named_Instance`. + + * include/freetype/ftmm.h, src/base/ftmm.c (FT_Get_Default_Named_Instance): + New function. + + * include/freetype/internal/services/svmm.h + (FT_Get_Default_Named_Instance_Func): New typedef. + (FT_Service_MultiMasters): New field `get_default_named_instance`. + (FT_DEFINE_SERVICE_MULTIMASTERSREC): Updated. + + * include/freetype/internal/tttypes.h (TT_Face): New field + `var_default_named_instance`. + + * src/sfnt/sfobjc.s (sfnt_init_face): Initialize + `var_default_named_instance`. + + * src/cff/cffdrivr.c (cff_get_default_named_instance): New function. + (cff_service_multi_masters): Updated. + + * src/truetype/ttgxvar.c (TT_Get_MM_Var): Initialize + `var_default_named_instance`. + (TT_Get_Default_Named_Instance): New function. + * src/truetype/ttgxvar.h: Updated. + * src/truetype/ttdriver.c (tt_service_gx_multi_masters): Updated. + + * src/type1/t1driver.c (t1_service_multi_masters): Updated. + + * docs/CHANGES: Updated. + +2023-05-06 Werner Lemberg + + [cid] Improve tracing messages; formatting. + +2023-05-04 Alexei Podtelezhnikov + + * src/cache/ftccache.c (ftc_node_hash_unlink): Minor. + +2023-05-04 Alexei Podtelezhnikov + + * src/cache/ftcmru.c (FTC_MruList_RemoveSelection): Purge backwards. + +2023-05-04 Alexei Podtelezhnikov + + [cache] Revise list cleansing. + + * src/cache/ftcmru.c (FTC_MruList_RemoveSelection): Use one loop to + do it. + * src/cache/ftcmanag.c (FTC_Manager_Compress, FTC_Manager_FlushN): + Streamline loops. + +2023-05-03 suzuki toshiya + + [t1cid] Improve cid_get_cid_from_glyph_index(). + + Update cid_get_cid_from_glyph_index() to + return an error and CID=0 in the case that + the specified glyph index points to an invalid + entry. + + cidgload.h (cid_compute_fd_and_offsets): + Declare new helper function to set the + fd_select and 2 offsets to access the glyph + description data. + + cidgload.c (cid_compute_fd_and_offsets): + Move the part loading fd_select and 2 offsets + from cid_load_glyph() to here. If the loaded + parameters are broken, return the Invalid_Offset + error. This function does not load the glyph + data, only fills these parameters. + + (cid_load_glyph): Use new helper function in above. + + cidriver.c (cid_get_cid_from_glyph_index): + Check whether the requested glyph index points + to a valid entry, by calling cid_compute_fd_and_offsets(). + If it is valid, fill the cid by the glyph + index (=CID). If it is invalid, return an + error and fill the cid by 0. + +2023-04-30 Werner Lemberg + + API documentation: Re-organize chapters and sections + + * Split the very long 'Base Interface' section into smaller sections. + * Split the 'Core API' chapter into two chapters. + * Remove single enumeration values from `@order` fields since they have no + effect. + +2023-04-29 Alexei Podtelezhnikov + + * src/sfnt/pngshim.c (Load_SBit_Png): Remove FALL_THROUGH warning. + +2023-04-28 Werner Lemberg + + * src/sfnt/ttload.c (tt_face_load_font_dir): Add another guard. + + Reject 'OTTO' fonts with no valid tables. + +2023-04-28 Werner Lemberg + + * src/cff/cffdrivr/c (cff_get_ps_name): Avoid unnecessary crash. + + The situation can happen if `FT_New_Face` (or one of its siblings) is called + with a negative index to get the number of contained faces, followed + immediately by a call to `FT_Get_Postscript_Name`. While this is not a valid + use of the FreeType library there is no need for a crash. + + Fixes #1219. + +2023-04-28 Werner Lemberg + + * src/cff/cffdrivr.c (cff_ps_get_font_info): Reject 'CFF2' format. + +2023-04-28 Werner Lemberg + + * src/cid/cidgload.c (cid_load_glyph): Fix compiler warnings. + +2023-04-28 Werner Lemberg + + Minor documentation updates. + +2023-04-27 Werner Lemberg + + * src/ttgxvar.c: Minor changes. + + (TT_Get_MM_Var): Improve tracing messages. + (tt_set_mm_blend): Minor speed-up. + +2023-04-27 Werner Lemberg + + s/this is,/that is,/ + +2023-04-27 Alexei Podtelezhnikov + + [bdf] Clean up the atom property parsing. + + * src/bdflib.c (bdf_is_atom_): Refactor code with fewer checks. + (bdf_list_join_): Return NULL. + (bdf_add_comment_): Use const argument. + (bdf_get_property): Ditto, ditto, make the function static. + * src/bdf.h (bdf_get_property): Remove prototype. + +2023-04-25 Werner Lemberg + + Improve/add source comments and documentation. + +2023-04-25 Werner Lemberg + + [sfnt] Fix handling of PS names for Variation Fonts. + + * src/sfnt/sfdriver.c (get_win_string, get_apple_string): Continue + construction of string if an invalid character is encountered. + + Fixes #1218. + +2023-04-24 suzuki toshiya + + [t1cid] Change the trace messages of the charstrings retrieval errors. + + The t1cid driver catches 3 types of errors in + the charstrings retrieval; + A) The invalid FD number, there are 2 subtypes; + A-1) FD number is the maximum number fitting to FDBytes. + A-2) FD number is greater than num_dicts. + B) Declared length is overrunning. + C) Declared length is invalid (its end is before its head). + + Considering that some widely distributed fonts + (e.g., "CJKV" book by O'Reilly) have A-1 errors + in the unimplemented glyphs, the trace level for + A-1 is calmed to level 1. + + The errors A-2, B, and C would be irregular; + their trace levels are kept at level 0, but + the updated trace messages include the CID number. + +2023-04-24 suzuki toshiya + + [truetype] Fix `make multi'. + + * src/truetype/ttgxvar.c: Include freetype/internal/services/svmetric.h + for the FT_Service_MetricsVariations type definition. + +2023-04-19 Ben Wagner + + [services] FT_Size_Reset_Func to return FT_Error + + The `MetricsVariations` `FT_Size_Reset_Func` is currently defined to + return `void`, but the implementations return `FT_Error`. Even though + the pointers passed will be the same at runtime, calling a function + through a pointer of a different type from the original function pointer + type is undefined behavior. This may be caught at runtime by Control + Flow Integrity with something like clang's `cfi-icall`. + + Issue: https://crbug.com/1433651 + + * include/freetype/internal/services/svmetric.h (FT_Size_Reset_Func): + return `FT_Error` instead of `void`. + +2023-04-17 Ben Wagner + + [truetype] tt_size_reset_height to take FT_Size + + The `MetricsVariations` `FT_Size_Reset_Func` is defined to take an + `FT_Size`. Because `tt_size_reset_height` is to be used as such a + function, it must also take an `FT_Size` instead of a `TT_Size`. Even + though the pointers passed will be the same at runtime, calling a + function through a pointer of a different type from the original + function pointer type is undefined behavior. This may be caught at + runtime by Control Flow Integrity with something like clang's + `cfi-icall`. + + Issue: https://crbug.com/1433651 + + * src/truetype/ttobjs.h (tt_size_reset_height): take `FT_Size` + + * src/truetype/ttobjs.c (tt_size_reset_height): take `FT_Size` and + update documentation + +2023-04-13 Werner Lemberg + + * src/truetype/ttinterp.c: Remove outdated comments. + +2023-04-11 Ben Wagner + + [sfnt, truetype] Add `size_reset` to `MetricsVariations`. + + This is a generalization of commit + + ``` + commit e6699596af5c5d6f0ae0ea06e19df87dce088df8 + Author: Werner Lemberg + Date: Thu Feb 2 11:38:04 2017 +0100 + + [truetype] Fix MVAR post-action handling. + ``` + + It is also possible for plain `CFF ` style fonts to contain an `fvar` and + `MVAR` table and use `cff_metrics_adjust`. `tt_size_reset` should only be + called with `TT_Size` and never with `CFF_Size`. + + Allow the "metrics-variations" service to specify the correct function (if + any) to reset `FT_Size`s after adjusting metrics. + + * src/truetype/ttobjs.c (tt_size_reset): Split off some functionality + into... + (tt_size_reset_height): ... this new function. + + * src/truetype/ttdriver.c (tt_service_metrics_variations): Add + `size_reset`. + (tt_size_select, tt_size_request): Updated. + + * src/truetype/ttobjs.h: Updated. + + * include/freetype/internal/services/svmetric.h (MetricsVariations): Add + `size_reset`. + (FT_DEFINE_SERVICE_METRICSVARIATIONSREC): Updated. + + * include/freetype/internal/tttypes.h (TT_FaceRec_): Rename `var` to + `tt_var` and add `face_var`. + + * src/cff/cffdrivr.c (cff_service_metrics_variations): Add `size_reset`. + (cff_hadvance_adjust, cff_metrics_adjust): Updated. + + * src/cff/cffobjs.c (cff_face_init): Use `face_var`. + + * src/sfnt/sfobjs.c (sfnt_init_face): Initialize `face_var`. + + * src/sfnt/ttmtx.c (tt_face_get_metrics): Use `tt_var`. + + * src/truetype/ttgxvar.c (tt_size_reset_iterator): Renamed to... + (ft_size_reset_iterator): ... this new function. + Call `size_reset`. + (tt_apply_mvar): Pass `size_reset` to `ft_size_reset_iterator`. + + Fixes #1211 + +2023-04-10 Alexei Podtelezhnikov + + * src/cff/cffcmap.c (cff_cmap_encoding_char_next): Abbreviate. + +2023-04-10 Alexei Podtelezhnikov + + Align `char_next` return types. + + This is mostly cosmetic because FT_UInt and FT_UInt32 are likely identical. + + * src/sfnt/ttcmap.c, src/cff/cffcmap.c, src/psaux/t1cmap.c, + src/psnames/psmodule.c, include/freetype/internal/service/svpcsmap.h, + src/pfr/pfrcmap.c, src/winfonts/winfnt.c (*_char_next): return FT_UInt. + +2023-04-09 Alexei Podtelezhnikov + + [sfnt] Clean up CMAP{4,12,13} handling. + + This moves the charcode overflow checks upstream and turns some + while-loops into the do-while ones to avoid the uninitialized warnings. + This should slightly reduce the number of checks and jumps. + + * src/sfnt/ttcmap.c (tt_cmap{4,12,13}_next, + tt_cmap{4.12.13}_char_map_linear): Remove the charcode overflow check. + (tt_cmap{4,12,13}_char_map_binary): Ditto and use do-while. + (tt_cmap{12,13}_char_next): Add the overflow check. + +2023-04-03 Alexei Podtelezhnikov + + * src/sfnt/ttpost.c (load_format_25): Do not abort frame reading. + +2023-04-03 Alexei Podtelezhnikov + + * src/sfnt/ttpost.c (load_format_*): Streamline frame reading. + +2023-04-02 Alexei Podtelezhnikov + + * src/sfnt/ttpost.c: Formatting and comments. + +2023-04-02 Alexei Podtelezhnikov + + [sfnt] Consolidate POST version 2.0 and 2.5 (pt 2). + + * src/sfnt/ttpost.c (load_format_20, load_format_25): Update arguments + and move shared calls and checks upstream to... + (load_post_names): ... this function. + (tt_face_free_ps_names, tt_face_get_ps_name): Updated. + +2023-04-02 Alexei Podtelezhnikov + + [sfnt] Consolidate POST version 2.0 and 2.5 (pt 1). + + The deprecated POST version 2.5 can be handled using the data + structures of version 2.0. The goal is to reduce the footprint. + + * include/freetype/internal/tttypes.h (TT_Post_Names): Absorb and... + (TT_Post_20, TT_Post_25): ... remove these structures. + src/sfnt/ttpost.c (load_post_names, tt_face_get_ps_name, + tt_face_free_ps_names, load_format_20): Updated accordingly. + (load_format_25): ditto and convert offsets to glyph indices. + +2023-04-01 Alexei Podtelezhnikov + + [sfnt] Miscellaneous POST clean-ups. + + * src/sfnt/ttpost.c (load_format_20): Decrease casts. + (load_format_25): Check the table length and impose a theoretical + glyph number limit usable with 8-bit offset. Decrease casts. + (load_post_names): Pass the mapping data length without 2 bytes. + +2023-03-30 Alexei Podtelezhnikov + + * src/sfnt/ttpost.c (load_format_20): Simplify comutations. + +2023-03-29 Alexei Podtelezhnikov + + [sfnt] Streamline POST format 2.0 handing (cont'd). + + * src/sfnt/ttpost.c (load_format_20): Co-allocate the string data and + their pointers, which makes it easier to handle and free them. + (tt_face_free_ps_names): Updated. + * include/freetype/internal/tttypes.h (TT_Post_20): Update type. + +2023-03-20 Alexei Podtelezhnikov + + [cff] Simplify `t2_strings` management in the old engine. + + * src/cff/cffparse.c (cff_parser_run): Allocate the charstring buffers + and the list nodes together so that they can be freed at once. + (finalize_t2_strings): Removed as no longer needed. + (cff_parser_done): Updated. + +2023-03-19 Alexei Podtelezhnikov + + [cff] Rework the stream limit checks. + + The old stream limit checks, before 6986ddac1ece, were good but + pointless for the crafted t2_strings. Checking limits there is + not necessary as they are created to hold all data. By using two + conditions, we can detect the actual crossing of the stream boundary + as appropriate for the stream pointer only. The t2_strings parsing + will not be triggering these checks. + + * src/cff/cffparse.c (cff_parser_within_limits): Removed. + (cff_parse_real, cff_parse_integer): Redesign the stream limit check. + (cff_parse_num, do fixed, cff_parse_fixed_dynamic): Update callers. + +2023-03-18 Alexei Podtelezhnikov + + * src/truetype/ttgload.c (TT_Load_Simple_Glyph): Use for-loop. + + Even though we never call `TT_Load_Simple_Glyph` with zero contours, + out of abundance of precaution, let's handle this case properly. + +2023-03-18 Alexei Podtelezhnikov + + [truetype] Clean up zeroing and local variables. + + * src/truetype/ttgload.c (TT_Process_Simple_Glyph): Avoid zeroing. + (load_truetype_glyph): Avoid zeroing and clean local variables. + +2023-03-16 Werner Lemberg + + * include/freetype/ftsystem.h (FT_Stream_IoFunc): Improve documentation. + + Fixes #1208. + +2023-03-16 Alexei Podtelezhnikov + + * src/base/ftsynth.c (FT_GlyphSlot_AdjustWeight): New API. + +2023-03-16 Alexei Podtelezhnikov + + [truetype] Clean up glyph loading. + + * src/truetype/ttgload.c (TT_Load_Simple_Glyph): Clean space checking. + (TT_Hint_Glyph): Don't copy the outline structure. + (TT_Process_Simple_Glyph): Cosmetic update. + +2023-03-15 Alexei Podtelezhnikov + + * src/truetype/ttgload.c (TT_Load_Simple_Glyph): Clean up. + +2023-03-13 Werner Lemberg + + builds/vms/apinames_vms.bash: Fix `unzip` artifact + + The problem occured when unpacking a zip file created on OpenVMS on Linux. + While OpenVMS knows many different file formats, Unix only knows stream-LF + and binary. In principle `zip` on Linux should have translated the file to + stream-LF but failed to do so. That caused the file to incorrectly contain + only one line with control-characters. + +2023-03-11 Alexei Podtelezhnikov + + [truetype] Fix recent fallout in memory management. + + * src/truetype/ttgload.c (TT_Process_Composite_Glyph, + TT_Load_Simple_Glyph): Clean up old instructions regardless of + new ones, postpone setting `control_len` and `control_data` until... + (TT_Load_Glyph): ... the exit from this function. + +2023-03-10 Jouk Jansen + + Update VMS installation support. + +2023-03-10 Alexei Podtelezhnikov + + * src/truetype/ttgload.c (TT_Hint_Glyph): Mostly cosmetic update. + + The number of instructions is now taken from the executed context. + Technically, this means that `control_len` and `control_data` + values are no longer _used_ internally but only expose them. + +2023-03-08 Werner Lemberg + + apinames.c: Add comment. + +2023-03-07 Werner Lemberg + + [gzip] File `infback.c` is not needed. + + * src/gzip/infback.c: Remove. + * src/gzip/rules.mk (GZIP_DRV_SRCS): Updated. + +2023-03-07 Werner Lemberg + + [apinames] Fix VMS handling of overly long function names. + + Based on ideas from Jouk Jansen . + + * src/tools/vms_shorten_symbol.c: New file, taken from + + https://sourceforge.net/p/vms-ports/vmsshortsym/ci/default/tree/vms_shorten_symbol.c + + with some minor edits to allow compilation with C++ and being included in + another source code file. + + * src/tools/apinames.c: Include `vms_shorten_symbol.c`. + (PROGRAM_VERSION): Set to '0.5'. + (names_dump) [OUTPUT_VMS_OPT]: Call `vms_shorten_symbol` to get unique function + identifiers not longer than 31 characters. + +2023-03-07 Werner Lemberg + + * src/tools/apinames.c (panic): Accept variable number of arguments. + +2023-03-07 Alexei Podtelezhnikov + + * src/truetype/ttgload.c (TT_Process_Composite_Glyph): Fix leak too. + +2023-03-07 Alexei Podtelezhnikov + + * src/truetype/ttgload.c (TT_Load_Simple_Glyph): Triage memory leak. + + This leak has been introduced in the previous commit and immediately + detected: + https://chromium-review.googlesource.com/c/chromium/src/+/4313202 + +2023-03-06 Alexei Podtelezhnikov + + [truetype] Simplify memory management. + + Instead of using `Update_Max`, switch to regular FreeType memory + allocation macros, stop pre-allocating the glyph instruction arrays. + + * src/truetype/ttgload.c (TT_Load_Simple_Glyph, + TT_Process_Composite_Glyph): Switch to regular memory allocation. + * src/truetype/ttinterp.c (Update_Max): Removed. + (TT_Load_Context): Reallocate stack and free old instructions. + (Modify_CVT_Check, Ins_WS): Switch to regular memory allocation. + * src/truetype/ttinterp.h (Update_Max): Removed. + +2023-03-06 David PROVENT + + Added information about the zlib version update in the changelog + +2023-03-06 Alexei Podtelezhnikov + + Fix a couple of MSVC warnings. + + * src/base/ftcalc.c (FT_MulAddFix): Add cast. + * src/sfnt/ttcolr.c (tt_face_get_colorline_stops, read_paint): Ditto. + +2023-03-05 Alexei Podtelezhnikov + + * builds/windows/vc2010/freetype.vcxproj: Suppress C4267 on _WIN64. + + This usually comes from `strlen` returning 64-bit `size_t`, which + we often assign to 32-bit `FT_ULong` on Windows-64 (LLP64). + +2023-03-05 Alexei Podtelezhnikov + + * src/cff/cffparse.c (cff_parser_run): Thinko. + +2023-03-05 Alexei Podtelezhnikov + + [cff] Clean up CharString number encoding. + + * src/cff/cffparser.c (cff_parser_run): Work with signed numbers. + +2023-03-05 Alexei Podtelezhnikov + + * src/cff/cffparse.c (cff_parser_run): Fix variable type. + +2023-03-04 Alexei Podtelezhnikov + + [cff] Clean up memory management in the old engine. + + * src/cff/cffparse.c (finalize_t2_strings): Fix NULL-dereferencing + in the out-of-memory situation, use `FT_FREE`. + (cff_parser_run): Use FreeType memory allocation macros and avoid + uninitialized pointers. + +2023-03-04 Alexei Podtelezhnikov + + * src/cff/cffobjs.c (cff_size_init): Synonymous change. + +2023-03-04 Alexei Podtelezhnikov + + * src/sfnt/sfobjs.c (sfnt_load_face): Shorten de-referencing. + +2023-03-04 Alexei Podtelezhnikov + + [pfr] Shorten de-referencing. + + * src/pfr/pfrobjs.c (pfr_face_done, pfr_face_init): Use closer `memory`. + * src/pfr/pfrgload.c (pfr_glyph_load_compound): Remove `loader`. + +2023-03-03 Alexei Podtelezhnikov + + * src/cff/cffobjs.c (cff_size_get_globals_funcs): Shorten de-referencing. + +2023-03-03 Alexei Podtelezhnikov + + [cff,cid,type1] Shorten de-referencing. + + * src/cff/cffobjs.c (cff_clot_init): Use immediate library reference. + * src/cid/cidobjs.c (cid_slot_init): Ditto. + * src/type1/t1objs.c (T1_GlyphSlot_Init): Ditto. + +2023-03-02 Alexei Podtelezhnikov + + * configure: Use `sed` instead of `grep`. + + This is more portable and consistent with `autogen.sh`. + +2023-03-02 Ben Wagner + + Avoid strtol on non-null-terminated data. + + Technically, `strtol` can only be used with C strings terminated with + `\0`. CID data is not generally null-terminated and often does not + contain a `\0` if it is hex-encoded. AddressSanitizer with `ASAN_OPTIONS` + containing `strict_string_checks=1` verifies this by using an adversarial + `strtol` that always reads to the terminating `\0`. + + To avoid undefined behavior from `strtol` in `cid_parser_new`, use the + parser to parse the tokens instead of attempting to parse them ad-hoc. + This will internally use `PS_Conv_Strtol` to parse the integer, which + respects the parser's limits and directly implements the PostScript + parsing rules for integers. + + * src/cid/cidparse.c (cid_parser_new): Use the parser to parse the + tokens. + + Fixes: https://bugs.chromium.org/p/chromium/issues/detail?id=1420329 + +2023-03-02 Alexei Podtelezhnikov + + * src/cff/cffload.c (cff_subfont_load): Synonymous update. + +2023-03-01 ubawurinna + + * src/gzip/README.freetype: Update version. + +2023-03-01 ubawurinna + + [gzip] Fix static linking. + + Without this patch, static linking with MS Visual Studio causes linking + errors. + + * src/gzip/ftgzip.c: Set `ZEXPORT` to nothing and `ZEXTERN` to static for + all compilers. + +2023-03-01 Werner Lemberg + + * include/freetype/internal/compiler-macros.h (FALL_THROUGH): Update. + + This follows + + https://lists.gnu.org/archive/html/bug-gnulib/2023-02/msg00200.html + +2023-02-28 Alexei Podtelezhnikov + + [truetype] Treat 38 as 40 without Infinality. + + * include/freetype/ftdriver.h (TT_INTERPRETER_VERSION_38): Reinstate. + * src/truetype/ttdriver.c (tt_property_set): Fallback from 38 to 40. + +2023-02-26 Werner Lemberg + + * include/freetype/internal/compiler-macros.h (FALL_THROUGH): Update. + + This follows + + https://lists.gnu.org/archive/html/bug-gnulib/2023-02/msg00159.html + +2023-02-26 Werner Lemberg + + * src/*: Replace leading underscores with trailing ones in dummy variables. + + This is to avoid clang warnings. + +2023-02-26 Karl Berry + + * configure: Don't hardcode `grep -E`. + + TeXLive still supports Solaris 5.10, where the system's `grep` doesn't + accept the `-E` option. We thus introduce an `EGREP` variable that is set + to either `grep -E` or `-egrep`. + +2023-02-26 Alexei Podtelezhnikov + + * src/cff/cffload.c (cff_encoding_load): Optimize array zeroing. + + This is unnecessary for predefined standard and expert encodings. + Even for custom encodings the arrays might be already zeroed when + CFF_FontRec is created but we keep it just in case. + +2023-02-25 Alexei Podtelezhnikov + + * src/type1/t1load.c (T1_Get_MM_Var): Optimize array zeroing. + +2023-02-25 Tamir Duberstein + + * src/base/ftsystem.c (ft_ansi_stream_io): Avoid undefined behaviour. + Also short-circuit on `offset` to avoid checking `count` a second time when + `ft_ansi_stream_io` is used for reading. + + Per ISO/IEC 9899: + + If an argument to a function has an invalid value (such as a value outside + the domain of the function, or a pointer outside the address space of the + program, or a null pointer, or apointer to non-modifiable storage when the + corresponding parameter is not const-qualified) or a type (after + promotion) not expected by a function with variable number of arguments, + the behavior is undefined. If a function argument is described as being + an array, the pointer actually passed to the function shall have a value + such that all address computations and accesses to objects (that would be + valid if the pointer did point to the first element of such an array) are + in fact valid. + + Per IEEE Std 1003.1: + + size_t fread(void *restrict ptr, size_t size, size_t nitems, + FILE *restrict stream); + + The `fread` function shall read into the array pointed to by `ptr` up to + `nitems` elements whose size is specified by `size` in bytes, from the + stream pointed to by `stream`. + + Since the first argument to `fread` is described as being an array, its + behavior is undefined when that argument is a null pointer. + + Per the documentation on `ft_ansi_stream_io`: + + If `count' is zero (this is, the function is used for seeking), a non-zero + return value indicates an error. + + Thus the intent is clear, and the call to `fread` can be skipped, avoiding + undefined behaviour. + +2023-02-21 Alexei Podtelezhnikov + + [raster] Clean up contour indexing. + + * src/raster/ftraster.c (Decompose_Curve, Convert_Glyph): Use consistent + index types (Int) and compact iterations. + +2023-02-21 Alexei Podtelezhnikov + + [autofit] Clean up contour indexing. + + * src/autofit/aflatin.c (af_latin_metrics_init_blues): Refactor. + * src/autofit/afcjk.c (af_cjk_metrics_init_blues): Ditto. + +2023-02-21 Alexei Podtelezhnikov + + * src/base/ftoutln.c (FT_Outline_Check): Fix C4701 warning. + +2023-02-21 Alexei Podtelezhnikov + + * src/sdf/ftsdf.c (get_min_distance_cubic): Fix C4701, typos. + +2023-02-20 Alexei Podtelezhnikov + + * src/base/ftstroke.c (FT_Stroker_ParseOutline): Clean up contour indexing. + +2023-02-20 Alexei Podtelezhnikov + + [base] Clean up contour indexing. + + * src/base/ftoutln.c (FT_Outline_Reverse, FT_Outline_EmboldenXY, + FT_Outline_Get_Orientation): Set the first and last indexes together. + (FT_Outline_Decompose): Ditto and check them more stringently. + * src/smooth/ftgrays.c (FT_Outline_Decompose)[STANDALONE_]: Ditto. + +2023-02-20 Alexei Podtelezhnikov + + * src/base/ftoutln.c (FT_Outline_Check): Update error code, clean up. + +2023-02-17 Alexei Podtelezhnikov + + [truetype] Hide Infinality. + + Remove Infinality as an option before its complete extraction. + + * include/freetype/ftoption.h: Remove the Infinality option. + * devel/ftoption.h: Ditto. + * include/freetype/ftdriver.h (TT_INTERPRETER_VERSION_38): Is 40 now. + +2023-02-17 Alex Ringlein + + * src/base/ftoutln.c (FT_Outline_Reverse): Anchor first contour points. + + A cubic contour has to always start from an on-point. Therefore, we + should not swap the first with the last point, which might be off, and + obtain an invalid contour. This does not matter for conic contours. + If anything, it also saves one swap there. Fixes #1207. + +2023-02-16 Werner Lemberg + + Documentation improvement for `FT_Bitmap`. + + Fixes #1205. + +2023-02-10 Alexei Podtelezhnikov + + [type1/MM] Round design coordinates. + + The design coordinates for MM fonts were not rounded. For example, + `FT_Get_Var_Design_Coordinates` returned values with fractional part. + + * src/type1/t1load.c (mm_axis_unmap): Refactor with rounding. + + * include/freetype/ftmm.h (FT_Var_Axis, FT_Set_Var_Design_Coordinates, + FT_Get_Var_Design_Coordinates): Reword documentation. + +2023-02-09 Jan Alexander Steffens (heftig) + + * builds/meson/parse_modules_cfg.py: Handle `gxvalid` and `otvalid`. + + These need a name mapping similar to what was done for other modules, + or linking will fail. + +2023-02-09 Werner Lemberg + + * build/toplevel.mk (do_dist): Fix typo. + +2023-02-09 Werner Lemberg + + * Version 2.13 released. + ========================== + + Tag sources with `VER-2-13-0'. + + * docs/VERSION.TXT: Add entry for version 2.13. + * docs/CHANGES: Updated. + + * README, src/base/ftver.rc, builds/windows/vc2010/index.html, + builds/windows/visualc/index.html, builds/windows/visualce/index.html, + builds/wince/vc2005-ce/index.html, builds/wince/vc2008-ce/index.html, + docs/freetype-config.1: s/2.12.1/2.13/, s/2121/2130/. + + * include/freetype/freetype.h (FREETYPE_MINOR): Set to 13. + (FREETYPE_PATCH): Set to 0. + + * builds/unix/configure.raw (version_info): Set to 25:0:19. + * CMakeLists.txt (VERSION_MINOR): Set to 13. + (VERSION_PATCH): Set to 0. + +2023-02-09 Alexei Podtelezhnikov + + Comment on `FT_GlyphSlot_Slant'. + +2023-02-08 Werner Lemberg + + [autofit] Fix 'multi' compilation. + + * src/autofit/ft-hb.c: Decorate with `FT_LOCAL_DEF`. + Add ANSI boilerplate code for otherwise empty file. + * src/autofit/ft-hb.h: Include `compiler-macros.h` and `freetype.h`. + Use `FT_BEGIN_HEADER` and `FT_END_HEADER`. + Decorate with `FT_LOCAL`. + + * src/autofit/rules.mk (AUTOF_DRV_SRC): Add `ft-hb.c`. + +2023-02-08 Werner Lemberg + + Fix `FT_LOCAL` and `FT_LOCAL_DEF` tags. + +2023-02-08 Werner Lemberg + + Fix 'fall-through' warning messages. + + Modern compilers get more insistent on that... + + * include/freetype/internal/compiler-macros.h (FALL_THROUGH): Define. + * src/*: Use it instead of `/* fall through */` comments. + +2023-02-08 Werner Lemberg + + For debugging, avoid implicit conversion from integer to double. + + Otherwise we get zillions of clang 15 warnings. + + * src/autofit/afcjk.c, src/autofit/afhints.c, src/autofit/aflatin.c, + src/base/ftobjs.c, src/base/ftoutln.c, src/cff/cffparse.c, + src/raster/ftraster.c, src/sfnt/pngshim.c, src/truetype/ttgload.c, + src/truetype/ttgxvar.c, src/truetype/ttobjs.c, src/type1/t1gload.c: Use + `double` cast in debugging and tracing macros. + +2023-02-08 Werner Lemberg + + Avoid reserved identifiers that are globally defined. + + This is mandated by the C99 standard, and clang 15 produces zillions of + warnings otherwise. + + * devel/ftoption.h, include/freetype/config/ftoption.h, + include/freetype/internal/ftmemory.h, src/autofit/afhints.h, + src/autofit/afmodule.c, src/autofit/aftypes.h, src/base/ftadvanc.c, + src/base/ftdbgmem.c, src/base/ftstream.c, src/bdf/bdflib.c, + src/truetype/ttinterp.c: Replace identifiers of the form `_foo` with `foo_`. + +2023-02-08 Werner Lemberg + + Fix minor clang and clang++ warnings. + +2023-02-08 Alexei Podtelezhnikov + + [truetype, type1] Additional variation tags. + + Sync with + https://learn.microsoft.com/en-us/typography/opentype/spec/dvaraxisreg#registered-axis-tags + + * src/truetype/ttgxvar.h (TTAG_ital): New tag. + * src/truetype/ttgxvar.c (TT_Get_MM_Var): Use it. + * src/type1/t1load.c (T1_Get_MM_Var): Handle 'slnt' and 'ital'. + +2023-02-08 Alexei Podtelezhnikov + + * src/base/ftsynth.c (FT_GlyphSlot_Slant): Add vertical slant. + * include/freetype/ftsynth.h (FT_GlyphSlot_Slant): Update it. + +2023-02-08 anuj <95867901+anuj99@users.noreply.github.com> + + [sdf] Use 32-bit integers internally. + + * src/sdf/ftsdfcommon.h (FT_16D16, FT_26D6): Use 32-bit integers + instead of `FT_Fixed` for internal data types. `FT_Fixed` i.e. + `signed long` is 64-bit on some architectures. + +2023-02-07 Werner Lemberg + + docs/CHANGES: Updated. + +2023-02-04 Alexei Podtelezhnikov + + Comment on optional ascender and descender. + +2023-02-04 Alexei Podtelezhnikov + + * src/type1/t1afm.c (T1_Read_Metrics): Reaffirm ascender and descender. + +2023-02-04 Alexei Podtelezhnikov + + * src/type1/t1afm.c (T1_Read_Metrics): Validate ascender and descender. + + The ascender and descender are optional in the AFM specifications. + They could be omitted or even set to zero, e.g., in the current release + of URW++ base 35 fonts. + +2023-02-02 Werner Lemberg + + * src/cff/cffgload.c (cff_slot_load): Avoid memory leak. + + Fixes issue #1204. + +2023-02-01 Werner Lemberg + + * src/truetype/ttgxvar.c (tt_var_get_item_delta): Check `face->blend`. + + Reported as + + https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=55581 + +2023-02-01 Werner Lemberg + + * docs/CHANGES: Add news for 'freetype-demos'. + +2023-01-30 Werner Lemberg + + * subprojects/harfbuzz.wrap, subprojects/libpng.wrap: Updated. + +2023-01-28 Werner Lemberg + + Minor changes. + + Comment fixes, typos, removing of unnecessary parentheses. + +2023-01-28 Werner Lemberg + + Whitespace. + +2023-01-27 Behdad Esfahbod + + [ttgxvar] Fix crash in COLRv1. + + This is a stopgap until issue #1202 is properly fixed. + + * src/truetype/ttxgvar.c (tt_var_get_item_delta): Check `normalizedcoords`. + +2023-01-19 Werner Lemberg + + The 'COLR' v1 API will no longer be experimental in the next release. + +2023-01-18 Alexei Podtelezhnikov + + * docs/oldlogs/ChangeLog.210: Typos. + +2023-01-18 Ben Wagner + + [base] Fix typo. + + * src/base/ftobjs.c (open_face_PS_from_sfnt_stream): Request module 't1cid', + not 'cid'. + +2023-01-18 Ben Wagner + + [base] Return error if requested driver is not found. + + In `open_face_from_buffer` it is possible that a driver is requested but + FreeType was built without the requested module. Return an error in this + case to indicate that the request could not be satisfied, rather than trying + all existing driver modules. + + * src/base/ftobjs.c (open_face_from_buffer): Return `FT_Err_Missing_Module` + if a driver is specified but not found. + +2023-01-18 Dominik Röttsches + + [sfnt] Avoid nullptr dereference in reading malformed 'COLR' v1 table. + + Fixes https://bugs.chromium.org/p/chromium/issues/detail?id=1408044. + + * src/sfnt/ttcolr.c (tt_face_load_colr): When the 'COLR' v1 table header is + too small, don't deallocate delta set index map structures. + +2023-01-17 Werner Lemberg + + * src/tools/update-copyright: Allow execution from other repositories. + + We use this for `freetype-demos`. + +2023-01-17 Werner Lemberg + + Update all copyright notices. + +2023-01-17 Werner Lemberg + + * src/tools/no-copyright: Updated. + +2023-01-17 Ben Wagner + + [base] 'close' callback may not use `stream->memory`. + + The documentation for `FT_StreamRec::memory` states that it 'shouldn't be + touched by stream implementations'. This is true even for internal + implementations of the 'close' callback, since it is not guaranteed that + `memory` will even be set when the 'close' callback occurs. + + * src/base/ftobjs.c (new_memory_stream): stash current `memory` in + `stream->descriptor`. + (memory_stream_close): Use it. + +2023-01-17 Ben Wagner + + [base] Always close user-provided stream. + + The `FT_Open_Face` documentation states + + > If `FT_OPEN_STREAM` is set in `args->flags`, the stream in `args->stream` + > is automatically closed before this function returns any error (including + > `FT_Err_Invalid_Argument`). + + However, if the user provides a stream in `args.stream` with + `FT_OPEN_STREAM` set and a `close` function, but then for some reason passes + NULL for `aface` and a non-negative `face_index`, the error + `Invalid_Argument` is returned but the `close` callback will not be called + on the user-provided stream. This may cause resource leaks if the caller is + depending on the `close` callback to free resources. + + The difficulty is that a user may fill out a `FT_StreamRec` and pass its + address as `args.stream`, but the stream isn't really 'live' until + `FT_Stream_New` is called on it (and `memory` is set). In particular, it + cannot really be cleaned up properly in `ft_open_face_internal` until the + stream pointer has been copied into the `stream` local variable. + + * src/base/ftobj.c (ft_open_face_internal): Ensure that user-provided + `args.stream.close` is called even with early errors. + +2023-01-17 Ben Wagner + + [base] Fix leak of internal stream marked external. + + `open_face_from_buffer` allocates a new `FT_Stream` to pass to + `ft_open_face_internal`. Because this is an `FT_OPEN_STREAM`, + `ft_open_face_internal` will mark this as an 'external stream', which the + caller must free. However, `open_face_from_buffer` cannot directly free it + because the stream must last as long as the face. There is currently an + attempt at this by clearing the 'external stream' bit after + `open_face_from_buffer` returns successfully. However, this is too late as + the original stream may have already been closed and the stream on the face + may not be the same stream as originally passed. + + It is tempting to use `FT_OPEN_MEMORY` and let `ft_open_face_internal` + create the stream internally. However, with this method there is no means + to pass through a 'close' function to the created stream to free the + underlying data, which must be owned by the stream. + + A possibility is to check on success if the stream of the face is the same + as the original stream. If it is then unset the external flag. If not, + then free the original stream. Unfortunately, while no current + implementation does so, it is possible that the face still has the original + stream somewhere other than as the `FT_FaceRec::stream`. The stream needs + to remain available for the life of the face or until it is closed, + whichever comes earlier. + + The approach taken here is to let the stream own itself. When the stream is + closed it will free itself. + + * src/base/ftobjs.c (memory_stream_close): Free `stream`. + (open_face_from_buffer): Simplify error handling, since + `ft_open_face_internal` always closes `args.stream` on any error. + + Fixes: https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=54930 + +2023-01-16 Werner Lemberg + + sr/*.c: Various minor fixes. + + * src/autofit/ft-hb.c (_hb_ft_reference_table): Call `FT_UNUSED` after + variable declarations. + + * src/gxvalid/gxvjust.c (gxv_just_widthDeltaClusters_validate): Eliminate + unused variable. + + * src/gzip/ftgzip.c: Don't call GCC '-Wstrict-prototypes' pragma for C++ + compiler. + + * src/sfnt/ttcolr.c (ENSURE_READ_BYTES): Remove final semicolon to avoid + compiler warning. + + * src/sfnt/ttsvg.c (tt_face_load_svg_doc): Fix signedness warning. + +2023-01-16 Dominik Röttsches + + [sfnt] Remove temporary runtime flag for variable 'COLR' v1. + + Fixes #1187. + + * src/sfnt/ttcolr.c (top level, read_paint, tt_face_load_colr, + tt_face_free_colr, get_deltas_for_var_index_base, + tt_face_get_color_glyph_clipbox, tt_face_get_colorline_stops): Remove macro + definition `VARIABLE_COLRV1_ENABLED` and its usage. + + * src/truetype/ttdriver.c (tt_property_set): Remove parsing of + 'TEMPORARY-enable-variable-colrv1' property name. + + * src/truetype/ttobjs.h (TT_DriverRec): Remove `enable_variable_colrv1` + flag. + +2023-01-07 Werner Lemberg + + * src/autofit/ft-hb.c (_hb_ft_reference_table): Minor integration fixes. + +2023-01-07 Ben Wagner + + [truetype] Reset cvt and storage in context load. + + Currently the cvt and storage are saved and restored in `TT_RunIns`. + However, this is too granular as the cvt and storage area should be set to + the original cvt and storage area only when setting up the hinting context. + This allows for the cvt and storage area to be modified while parsing + multiple glyphs, as is the case with composite glyphs. + + * src/truetype/ttinterp.h (TT_ExecContextRec): Remove `origCvt` and + `origStorage`. + + * src/truetype/ttinterp.c (TT_RunIns): Don't save and restore the cvt and + storage area. + (Modify_CVT_Check, Ins_WS): Switch from "if in glyph and using original data + do copy on write" to "if in glyph and not using glyph specific data do copy + on write". + +2023-01-06 Matthias Clasen + + [autofit] Don't depend on 'hb-ft'. + + The circular dependency is still there, but at least we no longer depend on + the HarfBuzz API that is only present if HarfBuzz has been built with + FreeType support, making the bootstrapping a bit easier. + + * src/autofit/ft-hb.c, src/autofit/ft-hb.h: New files, providing + `_hb_ft_font_create`, which is more or less a verbatim copy of the + corresponding HarfBuzz code from file `hb-ft.cc`. + + * src/autofit/afglobal.c (af_face_globals_new): Use it. + * src/autofit/afshaper.h: Don't include `hb-ft.h` but `ft-hb.h`. + * src/autofit/autofit.c: Include `ft-hb.c`. + + * LICENSE.TXT: Updated. + +2023-01-06 Ben Wagner + + [truetype] Keep variation store consistent. + + `tt_var_load_item_variation_store` fills out a `GX_ItemVarStore`. While it + may return an error, the item store must be left in a consistent state so + that any use or destruction of the item store can properly use or free the + data in it. Before this change the counts from the font data were read + directly into the item store before the actual allocation of the arrays to + which they referred. There exist many opportunities between the time the + counts are read and the arrays are allocated to return early due to invalid + data. When this happened the item store claimed to have entires it actually + did not, leading to crashes later when it was used. + + Fixes: https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=54449 + + * src/truetype/ttgxvar.c (tt_var_load_item_variation_store): Read the counts + into local variables and store them in the item store only after the related + arrays are actually created on the item store. + +2023-01-05 Ben Wagner + + [base] Report used stream's external status. + + In `open_face` the initial stream is set on the face, along with the + information about if FreeType is the owner of the stream object itself. The + loaders may in the course of their work replace this stream with a new + stream (as is the case for 'woff' and 'woff2'), which may have a different + ownership than the initial stream object (likely the original stream object + is owned by the user and is external, while the new stream object is created + internally to FreeType and is internal). When the stream is replaced, the + face's flags are updated with the new ownership status. + + However, `open_face` cannot itself free this stream as its caller + `ft_open_face_internal` is responsible for this. In addition, in the case + of an error `open_face` cannot return an actual face with the new stream and + its ownership status to the caller. As a result, it must pass this + information back to the caller as a sort of "failed face" so that the caller + can clean up. + + `open_face` was already passing back the new stream but was not passing back + the stream ownership information. As a result the stream may not have been + free'd when needed. + + Fixes https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=54700 + + * src/base/ftobjs.c (open_face): Pass back the ownership information as + well. + (ft_open_face_internal): Updated. + +2023-01-05 Noah Cabral + + fix spelling err in LICENSE.txt + +2023-01-05 Dominik Röttsches + + [sfnt] Fix color stop bounds check calculation at table end. + + Fixes https://bugs.chromium.org/p/skia/issues/detail?id=14021 + + * src/sfnt/ttcolr.c (VAR_IDX_BASE_SIZE): New macro. + (tt_face_get_colorline_stops): Fix off-by-one bounds check calculation, take + `VarColorStop` into account, and hopefully make it easier to read. + +2023-01-05 Alexei Podtelezhnikov + + * src/base/ftobjs.c (FT_Request_Metrics): Avoid division by zero. + + The division-by-zero might happen in broken fonts (see #1194). + Instead of returning a huge number from FT_DivFix and failing + to scale later, we now bail immediately. + +2022-12-20 Alexei Podtelezhnikov + + [psaux] Delay the upem validity assertion. + + Fixes #1194. + + * src/psaux/psft.c (cf2_getUnitsPerEm): Remove the upem assert. + (cf2_checkTransform): Assert the upem validity after checking the scale. + +2022-12-14 David Vanderson + Werner Lemberg + + [gzip] Make static compilation not leak global symbols. + + * src/gzip/ftgzip.c (HAVE_HIDDEN): Do not define; it is no longer needed + because everything is static. + (HAVE_MEMCPY): Define. + (zcalloc, zcfree): Remove no longer needed definitions (because `Z_SOLO` is + active). + + * src/gzip/patches/freetype-zlib.diff: Regenerated. + + Fixes #1146. + +2022-12-14 Werner Lemberg + + * src/gzip/ftzconf.h: Updated to zlib 1.2.13. + + I forgot to copy that file. + +2022-12-14 Werner Lemberg + + * builds/unix/configure.raw: Don't check for `memcpy` and `memmove`. + + We expect a C99 compiler, and both functions are part of this standard. + +2022-12-13 Werner Lemberg + + [sdf, sfnt] Handle minor compiler warnings. + + * src/sdf/ftsdf.c (get_min_distance_conic): Initialize `nearest_point`. + + * src/sfnt/ttsvg.c (find_doc): Initialize `mid_doc`. + + Fixes #1195. + +2022-12-07 Werner Lemberg + + * subprojects/zlib.wrap: Micro-update from upstream. + +2022-12-06 Jiří Malák + + * include/freetype/internal/ftcalc.h (FT_MSB): Support Open Watcom 2.0. + + Closes !232. + +2022-11-23 Luca Bacci + + * src/base/ftdbgmem.c (ft_mem_source_compare): Add FT_COMPARE_DEF. + + Closes !230. + +2022-11-21 Alexei Podtelezhnikov + + * src/autofit/afloader.c (af_loader_load_glyph): Remove `size` check. + + This is done by `FT_Load_Glyph`. + +2022-11-18 Alexei Podtelezhnikov + + Comments added. + +2022-11-16 Johan Matsson + + * src/autofit/afloader.c (af_loader_load_glyph): Fix dereference. + + This must happen after the NULL check. + + Taken from + + https://github.com/freetype/freetype/pull/2 + +2022-11-15 Alexei Podtelezhnikov + + * src/pcf/pcfutil.c ({Two,Four}ByteSwap): Use builtins or shifts. + + We trust glibc which uses shifts or builtins to swap bytes. This + must be more efficient. + +2022-11-14 Werner Lemberg + + * src/truetype/ttgxvar.c (tt_hvadvance_adjust): Integer overflow. + + Reported as + + https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=50462 + +2022-11-14 Loïc Yhuel + + [meson] Use generated ftmodule.h + + ftmodule.h is generated at the root of the build directory, but FT_CONFIG_MODULES_H + (freetype/config/ftmodule.h) is used instead. + This makes the build fail when disabling modules in modules.cfg. + + * meson.build (harfbuzz_dep): Add '-DFT_CONFIG_MODULES_H='. + +2022-11-14 Loïc Yhuel + + [meson] Fix generated ftmodule.h + + The sdf module wasn't recognized, so the generated ftmodule.h had "None_renderer_class". + + * builds/meson/parse_modules_cfg.py: Handle sdf in RASTER_MODULES. + +2022-11-12 Dominik Röttsches + + Add `TT_CONFIG_OPTION_NO_BORING_EXPANSION` configuration macro. + + This gives users a possibility to deactivate new features not (yet) in the + OpenType standard. + + * include/freetype/config/ftoption.h, devel/ftoption.h + (TT_CONFIG_OPTION_NO_BORING_EXPANSION): New macro. + + * src/truetype/ttgxvar.c (ft_var_load_avar): Use it to disable 'avar' + version 2.0 support. + +2022-11-12 Behdad Esfahbod + + [truetype] Improve bounds checks for `ItemVariationStore`. + + * src/truetype/ttgxvar.c (tt_hvadvance_adjust): Move bounds check ... + (tt_var_get_item_delta): ... to this function, because it is safer. For + example, the 'avar' table 2.0 codepath was not performing a bounds check at + all. + +2022-11-12 Behdad Esfahbod + + [truetype] In `ItemVariationStore`, value 0xFFFF for `dataCount` is valid. + + It corresponds to outer indices of 0 to 0xFFFE. + + * src/truetype/ttgxvar.c (tt_var_load_item_variation_store): Remove invalid + code. + +2022-11-11 Alexei Podtelezhnikov + + [pcf] Improve CMap efficiency and readability. + + * src/pcf/pcfdrivr.c (pcf_cmap_char_{index,next}): Check and walk + the encoding array indexes. + +2022-11-10 Sam James + + Fix `-Wstrict-prototypes`. + + * builds/unix/configure.raw: Fix `-Wstrict-prototypes`. + Clang 16 warns on these and they will be dropped in C23. + + * builds/unix/freetype2.m4: Ditto. + +2022-11-09 Ben Wagner + + [truetype] Check avar_segment before access + + * src/truetype/ttgxvar.c (tt_done_blend): check `avar_segment` before + accessing to free its `correspondence`. + + Reported as: + + https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=53062 + +2022-11-09 Ben Wagner + + [truetype] Restore behavior of ft_var_load_hvvar + + * src/truetype/ttgcvar.c (ft_var_load_hvvar): restore previous behavior + + In a previous change [0] the behavior of `ft_var_load_hvvar` was changed + to not load the item variation store if it was at offset 0, but not + return an error when this happened. This broke any users, like + `tt_hvadvance_adjust`, that rely on successful completion of + `ft_var_load_hvvar` to imply that returned table's `itemStore` had been + initialized. This lead such users to dereference NULL. + + This change appears to have been unintentional and unrelated to the + actual avar2 changes. As a result, fix these NULL dereferences by + restoring the code to always attempt to initialize the `itemStore`. + + [0] ae4eb996 "[truetype] Add support for `avar` table 2.0 format." + + Reported as + + https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=53061 + +2022-11-08 Werner Lemberg + + docs/CHANGES: Updated. + +2022-11-08 suzuki toshiya + + [build] use AC_CHECK_PROG() macro for libpng-config detection + + * builds/unix/configure.raw: use AC_CHECK_PROG() instead of `which` to find `libpng-config`. + +2022-11-08 suzuki toshiya + + [build] fix for make multi + + Fix "make multi" by MR !223 + + * include/freetype/internal/services/svmm.h: include ftmm.h to define FT_Get_MM_Func. + * src/truetype/ttgxvar.h: include ftmmtypes.h to use GX_AVarTable properly. + * src/base/ftmac.c: include ftdebug.h to use FT_THROW() properly. + +2022-11-08 Alexei Podtelezhnikov + + * src/pfr/pfrsbit.c (pfr_lookup_bitmap_data): Accelerate the search. + + This is mostly for consistency because PFR fonts with bitmap strikes + do not seem to exist. + +2022-11-06 Alexei Podtelezhnikov + + [bdf, pfr, psnames] Accelarate charmap searches. + + The binary searches within charmaps can be accelerated because they + often contain dense continuous blocks of character codes. Within such + blocks, you can predict matches based on misses. This method has been + deployed in `bdf` since 0f122fef34; we only refactor it there. We now + use it in `pfr` and `psnames`, which speeds up the unicode charmap + access by about 50% in PFR and Type 1 fonts. + + * src/bdf/bdfdrivr.c (bdf_cmap_char_{index,next}): Refactor. + * src/pfr/pfrcmap.c (pfr_cmap_char_{index,next}): Predict `mid` based + on the mismatch distance. + * src/psnames/psmodule.c (ps_unicodes_char_{index,next}): Ditto. + +2022-11-04 Behdad Esfahbod + + [truetype] Add support for `avar` table 2.0 format. + + See + + https://github.com/harfbuzz/boring-expansion-spec/blob/main/avar2.md + + for the specification. + + Currently, this is implemented only in most recent OS versions on Apple + platforms and in the HarfBuzz library, but it is expected to be added to the + OpenType standard soon. + + * src/truetype/ttgxvar.h (GX_AVarTableRec): New structure. + (GX_BlendRec): Use it to replace `avar_segment` with `avar_table`. + + * src/truetype/ttgxvar.c (ft_var_load_avar): Load new table version. + (ft_var_to_normalized, tt_done_blend): Extend for new format. + (ft_var_load_hvvar, ft_var_to_design): Updated. + +2022-10-24 Werner Lemberg + + Replace '1/64th' (and similar entries) with '1/64' in docs and comments. + +2022-10-24 Ivan Panchenko + + * include/freetype/*: Fix documentation typos. + +2022-10-21 Alexei Podtelezhnikov + + * src/truetype/ttgload.c: Cosmetic changes. + +2022-10-21 Alexei Podtelezhnikov + + [cff, truetype] Simplify SVG metrics scaling. + + Use pre-calculated scaling factors. Also, the advance widths used + to be rounded, which was incorrect. + + * src/cff/cffgload.c (cff_slot_load): Use `x_scale` and `y_scale`. + * src/truetype/ttgload.c (TT_Load_Glyph): Ditto. + +2022-10-20 Werner Lemberg + + * subprojects/zlib.wrap: Update to zlib version 1.2.13. + +2022-10-18 Dominik Röttsches + + [sfnt] Additional bounds checks for `COLR` v1 table handling. + + * src/sfnt/ttcolr.c (read_paint): Add `colr` argument, necessary for... + ... another use of `ENSURE_READ_BYTES`. + Update callers. + (tt_face_get_paint_layers): Ensure that the 4-byte paint table + offset can be read. + + This is a follow-up to !124 and issue + https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=52404 + +2022-10-18 Werner Lemberg + + [gzip] Update sources to zlib 1.2.13. + +2022-10-18 Alexei Podtelezhnikov + + * src/sfnt/ttsbit.c (tt_face_load_strike_metrics): Simplify calculations. + +2022-10-18 Werner Lemberg + + Minor formatting. + +2022-10-18 Dominik Röttsches + + [sfnt] Guard individual `COLR` v1 paint field reads. + + * src/sfnt/ttcolr.c (ENSURE_READ_BYTES): New macro. + (read_paint): Use it – after the start pointer `p` has been checked for + whether it allows reading the format byte, each successive paint table field + read need to be bounds-checked before reading further values. + + Reported as + + https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=52404 + +2022-10-17 Xiang Xiao + + * builds/toplevel.mk: Prefix all paths with `$(TOP_DIR)/`. + + This is useful for builds that are not started from the root directory. + +2022-10-17 Liu Kunpeng(柳鲲鹏) + + * src/base/ftsynth.c (FT_GlyphSlot_Slant): New API with custom slant. + * include/freetype/ftsynth.h (FT_GlyphSlot_Slant): Declare it. + +2022-10-15 Alexei Podtelezhnikov + + Note the lack of floating-point data types. + +2022-10-10 Werner Lemberg + + [cff] Remove `FT_CONFIG_OPTION_NO_GLYPH_NAMES`. + + This ancient option stayed completely undocumented. Given that the 'cff' + driver requires the 'psnames' module, it makes no sense today to have this + macro. + + * src/cff/cffdrivr.c (cff_services), src/cff/cffobjs.c (cff_face_init): + Remove corresponding conditional code. + +2022-10-10 Werner Lemberg + + Synchronize `ftoption.h` flavours. + +2022-10-10 Werner Lemberg + + Minor comment changes. + +2022-10-05 Alexei Podtelezhnikov + + Improve FT_Get_Name_Index docs and place it next to FT_Get_Glyph_Name. + +2022-10-04 Alexei Podtelezhnikov + + [autofit] Reset the face charmap directly. + + There is no need to validate the original charmap in `FT_Set_Charmap`. + It can be reset directly. + + * src/autofit/afglobal.c (af_face_globals_compute_style_coverage): + Use direct assignment. + * src/autofit/af{latin,cjk,indic}.c (af_latin_metrics_init): Ditto. + +2022-10-04 Alexei Podtelezhnikov + + * src/type1/t1afm.c (T1_Read_PFM): Set charmaps directly. + + As with the previous commit, we can avoid the validation checks + of `FT_Set_Charmap` and set it directly when choosing from the + available list. + +2022-10-03 Alexei Podtelezhnikov + + * src/cache/ftccmap.c (FTC_CMapCache_Lookup): Avoid `FT_Set_Charmap`. + + Set charmap aggressively without all validations of `FT_Set_Charmap` + because we take it from the available array and only temporarily. + Even CMap Format 14 will gracefully return 0. + +2022-10-03 Alexei Podtelezhnikov + + * src/cache/ftcbasic.c (ftc_basic_family_get_count): Remove redundancy. + +2022-09-30 Werner Lemberg + + * src/psaux/pshints.c (cf2_hintmap_insertHint): Fix midpoint computation. + + Replace '(start + end) / 2' with 'start + (end - start) / 2' to avoid + overflow. + + Fixes #1180. + +2022-09-30 Werner Lemberg + + * src/psaux/pshints.c (cf2_hintmap_build): Improve debugging output. + +2022-09-29 mlugg + + [truetype] Fix undefined pointer arithmetic. + + * src/truetype/ttgxvar.c (tt_var_get_item_delta, ft_var_load_mvar): Use + `FT_OFFSET`. + +2022-09-29 Alexei Podtelezhnikov + + * src/sfnt/ttsbit.c (tt_face_load_strike_metrics): Use lighter FT_DivFix. + +2022-09-29 Ali Chraghi + + [base] FT_Attach_Stream: Make `parameters` argument constant. + +2022-09-29 Azamat Hackimov + + * src/tools/*.py: Migrate to Python 3. + + Fixes #1185, closes !205. Formatting changes according to PEP8. + +2022-09-27 Dominik Röttsches + + [sfnt] Guard access in 'COLR' table when requesting child table pointer. + + * src/sfnt/ttcolr.c (tt_face_get_colorline_stops, read_paint): Tighten + pointer bounds checks. + (get_child_table_pointer): Check whether incoming pointer `p` lies within + the 'COLR' table. + + Reported as + + https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=51816 + +2022-09-27 Ben Wagner + + [sfnt] Add SVG document bounds checking. + + Add a check that the document content is actually contained within the + `SVG ` table. Without this check a malformed font may claim arbitrary + memory as its document content. + + * src/sfnt/ttsvg.c (tt_face_load_svg): Take `numEntries` into account when + testing 'documentRecord' extents. + (find_doc): Rename `stream` to `document_records` for clarity. + (tt_face_load_svg_doc): Split `doc` from `doc_list` pointer for clarity. + Test that the document content is contained within the table. + Ensure minimum length of document before testing for gzip format. + + Reported as + + https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=51812 + +2022-09-23 Alexei Podtelezhnikov + + [base] Clean up the bitmap flow control. + + * src/base/ftbitmap.c (FT_Bitmap_Copy): Flip the copy if its pitch + is trully opposite, zero is not a positive value. + (FT_Bitmap_Convert): Set negative pitch as needed, accept negative + alignment values. + +2022-09-22 Alexei Podtelezhnikov + + [base] Discard and recreate bitmaps for copying and converting. + + Reusing target bitmaps for copying and converting is permitted. It is, + however, pointless to preserve their content before overwriting. Free- + malloc might be faster than realloc. + + * src/base/ftbitmap.c (FT_Bitmap_Copy, FT_Bitmap_Convert): Free + an old buffer and create a new one. + +2022-09-16 Dominik Röttsches + + Reject 'COLR' table if version is 1 but header too small. + + * src/sfnt/ttcolr.c (tt_face_load_colr): If the version is determined to + be 1, then the table size has to be at least the size of the v1 header. + Also, for peeking the number of base glyphs and entries in the layer list, + ensure that the table is sufficiently long. + + Fixes #1179. Original patch by Sergey Temnikov. + +2022-09-15 Werner Lemberg + + * src/otvalid/otvgsub.c (otv_SingleSubst_validate): Fix format 1 handling. + + Fixes #1181. + +2022-09-06 Dominik Röttsches + + [truetype] Reject 'fvar' loading when `num_instances` is too small. + + * src/truetype/ttgxvar.c (TT_Get_MM_Var): Reject retrieving master when + 'fvar' values locally do not match with sanitized values from initialization + at `sfnt_init_face` time. + + Reported as + + https://bugs.chromium.org/p/chromium/issues/detail?id=1360295 + +2022-09-05 Dominik Röttsches + + [sfnt] Handle variable `COLR` v1 fonts without delta set index map + + Fixes #1178. + + * src/sfnt/ttcolr.c (get_deltas_for_var_index_base): Set outer index to + 0 and inner index to the delta index when retrieving deltas if the + `COLR` table has no delta set index map. + +2022-09-05 Dominik Röttsches + + [sfnt] Pointer sanity checks before reading layer info in 'COLR' v0 + + * src/sfnt/ttcolr.c (tt_face_get_colr_layer): Check that the pointer to + read from is within the 'COLR' table. + + Reported as + + https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=50633 + +2022-09-05 Werner Lemberg + + [autofit] Minor fix. + + * src/autofit/afglobal.c (af_face_globals_compute_style_coverage): Avoid + compiler warning. + +2022-09-05 Dominik Röttsches + + [sfnt] Don't require 'gvar' table to support variation fonts. + + Fixes #1172. + + * src/sfnt/sfobjs.c (sfnt_load_face): Tag font as Multiple Masters font if + `fvar` is present; do not require other tables to be present. + + * src/truetype/ttgxvar.c (tt_set_mm_blend): Allow for a missing 'gvar' table + when setting variation coordinates. However, if a 'gvar' table is actually + present, do perform a sanity check and fail on malformedness. + (TT_Get_MM_Var): Don't assume 'fvar' needs 'gvar' or 'CFF2 tables in all + cases, which is an overly tight check. + +2022-08-27 Alexei Podtelezhnikov + + * src/base/ftver.rc: Explicitly use UTF-16. + + Fixes #1177 to avoid mistranslation and other problems. + +2022-08-26 Dominik Röttsches + + [sfnt] Avoid undefined shifts in `COLR` v1 color line retrieval + + * src/sfnt/ttcolr.c (tt_face_get_colorline_stops): Disambiguate shift + behavior by using multiplication using macros from ftcalc.h. + + Fixes: https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=50573 + +2022-08-21 Sean Farrell + + CMakeLists.txt (FT_ENABLE_ERROR_STRINGS): New configuration option. + + This option uncomments FreeType configuration macro + `FT_CONFIG_OPTION_ERROR_STRINGS` to make function `FT_Error_String` return + meaningful error strings. + + This option is off by default. + +2022-08-21 Chris Liddell + + [base, type1] Better handling of out-of-memory situations. + + This follows similar code in `cff_slot_done`. + + * src/base/ftobjs.c (ft_glyphslot_done), src/type1/t1objs.c + (T1_GlyphSlot_Done): Check `internal` pointer. + + The Type1 problems was reported as + + https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=50057. + +2022-08-06 Tim-Philipp Müller + + ci: bump windows image and use newer runner and vs2019 + + The old 1809 runner will be decommissioned at some point. + +2022-08-04 @udoudou <> + + * src/cache/ftcmanag.c (FTC_Manager_New): Initialize `cur_weight`. + + See !192. + +2022-08-02 Alexei Podtelezhnikov + + * src/sfnt/ttload.c: Trace formatting updates. + +2022-08-02 Alexei Podtelezhnikov + + * src/psaux/psobjs.c (ps_table_release): Remove redundant casting. + +2022-08-02 Alexei Podtelezhnikov + + * src/base/ftobjs.c (Mac_Read_sfnt_Resource): Reduce casting. + +2022-08-02 Alexei Podtelezhnikov + + [cache] Remove some casts, clean up tracing. + + * src/cache/ftcbasic.c (FTC_ImageCache_Lookup, FTC_SBitCache_Lookup): + Clean up tracing types. + * src/cache/ftccache.c (ftc_node_destroy): Ditto. + * src/cache/ftcmanag.c (FTC_Manager_Check): Ditto. + (FTC_Manager_Check, FTC_Node_Unref): Remove a cast. + * src/cache/ftccmap.c (FTC_CMapCache_Lookup): Ditto. + +2022-08-01 Alexei Podtelezhnikov + + [autofit] Updated to reduce casting (cont'd). + + * src/autofit/afmodule.h (AF_ModuleRec): Change `default_script` type. + * src/autofit/afglobal.c (af_face_globals_compute_style_coverage): + Remove casting. + * src/autofit/afmodule.c (af_property_{set,get}): Updated accordingly. + +2022-08-01 Alexei Podtelezhnikov + + [autofit] Updated to reduce casting. + + * src/autofit/afglobal.h (AF_FaceGlobalsRec): Change `glyph_count` type. + * src/autofit/afglobal.c (af_face_globals_compute_style_coverage, + af_face_globals_get_metrics, af_face_globals_is_digit, + af_face_globals_new): Changed local types and updated accordingly. + * src/autofit/aflatin.c (af_latin_metrics_init_blues): Ditto. + +2022-08-01 Alexei Podtelezhnikov + + [psaux] Remove unused structure field. + + * include/freetype/internal/psaux.h (PS_TableRec): Remove `num_elems`. + * src/psaux/psobjs.c (ps_table_new): Remoove its initialization. + +2022-07-30 Dominik Röttsches + + [sfnt] Implement VarClipBox. + + * src/sfnt/ttcolr.c (tt_face_get_color_glyph_clipbox): Depending on the + format, read `var_index_base`, then retrieve and apply scaled deltas. + +2022-07-30 Dominik Röttsches + + [sfnt] Fix typo in clip box computation. + + * src/sfnt/ttcolr.c (tt_face_get_color_glyph_clipbox): Use appropriate + scale factor for `yMin` and `yMax`. + +2022-07-30 Alexei Podtelezhnikov + + [autofit] Use unsigned accounting for hints. + + * src/autofit/afhints.h (AF_AxisHintsRec): Use unsigned types. + + * src/autofit/afhints.c (af_axis_hints_new_{segment,edge}, + af_glyph_hints_get_num_segments, af_glyph_hints_get_segment_offset): + Updated accordingly. + * src/autofit/aflatin.c (af_cjk_hints_compute_edges): Ditto. + * src/autofit/afcjk.c (af_cjk_hints_compute_edges): Ditto. + +2022-07-30 Alexei Podtelezhnikov + + * src/autofit/afhints.h: Remove dead code. + +2022-07-29 Werner Lemberg + + * src/base/ftglyph.c (FT_Get_Glyph): Set `*aglyph` to NULL in case of error. + +2022-07-29 Werner Lemberg + + Fix compilation if `TT_CONFIG_OPTION_GX_VAR_SUPPORT` is not set. + + * src/sfnt/ttcolr.c: Protect relevant code with + `TT_CONFIG_OPTION_GX_VAR_SUPPORT`. + +2022-07-29 Werner Lemberg + + Fix clang14 compiler warnings. + + * include/freetype/internal/ftstream.h (FT_GET_SHORT_LE, FT_GET_USHORT_LE): + Fix type. + + * src/sfnt/ttcolr.c (get_deltas_for_var_index_base): Always return boolean + value. + (tt_face_get_colorline_stops): Fix type of `var_index_base`. + +2022-07-26 Alexei Podtelezhnikov + + [pfr] Fortify the kerning code. + + Any array index must be strictly less then the array size. Therefore, + we must reject indexes that are equal to the array size. Alternatively, + we should move the bounds check before the index decrement but that + would be confusing. + + In addition, it is ok to decrement zero (.notdef) and get UINT_MAX, + which is then automatically rejected in the bounds check. + + * src/pfr/pfrobjs.c (pfr_face_get_kerning): Fix the bounds checking. + +2022-07-26 Werner Lemberg + + [pfr] Add some safety guards. + + * src/pfr/pfrload.c (pfr_phy_font_load): Check resolutions and number of + characters. + + Fixes #1174. + +2022-07-26 Werner Lemberg + + * src/pfr/*.c: Trivial improvements and formatting. + +2022-07-24 Werner Lemberg + + * configure: s/egrep/grep -E/ + + `egrep` is deprecated. + +2022-07-23 Ben Wagner + + [base] Build outlines in amortized constant time. + + When resizing the loader's points and contours, resize them to at least 1.5 + times their current size. The code currently only reserves as much space as + is currently required, leading to O(n^2) runtime when adding points one at a + time. + + This change does not attempt to ever shrink the loader's point and contour + storage since this was not attempted previously either. The 1.5 multiple + was chosen as a trade-off between potentially unused space and the runtime. + + * src/base/ftgloader.c (FT_GlyphLoader_CheckPoints): Implement it. + + Fixes #1173. + +2022-07-09 Dominik Röttsches + + [sfnt] Support variable 'COLR' v1 `PaintVarSkew*`. + + * src/sfnt/ttcolr.c (FT_PaintFormat_Internal): New enumeration values + `FT_COLR_PAINTFORMAT_INTERNAL_VAR_SKEW`, + `FT_COLR_PAINTFORMAT_INTERNAL_SKEW_CENTER`, and + `FT_COLR_PAINTFORMAT_INTERNAL_VAR_SKEW_CENTER`. + (read_paint): Handle new enumeration values. + +2022-07-09 Dominik Röttsches + + [sfnt] Support variable 'COLR' v1 `PaintVarRotate*`. + + * src/sfnt/ttcolr.c (FT_PaintFormat_Internal): New enumeration values + `FT_COLR_PAINTFORMAT_INTERNAL_VAR_ROTATE` and + `FT_COLR_PAINTFORMAT_INTERNAL_VAR_ROTATE_CENTER`. + (read_paint): Handle new enumeration values. + +2022-07-09 Dominik Röttsches + + [sfnt] Support 'COLR' v1 variable `PaintVarScale*`. + + * src/sfnt/ttcolr.c: (FT_PaintFormatInternal): New enumeration values + `FT_COLR_PAINTFORMAT_INTERNAL_VAR_SCALE`, + `FT_COLR_PAINTFORMAT_INTERNAL_VAR_SCALE_CENTER`, + `FT_COLR_PAINTFORMAT_INTERNAL_VAR_SCALE_UNIFORM`, and + `FT_COLR_PAINTFORMAT_INTERNAL_VAR_SCALE_UNIFORM_CENTER`. + (read_paint): Handle new enumeration values. + +2022-07-09 Dominik Röttsches + + [sfnt] Support for 'COLR' v1 variable translate. + + * src/sfnt/ttcolr.c (FT_PaintFormat_Internal): New enumeration value + `FT_COLR_PAINTFORMAT_INTERNAL_VAR_TRANSLATE`. + (read_paint): Handle new enumeration value. + +2022-07-09 Dominik Röttsches + + [sfnt] Support for 'COLR' v1 variable transforms. + + * src/sfnt/ttcolr.c (FT_PaintFormat_Internal): New enumeration value + `FT_COLR_PAINTFORMAT_INTERNAL_VAR_TRANSFORM`. + (read_paint): Handle new enumeration value. + +2022-07-09 Dominik Röttsches + + [sfnt] Deltas for 'COLR' v1 gradient coordinates. + + * src/sfnt/ttcolr.c (read_paint) [TT_CONFIG_OPTION_GX_VAR_SUPPORT]: Read and + apply deltas to radial, linear, and sweep gradient coordinates such as 'p0', + 'p1', 'p2', 'center', 'radii', and 'angles'. + +2022-07-08 Dominik Röttsches + + [sfnt] Support variable 'COLR' v1 color lines. + + * include/freetype/ftcolor.h (FT_ColorStopIterator): Add field + `read_variable` to indicate whether a variation index base should be read. + + * src/sfnt/ttcolr.c: (FT_PaintFormat_Internal): New enumerations + `FT_COLR_PAINTFORMAT_INTERNAL_VAR_LINEAR_GRADIENT` + `FT_COLR_PAINTFORMAT_INTERNAL_VAR_RADIAL_GRADIENT`, and + `FT_COLR_PAINTFORMAT_INTERNAL_VAR_SWEEP_GRADIENT`. + (read_color_line): New parameter `read_variable`; update callers. + (read_paint): Handle new enumerations. + +2022-07-07 Dominik Röttsches + + [sfnt] Apply variation deltas to `PaintVarSolid`. + + * src/sfnt/ttcolr.c (FT_PaintFormat_Internal_): New enumeration + `FT_COLR_PAINTFORMAT_INTERNAL_VAR_SOLID`. + + (get_deltas_for_var_index_base) [TT_CONFIG_OPTION_GX_VAR_SUPPORT]: New + function to retrieve an array of delta values, which will be used for most + of 'COLR' v1 variation formats (in follow-up commits). + + (read_paint): Add `face` parameter; update caller. + Handle `FT_COLR_PAINTFORMAT_INTERNAL_VAR_SOLID`. + +2022-07-07 Dominik Röttsches + + [sfnt] Check safety of cast to `TT_Driver` before accessing member. + + * src/sfnt/ttcolr.c (VARIABLE_COLRV1_ENABLED): Access + `enable_variable_colrv1` only if driver class matches. + +2022-07-06 Stephen Holdaway + + doc: Clarify description of `FT_Stream_IoFunc`. + + The existing documentation comments on `FT_Stream_IoFunc` hinted at the dual + seek/read behavior required for custom stream implementations to work, but + it didn't explicitly explain it. Without looking at the internals of + FreeType, it was easy for someone to assume their implementation should + handle both seek and read operations all the time. If this is done, you get + a variety of errors, but mostly just `Unknown_File_Format` (error code + 0x02). + +2022-07-04 Dominik Röttsches + + [sfnt] Load variation store for 'COLR' v1. + + * src/sfnt/ttcolr.c: Include `ttobjs.h` temporarily. + (VARIABLE_COLRV1_ENABLED): New temporary macro to detect whether variable + COLRv1 is enabled. + (Colr): New fields `var_store` and `delta_set_idx_map`. + (tt_face_load_colr, tt_face_free_colr) [VARIABLE_COLRV1_ENABLED]: Load and + free variation store data using the functions from the Multiple Masters + service. + +2022-07-03 Chris Liddell + + [base] Improve error handling in `FT_GlyphLoader_CheckPoints`. + + If `FT_GlyphLoader_CreateExtra` returns an error (and a couple of other + places), `FT_GlyphLoader_CheckPoints` would propagate the error immediately, + rather than cleaning up the partially set up `FT_GlyphLoader`. As a + consequence, a subsequent attempt to create a glyph could result in a crash. + + * src/base/ftgloadr.c (FT_GlyphLoader_CheckPoints): Ensure all the error + conditions exits are consistent, eventually calling `FT_GlyphLoader_Reset`. + +2022-07-03 Thomas Sondergaard + + CMakeLists.txt: Provide both 'freetype' and 'Freetype::Freetype' targets. + + FreeType can be located by consuming projects that use + `find_package(Freetype)` either via the old `MODULE` path (which uses + `FindFreetype.cmake` supplied by CMake), or via the new `CONFIG` path (which + uses `freetype-config.cmake` as supplied by this project). Up to this point + the CMake module has supplied the target `Freetype::Freetype` and the config + file provided by this project the target `freetype`. Now we supply both + `freetype` and `Freetype::Freetype` so that consuming projects can always + use the target `Freetype::Freetype` regardless of what path was taken by + `find_package(Freetype)`. + + Fixes #1165. + +2022-07-02 Werner Lemberg + + include/freetype/ftmm.h: Improve documentation. + +2022-07-01 Dominik Röttsches + + [base] Round values in `FT_MulAdd_Fix`. + + This avoids regressing Blink layout tests and makes `FT_MulAdd_Fix` delta + retrieval implementation consistent with the previous implementation, which + used `FT_fixedToInt` and included rounding. + + * src/base/ftcalc.c (FT_MulAdd_Fix): Implement it. + Also fix remaining `temp` initialization compilation issue. + + Fixes #1169. + +2022-07-01 Werner Lemberg + + Minor formatting. + +2022-06-30 Dominik Röttsches + + Fix initialisation of temp variable in new FT_MulAddFix + + src/truetype/ttgxvar.c (FT_MulAddFix): Initialise `temp`. + +2022-06-29 Dominik Röttsches + + [truetype] Perform variation store delta computation with 64-bit precision. + + * include/freetype/internal/ftmmtypes.h (FT_ItemVarDelta): Make type + explicitly 32-bit. + * include/freetype/internal/services/svmm.h + (FT_Var_Get_Item_Delta_Func): Change return type to `FT_ItemVarDelta` + * truetype/ttgxvar.h (tt_var_get_item_delta): Change return type to + `FT_ItemVarDelta`. + * truetype/ttgxvar.c (tt_var_get_item_delta): Store scalars and deltas + to intermediate array, perform computation using new method + `FT_MulAddFix`. + +2022-06-29 Dominik Röttsches + + New function `FT_MulAddFix` to compute the sum of fixed-point products. + + This function, based on the code of `FT_MulFix`, uses 64-bit precision + internally for intermediate computations. + + * include/freetype/internal/ftcalc.h, base/ftcalc.c (FT_MulAddFix): + Implement it. + +2022-06-22 Werner Lemberg + + CMakeLists.txt: Move inclusion of `FindPkgConfig` down. + + It must come after `CMAKE_TOOLCHAIN_FILE`. + + Fixes #1167. + +2022-06-22 Dominik Röttsches + + [sfnt] Upgrade stop_offset to FT_Fixed from FT_F2Dot14 + +2022-06-21 Alexei Podtelezhnikov + + * docs/CHANGES: Announce impending Infinality removal. + +2022-06-21 Alexei Podtelezhnikov + + * ttgload.c (TT_Process_Composite_Glyph): Fix a signedness warning. + +2022-06-21 Werner Lemberg + + s/fixed point/fixed-point/ + +2022-06-21 Werner Lemberg + + .gitlab-ci.yml: Correctly upgrade `meson`. + +2022-06-21 Dominik Röttsches + + Proposal: Feature control for variable COLRv1 + + * include/freetype/ftdriver.h (variable-color-v1 property): Add documentation + for variable-colr-v1 property. + * src/truetype/ttdriver.c (tt_property_set): Ingest variable-control property + when called, set to enable_variable_colrv1 driver flag. + * src/truetype/ttobjs.h (TT_DriverRec): Add enable_variable_colrv1 flag. + +2022-06-21 Xavier Claessens + + [meson] Disable FreeType in HarfBuzz fallback. + + This avoids cyclic subproject configuration when the 'harfbuzz' feature is + enabled, or `--wrap-mode=forcefallback` is used, but HarfBuzz is built as a + subproject. HarfBuzz does the same and disables HarfBuzz support when + configuring FreeType as a subproject. + + * meson.build (harfbuzz_dep): Implement it. + + * subprojects/harfbuzz.wrap: New file. + + * .gitlab-ci.yml [windows meson]: Use latest version of the meson 0.59 + series, which has a necessary bug fix to make CI work. + +2022-06-19 Alexei Podtelezhnikov + + [truetype] Clean up phantom point accounting. + + This formalizes that the phantom points appended in the outline + do not increase its point count, nor are they tagged or included + in any additional contours. Only their coordinates are stored. + They are counted in the glyph zone, however. + + * src/truetype/ttgxvar.c (TT_Vary_Apply_Glyph_Deltas): Infer `n_points` + from the outline size plus four phantom points. + * src/truetype/ttgxvar.h (TT_Vary_Apply_Glyph_Deltas): Remove this + argument. + * src/truetype/ttgload.c (tt_prepare_zone): Add phantom four. + (TT_Process_Simple_Glyph, load_truetype_glyph): Update all callers. + +2022-06-19 Alexei Podtelezhnikov + + [truetype/GX] Clean up phantom point adjustment. + + This moves phantom point and advance variation adjustment next to + calculations. The logic stays the same, HVAR and VVAR take priority. + + * src/truetype/ttgload.c (load_truetype_glyph): Move it from here... + * src/truetype/ttgxvar.c (TT_Vary_Apply_Glyph_Deltas): ... to here + and check for HVAR and VVAR presence outside the main loop. + +2022-06-18 Ben Wagner + + [stream] Fix reading s32 when long is s64 + + `FT_READ_LONG`, `FT_GET_LONG`, and related macros did not return + negative values when `long` is more than 32 bits. `FT_Stream_ReadULong` + would read four bytes into the LSB of an `FT_ULong` and return that. + Since this can never set the MSb of the `FT_ULong` when `FT_ULong` is + more than 32 bits the cast to `FT_Long` never resulted in a negative + value. + + Fix this by modifying `FT_Stream_Read*` to return a type of the same + size as the bytes it is reading and changing the `FT_READ_*` and + `FT_GET_*` macros to cast to the same type returned by `FT_Stream_Read*` + but with the correctly signed type (instead of casting to what is + assumed to be the type of `var` which will happen automatically anyway). + + There exist a few cases like with the `OFF3` variants where there isn't + generally a type with the correct size. `FT_PEEK_OFF3` works around this + loading the bytes into the three most significant bits and then doing a + signed shift down. `FT_NEXT_OFF3` also already worked correctly by + casting this signed value to another signed type. `FT_Stream_GetUOffset` + works correctly but one must be careful not to attempt to cast the + returned value to a signed type. Fortunately there is only + `FT_GET_UOFF3` and no `FT_GET_OFF3`. + + All of these cases are handled correctly when reading values through + `FT_Stream_ReadFields` since it generically computes the signed value + through an `FT_Int32`. This change is essentially doing the same for + these macros. + + * include/freetype/internal/ftstream.h (FT_NEXT_*, FT_GET_*, FT_READ*): + Update macros and return types to use fixed size types for fixed size + values. + + * src/base/ftstream.c (FT_StreamGet*, FT_StreamRead*): Dito. + + Issue: #1161 + +2022-06-17 Alexei Podtelezhnikov + + [truetype/GX] Fix an old typo. + + * src/truetype/ttgxvar.c (TT_Vary_Apply_Glyph_Deltas): Vertical + advance is measured along y-coordinate. + +2022-06-16 Alexei Podtelezhnikov + + [truetype/GX] Clean up advance adjustment (Brrr). + + * src/truetype/ttgload.c (load_truetype_glyph): Remove remaining code. + +2022-06-16 Ben Wagner + + [type1] Directly search for eexec in private dict + + This code originally just searched for `eexec`. This was later modified + to check that the `eexec` found is valid (not in a string or comment). + This was done by searching for `eexec` as before and then, for each + `eexec` found, searching from the beginning using the correct parsing to + see if the `eexec` was still found. If the private dictionary is large + and contains many copies of `eexec` which are not valid, the initial + part of the private dictionary is scanned once for each, potentially + leading to n^2 parsing time. + + Instead of finding an initial `eexec` and then re-parsing to discover if + it is valid, drop the initial search for `eexec` and just parse to find + a valid `eexec`. This is strictly faster since the validation must + happen anyway and avoids restarting from the beginning each time an + `eexec` is found in the data. + + * src/type1/t1parse.c (T1_Get_Private_Dict): avoid n^2 parsing + + Bug: https://bugs.chromium.org/p/chromium/issues/detail?id=1328883 + +2022-06-16 Alexei Podtelezhnikov + + [truetype/GX] Clean up advance adjustment. + + * src/truetype/ttgload.c (TT_Process_Simple_Glyph, load_truetype_glyph): + Move the advance adjustment from here... + * src/truetype/ttgxvar.c (TT_Vary_Apply_Glyph_Deltas): ... to here and + simplify arguments. + * src/truetype/ttgxvar.h (TT_Vary_Apply_Glyph_Deltas): Update prototype + with fewer arguments. + +2022-06-14 Ben Wagner + + [gzip] Handle inflate returning Z_NEED_DICT + + When `inflate` returns `Z_NEED_DICT` this is currently not reported as + an error and callers may assume that the decompression succeeded when it + did not. In particular, a compressed table in a woff file may not + actually be decompressed and written as expected, leaving the backing + memory for the expanded table uninitialized. + + * src/gzlip/ftgzip.c (FT_Gzip_Uncompress): treat `Z_NEED_DICT` as + indicating invalid data since there is no means to provide a dictionary. + + Bug: https://bugs.chromium.org/p/chromium/issues/detail?id=1335712 + +2022-06-13 Ben Wagner + + [woff] Don't allocate table entries until needed + + * src/sfnt/sfwoff.c (woff_open_font): delay allocating space for the + table entries until they are actually written out with the data. + +2022-06-12 Alexei Podtelezhnikov + + * src/sfnt/sfwoff2.c (woff2_open_font): Partial revert. + + Fixes https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=47981. + +2022-06-12 Alexei Podtelezhnikov + + * src/lzw/ftzopen.c (ft_lzwstate_stack_grow): Cosmetic macro change. + +2022-06-11 Alexei Podtelezhnikov + + [woff, woff2] Avoid buffer zeroing. + + * src/sfnt/sfwoff.c (woff_open_font): Use Q-macros. + * src/sfnt/sfwoff2.c: Ditto. + (reconstruct_font): Allocate table_entry on stack. + +2022-06-10 Alexei Podtelezhnikov + + [smooth] Fix GCC LTO crashes on Windows. + + Fixes #1164 by using a volatile variable around `setjmp`. It is hard to + say how this fixes crashes related to certain link-time optimizations. + This does not decrease the rendering performance. + + * src/smooth/ftgrays.c (gray_convert_glyph_inner): Use volatile `error`. + +2022-06-09 bruvzg <@bruvzg> + + * src/smooth/ftgrays.c [FT_STATIC_RASTER]: Fix compilation. + +2022-06-06 Ben Wagner + + [svg] Set linear advances when loading SVG glyphs + + * include/freetype/freetype.h (FT_GlyphSlotRec_): update doc + * src/cff/cffgload.c (cff_slot_load): do it + * src/truetype/ttgload.c (TT_Load_Glyph): do it + + Fixes: #1156 + +2022-06-01 Ben Wagner + + [svg] Clear correct flags for doc ownership + + This issue was discovered with an SVG based font with some documents + compressed and other uncompressed. After loading the first compressed + document the ownership flag on the glyph slot was set to true but never + set to false. As a result after loading a compressed document a glyph + from an uncompressed document would load fine, but when this glyph slot + was cleared it would try to free its document resulting in a wild free. + + * src/base/ftobjs.c (ft_glyphslot_clear): clear correct flags + + Fixes: #1162 + +2022-06-01 Alexei Podtelezhnikov + + [docs] Correct favicon. + +2022-06-01 Alexei Podtelezhnikov + + [docs] Use hinted favicon. + +2022-05-27 Alexei Podtelezhnikov + + [docs] Update favicon. + +2022-05-25 Behdad Esfahbod (بهداد اسفهبد) + + * src/sfnt/ttmtx.c (tt_face_get_metrics): Apply variations unconditionally. + + This causes a speed-up of approx. 20% for getting advance widths. + +2022-05-23 Dominik Röttsches + + [truetype] Support reading 32bit/16bit VarStore deltas + + * include/freetype/internal/ftmmtypes.h (FT_ItemVarDelta): Define type + to be used for delta arrays, upgrade to FT_long. + * src/truetype/ttgxvar.c: Adhere to long_words bit and read either + Short/Byte pairs or Long/Short pairs, as defined by spec. For better + readability, define macro for repetitive read code. + +2022-05-20 Dominik Röttsches + + [truetype] Handle 0xFFFF special value inside delta retrieval function + + * truetype/ttgxvar.c (tt_hvadvance_adjust, tt_apply_mvar, + tt_var_get_item_delta): Remove special 0xFFFF handling in favor of less + redundant handling inside the tt_var_get_item_delta function, as it is + equivalent to returning a 0 delta. Avoids code-duplication checking for + special value 0xFFFF. + +2022-05-19 Dominik Röttsches + + [truetype, snft] Add service methods for `DeltaSetIdxMap` and `VarStore`. + + This will be needed for 'COLR' v1 variation support. + + * src/truetype/ttgxvar.h (GX_ItemVarData, GX_AxisCoords, GX_VarRegion, + GX_VarItemStore, GX_DeltaSetIdxMap): Move structures to... + * include/freetype/internal/ftmmtypes.h: ... this new file. + + * include/freetype/internal/service/svmm.h (MultiMasters): Include + `ftmmtypes.h`. + (FT_Var_Load_Delta_Set_Idx_Map_Func, FT_Var_Load_Item_Var_Store_Func, + FT_Var_Get_Item_Delta_Func, FT_Var_Done_Item_Var_Store_Func, + FT_Var_Done_Delta_Set_Idx_Map_Func): New function typedefs. + (MultiMasters): Add them. + (FT_DEFINE_SERVICE_MULTIMASTERSREC): Updated. + + * src/cff/cffdrivr.c (cff_load_item_variation_store, + cff_load_delta_set_index_mapping, cff_get_item_delta, + cff_done_item_variation_store, cff_done_delta_set_index_map): New wrapper + methods calling into mm service. + (cff_service_multi_masters): Updated. + + * src/truetype/ttgxvar.c (ft_var_load_item_variation_store, + ft_var_load_delta_set_index_mapping, ft_var_get_item_delta, + ft_var_done_item_variation_store, ft_var_done_delta_set_index_map): Renamed + to ... + (tt_var_load_item_variation_store, tt_var_load_delta_set_index_mapping, + tt_var_get_item_delta, tt_var_done_item_variation_store, + tt_var_done_delta_set_index_map): ... this for consistency. + Mark them as non-static. + * src/truetype/ttgxvar.h: Add corresponding prototypes. + + * src/truetype/ttdriver.c (tt_service_gx_multi_masters): Updated. + + * src/type1/t1driver.c (t1_service_multi_masters): Updated. + +2022-05-19 Dominik Röttsches + + [truetype] Move deallocation of `DeltaSetIdxMap` into own function. + + This is a preparation for handling `DeltaSetIdxMap` and `VarStore` as a + FreeType service. + + * src/truetype/ttgxvar.c (ft_var_done_delta_set_index_map): New function. + (tt_done_blend): Use it. + +2022-05-18 Werner Lemberg + + * builds/toplevel.mk (do-dist): Don't remove meson wrap files. + + Fixes #1157. + +2022-05-18 Werner Lemberg + + * subprojects/zlib.wrap: Update to zlib version 1.2.12. + +2022-05-18 Werner Lemberg + + REAMDE: Mention that gitlab's 'download' button doesn't work. + + This is because the `git archive` command doesn't preserve submodules. + + Note that currently there is no support for disabling the 'download' button + in gitlab (https://gitlab.com/gitlab-org/gitlab/-/issues/17032). + + Fixes issue #1158. + +2022-05-11 Werner Lemberg + + [truetype] Handle inner/outer index values 0xFFFF/0xFFFF. + + This was introduced in OpenType 1.8.4. + + * src/truetype/ttgxvar.c (ft_var_load_delta_set_index_mapping, + tt_hvadvance_adjust, ft_var_load_mvar, tt_apply_mvar): Handle special + inner/outer index values. + (ft_var_load_item_variation_store): Add test. + + Fixes #1154. + +2022-05-01 Werner Lemberg + + * Version 2.12.1 released. + ========================== + + Tag sources with `VER-2-12-1'. + + * docs/VERSION.TXT: Add entry for version 2.12.1. + * docs/CHANGES, docs/release: Updated. + + * README, src/base/ftver.rc, builds/windows/vc2010/index.html, + builds/windows/visualc/index.html, builds/windows/visualce/index.html, + builds/wince/vc2005-ce/index.html, builds/wince/vc2008-ce/index.html, + docs/freetype-config.1: s/2.12.0/2.12.1/, s/2120/2121/. + + * include/freetype/freetype.h (FREETYPE_PATCH): Set to 1. + + * builds/unix/configure.raw (version_info): Set to 24:3:18. + * CMakeLists.txt (VERSION_PATCH): Set to 1. + +2022-04-30 Anuj Verma + + [sdf] Do not throw errors for invisible glyphs. + + * src/sdf/ftsdfrend.c (ft_sdf_render, ft_bsdf_render): Return `FT_Err_Ok` if + width or height is zero, since some glyphs do not generate visible bitmaps. + + Fixes #1150. + +2022-04-30 Werner Lemberg + + * src/sfnt/sfobjs.c (sfnt_load_face): Set `FT_FACE_FLAG_COLOR` for SVG fonts. + + Fixes #1151. + +2022-04-27 Brendan Shanks + + autogen.sh: Fix building when freetype is itself a git submodule. + + There are situations where .git is not a directory, like when + freetype is a submodule in another repository. + +2022-04-26 Alexei Podtelezhnikov + + [builds/windows] Simplify non-desktop UWP check. + + Fixes mingw compilation described in !159. + + * builds/windows/ftsystem.c: Do not use WINAPI_FAMILY_PARTITION macro. + +2022-04-25 Alexei Podtelezhnikov + + [truetype] Reset IUP flags in `TT_RunIns`. + + Fixes #1148 by moving the flag initialization back, partly reverting + 7809007a and fd03dcc1. Initializing these flags elsewhere skips 'cvt'. + + * src/truetype/ttinterp.c (TT_RunIns): Initialize the IUP flag here... + (TT_Run_Context): ... instead of here. + +2022-04-24 Xavier Claessens + + [meson] Remove `default_library=both` from `default_options`. + + It is inconsistent with what all other Meson projects do. + + It also prevents static linking to FreeType when it is a subproject because + `default_options` in a subproject takes precedence on values set on the main + project. For example, building 'GStreamer' with `-Ddefault_library=static` + would still dynamically link on FreeType unless the user also sets + `-Dfreetype2:default_library=static`. + + * meson.build: Updated. + + * .gitlab-ci.yml: Retain `both` option for testing. + +2022-04-19 Werner Lemberg + + * src/truetype/ttgload.c (TT_Process_Simple_Glyph): Integer overflow. + + Reported as + + https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=46792 + +2022-04-16 Georg Brandl + + * src/cff/cffgload.c (cff_slot_load) [FT_CONFIG_OPTION_SVG]: Fix segfault. + + This can happen if the function is called with `size` being `NULL`. + + Fixes #1147. + +2022-04-14 Steve Lhomme + + .gitlab-ci.yml: Add a Universal Windows build target + + It's compiled for Windows 10 and up, ensuring UNICODE is set (default for UWP) + and selecting the proper WINAPI_FAMILY (WINAPI_FAMILY_APP). + + Do not try to run the UWP exe in the Docker as it doesn't work. + +2022-04-04 Ben Wagner + + [sfnt] Correct FT_ColorStopIterator documentation. + + * include/freetype/ftcolor.h (FT_ColorStopIterator): the user should not + set `p` to NULL before calling `FT_Get_Colorline_Stops`. `p` and + `num_color_stops` are set by `FT_Get_Paint`. `p` and + `current_color_stop` are updated by `FT_Get_Colorline_Stops`. + +2022-04-01 Werner Lemberg + + * builds/unix/configure.raw: Add option `--with-librsvg`. + + Since 'librsvg' is written in Rust, this option allows distributions to + avoid a dependency on the entire Rust toolchain to provide the FreeType demo + programs. + + Suggested by Lars Wendler in !156. + +2022-04-01 Werner Lemberg + + * src/sfnt/sfwoff.c (reconstruct_glyf): Fix gcc 10 warning. + +2022-04-01 Werner Lemberg + + [gzip] Update sources to zlib 1.2.12. + +2022-04-01 Eric Jing <@CPUcontrol> + + CMakeLists.txt: Fix `Info.plist` path. + + When building a framework using CMake with `add_subdirectory`, CMake must be + able to find `freetype-Info.plist` when configuring the framework + properties. + + Fixes #1145. + +2022-04-01 Werner Lemberg + + Whitespace. + +2022-04-01 Ben Wagner + + [truetype] Use SUB_LONG for component offset. + + * src/truetype/ttgload.c (TT_Process_Composite_Component): do it. + + Bug: https://crbug.com/1309429 + +2022-03-31 Werner Lemberg + + CMakeList.txt: Update code to handle recent changes for `freetype.pc`. + + Fixes #1144. + +2022-03-31 Werner Lemberg + + CMakeLists.txt: s/PKG_CONFIG/PKGCONFIG/, s/REQUIRED_/REQUIRES_/. + +2022-03-31 Werner Lemberg + + * Version 2.12.0 released. + ========================== + + Tag sources with `VER-2-12-0'. + + * docs/VERSION.TXT: Add entry for version 2.12.0. + * docs/CHANGES, docs/release: Updated. + + * README, src/base/ftver.rc, builds/windows/vc2010/index.html, + builds/windows/visualc/index.html, builds/windows/visualce/index.html, + builds/wince/vc2005-ce/index.html, builds/wince/vc2008-ce/index.html, + docs/freetype-config.1: s/2.11.1/2.12.0/, s/2111/2120/. + + * include/freetype/freetype.h (FREETYPE_MINOR): Set to 12. + (FREETYPE_PATCH): Set to 0. + + * builds/unix/configure.raw (version_info): Set to 24:2:18. + * CMakeLists.txt (VERSION_MINOR): Set to 12. + (VERSION_PATCH): Set to 0. + + * builds/toplevel.mk (do-dist): Generate `ChangeLog` entries for all commits + since version 2.11.0 (when we stopped creating this file manually). + +2022-03-31 Werner Lemberg + + Fix clang++ warnings. + + * src/base/ftglyph.c (ft_svg_glyph_prepare), src/base/ftobj.c + (ft_glyphslot_init), src/cache/ftccmap.c (ftc_cmap_node_new), + src/cache/ftcimage.c (FTC_INode_New), src/lzw/ftlzw.c (FT_Stream_OpenLZW), + src/psaux/psobjs.c (ps_parser_load_field), src/pshinter/pshglob.c + (psh_globals_new), src/sfnt/ttsvg.c (tt_face_load_svg_doc): Initialize + variables used for allocation. + + * src/sdf/ftsdf.c (split_sdf_conic, split_sdf_cubic): Change type of + `max_splits` to FT_UInt. + (sdf_generate_bounding_box): Add cast. + +2022-03-30 Werner Lemberg + + Whitespace. + +2022-03-30 Werner Lemberg + + [builds] Fix creation of `freetype2.pc` for static-only builds. + + We have to help `pkg-config` since it can't recognize that there is no + shared library installed. + + Note that meson already does exactly the same. + + * builds/unix/configure.raw (REQUIRES_PRIVATE, LIBS_PRIVATE): Rename to... + (PKGCONFIG_REQUIRES_PRIVATE, PKGCONFIG_LIBS_PRIVATE): This. Adjust them + depending on `$enable_shared`. + (PKGCONFIG_REQUIRES, PKGCONFIG_LIBS): New variables. + + * builds/unix/freetype2.in, builds/unix/unix-def.in: Use new and updated + variables. + +2022-03-25 Werner Lemberg + + Add `FT_FACE_FLAG_SBIX_OVERLAY` and `FT_HAS_SBIX_OVERLAY`. + + * include/freetype/freetype.h (FT_FACE_FLAG_SBIX_OVERLAY, + FT_HAS_SBIX_OVERLAY): New macro. + + * src/sfnt/ttsbit.c (tt_face_load_sbit): Handle `FT_FACE_FLAG_SBIX_OVERLAY`. + Remove obsolete tracing message. + +2022-03-25 Werner Lemberg + + Add `FT_PARAM_TAG_IGNORE_SBIX`. + + This is another bit to handle 'sbix' tables as described in the OpenType + specification. + + * include/freetype/ftparams.h (FT_PARAM_TAG_IGNORE_SBIX): New macro. + + * src/sfnt/sfobjc.c (is_apple_sbix): Rename to... + (has_sbix): ... this. + Check for more sbit tables. + Handle `FT_PARAM_TAG_IGNORE_SBIX` to eventually control `has_sbix`. + Only call sbit table loader if an sbit table is present. + +2022-03-25 Werner Lemberg + + [truetype] Fix 'sbix' table handling. + + * src/sfnt/ttsbit.c (tt_face_load_sbix_image): Correct calculation of + 'metrics->horiBearingY'. + Set vertical metrics. + + * src/sfnt/sfobjs.c (sfnt_load_face): Adjust setting of `FT_FACE_FLAG_SBIX`. + Handle metrics of fonts with 'sbix' table. + + * src/truetype/ttgload.c (TT_Load_Glyph): For 'sbix' embedded bitmaps, apply + bbox offset and bearing values of the corresponding glyph in the 'glyf' + table if it exists and has a contour. + + * src/truetype/ttobjs.c (tt_face_init): Handle font with 'sbix' table. + + Fixes issue #998. + +2022-03-25 Werner Lemberg + + Add `FT_FACE_FLAG_SBIX` and `FT_HAS_SBIX`. + + Fonts with 'sbix' tables need special handling by the application. + + * include/freetype/freetype.h (FT_FACE_FLAG_SBIX, FT_HAS_SBIX): New macros. + + * src/sfnt/sfobjs.c (sfnt_load_face): Set `FT_FACE_FLAG_SBIX` if 'sbix' + table is present. + +2022-03-25 Werner Lemberg + + * include/freetype/freetype.h (FT_LOAD_SBITS_ONLY): Tag macro as public. + +2022-03-24 Carlo Bramini + + [builds/windows] Fix WCE support. + + * builds/windows/ftsystem.c [_WIN32_WCE]: Include needed by + _alloca. + +2022-03-24 Steve Lhomme + + [build/windows] Improve UWP support. + + * builds/windows/ftsystem.c [UWP]: Wrap CreateFile2 into CreateFileA. + +2022-03-21 Werner Lemberg + + * src/sfnt/ttkern.c (tt_face_get_kerning): Exit early if no table. + + Fixes #1141. + +2022-03-20 Ben Wagner + + [woff2] Support overlap flag for simple glyphs. + + In the woff2 spec it has been proposed to allow the OVERLAP_SIMPLE flag + to be retained through the woff2 format [0]. + + [0] https://www.w3.org/TR/WOFF2/#glyf_table_format + + * src/sfnt/sfwoff2.h (GLYF_OVERLAP_SIMPLE): add glyf flag. + + * src/sfnt/sfwoff2.c (reconstruct_glyf): parse optionFlags and + overlapSimpleBitmap[]. (store_points): set OVERLAP_SIMPLE on first point's + flag if the overlap bit is set. + +2022-03-19 Werner Lemberg + + [cff] Synchronize `cff_slot_load` with `TT_Load_Glyph`. + + * src/cff/cffgload.c (IS_DEFAULT_INSTANCE): New macro. + (cff_slot_load): Use it. + +2022-03-19 Werner Lemberg + + * src/base/ftobjs.c (FT_Request_Size): Guard `face->size`. + + Fixes #1140. + +2022-03-19 Werner Lemberg + + * src/base/ftobjs.c (ft_open_face_internal): Thinko. + +2022-03-19 Ben Wagner + + [doc] FT_OUTLINE_OVERLAP was introduced in 2.10.3. + + * include/freetype/ftimage.h (FT_OUTLINE_OVERLAP): Document when added. + +2022-03-19 Werner Lemberg + + * src/base/ftobjs.c (ft_open_face_internal): Properly guard `face_index`. + + We must ensure that the cast to `FT_Int` doesn't change the sign. + + Fixes #1139. + +2022-03-17 Werner Lemberg + + [sfnt] Avoid invalid face index. + + Fixes #1138. + + * src/sfnt/sfobjs.c (sfnt_init_face), src/sfnt/sfwoff2.c (woff2_open_font): + Check `face_index` before decrementing. + +2022-03-07 Werner Lemberg + + Documentation, whitespace. + +2022-03-05 Anuj Verma + + [sdf] Fix corner checks and improve performance. + + * src/sdf/ftsdf.c (sdf_generate_bounding_box): Always check for a corner if + two distances (for different curves) are very close. + + (sdf_conic_to): Check whether the conic curve can be treated as a line + (which happens if the control point coincides with any end point). + +2022-03-05 Anuj Verma + + [sdf] Implement deviation-based splitting for Bezier curves. + + * src/sdf/ftsdf.c (split_sdf_cubic, split_sdf_shape): Add checks to figure + out the deviation of Bezier curves and stop splitting if the curve is flat + enough. + + * src/sdf/ftsdfcommon.h (ONE_PIXEL): New macro. + +2022-03-05 Anuj Verma + + * include/freetype/freetype.h: Improve SDF documentation. + +2022-03-03 Ben Wagner + + [sfnt] Fix bounds check in SVG. + + The `SVG_DOCUMENT_LIST_MINIMUM_SIZE` macro is non trivial and not + protected by parentheses. As a result, the expression + `table_size - SVG_DOCUMENT_LIST_MINIMUM_SIZE` expands to + `table_size - 2U + SVG_DOCUMENT_RECORD_SIZE` instead of the expected + `table_size - (2U + SVG_DOCUMENT_RECORD_SIZE)`. This causes an incorrect + bounds check which may lead to reading past the end of the `SVG ` table. + + * src/sfnt/ttsvg.c (tt_face_load_svg): wrap macro definitions in + parentheses. + + Bug: https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=45179 + +2022-02-23 Ben Wagner + + [psaux] Full bounds check for OtherSubr 19. + + It is possible for OtherSubr 19 to be invoked when `decoder->buildchar` is + NULL (so that `decoder->len_buildchar` is 0), the `blend` is non-NULL with + `blend->num_designs` set to 2, and the user supplied `idx` to be large (for + example 0xFFFFFFFE). Since these are all `FT_UInt32` the existing bounds + check overflows in a well defined manner, allowing for an invalid call to + `memcpy`. + + In addition, it is possible to call OtherSubr 19 with + `decoder->len_buildchar`, `blend->num_designs`, and `idx` all zero (implying + that `blend->weight_vector` and `decoder->buildchar` are NULL). This passes + the bounds check (it is logically always fine to copy nothing starting at + index zero) but may invoke undefined behavior in `ft_memcpy` if it is backed + by `memcpy`. Calling `memcpy` with either the `src` or `dst` NULL is + undefined behavior (even if `count` is zero). + + * src/psaux/psintrp.c (cf2_interpT2CharString): Correctly check that + `blend->num_designs` can be copied to `decoder->buildchar[idx]`. + Also avoid passing NULL to `ft_memcpy`. + + Bug: https://crbug.com/1299259 + +2022-02-21 suzuki toshiya + + [cmake] Drop the support of CMake 2.x. + + * CMakeLists.txt: Require CMake 3.0 (released on 2014) or newer. + + The issue #1059 reports the difficulty to support both of + CMake 2.x and newer one by single CMakeLists.txt without + the inflation of cmake_policy() workarounds. + + For better maintainability, the support of CMake 2.x is + dropped. + +2022-02-19 Werner Lemberg + + * src/bdf/README: Updated. + +2022-02-19 Werner Lemberg + + * builds/mac/ftmac.c, src/base/ftmac.c: s|FT_MAC_H||. + +2022-02-19 Werner Lemberg + + src/sfnt/ttkern.c (tt_face_load_kern): Micro-optimize. + + A kerning table can be handled by binary search if it has equal entries. + + Fixes #1132. + +2022-02-17 Steve Lhomme + Alexei Podtelezhnikov + + [builds/windows] Add support for legacy UWP builds. + + * builds/windows/ftsystem.c: Add neccessary macro substitutions to + enable strict UWP builds. + + See !141. + +2022-02-16 Werner Lemberg + + ftmm.h: Minor documentation improvement. + +2022-02-13 Alexei Podtelezhnikov + + [pshinter] Tune PSH_STRONG_THRESHOLD_MAXIMUM value. + + Before the change, the hinting engine frequently confused horizontal + stem and serif hints making some stems too thin and some serifs too + thick. The value was tuned using serif fonts from the URW+ base 35 + collection. + + * src/pshinter/pshalgo.c [PSH_STRONG_THRESHOLD_MAXIMUM]: s/30/12/. + +2022-02-12 Werner Lemberg + + t1tables.h: Documentation improvements. + +2022-02-12 Werner Lemberg + + t1tables.h: Whitespace. + +2022-02-11 Werner Lemberg + + [type42] Fix `FT_Get_PS_Font_Private` for this format. + + Since Type42 fonts don't have a 'Private' dictionary, the return value + should be `FT_Err_Invalid_Argument`. + + * src/type42/t42drivr.c (t42_ps_get_font_private): Removed. + (t42_service_ps_info): Updated. + +2022-02-09 Alexei Podtelezhnikov + + [pshinter] Clear reused mask. + + In PS hinter, memory allocations persist until the module is done. + Therefore, we have to clear reused masks. + + * src/pshinter/pshrec.c (ps_mask_table_alloc): Clear reused mask. + +2022-02-09 Alexei Podtelezhnikov + + [pshinter] Use unsigned indices. + + This reduces casting and eliminates some checks. + + * src/pshinter/pshrec.c (ps_mask_test_bit, ps_mask_table_merge, + ps_dimension_add_t1stem, ps_hints_t1stem3): Updated. + (ps_dimension_add_counter): Updated, unnecessary checks removed. + +2022-02-08 Alexei Podtelezhnikov + + [pshinter] Fix mask merging. + + We forgot to update the number of bits when merging a larger mask + into a smaller one. This fix might have rendering effects. + + * src/pshinter/pshrec.c (ps_mask_table_merge): Inherit the number + of bits from a larger mask. There is no need to zero unused bits, + already zeroed during allocation. + (ps_mask_clear_bit): Removed. + (ps_mask_ensure): Minor. + +2022-02-08 Alexei Podtelezhnikov + + [pshinter] Revise the hint table handling. + + * src/pshinter/pshrec.c (ps_hint_table_ensure): Remove redundant size + check; avoid array zeroing because it is fully initialized when used. + (ps_hint_table_alloc): Fix off-by-one comparison and remove another + zeroing of the array elements. + +2022-02-06 Werner Lemberg + + Various minor doc fixes. + +2022-02-06 Alexei Podtelezhnikov + + [builds/windows] Add SVG to to project files. + + * builds/windows/vc2010/freetype.vcxproj: Updated. + * builds/windows/vc2010/freetype.vcxproj.filters: Updated. + * builds/windows/visualc/freetype.vcproj: Updated. + +2022-02-03 Alexei Podtelezhnikov + + * src/winfonts/winfnt.c (fnt_face_get_dll_font): Trace font resources. + +2022-02-02 Eric Jing <@CPUcontrol> + + [cmake] Fix build on MacOS. + + * CMakeLists.txt (CMAKE_OSX_ARCHITECTURES): Update value to fix the building + of a framework on MacOS. + + * builds/mac/freetype-Info.plist (CFBundleExecutable): Make identifier + lowercase only. + + Fixes #1127. + +2022-02-02 Alexei Podtelezhnikov + + [psaux] Revise `PS_Table` handling. + + The old impleemntation was not using `FT_REALLOC`, buing too careful + with the offset rebasing. It shoudl be safe to rely on the base + movements. + + * src/psaux/psobjs.c (reallocate_t1_table, shift_elements): Combine + into... + (ps_table_realloc): ... this function based on `FT_REALLOC`. + (ps_table_done): Simplified. + (ps_table_add): Updated. + +2022-02-02 Alexei Podtelezhnikov + + * src/cache/ftcmru.c (FTC_MruList_New): Explain zeroing. + +2022-01-31 Alexei Podtelezhnikov + + [cache] Partially revert 9870b6c07e2c. + + Fix crashes reported by Werner. + + * src/cache/ftcmru.c (FTC_MruList_New): Use `FT_ALLOC` again. + +2022-01-31 Werner Lemberg + + freetype.h: Minor documentation improvement. + +2022-01-31 Alexei Podtelezhnikov + + [cache] Fix fallouts from edd4fedc5427. + + Reported by Werner. + + * src/cache/ftcimage.c (FTC_INode_New): Always initialize FT_Glyph. + * src/cache/ftcsbits.c (FTC_SNode_New): Always initialize FT_SBit. + +2022-01-31 Alexei Podtelezhnikov + + Clean-up - do not doubt FT_FREE. + + * src/base/ftobjs.c (memory_stream_close): Do not reassign zero + after `FT_FREE`. + * src/sfnt/sfwoff.c (sfnt_stream_close): Ditto. + * src/sfnt/sfwoff2.c (stream_close): Ditto. + * src/psaux/psobjs.c (ps_parser_load_field): Ditto. + * src/truetype/ttgxvar.c (ft_var_load_avar, tt_set_mm_blend, + tt_set_mm_blend): Ditto. + +2022-01-30 Werner Lemberg + + * CMakeLists.txt: Include 'FindPkgConfig' module. + + Older cmake versions don't provide `pkg_check_modules` by default. + + Fixes #1126. + +2022-01-30 Alexei Podtelezhnikov + + * src/psaux/psobjs.c (ps_parser_load_field): Reduce `string` scope. + +2022-01-29 suzuki toshiya + + [cmake] Check the availability of `bzip2.pc'. + + (CMakeLists.txt): Check the availability of `bzip2.pc'. + + * If `bzip2.pc' is available, Requires.private should include + bzip2, but Libs.private should not include -lbz2. + + * If `bzip2.pc' is unavailable, Requires.private cannot include + bzip2, but Libs.private should include -lbz2. + + Fix #897. + +2022-01-28 Werner Lemberg + + * unix/configure.raw: We need 'librsvg' version 2.46.0 or newer. + + Older versions don't have function `rsvg_handle_get_intrinsic_dimensions`. + +2022-01-28 Alexei Podtelezhnikov + + Minor clean-ups. + + * src/base/ftrfork.c (raccess_make_file_name): Do not set error. + * src/sfnt/sfdriver.c (get_win_string, get_apple_string): Ditto. + * src/cff/cffobjs.c (cff_strcpy): Do not confuse about error. + * src/psaux/psobjs.c (ps_table_done): Ditto. + * src/truetype/ttgxvar.c (ft_var_readpacked*, ft_var_load_avar): Ditto. + +2022-01-27 Ben Wagner + + Document `FT_Outline_Decompose` degenerate segments. + + `FT_Outline_Decompose` does not filter out and can return degenerate + segments in an outline. This can be surprising when attemping to + stroke such an outline. Clarify the existing documentation on this + matter to cover all forms of degeneracy (without specifying exactly + how they will be reported), why they might arise, and better explain in + what cases they may be an issue. + + * include/freetype/ftoutlin.h (FT_Outline_Decompose): update + documentation. + + Fixes #952. + +2022-01-27 Anuj Verma + + Fix sdf computation while `USE_SQUARED_DISTANCES`. + + Function `map_fixed_to_sdf` expects spread to be absolute + and not squared. + + * src/sdf/ftbsdf.c (finalize_sdf): Pass absolute spread + while `map_fixed_to_sdf`. + + * src/sdf/ftsdf.c (sdf_generate_bounding_box): Ditto. + +2022-01-27 Tapish Ojha + + [sfnt] Improve sRGB constants. + + * src/base/ftbitmap.c (ft_gray_for_premultiplied_srgb_bgra): Use slightly + more precise values. + + Fixes #1018. + +2022-01-27 Werner Lemberg + + docs/release: Updated. + +2022-01-26 Alexei Podtelezhnikov + + * src/pfr/pfrload.c (pfr_phy_font_load): Use FT_QNEW_ARRAY. + +2022-01-26 Alexei Podtelezhnikov + + * src/sdf/ftsdf.c (sdf_*_new): Use standard macro. + +2022-01-26 Alexei Podtelezhnikov + + [pcf] Delay encoding allocation and avoid its zeroing. + + * src/pcf/pcfread.c (pcf_get_encodings): Refactor and use FT_QNEW_ARRAY. + +2022-01-25 Werner Lemberg + + Aarg, typo. + +2022-01-25 Werner Lemberg + + freetype.h: More updates to `FT_LOAD_COLOR` description. + +2022-01-25 Werner Lemberg + + * builds/unix/configure.raw (FT_DEMO_CFLAGS): Pass `-DHAVE-LIBRSVG`. + + This helps in decoupling library support from `pkg-config` for other + platforms. + +2022-01-25 Werner Lemberg + + Update documentation for `FT_LOAD_COLOR`. + +2022-01-24 Ben Wagner + + [pshinter] Ensure all point flags are initialized. + + Only off curve point flags were fully initialized. + + * src/pshinter/pshalgo.c (psh_glyph_init): always initialize flags. + + Fixes: https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=43930 + +2022-01-24 Werner Lemberg + + .mailmap: Typo. + +2022-01-23 Werner Lemberg + + * src/svg/ftsvg.c (ft_svg_property_set): Disallow NULL pointers. + +2022-01-23 Werner Lemberg + + .mailmap: Updated. + +2022-01-23 Werner Lemberg + + More documentation on handling OT-SVG. + +2022-01-23 Werner Lemberg + + * src/svg/ftsvg.c: Rename `svg_hooks` to `svg-hooks` for consistency. + +2022-01-22 Werner Lemberg + + [sfnt] Reject malformed SVG tables. + + * src/sfnt/ttsvg.c (SVG_TABLE_HEADER_SIZE, SVG_DOCUMENT_RECORD_SIZE, + SVG_DOCUMENT_LIST_MINIMUM_SIZE, SVG_MINIMUM_SIZE): New macros. + (tt_face_load_svg): Check offsets. + Check table and record sizes. + + Reported as + + https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=43918 + +2022-01-22 Alexei Podtelezhnikov + + * src/psaux/psobjs.c (ps_table_new): Revert to zeroing. + +2022-01-20 Alexei Podtelezhnikov + + [psaux, type1, type42] Avoid annecessary zeroing. + + * src/psaux/psobjs.c (ps_table_new): Use FT_QNEW_ARRAY. + * src/type1/t1load.c (parse_encoding): Ditto. + * src/type42/t42parse.c (t42_parse_encoding): Ditto. + +2022-01-20 Werner Lemberg + + [builds/unix] Handle 'librsvg' for demo programs. + + * builds/unix/configure.raw: Check for 'librsvg'. + (LIB_CLOCK_GETTIME): Don't call `AC_SUBST` on this but on... + (FT_DEMO_CFLAGS, FT_DEMO_LDFLAGS): ... these two new variables. + + * builds/unix/unix-cc.in (LIB_CLOCK_GETTIME): Replaced by... + (FT_DEMO_CFLAGS, FT_DEMO_LDFLAGS): ... these two new variables. + +2022-01-20 Moazin Khatti + + Add 'svg' module for OT-SVG rendering. + + * CMakeLists.txt (BASE_SRCS): Add svg module file. + * meson.build (ft2_public_headers): Add `otsvg.h`. + + * modules.cfg (RASTER_MODULES): Add `svg` module. + + * builds/meson/parse_modules_cfg.py: Add svg module. + + * include/freetype/config/ftmodule.h: Add `ft_svg_renderer_class`. + * include/freetype/fterrdef.h: Add `Invalid_SVG_Document` and + `Missing_SVG_Hooks` error codes. + * include/freetype/internal/fttrace.h: Add tracing for `otsvg`. + * include/freetype/internal/svginterface.h: New file. It adds an interface + to enable the presetting hook from the `base` module. + * include/freetype/otsvg.h (SVG_Lib_Init_Func, SVG_Lib_Free_Func, + SVG_Lib_Render_Func, SVG_Lib_Preset_Slot_Func): New hooks for SVG rendering. + (SVG_RendererHooks): New structure to access them. + + * src/base/ftobjs.c: Include `svginterface.h`. + (ft_glyphslot_preset_bitmap): Add code for presetting the slot for SVG + glyphs. + (ft_add_renderer): Updated. + + * src/svg/*: New files. + +2022-01-20 Moazin Khatti + + Add `FT_Glyph` support for OT-SVG glyphs. + + * include/freetype/ftglyph.h (FT_SvgGlyphRec, FT_SvgGlyph): New structure. + + * src/base/ftglyph.c: Include `otsvg.h`. + (ft_svg_glyph_init, ft_svg_glyph_done, ft_svg_glyph_copy, + ft_svg_glyph_transform, ft_svg_glyph_prepare): New function. + (ft_svg_glyph_class): New class. + (FT_New_Glyph, FT_Glyph_To_Bitmap): Updated to handle OT-SVG glyphs. + * src/base/ftglyph.h: Updated. + +2022-01-20 Moazin Khatti + + [truetype, cff] Add code to load SVG document. + + * src/cff/cffgload.c (cff_slot_load): Add code to load SVG doc. + * src/truetype/ttgload.c (TT_Load_Glyph): Add code to load SVG doc. + +2022-01-20 Moazin Khatti + + Add code to load OT-SVG glyph documents. + + * include/freetype/config/ftheader.h (FT_OTSVG_H): New macro. + * include/freetype/freetype.h (FT_FACE_FLAG_SVG, FT_HAS_SVG): New macros. + (FT_LOAD_SVG_ONLY): New internal macro. + * include/freetype/ftimage.h (FT_Glyph_Format): New enumeration value + `FT_GLYPH_FORMAT_SVG`. + * include/freetype/internal/ftobjs.h (FT_GLYPH_OWN_GZIP_SVG): New macro. + * include/freetype/internal/fttrace.h: Add `ttsvg` for `ttsvg.c`. + * include/freetype/internal/sfnt.h(load_svg, free_svg, load_svg_doc): New + functions. + * include/freetype/internal/tttypes.h (TT_FaceRec): Add `svg` for + the SVG table. + * include/freetype/otsvg.h (FT_SVG_DocumentRec): New structure to hold the + SVG document and other necessary information of an OT-SVG glyph in a glyph + slot. + * include/freetype/tttags.h (TTAG_SVG): New macro. + + * src/base/ftobjs.c: Include `otsvg.h`. + (ft_glyphslot_init): Allocate `FT_SVG_DocumentRec` in `slot->other` + if the SVG table exists. + (ft_glyphslot_clear): Free it upon clean-up if it is a GZIP compressed + glyph. + (ft_glyphslot_done): Free the document data if it is a GZIP compressed + glyph. + (FT_Load_Glyph): Don't auto-hint SVG documents. + + * src/cache/ftcbasic.c (ftc_basic_family_load_glyph): Add support for + FT_GLYPH_FORMAT_SVG. + + * src/sfnt/rules.mk (SFNT_DRV_SRC): Add `ttsvg.c`. + * src/sfnt/sfdriver.c: Include `ttsvg.h`. + (sfnt_interface): Add `tt_face_load_svg`, `tt_face_free_svg` and + `tt_face_load_svg_doc`. + * src/sfnt/sfnt.c: Include `ttsvg.c`. + * src/sfnt/sfobjs.c (sfnt_load_face, sfnt_done_face): Add code to load and + free data of the the SVG table. + * src/sfnt/ttsvg.c: New file, implementing `tt_face_load_svg`, + `tt_face_free_svg` and `tt_face_load_svg_doc`. + * src/sfnt/ttsvg.h: Declarations of the SVG functions in + `ttsvg.c`. + +2022-01-20 Moazin Khatti + + Add flag `FT_CONFIG_OPTION_SVG`. + + This flag is going to be used to conditionally compile support for OT-SVG + glyphs. FreeType will do the parsing and rely on external hooks for + rendering of OT-SVG glyphs. + + * devel/ftoption.h, include/freetype/config/ftoption.h + (FT_CONFIG_OPTION_SVG): New flag. + +2022-01-20 Alexei Podtelezhnikov + + [pshinter] Avoid unnecessary zeroing. + + * src/pshinter/pshalgo.c (psh_hint_table_init,psh_glyph_init, + psh_glyph_interpolate_normal_points): Use FT_QNEW_ARRAY. + +2022-01-20 Alexei Podtelezhnikov + + * include/freetype/freetype.h: Clarify `FT_Size` life cycle. + +2022-01-20 Alexei Podtelezhnikov + + [base] Undefined scale means no scale. + + It might be surprising that FreeType does not have default ppem and + the size has to be set explicitly or face undefined behavior with + undefined variables and errors. This offers an alternative to + missing or zero scale by simply setting FT_LOAD_NO_SCALE. Defined + behavior is bettr than undefined one. + + This is alternative to !132 and discussed in + https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=43708 + + * src/base/ftobjs.c (FT_Load_Glyph): Deal with zero scale. + * include/freetype/freetype.h: Document it. + +2022-01-18 Alexei Podtelezhnikov + + * src/autofit/afglobal.c (af_face_globals_new): Reduce zeroing. + + Everything in AF_FaceGlobals is initialized except metrics. Those + are zeroed here and initialized on demand later. + +2022-01-16 Alexei Podtelezhnikov + + [bdf,type1] Avoid unnecessary hash zeroing. + + * src/bdf/bdflib.c (_bdf_parse_start): Use `FT_QALLOC`. + * src/type1/t1load.c (parse_subrs): Use `FT_QNEW`. + +2022-01-16 Ozkan Sezer + + Add Watcom C/C++ calling. + + In the unlikely case the source is built with OpenWatcom's -ec? + switches to enforce a calling convention, the qsort() compare + function must still be set to __watcall. + + * include/freetype/internal/compiler-macros.h (FT_COMPARE_DEF): + Updated. + +2022-01-15 Ben Wagner + + [pshinter] Avoid accessing uninitialized zone. + + The `normal_top.count` may be 0, implying no `normal_top.zones` exist. + The code must not access these (non-existent) `normal_top.zones`. + + * src/pshinter/pshalgo.c (ps_hints_apply): Do not assume that + `normal_top.zones[0]` is initialized. Test `normal_top.count` + before using `normal_top.zones[0]`. Do not rescale if there are no + `zones`. + + Fixes: https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=43675 + +2022-01-15 Alexei Podtelezhnikov + + [cache] Avoid unnecessary zeroing. + + * src/cache/ftccmap.c (ftc_cmap_node_new): Use `FT_QNEW`. + * src/cache/ftcimage.c (FTC_INode_New): Ditto. + * src/cache/ftcsbits.c (FTC_SNode_New): Ditto. + +2022-01-15 Ozkan Sezer + + Add Watcom C/C++ support. + + * include/freetype/config/integer-types.h: Make sure `long long` is + used then available. + * include/freetype/internal/ftcalc.h (FT_MSB): Add Watcom C/C++ pragma. + +2022-01-15 Alexei Podtelezhnikov + + * src/sdf/ftbsdf.c (ED): s/near/prox/. + + This works around the Watcom C definition of `near` as restricted + __near. + +2022-01-15 Alexei Podtelezhnikov + + * include/freetype/internal/compiler-macros.h [FT_COMPARE_DEF]: Tighten. + + This works around Watcom C library using __watcall. + +2022-01-14 Alexei Podtelezhnikov + + * src/pshinter/pshglob.c (psh_globals_new): Avoid zeroing. + + This large allocation is followed by careful initialization. Whatever + is missed should be initialized manually. + +2022-01-14 Alexei Podtelezhnikov + + * src/base/fthash.c (hash_insert): Avoid unnecessary zeroing. + +2022-01-14 Alexei Podtelezhnikov + + * src/bdf/bdflib.c (_bdf_parse_glyphs): Remove redundant assignment. + +2022-01-13 Alexei Podtelezhnikov + + * src/lzw/ftlzw.c (FT_Stream_OpenLZW): Avoid unnecessary zeroing. + +2022-01-13 Ben Wagner + + [bzip2] Reset bzip stream on any error. + + According to the bzip documentation it is undefined what will happen if + `BZ2_bzDecompress` is called on a `bz_stream` it has previously returned an + error against. If `BZ2_bzDecompress` returns anything other than `BZ_OK` + the only valid next action is `BZ2_bzDecompressEnd`. + + Reported as + + https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=43564 + + * src/bzip2/ftbzip2.c (FT_BZip2FileRec_): Add `reset` to track the need to + reset the stream. + (ft_bzip2_file_init): Initialize `reset` to 0. + (ft_bzip2_file_reset): Set `reset` to 0 after resetting. + (ft_bzip2_file_fill_output): Set `reset` to 1 when `BZ2_bzDecompress` + returns anything other than `BZ_OK`. + +2022-01-12 Werner Lemberg + + .gitlab-ci.yml: Minor comment cleanups. + +2022-01-12 Azamat H. Hackimov + + .gitlab-ci.yml: Add steps to `before_script` to ensure recent CA. + + Fetch current list of valid CAs from Windows Update and manually import them + to trusted datastore. This action is required to make downloads work from + sites that need recent Let's Encrypt ISRG Root X1 certificate. + +2022-01-11 Ben Wagner + + Revert "[bzip2] Avoid use of uninitialized memory." + + This reverts commit d276bcb7f0c02c20d3585b2e5626702df6d140a6. + + The original commit did avoid the use of uninitialized memory. However, + it appears that the original commit is no longer required. The + underlying issue was resolved by a change in freetype2-testing "Build + bzip2 correctly." [0]. Prior to [0] bzip2 was built without msan, so + bzip2 writes were not tracked or considered initialized. Clearing + `buffer` in the original commit allowed msan to see the `buffer` content + initialized once in FreeType code, but msan saw no writes into buffer + from bzip2. With bzip2 now built with msan, the bzip2 writes are + properly instrumented and msan sees the bzip2 writes into the buffer. As + a result the original commit can be safely reverted to allow for better + detection of other uninitialized data scenarios. + + * src/bzip2/ftbzip2.c (FT_Stream_OpenBzip2): Revert to using `FT_QNEW`. + + [0] https://github.com/freetype/freetype2-testing/commit/3c052a837a3c960709227a0d6ddd256e87b88853 + +2022-01-11 Ben Wagner + + [type42] Track how much type42 ttf data is available. + + Currently `T42_Open_Face` eagerly allocates 12 bytes for the ttf header + data which it expects `t42_parse_sfnts` to fill out from /sfnts data. + However, there is no guarantee that `t42_parse_sfnts` will actually be + called while parsing the type42 data as the /sfnts array may be missing + or very short. This is also confusing behavior as it means + `T42_Open_Face` is tightly coupled to the implementation of the very + distant `t42_parse_sfnts` code which requires at least 12 bytes to + already be reserved in `face->ttf_data`. + + `t42_parse_sfnts` itself eagerly updates `face->ttf_size` to track how + much space is reserved for ttf data instead of traking how much data has + actually been written into `face->ttf_data`. It will also act strangely + in the presense of multiple /sfnts arrays. + + * src/type42/t42objs.c (T42_Open_Face): ensure `ttf_data` is initialized + to NULL. Free `ttf_data` on error. + + * src/type42/t42parse.c (t42_parse_sfnts): delay setting `ttf_size` and + set it to the actual number of bytes read. Ensure `ttf_data` is freed + if there are multiple /sfnts arrays or there are any errors. + +2022-01-11 Dominik Röttsches + + [sfnt] Fix limit checks for `COLR` v1 ClipBoxes + + * src/sfnt/ttcolr.c (tt_face_get_color_glyph_clipbox): Fix off-by-one in + limit checks. + +2022-01-11 Werner Lemberg + + Update all copyright notices. + +2022-01-11 Werner Lemberg + + * src/sfnt/ttcolr.c (read_paint): Fix undefined left-shift operation. + + Reported as + + https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=43151 + +2022-01-11 Werner Lemberg + + * src/type42/t42objs.c (T42_Open_Face): Avoid use of uninitialized memory. + + Reported as + + https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=43508 + +2022-01-11 Werner Lemberg + + .gitlab-ci.yml: Fix typo in previous commit. + +2022-01-11 Werner Lemberg + + .gitlab-ci.yml: Update Windows image. + + The old image produced errors like + + ``` + Downloading zlib patch from + https://wrapdb.mesonbuild.com/v2/zlib_1.2.11-5/get_patch + A fallback URL could be specified using patch_fallback_url key in the wrap file + WrapDB connection failed to + https://wrapdb.mesonbuild.com/v2/zlib_1.2.11-5/get_patch + with error + + ``` + +2022-01-11 Werner Lemberg + + * subprojects/zlib.wrap: Update from upstream. + +2022-01-10 Werner Lemberg + + * src/sfnt/ttcolr.c (tt_face_get_color_glyph_clipbox): Add limit checks. + + Reported as + + https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=40716 + +2022-01-10 Werner Lemberg + + [zlib] Don't typedef `ptrdiff_t`. + + While using zlib in 'solo' mode (via the `Z_SOLO` macro), we actually + include some standard header files, making the typedef fail on systems where + the native `ptrdiff_t` type differs. + + Fixes #1124. + + * src/zlib/zutil.h: Comment out definition; it doesn't work on Windows. + + * src/zlib/patches/freetype-zlib.diff: Updated. + +2022-01-10 Werner Lemberg + + [zlib] Some organizational changes. + + We now first apply zlib's `zlib2ansi` script, then FreeType's patch file. + + * src/gzip/README.freetype: Updated. + + * patches/0001-zlib-Fix-zlib-sources-to-compile-for-FreeType.patch: Renamed + to... + * patches/freetype-zlib.diff: This. + Clean up description, then regenerate it as follows: + + - Copy unmodified files from `zlib` repository. + - Run `zlib2ansi` script. + - Run `git diff -R > patches/freetype-zlib.diff.new`. + - Insert patch description of old diff file, then replace old diff with + new diff file. + +2022-01-09 David Turner + + [gzip] Update sources to zlib 1.2.11 + + This can be tested by building with the Unix development build + + make setup devel + make + + or by building the freetype-demos programs with + + meson setup build -Dfreetype2:zlib=internal + meson compile -C out + + and trying to run `ftview` with a `.pcf.gz` font file. + + * src/gzip/ftgzip.c, src/gzip/rules.mk: Update for new zlib sources. Also + remove the temporary fix introduced in commit 6a431038 to work around the + fact that the internal sources were too old. + + * src/gzip/README.freetype: New file describing the origin of the sources + and how they were modified. + + * src/gzip/patches/*: Patch files applied to original sources. + + * src/gzip/*: Updated zlib sources with the patch file(s) from + `src/gzip/patches/` applied, followed by a conversion with zlib's + `zlib2ansi` script. + +2022-01-09 David Turner + + [meson] Change Zlib configuration option. + + * meson_options.txt, meson.build: Change the format of the 'zlib' meson + build configuration option to be a combo with the following choices: + + - none: Do not support gzip-compressed streams at all. + + - internal: Support gzip-compressed streams using the copy of the gzip + sources under `src/gzip/`; this should only be used during development + to ensure these work properly. + + - external: Support gzip-compressed streams using the 'zlib' Meson + subproject, linked as a static library. + + - system: Support gzip-compressed streams using a system-installed version + of zlib. + + - auto: Support gzip-compressed streams using a system-installed version + of zlib, if available, or using the 'zlib' subproject otherwise. This + is the default. + + - disabled: Backward-compatible alias for 'none'. + + - enabled: Backward-compatible alias for 'auto'. + +2022-01-09 Werner Lemberg + + [bzip2] Avoid use of uninitialized memory. + + * src/bzip2/ftbzip2.c (FT_Stream_OpenBzip2): Don't use `FT_QNEW` but + `FT_NEW` for setting up `zip` to avoid uninitialized memory access while + handling malformed PCF fonts later on. + + Fixes + + https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=42800 + +2022-01-09 Alexei Podtelezhnikov + + [sfnt] Fix off-by-one error. + + The 0-base index is equal to the number of previosly parsed entries. + It is an error to adjust it by one to get the number truncated by + a stream error. This is probably inconsequential because valid + entries are correctly accounted for. + + * src/sfnt/ttload.c (check_table_dir): Do not adjust the truncated + number of tables. + +2022-01-08 Werner Lemberg + + [sfnt, type42] Correct previous commit. + + Really fix https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=42773. + + * src/sfnt/ttload.c (check_table_dir): Revert change. + + * src/type42/t42.parse.c (t42_parse_sfnts): Don't use `FT_QREALLOC` but + `FT_REALLOC` for setting up `ttf_data` to avoid uninitialized memory access + while handling malformed TrueType fonts later on. + +2022-01-07 Werner Lemberg + + * src/sfnt/ttload.c (check_table_dir): Initialize `table`. + + Reported as + + https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=42773 + +2022-01-07 Werner Lemberg + + [sfnt] Avoid 'runtime error: applying zero offset to null pointer'. + + * src/sfnt/ttsbit.c (tt_sbit_decoder_load_byte_aligned): Exit early if + `line` is NULL. + +2022-01-07 Werner Lemberg + + [autofit, pshinter] Use `FT_OFFSET`. + + This avoids + + ``` + runtime error: applying zero offset to null pointer + ``` + + warnings of clang's undefined behaviour sanitizer. + + * src/autofit/afcjk.c (af_cjk_hints_link_segments, + af_cjk_hints_compute_edges, af_cjk_hints_compute_blue_edges, + af_cjk_hint_edges, af_cjk_align_edge_points): Do it. + + * src/autofit/afhints.c (af_glyph_hints_align_edge_points, + af_glyph_hints_align_strong_points): Ditto. + + * src/autofit/aflatin.c (af_latin_metrics_init_widths, + af_latin_hints_link_segments, af_latin_hints_compute_edges, + af_latin_hints_compute_blue_edges, af_latin_hint_edges): Ditto. + + * src/pshinter/pshalgo.c (psh_hint_table_init): Ditto. + +2022-01-06 Ben Wagner + + [truetype] Reset localpoints when varying cvt. + + When iterating over the cvt tuples and reading in the points it is necessary + to set all of `localpoints`, `points`, and `point_count` in all cases. The + existing code did not reset `localpoints` to `NULL` when there were no + private point numbers. If the previous tuple did have private point numbers + and set `localpoints` to `ALL_POINTS` this would not be cleared and the + wrong branch would be taken later, leading to possible heap buffer overflow. + + * src/truetype/ttgxvar.c (tt_face_vary_cvt): Reset `localpoints` to `NULL` + when it isn't valid. + + Fixes: https://crbug.com/1284742 + +2022-01-02 Werner Lemberg + + * builds/unix/configure.raw: Restore `SYSTEM_ZLIB` variable. + + This was accidentally removed with commit 93ebcbd0 almost eight years ago. + +2021-12-27 Alexander Borsuk + + Fix warnings for CMake Unity builds. + + * src/cache/ftcbasic.c (FT_COMPONENT): Undefine macro before redefinition. + * src/smooth/ftgrays.c (TRUNC, FRACT): Ditto. + +2021-12-18 Alexander Borsuk + + Clang-Tidy warning fixes. + + * src/base/ftobjs.c (FT_Get_Paint): Operator has equivalent nested operands. + * src/bdf/bdflib.c (_bdf_add_property): Value stored to `fp` is never read. + * src/sdf/ftbsdf.c (bsdf_init_distance_map): Value stored to `pixel` is + never read. + * src/sdf/ftsdf.c (split_sdf_shape): Value stored to `error` is never read. + +2021-12-17 Eli Schwartz + + * meson.build: Optimize lookup for `python3` program. + + The python module's `find_installation` method is intended to provide + routines for compiling and installing python modules into the + `site-packages` directory. It does a couple of slow things, including run + an introspection command to scrape sysconfig info from the detected + interpreter, which are not needed for the sole use case of invoking the + found installation as an executable. + + Furthermore, when invoked without the name or path of a python binary, it is + hardcoded to always look for `python3` corresponding to the interpreter + meson itself uses to run. So using `find_installation` did not even allow + detecting `python2` as a fallback. + + Instead, switch to a simple `find_program` lookup that finishes as soon as + the program is found. + +2021-12-17 Eli Schwartz + + * builds/meson/*.py: Fix name of python executable for auxiliary scripts. + + The previous change to check the return code of `run_command` invocations + caused the CI to fail. Although most scripts used `python_exe` as the + program command, the script to determine the project version did not. + + But, all scripts used `python` as the shebang, and this is not available on + all systems. Particularly Debian does not provide a `python` command, + though `python3` does exist. This meant that formerly the version number + was lacking, and now the build simply fails. + + Instead, rely on `python3` since it is guaranteed to exist when running + meson, and `python2` is end of life anyway. + +2021-12-17 Eli Schwartz + + * meson.build: Check the return value of `run_command`. + + By default, errors are not checked and a command that is somehow broken will + just capture incorrect output (likely an empty string). Current development + versions of meson now raise a warning for this implicit behavior, and advise + explicitly setting the `check:` keyword argumend to determine whether a + failing return code should be considered an error. + + Since none of the commands in this project are expected to fail, mark them + as required to succeed. + +2021-12-13 Alexei Podtelezhnikov + + [truetype] Upstream the hdmx binary search. + + * src/truetype/ttobjs.h (TT_SizeRec): Add `widthp` for the hdmx + widths. + * src/truetype/ttobjs.c (tt_size_reset): Initialize `widthp` even + though it might never be used by the interpreter. + * src/truetype/ttgload.c (tt_loader_init): Avoid repeated searches + in the hdmx table. + +2021-12-12 Alexei Podtelezhnikov + + [truetype] Reset the IUP-called flags for each subglyph. + + This fixes fall-out from 7809007a5b88b15, where the composite + accents were no longer hinted. + + * src/truetype/ttgload.c (ttloader_init): Move the IUP-called flag + initialization from here... + * src/truetype/ttinterp.c (TT_Run_Context): ... to here. + +2021-12-12 Alexei Podtelezhnikov + + [truetype] Binary search through the `hdmx` records. + + The `hdmx` table is supposed to be sorted by ppem size, which + enables binary search. We also drop the check for the sufficient + length of the record because it is now enforced when the table + is loaded. + + * include/freetype/internal/tttypes.h (TT_FaceRec): Store the `hdmx` + record pointers sorted by ppem instead of ppem's themselves. + * src/truetype/ttpload.c (tt_face_load_hdmx): Prudently sort records. + (tt_face_get_device_metrics): Implement binary search to retrieve + advances. + +2021-12-12 Alexei Podtelezhnikov + + [truetype] Honor FT_LOAD_ADVANCE_ONLY if `hdmx` is usable. + + This simply shortcuts the glyph loading if FT_LOAD_ADVANCE_ONLY + is specified by FT_Get_Advances and the `hdmx` data are located. + Particularly, the classic v35 interpreter or "verified" ClearType + fonts might see 100x speed up in retrieving the hdmx cache. + + * src/truetype/ttgload.c (TT_Load_Glyph): Insert the shortcut. + +2021-12-12 Alexei Podtelezhnikov + + [truetype] Initialize the loader with `hdmx` data. + + The `hdmx` matching can be done before the glyph is loaded. + + * include/freetype/internal/tttypes.h (TT_LoaderRec): Add a field. + * src/truetype/ttgload.c (compute_glyph_metrics): Relocate the `hdmx` + code from here... + (tt_loader_init): ... to here, before the glyph is loaded. + +2021-12-12 Alexei Podtelezhnikov + + [truetype] Relocate subpixel flag setting. + + `TT_RunIns` is too busy to deal with subpixel flags. It is better + to set them in `tt_loader_init`, which is executed before each + glyph program. + + * src/truetype/ttinterp.c (TT_RunIns): Move the flag setting from + here... + * src/truetype/ttgload.c (tt_loader_init): ... to here. + +2021-12-12 Alexei Podtelezhnikov + + [truetype] Limit INSTCTRL appication within specs. + + * src/truetype/ttinterp.c (Ins_INSTCTRL): Limit its global effects + to the CVT program and local effects to the glyph program. + + This also fixes an Infinality buglet. The `ignore_x_mode` should be + locally unset by the glyph program. + +2021-12-09 Ben Wagner + + [bdf] Fix use of uninitialized value. + + In _bdf_readstream if the data contained no newline then the buffer + would continue to grow and uninitialized data read until either the + uninitialized data contained a newline or the buffer reached its + maxiumum size. The assumption was that the line was always too long and + the buffer had been filled, however this case can also happen when there + is not enough data to fill the buffer. + + Correct this by properly setting the cursor to the end of the available + data, which may be different from the end of the buffer. This may still + result in one extra allocation, but only on malformed fonts. + + * src/bdf/bdflib.c (_bfd_readstream): Correctly update cursor. Remove + unread set of `avail`. + + Bug: https://lists.nongnu.org/archive/html/freetype-devel/2021-12/msg00001.html + +2021-12-07 Alexei Podtelezhnikov + + [truetype] Reduce Infinality footprint again. + + * src/truetype/ttgload.c (compute_glyph_metrics): Streamline and + prioritize the Infinality checks to use `hdmx`. + +2021-12-07 Cameron Cawley + + [builds/windows] Guard some non-ancient API. + + We can support Windows 98 and NT 4.0 in principle... + + * builds/windows/ftdebug.c, builds/windows/ftsystem.c: Check for the + ancient SDK using _WIN32_WINDOWS, _WIN32_WCE, or _WIN32_WINNT. + +2021-12-07 Cameron Cawley + + * builds/windows/visualc/freetype.vcproj: Add missing file. + +2021-12-02 Werner Lemberg + + * Version 2.11.1 released. + ========================== + + Tag sources with `VER-2-11-1'. + + * docs/VERSION.TXT: Add entry for version 2.11.1. + * docs/CHANGES, docs/release: Updated. + + * README, src/base/ftver.rc, builds/windows/vc2010/index.html, + builds/windows/visualc/index.html, builds/windows/visualce/index.html, + builds/wince/vc2005-ce/index.html, builds/wince/vc2008-ce/index.html, + docs/freetype-config.1: s/2.11.0/2.11.1/, s/2110/2111/. + + * include/freetype/freetype.h (FREETYPE_PATCH): Set to 1. + + * builds/unix/configure.raw (version_info): Set to 24:1:18. + * CMakeLists.txt (VERSION_PATCH): Set to 1. + + * builds/toplevel.mk (version_tag, CHANGELOG_SCRIPT): New variables. + (do-dist): Generate `ChangeLog` file with all commits since last release. + +2021-11-30 Alexei Podtelezhnikov + + [builds/windows] Improve debugging. + + * builds/windows/ftdebug.c (FT_Message, FT_Panic): Buffer output + and call `OutputDebugStringA` only if `IsDebuggerPresent`. + [_WIN32_WCE] (OutputDebugStringA): Implement the missing API. + +2021-11-29 Seigo Nonaka + + * src/base/ftobjs.c (FT_Request_Metrics): Fix build warning on Android. + + Use casts since `FT_USHORT_MAX` is unsigned short in bionic (libc used in + Android). + +2021-11-28 Alexei Podtelezhnikov + + * builds/windows/vc2010/freetype.vcxproj (DlgCopy): Minor tweak. + +2021-11-26 Alexei Podtelezhnikov + + * src/truetype/ttpload.c (tt_face_load_hdmx): Added comments. + +2021-11-26 Alexei Podtelezhnikov + + [truetype] Quietly reject out-of-spec `hdmx` tables. + + The `hdmx` table is optional and can be safely rejected without + an error if it does not follow specifications. The record size + must be equal to the number of glyphs + 2 + 32-bit padding. + + * src/truetype/ttpload.c (tt_face_load_hdmx): Thoroughly check + the record size and improve tracing. + +2021-11-23 Alexei Podtelezhnikov + + [truetype] Partly revert 5b626281. + + Fixes #1118. + + * src/truetype/ttpload.c (tt_face_load_hdmx): Do not assume that + `record_size` is rounded even though the records are padded. + +2021-11-23 Alexei Podtelezhnikov + + * builds/windows/vc2010/freetype.vcxproj (DlgCopy): Use transforms. + +2021-11-22 Werner Lemberg + + Update `CHANGES` files, other minor whitespace and documentation issues. + +2021-11-21 Werner Lemberg + + formats.txt: Add info about WOFF and WOFF2. + +2021-11-21 Werner Lemberg + + meson.build: Initialize `common_ldflags`. + +2021-11-21 Lukas Oberhuber <@lukaso> + + * meson.build: Fix compatibility version on MacOS. + + Fixes #1117. + +2021-11-21 Werner Lemberg + + * src/truetype/ttinterp.c (Ins_MD): Avoid `FT_ABS`. + + Reported as + + https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=38562 + +2021-11-20 Alexei Podtelezhnikov + + * include/freetype/fttypes.h (FT_MAKE_TAG): Remove the same casting. + +2021-11-20 Werner Lemberg + + [gxvalid] Fix minor compilation warning. + + * src/gxvalid/gxvmort5.c (gxv_mort_subtable_type5_subtable_setup): Declare + as static. + +2021-11-20 Werner Lemberg + + [smooth] Fix stand-alone compilation. + + * src/smooth/ftgrays.c (FT_Trace_Enable, FT_Trace_Disable)[STANDALONE_]: + Define. + +2021-11-20 Werner Lemberg + + Avoid undefined left-shifts. + + We really have to use double casts to avoid issues with C's and C++'s + signedness propagation rules in implicit casts. + + Reported as + + https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=41178 + https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=41182 + + * include/freetype/config/public-macros.h (FT_STATIC_CAST, + FT_REINTERPRET_CAST): Modify macro to take two arguments. + Update all callers. + (FT_STATIC_BYTE_CAST): New macro. + + * include/freetype/freetype.h (FT_ENC_TAG): Use `FT_STATIC_BYTE_CAST`. + * include/freetype/ftimage.h (FT_IMAGE_TAG): Ditto. + * include/freetype/fttypes.h (FT_MAKE_TAG): Ditto. + Use `FT_Tag` for casting. + + * src/ftraster/ftmisc.h (FT_MAKE_TAG): Removed, no longer needed. + (FT_STATIC_BYTE_CAST): New macro. + + * src/smooth/ftgrays.c (FT_STATIC_CAST): Replace with... + (FT_STATIC_BYTE_CAST): ... this. + +2021-11-18 Werner Lemberg + + Provide C++ versions for public macros with casts. + + Many FreeType clients use C++. However `g++ -Wold-style-cast` warns for + macros with C-style casts even for system header files; this also affects + directories included with `-isystem`. While this could be seen as a problem + with g++, the problem is more a philosophical one: Over the time, C and C++ + diverged more and more, and some features of C are no longer the 'right' + solution in C++. + + * include/freetype/config/public-macros.h (FT_STATIC_CAST, + FT_REINTERPRET_CAST): New macros. + + * include/freetype/freetype.h (FT_ENC_TAG, FT_LOAD_TARGET_, + FT_LOAD_TARGET_MODE): Use `FT_STATIC_CAST`. + Correctly handle negative 'signed char' input. + * include/freetype/ftimage.h (FT_IMAGE_TAG): Ditto. + * include/freetype/fttypes.h (FT_MAKE_TAG, FT_BOOL): Ditto. + * include/freetype/ftmodapi.h (FT_FACE_DRIVER_NAME): Use + `FT_REINTERPRET_CAST`. + + * src/smooth/ftgrays.c (FT_STATIC_CAST)[STANDALONE_]: New macro. + [!STANDALONE]: Include `FT_CONFIG_CONFIG_H`. + + Fixes #1116. + +2021-11-16 Werner Lemberg + + Fix clang++ warnings. + + * src/*: Initialize some variables to NULL. + +2021-11-16 Werner Lemberg + + [truetype] Updates for the forthcoming OpenType 1.9 standard (2/2). + + * src/truetype/ttgxvar.c (ft_var_load_item_variation_store): + s/shortDeltaCount/wordDeltaCount/ (as done in the specification, too). + Recognize new format and reject it for now. + +2021-11-16 Werner Lemberg + + [truetype] Updates for the forthcoming OpenType 1.9 standard (1/2). + + This is in preparation for implementing `DeltaSetIndexMap` format 1, which + is used by `COLR` v1 tables, and which allows 32bit indices. + + https://docs.microsoft.com/en-us/typography/opentype/otspec190/delta/otvarcommonformats_delta.html + + * src/truetype/ttgxvar.h (GX_DeltaSetIdxMapRec): Change type of `mapCount` + to `FT_ULong`. + + * src/truetype/ttgxvar.c (ft_var_load_delta_set_index_mapping): Add argument + for passing the table size; update caller. + Implement new format. + +2021-11-14 Werner Lemberg + + Fix clang warnings. + + * src/gxvalid/gxvcmmn.h (GXV_SET_ERR_IF_PARANOID): Use 'do' block. + * src/gxvalid/gxvmod.c (GXV_TABLE_LOAD, GXV_TABLE_VALIDATE): Ditto. + + * src/smooth/ftgrays.c (gray_convert_glyph): Add cast. + + * src/type1/t1gload.c (T1_Parse_Glyph_And_Get_Char_String): Remove cast. + * src/type1/t1load.c (read_binay_data): Use `FT_ULong` for `size` parameter. + (parse_subrs, parse_charstrings, parse_dict): Ditto; also add some casts. + +2021-11-13 Dominik Röttsches + + [sfnt] Avoid undefined shifts in `COLR` v1 paint parsing + + * src/sfnt/ttcolr.c (read_paint, tt_face_get_paint): Tighten shift + behavior by using multiplication, mostly using macros from ftcalc.h. + + Fixes: https://bugs.chromium.org/p/chromium/issues/detail?id=1269168 + +2021-11-13 Alexei Podtelezhnikov + + [builds/windows] Improve `DlgCopy` target. + + Fixes #1113. + + * builds/windows/vc2010/freetype.vcxproj: Run `DlgCopy` conditionally + and decouple it from `Build`. + +2021-11-12 Alexei Podtelezhnikov + + Explicitly define `FT_MSB` for Clang. + + * include/freetype/internal/ftcalc.h [__clang__] (FT_MSB): Updated. + +2021-11-10 Alexei Podtelezhnikov + + * src/truetype/ttgxvar.c (ft_var_to_normalized): Edge optimization. + +2021-11-10 Alexei Podtelezhnikov + + Additional `FT_MSB` macro definitions. + + Better macros for Windoes CE and ARM in general, based on !109 + from metarutaiga. + + * include/freetype/internal/ftcalc.h [_MSC_VER] (FT_MSB): Updated. + +2021-11-09 Alexei Podtelezhnikov + + [build/windows] Remove logging from default debug configurations. + + DLG is rather costly for performance and should be used judiciously. + This removes it from the default configurations but gives an example + how to enable it using the `UserDefines` property. + + * builds/windows/vc2010/freetype.vcxproj: Hide FT_DEBUG_LOGGING. + +2021-11-08 Werner Lemberg + + * src/sfnt/sfobjs.c (sfnt_open_font): Fix typo. + +2021-11-08 Werner Lemberg + + * src/gxvalid.*, src/otvalid.*: Fix `-Wformat` warnings. + +2021-11-08 Werner Lemberg + + [pshinter] Fix C++ compilation. + + * src/pshinter/pshalgo.c (psh_compute_dir): Fix type of `result`. + (psh_hint_table_find_strong_points): Add cast. + +2021-11-08 Werner Lemberg + + [sfnt] Reduce footprint if WOFF and WOFF2 support is not needed. + + Based on a patch from metarutaiga (MR !106). The gist of this commit is + that it doesn't make sense to support WOFF without compression (which would + be only possible in WOFF 1.0 anyway). + + * src/sfnt/sfobjs.c (sfnt_open_font): Guard WOFF code with + `FT_CONFIG_OPTION_USE_ZLIB` block. + Guard WOFF2 code with `FT_CONFIG_OPTION_USE_BROTLI` block. + + * src/sfnt/sfwoff.c, src/sfnt/sfwoff.h: Guard files with + `FT_CONFIG_OPTION_USE_ZLIB` blocks, not parts of the code. + + * src/sfnt/sfwoff2.c, src/sfnt/sfwoff2.h, src/sfnt/woff2tags.c, + src/sfnt/woff2tags.h: Guard files with `FT_CONFIG_OPTION_USE_BROTLI` blocks, + not parts of the code. + + Fixes #1111. + +2021-11-08 Werner Lemberg + + [truetype] Make trickyness checks depend on TT_USE_BYTECODE_INTERPRETER. + + Based on a patch from metarutaiga (MR !106). + + * src/truetype/ttobjs.c (tt_skip_pdffont_random_tag, + tt_check_trickyness_family, tt_synth_sfnt_checksum, tt_get_sfnt_checksum, + tt_check_trickyness_sfnt_ids, tt_check_trickyness): Put functions into a + `TT_USE_BYTECODE_INTERPRETER` block. + (tt_face_init): Put trickyness checks into a `TT_USE_BYTECODE_INTERPRETER` + block. + + Fixes #1111. + +2021-11-08 Alexei Podtelezhnikov + + * src/sfnt/ttload.c (tt_face_load_gasp): Fix a type mismatch warning. + +2021-11-07 Alexei Podtelezhnikov + + [dlg] Define DLG_STATIC explicitly. + + DLG_STATIC is intended to disable Windows DLL linking attributes. + It does not hurt to define it explicitly when we wrap DLG code. + This fixes tons of LNK4286 and C4273 warnings from MSVC if we + forget to define DLG_STATIC as a compiler option. + + * builds/windows/vc2010/freetype.vcxproj: Remove DLG_STATIC option. + * src/dlg/dlgwrap.c [FT_DEBUG_LOGGING]: Define DLG_STATIC. + * include/freetype/internal/ftdebug.h [FT_DEBUG_LOGGING]: Ditto. + +2021-11-07 Alexei Podtelezhnikov + + [dlg] Lighten up the inclusions. + + The DLG wrapper needs to know if FT_DEBUG_LOGGING is defined in + `ftoption.h`. It does not need entire FreeType. + + * src/dlg/dlgwrap.c: Include FT_CONFIG_OPTIONS_H directly. + +2021-11-07 Alexei Podtelezhnikov + + [truetype] Avoid some memory zeroing in variations. + + * src/truetype/ttgxvar.c (ft_var_readpackeddeltas, ft_var_load_avar, + ft_var_load_item_variation_store, ft_var_load_gvar): Use FT_QNEW_ARRAY + if memory immediately initialized or discarded otherwise. + +2021-11-05 Jany Belluz + + [truetype] Fix handling of packed deltas in Variation Fonts. + + * src/truetype/ttgxvar (ft_var_readpackeddeltas): Don't expect the number of + bytes used to encode the deltas to be higher than the number of encoded + values. The specification allows a very compact encoding; for example, a + list of 200 zeros can be encoded with just a couple of bytes. + + We now count the consumed bytes to make sure to not read more than expected. + +2021-11-04 Jany Belluz + + [truetype] Fix CVAR handling of tuples for all points. + + * src/truetype/ttgxvar (tt_face_vary_cvt): Function + `ft_var_readpackedpoints`, when it returns `ALL_POINTS`, also sets + `point_count` to value 0. However, the CVAR code was incorrectly expecting + that `point_count` would be set to match the length of the CVT table. + +2021-11-04 Jany Belluz + + * src/truetype/ttgxvar.c: Fix typos in macros that guard CVAR code. + +2021-11-04 Alexei Podtelezhnikov + + * docs/INSTALL: Mention Meson and MSBuild more prominently. + +2021-11-03 Gabor Kertesz + + [libpng] Update Meson wrap for win-arm64 + + 1.6.37-5 released patches for win-arm64 to successfully build + libpng with Meson: + https://github.com/mesonbuild/wrapdb/pull/205 + https://github.com/mesonbuild/wrapdb/pull/216 + + Updated by the following command: + meson wrap update libpng + + Tested on win-arm64 and x64. + +2021-11-03 Dominik Röttsches + + [sfnt] Clarify `COLR` v1 FT_Paint* format representations + + * include/freetype/ftcolor.h (FT_PaintLinearGradient, + FT_PaintRadialGradient, FT_PaintSweepGradient, FT_PaintTransform, + FT_PaintTranslate, FT_PaintScale, FT_PaintRotate, FT_PaintSkew): Clarify + 16.16 fixed point representation of struct fields. + * src/sfnt/ttcolr.c (read_paint): Shift coordinates for + FT_PaintLinearGradient, FT_PaintRadialGradient, FT_PaintSweepGradient + accordingly. + + Fixes: https://gitlab.freedesktop.org/freetype/freetype/-/issues/1110 + +2021-11-03 Alexei Podtelezhnikov + + [builds/windows] Let MSBuild handle DLG copy. + + * builds/windows/vc2010/freetype.vcxproj: Specify DlgCopy target. + * builds/windows/vc2010/script.bat: Deleted. + +2021-10-29 Alexei Podtelezhnikov + + * src/truetype/ttgload.c (load_truetype_glyph): Fix MSVC warning C4312. + +2021-10-29 Alexei Podtelezhnikov + + [builds/windows] Separate MSVC linker and librarian. + + MSVC uses LIB for static and LINK for dynamic libraries. They are + related but the former has much smaller set of options. + + * builds/windows/vc2010/freetype.vcxproj: Updated. + +2021-10-29 Alexei Podtelezhnikov + + [builds/windows] Revise MSVC linking optimizations. + + * builds/windows/vc2010/freetype.vcxproj: Optimize DLL linking only. + * builds/windows/visualc/freetype.dsp: Ditto. + * builds/windows/visualc/freetype.vcproj: Ditto. + +2021-10-28 Alexei Podtelezhnikov + + [woff] Optimize table tagging. + + * include/freetype/internal/wofftypes.h (WOFF_TableRec): Use + 32-bit tag. + * src/sfnt/sfwoff.c (woff_open_font): Use 32-bit tag. + +2021-10-28 Alexei Podtelezhnikov + + [woff2] Optimize table tagging. + + Fixes #1107. + + * include/freetype/internal/wofftypes.h (WOFF2_TableRec): Use + 32-bit tag. + * src/sfnt/sfwoff2.c (compare_tags, find_table, woff2_open_font): + Use 32-bit tag. + * src/sfnt/woff2tags.[ch] (woff2_known_tags): Use static storage and + return 32-bit tag. + +2021-10-26 Werner Lemberg + + Formatting. + +2021-10-26 Ben Wagner + + [mm] Tolerate missing Blend dictionary entries + + In a Multiple Master font, the Blend dictionary must contain valid + Private, FontInfo, and FontBBox. The current code will error if any of + these are present and invalid, but will not error and will provide + uninitialized data if the Blend dictionary exists but does not contain + one of these entries. This change reverts to the older behavior of + treating any missing entries as containing all zero data and not + returning an error. + + In the future it may be best to keep track of when these are actually + initialized and error if they are not. + + * src/type1/t1load.c (t1_allocate_blend): Zero initiailize. + +2021-10-26 Alexei Podtelezhnikov + + [builds/windows] Add MSVC linker optimazations. + + We continue to build static libraries with statically linked C run- + time and add options to optimize references. + + * builds/windows/vc2010/freetype.vcxproj: Sort entries, add options. + +2021-10-23 Alexei Podtelezhnikov + + * builds/windows/vc2010/freetype.vcxproj: Use MachineARM64. + +2021-10-22 Alexei Podtelezhnikov + + [builds/windows] Prioritize x64. + + * builds/windows/vc2010/freetype.sln: Sort entries. + +2021-10-22 Gabor Kertesz + + [builds/windows] Add ARM64 platform. + + * builds/windows/vc2010/freetype.sln: Updated + * builds/windows/vc2010/freetype.vcxproj: Updated. + * builds/windows/vc2010/freetype.vcxproj.filters: Minor fix. + +2021-10-21 Ben Wagner + + [mm] Delay setting blend weight and design position. + + Previously the `blend->weight_vector`, `blend->default_weight_vector`, + and `blend->design_pos` were set early to allocated but uninitialized + memory under the assumption that the memory would eventually be + initialized. However, it is possible that some of the required + keywords may not actually be present, leaving the memory uninitialized. + This is different from a present but invalid table, which would produce + an error. + + Reported as + https://bugs.chromium.org/p/chromium/issues/detail?id=1261762 + + * src/type1/t1load.c (t1_allocate_blend): Remove early allocation and + initialization. + (parse_blend_design_positions, parse_weight_vector): Parse into local + and assign to blend if valid. + (T1_Open_Face): Check that if a blend exists that it has the weight + vector and design positions. + +2021-10-21 Ben Wagner + + [cff] Commit vstore data and regions on allocation. + + The vstore->regionCount and vstore->dataCount were read directly + from the data. However, vstore->varRegionList and vstore->varData + would still contain uninitialized entries with uninitialized + pointers in the event of an error, leading to issues when attempting + to clean up. + + Reportd as + https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=40104 + + * src/cff/cffload.c (cff_vstore_load): Read the region and data counts + into locals and update the vstore counts immediately after each entry + becomes free-able. + +2021-10-20 Ben Wagner + + [sfnt] Delay setting gasp ranges and count until computed. + + Previously, the gasp.numRanges was set and gasp.gaspRanges was + allocated and assigned before a possible early exit if the frame could + not be entered. It is also possible that the gaspRanges allocation + could fail but the numRanges still be set to non-zero. In such cases + an error would be returned, but the face would have a gasp in an + inconsistent state which may still be accessed. + + Reported as + https://bugs.chromium.org/p/chromium/issues/detail?id=1261450 + + * src/sfnt/ttload.c (tt_face_load_gasp): Delay setting gasp.numRanges + and gasp.gaspRanges until after the ranges are initialized. + +2021-10-20 Ben Wagner + + [sfnt] Delay setting names and langTags until computed. + + Previously, the table->names and table->langTags fields were created + pointing to uninitialized memory and an early exit could happen if the + frame could not be entered. The caller would then be unable to properly + dispose of the memory as the string fields had not been initialized. + + Reported as + https://bugs.chromium.org/p/chromium/issues/detail?id=1261343 + + * src/sfnt/ttload.c (tt_face_load_name): delay setting table->langTags + and table->names until after the memory they will point to is fully + initialized. + +2021-10-20 Alexei Podtelezhnikov + + * tests/issue-1063/main.c: s/PATH_MAX/FILENAME_MAX/. + + Closes !97 for Windows by using a standard macro. + +2021-10-19 Werner Lemberg + + [bdf, cid, pfr, winfonts] Improve rejection of other font formats. + + This is mainly for better diagnostics of malformed fonts. + + * src/bdf/bdflib.c (_bfd_readstream): Stop font format testing if the first + input line is too long or doesn't end with `\r` or `\n`. + + * src/cid/cidparse.c (cid_parser_new): Don't handle too short input as an + error but as an unknown format. + + * src/pfr/pfrobjs.c (pfr_face_init): Ditto. + + * src/winfonts/winfnt.c (fnt_font_load, fnt_face_get_dll_font): Ditto. + +2021-10-19 Alexei Podtelezhnikov + + [pcf] Zero out the allocated properties. + + Fallout reported as + https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=40033 + + * src/pcf/pcfread.c (pcf_get_properties): Use FT_NEW_ARRAY and zero + out `properties` in case of failure. + +2021-10-18 Werner Lemberg + + configure: Use string comparison for directory inodes. + + Inode values might be larger than integers supported by the shell. + + Fixes #1105. + +2021-10-17 Alexei Podtelezhnikov + + * src/sfnt/ttload.c (tt_face_load_name): NULL-initialize langTag. + + Another attempt to fix fallout reported as + https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=40024 + +2021-10-17 Alexei Podtelezhnikov + + [bdf] Fix up user properties. + + Fallout reported as + https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=40027 + + * src/bdf/bdflib.c (_bdf_add_property): Cosmetic NULL. + (bdf_create_property): Limit allocations to customary signed + FT_Long and NULL-initialize unused storage. + (bdf_free_font): Do not free unused storage. + +2021-10-17 Alexei Podtelezhnikov + + * src/sfnt/ttload.c (tt_face_load_name): Accounting fix. + + Fallout reported as + https://crbug.com/40024 + +2021-10-16 Ben Wagner + + Fix typos in memory macros. + + FT_QNEW_ARRAY and FT_QRENEW_ARRAY were using the non-Q + FT_MEM_NEW_ARRAY and FT_MEM_RENEW_ARRAY. Change these to use the Q + versions. Also fix the one issue discovered in tt_face_load_name + where table->names is created with FT_QNEW_ARRAY but the extra + string member is not initialized to NULL. + + * include/freetype/internal/ftmemory.h (FT_Q(RE)NEW_ARRAY): + Use FT_MEM_Q(RE)NEW_ARRAY as needed. + + * src/sfnt/ttload.c (tt_face_load_name): Initialize `entry->string`. + +2021-10-15 Ben Wagner + + [truetype] Reload context after re-executing `prep`. + + When a different hinting mode from the current is selected, the `prep` table + must be re-executed with the new mode. After this happens the context must + be re-loaded in preparation for the glyph program to be run. + + Fixes #1104. + + * truetype/ttgload.c (tt_loader_init): Add call to `TT_Load_Context`. + +2021-10-15 Werner Lemberg + + [truetype] Minor documentation improvements. + +2021-10-14 Anurag Thakur + + Add clang build to linux CI + +2021-10-12 Anurag Thakur + + CI: Add macOS CI, including a clang build + +2021-10-12 Alexei Podtelezhnikov + + * src/cid/cidload.c (parse_fd_array): Protect against trancation. + +2021-10-12 Alexei Podtelezhnikov + + [type1] Revert to signed size for binary data. + + Recently introduced and reported as + https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=39838 + + * src/type1/t1load.c (read_binary_data): Reject negative size. + (parse_subrs, parse_charstrings): Use customary signed size. + +2021-10-11 Alexei Podtelezhnikov + + [psaux] Signedness revisions. + + Unsigned indexes are easier to check. + + * src/psaux/cffdecode.c (cff_decoder_parse_charstrings): Updated. + * src/psaux/psintrp.c (cf2_interpT2CharString): Ditto. + * src/psaux/t1decode.c (t1_decoder_parse_charstrings): Ditto. + * src/type1/t1load.c (read_binary_data): Ditto. + +2021-10-11 Alexei Podtelezhnikov + + [cid] Signedness revisions. + + Unsigned checks are simpler. + + * include/freetype/t1tables.h (CID_FaceInfoRec): Change to unsignd + `num_dicts`. + * src/cid/cidparse.h (CID_Parser): Change to unsigned `num_dict`. + + * src/cid/cidgload.c (cid_load_glyph): Updated. + * src/cid/cidload.c (cid_load_keyword, parse_fd_array, + parse_expansion_factor, parse_font_name, cid_read_subrs, + cid_face_open): Updated. + * src/cid/cidobjs.c (cid_face_done): Updated. + * src/cid/cidparse.c (cid_parser_new): Updated. + +2021-10-09 Alexei Podtelezhnikov + + * src/cid/cidload.c (cid_face_open): Streamline CIDCount check. + +2021-10-08 Alexei Podtelezhnikov + + * src/cid/cidload.c (cid_face_open): Streamline SubrCount check. + +2021-10-08 Alexei Podtelezhnikov + + * src/cid/cidgload.c (cid_load_glyph): Fortify incremental loading. + +2021-10-08 Alexei Podtelezhnikov + + Signedness revisions. + + This eliminates explicit casting by switching to unsigned fields. + The revisions mostly impact the handling of CID fonts. + + * include/freetype/fttypes.h (FT_Data): Change to unsigned `length`. + * include/freetype/t1tables.h (CID_FaceDictRec): Ditto for `sd_bytes`. + (CID_FaceInfoRec): Ditto for `gd_bytes` and `gd_bytes`. + * include/freetype/internal/tttypes.h (TT_LoaderRec): Ditto for + `byte_len`. + + * src/cid/cidgload.c (cid_load_glyph): Updated. + * src/cid/cidload.h (cid_get_offset): Update argument. + * src/cid/cidload.c (cid_get_offset, cid_read_subrs, cid_face_open): + Updated. + * src/cff/cffgload.c (cff_get_glyph_data, cff_free_glyph_data): + Updated. + * src/psaux/psft.c (cf2_getT1SeacComponent): Updated. + * src/truetype/ttgload.c (TT_Process_Composite_Glyph, + load_truetype_glyph): Updated. + +2021-10-07 Jan Alexander Steffens (heftig) + + meson.build (gen_docs): Use `current_source_dir` instead of `source_root`. + + These two are not equal when FreeType is used as a subproject, such as in + `freetype-demos`. In that case, `source_root` points at the root project, + causing the docs build to fail. + +2021-10-05 Alexei Podtelezhnikov + + * src/smooth/ftgrays.c (FT_DIV_MOD): Limit the ARM workaround. + +2021-10-05 Alexei Podtelezhnikov + + [builds/unix, builds/vms] Standardize `mmap` failure. + + * builds/unix/ftsystem.c (FT_Stream_Open): Check for MAP_FAILED. + * builds/vms/ftsystem.c (FT_Stream_Open): Ditto. + + This should cover https://savannah.nongnu.org/patch/?5909 as well. + +2021-10-05 Hugh McMaster + + autogen.sh: Only copy submodules if building from a git branch. + + `autogen.sh` fails if building from a standard source tarball. Firstly, git + expects to be called in a git repository, then `copy_submodule_files` + blindly attempts to copy files. + + Debian, Ubuntu, Linux Mint, and other derivatives all run `autogen.sh` + before compiling to regenerate build files. + + This patch ensures that various git commands are only called and 'dlg' files + are only copied if `autogen.sh` is called from a git repository. + +2021-10-05 Alexei Podtelezhnikov + + * include/freetype/internal/ftgloadr.h: Add missing header. + + Noticed by Jouk Jansen. + +2021-10-05 Alexei Podtelezhnikov + + [pshinter] Additional clean-ups. + + * src/pshinter/pshalgo.h (psh_hint_table_find_strong_points): Streamline code. + * src/pshinter/pshalgo.h (PSH_Glyph): Remove unused fields. + +2021-10-04 Alexei Podtelezhnikov + + [pshinter] More convenient direction definition. + + It is easier to check directions using flags than integer values. + + * src/pshinter/pshalgo.h (PSH_Dir): Redefine directions. + (PSH_PointRec): Use them as an enum type. + + * src/pshinter/pshalgo.c (psh_compute_dir): Modify return type. + (psh_glyph_init, psh_hint_table_find_strong_points, + psh_glyph_find_blue_points): Update users. + +2021-10-04 Alexei Podtelezhnikov + + [pshinter] Remove unnecessary check. + + * src/pshinter/pshalgo.c (psh_hint_table_find_strong_points): Do not + check if direction is defined before checking how. + +2021-10-02 AnuthaDev + + CI: Hardcode meson version to fix build failure on windows + +2021-10-01 Alexei Podtelezhnikov + + Additional `FT_MSB` macro definitions. + + * include/freetype/internal/ftcalc.h [__DECC,_CRAYC]: Use builtins + and intrinsics. + +2021-10-01 Alexei Podtelezhnikov + + * src/autofit/afhints.c (af_glyph_hints_reload): Decrease casting. + +2021-09-30 Alexei Podtelezhnikov + + * src/tools/apinames.c: Facilitate OpenVMS linker options. + +2021-09-29 Alexei Podtelezhnikov + + * src/winfonts/winfnt.c (FNT_Face_Init): Correct reallocation. + +2021-09-25 Alexei Podtelezhnikov + + [builds/unix] Do not use autoconf SIZEOF. + + * builds/unix/ftconfig.h.in [FT_USE_AUTOCONF_SIZEOF_TYPES]: Removed. + * builds/unix/configure.raw: Remove AC_CHECK_SIZEOF and update. + + After this commit, autoconf builds will fully rely on + rather than falling back on it if AC_CHECK_SIZEOF failed for some + reason. There is a risk that misconfigured cross-compilation might + have wrong headers. Note that Meson and CMake builds always relied on + for sizes and availability of integer types. + +2021-09-25 Alexei Podtelezhnikov + + Propagate sign when reading OFF3. + + Signed 24-bit values are extremely rare. FreeType only reads them in + PFR fonts with bitmap strikes conditionally. They have not been seen + in the known fonts. That is why this bug could never be discovered. + `FT_FRAME_OFF3` propagates sign correctly. + + * include/freetype/internal/ftstream.h (FT_PEEK_OFF3, FT_PEEK_OFF3_LE): + Propagate sign into 32-bit value. + (FT_GET_OFF3, FT_READ_OFF3): Needed fixing but removed as unused. + +2021-09-25 Alexei Podtelezhnikov + + [bdf] Simplify comment collection or lack thereof. + + BDF comments are neither actually collected nor retrieved. There is + no need to be fancy with delimiters. + + * src/bdf/bdflib.c (_add_bdf_comment): Delimit comments with zeros... + (bdf_load_font): ...and do not null-terminate comments additionally. + (_bdf_parse_glyphs): Check if comments are kept, which they are not. + (_bdf_parse_start): Minor clean up. + +2021-09-24 Alexei Podtelezhnikov + + Use NULL for pointers only. + + * src/bdf/bdflib.c (*): Code changes. + * include/freetype/freetype.h: Comments only. + * src/cff/cffload.c, src/cff/cffobjs.c: Ditto. + * src/winfonts/winfnt.c: Ditto. + +2021-09-23 Werner Lemberg + + Minor documentation fixes and improvements. + +2021-09-23 Alexei Podtelezhnikov + + Reference `fopen` in the docs. + +2021-09-23 Alexei Podtelezhnikov + + [bdf, pcf] Minor optimization. + + * src/pcf/pcfread.c (pcf_load_font): Do not call `FT_MulDiv` for a + small job. + * src/bdf/bdfdrivr.c (BDF_Face_Init): Ditto. + * src/bdf/bdflib.c (_bdf_parse_glyphs): Fix a comment. + +2021-09-22 Alexei Podtelezhnikov + + [base] Initialize stream memory earlier. + + With Windows memory management tracking heap, it is important to use + it during the stream opening fallback. In Unix, the argument is + unused, but it is better to set it correctly. + + * src/base/ftobjs.c (FT_Stream_New): Set memory before calling + `FT_Stream_Open`. + * builds/windows/ftsystem.c, builds/unix/ftsystem.c (FT_Stream_Open, + ft_close_stream_by_free): Call `ft_alloc` and `ft_free` with proper + memory argumment. + +2021-09-22 Alexei Podtelezhnikov + + [builds/windows] Revert back to `CreateFileA` only. + + Calling `CreateFileW` without making sure that the patname is really + `wchar_t` is a bad idea and can lead to unpredictable overreads. For + Windows CE, we impelemnt the missing API. + + Fixes #1098 and !76 again. + + * builds/windows/ftsystem.c (FT_Stream_Open): Call `CreateFileA`. + [_WIN32_WCE] (CreateFileA, FileSizeEx): Implement missing interfaces. + +2021-09-21 Alexei Podtelezhnikov + + * src/bdf/bdflib.c (_bdf_parse_{start,glyphs}): Use appropriate scanner. + +2021-09-21 Alexei Podtelezhnikov + + Minor. + +2021-09-20 Alexei Podtelezhnikov + + * src/cff/cffdrivr.c (cff_ps_get_font_{info,extra}): Use FT_QNEW. + +2021-09-18 Alexei Podtelezhnikov + + [cache] Minor clean-ups. + + * src/cache/ftccache.h (FTC_CACHE_LOOKUP_CMP): Remove parantheses. + * src/cache/ftccache.c (FTC_Cache_Lookup): Ditto. + (FTC_Cache_RemoveFaceID): Remove unnecessary variable. + +2021-09-17 Alexei Podtelezhnikov + + [builds/windows] Try both wide and narrow `CreateFile` + + Windows handles wchar_t* UTF-16 and char* ANSI (presently UTF-8) + filenames using alternative -A and -W API. We'll try them both + when opening a file. This means that you should not worry about + about conversions. + + Fixes #1098 and !76. + + * builds/windows/ftsystem.c (FT_Stream_Open): Call alternative + `CreateFile` in the case of failure. + +2021-09-17 Edwin Steiner + + [cff] Explicitly set StandardEncoding or ExpertEncoding offsets. + + Fixes #1097. + + * src/cff/cffload.c (cff_encoding_load): Set special offset values. + +2021-09-16 Alexei Podtelezhnikov + + [cache] Miscellaneous clean-ups. + + * src/cache/ftccache.c (ftc_get_top_node_for_hash, FTC_Cache_Clear): + Remove barely used variables. + (ftc_cache_add): Adjust casting. + * src/cache/ftccmap.c (FTC_CMapCache_Lookup): Remove casting. + * src/cache/ftcsbits.c (ftc_snode_load): Remove casting. + +2021-09-16 Alexei Podtelezhnikov + + * src/cff/cffload.c (cff_fd_select_get): Remove casting. + +2021-09-16 Alexei Podtelezhnikov + + * src/pcf/pcfread.c (pcf_read_TOC): Remove casting. + +2021-09-15 Alexei Podtelezhnikov + + Minor type adjustments. + + * src/cff/cffobjs.c (cff_face_init): Reduce casting. + * src/truetype/ttobjs.c (tt_size_ready_bytecode): Ditto. + * src/type1/t1load.c (T1_Set_MM_Design): Ditto. + +2021-09-15 Alexei Podtelezhnikov + + Replace boolean allocation macros with MEM ones. + + * src/base/ftbitmap.c (FT_Bitmap_Copy): Use MEM-macro. + * src/base/ftobjs.c (ft_glyphslot_alloc_bitmap): Ditto. + * src/bzip2/ftbzip2.c (ft_bzip2_alloc): Ditto. + * src/cache/ftccache.c (ftc_cache_init): Ditto + * src/gzip/ftgzip.c (ft_gzip_alloc): Ditto. + * src/psnames/psmodule.c (ps_unicodes_init): Ditto. + * src/sfnt/sfobjs.c (sfnt_load_face): Ditto. + * src/sfnt/ttload.c (tt_face_load_name): Ditto. + +2021-09-15 Alexei Podtelezhnikov + + [cache] Revert to some zeroing. + + * src/cache/ftccache.c (ftc_cache_init, ftc_cache_resize): Zero + `buckets` again to fix some crashes. + +2021-09-14 Alexei Podtelezhnikov + + * src/pshinter/pshrec.c (ps_mask_table_merge_all): Tweak loops. + + Fixes fallout from 731d0b685685 reported as + + https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=38685 + +2021-09-13 Alexei Podtelezhnikov + + [cff, pshinter] Clean up unsigned counters. + + Loops with unsigned decrement can be reliably stopped when the counter + wraps around after reaching zero. + + * src/cff/cffload.c (cff_charset_compute_cids): Use unsigned counter. + * src/pshinter/pshalgo.c (psh_hint_table_activate_mask): Ditto. + * src/pshinter/pshrec.c (ps_mask_table_merge): Ditto. + +2021-09-13 Alexei Podtelezhnikov + + [bdf, psnames, sfnt] Avoid some memory zeroing. + + * src/bdf/bdfdrivr.c (BDF_Face_Init): Use Q-macro. + * src/sfnt/sfobjs.c (sfnt_load_face): Ditto. + * src/psnames/psmodule.c (src/psnames/psmodule.c): Remove zero. + +2021-09-13 Alexei Podtelezhnikov + + * src/base/ftobjs.c (FT_CMap_New): Revert to zeroing. + + Fixes fallout from c1fa7aa2bc96, reported as + + https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=38641 + +2021-09-13 Alexei Podtelezhnikov + + [truetype] Clean up `exec` initialization. + + * src/truetype/ttinterp.c (Init_Context): Absorbed into... + (TT_New_Context): ... this function. + +2021-09-13 Alexei Podtelezhnikov + + [truetype] Avoid some memory zeroing. + + * src/truetype/ttgload.c (load_truetype_glyph): Use Q-macro. + * src/truetype/ttinterp.c (Update_Max): Ditto. + * src/truetype/ttpload.c (src/truetype/ttpload.c): Ditto. + +2021-09-13 Alexei Podtelezhnikov + + [base] Avoid some memory zeroing. + + * src/base/ftobjs.c (FT_New_Size, FT_CMap_New, FT_CMap_Done, + ft_open_face_internal, ft_open_face_internal): Use Q-macros. + +2021-09-13 Alexei Podtelezhnikov + + [cache, psaux] Remove zeros. + + * src/cache/ftcmru.c (FTC_MruList_New): Remove initialization. + * src/psaux/psstack.c (cf2_stack_init): Ditto. + +2021-09-12 Alexei Podtelezhnikov + + [cache] Avoid some memory zeroing. + + * src/cache/ftcmru.c (FTC_MruList_New): Use Q-macro. + * src/cache/ftcmanag.c (FTC_Manager_RegisterCache): Ditto. + * src/cache/ftccache.c (ftc_cache_init, ftc_cache_resize): Ditto. + +2021-09-11 Alexei Podtelezhnikov + + * src/cache/ftcmanag.c (FTC_Manager_New): Add missing zero. + + Fixes fall out from a7b199d081e7. + +2021-09-10 Alexei Podtelezhnikov + + [truetype] Tweak `hdmx` checking. + + Fixes #1096. + + * src/truetype/ttpload.c (tt_face_load_hdmx): Account for padding. + +2021-09-10 Alexei Podtelezhnikov + + [truetype] Tweak `loca` clamping. + + Fixes #1095. + + * src/truetype/ttpload.c (tt_face_load_loca): Fix up clamping. + * include/freetype/internal/tttypes.h (TT_Face): Correct docs. + +2021-09-08 Alexei Podtelezhnikov + + Fortify memory debugging (cont'd). + + * src/base/ftdbgmem.c (FT_DumpMemory): Check for active debugger. + (ft_mem_table_destroy): Move `FT_DumpMemory` call from here... + (ft_mem_debug_done): ... to here. + +2021-09-08 Alexei Podtelezhnikov + + Fortify memory debugging. + + These changes are neccessary to properly recover `memory->user` that + holds the Windows heap handle now. + + * src/base/ftdbgmem.c (ft_mem_debug_init): Handle all table allocations, + initializations, and sizing instead of... + (ft_mem_table_new): ... this function removed. + (ft_mem_debug_done): Better check for the active debugger and free the + debugger table here instead of... + (ft_mem_table_destroy): ... here. + +2021-09-08 Werner Lemberg + + src/tools/ftrandom/ftrandom.c (_XOPEN_SOURCE): Set to 600. + + This allows C99 compilation on Solaris. + + Problem reported by Mojca Miklavec. + +2021-09-07 Alexei Podtelezhnikov + + [builds/windows] Use native memory allocation API. + + * builds/windows/ftsystem.c (ft_alloc, ft_realloc, ft_free): + Wrap HeapAlloc, HeapReAlloc, and HeapFree. + (FT_New_Memory): Set the heap handle. + +2021-09-07 Werner Lemberg + + [dlg] Synchronize with upstream. + + * src/dlg/dlgwrap.c (_XOPEN_SOURCE): Set to 600. + + Fixes #1093. + +2021-09-04 Alexei Podtelezhnikov + + Cosmetic zeros. + +2021-09-03 Alexei Podtelezhnikov + + * src/bdf/bdflib.c (_bdf_parse_start): Keep parser memory. + +2021-09-03 Werner Lemberg + + autogen.sh: Make it work with old Solaris 10 shell. + +2021-09-03 Alexei Podtelezhnikov + + [smooth, raster, sdf] Clean up initialization calls. + + * src/raster/ftraster.c (ft_black_init): Removed. + (ft_black_new): Clean up. + * src/sdf/ftbsdf.c (bsdf_raster_new): Ditto. + * src/sdf/ftsdf.c (sdf_raster_new): Ditto. + * src/smooth/ftgrays.c (gray_raster_new): Ditto. + +2021-09-03 Alexei Podtelezhnikov + + * src/cache/ftcmanag.c (FTC_Manager_New): Avoid some zeroing. + +2021-09-03 Alexei Podtelezhnikov + + * src/bdf/bdflib.c (bdf_load_font): Remove memory shuffling. + +2021-09-03 Alexei Podtelezhnikov + + Cosmetic zeros. + +2021-09-02 Alexei Podtelezhnikov + + [base] Clean up stream reading. + + * src/base/ftstream.c (FT_Stream_ReadUShort, FT_Stream_ReadUOffset, + FT_Stream_ReadULong and their LE variants): Remove unnecessary + initialization and slightly refactor. + (FT_Stream_GetByte, FT_Stream_ReadByte): Rename to return unsigned + value and align with sister functions. + + * include/freetype/internal/ftstream.h (FT_Stream_GetByte, + FT_Stream_ReadByte): Update prototypes and caller macros. + +2021-09-02 Alexei Podtelezhnikov + + s/0/NULL/ where appropriate. + +2021-08-30 Alexei Podtelezhnikov + + * builds/windows/ftsystem.c (FT_Stream_Open): Fix double-close. + +2021-08-30 Alexei Podtelezhnikov + + [smooth] Reduce shift in multiply-shift optimization. + + * src/smooth/ftgrays.c (FT_UDIVPREP, FT_UDIV): Reduce shift. + + Smaller shifts that keep the division operands of FT_UDIVPREP within + 32 bits result in slightly faster divisions, which is noticeable in + the overall performance. The loss of precision is tolerable until the + divisors (the components dx and dy) approach 32 - PIXEL_BITS. With + PIXEL_BITS = 8, this corresponds to 65,000 pixels or the bitmap size + that we refuse to render anyway. + + Using `ftbench -p -s60 -t5 -bc timesi.ttf`, + + Before: 8.52 us/op + After: 8.32 us/op + +2021-08-28 Werner Lemberg + + [truetype] Fix compilation if !TT_CONFIG_OPTION_BYTECODE_INTERPRETER. + + * src/truetype/ttgxvar.c (tt_cvt_ready_iterator): Compile function + conditionally. + (tt_face_vary_cvt) [!TT_CONFIG_OPTION_BYTECODE_INTERPRETER]: Add code. + + Fixes #1091. + +2021-08-27 Alexei Podtelezhnikov + + [builds/windows] Revise SSE2 settings. + + * builds/windows/vc2010/freetype.vcxproj [x64]: Remove explicit SSE2. + * builds/windows/visualc/freetype.vcproj [Win32]: Add explicit SSE2. + +2021-08-27 Ben Wagner + + [smooth] Detect SSE2 with MSVC for x86 + + MSVC does not set `__SSE2__`. Instead one must check whether `_M_IX86_FP` is + defined and greater than or equal to 2. + + * src/smooth/ftgrays.c (FT_SSE2): New macro. + Use it where appropriate. + +2021-08-26 Alexei Podtelezhnikov + + Expand comment (cont'd). + +2021-08-26 Alexei Podtelezhnikov + + Expand comment. + +2021-08-24 Alexei Podtelezhnikov + + * src/smooth/ftgrays.c (gray_render_conic): Refactor redundancy. + +2021-08-24 suzuki toshiya + + [truetype] Fix for the family name shorter than 8 characters. + + * src/truetype/ttobjs.c (tt_skip_pdffont_random_tag): + If the family name to be checked is shorter than 8 characters, + do not check its syntax. + +2021-08-24 suzuki toshiya + + [truetype] Simplify `trick_names'. + + * src/truetype/ttobjs.c (tt_check_trickyness_family): For the case + that the beginning part of a long tricky family name is already + registered as another tricky family name, no need to double-check + the longer one. Such long tricky family names are removed from + the `trick_names'. + +2021-08-24 suzuki toshiya + + [truetype] Add 2 tricky font names. + + Additional fix for the issue #1087. + + * src/truetype/ttobjs.c (tt_check_trickyness_family): Add 2 tricky + font names reported in #1087. + +2021-08-24 suzuki toshiya + + [truetype] New function to skip the randomization tag. + + * src/truetype/ttobjs.c (tt_skip_pdffont_random_tag): + New function to skip the randomization tag in the names of the + fonts embedded in a PDF. It is used by tt_check_trickyness_family(), + to keep from mistaking "DLC" in the randomization tag as a + tricky font name. See discussion in: + + https://lists.nongnu.org/archive/html/freetype-devel/2021-02/msg00002.html + + For technical detail about the randomization tag, please find + PDF Reference 5.5.3 "Font Subsets". Thanks to Justyna Wawrzynska + for pointing out the issue caused by the randomization tag. + +2021-08-24 suzuki toshiya + + [truetype] Add checksums for 2 tricky fonts. + + Thanks to Ting717 for providing sample PDF. Fixes #1087. + + * src/truetype/ttobjs.c (tt_check_trickyness_sfnt_ids): Add + checksums for 2 tricky fonts `DFHei-Bd-WIN-HK-BF' and + `DFMing-Md-WIN-HK-BF'. + +2021-08-23 Alexei Podtelezhnikov + + Whitespace formatting. + +2021-08-22 Alexei Podtelezhnikov + + Decorate const arguments. + + * src/base/ftglyph.c (FT_Glyph_Transform, FT_Glyph_To_Bitmap): Do it. + * include/freetype/ftglyph.h (FT_Glyph_Transform, FT_Glyph_To_Bitmap): + Do it. + +2021-08-21 Alexei Podtelezhnikov + + [smooth] Clean up the null cell usage. + + Put the null cell at the end of the pool and store it explicitly so that + we can use it as both the limit and the dumpster. + + * src/smooth/ftgrays.c (gray_TWorker): Store the last `cell_null` and + remove unnecesary fields. + (NULL_CELL_PTR, CELL_IS_NULL): Remove in favor of explicit `cell_null`. + (gray_dump_cells, gray_set_cell, gray_sweep{,_direct}): Update callers. + (gray_convert_glyph_inner): Trace remaining cells (oh well). + (gray_convert_glyph): Set up `cell_null` and slightly improve the pool + management. + +2021-08-20 Alexei Podtelezhnikov + + [base] Restore quiet no-op rendering of bitmap glyphs. + + Fixes #1076. + + * src/base/ftobjs.c (FT_Render_Glyph_Internal): Discard an error when + rendering a bitmap glyph. + +2021-08-20 Alexei Podtelezhnikov + + [smooth] Fortify 64-bit algorithm. + + * src/smooth/ftgrays.c (FT_UDIVPREP, FT_UDIV): s/long/FT_Int64/ and + s/unsigned long/FT_UInt64/. + (gray_render_line): Adjust a critical variable type. + +2021-08-20 Carlo Bramini + + * builds/windows/ftsystem.c (FT_Stream_Open): Support legacy Windows. + +2021-08-20 Alexei Podtelezhnikov + + Determine `long long` availability based on its size. + + MSVC, for example, used `long long` even without full C99 support. + + * include/freetype/config/ftstdlib.h: Check if `long long` limits are + defined in . + * include/freetype/config/integer-types.h: Check `long long` size and + use it to typedef FT_Int64. + +2021-08-19 Dominik Röttsches + + [sfnt] Fix format expectation for `COLR` v1 ClipList + + * src/sfnt/ttcolr.c (tt_face_get_color_glyph_clipbox): Change ClipList + format expectation to 1 instead of 0 to make it compliant with the + latest spec. + +2021-08-19 Alexei Podtelezhnikov + + Readily use `long long` as a 64-bit type in C99 mode. + + * include/freetype/config/integer-types.h (FT_INT64): + FT_CONFIG_OPTION_FORCE_INT64 is no longer required to use `long long`. + +2021-08-19 Alexei Podtelezhnikov + + Use FT_INT64 instead of FT_LONG64. + + * include/freetype/config/integer-types.h: Remove synonymous FT_LONG64. + * include/freetype/internal/ftcalc.h: s/FT_LONG64/FT_INT64/. + * src/base/ftcalc.c: Ditto. + * src/base/fttrigon.c: Ditto. + * src/smooth/ftgrays.c: Ditto. + +2021-08-18 Alexei Podtelezhnikov + + [builds/windows] Do not set CharacterSet for VC++. + + * builds/windows/vc2010/freetype.vcxproj: s/Unicode/NotSet/. + * builds/windows/visualc/freetype.vcproj: s/"1"/"0"/. + +2021-08-18 Werner Lemberg + + * src/sdf/ftsdf.c (get_control_box): Fix compiler warning. + +2021-08-18 Werner Lemberg + + [base] Fix ppem size overflow. + + Fixes #1086. + + * src/base/ftobjs.c (FT_Request_Metrics): Add return value. + Check whether ppem values fit into unsigned short values. + (FT_Request_Size): Updated. + + * include/freetype/internal/ftobjs.h: Updated. + + * src/cff/cffobjs.c (cff_size_request), src/cid/cidobjs.c + (cid_size_request), src/truetype/ttdriver.c (tt_size_request), + src/type1/t1objs.c (T1_Size_Request): Updated. + +2021-08-18 Alexei Podtelezhnikov + + * builds/windows/ftsystem.c (FT_Stream_Open): Cast to remove warning. + +2021-08-18 Alexei Podtelezhnikov + + * builds/windows/ftsystem.c (FT_Stream_Open): Support UNICODE compilation. + +2021-08-09 Werner Lemberg + + * src/sfnt/ttcolr.c (tt_face_get_color_glyph_clipbox): Minor fix. + +2021-08-09 Dominik Röttsches + + [sfnt] Add missing blend mode 'plus' to 'COLR' v1. + + * include/freetype/ftcolor.h (FT_Composite_Mode): Add missing blend mode + 'plus' after it was added to the spec. + +2021-08-08 Werner Lemberg + + include/freetype/freetype.h (FT_Encoding): Improve documentation. + + Based on a suggestion by Antony Lee . + +2021-08-07 Werner Lemberg + + [smooth] Avoid integer overflow. + + Reported as + + https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=36243 + + * src/smooth/ftgrays.c(ADD_LONG, SUB_LONG, MUL_LONG, NEG_LONG) + [STANDALONE_]: Removed, unused. + (ADD_INT) [STANDALONE_]: New macro. + (FT_INTEGRATE): Use ADD_INT. + +2021-08-07 Dominik Röttsches + + [sfnt] Add API for retrieving a 'COLR' v1 'ClipBox' table. + + The optional 'COLR' v1 glyph-specific clip box helps upstream graphics + libraries allocate a sufficiently large bitmap for a glyph without having to + traverse the glyph graph for that. See + + https://github.com/googlefonts/colr-gradients-spec/issues/251 + + for background on the introduction of this specification change. + + * include/freetype/ftcolor.h (FT_ClipBox): New structure. + (FT_Get_Color_Glyph_ClipBox): New function declaration. + + * include/freetype/internal/sfnt.h (TT_Get_Color_Glyph_ClipBox_Func): + New function type. + (SFNT_Interface, FT_DEFINE_SFNT_INTERFACE): Use it. + + * src/base/ftobjs.c (FT_Get_Color_Glyph_ClipBox): New function to link API + with SFNT implementation. + + * src/sfnt/sfdriver.c (sfnt_interface): Updated. + * src/sfnt/ttcolr.c (Colr): New field `clip_list`. + (tt_face_load_colr): Parse global clip list offset. + (tt_face_get_color_glyph_clipbox): New function to find the clip box for a + glyph id from the clip list array. + * src/sfnt/ttcolr.h: Updated. + +2021-08-06 Werner Lemberg + + [smooth] Fix left shifts of negative numbers. + + Reported as + + https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=36241 + + * src/smooth/ftgrays.c (LEFT_SHIFT): New macro. + (gray_render_conic) [BEZIER_USE_DDA]: Use it. + +2021-08-02 Werner Lemberg + + * meson.build: Fix zlib support. + + This commit synchronizes zlib support with both autotools and cmake: If no + external zlib is found (or intentionally disabled on the command line), use + the internal zlib by undefining `FT_CONFIG_OPTION_SYSTEM_ZLIB` without + modifying `FT_CONFIG_OPTION_USE_ZLIB`. + + Also improve summary output. + + Problem reported by Moazin. + +2021-08-02 Anuj Verma + + [sdf] Fix out-of-range-access. + + * src/sdf/ftbsdf.c (first_pass, second_pass): Fix range during forward pass. + Otherwise the index goes out of range for the last column. + + Fixes issue #1077. + +2021-08-02 Anuj Verma + + Fix invalid memory access in `bsdf` rasterizer. + + Do not generate SDF from bitmap if the `FT_GLYPH_OWN_BITMAP` flag is not + set. In some cases the bitmap buffer is freed but still points to a valid + address; to handle those cases check the flag before accessing the memory. + + * src/sdf/ftsdfrend.c (ft_bsdf_render): Handle the above case. + Also, return an error message if the bitmap's rows/pitch is invalid, + otherwise `slot->buffer` might be assigned to some invalid memory location. + (ft_sdf_render): Same as above. + Plus, move the outline back to original state after rasterization and not if + any error occurs. + +2021-07-29 Heiko Becker + + * meson.build: Honor `--includedir` instead of hard-coding 'include'. + +2021-07-29 Werner Lemberg + + src/sfnt/ttcolr.c: Minor formatting. + +2021-07-29 Dominik Röttsches + + [sfnt] 'COLR' v1 PaintSweepGradient spec update + + * src/sfnt/ttcolr.c (read_paint): PaintSweepGradient follows other + spec changes and now has the angles specified as F2DOT14, reflect + that in the implementation. + * include/freetype/ftcolor.h (FT_PaintSweepGradient): Update + documentation. + +2021-07-29 Dominik Röttsches + + [sfnt] Retrieve affine matrix from offset in 'COLR' v1 parsing. + + * src/sfnt/ttcolr.c (read_paint): Implement spec change where + affine transform matrix is now referenced by offset instead of + being placed inline in the PaintTransform table. + +2021-07-29 Dominik Röttsches + + [sfnt] 'COLR' v1 PaintSkew related spec updates + + * src/sfnt/ttcolr.c (read_paint): Implement spec changes around + PaintSkew, PaintSkewAroundCenter. Update parsing to read shorter + values as changed in the spec. + * include/freetype/ftcolor.h (FT_PaintSkew): Update documentation. + +2021-07-29 Dominik Röttsches + + [sfnt] PaintRotate/PaintRotateAroundCenter spec updates + + * src/sfnt/ttcolr.c (read_paint): Implement spec change where + PaintRotate and PaintRotateAroundCenter were split for a more + compact format definition. Update parsing to read shorter values + as changed in the spec. + * include/freetype/ftcolor.h (FT_PaintRotate): Update documentation. + +2021-07-29 Dominik Röttsches + + [sfnt] 'COLR' v1 PaintTranslate and PaintScale precision + + * src/sfnt/ttcolr.c (read_paint): Implement spec changes in + PaintTranslate and PaintScale and friends. Update parsing to read + new shorter values. + +2021-07-29 AnuthaDev + + README.git: Add Code of Conduct. + +2021-07-25 Werner Lemberg + + ChangeLog housekeeping. + + Archive old `ChangeLog` file. + + We no longer write ChangeLog entries manually; instead, the file will be + created from commit messages (which should be formatted in GNU's ChangeLog + style) by a call to + + gitlog-to-changelog --format='%B%n' + + or something similar (this script is part of the 'gnulib' repository). + +2021-07-24 Werner Lemberg + + Fix some `cppcheck` warnings. + + * src/bzip2/ftbzip2.c (ft_bzip2_file_skip_output), src/gzip/ftgzip.c + (ft_gzip_file_skip_output): Reduce scope of `delta`. + + * src/psaux/psintrp.c, src/psaux/psintrp.h (cf2_interpT2CharString): Add + `const` to `buf` parameter. + + * src/raster/ftraster.c (DelOld): Add `const` to `profile` parameter. + (Vertical_Sweep_Span): Reduce scope of `target`. + (FT_Outline_Get_CBox): Reduce scope of `xMin`, `xMax`, `yMin`, `yMax`. + + * src/smooth/ftgrays.c (gray_render_conic): Reduce scope of `split`. + (gray_sweep, gray_sweep_direct): Reduce scope of `area`. + + * src/tools/apinames.c (names_dump) : Reduce scope of + `temp`. + +2021-07-24 AnuthaDev + + * .gitlab-ci.yml: Fixed cmake build, using correct options. + +2021-07-24 AnuthaDev + + * CMakeLists.txt: Make `cmake` handle disabled dependencies correctly. + + Include 'CMakeDependentOption'. + + Replace `FT_WITH_XXX` options with `FT_DISABLE_XXX` and `FT_REQUIRE_XXX` + pairs. Update option logic accordingly. + + Fixes #1066. + +2021-07-24 Ben Wagner + + [autofit] Split `afwrtsys.h`. + + The header file `afwrtsys.h` has two distinct functions: to include the + required writing system headers and also to generate code for each writing + system. At each current use site only one or the other is used, with + various macro trickery selecting one or the other. Split this header into + `afws-decl.h` for the required writing system declarations and `afws-iter.h` + for iterating over the writing systems to generate code. + + The motivation for this change is that the Visual C++ compiler treats the + standard include guard idiom like `#pragma once` 'if no non-comment code or + preprocessor directive comes before or after the standard form of the + idiom'. It appears to check this after macro expansion, so if + `WRITING_SYSTEM` expands to empty the bottom of `afwrtsys.h` is empty and + looks like the standard include guard idiom which is treated like `#pragma + once`, so subsequent inclusion of `afwrtsys.h` is elided. + + Fixes #1075. + + * src/autofit/afglobal.c (af_writing_system_classes), src/autofit/aftypes.h + (AF_WritingSystem), src/autofit/rules.mk (AUTOF_DRV_H): Updated. + + * src/autofit/afwrtsys.h: Split into... + * src/autofit/afws-decl.h, src/autofit/afws-iter.h: New files. diff --git a/builtins/textcode_pdf2text-macosx/src/textcode_pdf2text/licenses/freetype/INSTALL_RECEIPT.json b/builtins/textcode_pdf2text-macosx/src/textcode_pdf2text/licenses/freetype/INSTALL_RECEIPT.json new file mode 100644 index 0000000..1f136d5 --- /dev/null +++ b/builtins/textcode_pdf2text-macosx/src/textcode_pdf2text/licenses/freetype/INSTALL_RECEIPT.json @@ -0,0 +1,50 @@ +{ + "homebrew_version": "4.6.11-62-gffdb66a", + "used_options": [], + "unused_options": [], + "built_as_bottle": true, + "poured_from_bottle": true, + "loaded_from_api": true, + "installed_as_dependency": true, + "installed_on_request": false, + "changed_files": [ + "bin/freetype-config", + "lib/pkgconfig/freetype2.pc" + ], + "time": 1758996911, + "source_modified_time": 1757589576, + "compiler": "clang", + "aliases": [ + "freetype2" + ], + "runtime_dependencies": [ + { + "full_name": "libpng", + "version": "1.6.50", + "revision": 0, + "bottle_rebuild": 0, + "pkg_version": "1.6.50", + "declared_directly": true + } + ], + "source": { + "spec": "stable", + "versions": { + "stable": "2.14.1", + "head": null, + "version_scheme": 0 + }, + "path": "/Users/van/Library/Caches/Homebrew/api/formula.jws.json", + "tap_git_head": "49b612d86a5672c1a7b52fe8add45ac9ad597960", + "tap": "homebrew/core" + }, + "arch": "arm64", + "built_on": { + "os": "Macintosh", + "os_version": "macOS 26", + "cpu_family": "dunno", + "xcode": "26.0", + "clt": "26.0.0.0.1.1756965055", + "preferred_perl": "5.34" + } +} \ No newline at end of file diff --git a/builtins/textcode_pdf2text-macosx/src/textcode_pdf2text/licenses/freetype/LICENSE.TXT b/builtins/textcode_pdf2text-macosx/src/textcode_pdf2text/licenses/freetype/LICENSE.TXT new file mode 100644 index 0000000..0f9df21 --- /dev/null +++ b/builtins/textcode_pdf2text-macosx/src/textcode_pdf2text/licenses/freetype/LICENSE.TXT @@ -0,0 +1,47 @@ +FREETYPE LICENSES +----------------- + +The FreeType 2 font engine is copyrighted work and cannot be used +legally without a software license. In order to make this project +usable to a vast majority of developers, we distribute it under two +mutually exclusive open-source licenses. + +This means that *you* must choose *one* of the two licenses described +below, then obey all its terms and conditions when using FreeType 2 in +any of your projects or products. + + - The FreeType License, found in the file `docs/FTL.TXT`, which is + similar to the original BSD license *with* an advertising clause + that forces you to explicitly cite the FreeType project in your + product's documentation. All details are in the license file. + This license is suited to products which don't use the GNU General + Public License. + + Note that this license is compatible to the GNU General Public + License version 3, but not version 2. + + - The GNU General Public License version 2, found in + `docs/GPLv2.TXT` (any later version can be used also), for + programs which already use the GPL. Note that the FTL is + incompatible with GPLv2 due to its advertisement clause. + +The contributed BDF and PCF drivers come with a license similar to +that of the X Window System. It is compatible to the above two +licenses (see files `src/bdf/README` and `src/pcf/README`). The same +holds for the source code files `src/base/fthash.c` and +`include/freetype/internal/fthash.h`; they were part of the BDF driver +in earlier FreeType versions. + +The gzip module uses the zlib license (see `src/gzip/zlib.h`) which +too is compatible to the above two licenses. + +The files `src/autofit/ft-hb-ft.c`, `src/autofit/ft-hb-decls.h`, +`src/autofit/ft-hb-types.h`, and `src/autofit/hb-script-list.h` +contain code taken (almost) verbatim from the HarfBuzz library, which +uses the 'Old MIT' license compatible to the above two licenses. + +The MD5 checksum support (only used for debugging in development +builds) is in the public domain. + + +--- end of LICENSE.TXT --- diff --git a/builtins/textcode_pdf2text-macosx/src/textcode_pdf2text/licenses/freetype/README b/builtins/textcode_pdf2text-macosx/src/textcode_pdf2text/licenses/freetype/README new file mode 100644 index 0000000..515e4d1 --- /dev/null +++ b/builtins/textcode_pdf2text-macosx/src/textcode_pdf2text/licenses/freetype/README @@ -0,0 +1,107 @@ +FreeType 2.14.1 +=============== + +Homepage: https://freetype.org + +FreeType is a freely available software library to render fonts. + +It is written in C, designed to be small, efficient, highly +customizable, and portable while capable of producing high-quality +output (glyph images) of most vector and bitmap font formats. + +Please read the `docs/CHANGES` file, it contains IMPORTANT +INFORMATION. + +Read the files `docs/INSTALL*` for installation instructions; see the +file `LICENSE.TXT` for the available licenses. + +For using FreeType's git repository instead of a distribution bundle, +please read file `README.git`. Note that you have to actually clone +the repository; using a snapshot will not work (in other words, don't +use gitlab's 'Download' button). + +The FreeType 2 API reference is located in directory `docs/reference`; +use the file `index.html` as the top entry point. [Please note that +currently the search function for locally installed documentation +doesn't work due to cross-site scripting issues.] + +Additional documentation is available as a separate package from our +sites. Go to + + https://download.savannah.gnu.org/releases/freetype/ + +and download one of the following files. + + freetype-doc-2.14.1.tar.xz + freetype-doc-2.14.1.tar.gz + ftdoc2141.zip + +To view the documentation online, go to + + https://freetype.org/freetype2/docs/ + + +Mailing Lists +------------- + +The preferred way of communication with the FreeType team is using +e-mail lists. + + general use and discussion: freetype@nongnu.org + engine internals, porting, etc.: freetype-devel@nongnu.org + announcements: freetype-announce@nongnu.org + git repository tracker: freetype-commit@nongnu.org + +The lists are moderated; see + + https://freetype.org/contact.html + +how to subscribe. + + +Bugs +---- + +Please submit bug reports at + + https://gitlab.freedesktop.org/freetype/freetype/-/issues + +Alternatively, you might report bugs by e-mail to +`freetype-devel@nongnu.org`. Don't forget to send a detailed +explanation of the problem -- there is nothing worse than receiving a +terse message that only says 'it doesn't work'. + + +Patches +------- + +For larger changes please provide merge requests at + + https://gitlab.freedesktop.org/freetype/freetype/-/merge_requests + +Alternatively, you can send patches to the `freetype-devel@nongnu.org` +mailing list -- and thank you in advance for your work on improving +FreeType! + +Details on the process can be found here: + + https://freetype.org/developer.html#patches + + +Enjoy! + + The FreeType Team + +---------------------------------------------------------------------- + +Copyright (C) 2006-2025 by +David Turner, Robert Wilhelm, and Werner Lemberg. + +This file is part of the FreeType project, and may only be used, +modified, and distributed under the terms of the FreeType project +license, LICENSE.TXT. By continuing to use, modify, or distribute +this file you indicate that you have read the license and understand +and accept it fully. + + +--- end of README --- diff --git a/builtins/textcode_pdf2text-macosx/src/textcode_pdf2text/licenses/gettext/AUTHORS b/builtins/textcode_pdf2text-macosx/src/textcode_pdf2text/licenses/gettext/AUTHORS new file mode 100644 index 0000000..76cf7ad --- /dev/null +++ b/builtins/textcode_pdf2text-macosx/src/textcode_pdf2text/licenses/gettext/AUTHORS @@ -0,0 +1,93 @@ +Authors of GNU gettext. + +The following contributions warranted legal paper exchanges with the +Free Software Foundation. Also see files ChangeLog and THANKS. + +GETTEXT Ulrich Drepper +Assigns program and future changes. + +GETTEXT Peter Miller +Assigns past and future changes. + +GETTEXT François Pinard +Assigns past and future changes. + +GETTEXT Ben Kasmin Bullock +Disclaims changes to manual. + +GETTEXT Paul Eggert +Assigns past and future changes. + +GETTEXT Bruno Haible +Assigns past and future changes. + +GETTEXT Tim Van Holder +Assigns past and future changes. +(No contributions so far.) + +GETTEXT Tommy Johansson +Assigns changes. (changed: xgettext.c, configure.in; added: x-java.[lh]) +(Contributions: support for Java.) + +GETTEXT Karl Eichwalder +Assigns past and future changes. +GETTEXT SuSE Linux AG 2002-07-03 +Disclaimer for Karl Eichwalder, in the past and for the next 5 years. +(Contributions to the manual and to the tests.) + +GETTEXT Alexandre Duret-Lutz +Assigns past and future changes. +(No contributions so far.) + +GETTEXT Guido Flohr +Assigns past and future changes. +GETTEXT Imperia Inc 2003-12-05 +Disclaimer for Guido Flohr, in the past and for the next 5 years. +(Contributions: support for Perl.) + +GETTEXT Michele Cicciotti alias KJK::Hyperion +Assigns past and future changes. +(Contributions to langprefs.c for Windows.) + +GETTEXT Noritada Kobayashi +Assigns past and future changes. +(Contributions to po-mode.) + +GETTEXT KO Myung-Hun +Assigns past and future changes. +(Contributions: support for OS/2.) + +GETTEXT Lubomir Remak +Assigns past and future changes. +(Contributions: support for Lua.) + +GETTEXT Daiki Ueno +Assigns past and future changes. + +GETTEXT Miguel Angel Arruga Vivas +Assigns past and future changes. +GETTEXT GMV Innovating Solutions S.L. +Disclaimer for Miguel Angel Arruga Vivas. + +GETTEXT FutureLAB, AG +Assigns past and future changes of Andreas Stricker. +(Contributions: support for JavaScript.) + +GETTEXT Roumen Iordanov Petrov +Assigns past and future changes. +(Contributions: tests fixes.) + +GETTEXT Philip Withnall +Assigns past and future changes. +(Contributions: support for AppData.) + +GETTEXT Pavel Raiskup +Assigns past and future changes. + +GETTEXT Sundeep Anand +Assigns past and future changes. +(No contributions so far.) + +GETTEXT John Darrington +Assigns past and future changes. +(No contributions so far.) diff --git a/builtins/textcode_pdf2text-macosx/src/textcode_pdf2text/licenses/gettext/COPYING b/builtins/textcode_pdf2text-macosx/src/textcode_pdf2text/licenses/gettext/COPYING new file mode 100644 index 0000000..e600086 --- /dev/null +++ b/builtins/textcode_pdf2text-macosx/src/textcode_pdf2text/licenses/gettext/COPYING @@ -0,0 +1,674 @@ + GNU GENERAL PUBLIC LICENSE + Version 3, 29 June 2007 + + Copyright (C) 2007 Free Software Foundation, Inc. + Everyone is permitted to copy and distribute verbatim copies + of this license document, but changing it is not allowed. + + Preamble + + The GNU General Public License is a free, copyleft license for +software and other kinds of works. + + The licenses for most software and other practical works are designed +to take away your freedom to share and change the works. By contrast, +the GNU General Public License is intended to guarantee your freedom to +share and change all versions of a program--to make sure it remains free +software for all its users. We, the Free Software Foundation, use the +GNU General Public License for most of our software; it applies also to +any other work released this way by its authors. You can apply it to +your programs, too. + + When we speak of free software, we are referring to freedom, not +price. Our General Public Licenses are designed to make sure that you +have the freedom to distribute copies of free software (and charge for +them if you wish), that you receive source code or can get it if you +want it, that you can change the software or use pieces of it in new +free programs, and that you know you can do these things. + + To protect your rights, we need to prevent others from denying you +these rights or asking you to surrender the rights. Therefore, you have +certain responsibilities if you distribute copies of the software, or if +you modify it: responsibilities to respect the freedom of others. + + For example, if you distribute copies of such a program, whether +gratis or for a fee, you must pass on to the recipients the same +freedoms that you received. You must make sure that they, too, receive +or can get the source code. And you must show them these terms so they +know their rights. + + Developers that use the GNU GPL protect your rights with two steps: +(1) assert copyright on the software, and (2) offer you this License +giving you legal permission to copy, distribute and/or modify it. + + For the developers' and authors' protection, the GPL clearly explains +that there is no warranty for this free software. For both users' and +authors' sake, the GPL requires that modified versions be marked as +changed, so that their problems will not be attributed erroneously to +authors of previous versions. + + Some devices are designed to deny users access to install or run +modified versions of the software inside them, although the manufacturer +can do so. This is fundamentally incompatible with the aim of +protecting users' freedom to change the software. The systematic +pattern of such abuse occurs in the area of products for individuals to +use, which is precisely where it is most unacceptable. Therefore, we +have designed this version of the GPL to prohibit the practice for those +products. If such problems arise substantially in other domains, we +stand ready to extend this provision to those domains in future versions +of the GPL, as needed to protect the freedom of users. + + Finally, every program is threatened constantly by software patents. +States should not allow patents to restrict development and use of +software on general-purpose computers, but in those that do, we wish to +avoid the special danger that patents applied to a free program could +make it effectively proprietary. To prevent this, the GPL assures that +patents cannot be used to render the program non-free. + + The precise terms and conditions for copying, distribution and +modification follow. + + TERMS AND CONDITIONS + + 0. Definitions. + + "This License" refers to version 3 of the GNU General Public License. + + "Copyright" also means copyright-like laws that apply to other kinds of +works, such as semiconductor masks. + + "The Program" refers to any copyrightable work licensed under this +License. Each licensee is addressed as "you". "Licensees" and +"recipients" may be individuals or organizations. + + To "modify" a work means to copy from or adapt all or part of the work +in a fashion requiring copyright permission, other than the making of an +exact copy. The resulting work is called a "modified version" of the +earlier work or a work "based on" the earlier work. + + A "covered work" means either the unmodified Program or a work based +on the Program. + + To "propagate" a work means to do anything with it that, without +permission, would make you directly or secondarily liable for +infringement under applicable copyright law, except executing it on a +computer or modifying a private copy. Propagation includes copying, +distribution (with or without modification), making available to the +public, and in some countries other activities as well. + + To "convey" a work means any kind of propagation that enables other +parties to make or receive copies. Mere interaction with a user through +a computer network, with no transfer of a copy, is not conveying. + + An interactive user interface displays "Appropriate Legal Notices" +to the extent that it includes a convenient and prominently visible +feature that (1) displays an appropriate copyright notice, and (2) +tells the user that there is no warranty for the work (except to the +extent that warranties are provided), that licensees may convey the +work under this License, and how to view a copy of this License. If +the interface presents a list of user commands or options, such as a +menu, a prominent item in the list meets this criterion. + + 1. Source Code. + + The "source code" for a work means the preferred form of the work +for making modifications to it. "Object code" means any non-source +form of a work. + + A "Standard Interface" means an interface that either is an official +standard defined by a recognized standards body, or, in the case of +interfaces specified for a particular programming language, one that +is widely used among developers working in that language. + + The "System Libraries" of an executable work include anything, other +than the work as a whole, that (a) is included in the normal form of +packaging a Major Component, but which is not part of that Major +Component, and (b) serves only to enable use of the work with that +Major Component, or to implement a Standard Interface for which an +implementation is available to the public in source code form. A +"Major Component", in this context, means a major essential component +(kernel, window system, and so on) of the specific operating system +(if any) on which the executable work runs, or a compiler used to +produce the work, or an object code interpreter used to run it. + + The "Corresponding Source" for a work in object code form means all +the source code needed to generate, install, and (for an executable +work) run the object code and to modify the work, including scripts to +control those activities. However, it does not include the work's +System Libraries, or general-purpose tools or generally available free +programs which are used unmodified in performing those activities but +which are not part of the work. For example, Corresponding Source +includes interface definition files associated with source files for +the work, and the source code for shared libraries and dynamically +linked subprograms that the work is specifically designed to require, +such as by intimate data communication or control flow between those +subprograms and other parts of the work. + + The Corresponding Source need not include anything that users +can regenerate automatically from other parts of the Corresponding +Source. + + The Corresponding Source for a work in source code form is that +same work. + + 2. Basic Permissions. + + All rights granted under this License are granted for the term of +copyright on the Program, and are irrevocable provided the stated +conditions are met. This License explicitly affirms your unlimited +permission to run the unmodified Program. The output from running a +covered work is covered by this License only if the output, given its +content, constitutes a covered work. This License acknowledges your +rights of fair use or other equivalent, as provided by copyright law. + + You may make, run and propagate covered works that you do not +convey, without conditions so long as your license otherwise remains +in force. You may convey covered works to others for the sole purpose +of having them make modifications exclusively for you, or provide you +with facilities for running those works, provided that you comply with +the terms of this License in conveying all material for which you do +not control copyright. Those thus making or running the covered works +for you must do so exclusively on your behalf, under your direction +and control, on terms that prohibit them from making any copies of +your copyrighted material outside their relationship with you. + + Conveying under any other circumstances is permitted solely under +the conditions stated below. Sublicensing is not allowed; section 10 +makes it unnecessary. + + 3. Protecting Users' Legal Rights From Anti-Circumvention Law. + + No covered work shall be deemed part of an effective technological +measure under any applicable law fulfilling obligations under article +11 of the WIPO copyright treaty adopted on 20 December 1996, or +similar laws prohibiting or restricting circumvention of such +measures. + + When you convey a covered work, you waive any legal power to forbid +circumvention of technological measures to the extent such circumvention +is effected by exercising rights under this License with respect to +the covered work, and you disclaim any intention to limit operation or +modification of the work as a means of enforcing, against the work's +users, your or third parties' legal rights to forbid circumvention of +technological measures. + + 4. Conveying Verbatim Copies. + + You may convey verbatim copies of the Program's source code as you +receive it, in any medium, provided that you conspicuously and +appropriately publish on each copy an appropriate copyright notice; +keep intact all notices stating that this License and any +non-permissive terms added in accord with section 7 apply to the code; +keep intact all notices of the absence of any warranty; and give all +recipients a copy of this License along with the Program. + + You may charge any price or no price for each copy that you convey, +and you may offer support or warranty protection for a fee. + + 5. Conveying Modified Source Versions. + + You may convey a work based on the Program, or the modifications to +produce it from the Program, in the form of source code under the +terms of section 4, provided that you also meet all of these conditions: + + a) The work must carry prominent notices stating that you modified + it, and giving a relevant date. + + b) The work must carry prominent notices stating that it is + released under this License and any conditions added under section + 7. This requirement modifies the requirement in section 4 to + "keep intact all notices". + + c) You must license the entire work, as a whole, under this + License to anyone who comes into possession of a copy. This + License will therefore apply, along with any applicable section 7 + additional terms, to the whole of the work, and all its parts, + regardless of how they are packaged. This License gives no + permission to license the work in any other way, but it does not + invalidate such permission if you have separately received it. + + d) If the work has interactive user interfaces, each must display + Appropriate Legal Notices; however, if the Program has interactive + interfaces that do not display Appropriate Legal Notices, your + work need not make them do so. + + A compilation of a covered work with other separate and independent +works, which are not by their nature extensions of the covered work, +and which are not combined with it such as to form a larger program, +in or on a volume of a storage or distribution medium, is called an +"aggregate" if the compilation and its resulting copyright are not +used to limit the access or legal rights of the compilation's users +beyond what the individual works permit. Inclusion of a covered work +in an aggregate does not cause this License to apply to the other +parts of the aggregate. + + 6. Conveying Non-Source Forms. + + You may convey a covered work in object code form under the terms +of sections 4 and 5, provided that you also convey the +machine-readable Corresponding Source under the terms of this License, +in one of these ways: + + a) Convey the object code in, or embodied in, a physical product + (including a physical distribution medium), accompanied by the + Corresponding Source fixed on a durable physical medium + customarily used for software interchange. + + b) Convey the object code in, or embodied in, a physical product + (including a physical distribution medium), accompanied by a + written offer, valid for at least three years and valid for as + long as you offer spare parts or customer support for that product + model, to give anyone who possesses the object code either (1) a + copy of the Corresponding Source for all the software in the + product that is covered by this License, on a durable physical + medium customarily used for software interchange, for a price no + more than your reasonable cost of physically performing this + conveying of source, or (2) access to copy the + Corresponding Source from a network server at no charge. + + c) Convey individual copies of the object code with a copy of the + written offer to provide the Corresponding Source. This + alternative is allowed only occasionally and noncommercially, and + only if you received the object code with such an offer, in accord + with subsection 6b. + + d) Convey the object code by offering access from a designated + place (gratis or for a charge), and offer equivalent access to the + Corresponding Source in the same way through the same place at no + further charge. You need not require recipients to copy the + Corresponding Source along with the object code. If the place to + copy the object code is a network server, the Corresponding Source + may be on a different server (operated by you or a third party) + that supports equivalent copying facilities, provided you maintain + clear directions next to the object code saying where to find the + Corresponding Source. Regardless of what server hosts the + Corresponding Source, you remain obligated to ensure that it is + available for as long as needed to satisfy these requirements. + + e) Convey the object code using peer-to-peer transmission, provided + you inform other peers where the object code and Corresponding + Source of the work are being offered to the general public at no + charge under subsection 6d. + + A separable portion of the object code, whose source code is excluded +from the Corresponding Source as a System Library, need not be +included in conveying the object code work. + + A "User Product" is either (1) a "consumer product", which means any +tangible personal property which is normally used for personal, family, +or household purposes, or (2) anything designed or sold for incorporation +into a dwelling. In determining whether a product is a consumer product, +doubtful cases shall be resolved in favor of coverage. For a particular +product received by a particular user, "normally used" refers to a +typical or common use of that class of product, regardless of the status +of the particular user or of the way in which the particular user +actually uses, or expects or is expected to use, the product. A product +is a consumer product regardless of whether the product has substantial +commercial, industrial or non-consumer uses, unless such uses represent +the only significant mode of use of the product. + + "Installation Information" for a User Product means any methods, +procedures, authorization keys, or other information required to install +and execute modified versions of a covered work in that User Product from +a modified version of its Corresponding Source. The information must +suffice to ensure that the continued functioning of the modified object +code is in no case prevented or interfered with solely because +modification has been made. + + If you convey an object code work under this section in, or with, or +specifically for use in, a User Product, and the conveying occurs as +part of a transaction in which the right of possession and use of the +User Product is transferred to the recipient in perpetuity or for a +fixed term (regardless of how the transaction is characterized), the +Corresponding Source conveyed under this section must be accompanied +by the Installation Information. But this requirement does not apply +if neither you nor any third party retains the ability to install +modified object code on the User Product (for example, the work has +been installed in ROM). + + The requirement to provide Installation Information does not include a +requirement to continue to provide support service, warranty, or updates +for a work that has been modified or installed by the recipient, or for +the User Product in which it has been modified or installed. Access to a +network may be denied when the modification itself materially and +adversely affects the operation of the network or violates the rules and +protocols for communication across the network. + + Corresponding Source conveyed, and Installation Information provided, +in accord with this section must be in a format that is publicly +documented (and with an implementation available to the public in +source code form), and must require no special password or key for +unpacking, reading or copying. + + 7. Additional Terms. + + "Additional permissions" are terms that supplement the terms of this +License by making exceptions from one or more of its conditions. +Additional permissions that are applicable to the entire Program shall +be treated as though they were included in this License, to the extent +that they are valid under applicable law. If additional permissions +apply only to part of the Program, that part may be used separately +under those permissions, but the entire Program remains governed by +this License without regard to the additional permissions. + + When you convey a copy of a covered work, you may at your option +remove any additional permissions from that copy, or from any part of +it. (Additional permissions may be written to require their own +removal in certain cases when you modify the work.) You may place +additional permissions on material, added by you to a covered work, +for which you have or can give appropriate copyright permission. + + Notwithstanding any other provision of this License, for material you +add to a covered work, you may (if authorized by the copyright holders of +that material) supplement the terms of this License with terms: + + a) Disclaiming warranty or limiting liability differently from the + terms of sections 15 and 16 of this License; or + + b) Requiring preservation of specified reasonable legal notices or + author attributions in that material or in the Appropriate Legal + Notices displayed by works containing it; or + + c) Prohibiting misrepresentation of the origin of that material, or + requiring that modified versions of such material be marked in + reasonable ways as different from the original version; or + + d) Limiting the use for publicity purposes of names of licensors or + authors of the material; or + + e) Declining to grant rights under trademark law for use of some + trade names, trademarks, or service marks; or + + f) Requiring indemnification of licensors and authors of that + material by anyone who conveys the material (or modified versions of + it) with contractual assumptions of liability to the recipient, for + any liability that these contractual assumptions directly impose on + those licensors and authors. + + All other non-permissive additional terms are considered "further +restrictions" within the meaning of section 10. If the Program as you +received it, or any part of it, contains a notice stating that it is +governed by this License along with a term that is a further +restriction, you may remove that term. If a license document contains +a further restriction but permits relicensing or conveying under this +License, you may add to a covered work material governed by the terms +of that license document, provided that the further restriction does +not survive such relicensing or conveying. + + If you add terms to a covered work in accord with this section, you +must place, in the relevant source files, a statement of the +additional terms that apply to those files, or a notice indicating +where to find the applicable terms. + + Additional terms, permissive or non-permissive, may be stated in the +form of a separately written license, or stated as exceptions; +the above requirements apply either way. + + 8. Termination. + + You may not propagate or modify a covered work except as expressly +provided under this License. Any attempt otherwise to propagate or +modify it is void, and will automatically terminate your rights under +this License (including any patent licenses granted under the third +paragraph of section 11). + + However, if you cease all violation of this License, then your +license from a particular copyright holder is reinstated (a) +provisionally, unless and until the copyright holder explicitly and +finally terminates your license, and (b) permanently, if the copyright +holder fails to notify you of the violation by some reasonable means +prior to 60 days after the cessation. + + Moreover, your license from a particular copyright holder is +reinstated permanently if the copyright holder notifies you of the +violation by some reasonable means, this is the first time you have +received notice of violation of this License (for any work) from that +copyright holder, and you cure the violation prior to 30 days after +your receipt of the notice. + + Termination of your rights under this section does not terminate the +licenses of parties who have received copies or rights from you under +this License. If your rights have been terminated and not permanently +reinstated, you do not qualify to receive new licenses for the same +material under section 10. + + 9. Acceptance Not Required for Having Copies. + + You are not required to accept this License in order to receive or +run a copy of the Program. Ancillary propagation of a covered work +occurring solely as a consequence of using peer-to-peer transmission +to receive a copy likewise does not require acceptance. However, +nothing other than this License grants you permission to propagate or +modify any covered work. These actions infringe copyright if you do +not accept this License. Therefore, by modifying or propagating a +covered work, you indicate your acceptance of this License to do so. + + 10. Automatic Licensing of Downstream Recipients. + + Each time you convey a covered work, the recipient automatically +receives a license from the original licensors, to run, modify and +propagate that work, subject to this License. You are not responsible +for enforcing compliance by third parties with this License. + + An "entity transaction" is a transaction transferring control of an +organization, or substantially all assets of one, or subdividing an +organization, or merging organizations. If propagation of a covered +work results from an entity transaction, each party to that +transaction who receives a copy of the work also receives whatever +licenses to the work the party's predecessor in interest had or could +give under the previous paragraph, plus a right to possession of the +Corresponding Source of the work from the predecessor in interest, if +the predecessor has it or can get it with reasonable efforts. + + You may not impose any further restrictions on the exercise of the +rights granted or affirmed under this License. For example, you may +not impose a license fee, royalty, or other charge for exercise of +rights granted under this License, and you may not initiate litigation +(including a cross-claim or counterclaim in a lawsuit) alleging that +any patent claim is infringed by making, using, selling, offering for +sale, or importing the Program or any portion of it. + + 11. Patents. + + A "contributor" is a copyright holder who authorizes use under this +License of the Program or a work on which the Program is based. The +work thus licensed is called the contributor's "contributor version". + + A contributor's "essential patent claims" are all patent claims +owned or controlled by the contributor, whether already acquired or +hereafter acquired, that would be infringed by some manner, permitted +by this License, of making, using, or selling its contributor version, +but do not include claims that would be infringed only as a +consequence of further modification of the contributor version. For +purposes of this definition, "control" includes the right to grant +patent sublicenses in a manner consistent with the requirements of +this License. + + Each contributor grants you a non-exclusive, worldwide, royalty-free +patent license under the contributor's essential patent claims, to +make, use, sell, offer for sale, import and otherwise run, modify and +propagate the contents of its contributor version. + + In the following three paragraphs, a "patent license" is any express +agreement or commitment, however denominated, not to enforce a patent +(such as an express permission to practice a patent or covenant not to +sue for patent infringement). To "grant" such a patent license to a +party means to make such an agreement or commitment not to enforce a +patent against the party. + + If you convey a covered work, knowingly relying on a patent license, +and the Corresponding Source of the work is not available for anyone +to copy, free of charge and under the terms of this License, through a +publicly available network server or other readily accessible means, +then you must either (1) cause the Corresponding Source to be so +available, or (2) arrange to deprive yourself of the benefit of the +patent license for this particular work, or (3) arrange, in a manner +consistent with the requirements of this License, to extend the patent +license to downstream recipients. "Knowingly relying" means you have +actual knowledge that, but for the patent license, your conveying the +covered work in a country, or your recipient's use of the covered work +in a country, would infringe one or more identifiable patents in that +country that you have reason to believe are valid. + + If, pursuant to or in connection with a single transaction or +arrangement, you convey, or propagate by procuring conveyance of, a +covered work, and grant a patent license to some of the parties +receiving the covered work authorizing them to use, propagate, modify +or convey a specific copy of the covered work, then the patent license +you grant is automatically extended to all recipients of the covered +work and works based on it. + + A patent license is "discriminatory" if it does not include within +the scope of its coverage, prohibits the exercise of, or is +conditioned on the non-exercise of one or more of the rights that are +specifically granted under this License. You may not convey a covered +work if you are a party to an arrangement with a third party that is +in the business of distributing software, under which you make payment +to the third party based on the extent of your activity of conveying +the work, and under which the third party grants, to any of the +parties who would receive the covered work from you, a discriminatory +patent license (a) in connection with copies of the covered work +conveyed by you (or copies made from those copies), or (b) primarily +for and in connection with specific products or compilations that +contain the covered work, unless you entered into that arrangement, +or that patent license was granted, prior to 28 March 2007. + + Nothing in this License shall be construed as excluding or limiting +any implied license or other defenses to infringement that may +otherwise be available to you under applicable patent law. + + 12. No Surrender of Others' Freedom. + + If conditions are imposed on you (whether by court order, agreement or +otherwise) that contradict the conditions of this License, they do not +excuse you from the conditions of this License. If you cannot convey a +covered work so as to satisfy simultaneously your obligations under this +License and any other pertinent obligations, then as a consequence you may +not convey it at all. For example, if you agree to terms that obligate you +to collect a royalty for further conveying from those to whom you convey +the Program, the only way you could satisfy both those terms and this +License would be to refrain entirely from conveying the Program. + + 13. Use with the GNU Affero General Public License. + + Notwithstanding any other provision of this License, you have +permission to link or combine any covered work with a work licensed +under version 3 of the GNU Affero General Public License into a single +combined work, and to convey the resulting work. The terms of this +License will continue to apply to the part which is the covered work, +but the special requirements of the GNU Affero General Public License, +section 13, concerning interaction through a network will apply to the +combination as such. + + 14. Revised Versions of this License. + + The Free Software Foundation may publish revised and/or new versions of +the GNU General Public License from time to time. Such new versions will +be similar in spirit to the present version, but may differ in detail to +address new problems or concerns. + + Each version is given a distinguishing version number. If the +Program specifies that a certain numbered version of the GNU General +Public License "or any later version" applies to it, you have the +option of following the terms and conditions either of that numbered +version or of any later version published by the Free Software +Foundation. If the Program does not specify a version number of the +GNU General Public License, you may choose any version ever published +by the Free Software Foundation. + + If the Program specifies that a proxy can decide which future +versions of the GNU General Public License can be used, that proxy's +public statement of acceptance of a version permanently authorizes you +to choose that version for the Program. + + Later license versions may give you additional or different +permissions. However, no additional obligations are imposed on any +author or copyright holder as a result of your choosing to follow a +later version. + + 15. Disclaimer of Warranty. + + THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY +APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT +HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY +OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, +THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR +PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM +IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF +ALL NECESSARY SERVICING, REPAIR OR CORRECTION. + + 16. Limitation of Liability. + + IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING +WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS +THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY +GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE +USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF +DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD +PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), +EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF +SUCH DAMAGES. + + 17. Interpretation of Sections 15 and 16. + + If the disclaimer of warranty and limitation of liability provided +above cannot be given local legal effect according to their terms, +reviewing courts shall apply local law that most closely approximates +an absolute waiver of all civil liability in connection with the +Program, unless a warranty or assumption of liability accompanies a +copy of the Program in return for a fee. + + END OF TERMS AND CONDITIONS + + How to Apply These Terms to Your New Programs + + If you develop a new program, and you want it to be of the greatest +possible use to the public, the best way to achieve this is to make it +free software which everyone can redistribute and change under these terms. + + To do so, attach the following notices to the program. It is safest +to attach them to the start of each source file to most effectively +state the exclusion of warranty; and each file should have at least +the "copyright" line and a pointer to where the full notice is found. + + + Copyright (C) + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see . + +Also add information on how to contact you by electronic and paper mail. + + If the program does terminal interaction, make it output a short +notice like this when it starts in an interactive mode: + + Copyright (C) + This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. + This is free software, and you are welcome to redistribute it + under certain conditions; type `show c' for details. + +The hypothetical commands `show w' and `show c' should show the appropriate +parts of the General Public License. Of course, your program's commands +might be different; for a GUI interface, you would use an "about box". + + You should also get your employer (if you work as a programmer) or school, +if any, to sign a "copyright disclaimer" for the program, if necessary. +For more information on this, and how to apply and follow the GNU GPL, see +. + + The GNU General Public License does not permit incorporating your program +into proprietary programs. If your program is a subroutine library, you +may consider it more useful to permit linking proprietary applications with +the library. If this is what you want to do, use the GNU Lesser General +Public License instead of this License. But first, please read +. diff --git a/builtins/textcode_pdf2text-macosx/src/textcode_pdf2text/licenses/gettext/ChangeLog b/builtins/textcode_pdf2text-macosx/src/textcode_pdf2text/licenses/gettext/ChangeLog new file mode 100644 index 0000000..0a1716d --- /dev/null +++ b/builtins/textcode_pdf2text-macosx/src/textcode_pdf2text/licenses/gettext/ChangeLog @@ -0,0 +1,20750 @@ +2025-07-19 Bruno Haible + + Update release steps. + +2025-07-19 Bruno Haible + + examples: Use infrastructure from gettext version 0.26. + * gettext-tools/examples/hello-*/configure.ac: Use AM_GNU_GETTEXT_VERSION with + version 0.26. + * gettext-tools/examples/hello-c++-kde/configure.in.in: Likewise. + +2025-07-19 Bruno Haible + + Update translations from TP. + * gettext-runtime/po/*.po: Update from TP. + * gettext-tools/po/*.po: Update from TP. + * gettext-tools/examples/po/*.po: Update from TP. + +2025-07-19 Bruno Haible + + Prepare for 0.26 release. + * gettext-runtime/doc/matrix.texi: Update from TP. + * gettext-runtime/doc/nls.texi (STATUS): Update. + * gettext-runtime/intl/libgnuintl.in.h (LIBINTL_VERSION): Bump. + * libtextstyle/version.sh: Update VERSION_NUMBER, RELEASE_DATE. + * gettext-tools/libgettextpo/gettext-po.in.h (LIBGETTEXTPO_VERSION): Bump. + * gettext-runtime/po/Makefile.in.in: Update Origin. + * gettext-runtime/intl/Makefile.am (LTV_*): Bump to 12:5:4. + * libtextstyle/lib/Makefile.am (LTV_*): Bump to 2:6:2. + * gettext-tools/libgettextpo/Makefile.am (LTV_*): Bump to 5:15:5. + * gettext-tools/misc/autopoint.in: Likewise. Accept version 0.26. + * gettext-tools/configure.ac (ARCHIVE_VERSION): Bump to 0.26. + +2025-07-19 Bruno Haible + + Update to the newest gnulib. + +2025-07-19 Bruno Haible + + xgettext: JavaScript: Add one more test. + Reported by + at . + + * gettext-tools/tests/xgettext-javascript-14: New file. + * gettext-tools/tests/Makefile.am (TESTS): Add it. + +2025-07-18 Bruno Haible + + msginit: Fix encoding of second title line, part 2. + Reported by Matilin Torre in + . + + To reproduce the problem: + $ LC_ALL=de_DE.ISO-8859-1 msginit -l fr_FR.ISO-8859-1 -i some_utf-8.pot -o fr.po + + * gettext-tools/src/msginit.c (output_charset): New variable. + (content_type): Use output_charset. + (get_title): Use output_charset instead of ignoring was_utf8. + (fill_header): Initialize output_charset. Moved logic from content_type() + to here. + +2025-07-18 Bruno Haible + + msginit: Fix encoding of second title line, part 1. + Reported by Matilin Torre in + . + + * gettext-tools/src/msginit.c: Include xstriconv.h. + (get_title): Don't set OUTPUT_CHARSET; this does not work any more since 2005, + when an optimization was made in dcigettext.c. Instead, use xstr_iconv(). + +2025-07-12 Bruno Haible + + msgfmt: Verify that .mo files are reproducible across GNU gettext versions. + * gettext-tools/tests/msgfmt-21: New file. + * gettext-tools/tests/testdata/mf-21.mo: New generated file. + * gettext-tools/tests/Makefile.am (TESTS): Add msgfmt-21. + (EXTRA_DIST): Add testdata/mf-21.mo. + +2025-07-12 Bruno Haible + + Update to the newest gnulib. + +2025-07-09 Bruno Haible + + build: On mingw, avoid link dependency from xgettext.exe to libstdc++. + Reported by Michele Locati in + . + + * gettext-tools/src/Makefile.am (xgettext_CXXFLAGS): New variable. + +2025-07-09 Bruno Haible + + build: Use a more understandable directory name for ITS data files. + Reported by Santiago Vila . + + * gettext-tools/configure.ac (PACKAGE_SUFFIX): Use PACKAGE_VERSION, not + ARCHIVE_VERSION. + +2025-07-08 Bruno Haible + + build: Update .gitignore files. + +2025-07-08 Bruno Haible + + build: Remove autosprintf_all.html upon "make maintainer-clean". + * gettext-runtime/libasprintf/Makefile.am (MAINTAINERCLEANFILES): New variable. + +2025-07-07 Bruno Haible + + tests: Fix suggested valgrind invocation. + A while ago, valgrind exited with exit code != 0 when it encountered an error. + This is apparently not the case any more. + + * gettext-tools/tests/Makefile.am (CHECKER): Add --error-exitcode option. + +2025-07-07 Bruno Haible + + xgettext: Perl: Add unit test for bug. + * gettext-tools/tests/xgettext-perl-11: New file. + * gettext-tools/tests/Makefile.am (TESTS): Add it. + +2025-07-07 Bruno Haible + + xgettext: Perl: Fix a memory leak (regression 2003-06-27). + * gettext-tools/src/x-perl.c (phase2_getc): Free the result of + from_current_source_encoding. + +2025-07-07 Bruno Haible + + xgettext: Perl: Fix bug with comment lines longer than 1024 (regr. 2024-09-26). + Reported by Alyssa Ross in + . + + * gettext-tools/src/x-perl.c (phase2_getc): Move the sb_free call until after + the savable_comment_add call. + +2025-07-04 Bruno Haible + + doc: More precisions about POSIX printf portability. + * gettext-tools/doc/lang-sh.texi (The printf approach): Add more details. + Based on info given by Jörg Schilling in 2020. + +2025-07-04 Bruno Haible + + Prepare for prerelease. + * gettext-tools/po/POTFILES.in: Update file list. + +2025-07-04 Bruno Haible + + Update to the newest gnulib. + +2025-07-04 Bruno Haible + + xgettext: Warn when a message contains an URL or email address. + Reported by Arsen Arsenović + at . + + * gettext-tools/src/xg-check.c: Include c-strstr.h. + (SIZEOF): New macro. + (string_has_url, message_has_url, string_has_email, message_has_email, + url_check_message): New functions. + (xgettext_check_message_list): Invoke url_check_message. + * gettext-tools/tests/xgettext-20: New file. + * gettext-tools/tests/Makefile.am (TESTS): Add it. + * NEWS: Mention the change. + +2025-07-03 Bruno Haible + + msgcat, msgen, xgettext: Tweak processing order. + * gettext-tools/src/msgcat.c (main): Sort the list of messages as the last + processing step before writing the PO file. + * gettext-tools/src/msgen.c (main): Likewise. + * gettext-tools/src/xgettext.c (main): Likewise. + +2025-07-03 Bruno Haible + + xgettext: Check msgid and msgid_plural for compatibility as format strings. + * gettext-tools/src/if-error.h: Include . + (if_verror): New declaration. + * gettext-tools/src/if-error.c (if_verror): New function, extracted from + if_error. + (if_error): Invoke it. + * gettext-tools/src/xg-check.h (xgettext_check_message_list): Renamed from + syntax_check_message_list. + * gettext-tools/src/xg-check.c: Include format.h, if-error.h. + (struct formatstring_error_logger_locals): New type. + (formatstring_error_logger, format_check_message): New functions. + (xgettext_check_message_list): Renamed from syntax_check_message_list. Invoke + also format_check_message. + * gettext-tools/src/xgettext.c (main): Invoke xgettext_check_message_list + instead of syntax_check_message_list. + * gettext-tools/tests/xgettext-19: New file. + * gettext-tools/tests/Makefile.am (TESTS): Add it. + * NEWS: Mention the change. + +2025-07-03 Bruno Haible + + Lisp, Scheme support: Fix format string checking. + * gettext-tools/src/format-lisp.c (format_check): Allow missing arguments if + !equality. + * gettext-tools/src/format-scheme.c (format_check): Likewise. + +2025-07-03 Bruno Haible + + Lua support: Fix format string checking. + * gettext-tools/src/format-lua.c (format_check): Allow missing arguments if + !equality. Report all argument type mismatches at once. + +2025-07-03 Bruno Haible + + tests: Strengthen tests. + * gettext-tools/tests/lang-bash: Invoke msgfmt with option '-c'. + * gettext-tools/tests/lang-c: Likewise. + * gettext-tools/tests/lang-c++: Likewise. + * gettext-tools/tests/lang-c++20: Likewise. + * gettext-tools/tests/lang-c++26: Likewise. + * gettext-tools/tests/lang-c++-boost: Likewise. + * gettext-tools/tests/lang-clisp: Likewise. + * gettext-tools/tests/lang-csharp: Likewise. + * gettext-tools/tests/lang-d: Likewise. + * gettext-tools/tests/lang-elisp: Likewise. + * gettext-tools/tests/lang-gawk: Likewise. + * gettext-tools/tests/lang-go: Likewise. + * gettext-tools/tests/lang-guile: Likewise. + * gettext-tools/tests/lang-java: Likewise. + * gettext-tools/tests/lang-javascript: Likewise. + * gettext-tools/tests/lang-librep: Likewise. + * gettext-tools/tests/lang-lua: Likewise. + * gettext-tools/tests/lang-modula2: Likewise. + * gettext-tools/tests/lang-objc: Likewise. + * gettext-tools/tests/lang-pascal: Likewise. + * gettext-tools/tests/lang-perl-1: Likewise. + * gettext-tools/tests/lang-perl-2: Likewise. + * gettext-tools/tests/lang-php: Likewise. + * gettext-tools/tests/lang-python-1: Likewise. + * gettext-tools/tests/lang-python-2: Likewise. + * gettext-tools/tests/lang-ruby: Likewise. + * gettext-tools/tests/lang-rust: Likewise. + * gettext-tools/tests/lang-sh-1: Likewise. + * gettext-tools/tests/lang-sh-2: Likewise. + * gettext-tools/tests/lang-sh-3: Likewise. + * gettext-tools/tests/lang-smalltalk: Likewise. + * gettext-tools/tests/lang-tcl: Likewise. + * gettext-tools/tests/lang-vala: Likewise. + +2025-07-03 Bruno Haible + + Python: Fix compilation error (regression 2025-06-24). + * gettext-tools/src/format-python-brace.c (parse_directive): Pass NULL, not + false. + +2025-07-03 Bruno Haible + + Modula-2 support: Fix possible crash during format string checking. + * gettext-tools/src/format-modula2.c (format_check): Fix error message. Fix loop + bound. + +2025-07-03 Bruno Haible + + xgettext: Fix bug with syntax-checks on messages from Perl source code. + * gettext-tools/src/x-perl.c (extract_perl): Don't free logical_file_name, + because it is referenced by the 'pos' field of the returned messages, and + xg-check.c accesses and prints it. + +2025-07-03 Bruno Haible + + xgettext: Fix handling of syntax-checks with multi-domain POT files. + * gettext-tools/src/xgettext.c (main): Consider the total number of errors. + +2025-07-03 Bruno Haible + + msggrep: Add new options -W and -S. + Reported at . + + * gettext-tools/src/msggrep.c (workflow_flags, sticky_flags): New variables. + (main): Initialize them. Handle the options -W and -S. + (usage): Document the -W and -S options. + (is_message_selected_no_invert): Return true if one of the specified workflow + flags or one of the specified sticky flags is set. + * gettext-tools/tests/msggrep-12: New file. + * gettext-tools/tests/Makefile.am (TESTS): Add it. + * gettext-tools/doc/msggrep.texi: Document the -W and -S options. + * NEWS: Mention the change. + +2025-07-03 Bruno Haible + + msggrep: Finish documenting the -X option (left-over from 2006-03-17). + * gettext-tools/doc/msggrep.texi: Mention the -X option in the summary. + +2025-07-02 Bruno Haible + + Update NEWS after 0.25.1 release. + * NEWS: Mention 0.25.1 release. + +2025-07-02 Bruno Haible + + Merge from 0.25.x branch: Prepare for 0.25.1 release. + * gettext-tools/misc/autopoint.in: Accept versions 0.23.2, 0.24.2, 0.25.1. + * gettext-tools/configure.ac (ARCHIVE_VERSION): Bump to 0.25.1. + * NEWS: Update. + +2025-07-01 Bruno Haible + + autopoint: Don't fail if no gettext version is specified, part 2. + * gettext-tools/misc/autopoint.in (func_trace_sed): Recognize also macro calls + without arguments. + * gettext-tools/tests/autopoint-1: Remove unneeded parentheses in macro call. + +2025-07-01 Bruno Haible + + autopoint: Update unit test, part 2. + * gettext-tools/tests/autopoint-1: Remove debugging trace. + +2025-07-01 Bruno Haible + + autopoint: Update unit test. + * gettext-tools/tests/autopoint-1: Update for new autopoint behaviour. + +2025-07-01 Bruno Haible + + Fix an autoreconf failure in packages that only need AM_NLS. + Rationale: https://lists.gnu.org/archive/html/bug-gettext/2025-06/msg00009.html + + * gettext-tools/m4/Makefile.am (aclocaldir, aclocal_DATA): New variables. + * PACKAGING: Update. + +2025-07-01 Bruno Haible + + autopoint: Don't fail if no gettext version is specified. + Rationale: https://lists.gnu.org/archive/html/bug-gettext/2025-06/msg00009.html + + * gettext-tools/misc/autopoint.in: Instead of failing with "Missing version", + use version 0.23.1. Set omitintl=yes if there is no AM_GNU_GETTEXT invocation. + +2025-06-30 Bruno Haible + + Support reading PO files with '#=' lines. + * gettext-tools/src/read-catalog-abstract.c + (catalog_reader_seen_generic_comment): Treat '=' like ','. + * gettext-tools/src/read-catalog.c (default_comment_special): Allow several + calls to this method to make side effects on dcatr. + * gettext-tools/src/read-catalog-special.h: Update comment. + * gettext-tools/src/read-catalog-special.c: Likewise. + * gettext-tools/tests/msgcat-24: New file. + * gettext-tools/tests/Makefile.am (TESTS): Add it. + +2025-06-30 Bruno Haible + + doc: Document the short-term PO file format evolution. + * gettext-tools/doc/gettext.texi (PO File Format Evolution): New section. + +2025-06-30 Bruno Haible + + doc: Structure the "PO Files" chapter. + * gettext-tools/doc (PO Files): Split into sections. Introduce workflow flags + and sticky flags. Mention the 'no-wrap' flag. + +2025-06-30 Bruno Haible + + Simplify code: The syntax-check flags are only used inside xgettext. + * gettext-tools/src/message.h: Improve comments regarding do_syntax_check. + * gettext-tools/src/msgl-cat.c (catenate_msgdomain_list): Don't manipulate + do_syntax_check field. + * gettext-tools/src/msgmerge.c (message_merge): Likewise. + * gettext-tools/src/read-catalog-special.h (parse_comment_special): Change 'scp' + parameter to a pointer. + * gettext-tools/src/read-catalog-special.c (parse_comment_special): Support a + null 'scp' argument. + * gettext-tools/src/read-catalog.h (DEFAULT_CATALOG_READER_TY): Remove + do_syntax_check field. + * gettext-tools/src/read-catalog.c (default_constructor, + default_copy_comment_state, default_reset_comment_state, + default_comment_special): Don't reference do_syntax_check field. + +2025-06-29 Bruno Haible + + examples: Extend the hello-sh example, part 2. + * gettext-tools/examples/hello-sh/hello-2.sh: New file, based on + gettext-tools/examples/hello-sh/hello-1.sh. + * gettext-tools/examples/hello-sh/hello-3.sh: New file, based on + gettext-tools/examples/hello-sh/hello-2.sh. + +2025-06-29 Bruno Haible + + Tweak last commit. + * gettext-tools/src/msgcmp.c (main): Tweak whitespace. + +2025-06-28 Bruno Haible + + Refactor: Use gnulib's 'options' module. + * autogen.sh (GNULIB_MODULES_RUNTIME_FOR_SRC, GNULIB_MODULES_TOOLS_FOR_SRC): Add + 'options'. Remove 'getopt-gnu'. + * gettext-runtime/src/envsubst.c: Include options.h instead of . + (long_options): Remove variable. + (main): Define options array here. Call start_options, get_next_option instead + of getopt_long(). + * gettext-runtime/src/gettext.c: Likewise. + * gettext-runtime/src/ngettext.c: Likewise. + * gettext-runtime/src/printf_gettext.c: Likewise. + * gettext-runtime/src/printf_ngettext.c: Likewise. + * gettext-tools/src/cldr-plurals.c: Likewise. + * gettext-tools/src/hostname.c: Likewise. + * gettext-tools/src/msgattrib.c: Likewise. + * gettext-tools/src/msgcat.c: Likewise. + * gettext-tools/src/msgcmp.c: Likewise. + * gettext-tools/src/msgcomm.c: Likewise. + * gettext-tools/src/msgconv.c: Likewise. + * gettext-tools/src/msgen.c: Likewise. + * gettext-tools/src/msgexec.c: Likewise. + * gettext-tools/src/msgfilter.c: Likewise. + * gettext-tools/src/msgfmt.c: Likewise. + * gettext-tools/src/msggrep.c: Likewise. + * gettext-tools/src/msginit.c: Likewise. + * gettext-tools/src/msgmerge.c: Likewise. + * gettext-tools/src/msgunfmt.c: Likewise. + * gettext-tools/src/msguniq.c: Likewise. + * gettext-tools/src/recode-sr-latin.c: Likewise. + * gettext-tools/src/urlget.c: Likewise. + * gettext-tools/src/xgettext.c: Likewise. + * gettext-tools/tests/tstgettext.c: Likewise. + * gettext-tools/tests/tstngettext.c: Likewise. + +2025-06-28 Bruno Haible + + Update to the newest gnulib. + +2025-06-28 Bruno Haible + + Adhere to GNU Coding Style. + * gettext-runtime/src/envsubst.c (main): Use common 'switch' indentation. + * gettext-tools/src/hostname.c (main): Likewise. + * gettext-tools/src/recode-sr-latin.c (main): Likewise. + * gettext-tools/src/urlget.c (main): Likewise. + * gettext-tools/tests/tstgettext.c (main): Likewise. + * gettext-tools/tests/tstngettext.c (main): Likewise. + +2025-06-28 Bruno Haible + + xgettext: Remove undocumented no-op option '-W'. + This was a regression from 2015-01-29. + + * gettext-tools/src/xgettext.c (main): Remove short option '-W'. + +2025-06-28 Bruno Haible + + msgconv, msgen, msgfilter, msggrep, msgmerge: The option '-n' takes no argument. + This was a regression from 2014-03-24. + + * gettext-tools/src/msgconv.c (main): Change "n:" to "n" in getopt_long + argument. + * gettext-tools/src/msgen.c (main): Likewise. + * gettext-tools/src/msgfilter.c (main): Likewise. + * gettext-tools/src/msggrep.c (main): Likewise. + * gettext-tools/src/msgmerge.c (main): Likewise. + +2025-06-27 Bruno Haible + + Shell: Document two more approaches. + * gettext-tools/doc/lang-sh.texi (sh): Tweaks. + (sh - Three approaches): New subsubsection. + (The gettext.sh approach): New subsubsection, incorporating the "gettext.sh" + subsubsection. + (The printf approach, The printf_gettext approach): New subsubsections. + (Preparing for gettext.sh): Renamed from "Preparing Shell Scripts". + (Preparing for printf, Preparing for printf_gettext): New subsubsections. + * gettext-tools/doc/gettext.texi: Update detailed node list. + * NEWS: Mention the change. + +2025-06-27 Bruno Haible + + examples: Extend the hello-sh example. + * gettext-tools/examples/hello-sh/hello-1.sh: Renamed from + gettext-tools/examples/hello-sh/hello.sh. + * gettext-tools/examples/hello-sh/hello-2.sh: New file, based on + gettext-tools/examples/hello-sh/hello-1.sh. + * gettext-tools/examples/hello-sh/hello-3.sh: New file, based on + gettext-tools/examples/hello-sh/hello-2.sh. + * gettext-tools/examples/hello-sh/configure.ac: Update AC_CONFIG_SRCDIR + invocation and AC_CONFIG_FILES invocations. + * gettext-tools/examples/hello-sh/Makefile.am (bin_SCRIPTS): Remove hello. + Add hello-1, hello-2, hello-3. + * gettext-tools/examples/hello-sh/po/Makefile.am (POTFILES): Remove hello.sh. + Add hello-1.sh, hello-2.sh, hello-3.sh. + * gettext-tools/examples/po/Makefile.am (POTFILES): Update accordingly. + * gettext-tools/examples/Makefile.am (EXAMPLESFILES): Update file list. + +2025-06-27 Bruno Haible + + Shell: Add another unit test. + * gettext-tools/tests/lang-sh-3: New file, based on + gettext-tools/tests/lang-sh-2. + * gettext-tools/tests/Makefile.am (TESTS): Add it. + +2025-06-27 Bruno Haible + + build: Use module 'kwset' from gnulib. + * autogen.sh (GNULIB_MODULES_TOOLS_FOR_LIBGREP): Add kwset. + (GNULIB_MODULES_TOOLS_FOR_SRC_COMMON_DEPENDENCIES): Update. + * gettext-tools/libgrep/m-fgrep.c (Fcompile, Fexecute): Update for changed kwset + API. + * gettext-tools/libgrep/kwset.h: Remove file. + * gettext-tools/libgrep/kwset.c: Remove file. + * gettext-tools/libgrep/Makefile.am (libgrep_a_SOURCES): Remove kwset.h, + kwset.c. + +2025-06-26 Bruno Haible + + Update to the newest gnulib. + +2025-06-26 Bruno Haible + + build: Update regarding current gnulib. + * autogen.sh (GNULIB_MODULES_TOOLS_FOR_SRC_COMMON_DEPENDENCIES): Update. + +2025-06-25 Bruno Haible + + build: Fix "make distcheck" failure. + * gettext-runtime/man/*.x: Add copyright and license header. + +2025-06-25 Bruno Haible + + xgettext: Shell: Recognize printf_gettext, printf_ngettext invocations. + * gettext-tools/src/x-sh.c (init_keywords, init_flag_table_sh): Add knowledge + about printf_gettext and printf_ngettext. + (read_command): Recognize '-c' option of printf_gettext and printf_ngettext. + * gettext-tools/tests/xgettext-sh-1: Add test cases with printf_gettext and + printf_ngettext. + * gettext-tools/doc/xgettext.texi: Document it. + +2025-06-25 Bruno Haible + + gettext-runtime: New programs 'printf_gettext', 'printf_ngettext'. + * autogen.sh (GNULIB_MODULES_RUNTIME_FOR_SRC): Add c-ctype, c-strtold, + fzprintf-posix, mbrtoc32, mbszero, quote, stdint-h, strtoimax, strtold, + strtoumax, xstrtold. + * gettext-runtime/src/printf-command.h: New file. + * gettext-runtime/src/printf-command.c: New file. + * gettext-runtime/src/printf_gettext.c: New file. + * gettext-runtime/src/Makefile.am (bin_PROGRAMS): Add printf_gettext, + printf_ngettext. + (noinst_LIBRARIES, libgrtsrc_a_SOURCES): New variables. + (printf_gettext_SOURCES, printf_gettext_CFLAGS, printf_gettext_LDFLAGS): New + variables. + (printf_ngettext_SOURCES, printf_ngettext_CFLAGS, printf_ngettext_LDFLAGS): New + variables. + (LDADD): Add libgrtsrc.a. + * gettext-runtime/po/POTFILES.in: Add src/printf-command.c, + src/printf_gettext.c, src/printf_ngettext.c. + * gettext-runtime/man/printf_gettext.x: New file. + * gettext-runtime/man/printf_ngettext.x: New file. + * gettext-runtime/man/Makefile.am (man_aux): Add printf_gettext.x, + printf_ngettext.x. + (man_MAN1GEN): Add printf_gettext.1, printf_ngettext.1. + (man_MAN1IN): Add printf_gettext.1.in, printf_ngettext.1.in. + (man_HTML1GEN): Add printf_gettext.1.html, printf_ngettext.1.html. + (man_HTML1IN): Add printf_gettext.1.html.in, printf_ngettext.1.html.in. + (printf_gettext.1, rintf_ngettext.1, printf_gettext.1.in, printf_ngettext.1.in): + Add dependencies. + (printf_gettext.1.html, printf_ngettext.1.html, printf_gettext.1.html.in, + printf_ngettext.1.html.in): Likewise. + * gettext-runtime/Makefile.am (distdir1): Depend on man/printf_gettext.1 and + man/printf_ngettext.1. + (man/printf_gettext.1, man/printf_ngettext.1): Depend on gen-man1. + (gen-man1): Make src/printf_gettext, src/printf_ngettext and printf_gettext.1, + printf_ngettext.1. + * gettext-runtime/doc/rt-printf_gettext.texi: New file. + * gettext-runtime/doc/rt-printf_ngettext.texi: New file. + * gettext-runtime/doc/Makefile.am (EXTRA_DIST): Add them. + * gettext-tools/doc/lang-sh.texi (printf_gettext Invocation, + printf_ngettext Invocation): New subsubsections. + * gettext-tools/doc/gettext.texi (@direntry): Add printf_gettext, . + * gettext-tools/doc/Makefile.am (gettext_TEXINFOS): Add rt-printf_gettext.texi, + rt-printf_ngettext.texi. + * gettext-runtime/NEWS: Mention the new programs. + * NEWS: Likewise. + * PACKAGING: Add the printf_gettext and printf_ngettext programs and their + documentation. + +2025-06-25 Bruno Haible + + gettext-runtime: Improve --help output. + * gettext-runtime/src/gettext.c (usage): Add section title + "Options and arguments". + * gettext-runtime/src/ngettext.c (usage): Likewise. + * gettext-runtime/doc/rt-gettext.texi: Add section titles + "Options and arguments" and "Informative output". + * gettext-runtime/doc/rt-ngettext.texi: Likewise. + +2025-06-24 Bruno Haible + + C++: Add another unit test. + * gettext-tools/tests/lang-c++-boost: New file, based on + gettext-tools/tests/lang-c++26. + * gettext-tools/tests/Makefile.am (TESTS): Add it. + * gettext-tools/doc/lang-c.texi: Mention how to use C++ with the Boost library. + * HACKING: Mention the Boost library. + +2025-06-24 Bruno Haible + + Shell: Add another unit test. + * gettext-tools/tests/lang-sh-1: Renamed from gettext-tools/tests/lang-sh. + * gettext-tools/tests/lang-sh-2: New file, based on + gettext-tools/tests/lang-sh-1. + * gettext-tools/tests/Makefile.am (TESTS): Remove lang-sh. Add lang-sh-1, + lang-sh-2. + +2025-06-24 Bruno Haible + + Python: Add another unit test. + * gettext-tools/tests/lang-python-2: New file, based on + gettext-tools/tests/lang-python-1. + * gettext-tools/tests/Makefile.am (TESTS): Add it. + +2025-06-24 Bruno Haible + + Python: Update python-brace-format, assuming Python >= 3.1. + * gettext-tools/src/format-python-brace.c (struct toplevel_counters): New type. + (parse_directive): Take a 'struct toplevel_counters *' parameter. Allow empty + argument names at the top-level. But reject format strings with both absolute + argument numbers and unnamed arguments at the top-level. + (parse_upto): Take a 'struct toplevel_counters *' parameter. + (format_parse): Pass a 'struct toplevel_counters *' to parse_upto. + * gettext-tools/tests/format-python-brace-1: Update. + * gettext-tools/tests/format-python-brace-2: Add another test case. + * gettext-tools/doc/lang-python.texi: Add more examples of formatting with + positions. + +2025-06-24 Bruno Haible + + Python: Fix bug in python-brace-format. + * gettext-tools/src/format-python-brace.c (parse_directive): The name ends + before ':', not before '}'. + +2025-06-24 Bruno Haible + + Python: Remove an obsolete unit test. + Python versions < 2.3 are irrelevant nowadays. + + * gettext-tools/tests/lang-python-1: Renamed from + gettext-tools/tests/lang-python-2. + * gettext-tools/tests/Makefile.am (TESTS): Remove lang-python-2. + +2025-06-23 Bruno Haible + + Support format strings longer than 2 GiB on 64-bit platforms. + * gettext-tools/configure.ac: In config.h, define GCD_WORD_T. + * gettext-tools/src/format-invalid.h: In format strings, use %zu instead of %u. + * gettext-tools/src/format-awk.c: Use size_t instead of 'unsigned int'. In + format strings, use %zu instead of %u. + * gettext-tools/src/format-boost.c: Likewise. + * gettext-tools/src/format-c.c: Likewise. + * gettext-tools/src/format-c-parse.h: Likewise. + * gettext-tools/src/format-c++-brace.c: Likewise. + * gettext-tools/src/format-csharp.c: Likewise. + * gettext-tools/src/format-d.c: Likewise. + * gettext-tools/src/format-elisp.c: Likewise. + * gettext-tools/src/format-gcc-internal.c: Likewise. + * gettext-tools/src/format-gfc-internal.c: Likewise. + * gettext-tools/src/format-go.c: Likewise. + * gettext-tools/src/format-java.c: Likewise. + * gettext-tools/src/format-java-printf.c: Likewise. + * gettext-tools/src/format-javascript.c: Likewise. + * gettext-tools/src/format-kde.c: Likewise. + * gettext-tools/src/format-kde-kuit.c: Likewise. + * gettext-tools/src/format-librep.c: Likewise. + * gettext-tools/src/format-lisp.c: Likewise. + * gettext-tools/src/format-lua.c: Likewise. + * gettext-tools/src/format-modula2.c: Likewise. + * gettext-tools/src/format-pascal.c: Likewise. + * gettext-tools/src/format-perl.c: Likewise. + * gettext-tools/src/format-perl-brace.c: Likewise. + * gettext-tools/src/format-php.c: Likewise. + * gettext-tools/src/format-python.c: Likewise. + * gettext-tools/src/format-python-brace.c: Likewise. + * gettext-tools/src/format-qt.c: Likewise. + * gettext-tools/src/format-qt-plural.c: Likewise. + * gettext-tools/src/format-ruby.c: Likewise. + * gettext-tools/src/format-rust.c: Likewise. + * gettext-tools/src/format-scheme.c: Likewise. + * gettext-tools/src/format-sh.c: Likewise. + * gettext-tools/src/format-sh-printf.c: Likewise. + * gettext-tools/src/format-smalltalk.c: Likewise. + * gettext-tools/src/format-tcl.c: Likewise. + * gettext-tools/src/format.h (get_python_format_unnamed_arg_count): Return + size_t instead of 'unsigned int'. + +2025-06-23 Bruno Haible + + Update to the newest gnulib. + +2025-06-23 Bruno Haible + + gettext-runtime: Fix --help output in relocatable installations. + * gettext-runtime/src/gettext.c (usage): Show the relocated LOCALEDIR. + * gettext-runtime/src/ngettext.c (usage): Likewise. + +2025-06-23 Bruno Haible + + Adhere to GNU Coding Style. + * gettext-runtime/src/gettext.c (usage): Add space after 'printf'. + * gettext-runtime/src/ngettext.c (usage): Likewise. + * gettext-runtime/src/envsubst.c (usage): Likewise. + +2025-06-23 Bruno Haible + + Add support for Shell printf format strings, part 3. + * gettext-tools/src/format-invalid.h (INVALID_FLAG_FOR): New macro. + * gettext-tools/src/format-java-printf.c (INVALID_FLAG_FOR): Remove macro. + * gettext-tools/src/format-sh-printf.c (format_parse): Reject format strings + with invalid flag+specifier combinations. + * gettext-tools/tests/format-sh-printf-1: Add more test cases. + * gettext-tools/doc/gettext.texi (sh-format): Mention the ' flag. + +2025-06-23 Bruno Haible + + Add support for Shell printf format strings, part 2. + * gettext-tools/po/POTFILES.in: Add src/format-sh-printf.c. + * gettext-tools/tests/format-sh-printf-1: Use 'printf' instead of 'echo', + because 'echo' processes escape sequences on macOS, OpenBSD, Solaris. + +2025-06-22 Bruno Haible + + Add support for Shell printf format strings. + * gettext-tools/src/message.h (enum format_type): Add format_sh_printf. + (NFORMATS): Increment. + * gettext-tools/src/message.c (format_language, format_language_pretty): Add an + entry for format_sh_printf. + * gettext-tools/src/format.h (formatstring_sh_printf): New declaration. + * gettext-tools/src/format.c (formatstring_parsers): Add an entry for + format_sh_printf. + * gettext-tools/src/format-sh-printf.c: New file, based on + gettext-tools/src/format-awk.c. + * gettext-tools/src/FILES: Mention it. + * gettext-tools/src/x-sh.h (SCANNERS_SH): Use formatstring_sh_printf as + secondary format string type. + * gettext-tools/src/xgettext.c (xgettext_record_flag): Update accordingly. + * gettext-tools/src/x-sh.c (init_flag_table_sh): Register gettext, ngettext with + flag 'pass-sh-printf-format'. Register 'printf' with flag 'sh-printf-format'. + * gettext-tools/src/Makefile.am (FORMAT_SOURCE): Add format-sh-printf.c. + * gettext-tools/libgettextpo/Makefile.am (libgettextpo_la_AUXSOURCES): Likewise. + * gettext-tools/doc/gettext.texi (PO Files): Mention sh-printf-format. + (sh-format): Document also the sh-printf-format strings. + * gettext-tools/doc/lang-sh.texi (sh): Mention the coreutils 'printf' command. + * gettext-tools/tests/xgettext-sh-1: Add a test case with a printf invocation. + * gettext-tools/tests/format-sh-printf-1: New file, based on + gettext-tools/tests/format-awk-1. + * gettext-tools/tests/format-sh-printf-2: New file, based on + gettext-tools/tests/format-awk-2. + * gettext-tools/tests/Makefile.am (TESTS): Add them. + * NEWS: Mention the change. + +2025-06-22 Bruno Haible + + tcl-format: Accept null precision. + Proof that it's valid: + $ tclsh + puts [format "%.f" 3.1415926535] + + * gettext-tools/src/format-tcl.c: Fix comment regarding the precision. + * gettext-tools/tests/format-tcl-1: Add a test case with null precision. + +2025-06-22 Bruno Haible + + rust-format: Reject null precision. + * gettext-tools/tests/format-rust-1: Add more test cases with null precision. + +2025-06-22 Bruno Haible + + ruby-format: Accept null precision. + Proof that it's valid: + $ ruby + puts "%.f" % 3.1415926535 + + * gettext-tools/src/format-ruby.c: Clarify comment regarding the precision. + * gettext-tools/tests/format-ruby-1: Add test cases with null precision. + +2025-06-22 Bruno Haible + + python-brace-format: Reject null precision. + Proof that it's invalid: + $ python + print("{value:.}".format(value = 3.141592535)) + + * gettext-tools/tests/format-python-brace-1: Add another test case with null + precision. + +2025-06-22 Bruno Haible + + python-format: Accept null precision. + Proof that it's valid: + $ python + print("%(value).f" % { 'value': 3.1415926535 }) + + * gettext-tools/src/format-python.c: Fix comment regarding the precision. + * gettext-tools/tests/format-python-1: Add a test case with null precision. + +2025-06-22 Bruno Haible + + php-format: Reject null precision. + Rationale: The handling of null precision in php is buggy, + cf. . + + * gettext-tools/src/format-php.c: Fix comment regarding the precision. + * gettext-tools/tests/format-php-1: Add a test case with null precision. + +2025-06-22 Bruno Haible + + perl-format: Accept null precision. + Proof that it's valid: + $ perl + printf "%.f", 3.1415926535 + + * gettext-tools/src/format-perl.c: Clarify comment regarding the precision. + * gettext-tools/tests/format-perl-1: Add a test case with null precision. + +2025-06-22 Bruno Haible + + pascal-format: Accept null precision. + Proof that it's valid: + ------------------------- foo.pp ------------------------- + program foo; + uses sysutils; + begin + writeln(format('%.f', [3.1415926535])); + end. + ---------------------------------------------------------- + + * gettext-tools/src/format-pascal.c: Fix comment regarding the precision. + (format_parse): Accept a null precision after '.'. + * gettext-tools/tests/format-pascal-1: Add a test case with null precision. + +2025-06-22 Bruno Haible + + lua-format: Accept null precision. Limit width and precision to two digits. + Proof that it's valid: + $ lua + print(string.format("%.f", 3.1415926535)) + + * gettext-tools/src/format-lua.c: Fix comment regarding the width and the + precision. + (format_parse): Recognize at most two digits for the width. Recognize at most + two digits for the precision. + * gettext-tools/tests/format-lua-1: Add test cases with large width, null + precision, and large precision. + +2025-06-22 Bruno Haible + + librep-format: Accept null precision. + Proof that it's valid: + $ rep + (format t "%.d" 3.1415926535) + + * gettext-tools/src/format-librep.c: Fix comment regarding the precision. + * gettext-tools/tests/format-librep-1: Add a test case with null precision. + +2025-06-22 Bruno Haible + + javascript-format: Reject null precision. + Proof that it's invalid: + ------------------------------- foo.js ------------------------------- + const Format = imports.format; + String.prototype.format = Format.format; + print("%.f".format(3.1415916535)); + ---------------------------------------------------------------------- + $ gjs foo.js + + * gettext-tools/src/format-invalid.h (INVALID_PRECISION_MISSING): New macro. + * gettext-tools/src/format-java-printf.c (INVALID_PRECISION_MISSING): Remove + macro. + * gettext-tools/src/format-javascript.c: Fix comment regarding the precision. + (format_parse): Report an error if the precision is null (empty). + * gettext-tools/tests/format-javascript-1: Add a test case with null precision. + +2025-06-22 Bruno Haible + + java-printf-format: Reject null precision. + Proof that it's invalid: + --------------------------- foo.java --------------------------- + public class foo { + public static void main(String[] args) { + System.out.println(String.format("%.f\n", 3.1415926535)); + } + } + ---------------------------------------------------------------- + + * gettext-tools/tests/format-java-printf-1: Add a test case with null precision. + +2025-06-22 Bruno Haible + + go-format: Accept null precision. + * gettext-tools/src/format-go.c: Clarify comment regarding the precision. + (format_parse): Accept a null precision after '.'. + * gettext-tools/tests/format-go-1: Add a test case with null precision. + +2025-06-22 Bruno Haible + + elisp-format: Accept null precision. + Proof that is is valid: + (format "%.f" 3.1415926) + + * gettext-tools/src/format-elisp.c: Fix comment regarding the precision. + * gettext-tools/tests/format-elisp-1: Add a test case with null precision. + +2025-06-22 Bruno Haible + + d-format: Accept null precision. + Proof that a null precision is valid: + ------------------------------- foo.d ------------------------------- + import std.stdio; + import std.format; + void main () { writeln (format ("%.f", 3.1415926)); } + --------------------------------------------------------------------- + + * gettext-tools/tests/format-d-1: Add a test case with null precision. + +2025-06-21 Bruno Haible + + c-format: Accept null precision. + * gettext-tools/src/format-c-parse.h: Fix comment regarding the precision and + the ISO C23 size specifiers. + * gettext-tools/tests/format-c-1: Add a test case with null precision. + +2025-06-21 Bruno Haible + + boost-format: Accept null precision. + * gettext-tools/src/format-boost.c: Fix comment regarding the precision. + * gettext-tools/tests/format-boost-1: Add a test case with null precision. + +2025-06-21 Bruno Haible + + awk-format: Accept null precision. + Proof that it's valid: + $ echo 3.1415926 | gawk '{ printf "%.f", $1 }' + + * gettext-tools/src/format-awk.c: Fix comment regarding the precision. + * gettext-tools/tests/format-awk-1: Add a test case with null precision. + +2025-06-21 Bruno Haible + + xgettext: Shell: Reject \u and \U escape sequences that produce surrogates. + * gettext-tools/src/x-sh.c (read_word): Reject \u and \U values in the range + 0xD800..0xDFFF. + * gettext-tools/tests/xgettext-sh-9: Add more test cases. + +2025-06-21 Bruno Haible + + xgettext: Shell: Bump phase1_pushback buffer size. + * gettext-tools/src/x-sh.c (phase1_pushback): Bump size to 9. + * gettext-tools/tests/xgettext-sh-8: Add more test cases. + +2025-06-21 Bruno Haible + + xgettext: Shell: Recognize \u and \U escape sequences in $'...' strings. + * gettext-tools/src/xg-mixed-string.h (mixed_string_remove_prefix, + mixed_string_buffer_equals, mixed_string_buffer_startswith, + mixed_string_buffer_cloned_result): New declarations. + * gettext-tools/src/xg-mixed-string.c (mixed_string_remove_prefix): New + function. + (mixed_string_buffer_is_empty): Also test the absence of utf16_surr. + (mixed_string_buffer_equals, mixed_string_buffer_startswith, + mixed_string_buffer_cloned_result): New functions. + * gettext-tools/src/x-sh.c (struct token): Remove type. + (init_token, free_token, grow_token, string_of_token): Remove functions. + (struct word): Change type of 'token' field. + (free_word): Update. + (string_of_word, substring_of_word): Remove functions. + (read_word): Call mixed_string_buffer_init instead of init_token, + mixed_string_buffer_destroy instead of free_token, + mixed_string_buffer_append_char instead of grow_token. Update accesses to + wp->token. Recognize \u and \U escape sequences in $'...' strings. + (read_command): Call mixed_string_buffer_cloned_result instead of + string_of_word. Update accesses to inner.token. + * gettext-tools/tests/xgettext-sh-7: Use --from-code option. + * gettext-tools/tests/xgettext-sh-9: New file. + * gettext-tools/tests/Makefile.am (TESTS): Add it. + * NEWS: Mention this and the previous change. + +2025-06-21 Bruno Haible + + xgettext: Shell: Recognize \c escape sequences in $'...' strings. + * gettext-tools/src/x-sh.c (read_word): Recognize \c escape sequences. + * gettext-tools/tests/xgettext-sh-1: Add test cases with ASCII $'...' strings. + +2025-06-21 Bruno Haible + + tests: Avoid a test failure with valgrind. + * gettext-tools/tests/xgettext-python-9: Filter out the valgrind traces. + +2025-06-20 Bruno Haible + + Fix 'make installcheck' failure on Cygwin. + * gettext-tools/configure.ac (INSTALLED_LIBINTL, INSTALLED_LIBGETTEXTPO_DEPS): + New variables. + * gettext-tools/install-tests/Makefile.am (installcheck): Use + INSTALLED_LIBGETTEXTPO_DEPS. + +2025-06-19 Bruno Haible + + Reject the dysfunctional gettext in Solaris libc, other than Solaris 11.4. + This fixes a 'make installcheck' failure. + + has been reported more than 4 years ago. + I don't have hope that they will fix it, ever. + + * gettext-runtime/m4/gettext.m4 (AM_GNU_GETTEXT): On Solaris other than + Solaris 11.4, don't use the gettext() function in libc. + * gettext-tools/tests/init.cfg (prepare_locale_): Remove function. + * gettext-tools/tests/format-c-3: Remove prepare_locale_ invocations. + * gettext-tools/tests/format-c-4: Likewise. + * gettext-tools/tests/format-c-5: Likewise. + * gettext-tools/tests/intl-0: Likewise. + * gettext-tools/tests/intl-1: Likewise. + * gettext-tools/tests/intl-2: Likewise. + * gettext-tools/tests/intl-3: Likewise. + * gettext-tools/tests/intl-4: Likewise. + * gettext-tools/tests/intl-6: Likewise. + * gettext-tools/tests/intl-7: Likewise. + * gettext-tools/tests/intl-thread-1: Likewise. + * gettext-tools/tests/intl-thread-2: Likewise. + * gettext-tools/tests/intl-thread-3: Likewise. + * gettext-tools/tests/lang-bash: Likewise. + * gettext-tools/tests/lang-c: Likewise. + * gettext-tools/tests/lang-c++: Likewise. + * gettext-tools/tests/lang-c++20: Likewise. + * gettext-tools/tests/lang-c++26: Likewise. + * gettext-tools/tests/lang-clisp: Likewise. + * gettext-tools/tests/lang-csharp: Likewise. + * gettext-tools/tests/lang-d: Likewise. + * gettext-tools/tests/lang-gawk: Likewise. + * gettext-tools/tests/lang-go: Likewise. + * gettext-tools/tests/lang-guile: Likewise. + * gettext-tools/tests/lang-java: Likewise. + * gettext-tools/tests/lang-javascript: Likewise. + * gettext-tools/tests/lang-librep: Likewise. + * gettext-tools/tests/lang-lua: Likewise. + * gettext-tools/tests/lang-modula2: Likewise. + * gettext-tools/tests/lang-objc: Likewise. + * gettext-tools/tests/lang-pascal: Likewise. + * gettext-tools/tests/lang-perl-1: Likewise. + * gettext-tools/tests/lang-perl-2: Likewise. + * gettext-tools/tests/lang-php: Likewise. + * gettext-tools/tests/lang-python-1: Likewise. + * gettext-tools/tests/lang-python-2: Likewise. + * gettext-tools/tests/lang-ruby: Likewise. + * gettext-tools/tests/lang-rust: Likewise. + * gettext-tools/tests/lang-sh: Likewise. + * gettext-tools/tests/lang-smalltalk: Likewise. + * gettext-tools/tests/lang-tcl: Likewise. + * gettext-tools/tests/lang-vala: Likewise. + * gettext-tools/tests/msgfmt-20: Likewise. + * gettext-tools/tests/plural-1: Likewise. + * NEWS: Mention the change. + +2025-06-19 Bruno Haible + + Fix 'make installcheck' failure on Cygwin. + * gettext-runtime/configure.ac (INSTALLED_LIBINTL): Add $LIBICONV. + +2025-06-19 Bruno Haible + + Deprecate the gfc-internal-format flag. + * gettext-tools/src/format-gfc-internal.c: Update comment. + * gettext-tools/doc/gettext.texi (PO Files): Mark gfc-internal-format as + deprecated. + (gfc-internal-format): Mention "up to GCC 14". + +2025-06-19 Bruno Haible + + xgettext: GCC-source: Disable gfc-format-internal recognition. + * gettext-tools/src/x-c.h (SCANNERS_C): Replace formatstring_gfc_internal with + NULL. + * gettext-tools/tests/format-gfc-internal-1: Remove file. + * gettext-tools/tests/Makefile.am (TESTS): Remove it. + +2025-06-19 Bruno Haible + + Strengthen gcc-internal-format: Check that %< %>, %r %R, %{ %} come in pairs. + * gettext-tools/src/format-gcc-internal.c (format_parse): New local variables + in_quote_group, in_color_group, in_url_group. Add pairing checks for %< %>, + %r %R, %{ %}. + * gettext-tools/tests/format-gcc-internal-1: Update. + * gettext-tools/tests/format-gcc-internal-2: Update. + +2025-06-19 Bruno Haible + + Update gcc-internal-format for GCC 15. + Reported by Roland Illig, Andrew Pinski, Jakub Jelinek in + . + Also reported by Roland Illig in + , . + + * gettext-tools/src/format-gcc-internal.c: Update for GCC 15. + * gettext-tools/tests/format-gcc-internal-1: Likewise. + * gettext-tools/tests/format-gcc-internal-2: Likewise. + * gettext-tools/doc/gettext.texi (gcc-internal-format): Likewise. + +2025-06-19 Bruno Haible + + gettext-runtime: Fix "make installcheck" failure on MSVC with --enable-shared. + * gettext-runtime/intl/Makefile.am (libintl.h): Insert '__declspec (dllimport)' + in the variable declarations, like in libgnuintl.h. + +2025-06-19 Bruno Haible + + gettext-tools: Implement 'installcheck' target. + * gettext-tools/install-tests/test-version.c: New file. + * gettext-tools/install-tests/test-api.c: New file. + * gettext-tools/install-tests/de.po: New file. + * gettext-tools/install-tests/Makefile.am: New file. + * gettext-tools/configure.ac (PATH_SEPARATOR, AUGMENT_SHLIBPATH): New variables. + (AC_CONFIG_FILES): Add install-tests/Makefile. + * gettext-tools/Makefile.am (SUBDIRS): Add install-tests. + +2025-06-19 Bruno Haible + + gettext-runtime: Implement 'installcheck' target. + * gettext-runtime/install-tests/test-version.c: New file. + * gettext-runtime/install-tests/test-api.c: New file. + * gettext-runtime/install-tests/itest.pot: New file. + * gettext-runtime/install-tests/locale/en_US/LC_MESSAGES/itest.mo: New file. + * gettext-runtime/install-tests/Makefile.am: New file. + * gettext-runtime/configure.ac (INSTALLED_LIBINTL, PATH_SEPARATOR, + AUGMENT_SHLIBPATH): New variables. + (AC_CONFIG_FILES): Add install-tests/Makefile. + * gettext-runtime/Makefile.am (SUBDIRS): Add install-tests. + +2025-06-19 Bruno Haible + + libtextstyle: Implement 'installcheck' target. + * libtextstyle/install-tests/test-version.c: New file. + * libtextstyle/install-tests/test-api.c: New file. + * libtextstyle/install-tests/Makefile.am: New file. + * libtextstyle/configure.ac (AUGMENT_SHLIBPATH): New variable. + (AC_CONFIG_FILES): Add install-tests/Makefile. + * libtextstyle/Makefile.am (SUBDIRS): Add install-tests. + +2025-06-14 Bruno Haible + + build: Simplify. + * gettext-runtime/configure.ac (LIBSCHED): Remove variable. + +2025-06-12 Bruno Haible + + Improve config.log traces. + * gettext-runtime/m4/progtest.m4 (AM_PATH_PROG_WITH_TEST): Emit the configure + line number into config.log. + +2025-06-08 Bruno Haible + + build: Simplify handling of exported symbols on Windows, part 2. + * gettext-tools/configure.ac (WINDOWS_MSVC): New conditional. + * gnulib-local/modules/gettext-tools-misc (Makefile.am): Re-add the + --export-all-symbols linker option. + * gettext-tools/src/Makefile.am (libgettextsrc_la_LDFLAGS): Re-add the + --export-all-symbols linker option. + +2025-06-07 Bruno Haible + + gettext.m4: Recognize the shared GNU libintl on MSVC. + Reported by Kirill Makurin + in . + + * gettext-runtime/m4/gettext.m4 (AM_GNU_GETTEXT): On MSVC, don't try to use + _nl_msg_cat_cntr. + * NEWS: Mention it. + +2025-06-07 Bruno Haible + + build: Simplify handling of exported symbols on Windows. + * gnulib-local/modules/gettext-tools-misc (Makefile.am): Don't compile + gettextlib-exports.c. Don't add now-redundant --export-all-symbols linker + option. Don't use GETTEXTLIB_EXPORTS_FLAGS. + * gettext-tools/src/Makefile.am (libgettextsrc_la_SOURCES): Don't add + gettextsrc-exports.c. + (libgettextsrc_la_LDFLAGS): Don't add now-redundant --export-all-symbols linker + option. + (libgettextsrc_la_CPPFLAGS): Don't add $(GETTEXTLIB_EXPORTS_FLAGS). + * gettext-tools/configure.ac (GETTEXTLIB_EXPORTS_FLAGS): Remove variable. + * gettext-tools/woe32dll/gettextlib-exports.c: Remove file. + * gettext-tools/woe32dll/gettextsrc-exports.c: Remove file. + * gettext-tools/woe32dll/export.h: Update comments. + +2025-06-06 Bruno Haible + + build: Fix build error on MSVC with --enable-shared. + * autogen.sh: Avoid the float-h-tests, since they reference the variables + gl_FLT_SNAN, gl_DBL_SNAN, gl_LDBL_SNAN. + +2025-06-06 Bruno Haible + + build: Fix build failure on Cygwin and mingw without preinstalled libunistring. + * gettext-tools/configure.ac: Define DLL_VARIABLE and LIBGETTEXTSRC_DLL_VARIABLE + on Cygwin and mingw like on MSVC. + +2025-06-06 Bruno Haible + + libtextstyle: Fix build failure on Cygwin < 3.4.6. + * libtextstyle/lib/Makefile.am (config.h): Don't rename the _imp_ variable + associated with the gl_get_setlocale_null_lock function. + +2025-06-05 Bruno Haible + + tests: xgettext-scheme-6: Fix potential conflict with xgettext-scheme-7. + * gettext-tools/tests/xgettext-scheme-6: Use common file name idiom. + +2025-06-05 Bruno Haible + + build: Fix "make install" in MSVC builds with --enable-shared. + The problem was that intl-8.dll was not installed with execute permissions. + + * gettext-runtime/intl/Makefile.am (install-exec-libintl): Use $(INSTALL), + not $(INSTALL_DATA), with libtool --mode=install. + * INSTALL.windows: Remove constraint to use --disable-shared on MSVC. + +2025-06-05 Bruno Haible + + build: Fix MSVC builds with --enable-shared. + This was a regression in commit 8e914861708ed459a2ae8157eb60d89375ab46cd + from 2023-09-06. + + Thanks to Kirill Makurin for fruitful discussions. + + * autogen.sh: Among the gnulib-tests, avoid the modules array-map-tests, + array-oset-tests, carray-list-tests, and uninorm/decomposing-form-tests, since + they use variables from libgettextlib. + * gettext-tools/configure.ac (GL_GNULIB_LIBUNISTRING_DLL_VARIABLE_NAME): New + variable. + (WOE32DLL): New C macro. + (DLL_VARIABLE): On MSVC with --enable-shared, define to '__declspec(dllexport)' + when compiling libgettextlib, and define to '__declspec(dllimport)' when + compiling the programs in src/. + (LIBGETTEXTSRC_DLL_VARIABLE): New C macro. + * gettext-tools/gnulib-lib/Makefile.am (AM_CPPFLAGS): Define the C macro + IN_LIBGETTEXTLIB. + * gettext-tools/src/Makefile.am (libgettextsrc_la_CPPFLAGS): Define the C macro + IN_LIBGETTEXTSRC. + * gettext-tools/src/format.h: Use LIBGETTEXTSRC_DLL_VARIABLE instead of + DLL_VARIABLE. + * gettext-tools/src/message.h: Likewise. + * gettext-tools/src/msgl-cat.h: Likewise. + * gettext-tools/src/plural-table.h: Likewise. + * gettext-tools/src/po-charset.h: Likewise. + * gettext-tools/src/po-error.h: Likewise. + * gettext-tools/src/read-catalog.h: Likewise. + * gettext-tools/src/read-po.h: Likewise. + * gettext-tools/src/read-properties.h: Likewise. + * gettext-tools/src/read-stringtable.h: Likewise. + * gettext-tools/src/sentence.h: Likewise. + * gettext-tools/src/write-po.h: Likewise. + * gettext-tools/src/write-properties.h: Likewise. + * gettext-tools/src/write-stringtable.h: Likewise. + * gettext-tools/src/xerror-handler.h: Likewise. + * gettext-tools/libgettextpo/Makefile.am (config.h): Override the value of + LIBGETTEXTSRC_DLL_VARIABLE. + * gettext-runtime/configure.ac (WOE32DLL): New C macro. + (DLL_VARIABLE): Define to empty always. + +2025-06-05 Bruno Haible + + Update to the newest gnulib. + +2025-06-05 Bruno Haible + + Fix compilation error on MSVC due to conflict of different stdlib.h files. + Reported by Kirill Makurin in + . + + * autogen.sh: Change gnulib-tool invocation for libgrep. + * gettext-tools/configure.ac (AC_CONFIG_FILES): Add libgrep/gnulib-lib/Makefile. + * gettext-tools/libgrep/Makefile.am: Don't include Makefile.gnulib. + (SUBDIRS): New variable. + (noinst_LIBRARIES): Add libgrep.a. + (AM_CPPFLAGS): Add -I options for gnulib-lib subdirectory. + (libgrep_a_DEPENDENCIES): New variable. + * gettext-tools/libgrep/gnulib-lib/Makefile.am: New file. + * gettext-tools/src/Makefile.am (LIBGREP): Add ../libgrep/gnulib-lib/libgnu.a. + +2025-06-03 Bruno Haible + + build: Fix some crashes when building with --enable-shared on MSVC, part 2. + * gettext-tools/woe32dll/gettextlib-exports.c: Export also + gl_carray_list_implementation, gl_hash_map_implementation, + gl_hash_set_implementation, gl_linked_list_implementation. + +2025-06-02 Bruno Haible + + tests: Fix test failure when rxgettext is not installed. + * gettext-tools/tests/format-ruby-3: Skip test if rxgettext is not installed. + +2025-06-02 Collin Funk + + Update a country name. + * gettext-tools/doc/ISO_3166: Use "Eswatini" instead of "Swaziland". + * gettext-tools/doc/iso-3166.texi: Likewise. + +2025-06-02 Bruno Haible + + Add a NEWS entry. + * NEWS: Mention the format string heuristic improvements. + +2025-06-02 Bruno Haible + + xgettext: Tcl: Improve heuristic for format strings. + * gettext-tools/src/format-tcl.c (struct spec): Add field + 'likely_intentional_directives'. + (format_parse): Set it to the number of directives that don't contain a space. + (format_is_unlikely_intentional): New function. + (formatstring_tcl): Use it. + * gettext-tools/tests/format-tcl-3: New file. + * gettext-tools/tests/Makefile.am (TESTS): Add it. + +2025-06-02 Bruno Haible + + xgettext: Ruby: Improve heuristic for format strings. + * gettext-tools/src/format-ruby.c (struct spec): Add field + 'likely_intentional_directives'. + (format_parse): Set it to the number of directives that don't contain a space. + (format_is_unlikely_intentional): New function. + (formatstring_ruby): Use it. + * gettext-tools/tests/format-ruby-3: New file. + * gettext-tools/tests/Makefile.am (TESTS): Add it. + +2025-06-02 Bruno Haible + + xgettext: Python: Improve heuristic for format strings. + * gettext-tools/src/format-python.c (struct spec): Add field + 'likely_intentional_directives'. + (format_parse): Set it to the number of directives that don't contain a space. + (format_is_unlikely_intentional): New function. + (formatstring_python): Use it. + * gettext-tools/tests/format-python-3: New file. + * gettext-tools/tests/Makefile.am (TESTS): Add it. + +2025-06-02 Bruno Haible + + xgettext: PHP: Improve heuristic for format strings. + * gettext-tools/src/format-php.c (struct spec): Add field + 'likely_intentional_directives'. + (format_parse): Set it to the number of directives that don't contain a space. + (format_is_unlikely_intentional): New function. + (formatstring_php): Use it. + * gettext-tools/tests/format-php-3: New file. + * gettext-tools/tests/Makefile.am (TESTS): Add it. + +2025-06-02 Bruno Haible + + xgettext: Perl: Improve heuristic for format strings. + * gettext-tools/src/format-perl.c (struct spec): Add field + 'likely_intentional_directives'. + (format_parse): Set it to the number of directives that don't contain a space. + (format_is_unlikely_intentional): New function. + (formatstring_perl): Use it. + * gettext-tools/tests/format-perl-3: New file. + * gettext-tools/tests/Makefile.am (TESTS): Add it. + +2025-06-02 Bruno Haible + + xgettext: librep: Improve heuristic for format strings. + * gettext-tools/src/format-librep.c (struct spec): Add field + 'likely_intentional_directives'. + (format_parse): Set it to the number of directives that don't contain a space. + (format_is_unlikely_intentional): New function. + (formatstring_librep): Use it. + * gettext-tools/tests/format-librep-3: New file. + * gettext-tools/tests/Makefile.am (TESTS): Add it. + +2025-06-02 Bruno Haible + + xgettext: JavaScript: Improve heuristic for format strings. + * gettext-tools/src/format-javascript.c (struct spec): Add field + 'likely_intentional_directives'. + (format_parse): Set it to the number of directives that don't contain a space. + (format_is_unlikely_intentional): New function. + (formatstring_javascript): Use it. + * gettext-tools/tests/format-javascript-3: New file. + * gettext-tools/tests/Makefile.am (TESTS): Add it. + +2025-06-02 Bruno Haible + + xgettext: Go: Improve heuristic for format strings. + * gettext-tools/src/format-go.c (struct spec): Add field + 'likely_intentional_directives'. + (format_parse): Set it to the number of directives that don't contain a space. + (format_is_unlikely_intentional): New function. + (formatstring_go): Use it. + * gettext-tools/tests/format-go-3: New file. + * gettext-tools/tests/Makefile.am (TESTS): Add it. + +2025-06-02 Bruno Haible + + xgettext: Emacs Lisp: Improve heuristic for format strings. + * gettext-tools/src/format-elisp.c (struct spec): Add field + 'likely_intentional_directives'. + (format_parse): Set it to the number of directives that don't contain a space. + (format_is_unlikely_intentional): New function. + (formatstring_elisp): Use it. + * gettext-tools/tests/format-elisp-3: New file. + * gettext-tools/tests/Makefile.am (TESTS): Add it. + +2025-06-02 Bruno Haible + + xgettext: D: Improve heuristic for format strings. + * gettext-tools/src/format-d.c (struct spec): Add field + 'likely_intentional_directives'. + (parse_upto): Increment it for each directive that don't contain a space. + (format_parse): Initialize it. + (format_is_unlikely_intentional): New function. + (formatstring_d): Use it. + * gettext-tools/tests/format-d-3: New file. + * gettext-tools/tests/Makefile.am (TESTS): Add it. + +2025-06-02 Bruno Haible + + xgettext: C++: Improve heuristic for Boost format strings. + * gettext-tools/src/format-boost.c (struct spec): Add field + 'likely_intentional_directives'. + (format_parse): Set it to the number of directives that don't contain a space. + (format_is_unlikely_intentional): New function. + (formatstring_boost): Use it. + * gettext-tools/tests/format-boost-3: New file. + * gettext-tools/tests/Makefile.am (TESTS): Add it. + +2025-06-02 Bruno Haible + + xgettext: C: Improve heuristic for format strings. + * gettext-tools/src/format-c-parse.h (struct spec): Add field + 'likely_intentional_directives'. + (format_parse_entrails): Set it to the number of directives that don't contain + a space. + * gettext-tools/src/format-c.c (format_is_unlikely_intentional): Also test the + 'likely_intentional_directives' field. + * gettext-tools/tests/format-c-6: New file. + * gettext-tools/tests/Makefile.am (TESTS): Add it. + +2025-06-02 Bruno Haible + + xgettext: awk: Improve heuristic for format strings. + * gettext-tools/src/format-awk.c (struct spec): Add field + 'likely_intentional_directives'. + (format_parse): Set it to the number of directives that don't contain a space. + (format_is_unlikely_intentional): New function. + (formatstring_awk): Use it. + * gettext-tools/tests/format-awk-3: New file. + * gettext-tools/tests/Makefile.am (TESTS): Add it. + +2025-06-02 Bruno Haible + + D: Fix handling of %% directive in format string parser. + * gettext-tools/src/format-d.c (parse_upto): Add matching FMTDIR_END also for + the %% directive. + +2025-06-01 Bruno Haible + + Avoid warnings from "gcc -Wextra". + Reported by Collin Funk in + . + + * gnulib-local/lib/gettext.h (gettext, dgettext, dcgettext): Silence + -Wbuiltin-declaration-mismatch warning. + +2025-06-01 Bruno Haible + + Fix compilation error on Solaris 11 (regr. 2025-05-28). + * gnulib-local/lib/gettext.h (gettext, dgettext, dcgettext): On Solaris, use + 'char *' as return type. + +2025-05-31 Bruno Haible + + build: Fix some crashes when building with --enable-shared on MSVC. + Reported by Kirill Makurin in + . + + * gnulib-local/lib/gl_carray_list.h.diff: New file. + * gnulib-local/lib/gl_hash_map.h.diff: New file. + * gnulib-local/lib/gl_hash_set.h.diff: New file. + * gnulib-local/lib/gl_linked_list.h.diff: New file. + * gnulib-local/Makefile.am (EXTRA_DIST): Add them. + +2025-05-31 Bruno Haible + + build: Mark automake 1.18 as supported. + * autogen.sh: Update comment. + * m4/fixautomake.m4 (FIX_MAKEFILE_DISTRIB): Likewise. + +2025-05-31 Bruno Haible + + doc: For MSVC, recommend to avoid the preinstalled libunistring. + This fixes an "initializer is not a constant" error upon use of uninorm_nfc. + Reported by Kirill Makurin in + . + + * INSTALL.windows: For MSVC, recommend --with-included-libunistring. + +2025-05-31 Bruno Haible + + build: Tweak option for MSVC. + Suggested by Kirill Makurin in + . + + * gettext-tools/src/Makefile.am (xgettext_LDFLAGS): Use an MSVC option with '-' + instead of '/', for resilience against the (unsupported) MSYS2. + +2025-05-28 Bruno Haible + + Avoid gcc -Wformat-security warnings with --disable-nls. + Reported by Holger Hoffstätte in + . + + * gnulib-local/lib/gettext.h (gettext, dgettext, dcgettext): With gcc in C mode, + define these as inline functions. + +2025-05-20 Bruno Haible + + xgettext: JavaScript: Parse RegExp literals according to ECMA-262 15th edition. + Reported by Christian Wasserthal in + . + + * gettext-tools/src/x-javascript.c (phase5_scan_regexp): Report an error when + end-of-line is reached. Parse character classes. Recognize more modifier flags. + * gettext-tools/tests/xgettext-javascript-2: Add two more test cases. + * NEWS: Mention the change. + +2025-05-16 Bruno Haible + + doc: Update, now that autopull.sh does more than a gnulib checkout. + * autogen.sh: Update comments. + * HACKING: Improve formatting. + +2025-05-11 Bruno Haible + + Refactor: Fix a compiler warning. + * gettext-tools/src/x-perl.c: Remove a stray ';'. + +2025-05-11 Bruno Haible + + Refactor: Fix typo in function name. + * gettext-tools/src/x-d.c (extract_from_template_instantiation): Renamed from + extract_from_template_instantation. + +2025-05-11 Bruno Haible + + Update after gnulib changed. + * gettext-tools/src/msgl-iconv.h (convert_string_desc_directly): Change result + type to rw_string_desc_t. + * gettext-tools/src/msgl-iconv.c (convert_string_desc_directly): Likewise. + * gettext-tools/src/its.c (_its_is_valid_simple_gen_xml): Omit casts to + 'char *'. Don't use sd_c_casecmp, sd_cmp as function pointers. + * gettext-tools/src/xg-encoding.h (string_desc_from_current_source_encoding): + Change result type to rw_string_desc_t. + * gettext-tools/src/xg-encoding.c (from_current_source_encoding): Return + converted result directly, without a cast. + (string_desc_from_current_source_encoding): Change result type to + rw_string_desc_t. Return converted result directly, without a cast. Invoke + sd_readwrite. + * gettext-tools/src/x-perl.c (get_here_document): Add benign cast. + (extract_quotelike_pass1, extract_quotelike_pass1_utf8): Change result type to + rw_string_desc_t. + (extract_quotelike, extract_triple_quotelike): Update. + (extract_quotelike_pass3): Add benign casts. + (interpolate_keywords): Don't call sd_set_char_at on a string_desc_t. + * gettext-tools/src/x-d.c (handle_comments, is_string_literal, + string_literal_accumulate_pieces, extract_from_function_call, + extract_from_function_call_without_args, extract_from_template_instantation, + extract_from_node): Omit casts to 'char *'. + * gettext-tools/src/x-go.c (string_literal_accumulate_pieces, + string_literal_value, scan_import_spec, get_type_from_type_identifier_node, + get_type_from_type_node, store_type_declaration, get_mvtypes_of_expression, + store_var_spec, store_const_spec, store_function_declaration, + augment_for_type_declaration, augment_for_parameter_list, augment_for_var_spec, + augment_for_const_spec, augment_for_short_variable_declaration, handle_comments, + extract_from_function_call, extract_from_node): Omit casts to 'char *'. + * gettext-tools/src/x-rust.c (handle_comments, string_literal_value): Omit casts + to 'char *'. Add benign casts. + (extract_from_function_call, extract_from_function_call_like, + extract_from_node): Omit casts to 'char *'. + * gettext-tools/src/x-typescript-impl.h (handle_comments, + sbru_prepend_lone_surrogate): Omit casts to 'char *'. + (sbru_xprepend_unicode): Add benign casts. + (string_literal_accumulate_pieces, string_literal_value, + extract_from_function_call, extract_from_node): Omit casts to 'char *'. + +2025-05-11 Bruno Haible + + Update to the newest gnulib. + +2025-05-07 Bruno Haible + + examples: Use infrastructure from gettext version 0.25. + * gettext-tools/examples/hello-*/configure.ac: Use AM_GNU_GETTEXT_VERSION with + version 0.25. + * gettext-tools/examples/hello-c++-kde/configure.in.in: Likewise. + +2025-05-07 Bruno Haible + + Update translations from TP. + * gettext-runtime/po/*.po: Update from TP. + * gettext-tools/po/*.po: Update from TP. + * gettext-tools/examples/po/*.po: Update from TP. + +2025-05-07 Bruno Haible + + Prepare for 0.25 release. + * gettext-runtime/doc/matrix.texi: Update from TP. + * gettext-runtime/doc/nls.texi (STATUS): Update. + * gettext-runtime/intl/libgnuintl.in.h (LIBINTL_VERSION): Bump. + * libtextstyle/version.sh: Update VERSION_NUMBER, RELEASE_DATE. + * gettext-tools/libgettextpo/gettext-po.in.h (LIBGETTEXTPO_VERSION): Bump. + * gettext-runtime/po/Makefile.in.in: Update Origin. + * gettext-runtime/intl/Makefile.am (LTV_*): Bump to 12:4:4. + * libtextstyle/lib/Makefile.am (LTV_*): Bump to 2:5:2. + * gettext-tools/libgettextpo/Makefile.am (LTV_*): Bump to 5:14:5. + * gettext-tools/misc/autopoint.in: Likewise. Accept version 0.25. + * gettext-tools/configure.ac (ARCHIVE_VERSION): Bump to 0.25. + +2025-05-07 Bruno Haible + + doc: Clarify how to obtain the various autoconf macros. + * gettext-tools/doc/gettext.texi (autoconf macros): Suggest to use gettextize or + autopoint. Discourage autoreconf. + +2025-05-07 Bruno Haible + + Update .gitignore. + +2025-05-07 Bruno Haible + + Update to a newer gnulib. + +2025-05-06 Bruno Haible + + intl-modula2: Try to fix a build failure on macOS. + * gettext-runtime/intl-modula2/Makefile.am (libintl_m2_la_LDFLAGS): Revert last + two commits. Instead, use -L and -l options. + +2025-05-06 Bruno Haible + + tests: Avoid xgettext-git-1 failure on AIX. + * gettext-tools/tests/xgettext-git-1: Don't use shell pattern matching with + braces. + +2025-05-05 Bruno Haible + + intl-modula2: Try to fix a build failure on macOS. + * gettext-runtime/intl-modula2/Makefile.am (libintl_m2_la_LIBADD): Avoid + automake error. + +2025-05-05 Bruno Haible + + intl-modula2: Try to fix a build failure on macOS. + * gettext-runtime/intl-modula2/Makefile.am (libintl_m2_la_LIBADD): New variable. + +2025-05-05 Bruno Haible + + PACKAGING: Revisit intl-d and intl-modula2 packaging. + * PACKAGING: Suggest packaging libintl_d and libintl_m2 each in a separate + package. + +2025-05-05 Bruno Haible + + Update after gnulib changed. + +2025-05-05 Bruno Haible + + tests: Avoid xgettext-git-1 failure on native Windows. + +2025-05-05 Bruno Haible + + Update to the newest gnulib. + +2025-05-05 Bruno Haible + + doc: xgettext: More doc regarding --generated. + Suggested by Vaclav Slavik + at . + + * gettext-tools/doc/xgettext.texi: Mention the --generated option in the + --files-from description. + +2025-05-05 Bruno Haible + + doc: Update list of examples. + * gettext-tools/doc/lang-c.texi: Update the list of examples. + * gettext-tools/doc/lang-ruby.texi: Mention the hello-ruby example. + +2025-05-05 Bruno Haible + + tests: Avoid a lang-modula2 failure. + * gettext-tools/tests/lang-modula2: Skip the test if gm2 is not working. + +2025-05-05 Bruno Haible + + tests: Add a comment regarding a lang-modula2 failure. + * gettext-tools/tests/lang-modula2: Add comment. + +2025-05-05 Bruno Haible + + intl-modula2: Fix a build failure on Ubuntu 22.04. + * gettext-runtime/configure.ac: Substitute M2SHLIBEXT. + * gettext-runtime/intl-modula2/Makefile.am (libintl_m2_la_LDFLAGS): Attempt + harder to find the libm2pim library. + +2025-05-05 Bruno Haible + + build: Avoid possible problems due to AC_REQUIRE in if/else branches. + * gettext-runtime/configure.ac: Use AS_IF when at least one of the if/else + branches invokes a complicated Autoconf macro. + * gettext-tools/configure.ac: Likewise. + +2025-05-04 Bruno Haible + + Avoid some clang -Wthread-safety-analysis warnings. + * gettext-tools/src/x-typescript-impl.h (sbru_init): Declare with + _GL_ATTRIBUTE_ACQUIRE_CAPABILITY. + (sbru_xdupfree_c): Declare with _GL_ATTRIBUTE_RELEASE_CAPABILITY. + +2025-05-04 Bruno Haible + + xgettext: Allow ignoring specific files in the POT-Creation-Date computation. + Reported by Vaclav Slavik + at . + + * autogen.sh (GNULIB_MODULES_TOOLS_FOR_SRC): Add hashkey-string, set. + * gettext-tools/src/xgettext.c: Include gl_set.h, gl_xset.h, gl_hash_set.h, + hashkey-string.h. + (generated_files): New variables. + (long_options): New option '--generated'. + (main): Initialize generated_files. Handle the option '--generated'. + (usage): Document the option '--generated'. + (finalize_header): Filter out the generated_files from the file list. + * gettext-tools/doc/xgettext.texi: Document the option '--generated'. + * gettext-tools/tests/xgettext-git-1: Test the --generated option. + * NEWS: Mention the new option. + +2025-05-04 Bruno Haible + + Update to the newest gnulib. + +2025-05-04 Bruno Haible + + Update release steps. + +2025-05-03 Bruno Haible + + doc: Clarify that the minimum needed GCC version is 4.4. + Rationale: With GCC version 4.1.2 or 4.2.1, all tree-sitter based extractors + in xgettext crash at runtime when compiled with optimization. Whereas + GCC 4.4.7 works fine. + + * DEPENDENCIES: State "GCC 4.4 or newer". + +2025-05-03 Bruno Haible + + xgettext: D: Work around a gcc miscompilation bug. + * gettext-tools/build-aux/tree-sitter-d-optimization-bug.diff: New file. + * autopull.sh: Apply it. + +2025-05-02 Bruno Haible + + Merge from 0.24.x branch: Prepare for 0.24.1 release. + * gettext-runtime/intl/libgnuintl.in.h (LIBINTL_VERSION): Bump. + * libtextstyle/version.sh: Update VERSION_NUMBER, RELEASE_DATE. + * gettext-tools/libgettextpo/gettext-po.in.h (LIBGETTEXTPO_VERSION): Bump. + * gettext-tools/misc/autopoint.in: Likewise. Accept version 0.24.1. + * gettext-tools/configure.ac (ARCHIVE_VERSION): Bump to 0.24.1. + +2025-05-02 Bruno Haible + + build: Update after recent gettextize fix. + * gettext-tools/misc/add-to-archive: Look up the *.m4 files in + $datadir/gettext/m4, not $datadir/aclocal. + +2025-05-02 Bruno Haible + + xgettext: Give a hint about --no-git when max_vc_mtime() took more than 10 sec. + * autogen.sh (GNULIB_MODULES_TOOLS_FOR_SRC): Add getrusage. + * gettext-tools/src/xgettext.c: Include . + (max_mtime): New function. + (finalize_header): Invoke it. + +2025-05-02 Bruno Haible + + xgettext: Add an option to opt-out of the use of git for the POT-Creation-Date. + Reported by Serhii Tereshchenko at . + + * autogen.sh (GNULIB_MODULES_TOOLS_FOR_SRC): Add stat-time. + * gettext-tools/src/xgettext.c: Include stat-time.h. + (xgettext_no_git): New variable. + (long_options): Add option '--no-git'. + (main): Handle the option --no-git. + (usage): Document the option --no-git. + (struct accumulator): New type, copied from gnulib/lib/vc-mtime.c. + (accumulate): New function, copied from gnulib/lib/vc-mtime.c. + (max_mtime_without_git): New function, based on gnulib/lib/vc-mtime.c. + (finalize_header): Conditionally invoke max_mtime_without_git instead of + max_vc_mtime. + * gettext-tools/doc/xgettext.texi: Document the option --no-git. + * NEWS: Mention the change. + +2025-05-02 Bruno Haible + + tests: Fix test failure with git versions < 2.23. + * gettext-tools/tests/xgettext-git-1: Use 'git checkout' instead of + 'git restore'. + +2025-05-02 Bruno Haible + + Update to the newest gnulib. + +2025-05-02 Bruno Haible + + xgettext: Speed up the computation of the POT-Creation-Date. + Reported by Serhii Tereshchenko, Arthur, Adam YS, Foucauld Degeorges + at . + + * gettext-tools/src/xgettext.c (has_some_mtimes, max_of_mtimes, some_mtimes_failed): Remove variables. + (files_for_vc_mtime): New variable. + (main): Initialize files_for_vc_mtime. Update files_for_vc_mtime instead of calling consider_vc_mtime. + (consider_vc_mtime): Remove function. + (read_exclusion_file, extract_from_file, extract_from_xml_file): Update files_for_vc_mtime instead of calling consider_vc_mtime. + (finalize_header): Call max_vc_mtime. + * NEWS: Mention the speedup. + +2025-05-02 Bruno Haible + + Update to the newest gnulib. + +2025-05-02 Bruno Haible + + tests: Add a test for xgettext's computation of the POT-Creation-Date. + * gettext-tools/tests/testdata/repo.tar.gz: New file. + * gettext-tools/tests/xgettext-git-1: New file. + * gettext-tools/tests/Makefile.am (TESTS): Add it. + (EXTRA_DIST): Add testdata/repo.tar.gz. + +2025-04-30 Bruno Haible + + build: Take the mem-hash-map module from Gnulib now, part 2. + * autogen.sh (GNULIB_MODULES_TOOLS_FOR_SRC): Add next-prime. + * gettext-tools/src/write-mo.c: Include next-prime.h. + * gettext-tools/src/write-qt.c: Likewise. + +2025-04-30 Bruno Haible + + build: Take the mem-hash-map module from Gnulib now. + * gnulib-local/lib/mem-hash-map.h: Remove file. + * gnulib-local/lib/mem-hash-map.c: Remove file. + * gnulib-local/modules/mem-hash-map: Remove file. + * gnulib-local/Makefile.am (EXTRA_DIST): Remove them. + +2025-04-30 Bruno Haible + + Update to the newest gnulib. + * gnulib-local/lib/hash.h.diff: Remove file. + * gnulib-local/lib/hash.c.diff: Remove file. + * gnulib-local/Makefile.am (EXTRA_DIST): Remove them. + * autogen.sh: Avoid module hashcode-string1. + +2025-04-29 Bruno Haible + + build: Ignore -Wduplicated-branches warnings. + * m4/more-warnings.m4 (gt_MORE_WARNINGS): Don't add the -Wduplicated-branches + option. + +2025-04-28 Bruno Haible + + Modula-2: Fix linking of libintl_m2 on non-ELF platforms. + * gettext-runtime/intl-modula2/Makefile.am (libintl_m2_la_LDFLAGS): Link with + libm2pim.la. + +2025-04-28 Bruno Haible + + tests: Support older GNU Modula-2 compilers. + * gettext-tools/tests/lang-modula2: Don't use the option -fscaffold-main. + +2025-04-25 Bruno Haible + + Modula-2 support: Simplify build system. + * gettext-runtime/intl-modula2/Makefile.am (nodist_m2include_HEADERS): New + variable. + (installdirs-modula2-sources, uninstall-modula2-sources): Remove rules. + (install-data-local, installdirs-local, uninstall-local): Remove dependencies. + +2025-04-25 Bruno Haible + + Modula-2 support: Fix VPATH builds. + * gettext-runtime/intl-modula2/Makefile.am (install-modula2-sources): Take + Libintl.def from the build dir, not from the source dir. + * gettext-tools/tests/lang-modula2: Search for Libintl.def in the build dir, + not in the source dir. + +2025-04-25 Bruno Haible + + examples: Add hello-modula2 example. + * gettext-tools/examples/hello-modula2/INSTALL: New file. + * gettext-tools/examples/hello-modula2/autogen.sh: New file. + * gettext-tools/examples/hello-modula2/autoclean.sh: New file. + * gettext-tools/examples/hello-modula2/hello.mod.in: New file. + * gettext-tools/examples/hello-modula2/Makefile.am: New file. + * gettext-tools/examples/hello-modula2/configure.ac: New file. + * gettext-tools/examples/hello-modula2/m4/Makefile.am: New file. + * gettext-tools/examples/hello-modula2/po/LINGUAS: New file. + * gettext-tools/examples/hello-modula2/po/Makefile.am: New file. + * gettext-tools/examples/installpaths.in: Define also libdir. + * gettext-tools/m4/Makefile.am (examplesbuildaux_DATA): Add modula2comp.m4. + * gettext-tools/examples/Makefile.am (EXAMPLESFILES, EXAMPLESDIRS): Add + hello-modula2. + * gettext-tools/examples/po/Makefile.am (POTFILES, SMALLPOTS): Update for + hello-modula2. + (hello-modula2.pot): New target. + (SMALLPOFILES_FOR_lang): Update for hello-modula2. + ($(srcdir)/../hello-modula2/po/$(LL).po): New rule. + * gettext-tools/examples/check-examples (func_check_autoclean_all, + func_check_distclean_all, func_check_maintainerclean_all, + func_check_maintainerclean_vpath_all, func_check_dist_all, + func_check_dist_vpath_all, func_check_install_all, func_check_uninstall_all, + func_check_distcheck_all, func_check_all): Handle hello-modula2 as well. + * gettext-tools/examples/README: Mention hello-modula2. + * gettext-tools/doc/lang-modula2.texi: Likewise. + * NEWS: Likewise. + +2025-04-25 Bruno Haible + + Modula-2 support: Add a unit test. + * autogen.sh (GNULIB_MODULES_TOOLS_OTHER): Add modula2, modula2comp-script. + * gettext-tools/configure.ac: Set and substitute BUILDMODULA2. + * gettext-tools/tests/init-env.in: Propagate MODULA2_CHOICE, BUILDMODULA2, M2C, + M2FLAGS. + * gettext-tools/tests/lang-modula2: New file. + * gettext-tools/tests/Makefile.am (TESTS): Add it. + +2025-04-25 Bruno Haible + + Modula-2 support: Add Modula-2 support in the tools. + * gettext-tools/doc/lang-modula2.texi: New file. + * gettext-tools/doc/Makefile.am (gettext_TEXINFOS): Add it. + * gettext-tools/doc/gettext.texi (PO Files): Mention modula2-format. + (No string concatenation): Mention string concatenation in Modula-2. + (Translators for other Languages): New subsection "Modula-2 Format Strings". + (List of Programming Languages): Include lang-modula2.texi. + * gettext-tools/doc/xgettext.texi: Document the -L Modula-2 option. + * gettext-tools/src/message.h (format_modula2): New enum value. + (NFORMATS): Increment. + * gettext-tools/src/message.c (format_language, format_language_pretty): Add an + entry for format_modula2. + * gettext-tools/src/format-modula2.c: New file. + * gettext-tools/src/format.h (formatstring_modula2): New declaration. + * gettext-tools/src/format.c (formatstring_parsers): Add formatstring_modula2. + * gettext-tools/src/x-modula2.h: New file. + * gettext-tools/src/x-modula2.c: New file. + * gettext-tools/src/xgettext.c: Include x-modula2.h. + (flag_table_modula2): New variable. + (main): Invoke init_flag_table_modula2, x_modula2_extract_all, + x_modula2_keyword. + (usage): Document the -L Modula-2 option. + (xgettext_record_flag): Support format_modula2. + (language_to_extractor, extension_to_language): Support Modula-2. + * gettext-tools/src/FILES: Mention format-modula2.c, x-modula2.h, x-modula2.c. + * gettext-tools/src/Makefile.am (noinst_HEADERS): Add x-modula2.h. + (FORMAT_SOURCE): Add format-modula2.c. + (xgettext_SOURCES): Add x-modula2.c. + * gettext-tools/libgettextpo/Makefile.am (libgettextpo_la_AUXSOURCES): Add + format-modula2.c. + * gettext-tools/po/POTFILES.in: Add src/format-modula2.c, src/x-modula2.c. + * gettext-tools/woe32dll/gettextsrc-exports.c: Export formatstring_modula2. + * gettext-tools/tests/format-modula2-1: New file. + * gettext-tools/tests/format-modula2-2: New file. + * gettext-tools/tests/xgettext-modula2-1: New file. + * gettext-tools/tests/xgettext-modula2-2: New file. + * gettext-tools/tests/Makefile.am (TESTS): Add the new tests. + * NEWS: Mention the Modula-2 support. + +2025-04-25 Bruno Haible + + Modula-2 support: Add the runtime library. + * gnulib-local/m4/modula2.m4: New file. + * gnulib-local/modules/modula2: New file. + * gnulib-local/Makefile.am (EXTRA_DIST): Add modula2.m4 and the 'modula2' + module. + * autogen.sh (GNULIB_MODULES_RUNTIME_OTHER): Add modula2, modula2comp-script. + * gettext-runtime/intl-modula2/Libintl.def.in: New file. + * gettext-runtime/intl-modula2/Libintl.mod: New file. + * gettext-runtime/intl-modula2/LibintlFromC.def: New file. + * gettext-runtime/intl-modula2/Makefile.am: New file. + * gettext-runtime/intl-modula2/HACKING: New file. + * gettext-runtime/configure.ac: Invoke gt_MODULA2_CHOICE, gt_MODULA2COMP. + Determine VALUE_OF_LC_* for each LC_* constant. Set the variable BUILDMODULA2 + and the Automake conditional BUILD_MODULA2. + * gettext-runtime/Makefile.am (SUBDIRS): Add intl-modula2. + * NEWS: Mention libintl_m2.so. + * gettext-runtime/NEWS: Likewise. + * PACKAGING: Add the interface and binary for the libintl_m2 library. + * DEPENDENCIES: Mention the Modula-2 compiler and runtime. + +2025-04-25 Bruno Haible + + Update to the newest gnulib. + +2025-04-25 Bruno Haible + + examples: Fix the D example. + * gettext-tools/Makefile.am (examplesbuildaux_DATA): Add dcomp.sh.in. + * gettext-tools/m4/Makefile.am (examplesbuildaux_DATA): Add dcomp.m4. + +2025-04-25 Bruno Haible + + examples: Fix the Go examples. + * gettext-tools/Makefile.am (examplesbuildaux_DATA): Add gocomp.sh.in. + * gettext-tools/m4/Makefile.am (examplesbuildaux_DATA): Add gocomp.m4. + +2025-04-25 Bruno Haible + + examples: Fix the C# examples. + * gettext-tools/m4/Makefile.am (examplesbuildaux_DATA): Add csharp.m4. + +2025-04-25 Bruno Haible + + examples: Fix reference to examples/build-aux/ directory (regr. 2005-03-22). + * gettext-tools/examples/installpaths.in (EXAMPLESCONFIGDIR): Correct value. + +2025-04-25 Bruno Haible + + tests: Fix the lang-d test. + * gettext-tools/tests/lang-d: Reencode in ISO-8859-1 encoding. + +2025-04-24 Bruno Haible + + intl: Export libintl_{new,dup,free}locale from libintl.so on OpenBSD. + Reported by Christian Weisgerber . + + * gnulib-local/lib/getlocalename_l-unsafe.c.diff: New file. + * gnulib-local/Makefile.am (EXTRA_DIST): Add it. + * gettext-runtime/intl/configure.ac (rpl_newlocale, rpl_duplocale, + rpl_freelocale): Redirect to symbols prefixed with 'libintl_', not '_libintl_'. + * gettext-runtime/intl/Makefile.am (BUILT_SOURCES): Add libgnuintl.h. + +2025-04-24 Bruno Haible + + Update to the newest gnulib. + +2025-04-23 Bruno Haible + + xgettext: D: Allow comments between the parts of concatenated string literals. + * gettext-tools/src/x-d.c (is_add_expression_with_tilde): New function. + (is_string_literal, string_literal_accumulate_pieces): Use it. + * gettext-tools/tests/xgettext-d-2: Add another test case regarding string + concatenation. + +2025-04-23 Bruno Haible + + xgettext: Go: More unit tests. + * gettext-tools/tests/xgettext-go-6: Add more test cases regarding string + concatenation. + +2025-04-23 Bruno Haible + + Refactor: Make format-lua.c more similar to format-elisp.c. + * gettext-tools/src/format-lua.c (format_parse): Allocate the final spec on the + heap only once parsing was successful. + +2025-04-22 Bruno Haible + + build: Simplify. + * gettext-runtime/configure.ac: Don't test whether setlocale exists. + +2025-04-16 Bruno Haible + + Update after gnulib changed. + * gitsub.sh: Update from gnulib. + +2025-04-15 Bruno Haible + + Update after gnulib changed. + * libtextstyle/autogen.sh: Don't avoid module 'locale-h'. vasnprintf now needs + localeconv, and localeconv depends on locale-h. + +2025-04-15 Bruno Haible + + build: Simplify D configuration-time support. + * gettext-runtime/configure.ac: Don't search for the D compiler a second time + (already done by gt_DCOMP). + * gettext-tools/configure.ac: Likewise. + +2025-04-02 Bruno Haible + + build: Simplify last commit. + * gettext-tools/src/Makefile.am (LIBXGETTEXTX): Remove variable. + +2025-04-02 Bruno Haible + + build: Make it possible to compile x-go.c with GCC 11 in 1 GB of RAM. + * gettext-tools/src/Makefile.am (LIBXGETTEXTX, libxgettextx_a_SOURCES, + libxgettextx_a_CPPFLAGS, libxgettextx_a_CFLAGS): New variables. + (xgettext_SOURCES): Remove x-go.c. + (noinst_LIBRARIES, xgettext_LDADD, xgettext_DEPENDENCIES): Add $(LIBXGETTEXTX). + +2025-04-02 Bruno Haible + + build: Make it possible to compile tree-sitter with GCC 11 in 1 GB of RAM. + * gettext-tools/src/Makefile.am (libxgettextts1_a_CFLAGS, + libxgettextts2_a_CFLAGS, libxgettextts3_a_CFLAGS, libxgettextts4_a_CFLAGS): New + variables. + +2025-04-02 Bruno Haible + + gettextize: Fix last commit. + * gettext-tools/m4/Makefile.am (OLD_M4_FILES): New variable. + (uninstall-macros): Delete only these files from @aclocaldir@. + +2025-04-02 Bruno Haible + + gettextize: Fix bad interactions between autoreconf and autopoint. + Reported by Sebastian Pipping + in . + + * gettext-tools/m4/Makefile.am (aclocaldir): Remove variable. + (pkgdatadir, macrosdir): Add variables. + (macros_DATA): Renamed from aclocal_DATA. + (install-data-local, uninstall-local, uninstall-macros): New targets. + * gettext-tools/misc/gettextize.in: Copy the *.m4 files from + $datadir/gettext/m4, not from $datadir/aclocal. + * gettext-tools/doc/gettext.texi (aclocal): Don't recommend to add option + --install to ACLOCAL_MFLAGS. Instead, recommend one-time use of --system-acdir. + * PACKAGING: Expect *.m4 files in $prefix/share/gettext/m4, not in + $prefix/share/aclocal. + * NEWS: Mention the fix. + +2025-04-02 Bruno Haible + + examples: Add hello-d example. + * gettext-tools/examples/hello-d/INSTALL: New file. + * gettext-tools/examples/hello-d/autogen.sh: New file. + * gettext-tools/examples/hello-d/autoclean.sh: New file. + * gettext-tools/examples/hello-d/hello.d.in: New file. + * gettext-tools/examples/hello-d/Makefile.am: New file. + * gettext-tools/examples/hello-d/configure.ac: New file. + * gettext-tools/examples/hello-d/m4/Makefile.am: New file. + * gettext-tools/examples/hello-d/po/LINGUAS: New file. + * gettext-tools/examples/hello-d/po/Makefile.am: New file. + * gettext-tools/examples/installpaths.in: Define also includedir. + * gettext-tools/examples/Makefile.am (EXAMPLESFILES, EXAMPLESDIRS): Add hello-d. + * gettext-tools/examples/po/Makefile.am (POTFILES, SMALLPOTS): Update for hello-d. + (hello-d.pot): New target. + (SMALLPOFILES_FOR_lang): Update for hello-d. + ($(srcdir)/../hello-d/po/$(LL).po): New rule. + * gettext-tools/examples/check-examples (func_check_autoclean_all, + func_check_distclean_all, func_check_maintainerclean_all, + func_check_maintainerclean_vpath_all, func_check_dist_all, + func_check_dist_vpath_all, func_check_install_all, func_check_uninstall_all, + func_check_distcheck_all, func_check_all): Handle hello-d as well. + * gettext-tools/examples/README: Mention hello-d. + * gettext-tools/doc/lang-d.texi: Likewise. + * NEWS: Likewise. + +2025-04-01 Bruno Haible + + D support: Add a unit test. + * autogen.sh (GNULIB_MODULES_TOOLS_OTHER): Add d, dcomp-script. + * gettext-tools/configure.ac: Set and substitute BUILDD. + * gettext-tools/tests/init-env.in: Propagate D_CHOICE, BUILDD. + * gettext-tools/tests/lang-d: New file. + * gettext-tools/tests/Makefile.am (TESTS): Add it. + +2025-04-01 Bruno Haible + + D support: Add D support in the tools. + * autopull.sh: Check out tree-sitter-d. Set TREE_SITTER_D_VERSION. + * autogen.sh (GNULIB_MODULES_TOOLS_FOR_SRC): Add unistr/u16-check, + unistr/u16-to-u8, unistr/u32-check, unistr/u32-to-u8. + * gettext-tools/build-aux/tree-sitter-d-portability.diff: New file. + * gettext-tools/configure.ac: Set TREE_SITTER_D_VERSION. + * gettext-tools/Makefile.am (EXTRA_DIST): Add the tree-sitter-d source code and + patch. + * gettext-tools/doc/lang-d.texi: New file. + * gettext-tools/doc/Makefile.am (gettext_TEXINFOS): Add it. + * gettext-tools/doc/gettext.texi (PO Files): Mention d-format. + (No string concatenation): Mention string concatenation and string interpolation + in D. + (Translators for other Languages): New subsection "D Format Strings". + (List of Programming Languages): Include lang-d.texi. + * gettext-tools/doc/xgettext.texi: Document the -L D option. + * gettext-tools/src/message.h (format_d): New enum value. + (NFORMATS): Increment. + * gettext-tools/src/message.c (format_language, format_language_pretty): Add an + entry for format_d. + * gettext-tools/src/format-d.c: New file, based on + gettext-tools/src/format-lisp.c. + * gettext-tools/src/format.h (formatstring_d): New declaration. + * gettext-tools/src/format.c (formatstring_parsers): Add formatstring_d. + * gettext-tools/src/x-d.h: New file. + * gettext-tools/src/x-d.c: New file, based on gettext-tools/src/x-rust.c and + gettext-tools/src/x-go.c. + * gettext-tools/src/html5-entities.h: New file. + * gettext-tools/src/xgettext.c: Include x-d.h. + (flag_table_d): New variable. + (main): Invoke init_flag_table_d, x_d_extract_all, x_d_keyword. + (usage): Document the -L D option. + (xgettext_record_flag): Support format_d. + (language_to_extractor, extension_to_language): Support D. + * gettext-tools/src/xg-message.c (decide_is_format, remember_a_message_plural): + Add better heuristic for c-format and d-format. + * gettext-tools/src/FILES: Mention format-d.c, x-d.h, x-d.c, html5-entities.h. + * gettext-tools/src/Makefile.am (noinst_HEADERS): Add x-d.h, html5-entities.h. + (FORMAT_SOURCE): Add format-d.c. + (libxgettextts2_a_SOURCES): Add d-parser.c, d-scanner.c. + (xgettext_SOURCES): Add x-d.c. + * gettext-tools/libgettextpo/Makefile.am (libgettextpo_la_AUXSOURCES): Add + format-d.c. + * gettext-tools/po/POTFILES.in: Add src/format-d.c, src/x-d.c. + * gettext-tools/woe32dll/gettextsrc-exports.c: Export formatstring_d. + * gettext-tools/tests/format-d-1: New file. + * gettext-tools/tests/format-d-2: New file. + * gettext-tools/tests/xgettext-d-1: New file. + * gettext-tools/tests/xgettext-d-2: New file. + * gettext-tools/tests/xgettext-d-3: New file. + * gettext-tools/tests/xgettext-d-4: New file. + * gettext-tools/tests/xgettext-d-5: New file, based on + gettext-tools/tests/xgettext-rust-5. + * gettext-tools/tests/xgettext-d-6: New file, based on + gettext-tools/tests/xgettext-rust-7. + * gettext-tools/tests/testdata/dprog.utf-8.d: New file. + * gettext-tools/tests/testdata/dprog.utf-8+bom.d: New file, based on + gettext-tools/tests/testdata/dprog.utf-8.d. + * gettext-tools/tests/testdata/dprog.utf-16be.d: New file, based on + gettext-tools/tests/testdata/dprog.utf-8.d. + * gettext-tools/tests/testdata/dprog.utf-16le.d: New file, based on + gettext-tools/tests/testdata/dprog.utf-8.d. + * gettext-tools/tests/testdata/dprog.utf-32be.d: New file, based on + gettext-tools/tests/testdata/dprog.utf-8.d. + * gettext-tools/tests/testdata/dprog.utf-32le.d: New file, based on + gettext-tools/tests/testdata/dprog.utf-8.d. + * gettext-tools/tests/Makefile.am (TESTS): Add the new tests. + (EXTRA_DIST): Add the new testdata files. + * NEWS: Mention the D support. + +2025-04-01 Bruno Haible + + D support: Add the runtime library. + * gnulib-local/m4/d.m4: New file. + * gnulib-local/modules/d: New file. + * gnulib-local/Makefile.am (EXTRA_DIST): Add d.m4 and the 'd' module. + * autogen.sh (GNULIB_MODULES_RUNTIME_OTHER): Add d, dcomp-script. + * gettext-runtime/intl-d/Makefile.am: New file. + * gettext-runtime/intl-d/gnu/libintl/package.d: New file. + * gettext-runtime/intl-d/gnu/libintl/libintl.d: New file. + * gettext-runtime/intl-d/gnu/libintl/internal/low.d: New file. + * gettext-runtime/configure.ac: Invoke gt_D_CHOICE, gt_DCOMP. Set the variable + BUILDD and the Automake conditional BUILD_D. + * gettext-runtime/Makefile.am (SUBDIRS): Add intl-d. + * NEWS: Mention libintl_d.a. + * gettext-runtime/NEWS: Likewise. + * PACKAGING: Add the sources and binary for the libintl_d library. + * DEPENDENCIES: Mention the D compiler and runtime. + +2025-04-01 Bruno Haible + + Update to the newest gnulib. + +2025-03-27 Bruno Haible + + Objective-C: xgettext: Strengthen tests. + * gettext-tools/tests/xgettext-objc-1: Add test cases with format strings. + +2025-03-25 Bruno Haible + + doc: Small updates. + Reported by Michael Chirico . + + * gettext-tools/doc/gettext.texi (The LANGUAGE variable): Rephrase + recommendation for Norwegian users. + (Header Entry): Remove statement about old versions of Emacs. + +2025-03-23 Bruno Haible + + Refactor: Use more of c-ctype.h. + * gettext-tools/src/format-awk.c (isdigit): Remove macro. + (format_parse): Use c_isdigit instead. + * gettext-tools/src/format-boost.c (isdigit): Remove macro. + (format_parse): Use c_isdigit instead. + * gettext-tools/src/format-c-parse.h (isdigit): Remove macro. + (format_parse_entrails): Use c_isdigit instead. + * gettext-tools/src/format-c++-brace.c (isdigit): Remove macro. + (format_parse): Use c_isdigit instead. + * gettext-tools/src/format-elisp.c (isdigit): Remove macro. + (format_parse): Use c_isdigit instead. + * gettext-tools/src/format-gcc-internal.c (isdigit): Remove macro. + (format_parse): Use c_isdigit instead. + * gettext-tools/src/format-gfc-internal.c (isdigit): Remove macro. + (format_parse): Use c_isdigit instead. + * gettext-tools/src/format-go.c (isdigit): Remove macro. + (format_parse): Use c_isdigit instead. + * gettext-tools/src/format-java-printf.c (isdigit): Remove macro. + (format_parse): Use c_isdigit instead. + * gettext-tools/src/format-javascript.c (isdigit): Remove macro. + (format_parse): Use c_isdigit instead. + * gettext-tools/src/format-librep.c (isdigit): Remove macro. + (format_parse): Use c_isdigit instead. + * gettext-tools/src/format-lua.c (isdigit): Remove macro. + (format_parse): Use c_isdigit instead. + * gettext-tools/src/format-pascal.c (isdigit): Remove macro. + (format_parse): Use c_isdigit instead. + * gettext-tools/src/format-perl.c (isdigit): Remove macro. + (c_isnonzerodigit): Renamed from isnonzerodigit. + (format_parse): Use c_isdigit instead of isdigit. + * gettext-tools/src/format-php.c (isdigit): Remove macro. + (format_parse): Use c_isdigit instead. + * gettext-tools/src/format-python.c (isdigit): Remove macro. + (format_parse): Use c_isdigit instead. + * gettext-tools/src/format-ruby.c (isdigit): Remove macro. + (format_parse): Use c_isdigit instead. + * gettext-tools/src/format-tcl.c (isdigit): Remove macro. + (format_parse): Use c_isdigit instead. + +2025-03-23 Bruno Haible + + Comment cleanup. + * gettext-tools/src/format-rust.c: Remove obsolete comment. + +2025-03-22 Bruno Haible + + Update after gnulib changed. + * gettext-runtime/intl/setlocale.c: Include setlocale-fixes.h instead of + setlocale-messages.h. + (setlocale_unixlike) [__ANDROID__]: Use setlocale_fixed instead of setlocale. + (setlocale_improved): On Android, use setlocale_fixed_null instead of setlocale. + +2025-03-22 Bruno Haible + + Update to the newest gnulib. + +2025-03-21 Bruno Haible + + Avoid bit rot of unused code. + * gettext-tools/src/format-lisp.c: Include attribute.h. + (intersection): Mark with MAYBE_UNUSED instead of '#ifdef unused'. + * gettext-tools/src/format-scheme.c (intersection): Likewise. + * gettext-tools/src/x-csharp.c (phase5_ungetc): Likewise. + * gettext-tools/src/x-php.c (phase3_ungetc): Likewise. + +2025-03-21 Bruno Haible + + Simplify strtoul() invocation. + * gnulib-local/lib/markup.c: Don't include . + (unescape_string_inplace): Don't reset or test errno. + +2025-03-21 Bruno Haible + + Work around an strtoul() misfeature. + * gettext-runtime/src/ngettext.c: Include . + (main): When parsing a nonnegative number, disallow leading whitespace and sign. + * gettext-tools/tests/tstngettext.c: Include . + (worker_thread): When parsing a nonnegative number, disallow leading whitespace + and sign. + * gnulib-local/lib/markup.c (unescape_string_inplace): When parsing a numeric + character entity, disallow leading whitespace and sign, and report a too large + number as "non-permitted character" rather than "Numerical result out of range". + * gettext-tools/src/msgfmt.c (main): When parsing the '-a' argument, disallow + leading whitespace and sign and check whether the value is a power of 2. + * gettext-tools/src/read-stringtable.c: Include c-ctype.h. + (comment_line_end): When parsing a line number, disallow leading whitespace and + sign. + +2025-03-20 Bruno Haible + + Refactor. + * gettext-tools/src/x-rust.c (ts_language_symbol, ts_language_field): Follow GNU + coding style. + * gettext-tools/src/x-go.c (ts_language_symbol, ts_language_field): Likewise. + * gettext-tools/src/x-typescript-impl.h (ts_language_symbol, ts_language_field): + Likewise. + +2025-03-20 Bruno Haible + + Makevars template: Fix small mistake. + * gettext-tools/po/Makevars.template: Correct statement about copyright. + * gettext-runtime/po/Makevars: Likewise. + * gettext-tools/po/Makevars: Likewise. + * gettext-tools/examples/po/Makefile.am: Likewise. + * gettext-tools/examples/hello-*/po/Makevars: Likewise. + * gettext-tools/examples/hello-*/po/Makefile.am: Likewise. + * gettext-tools/examples/hello-objc-gnustep/po/GNUmakefile: Likewise. + +2025-03-20 Bruno Haible + + doc: Fix small mistake. + * gettext-tools/doc/xgettext.texi: Correct statement about copyright. + +2025-03-11 Bruno Haible + + doc: Mention strings with embedded expressions in TypeScript. + * gettext-tools/doc/gettext.texi (No string concatenation): Mention + "template literals" in TypeScript. + +2025-03-11 Bruno Haible + + Add TypeScript support. + * autopull.sh: Check out tree-sitter-typescript. Set + TREE_SITTER_TYPESCRIPT_VERSION. + * gettext-tools/build-aux/tree-sitter-typescript-portability.diff: New file. + * gettext-tools/configure.ac: Set TREE_SITTER_TYPESCRIPT_VERSION. + * gettext-tools/Makefile.am (EXTRA_DIST): Add the tree-sitter-typescript source + code and patch. + * gettext-tools/doc/lang-typescript.texi: New file. + * gettext-tools/doc/Makefile.am (gettext_TEXINFOS): Add it. + * gettext-tools/doc/gettext.texi (No string concatenation): Mention string + concatenation in TypeScript. + (List of Programming Languages): Include lang-typescript.texi. + * gettext-tools/doc/xgettext.texi: Document the -L TypeScript and -L TSX + options. + * gettext-tools/src/x-typescript-impl.h: New file. + * gettext-tools/src/x-typescript.h: New file. + * gettext-tools/src/x-typescript.c: New file. + * gettext-tools/src/x-typescriptx.h: New file. + * gettext-tools/src/x-typescriptx.c: New file. + * gettext-tools/src/xgettext.c: Include x-typescript.h, x-typescriptx.h. + (flag_table_typescript, flag_table_typescriptx): New variables. + (main): Invoke init_flag_table_typescript, init_flag_table_typescriptx, + x_typescript_extract_all, x_typescriptx_extract_all, x_typescript_keyword, + x_typescriptx_keyword. + (usage): Document the -L TypeScript and -L TSX options. + (xgettext_record_flag): Support format_javascript with TypeScript and TSX. + (language_to_extractor, extension_to_language): Support TypeScript and TSX. + * gettext-tools/src/FILES: Mention x-typescript.h, x-typescript.c, + x-typescriptx.h, x-typescriptx.c, x-typescript-impl.h. + * gettext-tools/src/Makefile.am (noinst_LIBRARIES): Reference LIBXGETTEXTTS. + (noinst_HEADERS): Add x-typescript.h, x-typescriptx.h, x-typescript-impl.h. + (LIBXGETTEXTTS): Add libxgettextts3.a, libxgettextts4.a. + (libxgettextts3_a_SOURCES, libxgettextts3_a_CPPFLAGS): New variables. + (libxgettextts4_a_SOURCES, libxgettextts4_a_CPPFLAGS): New variables. + (xgettext_SOURCES): Add x-typescript.c, x-typescriptx.c. + * gettext-tools/tests/xgettext-javascript-6: Improve comments. + * gettext-tools/tests/xgettext-typescript-1: New file, based on + gettext-tools/tests/xgettext-javascript-1. + * gettext-tools/tests/xgettext-typescript-2: New file, based on + gettext-tools/tests/xgettext-javascript-2. + * gettext-tools/tests/xgettext-typescript-3: New file, based on + gettext-tools/tests/xgettext-javascript-3. + * gettext-tools/tests/xgettext-typescript-4: New file, based on + gettext-tools/tests/xgettext-javascript-4. + * gettext-tools/tests/xgettext-typescript-5: New file, based on + gettext-tools/tests/xgettext-javascript-5. + * gettext-tools/tests/xgettext-typescript-6: New file, based on + gettext-tools/tests/xgettext-javascript-6. + * gettext-tools/tests/xgettext-typescript-7: New file, based on + gettext-tools/tests/xgettext-javascript-7. + * gettext-tools/tests/Makefile.am (TESTS): Add the new tests. + * NEWS: Mention the TypeScript support. + +2025-03-11 Bruno Haible + + xgettext: Go: Refactor. + * gettext-tools/src/x-go.c (handle_comments): Remove 'contents' parameter. + (extract_from_function_call, extract_from_node): Update. + +2025-03-10 Bruno Haible + + examples: Fix "make install". + * gettext-tools/examples/Makefile.am (EXAMPLESFILES): Match actual file list. + +2025-03-09 Bruno Haible + + xgettext: Rust: Refactor, part 2. + * gettext-tools/src/x-rust.c (handle_comments, string_literal_value): Remove + 'contents' parameter. + (extract_from_function_call, extract_from_function_call_like, + extract_from_node): Update. + +2025-03-09 Bruno Haible + + Fix a comment. + * gettext-tools/src/x-javascript.h: Fix typo in comment. + +2025-03-08 Bruno Haible + + examples: Add hello-go-http example. + * gettext-tools/examples/hello-go-http/INSTALL: New file. + * gettext-tools/examples/hello-go-http/autogen.sh: New file. + * gettext-tools/examples/hello-go-http/autoclean.sh: New file. + * gettext-tools/examples/hello-go-http/example1/hello1ml.go.in: New file. + * gettext-tools/examples/hello-go-http/example1/go.mod.in: New file. + * gettext-tools/examples/hello-go-http/example1/Makefile.am: New file. + * gettext-tools/examples/hello-go-http/Makefile.am: New file. + * gettext-tools/examples/hello-go-http/configure.ac: New file. + * gettext-tools/examples/hello-go-http/m4/Makefile.am: New file. + * gettext-tools/examples/hello-go-http/po/LINGUAS: New file. + * gettext-tools/examples/hello-go-http/po/Makefile.am: New file. + * gettext-tools/examples/Makefile.am (EXAMPLESFILES, EXAMPLESDIRS): Add + hello-go-http. + * gettext-tools/examples/po/Makefile.am (POTFILES, SMALLPOTS): Update for + hello-go-http. + (hello-go-http.pot): New target. + (SMALLPOFILES_FOR_lang): Update for hello-go-http. + ($(srcdir)/../hello-go-http/po/$(LL).po): New rule. + * gettext-tools/examples/check-examples (func_check_autoclean_all, + func_check_distclean_all, func_check_maintainerclean_all, + func_check_maintainerclean_vpath_all, func_check_dist_all, + func_check_dist_vpath_all, func_check_install_all, func_check_uninstall_all, + func_check_distcheck_all, func_check_all): Handle hello-go-http as well. + * gettext-tools/examples/README: Mention hello-go-http. + * gettext-tools/doc/lang-go.texi: Likewise. + * NEWS: Likewise. + +2025-03-08 Bruno Haible + + examples: Add hello-go example. + * gettext-tools/examples/hello-go/INSTALL: New file. + * gettext-tools/examples/hello-go/autogen.sh: New file. + * gettext-tools/examples/hello-go/autoclean.sh: New file. + * gettext-tools/examples/hello-go/example1/hello1sl.go.in: New file. + * gettext-tools/examples/hello-go/example1/hello1ml.go.in: New file. + * gettext-tools/examples/hello-go/example1/go.mod.in: New file. + * gettext-tools/examples/hello-go/example1/Makefile.am: New file. + * gettext-tools/examples/hello-go/example2/hello2sl.go.in: New file. + * gettext-tools/examples/hello-go/example2/go.mod.in: New file. + * gettext-tools/examples/hello-go/example2/Makefile.am: New file. + * gettext-tools/examples/hello-go/example3/hello3ml.go.in: New file. + * gettext-tools/examples/hello-go/example3/go.mod.in: New file. + * gettext-tools/examples/hello-go/example3/Makefile.am: New file. + * gettext-tools/examples/hello-go/Makefile.am: New file. + * gettext-tools/examples/hello-go/configure.ac: New file. + * gettext-tools/examples/hello-go/m4/Makefile.am: New file. + * gettext-tools/examples/hello-go/po/LINGUAS: New file. + * gettext-tools/examples/hello-go/po/Makefile.am: New file. + * gettext-tools/examples/Makefile.am (EXAMPLESFILES, EXAMPLESDIRS): Add + hello-go. + * gettext-tools/examples/po/Makefile.am (POTFILES, SMALLPOTS): Update for + hello-go. + (hello-go.pot): New target. + (SMALLPOFILES_FOR_lang): Update for hello-go. + ($(srcdir)/../hello-go/po/$(LL).po): New rule. + * gettext-tools/examples/check-examples (func_check_autoclean_all, + func_check_distclean_all, func_check_maintainerclean_all, + func_check_maintainerclean_vpath_all, func_check_dist_all, + func_check_dist_vpath_all, func_check_install_all, func_check_uninstall_all, + func_check_distcheck_all, func_check_all): Handle hello-go as well. + * gettext-tools/examples/README: Mention hello-go. + * gettext-tools/doc/lang-go.texi: Likewise. + * NEWS: Likewise. + +2025-03-07 Bruno Haible + + tests: Fix autopoint-3 test failure on macOS. + * gettext-tools/tests/autopoint-3 (MAKE): Set to 'gmake' only if gmake exists. + +2025-03-07 Bruno Haible + + Go: Add integration test. + * autogen.sh (GNULIB_MODULES_RUNTIME_FOR_SRC): Add gocomp-script. + * gettext-tools/tests/init-env.in (GO_CHOICE, GO): New variables. + * gettext-tools/tests/lang-go: New file. + * gettext-tools/tests/Makefile.am (TESTS): Add it. + * HACKING: Document dependencies for lang-go. + +2025-03-07 Bruno Haible + + Update to the newest gnulib. + +2025-03-07 Bruno Haible + + tests: Fix autopoint-3 test failure on Solaris 11. + * gettext-tools/tests/autopoint-3 (MAKE): Set to 'gmake' on macOS, Solaris, AIX. + +2025-03-07 Bruno Haible + + Add Go support. + * autopull.sh: Check out tree-sitter-go. Set TREE_SITTER_GO_VERSION. + * autogen.sh (GNULIB_MODULES_TOOLS_FOR_SRC): Add carray-list, hash-map, + hash-set, xlist, xmap, xset, xstring-buffer-reversed. + * gettext-tools/build-aux/tree-sitter-go-portability.diff: New file. + * gettext-tools/configure.ac: Set TREE_SITTER_GO_VERSION. + * gettext-tools/Makefile.am (EXTRA_DIST): Add the tree-sitter-go source code and + patch. + * gettext-tools/doc/lang-go.texi: New file. + * gettext-tools/doc/Makefile.am (gettext_TEXINFOS): Add it. + * gettext-tools/doc/gettext.texi (PO Files): Mention go-format. + (No string concatenation): Mention string concatenation in Go. + (Translators for other Languages): New subsection "Go Format Strings". + (List of Programming Languages): Include lang-go.texi. + * gettext-tools/doc/xgettext.texi: Document the -L Go option. + * gettext-tools/src/message.h (format_go): New enum value. + (NFORMATS): Increment. + * gettext-tools/src/message.c (format_language, format_language_pretty): Add an + entry for format_go. + * gettext-tools/src/format-go.c: New file. + * gettext-tools/src/format.h (formatstring_go): New declaration. + * gettext-tools/src/format.c (formatstring_parsers): Add formatstring_go. + * gettext-tools/src/x-go.h: New file. + * gettext-tools/src/x-go.c: New file. + * gettext-tools/src/xgettext.c: Include x-go.h. + (flag_table_go): New variable. + (main): Invoke init_flag_table_go, x_go_extract_all, x_go_keyword. + (usage): Document the -L Go option. + (xgettext_record_flag): Support format_go. + (language_to_extractor, extension_to_language): Support Go. + * gettext-tools/src/FILES: Mention format-go.c, x-go.h, x-go.c. + * gettext-tools/src/Makefile.am (noinst_HEADERS): Add x-go.h. + (FORMAT_SOURCE): Add format-go.c. + (libxgettextts2_a_SOURCES): Add go-parser.c. + (xgettext_SOURCES): Add x-go.c. + * gettext-tools/libgettextpo/Makefile.am (libgettextpo_la_AUXSOURCES): Add + format-go.c. + * gettext-tools/woe32dll/gettextsrc-exports.c: Export formatstring_go. + * gettext-tools/tests/format-go-1: New file. + * gettext-tools/tests/format-go-2: New file. + * gettext-tools/tests/xgettext-go-1: New file. + * gettext-tools/tests/xgettext-go-2: New file. + * gettext-tools/tests/xgettext-go-3: New file. + * gettext-tools/tests/xgettext-go-4: New file. + * gettext-tools/tests/xgettext-go-5: New file. + * gettext-tools/tests/xgettext-go-6: New file. + * gettext-tools/tests/xgettext-go-7: New file. + * gettext-tools/tests/xgettext-go-8: New file. + * gettext-tools/tests/xgettext-go-9: New file. + * gettext-tools/tests/xgettext-go-10: New file. + * gettext-tools/tests/xgettext-go-11: New file. + * gettext-tools/tests/xgettext-go-12: New file. + * gettext-tools/tests/xgettext-go-13: New file. + * gettext-tools/tests/xgettext-go-14: New file. + * gettext-tools/tests/xgettext-go-15: New file. + * gettext-tools/tests/xgettext-go-16: New file. + * gettext-tools/tests/xgettext-go-17: New file. + * gettext-tools/tests/xgettext-go-18: New file. + * gettext-tools/tests/xgettext-go-stackovfl-1: New file. + * gettext-tools/tests/xgettext-go-stackovfl-2: New file. + * gettext-tools/tests/Makefile.am (TESTS): Add the new tests. + * NEWS: Mention the Go support. + +2025-03-04 Bruno Haible + + tests: Rust: Small fix. + * gettext-tools/tests/xgettext-rust-7: Fix a typo. + +2025-03-04 Bruno Haible + + tests: Prefer 'cat <<\EOF' to 'cat < + + build: Improve wording in './configure --help'. + Reported by Benno Schulenberg in + . + + * configure.ac: Use a dummy version number named 'package', not 'dummy'. + * gettext-runtime/configure.ac: Likewise. + * gettext-runtime/intl/configure.ac: Likewise. + * gettext-tools/configure.ac: Likewise. + * gettext-tools/examples/configure.ac: Likewise. + * libtextstyle/configure.ac: Likewise. + +2025-02-25 Bruno Haible + + examples: Use #| (previous) lines in the PO files. + * gettext-tools/examples/po/Makefile.am ($(POFILES), update-po): Pass --lang and + --previous options to msgmerge. + +2025-02-25 Bruno Haible + + examples: Use infrastructure from gettext version 0.24. + * gettext-tools/examples/hello-*/configure.ac: Use AM_GNU_GETTEXT_VERSION with + version 0.24. + * gettext-tools/examples/hello-c++-kde/configure.in.in: Likewise. + +2025-02-25 Bruno Haible + + examples: Make hello-rust pass the check. + * gettext-tools/examples/check-examples (func_check_dist): Ignore the + till-present 'target' directory in hello-rust. + (func_check_dist_vpath): Likewise. + +2025-02-25 Bruno Haible + + examples: Fix hello-c++-gnome3. + * gettext-tools/examples/hello-c++-gnome3/autoclean.sh: Remove po/Makefile.in.in. + +2025-02-25 Bruno Haible + + Update translations from TP. + * gettext-runtime/po/*.po: Update from TP. + * gettext-tools/po/*.po: Update from TP. + * gettext-tools/examples/po/*.po: Update from TP. + +2025-02-25 Bruno Haible + + Prepare for 0.24 release. + * gettext-runtime/doc/matrix.texi: Update from TP. + * gettext-runtime/doc/nls.texi (STATUS): Update. + * gettext-runtime/m4/gettext.m4: Update comments. + * gettext-runtime/m4/nls.m4: Likewise. + * gettext-runtime/m4/progtest.m4: Likewise. + * gettext-runtime/intl/libgnuintl.in.h (LIBINTL_VERSION): Bump. + * libtextstyle/version.sh: Update VERSION_NUMBER, RELEASE_DATE. + * gettext-tools/libgettextpo/gettext-po.in.h (LIBGETTEXTPO_VERSION): Bump. + * gettext-runtime/intl/Makefile.am (LTV_*): Bump to 12:3:4. + * libtextstyle/lib/Makefile.am (LTV_*): Bump to 2:4:2. + * gettext-tools/libgettextpo/Makefile.am (LTV_*): Bump to 5:13:5. + * gettext-runtime/src/envsubst.c (main): Update copyright year in --version + output. + * gettext-runtime/src/gettext.c (main): Likewise. + * gettext-runtime/src/gettext.sh.in (func_version): Likewise. + * gettext-runtime/src/ngettext.c (main): Likewise. + * gettext-tools/src/cldr-plurals.c (main): Likewise. + * gettext-tools/src/hostname.c (main): Likewise. + * gettext-tools/src/msgattrib.c (main): Likewise. + * gettext-tools/src/msgcat.c (main): Likewise. + * gettext-tools/src/msgcmp.c (main): Likewise. + * gettext-tools/src/msgcomm.c (main): Likewise. + * gettext-tools/src/msgconv.c (main): Likewise. + * gettext-tools/src/msgen.c (main): Likewise. + * gettext-tools/src/msgexec.c (main): Likewise. + * gettext-tools/src/msgfilter.c (main): Likewise. + * gettext-tools/src/msgfmt.c (main): Likewise. + * gettext-tools/src/msggrep.c (main): Likewise. + * gettext-tools/src/msginit.c (main): Likewise. + * gettext-tools/src/msgmerge.c (main): Likewise. + * gettext-tools/src/msgunfmt.c (main): Likewise. + * gettext-tools/src/msguniq.c (main): Likewise. + * gettext-tools/src/recode-sr-latin.c (main): Likewise. + * gettext-tools/src/urlget.c (main): Likewise. + * gettext-tools/src/xgettext.c (main): Likewise. + * gettext-tools/misc/convert-archive.in (func_version): Likewise. + * gettext-tools/misc/gettextize.in (func_version): Likewise. + * gettext-tools/misc/autopoint.in: Likewise. Accept version 0.24. + * gettext-tools/configure.ac (ARCHIVE_VERSION): Bump to 0.24. + * NEWS: Update. + +2025-02-25 Bruno Haible + + Update to the newest gnulib. + +2025-02-24 Bruno Haible + + xgettext: Implement a "reproducible" POT-Creation-Date value. + * autogen.sh (GNULIB_MODULES_TOOLS_FOR_SRC): Add vc-mtime. + * gettext-tools/src/xgettext.c: Include vc-mtime.h, msgl-header.h. + (has_some_mtimes, max_of_mtimes, some_mtimes_failed): New variables. + (long_options): Add --reference option. + (main): Implement --reference option. Invoke consider_vc_mtime for the + --files-from option. + (usage): Document the --reference option. + (consider_vc_mtime): New function. + (read_exclusion_file, extract_from_file, extract_from_xml_file: Invoke + consider_vc_mtime. + (construct_header): Don't compute the value of POT-Creation-Date here. + (finalize_header): Compute it here. + * gettext-tools/doc/xgettext.texi: Document the --reference option. + * NEWS: Mention the change. + +2025-02-24 Bruno Haible + + Update after gnulib changed. + * gettext-runtime/intl/setlocale.c: Include setlocale-messages.h. + (lc_messages_name): Remove variable. + +2025-02-24 Bruno Haible + + Update to the newest gnulib. + +2025-02-19 Bruno Haible + + Prepare for prerelease. + * gettext-tools/po/POTFILES.in: Update file list. + +2025-02-19 Bruno Haible + + Update to the newest gnulib. + +2025-02-18 Bruno Haible + + Update after gnulib changed. + +2025-02-18 Bruno Haible + + libtextstyle: Avoid an error localeconv_used_without_requesting_gnulib_module_localeconv on mingw. + * libtextstyle/autogen.sh: Avoid module 'locale-h'. + +2025-02-13 Bruno Haible + + examples: Add hello-c-http example. + * gettext-tools/examples/hello-c-http/INSTALL: New file. + * gettext-tools/examples/hello-c-http/autogen.sh: New file, based on + gettext-tools/examples/hello-c/autogen.sh. + * gettext-tools/examples/hello-c-http/autoclean.sh: New file, based on + gettext-tools/examples/hello-c/autoclean.sh. + * gettext-tools/examples/hello-c-http/hello-server.c: New file. + * gettext-tools/examples/hello-c-http/Makefile.am: New file, based on + gettext-tools/examples/hello-c/Makefile.am. + * gettext-tools/examples/hello-c-http/configure.ac: New file, based on + gettext-tools/examples/hello-c/configure.ac. + * gettext-tools/examples/hello-c-http/m4/Makefile.am: New file, copied from + gettext-tools/examples/hello-c/m4/Makefile.am. + * gettext-tools/examples/hello-c-http/po/POTFILES.in: New file. + * gettext-tools/examples/hello-c-http/po/Makevars: New file, copied from + gettext-tools/examples/hello-c/po/Makevars. + * gettext-tools/examples/hello-c-http/po/LINGUAS: New file, copied from + gettext-tools/examples/hello-c/po/LINGUAS. + * gettext-tools/examples/Makefile.am (EXAMPLESFILES, EXAMPLESDIRS): Add + hello-c-http. + * gettext-tools/examples/po/Makefile.am (POTFILES, SMALLPOTS): Update for + hello-c-http. + (hello-c-http.pot): New target. + (SMALLPOFILES_FOR_lang): Update for hello-c-http. + ($(srcdir)/../hello-c-http/po/$(LL).po): New rule. + * gettext-tools/examples/check-examples (func_check_autoclean_all, + func_check_distclean_all, func_check_maintainerclean_all, + func_check_maintainerclean_vpath_all, func_check_dist_all, + func_check_dist_vpath_all, func_check_install_all, func_check_uninstall_all, + func_check_distcheck_all, func_check_all): Handle hello-c-http as well. + * gettext-tools/examples/README: Mention hello-c-http. + * NEWS: Likewise. + +2025-02-13 Bruno Haible + + intl: Update info about Galician and Tamil. + * gettext-runtime/intl/setlocale.c (locales_with_principal_territory): Galician + is mostly spoken in Spain, not Portugal. Tamil is mostly spoken in India, not + Sri Lanka. + +2025-02-12 Bruno Haible + + msginit: Update info about Galician and Tamil. + * gettext-tools/src/msginit.c (catalogname_for_locale): Galician is mostly + spoken in Spain, not Portugal. Tamil is mostly spoken in India, not Sri Lanka. + +2025-02-11 Bruno Haible + + xgettext: Rust: Support named format string arguments. + Reported by Kévin Commaille + in . + + * autogen.sh (GNULIB_MODULES_TOOLS_FOR_SRC): Add unictype/property-xid-start, + unictype/property-xid-continue. + (GNULIB_MODULES_LIBGETTEXTPO): Likewise. + * gettext-tools/src/format-rust.c (struct named_arg): New type. + (struct spec): Add fields named_arg_count, named. + (named_arg_compare): New function. + (format_parse): Recognize named arguments. + (format_check): Search for differences also between the named arguments. + (format_print): Print also the named arguments. + * gettext-tools/tests/format-rust-1: Add test cases for named arguments. + * gettext-tools/tests/format-rust-2: Likewise. + * gettext-tools/doc/gettext.texi (rust-format): Describe rust-format in detail. + +2025-02-11 Bruno Haible + + xgettext: Rust: Fix comments. + * gettext-tools/src/x-rust.c: Fix reference to the Rust specification. + +2025-02-11 Bruno Haible + + Refactor. + * gettext-tools/src/format-ruby.c (format_parse): Use two different variables + named_allocated, numbered_allocated, instead of a single variable (assuming that + INVALID_MIXES_NAMED_UNNAMED is called when it should). + +2025-02-10 Ivan Krylov (tiny change) + + doc: Suggest to not use ngettext() in a specific case. + Edits from Ivan Krylov at + + and Bruno Haible. + + * gettext-tools/doc/gettext.texi (Plural forms): Suggest to not use ngettext() + in singular/plural cases without a number in the strings. + +2025-02-09 Bruno Haible + + Refactor: Allow for better static analysis, fixing some GCC analyzer warnings. + * gettext-tools/src/cldr-plural.y: Define SB_NO_APPENDF. + * gettext-tools/src/its.c: Likewise. + * gettext-tools/src/read-desktop.c: Likewise. + * gettext-tools/src/read-properties.c: Likewise. + * gettext-tools/src/x-awk.c: Likewise. + * gettext-tools/src/x-c.c: Likewise. + * gettext-tools/src/x-java.c: Likewise. + * gettext-tools/src/x-javascript.c: Likewise. + * gettext-tools/src/x-lua.c: Likewise. + * gettext-tools/src/x-perl.c: Likewise. + * gettext-tools/src/x-php.c: Likewise. + * gettext-tools/src/x-python.c: Likewise. + * gettext-tools/src/x-rst.c: Likewise. + * gettext-tools/src/x-smalltalk.c: Likewise. + * gettext-tools/src/x-vala.c: Likewise. + * gettext-tools/src/x-ycp.c: Likewise. + +2025-02-09 Bruno Haible + + xgettext: Rust: Refactor. + * gettext-tools/src/x-rust.c (contents): New variable. + (extract_from_function_call, extract_from_function_call_like, + extract_from_node): Remove the 'contents' parameter. + (extract_rust): Update. + +2025-02-09 Bruno Haible + + xgettext: Handle out-of-memory situation. + * gettext-tools/src/x-perl.c: Include xstring-desc.h. + (extract_quotelike): Call xsd_c instead of sd_c. + * gettext-tools/src/x-rust.c: Include xstring-desc.h. + (string_literal_value): Call xsd_c instead of sd_c. Call sb_xappend_desc + instead of sb_append_desc. + +2025-02-05 Bruno Haible + + doc: Sort programming languages consistently. + * gettext-tools/doc/gettext.texi (No string concatenation): Sort the programming + languages like elsewhere in the doc. + +2025-02-04 Bruno Haible + + build: Remove undesired output from autopull.sh. + * autopull.sh (func_git_clone_shallow): Silence the initial branch hint. + +2025-02-04 Bruno Haible + + Fix last two commits. + +2025-02-04 Bruno Haible + + libtextstyle: Improve namespacing. + * gettext-tools/libgettextpo/Makefile.am (COMPILATION_UNITS): Fix reference to + LIBOBJS variable. + (config.h): Remove leading part of the elements of + $(lts_libtextstyle_LTLIBOBJS). + +2025-02-04 Bruno Haible + + Update after gnulib changed. + * gettext-tools/libgettextpo/Makefile.am (config.h): Remove leading part of the + elements of $(libgnu_la_LIBADD). + +2025-02-04 Bruno Haible + + Update to the newest gnulib. + +2025-02-03 Bruno Haible + + Rust: Update .gitignore. + +2025-02-03 Bruno Haible + + Rust: Reference the example in the documentation. + * gettext-tools/doc/lang-rust.texi: Reference the example. + +2025-02-03 Bruno Haible + + Java: Doc comments. + * gettext-tools/doc/lang-java.texi: Add comments. + +2025-02-02 Bruno Haible + + Sort programming languages like in the documentation. + * gettext-tools/src/xgettext.c (usage): For the -L, -a, -k, --flag options, sort + the list of programming languages like in the documentation. Add Guile, Rust, + GSettings, that were forgotten earlier. + * gettext-tools/doc/xgettext.texi: Likewise. + * gettext-tools/examples/README: Sort the examples like the programming + languages in the documentation. + * gettext-tools/examples/Makefile.am (EXAMPLESFILES, EXAMPLESDIRS): Likewise. + * gettext-tools/examples/check-examples (func_check_autoclean_all, + func_check_distclean_all, func_check_maintainerclean_all, + func_check_maintainerclean_vpath_all, func_check_dist_all, + func_check_dist_vpath_all, func_check_install_all, func_check_uninstall_all, + func_check_distcheck_all, func_check_all): Likewise. + * gettext-tools/examples/po/Makefile.am (POTFILES, SMALLPOTS, hello-*.pot, + SMALLPOFILES_FOR_lang, $(srcdir)/../hello-*/po/$(LL).po): Likewise. + +2025-02-02 Bruno Haible + + tests: Fix a comment. + * gettext-tools/tests/format-lua-2: Fix comment. + +2025-02-01 Bruno Haible + + doc: Explain why localizations are in separate files. + * gettext-tools/doc/gettext.texi (Overview): Explain why the MO files should + not be embedded in the executable. + +2025-01-29 Bruno Haible + + tests: Fix a comment. + * gettext-tools/tests/lang-rust: Fix comment. + +2025-01-29 Bruno Haible + + intl: Fix undefined behaviour. + Found using clang's undefined-behaviour sanitizer: + CC="clang -fsanitize=undefined -fno-sanitize-recover=undefined". + It reported errors + dcigettext.c:1219:25: runtime error: applying non-zero offset 8 to null pointer + because the code was computing + outbuf = freemem + sizeof (size_t); + where freemem == NULL. + + * gettext-runtime/intl/dcigettext.c (_nl_find_msg): Initialize outbuf only after + having verified that freemem_size >= sizeof (size_t). + +2025-01-29 Bruno Haible + + xgettext: Rust: Fix xgettext-rust-stackovfl-* failures on MSVC 14/x86_64. + * autogen.sh (GNULIB_MODULES_TOOLS_OTHER): Add test-xfail. + * gettext-tools/src/Makefile.am (xgettext_LDFLAGS): On MSVC, use a larger + stack size. + +2025-01-28 Bruno Haible + + examples: Add hello-rust example. + * gettext-tools/examples/hello-rust/INSTALL: New file. + * gettext-tools/examples/hello-rust/autogen.sh: New file. + * gettext-tools/examples/hello-rust/autoclean.sh: New file. + * gettext-tools/examples/hello-rust/Cargo.toml.in: New file. + * gettext-tools/examples/hello-rust/src/main.rs.in: New file. + * gettext-tools/examples/hello-rust/Makefile.am: New file. + * gettext-tools/examples/hello-rust/configure.ac: New file. + * gettext-tools/examples/hello-rust/m4/Makefile.am: New file. + * gettext-tools/examples/hello-rust/po/Makefile.am: New file. + * gettext-tools/examples/hello-rust/po/LINGUAS: New file. + * gettext-tools/examples/Makefile.am (EXAMPLESFILES, EXAMPLESDIRS): Add + hello-rust. + * gettext-tools/examples/po/Makefile.am (POTFILES, SMALLPOTS): Update for + hello-rust. + (hello-rust.pot): New target. + (SMALLPOFILES_FOR_lang): Update for hello-rust. + ($(srcdir)/../hello-rust/po/$(LL).po): New rule. + * gettext-tools/examples/check-examples (func_check_autoclean_all, + func_check_distclean_all, func_check_maintainerclean_all, + func_check_maintainerclean_vpath_all, func_check_dist_all, + func_check_dist_vpath_all, func_check_install_all, func_check_uninstall_all, + func_check_distcheck_all, func_check_all): Handle hello-rust as well. + (func_check): Add a more useful body. + * gettext-tools/examples/README: Mention hello-rust. + * NEWS: Likewise. + +2025-01-28 Bruno Haible + + Rust: Add lang-rust unit test. + * gettext-tools/tests/init.cfg (this_test_is_longrunning_): New function. + * gettext-tools/tests/lang-rust: New file. + * gettext-tools/tests/Makefile.am (TESTS): Add it. + * HACKING: Reorder. Document prerequisites for Rust unit test. + +2025-01-28 Bruno Haible + + Add Rust support. + * autopull.sh (func_git_clone_shallow): New function, based on + gnulib/top/bootstrap-funclib.sh. + Check out tree-sitter and tree-sitter-rust. + Create gettext-tools/tree-sitter.cfg. + * autogen.sh (GNULIB_MODULES_TOOLS_FOR_SRC): Add strnlen, + unictype/property-white-space. + (GNULIB_MODULES_LIBGETTEXTPO): Likewise. + * gettext-tools/build-aux/tree-sitter-portability.diff: New file. + * gettext-tools/build-aux/tree-sitter-rust-portability.diff: New file. + * gettext-tools/configure.ac: Set TREE_SITTER_VERSION, TREE_SITTER_RUST_VERSION. + * gettext-tools/Makefile.am (EXTRA_DIST): Add the tree-sitter configuration, + source code, and patches. + * gettext-tools/doc/lang-rust.texi: New file. + * gettext-tools/doc/Makefile.am (gettext_TEXINFOS): Add it. + * gettext-tools/doc/gettext.texi (PO Files): Mention rust-format. + (Translators for other Languages): New subsection "Rust Format Strings". + (List of Programming Languages): Include lang-rust.texi. + * gettext-tools/doc/xgettext.texi: Document the -L Rust option. + * gettext-tools/src/message.h (format_rust): New enum value. + (NFORMATS): Increment. + * gettext-tools/src/message.c (format_language, format_language_pretty): Add an + entry for format_rust. + * gettext-tools/src/format-rust.c: New file. + * gettext-tools/src/format.h (formatstring_rust): New declaration. + * gettext-tools/src/format.c (formatstring_parsers): Add formatstring_rust. + * gettext-tools/src/x-rust.h: New file. + * gettext-tools/src/x-rust.c: New file. + * gettext-tools/src/xgettext.c: Include x-rust.h. + (main): Invoke init_flag_table_rust, x_rust_extract_all, x_rust_keyword. + (usage): Document the -L Rust option. + (xgettext_record_flag): Support format_rust. + (language_to_extractor, extension_to_language): Support Rust. + * gettext-tools/src/FILES: Mention format-rust.c, x-rust.h, x-rust.c. + * gettext-tools/src/Makefile.am (noinst_LIBRARIES): New variable. + (noinst_HEADERS): Add x-rust.h. + (AM_CPPFLAGS): Add a -I option for tree-sitter. + (FORMAT_SOURCE): Add format-rust.c. + (LIBXGETTEXTTS): New variable. + (libxgettextts1_a_SOURCES, libxgettextts1_a_CPPFLAGS): New variables. + (libxgettextts2_a_SOURCES, libxgettextts2_a_CPPFLAGS): New variables. + (xgettext_SOURCES): Add x-rust.c. + (xgettext_LDADD, xgettext_DEPENDENCIES): Add $(LIBXGETTEXTTS). + * gettext-tools/libgettextpo/Makefile.am (libgettextpo_la_AUXSOURCES): Add + format-rust.c. + * gettext-tools/woe32dll/gettextsrc-exports.c: Export formatstring_rust. + * gettext-tools/tests/format-rust-1: New file. + * gettext-tools/tests/format-rust-2: New file. + * gettext-tools/tests/xgettext-rust-1: Fix string literal concatenation test. + Fix -k options. + * gettext-tools/tests/xgettext-rust-2: Fix gettext invocations. + * gettext-tools/tests/xgettext-rust-3: Fix string literal concatenation test. + Test multiline strings. + * gettext-tools/tests/xgettext-rust-4: Tweak. + * gettext-tools/tests/xgettext-rust-5: Fix test identifier. + * gettext-tools/tests/xgettext-rust-6: New file. + * gettext-tools/tests/xgettext-rust-7: New file. + * gettext-tools/tests/xgettext-rust-stackovfl-1: New file. + * gettext-tools/tests/xgettext-rust-stackovfl-2: New file. + * gettext-tools/tests/xgettext-rust-stackovfl-3: New file. + * gettext-tools/tests/xgettext-rust-stackovfl-4: New file. + * gettext-tools/tests/Makefile.am (TESTS): Add the new tests. + * check-copyright-headers (func_check_file): Ignore tree-sitter files. + * NEWS: Mention the Rust support. + +2025-01-28 Kévin Commaille + + Prepare for Rust support. + * gettext-tools/tests/xgettext-rust-1: New file, based on + gettext-tools/tests/xgettext-csharp-1. + * gettext-tools/tests/xgettext-rust-2: New file, based on + gettext-tools/tests/xgettext-csharp-2. + * gettext-tools/tests/xgettext-rust-3: New file, based on + gettext-tools/tests/xgettext-csharp-3. + * gettext-tools/tests/xgettext-rust-4: New file, based on + gettext-tools/tests/xgettext-csharp-4. + * gettext-tools/tests/xgettext-rust-5: New file, based on + gettext-tools/tests/xgettext-csharp-7. + +2025-01-28 Bruno Haible + + examples: Improve autoclean.sh. + * gettext-tools/examples/hello-c-gnome3/autoclean.sh: Do also the equivalent of + "make maintainer-clean". + * gettext-tools/examples/hello-c++-gnome3/autoclean.sh: Likewise. + * gettext-tools/examples/hello-c++-kde/autoclean.sh: Likewise. + * gettext-tools/examples/hello-csharp/autoclean.sh: Likewise. + * gettext-tools/examples/hello-csharp-forms/autoclean.sh: Likewise. + * gettext-tools/examples/hello-pascal/autoclean.sh: Likewise. + +2025-01-28 Bruno Haible + + examples: Assume autoconf >= 2.60. + * gettext-tools/examples/hello-clisp/configure.ac: Compute localedir based on + ${datarootdir}, not ${datadir}. + * gettext-tools/examples/hello-gawk/configure.ac: Likewise. + * gettext-tools/examples/hello-guile/configure.ac: Likewise. + * gettext-tools/examples/hello-librep/configure.ac: Likewise. + * gettext-tools/examples/hello-pascal/configure.ac: Likewise. + * gettext-tools/examples/hello-perl/configure.ac: Likewise. + * gettext-tools/examples/hello-php/configure.ac: Likewise. + * gettext-tools/examples/hello-python/configure.ac: Likewise. + * gettext-tools/examples/hello-ruby/configure.ac: Likewise. + * gettext-tools/examples/hello-sh/configure.ac: Likewise. + * gettext-tools/examples/hello-smalltalk/configure.ac: Likewise. + +2025-01-28 Bruno Haible + + libtextstyle: Update after 2025-01-24 change. + +2025-01-28 Bruno Haible + + format-ruby: Fix error handling. + * gettext-tools/src/format-ruby.c (format_parse): Respect FDI_SET constraint. + +2025-01-28 Bruno Haible + + format-python-brace: Fix error handling. + * gettext-tools/src/format.h (FDI_SET): Improve comment. + * gettext-tools/src/format-python-brace.c (parse_directive): Improve error + messages. Respect FDI_SET constraint. + +2025-01-28 Bruno Haible + + Mention the GNU make requirement more prominently. + * NEWS: Mention the GNU make requirement. + +2025-01-28 Bruno Haible + + build: Update package version handling after gnulib changed. + * configure.ac: Drop postprocessing of git-version-gen output. + * gettext-runtime/configure.ac: Likewise. + * gettext-runtime/intl/configure.ac: Likewise. + * gettext-tools/configure.ac: Likewise. + * gettext-tools/examples/configure.ac: Likewise. + +2025-01-28 Bruno Haible + + Update to the newest gnulib. + +2025-01-25 Bruno Haible + + build: Update package version handling after gnulib changed. + * configure.ac: Invoke AC_INIT with arguments. Invoke gl_INIT_PACKAGE_VERSION + instead of gl_INIT_PACKAGE. + * gettext-runtime/configure.ac: Likewise. + * gettext-runtime/intl/configure.ac: Likewise. + * gettext-tools/configure.ac: Likewise. + * gettext-tools/examples/configure.ac: Likewise. + * libtextstyle/configure.ac: Likewise. + +2025-01-25 Bruno Haible + + Update to the newest gnulib. + +2025-01-24 Bruno Haible + + libtextstyle: Improve package version handling. + * libtextstyle/autogen.sh: Copy also m4/init-package-version.m4. + * libtextstyle/m4/init-package-version.m4: Remove file, moved to gnulib. + +2025-01-24 Bruno Haible + + Temporarily revert "po: Rename Makefile.in.in to Makefile.in." + +2025-01-24 Bruno Haible + + build: Update release-steps after problem with .version has been fixed. + +2025-01-23 Bruno Haible + + build: Improve package version handling. + * autogen.sh: Copy also m4/init-package-version.m4, m4/version-stamp.m4. + * configure.ac: Use gl_INIT_PACKAGE and gl_CONFIG_VERSION_STAMP. + * gettext-runtime/configure.ac: Use gl_INIT_PACKAGE. + * gettext-runtime/intl/configure.ac: Likewise. + * gettext-tools/configure.ac: Likewise. + * gettext-tools/examples/configure.ac: Likewise. + * Makefile.am (dist-tarball-version): New target. + ($(top_srcdir)/.version): Remove target. + +2025-01-23 Bruno Haible + + Update to the newest gnulib. + +2025-01-12 Bruno Haible + + format-kde-kuit: Fix test program. + * gettext-tools/src/format-kde-kuit.c: Fix compile-command. + (format_print): Make it compile. Print a '*' for each argument. + +2025-01-12 Bruno Haible + + format-kde: Fix test program. + * gettext-tools/src/format-kde.c (format_print): Print a '*' for each argument. + +2025-01-09 Bruno Haible + + Update .gitignore after the recent refactorings. + +2025-01-08 Bruno Haible + + Fix a test failure when LC_ALL is set to a non-English locale. + Reported by Simon Josefsson + in . + + * gettext-tools/tests/xgettext-its-2: When setting LC_MESSAGES, also unset + LC_ALL. + +2025-01-08 Bruno Haible + + xgettext: JavaScript: Parse recursive JSX expressions correctly. + Reported by at . + + * gettext-tools/src/x-javascript.c (phase5_get): Treat a '<' character in + level type level_embedded_js_in_xml like in the other level types. + * gettext-tools/tests/xgettext-javascript-6: Add another test case. + * NEWS: Mention the fix. + +2025-01-08 Bruno Haible + + build: Achieve better tarball compression ratios in "make dist". + Suggested by Lasse Collin + in . + + * configure.ac (am__tar): Sort the files by basename. + +2025-01-08 Bruno Haible + + Refactor: Use function str_endswith. + * libtextstyle/gnulib-local/lib/term-ostream.oo.c (term_ostream_create): Use + str_endswith. + * libtextstyle/gnulib-local/modules/term-ostream (Depends-on): Add + str_endswith. + +2025-01-08 Bruno Haible + + Refactor: Use function str_startswith. + * libtextstyle/gnulib-local/lib/term-ostream.oo.c (should_enable_hyperlinks): + Use str_startswith. + * libtextstyle/gnulib-local/modules/term-ostream (Depends-on): Add + str_startswith. + * gettext-tools/src/cldr-plural.y (yylex): Use str_startswith. + * gettext-tools/src/format-java.c (message_format_parse, choice_format_parse): + Likewise. + * gettext-tools/src/msgl-check.c (plural_help, check_header_entry): Likewise. + * gettext-tools/src/read-catalog-abstract.c (parse_comment_filepos): Likewise. + * gettext-tools/src/read-csharp.c (msgdomain_read_csharp): Likewise. + * gettext-tools/src/write-csharp.c (msgdomain_write_csharp): Likewise. + * gettext-tools/src/x-perl.c (skip_pod): Likewise. + * autogen.sh (GNULIB_MODULES_TOOLS_FOR_SRC, GNULIB_MODULES_LIBGETTEXTPO): Add + str_startswith. + +2025-01-03 Bruno Haible + + Update to the newest gnulib. + +2025-01-03 Bruno Haible + + Refactor: Use GNU coding style. + * gnulib-local/lib/markup.c (slow_name_validate, unescape_string_inplace, + clear_attributes, markup_parse_context_parse): Break lines before the operator. + +2025-01-03 Bruno Haible + + libtextstyle: Recognize number of colours in TERM=*-direct. + * libtextstyle/gnulib-local/lib/term-ostream.oo.c (term_ostream_create): Fix + recognition of TERM values that end in "-direct". + +2025-01-03 Bruno Haible + + libtextstyle: Add comments. + * libtextstyle/gnulib-local/lib/term-ostream.oo.c (term_ostream_create): Add + comments. + +2025-01-02 Bruno Haible + + Update after gnulib changed. + * gettext-runtime/src/envsubst.c (subst_from_stdin): Use sd_ function prefix + instead of string_desc_ function prefix. + * gettext-tools/src/its.c (set_doc_encoding_utf8, _its_is_valid_simple_gen_xml, + is_valid_xhtml_element, is_valid_html_element, is_no_end_html_element): + Likewise. + * gettext-tools/src/msgl-ascii.c (is_ascii_string_desc): Likewise. + * gettext-tools/src/msgl-iconv.c (convert_string_desc_directly): Likewise. + * gettext-tools/src/read-desktop.c (desktop_lex): Likewise. + * gettext-tools/src/x-awk.c (phase2_getc, phase3_get): Likewise. + * gettext-tools/src/x-c.c (phase5_get): Likewise. + * gettext-tools/src/x-perl.c (get_here_document, extract_quotelike_pass1, + extract_quotelike_pass1_utf8, extract_quotelike, extract_triple_quotelike, + extract_quotelike_pass3, extract_variable, interpolate_keywords, x_perl_prelex): + Likewise. + * gettext-tools/src/x-php.c (phase4_get): Likewise. + * gettext-tools/src/x-rst.c (parse_integer): Likewise. + * gettext-tools/src/x-ycp.c (phase2_getc, phase5_get): Likewise. + * gettext-tools/src/xg-encoding.c (string_desc_from_current_source_encoding): + Likewise. + +2025-01-02 Bruno Haible + + Update to the newest gnulib. + +2025-01-01 Bruno Haible + + msgfmt: Fix python-brace-format checking. + Reported at . + + * gettext-tools/src/format-python-brace.c (format_check): Fix comment. Do the + cmp > 0 check also if equality==false. + * gettext-tools/src/format-python.c (format_check): Fix comment. + * gettext-tools/src/format-ruby.c (format_check): Likewise. + * gettext-tools/src/format-sh.c (format_check): Likewise. + +2024-12-31 Bruno Haible + + When reading PO files, treat CRLF line terminators like LF, part 2. + * gettext-tools/tests/Makefile.am (EXTRA_DIST): Add testdata/crlf.pot. + +2024-12-31 Bruno Haible + + Merge from 0.23.x branch: Prepare for 0.23.1 release. + * gettext-runtime/intl/libgnuintl.in.h (LIBINTL_VERSION): Bump. + * libtextstyle/version.sh: Update VERSION_NUMBER, RELEASE_DATE. + * gettext-tools/libgettextpo/gettext-po.in.h (LIBGETTEXTPO_VERSION): Bump. + * gettext-runtime/intl/Makefile.am (LTV_*): Bump to 12:2:4. + * libtextstyle/lib/Makefile.am (LTV_*): Bump to 2:3:2. + * gettext-tools/libgettextpo/Makefile.am (LTV_*): Bump to 5:12:5. + * gettext-tools/misc/autopoint.in: Likewise. Accept version 0.23.1. + * gettext-tools/configure.ac (ARCHIVE_VERSION): Bump to 0.23.1. + +2024-12-31 Bruno Haible + + Merge from 0.23.x branch: Update NEWS file for release 0.23.1. + +2024-12-31 Bruno Haible + + doc: Update list of dependencies. + +2024-12-31 Bruno Haible + + When reading PO files, treat CRLF line terminators like LF. + Reported by Hendy Irawan at + . + + * gettext-tools/src/read-po-internal.h (MBFILE_MAX_PUSHBACK): Renamed from + NPUSHBACK. Increase by 1. + (struct mbfile): Rename field 'have_pushback' to 'pushback_count'. + * gettext-tools/src/read-po-lex.c (mbfile_init): Update. + (mbfile_getc): Read pushed-back character before testing for sticky EOF. + (mbfile_ungetc): Update. + (mbfile_getc_normalized): New function. + (lex_getc): Invoke mbfile_getc_normalized instead of mbfile_getc. + * gettext-tools/tests/testdata/crlf.pot: New file. + * gettext-tools/tests/msgcat-23: New file. + * gettext-tools/tests/Makefile.am (TESTS): Add it. + +2024-12-28 Bruno Haible + + Update after gnulib changed. + * autogen.sh (GNULIB_MODULES_RUNTIME_FOR_SRC, GNULIB_MODULES_TOOLS_FOR_SRC, + GNULIB_MODULES_TOOLS_FOR_SRC_COMMON_DEPENDENCIES, GNULIB_MODULES_TOOLS_OTHER, + GNULIB_MODULES_LIBGETTEXTPO): Use the new names of renamed gnulib modules. + * gnulib-local/modules/backupfile (Depends-on): Likewise. + * gnulib-local/modules/closeout (Depends-on): Likewise. + * gnulib-local/modules/libtextstyle-dummy (Depends-on): Likewise. + * gnulib-local/modules/libxml (Depends-on): Likewise. + * libtextstyle/gnulib-local/modules/fd-ostream (Depends-on): Likewise. + * libtextstyle/gnulib-local/modules/html-styled-ostream (Depends-on): Likewise. + * libtextstyle/gnulib-local/modules/iconv-ostream (Depends-on): Likewise. + * libtextstyle/gnulib-local/modules/memory-ostream (Depends-on): Likewise. + * libtextstyle/gnulib-local/modules/noop-styled-ostream (Depends-on): Likewise. + * libtextstyle/gnulib-local/modules/term-ostream (Depends-on): Likewise. + +2024-12-28 Bruno Haible + + Update to the newest gnulib. + +2024-12-27 Bruno Haible + + build: Fix "make dist" result when run in a VPATH build. + Suggested by Simon Josefsson in + . + + * Makefile.am (gen-ChangeLogs): Consider $(srcdir). + +2024-12-24 Bruno Haible + + intl: Support the UTF-8 environment on native Windows. + Reported by Lasse Collin in + . + + * gettext-runtime/intl/setlocale.c: Include . + (setlocale_unixlike): In the UTF-8 environment, append a suffix ".65001" + to the locale names passed to the native setlocale(). + +2024-12-24 Bruno Haible + + intl: Handle LC_MESSAGES correctly on native Windows. + * gettext-runtime/intl/setlocale.c (libintl_setlocale): Revamp the LC_ALL case + if LC_MESSAGES is 1729. + +2024-12-24 Bruno Haible + + Update to the newest gnulib. + +2024-12-24 Bruno Haible + + lang-python-*: Fix test failures on mingw with UCRT. + * gettext-tools/tests/lang-python-1: Disable ISO8859_LOCALE_UNSUPPORTED for + Python 3. Set PYTHONIOENCODING environment variable. + * gettext-tools/tests/lang-python-2: Likewise. + +2024-12-23 Bruno Haible + + libtextstyle: Fix a test failure on MSYS2. + * libtextstyle/gnulib-local/tests/test-term-ostream-xterm-msys2.out: New file. + * libtextstyle/gnulib-local/tests/test-term-ostream-xterm.sh: Use it as an + expected test result. + * libtextstyle/gnulib-local/modules/term-ostream-tests (Files): Add it. + * libtextstyle/Makefile.am (EXTRA_DIST): Likewise. + +2024-12-23 Bruno Haible + + Fix test failure of lang-ruby. + * gettext-tools/tests/lang-ruby: Skip the test if 'rxgettext' is not installed. + +2024-12-23 Bruno Haible + + examples: Don't fail build if rxgettext is not installed. + * gettext-tools/examples/po/xsmallpot.sh: Ignore a 'make' failure in the + hello-ruby example. + * gettext-tools/examples/po/hello-ruby.pot: New generated file. + +2024-12-23 Bruno Haible + + examples: Don't fail configuration of hello-objc if no Objective-C compiler is found, part 2. + * gettext-tools/examples/po/xsmallpot.sh: Don't remove the m4_pushdef, m4_popdef + lines from hello-objc*/configure.ac. + +2024-12-23 Bruno Haible + + examples: Find the Objective-C compiler out-of-the-box on AlmaLinux 9 systems. + * gettext-tools/examples/hello-objc-gnome2/configure.ac: Invoke AC_PROG_OBJC + with a customized search list. Don't invoke AC_PROC_CC. + +2024-12-23 Bruno Haible + + examples: Don't fail configuration of hello-objc if no Objective-C compiler is found. + * gettext-tools/examples/hello-objc/configure.ac: Map AC_MSG_FAILURE to + AC_MSG_WARN. + +2024-12-20 Bruno Haible + + po: Remove a comment that is not valid any more since 2002-01-07. + The comment "Target 'all' must not depend on target '$(DOMAIN).pot-update'" + does not hold any more: + all <- all-yes <- $(srcdir)/stamp-po <- $(srcdir)/$(DOMAIN).pot + and the latter rule executes + $(MAKE) $(DOMAIN).pot-update + + * gettext-runtime/po/Makefile.in: Remove comment. + * gettext-tools/examples/po/Makefile.am: Likewise. + * gettext-tools/examples/*/po/Makefile.am: Likewise. + * gettext-tools/examples/hello-objc-gnustep/po/GNUmakefile: Likewise. + +2024-12-18 Bruno Haible + + New example 'hello-c++-gnome3'. + * gettext-tools/examples/hello-c++-gnome3: New directory, based on + gettext-tools/examples/hello-c-gnome3. + * gettext-tools/examples/Makefile.am (EXAMPLESFILES, EXAMPLESDIRS): Update. + * gettext-tools/examples/po/Makefile.am (POTFILES, SMALLPOTS, + SMALLPOFILES_FOR_lang): Update. + * gettext-tools/examples/README: Update. + * gettext-tools/examples/check-examples: Handle this directory as well. + * NEWS: Mention the new example. + * HACKING: Mention the gtkmm dependency. + +2024-12-18 Bruno Haible + + hello-c-gnome3: Document build dependencies. + * HACKING: Mention Gtk3 dependency. + +2024-12-18 Bruno Haible + + hello-c-gnome3: Add a simpler "hello world" program. + * gettext-tools/examples/hello-c-gnome3/README: New file. + * gettext-tools/examples/hello-c-gnome3/hello2.c: New file, based on + gettext-tools/examples/hello-c-gnome3/hello.c. + * gettext-tools/examples/hello-c-gnome3/hello2.desktop.in.in: New file, based on + gettext-tools/examples/hello-c-gnome3/hello.desktop.in.in. + * gettext-tools/examples/hello-c-gnome3/hello2.gresource.xml: New file, based on + gettext-tools/examples/hello-c-gnome3/hello.gresource.xml. + * gettext-tools/examples/hello-c-gnome3/hello2.ui: Renamed from + gettext-tools/examples/hello-c-gnome3/hello.ui. + * gettext-tools/examples/hello-c-gnome3/hello2.gschema.xml: New file, based on + gettext-tools/examples/hello-c-gnome3/hello.gschema.xml. + * gettext-tools/examples/hello-c-gnome3/hello.c: Greatly simplified. + * gettext-tools/examples/hello-c-gnome3/hello.ui: Use an element + instead of a