Mailinglist Archive: opensuse-buildservice (262 mails)

< Previous Next >
Re: [opensuse-buildservice] Conventions for game packages
  • From: Pavol Rusnak <prusnak@xxxxxxx>
  • Date: Mon, 03 Aug 2009 13:39:34 +0200
  • Message-id: <4A76CC76.1020800@xxxxxxx>
Vincent Petry wrote:

Other related questions to game packaging:
1) Currently I'm packaging a game (let's call it "thegame") that
only has one thegame.tar.gz archive, containing the source files and
data files. I've written a shell script that splits that file into
two separate thegame.tar.bz2 files and thegame-data.tar.bz2. I
included the shell script in the package sources for convenience. I
assume that it's a common practice. Can you confirm this ?

Well, not really. You don't have to split the upstream tarball into game
and game-data. It is only important to create two packages (one for the
game and one for the data).

2) When splitting the package, should I create one single package in
OBS containing both spec files (thegame.spec and thegame-data.spec),
or rather use two separate OBS packages "thegame" and
"thegame-data", each one with a single spec file ?

Your choice. If you use one package with two specs, you'd still need to
create game-data package and create a link to the first package. (OBS
discovers only packagename.spec file while building).

3) If there are two spec files for one single OBS package "thegame",
will the rebuilding of a package depended upon (ex: libSDL)
affect/trigger only the one spec file "thegame" or both "thegame"
and "thegame-data", given that only "thegame" depends on "libSDL" ?

See the point above. You still need to create a link package if you use
two specs in one package.

4) In the spec file for the data packages, the name is like
"thegame-data", but the target directory is still
"/usr/share/thegame". I can't use the %{name} macro in the
"thegame-data" spec file since its value is "thegame-data", so I
tried to add a macro at the beginning of the spec file with "%define
basename thegame", and specify the target directory as
"/usr/share/%{basename}. But it doesn't work, the value of
%{basename} is always empty.
I tried to define it at the top of the spec file, and also in the
%prep part, but it doesn't work. Same thing if I use "%global
basename thegame". What did I do wrong ?

Defining the macro somewhere at the beginning of the file should work.
(%define basename thegame). I'm not sure what is causing the problem.
Maybe the basename macro is reserved for something else. Try using
another name for the macro (e.g. gamename). If it still fails, please
send me a spec file (or link to OBS).


Best Regards / S pozdravom,

openSUSE Community Multiplier Team Lihovarska 1060/12
PGP 0xA6917144 19000 Praha 9, CR
To unsubscribe, e-mail: opensuse-buildservice+unsubscribe@xxxxxxxxxxxx
For additional commands, e-mail: opensuse-buildservice+help@xxxxxxxxxxxx

< Previous Next >
Follow Ups