Results 1 to 16 of 16

Thread: Error Link !!!!!!!!!!!!!!!

  1. #1
    Lesser Knight
    Join Date
    Jan 2011
    Posts
    30

    Default Error Link !!!!!!!!!!!!!!!

    why i cant use clanlib in windows 7 64-bit ?!!!!
    i can use it in windows 32 bit , but i cant use it in 64 bit and my compiler (visual studio) take error link ?!! why ?
    (Runtime library set "Multi-threaded Debug (/MTd)")

  2. #2
    ClanLib Developer
    Join Date
    Sep 2006
    Location
    Denmark
    Posts
    554

    Default

    Could you paste the error message?

    ClanLib works fine on my Windows 7 64 bit. Both the 32 bit builds and the 64 bit builds.

  3. #3
    Lesser Knight
    Join Date
    Jan 2011
    Posts
    30

    Default

    my source code is

    #include <ClanLib/core.h>
    #include <ClanLib/application.h>
    #include <ClanLib/display.h>
    #include <ClanLib/swrender.h>

    int main(const std::vector<CL_String> &args)
    {
    CL_SetupCore s_core;
    CL_SetupDisplay s_display;
    CL_SetupSWRender s_swrender;

    return 0;
    }

    CL_ClanApplication app( main );


    and my compiler take 52 error links one of them


    Error 1 error LNK2019: unresolved external symbol _png_destroy_write_struct referenced in function "public: static void __cdecl CL_PNGProvider::save(class CL_PixelBuffer,class CL_IODevice &)" (?save@CL_PNGProvider@@SAXVCL_PixelBuffer@@AAVCL_I ODevice@@@Z) c:\Users\AhUrA\documents\visual studio 2010\Projects\Clanlib\Clanlib\clanDisplay-static-mt-debug.lib(png_provider.obj)

    and

    Error 50 error LNK2001: unresolved external symbol _IID_IDirectInput8W c:\Users\AhUrA\documents\visual studio 2010\Projects\Clanlib\Clanlib\clanDisplay-static-mt-debug.lib(win32_window.obj)

    and

    Error 51 error LNK2001: unresolved external symbol _c_dfDIJoystick2 c:\Users\AhUrA\documents\visual studio 2010\Projects\Clanlib\Clanlib\clanDisplay-static-mt-debug.lib(input_device_provider_directinput.obj)


    and

    Error 52 error LNK1120: 48 unresolved externals c:\users\ahura\documents\visual studio 2010\Projects\Clanlib\Debug\Clanlib.exe

    and ....... i copy directX and ClanLib Dependency Libraries on vc folder (include and lib). i can use clanlib on 32-bit windows but i cant use on 64-bit why ?!!! why take error link !! please help me to resolve them

  4. #4
    ClanLib Developer
    Join Date
    Sep 2006
    Location
    Bergen, Norway
    Posts
    588

    Default

    Please, try to use less !!! in your text, I get annoyed just by looking at your text.

    Anyway, http://clanlib.org/wiki/VisualStudio2010GlobalIncludes - pay closely attention to the last sentence - maybe you haven't set up your proper directories for 64 bit builds.

  5. #5
    Lesser Knight
    Join Date
    Jan 2011
    Posts
    30

    Default

    my friend i must say my problem ... !!! i like clanlib and i want to use it but i cant use clanlib in 64-bit windows ! i can use it in 32-bit windows (xp or 7) but i cant use it in 64-bit and take error linked ( please help me

  6. #6
    Lesser Knight
    Join Date
    Jan 2011
    Posts
    30

    Default

    no body help me ?!!!!!!!

  7. #7
    Lesser Knight
    Join Date
    Jan 2011
    Posts
    30

    Default

    i do same work . works on 32 bit but dont work on 64 bit !!! why ?

  8. #8
    ClanLib Developer
    Join Date
    May 2007
    Posts
    1,824

    Default

    http://clanlib.org/wiki/VisualStudio2010GlobalIncludes

    If you are using 64 bit versions of ClanLib, you need to change the Platform combobox to x64 and modify the Include and Libs directories there as well.

  9. #9
    Lesser Knight
    Join Date
    Jan 2011
    Posts
    30

    Default

    tnx . i do it but doesnt work

  10. #10
    ClanLib Developer
    Join Date
    May 2007
    Posts
    1,824

    Default

    Unless you really know what you are doing. I would avoid using x64.

    For general use, there are no advantages in using x64.

    Unless you are using more than 4GB of data and require the fastest processing speed.

    Using Win32 works on all PC's

  11. #11
    Lesser Knight
    Join Date
    Jan 2011
    Posts
    30

    Default

    i use win32 (32-bit) clanlib its very wonderful clancore and application works but graphics like swrender and gl doesnt work idont know why ?!!! for example if my source be

    int main(...)
    {
    cl_setupcore s_c;
    return 0;
    }

    my code is compile successfully. but if be

    int main(...)
    {
    cl_setupcore s_c;
    cl_setupswrender s_s;
    return 0;
    }

    it takes error link

  12. #12

    Default

    You're missing CL_SetupDisplay. Also check you're linking against (as well as #includeing) clanCore-2.2, clanDisplay-2.2, clan{GL1, GL or SWRender}-2.2 and clanApplication-2.2.

    #include <ClanLib/core.h>
    #include <ClanLib/display.h>
    #include <ClanLib/gl1.h> // or GL or SWRender
    #include <ClanLib/application.h>
    int program(const std::vector<CL_String> &args){ // I wouldn't call it 'main' if using CL_ClanApplication, though I don't know if this is actually forbidden
    CL_SetupCore setup_core;
    {//this ensures Core is set up before the others
    CL_SetupDisplay setup_display;
    CL_SetupGL1 target_gl1; // or GL or SWRender
    /*your code*/
    }
    return 0;
    }
    CL_ClanApplication app(&program);

  13. #13
    Lesser Knight
    Join Date
    Jan 2011
    Posts
    30

    Default

    tnx my friend for your help . i compile your code but takes error :

    Error 1 error LNK2001: unresolved external symbol _IID_IDirectInput8W clanDisplay-static-mt-debug.lib

    Error 2 error LNK2001: unresolved external symbol _c_dfDIJoystick2 clanDisplay-static-mt-debug.lib

  14. #14
    ClanLib Developer
    Join Date
    May 2007
    Posts
    1,824

    Default

    You also need to install a version of the DirectX SDK (if you have not already done it)

    On my PC, it is found in:

    (32 bit) - C:\Program Files (x86)\Microsoft DirectX SDK (June 2010)\Lib\x86
    (64 bit) - C:\Program Files (x86)\Microsoft DirectX SDK (June 2010)\Lib\x64

  15. #15
    Lesser Knight
    Join Date
    Jan 2011
    Posts
    30

    Default

    means i use directX 32-bit ? or 64-bit ?

  16. #16
    Lesser Knight
    Join Date
    Jan 2011
    Posts
    30

    Default

    tnx a lot

Similar Threads

  1. Link warning
    By Eng C. Born in forum Official ClanLib SDK Forums
    Replies: 2
    Last Post: 04-22-2009, 12:29 PM
  2. Server link
    By in forum Funeral Quest
    Replies: 2
    Last Post: 06-05-2005, 09:59 PM
  3. if you link Dink Smallwood
    By in forum Dink Smallwood HD
    Replies: 0
    Last Post: 02-14-2005, 11:30 AM
  4. Whats with the link to Dink?
    By in forum Dink Smallwood HD
    Replies: 2
    Last Post: 09-29-2003, 10:16 PM
  5. Why does the BYG server link
    By jimbobbucky in forum Funeral Quest
    Replies: 20
    Last Post: 06-23-2003, 12:56 AM

Bookmarks

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •