TurboC++ on Linux
Ever tried running TurboC++ on Linux? Hate CBSE for still using such a sucky compiler even though it has gone out of use after 13 years? DosEMU giving nightmares and not working right? DosBOX has come to your rescue.
Seriously, after trying years to make TurboC++ work on DosEMU using various configurations, I finally gave up and tried to use DosBox, something that was originally meant for playing DOS games, but works like a charm for TurboC++.
Anyway, to get TurboC++ working on Linux:
- Get Linux: Like, DUH!
- Get TurboC++: Get it here
- Get DosBOX: Get it here. I've also compiled RPMs for DosBOX on FC5:
- Install DosBOX See DosBox documentation on its site
- Integrate TurboC++ with DosBOX:
- Unzip the TurboC++ zipfile into ~/tc. It will create a directory called tc inside ~/tc. Rename this directory to something like INSTALL or something.
- Run DosBOX and the enter the following code:
It will show an installation screen. In the first screen, ensure that the source media is C, not A. On the other screen, The Default Works Just Fine™.mount c ~/tc c: cd install install
- When the installation is done, issue the following commands:
This will launch TurboC++. Go to Options->Directories. In Includes, put ";C:\TC\CLASSLIB\INCLUDE" ath the end (without the quotes). In Libraries, put ";C:\TC\CLASSLIB\LIB" at the end (without the quotes). This isn't required, but this allows you to use the predefined classes, like vectors, queues, stacks, lists, string etc., offered by C++. Exit TurboC++cd \tc\bin tc
- (Optional) Make DosBOX autorun TurboC++:
Open ~/.dosboxrc in your favourite editor and put the following in it:@echo off echo Setting default sound mixers SET BLASTER=A220 I7 D1 H5 T6 SET ULTRASND=240,3,3,5,5 SET ULTRADIR=C:\ULTRASND echo Mounting TurboC++ directory as C: mount c ~/dosbox echo Setting required environment variables set FILES=20 c: set PATH=c:/tc/bin;c:/bin;z:/ echo Running TurboC++ tc @echo Exiting... exit
Now, everytime you run DosBOX, it will automatically open up TurboC++. You can create a shortcut or something on the desktop for running DosBOX. Though, as the great thinkers of the 21st century have said, Your Mileage May Vary™.