古代历史:任何版本的 Turbo Pascal 都能够在 286 或更高版本上编译为保护模式吗?

发布于 2024-10-31 01:30:58 字数 151 浏览 5 评论 0原文

我记得 1990 年的 Turbo Pascal 6.0 有几个针对 80286 特定功能的编译器开关,所有开关都注明它们只能在实模式下工作,而不能在保护模式下工作。 Turbo Pascal 曾经有过可以编译为 286 保护模式的编译器吗? (这个功能可以用来编写OS/2本机程序吗?)

I remember 1990's Turbo Pascal 6.0 which had several compiler switches for 80286-specific features, all with a note that they work only in Real Mode but not in Protected Mode. Did Turbo Pascal ever have a compiler that could compile to 286 Protected Mode? (Could this feature be used to write OS/2 native programs?)

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

听风念你 2024-11-07 01:30:58

是的。 Borland Pascal 7 支持 dos 和 win 3.x 的 16 位 PM 程序。但它不再可用(并且商业许可证在二手市场上非常昂贵)。为了使其与 OS/2 一起工作,您可能需要重新设计整个扩展器模型以匹配 OS/2。 (例如 EMX)它可能已经完成,但结果可能会很笨拙地说最好(并且基于 EMX 而不是本机)

但是有两个 TP/Delphi 克隆几乎支持整个 TP 方言,甚至支持部分 Delphi:

  • 虚拟帕斯卡。近十年来没有积极开发,但仍然可以使用并且是免费软件。 VP 社区的剩余部分在这里 Delphi 支持直到 D2 左右。
  • Free Pascal 仍然受支持,Delphi 支持是混合版本,当前重心在 D2006/ 2007年。 OS/2 移植仍然受支持,但进展缓慢

虽然两者都会生成 386+ 代码,如果您想要移植大量 16 位汇编程序,这可能会成为问题(但这些可能需要审查以进行更改) 286 保护模式)

一般来说,我建议使用 Free Pascal,但由于 VP 的 OS/2 端口曾经非常流行,在这种情况下,至少也值得看看 VP。特别是如果项目的范围和时间有限。从长远来看,Free Pascal 作为仍然活跃的项目是更好的选择。

Yes. Borland Pascal 7 supported 16-bit PM programs for dos and win 3.x. But it is no longer available (and commercial licenses are very expensive on the 2nd hand market). To make it work with OS/2 you probably need to rework the entire extender model to match OS/2. (e.g. EMX) It might have been done, but the result will probably be clumsy to say the best (and EMX based rather than native)

However there are two TP/Delphi clones that support nearly the entire TP dialect, and partial Delphi even:

  • Virtual Pascal. Out of active development for nearly a decade, but still working and freeware. What's left of the VP community is here The Delphi support is till about D2.
  • Free Pascal is a still supported, and the Delphi support is a mix of versions, with the current gravity point at D2006/2007. The OS/2 port is still supported, but only proceeds slowly

Both generate 386+ code though, and that might be a problem if you have large amounts of 16-bit assembler you want to port (but these probably need review for the change to 286 protected mode too)

In general, I would advise Free Pascal, but since the OS/2 port of VP was once very popular, in this case it might be worth to at least have a look at VP too. Specially if the project is limited in scope and time. Long term, Free Pascal, as still active project is a better bet.

温柔嚣张 2024-11-07 01:30:58

Jonathan de Boyne Pollard 的 16 位系列 API 工具包 能够通过 Turbo Pascal 链接到(我忘记了具体是哪个版本,它可能需要修补 tpc.exe)才能创建 16 位 OS/2 控制台模式程序。

我刚刚在这里找到了补丁工具包的链接 - 它归功于德国计算机杂志 C'T。

Jonathan de Boyne Pollard's 16-bit Family API Toolkit was able to be linked to by Turbo Pascal (I forget exactly which version, it may have required patching tpc.exe) to create 16-bit OS/2 console-mode programs.

I've just found a link to the patch toolkit here - it credits the German computer magazine C'T.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文