Error compiling



  • Hi, whenever I try to run my project I get the following error :
    @collect2.exe:-1: error: fatal error: cannot find 'ld'@

    Here's my compile output :
    @15:12:53: Running steps for project mtacreat...
    15:12:53: Configuration unchanged, skipping qmake step.
    15:12:53: Starting: "C:\Qt\Tools\mingw48_32\bin\mingw32-make.exe"
    C:/Qt/Tools/mingw48_32/bin/mingw32-make -f Makefile.Debug
    mingw32-make[1]: Entering directory 'C:/Users/Robbe/Documents/build-mtacreat-Desktop_Qt_5_2_1_MinGW_32bit-Debug'
    g++ -Wl,-subsystem,windows -mthreads -o debug\mtacreat.exe debug/main.o debug/mainwindow.o debug/moc_mainwindow.o -lglu32 -lopengl32 -lgdi32 -luser32 -lmingw32 -lqtmaind -LC:\Qt\5.2.1\mingw48_32\lib -lQt5Widgetsd -lQt5Guid -lQt5Cored
    collect2.exe: fatal error: cannot find 'ld'
    compilation terminated.
    Makefile.Debug:80: recipe for target 'debug\mtacreat.exe' failed
    mingw32-make[1]: *** [debug\mtacreat.exe] Error 1
    mingw32-make[1]: Leaving directory 'C:/Users/Robbe/Documents/build-mtacreat-Desktop_Qt_5_2_1_MinGW_32bit-Debug'
    makefile:34: recipe for target 'debug' failed
    mingw32-make: *** [debug] Error 2
    15:12:56: The process "C:\Qt\Tools\mingw48_32\bin\mingw32-make.exe" exited with code 2.
    Error while building/deploying project mtacreat (kit: Desktop Qt 5.2.1 MinGW 32bit)
    When executing step 'Make'
    15:12:56: Elapsed time: 00:03.@

    I run Windows7 and use the qt IDE, I haven't written any code yet, I have only designed my guis. If I forgot to post something please let me know. Also, if it may help I constantly get errors about how qt cannot write on my disk because it lacks space, but I guarantee you it does not.



  • Hi, the message collect2.exe: fatal error: cannot find 'ld' says that the linker (eg. mingw) cannot be found. You should check whether all components are installed.



  • [quote author="Clochydd" date="1397222635"]Hi, the message collect2.exe: fatal error: cannot find 'ld' says that the linker (eg. mingw) cannot be found. You should check whether all components are installed.[/quote]

    How do I do that? It used to work before, it even did 30 minutes ago.



  • If it worked before:
    Can you remember what has been modified?
    Changed directory names?
    Installed or deinstalled something?



  • [quote author="Clochydd" date="1397226447"]If it worked before:
    Can you remember what has been modified?
    Changed directory names?
    Installed or deinstalled something?[/quote]

    Tbh, I don't remember. But what I've noticed is that my workspace directory seemed to have changed to my documents folder.

    Edit: I'm currently re-installing QT to another directory.



  • So, I re-installed QT to another directory, it still throws me those "memory full" errors but at least the error is solved and I can now continue programming.

    Edit : Aaaaaand it's back, I added a label, a text edit and a pushbutton and tried to run my project. Got the same error, removed the stuff I had created, still the same error.

    Edit Edit : http://puu.sh/84Gkd.png I keep on getting these messages too, I've already cleared out my appdata qtproject folder.



  • Could you post your error error message again?
    I cannot understand why the linker error disappeared and is back now so we should analyse in depth.



  • Okay, so I did a clean install of qt and cleared out my appdata, also I reset my path variables. I've just started up QT and ran a test project and it seemed to work fine now. Also my full memory errors are gone.



  • That's good news - happy coding!


Log in to reply
 

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.