How can I compile all necessary files within my executable using Borland 5?

  • Thread starter Thread starter sweetjones
  • Start date Start date
Click For Summary
SUMMARY

The discussion centers on compiling a self-sufficient executable using Borland 5, specifically addressing the issue of missing runtime files like "VCL50.BPL" and various .DLL files when distributing the application. The solution involves setting static linkage instead of dynamic linkage, which allows all necessary libraries to be included within the executable. Users are advised to uncheck the "Build with Runtime-Packages" option to avoid dependency on external files. Despite attempts to resolve the issue, the user ultimately considers switching to Microsoft Studios for better support.

PREREQUISITES
  • Understanding of Borland 5 IDE and its compilation settings
  • Knowledge of static vs. dynamic linking in software development
  • Familiarity with runtime packages and their implications
  • Basic experience in C++ programming and executable file management
NEXT STEPS
  • Research how to set static linkage in Borland 5
  • Learn about the implications of using runtime packages in C++ applications
  • Explore alternatives to Borland 5, such as Microsoft Visual Studio
  • Investigate methods for packaging C++ applications for distribution
USEFUL FOR

Software developers, particularly those using Borland 5, who need to create standalone executables without external dependencies, as well as those considering transitioning to other development environments like Microsoft Visual Studio.

sweetjones
Messages
44
Reaction score
0
Hello, I made a program that does calculations on fractions. It's finally finished with all of the validations and things. All of the lines of code finally compiles with no errors. I can run the exe on my cpu, but when I give it to others that do not have Borland installed they can't run it. A message pops up saying that "VCL50.BPL" can't be found. So I copied that file and pasted it in the same folder as my exe. Then, I ran it and an error message popped up saying that a certain .DLL file can't be found. So I copied the "VCL50.BPL" file and my exe file out of my borland directory and pasted them in the bin folder from my borland directory where all of the .DLL files are located. My exe can now run on other cpu's because it's inside the same folder as all of these different files. My question is, what do I need to include in my source code so that all of the necessary files can be compiled within my executable so that I don't have to zip up a big folder just to run one file? So far this is the only way my program can run on other computers. Thanks In Advance!
 
Technology news on Phys.org
Without being familiar with Borland 5, it sure sounds like you need to set static linkage instead of dynamic. External libraries are now being dynamically loaded when your program runs instead of being included in the program. Search for an option (check in your help file) to link statically, or to turn off dynamic linkage, or words to that effect. Your .exe file will be larger but self-sufficient.
 
out of whack said:
Without being familiar with Borland 5, it sure sounds like you need to set static linkage instead of dynamic. External libraries are now being dynamically loaded when your program runs instead of being included in the program. Search for an option (check in your help file) to link statically, or to turn off dynamic linkage, or words to that effect. Your .exe file will be larger but self-sufficient.

Thank you for your reply. After using your advice I found that this is one of the many downfalls when using Borland. I've read that I need to uncheck the "Build with Runtime-Packages" option in Borland. I tried this but it still needed those 2 .DLL files. It didn't ask me for the .BPL file though. I'm just going to stick with Microsoft Studios.
 

Similar threads

  • · Replies 29 ·
Replies
29
Views
4K
  • · Replies 5 ·
Replies
5
Views
3K
  • · Replies 1 ·
Replies
1
Views
4K
  • · Replies 2 ·
Replies
2
Views
3K
  • · Replies 27 ·
Replies
27
Views
6K
Replies
7
Views
3K
Replies
3
Views
3K
Replies
1
Views
7K
  • · Replies 19 ·
Replies
19
Views
6K
Replies
81
Views
8K