Planned maintenance: From Sunday 8th December 10:00 CET there will be changes to try and solve the caching issues that have been experienced. If anyone has a problem connecting after this period then please PM @AndyS or any of the moderators.
New to Qt.
-
@jsulm I didn't change the Make file. The sources were fixed since I just downloaded the project. --- It is actually tabbed, 2 tabs. I don't get your point with DO SOMETHING.
-
error: missing separator (did you mean TAB instead of 8 spaces?). Stop.
Makefile.Debug:159: *** missing separator. Stop.Well, this tells us that the Make file has wrong syntax (spaces instead of TAB).
-
@jsulm I think I fixed that, the only error I got now is,
No rule to make target 'src/*.cpp', needed by 'build/*.o'. Stop.
15:27:30: Configuration unchanged, skipping qmake step. 15:27:30: Starting: "C:\Users\irish_ElEveN\Desktop\mingw32\bin\mingw32-make.exe" C:/Users/irish_ElEveN/Desktop/mingw32/bin/mingw32-make -f Makefile.Debug mingw32-make[1]: Entering directory 'C:/Users/irish_ElEveN/Desktop/build-SimulIDE-Unnamed-Debug' mingw32-make[1]: *** ****No rule to make target 'src/*.cpp', needed by 'build/*.o'. Stop.**** mingw32-make[1]: Leaving directory 'C:/Users/irish_ElEveN/Desktop/build-SimulIDE-Unnamed-Debug' mingw32-make: *** [debug] Error 2 Makefile:34: recipe for target 'debug' failed 15:27:30: The process "C:\Users\irish_ElEveN\Desktop\mingw32\bin\mingw32-make.exe" exited with code 2. Error while building/deploying project SimulIDE (kit: Desktop Qt 4.8.7) When executing step "Make" 15:27:30: Elapsed **bolded text**time: 00:00.```
-
I observed that 'src.cpp' isn't a .cpp file. It is just a folder containing sub folders for the sources of the project. What should I do to that?
-
There are two cpp files inside src directory, so it should be OK.
Replace all that *.cpp and *.h with complete file names like: src/mainwindow.cpp
-
Add widgets to QT in pro file: QT += xml widgets
Remove all prefixes in the Qt includes:
#include <QtGui/QTreeView>
should be
#include <QTreeView>
-
@jsulm Where's Qt includes? is it INCLUDEPATH += src \
-
I mean in your source code, in all places where you include Qt header files
#include <QtGui/QTreeView>
should be
#include <QTreeView>
-
If the path are giving problems add
$ $PWD
(without the space obviously) before them e.g.INCLUDEPATH += $ $PWD/src
(again without the space between the dollars the forum eats one if two are following each other)
-
-
Just build again and again and fix all the wrong includes (there are many in this project)
-
@SGaist I added $ $PWD on
SOURCES += $$PWD/src/*.cpp \
HEADERS += $$PWD/src/*.h \
INCLUDEPATH += $$PWD/src \
Is that right?
-
Do it for all the paths contained in these variables
-
@SGaist I got a new error,
:-1: error: error: C:/Users/irish_ElEveN/Desktop/simulide-svnrepo-27-trunk/include/simavr/libsimavr.a: No such file or directory
How can I remove simavr? Is it necessary to have that file on SimulIDE?
-
I don't know whether this lib is needed or not.
You can remove (or comment out) this line in SimulIDE.pro:
LIBS += $$PRO_FILE_PWD/include/simavr/libsimavr.a
-
@jsulm c:\Qt\4.8.7\lib\qtmaind.lib(tmp\obj\debug_shared\qtmain_win.obj):-1: error: undefined reference to `_CxxThrowException@8'
17:14:16: Configuration unchanged, skipping qmake step. 17:14:16: Starting: "C:\Users\irish_ElEveN\Desktop\mingw32\bin\mingw32-make.exe" c:\Qt\4.8.7\bin\qmake.exe -spec ..\..\..\..\Qt\4.8.7\mkspecs\win32-g++ -o Makefile ..\simulide-svnrepo-27-trunk\SimulIDE.pro C:/Users/irish_ElEveN/Desktop/mingw32/bin/mingw32-make -f Makefile.Debug mingw32-make[1]: Entering directory 'C:/Users/irish_ElEveN/Desktop/build-SimulIDE-Unnamed-Debug' g++ -mthreads -Wl,-subsystem,windows -o debug\SimulIDE\SimulIDE.exe object_script.SimulIDE.Debug -L"c:\Qt\4.8.7\lib" -lmingw32 -lqtmaind -lQtXmld4 -lQtGuid4 -lQtCored4 Warning: corrupt .drectve at end of def file c:\Qt\4.8.7\lib/qtmaind.lib(tmp/obj/debug_shared/qtmain_win.obj):(.text[?realloc@?$QVector@PAD@@AAEXHH@Z]+0x240): undefined reference to `_CxxThrowException@8' Makefile.Debug:209: recipe for target 'debug\SimulIDE\SimulIDE.exe' failed c:\Qt\4.8.7\lib/qtmaind.lib(tmp/obj/debug_shared/qtmain_win.obj):(.text[?realloc@?$QVector@PAD@@AAEXHH@Z]+0x3b1): undefined reference to `_CxxThrowException@8' C:/Users/irish_ElEveN/Desktop/mingw32/bin/../lib/gcc/i686-w64-mingw32/4.8.2/../../../../i686-w64-mingw32/bin/ld.exe: c:\Qt\4.8.7\lib/qtmaind.lib(tmp/obj/debug_shared/qtmain_win.obj): bad reloc address 0x3b1 in section `.text[?realloc@?$QVector@PAD@@AAEXHH@Z]' collect2.exe: error: ld returned 1 exit status mingw32-make[1]: *** [debug\SimulIDE\SimulIDE.exe] Error 1 mingw32-make: *** [debug] Error 2 mingw32-make[1]: Leaving directory 'C:/Users/irish_ElEveN/Desktop/build-SimulIDE-Unnamed-Debug' Makefile:34: recipe for target 'debug' failed 17:14:19: The process "C:\Users\irish_ElEveN\Desktop\mingw32\bin\mingw32-make.exe" exited with code 2. Error while building/deploying project SimulIDE (kit: Desktop Qt 4.8.7) When executing step "Make" 17:14:19: Elapsed time: 00:03.
-
Didn't you install Qt for VS?
If so you cannot use MinGW with that version, you need Qt built for MinGW.
-
qt-opensource-windows-x86-vs2010-4.8.7.exe : this is for VS2010 not MinGW!
-
So what do I need to do then? I'm so confused. lol :\
-
If you installed Qt for VS2010 then you have to use VS2010 compiler to build the app. Do you have VS2010?
If you do not have VS2010 then install Qt for MinGW and use this one.
-
@jsulm I downloaded the Qt MinGW Compiler, I manually added it alongside with my Version 4.8.7.
-
There is no such thing "Qt MinGW Compiler".
I saw above that you installed qt-opensource-windows-x86-vs2010-4.8.7.exe, this one can only be used with VS2010 compiler.
If you want to use MinGW compiler then download and install http://download.qt.io/archive/qt/4.8/4.8.6/qt-opensource-windows-x86-mingw482-4.8.6-1.exe
-
@jsulm I'll update you once the download is finished. Thank you!
-
This post is deleted!
-
@jsulm I can't put comment on avrsim 'cause some codes rely on it. simavr/libsimavr.a have no file, so that's the error now
-
I think it is this one: https://github.com/buserror/simavr
But take care: you have to build it with the same compiler you're using for your Qt app!
-
@jsulm What should I do with that?
-
@ijnuj.aicrag said:
@jsulm I can't put comment on avrsim 'cause some codes rely on it. simavr/libsimavr.a have no file, so that's the error now
See SimulIDE's README file. It talks about simavr.
-
@JKSH How can I get that?
-
You already have it. See in the simulide directory.
-
@jsulm It says no such file or directory. (libsimavr.a)
-
@ijnuj.aicrag said:
@jsulm It says no such file or directory. (libsimavr.a)
Have you found the README file yet?
If I've understood the README file correctly, you need to follow its instructions to build simavr.
-
@JKSH Yes, I have read the README file. I can't see any library/file to where simavr to build it.
-
@JKSH I've seen some links where it occurred the error too. Here:
-
@ijnuj.aicrag said:
@JKSH Yes, I have read the README file. I can't see any library/file to where simavr to build it.
Did you read this one? http://sourceforge.net/p/simulide/svnrepo/HEAD/tree/trunk/ Where it says "compiling simavr"?
-
@JKSH I don't get it, where should I compile simavr?
cd include/simavr
make
-
cd include/simavr
make
These are the commands you are meant to type into your console (command line).
- Call
cd
to navigate to the "include/simavr" folder. - Call
make
to build simavr. (If you are using MinGW, you probably need to callmingw32-make
instead of justmake
)
Note: These are not specific to Qt. I suggest you research a bit on (i) how to use a Makefile and (ii) how to use MinGW to build things.
- Call
-
@JKSH Which cmd should I call those commands? Any specific part of Qt or something?
-
@ijnuj.aicrag said:
@JKSH Which cmd should I call those commands? Any specific part of Qt or something?
This is not specific to Qt. Search Google for beginner tutorials on "Windows command prompt". It's also called the "command line" or "console".
-
I stil can't build the project. :\