← Back to issue list

plugin handler: process elf files only if base is specified

View original Github issue

Metadata

Project
snapcraft
Number
#2926
Type
pull request
State
merged
Author
cjp256
Labels
—
Created
Updated
Closed

Current evaluation

PR #2926 merged into snapcraft master as commit 9b1655d02: the plugin handler now processes ELF files only when a base is specified, unblocking snapd builds (LP #1857019).

Resolution: closed resolved

Reason: Merged by maintainer cjp256 on 2020-02-12 as commit 9b1655d02 ("plugin handler: process elf files only if base is specified (#2926)"). The change skips ELF processing when no base is declared, fixing the snapd build failure from LP #1857019; snapd PR7904 was reported building fine with it.

Evaluated by: mr-cal-bot

No scores available.

Issue body

ELF files are always processed when `type: app`, where `app` is the default type. This causes an issue when snapd is building without specifying the type, as it gets treated as `type: app` and its files are processed like typical app snaps. The schema currently allows for this because it fails to set the default type `app` in time for validation. Since snapd does not have a base, check for the existence of the base before attempting to process ELF files. This will prevent the error reported in LP #1857019 and allow snapd to build without a type specified. Once snapd moves to `type: snapd`, we can fix the schema to ensure that the invalid configuration that led to this error does not pass verification. LP #1857019 LP #1862642 Signed-off-by: Chris Patterson <chris.patterson@canonical.com> - [ ] Have you followed the [guidelines for contributing](https://github.com/snapcore/snapcraft/blob/master/CONTRIBUTING.md)? - [ ] Have you signed the [CLA](http://www.ubuntu.com/legal/contributors/)? - [ ] Have you successfully run `./runtests.sh static`? - [ ] Have you successfully run `./runtests.sh tests/unit`? -----

Evaluation history

Date Model Scores Action Summary
stealth/space-bunny-alpha — closed resolved PR #2926 merged into snapcraft master as commit 9b1655d02: the plugin handler now processes ELF files only when a base is specified, unblocking snapd builds (LP #1857019).
stealth/space-bunny-alpha — closed resolved Merged #2926, requiring a base before the plugin handler processes ELF files so snapd builds without an explicit type.
stealth/space-bunny-alpha — closed resolved Merged PR #2926 (commit 9b1655d02) skips ELF processing when no base is set, allowing snapd to build without an explicit type and resolving LP #1857019.
qwen/qwen3.6-35b-a3b — — Merged. Prevents ELF file processing when no base is specified, resolving snapd build failures without an explicit type. Approved by reviewers, passed CI, and unblocked downstream snapd development.
qwen3.6-35b-a3b-mtp-q6 — — Merged. Updates the plugin handler to process ELF files only when a base is specified, preventing validation errors during snapd builds without an explicit type. Includes a spread test and unblocks snapd development.

Update history

No update history recorded yet.

Related work

  • Likely Fixed By: 9b1655d02 (confidence 95%)

    Merge commit landing the base-gated ELF processing in snapcraft.

Related issues

Issue Project State Summary Similarity
#2021 pluginhandler: only resort to elf mangling if the snap type is app snapcraft merged Merged #2021 in commit b4a07ba58, limiting ELF mangling to app-type snaps so non-app snaps are left unprocessed.
76%
#1850 pluginhandler: patch and handle elf files on glibc mismatch snapcraft merged Merged in snapcraft#1850 (bdaf0b7f1), adding host libc6 staging and its dynamic loader when ELF files need newer glibc; fixes #1668 and #1669.
72%
#2012 pluginhandler: only do elf checking and patching for type app snapcraft merged Merged PR #2012 in commit eae356003, limiting ELF/libc ABI/API checks and patching to app-type snaps and avoiding unnecessary checks for other snap types.
70%