You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: src/content/docs/wix/whatsnew/oopbas.md
+29Lines changed: 29 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -14,6 +14,8 @@ The motivation for this change can be found in [#7916](https://github.com/wixtoo
14
14
The [WiX repo on GitHub](https://github.com/wixtoolset/wix) contains the code to bootstrapper applications using the new model, like [WixStandardBootstrapperApplication](https://github.com/wixtoolset/wix/blob/HEAD/src/ext/Bal/stdbas/WixStandardBootstrapperApplication.cpp) (C++) and [WixBA](https://github.com/wixtoolset/wix/tree/HEAD/src/test/burn/WixToolset.WixBA) (C#).
15
15
:::
16
16
17
+
## BootstrapperApplication as an EXE
18
+
17
19
First, the custom bootstrapper application project needs to change from DLL to EXE.
18
20
19
21
```diff
@@ -83,6 +85,8 @@ At this point, the bootstrapper application API is fairly compatible with only a
83
85
*`BalBaseBootstrapperApplication.h` was renamed to `BootstrapperApplicationBase.h`.
84
86
*`CBalBaseBootstrapperApplication` was deprecated, use `CBootstrapperApplicationBase` instead.
85
87
88
+
## Package Renames
89
+
86
90
To take advantage of the breaking change, we took the opportunity to improve the names of many NuGet packages related to custom bootstrapper applications:
87
91
88
92
*`WixToolset.BalUtil` - renamed to `WixToolset.BootstrapperApplicationApi` to provide the native headers and libraries to communicate with Burn. Also, split out the `WixToolset.WixStandardBootstrapperApplicationFunctionApi` for WixStdBA BAFunctions API.
A bundle may include two BootstrapperApplications: the primary and the secondary. The primary (no pun intended) use case is to support a complex BootstrapperApplication that requires prerequisites to be installed before it can proceed. A "secondary" BootstrapperApplication with no dependencies (and usually a minimal design) can be included to install those prerequisites. The sequence works like this:
112
+
113
+
1. Burn launches the primary BootstrapperApplication.
114
+
2. If the primary BootstrapperApplication returns `0` as its exit code, Burn exits with the code provided via `IBootstrapperEngine.Quit()` and the sequence is complete.
115
+
3. Otherwise, Burn launches the secondary BootstrapperApplication.
116
+
4. If the secondary BootstrapperApplication returns `0` as its exit code, Burn exits with the code provided via `IBootstrapperEngine.Quit()` and the sequence is complete.
117
+
5. Otherwise, Burn launches the primary BootstrapperApplication, one last time.
118
+
119
+
This sequence allows the primary BootstrapperApplication to complete the install/uninstall/repair/etc if possible. If not, the secondary BootstrapperApplication can complete the process itself or, more common, install a subset of the bundle's packages required to boot the primary BootstrapperApplication then return non-zero exit code to Burn.
120
+
121
+
This sequence also supports _always_ launching the prerequisite BootstrapperApplication as "primary" where it detects that everything is in place before _always_ returning non-zero so the main BootstrapperApplication runs secondary. This sequence is less optimal as it always requires two BootstrapperApplication launches but it is supported.
122
+
123
+
To author your primary and secondary BootstrapperApplications, use the `BootstrapperApplication` element's `Secondary` attribute. For example:
0 commit comments