Skip to content

Commit 6f1e95b

Browse files
[3.9] pythongh-101981: Build macOS as recommended by the devguide (pythonGH-102070)
Automerge-Triggered-By: GH:erlend-aasland. (cherry picked from commit 2713631) Co-authored-by: Erlend E. Aasland <[email protected]>
1 parent c25b484 commit 6f1e95b

File tree

1 file changed

+12
-1
lines changed

1 file changed

+12
-1
lines changed

.github/workflows/build.yml

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -150,8 +150,19 @@ jobs:
150150
PYTHONSTRICTEXTENSIONBUILD: 1
151151
steps:
152152
- uses: actions/checkout@v3
153+
- name: Install Homebrew dependencies
154+
run: brew install pkg-config [email protected] xz gdbm tcl-tk
153155
- name: Configure CPython
154-
run: ./configure --with-pydebug --with-openssl=/usr/local/opt/openssl --prefix=/opt/python-dev --with-tcltk-includes=-I$(brew --prefix tcl-tk)/include --with-tcltk-libs="-L$(brew --prefix tcl-tk)/lib -ltcl8.6 -ltk8.6"
156+
run: |
157+
CFLAGS="-I$(brew --prefix gdbm)/include -I$(brew --prefix xz)/include" \
158+
LDFLAGS="-L$(brew --prefix gdbm)/lib -L$(brew --prefix xz)/lib" \
159+
PKG_CONFIG_PATH="$(brew --prefix tcl-tk)/lib/pkgconfig" \
160+
./configure \
161+
--with-pydebug \
162+
--prefix=/opt/python-dev \
163+
--with-openssl="$(brew --prefix [email protected])" \
164+
--with-tcltk-libs="$(pkg-config --libs tcl tk)" \
165+
--with-tcltk-includes="$(pkg-config --cflags tcl tk)"
155166
- name: Build CPython
156167
run: make -j4
157168
- name: Display build info

0 commit comments

Comments
 (0)