-
Notifications
You must be signed in to change notification settings - Fork 19
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Qt 6.9 not compiling - QObjectData_dynamicMetaObject invalid conversion from const #194
Comments
Thanks for trying miqt! What OS + version of Qt do you have? |
It looks like
Miqt will need a small update in order to work with Qt 6.9. This can be easily fixed with genbindings/config-allowlist.go ApplyQuirks function to set the BecomesNonConstInVersion quirk for this method. |
This seems to be slightly more annoying to address: diff --git a/qt6/gen_qobject.cpp b/qt6/gen_qobject.cpp
index 7c2a5635..b57d1418 100644
--- a/qt6/gen_qobject.cpp
+++ b/qt6/gen_qobject.cpp
@@ -36,7 +36,7 @@ void miqt_exec_callback_QObject_disconnectNotify(QObject*, intptr_t, QMetaMethod
} /* extern C */
#endif
-QMetaObject* QObjectData_dynamicMetaObject(const QObjectData* self) {
+const QMetaObject* QObjectData_dynamicMetaObject(const QObjectData* self) {
return self->dynamicMetaObject();
}
diff --git a/qt6/gen_qobject.h b/qt6/gen_qobject.h
index 47606a20..2597e069 100644
--- a/qt6/gen_qobject.h
+++ b/qt6/gen_qobject.h
@@ -48,7 +48,7 @@ typedef struct QTimerEvent QTimerEvent;
typedef struct QVariant QVariant;
#endif
-QMetaObject* QObjectData_dynamicMetaObject(const QObjectData* self);
+const QMetaObject* QObjectData_dynamicMetaObject(const QObjectData* self);
void QObjectData_delete(QObjectData* self);
QObject* QObject_new(); The return type is now |
Feel free to assign this to me if you haven't started yet. I think I can get it done in an hour or two. Fortunately, this doesn't intersect with the existing const/non-const change. Once we start getting versions built against newer Qt bases, this should mitigate the issues. (And hopefully we don't need to deal with the intersection of these two... ever. 😅) |
@emad-elsaid Can you please try |
Thanks, I'll do that in the end of the day when I have access the machine |
@mappu I'm getting a different error:
|
This is something with how Qt 6 is packaged for Arch. See #150 for more details. There is a workaround for the QQmlWebChannel header but QSctpServer and QSctpSocket are missing from the Qt 6 Network packages for Arch. This seems to be intentional but maybe check with upstream to be sure? It would be great for Arch users if there could be a fix either here or upstream but this would be Arch-specific and not Linux-specific which makes a potential implementation more interesting. |
Seems like these classes have been missing in Arch Linux since at least 2019. A workaround would be to have genbindings move the two Sctp classes to a new subpackage, like was done with FYI @5k3105 |
Should this issue be closed in favor of #150 or a new issue? Could it be tied into #185?
These headers are also missing from FreeBSD just the same. I haven't looked into why yet. |
I see #199 is merged as a fix, but pulling master and retrying produce the same error, I made sure it's using the correct commit from go.sum
I'm in no rush for a solution, just making sure we're aware it's not solved yet. |
#199 is not merged yet. To try it early, run |
When trying to compile the webEngine example I'm getting an error:
my go.mod
The error I'm getting:
tried with dynamic linking:
The text was updated successfully, but these errors were encountered: