Re: [Interest] Host Qt version requirement when cross-compiling
Hi, See https://lists.qt-project.org/pipermail/development/2021-November/041917.html Quote: >Apart from that, after internal discussion I have to lower expectations >regarding our commitment to this. I don't see us creating the test >infra for testing the build of different host/target Qt combinations. As >such we offer no commitment or support, but we will accept patches that >improve the situation. And whenever someone asks me which host version to use for host tools, I always answer the: 'same patch version'. Anything else: you're on your own. On Sun, Mar 13, 2022 at 6:22 AM Thiago Macieira wrote: > On Saturday, 12 March 2022 14:24:20 PST Alexey Rochev wrote: > > Does cross-compiling Qt6 (for Android) require exact same version of > > host Qt to build correctly? I'm assuming that it does since when I > > tried to cross-compile 6.2.2 using host 6.2.3 (don't ask me why) it > > failed with a strange error (in cmake_automoc_parser) and it was gone > > when I updated the cross-compiled version to 6.2.3. I would still like > > to get official information on this, however. > > Our objective was that any version within N-4 and N+4 of the minor version > should work, but only starting with 6.3. > > It's also not tested. > > -- > Thiago Macieira - thiago.macieira (AT) intel.com > Software Architect - Intel DPG Cloud Engineering > > > > ___ > Interest mailing list > Interest@qt-project.org > https://lists.qt-project.org/listinfo/interest > ___ Interest mailing list Interest@qt-project.org https://lists.qt-project.org/listinfo/interest
Re: [Interest] Qt 6 Universal binaries for Mac OS?
Hi, Seems like the doc snapshots haven't been indexed by search engines yet (from my results at least). See https://doc-snapshots.qt.io/qt6-6.2/macos.html#architectures You can specify the relevant options in Creator's Project pane for either build system. On Wed, Sep 22, 2021 at 10:38 PM Wesley Krasko wrote: > Hello all. We have been waiting for Qt 6.2 for universal binary support. > I have 6.2 RC and have our app building and running fine in Creator (for > Intel on an Intel machine, Big Sur, Xcode 12). > Does anyone know how to then create the universal binaries? I have found > documentation on building Qt for both architectures, but that's irrelevant > as we use the pre-compiled Qt downloaded through the maintenance tool. > Our current process has been to dev/build the app in Creator (we do not > use Xcode, find Creator much easier and more user friendly). Once done, I > copy the bundle somewhere, run macdeployqt on it, sign it, then > notarize it. Of course there's some details in between but that's > essentially it, I have a pkg to distribute. > I'm not seeing in Creator now how to create a universal binary, or finding > any docs. > Thanks! > > -- > Wes Krasko > www.worldwidewes.com > www.kraskofamily.com > "Stay away from negative people. They have a problem for every solution." > > ___ > Interest mailing list > Interest@qt-project.org > https://lists.qt-project.org/listinfo/interest > ___ Interest mailing list Interest@qt-project.org https://lists.qt-project.org/listinfo/interest
Re: [Interest] PySide2 installer for windows?
Hi, Point 1: At the official first release of Qt For Python / PySide2 which was bundled with Qt 5.11, we never provided py27 windows packages. So officially, we haven't dropped any packages, because they weren't there in the first place. Point 2: Packages for py2.7 for PySide2 do not exist not because of py2 EoL, but rather because the official py27 interpreter is built with MSVC 2008, whereas Qt is built with MSVC2015, and we deemed that with the current PySide2 codebase, it is not safe to mix MSVC runtimes. This was communicated multiple times, and is mentioned on the wiki as well. Yet people still insist on bringing it up, disregarding that such packages are not safe to use. People are free to try and build Py2.7 + Qt + PySide2 with the same MSVC version, and use that. On Sat, May 18, 2019 at 7:03 PM Thiago Macieira wrote: > On Friday, 17 May 2019 18:26:11 PDT Bob Hood wrote: > > On 5/17/2019 2:58 PM, Thiago Macieira wrote: > > > On Friday, 17 May 2019 10:16:04 PDT Bob Hood wrote: > > >> They have (prematurely, imo) abandoned the combination of Windows + > > >> Python > > >> v2.7. You will only be able to install PySide2 under Windows with > Python > > >> v3.x now. > > > > > > Less than 7 and a half months of support for Python 2 left, until it > EOLs, > > > after a 5 year extension. Everyone has migrated their business critical > > > applications to Python 3 by now, right? > > > > Well, to me "7 and a half months...left" is not EOL, and I don't know > > precisely when Python v2/Windows support was jettisoned, but you can add > > that difference to the duration as well.That's how I personally define > > "prematurely." > > Python2 support was deprecated by the Python community and the Python > Software > Foundation many years ago. Its EOL was pushed from Jan 1, 2015 to Jan 1, > 2020. > > The point is not about Pyside, it's about *Python*. People have had over > 10 > years to switch from 2.x to 3. With less than 7½ months left, I'm sure > everyone with critical applications have already switch, right? > > https://pythonclock.org/ > > > But the decision is made; I'm not instigating a brush war over it. I'm > not > > invested in PySide2, and neither are my customers. It was just going to > be a > > convenience for them as long as we continued to support Python v2. Now > it > > won't. > > I think the point is that it's not worth the resources required to build > and > test the Python2 bulld when so few are (supposed to be) still using it. > > -- > Thiago Macieira - thiago.macieira (AT) intel.com > Software Architect - Intel System Software Products > > > > ___ > Interest mailing list > Interest@qt-project.org > https://lists.qt-project.org/listinfo/interest > ___ Interest mailing list Interest@qt-project.org https://lists.qt-project.org/listinfo/interest
Re: [Interest] Building Qt and WebEngine
Hi, You install Qt, then you can use the Qt installed qmake to build and install WebEngine. So something like: 1) qt5/configure && make && make install 2) mkdir qtwebengine_build && cd qtwebengine_build && qt_installed_location/bin/qmake /path/to/qtwebengine.pro 3) make && make install On Thu, Apr 25, 2019 at 10:30 AM Volker Enderlein < volker.enderl...@ifm-chemnitz.de> wrote: > Hi, > > > when building Qt and WebEngine separately (i.e. not doing an embeddd > build), do I need to install Qt before building WebEngine and provide > the path to the installation? > > Are there any step by step instructions how to do this? I searched > already for a while with no luck, apparently using the wrong keywords. > > > Cheers, Volker > > -- > > ___ > Interest mailing list > Interest@qt-project.org > https://lists.qt-project.org/listinfo/interest > ___ Interest mailing list Interest@qt-project.org https://lists.qt-project.org/listinfo/interest
Re: [Interest] What are you using for continuous integration?
Not 100% sure, but assuming the macx-clang mkspec actually exists, I think that your Qt installation is not relocatable. Although locally I tried moving the online installed qt dir, and invoking qmake on an example worked fine. Maybe try running qmake -d .. &> log.txt and check if that gives you any info on which paths qmake is looking for. Maybe setting a qt.conf with a PrefixPath might also help. Just some suggestions. On Mon, Feb 18, 2019 at 1:08 PM Nuno Santos wrote: > Hi, > > I have found this slide deck very very very interesting. > > http://www.slidedeck.io/lasconic/qtci-qtcon2016 > > > It seems that MuseScore doing precisely what I want to do with Travis help. > > I became aware that Travis can build for Mac OSX. I didn’t knew that. And > that it is possible to build for windows as well through AppVeyor. This > were my number one requirements for this CI quest so I decided to give it a > try. > > I don’t have time to go through all the configuration steps from the > scratch with Jenkins. Yes, I could save money because Jenkins is free, but > time is money too and time is my most valuable resource. > > > I’m now tinkering around a Mac OSX build with Travis but I’m running into > a problem… > > For my desktop builds I depend on a static build of Qt. Obviously I don’t > want to compile Qt from source at each build so I’m downloading into the > worker a prebuilt Qt kit and I’m calling my build script which will call > qmake on the project, on the worker environment. The problem is: > > 1.06s$ ./build.sh > Building app.pro on 1550491076 > *Could not find qmake spec 'macx-clang'.* > > qmake is returning with the error above, saying that it can’t find qmake > spec ‘macx-clang’ > > What are the possible reasons for qmake to return with such error? What is > qmake looking for that it can’t find? > > Does anyone has an idea why this is happening? > > Thanks in advance! > > Regards, > > Nuno > > On 17 Feb 2019, at 15:33, Croitor Alexandru wrote: > > Hi, > > The mentioned qtci repo https://github.com/benlau/qtci also has two > reference links which look useful. Pasting here as well. > > http://www.slidedeck.io/lasconic/qtci-qtcon2016 > > http://andrewdolby.com/articles/2016/continuous-deployment-for-qt-applications/ > > Another source of inspiration can be the travis and appveyor config files > at https://github.com/bjorn/tiled which is a Qt application built with > qbs. > > One provider also worth considering is VSTS / Azure Pipelines. > > They offer free CI / CD and free runners (Windows, Linux, macOS) for open > source Git projects. > https://azure.microsoft.com/en-us/services/devops/pipelines/ > They claim each job can be up to 6 hours, which is higher than what Travis > allows iirc. > > Some discussion about it can be found here > https://www.reddit.com/r/programming/comments/9enz31/announcing_azure_pipelines_with_unlimited_cicd/ > > Cheers. > > On Sun, Feb 17, 2019 at 3:34 PM René Hansen wrote: > >> Does anyone have any experience using Travis for for Qt projects? >> >> I found this project, which seems to at least have a good general >> approach to setting up a usable environment for Travis: >> >> https://github.com/benlau/qtci >> >> If anyone has tried using it, I'd love to hear about it. >> >> >> /René >> >> On Thu, 14 Feb 2019 at 10:22 Elvis Stansvik wrote: >> >>> Den tors 14 feb. 2019 kl 10:08 skrev Nuno Santos < >>> nunosan...@imaginando.pt>: >>> > >>> > Hey, >>> > >>> > Thank you all for sharing your solutions and approaches. Among here >>> there are two obvious winners: >>> > >>> > - Jenkins >>> > - Buildbot >>> > >>> > I want to keep the build config within the project so I guess Jenkins >>> will be my way to go. >>> >>> For brevity, this is the side-project I mentioned to make Buildbot >>> more like Travis in that respect: >>> https://github.com/buildbot/buildbot_travis >>> >>> It's maintained (and I believe used) by the Buildbot maintainers >>> themselves. I've looked at it, but we haven't tried to use it. One >>> reason is that it works by dynamically adjusting the Buildbot config, >>> and I was unsure how this would work if we still wanted to have parts >>> of the Buildbot config that were custom/static (like I mentioned, we >>> have some other automation tasks that we run on top of the same >>> Buildbot master instance). >>> >>> Anyway, just thought I'd drop the link. Probably good idea to go with >
Re: [Interest] What are you using for continuous integration?
Hi, The mentioned qtci repo https://github.com/benlau/qtci also has two reference links which look useful. Pasting here as well. http://www.slidedeck.io/lasconic/qtci-qtcon2016 http://andrewdolby.com/articles/2016/continuous-deployment-for-qt-applications/ Another source of inspiration can be the travis and appveyor config files at https://github.com/bjorn/tiled which is a Qt application built with qbs. One provider also worth considering is VSTS / Azure Pipelines. They offer free CI / CD and free runners (Windows, Linux, macOS) for open source Git projects. https://azure.microsoft.com/en-us/services/devops/pipelines/ They claim each job can be up to 6 hours, which is higher than what Travis allows iirc. Some discussion about it can be found here https://www.reddit.com/r/programming/comments/9enz31/announcing_azure_pipelines_with_unlimited_cicd/ Cheers. On Sun, Feb 17, 2019 at 3:34 PM René Hansen wrote: > Does anyone have any experience using Travis for for Qt projects? > > I found this project, which seems to at least have a good general approach > to setting up a usable environment for Travis: > > https://github.com/benlau/qtci > > If anyone has tried using it, I'd love to hear about it. > > > /René > > On Thu, 14 Feb 2019 at 10:22 Elvis Stansvik wrote: > >> Den tors 14 feb. 2019 kl 10:08 skrev Nuno Santos < >> nunosan...@imaginando.pt>: >> > >> > Hey, >> > >> > Thank you all for sharing your solutions and approaches. Among here >> there are two obvious winners: >> > >> > - Jenkins >> > - Buildbot >> > >> > I want to keep the build config within the project so I guess Jenkins >> will be my way to go. >> >> For brevity, this is the side-project I mentioned to make Buildbot >> more like Travis in that respect: >> https://github.com/buildbot/buildbot_travis >> >> It's maintained (and I believe used) by the Buildbot maintainers >> themselves. I've looked at it, but we haven't tried to use it. One >> reason is that it works by dynamically adjusting the Buildbot config, >> and I was unsure how this would work if we still wanted to have parts >> of the Buildbot config that were custom/static (like I mentioned, we >> have some other automation tasks that we run on top of the same >> Buildbot master instance). >> >> Anyway, just thought I'd drop the link. Probably good idea to go with >> Jenkins if you want in-repo build recipies out of the box. >> >> Elvis >> >> > >> > Now I just need to go though all the configuration details. If anyone >> knows any really pragmatic documentation on how to setup Jenkins server >> with GitHub and how to setup a worker on Mac and Windows, please share. >> > >> > Thanks, >> > >> > Best regards, >> > >> > Nuno >> > >> > On 13 Feb 2019, at 19:02, Elvis Stansvik wrote: >> > >> > Den ons 13 feb. 2019 kl 00:06 skrev Nuno Santos < >> nunosan...@imaginando.pt>: >> > >> > >> > Hi, >> > >> > I’m curious about what you Qt heads are using for continuous >> integration. >> > >> > I have googled a few times this for this topic and I have found a >> couple of options but every time I tried to spend the minimum amount of >> time to setup one, it seems an incredible effort. I’m looking for a >> solution that allows me to: >> > >> > - push to a specific branch on GitHub >> > - get a local CI agent to fetch that branch and build it >> > >> > Ideally I would like it to be : >> > >> > - fast to setup >> > - Windows & Mac compatible >> > - ideally with docker integration >> > >> > Drone works damn well for web projects. I wanted something that cool >> for automatic desktop software building and packaging >> > >> > What are you people using? >> > >> > >> > We use Buildbot. It has worked very well, and we use it for some other >> > automation tasks besides software builds. It builds and tests software >> > from our local GitLab instance. Builds are mostly done in Docker >> > containers, though for macOS and Windows we run the Buildbot workers >> > on bare metal. >> > >> > Downside is it's configured using Python and the configuration takes >> > some getting used to when setting it up for the first time (but it's >> > very well designed and worth learning). The upside is it's Python :) >> > so it's *very* flexible. Downside is also that the config is central >> > and not kept with the repos (though there is a project to support >> > Travis-style in-repo config). >> > >> > Elvis >> > >> > >> > Thanks! >> > >> > Best, >> > >> > Nuno >> > ___ >> > Interest mailing list >> > Interest@qt-project.org >> > https://lists.qt-project.org/listinfo/interest >> > >> > >> > ___ >> > Interest mailing list >> > Interest@qt-project.org >> > https://lists.qt-project.org/listinfo/interest >> ___ >> Interest mailing list >> Interest@qt-project.org >> https://lists.qt-project.org/listinfo/interest >> > ___ > Interest mailing list >
Re: [Interest] QList and erase problem...
The documentation for QList::erase says: -- Removes the item associated with the iterator *pos* from the list, and returns an iterator to the next item in the list (which may be end ()). Documentation for iterator::operator++() says: Calling this function on QList::end () leads to undefined results. You have no check in your code to see if the iterator return by erase is QList::end(), thus calling operator++ on it might crash your application. On Mon, Sep 14, 2015 at 6:13 PM, Igor Mironchikwrote: > Hi, > > it seems that problem not in the iterating and deletion from cantainer... > > I wrote simple test app and everything is ok. > > But something here crashes my app and only in release mode, so I can't > understand what is the problem... > > And ideas? > > 9/14/2015 6:06 PM, André Somers пишет: > > Op 14-9-2015 om 16:57 schreef Igor Mironchik: > >> Hi, > >> > >> I ran into this problem... > >> > >> void > >> ImageFilesStoragePrivate::removeAllImages( > >>QList< ImageRecord > & images, > >>ImageFilesStorage::ImageType type ) > >> { > >>QList< ImageRecord >::Iterator it = images.begin(); > >>QList< ImageRecord >::Iterator last = images.end(); > >> > >>while( it != last ) > >>{ > >>if( (*it).m_type == type ) > >>{ > >>LOG( DebugLogLevel, "Before real deletion" ) > >>removeFromDatabase( it ); > >>LOG( DebugLogLevel, "After real deletion" ) > >> > >> //it = images.erase( it ); // LOOK AT THIS LINE !!! If I > >> uncomment it and comment next line - crash... > >>++it; > >> > >>LOG( DebugLogLevel, QString( "it == last : %1" ).arg( ( > it > >> == last ? "true" : "false" ) ) ) > >>} > >>else > >>++it; > >>} > >> } > >> > >> What is wrong? > > A lot is wrong. > > > > First, you are not using standard algorithms to do standard things. I'd > > say std::remove_if with std::erase would be a better way to solve the > issue. > > > > Then in general, if you delete from the container, iterators are going > > to be invalidated. Iterate backwards if you are going to delete items > > from the container. > > > > Last: you probably don't want to use QList but QVector. > > > > André > > > > > > ___ > > Interest mailing list > > Interest@qt-project.org > > http://lists.qt-project.org/mailman/listinfo/interest > > ___ > Interest mailing list > Interest@qt-project.org > http://lists.qt-project.org/mailman/listinfo/interest > ___ Interest mailing list Interest@qt-project.org http://lists.qt-project.org/mailman/listinfo/interest
[Interest] Track QQuickText console warning
Hi. I have Label {} qml element that has its visible and enabled property set to false. Whenever I hover over where the element should be, the following warning appears in console: QQuickText QVariant(Invalid) QRect(0,0 0x0) If remove the element, or set the visible flag to true, the warning disappears. This is the full element declaration. Label { id: backButton width: 40 height: root.height color: #ff text: \uE605 verticalAlignment: Text.AlignVCenter horizontalAlignment: Text.AlignHCenter font.family: *iconsfont.name http://iconsfont.name* font.pixelSize: 12 enabled: false visible: false } Can anyone point out what is the problem, or how I can track the source code line that is displaying this, so I can figure out what's wrong? I'm using Qt 5.5, on Mac OS Yosemite 10.10, XCode 6.4. ___ Interest mailing list Interest@qt-project.org http://lists.qt-project.org/mailman/listinfo/interest
Re: [Interest] Objective C Category for QCocoaApplicationDelegate undefined symbols
Thanks for the suggestions. I'll check if I'll be able to link against the base protocol (maybe with the use of the mentioned library). For the time being, I was able to solve the problem using method swizzling, by replacing the method provided by Qt with my own Block (lambda). I am aware that overriding methods this way is not a best practice, but it looks like the only way without modifying Qt's platform plugin source code, and compiling my own Qt. The pseudo-code looks something like this, in case if anyone needs to do the same. BOOL SwizzleReplaceMethodWithBlock(Class c, SEL origSEL, SEL newSEL, id block) { if ([c respondsToSelector:newSEL]) return YES; // Selector already implemented, skip Method origMethod = class_getInstanceMethod(c, origSEL); // Add the new method. IMP impl = imp_implementationWithBlock(block); if (!class_addMethod(c, newSEL, impl, method_getTypeEncoding(origMethod))) { NSLog(@Failed to add method: %@ on %@, NSStringFromSelector(newSEL), c); return NO; }else { Method newMethod = class_getInstanceMethod(c, newSEL); // If original doesn't implement the method we want to swizzle, create it. if (class_addMethod(c, origSEL, method_getImplementation(newMethod), method_getTypeEncoding(origMethod))) { class_replaceMethod(c, newSEL, method_getImplementation(origMethod), method_getTypeEncoding(newMethod)); }else { method_exchangeImplementations(origMethod, newMethod); } } return YES; } Class qtAppDelegateClass = [[[NSApplication sharedApplication] delegate] class]; SEL newAppDelegateLaunchSelector = NSSelectorFromString(@myAppDelegateApplicationDidFinishLaunching:); SwizzleReplaceMethodWithBlock(qtAppDelegateClass, @selector(applicationDidFinishLaunching:), newAppDelegateLaunchSelector, ^(NSObject* _self, NSNotification* aNotification) { NSLog(@applicationDidFinishLaunching before Qt method); // Call the original method. ((void ( *)(id, SEL, NSNotification *))objc_msgSend)(_self, newAppDelegateLaunchSelector, aNotification); NSLog(@The notification with which the app started is %@, aNotification); NSLog(@applicationDidFinishLaunching after Qt method); }); Anyway, my general idea, as you have figured out, is to extend QCocoaApplicationDelegate's base class (or Protocol), which I guess is an NSWhatever class/protocol. Then simply link your application explicitly with -lcocoa (or the correct framework/if needed). Maybe that gets you some ideas... ___ Interest mailing list Interest@qt-project.org http://lists.qt-project.org/mailman/listinfo/interest
[Interest] Objective C Category for QCocoaApplicationDelegate undefined symbols
Hi. I'm trying to add an Objective C category to the QCocoaApplicationDelegate class that is defined by the Mac OS X Cocoa platform plugin, to add / override some methods. The QCocoaApplicationDelegate is defined in Qt's source folder src/plugins/platforms/cocoa/qcocoaapplicationdelegate.h. My code for the category is as simple as this: // Code in osx_app_delegate.mm #include qglobal.h #include Cocoa/Cocoa.h @interface QCocoaApplicationDelegate @end @interface QCocoaApplicationDelegate (AppDelegate) @end @implementation QCocoaApplicationDelegate (AppDelegate) @end But when I try to compile the code, I get the following error: Undefined symbols for architecture x86_64: _OBJC_CLASS_$_QCocoaApplicationDelegate, referenced from: l_OBJC_$_CATEGORY_QCocoaApplicationDelegate_$_AppDelegate in osx_app_delegate.o ld: symbol(s) not found for architecture x86_64 clang: error: linker command failed with exit code 1 (use -v to see invocation) Doing the same (adding a category to the app delegate) on IOS works properly. I assume that is because the platform plugin on IOS is linked statically, whereas on OSX it is linked dynamically. I tried manually linking the cocoa plugin dylib file at link stage like so: LIBS += -L/Users/X/Dev/Qt/5.4/clang_64/plugins/platforms -lqcocoa But this doesn't help either. Is there no way to add the category if the platform plugin is dynamically loaded? Is the only option to statically compile Qt, and therefore the platform plugin as well? ___ Interest mailing list Interest@qt-project.org http://lists.qt-project.org/mailman/listinfo/interest
[Interest] Objective C Category for QCocoaApplicationDelegate undefined symbols
Hi. I'm trying to add an Objective C category to the QCocoaApplicationDelegate class that is defined by the Mac OS X Cocoa platform plugin, to add / override some methods. The QCocoaApplicationDelegate is defined in Qt's source folder src/plugins/platforms/cocoa/qcocoaapplicationdelegate.h. My code for the category is as simple as this: // Code in osx_app_delegate.mm #include qglobal.h #include Cocoa/Cocoa.h @interface QCocoaApplicationDelegate @end @interface QCocoaApplicationDelegate (AppDelegate) @end @implementation QCocoaApplicationDelegate (AppDelegate) @end But when I try to compile the code, I get the following error: Undefined symbols for architecture x86_64: _OBJC_CLASS_$_QCocoaApplicationDelegate, referenced from: l_OBJC_$_CATEGORY_QCocoaApplicationDelegate_$_AppDelegate in osx_app_delegate.o ld: symbol(s) not found for architecture x86_64 clang: error: linker command failed with exit code 1 (use -v to see invocation) Doing the same (adding a category to the app delegate) on IOS works properly. I assume that is because the platform plugin on IOS is linked statically, whereas on OSX it is linked dynamically. I tried manually linking the cocoa plugin dylib file at link stage like so: LIBS += -L/Users/X/Dev/Qt/5.4/clang_64/plugins/platforms -lqcocoa But this doesn't help either. Is there no way to add the category if the platform plugin is dynamically loaded? Is the only option to statically compile Qt, and therefore the platform plugin as well? ___ Interest mailing list Interest@qt-project.org http://lists.qt-project.org/mailman/listinfo/interest