File: rules

package info (click to toggle)
librmagick-ruby 2.13.1-2
  • links: PTS, VCS
  • area: main
  • in suites: squeeze
  • size: 4,444 kB
  • ctags: 1,716
  • sloc: ansic: 16,755; ruby: 9,730; makefile: 16; sh: 12
file content (37 lines) | stat: -rwxr-xr-x 1,257 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
#!/usr/bin/make -f

# Uncomment this to turn on verbose mode.
#export DH_VERBOSE=1

include /usr/share/cdbs/1/rules/debhelper.mk
# include /usr/share/cdbs/1/rules/patchsys-quilt.mk
include /usr/share/ruby-pkg-tools/1/class/ruby-setup-rb.mk

docdir := /usr/share/doc/librmagick-ruby-doc/html
DEB_RUBY_CONFIG_ARGS += --doc-dir=$(CURDIR)/debian/librmagick-ruby-doc/$(docdir)

# Workaround buggy buildds on sparc
ifeq ($(DEB_BUILD_ARCH),sparc)
DEB_RUBY_CONFIG_ARGS +=  --allow-example-errors
endif

# upstream uses a "post-clean" hook, but no "post-distclean", so we have to
# override DEB_RUBY_CLEAN_TARGET.
DEB_RUBY_CLEAN_TARGET = clean

# avoid compressing examples
DEB_COMPRESS_EXCLUDE := .rb

# this is a hack: we need to "install" librmagick-ruby1.8, since it will
# generate the HTML doc for librmagick-ruby-doc. This should probably be
# fixed in ruby-pkg-tools instead.
install/librmagick-ruby-doc:: install/librmagick-ruby1.8

# generate rdoc documentation
install/librmagick-ruby-doc::
	dh_rdoc -plibrmagick-ruby-doc ext lib
	find $(CURDIR)/debian/librmagick-ruby-doc/$(docdir) -name .rmagick -exec rm {} +
	find $(CURDIR)/debian/librmagick-ruby-doc/$(docdir) -name .cvsignore -exec rm {} +

clean::
	rm -f ext/RMagick/Makefile ext/RMagick/extconf.h