summaryrefslogtreecommitdiff
path: root/scripts
AgeCommit message (Collapse)AuthorFilesLines
2017-02-27Update German scripts translationHelge Kreutzmann1-6/+22
Update to 589t.
2017-02-26test: Use the detected perl interpreter instead of a random one from PATHGuillem Jover4-5/+6
We check for a specific version of perl and store that in the PERL variable. But the shebangs on several test scripts hardcode a specific perl that might not be present or might not be recent enough. Always invoke perl scripts explicitly with PERL, or implicitly by letting the currently running interpreter use itself.
2017-02-26Dpkg::Vendor::Debian: Switch PIE handling to have no default (!)Guillem Jover1-3/+12
Delegate the setting to gcc builtin or an explicit request by a user. This is needed to cope with the general PIE brokenness situation in Debian, and the current specific brokenness of a Debian gcc patch mangling the dpkg build flags. This is wrong in so many levels, as we'll have discrepancies between architectures, the interface towards maintainers is inconsistent, and updating the PIE support needs touching and coordinating two places. But it's certainly the current lesser evil. Closes: #848129, #845550
2017-02-26Dpkg::Vendor::Debian: Mark more architectures as having gcc builtin PIEGuillem Jover1-1/+2
Specifically kfreebsd-amd64, kfreebsd-i386, sparc and sparc64.
2017-02-26Dpkg::Source::Package: Add ‘.mnt-ignore’ to the default ignore listsNicolas Boulenguez1-1/+2
Closes: #855450 Signed-off-by: Guillem Jover <guillem@debian.org>
2017-02-26Dpkg::Shlibs::Objdump: Do not parse bogus ELF binaries in get_format()Guillem Jover1-2/+2
If the ELF class or endianness are unknown or bogus, ignore the file. Reported-by: Niels Thykier <niels@thykier.net>
2017-02-26Dpkg::Shlibs::Objdump:Object: Warn for unknown exec formats in analyze()Guillem Jover1-0/+5
Emit an explicit warning whenever we cannot detect the format for an executable object, instead of delegating this to the subsequent objdump, and letting it die, which ca be canfusing and is not future-proof. Closes: #854536
2017-02-26Dpkg::Shlibs::Objdump: Fix read() error handling in get_format()Guillem Jover1-1/+6
The rest of the code handles non-binary files (ELF in this case) gracefully and ignores them, even though not very explicitly, as objdump will emit a warning that might be difficult to decrypt. We will still fail for other read failures that are not just short-reads, as those imply some actual problem with the passed files. Closes: #854536
2017-02-26Dpkg::Shlibs::Objdump: Do not special case EM_SPARC32PLUS for NetBSDGuillem Jover1-10/+1
The affected code in NetBSD was bogus, and has been removed now. So there is no point in trying to special case the EM_SPARC32PLUS ELF machine ID depending on the ELF class, for something that should never happen. Ref: https//gnats.netbsd.org/51925
2017-02-26dpkg-genbuildinfo: Declare .buildinfo format as stable with version 1.0Guillem Jover1-1/+1
All the currently planned changes have been done, let's bump the format version to denote a stable format, which will not change in incomatible changes any more without bumping the major version component.
2017-02-26dpkg-genbuildinfo: Handle unmatched virtual arch-qualified packagesGuillem Jover1-0/+1
The dependency traversal code is currently broken, and this mostly papers over the issue. Properly fixing this involves changes all over the place, which would be too intrusive for this series. We should handle this gracefully, instead of letting perl die. Closes: #849944
2017-02-26dpkg-buildpackage: Document --ignore-builtin-builddeps in --help outputGuillem Jover1-0/+2
Missed in commit 98b3341f5f46866208862ff40e4336ff1a7e1cd3.
2017-02-20dpkg-source: Document --before-build and --after-build in --help outputGuillem Jover1-0/+2
2017-02-01po: Regenerate .pot files and merge .po files with themGuillem Jover8-9/+9
2017-02-01Dpkg::Shlibs::Objdump: Mask ABI bits in flags for ARMGuillem Jover1-3/+0
These are too unreliable for exact matches. There are objects with EABIv4 in the wild, even when the current is EABIv5. The soft and hard float flags are not always set on armel and armhf respectively, although the Tag_ABI_VFP_args attribute in the the ARM attribute section should always be present on armhf. And there are cases were both soft and hard float flags are set at the same time(!). Mask all flags on ARM, so that we get back to the previous behavior with objdump. We can try to revisit this for a better matching during the dpkg 1.19.x cycle. Closes: #853793
2017-01-30Update German scripts translationHelge Kreutzmann1-68/+5
Update to 588t.
2017-01-29po: Regenerate .pot files and merge .po files with themGuillem Jover8-9/+9
2017-01-29Revert "dpkg-source: Generate Testsuite-Restrictions fields from test ↵Guillem Jover5-56/+2
restrictions" This reverts commit 9899bdcf9bde76d969b124abf0a898fcbb202c70. This change is contentious and should have been discussed more widely. Given that this has been live only for a couple of days, the impact should be minimal, but still something to take into account once and if this gets reintroduced, in the same or different form and shape. Closes: #852820
2017-01-29Dpkg::Shlibs::Objdump: Map alternative or old ELF machines to canonical onesGuillem Jover1-0/+49
Some ELF binaries contain alternative or old ELF machine types, which should match with their canonical forms. Map those before encoding the ABI. We ignore some mappings for things that should certainly never appear in current systems. Of note are EM_PPC_OLD (17) that conflicts with EM_VPP550 (17), and EM_PJ_OLD (99) that conflicts with EM_SNP1K (99). Warned-by: rebootstrap
2017-01-28po: Regenerate .pot files and merge .po files with themGuillem Jover8-19/+91
2017-01-28Dpkg::File: Disable the NFS-unsafe warning on LinuxGuillem Jover1-1/+5
On Linux systems the flock() locks get converted to file-range locks on NFS mounts, which makes it safe. The correct solution here will be to completely get rid of the need to do any locking, which should also make parallel builds faster. Addresses: #677865 (on Linux)
2017-01-28dpkg-buildpackage: Make --unsigned-changes not sign .buildinfo eitherGuillem Jover1-1/+2
There was no option to disable signing globally, so many users and tools rely on the two existing options to disable it. But with the introduction of signed .buildinfo files, there is no way for old tools to request the right thing. Abuse --unsigned-changes to mean not signing .buildinfo either. Closes: #852822
2017-01-28dpkg-buildpackage: Add new --no-sign optionGuillem Jover1-0/+6
This option disables signing any file. This makes this option a future-proof way to disable all signing, in case we add yet more files to sign, so that programs do not have to keep learning what options to pass.
2017-01-28Dpkg::Shlibs::Objdump: Encode the ELF ABI as a big-endian byte streamGuillem Jover1-2/+3
This way when unpacking for output, the result gives meaningful results.
2017-01-28Dpkg::Shlibs::Objdump: Mask ELF machine bits for SH and MIPSGuillem Jover1-3/+1
These do not define the ABI, and seem to be set depending on the ISA used. Mask them for now, and postpone possibly making more fine-grained matching in the future.
2017-01-27Update German scripts translationHelge Kreutzmann1-72/+8
Update to 588t.
2017-01-27po: Regenerate .pot files and merge .po files with themGuillem Jover8-144/+350
2017-01-27dpkg-buildpackage: Add support for signed .buildinfo filesGuillem Jover2-13/+42
Add new options -ui and --unsigned-buildinfo. Closes: #843925
2017-01-27dpkg-genbuildinfo: Fix parsing of Pre-Depends and DependsGuillem Jover1-1/+3
The loop is per package stanza, so we need to parse both fields separately. Based-on-patch-by: Johannes Schauer <josch@debian.org> Signed-off-by: Guillem Jover <guillem@debian.org>
2017-01-27dpkg-genchanges: Fix check for expected number of binary artifactsGuillem Jover1-5/+6
Only count the binaries that we are going to include in the upload, instead of guessing using implicit counts.
2017-01-27dpkg-genchanges: Include .buildinfo files also for source-only uploadsGuillem Jover2-0/+9
The .buildinfo file also makes sense on source-only uploads, because it is still a build. And more so when we have done a full build, but filtered the changes to only include the sources in the upload. In any case, this was the intended behavior from the beginning. Closes: #846164
2017-01-27dpkg-genchanges: Do not compute the architecture list twiceGuillem Jover1-6/+2
Just generate the list correctly when doing the initial filtering instead of having to do a useless two-pass.
2017-01-27dpkg-genchanges: Fold dist filtering and checksumming into initial loopGuillem Jover1-11/+9
We should not include architectures for artifacts we are not going to distribute. And we should not recompute the checksums for artifacts we have already computed.
2017-01-27Revert "dpkg-genchanges: Only add architectures for .deb/.udeb artifacts"Guillem Jover1-3/+3
This reverts commit cae957871dad79bbd48e264611ad3b4ca146dd7c. This was done to handle the .buildinfo files, but the changes is bogus, as it breaks the historical behavior of taking into account non-deb files such as by-hand ones.
2017-01-27dpkg-genchanges: Invert the binary distribution loop inside-outGuillem Jover1-12/+13
Move the if conditional from outside to inside the loop, this way removing one nesting level.
2017-01-27test: Rename parse_option to parse_featuresGuillem Jover1-4/+4
Missed in commit dad593660d922abce634542b43e9d56b03228a8c.
2017-01-26dpkg-genbuildinfo: Add initial support for DEB_BUILD_OPTIONSGuillem Jover1-3/+9
This will make it possible to enable or disable specific features that should be recorded in the .buildinfo file. For now only “all” and “path” are supported. Closes: #848705
2017-01-26Dpkg::BuildOptions: Add new parse_features() methodGuillem Jover3-32/+86
This has been refactored from Dpkg::Vendor::Debian, to have a generic option parser.
2017-01-26dpkg-shlibdeps: Improve ELF ABI mismatch detectorGuillem Jover3-33/+108
The previous ELF ABI mismatch detector was very naïve, as the string returned by «objdump -a» is a very simplistic representation of the ELF ABI used. Switch to our own ELF header parser, so that we can distinguish based on the fields that define the object ABI. This is still not enough, and we will have collisions with things such as linux-i386 and hurd-i386, but most of the previously colliding objects are now filtered. This also makes us independent of objdump not supporting any unknown ELF object ABI. Closes: #849913
2017-01-26Dpkg::ErrorHandling: Add a new debug() functionGuillem Jover4-30/+50
Switch scripts to use the new function instead of using ad-hoc implementations.
2017-01-25dpkg-source: Generate Testsuite-Restrictions fields from test restrictionsGuillem Jover5-2/+56
This information is currently only available in the Restrictions field in the debian/tests/control file. When dispatching tests, it might be inconvenient to have to download and unpack the source package beforehand. Let's expose this via the .dsc in a similar way we do for the Testsuite-Triggers field. Closes: #847926 Based-on-patch-by: Iain Lane <laney@debian.org>
2017-01-25dpkg-source: Refactor testsuite functionsGuillem Jover1-11/+9
Call set_testsuite_triggers_field() from inside set_testsuite_fields(), so that we do not have to perform the same checks more than once.
2017-01-25test: Correctly iterate over all default and passed .dsc template substvarsGuillem Jover1-1/+1
The code was returning all keys and values for %default_substvars, when instead we should have been requesting all %default_substvars and %options keys.
2017-01-25test: Refactor unit test data path into test_get_data_path()Guillem Jover12-25/+41
2017-01-23Update German scripts translationHelge Kreutzmann1-3/+15
Update to 589t.
2017-01-23dpkg-buildpackage, dpkg-source: Always set SOURCE_DATE_EPOCHGuillem Jover3-3/+3
If we do not have a date from the changelog set it to the current time. Closes: #849081
2017-01-23libdpkg, Dpkg::Version: Do not allow empty epochs and revisionsGuillem Jover2-4/+22
When there's at least one colon or one dash, we should expect epoch and revision numbers.
2017-01-23man, Dpkg::Control::FieldsCore: Add new Auto-Built-Package fieldGuillem Jover1-1/+5
This field is used to distinguish packages that have been automatically injected by some build tool, and are not present in the debian/control file.
2017-01-23Dpkg: Call anonymous subs via -> operator instead of casting with &Guillem Jover2-4/+4
And fix the documentation while at it, which was incorrect code.
2017-01-22doc: Fix typos in documentation and code commentsGuillem Jover4-4/+4
Warned-by: codespell, spellintian