How create an standalone (without DLL file depende

2020-06-15 10:52发布

问题:

When I create a Delphi console application, I can deploy the generated EXE file without worrying about external DLL files. But if I create very simple C++Builder (version 2007) console application (no VCL) the EXE file requires the CC3280MT.dll file to run.

How can I avoid which my C++Builder console application requires the CC3280MT.dll file?

Even this simple code cause this dependence:

#include <iostream.h>
#pragma hdrstop

#pragma argsused
int main(int argc, char* argv[])
{
    cout << "Hello" << endl;
    getchar();
    return 0;
}

回答1:

  1. In the project options, uncheck the linker option "Dynamic RTL".
  2. In the packages options, uncheck "Link with runtime packages".


回答2:

Also you should uncheck:

Project Options -> C++ Linker -> Link with the Delphi Runtime Library ...