Skip to content

build: declare product packaging manifest - #775

Open
hdwhdw wants to merge 2 commits into
sonic-net:masterfrom
hdwhdw:build/product-packaging-manifest
Open

hdwhdw wants to merge 2 commits into
sonic-net:masterfrom
hdwhdw:build/product-packaging-manifest

Conversation

@hdwhdw

@hdwhdw hdwhdw commented Sep 1, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Makefile defines one manifest for the nine sonic-gnmi product binaries.
  • Native and cross builds create the nine declared binaries in build/bin.
  • Debian package staging and make deinstall use this manifest.

Scope

This PR changes only Makefile. It does not change test fixtures, test privilege use, or cleanup behavior.

Verification

  • A clean native build produced all nine binaries as user ID 1000 in the SONiC slave container.
  • A clean build with CROSS_BUILD_ENVIRON=y produced the same nine binaries.
  • After each build, make install staged all nine declared binaries in /usr/sbin.
  • Install and deinstall checks passed with dialout enabled and disabled.
  • git diff --check passed.

Azure DevOps task: 39500132

Signed-off-by: Dawei Huang <daweihuang@microsoft.com>
Copilot AI lite review requested due to automatic review settings September 1, 2026 12:27
@azure-pipelines

Copy link
Copy Markdown
Azure Pipelines:
There may be pipelines that require an authorized user to comment /azp run to run.

@mssonicbld

Copy link
Copy Markdown
Contributor

/azp run

@azure-pipelines

Copy link
Copy Markdown
Azure Pipelines:
Successfully started running 1 pipeline(s).

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR refactors the build and install logic in the top-level Makefile to define a single “product binaries” manifest and to standardize both native and cross builds to emit the same set of artifacts into build/bin, aligning packaging/install staging with that manifest.

Changes:

  • Switches build steps to consistently use go build -o $(BUILD_DIR)/... (instead of mixing go build vs go install) and ensures $(BUILD_DIR) exists.
  • Introduces PRODUCT_BINARIES as a manifest of shipped executables and uses it to drive make install staging into /usr/sbin.
  • Updates gNMI client build outputs to also land in build/bin for both native and cross builds.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment thread Makefile
Comment thread Makefile
Signed-off-by: Dawei Huang <daweihuang@microsoft.com>
@mssonicbld

Copy link
Copy Markdown
Contributor

/azp run

@azure-pipelines

Copy link
Copy Markdown
Azure Pipelines:
Successfully started running 1 pipeline(s).

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 1 out of 1 changed files in this pull request and generated no new comments.

@hdwhdw

hdwhdw commented Sep 2, 2026

Copy link
Copy Markdown
Contributor Author

Azure build 1209124 completed downstream validation of sonic-gnmi commit 892da4a for draft sonic-buildimage PR 29171.

  • Eight platform and virtual-switch image jobs passed.
  • The ARMHF job built the sonic-gnmi package, docker-sonic-gnmi, and the final installer. Unrelated strict software bill of materials (SBOM) validation then failed because syft does not support ARMHF.
  • The T0, T0-2VLANs, T1-LAG, T1-LAG-VPP, multi-ASIC T1, and T2 Kernel-based Virtual Machine (KVM) jobs passed.
  • Four other KVM jobs did not start because requests to the Elastictest scheduler timed out.

No downstream failure affected the sonic-gnmi package, image, or executed KVM paths. The sonic-buildimage PR remains a draft. Do not merge it.

@hdwhdw
hdwhdw requested a review from donghaolicd September 2, 2026 15:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants