Turbo C++ for ubuntu/linux using dosbox

turbo c ubuntu,linux using dosbox

The target of this article is to help C++ learners to run Turbo c++ under Ubuntu (Linux) O/s.

Turbo c++ is a quite generally utilized compiler for C and C++ in most Indian schools  and universities/colleges (SPECIALLY DELHI UNIVERSITY). Despite the fact that there are numerous different compilers like Eclipse Cpp (not to be confounded for Eclipse IDE for Java), CINT and so on accessible on the house and offer better functional and intriguing IDE characteristics, numerous schools and universities are even now utilizing Turbo c++ which is an old fashioned compiler. As scholars are never presented to such new engineering upgrades, they are not sure about utilizing most recent C++ compilers.

Also Read: How to Download and Install Turbo C/C++ on Windows 10 32/64 bit

The excuse for why Turbo C++ can’t run under Ubuntu is  in light of the fact that turbo C++ is constructed for Dos. Yet there is a method for doing it. The answer for this issue is utilizing Dosbox, which is a Dos emulator for Linux O/s. Dosbox has a repution of being extremely light and stable emulator for Dos based projects and was created with the intension of utilizing it to imitate Dos amusements and systems on linux frameworks.

You may be asking why I picked Dosbox in place of Wine, well thats since wine can’t handle dos programs like Turbo C++, and I would say wine is  overwhelming on the framework as it is essentially implied for Windows based projects.

Also Read: How to Download and Install Turbo C/C++ on Windows 10 32/64 bit

Steps for installation….

Step 1) INSTALLATION

Download DOSBox Emulator from USC [Ubuntu Software Center].

download dosbox from ubuntu software centre

                                                OR


Run this command in terminal(Ctrl+Alt+T): 

code:

 
sudo apt-get install dosbox

When your done installing Dosbox you will now require the turbo C++ installation setup which could be downloaded from here(download).(LINK UPDATED)

Unzip the setup zip folder and place the files in home/your-user-name directory (* Necessary)


Now open up Dosbox and Type in the below code (in separate lines):


Code:

mount c ~
c:
cd setup
install.exe

mount dosbox to run turbo c

     This will start the setup of  Turbo C++.

turbo c installation setup
     Here choose the destination drive as c and source path as setup in the next window.

source drive to use turbo c


   Select “Start Installation” in the below window.


start installation
Turbo C++ is now installed on Dosbox. You may consider checking it by executing the following code on Dosbox (in separate lines):


Code:
c:

cd TC\bin

tc.exe


Step 2) Creating the configuration file


creating configuration file

Run this command in DOSBOX to generate the configuration file which will be stored as: /home/user-name/dosbox.conf.  Ensure you enter your system user-name in place of “your-username” in the below code:

code: 


config -writeconf /home/your-username/dosbox.conf



Step 3) Creating auto-mount and emulating in fullscreen.


auto mount in full screen

Open dosbox.conf that we created earlier in any text editor, which you will find it under home/your-username, and configure DOSBOX for auto-mount.



Add the following lines at the end of the configuration file as shown in the above highlight.

code: 

mount c ~ /home/your-username/
C:
CD TC
CD BIN
TC


Now to set the default screen size to full-screen, find the word fullscreen in the same file (dosbox.conf)  and change its value to true:




Now you are done setting up the configuration file for Dosbox to auto-mount and emulate in fullscreen. Save the file and close it.

Step 4)  Deleting Ctrl+F9 key to avoid shutdown of Dosbox

And in the end you will have to delete a key from the Dosbox keymapper : Ctrl+F9
Since Ctrl+F9 is a Shutdown key in Dosbox you may feel very irritated with it, as the same key is used to compile a program in Turbo C++.

To work-around this issue, open dosbox and hold Ctrl+F1. Now in the window, select theshutdown option on the right hand side bottom, click on delete and then save and exit. This should remove the keymap to Shutdown DOSBOX.



dosbox key mapping


Step 5) Creating Launcher

To make things more convenient, we will create a launcher so that you can run your compiler just by double clicking on it. Here’s how you can do it: 

Right click on the desktop and select create launcher.
Name: Turbo c++
command: dosbox -c TC.EXE -c EXIT



creating launcher for dosbox

and now its all set for you to enjoy Turbo C++ on Ubuntu./linux
Also Read: How to Download and Install Turbo C/C++ on Windows 10 32/64 bit

Note: Since we have set Dosbox to open in fullscreen you may consider the Alt+Enter key to use it under seamless mode  .
  


If you have any trouble on the installation procedures contact me on www.facebook.com/turbocforwindows8
                                        

Be the first to comment on "Turbo C++ for ubuntu/linux using dosbox"

Leave a comment

Your email address will not be published.


*