File: rules

package info (click to toggle)
ruby-prawn 2.1.0%2Bdfsg-1
  • links: PTS, VCS
  • area: main
  • in suites: stretch
  • size: 3,220 kB
  • ctags: 826
  • sloc: ruby: 14,469; sh: 43; makefile: 18
file content (40 lines) | stat: -rwxr-xr-x 1,237 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
38
39
40
#!/usr/bin/make -f
#export DH_VERBOSE=1
#
# Uncomment to ignore all test failures (but the tests will run anyway)
#export DH_RUBY_IGNORE_TESTS=all
#
# Uncomment to ignore some test failures (but the tests will run anyway).
# Valid values:
#export DH_RUBY_IGNORE_TESTS=ruby1.8 ruby1.9.1 require-rubygems
#
# If you need to specify the .gemspec (eg there is more than one)
#export DH_RUBY_GEMSPEC=gem.gemspec

LAST_CHANGE = $(shell dpkg-parsechangelog -S Date)
BUILD_EPOCH = $(shell date -u +"%s" --date="$(LAST_CHANGE)")
export BUILD_EPOCH

%:
	dh $@ --buildsystem=ruby --with ruby


override_dh_auto_install:
	# copy specs' data to data dir in order to install them correctly to run the specs
	# install manually and temporarily data
	mkdir -p debian/ruby-prawn/usr/share/ruby-prawn
	cp -R data/* debian/ruby-prawn/usr/share/ruby-prawn
	dh_auto_install
	ruby -I "debian/ruby-prawn/usr/lib/ruby/vendor_ruby" manual/contents.rb
	# remove the copy of data in debian/ruby-prawn (will be reinstalled by dh_install)
	rm -rf debian/ruby-prawn/usr/share/ruby-prawn

override_dh_auto_clean:
	# remove the copy of spec/data in data/
	rm -rf data/spec
	rm -f manual.pdf
	dh_auto_clean

get-orig-source:
	chmod +x debian/repack.sh
	debian/repack.sh