Linker Error Contains Invalid Omf Record Type 0x21 Possibly Coff
Contents |
here for a quick overview of the site Help Center Detailed answers to any questions you might have Meta Discuss the workings and policies of this site About Us Learn more about Stack Overflow the company Business Learn more about hiring
Coff2omf
developers or posting ads with us Stack Overflow Questions Jobs Documentation Tags Users Badges Ask Question implib x Dismiss Join the Stack Overflow Community Stack Overflow is a community of 6.2 million programmers, just like you, helping each other. Join them; it only takes a minute: Sign up Linker error “contains invalid OMF record” up vote 1 down vote favorite In C++ Builder when I compile I get [ilink32 Error] Error: 'C:\PATH\TO\A\LIB\INCLUDED\IN\THE\PROJECT\ALIBRARY.LIB' contains invalid OMF record, type 0x21 (possibly COFF) When I convert .lib with utilities coff2omf, new lib looses significant functions. c++builder builder coff omf share|improve this question edited Jun 25 '14 at 14:54 bluish 9,4181269126 asked Jul 17 '13 at 8:31 Yaroslav Vozyka 612 Please clarify your question - e.g. did you make the lib yourself or you have got it from somewhere? To get a good answer you have to provide more details on what you are trying to do and what exactly the problem is. –bbonev Jul 17 '13 at 8:57 add a comment| 1 Answer 1 active oldest votes up vote 4 down vote C++Builder cannot use .lib files from other compilers, only its own. If the .lib file is an import lib for a DLL, use C++Builder's command-line IMPLIB tool to create a new .lib file from the DLL directly. If the .lib file is a static library (containing actual code), C++Builder's command-line COFF2OMF tool MAY be able to convert the library, but it is not guaranteed. It really depends on what kind of code the library is actually using. If the conversion is not possible, you will have to wrap the .lib file into a DLL that is written in the same compiler that created the .lib file. Then you can use the DLL in C++Builder. share|improve this answer answered Jul 17 '13 at 21:05 Remy Lebeau 232k13143273 add a comment| Your Answer draft saved draft discarded Sign up or log in Sign up using Google Sign up using Facebook Sign up using Email and Password Post as a guest Name Email Post as a guest Name Email discard By posting your answer, you agree to the privacy policy and terms of service. Not the answer you're looking for? Browse other questions tagged c++builder builder coff omf or ask your own question. asked 3 years ago viewed 4345 times active 2 years ago Linked 1 Linker er
van GoogleInloggenVerborgen veldenZoeken naar groepen of berichten
[Linker Error] linker error [...]\NAME.LIB contains invalid OMF record, type 0x21 (possibly COFF)
Cause The library is of the wrong type. Use linker error contains coff2omf.exe, located in the CBuilder/bin folder, to convert it to the correct type. Solution The following MS-DOS commands converts a COFF library called MyLib.lib to the OMF library file MyNewLib.lib, after making a backup file called MyBackupLib.lib: copy MyLib.lib MyBackupLib.lib
coff2omf MyLib.lib MyNewLib.lib
copy MyNewLib.lib MyLib.lib
Go back to Richel Bilderbeek's C++ page. Go back to Richel Bilderbeek's homepage.