Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
These are the d/rules and d/control from the official Debian packaging.
- Loading branch information
Showing
2 changed files
with
23 additions
and
56 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,46 +1,21 @@ | ||
#!/usr/bin/make -f | ||
# -*- makefile -*- | ||
# Sample debian/rules that uses debhelper. | ||
# This file was originally written by Joey Hess and Craig Small. | ||
# As a special exception, when this file is copied by dh-make into a | ||
# dh-make output file, you may use that output file without restriction. | ||
# This special exception was added by Craig Small in version 0.37 of dh-make. | ||
|
||
# Uncomment this to turn on verbose mode. | ||
export DH_VERBOSE=1 | ||
# Enable build hardening | ||
export DEB_BUILD_MAINT_OPTIONS=hardening=+all | ||
DPKG_EXPORT_BUILDFLAGS=1 | ||
include /usr/share/dpkg/buildflags.mk | ||
|
||
# enable hardening | ||
export DEB_BUILD_HARDENING=1 | ||
|
||
# Make sure to NOT use any flags from environment and only use the standard | ||
# debian build flags. | ||
# provide debian version number to the build system | ||
# | ||
# include CPPFLAGS in CFLAGS, this is a cmake workaround found on | ||
# https://wiki.debian.org/Hardening#Notes_for_packages_using_CMake | ||
export CPPFLAGS:=$(shell dpkg-buildflags --get CPPFLAGS) | ||
export CFLAGS:=$(shell dpkg-buildflags --get CFLAGS) $(CPPFLAGS) | ||
export CXXFLAGS:=$(shell dpkg-buildflags --get CXXFLAGS) $(CPPFLAGS) | ||
export LDFLAGS:=$(shell dpkg-buildflags --get LDFLAGS) | ||
|
||
VERSION=$(shell dpkg-parsechangelog | sed -n 's/^Version: //p') | ||
|
||
# Rationale: dspdfviewer --version embeds the information that this | ||
# is from the debian package. This is useful when users go | ||
# directly to the github-issue-tracker instead of using reportbug. | ||
|
||
override_dh_auto_configure: | ||
dh_auto_configure -- -DDSPDFVIEWER_VERSION=$(VERSION) | ||
|
||
|
||
# Debug package building | ||
.PHONY: override_dh_strip | ||
override_dh_strip: | ||
dh_strip --dbg-package=dspdfviewer-dbg | ||
|
||
override_dh_auto_install: | ||
dh_auto_install --destdir=debian/dspdfviewer | ||
|
||
override_dh_installdocs: | ||
dh_installdocs --link-doc=dspdfviewer | ||
|
||
dh_auto_configure -- \ | ||
-DDSPDFVIEWER_VERSION=$(shell dpkg-parsechangelog --show-field Version) \ | ||
-DUseQtFive=ON | ||
|
||
# Use debhelper for the rest | ||
%: | ||
dh $@ | ||
dh $@ --parallel |