Skip to content
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

mtsgui compilation issue caused by qt5 #135

Open
liuyang12 opened this issue Jul 24, 2020 · 3 comments
Open

mtsgui compilation issue caused by qt5 #135

liuyang12 opened this issue Jul 24, 2020 · 3 comments

Comments

@liuyang12
Copy link

I got compilation issues while trying to compile mitsuba 0.6 on Ubuntu 18.04.

The first issue is the Qt5xxx vs Qtxxx issue as stated in #32 and is solved by either modifying the corresponding names in data/scons/qt5.py as suggested in #38 or modifying the link mappings as in #125.

The second issue is the -std=c++11 issue (solved by changing it to -std=gnu++11) as posted by @SilvioJin in #32.

The third issue is the mtsgui compilation issue directly caused by qt5, which I have no solution yet. Everything seems to be okay after the above two steps. But when it began to compile mtsgui, it started to throw errors and then terminated.

The error message is like this

build/release/mtsgui/moc_acknowledgmentdlg.cc:65:1: error: ‘QT_INIT_METAOBJECT’
does not name a type; did you mean ‘Q_INIT_RESOURCE’?
 QT_INIT_METAOBJECT const QMetaObject AcknowledgmentDialog::staticMetaObject = {
 {
 ^~~~~~~~~~~~~~~~~~
 Q_INIT_RESOURCE
build/release/mtsgui/moc_addserverdlg.cc:87:1: error: ‘QT_INIT_METAOBJECT’ does
not name a type; did you mean ‘Q_INIT_RESOURCE’?
 QT_INIT_METAOBJECT const QMetaObject AddServerDialog::staticMetaObject = { {
 ^~~~~~~~~~~~~~~~~~
 Q_INIT_RESOURCE
build/release/mtsgui/moc_importdlg.cc:106:1: error: ‘QT_INIT_METAOBJECT’ does no
t name a type; did you mean ‘Q_INIT_RESOURCE’?
 QT_INIT_METAOBJECT const QMetaObject ImportDialog::staticMetaObject = { {
 ^~~~~~~~~~~~~~~~~~
 Q_INIT_RESOURCE
build/release/mtsgui/moc_aboutdlg.cc:78:1: error: ‘QT_INIT_METAOBJECT’ does not
name a type; did you mean ‘Q_INIT_RESOURCE’?
 QT_INIT_METAOBJECT const QMetaObject AboutDialog::staticMetaObject = { {
 ^~~~~~~~~~~~~~~~~~
 Q_INIT_RESOURCE
build/release/mtsgui/moc_glwidget.cc:260:1: error: ‘QT_INIT_METAOBJECT’ does not
 name a type; did you mean ‘Q_INIT_RESOURCE’?
 QT_INIT_METAOBJECT const QMetaObject GLWidget::staticMetaObject = { {
 ^~~~~~~~~~~~~~~~~~
 Q_INIT_RESOURCE
scons: *** [build/release/mtsgui/moc_acknowledgmentdlg.o] Error 1
scons: *** [build/release/mtsgui/moc_addserverdlg.o] Error 1
scons: *** [build/release/mtsgui/moc_importdlg.o] Error 1
scons: *** [build/release/mtsgui/moc_aboutdlg.o] Error 1
scons: *** [build/release/mtsgui/moc_glwidget.o] Error 1
scons: building terminated because of errors.

I also tried to compile mitsuba without mtsgui since it led to failure following #131. Unfortunately, it failed with error message like dist/mtsgui is required.

@antequ
Copy link

antequ commented Nov 16, 2020

For me, the issue seems to be fixed after following the changes in pr #38, as long as I didn't also try to follow #125 . Make sure your qt4 and qt5 are compatible and don't have name conflicts. However, I found it simplest to just build mitsuba 0.5 without the qt5 changes, if you cherry-pick the right changes from after the 0.5 release. I made a guide here: https://docs.google.com/document/d/1W-g23kfUGqOgmczd-hKbiMdtf_yA48BeQngrchio4b8/edit?usp=sharing

I noticed that it's been 4 months. Please update me on what you found that helped you compile, if you found the problem and solution to this!

@nitinagarwal
Copy link

I too am getting the same error as @liuyang12 . Any solutions?

@antequ
Copy link

antequ commented Nov 17, 2020

I’m sorry, I wasn’t able to build mtsgui either. I’ve been using the command line version.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants