Board index » cppbuilder » Linker Error: invalid OMF record?

Linker Error: invalid OMF record?

After adding a third-party .LIB file (built with MS VC++ 6.0) to my BCB
4.0 project, I receive a linker error: XXX.LIB contains invalid OMF
record, type 0x21 (possibly COFF).  Using the COFF2OMF utility to
convert the third-party .LIB file did not help.  

What's next?  And what can I tell my supplier of the .LIB file with
regards to what to do so the file is directly useable in BCB?

--
Joe

---------------------------------------------------------------------------
Joe Dubner         |  P.O. Box 98              |  
                   |  Liberty Lake, WA 99019   |  +1 509 255-1102
---------------------------------------------------------------------------

 

Re:Linker Error: invalid OMF record?


COFF2OMF is only for import libs, not static libs.  You will need a dll and OMF
import libray.  C++ static libs are not cross compiler even if in the same
format.

Quote
Joe Dubner wrote:

> After adding a third-party .LIB file (built with MS VC++ 6.0) to my BCB
> 4.0 project, I receive a linker error: XXX.LIB contains invalid OMF
> record, type 0x21 (possibly COFF).  Using the COFF2OMF utility to
> convert the third-party .LIB file did not help.

> What's next?  And what can I tell my supplier of the .LIB file with
> regards to what to do so the file is directly useable in BCB?

> --
> Joe

> ---------------------------------------------------------------------------
> Joe Dubner         |  P.O. Box 98              |
>                    |  Liberty Lake, WA 99019   |  +1 509 255-1102
> ---------------------------------------------------------------------------

--
Jeff Overcash (TeamB)
      (Please do not email me directly unless  asked. Thank You)
Anyone who cannot cope with mathematics is not fully human.
At best he is a tolerable subhuman who has learned to wear
shoes, bathe and not make messes in the house.   (Heinlein)

Re:Linker Error: invalid OMF record?


Jeff -

I have similar problems, but am trying to install OpenGL and DirectX libraries. The
manuals do not give a desciption that I can understand (pretty brief) for how to
link to the DLLs I've downloaded (some OpenGL and DiretX DLLs). It looks like I
need to "manually" create a "LIB" file using implib (from DOS command line) for
each of the DLLs (?). If this is correct and I have done this, what do I need to do
to access (link) the LIB routines from within a BCB Project?

Quote
"Jeff Overcash (TeamB)" wrote:
> COFF2OMF is only for import libs, not static libs.  You will need a dll and OMF
> import libray.  C++ static libs are not cross compiler even if in the same
> format.

> Joe Dubner wrote:

> > After adding a third-party .LIB file (built with MS VC++ 6.0) to my BCB
> > 4.0 project, I receive a linker error: XXX.LIB contains invalid OMF
> > record, type 0x21 (possibly COFF).  Using the COFF2OMF utility to
> > convert the third-party .LIB file did not help.

> > What's next?  And what can I tell my supplier of the .LIB file with
> > regards to what to do so the file is directly useable in BCB?

> > --
> > Joe

> > ---------------------------------------------------------------------------
> > Joe Dubner         |  P.O. Box 98              |
> >                    |  Liberty Lake, WA 99019   |  +1 509 255-1102
> > ---------------------------------------------------------------------------

> --
> Jeff Overcash (TeamB)
>       (Please do not email me directly unless  asked. Thank You)
> Anyone who cannot cope with mathematics is not fully human.
> At best he is a tolerable subhuman who has learned to wear
> shoes, bathe and not make messes in the house.   (Heinlein)

--
==================================================
| Tim S. Haynes
| email: thay...@sprintmail.com
| web: http://home.sprintmail.com/~thaynes/
=================================================

Re:Linker Error: invalid OMF record?


: Tim Haynes <thay...@sprintmail.com> wrote:

Quote
>how to link to the DLLs I've downloaded

Add the LIB file to the project.

Quote
>It looks like I need to "manually" create a "LIB" file using implib

Not if there are Borland LIBs already.

--
General information:
  * Post to the right group - http://www.borland.com/newsgroups/
    * Do not cross- or multipost
      * Research at http://www.mers.com/searchsite.html

Stefan Hoffmeister - http://www.econos.de/
(TeamB - http://www.teamb.com/)

Other Threads