:: error: collect2: ld returned 1 exit status



  • Hi,

    I got this error when linking to autodesk FBX sdk.

    The log is :

    @Creating library file: debug\libfbx.a

    mingw32-make[1]: Leaving directory `E:/projects/qt/Draupnir/fbx-build-desktop'

    mingw32-make: Leaving directory `E:/projects/qt/Draupnir/fbx-build-desktop'

    debug/cfbx.o:E:\projects\qt\Draupnir\fbx-build-desktop/../fbx/cfbx.cpp:345: undefined reference to `fbxsdk_2011_3_1::KFbxNode::GetChild(int)'

    debug/cfbx.o:E:\projects\qt\Draupnir\fbx-build-desktop/../fbx/cfbx.cpp:343: undefined reference to `fbxsdk_2011_3_1::KFbxNode::GetChildCount(bool) const'

    debug/cfbx.o:E:\projects\qt\Draupnir\fbx-build-desktop/../../../fbx-sdk-2011.3.1/include/fbxfilesdk/kfbxplugins/kfbxlayer.h:950: undefined reference to `fbxsdk_2011_3_1::KFbxVector4::KFbxVector4()'

    debug/cfbx.o:E:\projects\qt\Draupnir\fbx-build-desktop/../../../fbx-sdk-2011.3.1/include/fbxfilesdk/kfbxplugins/kfbxlayer.h:950: undefined reference to `fbxsdk_2011_3_1::KFbxVector4::~KFbxVector4()'

    debug/cfbx.o:E:\projects\qt\Draupnir\fbx-build-desktop/../../../fbx-sdk-2011.3.1/include/fbxfilesdk/kfbxplugins/kfbxlayer.h:761: undefined reference to `fbxsdk_2011_3_1::KFbxLayerElementArray::GetAt(int, void**, fbxsdk_2011_3_1::EFbxType) const'

    debug/cfbx.o:E:\projects\qt\Draupnir\fbx-build-desktop/../../../fbx-sdk-2011.3.1/include/fbxfilesdk/kfbxplugins/kfbxlayer.h:761: undefined reference to `fbxsdk_2011_3_1::KFbxLayerElementArray::GetAt(int, void**, fbxsdk_2011_3_1::EFbxType) const'

    collect2: ld returned 1 exit status

    mingw32-make[1]: *** [debug\fbx.dll] Error 1

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

    and this is my pro :

    @#-------------------------------------------------

    Project created by QtCreator 2011-03-26T19:40:57

    #-------------------------------------------------

    QT += script scripttools

    TARGET = fbx
    TEMPLATE = lib

    DEFINES += FBX_LIBRARY
    DEFINES += _M_IX86

    SOURCES += cfbx.cpp

    HEADERS += cfbx.h
    fbx_global.h

    INCLUDEPATH +=
    "E:\projects\fbx-sdk-2011.3.1\include\"
    "E:\projects\qt\Draupnir\Draupnir\"

    FORMS +=
    ImportFBXWidget.ui

    LIBS +=
    "E:\projects\fbx-sdk-2011.3.1\lib\vs2005\fbxsdk_20113_1d.lib"
    @



  • From the name of the path, it looks like your SDK is built for use with MSVC 2005 but you are trying to use MinGW. Try using MSVC 2005 instead or find a build of the sdk lib for MinGW.


Log in to reply
 

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