Bootstrapping Debian package

Debian packages depend on a “Debian” directory. While you could create this by hand, there is a faster way: you can use dh_make. Here is what I used to get started:

create_debian_directory()
{
pushd $1
dh_make -y -s -e ${MAINTAINER_EMAIL} -f ../package-0.0.21.orig.tar.gz

cat > debian/rules <<EOF
#!/usr/bin/make -f
%:
dh \$@

override_dh_auto_configure:
./configure

override_dh_usrlocal:
echo “Skipping dh_usrlocal”

override_dh_shlibdeps:
echo “Skipping dh_shlibdeps”

EOF

sed -e “s/^Build-Depends: /Build-Depends: ${BUILD_DEPENDS}, /” -i debian/control
popd

Things to what’d out for :

  • You have to have the tar.gz file named a certain WAY.
  • The debian/control and debian/rules are what controls everything
  • A good resource is Here

About joelgranados

I'm fascinated with how technology and science impact our reality and am drawn to leverage them in order to increase the potential of human activity.
This entry was posted in Uncategorized and tagged , , , , . Bookmark the permalink.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s