How to building a package for a repository for Debian or Debian.md - tx00100xt/SeriousSamClassic GitHub Wiki

Install Development Environments

apt install build-essential dput dh-make bzr-builddeb gnupg pbuilder ubuntu-dev-tools apt-file git

Generate Signing Key Pair

gpg --full-generate-key 

Configure your shell

The Debian/Ubuntu packaging tools need to learn about you as well in order to properly credit you in the changelog. Simply open your ~/.bashrc in a text editor and add something like this to the bottom of it:

export DEBFULLNAME="Bob Dobbs"
export DEBEMAIL="[email protected]"

Now save the file and either restart your terminal or run:

$ source ~/.bashrc (If you do not use the default shell, which is bash, please edit the configuration file for that shell accordingly.)

Install build package dependencies

apt install debhelper cmake flex bison nasm libsdl2-dev libvorbis-dev zlib1g-dev imagemagick 

Make a package

Clone the repository

git clone https://github.com/tx00100xt/SeriousSamClassic.git serioussamclassic

Write your DEBFULLNAME and DEBEMAIL in the files:

cd serioussamclassic
nano -w debian/changelog
nano -w debian/control
nano -w debian/copyright
nano -w debian/serioussamclassic.1

Prepare the Package Environment

rm -rf .git
bzr init
brz add debian/*
bzr commit -m "Initial Release"
dh_make --createorig -c gpl2 -s -t debian -p serioussamclassic_1.10.5

Build the package and check if it works.

bzr builddeb -- -us -uc

Build the signed package, ready to push to the repository

debuild -S