2 Author: Russ Allbery <rra@debian.org>
6 Info: Check targets and actions in debian/rules.
9 Tag: debian-rules-is-symlink
11 Info: The file <tt>debian/rules</tt> is a symlink instead of a regular
12 file. This is unnecessary and makes package checking and manipulation
13 more difficult. If the rules file should be available in the source
14 package under multiple names, make <tt>debian/rules</tt> the real
15 file and the other names symlinks to it.
17 This problem may have prevented lintian from performing other checks,
18 leading to undetected changelog errors.
20 Tag: debian-rules-not-a-makefile
23 Info: The <tt>debian/rules</tt> file for this package does not appear to
24 be a makefile or does not start with the required line.
25 <tt>debian/rules</tt> must be a valid makefile and must have
26 "<tt>#!/usr/bin/make -f</tt>" as its first line.
28 Tag: debian-rules-missing-required-target
31 Info: The <tt>debian/rules</tt> file for this package does not provide one
32 of the required targets. All of build, binary, binary-arch,
33 binary-indep, and clean must be provided, even if they don't do anything
36 Tag: debian-rules-uses-pwd
38 Info: The <tt>debian/rules</tt> file for this package appears to use the
39 variable $(PWD) to refer to the current directory. This variable is not
40 set by GNU make and therefore will have whatever value it has in the
41 environment, which may not be the actual current directory. Some ways of
42 building Debian packages (such as through sudo) will clear the PWD
45 Instead of $(PWD), use $(CURDIR), which is set by GNU make, ignores the
46 environment, and is guaranteed to always be set.
48 Tag: debian-rules-ignores-make-clean-error
50 Info: A rule in the <tt>debian/rules</tt> file for this package calls the
51 package's clean or distclean target with a line like:
57 The leading "-" or the option -i tells make to ignore all errors.
58 Normally this is done for packages using Autoconf since Makefile may not
59 exist. However, this line ignores all other error messages, not just
60 the missing Makefile error. It's better to use:
62 [ ! -f Makefile ] || $(MAKE) distclean
64 so that other error messages from the clean or distclean rule will still
65 be caught (or just remove the "-" if the package uses a static makefile).
67 Tag: debian-rules-uses-DEB_BUILD_OPTS
69 Info: The standard environment variable for build options is
70 DEB_BUILD_OPTIONS. Usually, referring to DEB_BUILD_OPTS is a mistake and
71 DEB_BUILD_OPTIONS was intended instead.
73 Tag: debian-rules-sets-DH_COMPAT
76 Info: As of debhelper version 4, the DH_COMPAT environment variable is
77 only to be used for temporarily overriding <tt>debian/compat</tt>. Any
78 line in <tt>debian/rules</tt> that sets it globally should be deleted and
79 a separate <tt>debian/compat</tt> file created if needed.
81 Tag: binary-arch-rules-but-pkg-is-arch-indep
83 Info: It looks like you try to run code in the binary-arch target of
84 <tt>debian/rules</tt>, even though your package is architecture-
87 Tag: desktop-file-but-no-dh_desktop-call
89 Info: It looks like your package includes a .desktop file and you use
90 debhelper to build it, but you don't call dh_desktop in your rules
93 Tag: debian-rules-calls-debhelper-in-odd-order
95 Info: One of the targets in the <tt>debian/rules</tt> file for this
96 package calls debhelper programs in an odd order. Normally,
97 dh_makeshlibs should be called before dh_shlibdeps or dh_installdeb,
98 dh_shlibdeps should be called before dh_gencontrol, and all should be
99 called before dh_builddeb. Calling them in the wrong order may cause
100 incorrect or missing package files and metadata.