Generally, both methods just zip a folder with your files. For instance, I use something like this: /home/user/sources/project with subfolder /usr/bin/ that contains the executable and /usr/share/application with a desktop file and /usr/share/pixmaps with the icon.
The desktop file contains:
[Desktop Entry]
Name=Scrabble3D
Comment=A highly customizable Scrabble game that not only supports Classic Scrabble and Superscrabble but also 3D games and own boards
Exec=/usr/bin/Scrabble3D
Icon=Scrabble3D
Terminal=false
Type=Application
Categories=Game
StartupNotify=false
Than you need the control file that has to be located at /home/user/sources/project/DEBIAN. It looks like this:
Package: scrabble3d
Version: 3.1.1-1
Section: games
Priority: optional
Architecture: i386
Installed-Size: 7653
Maintainer: Heiko Tietze <heiko_tietze@web.de>
Homepage: http://sourceforge.net/apps/mediawiki/scrabble/
Provides: scrabble3d
Depends: libatk1.0-0 (>= 1.29.3), libc6 (>= 2.3.6-6~), libcairo2 (>= 1.2.4), libgl1-mesa-glx | libgl1, libglib2.0-0 (>= 2.12.0), libgtk2.0-0 (>= 2.8.0), libpango1.0-0 (>= 1.14.0), libx11-6 (>= 0)
Description: Highly customizable Scrabble game that not only supports Classic Scrabble and Superscrabble but also 3D games and own boards.
Features:
* Configurable board, letterset and design
* Board in OpenGL graphics with user-definable wavefront model
* Game against computer with support of multithreading
* Post-hoc game analysis with calculation of best move by computer
* Match with other players connected on a game server
* NSA rating and highscore at game server
* Time limit of games
* Localization; use of non-standard digraphs like CH, RR, LL and right to left reading
* Multilanguage help / wiki
* Network games are buffered and asynchronous games are possible
* Running games can be kibitzed
* International rules including italian "Cambio Secco"
* Challenge mode, What-if-variant, etc.
Take care about correct permissions and run "dpkg -b /home/user/sources/project". Check the result with lintian.
For RPM you need to create a different folder structure and a slightly other spec file. The command is "rpmbuild -bb --target i386 ./SPECS/Scrabbel3D.spec". Both debian and RPM have a lot of manuals to read, just use the search engine of your trust. It always takes at least a day for me to pack 32/64bit deb/rpm, msi and pkg/dmg. Perhaps you can benefit from openSuSE's build service (
https://build.opensuse.org/).