Subversion Repositories

?revision_form?Rev ?revision_input??revision_submit??revision_endform?

Rev 8 | Go to most recent revision | Details | Compare with Previous | Last modification | View Log | RSS feed

Rev Author Line No. Line
3 magnus 1
#!/usr/bin/make -f
2
# -*- makefile -*-
3
 
4
# Uncomment this to turn on verbose mode.
5
#export DH_VERBOSE=1
6
 
7
# set some variables
8
ICONDIR=usr/share/icons
9
SHAREDIR=usr/share/crystalcursors
10
WRAPPERDIR=etc/X11/cursors
11
 
6 magnus 12
build: build-indep
3 magnus 13
 
6 magnus 14
build-indep: build-stamp
15
build-stamp:
3 magnus 16
	dh_testdir
17
 
18
	$(MAKE)
19
 
20
	touch build-stamp
21
 
22
clean:
23
	dh_testdir
24
	dh_testroot
25
	rm -f build-stamp configure-stamp
26
 
6 magnus 27
	$(MAKE) clean
3 magnus 28
 
29
	dh_clean
30
 
6 magnus 31
install: build-indep
3 magnus 32
	dh_testdir
33
	dh_testroot
34
	dh_prep
35
	dh_installdirs
36
 
37
	# Add here commands to install the package into debian/crystalcursors.
6 magnus 38
	$(MAKE) install PREFIX=$(CURDIR)/debian/crystalcursors/$(ICONDIR)
3 magnus 39
	find $(CURDIR)/debian/crystalcursors/$(ICONDIR) -type f -exec chmod 644 {} \;
40
	find $(CURDIR)/debian/crystalcursors/$(ICONDIR) -type d -exec chmod 755 {} \;
41
 
42
	# Don't overwrite system's default xcursor, just provide the directory
43
	rm -r $(CURDIR)/debian/crystalcursors/$(ICONDIR)/default/*
44
 
17 magnus 45
	# There are no left-hand "cross" cursors, so don't symlink to them:
46
	rm $(CURDIR)/debian/crystalcursors/$(ICONDIR)/crystal*left/cursors/plus
47
 
3 magnus 48
	# Find *.theme and copy 'em to wrapper-location (see #365072)
49
	# We have to change the Inherits line in (only) in the wrapper *.themes:
50
	#  1) find .themes
51
	#  2) remove lines with "Inherits" and save as tmp
52
	#  3) write new Inherits-line with name of the directory in /usr/share/icons
53
	# -- I know this is tricky, but I have not yet found a more elegant way to make
54
	#    crystalcursors work with debian's update-alternative
8 magnus 55
	# In addition, add new symlinks that Qt 4 looks for
56
 
3 magnus 57
	cd $(CURDIR)/debian/crystalcursors/$(ICONDIR); \
58
	for theme in crystal*; do \
59
	    grep -v Inherits $(CURDIR)/debian/crystalcursors/$(ICONDIR)/$${theme}/index.theme > tmp ; \
60
	    echo "Inherits = $${theme}" >> tmp ; \
61
	    install -m 644 tmp $(CURDIR)/debian/crystalcursors/$(WRAPPERDIR)/$${theme}.theme; \
62
	    rm tmp; \
8 magnus 63
	    while read target link; do \
64
	        if [ -e $$theme/cursors/$$target ]; then ln -sf $$target $$theme/cursors/$$link; fi; \
65
	    done < $(CURDIR)/debian/extra_symlinks;\
66
	done
3 magnus 67
 
6 magnus 68
binary-indep: build-indep install
3 magnus 69
	dh_testdir
70
	dh_testroot
71
	dh_installchangelogs CHANGELOG
72
	dh_installdocs
73
#	dh_install
74
	dh_compress
75
	dh_fixperms
76
	dh_installdeb
77
	dh_shlibdeps
78
	dh_gencontrol
79
	dh_md5sums
80
	dh_builddeb
81
 
6 magnus 82
binary-arch:
83
# No arch-dependent packages
3 magnus 84
 
6 magnus 85
binary: binary-indep
86
.PHONY: build-indep build clean binary-indep binary-arch binary install configure