File: rules

package info (click to toggle)
phpmyadmin 4:5.0.4+dfsg2-2
  • links: PTS, VCS
  • area: main
  • in suites: bullseye, sid
  • size: 104,204 kB
  • sloc: php: 152,799; javascript: 136,970; sql: 504; sh: 263; python: 200; makefile: 196; xml: 167
file content (49 lines) | stat: -rwxr-xr-x 1,820 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
42
43
44
45
46
47
48
49
#!/usr/bin/make -f
# Uncomment this to turn on verbose mode.
#export DH_VERBOSE=1

REVISION := $(shell head -1 debian/changelog | sed 's/.*(//;s/).*//;s/.*-//')

%:
	dh $@ --with sphinxdoc,phpcomposer


DEB_DIR=debian/phpmyadmin/usr/share/phpmyadmin

SRC_FILES = $(wildcard themes/original/scss/*.scss themes/pmahomme/scss/*.scss themes/metro/scss/*.scss)
INCLUDE_FILES=$(wildcard themes/original/scss/_*.scss themes/pmahomme/scss/_*.scss themes/metro/scss/_*.scss)
SRC_FILES := $(filter-out $(INCLUDE_FILES), $(SRC_FILES))
SRC_FILES_TO_BUILD = $(patsubst %,$(DEB_DIR)/%,$(SRC_FILES))

$(DEB_DIR)/%.scss: %.scss
	sassc --sourcemap --style compressed $< $(subst scss,css,$<)

override_dh_auto_test:
	# keep in sync with debian/tests/phpunit
	LC_ALL=C.UTF-8 phpunit --no-coverage --exclude-group selenium,network,git-revision,environment,extension-iconv,32bit-incompatible

override_dh_auto_clean:
	dh_auto_clean --sourcedirectory=doc

override_dh_auto_build: $(SRC_FILES_TO_BUILD)
	minify -o js/vendor/stickyfill.min.js debian/missing-sources/stickyfill/stickyfill.js
	make -C doc/ html
	# generate outoload-files. keep in sync with debian/tests/phpunit
	phpab --template debian/autoload.php.tpl \
		--output autoload.php \
		libraries/classes
	phpab --template debian/autoload-test.php.tpl \
		--output test/autoload.php \
		test

override_dh_install:
	dh_install -XLICENSE
	rm -rf $(DEB_DIR)/js/vendor/openlayers
	rm -rf $(DEB_DIR)/js/vendor/codemirror
	rm -rf $(DEB_DIR)/themes/original/jquery/images
	rm -rf $(DEB_DIR)/themes/pmahomme/jquery/images
	rm -rf $(DEB_DIR)/themes/metro/jquery/images
	rm -rf $(DEB_DIR)/themes/metro/fonts
	# include Debian marker in version string
	sed -ri "/set..PMA_VERSION/ s/'([-0-9a-z.]+)'/'\\1deb$(REVISION)'/" \
		debian/phpmyadmin/usr/share/phpmyadmin/libraries/classes/Config.php