Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
26 commits
Select commit Hold shift + click to select a range
05f9e20
GHA: test msys2 clang and ucrt systems
nulano Jan 13, 2023
0546eb9
msys2: update install documentation
nulano Jan 13, 2023
d367a31
update installation instructions for MSYS2 UCRT64
nulano Feb 2, 2023
eba0679
replace msys2 package check with msystem check
nulano Feb 2, 2023
fa09950
GHA: use pacboy to install msys2 packages
nulano Feb 2, 2023
f69347e
GHA: skip some msys2 jobs
nulano Feb 2, 2023
2e469bd
update CI targets table
nulano Feb 2, 2023
286db61
make sure pacboy is installed
nulano Feb 2, 2023
b853854
simplify MSYS2 testing on GHA
nulano Feb 12, 2023
469f9e3
Updated mergify.yml
nulano Jun 25, 2023
2dc6840
Merge branch 'main' into msys
radarhere Nov 30, 2024
8d25ee1
Merge branch 'main' into msys
radarhere Nov 30, 2024
1184c01
Merge branch 'main' into msys
radarhere Jan 15, 2025
bf2ee41
Use python instead of python3 packages
radarhere Jan 15, 2025
40a874d
Merge branch 'main' into msys
radarhere Feb 7, 2025
799d908
Merge branch 'main' into msys
radarhere Mar 3, 2025
75bb959
Merge branch 'main' into msys
radarhere Mar 18, 2025
dcab6e6
Merge branch 'main' into msys
radarhere Jun 10, 2025
99c1146
Merge branch 'main' into msys
radarhere Aug 4, 2025
8f6b6b9
Merge branch 'main' into msys
radarhere Aug 26, 2025
75cfa5b
Merge branch 'main' into msys
radarhere Oct 16, 2025
943ed5f
Merge branch 'main' into msys
radarhere Dec 5, 2025
4a55cbd
Updated actions/checkout to v6
radarhere Dec 5, 2025
f612e01
Merge branch 'main' into msys
radarhere Jan 18, 2026
dbcfdd5
Merge branch 'main' into msys
radarhere Jan 20, 2026
d6b0b0b
Merge branch 'main' into msys
radarhere Apr 2, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/mergify.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ pull_request_rules:
- status-success=Test Successful
- status-success=Docker Test Successful
- status-success=Windows Test Successful
- status-success=MinGW
- status-success=MSYS2 Test Successful
actions:
merge:
method: merge
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Test MinGW
name: Test MSYS2

on:
push:
Expand Down Expand Up @@ -33,16 +33,24 @@ env:
jobs:
build:
runs-on: windows-latest

strategy:
fail-fast: false
matrix:
include:
# skip to save CI time:
# see https://github.com/python-pillow/Pillow/pull/6888#issuecomment-1400392821
# - msystem: "UCRT64"
- msystem: "CLANG64"
- msystem: "MINGW64"
defaults:
run:
shell: bash.exe --login -eo pipefail "{0}"
env:
MSYSTEM: MINGW64
MSYSTEM: ${{ matrix.msystem }}
CHERE_INVOKING: 1

timeout-minutes: 30
name: "MinGW"
name: MSYS2 ${{ matrix.msystem }}

steps:
- name: Checkout Pillow
Expand All @@ -57,39 +65,52 @@ jobs:
- name: Install dependencies
run: |
pacman -S --noconfirm \
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Add --needed

mingw-w64-x86_64-freetype \
mingw-w64-x86_64-gcc \
mingw-w64-x86_64-ghostscript \
mingw-w64-x86_64-lcms2 \
mingw-w64-x86_64-libavif \
mingw-w64-x86_64-libimagequant \
mingw-w64-x86_64-libjpeg-turbo \
mingw-w64-x86_64-libraqm \
mingw-w64-x86_64-libtiff \
mingw-w64-x86_64-libwebp \
mingw-w64-x86_64-openjpeg2 \
mingw-w64-x86_64-python-numpy \
mingw-w64-x86_64-python-olefile \
mingw-w64-x86_64-python-pip \
mingw-w64-x86_64-python-pytest \
mingw-w64-x86_64-python-pytest-cov \
mingw-w64-x86_64-python-pytest-timeout \
mingw-w64-x86_64-python-pyqt6
make \
pactoys \
subversion

pacboy -S --noconfirm \
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Add --needed

freetype:p \
gcc:p \
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"gcc" - > "cc"

ghostscript:p \
lcms2:p \
libimagequant:p \
libjpeg-turbo:p \
libraqm:p \
libtiff:p \
libwebp:p \
openjpeg2:p \
python-numpy:p \
python-olefile:p \
python-pip:p \
python-pyqt6:p

python3 -m pip install pyroma pytest pytest-cov pytest-timeout
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

pytest, pytest-cov, and pytest-timeout can be (preferably?) installed by pacboy above


pushd depends && ./install_extra_test_images.sh && popd

- name: Build Pillow
run: CFLAGS="-coverage" python3 -m pip install .
run: .ci/build.sh

- name: Test Pillow
run: |
python3 selftest.py --installed
.ci/test.sh
run: .ci/test.sh

- name: After success
run: .ci/after_success.sh

- name: Upload coverage
uses: codecov/codecov-action@v5
with:
files: ./coverage.xml
flags: GHA_Windows
name: "MSYS2 MinGW"
token: ${{ secrets.CODECOV_ORG_TOKEN }}
name: MSYS2 ${{ matrix.msystem }}

success:
permissions:
contents: none
needs: build
runs-on: ubuntu-latest
name: MSYS2 Test Successful
steps:
- name: Success
run: echo MSYS2 Test Successful
50 changes: 31 additions & 19 deletions docs/installation/building-from-source.rst
Original file line number Diff line number Diff line change
Expand Up @@ -184,33 +184,45 @@ Many of Pillow's features require external libraries:

.. tab:: Windows using MSYS2/MinGW

To build Pillow using MSYS2, make sure you run the **MSYS2 MinGW 32-bit** or
**MSYS2 MinGW 64-bit** console, *not* **MSYS2** directly.
The following instructions are for the **MSYS2 UCRT64** system.
To build Pillow on one of the other MSYS2 systems, replace all occurences of
``mingw-w64-ucrt-x86_64`` with the corresponding prefix:

The following instructions target the 64-bit build, for 32-bit
replace all occurrences of ``mingw-w64-x86_64-`` with ``mingw-w64-i686-``.
.. list-table::
:header-rows: 1

* - MSYS2 system
- Package prefix
* - **UCRT64**
- ``mingw-w64-ucrt-x86_64``
* - **CLANG64**
- ``mingw-w64-clang-x86_64``
* - **MINGW64**
- ``mingw-w64-x86_64``

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please add CLANGARM64 as well?

Installing in **MSYS2 MSYS** is not supported.

Make sure you have Python and GCC installed::
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"GCC" -> "a C compiler"


pacman -S \
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Might be an idea to add --needed to all pacman commands to avoid reinstallation...

mingw-w64-x86_64-gcc \
mingw-w64-x86_64-python \
mingw-w64-x86_64-python-pip \
mingw-w64-x86_64-python-setuptools
mingw-w64-ucrt-x86_64-gcc \
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In order to cover the CLANG env, this should not be verbatim "gcc". There is a generic "cc" metapackage that will pull in either "gcc" or "clang" as needed.

mingw-w64-ucrt-x86_64-python3 \
mingw-w64-ucrt-x86_64-python3-pip \
mingw-w64-ucrt-x86_64-python3-setuptools

Prerequisites are installed on **MSYS2 MinGW 64-bit** with::
Prerequisites are installed on **MSYS2 UCRT64** with::

pacman -S \
mingw-w64-x86_64-libjpeg-turbo \
mingw-w64-x86_64-zlib \
mingw-w64-x86_64-libtiff \
mingw-w64-x86_64-freetype \
mingw-w64-x86_64-lcms2 \
mingw-w64-x86_64-libwebp \
mingw-w64-x86_64-openjpeg2 \
mingw-w64-x86_64-libimagequant \
mingw-w64-x86_64-libraqm \
mingw-w64-x86_64-libavif
mingw-w64-ucrt-x86_64-libjpeg-turbo \
mingw-w64-ucrt-x86_64-zlib \
mingw-w64-ucrt-x86_64-libtiff \
mingw-w64-ucrt-x86_64-freetype \
mingw-w64-ucrt-x86_64-lcms2 \
mingw-w64-ucrt-x86_64-libwebp \
mingw-w64-ucrt-x86_64-openjpeg2 \
mingw-w64-ucrt-x86_64-libimagequant \
mingw-w64-ucrt-x86_64-libraqm \
mingw-w64-ucrt-x86_64-libavif

.. tab:: FreeBSD

Expand Down
2 changes: 1 addition & 1 deletion docs/installation/platform-support.rst
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ These platforms are built and tested for every change.
| Windows Server 2025 | 3.11, 3.12, 3.13, 3.14, | x86-64 |
| | 3.15, PyPy3 | |
| +----------------------------+---------------------+
| | 3.14 (MinGW) | x86-64 |
| | 3.14 (CLANG64, MINGW64) | x86-64 |
+----------------------------------+----------------------------+---------------------+


Expand Down
Loading