dos-tpdemos
dos-tpdemos copied to clipboard
Retro programming in Borland Turbo Pascal 7
dos-tpdemos
Retro programming in Borland Turbo Pascal 7

Prerequisites
To build and run the Borland Turbo Pascal demos, you must first install the following tools:
Install DOSBox
openSUSE
$ sudo zypper install dosbox mtools p7zip-full
Ubuntu
$ sudo apt install dosbox mtools p7zip-full
Configuration
When starting dosbox the first time, the configuration file ~/.dosbox/dosbox-0.74-2.conf will be generated
Install Borland Turbo Pascal
-
Download
Borland Turbo Pascal 7.1 (3.5).7z -
Create a directory which will contain the DOS C: drive
$ mkdir ~/DOSBox -
Extract the downloaded Turbo Pascal archive
$ 7z x "Borland Turbo Pascal 7.1 (3.5).7z" -
Extract the Borland Turbo Pascal disk images
$ cd "Borland Turbo Pascal 7.1 (3.5)"/ $ mkdir tpsetup $ for i in *.img; do echo $i; mcopy -m -i $i :: tpsetup; done -
Move the extracted files to the DOS C: drive
$ mv tpsetup ~/DOSBox/ -
Configure DOSBox
Edit
~/.dosbox/dosbox-0.74-2.confand add the following autoexec options[autoexec] mount c ~/DOSBox path %PATH%;C:\TP\BIN c: -
Start
dosboxand execute the Borland Turbo Pascal installation program$ dosbox C:\> cd tpsetup C:\TPSETUP> install.exeIn the installation program, select the following options
Enter the SOURCE drive to use: C Enter the SOURCE Path: \TPSETUP Install Turbo Pascal on a Hard Drive Start Installation
Build demos
Link the dos-tpdemos git repository to the DOS C: drive
$ ln -s ~/git/github/dos-tpdemos ~/DOSBox/tpdemos
Build demos from DOS terminal
-
Execute build script
C:\TPDEMOS> buildall.batThe demos will be located in the
C:\TPDEMOS\BUILDdirectory -
Run demo
C:\TPDEMOS> build\demo01.exe
Build demos from Borland Turbo Pascal IDE
-
Start Borland Turbo Pascal IDE
C:\TPDEMOS> turbo -
Configure Borland Turbo Pascal
Press
ALT+Ofor optionsSelect
Directoriesand type in the following directoriesEXE & TPU directory: C:\TPDEMOS\BUILD Include directories: C:\TPDEMOS\ASSETS Unit directories: C:\TP\UNITS;C:\TPDEMOS\SRC\LIBSelect
Compilerand the following options[X] 286 instructionsSelect
Environment,Preferencesand the following options[ ] Auto save [ ] Change dir on openSelect
Environment,Editorand the following options[ ] Create backup filesSelect
Save -
Open demo source file
Press
F3to open file -
Build demo source file
Press
F9to build file -
Run demo
Press
ALT+RandRto run demo
License
Licensed under MIT license. See LICENSE for more information.
Authors
- Johan Gardhage
Screenshots
