File: rules

package info (click to toggle)
pdf.js 1.0.907%2Bdfsg-1%2Bdeb8u1
  • links: PTS, VCS
  • area: main
  • in suites: jessie
  • size: 36,472 kB
  • ctags: 8,197
  • sloc: makefile: 41
file content (41 lines) | stat: -rwxr-xr-x 1,078 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
41
#!/usr/bin/make -f

UPSTREAM := $(shell head -1 debian/changelog | sed 's/.*(//;s/[+-].*).*//')

%:
	dh $@

override_dh_auto_build:
	# Save initial Makefile
	cp make.js make.js.bkp
	# Normal builds
	sed -i "s/@EXTENSION_VERSION@/$(UPSTREAM)/" make.js
	nodejs make cmaps
	nodejs make extension
	nodejs make generic
	# Build ownCloud-specific version
	for i in debian/patches/ownCloud/*;do patch -p1 < $$i;done
	nodejs make generic
	for i in `ls -r $(CURDIR)/debian/patches/ownCloud/*`;do patch -Rp1 < $$i;done
	# Restore initial Makefile
	mv make.js.bkp make.js
	dh_auto_build

override_dh_auto_clean:
	nodejs make clean
	rm -rf extensions/firefox/locale
	rm -rf oc
	rm -rf web/locale
	dh_auto_clean

override_dh_installchangelogs:
	dh_installchangelogs $(CURDIR)/debian/upstream/changelog

override_dh_link:
	rm -r $(CURDIR)/debian/libjs-pdf/usr/share/javascript/pdf/web/cmaps
	rm -r $(CURDIR)/debian/libjs-pdf/usr/share/javascript/pdf/web/images
	rm -r $(CURDIR)/debian/libjs-pdf/usr/share/javascript/pdf/web/locale
	dh_link

get-orig-source:
	uscan --verbose --rename --force