Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

In this Discussion

Unable to compile C++ libraries in C++ Builder 10.4

When I try to compile C++ (Builder 10.4) version of the libraries, I get the following errors:

[ilink32 Error] Error: Unresolved external '__InitVCL' referenced from C:\PROGRAM FILES (X86)\EMBARCADERO\STUDIO\21.0\LIB\WIN32\RELEASE\CP32MTI.LIB|crtlvcl
[ilink32 Error] Error: Unresolved external '__ExitVCL' referenced from C:\PROGRAM FILES (X86)\EMBARCADERO\STUDIO\21.0\LIB\WIN32\RELEASE\CP32MTI.LIB|crtlvcl
[ilink32 Error] Error: Unable to perform link

This are the steps I make to compile all libraries:

- Execute the installer for the libraries. I install them in C:\LMD2020. Lib path is C:\LMD2020\lib
- Execute the installer for the source code. Install it also in C:\LMD2020. BPL folder if the default folder and mark the option to modify the search path in Builder 10.4
- Compile (with Delphi) project _LMD2020VCL_d27.groupproj, both for 32 and 64 bits --> No errors
- Compile (with Builder) project _LMD2020VCL_b27.groupproj --> Linking error

At this point, I have noticed that there is projects for C++ version are not configured to have 32 and 64 bits platform. Only 32 is available. Is this correct?, I think is also needed platform for 64 bits version.

Comments

  • 5 Comments sorted by Votes Date Added
  • edited October 2020 Posts: 0Vote Up0Vote Down
    For creating installers we compile our libraries using Delphi project files and Delphi compiler (using LMD-DevUtil). This should be sufficient to use them in C++ projects (given that all C++ related library/include/ect paths are specified).

  • That means that is not needed to compile the C++ projects?

    In that case, how and where x64 libraries (*.a) are generated?

    What is LMD-DevUtils?
  • edited October 2020 Posts: 0Vote Up0Vote Down
    Delphi compiler supports special command line keys, which can be used to generate C++ headers and libraries. LMD-DevUtil uses these keys (and I believe VCL itself is compiled similarly - using Delphi compiler).

    Compiled packages are placed into RadStudio default paths; on my system these paths are:

    C:\Users\Public\Documents\Embarcadero\Studio\21.0\Bpl
    C:\Users\Public\Documents\Embarcadero\Studio\21.0\Blp\Win64
    C:\Users\Public\Documents\Embarcadero\Studio\21.0\Dcp
    C:\Users\Public\Documents\Embarcadero\Studio\21.0\Dcp\Win64

    There you can find 32 bit "*.lib" files, as well as 64 bit "*.a" files.
  • edited October 2020 Posts: 0 Accepted Answer Vote Up0Vote Down
    LMD-DevUtil is our utility tool, which allows to manage source code. But, it only accessible for customers, which own LMD VCL Complete (with GIT access).

    Anyway, LMD-DevUtil is not absolutely required. Just recompiling Delphi packages for x64 platform inside IDE will produce "*.a" files in mentioned above folders. But, note that design-time packages cannot be recompiled for x64 bit, since IDE itself is 32 bit; so, just skip them.
Sign In or Register to comment.