File: rules

package info (click to toggle)
matomo-component-decompress 3.0.0-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 444 kB
  • sloc: php: 3,125; makefile: 25; xml: 21
file content (35 lines) | stat: -rwxr-xr-x 1,019 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
#!/usr/bin/make -f

%:
	dh $@

override_dh_auto_build:
	phpabtpl \
	        --basedir . \
	        --require-file libs/PclZip/pclzip.lib.php \
	        composer.json \
	        > debian/autoload.php.tpl

	# Path at the install time does not have src/
	phpab --basedir src \
	        --output autoload.php \
	        --template debian/autoload.php.tpl src/

override_dh_auto_test:
	phpab --basedir . \
	        --output tests-autoload.php \
	        --template debian/autoload.php.tpl src/ tests/TestBase.php
	phpunit --no-coverage --do-not-cache-result --fail-on-empty-test-suite --bootstrap ./tests-autoload.php
	# Restore the state (https://github.com/php/php-src/issues/8781)
	touch tests/Fixture/empty.zip
	chmod +x tests/Fixture/empty.zip


override_dh_install:
	dh_install
	chmod -x debian/php-matomo-component-decompress/usr/share/php/matomo/decompress/Gzip.php
	chmod -x debian/php-matomo-component-decompress/usr/share/php/matomo/decompress/Tar.php

override_dh_clean:
	dh_clean
	touch tests/Fixture/empty.zip