New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Various fixes for pip file discovery #7682
Conversation
Thanks for the fix -- the code looks good. Can you amend the commit message to describe what it does? You can see an example of what our commit messages usually look like using |
I see you've edited the PR description -- to be clear, I am asking specifically that the commit be amended. The PR will get lost in the sands of time, but the commit is in the history forever. The easiest is to use |
Despite getting that section of code to at least work, and avoid an error, there is still more to do (build error) |
ninja: error: '/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/site-packages/shiboken6/lib', needed by 'lib/libFreeCADGui.dylib', missing and no known rule to make it |
Do you want to switch this PR to draft mode while you continue to work on it? Or would you prefer to merge this improvement, and work on fixing that bug separately? |
Now that pip file discovery code works, it seems to expose an error in the underlying assumptions. As the original author, perhaps you could take a look? |
Added some cleanups to make going forward easier |
@chennes Your code specifies a /lib directory as _LIBRARY. My pip-installed PySide and Shiboken directories do not have such a lib directory. Assuming the original code was somehow tested (yes?) , then the question becomes why doesn't my installation have that directory? |
Interesting -- in my Windows install of PySide6 there is a lib and include directory, but not in PySide2 (which doesn't matter because on Windows we ship with PySide2 as a cMake-findpackage-findable package). It looks to me like the libraries are just in the top-level directory on my system (e.g. not within lib at all). Is that the case on yours? (Homebrew Mac, I think?) |
I don't understand most of that. We are talking pip-installed PySide6 and Shiboken6 on macOS. No system-installed, no Homebrew.
These libraries you mention, what do they look like? .so? .dylib? Something else? |
On my Mac I have |
And for shiboken I have |
I guess we better reach out to our Python-integration experts -- it's possible the find_pip_package isn't needed at all. I was under the impression that it was better for us to link against those libraries, but we didn't make any effort to locate pip-installed PySide2 or Shiboken2. @wwmayer, Qt's documentation suggests installing using pip, so I thought it would be a good idea to try to find it in cMake, but it seems it's not as straightforward as I had hoped. Is this needed/worth pursuing? |
Homebrew has been one drama after another despite lots of fiddling. Maybe Qt came to the same conclusion. Pip is very much worth pursuing. A bit of testing along the way might be an idea though. |
Given bad experiences with Homebrew I've opened a new can of worms locally (macOS) by download and install Unfortunately @chennes @wwmayer Could one or both of you please give me a brief shove in the right direction? I get that |
Itried this patch. Before the patch this error was displayed: After: |
Yes, it is broken. The history is self-explanatory, I think. |
Thank you for creating a pull request to contribute to FreeCAD! To ease integration, we ask you to conform to the following items. Pull requests which don't satisfy all the items below might be rejected. If you are in doubt with any of the items below, don't hesitate to ask for help in the FreeCAD forum!
App
,Base
,Gui
or one of theMod
subfolders. If you need to make changes in several locations, make several pull requests and wait for the first one to be merged before submitting the next onesgit pull --rebase upstream master
./bin/FreeCAD --run-test 0
Fixes typo in Draft Move command text
Draft: Fixed typos
issue #<id>
orfixes #<id>
where<id>
is the issue ID number from our Issues database in case a particular commit solves or is related to an existing issue. Ex:Draft: fix typos - fixes #4805
And please remember to update the Wiki with the features added or changed once this PR is merged.
Note: If you don't have wiki access, then please mention your contribution on the 1.0 Changelog Forum Thread.
Corrects multiple issues causing "include files not found" warning for pip-based pyside and shiboken