Title: macOS framework installs can break if `DESTDIR` specified during builds · Issue #149351 · python/cpython · GitHub
Open Graph Title: macOS framework installs can break if `DESTDIR` specified during builds · Issue #149351 · python/cpython
X Title: macOS framework installs can break if `DESTDIR` specified during builds · Issue #149351 · python/cpython
Description: Bug report Bug description: The Makefile build target for the shared Python library in a macOS framework build can include an incorrect library install name if the DESTDIR Makefile variable is set. The symptom is that launching the insta...
Open Graph Description: Bug report Bug description: The Makefile build target for the shared Python library in a macOS framework build can include an incorrect library install name if the DESTDIR Makefile variable is set....
X Description: Bug report Bug description: The Makefile build target for the shared Python library in a macOS framework build can include an incorrect library install name if the DESTDIR Makefile variable is set....
Opengraph URL: https://github.com/python/cpython/issues/149351
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"macOS framework installs can break if `DESTDIR` specified during builds","articleBody":"# Bug report\n\n### Bug description:\n\nThe Makefile build target for the shared Python library in a macOS framework build can include an incorrect library install name if the `DESTDIR` Makefile variable is set. The symptom is that launching the installed python3.x binary will result in a crash with the system unable to find the Python shared library; the path of the library will mistakenly include the `DESTDIR` path prefix.\n\nThe `DESTDIR` variable is often used in Makefile-based build pipelines to allow build artifacts to be installed temporarily in a directory tree other than the intended system installation location which could otherwise affect the system environment on the build platform. For a long time now, the value of `DESTDIR`, if specified, has been included in the install name path of the framework library. That hasn't caused a problem as long as the build is done in multiple make steps, for example:\n\n```\n./configure --enable-framework ...\nmake ... \nmake install DESTDIR=release_directory\n```\n\nBut if the first make were skipped such that the `make install` step causes the Python library to be linked, the `DESTDIR` path prefix will be include in the install name and the installed framework will not work. This could also happen if the `make install` step causes the library to be relinked due to a Makefile dependency issue, which is how this problem was discovered.\n\nThe solution is simple: don't include `DESTDIR` in the `-install_name` argument. Note that the very similar iOS framework build rule does not have this problem.\n\n\n### CPython versions tested on:\n\nCPython main branch\n\n### Operating systems tested on:\n\nmacOS\n\n\u003c!-- gh-linked-prs -->\n### Linked PRs\n* gh-149352\n* gh-149354\n* gh-149355\n\u003c!-- /gh-linked-prs -->\n","author":{"url":"https://github.com/ned-deily","@type":"Person","name":"ned-deily"},"datePublished":"2026-05-04T09:54:09Z","url":"https://github.com/python/cpython/issues/149351"}
| react-profiling | 0 |
| react-import-map | react,react-dom,react-dom/client,react-dom/profiling,react-is,react-reconciler,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@d5750093facf |
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:74e9a265-89c0-7406-3561-ceefdd3b813b |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | D82E:1958AD:240A3C:308EBF:6AECC4D1 |
| html-safe-nonce | 698ce258c99d7d843537b54e0a805ae89f7c911656050b98793abb82b102a22f |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJEODJFOjE5NThBRDoyNDBBM0M6MzA4RUJGOjZBRUNDNEQxIiwidmlzaXRvcl9pZCI6IjYzNzc1NTA0MDM2NTM2NDk2MTciLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ== |
| visitor-hmac | 58f36ca825b6e56282bcf4bc2e0864853baa121a8d3ddd048194bd2c6068b2eb |
| hovercard-subject-tag | issue:4375568267 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/python/cpython/149351/issue_layout |
| twitter:image | https://opengraph.githubassets.com/bcc699e96ac384efdbed37ca692878f4ec60a59b944a9def88cc58beff407f5d/python/cpython/issues/149351 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/bcc699e96ac384efdbed37ca692878f4ec60a59b944a9def88cc58beff407f5d/python/cpython/issues/149351 |
| og:image:alt | Bug report Bug description: The Makefile build target for the shared Python library in a macOS framework build can include an incorrect library install name if the DESTDIR Makefile variable is set.... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | ned-deily |
| hostname | github.com |
| expected-hostname | github.com |
| None | dc0b519c5798dc1150b88dc4c06a8b9634d0069218dc04e469970e76aad74016 |
| turbo-cache-control | no-preview |
| go-import | github.com/python/cpython git https://github.com/python/cpython.git |
| octolytics-dimension-user_id | 1525981 |
| octolytics-dimension-user_login | python |
| octolytics-dimension-repository_id | 81598961 |
| octolytics-dimension-repository_nwo | python/cpython |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 81598961 |
| octolytics-dimension-repository_network_root_nwo | python/cpython |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | db139f0bf57b59bf9a8c4abb0849924d6c6ca559 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
| react-app-name | issues |
Links:
Viewport: width=device-width