You are not logged in.
I've been learning C++ for a week or two now, getting a good hang of it. I just use Kate as my editor and g++ to compile the program. It all runs fine under linux, but I'm not sure how to make a program to execute easily (terminal) in windows. So if the program runs in terminal on Linux should it run in a DOS window on windows? What do I need to do to allow my little apps to work properly under windows?
Offline
I've been learning C++ for a week or two now, getting a good hang of it. I just use Kate as my editor and g++ to compile the program. It all runs fine under linux, but I'm not sure how to make a program to execute easily (terminal) in windows. So if the program runs in terminal on Linux should it run in a DOS window on windows? What do I need to do to allow my little apps to work properly under windows?
You have to recompile your source code under Windows.
Offline
Thanks for the help. You can tell I'm a complete beginner when it comes to programming.
Offline
depending on the app, you might want to take a look at cygwin, else you will hit many (mainly posix compliance, unix semantics, and api differences) porting issues that could be too much hassle if you're just beginning to learn. cygwin alleviates all that. I used it back in the day (before windows went through my window ) for exactly the same purpose.
Last edited by lloeki (2007-05-04 08:35:23)
To know recursion, you must first know recursion.
Offline
depending on the app, you might want to take a look at cygwin
MinGW is another alternative.
Offline
I'd recommend you using MinGW as a compiler for windows when you used linux to program and test your sources.
Though, some calls, defines and includes are different in windows and linux, but you can check this by checking the compiler environment
#ifdef __WIN32__
...
#endif
#ifdef __LINUX__
...
#endif
also WINBUILD instead of __WIN32__ and LINUX instead of __LINUX__ should work properly.
// STi
Ability is nothing without opportunity.
Offline