古代历史:任何版本的 Turbo Pascal 都能够在 286 或更高版本上编译为保护模式吗?
我记得 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 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
是的。 Borland Pascal 7 支持 dos 和 win 3.x 的 16 位 PM 程序。但它不再可用(并且商业许可证在二手市场上非常昂贵)。为了使其与 OS/2 一起工作,您可能需要重新设计整个扩展器模型以匹配 OS/2。 (例如 EMX)它可能已经完成,但结果可能会很笨拙地说最好(并且基于 EMX 而不是本机)
但是有两个 TP/Delphi 克隆几乎支持整个 TP 方言,甚至支持部分 Delphi:
虽然两者都会生成 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:
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.
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.