OK. So I have this very nice C++ code written and it works wonderfully on a Windows based system. However, the thing is I will need this code to ultimately work on a UNIX system. I have zero experience with Unix (since I have only used Windows) so I need to know what to do to get it working off of Windows.
Sorry if that didnt make too much sense. I am computer literate, just not SUPER computer literate.
We need more details about the application. Does it use mfc, or any other windows centric code in it?
As far as I can tell it doesnt have any windows centric code. Its a simple program that basically creates a text file that will be read into the unix system. I had to work on the windows system because I would not be guaranteed any extended amount of time on the Unix systems here at work.
Download Ubuntu, install it in a virtual machine, install build-essential and see what happens when you compile.
If the code is simple you'll just have to write a makefile, otherwise you might have to set up a build system like Scons. If there's any GUI code, you'll want to port it to GTK+ or Qt. It's hard to give more advice about how to proceed without knowing if there were any problems compiling it.
Janin's way is likely best. It doesn't mess with your regular desktop and you can get a free vmware player and ubuntu image for it from the vmware website.
Whats the easiest way to write a makefile? Up to this point I have done all my programming using Visual Studio. Could I still use this or am I going to have to seek other utilities?
As for my code, its a fairly simple code. No fancy UI or anything, just basic array manipulation and some small file I/O. I see no reason why it shouldnt work on any other platform. Right now I have an .exe file that does what I want it to do on windows and I just want to get it to a form that will work on a unix system.
Whats the easiest way to write a makefile? Up to this point I have done all my programming using Visual Studio. Could I still use this or am I going to have to seek other utilities?
As for my code, its a fairly simple code. No fancy UI or anything, just basic array manipulation and some small file I/O. I see no reason why it shouldnt work on any other platform. Right now I have an .exe file that does what I want it to do on windows and I just want to get it to a form that will work on a unix system.
Thanks for your help so far though.
A makefile is a text-based file for compiling projects, and is the most popular compilation system in UNIX. If your project is simple, you can just hand-write it yourself. In fact, if your project is *very* small (say, less than 3 .cpp files) you can just use g++ directly as:
Janin's advice is sound. When I was working on my CS degree, the University required all my work to compile in UNIX. This means you actually have to compile your code on a UNIX/LINUX box, and it doesn't take anything more fancy than using make and the GNU c/c++ compiler. Make is easy to learn, so that shouldn't be a problem.
If you're using VS to manage your code, make sure you aren't setting up your projects to be run under Windows, or VS will add a bunch of extensions and extra files that will bork the UNIX version. Just make it a vanilla project.
Posts
As far as I can tell it doesnt have any windows centric code. Its a simple program that basically creates a text file that will be read into the unix system. I had to work on the windows system because I would not be guaranteed any extended amount of time on the Unix systems here at work.
I have 549 Rock Band Drum and 305 Pro Drum FC's
REFS REFS REFS REFS REFS REFS REFS REFS
If the code is simple you'll just have to write a makefile, otherwise you might have to set up a build system like Scons. If there's any GUI code, you'll want to port it to GTK+ or Qt. It's hard to give more advice about how to proceed without knowing if there were any problems compiling it.
As for my code, its a fairly simple code. No fancy UI or anything, just basic array manipulation and some small file I/O. I see no reason why it shouldnt work on any other platform. Right now I have an .exe file that does what I want it to do on windows and I just want to get it to a form that will work on a unix system.
Thanks for your help so far though.
I have 549 Rock Band Drum and 305 Pro Drum FC's
REFS REFS REFS REFS REFS REFS REFS REFS
A makefile is a text-based file for compiling projects, and is the most popular compilation system in UNIX. If your project is simple, you can just hand-write it yourself. In fact, if your project is *very* small (say, less than 3 .cpp files) you can just use g++ directly as:
Here's a nice tutorial on how to make a small Makefile. I prefer to name mine "Makefile" (capital M), so I can just type "make" instead of "make -f <makefile here>".
Once you have a virtual machine configured, try building a few hello-world apps that just print to the terminal or something to get the hang of G++.
If you're using VS to manage your code, make sure you aren't setting up your projects to be run under Windows, or VS will add a bunch of extensions and extra files that will bork the UNIX version. Just make it a vanilla project.