GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — Update instructions for building on macOS by cesarcoatl · Pull Request #1052 · python/devguide

Conversation

@cesarcoatl

@cesarcoatl cesarcoatl commented Feb 10, 2023

Copy link
Copy Markdown
  1. Update the command for building Python 3.7 through 3.9 by exporting PKG_CONFIG_PATH so pkg-config can find tcl and tk
  2. Instruct users on installing openssl with brew for building Python 3.10

Fixes: #1049

Signed-off-by: César Román [email protected]

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
César Román
Update instructions for building on macOS
3665af1
Signed-off-by: César Román <[email protected]>
@ghost

ghost commented Feb 10, 2023 •
edited by ghost
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown

All commit authors signed the Contributor License Agreement.
CLA signed

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@arhadthedev arhadthedev added the type-feature Additions; New content or section needed label Feb 10, 2023
César Román
Fix WARNING: Literal block expected; none found.
c5d0291
getting-started/setup-building.rst:420
@erlend-aasland
erlend-aasland requested review from erlend-aasland and ned-deily February 10, 2023 16:36
@erlend-aasland erlend-aasland self-assigned this Feb 10, 2023
CAM-Gerlach
CAM-Gerlach reviewed Feb 10, 2023
View reviewed changes

@CAM-Gerlach CAM-Gerlach left a comment •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

Standard reminder: You can directly apply all the suggestions you want in one go with Files changed -> Add to batch -> Commit

Some suggestions and questions to clarify the advice and the structure

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
Comment thread getting-started/setup-building.rst Resolved

Uh oh!

There was an error while loading. Please reload this page.

Comment thread getting-started/setup-building.rst Resolved

Uh oh!

There was an error while loading. Please reload this page.

Comment thread getting-started/setup-building.rst Resolved

Uh oh!

There was an error while loading. Please reload this page.

Comment thread getting-started/setup-building.rst Resolved

Uh oh!

There was an error while loading. Please reload this page.

Comment thread getting-started/setup-building.rst Resolved

Uh oh!

There was an error while loading. Please reload this page.

Comment thread getting-started/setup-building.rst Resolved

Uh oh!

There was an error while loading. Please reload this page.

Comment thread getting-started/setup-building.rst Resolved

Uh oh!

There was an error while loading. Please reload this page.

@CAM-Gerlach

CAM-Gerlach commented Feb 10, 2023

Copy link
Copy Markdown
Member

(Standard reminder: You can directly apply all the suggestions you want in one go with Files changed -> Add to batch -> Commit)

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

César Román and others added 2 commits February 10, 2023 16:29
César Román @CAM-Gerlach
Apply suggestions from code review
c47691a
Co-authored-by: C.A.M. Gerlach <[email protected]>
César Román
Install and use [email protected] with Homebrew
e394c53
CAM-Gerlach
CAM-Gerlach reviewed Feb 14, 2023
View reviewed changes
Comment thread getting-started/setup-building.rst Resolved

Uh oh!

There was an error while loading. Please reload this page.

César Román @CAM-Gerlach
Apply suggestions from code review
7ef41ca
Co-authored-by: C.A.M. Gerlach <[email protected]>
ned-deily
ned-deily requested changes Feb 15, 2023
View reviewed changes

@ned-deily ned-deily left a comment

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

Thanks for making the PR! If the 3.10+ PKG_CONFIG_PATH line is restored as I've commented in line, the Homebrew instructions seem to build as expected for 3.7 through current main/3.12 on a current macOS 13 system.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
Comment thread getting-started/setup-building.rst Resolved

Uh oh!

There was an error while loading. Please reload this page.

César Román added 2 commits February 15, 2023 16:00
César Román
Restore Python 3.10+ PKG_CONFIG_PATH
5b35659
César Román
Merge branch 'main' into docs/setup-building-macOS
fa48550
ned-deily
ned-deily approved these changes Feb 16, 2023
View reviewed changes
CAM-Gerlach
CAM-Gerlach reviewed Feb 16, 2023
View reviewed changes

@CAM-Gerlach CAM-Gerlach left a comment

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

This looks good from my side, except that as mentioned previously, the immediately following introductory text (the last make step and the first line for MacPorts after it) should be updated to make sense with the changes here and ensure it is clearer for readers which instructions are specific to which distributor and Python version.

I can't make them as suggestions, but I can either just push a commit directly to your branch, or you can apply this diff:

``git diff`` output
diff --git a/getting-started/setup-building.rst b/getting-started/setup-building.rst
index b285a74..15e094a 100644
--- a/getting-started/setup-building.rst
+++ b/getting-started/setup-building.rst
@@ -419,7 +419,7 @@ For example, with **Homebrew**, install the dependencies::

     $ brew install pkg-config [email protected] xz gdbm tcl-tk

-Then, for Python 3.10 and newer::
+Then, for Python 3.10 and newer, run ``configure``::

     $ CFLAGS="-I$(brew --prefix gdbm)/include -I$(brew --prefix xz)/include" \
       LDFLAGS="-L$(brew --prefix gdbm)/lib -I$(brew --prefix xz)/lib" \
@@ -438,11 +438,11 @@ Or, for Python 3.7 through 3.9::
               --with-tcltk-libs="$(pkg-config --libs tcl tk)" \
               --with-tcltk-includes="$(pkg-config --cflags tcl tk)"

-and ``make``::
+And finally, run ``make``::

     $ make -s -j2

-or **MacPorts**::
+Alternatively, with **MacPorts**::

     $ sudo port install pkgconfig openssl xz gdbm

Or am this patch:

``git format-patch`` output
From 8ae83afc0cbf616c1937408c8e5767ecd4625cf1 Mon Sep 17 00:00:00 2001
From: "C.A.M. Gerlach" <[email protected]>
Date: Wed, 15 Feb 2023 20:01:14 -0600
Subject: [PATCH] Update following text to match revised macOS building
 language

---
 getting-started/setup-building.rst | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/getting-started/setup-building.rst b/getting-started/setup-building.rst
index b285a74..15e094a 100644
--- a/getting-started/setup-building.rst
+++ b/getting-started/setup-building.rst
@@ -419,7 +419,7 @@ For example, with **Homebrew**, install the dependencies::

     $ brew install pkg-config [email protected] xz gdbm tcl-tk

-Then, for Python 3.10 and newer::
+Then, for Python 3.10 and newer, run ``configure``::

     $ CFLAGS="-I$(brew --prefix gdbm)/include -I$(brew --prefix xz)/include" \
       LDFLAGS="-L$(brew --prefix gdbm)/lib -I$(brew --prefix xz)/lib" \
@@ -438,11 +438,11 @@ Or, for Python 3.7 through 3.9::
               --with-tcltk-libs="$(pkg-config --libs tcl tk)" \
               --with-tcltk-includes="$(pkg-config --cflags tcl tk)"

-and ``make``::
+And finally, run ``make``::

     $ make -s -j2

-or **MacPorts**::
+Alternatively, with **MacPorts**::

     $ sudo port install pkgconfig openssl xz gdbm

--
2.37.1.windows.1

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@cesarcoatl

cesarcoatl commented Feb 16, 2023

Copy link
Copy Markdown
Author

I'll work on that

CAM-Gerlach reacted with thumbs up emoji
All reactions
  • 👍 1 reaction

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@CAM-Gerlach César Román
Update following text to match revised macOS building language
d6bb8e0
@cesarcoatl

cesarcoatl commented Feb 16, 2023

Copy link
Copy Markdown
Author

@CAM-Gerlach patch has been applied

CAM-Gerlach reacted with thumbs up emoji
All reactions
  • 👍 1 reaction

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@pradyunsg
pradyunsg merged commit 80cd894 into python:main Feb 17, 2023
@pradyunsg

pradyunsg commented Feb 17, 2023 •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Member

Thanks @thecesrom!

PS: Merged this since OP has addressed all outstanding comments, the PR has an approval from the relevant expert, and changes look good to me!

CAM-Gerlach and erlend-aasland reacted with thumbs up emoji
All reactions
  • 👍 2 reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@erlend-aasland

erlend-aasland commented Feb 17, 2023 •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Contributor

Thanks for handling this CAM and Ned (and Pradyun for merging)!

pradyunsg reacted with rocket emoji
All reactions
  • 🚀 1 reaction

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@erlend-aasland erlend-aasland mentioned this pull request Feb 22, 2023
Use targeted env vars for macOS build instructions #1057
Closed
@cesarcoatl
cesarcoatl deleted the docs/setup-building-macOS branch March 10, 2023 22:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

@CAM-Gerlach CAM-Gerlach CAM-Gerlach left review comments
@ezio-melotti ezio-melotti ezio-melotti left review comments
@ned-deily ned-deily ned-deily approved these changes
@erlend-aasland erlend-aasland Awaiting requested review from erlend-aasland

Uh oh!

There was an error while loading. Please reload this page.

Assignees

@erlend-aasland erlend-aasland

Labels

type-feature Additions; New content or section needed

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

Envvars not set in subshell in macOS Python 3.7-3.9 configure invocation

Uh oh!

There was an error while loading. Please reload this page.

7 participants

@cesarcoatl @CAM-Gerlach @pradyunsg @erlend-aasland @ned-deily @ezio-melotti @arhadthedev
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.