2016-06-15 18:59:46 -07:00
|
|
|
Internals of build process
|
|
|
|
|
=========================================
|
|
|
|
|
|
2016-08-26 12:08:50 -07:00
|
|
|
The purpose of this document is to explain build process **internals** with subtle nuances.
|
2016-06-15 18:59:46 -07:00
|
|
|
This document is not by any means complete.
|
|
|
|
|
The ultimate source of truth is the code in `.\build.psm1` that's getting executed on the corresponding CI system.
|
|
|
|
|
|
2016-07-21 15:50:04 -07:00
|
|
|
This document assumes that you can successfully build PowerShell from sources for your platform.
|
2016-06-15 18:59:46 -07:00
|
|
|
|
|
|
|
|
|
|
|
|
|
Top directory
|
|
|
|
|
-----------
|
|
|
|
|
|
|
|
|
|
We are calling `dotnet` tool build for `$Top` directory
|
|
|
|
|
|
2016-07-26 16:47:57 -07:00
|
|
|
- `src\powershell-win-core` for CoreCLR on Windows.
|
2016-08-26 12:08:50 -07:00
|
|
|
- `src\powershell-unix` for CoreCLR on Linux and macOS.
|
2016-07-26 16:47:57 -07:00
|
|
|
- `src\powershell-win-full` for FullCLR builds (Windows only)
|
2016-06-15 18:59:46 -07:00
|
|
|
|
2016-06-15 19:17:45 -07:00
|
|
|
### Dummy dependencies
|
|
|
|
|
|
|
|
|
|
We use dummy dependencies between project.json files to leverage `dotnet` build functionality.
|
2016-07-26 16:47:57 -07:00
|
|
|
For example, `src\powershell-win-core\project.json` has dependency on `Microsoft.PowerShell.PSReadLine`,
|
2016-06-15 19:17:45 -07:00
|
|
|
but in reality, there is no build dependency.
|
|
|
|
|
|
|
|
|
|
Dummy dependencies allows us to build just `$Top` folder, instead of building several folders.
|
|
|
|
|
|
|
|
|
|
### Dummy dependencies rules
|
|
|
|
|
|
|
|
|
|
* If assembly is part of FullCLR build,
|
2016-07-26 16:47:57 -07:00
|
|
|
it should be listed as a dependency for FullCLR $Top folder (src\powershell-win-full)
|
2016-06-15 19:17:45 -07:00
|
|
|
|
|
|
|
|
* If assembly is part of CoreCLR build,
|
2016-07-26 16:47:57 -07:00
|
|
|
it should be listed as a dependency for $Top folder (src\powershell-unix or src\powershell-win-core)
|