Re: Cannot create import libraries with Microsoft's LIB with the option mixed language Borland C++ (-ml bc) with Lahey v5.7



C++ normally "decorates" linkage symbols -- and the decoration is NOT compatible from
one vendor's compiler to another. The usual trick is to

#ifdef __cplusplus
extern "C" {
#endif

in the C++ source for anything that needs to talk to Fortran, assembler &c.

What version of Borland C/C++ and what version of MSVC are you using?
.



Relevant Pages

  • Re: external variables
    ... external variables are analogous to fortran COMMON blocks or ... -unless a type declaration to the contrary is made" ... not have the extern attribute. ...
    (comp.lang.c)
  • Re: programming languages in order
    ... FORTRAN (learned from the FORTRAN coloring book over a weekend so I ... Z-80 Assembler, 360 Assembler, About 5 more dialects of BASIC, PASCAL, ... mess in my head of picking up about another language a year depending on ... to write well structured code either. ...
    (rec.arts.sf.written)
  • Re: Dvorak on Itanic
    ... SDS 900 series assembler was my first programming language. ... I taught myself Fortran from Daniel D. McCracken's book "A Guide to Fortran IV Programming" and then used it to make a decent living for many years, coding for people who hadn't a clue about computers or programming but needed the results. ... the compiler which prints out the generated assembly code. ...
    (comp.os.vms)
  • Re: programming languages in order
    ... (Eg, dunno if you want to count JCL, but if so, same time as Fortran.) ... FORTRAN, PASCAL, PDP/11 assembler, C. ... Learning FORTAN or BASIC first is probably a terrible idea, ...
    (rec.arts.sf.written)
  • Re: C++ wrapper for fortran functions
    ... How can I can wrap a fortran function in C++? ... I am aware of extern ... alone inside a function decleration most probably in a class ...
    (comp.lang.fortran)