3 build
clean install binary-arch binary-indep binary
:
4 +dh
--parallel
$(opt_no_act
) $@
6 override_dh_auto_clean
:
7 dh_auto_clean
--builddirectory debian
/xzdec-build
8 dh_auto_clean
--builddirectory debian
/normal-build
11 override_dh_auto_configure
:
13 dh_auto_configure
--builddirectory debian
/normal-build
-- \
14 $(opt_optimize
) $(opt_quiet
)
15 dh_auto_configure
--builddirectory debian
/xzdec-build
-- \
16 --disable-shared
--disable-nls
--disable-encoders \
17 --enable-small
--disable-threads \
18 $(opt_optimize_small
) $(opt_quiet
)
20 override_dh_auto_build
:
21 dh_auto_build
--builddirectory debian
/normal-build
22 cd debian
/normal-build
&& doxygen Doxyfile
23 $(MAKE
) -C debian
/xzdec-build
/src
/liblzma
24 $(MAKE
) -C debian
/xzdec-build
/src
/xzdec
26 override_dh_auto_test
:
27 $(MAKE
) -C debian
/normal-build
check
29 override_dh_auto_install
:
30 dh_auto_install
--builddirectory debian
/normal-build
31 $(MAKE
) -C debian
/xzdec-build
/src
/xzdec
install \
32 DESTDIR
=$$(pwd
)/debian
/tmp
34 override_dh_installchangelogs
:
35 dh_installchangelogs debian
/changelog.upstream
37 opt_optimize
= CFLAGS
="-g -O2"
38 opt_optimize_small
= CFLAGS
="-g -Os"
42 ifneq (,$(filter noopt
,$(DEB_BUILD_OPTIONS
)))
43 opt_optimize
= --disable-assembler CFLAGS
="-g -O0"
44 opt_optimize_small
= --disable-assembler CFLAGS
="-g -O0"
47 ifneq (,$(findstring n
,$(MAKEFLAGS
)))
51 ifneq (,$(filter quiet
,$(DEB_BUILD_OPTIONS
)))
56 # Build a tarball with the latest upstream version.
57 # This is made complicated by the need to choose a nice version number.
58 REPO
= git
://ctrl.tukaani.org
/xz.git
61 mkdir debian-orig-source
62 -set
-e
; cd debian-orig-source
; \
63 : fetch latest upstream version
; \
65 git fetch
-q
--tags $(REPO
); \
66 git fetch
-q
$(REPO
) $(BRANCH
); \
67 : determine upstream version number
; \
68 commit_name
=$$(git describe FETCH_HEAD
); \
69 release
=$${commit_name
%%-*}; \
70 date
=$$(date
--utc
--date
="$$( \
71 git log -1 --pretty=format:%cD "$$commit_name" \
73 if
test "$$commit_name" = "$$release"; \
74 then upstream_version
=$${commit_name
#v}; \
75 else upstream_version
="$${release#v}+$${date}"; \
78 echo
"packaging $$commit_name"; \
79 git archive
--format
=tar "$$commit_name" \
80 --prefix="xz-utils-$$upstream_version/" | \
81 gzip
-9 > "../xz-utils_$$upstream_version.orig.tar.gz"
82 rm -fr debian-orig-source