debian swirl logo

Back to the packages list icon-slicer

#!/usr/bin/make -f
# -*- mode: makefile; coding: utf-8 -*-
# Copyright © 2009,2012 Jonas Smedegaard 
# Description: Main Debian packaging script for icon-slicer
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License as
# published by the Free Software Foundation; either version 2, or (at
# your option) any later version.
#
# This program is distributed in the hope that it will be useful, but
# WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
# General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
# 02111-1307 USA.

include /usr/share/cdbs/1/rules/upstream-tarball.mk
include /usr/share/cdbs/1/rules/utils.mk
include /usr/share/cdbs/1/class/autotools.mk
include /usr/share/cdbs/1/rules/debhelper.mk

pkg = icon-slicer
cmd = $(pkg)

DEB_UPSTREAM_URL = http://freedesktop.org/software/$(pkg)/releases
#DEB_UPSTREAM_TARBALL_MD5 = e9997dd73ad5af43aadd49ac89105b33

# suppress checking binary files, to not upset dpkg-source
DEB_COPYRIGHT_CHECK_IGNORE_REGEX = ^(examples/.*\.png|debian/(changelog|copyright(|_hints|_newhints)))$

LDFLAGS += -Wl,--as-needed

DEB_INSTALL_EXAMPLES_$(pkg) = examples/sample* examples/Sample

DEB_INSTALL_MANPAGES_$(pkg) = debian/$(cmd).1

# generate manpage based on --help of script itself
common-post-build-arch:: debian/$(cmd).1
debian/$(cmd).1: src/$(cmd)
		chmod +x $<
	help2man --name= "utility for generating icon themes and libXcursor cursor themes" --no-info --output=$@ $<

clean::
		rm -f debian/$(cmd).1

# Needed by upstream build process
CDBS_BUILD_DEPENDS += , libgtk2.0-dev, libpopt-dev

# Needed for our packaging
CDBS_BUILD_DEPENDS += , help2man

# Needed both at build time and (always) at runtime
#  * x11-apps (xcursorgen) needed by icon-slider binary
depends = x11-apps
CDBS_BUILD_DEPENDS += , $(depends)
CDBS_DEPENDS_DEFAULT = $(depends)

Builds:

icon-slicer
utility for generating icon themes and libxcursor cursor themes