tags:

views:

103

answers:

5

Hi,

I am a C/C++ developer. I have never done C++ programming on UNIX, I have done only on windows. I want to practice C++ on Unix. (Because all big companies ask C++ with Unix). I have a laptop on which i do not want to install any other OS (because i have installed very important software on it and i don't have setups)

So, I searched and found CygWin which is Unix emulator for Windows. I am thinking to practice C++ on this. Please help me, how can I practice/learn in more close to the environment(Unix Environment) that is used in Big companies like IBM. What will be the difference between Unix and Cygwin?

+1  A: 

You should just install a free virtualised system under windows. Then put a real Unix/Linux in it.

Ones I use are

  1. Virtual Box
  2. VM Ware
  3. Virtual PC

The last one is built into Windows 7 already.

Preet Sangha
A: 

Download VirtualBox, then install a Unix flavour of your choice. Personally, I'm a big fan of Ubuntu. :)

Though Cygwin is pretty great at what it does, it's not going to be the same as working directly on a Unix machine.

Throlkim
+2  A: 

You may find this link helpful: http://en.wikipedia.org/wiki/Cygwin

They provide a lot of useful information to help you better understand what will be going on.

My advice would be to virtualize your own environment (with Ubuntu inside Virtual Box for example). Google them to get the download links

You can experiment to your heart's content.

Misty May
+1  A: 

Cygwin just has a subset of the functionality of a real Unix OS and there are certain things which you need to know about the Unix OS that cygwin will not tell you. It depends what you need to be able to do on a unix machine. As it has a different file system and doesn't have the same directory structure as Windows. For example there isn't a 'Program Files' in Unix, and you may need to know where a lot of files are situated, which you will not find out with cygwin. Though I do agree, if you don't want to install another OS on your machine, you can install it in a Virtual machine, or to simply use it every now and then you could simply use a liveCD

lavamunky
A: 

Cygwin is mainly a POSIX emulator - where POSIX is some lowest common denominator of UNIX and other systems. This makes it possible to have cleanly written POSIX applications running on Windows.

You will find all things that are specified in POSIX (like the filesystem hierarchy, /proc filesystem, signals, sockets) in cygwin as well and it will behave within the POSIX specs. But as lots of things are unspecified in POSIX, it will not be 100% like any other real Unix system.

For example, on most UNIX systems, you can delete a file while it is open (which will make it a temporary file without name which will be deleted when the last user closes it). Windows does not allow this (and POSIX does not mandate it either); so on Cygwin you will have Windows file semantics (you cannot delete a file while it is open).

Same goes for allowed characters in filenames, filename case sensitivity, and (of course) all the additional APIs (besids POSIX) that most real UNIXes offer but which are not included in Cygwin.

(At least you can have a X server in Cygwin, which does again only support the basic X operatoins).

mihi