[Interest] Scene Graph - Graph example background noise not appearing when OpenGL backend is used

2024-05-18 Thread Nuno Santos via Interest
Hi,

I’m taking as an example the Qt Scene Graph - Graph in order to pass a texture 
to a custom material.

However, if I use OpenGL as graphical backend by setting 
QQuickWindow::setGraphicsApi(QSGRendererInterface::OpenGL), the noise texture 
in the background does not appear. 

Is this example supposed to work if the backend is the default one?

Does anyone know the reason or the caveat here?

Thanks!

Regards,

Nuno










___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] Porting Qt5 OpenGL app to Qt6 - QQuickRenderTarget and OpenGL frame buffer object

2024-05-15 Thread Nuno Santos via Interest
Lazslo,

Thank you very much for your prompt reply.

If I will be doing this very very regularly, should I keep an instance of the 
FBO instance of creating and deleting all the time?

Best regards,

Nuno

> On 15 May 2024, at 15:46, Laszlo Agocs  wrote:
> 
> 
> Hi Nuno,
> 
> You can always create an FBO on the fly for the purposes of the readback.
> 
> For example, something along the lines of:
> 
> glGenFramebuffers(1, );
> glBindFramebuffer(GL_FRAMEBUFFER, fbo);
> glFramebufferTexture2D(GL_FRAMEBUFFER, GL_COLOR_ATTACHMENT0, GL_TEXTURE_2D, 
> texture, 0);
> glReadPixels(...);
> glBindFramebuffer(GL_FRAMEBUFFER, context->defaultFramebufferObject());
> glDeleteFramebuffers(1, );
> 
> Best regards,
> Laszlo
> 
> From: Nuno Santos  <mailto:nuno.san...@imaginando.pt>>
> Sent: Wednesday, May 15, 2024 4:29 PM
> To: Laszlo Agocs mailto:laszlo.ag...@qt.io>>
> Cc: interestqt-project. org  <mailto:interest@qt-project.org>>
> Subject: Re: [Interest] Porting Qt5 OpenGL app to Qt6 - QQuickRenderTarget 
> and OpenGL frame buffer object
>  
> Laszlo,
> 
> I have a new problem regarding this question.
> 
> I have a QQuickRenderControl in order to do a side render and be able to 
> extract the render output. I was reading from the FBO using the glReadPixels 
> function.
> 
> But now the render target is a OpenGL Texture but apparently the function 
> that reads from a GLTexture is glGetTexImage but that function is not on the 
> qopenglfunctions.
> 
> How can I read the texture now? 
> 
> Thanks!
> 
> Best regards,
> 
> Nuno
> 
>> On 8 May 2024, at 16:41, Laszlo Agocs > <mailto:laszlo.ag...@qt.io>> wrote:
>> 
>> Hi,
>> 
>> Passing 0 as a renderbuffer object name is not going to work. Try using 
>> https://doc.qt.io/qt-6/qquickrendertarget.html#fromOpenGLTexture with the 
>> texture that is used as the color attachment of your OpenGL framebuffer 
>> object. (actually that FBO is not useful in Qt 6 as one will be created 
>> internally as needed)
>> 
>> Best regards,
>> Laszlo
>> 
>> From: Interest > <mailto:interest-boun...@qt-project.org>> on behalf of Nuno Santos via 
>> Interest mailto:interest@qt-project.org>>
>> Sent: Tuesday, April 16, 2024 4:21 PM
>> To: interestqt-project. org > <mailto:interest@qt-project.org>>
>> Subject: [Interest] Porting Qt5 OpenGL app to Qt6 - QQuickRenderTarget and 
>> OpenGL frame buffer object
>>  
>> Hi,
>> 
>> I have an application that was heavily written on top of OpenGL. Right now I 
>> want to port it to Qt 6 with the minimum effort trying to stick to the 
>> OpenGL backend until I get the grip on the new things of Qt 6 Graphics API 
>> abstraction.
>> 
>> I used to do this in order to assign a target FBO to a QuickWindow:
>> 
>> _quickWindow->setRenderTarget(_fboRender);
>> 
>> This is no longer possible and it requires a QQuickRenderTarget to be 
>> created and I seem to have three options:
>> 
>> (since 6.2) QQuickRenderTarget  fromOpenGLRenderBuffer(uint renderbufferId, 
>> const QSize , int sampleCount = 1)
>> (since 6.4) QQuickRenderTarget  fromOpenGLTexture(uint textureId, uint 
>> format, const QSize , int sampleCount = 1)
>> QQuickRenderTarget  fromOpenGLTexture(uint textureId, const QSize 
>> , int sampleCount = 1)
>> 
>> I’m trying this:
>> 
>> _renderTarget = QQuickRenderTarget::fromOpenGLRenderBuffer(0, 
>> QSize(_renderResolution.width(), _renderResolution.height()));
>> _quickWindow->setRenderTarget(_renderTarget);
>> 
>> But nothing appears on the screen and I get a warning:
>> 
>> QQuickWindow: No render target (neither swapchain nor custom target was 
>> provided)
>> 
>> Can anyone tell me what am I failing here?
>> 
>> Any ideas suggestions are very welcome.
>> 
>> With my best regards,
>> 
>> Nuno
>> ___
>> Interest mailing list
>> Interest@qt-project.org <mailto: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] Porting Qt5 OpenGL app to Qt6 - QQuickRenderTarget and OpenGL frame buffer object

2024-05-15 Thread Nuno Santos via Interest
Laszlo,

I have a new problem regarding this question.

I have a QQuickRenderControl in order to do a side render and be able to 
extract the render output. I was reading from the FBO using the glReadPixels 
function.

But now the render target is a OpenGL Texture but apparently the function that 
reads from a GLTexture is glGetTexImage but that function is not on the 
qopenglfunctions.

How can I read the texture now? 

Thanks!

Best regards,

Nuno

> On 8 May 2024, at 16:41, Laszlo Agocs  wrote:
> 
> Hi,
> 
> Passing 0 as a renderbuffer object name is not going to work. Try using 
> https://doc.qt.io/qt-6/qquickrendertarget.html#fromOpenGLTexture with the 
> texture that is used as the color attachment of your OpenGL framebuffer 
> object. (actually that FBO is not useful in Qt 6 as one will be created 
> internally as needed)
> 
> Best regards,
> Laszlo
> 
> From: Interest  on behalf of Nuno Santos via 
> Interest 
> Sent: Tuesday, April 16, 2024 4:21 PM
> To: interestqt-project. org 
> Subject: [Interest] Porting Qt5 OpenGL app to Qt6 - QQuickRenderTarget and 
> OpenGL frame buffer object
>  
> Hi,
> 
> I have an application that was heavily written on top of OpenGL. Right now I 
> want to port it to Qt 6 with the minimum effort trying to stick to the OpenGL 
> backend until I get the grip on the new things of Qt 6 Graphics API 
> abstraction.
> 
> I used to do this in order to assign a target FBO to a QuickWindow:
> 
> _quickWindow->setRenderTarget(_fboRender);
> 
> This is no longer possible and it requires a QQuickRenderTarget to be created 
> and I seem to have three options:
> 
> (since 6.2) QQuickRenderTarget  fromOpenGLRenderBuffer(uint renderbufferId, 
> const QSize , int sampleCount = 1)
> (since 6.4) QQuickRenderTarget  fromOpenGLTexture(uint textureId, uint 
> format, const QSize , int sampleCount = 1)
> QQuickRenderTarget  fromOpenGLTexture(uint textureId, const QSize 
> , int sampleCount = 1)
> 
> I’m trying this:
> 
> _renderTarget = QQuickRenderTarget::fromOpenGLRenderBuffer(0, 
> QSize(_renderResolution.width(), _renderResolution.height()));
> _quickWindow->setRenderTarget(_renderTarget);
> 
> But nothing appears on the screen and I get a warning:
> 
> QQuickWindow: No render target (neither swapchain nor custom target was 
> provided)
> 
> Can anyone tell me what am I failing here?
> 
> Any ideas suggestions are very welcome.
> 
> With my best regards,
> 
> Nuno
> ___
> Interest mailing list
> Interest@qt-project.org <mailto: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] Is it possible to compile a shader in runtime using qsb?

2024-05-11 Thread Nuno Santos via Interest
Laszlo,

Thanks for this amazing tip. This is exactly what we needed! ;)

The Qt Company team rocks!

Have a great weekend.

Best regards,

Nuno

> On 8 May 2024, at 16:42, Laszlo Agocs  wrote:
> 
> Hi,
> 
> From Qt 6.6 on you can pull in the Qt Shader Tools module into the project 
> and try using https://doc.qt.io/qt-6/qshaderbaker.html
> 
> If this is actually suitable for your use case, cannot say without more 
> details, because doing the heavyweight compilation and transpilation at 
> runtime is one thing, being able to do something with the resulting QShader 
> object is another.
> 
> For instance, when working with custom scenegraph materials, a QShader can be 
> used instead of .qsb filenames via 
> https://doc.qt.io/qt-6/qsgmaterialshader.html#setShader
> If however the intention would be to do something similar in a ShaderEffect 
> declared in QML, there is no API to achieve that since its vertexShader and 
> fragmentShader properties only consume (.qsb) file URLs.
> 
> Best regards,
> Laszlo
> 
> From: Interest  on behalf of Nuno Santos via 
> Interest 
> Sent: Tuesday, May 7, 2024 11:28 AM
> To: interestqt-project. org 
> Subject: [Interest] Is it possible to compile a shader in runtime using qsb?
>  
> Hi,
> 
> I’m wondering if it is possible to run qsb to compile a shader in run time on 
> iOS.
> 
> I’m using QProcess to call qbs in order to compile in run time but since 
> QProcess does not exist on iOS, I wonder how can I achieve the same result?
> 
> Thanks!
> 
> Regards,
> 
> Nuno
> ___
> Interest mailing list
> Interest@qt-project.org <mailto: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] Porting Qt5 OpenGL app to Qt6 - QQuickRenderTarget and OpenGL frame buffer object

2024-05-08 Thread Nuno Santos via Interest
Laszlo,

Thanks for your reply.

I was able to overcome this problem a couple of weeks ago. Your suggestion was 
exactly what I have followed.

My biggest problem right now is definitely the lack of blend equation support. 
Can you please help?

Thank you!

Best regards,

Nuno

> On 8 May 2024, at 16:41, Laszlo Agocs  wrote:
> 
> Hi,
> 
> Passing 0 as a renderbuffer object name is not going to work. Try using 
> https://doc.qt.io/qt-6/qquickrendertarget.html#fromOpenGLTexture with the 
> texture that is used as the color attachment of your OpenGL framebuffer 
> object. (actually that FBO is not useful in Qt 6 as one will be created 
> internally as needed)
> 
> Best regards,
> Laszlo
> 
> From: Interest  on behalf of Nuno Santos via 
> Interest 
> Sent: Tuesday, April 16, 2024 4:21 PM
> To: interestqt-project. org 
> Subject: [Interest] Porting Qt5 OpenGL app to Qt6 - QQuickRenderTarget and 
> OpenGL frame buffer object
>  
> Hi,
> 
> I have an application that was heavily written on top of OpenGL. Right now I 
> want to port it to Qt 6 with the minimum effort trying to stick to the OpenGL 
> backend until I get the grip on the new things of Qt 6 Graphics API 
> abstraction.
> 
> I used to do this in order to assign a target FBO to a QuickWindow:
> 
> _quickWindow->setRenderTarget(_fboRender);
> 
> This is no longer possible and it requires a QQuickRenderTarget to be created 
> and I seem to have three options:
> 
> (since 6.2) QQuickRenderTarget  fromOpenGLRenderBuffer(uint renderbufferId, 
> const QSize , int sampleCount = 1)
> (since 6.4) QQuickRenderTarget  fromOpenGLTexture(uint textureId, uint 
> format, const QSize , int sampleCount = 1)
> QQuickRenderTarget  fromOpenGLTexture(uint textureId, const QSize 
> , int sampleCount = 1)
> 
> I’m trying this:
> 
> _renderTarget = QQuickRenderTarget::fromOpenGLRenderBuffer(0, 
> QSize(_renderResolution.width(), _renderResolution.height()));
> _quickWindow->setRenderTarget(_renderTarget);
> 
> But nothing appears on the screen and I get a warning:
> 
> QQuickWindow: No render target (neither swapchain nor custom target was 
> provided)
> 
> Can anyone tell me what am I failing here?
> 
> Any ideas suggestions are very welcome.
> 
> With my best regards,
> 
> Nuno
> ___
> Interest mailing list
> Interest@qt-project.org <mailto: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.7: How to set the blend equation when doing blend on updateGraphicsPipelineState?

2024-05-08 Thread Nuno Santos via Interest
Lazslo,

Thank you very much for your reply.

I was really hopeful that there was some kind of workaround for this 
limitation. This renders impossible to port an application from Qt 5 to Qt 6 at 
least as far as my knowledge goes.

Is there any possible workaround for this limitation? Can I do it if I edit the 
source code in any way? Can you please advise? 

With the current architecture the application relies heavily on this to make 
blending between layers. 

Thank you in advance!

Best regards,

Nuno

> On 8 May 2024, at 16:42, Laszlo Agocs  wrote:
> 
> Hi,
> 
> As you found, QSGMaterialShader::GraphicsPipelineState allows specifying the 
> blend factors, and from Qt 6.5 on it also supports specifying separate RGB 
> and alpha factors.
> 
> However, the blend equation is always ADD. There is no way to change that 
> currently.
> 
> Best regards,
> Laszlo
> 
> From: Interest  on behalf of Nuno Santos via 
> Interest 
> Sent: Monday, May 6, 2024 7:21 PM
> To: interestqt-project. org 
> Subject: [Interest] Qt 6.7: How to set the blend equation when doing blend on 
> updateGraphicsPipelineState?
>  
> Hi,
> 
> I’m porting an app from Qt 5.15 to Qt 6.7 but I’m stumbling on the fact that 
> there is no equivalent to blend equation in OpenGL.
> 
> Note: At the time being, I’m still using OpenGL as graphics backend to 
> minimise the already huge ongoing port.
> 
> 
> To achieve blending mode between nodes, I was using a mix between glBlendFunc 
> and glBlendEquation:
> 
> 
> case 
> Normal:
> 
> QOpenGLContext::currentContext()->functions()->glBlendFunc(GL_ONE, 
> GL_ONE_MINUS_SRC_ALPHA);
> 
> QOpenGLContext::currentContext()->functions()->glBlendEquation(GL_FUNC_ADD);
> 
> break;
> 
> case 
> Screen:
> 
> QOpenGLContext::currentContext()->functions()->glBlendFunc(GL_SRC_COLOR, 
> GL_ONE);
> 
> QOpenGLContext::currentContext()->functions()->glBlendEquation(GL_FUNC_ADD);
> 
> break;
> 
> case 
> Overlay:
> 
> QOpenGLContext::currentContext()->functions()->glBlendFunc(GL_SRC_COLOR, 
> GL_ONE);
> 
> QOpenGLContext::currentContext()->functions()->glBlendEquation(GL_MAX);
> 
> break;
> 
> case 
> Difference:
> 
> QOpenGLContext::currentContext()->functions()->glBlendFunc(GL_SRC_COLOR, 
> GL_ONE);
> 
> QOpenGLContext::currentContext()->functions()->glBlendEquation(GL_FUNC_REVERSE_SUBTRACT);
> 
> break;
> 
> 
> But in the newest version of QSGMaterialShader class documentation it says:
> 
> "The shader pipeline state changes are less often used. One use case is 
> materials that wish to use a specific blend mode. The relevant function is 
> updateGraphicsPipelineState(). This function is not called unless the 
> QSGMaterialShader has opted in by setting the flag 
> UpdatesGraphicsPipelineState. The task of the function is to update the 
> GraphicsPipelineState struct instance that is passed to it with the desired 
> changes. Currently only blending and culling-related features are available, 
> other states cannot be controlled by materials.”
> 
> So I’m now trying to use 
> 
> bool 
> QSGMaterialShader::updateGraphicsPipelineState(QSGMaterialShader::RenderState 
> , QSGMaterialShader::GraphicsPipelineState *ps, QSGMaterial 
> *newMaterial, QSGMaterial *oldMaterial)
> 
> 
> case Normal:
> 
> ps->srcColor = QSGMaterialShader::GraphicsPipelineState::One;
> 
> ps->dstColor = QSGMaterialShader::GraphicsPipelineState::OneMinusSrcAlpha;
> 
> break;
> 
> case Screen:
> 
> ps->srcColor = QSGMaterialShader::GraphicsPipelineState::SrcColor;
> 
> ps->dstColor = QSGMaterialShader::GraphicsPipelineState::One;
> 
> break;
> 
> case Overlay:
> 
> ps->srcColor = QSGMaterialShader::GraphicsPipelineState::SrcColor;
> 
> ps->dstColor = QSGMaterialShader::GraphicsPipelineState::One;
> 
> break;
> 
> case Difference:
> 
> ps->srcColor = QSGMaterialShader::GraphicsPipelineState::SrcColor;
> 
> ps->dstColor = QSGMaterialShader::GraphicsPipelineState::One;
> 
> break;
> 
> 
> 
> 
> 
> When the blendEquation GL_FUNC_ADD was used, it seems to be working.
> 
> But when I get to modes like Overlay and Difference, where the SRC and DST 
> are the same, without a blend equation, I don’t know how to do it.
> 
> Is there support to this use case?
> 
> Thank you in advance!
> 
> Best regards,
> 
> Nuno

___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


[Interest] Is it possible to compile a shader in runtime using qsb?

2024-05-07 Thread Nuno Santos via Interest
Hi,

I’m wondering if it is possible to run qsb to compile a shader in run time on 
iOS.

I’m using QProcess to call qbs in order to compile in run time but since 
QProcess does not exist on iOS, I wonder how can I achieve the same result?

Thanks!

Regards,

Nuno
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


[Interest] Qt 6.7: How to set the blend equation when doing blend on updateGraphicsPipelineState?

2024-05-06 Thread Nuno Santos via Interest
Hi,

I’m porting an app from Qt 5.15 to Qt 6.7 but I’m stumbling on the fact that 
there is no equivalent to blend equation in OpenGL.

Note: At the time being, I’m still using OpenGL as graphics backend to minimise 
the already huge ongoing port.


To achieve blending mode between nodes, I was using a mix between glBlendFunc 
and glBlendEquation:

case Normal:
QOpenGLContext::currentContext()->functions()->glBlendFunc(GL_ONE, 
GL_ONE_MINUS_SRC_ALPHA);

QOpenGLContext::currentContext()->functions()->glBlendEquation(GL_FUNC_ADD);
break;
case Screen:

QOpenGLContext::currentContext()->functions()->glBlendFunc(GL_SRC_COLOR, 
GL_ONE);

QOpenGLContext::currentContext()->functions()->glBlendEquation(GL_FUNC_ADD);
break;
case Overlay:

QOpenGLContext::currentContext()->functions()->glBlendFunc(GL_SRC_COLOR, 
GL_ONE);
QOpenGLContext::currentContext()->functions()->glBlendEquation(GL_MAX);
break;
case Difference:

QOpenGLContext::currentContext()->functions()->glBlendFunc(GL_SRC_COLOR, 
GL_ONE);

QOpenGLContext::currentContext()->functions()->glBlendEquation(GL_FUNC_REVERSE_SUBTRACT);
break;

But in the newest version of QSGMaterialShader class documentation it says:

"The shader pipeline state changes are less often used. One use case is 
materials that wish to use a specific blend mode. The relevant function is 
updateGraphicsPipelineState(). This function is not called unless the 
QSGMaterialShader has opted in by setting the flag 
UpdatesGraphicsPipelineState. The task of the function is to update the 
GraphicsPipelineState struct instance that is passed to it with the desired 
changes. Currently only blending and culling-related features are available, 
other states cannot be controlled by materials.”

So I’m now trying to use 

bool 
QSGMaterialShader::updateGraphicsPipelineState(QSGMaterialShader::RenderState 
, QSGMaterialShader::GraphicsPipelineState *ps, QSGMaterial *newMaterial, 
QSGMaterial *oldMaterial)

case Normal:
ps->srcColor = QSGMaterialShader::GraphicsPipelineState::One;
ps->dstColor = QSGMaterialShader::GraphicsPipelineState::OneMinusSrcAlpha;
break;
case Screen:
ps->srcColor = QSGMaterialShader::GraphicsPipelineState::SrcColor;
ps->dstColor = QSGMaterialShader::GraphicsPipelineState::One;
break;
case Overlay:
ps->srcColor = QSGMaterialShader::GraphicsPipelineState::SrcColor;
ps->dstColor = QSGMaterialShader::GraphicsPipelineState::One;
break;
case Difference:
ps->srcColor = QSGMaterialShader::GraphicsPipelineState::SrcColor;
ps->dstColor = QSGMaterialShader::GraphicsPipelineState::One;
break;


When the blendEquation GL_FUNC_ADD was used, it seems to be working.

But when I get to modes like Overlay and Difference, where the SRC and DST are 
the same, without a blend equation, I don’t know how to do it.

Is there support to this use case?

Thank you in advance!

Best regards,

Nuno___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


[Interest] How to make use of CONFIG+=sanitizer CONFIG+=sanitize_thread

2024-04-20 Thread Nuno Santos via Interest
Hi,

I’m trying to take advantage of the sanitizer functionality, but how does one 
take adavantage of it?

I’ve compiled Qt from source with "-sanitize thread”

And I’ve read that in qmake I need to add "CONFIG+=sanitizer 
CONFIG+=sanitize_thread”

But can I take advantage of this? How do I know it is working?

Can someone please enlighten me?

Thanks!

Regards,

Nuno
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] Outdated documentation detail

2024-04-19 Thread Nuno Santos via Interest
Kai,

Thanks for the tip.

Will do next time.

Best regards,

Nuno

> On 19 Apr 2024, at 12:02, Kai Köhne  wrote:
> 
> Hi Nuo,
> 
> thanks for the heads up! This will get fixed in the next releases ( 
> https://codereview.qt-project.org/c/qt/qtdeclarative/+/556227 ).
> 
> Just FYI, the more reliable process for also documentation bugs is to go to 
> https://bugreports.qt.io <https://bugreports.qt.io/>, and file a bug for the 
> 'Documentation'  component. 
> 
> Regards
> 
> Kai
> From: Interest  on behalf of Nuno Santos via 
> Interest 
> Sent: Wednesday, April 17, 2024 9:18
> To: interestqt-project. org 
> Subject: [Interest] Outdated documentation detail
>  
> Hi,
> 
> I just wanted to share that the following documentation is outdated:
> 
> https://doc.qt.io/qt-6/qtquick-scenegraph-metaltextureimport-example.html
> 
> It makes references to QQuickWindow::createTextureFromNativeObject() but this 
> method is now found under:
> 
> QNativeInterface::QSGOpenGLTexture::fromNative(…)
> 
> I’ve only found this actually looking at the example rendercontrol_opengl
> 
> Regards,
> 
> Nuno

___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


[Interest] What is the most efficient and performant way of rendering a QVideoSink to a Scene Graph node using Qt 6?

2024-04-17 Thread Nuno Santos via Interest
Hi,

I’m looking to render a video into a custom scene graph node.

I want to have all the source handling on the C++ side and inject the video 
frames into a custom scene graph node.

I can obtain the frames from QVideoSink and now I’m wondering how is the most 
performant way of copying it to a texture and displaying it on a 
QSGOpaqueTextureMaterial.

Any tips?

Thanks in advance!

Nuno

___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


[Interest] Outdated documentation detail

2024-04-17 Thread Nuno Santos via Interest
Hi,

I just wanted to share that the following documentation is outdated:

https://doc.qt.io/qt-6/qtquick-scenegraph-metaltextureimport-example.html

It makes references to QQuickWindow::createTextureFromNativeObject() but this 
method is now found under:

QNativeInterface::QSGOpenGLTexture::fromNative(…)

I’ve only found this actually looking at the example rendercontrol_opengl

Regards,

Nuno___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


[Interest] Porting Qt5 OpenGL app to Qt6 - QQuickRenderTarget and OpenGL frame buffer object

2024-04-16 Thread Nuno Santos via Interest
Hi,

I have an application that was heavily written on top of OpenGL. Right now I 
want to port it to Qt 6 with the minimum effort trying to stick to the OpenGL 
backend until I get the grip on the new things of Qt 6 Graphics API abstraction.

I used to do this in order to assign a target FBO to a QuickWindow:

_quickWindow->setRenderTarget(_fboRender);

This is no longer possible and it requires a QQuickRenderTarget to be created 
and I seem to have three options:

(since 6.2) QQuickRenderTarget  fromOpenGLRenderBuffer(uint renderbufferId, 
const QSize , int sampleCount = 1)
(since 6.4) QQuickRenderTarget  fromOpenGLTexture(uint textureId, uint format, 
const QSize , int sampleCount = 1)
QQuickRenderTarget  fromOpenGLTexture(uint textureId, const QSize 
, int sampleCount = 1)

I’m trying this:

_renderTarget = QQuickRenderTarget::fromOpenGLRenderBuffer(0, 
QSize(_renderResolution.width(), _renderResolution.height()));
_quickWindow->setRenderTarget(_renderTarget);

But nothing appears on the screen and I get a warning:

QQuickWindow: No render target (neither swapchain nor custom target was 
provided)

Can anyone tell me what am I failing here?

Any ideas suggestions are very welcome.

With my best regards,

Nuno
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


[Interest] Crash on Qt iOS - NSUndoStack popAndInvoke (NSUndoManager.m:1714)

2024-03-15 Thread Nuno Santos via Interest
Hi,

I have been having this stack trace related with undo manager. It is very 
particular to one single tester.

Is anyone having similar problems?

Thread 0 name:
Thread 0 Crashed:
0   libobjc.A.dylib 0x00019d454820 objc_msgSend + 32
1   Foundation  0x0001a4773410 -[_NSUndoStack 
popAndInvoke] + 116 (NSUndoManager.m:1714)
2   Foundation  0x0001a47717c4 -[NSUndoManager 
__redoCommonDoSingle:] + 184 (NSUndoManager.m:771)
3   UIKit   0x00023ba23c50 
-[NSUndoManagerAccessibility__UIKit__Foundation redo] + 76 
(NSUndoManagerAccessibility.m:38)
4   UIKitCore   0x0001a7ff1aac 
-[UIUndoGestureInteraction redo:] + 44 (UIUndoGestureInteraction.m:1536)
5   UIKitCore   0x0001a7ff13a4 
-[UIUndoGestureInteraction performActionWithDirection:] + 104 
(UIUndoGestureInteraction.m:0)
6   UIKitCore   0x0001a7ff10bc 
-[UIUndoGestureInteraction _endPanWithDirection:] + 40 
(UIUndoGestureInteraction.m:1346)
7   UIKitCore   0x0001a7ff150c 
-[UIUndoGestureInteraction performGestureWithDirection:authenticationMessage:] 
+ 120 (UIUndoGestureInteraction.m:1447)
8   UIKitCore   0x0001a78016dc 
-[_UIProductivityGestureAction _handleActionForWindowScene:] + 268 
(UIProductivityGestureAction.m:56)
9   UIKitCore   0x0001a7655344 -[UIApplication 
_handleNonLaunchSpecificActions:forScene:withTransitionContext:completion:] + 
3416 (UIApplication.m:11401)
10  UIKitCore   0x0001a73ea788 -[UIScene 
_emitSceneSettingsUpdateResponseForCompletion:afterSceneUpdateWork:] + 420 
(UIScene.m:1742)
11  UIKitCore   0x0001a73ea52c -[UIScene 
scene:didUpdateWithDiff:transitionContext:completion:] + 244 (UIScene.m:2012)
12  UIKitCore   0x0001a73ea36c 
-[UIApplicationSceneClientAgent scene:handleEvent:withCompletion:] + 336 
(UIApplicationSceneClientAgent.m:86)
13  FrontBoardServices  0x0001bd55641c -[FBSScene 
updater:didReceiveActions:forExtension:] + 1160 (FBSScene.m:904)
14  FrontBoardServices  0x0001bd53c19c -[FBSWorkspace 
_calloutQueue_executeCalloutFromSource:withBlock:] + 168 (FBSWorkspace.m:411)
15  FrontBoardServices  0x0001bd576cc4 
__71-[FBSWorkspaceScenesClient 
sceneID:sendActions:toExtension:completion:]_block_invoke + 220 
(FBSWorkspaceScenesClient.m:563)
16  libdispatch.dylib   0x0001ad082300 
_dispatch_client_callout + 20 (object.m:561)
17  libdispatch.dylib   0x0001ad085d48 
_dispatch_block_invoke_direct + 284 (queue.c:496)
18  FrontBoardServices  0x0001bd538520 
__FBSSERIALQUEUE_IS_CALLING_OUT_TO_A_BLOCK__ + 52 (FBSSerialQueue.m:285)
19  FrontBoardServices  0x0001bd5384a0 
-[FBSMainRunLoopSerialQueue _targetQueue_performNextIfPossible] + 240 
(FBSSerialQueue.m:309)
20  FrontBoardServices  0x0001bd538378 
-[FBSMainRunLoopSerialQueue _performNextFromRunLoopSource] + 28 
(FBSSerialQueue.m:322)
21  CoreFoundation  0x0001a50bd0ac 
__CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE0_PERFORM_FUNCTION__ + 28 
(CFRunLoop.c:1957)
22  CoreFoundation  0x0001a50bc328 __CFRunLoopDoSource0 
+ 176 (CFRunLoop.c:2001)
23  CoreFoundation  0x0001a50bab3c 
__CFRunLoopDoSources0 + 340 (CFRunLoop.c:2046)
24  CoreFoundation  0x0001a50b9818 __CFRunLoopRun + 828 
(CFRunLoop.c:2955)
25  CoreFoundation  0x0001a50b93f8 CFRunLoopRunSpecific 
+ 608 (CFRunLoop.c:3420)
26  GraphicsServices0x0001e86474f8 GSEventRunModal + 
164 (GSEvent.c:2196)
27  UIKitCore   0x0001a74df8a0 -[UIApplication 
_run] + 888 (UIApplication.m:3685)
28  UIKitCore   0x0001a74deedc UIApplicationMain + 
340 (UIApplication.m:5270)
29  BAM 0x00010462a660 qt_main_wrapper + 820
30  dyld0x0001c7e0edcc start + 2240 
(dyldMain.cpp:1269)
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] Is it possible to have a thread running in a Qt iOS app when the app is put in background?

2024-02-19 Thread Nuno Santos via Interest
Hi Tor,

Thanks for your reply and additional info.

Has any here in this list made this before with Qt?

Thanks!

Best,

Nuno

> On 19 Feb 2024, at 10:45, Tor Arne Vestbø  wrote:
> 
> Not out of the box.
> 
> You should be able to use 
> https://developer.apple.com/documentation/backgroundtasks?language=objc 
> though.
> 
> Cheers,
> Tor Arne
> 
>> On 19 Feb 2024, at 11:39, Nuno Santos via Interest  
>> wrote:
>> 
>> Hi,
>> 
>> I have a music making app that allows to export the full song. This is an 
>> asynchronous process that can take several minutes and the user can start an 
>> export and decide to put the app in background in the mean time. At the time 
>> being, if he does this, the app will crash. 
>> 
>> Is it possible to keep the thread running while the app is put in background?
>> 
>> 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] Is it possible to have a thread running in a Qt iOS app when the app is put in background?

2024-02-19 Thread Nuno Santos via Interest
Hi,

I have a music making app that allows to export the full song. This is an 
asynchronous process that can take several minutes and the user can start an 
export and decide to put the app in background in the mean time. At the time 
being, if he does this, the app will crash. 

Is it possible to keep the thread running while the app is put in background?

Thanks!

Best,

Nuno
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


[Interest] Is anyone here using Qt to develop audio plugins and is having issues with Steinberg's Cubase 13?

2024-02-15 Thread Nuno Santos via Interest
Hi,

Is anyone here developing audio plugins with Qt?

We have been doing this since 2015 without any issues. Last year, Steinberg 
released Cubase 13 and all our plugins freeze when instantiated, Qt 5 or Qt 6 
based, it does not matter.

This problem happens on Windows only. We believe the problem is on their side 
but we simply can’t reach them. I have tried via support, via friends, via old 
emails. I can’t get an answer from them.

I was wondering if someone here was passing through the same dilema. 

Thanks!

Best,

Nuno
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] Qt 6.5.4-LTS from source -> fatal: Unable to find current revision in submodule path 'qt5compat'

2024-02-09 Thread Nuno Santos via Interest
Alexandru,

Thanks for the additional info and for investigating further 

Best regards,

Nuno

> On 9 Feb 2024, at 10:48, Alexandru Croitor  wrote:
> 
> Hi, replying inline.
> 
>> On 9. Feb 2024, at 11:05, Nuno Santos  wrote:
>> 
>> Alexandru,
>> 
>> Same problem
>> 
>> ➜  6.5.4 git clone 
>> "ssh://sinosoi...@codereview.qt-project.org:29418/qt/tqtc-qt5"
>> Cloning into 'tqtc-qt5'...
>> remote: Counting objects: 189, done
>> remote: Finding sources: 100% (32453/32453)
>> remote: Total 32453 (delta 22269), reused 31126 (delta 22269)
>> Receiving objects: 100% (32453/32453), 10.35 MiB | 16.92 MiB/s, done.
>> Resolving deltas: 100% (22269/22269), done.
>> warning: remote HEAD refers to nonexistent ref, unable to checkout
> 
> 
> This is strange, even at tqtc-qt5 clone time, it's already trying to checkout 
> a non-existent ref.
> Same happens later with qt5compat in your provided log.
> 
> When i clone tqtc-qt5, i get a higher number of received objects.
> 
> git clone "ssh://codereview.qt-project.org:29418/qt/tqtc-qt5" qt6_new
> Cloning into 'qt6_new'...
> remote: Counting objects: 760, done
> remote: Finding sources: 100% (44/44)
> remote: Total 45689 (delta 6), reused 45651 (delta 6)
> Receiving objects: 100% (45689/45689), 12.53 MiB | 3.08 MiB/s, done.
> Resolving deltas: 100% (32846/32846), done.
> 
> 45689 vs 32453
> 
> I suspect your account might have insufficient access to download the 
> relevant refs from gerrit, due to additional access control on tqtc lts repos.
> 
> I reached out internally for additional info on that.

___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] Qt 6.5.4-LTS from source -> fatal: Unable to find current revision in submodule path 'qt5compat'

2024-02-09 Thread Nuno Santos via Interest
I’m trying as an alternative to build 6.6.1 from source but I’m also having 
this:

+ git submodule init tests/auto/qml/ecmascripttests/test262
 *** /qtdeclarative/tests/auto/qml/ecmascripttests/test262 not found, ignoring 
alternate for this submodule
+ git config remote.origin.url git://code.qt.io/qt/qtdeclarative-testsuites.git
+ git fetch origin
+ git config remote.gerrit.url 
ssh://codereview.qt-project.org/qt/qtdeclarative-testsuites.git
+ git config remote.gerrit.fetch +refs/heads/*:refs/remotes/gerrit/* /heads/
+ git submodule update --force --no-fetch
Submodule path 'tests/auto/qml/ecmascripttests/test262': checked out 
'a0efb7e1ab1cee24c387abe1897ff18fa116c17d'
+ git config remote.gerrit.url ssh://codereview.qt-project.org/qt/qt5
+ git config remote.gerrit.fetch +refs/heads/*:refs/remotes/gerrit/* /heads/
Warning: cannot find Git hooks, qtrepotools module might be absent



> On 9 Feb 2024, at 10:05, Nuno Santos  wrote:
> 
> Alexandru,
> 
> Same problem
> 
> ➜  6.5.4 git clone 
> "ssh://sinosoi...@codereview.qt-project.org:29418/qt/tqtc-qt5"
> Cloning into 'tqtc-qt5'...
> remote: Counting objects: 189, done
> remote: Finding sources: 100% (32453/32453)
> remote: Total 32453 (delta 22269), reused 31126 (delta 22269)
> Receiving objects: 100% (32453/32453), 10.35 MiB | 16.92 MiB/s, done.
> Resolving deltas: 100% (22269/22269), done.
> warning: remote HEAD refers to nonexistent ref, unable to checkout
> ➜  6.5.4 cd tqtc-qt5
> ➜  tqtc-qt5 git:(main) git checkout origin/tqtc/lts-6.5.4
> Note: switching to 'origin/tqtc/lts-6.5.4'.
> 
> You are in 'detached HEAD' state. You can look around, make experimental
> changes and commit them, and you can discard any commits you make in this
> state without impacting any branches by switching back to a branch.
> 
> If you want to create a new branch to retain commits you create, you may
> do so (now or later) by using -c with the switch command. Example:
> 
>  git switch -c 
> 
> Or undo this operation with:
> 
>  git switch -
> 
> Turn off this advice by setting config variable advice.detachedHead to false
> 
> HEAD is now at 3303dc7a Provisioning: Update Axivion bauhaus-suite
> ➜  tqtc-qt5 git:(3303dc7a) ./init-repository --module-subset=qt5compat
> + git submodule init qt5compat
> Submodule 'qt5compat' 
> (ssh://sinosoi...@codereview.qt-project.org:29418/qt/tqtc-qt5compat.git) 
> registered for path 'qt5compat'
> + git config commit.template /Users/nsantos/Qt/6.5.4/tqtc-qt5/.commit-template
> + git clone --no-checkout 
> ssh://sinosoi...@codereview.qt-project.org:29418/qt/tqtc-qt5compat.git 
> qt5compat
> Cloning into 'qt5compat'...
> remote: Counting objects: 29, done
> remote: Finding sources: 100% (6700/6700)
> remote: Total 6700 (delta 3705), reused 6477 (delta 3705)
> Receiving objects: 100% (6700/6700), 15.95 MiB | 20.39 MiB/s, done.
> Resolving deltas: 100% (3705/3705), done.
> + git config commit.template /Users/nsantos/Qt/6.5.4/tqtc-qt5/.commit-template
> + git config remote.gerrit.url 
> ssh://codereview.qt-project.org/qt/tqtc-qt5compat.git
> + git config remote.gerrit.fetch +refs/heads/*:refs/remotes/gerrit/* /heads/
> + git submodule update --force --no-fetch
> fatal: Unable to find current revision in submodule path 'qt5compat'
> git submodule update --force --no-fetch exited with status 32768 at 
> ./init-repository line 207.
>   Qt::InitRepository::exe(Qt::InitRepository=HASH(0x15980bdd8), "git", 
> "submodule", "update", "--force", "--no-fetch") called at ./init-repository 
> line 452
>   
> Qt::InitRepository::git_clone_all_submodules(Qt::InitRepository=HASH(0x15980bdd8),
>  "tqtc-qt5", 0, "", "qt5compat") called at ./init-repository line 674
>   Qt::InitRepository::run(Qt::InitRepository=HASH(0x15980bdd8)) called at 
> ./init-repository line 685
> ➜  tqtc-qt5 git:(3303dc7a)
> 
>> On 9 Feb 2024, at 09:52, Alexandru Croitor  wrote:
>> 
>> Hi,
>> 
>> I just tried the following sequence of commands locally with no pre-existing 
>> directory, and everything worked fine.
>> 
>> git clone "ssh://@codereview.qt-project.org:29418/qt/tqtc-qt5" 
>> qt6_new
>> cd qt6_new
>> git checkout origin/tqtc/lts-6.5.4
>> ./init-repository --module-subset=qt5compat
>> 
>> Can you confirm whether the same works for you, to figure out whether this 
>> is a general issue, or an issue with the state of your pre-existing checkout?
>> 
>> Also please show the output of running 'git rev-parse HEAD' in your 
>> pre-existing qt5compat directory and in your tqtc-qt5 directory.
>> 
>> 
>>> On 9. Feb 2024, at 10:33, Nuno Santos

Re: [Interest] Qt 6.5.4-LTS from source -> fatal: Unable to find current revision in submodule path 'qt5compat'

2024-02-09 Thread Nuno Santos via Interest
Alexandru,

Same problem

➜  6.5.4 git clone 
"ssh://sinosoi...@codereview.qt-project.org:29418/qt/tqtc-qt5"
Cloning into 'tqtc-qt5'...
remote: Counting objects: 189, done
remote: Finding sources: 100% (32453/32453)
remote: Total 32453 (delta 22269), reused 31126 (delta 22269)
Receiving objects: 100% (32453/32453), 10.35 MiB | 16.92 MiB/s, done.
Resolving deltas: 100% (22269/22269), done.
warning: remote HEAD refers to nonexistent ref, unable to checkout
➜  6.5.4 cd tqtc-qt5
➜  tqtc-qt5 git:(main) git checkout origin/tqtc/lts-6.5.4
Note: switching to 'origin/tqtc/lts-6.5.4'.

You are in 'detached HEAD' state. You can look around, make experimental
changes and commit them, and you can discard any commits you make in this
state without impacting any branches by switching back to a branch.

If you want to create a new branch to retain commits you create, you may
do so (now or later) by using -c with the switch command. Example:

  git switch -c 

Or undo this operation with:

  git switch -

Turn off this advice by setting config variable advice.detachedHead to false

HEAD is now at 3303dc7a Provisioning: Update Axivion bauhaus-suite
➜  tqtc-qt5 git:(3303dc7a) ./init-repository --module-subset=qt5compat
+ git submodule init qt5compat
Submodule 'qt5compat' 
(ssh://sinosoi...@codereview.qt-project.org:29418/qt/tqtc-qt5compat.git) 
registered for path 'qt5compat'
+ git config commit.template /Users/nsantos/Qt/6.5.4/tqtc-qt5/.commit-template
+ git clone --no-checkout 
ssh://sinosoi...@codereview.qt-project.org:29418/qt/tqtc-qt5compat.git qt5compat
Cloning into 'qt5compat'...
remote: Counting objects: 29, done
remote: Finding sources: 100% (6700/6700)
remote: Total 6700 (delta 3705), reused 6477 (delta 3705)
Receiving objects: 100% (6700/6700), 15.95 MiB | 20.39 MiB/s, done.
Resolving deltas: 100% (3705/3705), done.
+ git config commit.template /Users/nsantos/Qt/6.5.4/tqtc-qt5/.commit-template
+ git config remote.gerrit.url 
ssh://codereview.qt-project.org/qt/tqtc-qt5compat.git
+ git config remote.gerrit.fetch +refs/heads/*:refs/remotes/gerrit/* /heads/
+ git submodule update --force --no-fetch
fatal: Unable to find current revision in submodule path 'qt5compat'
git submodule update --force --no-fetch exited with status 32768 at 
./init-repository line 207.
Qt::InitRepository::exe(Qt::InitRepository=HASH(0x15980bdd8), "git", 
"submodule", "update", "--force", "--no-fetch") called at ./init-repository 
line 452

Qt::InitRepository::git_clone_all_submodules(Qt::InitRepository=HASH(0x15980bdd8),
 "tqtc-qt5", 0, "", "qt5compat") called at ./init-repository line 674
Qt::InitRepository::run(Qt::InitRepository=HASH(0x15980bdd8)) called at 
./init-repository line 685
➜  tqtc-qt5 git:(3303dc7a)

> On 9 Feb 2024, at 09:52, Alexandru Croitor  wrote:
> 
> Hi,
> 
> I just tried the following sequence of commands locally with no pre-existing 
> directory, and everything worked fine.
> 
> git clone "ssh://@codereview.qt-project.org:29418/qt/tqtc-qt5" 
> qt6_new
> cd qt6_new
> git checkout origin/tqtc/lts-6.5.4
> ./init-repository --module-subset=qt5compat
> 
> Can you confirm whether the same works for you, to figure out whether this is 
> a general issue, or an issue with the state of your pre-existing checkout?
> 
> Also please show the output of running 'git rev-parse HEAD' in your 
> pre-existing qt5compat directory and in your tqtc-qt5 directory.
> 
> 
>> On 9. Feb 2024, at 10:33, Nuno Santos via Interest  
>> wrote:
>> 
>> Thiago,
>> 
>> Doing just:
>> 
>> git submodule init qt5compat does nothing, the directory remains empty
>> 
>> Curiously it says the same thing as the perl init repository if I do:
>> 
>> git submodule update --init --recursive qt5compat
>> 
>> fatal: Unable to find current revision in submodule path ‘qt5compat’
>> 
>> ➜  tqtc-qt5 git:(v6.5.4-lts) ✗ cat .gitmodules | grep qt5compat
>> [submodule "qt5compat"]
>> path = qt5compat
>> url = ../tqtc-qt5compat.git
>> alias = qt/qt5compat
>> 
>> Any ideas?
>> 
>> Best,
>> 
>> Nuno
>> 
>> 
>>> On 9 Feb 2024, at 00:37, Thiago Macieira  wrote:
>>> 
>>> On Thursday, 8 February 2024 13:28:10 PST Nuno Santos via Interest wrote:
>>>> One question. I’m not interested in all the modules. Just some of them. If 
>>>> I
>>>> do that I will unit all the modules and therefore the build will contain
>>>> them all right?
>>> 
>>> Correct.
>>> 
>>> You can do "git submodule init" for each of the modules you want.
>>> 
>>> Alternatively, you can clone and build just the modules yo

Re: [Interest] Qt 6.5.4-LTS from source -> fatal: Unable to find current revision in submodule path 'qt5compat'

2024-02-09 Thread Nuno Santos via Interest
Thiago,

Doing just:

git submodule init qt5compat does nothing, the directory remains empty

Curiously it says the same thing as the perl init repository if I do:

git submodule update --init --recursive qt5compat

fatal: Unable to find current revision in submodule path ‘qt5compat’

➜  tqtc-qt5 git:(v6.5.4-lts) ✗ cat .gitmodules | grep qt5compat
[submodule "qt5compat"]
path = qt5compat
url = ../tqtc-qt5compat.git
alias = qt/qt5compat

Any ideas?

Best,

Nuno


> On 9 Feb 2024, at 00:37, Thiago Macieira  wrote:
> 
> On Thursday, 8 February 2024 13:28:10 PST Nuno Santos via Interest wrote:
>> One question. I’m not interested in all the modules. Just some of them. If I
>> do that I will unit all the modules and therefore the build will contain
>> them all right?
> 
> Correct.
> 
> You can do "git submodule init" for each of the modules you want.
> 
> Alternatively, you can clone and build just the modules you want. You don't 
> need the top-level dir.
> 
> -- 
> Thiago Macieira - thiago.macieira (AT) intel.com
>  Cloud Software Architect - Intel DCAI 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.5.4-LTS from source -> fatal: Unable to find current revision in submodule path 'qt5compat'

2024-02-08 Thread Nuno Santos via Interest
Thiago,

I could try to see if that is an option that works.

One question. I’m not interested in all the modules. Just some of them. If I do 
that I will unit all the modules and therefore the build will contain them all 
right?

Thanks,

--
Nuno Santos

> No dia 08/02/2024, às 20:31, Thiago Macieira  
> escreveu:
> 
> On Thursday, 8 February 2024 09:19:12 PST Nuno Santos via Interest wrote:
>> Thanks for your reply.
>> 
>> From the repository, the lts one.
> 
> I don't know what's wrong then. I don't use the init-repository script.
> 
> Just use "git submodule update --recursive --init" and be done with it. You
> don't need the extra features of the init-repository script because you're not
> going to use this repository to contribute to Qt (no need for the post-commit
> hook and for the Git remotes to push to Gerrit).
> 
> --
> Thiago Macieira - thiago.macieira (AT) intel.com
>  Cloud Software Architect - Intel DCAI 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.5.4-LTS from source -> fatal: Unable to find current revision in submodule path 'qt5compat'

2024-02-08 Thread Nuno Santos via Interest
Thiago,

Thanks for your reply.

From the repository, the lts one.

--
Nuno Santos

> No dia 08/02/2024, às 16:53, Thiago Macieira  
> escreveu:
> 
> On Tuesday, 6 February 2024 07:02:11 PST Nuno Santos via Interest wrote:
>> While trying to build Qt 6 from source I’m having this error while
>> initialising the necessary modulates with the following line:
> 
> To be clear: when you say "from source", do you mean from the tarball or from
> the Git repository?
> 
> If you're building from the tarball, then you do not have a Git repository, so
> you shouldn't run init-repository.
> 
> --
> Thiago Macieira - thiago.macieira (AT) intel.com
>  Cloud Software Architect - Intel DCAI 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.5.4-LTS from source -> fatal: Unable to find current revision in submodule path 'qt5compat'

2024-02-08 Thread Nuno Santos via Interest
Rainer,

Thanks for your reply.

I have tried to do:

git submodule sync —recursive

And then run again:

perl init-repository -f 
--module-subset=qt5compat,qtbase,qtdeclarative,qtimageformats,qtmultimedia,qtshadertools,qtsvg,qtwebsockets

But the same problem happened:

fatal: Unable to find current revision in submodule path 'qt5compat'
git submodule update --force --no-fetch exited with status 32768 at 
init-repository line 207.
Qt::InitRepository::exe(Qt::InitRepository=HASH(0x12f80b7d8), "git", 
"submodule", "update", "--force", "--no-fetch") called at init-repository line 
452

Qt::InitRepository::git_clone_all_submodules(Qt::InitRepository=HASH(0x12f80b7d8),
 "tqtc-qt5", 0, "", "qt5compat", "qtbase", "qtdeclarative", "qtimageformats", 
...) called at init-repository line 674
Qt::InitRepository::run(Qt::InitRepository=HASH(0x12f80b7d8)) called at 
init-repository line 685

Does anyone knows how to overcome this problem?

Thank you in advance!

Best regards,

Nuno

> On 6 Feb 2024, at 15:19, Rainer Wiesenfarth  
> wrote:
> 
> Not sure how Qt handles this, but whenever I ran into similar issues with git 
> submodules, a
> 
> git submodule sync --recursive
> 
> on the top level solved it.
> 
> Background: The submodules' remote repository may have changed in 
> .gitmodules, but the submodule itself still references the outdated remote 
> repository.
> 
> Cheers, Rainer
> 
> On Tue, Feb 6, 2024 at 4:06 PM Nuno Santos via Interest 
> mailto:interest@qt-project.org>> wrote:
>> It seems that the same happens for qtshadertools:
>> 
>> fatal: Unable to find current revision in submodule path ‘qtshadertools'
>> 
>> > On 6 Feb 2024, at 15:02, Nuno Santos > > <mailto:nuno.san...@imaginando.pt>> wrote:
>> > 
>> > Hi,
>> > 
>> > While trying to build Qt 6 from source I’m having this error while 
>> > initialising the necessary modulates with the following line:
>> > 
>> > ➜  tqtc-qt5 git:(v6.5.4-lts) perl init-repository 
>> > --module-subset=qt5compat,qtbase,qtdeclarative,qtimageformats,qtmultimedia,qtshadertools,qtsvg,qtwebsockets
>> > 
>> > 
>> > fatal: Unable to find current revision in submodule path 'qt5compat'
>> > git submodule update --force --no-fetch exited with status 32768 at 
>> > init-repository line 207.
>> >   Qt::InitRepository::exe(Qt::InitRepository=HASH(0x122808bd8), "git", 
>> > "submodule", "update", "--force", "--no-fetch") called at init-repository 
>> > line 452
>> >   
>> > Qt::InitRepository::git_clone_all_submodules(Qt::InitRepository=HASH(0x122808bd8),
>> >  "tqtc-qt5", 0, "", "qt5compat", "qtbase", "qtdeclarative", 
>> > "qtimageformats", ...) called at init-repository line 674
>> >   Qt::InitRepository::run(Qt::InitRepository=HASH(0x122808bd8)) called 
>> > at init-repository line 685
>> > 
>> > Does anyone know how to overcome this?
>> > 
>> > Thanks!
>> > 
>> > Nuno
>> 
>> ___
>> Interest mailing list
>> Interest@qt-project.org <mailto:Interest@qt-project.org>
>> https://lists.qt-project.org/listinfo/interest
> 
> 
> --
> 
> Rainer Wiesenfarth
> Senior Software Engineer
> Geospatial Division
>  
> 
> 
> Rotebühlstr. 81, 70178 Stuttgart
> Germany
> 
> rainer_wiesenfa...@trimble.com <mailto:rainer_wiesenfa...@trimble.com>
> geospatial.trimble.com/products-and-solutions/trimble-inpho 
> <https://geospatial.trimble.com/products-and-solutions/trimble-inpho>
> 
> Trimble Services GmbH, Am Prime Parc 11, 65479 Raunheim, Eingetragen beim 
> Amtsgericht Darmstadt unter HRB 83893, Geschäftsführer: Rob Reeder, Jürgen 
> Kesper
> ___
> 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.5.4-LTS from source -> fatal: Unable to find current revision in submodule path 'qt5compat'

2024-02-06 Thread Nuno Santos via Interest
It seems that the same happens for qtshadertools:

fatal: Unable to find current revision in submodule path ‘qtshadertools'

> On 6 Feb 2024, at 15:02, Nuno Santos  wrote:
> 
> Hi,
> 
> While trying to build Qt 6 from source I’m having this error while 
> initialising the necessary modulates with the following line:
> 
> ➜  tqtc-qt5 git:(v6.5.4-lts) perl init-repository 
> --module-subset=qt5compat,qtbase,qtdeclarative,qtimageformats,qtmultimedia,qtshadertools,qtsvg,qtwebsockets
> 
> 
> fatal: Unable to find current revision in submodule path 'qt5compat'
> git submodule update --force --no-fetch exited with status 32768 at 
> init-repository line 207.
>   Qt::InitRepository::exe(Qt::InitRepository=HASH(0x122808bd8), "git", 
> "submodule", "update", "--force", "--no-fetch") called at init-repository 
> line 452
>   
> Qt::InitRepository::git_clone_all_submodules(Qt::InitRepository=HASH(0x122808bd8),
>  "tqtc-qt5", 0, "", "qt5compat", "qtbase", "qtdeclarative", "qtimageformats", 
> ...) called at init-repository line 674
>   Qt::InitRepository::run(Qt::InitRepository=HASH(0x122808bd8)) called at 
> init-repository line 685
> 
> Does anyone know how to overcome this?
> 
> Thanks!
> 
> Nuno

___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


[Interest] Qt 6.5.4-LTS from source -> fatal: Unable to find current revision in submodule path 'qt5compat'

2024-02-06 Thread Nuno Santos via Interest
Hi,

While trying to build Qt 6 from source I’m having this error while initialising 
the necessary modulates with the following line:

➜  tqtc-qt5 git:(v6.5.4-lts) perl init-repository 
--module-subset=qt5compat,qtbase,qtdeclarative,qtimageformats,qtmultimedia,qtshadertools,qtsvg,qtwebsockets


fatal: Unable to find current revision in submodule path 'qt5compat'
git submodule update --force --no-fetch exited with status 32768 at 
init-repository line 207.
Qt::InitRepository::exe(Qt::InitRepository=HASH(0x122808bd8), "git", 
"submodule", "update", "--force", "--no-fetch") called at init-repository line 
452

Qt::InitRepository::git_clone_all_submodules(Qt::InitRepository=HASH(0x122808bd8),
 "tqtc-qt5", 0, "", "qt5compat", "qtbase", "qtdeclarative", "qtimageformats", 
...) called at init-repository line 674
Qt::InitRepository::run(Qt::InitRepository=HASH(0x122808bd8)) called at 
init-repository line 685

Does anyone know how to overcome this?

Thanks!

Nuno
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


[Interest] Potential causes and debugging tools or techniques for freezes between main thread and render thread

2024-01-30 Thread Nuno Santos
Hi,

I’m having a very specific and particular problem. I won’t say it is not bad 
programming on my side but this is are very rare and random issues that usually 
manifest in the iOS version of an app.

Sometimes the application freezes, probably a deadlock, when the main thread 
triggers an updated to the window. When I can reproduce this issue, which 
sometimes is only after 10 minutes of stress testing, the main thread and the 
render thread are stalled.

I wonder how do I find the cause for this freezes. I’m using version 6.5.3 of 
Qt for iOS.

Does anyone as any came across similar issues? Any tips?

Thanks in advance!

Best regards,

Nuno
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


[Interest] Is there a way of having a global signal spy?

2023-12-20 Thread Nuno Santos
Hi,

Sometimes I feel myself in the dark regarding signals being emitted.

Sometimes because of refactors and things that change, signals are being 
emitted and we are not aware of.

Is there any way of easily making all the emitted signals being traced on the 
console when a Qt app is running?

Has anyone ever crossed this specific problem/need?

Thanks!

Regards,

Nuno
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


[Interest] As anyone here extended or used MultiPointHandler?

2023-11-24 Thread Nuno Santos
Hi,

I need a MultPointHanlder. It appears as an abstract class on Qt documentation:

https://doc.qt.io/qt-6/qml-qtquick-multipointhandler.html

I cannot find an example on how to extend it or use. Simply exposing it to Qml 
does not even seem to trigger onGrabChanged.

Looking at PinchHandler and DragHandler implementation also didn’t provided me 
any additional insights

As anyone ever had the need to use a MultiPointHandler? What is the trick to 
use it?

Thanks!

Best,

Nuno



___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


[Interest] Preventing MultiPointTouchArea interactions to pass through to Flickable

2023-11-23 Thread Nuno Santos
Hi,

I’m handling touch interaction on some custom knobs with MultiPointTouchArea.

The problem is when I try to interact with this elements when they are 
contained in a Flickable. Depending on the orientation of the flickable and the 
interaction, the flickable moves as well.

Is there anyway to prevent this kind of interaction between both elements? 

Is there any newer and more adequate input handler to prevent this problem?

Thanks!

Nuno
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] Building a Qt app with target SDK 33 on Android with the latest Qt Creator 11.0.3

2023-11-21 Thread Nuno Santos
Ekke,

Thanks for your reply.

I’m still using qmake. I could select the Android Build Platform SDK as 
android-33

But the build would still get targeted to 31

But I have discovered that setting ANDROID_TARGET_SDK_VERSION variable on qmake 
set to 33 does the trick.

Best regards,

Nuno

> On 21 Nov 2023, at 10:07, ekke  wrote:
> 
> In QtCreator, Build Android APK
> can you select Android Build Platform SDK: android-33
> and Android Build-tools version 33.0.2 ?
> 
> are you building with QMake or CMake, for Qt 5.15 or 6.6 ?
> 
> Am 21.11.23 um 10:25 schrieb Nuno Santos:
>> Hi,
>> 
>> I’m having issues in build an app targeting SDK 33 with Qt Creator.
>> 
>> No matter what I do I have always end up with a build targeting SDK 31.
>> 
>> I’m using the latest Qt Creator 11.0.3
>> 
>> Does anyone knows how to work this around?
>> 
>> Thanks!
>> 
>> Regards,
>> 
>> 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] Building a Qt app with target SDK 33 on Android with the latest Qt Creator 11.0.3

2023-11-21 Thread Nuno Santos
Hi,

I’m having issues in build an app targeting SDK 33 with Qt Creator.

No matter what I do I have always end up with a build targeting SDK 31.

I’m using the latest Qt Creator 11.0.3

Does anyone knows how to work this around?

Thanks!

Regards,

Nuno
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] QJsonObject memory leak?

2023-11-02 Thread Nuno Santos
Thiago,

How?

I have sent an example project to this list, you will see it has nothing 
besides that.

Two buttons, two functions.

I would love to understand how to properly deal with this in a simple case so I 
can better handle it on the real use case that triggered this doubt.

Thank you!

Best,

--
Nuno Santos

> No dia 02/11/2023, às 21:52, Thiago Macieira  
> escreveu:
> 
> On Thursday, 2 November 2023 11:54:25 PDT Nuno Santos wrote:
>> Thiago,
>> 
>> So, there is no way of recovering that memory back until the process is
>> closed?
> 
> No, you can free the memory that caused the fragmenting. It's probably
> whatever happened between the two functions that you talked about.
> 
> --
> Thiago Macieira - thiago.macieira (AT) intel.com
>  Cloud Software Architect - Intel DCAI 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] QJsonObject memory leak?

2023-11-02 Thread Nuno Santos
Thiago,

So, there is no way of recovering that memory back until the process is closed?

Thanks!

Nuno

> On 2 Nov 2023, at 18:29, Thiago Macieira  wrote:
> 
> On Thursday, 2 November 2023 08:51:43 PDT Nuno Santos wrote:
>> Any ideas of what is happening here?
> 
> It's probably memory fragmentation. The JSON and CBOR classes store the 
> strings of a container in a large QString, per container level.
> 
> -- 
> Thiago Macieira - thiago.macieira (AT) intel.com
>  Cloud Software Architect - Intel DCAI 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] QJsonObject memory leak?

2023-11-02 Thread Nuno Santos
Elvis,The test follows attached.Best,Nuno<>
On 2 Nov 2023, at 16:28, Elvis Stansvik  wrote:Can you create a standalone example? (I see no calls to your create/uncreate)How are you measuring memory consumption?ElvisDen tors 2 nov. 2023 16:52Nuno Santos  skrev:Hi,I have realised that I cannot release all the memory allocated by a huge QJsonObject when I don’t need it any more. To ensure that nothing else was in between I have created a simple program that does what is below. Conclusion:- Running on a Mac, compiled in release with Qt 6.5.3- Starts with 31.7 MB- Goes up to 412.5 MB- After calling uncreate drops to 42.7If I repeat this procedure, it always increases the process memory size although it is not linear.In iOS the problem is even worse.Any ideas of what is happening here?Thank you!Best regards,NunoQString GetRandomString(){    const QString possibleCharacters("ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789");    const int randomStringLength = 4096; // assuming you want random strings of 12 characters        QString randomString;    for(int i=0; i    {        int index = QRandomGenerator::global()->generate() % possibleCharacters.length();        QChar nextChar = possibleCharacters.at(index);        randomString.append(nextChar);    }        return randomString;}void Controller::create(){    qDebug() << Q_FUNC_INFO;    for (int i=0; i<10; i++)        _data[QString::number(i)] = GetRandomString();}void Controller::uncreate(){    qDebug() << Q_FUNC_INFO;    _data = QJsonObject();}___
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] QJsonObject memory leak?

2023-11-02 Thread Nuno Santos
Hi,

I have realised that I cannot release all the memory allocated by a huge 
QJsonObject when I don’t need it any more. To ensure that nothing else was in 
between I have created a simple program that does what is below. Conclusion:

- Running on a Mac, compiled in release with Qt 6.5.3

- Starts with 31.7 MB



- Goes up to 412.5 MB



- After calling uncreate drops to 42.7




If I repeat this procedure, it always increases the process memory size 
although it is not linear.

In iOS the problem is even worse.

Any ideas of what is happening here?

Thank you!

Best regards,

Nuno


QString GetRandomString()
{
const QString 
possibleCharacters("ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789");
const int randomStringLength = 4096; // assuming you want random strings of 
12 characters

QString randomString;
for(int i=0; igenerate() % 
possibleCharacters.length();
QChar nextChar = possibleCharacters.at(index);
randomString.append(nextChar);
}

return randomString;
}

void Controller::create()
{
qDebug() << Q_FUNC_INFO;

for (int i=0; i<10; i++)
_data[QString::number(i)] = GetRandomString();
}

void Controller::uncreate()
{
qDebug() << Q_FUNC_INFO;

_data = QJsonObject();
}


___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


[Interest] Strategies to debug and improve UI performance (QML)

2023-10-23 Thread Nuno Santos
Hi,

I want to perform a UI optimisation. I would like to know how many items are 
being instantiated, and who is taking more time to load, etc

Are there ENV variables and tools that could help in this task?

I would love to hear your thoughts.

Best regards,

Nuno
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


[Interest] How to draw lines with glow with Qt Quick Scene Graph (custom vertex and material)

2023-06-13 Thread Nuno Santos
Hi,

Can anyone point me to some example or tutorial on how to make a custom 
material to draw a lines with scene graph using a custom vertex shader in order 
to achieve the glow effect?

I’ve been drawing graphics with Scene Graph but they always look very anti 
aliased and have that raw and pixelated appearance.

I’ve been trying to googling around for such resource without success.

Maybe someone here can help.

Thank you in advance.

Best regards,

Nuno


___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


[Interest] Hard time with random qml crash on Mac OS

2023-05-05 Thread Nuno Santos
Hi,

I’m having an hard time figuring out what is causing a random crash on Qml.

Is this stack trace familiar to anyone? 

Thanks!

Best regards,

Nuno

Thread 0 Crashed::  Dispatch queue: com.apple.main-thread
0   QtCore 0x10b9d6d58 
QObjectPrivate::flagsForDumping() const + 0
1   QtQuick0x10b4f733c 
QAccessibleQuickItem::role() const + 64
2   QtQuick0x10b4f80cc 
QAccessibleQuickItem::interface_cast(QAccessible::InterfaceType) + 32
3   libqcocoa.dylib0x10c5a84f0 0x10c538000 + 460016
4   libqcocoa.dylib0x10c5a857c 0x10c538000 + 460156
5   libqcocoa.dylib0x10c5a6bf8 0x10c538000 + 453624
6   QtQuick0x10b2eb830 
QQuickItemPrivate::setEffectiveVisibleRecur(bool) + 720
7   QtQuick0x10b2e9494 
QQuickItem::setParentItem(QQuickItem*) + 908
8   QtQuick0x10b2e8d2c 
QQuickItem::~QQuickItem() + 108
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] Qt 6.5 - The current style does not support customization of this control

2023-04-20 Thread Nuno Santos
Hi Mitch,

Thanks for your reply and for the useful insight. I will give it a shot.

Best regards,

Nuno

> On 20 Apr 2023, at 02:30, EXT Mitch Curtis  wrote:
> 
> Hi,
> 
>> -Original Message-
>> From: Interest > <mailto:interest-boun...@qt-project.org>> On Behalf Of Nuno Santos
>> Sent: Wednesday, April 19, 2023 5:25 PM
>> To: Qt Interest mailto:interest@qt-project.org>>
>> Subject: [Interest] Qt 6.5 - The current style does not support customization
>> of this control
>> 
>> Hi,
>> 
>> Yesterday I have installed Qt 6.5 to give it a try.
>> 
>> I’m having a lot of this warnings on my customised version of ComboBox. I
>> have already checked the documentation and I still don’t understand what are
>> causing them
> 
> The documentations says that the Windows and macOS styles don't support 
> customisation. Which style are you using? If you're not sure, you can check 
> by setting the QT_LOGGING_RULES environment variable to 
> qt.quick.controls.style=true.
> 
> https://bugreports.qt.io/browse/QTBUG-96733 has more background information 
> on the issue if you're interested.
> 
> It would be useful if we could print the current style in the warning, but we 
> can't because QQuickStyle::name() is in Qt Quick Controls, which Qt Quick 
> Templates (where the warning is printed) can't use.
> 
>> qrc:/qml/UIComboBox.qml:50:17: QML Rectangle: The current style does not
>> support customization of this control (property: "background" item:
>> QQuickRectangle(0x6383f3a0, parent=0x0, geometry=0,0 0x0)). Please
>> customize a non-native style (such as Basic, Fusion, Material, etc). For more
>> information, see: https://doc.qt.io/qt-6/qtquickcontrols2-
>> customize.html#customization-reference
>> 
>> What am I missing?
>> 
>> Thanks!
>> 
>> Regards,
>> 
>> Nuno
>> 
>> 
>> ___
>> Interest mailing list
>> Interest@qt-project.org <mailto: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] Qt 6.5 - The current style does not support customization of this control

2023-04-19 Thread Nuno Santos
Hi,

Yesterday I have installed Qt 6.5 to give it a try.

I’m having a lot of this warnings on my customised version of ComboBox. I have 
already checked the documentation and I still don’t understand what are causing 
them

qrc:/qml/UIComboBox.qml:50:17: QML Rectangle: The current style does not 
support customization of this control (property: "background" item: 
QQuickRectangle(0x6383f3a0, parent=0x0, geometry=0,0 0x0)). Please 
customize a non-native style (such as Basic, Fusion, Material, etc). For more 
information, see: 
https://doc.qt.io/qt-6/qtquickcontrols2-customize.html#customization-reference

What am I missing?

Thanks!

Regards,

Nuno


___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] Cannot drag a Pane in Qml even on Qt 6.X

2023-03-06 Thread Nuno Santos
Mitch,

Thank you very much for the clarification.

Best regards,

Nuno

> On 7 Mar 2023, at 00:28, EXT Mitch Curtis  wrote:
> 
>> -Original Message-
>> From: Interest > <mailto:interest-boun...@qt-project.org>> On Behalf Of Nuno
>> Santos
>> Sent: Monday, 6 March 2023 4:55 PM
>> To: Qt Interest mailto:interest@qt-project.org>>
>> Subject: [Interest] Cannot drag a Pane in Qml even on Qt 6.X
>> 
>> Hi,
>> 
>> It was not possible to drag a Pane on Qt 5.X
>> 
>> But I was almost convinced it was possible to do it on Qt 6.X
>> 
>> But now I have tried again and it seems it is not possible. Or maybe I’m 
>> doing
>> something wrong.
>> 
>> Is there any strong reason a Pane cannot be draggable?
> 
> The parent of the MouseArea is the contentItem, thanks to contentData being 
> the default property. That's explained here:
> 
> https://doc.qt.io/qt-6/qml-qtquick-controls2-pane.html#details 
> <https://doc.qt.io/qt-6/qml-qtquick-controls2-pane.html#details>
> 
> You can see what really happens by modifying the code below to set the drag 
> target to parent again and uncomment the title binding - the contentItem (and 
> black-bordered rectangle) will move but the Pane itself won't.
> 
> Set the drag target to the pane and it will work:
> 
>import QtQuick
>import QtQuick.Controls
> 
>Window {
>width: 640
>height: 480
>visible: true
>title: "pane.x: " + pane.x + " pane.y: " + pane.y
>//title: "pane.contentItem.x: " + pane.contentItem.x + 
> "pane.contentItem.y: " + pane.contentItem.y
> 
>Item {
>width: 200
>height: 200
> 
>DropArea {
>x: 75
>y: 75
>width: 50
>height: 50
> 
>Rectangle {
>anchors.fill: parent
>color: parent.containsDrag ? "green" : "gray"
>}
>}
> 
>Pane {
>id: pane
>x: 10
>y: 10
>width: 20
>height: 20
>leftPadding: 0
>rightPadding: 0
>topPadding: 0
>bottomPadding: 0
>background: Rectangle {
>color: "tomato"
>}
> 
>Rectangle {
>anchors.fill: parent
>color: "transparent"
>border.color: "black"
>}
> 
>Drag.active: dragArea.drag.active
>Drag.hotSpot.x: 10
>Drag.hotSpot.y: 10
> 
>MouseArea {
>id: dragArea
>anchors.fill: parent
> 
>drag.target: pane
>}
>}
>}
>}
> 
>> Thanks!
>> 
>> Nuno
>> 
>> 
>> import QtQuick
>> import QtQuick.Layouts
>> import QtQuick.Controls
>> 
>> Window {
>>width: 640
>>height: 480
>>visible: true
>>title: qsTr("Hello World")
>> 
>>Item {
>>width: 200; height: 200
>> 
>>DropArea {
>>x: 75; y: 75
>>width: 50; height: 50
>> 
>>Rectangle {
>>anchors.fill: parent
>>color: parent.containsDrag ? "green" : "gray"
>>}
>>}
>> 
>>//Rectangle {
>>Pane {
>>x: 10; y: 10
>>width: 20; height: 20
>>//color: "red"
>> 
>>Drag.active: dragArea.drag.active
>>Drag.hotSpot.x: 10
>>Drag.hotSpot.y: 10
>> 
>>MouseArea {
>>id: dragArea
>>anchors.fill: parent
>> 
>>drag.target: parent
>>}
>>}
>>}
>> }
>> ___
>> Interest mailing list
>> Interest@qt-project.org <mailto:Interest@qt-project.org>
>> https://lists.qt-project.org/listinfo/interest 
>> <https://lists.qt-project.org/listinfo/interest>
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


[Interest] Cannot drag a Pane in Qml even on Qt 6.X

2023-03-06 Thread Nuno Santos
Hi,

It was not possible to drag a Pane on Qt 5.X

But I was almost convinced it was possible to do it on Qt 6.X

But now I have tried again and it seems it is not possible. Or maybe I’m doing 
something wrong.

Is there any strong reason a Pane cannot be draggable?

Thanks!

Nuno


import QtQuick
import QtQuick.Layouts
import QtQuick.Controls

Window {
width: 640
height: 480
visible: true
title: qsTr("Hello World")

Item {
width: 200; height: 200

DropArea {
x: 75; y: 75
width: 50; height: 50

Rectangle {
anchors.fill: parent
color: parent.containsDrag ? "green" : "gray"
}
}

//Rectangle {
Pane {
x: 10; y: 10
width: 20; height: 20
//color: "red"

Drag.active: dragArea.drag.active
Drag.hotSpot.x: 10
Drag.hotSpot.y: 10

MouseArea {
id: dragArea
anchors.fill: parent

drag.target: parent
}
}
}
}
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] QtCreator - CMAKE_PREFIX_PATH with multiple paths

2023-02-09 Thread Nuno Santos
Cristian,

Are you able to do this in the QtCreator build settings?

Because for me it gets red and it 



And then it does not work at all:

CMake Error at CMakeLists.txt:16 (find_package):
  By not providing "FindQt6.cmake" in CMAKE_MODULE_PATH this project has
  asked CMake to find a package configuration file provided by "Qt6", but
  CMake did not find one.

Thank you!

Nuno

> On 9 Feb 2023, at 15:35, Cristian Adam  wrote:
> 
> 
> 
> On 02/09/2023 16:29, Nuno Santos wrote:
>> Hi,
>> 
>> Is anyone able to tell me if QtCreator is able to have a CMAKE var defined 
>> with multiple values?
>> 
>> The default value for a project is %{Qt:QT_INSTALL_PREFIX}, is it possible 
>> to append more paths?
>> 
>> How?
>> 
>> Thanks!
>> 
>> Nuno
> I have for Qt Creator itself the following:
> 
> -DCMAKE_PREFIX_PATH:PATH=%{Qt:QT_INSTALL_PREFIX};c:/llvm/msvc
> 
> The CMake documentation 
> <https://cmake.org/cmake/help/latest/variable/CMAKE_PREFIX_PATH.html> states:
> 
> Semicolon-separated list 
> <https://cmake.org/cmake/help/latest/manual/cmake-language.7.html#cmake-language-lists>
>  of directories specifying installation prefixes to be searched by the 
> find_package() 
> <https://cmake.org/cmake/help/latest/command/find_package.html#command:find_package>,find_program()
>  
> <https://cmake.org/cmake/help/latest/command/find_program.html#command:find_program>,
>  find_library() 
> <https://cmake.org/cmake/help/latest/command/find_library.html#command:find_library>,
>  find_file() 
> <https://cmake.org/cmake/help/latest/command/find_file.html#command:find_file>,
>  and find_path() 
> <https://cmake.org/cmake/help/latest/command/find_path.html#command:find_path>
>  commands. Each command will add appropriate subdirectories (like bin, lib, 
> or include) as specified in its own documentation.
> 
> By default this is empty. It is intended to be set by the project.
> 
> 
> Cheers,
> Cristian.
> 

___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


[Interest] QtCreator - CMAKE_PREFIX_PATH with multiple paths

2023-02-09 Thread Nuno Santos
Hi,

Is anyone able to tell me if QtCreator is able to have a CMAKE var defined with 
multiple values?

The default value for a project is %{Qt:QT_INSTALL_PREFIX}, is it possible to 
append more paths?

How?

Thanks!

Nuno
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] Tweaking a static build of Qt 6 for Windows

2023-02-01 Thread Nuno Santos
Cristian,

Thank you very much for your feedback. It worked like charm. Standalone 
application is now building and running.

I’m just having a new problem with the plugin version of the application that 
did not used to happen in Qt 5:

C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winnt.h:173: 
error: C1189: #error:  "No Target Architecture"

//
// Note: RC_INVOKED is checked in PROBE_ALIGNMENT to maintain compatibility 
with previous
//   versions of the SDK which did not block inclusion in an .RC file.
//

#if defined(_AMD64_) || defined(_X86_)
#define PROBE_ALIGNMENT( _s ) TYPE_ALIGNMENT( DWORD )
#elif defined(_IA64_) || defined(_ARM_) || defined(_ARM64_)

//
// TODO: WOWXX - Unblock ARM. Make all alignment checks DWORD for now.
//

#define PROBE_ALIGNMENT( _s ) TYPE_ALIGNMENT( DWORD )
#elif !defined(RC_INVOKED)
#error "No Target Architecture"
#endif

I’m not including winnt.h anywhere in my code.

Do you have any idea of what might be going on?

Thanks!

Regards,

Nuno


> On 1 Feb 2023, at 11:10, Cristian Adam  wrote:
> 
> Hi,
> 
> All the missing __imp symbols mean that you are trying to link to a shared 
> library.
> 
> C:\Projects\Qt\repo\qtbase
> $ configure --help | findstr static
>  sections. [auto for static builds, otherwise no]
>   -static .. Build static Qt libraries [no] (yes for UIKit)
>   -static-runtime .. With -static, use static runtime [no] (Windows only)
>  benchmarks, manual-tests, minimal-static-tests)
> 
> Make sure you pass both -static and -static-runtime to your Qt configuration. 
> -static-runtime will get you /MT for cl.exe
> 
> Cheers,
> Cristian.
> 
> From: Interest  on behalf of Nuno Santos 
> 
> Sent: Wednesday, February 1, 2023 11:07
> To: Macieira, Thiago 
> Cc: Qt Interest 
> Subject: Re: [Interest] Tweaking a static build of Qt 6 for Windows
>  
> Thiago,
> 
> Right now my problem is that the static build of Qt is unable to compile 
> successfully my project and I don’t understand why.
> 
> The static build of Qt does not have this problem on Mac.
> 
> Any ideas?
> 
> Thanks!
> 
> Best,
> 
> Nuno
> 
> 
> 
> 
> > On 30 Jan 2023, at 18:34, Thiago Macieira  wrote:
> > 
> > On Monday, 30 January 2023 10:13:49 PST Nuno Santos wrote:
> >> Thiago,
> >> 
> >> Thanks for your reply.
> >> 
> >> I’m not very technical about this details like yourself. I’ve been doing
> >> this since ever. To reconsider I need to better understand the reasons.
> > 
> > Sure.
> > 
> >> The thing is. I need to have Qt compiled with MT instead of MD other wise I
> >> can’t open two instances of my plugins on the same host. Also, I don’t want
> >> to bundle MSVC runtimes. That sucks.
> > 
> > You can open multiple plugins in the same process just fine and you don't 
> > have 
> > to ship the runtime if it's already installed. It's already installed on 
> > Windows 10.
> > 
> >> So… are those files still being taking into account when building Qt, even
> >> that Qt is now built by cmake?
> > 
> > Static runtime builds still exist, but I have no idea if they are tested or 
> > work. I recommend you reconsider your needs.
> > 
> > -- 
> > Thiago Macieira - thiago.macieira (AT) intel.com
> >  Cloud Software Architect - Intel DCAI Cloud Engineering
> > ___
> > Interest mailing list
> > Interest@qt-project.org
> > https://lists.qt-project.org/listinfo/interest
> 
> ___
> Interest mailing list
> Interest@qt-project.org <mailto: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] Tweaking a static build of Qt 6 for Windows

2023-01-30 Thread Nuno Santos
Thiago,

Thanks for your reply.

I’m not very technical about this details like yourself. I’ve been doing this 
since ever. To reconsider I need to better understand the reasons.

The thing is. I need to have Qt compiled with MT instead of MD other wise I 
can’t open two instances of my plugins on the same host. Also, I don’t want to 
bundle MSVC runtimes. That sucks.


So… are those files still being taking into account when building Qt, even that 
Qt is now built by cmake?

qtbase/mkspecs/common/msvc_desktop.conf

Or is there other place for the cmake build?

Thanks!

Regards,

Nuno


> On 26 Jan 2023, at 23:52, Thiago Macieira  wrote:
> 
> On Thursday, 26 January 2023 07:52:38 PST Nuno Santos wrote:
>> When building Qt 6, is this the same place for this type of settings or the
>> fact that the build is managed by cmake this files are ignored and others
>> are used. If so, which ones?
> 
> I suggest you reconsider. The runtime that MSVC 2015+ uses on Windows 
> (Universal CRT) has been shipped with Windows 10, so there's no reason to 
> statically link to it.
> 
> -- 
> Thiago Macieira - thiago.macieira (AT) intel.com
>  Cloud Software Architect - Intel DCAI 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


[Interest] Tweaking a static build of Qt 6 for Windows

2023-01-26 Thread Nuno Santos
Hi,

When I used to compile Qt 5 statically for Windows I would usually need to 
tweak a couple of settings under:

qtbase/mkspecs/common/msvc_desktop.conf

QMAKE_CFLAGS_RELEASE = -O2 -MT -Zc:strictStrings
QMAKE_CFLAGS_RELEASE_WITH_DEBUGINFO += -O2 -MT -Zi -Zc:strictStrings
QMAKE_CFLAGS_DEBUG = -Zi -MTd

QMAKE_LIBS_CORE = kernel32.lib user32.lib shell32.lib uuid.lib ole32.lib 
advapi32.lib ws2_32.lib gdi32.lib

Since I build plugins that can be opened multiple times, we need to change -MD 
to -MT. I would also need to link a couple extra libs. Don’t know why.

When building Qt 6, is this the same place for this type of settings or the 
fact that the build is managed by cmake this files are ignored and others are 
used. If so, which ones?

Thanks!

Regards,

Nuno

___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] What is the right way of creating a static lib that has qml resources with cmake?

2023-01-20 Thread Nuno Santos
Hi Robert,

I’m not talking about shared libraries. I’m talking about static libraries. 
While they are shared between several applications I link them statically with 
the final application. This is a requirement for me. This was possible to do 
with Qt 5 and qmake. As simple as that:

TEMPLATE = lib
CONFIG += staticlib
RESOURCES += resources.qrc

A couple of bug reports have been opened regarding this topics:

https://bugreports.qt.io/browse/QTBUG-110110

https://bugreports.qt.io/browse/QTBUG-110243

And if Qt is switching to a more evolved build system that will replace qmake, 
it does not make sense that this is not supported. 

Thank you!

Best regards,

Nuno

> On 20 Jan 2023, at 10:00, coroberti  wrote:
> 
> On Mon, Jan 16, 2023 at 10:07 AM Nuno Santos  <mailto:nuno.san...@imaginando.pt>> wrote:
>> 
>> Good morning Ulf,
>> 
>> Ok, so this this the news Qt 6 / CMake approach to things and we can’t avoid 
>> it right?
>> 
>> However, as it is, its buggy. I will upload my last week example to 
>> https://bugreports.qt.io/browse/QTBUG-110110
>> 
>> Because I’ve been struggling with this for days without having success. I’ve 
>> also shared this example with another top level Qt developer who couldn’t 
>> figure it out as well. I’ve only tested on Mac so far. At the time being 
>> this is a full blocker.
>> 
>> Thanks for your help and insights.
>> 
>> Have an excellent week!
>> 
>> Best regards,
>> 
>> Nuno
> 
> Dear Nuno,
> On Mac, unlike on Windows, there's a concept of an app bundle.
> The Qt shared libraries are copied by macdeployqt to the app bundle as
> shared libraries called frameworks.
> 
> Thus, shared libraries are coming together with the exe and are easily
> accessible.
> 
> Perhaps, at least on Mac you do not need static linking and can rather
> safely use the dynamic linking
> to the libs within the bundle?
> 
> Thanks.
> 
> Kind regards,
> Robert Iakobashvili
> 

___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] What is the right way of creating a static lib that has qml resources with cmake?

2023-01-16 Thread Nuno Santos
Good morning Ulf,

Ok, so this this the news Qt 6 / CMake approach to things and we can’t avoid it 
right?

However, as it is, its buggy. I will upload my last week example to 
https://bugreports.qt.io/browse/QTBUG-110110 


Because I’ve been struggling with this for days without having success. I’ve 
also shared this example with another top level Qt developer who couldn’t 
figure it out as well. I’ve only tested on Mac so far. At the time being this 
is a full blocker.

Thanks for your help and insights.

Have an excellent week!

Best regards,

Nuno

> On 12 Jan 2023, at 19:39, Ulf Hermann via Interest  
> wrote:
> 
> I haven't actually invented the plugin import mechanism, but AFAIU, it allows 
> us to specify plugins, and nothing else, as the stuff to be kept around even 
> if it's not referenced. QML modules piggy-back on that by creating small 
> plugins that do nothing but hold a reference to the type registration 
> function.

___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


[Interest] Porting a previous qmake approach to cmake

2023-01-13 Thread Nuno Santos
Ulf,Still related with the issue https://bugreports.qt.io/browse/QTBUG-110110What I’m really trying to achieve here follows attached in a very minimal example.For our applications we have a shared ground which would compile as a static lib without any requirement of a plugin. This lib is full of shared resources such as icons, images, qml, etc.Then, each application has also a static lib called common, which also has icons, images, qml, etc.Then each application which can have have up to 4 different targets will link static with this lib. We are doing audio plugins in most cases, which mean they are bundled as a single library (eg:  a single dll on Windows).While developing an app I want to be able to run in debug and compile all the sources at once with the hassle of building each lib. When doing a release build I usually want to build the shared and common libs first and then build the targets, linking with those libs.This is what I’m trying to achieve in the structure of the project below. It seems that to take full advantage of the qml compiling with cmake we can run to qt_add_qml_module. My biggest deal right now is how to glue things together. In this example if I compile in debug the application fails to launch because it says:qrc:/Common/qml/main.qml:3:1: module "CommonModule" is not installedqrc:/Common/qml/main.qml:2:1: module "SharedModule" is not installedIf I switch to release I need to have common compiled and installed, which will also compile and install shared. So what I’m doing is going to the build directory of common and call cmake —install .When I do that, I realise that libcommonplugin.a and libsharedplugin.a are not installed and I don’t understand why. So I need to manually copy this two items to the install folder in order to be able to install the application.➜  build-common-Qt_6_4_2_for_macOS-Debug cp libcommonplugin.a ../common/build/lib➜  build-common-Qt_6_4_2_for_macOS-Debug cp shared/libsharedplugin.a ../common/build/libWhen running the app in release the qml resources that are in shared and common static libs are not registered and therefore not available.I’ve been here all week trying to figure out the solution for this problem and any help would be amazing.Thank you very much!Best regards,Nuno<>
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] What is the right way of creating a static lib that has qml resources with cmake?

2023-01-12 Thread Nuno Santos
Thiago,
Ulf,

I focus on the practical side of things because I can’t simply know everything.

With qmake I only had to do this:

TEMPLATE = lib
CONFIG += staticlib
RESOURCES += $$PWD/resources/resources.qrc

And all the resources listed in the .qrc file would be available in the final 
lib.

This is what I’m trying to achieve with cmake.

Best,

Nuno

> On 12 Jan 2023, at 14:18, Thiago Macieira  wrote:
> 
> On Thursday, 12 January 2023 00:36:01 PST Ulf Hermann via Interest wrote:
>> That's because linkers "optimize" the resources out if you don't.
> 
> Strictly speaking, this should read "linkers don't include stuff you don't 
> need". If you don't need a particular .o from the static library, it won't be 
> included in the output.
> 
> "Need" is defined as "provides a symbol that is undefined in the linker at 
> this 
> point".
> 
>> We can't do much about this.
> 
> Yes, there is. There's -Wl,--whole-archive for the Unix linkers. This should 
> solve the problem for everyone except MSVC users.
> 
> -- 
> Thiago Macieira - thiago.macieira (AT) intel.com
>  Cloud Software Architect - Intel DCAI 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] What is the right way of creating a static lib that has qml resources with cmake?

2023-01-12 Thread Nuno Santos
Ulf,

What version of Qt are you using?

I’ve also tried with 6.4.2 before creating the bug report. Same problem!

Here is the link -> https://bugreports.qt.io/browse/QTBUG-110110

Thank you!

Regards,

Nuno

> On 12 Jan 2023, at 09:30, Ulf Hermann  wrote:
> 
> It works fine here. Please file a bug report with all the details (platform, 
> Qt version etc). Also please state whether you are trying to run the example 
> from the build directory or from some deployment.
> 
> best regards,
> Ulf

___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] What is the right way of creating a static lib that has qml resources with cmake?

2023-01-12 Thread Nuno Santos
Ulf,I based myself on the example provided in the documention -> https://doc.qt.io/qt-6/qtqml-writing-a-module.htmlIn the cmake build directory there was no dylib present, only static libs, so the same issue is not happening in this smaller case. However, when declaring import ExtraModule on main.qml, it's not found and the plugin is being registered on main.cpp via #include Q_IMPORT_QML_PLUGIN(ExtraModulePlugin)What am I missing here? Project attached.Regards,Nuno<>
On 12 Jan 2023, at 08:45, Nuno Santos  wrote:Ulf,On 12 Jan 2023, at 08:36, Ulf Hermann  wrote:If you state STATIC in qt_add_qml_module (without a qt_add_library or similar that makes it dynamic) and then it builds a dynamic library, that's a bug. Please file a report at https://bugreports.qt-project.org with a minimal reproducer and state the version of Qt you are using.I have been using the following documentation as a guide:https://doc.qt.io/qt-6/qtqml-writing-a-module.htmlI will try to reproduce the problem basing myself on this. In case I need to submit a bug report what is the category?If it does build a static library but the library doesn't contain qInitResources, that's on purpose. You need to do the plugin linking dance which uses additional .o files ("object library" in CMake lingo) to pull in the resource initialization. That's because linkers "optimize" the resources out if you don't. We can't do much about this.See also https://doc.qt.io/qt-6/qt-import-qml-plugins.html and https://doc.qt.io/qt-6/qqmlengineextensionplugin.html#Q_IMPORT_QML_PLUGINI have also seen this in the previous link and even that I have successfully made it link with the Q_IMPORT_QML_PLUGIN declaration, no resources were available. More on this later. I will start from the scratch with an example.Thank you!Best,Nunobest regards,Ulf___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] What is the right way of creating a static lib that has qml resources with cmake?

2023-01-12 Thread Nuno Santos
Ulf,

> On 12 Jan 2023, at 08:36, Ulf Hermann  wrote:
> 
> If you state STATIC in qt_add_qml_module (without a qt_add_library or similar 
> that makes it dynamic) and then it builds a dynamic library, that's a bug. 
> Please file a report at https://bugreports.qt-project.org with a minimal 
> reproducer and state the version of Qt you are using.

I have been using the following documentation as a guide:

https://doc.qt.io/qt-6/qtqml-writing-a-module.html

I will try to reproduce the problem basing myself on this. In case I need to 
submit a bug report what is the category?

> 
> If it does build a static library but the library doesn't contain 
> qInitResources, that's on purpose. You need to do the plugin linking dance 
> which uses additional .o files ("object library" in CMake lingo) to pull in 
> the resource initialization. That's because linkers "optimize" the resources 
> out if you don't. We can't do much about this.
> 
> See also https://doc.qt.io/qt-6/qt-import-qml-plugins.html and 
> https://doc.qt.io/qt-6/qqmlengineextensionplugin.html#Q_IMPORT_QML_PLUGIN

I have also seen this in the previous link and even that I have successfully 
made it link with the Q_IMPORT_QML_PLUGIN declaration, no resources were 
available. 

More on this later. I will start from the scratch with an example.

Thank you!

Best,

Nuno

> 
> best regards,
> Ulf

___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] What is the right way of creating a static lib that has qml resources with cmake?

2023-01-11 Thread Nuno Santos
Ulf,

In my latest try I give it a shot to the NO_PLUGIN approach and removed the 
qt_add_library line. I have also not set qml files with qt_add_resources

qt_add_qml_module(shared STATIC
URI shared
VERSION 1.0
QML_FILES ${SHARED_QML_FILES}
SOURCES ${SHARED_SOURCE_FILES}
NO_PLUGIN
#NO_LINT
#NO_CACHEGEN
)
#set_source_files_properties( PROPERTIES BASE )
qt_add_resources(shared "shared_fonts" PREFIX "/" BASE resources FILES 
${FONT_FILES})
qt_add_resources(shared "shared_icons" PREFIX "/" BASE resources FILES 
${ICON_FILES})
qt_add_resources(shared "shared_js" PREFIX "/" BASE resources FILES ${JS_FILES})
qt_add_resources(shared "shared_json" PREFIX "/" BASE resources FILES 
${JSON_FILES})
qt_add_resources(shared "shared_svg" PREFIX "/" BASE resources FILES 
${SVG_FILES})


But in the end, the only file that contains qInitResources is: libshared.dylib

But I want it to be libshared.a

What am I missing?

Thanks!

Best,

Nuno

> On 11 Jan 2023, at 16:19, Nuno Santos  wrote:
> 
> Ulf,
> 
> Thanks for your reply. So that you better understand my problem this is what 
> I have
> 
> shared
>   CMakeList.txt
> 
> project
>   CMakeList.txt
>   common
>   CMakeList.txt
> 
> 
> In order to build project I need shared and common. When in debug I don’t 
> want to build shared and common individually for each change so in project 
> CMakeList.txt I do this:
> 
> if(${CMAKE_BUILD_TYPE} STREQUAL "Debug")
>   add_subdirectory(common)
>   target_link_libraries(bam PRIVATE shared)
>   target_link_libraries(bam PRIVATE common)
> endif()
> 
> When doing this, all the qml resources are found and the application works as 
> expected
> 
> In release I just want to link with shared and common so I have something 
> like this:
> 
> if(${CMAKE_BUILD_TYPE} STREQUAL “Release")
>   target_link_libraries(bam PRIVATE libshared.a)
>   target_link_libraries(bam PRIVATE libcommon.a)
>   target_link_libraries(bam PRIVATE 
> -L${CMAKE_CURRENT_SOURCE_DIR}/common/build/lib)
>   target_include_directories(bam PRIVATE 
> ${CMAKE_CURRENT_SOURCE_DIR}/common/build/include)
> endif()
> 
> The problem is that when linking with libshared.a and libcommon.a the 
> resources are not available and when I try to call the function:
> 
> Q_INIT_RESOURCE(shared_qml);
> 
> It says:
> 
> Undefined symbols for architecture arm64:
>   "qInitResources_shared_qml()", referenced from:
> 
> The function is not available but searching for that function in binaries 
> says:
> 
> Binary file shared/libshared.dylib matches
> 
> I’m linking (and I want to link) with the static version of this lib and not 
> the dynamic one.
> 
> I think don’t totally understand your suggestion. My goal is to have a single 
> libshared.a that I can link with my project and call the necessary functions 
> to register the resources. 
> 
> What would be the right solution for this case?
> 
> Thanks in advance!
> 
> Regards,
> 
> Nuno
> 
> 
>> On 11 Jan 2023, at 15:43, Ulf Hermann via Interest  
>> wrote:
>> 
>> 
>>> With the following approach two libs are created:
>>> 
>>> libshared.a and libsharedplugin.a
>>> 
>>> I just want to have a single target called libshared.a with all the qml 
>>> resources embedded.
>> 
>> You can add NO_PLUGIN to your qt_add_qml_module, but be warned: The linker 
>> will be clever and omit your type registrations. You have to prevent that in 
>> some other way then. The usual way to prevent it is Q_IMPORT_PLUGIN on the 
>> generated plugin.
>> 
>> And you should not add your QML files with qt_add_resources. The most 
>> important thing qt_add_qml_module does is adding your QML files.
>> 
>> best regards,
>> 
>> Ulf
>> 
>> ___
>> 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 is the right way of creating a static lib that has qml resources with cmake?

2023-01-11 Thread Nuno Santos
Ulf,

Thanks for your reply. So that you better understand my problem this is what I 
have

shared
CMakeList.txt

project
CMakeList.txt
common
CMakeList.txt


In order to build project I need shared and common. When in debug I don’t want 
to build shared and common individually for each change so in project 
CMakeList.txt I do this:

if(${CMAKE_BUILD_TYPE} STREQUAL "Debug")
add_subdirectory(common)
target_link_libraries(bam PRIVATE shared)
target_link_libraries(bam PRIVATE common)
endif()

When doing this, all the qml resources are found and the application works as 
expected

In release I just want to link with shared and common so I have something like 
this:

if(${CMAKE_BUILD_TYPE} STREQUAL “Release")
target_link_libraries(bam PRIVATE libshared.a)
target_link_libraries(bam PRIVATE libcommon.a)
target_link_libraries(bam PRIVATE 
-L${CMAKE_CURRENT_SOURCE_DIR}/common/build/lib)
target_include_directories(bam PRIVATE 
${CMAKE_CURRENT_SOURCE_DIR}/common/build/include)
endif()

The problem is that when linking with libshared.a and libcommon.a the resources 
are not available and when I try to call the function:

Q_INIT_RESOURCE(shared_qml);

It says:

Undefined symbols for architecture arm64:
  "qInitResources_shared_qml()", referenced from:

The function is not available but searching for that function in binaries says:

Binary file shared/libshared.dylib matches

I’m linking (and I want to link) with the static version of this lib and not 
the dynamic one.

I think don’t totally understand your suggestion. My goal is to have a single 
libshared.a that I can link with my project and call the necessary functions to 
register the resources. 

What would be the right solution for this case?

Thanks in advance!

Regards,

Nuno


> On 11 Jan 2023, at 15:43, Ulf Hermann via Interest  
> wrote:
> 
> 
>> With the following approach two libs are created:
>> 
>> libshared.a and libsharedplugin.a
>> 
>> I just want to have a single target called libshared.a with all the qml 
>> resources embedded.
> 
> You can add NO_PLUGIN to your qt_add_qml_module, but be warned: The linker 
> will be clever and omit your type registrations. You have to prevent that in 
> some other way then. The usual way to prevent it is Q_IMPORT_PLUGIN on the 
> generated plugin.
> 
> And you should not add your QML files with qt_add_resources. The most 
> important thing qt_add_qml_module does is adding your QML files.
> 
> best regards,
> 
> Ulf
> 
> ___
> 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] What is the right way of creating a static lib that has qml resources with cmake?

2023-01-11 Thread Nuno Santos
Hi,

I’m trying to port a project from qmake to cmake.

The project typically consists in a shared library, common to all apps, a 
common library, common to a specific and its variants.

I still have doubts on how to create this shared static library with the qml 
resources built in.

qt_add_qml_module(shared STATIC
URI shared
VERSION 1.0
QML_FILES ${SHARED_QML_FILES}
SOURCES ${SHARED_SOURCE_FILES}
#NO_LINT
#NO_CACHEGEN
)
qt_add_resources(shared "shared_qml" PREFIX "/" BASE resources FILES 
${SHARED_QML_FILES})

With the following approach two libs are created:

libshared.a and libsharedplugin.a

I just want to have a single target called libshared.a with all the qml 
resources embedded.

What am I missing?

Thanks!

Best,

Nuno
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] Qt6 - Fails to compile when openssl-linked enabled

2023-01-09 Thread Nuno Santos
Marten,
Thiago,

I was able to successfully configure for openssl-linked. Below is the configure 
line:

C:\Qt\6.4.1\src\build>..\configure.bat -prefix C:\Qt\6.4.1\msvc2019_static 
-static -debug-and-release -nomake examples -nomake tests -nomake benchmarks 
-nomake manual-tests -nomake minimal-static-tests -openssl-linked -- 
-DOPENSSL_ROOT_DIR="C:\Qt-Utils\openssl" -DOPENSSL_USE_STATIC_LIBS=TRUE

The trick was to create a separeted dir called openssl with the folders include 
and lib inside. Before I was just pointing to a folder that had all the vcpkg 
libs compiled.

Thanks for your help.

Regards,

Nuno

> On 9 Jan 2023, at 11:25, Mårten Nordheim  wrote:
> 
> As Thiago mentioned, dynamically linking OpenSSL tends to be easier.
> From what I can tell, the vcpkg directory should work with the 
> FindOpenssl.cmake module.
>  You also may have trouble if you are mixing dynamically- and statically 
> linked libraries!
> Since they are likely linking the VC runtime in the same manner, they 
> _cannot_ be mixed.
> And, if I remember correctly, the default ‘static’ triplets in vcpkg all link 
> the runtime statically.
> Which means Qt and all other dependencies must also be built this way 
> (-static-runtime for Qt).
>  You can also define your own triplet with dynamic lining of the VC runtime, 
> but I’m not familiar with the process.
>  Mårten
>  From: Nuno Santos  
> Sent: fredag 6. januar 2023 19:04
> To: Mårten Nordheim 
> Cc: Qt Interest ; Macieira, Thiago 
> 
> Subject: Re: [Interest] Qt6 - Fails to compile when openssl-linked enabled
>  Marten,
>  I’m now trying to do the same in Windows but having problems.
>  I’m using vcpkg to build openssl and the only different in the configure 
> line is the path to the installed vcpkgs
>   ..\configure.bat -prefix C:\Qt\6.4.1\msvc2019_static -static 
> -debug-and-release -nomake examples -nomake tests -nomake benchmarks -nomake 
> manual-tests -nomake minimal-static-tests -openssl-linked -qtnamespace 
> com_imaginando_qt_6_4_1 -- 
> -DOPENSSL_ROOT_DIR="C:\vcpkg\installed\x64-windows-static\" 
> -DOPENSSL_USE_STATIC_LIBS=TRUE
>  Inside C:\vcpkg\installed\x64-windows-static\include there is the openssl 
> folder
> 
> 
> And inside the C:\vcpkg\installed\x64-windows-static\lib there is:
> 
> 
> libcrypto.lib
> libeay32.lib
> libssl.lib
>  However, the result is:
>  CMake Error at qtbase/cmake/QtBuildInformation.cmake:490 (message):
>   Feature "openssl": Forcing to "ON" breaks its condition:  
> QT_FEATURE_openssl_runtime OR QT_FEATURE_openssl_linked  Condition values 
> dump:  QT_FEATURE_openssl_runtime = "OFF"
>   QT_FEATURE_openssl_linked = "OFF"Call Stack (most recent call first):
>   qtbase/cmake/QtFeature.cmake:281 (qt_configure_add_report_error)
>   qtbase/cmake/QtFeature.cmake:403 (qt_feature_check_and_save_internal_value)
>   qtbase/cmake/QtFeature.cmake:155 (qt_evaluate_feature)
>   qtbase/cmake/QtFeature.cmake:349 (qt_evaluate_config_expression)
>   qtbase/cmake/QtFeature.cmake:606 (qt_evaluate_feature)
>   qtbase/cmake/QtFeature.cmake:575 (qt_feature_module_end)
>   qtbase/src/CMakeLists.txt:9 (qt_feature_evaluate_features)
>   Trying to build without this, worked perfectly.
>  What am I missing here?
>  Thanks!
>  Nuno
> 
> 
> On 8 Dec 2022, at 15:04, Nuno Santos  wrote:
> 
> Marten,
> 
> I’ve noticed the nuance yesterday and tried but there was an error but I 
> didn’t read the output correctly. I had a typo in a second define, 
> OPENSSL_USE_STATIC_LIBS, which needed to be set to true. The following 
> configure line worked:
> 
> ./configure -prefix /Users/nsantos/Qt/6.4.1/macos_static -static 
> -debug-and-release -nomake examples -nomake tests -nomake benchmarks -nomake 
> manual-tests -nomake minimal-static-tests -openssl-linked -- 
> -DOPENSSL_ROOT_DIR="/Users/nsantos/Qt-Utils/openssl" 
> -DOPENSSL_USE_STATIC_LIBS=TRUE
> 
> Thiago, using openssl linked on Mac was a decision I have made a many years 
> ago and I can’t remember the reason. Maybe it is not a good decision anymore. 
> I know Apple has its SecureTransport framework. I might need to evaluate it 
> again.
> 
> Thanks!
> 
> Regards,
> 
> Nuno
> 
> 
> On 8 Dec 2022, at 08:49, Mårten Nordheim  wrote:
> 
> The parameters to cmake (-D*) must be passed after a separating double dash 
> (--).
>  So, this:
> -openssl-linked -DOPENSSL_ROOT_DIR="…"
>  Should be like:
> -openssl-linked -- -DOPENSSL_ROOT_DIR="…"
>  Mårten
>  From: Nuno Santos  
> Sent: onsdag 7. desember 2022 17:40
> To: Mårten Nordheim 
> Cc: Qt Interest 
> Subject: Re: [Interest] Qt6 - Fails to compile when openssl-linked 

Re: [Interest] Qt6 - Fails to compile when openssl-linked enabled

2023-01-06 Thread Nuno Santos
Marten,

I’m now trying to do the same in Windows but having problems.

I’m using vcpkg to build openssl and the only different in the configure line 
is the path to the installed vcpkgs


..\configure.bat -prefix C:\Qt\6.4.1\msvc2019_static -static -debug-and-release 
-nomake examples -nomake tests -nomake benchmarks -nomake manual-tests -nomake 
minimal-static-tests -openssl-linked -qtnamespace com_imaginando_qt_6_4_1 -- 
-DOPENSSL_ROOT_DIR="C:\vcpkg\installed\x64-windows-static\" 
-DOPENSSL_USE_STATIC_LIBS=TRUE

Inside C:\vcpkg\installed\x64-windows-static\include there is the openssl folder

And inside the C:\vcpkg\installed\x64-windows-static\lib there is:

libcrypto.lib
libeay32.lib
libssl.lib

However, the result is:

CMake Error at qtbase/cmake/QtBuildInformation.cmake:490 (message):
  Feature "openssl": Forcing to "ON" breaks its condition:  
QT_FEATURE_openssl_runtime OR QT_FEATURE_openssl_linked  Condition values dump: 
 QT_FEATURE_openssl_runtime = "OFF"
  QT_FEATURE_openssl_linked = "OFF"Call Stack (most recent call first):
  qtbase/cmake/QtFeature.cmake:281 (qt_configure_add_report_error)
  qtbase/cmake/QtFeature.cmake:403 (qt_feature_check_and_save_internal_value)
  qtbase/cmake/QtFeature.cmake:155 (qt_evaluate_feature)
  qtbase/cmake/QtFeature.cmake:349 (qt_evaluate_config_expression)
  qtbase/cmake/QtFeature.cmake:606 (qt_evaluate_feature)
  qtbase/cmake/QtFeature.cmake:575 (qt_feature_module_end)
  qtbase/src/CMakeLists.txt:9 (qt_feature_evaluate_features)


Trying to build without this, worked perfectly.

What am I missing here?

Thanks!

Nuno

> On 8 Dec 2022, at 15:04, Nuno Santos  wrote:
> 
> Marten,
> 
> I’ve noticed the nuance yesterday and tried but there was an error but I 
> didn’t read the output correctly. I had a typo in a second define, 
> OPENSSL_USE_STATIC_LIBS, which needed to be set to true. The following 
> configure line worked:
> 
> ./configure -prefix /Users/nsantos/Qt/6.4.1/macos_static -static 
> -debug-and-release -nomake examples -nomake tests -nomake benchmarks -nomake 
> manual-tests -nomake minimal-static-tests -openssl-linked -- 
> -DOPENSSL_ROOT_DIR="/Users/nsantos/Qt-Utils/openssl" 
> -DOPENSSL_USE_STATIC_LIBS=TRUE
> 
> Thiago, using openssl linked on Mac was a decision I have made a many years 
> ago and I can’t remember the reason. Maybe it is not a good decision anymore. 
> I know Apple has its SecureTransport framework. I might need to evaluate it 
> again.
> 
> Thanks!
> 
> Regards,
> 
> Nuno
> 
>> On 8 Dec 2022, at 08:49, Mårten Nordheim  wrote:
>> 
>> The parameters to cmake (-D*) must be passed after a separating double dash 
>> (--).
>>  So, this:
>> -openssl-linked -DOPENSSL_ROOT_DIR="…"
>>  Should be like:
>> -openssl-linked -- -DOPENSSL_ROOT_DIR="…"
>>  Mårten
>>  From: Nuno Santos  
>> Sent: onsdag 7. desember 2022 17:40
>> To: Mårten Nordheim 
>> Cc: Qt Interest 
>> Subject: Re: [Interest] Qt6 - Fails to compile when openssl-linked enabled
>>  Marten,
>>  Tried again without success. Maybe it's the directory layout. I don’t know 
>> I’m in the dark since the the CMakeOutput.log and CMakeError.log do not even 
>> mention ssl anywhere. Below is the new configure call:
>>  ./configure -prefix /Users/nsantos/Qt/6.4.2/macos -static 
>> -debug-and-release -nomake examples -nomake tests -nomake benchmarks -nomake 
>> manual-tests -nomake minimal-static-tests -openssl-linked 
>> -DOPENSSL_ROOT_DIR="/Users/nsantos/Qt-Utils/openssl" 
>> -DOPENSSL_USE_STATIC_LIBS
>>  Where:
>>  > find /Users/nsantos/Qt-Utils/openssl
>> 
>> 
>> gives:
>>  /Users/nsantos/Qt-Utils/openssl
>> /Users/nsantos/Qt-Utils/openssl/include
>> /Users/nsantos/Qt-Utils/openssl/include/crypto
>> /Users/nsantos/Qt-Utils/openssl/include/crypto/md32_common.h
>> …
>> /Users/nsantos/Qt-Utils/openssl/lib
>> /Users/nsantos/Qt-Utils/openssl/lib/libcrypto.a
>> /Users/nsantos/Qt-Utils/openssl/lib/libssl.a
>>  Where can I find more information?
>>  Thank you!
>>  Best regards,
>>  Nuno
>> 
>> 
>> On 7 Dec 2022, at 13:50, Mårten Nordheim  wrote:
>>  Ah, I don’t think OPENSSL_LIBS is in use anymore!
>> I think it was still left printed at the end of configure, I’m not sure the 
>> change removing it was merged into 6.4.
>> Please use the FindOpenSSL cmake find-module variables: 
>> https://cmake.org/cmake/help/latest/module/FindOpenSSL.html
>> In your case, passing -DOPENSSL_ROOT_DIR="/Users/nsantos/Qt-Utils/openssl"
>> at the end of your configure line, something like this:
>>  ./configure -prefix …. -op

Re: [Interest] Qt6 fails to compile on linux Ubuntu 22.04

2023-01-06 Thread Nuno Santos
Thiago,

Thanks for your reply.

I had all those packets installed even so it was failing… 

Now I’m trying with Ubuntu 22.10 and I have a new problem during the config 
phase:

CMake Error at /usr/lib/llvm-15/lib/cmake/llvm/LLVMExports.cmake:1634 (message):
  The imported target "mlir-tblgen" references the file 
"/usr/lib/llvm-15/bin/mlir-tblgen”

The file does not exist indeed.

Any ideas?

Thanks!

Regards,

Nuno

> On 5 Jan 2023, at 21:06, Thiago Macieira  wrote:
> 
> On Thursday, 5 January 2023 13:24:34 -03 Nuno Santos wrote:
>> qxcbkeyboard.cpp:(.text._ZNK12QXcbKeyboard12possibleKeysEPK9QKeyEvent+0x2e):
>> undefined reference to `QXkbCommon::possibleKeys(xkb_state*, QKeyEvent
>> const*, bool, bool)'
> 
> You probably didn't install the xkbcommon development libraries in your 
> system. Look at the output from CMake and make sure you have "Yes" on 
> everything that applies to Unix, Linux and X11 (except the alternative-choice 
> ones), like this:
> 
>  Accessibility .. yes
>  FreeType ... yes
>Using system FreeType  yes
>  HarfBuzz ... yes
>Using system HarfBuzz  yes
>  Fontconfig . yes
>  Image formats:
>GIF .. yes
>ICO .. yes
>JPEG . yes
>  Using system libjpeg ... yes
>PNG .. yes
>  Using system libpng  yes
>  Text formats:
>HtmlParser ... yes
>CssParser  yes
>OdfWriter  yes
>MarkdownReader ... yes
>  Using system libmd4c ... no
>MarkdownWriter ... yes
>  EGL  yes
>  OpenVG . no
>  OpenGL:
>Desktop OpenGL ... yes
>OpenGL ES 2.0  no
>OpenGL ES 3.0  no
>OpenGL ES 3.1  no
>OpenGL ES 3.2  no
>  Vulkan . yes
>  Session Management . yes
> Features used by QPA backends:
>  evdev .. yes
>  libinput ... yes
>  HiRes wheel support in libinput  yes
>  INTEGRITY HID .. no
>  mtdev .. no
>  tslib .. no
>  xkbcommon .. yes
>  X11 specific:
>XLib . yes
>XCB Xlib . yes
>EGL on X11 ... yes
>xkbcommon-x11  yes
>xcb-sm ... no
> 
> 
> -- 
> Thiago Macieira - thiago.macieira (AT) intel.com
>  Cloud Software Architect - Intel DCAI 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


[Interest] Qt6 fails to compile on linux Ubuntu 22.04

2023-01-05 Thread Nuno Santos
Hi,

I’m trying to compile Qt 6.4.1 on Linux from source but I’m having the 
following error:

/usr/bin/ld: qtbase/lib/libQt6XcbQpa.a(qxcbkeyboard.cpp.o): in function 
`QXcbKeyboard::possibleKeys(QKeyEvent const*) const':
qxcbkeyboard.cpp:(.text._ZNK12QXcbKeyboard12possibleKeysEPK9QKeyEvent+0x2e): 
undefined reference to `QXkbCommon::possibleKeys(xkb_state*, QKeyEvent const*, 
bool, bool)'
/usr/bin/ld: qtbase/lib/libQt6XcbQpa.a(qxcbkeyboard.cpp.o): in function 
`QXcbKeyboard::initialize()':
qxcbkeyboard.cpp:(.text._ZN12QXcbKeyboard10initializeEv+0x24): undefined 
reference to `QXkbCommon::setXkbContext(QPlatformInputContext*, xkb_context*)'
/usr/bin/ld: qtbase/lib/libQt6XcbQpa.a(qxcbkeyboard.cpp.o): in function 
`QXcbKeyboard::updateKeymap()':
qxcbkeyboard.cpp:(.text._ZN12QXcbKeyboard12updateKeymapEv+0xe2): undefined 
reference to `QXkbCommon::verifyHasLatinLayout(xkb_keymap*)'
/usr/bin/ld: qtbase/lib/libQt6XcbQpa.a(qxcbkeyboard.cpp.o): in function 
`QXcbKeyboard::handleKeyEvent(unsigned int, QEvent::Type, unsigned char, 
unsigned short, unsigned int, bool)':
qxcbkeyboard.cpp:(.text._ZN12QXcbKeyboard14handleKeyEventEjN6QEvent4TypeEhtjb+0xee):
 undefined reference to `QXkbCommon::lookupString(xkb_state*, unsigned int)'
/usr/bin/ld: 
qxcbkeyboard.cpp:(.text._ZN12QXcbKeyboard14handleKeyEventEjN6QEvent4TypeEhtjb+0x12e):
 undefined reference to `QXkbCommon::keysymToQtKey(unsigned int, 
QFlags, xkb_state*, unsigned int, bool, bool)'
collect2: error: ld returned 1 exit status
[18/3272] Building CXX object 
qtsvg/src/svgwidgets/CMakeFiles/SvgWidgets.dir/cmake_pch.hxx.gch
ninja: build stopped: subcommand failed.

Does anyone knows why is it failing?

Regards,

Best,

Nuno

___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


[Interest] Apps targeting Android 12 and higher are required to specify an explicit value for `android:exported`

2023-01-02 Thread Nuno Santos
Hi,

Has anyone gone recently through this problem when setting up an higher api 
level?

What’s the fastest approach to solve it when dealing with a Qt app?

Thanks!

Regards,

Nuno


___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] Qt 6 and Windows with MSVC 2019

2022-12-30 Thread Nuno Santos
Cristian,

I have deleted the build folder and tried it again. It worked this time.

Thank you!

Best,

Nuno

> On 29 Dec 2022, at 14:43, Cristian Adam  wrote:
> 
> Hi Nuno,
> 
> The error message says that there is no CMAKE_CXX_COMPILER specified.
> 
> Your CMake command has only -S  and -B  parameters. This 
> means that you already have configured the project with an invalid 
> CMAKE_CXX_COMPILER  parameter.
> 
> Delete your build directory and try again or click on "Re-configure with 
> Initial Parameters" in the CMake project settings. Qt Creator should issue a 
> CMake command with a -D CMAKE_CXX_COMPILER parameter.
> 
> If the CMAKE_CXX_COMPILER parameter is empty, then you have to check your 
> Kit's compiler settings, fix the issue and try again.   
> 
> Cheers,
> Cristian. 
> 
> From: Interest  on behalf of Nuno Santos 
> 
> Sent: Thursday, December 29, 2022 14:16
> To: Macieira, Thiago 
> Cc: interest@qt-project.org 
> Subject: Re: [Interest] Qt 6 and Windows with MSVC 2019
>  
> Thiago,
> 
> Thanks for your reply.
> 
> This was run inside Qt Creator.
> 
> Regards,
> 
> Nuno
> 
> > On 29 Dec 2022, at 11:42, Thiago Macieira  wrote:
> > 
> > On Thursday, 29 December 2022 07:55:52 -03 Nuno Santos wrote:
> >> -- The CXX compiler identification is unknown
> > 
> > Did you run this from inside the MSVC Command Prompt, where the 
> > vcvarsall.bat 
> > script was previously run to set the environment up?
> > 
> > -- 
> > Thiago Macieira - thiago.macieira (AT) intel.com
> >  Cloud Software Architect - Intel DCAI Cloud Engineering
> > 
> > 
> > 
> > ___
> > Interest mailing list
> > Interest@qt-project.org
> > https://lists.qt-project.org/listinfo/interest
> 
> ___
> Interest mailing list
> Interest@qt-project.org <mailto: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] Qt6 on Ubuntu 22

2022-12-29 Thread Nuno Santos
Thiago,

Yes, that was the problem. I have new one though…

19:00:54: Starting /home/nsantos/workspace/build-test-Desktop-Debug/apptest...
QML debugging is enabled. Only use this in a safe environment.
Warning: Ignoring WAYLAND_DISPLAY on Gnome. Use QT_QPA_PLATFORM=wayland to run 
on Wayland anyway.
QQmlApplicationEngine failed to load component
qrc:/test/main.qml: module "QtQml.WorkerScript" is not installed
19:00:55: /home/nsantos/workspace/build-test-Desktop-Debug/apptest exited with 
code 255

It says worker script is not installed but it seems to be installed:

nsantos@nuno-ubuntu:/usr/lib/x86_64-linux-gnu/cmake/Qt6$ sudo apt install 
libqt6qmlworkerscript6
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
libqt6qmlworkerscript6 is already the newest version (6.2.4+dfsg-3ubuntu1).
libqt6qmlworkerscript6 set to manually installed.
The following packages were automatically installed and are no longer required:
  chromium-codecs-ffmpeg-extra gstreamer1.0-vaapi i965-va-driver 
intel-media-va-driver libaacs0 libaom3 libass9 libavcodec58 libavformat58 
libavutil56 libbdplus0 libblas3 libbluray2 libbs2b0
  libchromaprint1 libcodec2-1.0 libdav1d5 libflashrom1 libflite1 libftdi1-2 
libgme0 libgsm1 libgstreamer-plugins-bad1.0-0 libigdgmm12 liblilv-0-0 libmfx1 
libmysofa1 libnorm1 libopenmpt0 libpgm-5.3-0
  libpostproc55 librabbitmq4 librubberband2 libserd-0-0 libshine3 libsnappy1v5 
libsord-0-0 libsratom-0-0 libsrt1.4-gnutls libssh-gcrypt-4 libswresample3 
libswscale5 libudfread0 libva-drm2
  libva-wayland2 libva-x11-2 libva2 libvdpau1 libvidstab1.1 libx265-199 
libxvidcore4 libzimg2 libzmq5 libzvbi-common libzvbi0 mesa-va-drivers 
mesa-vdpau-drivers ocl-icd-libopencl1 pocketsphinx-en-us
  va-driver-all vdpau-driver-all
Use 'sudo apt autoremove' to remove them.
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
nsantos@nuno-ubuntu:/usr/lib/x86_64-linux-gnu/cmake/Qt6$

Any ideas?

Thanks!

Nuno

> On 29 Dec 2022, at 17:11, Thiago Macieira  wrote:
> 
> On Thursday, 29 December 2022 11:31:15 -03 Nuno Santos wrote:
>> [ 66%] Building CXX object
>> CMakeFiles/appqt6-test.dir/appqt6-test_qmltyperegistrations.cpp.o
>> /home/nsantos/workspace/build-qt6-test-Desktop-Debug/appqt6-test_qmltypereg
>> istrations.cpp:17:23: error: variable has incomplete type 'void'
>> Q_QMLTYPE_EXPORT void qml_register_types_qt6-test()
> 
> Most likely, your target name has a dash (qt6-test). Use an identifier-like 
> target name.
> 
> This can be fixed in the Qt scripts of course, but it won't benefit you now.
> 
> -- 
> Thiago Macieira - thiago.macieira (AT) intel.com
>  Cloud Software Architect - Intel DCAI 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] Qt6 on Ubuntu 22

2022-12-29 Thread Nuno Santos
Hi,

Thanks you both for your replies. It worked.

I also had to install libgl1-mesa-dev otherwise QtGui couldn’t be found.

I have an another problem though. A simple qt quick project does not compile 
with the following error:

11:30:34: Running steps for project qt6-test...
11:30:34: Starting: "/usr/bin/cmake" --build 
/home/nsantos/workspace/build-qt6-test-Desktop-Debug --target clean
11:30:34: The process "/usr/bin/cmake" exited normally.
11:30:34: Starting: "/usr/bin/cmake" --build 
/home/nsantos/workspace/build-qt6-test-Desktop-Debug --target all
[  5%] Generating qt6-test/main.qml
[  5%] Built target appqt6-test_tooling
[ 11%] Generating .rcc/qmlcache/appqt6-test_qmlcache_loader.cpp
[ 16%] Automatic MOC for target appqt6-test
[ 16%] Built target appqt6-test_autogen
[ 22%] Running AUTOMOC file extraction for target appqt6-test
[ 22%] Built target appqt6-test_automoc_json_extraction
[ 27%] Running moc --collect-json for target appqt6-test
[ 33%] Automatic QML type registration for target appqt6-test
[ 38%] Generating .rcc/qmlcache/appqt6-test_main_qml.cpp
[ 44%] Running rcc for resource appqt6-test_raw_qml_0
[ 50%] Running rcc for resource qmake_qt6-test
[ 55%] Building CXX object 
CMakeFiles/appqt6-test.dir/appqt6-test_autogen/mocs_compilation.cpp.o
[ 61%] Building CXX object CMakeFiles/appqt6-test.dir/main.cpp.o

[ 66%] Building CXX object 
CMakeFiles/appqt6-test.dir/appqt6-test_qmltyperegistrations.cpp.o
/home/nsantos/workspace/build-qt6-test-Desktop-Debug/appqt6-test_qmltyperegistrations.cpp:17:23:
 error: variable has incomplete type 'void'
Q_QMLTYPE_EXPORT void qml_register_types_qt6-test()
  ^
/home/nsantos/workspace/build-qt6-test-Desktop-Debug/appqt6-test_qmltyperegistrations.cpp:17:45:
 error: expected ';' after top level declarator
Q_QMLTYPE_EXPORT void qml_register_types_qt6-test()
^
;
2 errors generated.

gmake[2]: *** [CMakeFiles/appqt6-test.dir/build.make:160: 
CMakeFiles/appqt6-test.dir/appqt6-test_qmltyperegistrations.cpp.o] Error 1
gmake[1]: *** [CMakeFiles/Makefile2:94: CMakeFiles/appqt6-test.dir/all] Error 2
gmake: *** [Makefile:91: all] Error 2
11:30:40: The process "/usr/bin/cmake" exited with code 2.
Error while building/deploying project qt6-test (kit: Desktop)
When executing step "Build"
11:30:40: Elapsed time: 00:05.

Has anyone know the reason?

Thanks!

Regards,

Nuno

> On 29 Dec 2022, at 12:31, A. Pönitz  wrote:
> 
> On Thu, Dec 29, 2022 at 10:44:57AM +, Nuno Santos wrote:
>> Hi,
>> 
>> I’m trying to install and run Qt projects on Linux Ubuntu 22
>> 
>> I’ve used apt to install qt6-base-dev, qtcreator and libqt6quick6 packages.
>> 
>> But when I run Qt Creator and try a test project it always fails to find 
>> QtQuick packages:
>> 
>> Running /usr/bin/cmake -S /home/nsantos/workspace/qt6-test -B 
>> /home/nsantos/workspace/build-qt6-test-Desktop-Debug in 
>> /home/nsantos/workspace/build-qt6-test-Desktop-Debug.
>> -- Could NOT find Qt6Quick (missing: Qt6Quick_DIR)
>> CMake Error at CMakeLists.txt:8 (find_package):
>>  Found package configuration file:
>> /usr/lib/x86_64-linux-gnu/cmake/Qt6/Qt6Config.cmake  but it set Qt6_FOUND to 
>> FALSE so package "Qt6" is considered to be NOT
>>  FOUND.  Reason given by package:  Failed to find Qt component "Quick".  
>> Expected Config file at
>>  "/usr/lib/x86_64-linux-gnu/cmake/Qt6Quick/Qt6QuickConfig.cmake" does NOT
>>  exist-- Configuring incomplete, errors occurred!
>> See also 
>> "/home/nsantos/workspace/build-qt6-test-Desktop-Debug/CMakeFiles/CMakeOutput.log".
>> CMake process exited with exit code 1.
>> 
>> The directory /usr/lib/x86_64-linux-gnu/cmake/Qt6Quick is actually missing, 
>> so what package should I need to install in order to have it?
> 
> Juudging from apt output I'd try qt6-declarative-dev and perhaps
> qt6-declarative-dev-tools
> 
> $ apt-cache search qt6- | grep dev
> qcoro-qt6-dev - C++20 coroutines for Qt6 - development
> qt6-3d-dev - Qt 6 3D - development files
> qt6-base-dev - Qt 6 base development files
> qt6-base-dev-tools - Qt 6 base development programs
> qt6-base-private-dev - Qt 6 base private development files
> qt6-connectivity-dev - Qt 6 Connectivity - development files
> qt6-declarative-dev - Qt 6 declarative development files
> qt6-declarative-dev-tools - Qt 6 declarative development programs
> qt6-declarative-private-dev - Qt 6 declarative private development files
> qt6-multimedia-dev - Qt 6 Multimedia - development files
> qt6-pdf-dev - Qt 6 PDF library - development files
> qt6-positioning-dev - Qt 6 Positioning - development files
> qt6-quick3d-dev - Qt 6 Quick 3D 

Re: [Interest] Qt 6 and Windows with MSVC 2019

2022-12-29 Thread Nuno Santos
Thiago,

Thanks for your reply.

This was run inside Qt Creator.

Regards,

Nuno

> On 29 Dec 2022, at 11:42, Thiago Macieira  wrote:
> 
> On Thursday, 29 December 2022 07:55:52 -03 Nuno Santos wrote:
>> -- The CXX compiler identification is unknown
> 
> Did you run this from inside the MSVC Command Prompt, where the vcvarsall.bat 
> script was previously run to set the environment up?
> 
> -- 
> Thiago Macieira - thiago.macieira (AT) intel.com
>  Cloud Software Architect - Intel DCAI 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


[Interest] Qt 6 and Windows with MSVC 2019

2022-12-29 Thread Nuno Santos
Hi,

I’m trying to experiment Qt 6 on Windows but I’m facing an issue.

If I setup a test quick project using qmake, it works. However, if I choose 
cmake failed to find the compiler with the following cmake error:

Running C:\Program Files\CMake\bin\cmake.exe -S C:/Users/sinos/workspace/qt6 -B 
C:/Users/sinos/workspace/build-qt6-Desktop_Qt_6_4_1_MSVC2019_64bit-Debug in 
C:\Users\sinos\workspace\build-qt6-Desktop_Qt_6_4_1_MSVC2019_64bit-Debug.
-- The CXX compiler identification is unknown
CMake Error at CMakeLists.txt:3 (project):
  No CMAKE_CXX_COMPILER could be found.  Tell CMake where to find the compiler 
by setting either the environment
  variable "CXX" or the CMake cache entry CMAKE_CXX_COMPILER to the full path
  to the compiler, or to the compiler name if it is in the PATH.-- Configuring 
incomplete, errors occurred!
See also 
"C:/Users/sinos/workspace/build-qt6-Desktop_Qt_6_4_1_MSVC2019_64bit-Debug/CMakeFiles/CMakeOutput.log".
See also 
"C:/Users/sinos/workspace/build-qt6-Desktop_Qt_6_4_1_MSVC2019_64bit-Debug/CMakeFiles/CMakeError.log".
CMake process exited with exit code 1.Elapsed time: 00:01.Running C:\Program 
Files\CMake\bin\cmake.exe -S C:/Users/sinos/workspace/qt6 -B 
C:/Users/sinos/workspace/build-qt6-Desktop_Qt_6_4_1_MSVC2019_64bit-Debug in 
C:\Users\sinos\workspace\build-qt6-Desktop_Qt_6_4_1_MSVC2019_64bit-Debug.
-- The CXX compiler identification is unknown
CMake Error at CMakeLists.txt:3 (project):
  No CMAKE_CXX_COMPILER could be found.  Tell CMake where to find the compiler 
by setting either the environment
  variable "CXX" or the CMake cache entry CMAKE_CXX_COMPILER to the full path
  to the compiler, or to the compiler name if it is in the PATH.-- Configuring 
incomplete, errors occurred!
See also 
"C:/Users/sinos/workspace/build-qt6-Desktop_Qt_6_4_1_MSVC2019_64bit-Debug/CMakeFiles/CMakeOutput.log".
See also 
"C:/Users/sinos/workspace/build-qt6-Desktop_Qt_6_4_1_MSVC2019_64bit-Debug/CMakeFiles/CMakeError.log".
CMake process exited with exit code 1.Elapsed time: 00:00.

What could missing?

Thanks!

Nuno
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


[Interest] Qt6 on Ubuntu 22

2022-12-29 Thread Nuno Santos
Hi,

I’m trying to install and run Qt projects on Linux Ubuntu 22

I’ve used apt to install qt6-base-dev, qtcreator and libqt6quick6 packages.

But when I run Qt Creator and try a test project it always fails to find 
QtQuick packages:

Running /usr/bin/cmake -S /home/nsantos/workspace/qt6-test -B 
/home/nsantos/workspace/build-qt6-test-Desktop-Debug in 
/home/nsantos/workspace/build-qt6-test-Desktop-Debug.
-- Could NOT find Qt6Quick (missing: Qt6Quick_DIR)
CMake Error at CMakeLists.txt:8 (find_package):
  Found package configuration file:
/usr/lib/x86_64-linux-gnu/cmake/Qt6/Qt6Config.cmake  but it set Qt6_FOUND to 
FALSE so package "Qt6" is considered to be NOT
  FOUND.  Reason given by package:  Failed to find Qt component "Quick".  
Expected Config file at
  "/usr/lib/x86_64-linux-gnu/cmake/Qt6Quick/Qt6QuickConfig.cmake" does NOT
  exist-- Configuring incomplete, errors occurred!
See also 
"/home/nsantos/workspace/build-qt6-test-Desktop-Debug/CMakeFiles/CMakeOutput.log".
CMake process exited with exit code 1.

The directory /usr/lib/x86_64-linux-gnu/cmake/Qt6Quick is actually missing, so 
what package should I need to install in order to have it?

Thanks!

Regards,

Nuno
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] Qml Linting Error - Warnings occurred while importing module "QtQuick.Controls":

2022-12-19 Thread Nuno Santos
Ulf,

Thanks for your reply.

I will try again. There will be more questions for sure. 

Will there be a 2022 version of the following video?

https://www.youtube.com/watch?v=4ji6D6UpA54 


Best regards,

Nuno

> On 19 Dec 2022, at 18:43, Ulf Hermann via Interest  
> wrote:
> 
>> Warning: QtQuick.Controls uses optional imports which are not supported. 
>> Some types might not be found.
> 
> This is not an error but a warning. Indeed the compiler will not compile your 
> code to C++ because it doesn't know which of the optional imports (ie styles) 
> will be active at run time. You can import one specific style, for example 
> QtQuick.Controls.Fusion instead of QtQuick.Controls. Then the compiler will 
> know what to expect, but you won't be able to use a different style at run 
> time anymore.
> 
> best regards,
> Ulf
> ___
> 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] Qml Linting Error - Warnings occurred while importing module "QtQuick.Controls":

2022-12-19 Thread Nuno Santos
Hi,

I’m trying to take advantage of the new Qml Linting Tools provided by the Qt 
Quick Compiler Extensions (TP) to enhance the qml code and thus improve its 
performance.

This is all new to me and sometimes I’m faced with errors that does not seem 
error nor they give problems when actually running the code. For example, what 
is wrong with the following code in the linter perspective?

import QtQuick.Controls

Pane {
background: null
focusPolicy: Qt.ClickFocus
}

Because it gives the following error:

Warning: GPane.qml:1:1: Warnings occurred while importing module 
"QtQuick.Controls":
import QtQuick.Controls
^^
---
Warning: QtQuick.Controls uses optional imports which are not supported. Some 
types might not be found.
---

Warning: GPane.qml:3:1: Pane was not found. Did you add all import paths?
Pane {


Thanks!

Regards,

Nuno


___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] [Development] Qt 6.5 Is Irrelevant for More than 95% of Mac Desktops

2022-12-18 Thread Nuno Santos
Hi,

Every time a new Mac OS version comes out this is what happens:

https://cdm.link/2022/11/macos-13-ventura-compatibility-plugins/

https://cdm.link/2020/11/big-sur-and-the-new-macs-look-promising-but-youll-want-to-wait/

https://cdm.link/2019/10/wait-on-catalina/

https://cdm.link/2020/05/how-to-update-your-mac-to-mojave-not-catalina/

Many people are still running their Intel macs. I speak for myself. I had 
bought a really powerful quad core Intel mac laptop one year before m1 is out. 
Is terrible but what am I going to do? Throw it out of the window if it is 
still able to do the job?

Musicians are very conservative in the software they use because they have a 
music setup that relies on a certain plugin and are not likely to give away 
that feature just because Apple upgraded their software. So they keep it just 
as it is. The ones who venture in instant updates are the ones who report 
problems to the plugin makers which can sometime take months to fix the 
problems. In my case, if the problem relies on a Qt bug or incapability, I have 
my hands tied.

My experience is that sometimes people take up to two years to upgrade to a 
more recent operating system.

I understand all the technical reasons that have been thrown on the table from 
the incredible players of Qt team and their developers during this discussion.

However, for me as a developer it is also a challenge to upgrade to the new Qt 
6.

I have finally decided to make the move on a new product development and 
knowing up hand that it will only run on Big Sur onwards because Catalina 
support will be over is also ungrateful. 

Specially when during this development phase I find some Qml conversion issues 
that are Qt bugs which should only be address in future versions.

We understand your concerns and reasons, we are just asking more time for that 
move to be done, so that all other general bugs and improvements are still safe 
to run on systems like Catalina.
 
Just sharing my concern and personal experience.

Best regards,

--
Nuno Santos

> No dia 18/12/2022, às 06:32, coroberti  escreveu:
> 
> On Sun, Dec 18, 2022 at 3:29 AM Thiago Macieira
>  wrote:
>> 
>>> On Saturday, 17 December 2022 05:40:48 -03 Tuukka Turunen via Interest 
>>> wrote:
>>> at least between versions 10.15 and 11 there does not seem to be a
>>> major drop in what HW is supported.
>> 
>> There is a drop, but we're talking about  CPUs launched in 2013 and older.
>> Specifically, 11.0 drops support for Sandy Bridge and Ivy Bridge Macbooks and
>> Mac Minis. Whether you count that as "major" or not, I'll leave it up to you.
>> 
>> What matters to me is that those were the last AVX-incapable CPUs, which 
>> allow
>> us to assume that AVX2 is present.
> 
> Dear Thiago and Tuukka,
> It seems that you are working under an assumption that if the HW allows it,
> users will upgrade their Mac OS.
> 
> This is not how it works in reality, sorry.
> 
> Many, if not most, Mac users are upgrading only once.
> They upgrade, see how their content-editing, multimedia, etc. software
> is ruined by their first upgrade;
> next, they work with software vendors to restore their applications
> back to some working state, get the lesson and ... do not touch it forever.
> 
> Try to listen to the people that work with the real, live customers
> like Nuno and me.
> 
> Please, add one more old Mac OS release to the supported list to be
> more realistic, so it will be not a thin three releases but at least four.
> 
> Please, consider that.
> Thanks in advance!
> 
> P.S. Oh, these customers are not security aware? Agree, this is bad.
> 
> Sorry, but please get it that these people, not computer fricks and sometimes
> technically challenged, need to run smoothly with their daily jobs
> rather than work hard on
> bringing their apps to the working stage after each upgrade.
> ___
> 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.5 Is Irrelevant for More than 95% of Mac Desktops

2022-12-16 Thread Nuno Santos
Hi,

I totally subscribe this statement from Robert.

We are starting to develop a new application with Qt 6.4.1. Qt 6 is still very 
bug prone and we will keep stumbling on them and you will probably keep 
releasing new version of Qt 6 rather fix versions of Qt 6.4.X

Our users are very conservative about upgrading Mac OS because usually new 
version of Mac OS contain bugs and incompatibilities of existing software and 
no one wants to risk breaking their music setup at each Mac OS release.

This seems like a total non-sense decision. What are the fundaments for such 
decision?

Thank you!

Best regards,

Nuno Santos
Founder / CEO / CTO
www.imaginando.pt

> On 16 Dec 2022, at 12:20, coroberti  wrote:
> 
> Hi,
> Since Qt 6.5 drops Mac OS 10.15 Catalina,
> it apparently starts to be irrelevant for at least 95% of Mac Desktops.
> 
> https://gs.statcounter.com/macos-version-market-share/desktop/worldwide
> 
> Google Analytics data of visitors for some web-site, where I have access,
> also supports the above observations.
> 
> To keep Qt-6 being still relevant for Mac Desktop open-source
> development, please
> consider keeping  Mac OS 10.15 as a target.
> Thanks.
> 
> Kind regards,
> Robert Iakobashvili
> 
> ___
> 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] qmake to cmake - error: redefinition of 'unit' const QQmlPrivate::CachedQmlUnit unit

2022-12-15 Thread Nuno Santos
Ulf,

I found the culprit. I was indeed doing a duplicated import of my qml.cmake 
file, which was adding each qml twice to the compilation.

Thanks for the heads up.

Best regards,

Nuno

> On 15 Dec 2022, at 12:21, Ulf Hermann via Interest  
> wrote:
> 
>> list(APPEND QML_FILES
>> resources/qml/Browser.qml
>> resources/qml/BrowserBank.qml
>> resources/qml/BrowserButton.qml
>> …
> 
> Are there more files called "Browser.qml" in the same module? That doesn't 
> work. Your QML components need unique names.
> 
> Or is there some qt_target_qml_sources() or similar, repeating the same QML 
> files?
> 
> In general, I think we need a bug report with a complete example.
> 
> best regards,
> Ulf
> ___
> 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] qmake to cmake - error: redefinition of 'unit' const QQmlPrivate::CachedQmlUnit unit

2022-12-15 Thread Nuno Santos
Thiago,

Thanks for your reply. Too big to paste it here. I have included the errors and 
content of the shared_qmlcache_loader.cpp here:

https://pastebin.com/vV6DjRk6 <https://pastebin.com/vV6DjRk6>

Thanks!

Regards,

Nuno

> On 14 Dec 2022, at 19:57, Thiago Macieira  wrote:
> 
> On Wednesday, 14 December 2022 16:11:10 -03 Nuno Santos wrote:
>> error: redefinition of ‘unit' const QQmlPrivate::CachedQmlUnit unit
> 
> Please paste the full error message. In particular, the compiler must have 
> told you where the other definition was.
> 
> -- 
> Thiago Macieira - thiago.macieira (AT) intel.com
>  Cloud Software Architect - Intel DCAI 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


[Interest] qmake to cmake - error: redefinition of 'unit' const QQmlPrivate::CachedQmlUnit unit

2022-12-14 Thread Nuno Santos
Hi,

I’m trying to start porting my .pro/.pri files to cmake and I’m stumbling on 
the following error:

error: redefinition of ‘unit' const QQmlPrivate::CachedQmlUnit unit

The file shared_qmlcache_loader.cpp has a the following content:

namespace QmlCacheGeneratedCode {
namespace _shared_resources_qml_Browser_qml { 
extern const unsigned char qmlData[];
extern const QQmlPrivate::AOTCompiledFunction aotBuiltFunctions[];
const QQmlPrivate::CachedQmlUnit unit = {
reinterpret_cast(), 
[0], nullptr
};
}
namespace _shared_resources_qml_BrowserBank_qml { 
extern const unsigned char qmlData[];
extern const QQmlPrivate::AOTCompiledFunction aotBuiltFunctions[];
const QQmlPrivate::CachedQmlUnit unit = {
reinterpret_cast(), 
[0], nullptr
};
}

unit is always being used as a variable for each qml component.

In my CMakeLists.txt I have the following include:

include(qml.cmake)

list(APPEND QML_FILES
resources/qml/Browser.qml
resources/qml/BrowserBank.qml
resources/qml/BrowserButton.qml
…


qt_add_qml_module(shared
URI shared
VERSION 1.0
QML_FILES ${QML_FILES}
SOURCES ${SOURCE_FILES}
)

Not specifying qml source, it compiles correctly.




___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] Qt 6.4.1 static - Missing some debug objects when using a static build kit?

2022-12-09 Thread Nuno Santos
Alexandru,

Thanks for your reply.

That did the trick! Thank you!

Best regards,

Nuno

> On 9 Dec 2022, at 07:51, Alexandru Croitor  wrote:
> 
> Hi,
> 
> Most likely you're hitting 
> https://gitlab.kitware.com/cmake/cmake/-/issues/21475
> 
> Make sure you call either ninja install in the Qt build dir or cmake --build 
> . --target install
> 
> Just cmake --install . does not work.
> 
>> On 9. Dec 2022, at 00:07, Nuno Santos  wrote:
>> 
>> Hi,
>> 
>> I’ve built Qt 6.4.1 from the source and when compiling an existing project 
>> in debug the following symbols are missing.
>> 
>> However, if I build the same project in release, everything is fine, not a 
>> single error.
>> 
>> In order to build the kit I have used the following configuration:
>> 
>> perl init-repository 
>> --module-subset=qt5compat,qtbase,qtdeclarative,qtimageformats,qtmultimedia,qtshadertools,qtsvg,qtwebsockets
>> ./configure -prefix /Users/nsantos/Qt/6.4.1/macos_static -static 
>> -debug-and-release -nomake examples -nomake tests -nomake benchmarks -nomake 
>> manual-tests -nomake minimal-static-tests -openssl-linked -- 
>> -DOPENSSL_ROOT_DIR="/Users/nsantos/Qt-Utils/openssl" 
>> -DOPENSSL_USE_STATIC_LIBS=TRUE
>> 
>> clang: error: no such file or directory: 
>> '/Users/nsantos/Qt/6.4.1/macos_static/lib/objects-Debug/Widgets_resources_1/.rcc/qrc_qstyle.cpp.o'
>> clang: error: no such file or directory: 
>> '/Users/nsantos/Qt/6.4.1/macos_static/lib/objects-Debug/Widgets_resources_2/.rcc/qrc_qstyle1.cpp.o'
>> clang: error: no such file or directory: 
>> '/Users/nsantos/Qt/6.4.1/macos_static/lib/objects-Debug/Widgets_resources_3/.rcc/qrc_qmessagebox.cpp.o'
>> clang: error: no such file or directory: 
>> '/Users/nsantos/Qt/6.4.1/macos_static/lib/objects-Debug/Gui_resources_1/.rcc/qrc_qpdf.cpp.o'
>> clang: error: no such file or directory: 
>> '/Users/nsantos/Qt/6.4.1/macos_static/lib/objects-Debug/Gui_resources_2/.rcc/qrc_gui_shaders.cpp.o'
>> clang: error: no such file or directory: 
>> '/Users/nsantos/Qt/6.4.1/macos_static/plugins/styles/libqmacstyle_debug.a'
>> clang: error: no such file or directory: 
>> '/Users/nsantos/Qt/6.4.1/macos_static/lib/objects-Debug/QCocoaIntegrationPlugin_resources_1/.rcc/qrc_qcocoaresources.cpp.o'
>> clang: error: no such file or directory: 
>> '/Users/nsantos/Qt/6.4.1/macos_static/plugins/platforms/libqcocoa_debug.a'
>> clang: error: no such file or directory: 
>> '/Users/nsantos/Qt/6.4.1/macos_static/plugins/iconengines/libqsvgicon_debug.a'
>> clang: error: no such file or directory: 
>> '/Users/nsantos/Qt/6.4.1/macos_static/plugins/imageformats/libqgif_debug.a'
>> clang: error: no such file or directory: 
>> '/Users/nsantos/Qt/6.4.1/macos_static/plugins/imageformats/libqicns_debug.a'
>> clang: error: no such file or directory: 
>> '/Users/nsantos/Qt/6.4.1/macos_static/plugins/imageformats/libqico_debug.a'
>> clang: error: no such file or directory: 
>> '/Users/nsantos/Qt/6.4.1/macos_static/plugins/imageformats/libqjpeg_debug.a'
>> clang: error: no such file or directory: 
>> '/Users/nsantos/Qt/6.4.1/macos_static/lib/libQt6BundledLibjpeg_debug.a'
>> clang: error: no such file or directory: 
>> '/Users/nsantos/Qt/6.4.1/macos_static/plugins/imageformats/libqmacheif_debug.a'
>> clang: error: no such file or directory: 
>> '/Users/nsantos/Qt/6.4.1/macos_static/plugins/imageformats/libqmacjp2_debug.a'
>> clang: error: no such file or directory: 
>> '/Users/nsantos/Qt/6.4.1/macos_static/plugins/imageformats/libqsvg_debug.a'
>> clang: error: no such file or directory: 
>> '/Users/nsantos/Qt/6.4.1/macos_static/lib/libQt6Svg_debug.a'
>> clang: error: no such file or directory: 
>> '/Users/nsantos/Qt/6.4.1/macos_static/plugins/imageformats/libqtga_debug.a'
>> clang: error: no such file or directory: 
>> '/Users/nsantos/Qt/6.4.1/macos_static/plugins/imageformats/libqtiff_debug.a'
>> clang: error: no such file or directory: 
>> '/Users/nsantos/Qt/6.4.1/macos_static/plugins/imageformats/libqwbmp_debug.a'
>> clang: error: no such file or directory: 
>> '/Users/nsantos/Qt/6.4.1/macos_static/plugins/imageformats/libqwebp_debug.a'
>> clang: error: no such file or directory: 
>> '/Users/nsantos/Qt/6.4.1/macos_static/./qml/QtQml/objects-Debug/Qml_resources_1/.rcc/qrc_qmake_QtQml.cpp.o'
>> clang: error: no such file or directory: 
>> '/Users/nsantos/Qt/6.4.1/macos_static/plugins/qmltooling/libqmldbg_debugger_debug.a'
>> clang: error: no such file or directory: 
>> '/Users/nsantos/Qt/6.4.1/macos_static/./qml/QtQuick/objects-Debug/Quick_resources_1/.

[Interest] Qt 6.4.1 static - Missing some debug objects when using a static build kit?

2022-12-08 Thread Nuno Santos
Hi,

I’ve built Qt 6.4.1 from the source and when compiling an existing project in 
debug the following symbols are missing.

However, if I build the same project in release, everything is fine, not a 
single error.

In order to build the kit I have used the following configuration:

perl init-repository 
--module-subset=qt5compat,qtbase,qtdeclarative,qtimageformats,qtmultimedia,qtshadertools,qtsvg,qtwebsockets
./configure -prefix /Users/nsantos/Qt/6.4.1/macos_static -static 
-debug-and-release -nomake examples -nomake tests -nomake benchmarks -nomake 
manual-tests -nomake minimal-static-tests -openssl-linked -- 
-DOPENSSL_ROOT_DIR="/Users/nsantos/Qt-Utils/openssl" 
-DOPENSSL_USE_STATIC_LIBS=TRUE

clang: error: no such file or directory: 
'/Users/nsantos/Qt/6.4.1/macos_static/lib/objects-Debug/Widgets_resources_1/.rcc/qrc_qstyle.cpp.o'
clang: error: no such file or directory: 
'/Users/nsantos/Qt/6.4.1/macos_static/lib/objects-Debug/Widgets_resources_2/.rcc/qrc_qstyle1.cpp.o'
clang: error: no such file or directory: 
'/Users/nsantos/Qt/6.4.1/macos_static/lib/objects-Debug/Widgets_resources_3/.rcc/qrc_qmessagebox.cpp.o'
clang: error: no such file or directory: 
'/Users/nsantos/Qt/6.4.1/macos_static/lib/objects-Debug/Gui_resources_1/.rcc/qrc_qpdf.cpp.o'
clang: error: no such file or directory: 
'/Users/nsantos/Qt/6.4.1/macos_static/lib/objects-Debug/Gui_resources_2/.rcc/qrc_gui_shaders.cpp.o'
clang: error: no such file or directory: 
'/Users/nsantos/Qt/6.4.1/macos_static/plugins/styles/libqmacstyle_debug.a'
clang: error: no such file or directory: 
'/Users/nsantos/Qt/6.4.1/macos_static/lib/objects-Debug/QCocoaIntegrationPlugin_resources_1/.rcc/qrc_qcocoaresources.cpp.o'
clang: error: no such file or directory: 
'/Users/nsantos/Qt/6.4.1/macos_static/plugins/platforms/libqcocoa_debug.a'
clang: error: no such file or directory: 
'/Users/nsantos/Qt/6.4.1/macos_static/plugins/iconengines/libqsvgicon_debug.a'
clang: error: no such file or directory: 
'/Users/nsantos/Qt/6.4.1/macos_static/plugins/imageformats/libqgif_debug.a'
clang: error: no such file or directory: 
'/Users/nsantos/Qt/6.4.1/macos_static/plugins/imageformats/libqicns_debug.a'
clang: error: no such file or directory: 
'/Users/nsantos/Qt/6.4.1/macos_static/plugins/imageformats/libqico_debug.a'
clang: error: no such file or directory: 
'/Users/nsantos/Qt/6.4.1/macos_static/plugins/imageformats/libqjpeg_debug.a'
clang: error: no such file or directory: 
'/Users/nsantos/Qt/6.4.1/macos_static/lib/libQt6BundledLibjpeg_debug.a'
clang: error: no such file or directory: 
'/Users/nsantos/Qt/6.4.1/macos_static/plugins/imageformats/libqmacheif_debug.a'
clang: error: no such file or directory: 
'/Users/nsantos/Qt/6.4.1/macos_static/plugins/imageformats/libqmacjp2_debug.a'
clang: error: no such file or directory: 
'/Users/nsantos/Qt/6.4.1/macos_static/plugins/imageformats/libqsvg_debug.a'
clang: error: no such file or directory: 
'/Users/nsantos/Qt/6.4.1/macos_static/lib/libQt6Svg_debug.a'
clang: error: no such file or directory: 
'/Users/nsantos/Qt/6.4.1/macos_static/plugins/imageformats/libqtga_debug.a'
clang: error: no such file or directory: 
'/Users/nsantos/Qt/6.4.1/macos_static/plugins/imageformats/libqtiff_debug.a'
clang: error: no such file or directory: 
'/Users/nsantos/Qt/6.4.1/macos_static/plugins/imageformats/libqwbmp_debug.a'
clang: error: no such file or directory: 
'/Users/nsantos/Qt/6.4.1/macos_static/plugins/imageformats/libqwebp_debug.a'
clang: error: no such file or directory: 
'/Users/nsantos/Qt/6.4.1/macos_static/./qml/QtQml/objects-Debug/Qml_resources_1/.rcc/qrc_qmake_QtQml.cpp.o'
clang: error: no such file or directory: 
'/Users/nsantos/Qt/6.4.1/macos_static/plugins/qmltooling/libqmldbg_debugger_debug.a'
clang: error: no such file or directory: 
'/Users/nsantos/Qt/6.4.1/macos_static/./qml/QtQuick/objects-Debug/Quick_resources_1/.rcc/qrc_qmake_QtQuick.cpp.o'
clang: error: no such file or directory: 
'/Users/nsantos/Qt/6.4.1/macos_static/lib/objects-Debug/Quick_resources_2/.rcc/qrc_scenegraph_shaders.cpp.o'
clang: error: no such file or directory: 
'/Users/nsantos/Qt/6.4.1/macos_static/./qml/QtQml/Models/objects-Debug/QmlModels_resources_1/.rcc/qrc_qmake_QtQml_Models.cpp.o'
clang: error: no such file or directory: 
'/Users/nsantos/Qt/6.4.1/macos_static/plugins/qmltooling/libqmldbg_inspector_debug.a'
clang: error: no such file or directory: 
'/Users/nsantos/Qt/6.4.1/macos_static/plugins/qmltooling/libqmldbg_local_debug.a'
clang: error: no such file or directory: 
'/Users/nsantos/Qt/6.4.1/macos_static/plugins/qmltooling/libqmldbg_messages_debug.a'
clang: error: no such file or directory: 
'/Users/nsantos/Qt/6.4.1/macos_static/plugins/qmltooling/libqmldbg_native_debug.a'
clang: error: no such file or directory: 
'/Users/nsantos/Qt/6.4.1/macos_static/plugins/qmltooling/libqmldbg_nativedebugger_debug.a'
clang: error: no such file or directory: 
'/Users/nsantos/Qt/6.4.1/macos_static/plugins/qmltooling/libqmldbg_preview_debug.a'
clang: error: no 

Re: [Interest] Qt6 - Fails to compile when openssl-linked enabled

2022-12-08 Thread Nuno Santos
Marten,

I’ve noticed the nuance yesterday and tried but there was an error but I didn’t 
read the output correctly. I had a typo in a second define, 
OPENSSL_USE_STATIC_LIBS, which needed to be set to true. The following 
configure line worked:

./configure -prefix /Users/nsantos/Qt/6.4.1/macos_static -static 
-debug-and-release -nomake examples -nomake tests -nomake benchmarks -nomake 
manual-tests -nomake minimal-static-tests -openssl-linked -- 
-DOPENSSL_ROOT_DIR="/Users/nsantos/Qt-Utils/openssl" 
-DOPENSSL_USE_STATIC_LIBS=TRUE

Thiago, using openssl linked on Mac was a decision I have made a many years ago 
and I can’t remember the reason. Maybe it is not a good decision anymore. I 
know Apple has its SecureTransport framework. I might need to evaluate it again.

Thanks!

Regards,

Nuno

> On 8 Dec 2022, at 08:49, Mårten Nordheim  wrote:
> 
> The parameters to cmake (-D*) must be passed after a separating double dash 
> (--).
>  
> So, this:
> -openssl-linked -DOPENSSL_ROOT_DIR="…"
>  
> Should be like:
> -openssl-linked -- -DOPENSSL_ROOT_DIR="…"
>  
> Mårten
>  
> From: Nuno Santos  
> Sent: onsdag 7. desember 2022 17:40
> To: Mårten Nordheim 
> Cc: Qt Interest 
> Subject: Re: [Interest] Qt6 - Fails to compile when openssl-linked enabled
>  
> Marten,
>  
> Tried again without success. Maybe it's the directory layout. I don’t know 
> I’m in the dark since the the CMakeOutput.log and CMakeError.log do not even 
> mention ssl anywhere. Below is the new configure call:
>  
> ./configure -prefix /Users/nsantos/Qt/6.4.2/macos -static -debug-and-release 
> -nomake examples -nomake tests -nomake benchmarks -nomake manual-tests 
> -nomake minimal-static-tests -openssl-linked 
> -DOPENSSL_ROOT_DIR="/Users/nsantos/Qt-Utils/openssl" -DOPENSSL_USE_STATIC_LIBS
>  
> Where:
>  
> > find /Users/nsantos/Qt-Utils/openssl
> 
> 
> gives:
>  
> /Users/nsantos/Qt-Utils/openssl
> /Users/nsantos/Qt-Utils/openssl/include
> /Users/nsantos/Qt-Utils/openssl/include/crypto
> /Users/nsantos/Qt-Utils/openssl/include/crypto/md32_common.h
> …
> /Users/nsantos/Qt-Utils/openssl/lib
> /Users/nsantos/Qt-Utils/openssl/lib/libcrypto.a
> /Users/nsantos/Qt-Utils/openssl/lib/libssl.a
>  
> Where can I find more information?
>  
> Thank you!
>  
> Best regards,
>  
> Nuno
> 
> 
> On 7 Dec 2022, at 13:50, Mårten Nordheim  <mailto:marten.nordh...@qt.io>> wrote:
>  
> Ah, I don’t think OPENSSL_LIBS is in use anymore!
> I think it was still left printed at the end of configure, I’m not sure the 
> change removing it was merged into 6.4.
> Please use the FindOpenSSL cmake find-module variables: 
> https://cmake.org/cmake/help/latest/module/FindOpenSSL.html 
> <https://cmake.org/cmake/help/latest/module/FindOpenSSL.html>
> In your case, passing -DOPENSSL_ROOT_DIR="/Users/nsantos/Qt-Utils/openssl"
> at the end of your configure line, something like this:
>  
> ./configure -prefix …. -openssl-linked -- -DOPENSSL_ROOT_DIR="…"
>  
> Mårten
>  
> From: Nuno Santos  <mailto:nuno.san...@imaginando.pt>> 
> Sent: onsdag 7. desember 2022 14:01
> To: Mårten Nordheim mailto:marten.nordh...@qt.io>>
> Cc: Qt Interest mailto:interest@qt-project.org>>
> Subject: Re: [Interest] Qt6 - Fails to compile when openssl-linked enabled
>  
> Marten,
>  
> Thank you for your reply.
>  
> Yes the patch required? My configure line was:
>  
> ./configure -prefix /Users/nsantos/Qt/6.4.2/macos -static -debug-and-release 
> -nomake examples -nomake tests -nomake benchmarks -nomake manual-tests 
> -nomake minimal-static-tests -openssl-linked 
> -I/Users/nsantos/Qt-Utils/openssl/include 
> OPENSSL_LIBS="/Users/nsantos/Qt-Utils/openssl/lib/libssl.a 
> /Users/nsantos/Qt-Utils/openssl/lib/libcrypto.a”
>  
> Best,
>  
> Nuno
> 
> 
> 
> On 7 Dec 2022, at 11:59, Mårten Nordheim  <mailto:marten.nordh...@qt.io>> wrote:
>  
> [Reply is inline]
> 
> 
> 
> -Original Message-
> From: Nuno Santos  <mailto:nuno.san...@imaginando.pt>>
> Sent: onsdag 7. desember 2022 11:50
> To: Mårten Nordheim mailto:marten.nordh...@qt.io>>
> Cc: Qt Interest mailto:interest@qt-project.org>>
> Subject: Re: [Interest] Qt6 - Fails to compile when openssl-linked enabled
> 
> Marten,
> 
> Thanks for your reply.
> 
> I’m on branch 6.4.2 and before any configure I always call:
> 
> git submodule foreach --recursive "git clean -dfx" && git clean -dfx
> 
> Should I try with another branch?
> 
> No, it shouldn't be needed. I just configured 6.4 branch locally and it
> works fine. With only 
> https://co

Re: [Interest] Qt6 - Fails to compile when openssl-linked enabled

2022-12-07 Thread Nuno Santos
Marten,

Tried again without success. Maybe it's the directory layout. I don’t know I’m 
in the dark since the the CMakeOutput.log and CMakeError.log do not even 
mention ssl anywhere. Below is the new configure call:

./configure -prefix /Users/nsantos/Qt/6.4.2/macos -static -debug-and-release 
-nomake examples -nomake tests -nomake benchmarks -nomake manual-tests -nomake 
minimal-static-tests -openssl-linked 
-DOPENSSL_ROOT_DIR="/Users/nsantos/Qt-Utils/openssl" -DOPENSSL_USE_STATIC_LIBS

Where:

> find /Users/nsantos/Qt-Utils/openssl

gives:

/Users/nsantos/Qt-Utils/openssl
/Users/nsantos/Qt-Utils/openssl/include
/Users/nsantos/Qt-Utils/openssl/include/crypto
/Users/nsantos/Qt-Utils/openssl/include/crypto/md32_common.h
…
/Users/nsantos/Qt-Utils/openssl/lib
/Users/nsantos/Qt-Utils/openssl/lib/libcrypto.a
/Users/nsantos/Qt-Utils/openssl/lib/libssl.a

Where can I find more information?

Thank you!

Best regards,

Nuno

> On 7 Dec 2022, at 13:50, Mårten Nordheim  wrote:
> 
> Ah, I don’t think OPENSSL_LIBS is in use anymore!
> I think it was still left printed at the end of configure, I’m not sure the 
> change removing it was merged into 6.4.
> Please use the FindOpenSSL cmake find-module variables: 
> https://cmake.org/cmake/help/latest/module/FindOpenSSL.html 
> <https://cmake.org/cmake/help/latest/module/FindOpenSSL.html>
> In your case, passing -DOPENSSL_ROOT_DIR="/Users/nsantos/Qt-Utils/openssl"
> at the end of your configure line, something like this:
>  
> ./configure -prefix …. -openssl-linked -- -DOPENSSL_ROOT_DIR="…"
>  
> Mårten
>  
> From: Nuno Santos  
> Sent: onsdag 7. desember 2022 14:01
> To: Mårten Nordheim 
> Cc: Qt Interest 
> Subject: Re: [Interest] Qt6 - Fails to compile when openssl-linked enabled
>  
> Marten,
>  
> Thank you for your reply.
>  
> Yes the patch required? My configure line was:
>  
> ./configure -prefix /Users/nsantos/Qt/6.4.2/macos -static -debug-and-release 
> -nomake examples -nomake tests -nomake benchmarks -nomake manual-tests 
> -nomake minimal-static-tests -openssl-linked 
> -I/Users/nsantos/Qt-Utils/openssl/include 
> OPENSSL_LIBS="/Users/nsantos/Qt-Utils/openssl/lib/libssl.a 
> /Users/nsantos/Qt-Utils/openssl/lib/libcrypto.a”
>  
> Best,
>  
> Nuno
> 
> 
> On 7 Dec 2022, at 11:59, Mårten Nordheim  <mailto:marten.nordh...@qt.io>> wrote:
>  
> [Reply is inline]
> 
> 
> -Original Message-
> From: Nuno Santos  <mailto:nuno.san...@imaginando.pt>>
> Sent: onsdag 7. desember 2022 11:50
> To: Mårten Nordheim mailto:marten.nordh...@qt.io>>
> Cc: Qt Interest mailto:interest@qt-project.org>>
> Subject: Re: [Interest] Qt6 - Fails to compile when openssl-linked enabled
> 
> Marten,
> 
> Thanks for your reply.
> 
> I’m on branch 6.4.2 and before any configure I always call:
> 
> git submodule foreach --recursive "git clean -dfx" && git clean -dfx
> 
> Should I try with another branch?
> 
> No, it shouldn't be needed. I just configured 6.4 branch locally and it
> works fine. With only 
> https://codereview.qt-project.org/c/qt/qtbase/+/446542 
> <https://codereview.qt-project.org/c/qt/qtbase/+/446542>
> as the extra patch.
> I think this might indicate that the openssl compile test fails, which
> could disable the feature. But just to make sure; do you call configure
> like `../qt5/configure ... -openssl-linked` ?
> 
> 
> 
> Regards,
> 
> Nuno
> 
> 
> On 7 Dec 2022, at 09:45, Mårten Nordheim  <mailto:marten.nordh...@qt.io>>
> wrote:
> 
> 
> Hey,
> 
> If this is a clean build I need to know which branch you are building.
> If not then you could try deleting CMakeCache.txt and reconfiguring,
> there were some changes around configuration of openssl recently
> which may be conflicting with values in the cache.
> 
> Mårten
> 
> 
> -Original Message-
> From: Interest  <mailto:interest-boun...@qt-project.org>> On Behalf Of Nuno
> Santos
> Sent: onsdag 7. desember 2022 10:28
> To: Qt Interest mailto:interest@qt-project.org>>
> Subject: [Interest] Qt6 - Fails to compile when openssl-linked enabled
> 
> Hi,
> 
> I’m trying to compile Qt 6 with openssl-linked but I’m having this error and
> I’m not being able to interpret it.
> 
> What is failing? Can you please help me here?
> 
> Thanks in advance!
> 
> Regards,
> 
> Nuno
> 
> 
> Configuring submodule 'qtbase'
> CMake Error at qtbase/cmake/QtBuildInformation.cmake:490 (message):
> Feature "openssl": Forcing to "ON" breaks its condition:
> 
> QT_FEATURE_openssl_runtime OR QT_FEATURE_openssl_linked
> 
> Condition va

Re: [Interest] Qt6 - Fails to compile when openssl-linked enabled

2022-12-07 Thread Nuno Santos
Marten,

Thank you for your reply.

Yes the patch required? My configure line was:

./configure -prefix /Users/nsantos/Qt/6.4.2/macos -static -debug-and-release 
-nomake examples -nomake tests -nomake benchmarks -nomake manual-tests -nomake 
minimal-static-tests -openssl-linked -I/Users/nsantos/Qt-Utils/openssl/include 
OPENSSL_LIBS="/Users/nsantos/Qt-Utils/openssl/lib/libssl.a 
/Users/nsantos/Qt-Utils/openssl/lib/libcrypto.a”

Best,

Nuno

> On 7 Dec 2022, at 11:59, Mårten Nordheim  wrote:
> 
> [Reply is inline]
> 
>> -Original Message-----
>> From: Nuno Santos 
>> Sent: onsdag 7. desember 2022 11:50
>> To: Mårten Nordheim 
>> Cc: Qt Interest 
>> Subject: Re: [Interest] Qt6 - Fails to compile when openssl-linked enabled
>> 
>> Marten,
>> 
>> Thanks for your reply.
>> 
>> I’m on branch 6.4.2 and before any configure I always call:
>> 
>> git submodule foreach --recursive "git clean -dfx" && git clean -dfx
>> 
>> Should I try with another branch?
> 
> No, it shouldn't be needed. I just configured 6.4 branch locally and it
> works fine. With only 
> https://codereview.qt-project.org/c/qt/qtbase/+/446542 
> <https://codereview.qt-project.org/c/qt/qtbase/+/446542>
> as the extra patch.
> I think this might indicate that the openssl compile test fails, which
> could disable the feature. But just to make sure; do you call configure
> like `../qt5/configure ... -openssl-linked` ?
> 
>> 
>> Regards,
>> 
>> Nuno
>> 
>>> On 7 Dec 2022, at 09:45, Mårten Nordheim 
>> wrote:
>>> 
>>> Hey,
>>> 
>>> If this is a clean build I need to know which branch you are building.
>>> If not then you could try deleting CMakeCache.txt and reconfiguring,
>>> there were some changes around configuration of openssl recently
>>> which may be conflicting with values in the cache.
>>> 
>>> Mårten
>>> 
>>>> -Original Message-
>>>> From: Interest  On Behalf Of Nuno
>>>> Santos
>>>> Sent: onsdag 7. desember 2022 10:28
>>>> To: Qt Interest 
>>>> Subject: [Interest] Qt6 - Fails to compile when openssl-linked enabled
>>>> 
>>>> Hi,
>>>> 
>>>> I’m trying to compile Qt 6 with openssl-linked but I’m having this error 
>>>> and
>>>> I’m not being able to interpret it.
>>>> 
>>>> What is failing? Can you please help me here?
>>>> 
>>>> Thanks in advance!
>>>> 
>>>> Regards,
>>>> 
>>>> Nuno
>>>> 
>>>> 
>>>> Configuring submodule 'qtbase'
>>>> CMake Error at qtbase/cmake/QtBuildInformation.cmake:490 (message):
>>>> Feature "openssl": Forcing to "ON" breaks its condition:
>>>> 
>>>> QT_FEATURE_openssl_runtime OR QT_FEATURE_openssl_linked
>>>> 
>>>> Condition values dump:
>>>> 
>>>> QT_FEATURE_openssl_runtime = "OFF"
>>>> QT_FEATURE_openssl_linked = "OFF"
>>>> 
>>>> Call Stack (most recent call first):
>>>> qtbase/cmake/QtFeature.cmake:281 (qt_configure_add_report_error)
>>>> qtbase/cmake/QtFeature.cmake:403
>>>> (qt_feature_check_and_save_internal_value)
>>>> qtbase/cmake/QtFeature.cmake:155 (qt_evaluate_feature)
>>>> qtbase/cmake/QtFeature.cmake:349 (qt_evaluate_config_expression)
>>>> qtbase/cmake/QtFeature.cmake:606 (qt_evaluate_feature)
>>>> qtbase/cmake/QtFeature.cmake:575 (qt_feature_module_end)
>>>> qtbase/src/CMakeLists.txt:9 (qt_feature_evaluate_features)
>>>> 
>>>> 
>>>> -- Could NOT find md4c (missing: md4c_DIR)
>>>> -- Could NOT find md4c (missing: md4c_DIR)
>>>> CMake Error at qtbase/cmake/QtTargetHelpers.cmake:832 (message):
>>>> WrapOpenSSLHeaders::WrapOpenSSLHeaders is not a valid target.
>>>> Call Stack (most recent call first):
>>>> qtbase/src/plugins/tls/openssl/CMakeLists.txt:54
>>>> (qt_internal_add_target_include_dirs)
>>>> 
>>>> 
>>>> -- Configuring incomplete, errors occurred!
>>>> ___
>>>> 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] Qt6 - Fails to compile when openssl-linked enabled

2022-12-07 Thread Nuno Santos
Marten,

Thanks for your reply.

I’m on branch 6.4.2 and before any configure I always call:

git submodule foreach --recursive "git clean -dfx" && git clean -dfx

Should I try with another branch?

Regards,

Nuno

> On 7 Dec 2022, at 09:45, Mårten Nordheim  wrote:
> 
> Hey,
> 
> If this is a clean build I need to know which branch you are building.
> If not then you could try deleting CMakeCache.txt and reconfiguring,
> there were some changes around configuration of openssl recently
> which may be conflicting with values in the cache.
> 
> Mårten
> 
>> -----Original Message-
>> From: Interest  On Behalf Of Nuno
>> Santos
>> Sent: onsdag 7. desember 2022 10:28
>> To: Qt Interest 
>> Subject: [Interest] Qt6 - Fails to compile when openssl-linked enabled
>> 
>> Hi,
>> 
>> I’m trying to compile Qt 6 with openssl-linked but I’m having this error and
>> I’m not being able to interpret it.
>> 
>> What is failing? Can you please help me here?
>> 
>> Thanks in advance!
>> 
>> Regards,
>> 
>> Nuno
>> 
>> 
>> Configuring submodule 'qtbase'
>> CMake Error at qtbase/cmake/QtBuildInformation.cmake:490 (message):
>>  Feature "openssl": Forcing to "ON" breaks its condition:
>> 
>>  QT_FEATURE_openssl_runtime OR QT_FEATURE_openssl_linked
>> 
>>  Condition values dump:
>> 
>>  QT_FEATURE_openssl_runtime = "OFF"
>>  QT_FEATURE_openssl_linked = "OFF"
>> 
>> Call Stack (most recent call first):
>>  qtbase/cmake/QtFeature.cmake:281 (qt_configure_add_report_error)
>>  qtbase/cmake/QtFeature.cmake:403
>> (qt_feature_check_and_save_internal_value)
>>  qtbase/cmake/QtFeature.cmake:155 (qt_evaluate_feature)
>>  qtbase/cmake/QtFeature.cmake:349 (qt_evaluate_config_expression)
>>  qtbase/cmake/QtFeature.cmake:606 (qt_evaluate_feature)
>>  qtbase/cmake/QtFeature.cmake:575 (qt_feature_module_end)
>>  qtbase/src/CMakeLists.txt:9 (qt_feature_evaluate_features)
>> 
>> 
>> -- Could NOT find md4c (missing: md4c_DIR)
>> -- Could NOT find md4c (missing: md4c_DIR)
>> CMake Error at qtbase/cmake/QtTargetHelpers.cmake:832 (message):
>>  WrapOpenSSLHeaders::WrapOpenSSLHeaders is not a valid target.
>> Call Stack (most recent call first):
>>  qtbase/src/plugins/tls/openssl/CMakeLists.txt:54
>> (qt_internal_add_target_include_dirs)
>> 
>> 
>> -- Configuring incomplete, errors occurred!
>> ___
>> 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] Qt6 - Fails to compile when openssl-linked enabled

2022-12-07 Thread Nuno Santos
Hi,

I’m trying to compile Qt 6 with openssl-linked but I’m having this error and 
I’m not being able to interpret it. 

What is failing? Can you please help me here?

Thanks in advance!

Regards,

Nuno


Configuring submodule 'qtbase'
CMake Error at qtbase/cmake/QtBuildInformation.cmake:490 (message):
  Feature "openssl": Forcing to "ON" breaks its condition:

  QT_FEATURE_openssl_runtime OR QT_FEATURE_openssl_linked

  Condition values dump:

  QT_FEATURE_openssl_runtime = "OFF"
  QT_FEATURE_openssl_linked = "OFF"

Call Stack (most recent call first):
  qtbase/cmake/QtFeature.cmake:281 (qt_configure_add_report_error)
  qtbase/cmake/QtFeature.cmake:403 (qt_feature_check_and_save_internal_value)
  qtbase/cmake/QtFeature.cmake:155 (qt_evaluate_feature)
  qtbase/cmake/QtFeature.cmake:349 (qt_evaluate_config_expression)
  qtbase/cmake/QtFeature.cmake:606 (qt_evaluate_feature)
  qtbase/cmake/QtFeature.cmake:575 (qt_feature_module_end)
  qtbase/src/CMakeLists.txt:9 (qt_feature_evaluate_features)


-- Could NOT find md4c (missing: md4c_DIR)
-- Could NOT find md4c (missing: md4c_DIR)
CMake Error at qtbase/cmake/QtTargetHelpers.cmake:832 (message):
  WrapOpenSSLHeaders::WrapOpenSSLHeaders is not a valid target.
Call Stack (most recent call first):
  qtbase/src/plugins/tls/openssl/CMakeLists.txt:54 
(qt_internal_add_target_include_dirs)


-- Configuring incomplete, errors occurred!
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] Qt iOS and installEventFilter

2022-11-08 Thread Nuno Santos
Tor,

Thanks for your reply.

I find the way qml keyboard handling works very fiddly or I simply don’t 
understand how it is supposed to work.

Let’s say I put some keyboard events being handled on the main window, then if 
another elements gets focus I don’t intercept keyboard events anymore. 

Having a global way of intercepting keyboard events also brings another 
challenges. For instance, in my case (a music app), I want to be able to use 
the keyboard to play the instrument but if the users wants to save a preset he 
will need to type the name of the preset and I don’t want the instrument to 
play in that case.

Focus of qml elements is probably the thing that confuses me the most. It is 
very hard to work with. Sometimes we have focus on an element but 
clicking/tapping outside of it does not take the focus out of it just like in a 
webpage. 

Best,

Nuno

> On 8 Nov 2022, at 12:10, Tor Arne Vestbø  wrote:
> 
> Hi,
> 
> Verify that the keyboard events are coming in as expected in [QUIView 
> handlePresses:evenType:]
> 
> If that’s the case, the reason they are being filtered out as key events is 
> because they are being sent as input method events to the focus object.
> 
> The iOS platform plugin doesn’t seem to implement the filterNativeEvent 
> machinery. I’ve filed https://bugreports.qt.io/browse/QTBUG-108268 
> <https://bugreports.qt.io/browse/QTBUG-108268> for that
> 
> Cheers,
> Tor Arne
> 
>> On 8 Nov 2022, at 11:58, Nuno Santos > <mailto:nuno.san...@imaginando.pt>> wrote:
>> 
>> Hi,
>> 
>> I’m trying to find a way of intercepting keyboard events in a global and 
>> cross platform way. I don’t want this to be tied to certain element in Qml. 
>> I really want to have a global way of catching the keyboard events.
>> 
>> I have created an event filter and added this event filter to the QWindow. 
>> While this approach works on Desktop, it does not seem to work for iOS. 
>> There are events being catched on the event filter but none of those events 
>> are keyboard events. I have also event tried to install a nativeEventFilter 
>> on the QApplication but that also didn’t work.
>> 
>> Is there a way to do this on iOS?
>> 
>> Thanks!
>> 
>> Regards,
>> 
>> Nuno
>> 
>> 
>> 
>> ___
>> Interest mailing list
>> Interest@qt-project.org <mailto: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] Qt iOS and installEventFilter

2022-11-08 Thread Nuno Santos
Hi,

I’m trying to find a way of intercepting keyboard events in a global and cross 
platform way. I don’t want this to be tied to certain element in Qml. I really 
want to have a global way of catching the keyboard events.

I have created an event filter and added this event filter to the QWindow. 
While this approach works on Desktop, it does not seem to work for iOS. There 
are events being catched on the event filter but none of those events are 
keyboard events. I have also event tried to install a nativeEventFilter on the 
QApplication but that also didn’t work.

Is there a way to do this on iOS?

Thanks!

Regards,

Nuno



___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


[Interest] Massive flickering while resizing Qt Quick application while resizing the window (Windows only)

2022-07-18 Thread Nuno Santos
Hi,

I have never realised until today that there is a massive flickering when 
resizing a Qt Quick application window.

This happens even with the minimal Qt Quick application template. When doing 
the resize on a complex application it looks like rubbish.

There is a massive amount of flickering bug reports open for this topic.

I’m currently using Qt 5.15.9 but it seems this is still an issue on Qt 6.X

Is this a well know issue? 

How can we deploy professional applications with such behaviour? 

Thanks!

Regards,

Nuno


___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


[Interest] Qt Android - Targeting API 29 (Android 10): How to write to a non scoped location that is visible to the user via generic Files app?

2022-05-13 Thread Nuno Santos
Hi,

I’m having an hard time figuring out how to write files from a Qt Android app, 
to a location that is public to the user, outside of the scoped storage.

I’m currently using Qt 5.15.9 and targeting API 29 (Android 10). I have set in 
my manifest requestLegacyExternalStorage=true

And then I have tried to write a dummy file to the following StandardLocations:

DesktopLocation - "/data/user/0/com.acme.org/files/test_file.txt"
DocumentsLocation - 
"/storage/emulated/0/Android/data/com.acme.org/files/Documents/test_file.txt"
MusicLocation - 
"/storage/emulated/0/Android/data/com.acme.org/files/Music/test_file.txt"
PicturesLocation - 
"/storage/emulated/0/Android/data/com.acme.org/files/Pictures/test_file.txt"
HomeLocation - "/data/user/0/com.acme.org/files/test_file.txt"
GenericDataLocation - 
"/storage/emulated/0/Android/data/com.acme.org/files/test_file.txt"
DownloadLocation - 
"/storage/emulated/0/Android/data/com.acme.org/files/Download/test_file.txt"
GenericCacheLocation - "/data/user/0/com.acme.org/cache/test_file.txt”

Then, with the files app I try to find any of the files without success… :(

How do we write to public files to public locations, outside the scoped 
storage? Is it currently possible? 

Thanks in advance!

Nuno


___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] QtQuick on desktop cannot select from available GPUs.

2022-05-06 Thread Nuno Santos
Hi,

I don’t think you will ever be able to do it from Qt. I might be wrong though….

On Windows, you need to use Windows to set that preference: 
https://www.itechtics.com/use-specific-gpu/ 


There is another possible way which is setting a piece of code which will do 
the trick:

#ifdef Q_OS_WIN
extern "C"
{
__declspec(dllexport) unsigned long NvOptimusEnablement = 0x0001; // 
for NVIDIA
}

extern "C"
{
__declspec(dllexport) int AmdPowerXpressRequestHighPerformance = 1; // for 
AMD
}
#endif

Since you have an AMD and a NVIDIA, I don’t know how it will behave in that 
case… :/

Best regards,

Nuno

> On 6 May 2022, at 04:33, 乔燊 <1500013...@pku.edu.cn> wrote:
> 
> It seems that there are no appropriate functions that can set the GPU used by 
> QQuickWindow/QQuickView.
> 
> 
> 
> I'm using qt6.3 on windows11. I have two graphics card on my laptop:
> 
> 
> Device name: AMD Radeon(TM) Graphics
> Device type: integrated
> Device name: NVIDIA GeForce RTX 3060 Laptop GPU
> Device type: discrete
> I tried to use vulkan by calling QQuickView::setGraphicsApi, but found 
> nowhere to set GPU to use. Meanwhile the widget class QVulkanWindow gives us 
> a convenient function QVulkanWindow::setPhysicalDeviceIndex for doing this. 
> 
> 
> 
> Perhaps the setting up with class QQuickRenderControl is possible, but there 
> is too much stuff to take care of for merely selecting a GPU device. I 
> thought it would be a common demand for all desktop developer, not only those 
> using Vulkan.
> 
> 
> 
> Is there any plan on adding related function to select from GPUs? Or maybe 
> there is another already-exist solution for that?
> 
> ___
> 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] QtCreator >= 6 - Problems using code indentation shift with tab key

2022-04-15 Thread Nuno Santos
Cool! Thanks!

Just up voted it.

Best,

Nuno

> On 15 Apr 2022, at 14:42, Sze Howe Koh  wrote:
> 
> On Fri, 15 Apr 2022 at 15:02, André Pönitz  wrote:
>> 
>> On Fri, Apr 15, 2022 at 06:28:34AM +0100, Nuno Santos wrote:
>>> Kevin,
>>> 
>>> Thanks for your feedback.
>>> 
>>> Is anyone from the Qt Creator team around and aware of this? Is this a new
>>> setting? A bug? A feature?
>>> 
>>> Should we open bug report?
>> 
>> That would probably be the best approach.
>> 
>> Andre'
> 
> Someone already did: https://bugreports.qt.io/browse/QTCREATORBUG-27365
> 
> 
> Regards,
> Sze-Howe

___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] QtCreator >= 6 - Problems using code indentation shift with tab key

2022-04-14 Thread Nuno Santos
Kevin,

Thanks for your feedback.

Is anyone from the Qt Creator team around and aware of this? Is this a new 
setting? A bug? A feature?

Should we open bug report?

Thanks!

Nuno

> On 14 Apr 2022, at 23:14, Kevin André  wrote:
> 
> Hi,
> 
> Op wo 13 apr. 2022 om 17:26 schreef Nuno Santos :
>> Since Qt Creator 6.0 I’m unable to indent shit code with tab more than one 
>> time. After one indentation with tab, code gets deselected. This happens 
>> with shift+tab as well.
>> 
>> Is anyone else having the same problem? Is this some kind of non default 
>> behaviour that changed?
> 
> I can confirm this. It happens when more than one line is selected and
> shift-tab is used to move those lines to the left. (Not sure if moving
> to the right has the same problem.) This is annoying when you want to
> change indentation with more than one level.
> 
> 
> Kevin

___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


[Interest] QtCreator >= 6 - Problems using code indentation shift with tab key

2022-04-13 Thread Nuno Santos
Hi,

Since Qt Creator 6.0 I’m unable to indent shit code with tab more than one 
time. After one indentation with tab, code gets deselected. This happens with 
shift+tab as well.

Is anyone else having the same problem? Is this some kind of non default 
behaviour that changed?

Thanks!

Nuno
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


[Interest] Qt Creator (6/7) Project Executable Run - Failed to launch /Applications/APP_NAME.app: Permission denied

2022-04-12 Thread Nuno Santos
Hi,

Since Qt Creator 6 that it seems impossible to launch an app selected as 
executable under project run settings.

Today I have updated to Qt Creator 7 and the problems seems to persist.

When I launch the project, which is a plugin that will be loaded into an 
application, I get:

Failed to launch /Applications/APP_NAME.app: Permission denied

Is anyone else having this issue? What am I missing here?

Thanks!

Nuno
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


[Interest] [Qt iOS - QTBUG-101568] Application takes several seconds to become responsive depending on the number of items in scene

2022-04-12 Thread Nuno Santos
Hi,

I have a problem were all my apps take several seconds to become responsive. 
The more complex the app is, the more time it takes to get responsive to touch. 
This didn’t used to be this way.
I can easily demonstrate the issue happening with a simple example, which does 
not happen in Windows or Android, only iOS:

https://bugreports.qt.io/browse/QTBUG-101568 


Is anyone else having this issue?

I think this issue is particular severe for anyone who has complex applications 
on iOS.

Looking forward to hear the community thoughts about it.

Best,

Nuno___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] What is the minimum required macOS SDK to build Qt 5.15.9 with support for x86_64 and arm64?

2022-04-11 Thread Nuno Santos
Thank you Thiago!

> On 11 Apr 2022, at 20:51, Thiago Macieira  wrote:
> 
> On Monday, 11 April 2022 10:42:40 PDT Nuno Santos wrote:
>> My Mac build machine is still running mac OS Mojave 10.14.6 and Xcode 11.3.1
>> due to legacy requirements.
> 
> The SDK for 11.1 (available in XCode 12) has support for ARM:
> 
> /*
> * Architecture validation for current SDK
> */
> #if !defined(__sys_cdefs_arch_unknown__) && defined(__i386__)
> #elif !defined(__sys_cdefs_arch_unknown__) && defined(__x86_64__)
> #elif !defined(__sys_cdefs_arch_unknown__) && defined(__arm__)
> #elif !defined(__sys_cdefs_arch_unknown__) && defined(__arm64__)
> #else
> #error Unsupported architecture
> #endif
> 
> -- 
> 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


[Interest] What is the minimum required macOS SDK to build Qt 5.15.9 with support for x86_64 and arm64?

2022-04-11 Thread Nuno Santos
Hi,

I’m trying to build the latest Qt 5.15.9 with support for x86_64 and arm64:

./configure -confirm-license -recheck -platform macx-clang -device-option 
QMAKE_APPLE_DEVICE_ARCHS="x86_64 arm64" -commercial -debug-and-release -static 
-nomake examples -nomake tests -opengl desktop -no-securetransport

My Mac build machine is still running mac OS Mojave 10.14.6 and Xcode 11.3.1 
due to legacy requirements.

The compilation failed with many errors, this is the first:

/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang
 -c -pipe -Xarch_arm64 -DPCRE2_DISABLE_JIT -g -fPIC -std=gnu11  -arch x86_64  
-arch arm64 -isysroot 
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk
 -mmacosx-version-min=10.13 -fvisibility=hidden -w -fno-exceptions 
-DQT_NO_LINKED_LIST -DQT_NO_JAVA_STYLE_ITERATORS -DQT_COMPILER_SUPPORTS_SSE2 
-DQT_COMPILER_SUPPORTS_NEON -DPCRE2_CODE_UNIT_WIDTH=16 
-DQT_NO_NARROWING_CONVERSIONS_IN_CONNECT -DGL_SILENCE_DEPRECATION 
-DHAVE_CONFIG_H -DQT_NO_DYNAMIC_CAST -DQT_NO_EXCEPTIONS -D_LARGEFILE64_SOURCE 
-D_LARGEFILE_SOURCE -I. -Isrc -I/usr/local/Cellar/openssl@1.1/1.1.1m/include 
-I../../../mkspecs/macx-clang -o .obj/debug/pcre2_auto_possess.o 
src/pcre2_auto_possess.c
In file included from src/pcre2_auto_possess.c:50:
In file included from src/pcre2_internal.h:56:
In file included from 
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk/usr/include/ctype.h:69:
In file included from 
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk/usr/include/_ctype.h:69:
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk/usr/include/sys/cdefs.h:807:2:
 error: Unsupported architecture
#error Unsupported architecture

The Qt for macOS page -> https://doc.qt.io/qt-5/macos.html 
 says that we can build Qt 5.15.9 with Xcode 
11 but it is failing.

Does anyone knows what is the minimum macOS SDK to build Qt 5.15.9 with x86_64 
and arm64 support for universal builds? 

Thanks!

Nuno___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


[Interest] Is there a quick way of know how many quick items are presented in a quick scene graph?

2022-03-25 Thread Nuno Santos
Hi,

In order to optimize the number of items that are being instantiated within a 
qml interface I would like to know that number every time I run the app.

Is there any env var that allows this kind of debugging?

Thanks!

Nuno
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] Buod android minsdk

2022-02-10 Thread Nuno Santos
Phillipe,

I had the same problem recently.

Check qt creator project env vars.

--
Nuno Santos

> No dia 10/02/2022, às 19:47, maitai  escreveu:
> 
> 
> Hi,
> 
> I need to build a pure SDK/NDK30 android app. The reason for that is that 
> some static libs use functions not available in SDK/NDK21, for instance 
> stderr, stdout, and some other.
>  
> I have tried to set in pro file
> ANDROID_MIN_SDK_VERSION = 30
> 
> and also to modify  build.gradle, but linkage still shout about these 
> functions not defined
> 
> Thanks for any tip
> 
> --Philippe Lelong
> 
> 
> ___
> 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] Testing in-app purchases on a Qt Android app.

2022-02-02 Thread Nuno Santos
Hi,

This is a bit off topic but I’m looking for advice from other Qt for Android 
developers on how to test in-app purchases.

I had a stable purchasing experience for a long time and therefore there was no 
need for testing for a long time. But since Qt 5.15.8 has been released and I 
have released the first update I’m having issues with purchases so I need to 
debug the whole process.

The problem is that when I run the app in debug, deployed from Qt Creator to 
the device, I can’t seem to test in-app purchases. When I choose to purchase a 
in-app purchase I receive an error saying that: “This version of the 
application is not configured for billing through Google Play”. After googling 
I have found this stack over flow post:

https://stackoverflow.com/questions/11068686/this-version-of-the-application-is-not-configured-for-billing-through-google-pla
 


So, I have uploaded the apk to a alpha testing lane and published it but I’m 
still unable to test the in-app purchase. This is extremely cumbersome and 
intuitive…. :/


Is anyone able to test in-app purchases without having to upload a build to 
google play each time a modification is done?

Am I missing something here?

Thanks in advance!

Regards,

Nuno








___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] Qt Android: how to set __ANDROID_API__ ?

2022-01-31 Thread Nuno Santos
Alexander,

Thanks for your reply.

In the mean time I have discovered that I had to change ANDROID_NDK_PLATFORM 
env var to android-23. By default it was set to android-21.

Best regards,

Nuno

> On 25 Jan 2022, at 22:50, Alexander Dyagilev  wrote:
> 
> Sorry, forgot to say. As far as I know, the default value for Qt 5.x is:
> 
> ANDROID_NDK_PLATFORM=16
> 
> On 1/26/2022 1:48 AM, Alexander Dyagilev wrote:
>> Hello,
>> 
>> You need to define ANDROID_NDK_PLATFORM environment variable. You can do it 
>> by changing it in Qt Creator:
>> 
>> 
>> 
>> 
>> 
>> Or by changing using system's environment variables.
>> 
>> I use Qt 5.12 so I set it to ANDROID_NDK_PLATFORM=21.
>> 
>> For Qt 6.x, the default value (if not set by environment variable) is 
>> ANDROID_NDK_PLATFORM=23.
>> 
>> 
>> 
>> On 1/25/2022 2:57 PM, Nuno Santos wrote:
>>> Hi,
>>> 
>>> I’m trying to call get_nprocs which is defined on #include 
>>> 
>>> But it doesn’t get included because there is a macro making it available 
>>> only when __ANDROID_API__ is >= 23
>>> 
>>> Qt Creator installs by default NDK 21.3.6528147.
>>> 
>>> Is this something defined at the NDK level? Or is this something we can set 
>>> as a parameter somewhere, because I can’t find it… 
>>> 
>>> Thanks!
>>> 
>>> Nuno
>>> 
>>> 
>>> 
>>> 
>>> ___
>>> Interest mailing list
>>> Interest@qt-project.org <mailto:Interest@qt-project.org>
>>> https://lists.qt-project.org/listinfo/interest 
>>> <https://lists.qt-project.org/listinfo/interest>

___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


[Interest] Qt Android: how to set __ANDROID_API__ ?

2022-01-25 Thread Nuno Santos
Hi,

I’m trying to call get_nprocs which is defined on #include 

But it doesn’t get included because there is a macro making it available only 
when __ANDROID_API__ is >= 23

Qt Creator installs by default NDK 21.3.6528147.

Is this something defined at the NDK level? Or is this something we can set as 
a parameter somewhere, because I can’t find it… 

Thanks!

Nuno


___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


  1   2   3   4   5   6   7   8   9   >