Saturday, December 20, 2008

Install Borland Turbo C++ in Ubuntu

Normally in India majority of schools and colleges have Turbo C/C++ as the default IDE. Most students are younger than the Turbo C/C++ compiler they use at colleges. I checked our college's Turbo C++ and it was made in 1993. Back then George Bush Sr. was the president of the USA and Windows 95 was still 2 yrs away.

I tried using Turbo C in Vista but I couldn't use it in maximized state. Then I tried Wine but it didn't work, I wondered why, but then someone suggested this amazing piece of software called DOSBOX which helps run software made for your dad when he was young and had long hair.

Go to the terminal:sudo aptitude install dosbox

APT will now download and install DOSBOX.

You can also use Synaptic as usual.

Download Turbo C/C++ here
You have to register, but they don't nag and it is hasslefree.

Unpack the achieve

Keep the installation files inside a folder of your home directory named "setup".
Open up dosbox, its under Applications > Games

Type in :

Code:

mount c ~
c:
cd setup
install.exe

This will start the setup of Turbo C.

After setup is finished , do this:

Code:

c:
cd TC\bin
tc.exe

Now everytime you want to run Turbo C++ start DOSBOX and then type in the following:

Code:

mount C ~
c:
cd TC\bin
tc.exe

To maximise full screen hit 'Alt+Enter' and to go back to medium size again hit 'Alt+Enter'. DOSBOX has a habit of capturing the mouse pointer, once you click within DOSBOX you cannot move it away from the winow. To go back to Ubuntu hit 'Alt+Enter' twice.'Alt+X' will close Turbo C.Hope I have helped :)

@ Sujoy the Enlightened One!Please read the article carefully. In India Turbo C is unfortunately the default compiler. If you use anything except it you will be failed!I do not recommend it but since it is a necessity for schools and colleges, I have provided a method to use it in Ubuntu.

no no there weren any zip files at al !!! i gave in the command apt-get install dosboxit downloaded the package and opened the dosbox emulator terminal directly !! :(i found it on application>games as well...

But i'm facing a problem.I'm nt able to get the header files.So program is not compiling.How to clearly set the path,u hav to tell me...I'm nt able to munt as per the instructions above this page.The error i'm getting is "You are still on drive Z:,change to a mounted drive with C:."and also "Usage MOUNT Drive-Letter Local-Directory"How to fix.. Help me.

Moreover i'm ashamed by this comment.

_________________________________________________"November 24, 2009 2:00 AMJoeSchmoe said...are you people crazy? Turbo C on Linux? seriously what the fuck is wrong with you? Turbo C is the biggest piece of shit ever.

tell your instructors who insist on Turbo C to fuck off. Use CodeBlocks or any other free standard C compiler. make your code standard C, and it will be able to be compiled in their crap Turbo.

i dont know what is wrong with India, that all your colleges insist on Turbo C. the admins, must be getting bribes and kickbacks from Borland, that's got to be the only excuse.

or maybe its a larger conspiracy to keep you people hopelessly incompetent, so that the only jobs you'll take from the West are our call centers and tech support?"_________________________________________________

Can we do something to create some attention. Here education sucks. Illiterate idiots still rules our educational upper circles. can we make any difference. A movement for good.

in ubuntu dosbox while working in compiler the arrow keys are not working we have to use mouse & backspace button to edit the program in c & c++ please tell me the solution on my email id : rajesh_gos@rediffmail.com

HI!!!I TRIED THE METHOD...ITS GREAT...BUT I HAVE TWO PROBLEMS1. THAT THAT TC 1.01 IS THE "C" BUT NOT C++2. IF I INSTALL TURBO C++ 3.0 THIS METHOD,IT INTALLS,BUT AT COMPILATION OF THE PROGRAM,IT DOESN'T INCLUDES THE HEADER FILES

HIThanks for great tutorial!I have TurboC++1.01 installed on DOSBox in Ubuntu10.04 LTSLLynx now (dl from http://www.uv.tietgen.dk/staff/mlha/download/dos/). I haven't tried it yet but am sure it will work!?

I agree with JoeSchmoe about the need for TC though but I do not know how to avoid the need for graphics.h in those C/C++ programs using BGI TC? I am going to look into getting this sorted so I can do graphics coding in C/C++ with gcc & g++ without DOSBox.

But for now I can at least use C/C++ turboC code in Ubuntu with DosBox.

hi friends ...i am using ubunutu 10.10.and there is no windows in my laptop.i don't want to use gcc because it does not contain header files like conio.h.can anyone help how to get turbo c in my ubntu . i have downloaded dosbox and wine.thanks in advance...................

That's exactly what I was looking for. Here in Male' we've got Indian Teacher, teaching Indian Methods on this piece of software. I use Uberstudent and nothing else. Now finally I can finish my assignment :D Thanks