ChatCrawlersearch across public Telegram Open the app
Q

Qt for Python (PySide/Shiboken)

5 August 2022
2022-08-05×
5 August 2022
Hello guys, I've been trying to install Pyside v6.3.1 from source. Unfortunately the setup.py keep throwing an error saying Could not fin Qt via provided option --qt-target-path.. even though i've installed the Qt of the same version in the said path
the Qt was installed using the qt universal windows installer
I
any help would be appreciated :)
F
It's been a while since I last installed PySide from source, but can you show the full output?
`In directory E:\New folder\pyside-setup: Running command: "E:\New folder\venv\Scripts\python.exe" setup.py build --qtpaths=E:\Qt\6.3.1\msvc2019_64\bin\qtpaths.exe --build-tests --ignore-git --parallel=4 --qt-target-path=E://Qt --internal-build-type=shiboken6 running build Could not find Qt via provided option --qt-target-path=E://Qt Error was: Traceback (most recent call last): File "E:\New folder\pyside-setup\setup.py", line 78, in <module> setup_runner.run_setup() File "E:\New folder\pyside-setup\build_scripts\setup_runner.py", line 240, in run_setup self.run_setuptools_setup() File "E:\New folder\pyside-setup\build_scripts\setup_runner.py", line 313, in run_setuptools_setup setup(**kwargs) File "E:\New folder\venv\lib\site-packages\setuptools\__init__.py", line 87, in setup return distutils.core.setup(**attrs) File "E:\New folder\venv\lib\site-packages\setuptools\_distutils\core.py", line 177, in setup return run_commands(dist) File "E:\New folder\venv\lib\site-packages\setuptools\_distutils\core.py", line 193, in run_commands dist.run_commands() File "E:\New folder\venv\lib\site-packages\setuptools\_distutils\dist.py", line 968, in run_commands self.run_command(cmd) File "E:\New folder\venv\lib\site-packages\setuptools\dist.py", line 1217, in run_command super().run_command(command) File "E:\New folder\venv\lib\site-packages\setuptools\_distutils\dist.py", line 986, in run_command cmd_obj.ensure_finalized() File "E:\New folder\venv\lib\site-packages\setuptools\_distutils\cmd.py", line 107, in ensure_finalized self.finalize_options() File "E:\New folder\pyside-setup\build_scripts\main.py", line 314, in finalize_options DistUtilsCommandMixin.mixin_finalize_options(self) File "E:\New folder\pyside-setup\build_scripts\options.py", line 354, in mixin_finalize_options self._do_finalize() File "E:\New folder\pyside-setup\build_scripts\options.py", line 439, in _do_finalize raise
I
setup.py invocation was: E:\New folder\venv\Scripts\python.exe setup.py build --qtpaths=E:\Qt\6.3.1\msvc2019_64\bin\qtpaths.exe --build-tests --ignore-git --parallel=4 --qt-target-path=E://Qt --internal-build-type=shiboken6`
F
ok, that looks like cl.exe (the compiler) could not be found? don't really remember how this works on Windows, I think you need to run vcvarsall.bat or something first?
I
its already in the system path
A
On Windows you should build from the Visual Studio Developer PowerShell or Command Prompt.
A
From "Developer PowerShell for VS <version>"?
is this what the vcvarsall.bat that florian was referring to?
I
im gonna try using that developer powershell for vs
I'm not sure that's the exact name of the .bat, but what the Developer PowerShell / Developer Command Prompt do is that they run a .bat / import a .dll, respectively.
Looking at my system, for cmd it's VsDevCmd.bat.
In any case, I'd recommend either just searching the Developer PowerShell in the start menu (or opening it from Windows Terminal) and navigate to the directory from there, or set up your PowerShell user profile such that the dll import is done automatically at shell creation.
A
So you don't have to open the Developer PowerShell every time.
i managed to get new errors
Could not find Qt via provided option --qt-target-path=E:\Qt\6.3.1\msvc2019_64\bin Error was:
`RuntimeError: Failed to configure CMake project 'D:/silentmode/pyside apps/pyside-setup/sources/shiboken6/config.tests/target_qt_mkspec' with error: CMake Error at CMakeLists.txt:8 (find_package): Could not find a configuration file for package "Qt6" that is compatible with requested version "". The following configuration files were considered but not accepted: E:/Qt/6.3.1/msvc2019_64/lib/cmake/Qt6/Qt6Config.cmake, version: 6.3.1 (64bit) `
`Return code: 1 Configure args were: C:\Program Files\CMake\bin\cmake.EXE -G Ninja -S D:/silentmode/pyside apps/pyside-setup/sources/shiboken6/config.tests/target_qt_mkspec -B D:/silentmode/pyside apps/pyside-setup/build/config.tests\target_qt_mkspec_2xk7r4dp -DCMAKE_PREFIX_PATH=E:/Qt/6.3.1/msvc2019_64 -DCMAKE_C_COMPILER=cl.exe -DCMAKE_CXX_COMPILER=cl.exe`
I
still have no idea why the script not able to find the files in that path
if not, don't use --qt-target-path, just use --qtpaths or leave the Qt install in your PATH and don't pass options.
C
Because you are using msvc, just open the terminal from visual studio, the 'x64 native' one (you should have like 2-4 after the install of msvc) that terminal will have everything the compiler needs in path. Then you can simply do a set LLVM_INSTALL_PATH=.... set PATH=E:\Qt\6.3.1\msvc2019_64\bin;%PATH% so you have the Qt and libclang in path, then run a simple python setup.py install.....
btw what does this x64 native terminal differs with that visual studio powershell and the normal one
I
sorry im pretty new on this field
C
'in theory' you could load that manually on any terminal, but personally I have always had issues with that process, so I prefer to use the terminal that I know should work
I
thanks christian, adrian and florian for your aid XD
Calendar: August 2022
MoTuWeThFrSaSu1223445406786941029111812131415161718191201212212322243251262732829193025313
Archive by month
Open in Telegram Каталог площадок Искать в ChatCrawler

A snapshot of an open public feed from the search index ChatCrawler — “Google for public Telegram”; refreshed as the venue is crawled. Times are UTC.

Public content only, official Telegram API. About · FAQ · What we do not do · Remove a page · Catalog