I am trying to install Pyqt but I am having significant issues getting all the seperate installation processes to work in sync. I have looked online but I can't find anything to help in my specific situation.
So far I have downloaded and built Sip4.16.7. I saved the file to a random location on my directory and ran the configure file, it then installed the module in /Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages and seemed to work.
I then downloaded the latest version of Qt5.2 and installed it using the installer. The files are stored in /users/MyUsername/Qt
I then installed PyQt5.4.1 and tried to run the configure file but I obviously have an older version of qmake on my system as I get an error of Error: PyQt5 requires Qt v5.0 or later. You seem to be using v4.7.4. Use the
--qmake flag to specify the correct version of qmake. This is confirmed by typing qmake -v in the terminal and I get the output of QMake version 2.01a
Using Qt version 4.7.4 in /opt/anaconda1anaconda2anaconda3/lib. I have scoured the internet and I can't work out how to tell whether I have a new qmake for the Qt5.2 or If I have to make it. And I have no idea how to get set the right Qtmake directory for the new PyQt configure file.
I apologise for the very specific and confused question but I am totally lost at the moment. As an additional question When you download the PyQt and SIP files should they be saved in specific directories relative to each other?
To follow the entire discussion for how I answered this refer to https://forum.qt.io/topic/53035/installation-problems-with-pyqt-locating-old-version-of-qmake/37
There were 2 main problems:
1) The --qmake=/Users/MyUsername/Qt/5.4/ios/bin/qmake was directed to the iOS qmake which requires a subscription to apple developers program. using the --verbose option returned Check dependencies
Code Sign error: No code signing identities found: No valid signing identities (i.e. certificate and private key pair) matching the team ID “(null)” were found.
CodeSign error: code signing is required for product type 'Application' in SDK 'iOS 8.1'
The solution to this was to refer qmake to the clang-64 version to allow development on OS X not iOS.
2) I had saved the PyQt directory in my google drive and therefore there was a space in the file name. Therefore when I referred to the qmake in the clang-64 directory I got the error of ```clang: error: no such file or directory: Drive/Personal/Code/PyQT/PyQt-gpl-5.4.1 (when using --verbose) So I had to move the PyQT file to outside my google drive and rerun, and it worked fine.
Related
TLDR;
I installed John Sundell's Publish according to the accepted practices and immediately get an error when I try to build my site package. How do I successfully install the product?
After cloning the publish package:
git clone https://github.com/JohnSundell/Publish.git
I cd'd into the Publish folder and ran:
make
which created an executable at /usr/local/bin/publish
I opened a new terminal window, created a directory using mkdir Saturday and then cd'd into that folder. I typed publish new and was successful:
✅ Generated website project for 'Saturday'
Run 'open Package.swift' to open it and start building
When I open the manifest file (Package.swift) and type cmd-S (Save) it imports all the necessary packages, and everything looks good to go.
When I type cmd-B (Build), however this error message comes up:
The package product 'CollectionConcurrencyKit' requires minimum platform version 13.0 for the iOS platform, but this target supports 11.0
When I look at the clone/install of Publish I see:
Computing version for https://github.com/johnsundell/collectionConcurrencyKit.git
Computed https://github.com/johnsundell/collectionConcurrencyKit.git at 0.1.0 (0.37s)
Notice it says version 0.1.0. In the generated package for my site, it retrieves version 0.2.0. I don't know if that's an issue.
But not one other Package.swift file in all the fetched dependencies mentions iOS.
I have this line in my Package.swift
platforms: [.macOS(.v12)],
So I know I haven't added this dependency on iOS inadvertently, so I don't understand the error message.
I'm running macOS Monterey 12.6 on Xcode 14.0 (14A309) - both are the most recent release versions available.
The hardware is: MacBook Pro (16-inch, 2021) using the Apple M1 Pro chip
If I'm leaving anything out, please comment and I'll provide more detail.
This is a slap your forehead 🤦🏽♂️ kind of thing here.
It turns out that when I opened the Package.swift it defaulted to an iOS scheme that I had just been using. I updated the scheme to a macOS based one, the problem went away. Now I understand the source of the iOS error. Apparently the two versions of ConcurrencyKit is a red herring.
Hope this helps others! Always check your target when compiling.
I want to learn and use haarcascade classifier using OpenCV for detection of object of my choice. I searched the internet and found that createsamples utility helps in creating dataset for positive and negative images. I know how to install OpenCV in python (pip install opencv-python works perfectly) but since I need to use that utility I need to build the OpenCV for my windows system.
My attempts to install OpenCV in windows
Attempt 1 : using MinGW and cmake
cloned latest OpenCV using git at "C:\OpenCV" from https://github.com/opencv/opencv
Installed cmake
created build using cmake at "C:\OpenCV\build" using MinGW(64 bit) build system with default options
ran mingw32-make
ran mingw32-make install
It created an install directory in "C:\OpenCV\build\install"
but to my surprise opencv_createsamples.exe was not present there
opencv_visualisation.exe, opencv_annotation.exe, opencv_version.exe etc. are present
screenshot of install files generated
screenshot of build options selected in cmake by default
It is clear BUILD_opencv_apps is true by default and other apps were created except this one
still in source folder : createsamples.cpp is present in "C:\OpenCV\apps\" along with opencv_visualisation.cpp and others
Attempt 2: visual studio 14_15 build from official site
Downloaded OpenCV latest 4.0.1 from https://github.com/opencv/opencv/releases/download/4.0.1/opencv-4.0.1-vc14_vc15.exe from https://github.com/opencv/opencv/releases webpage
extracted the opencv build at "C:\OpenCV401\"
still to my surprise at "C:\OpenCV401\build\x64\vc14\bin" no opencv_createsamples.exe
likewise other files are present
screenshot of files present in build
Attempt 3
This time I downloaded visual studio 10 build from this github page : https://github.com/abreheret/opencv3.2.0_build
here at <OpenCV_DIR>/x64/vc10/bin/ all the amazing files are present
screenshot of files present in this build
So, my question is :
Why that utility was not built from the source using MinGW and cmake in my first attempt
Why they have not included in the official build
How to build using MinGW and cmake to get that utility correctly (maybe some build configuration needed?)
Createsamples was disabled in latest OpenCV (4.0 and greater): here.
When I run command ./configure I receive below mentioned error:
configure: error: Cannot build Qt apps, probably due to missing or too old Qt packages. Make sure Qt development packages are installed and newer than Qt 5.4. You can disable Qtenv by setting the WITH_QTENV variable to "no" in configure.user.
I have installed Qt5.9.0 after receiving above error, installed mingw-32bit but still receiving same error. Can anyone help me to solve the problem?
The OMNeT++ package for Windows contains all libraries and other tools (including JRE), so there is no need to install anything separately.
To install OMNeT++ in Windows one should:
Download a proper version of OMNeT++ - i.e. OMNeT++ 5.4 (Windows).
Turn off aniti-virus real time protection.
Extract the whole archive into a directory whose name doesn't contain spaces.
Double-click mingwenv.cmd, then press any key.
After some time in the mingwenv console type: ./configure, then make.
In the mingwenv console type omnetpp to start OMNeT++.
Later, to start OMNeT++ one should double click mingwenv.cmd, type omnetpp and do not close console.
I have removed polish characters from directory path and it solved thie problem. Check if directory has any special characters in directory path.
I'll share what worked for me. After installing the Qt package, remove the existing omnetpp directory and extract it from the zip file again. Run mingwenv.cmd, so that it initiates the tools extraction and is now able to load the installed Qt package. Running ./configure now doesn't show the error.
I'm trying to create a custom .platform and SDK in Xcode 8.3 and higher.
I am ultimately attempting to update the old DarwinBuild build system so that I can compile a few of the Apple open source components. DarwinBuild used to use this technique in order to be able to compile against a different set of headers and libraries without having to chroot.
DarwinBuild includes a setup script, installXcode32, that creates a new .platform under Xcode's Developer/Platforms directory, and a new sdk under the platform's Developer/SDKs directory. It also creates an Info.plist and SDKSettings.plist in the right spots. This script needs some updating to work with Xcode 8.3.
I know this is unsupported, but that doesn't matter in this case. After all, Apple published the original script...
I updated the original installXcode32 script to work with the new Xcode paths (/Applications/Xcode.app/Contents/...), and it produces the new .platform, Info.plist, and SDKSettings.plist, and they're all symlinked to the right spots. However, xcodebuild -showsdks now produces this error:
xcodebuild: error: Initialization failed.
Reason: Required content for platform darwin is missing.
I know it's an issue with the Info.plist and SDKSettings.plist files. I have tried copying the entire MacOSX.platform directory, and changing the names in the .plist, and I get the same error.
Does anyone know enough about Xcode and platforms to know what is required to get Xcode 8.3+ to recognize a "new" Platform and sdk?
Many thanks!
I have successfully done this with Xcode 9.4, pretty much like you did. I changed:
CanonicalName
PLATFORM_NAME
DisplayName
I am following the tutorial:https://github.com/thoughtbot/capybara-webkit/wiki/Installing-Qt-and-compiling-capybara-webkit#gentoo-linux
and get stuck at step 11, where I get an error saying Command 'qmake -spec win32-g++ CONFIG+=test' not avalable.
I have no idea how to solve this, and I did add Qt/4.8.6/bin in the path.
I just spent a while getting this to work. I found that the QT environment/system variables were not set up correctly when QT installed. Short version: I found a problem with my Qt install: although it was in my path and qmake would run (I could do qmake -v and get output), that wasn't enough. The variables that Qt uses for paths (e.g. QT_INSTALL_HEADERS, etc.) were not correct. I had to run the Qt configuration program configure.exe. That correctly set all of the Qt variables and all was fixed.
I figured that it must be some kind of issue on my end, since I saw that others have installed it successfully. I went through each of the components required to verify the installation and setup -- and found the problem. I've been able to compile gems just fine using just DevKit, so suspected that it had something to do with Qt. (and it did) Here's what I did to check and verify each component:
DevKit: made sure it was installed in the ruby versions needed, and
verified that it worked:
checked '/devkit/config.yml' to make sure it listed each of different installed ruby versions, and then
re-ran the DevKit install script (ruby dk.rb install) to be sure that DevKit had installed the right files into each of those ruby versions.
I verified that DevKit was working using the recommendation on the DevKit page [https://github.com/oneclick/rubyinstaller/wiki/Development-Kit]: I installed the json gem. It was able to build the native version so that verified that DevKit was installed and working properly.
Qt: I downloaded the Qt files (I used 4.8.5; glad to know I can upgrade). I ran the .exe file downloaded to install them.
made sure that Qt directories were in my path (see the list below).
made sure that the environment variable QMAKESPEC was defined:QMAKESPEC=win32-g++
made the edits to the qmake.conf file (the 'Frommel workaround') as described on https://github.com/thoughtbot/capybara-webkit/wiki/Installing-Qt-and-compiling-capybara-webkit#windows
ran qmake -version to verify that qmake would run and to verify the version
ran qmake -query to verify the set-up for Qt. This is where I saw the problem with my Qt install: the paths were all wrong.
ran the Qt configure.exe program to fully configure my Qt install. This was the key step. (I thought that the initial installation program would have configured things, but obviously it didn't.) Running this will build all of the demos and examples and so takes a while. But when it completed, all was well.
ran qmake -query to verify that the Qt settings and been fixed and were correct.
System path and ENV variables: the following need to be in your path:
[devkit dir] (ex: C:\rubys\devkit-mingw64-32-4.7.2)
[devkit dir]\mingw\bin;
[devkit dir]\bin;
[qt dir] (ex: C:\Qt\qt-4.8.5-x86-mingw)
[qt dir]\bin;
[ruby version]\bin (ex: C:\rubys\ruby-2.0.0-p598-i386-mingw32\bin)
[ruby version]\lib\ruby\gems\
define the environment (system) variable QMAKESPEC=win32-g++ (If you don't give qmake/Qt the specification about which system to build for, it will look for this ENV.)
I know it's been a while since you posted your question, so hopefully you've solved it. If not, try these steps and see if they help.