Conversation
Signed-off-by: Connor Roos <[email protected]>
There was a problem hiding this comment.
Pull request overview
Adds Debian packaging support to build an ASAN-instrumented variant of the SWSS packages, aligning build outputs with an asan build profile and updating install/strip rules accordingly.
Changes:
- Introduces
swss-asanandswss-dbg-asanbinary packages gated by Debian build profiles. - Updates
debian/rulesto install/strip into package-name-specific directories based on anENABLE_ASANtoggle. - Adds conflicts/build-profile metadata to prevent ASAN and non-ASAN packages from being built/installed together.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
debian/rules |
Switches install destdir and dbg-package name to swss(-dbg)-asan when ASAN is enabled. |
debian/control |
Adds ASAN-specific binary package stanzas and uses Build-Profiles to select ASAN vs non-ASAN packages. |
Signed-off-by: Connor Roos <[email protected]>
Signed-off-by: Connor Roos <[email protected]>
| configure_opts = | ||
| ifeq ($(ENABLE_ASAN), y) | ||
| ifneq ($(filter asan,$(DEB_BUILD_PROFILES)),) | ||
| configure_opts += --enable-asan | ||
| endif |
There was a problem hiding this comment.
The ASAN toggle was changed to only look at DEB_BUILD_PROFILES (ifneq ($(filter asan,$(DEB_BUILD_PROFILES)),)). The repo’s CI still enables ASAN by exporting ENABLE_ASAN=y (see .azure-pipelines/build-template.yml:252), so with this change the build will no longer pass --enable-asan unless the pipeline is updated to set DEB_BUILD_PROFILES=asan. Consider supporting both mechanisms (e.g., treat ENABLE_ASAN=y as enabling the asan profile) or updating the build pipeline in the same PR to avoid silently dropping ASAN builds.
Adds a separate ASAN swss build package to be created as the target when DEB_BUILD_PROFILES=asan. This is required for Clobbering of ASAN after a standard swss build on the same build machine.