Distributing SDL game

Hi all

What sdl files do I need to distrubute along with the my game’s .exe in
order for someone to run it on his/her pc?

Thanks
Don

It depends on the OS you want to distribute your game to…

If you targer Linux, I suggest you don’t include SDL at all since it’s
included in most distributions.

If it’s Windows, you only need to include SDL.dll. Of course, if you
use other SDL-related libraries (such as SDL_mixer or SDL_image) you
need to include the appropriate dll’s too (SDL_image needs a couple
dlls).

Hope it helps,
Ga?tan.On Sat, 04 Dec 2004 11:07:52 -0400, Donald wrote:

What sdl files do I need to distrubute along with the my game’s .exe in
order for someone to run it on his/her pc?

If you targer Linux, I suggest you don’t include SDL at all since it’s
included in most distributions.

Wrong!

Lots of distros include an SDL package, but not as default. Actually, I
don’t know any that install it, as a guarantee, by default, and then,
it won’t necessarily be configured to your liking. Always ship 3rd party
libraries with your Linux game, with the exception of things like glibc.

Only count on the distro to do the right thing if they are packaging
your game (i.e. - if you are installing a SuSE package on SuSE, then
SuSE will be smart enough to know to pull in the SDL dependency). If you
are packaging this as a generic binary for Linux distros, then you
should ship SDL yourself.

If you are shipping just the source code, assume the end user will
figure out what they need to go find.

(The advice about Windows was correct, though, and was probably what the
original user was asking for anyhow.)

–ryan.

Thanks for the correction.

What I meant is that SDL is easily installable system-wide on most of
the distributions I know of. I presupposed that most linux users could
install SDL themselves and would prefer it that way not to clutter
their system with one more SDL version. But I admit it’s only how I
thought things were. Since you are much more knowledgable on this than
me, I suppose I was wrong…

-Ga?tan.On Sat, 04 Dec 2004 20:50:32 -0500, Ryan C. Gordon wrote:

If you targer Linux, I suggest you don’t include SDL at all since it’s
included in most distributions.

Wrong!

Lots of distros include an SDL package, but not as default. Actually, I
don’t know any that install it, as a guarantee, by default, and then,
it won’t necessarily be configured to your liking. Always ship 3rd party
libraries with your Linux game, with the exception of things like glibc.

Only count on the distro to do the right thing if they are packaging
your game (i.e. - if you are installing a SuSE package on SuSE, then
SuSE will be smart enough to know to pull in the SDL dependency). If you
are packaging this as a generic binary for Linux distros, then you
should ship SDL yourself.

If you are shipping just the source code, assume the end user will
figure out what they need to go find.

(The advice about Windows was correct, though, and was probably what the
original user was asking for anyhow.)

–ryan.

‘.exe’, I’ll assume that your target platform is Microsofts OS. You’ll need to
include the SDL Dinamic Linked Library files, such as SDL.dll, SDL_image.dll,
SDL_sound.dll, etc … If you’re planning on distributing on UNIX/UNIX-like
Operating Systems I’d suggest just linking your progam staticly [sp?], unless
you’re 100% sure that your userbase has all the libraries your binary
requiress.

Anyhow good luck, and hope you enjoy using SDL.

Have fun,On Saturday 04 December 2004 07:07 am, Donald wrote:

What sdl files do I need to distrubute along with the my game’s .exe in
order for someone to run it on his/her pc?


Juan D. Espinoza

Juan D. Espinoza wrote:

If you’re planning on distributing on UNIX/UNIX-like
Operating Systems I’d suggest just linking your progam staticly [sp?], unless
you’re 100% sure that your userbase has all the libraries your binary
requiress.

actually, I liked the way the Unreal series has been done for linux.
they use a script that sets LD_LIBRARY_PATH to have the install dir first,
then in that dir is your libSDL.so and libSDL_image.so, etc…
so the user and replace the .so’s if they need/want to.
it avoids the static link problem and makes it rather easy to distribute
a game with all the libraries you see fit. It also satisfies the LGPL
without having to distribute source code or relinkable object files of
some sort.
In any case, this avoids having a huge binary…so updates to the game
can be smaller in size. I would expect development to be easier too.
plus, using to loki installer seems to make it work quite well.

-LIM-

Hi,

Gaetan de Menten wrote:

Thanks for the correction.

What I meant is that SDL is easily installable system-wide on most of
the distributions I know of. I presupposed that most linux users could
install SDL themselves and would prefer it that way not to clutter
their system with one more SDL version. But I admit it’s only how I
thought things were. Since you are much more knowledgable on this than
me, I suppose I was wrong…

That’s also partly a matter of opinion, or taste. IMHO, it just doesn’t
make sense to install SDL dlls for every SDL application, and is done so
only because Windows lacks a descent system for managing shared
libraries / multiple versions thereof.

IMHO, on Linux, it should suffice if you remind the user to install SDL
in the installer, in the readme, on the download page, or somewhere else
(preferably all of those).

Of course, with a commercial game, it might be good to research the ways
to install SDL on various distros, and include them in the installing
instructions. Even cooler, but also more work, would be to publish
various packages in rpm / deb / whatever format native to the various
distros, and have them depend on SDL. Even many open source games do this.

-Ga?tan.

-Sebastian

What sdl files do I need to distrubute along with the my game’s .exe
in
order for someone to run it on his/her pc?

‘.exe’, I’ll assume that your target platform is Microsofts OS. You’ll
need to
include the SDL Dinamic Linked Library files, such as SDL.dll,
SDL_image.dll,
SDL_sound.dll, etc … If you’re planning on distributing on
UNIX/UNIX-like
Operating Systems I’d suggest just linking your progam staticly [sp?],
unless
you’re 100% sure that your userbase has all the libraries your binary
requiress.

Anyhow good luck, and hope you enjoy using SDL.

There are licensing issues with compiling SDL statically into your
application, unless you also include the .o’s for your app, or your app
is LGPL compatible itself.

-bobOn Dec 5, 2004, at 1:10 AM, Juan D. Espinoza wrote:

On Saturday 04 December 2004 07:07 am, Donald wrote:

Sebastian Beschke wrote:

Of course, with a commercial game, it might be good to research the ways
to install SDL on various distros, and include them in the installing
instructions. Even cooler, but also more work, would be to publish
various packages in rpm / deb / whatever format native to the various
distros, and have them depend on SDL.

Please note that to support ONLY RedHat you’ll need to build almost 7
different rpm archives (different SDL libraries, libc, libstdc++…) and
it will not work if you want to use recent SDL features (for instance
the MMX probe functions of 1.2.7).

It’s a matter of fact that if you don’t have hundreds of hours/man to
spend on this there are only three solutions:

  • build from source (not applicable for closed source/commercial apps)
  • static link (with objects available for relink)
  • LD_LIBRARY_PATH & with local libraries built on an OLD architecture
    (used for instance also by Mozilla products)

There are still a LOT of Debian woody, RedHat 7, Mandrake 8, etc

If you plan to make your software usable for a clueless user you should
make it run “out of the box” also on those systems.

Otherwise we cannot complain that everyone use Windows…

Even many open source games do this.

They can support the sum of the distributions the project members use,
not every distribution.

Bye,
Gabry

If you publish for Linspire Linux, they will help you doing your
publishing package. In principle, you give them a binary of your game
and tell them what SDL_* libraries it depends on, and they fix/test
the rest. Really comfy…

/OlofOn Mon, 06 Dec 2004 12:56:33 +0100, Gabriele Greco <gabriele.greco at darts.it> wrote:

Sebastian Beschke wrote:

Of course, with a commercial game, it might be good to research the ways
to install SDL on various distros, and include them in the installing
instructions. Even cooler, but also more work, would be to publish
various packages in rpm / deb / whatever format native to the various
distros, and have them depend on SDL.

Please note that to support ONLY RedHat you’ll need to build almost 7
different rpm archives (different SDL libraries, libc, libstdc++…) and
it will not work if you want to use recent SDL features (for instance
the MMX probe functions of 1.2.7).

It’s a matter of fact that if you don’t have hundreds of hours/man to
spend on this there are only three solutions:

  • build from source (not applicable for closed source/commercial apps)
  • static link (with objects available for relink)
  • LD_LIBRARY_PATH & with local libraries built on an OLD architecture
    (used for instance also by Mozilla products)

There are still a LOT of Debian woody, RedHat 7, Mandrake 8, etc

If you plan to make your software usable for a clueless user you should
make it run “out of the box” also on those systems.

Otherwise we cannot complain that everyone use Windows…

Even many open source games do this.

They can support the sum of the distributions the project members use,
not every distribution.

Bye,
Gabry


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

Olof Bjarnason wrote:

If you publish for Linspire Linux, they will help you doing your
publishing package. In principle, you give them a binary of your game
and tell them what SDL_* libraries it depends on, and they fix/test
the rest. Really comfy…

/Olof

That’s pretty cool. Maybe some other distros would do this for you, too,
if you asked (and convinced them of your app’s value to the distro)…

-Sebastian