Forum > General

Compile Borland Pascal 7.0 code

(1/2) > >>

Tommek:
I have read a lot now that Free Pascal is supposed to have high degree of compatibility with Turbo Pascal and Borland Pascal 7.0. So I tried to compile some old Borland Pascal 7.0 program but I could not even get the compiler past the following line:

uses OWindows, WinProcs, WinTypes, FileDlgs, Strings, WinDos, BWCC, ODialogs, wincrt;

What do I have to do to get this program compiled?

molly:

--- Quote from: Tommek on September 17, 2017, 01:05:27 am ---I have read a lot now that Free Pascal is supposed to have high degree of compatibility with Turbo Pascal and Borland Pascal 7.0. So I tried to compile some old Borland Pascal 7.0 program but I could not even get the compiler past the following line:

--- End quote ---
That is true for the language. {$MODE TP} should be compatible with the pascal language as used in TP.


--- Quote ---uses OWindows, WinProcs, WinTypes, FileDlgs, Strings, WinDos, BWCC, ODialogs, wincrt;

--- End quote ---
However, Free Pascal does not get shipped with these units as some of them are platform specific. If you have their source-code they would probably compile otherwise a rewrite would be necessary.


--- Quote ---What do I have to do to get this program compiled?

--- End quote ---
Make sure you have the source-code of the units that are included in your program or rewrite/replace.

My memory is very hazy when it comes to the names of these units, perhaps someone else is able to shed a light on that but i believe some of them are windows 3.x units and afaik Free Pascal does not support win 3.x.

Akira1364:
Which units can't it find?

Tommek:
Thanks for the answers. So as I understand, compatibility only refers to the compiler itself, not to the compiler system (including units, resource files etc.), right?

Back to the problem: Almost none of the units can be found:
OWindows, WinProcs, WinTypes, FileDlgs, WinDos, BWCC, ODialogs

BP7 only contains the compiled versions of the units. Source files seem to be hard to find, at least I couldn't find any on the internet. Instead of rewriting the units, I guess rewriting the application makes more sense, doesn't it?

So any suggestions where one could get source code for the units or find some advice how to convert the application? I am surprised that I find so little information on the net. I can't be the first to convert old BP7 applications, ... or maybe I am?! :-)

wp:

--- Quote from: Tommek on September 17, 2017, 03:49:41 pm ---Instead of rewriting the units, I guess rewriting the application makes more sense, doesn't it?

--- End quote ---
Absolutely. Writing an application with Delphi or Lazarus is much easier than with the old OWL library of BP.

Navigation

[0] Message Index

[#] Next page

Go to full version