Coder Social home page Coder Social logo

Comments (2)

rprimmer avatar rprimmer commented on September 22, 2024 2

Hi Ronald, thank you for your response, it cleared up some things.

Let me just start by making sure I wasn't ambiguous in my first note. I only created a symlink in /Library/Frameworks/Python.framework/Versions/Current/lib; the symlink Current -> 3.12 in dir /Library/Frameworks/Python.framework/Versions
was already present as part of the python package install that I downloaded (for macOS) from python.org.

However, your question as to why I would even have need for adding the path in the first place made me realize I must have something wrong in my environment if others aren't seeing this issue on macOS.

After some digging, it turns out to be a toolchain issue. On this system I use python from the package downloaded from python.org. But there was some leftover stuff from homebrew on the same system. Homebrew downloads python3 as a dependency for some of its other packages, whether you explicitly download it yourself or not.

Once I uninstalled the brew pyinstaller it worked fine without having to set pathex=['/Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/site-packages'] in the project.spec file.

Thank you for your clear explanation. It pointed me in the right direction to figure out the toolchain conflict.

from cpython.

ronaldoussoren avatar ronaldoussoren commented on September 22, 2024 1

I'm -1 on this, the links in Python.framework are there to conform to platform conventions a "lib" or "bin" symlink doesn't conform to these conventions. Having the symlink can also lead to confusing behaviour when having multiple Python versions installed at the same time (as I commonly do).

Furthermore the library path can easily be retrieved using sysconfig.get_paths(), and that works on all platforms.

BTW. Are you sure you need to specify a path to the site-packages directory? I'd expect that pyinstaller can find that on its own.

from cpython.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.