Porting to Win32 -- Which Method?

Hello, today I’m relatively new to a lot of things, namely SDL, OpenGL,
KDevelop, and multi-platform coding.

I have a Win98 box and a Linux box. I’m using my Linux box for
development for a number of reasons. I wrote a simple SDL + OpenGL app
in C++, with a full automake/configure script that was generated by
KDevelop. I also set up a local CVS tree. The app is right now very
simple, but will become my very complex senior project.

It is imperative that I port it to Win32 as well, as my advisor will not
be able to run Linux binaries. Plus, I’d really like to show off to my
friends.

What method would anyone recommend for thus setup? MinGW? Cross
Compiling? Something else? What is the easiest method for generating
Win32 binaries? I may also need SDL-image, but I’m not sure yet. My
compile flags currently look like this:

c++ -O2 -O0 -g3 -Wall -fno-exceptions -fno-check-new
-I/usr/X11R6/include -I/usr/include/SDL -D_REENTRANT -DHAVE_OPENGL -o
phalanx spearmodel.o main.o -L/usr/X11R6/lib -lGL -lGLU -L/usr/lib
/usr/lib/libSDL.so -lm -lX11 -lXext -ldl -lpthread -lXxf86dga -lXxf86vm
-lXv

Keep in mind, I’m willing to ditch KDevelop in favor of emacs if adding
new targets to the makefile or something is necessary and may bork
KDevelop. It’s really powerfull as far as handling nifty OOP stuff, but
seems to have little or no ability to add make targets and advanced
build stuff.

–Aaron

Hi!
If this is your senior project, and you’re the only one being creative on a
creative system, the other guys and gals do a project, too, on a
virus-computer (windows==virus). Do they also use C++?
If so, which IDE do they use? If it’s MSVC, and if you don’t use X-related
stuff, it shouldn’t be a problem … I mean, my last Demo was created
partly under MacOSX and partly under win32. We had to change a ‘#define
WINDOOF’ and schwupp, it compiled under win32.
Just check what stuff related to LinuX/X you use, replace it by portable
code (ansi-C/iso-C++) and give it a try under win32.
St0fF 64

At 08:30 28.01.2002 -0500, you wrote:>Hello, today I’m relatively new to a lot of things, namely SDL, OpenGL,

KDevelop, and multi-platform coding.

I have a Win98 box and a Linux box. I’m using my Linux box for
development for a number of reasons. I wrote a simple SDL + OpenGL app
in C++, with a full automake/configure script that was generated by
KDevelop. I also set up a local CVS tree. The app is right now very
simple, but will become my very complex senior project.

It is imperative that I port it to Win32 as well, as my advisor will not
be able to run Linux binaries. Plus, I’d really like to show off to my
friends.

What method would anyone recommend for thus setup? MinGW? Cross
Compiling? Something else? What is the easiest method for generating
Win32 binaries? I may also need SDL-image, but I’m not sure yet. My
compile flags currently look like this:

c++ -O2 -O0 -g3 -Wall -fno-exceptions -fno-check-new
-I/usr/X11R6/include -I/usr/include/SDL -D_REENTRANT -DHAVE_OPENGL -o
phalanx spearmodel.o main.o -L/usr/X11R6/lib -lGL -lGLU -L/usr/lib
/usr/lib/libSDL.so -lm -lX11 -lXext -ldl -lpthread -lXxf86dga -lXxf86vm
-lXv

Keep in mind, I’m willing to ditch KDevelop in favor of emacs if adding
new targets to the makefile or something is necessary and may bork
KDevelop. It’s really powerfull as far as handling nifty OOP stuff, but
seems to have little or no ability to add make targets and advanced
build stuff.

–Aaron


SDL mailing list
SDL at libsdl.org
http://www.libsdl.org/mailman/listinfo/sdl

I’m the only one writing my project, so I can use any compiler I want.
It has to compile on Win32, however. I don’t know how to get the OpenGL
stuff compiling without linking with X. Is there any way to make the
autoconf scripts include libraries different in Linux and Win32?

I’ve never written really portable code before, and never made GNU
automake and autoconf scripts before. I had KDevelop generate them for
me.

Thanks.

–Aaron Traas

St0fF 64 wrote:>

Hi!
If this is your senior project, and you’re the only one being creative on a
creative system, the other guys and gals do a project, too, on a
virus-computer (windows==virus). Do they also use C++?
If so, which IDE do they use? If it’s MSVC, and if you don’t use X-related
stuff, it shouldn’t be a problem … I mean, my last Demo was created
partly under MacOSX and partly under win32. We had to change a ‘#define
WINDOOF’ and schwupp, it compiled under win32.
Just check what stuff related to LinuX/X you use, replace it by portable
code (ansi-C/iso-C++) and give it a try under win32.
St0fF 64

At 08:30 28.01.2002 -0500, you wrote:

Hello, today I’m relatively new to a lot of things, namely SDL, OpenGL,
KDevelop, and multi-platform coding.

I have a Win98 box and a Linux box. I’m using my Linux box for
development for a number of reasons. I wrote a simple SDL + OpenGL app
in C++, with a full automake/configure script that was generated by
KDevelop. I also set up a local CVS tree. The app is right now very
simple, but will become my very complex senior project.

It is imperative that I port it to Win32 as well, as my advisor will not
be able to run Linux binaries. Plus, I’d really like to show off to my
friends.

What method would anyone recommend for thus setup? MinGW? Cross
Compiling? Something else? What is the easiest method for generating
Win32 binaries? I may also need SDL-image, but I’m not sure yet. My
compile flags currently look like this:

c++ -O2 -O0 -g3 -Wall -fno-exceptions -fno-check-new
-I/usr/X11R6/include -I/usr/include/SDL -D_REENTRANT -DHAVE_OPENGL -o
phalanx spearmodel.o main.o -L/usr/X11R6/lib -lGL -lGLU -L/usr/lib
/usr/lib/libSDL.so -lm -lX11 -lXext -ldl -lpthread -lXxf86dga -lXxf86vm
-lXv

Keep in mind, I’m willing to ditch KDevelop in favor of emacs if adding
new targets to the makefile or something is necessary and may bork
KDevelop. It’s really powerfull as far as handling nifty OOP stuff, but
seems to have little or no ability to add make targets and advanced
build stuff.

–Aaron


SDL mailing list
SDL at libsdl.org
http://www.libsdl.org/mailman/listinfo/sdl


SDL mailing list
SDL at libsdl.org
http://www.libsdl.org/mailman/listinfo/sdl

HI!
What exactly do you mean by

I don’t know how to get the OpenGL
stuff compiling without linking with X.

?? Do you use “glX.h” ? If it’s that then I probably don’t know a lot and
would have to figure it out myself. But as OGL is made to be portable then I
guess all you use with glX could also be done with SDL and in that case it
should be SDL! All Xserver negotiation-crap is what SDL is made for (I think)
and you just need to use it right. and then it should be no problem to
compile under win32, I’d also offer to give it a try with MSVC if you can’t get a
working ide under win (that happens…) … just need to convert the makefile
into a project file and then it should take a minute (if we’d have to change
too much in the config it could also take a whole night…).

St0fF–
St0fF 64 of N30PLA51A - love, code, composition, design …

GMX - Die Kommunikationsplattform im Internet.
http://www.gmx.net

Just on a “WTF isn’t this thing compiling note.” Make sure you have

#ifdef WIN32
#include <windows.h>
#endif
#include <gl/gl.h>

whenever you include gl.h (lots of compiler errors otherwise)On Fri, 2002-02-01 at 07:51, Aaron Traas wrote:

I’m the only one writing my project, so I can use any compiler I want.
It has to compile on Win32, however. I don’t know how to get the OpenGL
stuff compiling without linking with X. Is there any way to make the
autoconf scripts include libraries different in Linux and Win32?

I’ve never written really portable code before, and never made GNU
automake and autoconf scripts before. I had KDevelop generate them for
me.

Thanks.

–Aaron Traas

St0fF 64 wrote:

Hi!
If this is your senior project, and you’re the only one being creative on a
creative system, the other guys and gals do a project, too, on a
virus-computer (windows==virus). Do they also use C++?
If so, which IDE do they use? If it’s MSVC, and if you don’t use X-related
stuff, it shouldn’t be a problem … I mean, my last Demo was created
partly under MacOSX and partly under win32. We had to change a ‘#define
WINDOOF’ and schwupp, it compiled under win32.
Just check what stuff related to LinuX/X you use, replace it by portable
code (ansi-C/iso-C++) and give it a try under win32.
St0fF 64

At 08:30 28.01.2002 -0500, you wrote:

Hello, today I’m relatively new to a lot of things, namely SDL, OpenGL,
KDevelop, and multi-platform coding.

I have a Win98 box and a Linux box. I’m using my Linux box for
development for a number of reasons. I wrote a simple SDL + OpenGL app
in C++, with a full automake/configure script that was generated by
KDevelop. I also set up a local CVS tree. The app is right now very
simple, but will become my very complex senior project.

It is imperative that I port it to Win32 as well, as my advisor will not
be able to run Linux binaries. Plus, I’d really like to show off to my
friends.

What method would anyone recommend for thus setup? MinGW? Cross
Compiling? Something else? What is the easiest method for generating
Win32 binaries? I may also need SDL-image, but I’m not sure yet. My
compile flags currently look like this:

c++ -O2 -O0 -g3 -Wall -fno-exceptions -fno-check-new
-I/usr/X11R6/include -I/usr/include/SDL -D_REENTRANT -DHAVE_OPENGL -o
phalanx spearmodel.o main.o -L/usr/X11R6/lib -lGL -lGLU -L/usr/lib
/usr/lib/libSDL.so -lm -lX11 -lXext -ldl -lpthread -lXxf86dga -lXxf86vm
-lXv

Keep in mind, I’m willing to ditch KDevelop in favor of emacs if adding
new targets to the makefile or something is necessary and may bork
KDevelop. It’s really powerfull as far as handling nifty OOP stuff, but
seems to have little or no ability to add make targets and advanced
build stuff.

–Aaron


SDL mailing list
SDL at libsdl.org
http://www.libsdl.org/mailman/listinfo/sdl


SDL mailing list
SDL at libsdl.org
http://www.libsdl.org/mailman/listinfo/sdl


SDL mailing list
SDL at libsdl.org
http://www.libsdl.org/mailman/listinfo/sdl