Frage

Ich hatte gedacht, dass ich nur ein Problem gelöst , aber es schien eine andere beschnittene up - oder zumindest das gleiche Problem in einer anderen Form. Nun, wenn ich versuche, alles wieder aufzubauen, wie in der Antwort auf diese Frage vorgeschlagen, alle Qt Creator zeigt in Build-Probleme ist eine eine Zeile collect2: ld returned 1 exit status

Hier ist ein Teil der Kompilierung Ausgabe, dass ich denke, relevant sein könnte:

Running build steps for project Othello-cmd...
Starting: "C:/Qt/2010.05/mingw/bin/mingw32-make.exe" clean -w
[snipped]
C:/Qt/2010.05/mingw/bin/mingw32-make -f Makefile.Release clean

Could Not Find C:\Users\Amos Ng\My Dropbox\School\College\2010.. Fall\CS 3A\Othello-cmd-build-desktop\debug\main.o           //this was in red

mingw32-make[1]: Entering directory `C:/Users/Amos Ng/My Dropbox/School/College/2010.. Fall/CS 3A/Othello-cmd-build-desktop'

del release\main.o release\board.o release\player.o release\referee.o release\misc.o release\humanplayer.o release\computerplayer.o release\chatter.o release\chatserver.o release\location.o
mingw32-make[1]: Leaving directory `C:/Users/Amos Ng/My Dropbox/School/College/2010.. Fall/CS 3A/Othello-cmd-build-desktop'

mingw32-make: Leaving directory `C:/Users/Amos Ng/My Dropbox/School/College/2010.. Fall/CS 3A/Othello-cmd-build-desktop'

Could Not Find C:\Users\Amos Ng\My Dropbox\School\College\2010.. Fall\CS 3A\Othello-cmd-build-desktop\release\main.o

//these next 3 lines are in blue
The process "C:/Qt/2010.05/mingw/bin/mingw32-make.exe" exited normally.
Configuration unchanged, skipping qmake step.
Starting: "C:/Qt/2010.05/mingw/bin/mingw32-make.exe" -w
mingw32-make: Entering directory `C:/Users/Amos Ng/My Dropbox/School/College/2010.. Fall/CS 3A/Othello-cmd-build-desktop'
[snipped]
//A bunch of lines similar to
g++ -c -g -frtti -fexceptions -mthreads -Wall -DUNICODE -DQT_LARGEFILE_SUPPORT -DQT_DLL -DQT_CORE_LIB -DQT_THREAD_SUPPORT -I"c:\Qt\2010.05\qt\include\QtCore" -I"c:\Qt\2010.05\qt\include" -I"c:\Qt\2010.05\qt\include\ActiveQt" -I"debug" -I"\\psf\Dropbox\School\College\2010.. Fall\CS 3A\Othello-cmd" -I"." -I"c: "filepath of .o file" "filepath of .cpp file"

g++ -enable-stdcall-fixup -Wl,-enable-auto-import -Wl,-enable-runtime-pseudo-reloc -Wl,-subsystem,console -mthreads -Wl -o debug\Othello-cmd.exe object_script.Othello-cmd.Debug  -L"c:\Qt\2010.05\qt\lib" -lQtCored4

 //everything's red starting here...

./debug\board.o://psf/Dropbox/School/College/2010.. Fall/CS 3A/Othello-cmd/board.cpp:29: undefined reference to `OPiece::OPiece(int)'

./debug\board.o://psf/Dropbox/School/College/2010.. Fall/CS 3A/Othello-cmd/board.cpp:39: undefined reference to `OPiece::flip()'

./debug\board.o://psf/Dropbox/School/College/2010.. Fall/CS 3A/Othello-cmd/board.cpp:76: undefined reference to `OPiece::display()'

./debug\board.o://psf/Dropbox/School/College/2010.. Fall/CS 3A/Othello-cmd/board.cpp:110: undefined reference to `OPiece::display()'

./debug\board.o://psf/Dropbox/School/College/2010.. Fall/CS 3A/Othello-cmd/board.cpp:159: undefined reference to `OPiece::OPiece(int)'

//couple more lines just like the above

collect2: ld returned 1 exit status

//...finally things are black again

mingw32-make[1]: Leaving directory `C:/Users/Amos Ng/My Dropbox/School/College/2010.. Fall/CS 3A/Othello-cmd-build-desktop'

mingw32-make: Leaving directory `C:/Users/Amos Ng/My Dropbox/School/College/2010.. Fall/CS 3A/Othello-cmd-build-desktop'

//everything's red again

mingw32-make[1]: *** [debug\Othello-cmd.exe] Error 1

mingw32-make: *** [debug] Error 2

The process "C:/Qt/2010.05/mingw/bin/mingw32-make.exe" exited with code %2.
Error while building project Othello-cmd (target: Desktop)
When executing build step 'Make'

Alle Ideen, was diesen Fehler verursachen?

Bearbeiten : Ich mag auch zu Kenntnis würde, dass ich das finden "main.o" innerhalb des Debug-Verzeichnis ...

SOLUTION (nicht wirklich): I neu kompilierte alles in Netbeans statt (auf einem Mac obwohl, so vielleicht der Linker anders war ...). Jetzt wird das Programm läuft gut ... Auf Wiedersehen Qt Creator

War es hilfreich?

Lösung

Ich werde versuchen zu erraten. Sie sind entweder Namensraum falsch verwendet (d # include-Direktive in dem Körper des Namespace setzen). Oder Sie haben nicht gelöscht Debug- und Release-Verzeichnisse vollständig, wie Sie raten wurden.

scroll top