Skip to content

Design for unified behavior controls #2974

Closed
@mmitche

Description

@mmitche

Describe the Problem

Right now, there is a rough assumption that the DotNetBuildFromSource property means building from source on Linux. This property is used to trim away package references, sources, target frameworks, and behaviors that should not be present when building from source on Linux (in offline mode).

The eventual goal is that Windows and Mac will use the same approach as Linux source build for building (a single all-up build per platforms), however the behavior and requirements will likely differ per platform. Examples:

  • Mac and Windows source builds may use pre-builts not allowable on Linux
  • Mac and Windows source builds may not trim away certain sources or package references not allowable on Linux.

Because the current source build schema is focused on Linux, we will need to redesign it to support multiple platforms.

In addition to this, improvements to the way that .NET builds will allow more organizations to build the product, and more organizations to include code or behavior in the source base that is not active during other builds. For instance, Microsoft may use specific functionality to sign binaries for its distribution, while other organizations may use another, Today, this pivot is largely represented by DotNetBuildFromSource

Describe the Solution

We need a coherent design for source build on other platforms. This design should:

  • Allow for an arbitrary set of platforms
  • Allow for different pre-built sets.
  • Allow for online vs. offline behavior.
  • Allow for different organizational behavior.
  • Allow for trimming of TFM targets (e.g. don't target net472 on Linux). This ideally does not involve conditionalization in a vast number of projects.
  • Still allow for platform-agnostic source build behavior (maybe use the existing properties)
  • Provide a rollout plan that is a smooth offramp from the current design and into the new one. It would be ideal if this was a scriptable, mechanical change.

Additional Context

Sub-issues

Metadata

Metadata

Assignees

Labels

area-infraSource-build infrastructure and reporting

Type

No type

Projects

Status

Done

Status

Done

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions