Skip to content

Commit 18e71aa

Browse files
committed
Fix Release build: copy dependencies to lib/ instead of moving
Keeping DLLs in the output root avoids assembly load failures when AssemblyResolve is not used (e.g. some load order/contexts in Release). Fixes empty server list and related issues in Release-only builds.
1 parent bf6c7f9 commit 18e71aa

1 file changed

Lines changed: 1 addition & 9 deletions

File tree

Nitrox.Shared.targets

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -87,21 +87,13 @@
8787
Condition="!Exists('$(OutputDirectory)')"
8888
ContinueOnError="WarnAndContinue" />
8989

90-
<!-- Copy in debug because some systems break when they don't use our assembly resolve to look inside lib folder -->
90+
<!-- Copy (don't Move) so dependencies stay in output root. Some code paths load assemblies before/when AssemblyResolve runs or from contexts that don't use it (e.g. Release vs Debug), causing empty UI or missing types when DLLs are only in lib/. -->
9191
<Copy SourceFiles="@(FilesToMove)"
9292
DestinationFolder="$(OutputDirectory)"
9393
OverwriteReadOnlyFiles="True"
9494
SkipUnchangedFiles="True"
9595
Retries="3"
9696
RetryDelayMilliseconds="100"
97-
Condition="'$(Configuration)' == 'Debug'"
98-
ContinueOnError="ErrorAndContinue" />
99-
100-
<!-- Move every matching files to OutputDirectory -->
101-
<Move SourceFiles="@(FilesToMove)"
102-
DestinationFolder="$(OutputDirectory)"
103-
OverwriteReadOnlyFiles="True"
104-
Condition="'$(Configuration)' == 'Release'"
10597
ContinueOnError="ErrorAndContinue" />
10698
</Target>
10799

0 commit comments

Comments
 (0)