ProjectOptions() having wrong values

Bug #1973030 reported by Ondrej Kubik
12
This bug affects 2 people
Affects Status Importance Assigned to Milestone
Snapcraft
Incomplete
Undecided
Callahan Kovacs

Bug Description

ProjectOptions() reports host machine value, ignoring --target-arch value.
This is inconsistent with values passed later the plugins in the build script
For example for --target-arch armhf
ProjectOptions().is_cross_compiling: False
ProjectOptions().target_arch: arm64
ProjectOptions().cross_compiler_prefix: aarch64-linux-gnu-
ProjectOptions().arch_triplet: aarch64-linux-gnu
ProjectOptions().deb_arch: arm64
ProjectOptions().kernel_arch: arm64

yet in the build.sh values are:
export SNAPCRAFT_ARCH_TRIPLET="arm-linux-gnueabihf"
export SNAPCRAFT_TARGET_ARCH="armhf"

Callahan Kovacs (mr-cal)
Changed in snapcraft:
assignee: nobody → Callahan Kovacs (mr-cal)
status: New → In Progress
Revision history for this message
Callahan Kovacs (mr-cal) wrote :

@ondrak, a few questions:
1. This is when building a snap on base core22, correct?
2. Can you try again on snapcraft `latest/edge`? (or post a reproducer snapcraft.yaml and/or command line arguments) There's been many updates to snapcraft 7 this month and I'm having trouble reproducing.
3. `--target-arch` isn't supported for core22, I need to check with Sergio to figure out the expected behavior.

Changed in snapcraft:
status: In Progress → Incomplete
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.