-
c7d30038
by Felix Lechner
at 2018-12-04T13:48:03Z
Transfer file permissions from templates to generated files.
The templating system does not preserve file permissions, but scripts
must be executable to run. This commit applies the file permissions of
the template to any generated file. Going forward, scripts generated
from templates can also run.
This change is important for a new mechanism to generate debian/watch
and is also used to supply compat files to the tests
generic-dh-make-*, which were created without it. Modern Debian tools
require compat. The script was a way to add it without modifying the
debian files originally created by dh-make.
Signed-off-by: Chris Lamb <lamby@debian.org>
-
c9d4838c
by Felix Lechner
at 2018-12-04T13:48:08Z
Add post-template script to the template set 'make-builder' for tests.
This script causes any watch file (or its template) that was shipped
as part of other template sets to be deleted, if a package is native.
Signed-off-by: Chris Lamb <lamby@debian.org>
-
d60498b1
by Felix Lechner
at 2018-12-04T13:48:13Z
Add a default post-template command; it is post_template.
Some templates require adjustment after they were copied to a test's
work directory. For native packages, a post-template script will
remove any watch files that may have been shipped as part of a
template. This commit only sets the name of the script. The script is
provided by a template set.
Signed-off-by: Chris Lamb <lamby@debian.org>
-
5717411e
by Felix Lechner
at 2018-12-04T13:48:20Z
Add empty watch files to the template sets for tests.
Watch files were previously created in builder Makefiles. For some
tests, that was too late in the process. Now they are supplied as part
of template sets. For native packages, the watch files supplied herein
will be removed by post-template scripts. That script is supplied
elsewhere.
Signed-off-by: Chris Lamb <lamby@debian.org>
-
b499aaf9
by Felix Lechner
at 2018-12-04T13:48:25Z
Remove dynamic generation of watch file from builder Makefile.
For a long time, the Lintian test suite automatically created watch
files for non-native packages. That worked well, except in some corner
cases. Some tests compensated by removing the file in the pre_build
script.
This commit is part of a series that changes that mechanism. The watch
file is now supplied by a template set and removed right after the
templates are copied into a test's work directory. The processing
takes place earlier. It allows tests deal with watch files like they
do with any other file that is (or is not) supplied by template sets.
Signed-off-by: Chris Lamb <lamby@debian.org>
-
eaa9032e
by Felix Lechner
at 2018-12-04T13:48:31Z
Execute post-template adjustment script in t/runtests.
This commit will execute a post-template script, if present. It is
part of a new mechanism to ensure that native packages are not
supplied with watch files.
With this commit, we can restore the two tests generic-dh-make-2005
and generic-dh-make-2008 to their original functionality: when they
were conceived, dh-make did not create watch files. Until now, neither
test showed the associated warnings because a template set supplied
the missing file. Very soon the two tests will no longer draw on
external Debian template sets. Instead they will trigger all the
warnings their original authors intended.
Signed-off-by: Chris Lamb <lamby@debian.org>
-
aad4a2db
by Felix Lechner
at 2018-12-04T13:48:42Z
Add a builder-only skeleton; does not supply any Debian templates.
This skeleton only installs (and fills) build files, but it does not
supply any Debian templates (although it will fill them). Tests like
generic-dh-make-* were meant to be snapshots in time. In the past,
they were seeded with standard template sets like other tests. That
may conflict with the intentions of their original authors. This
commit creates a more suitable skeleton for their use.
This skeleton also allows the script pre_build to be generated from a
template. That functionality is needed to supply debian/compat to both
tests mentioned above without modifying any of their static Debian
files.
Signed-off-by: Chris Lamb <lamby@debian.org>
-
bf735013
by Felix Lechner
at 2018-12-04T13:48:45Z
Fix test generic-dh-make-2008 to work without external templates.
Judging from the file orig/README the original author intended this
test to remain undisturbed "as a test of Lintian's handling of old ...
template packages". This commit stops the use of standard templates,
which in the past provided missing files.
During the build process, dh_clean is called. It errors out when no
compat file is present. To get the test to run, a compat file is now
generated through the pre_build script. This is done dynamically so
that the set of static files is not modified, as requested by the
original author.
Some tags appeared when the use of default templates was discontinued.
Those tags were added.
Signed-off-by: Chris Lamb <lamby@debian.org>
-
ac89c5fc
by Felix Lechner
at 2018-12-04T13:48:52Z
Fix test generic-dh-make-2005 to work without external templates.
test to remain undisturbed "as a test of Lintian's handling of old ...
template packages". This commit stops the use of standard templates,
which in the past provided missing files.
During the build process, dh_clean is called. It errors out when no
compat file is present. To get the test to run, a compat file is now
generated through the pre_build script. This is done dynamically so
that the set of static files is not modified, as requested by the
original author.
Some tags appeared when the use of default templates was discontinued.
Those tags were added.
Signed-off-by: Chris Lamb <lamby@debian.org>
-
c92295b0
by Felix Lechner
at 2018-12-04T13:48:58Z
Simplify test cruft-empty-diff; use only templates; no copies in ./orig.
The test 'cruft-empty-diff' replicated all standard templates in
./orig. Here we instead use the script ./pre_upstream to copy all
filled Debian files into the package directory before the orig.tar.gz
is created. It also renders the diff empty, but is probably more fool-
and future-proof.
Signed-off-by: Chris Lamb <lamby@debian.org>
-
143e08ea
by Chris Lamb
at 2018-12-04T13:49:06Z
Apply a patch series from Felix Lechner to provide a generalised facility to make any test template set independent of the package format. (MR: !82)