Thread: link error -- machine type conflict

  1. #1
    Registered User
    Join Date
    May 2006
    Posts
    1,579

    link error -- machine type conflict

    Hello everyone,


    I am building a DLL using embedded VC 4. When building a DLL (written in C) for platform MIPSFPU, there is a strange link error.

    fatal error LNK1112: module machine type 'MIPS' conflicts with target machine type 'MIPSFPU'

    Here is the link option I am using. I am wondering what is wrong with the settings?

    commctrl.lib coredll.lib /nologo /base:"0x00100000" /stack:0x10000,0x1000 /entry:"_DllMainCRTStartup" /dll /incremental:yes /pdb:"MIPSIVRel/recover.pdb" /debug /nodefaultlib:"$(CENoDefaultLib)" /out:"MIPSIVRel/recover.dll" /implib:"MIPSIVRel/recover.lib" /subsystem:$(CESubsystem) /MACHINE:MIPSFPU


    thanks in advance,
    George

  2. #2
    Kernel hacker
    Join Date
    Jul 2007
    Location
    Farncombe, Surrey, England
    Posts
    15,677
    So some of the code is built for a MIPS rather than MIPSFPU architecture, and the linker doesn't want to mix it.

    You probably need to rebuild the code to use MIPSFPU always. This is probably a setting in some of your build files - it's so long since I worked on CE that I couldn't tell you where to look.

    --
    Mats

  3. #3
    Registered User
    Join Date
    May 2006
    Posts
    1,579
    Thanks Mats,


    Quote Originally Posted by matsp View Post
    So some of the code is built for a MIPS rather than MIPSFPU architecture, and the linker doesn't want to mix it.

    You probably need to rebuild the code to use MIPSFPU always. This is probably a setting in some of your build files - it's so long since I worked on CE that I couldn't tell you where to look.

    --
    Mats
    Could you provide more information about what means *some of the code is built for a MIPS rather than MIPSFPU*? How to check?


    regards,
    George

  4. #4
    Kernel hacker
    Join Date
    Jul 2007
    Location
    Farncombe, Surrey, England
    Posts
    15,677
    There's a tool in MS called something like dumpbin which will show you the information within an object file, executable or dll. It has several flags, but something like /headers is probably what you want. I haven't got MS tools on my machine here at work, so I don't know what the exact name of the application or switches are.

    --
    Mats

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Can you check what is wrong with this code
    By Ron in forum C++ Programming
    Replies: 4
    Last Post: 08-01-2008, 10:59 PM
  2. Script errors - bool unrecognized and struct issues
    By ulillillia in forum Windows Programming
    Replies: 10
    Last Post: 12-18-2006, 04:44 AM
  3. Function to check memory left from malloc and free?
    By Lechx in forum C Programming
    Replies: 4
    Last Post: 04-24-2006, 05:45 AM
  4. Question on l-values.
    By Hulag in forum C++ Programming
    Replies: 6
    Last Post: 10-13-2005, 04:33 PM
  5. Dikumud
    By maxorator in forum C++ Programming
    Replies: 1
    Last Post: 10-01-2005, 06:39 AM