Skip to content

Commit b6c2aa3

Browse files
dseefeldomajid
andauthored
Add runtime repo (portable and non-portable) and build in master (#1528)
* Update arcade and standard shas * Add runtime repo and remove coreclr, corefx and core-setup * Update standard to build with new arcade version * Update version of roslyn to work with updated Arcade * Update patches to enable runtime repo to build * Update aspnet-extensions commit and get it building * Add runtime portable build * Add OverrideTargetRid for Linux * Retain portable logs when cleaning up after portable build * Include project.assets.json files in files to be saved from portable build * Update version of source-build archive * Remove old corefx, coreclr and core-setup projects and update known-good * Add patch for ilasm round trip issue * Add patch for ilasm round trip issue * Update commit shas for repos in known good for preview 2 * Reconcile patches for core-sdk * Reconcile patches for linkere * Reconcile patches for fsharp repo * Reconcile patches for nuget-client repo * Reconcile patches for roslyn repo * Reconcile patches for runtime repo * Reconcile patches for sdk repo * Remove dependency flow sources -- update Arcade version * Update commit sha for standard * Update Arcade and SDK versions * Reconcile patches for arcade repo * Remove ArcadeConfigurationOverride * Fixup output placement for standard repo * Remove unneccessary roslyn patch * Correct invalid merge * Remove linker reflection heuristics patch per comment from sbomer on #777 * Update PackagesOutput for linker * Add patch to set nopgooptimize in coreclr build * Update coreclr build arguments * Only build through coreclr for now * Only build through runtime * Add CentOS 8 CI build (#1539) * Add CentOS 8 CI build We have had some issues building in RHEL 8, so lets set up a CentOS 8 CI system to try and catch those issues earlier. * Pin to artifacts version with executable coreclr bits Co-authored-by: Aditya Aggarwal <[email protected]> Conflicts: eng/Versions.props repos/coreclr.common.props * Update docker images * Update version of xliff tasks * Include 1 addtional arcade patch * Add patch to exclude Helix tests from source-build in arcade * Add reference to PlatformAbstractions * Skip prebuilt check for now * Update version of previously source-built archive * Update online prebuilt baseline * Disable smoke-tests and unit tests until core-sdk build works * Don't remove placeholder pdb files * Add back temporary ildasm workaround until AspNetCore builds * Update baseline with OSX only prebuilts * Update offline baseline * Turn off processing of smoke-test-packages * Update debian & ubuntu images and turn off leak detection * Update Centos8 docker image to one that includes updated cmake * Another try at updating the centos8 docker image * Update to latest version of Private.SourceBuild.ReferencePackages * Remove detection of and de-assemble/re-assemble of read only ref pkgs With the completion of #1497, the need to detect and remove these read only ref packages has been removed. All packages that we have identified as read-only in the past have been included in source-build-reference-packages. If any new ones show up, they will show up as prebuilts and can be added to the source-build-reference-packages repo. * Revert "Skip prebuilt check for now" This reverts commit 5766e7e. * Update offline baseline * Add comments & issue links to disabled items * Updates based on PR review comments * Update to document temporary smoke-test removal * Remove standard project Going forward the repo will only be used for servicing. * Update runtime dependency name Co-authored-by: Omair Majid <[email protected]>
1 parent 5be73eb commit b6c2aa3

File tree

116 files changed

+1544
-2575
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

116 files changed

+1544
-2575
lines changed

.vsts.pipelines/builds/matrix.yml

Lines changed: 38 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -13,34 +13,61 @@ jobs:
1313
- template: ../jobs/ci-linux.yml
1414
parameters:
1515
job: centos71
16-
imageName: mcr.microsoft.com/dotnet-buildtools/prereqs:centos-7-3e800f1-20190501005343
17-
reportPrebuiltLeaks: true
16+
imageName: mcr.microsoft.com/dotnet-buildtools/prereqs:centos-7-359e48e-20200313130914
17+
# Temporarily disable reporting on prebuilt leaks until entire product builds.
18+
# See https://github.com/dotnet/source-build/issues/1548
19+
reportPrebuiltLeaks: false
1820
matrix:
19-
Production: { generatePrebuiltBurndown: true, runUnitTests: true }
21+
# Temporarily disable unit tests until entire product builds.
22+
# See https://github.com/dotnet/source-build/issues/1549
23+
Production: { generatePrebuiltBurndown: true, runUnitTests: false }
2024
Online: { type: Online }
2125
Offline: { type: Offline }
2226
Offline Portable: { type: Offline Portable }
2327

24-
- template: ../jobs/ci-linux_bootstrap.yml
28+
# Temporarily disable bootstrap build until entire product builds.
29+
# See https://github.com/dotnet/source-build/issues/1550
30+
#- template: ../jobs/ci-linux_bootstrap.yml
31+
# parameters:
32+
# job: centos71_BootStrap
33+
# dependsOn: centos71
34+
# imageName: mcr.microsoft.com/dotnet-buildtools/prereqs:centos-7-359e48e-20200313130914
35+
# matrix:
36+
# Offline: { type: Offline}
37+
38+
- template: ../jobs/ci-linux.yml
2539
parameters:
26-
job: centos71_BootStrap
27-
dependsOn: centos71
28-
imageName: mcr.microsoft.com/dotnet-buildtools/prereqs:centos-7-3e800f1-20190501005343
40+
job: centos8
41+
imageName: mcr.microsoft.com/dotnet-buildtools/prereqs:centos-8-source-build-20200402192642-9e679d4
42+
systemLibunwind: false
2943
matrix:
30-
Offline: { type: Offline}
44+
Production: {}
45+
Online: { type: Online }
46+
Offline: { type: Offline }
47+
Offline Portable: { type: Offline Portable }
3148

3249
- template: ../jobs/ci-linux.yml
3350
parameters:
3451
job: debian9
35-
imageName: mcr.microsoft.com/dotnet-buildtools/prereqs:debian-stretch-d61254f-20190807161114
52+
imageName: mcr.microsoft.com/dotnet-buildtools/prereqs:debian-stretch-source-build-20200331133109-ed32d26
3653
matrix:
3754
Production: {}
3855
Online: { type: Online }
3956

4057
- template: ../jobs/ci-linux.yml
4158
parameters:
4259
job: fedora30
43-
imageName: mcr.microsoft.com/dotnet-buildtools/prereqs:fedora-30-38e0f29-20191126135223
60+
imageName: mcr.microsoft.com/dotnet-buildtools/prereqs:fedora-30-bfcd90a-20200324132732
61+
matrix:
62+
Production: {}
63+
Online: { type: Online }
64+
Offline: { type: Offline }
65+
Offline Portable: { type: Offline Portable }
66+
67+
- template: ../jobs/ci-linux.yml
68+
parameters:
69+
job: fedora31
70+
imageName: mcr.microsoft.com/dotnet-buildtools/prereqs:fedora-31-02f7c7e-20200324132728
4471
matrix:
4572
Production: {}
4673
Online: { type: Online }
@@ -50,7 +77,7 @@ jobs:
5077
- template: ../jobs/ci-linux.yml
5178
parameters:
5279
job: ubuntu1804
53-
imageName: mcr.microsoft.com/dotnet-buildtools/prereqs:ubuntu-18.04-f90bc20-20180320154721
80+
imageName: mcr.microsoft.com/dotnet-buildtools/prereqs:ubuntu-18.04-source-build-20200401093015-ed32d26
5481

5582
- template: ../jobs/ci-local.yml
5683
parameters:

.vsts.pipelines/jobs/ci-linux.yml

Lines changed: 38 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,7 @@ jobs:
3535
generatePrebuiltBurndown: ${{ parameters.generatePrebuiltBurndown }}
3636
rootDirectory: $(Build.SourcesDirectory)/..
3737
stagingDirectory: $(rootDirectory)/sb/staging
38+
systemLibunwind: ${{ parameters.systemLibunwind }}
3839
tarballName: tarball_$(Build.BuildId)
3940
SOURCE_BUILD_SKIP_SUBMODULE_CHECK: true
4041
# Default type, can be overridden by matrix legs.
@@ -66,6 +67,7 @@ jobs:
6667
$(docker.run) $(docker.src.map) $(docker.src.work) $(imageName) ./build.sh \
6768
/p:Configuration=$(sb.configuration) \
6869
/p:PortableBuild=$(sb.portable) \
70+
/p:UseSystemLibunwind=$(systemLibunwind) \
6971
/p:ArchiveDownloadedPackages=$(sb.tarball) \
7072
/p:FailOnPrebuiltBaselineError=$failOnBaselineError \
7173
/p:ProdConBlobFeedUrlPrefix=$(prodConBlobFeedUrlPrefix) \
@@ -85,15 +87,17 @@ jobs:
8587
continueOnError: true
8688
8789
# Run smoke tests. This is needed even in tarball legs to create the smoke-test-prereqs archive.
88-
- script: |
89-
set -ex
90-
df -h
91-
$(docker.run) $(docker.src.map) $(docker.src.work) $(imageName) ./build.sh \
92-
--run-smoke-test \
93-
/p:Configuration=$(sb.configuration) \
94-
/p:ProdConBlobFeedUrlPrefix=$(prodConBlobFeedUrlPrefix)
95-
du -h $(rootDirectory) | sort -h | tail -n 50
96-
displayName: Run smoke-test
90+
# Temporarily disable smoke-tests until entire product builds.
91+
# See https://github.com/dotnet/source-build/issues/1552
92+
# - script: |
93+
# set -ex
94+
# df -h
95+
# $(docker.run) $(docker.src.map) $(docker.src.work) $(imageName) ./build.sh \
96+
# --run-smoke-test \
97+
# /p:Configuration=$(sb.configuration) \
98+
# /p:ProdConBlobFeedUrlPrefix=$(prodConBlobFeedUrlPrefix)
99+
# du -h $(rootDirectory) | sort -h | tail -n 50
100+
# displayName: Run smoke-test
97101

98102
# Run unit tests that we support.
99103
- script: |
@@ -174,17 +178,25 @@ jobs:
174178
df -h
175179
$(docker.run) $(docker.tb.map) $(docker.drop.map) $(docker.tb.work) $(imageName) /bin/bash -c '
176180
mkdir -p /drop/tarball/
177-
smokeTestPackages="$(tarballName)/packages/smoke-test-packages"
181+
# Temporarily disable smoke-tests until entire product builds.
182+
# See https://github.com/dotnet/source-build/issues/1552
183+
##smokeTestPackages="$(tarballName)/packages/smoke-test-packages"
178184
# smokeTestPackages is a package cache, with redundant data and unnecessary structure. E.g.
179185
# $smokeTestPackages/name/version/name.version.nupkg <- We want this.
180186
# $smokeTestPackages/name/version/lib/net46/name.dll <- This is already in the nupkg.
181187
# This find moves the nupkg files into $smokeTestPackages:
182-
find "$smokeTestPackages" -iname "*.nupkg" -exec mv {} "$smokeTestPackages" \;
188+
# Temporarily disable smoke-tests until entire product builds.
189+
# See https://github.com/dotnet/source-build/issues/1552
190+
##find "$smokeTestPackages" -iname "*.nupkg" -exec mv {} "$smokeTestPackages" \;
183191
# This find removes all non-nupkg files, which are not wanted:
184-
find "$smokeTestPackages" -not -iname "*.nupkg" -delete
192+
# Temporarily disable smoke-tests until entire product builds.
193+
# See https://github.com/dotnet/source-build/issues/1552
194+
##find "$smokeTestPackages" -not -iname "*.nupkg" -delete
185195
# Make one .tar.gz for build, another for extras necessary to smoke test:
186196
tar --numeric-owner "--exclude=$smokeTestPackages" -zcf "/drop/tarball/$(tarballName).tar.gz" "$(tarballName)"
187-
tar --numeric-owner -zcf "/drop/tarball/$(tarballName)-smoke-test-prereqs.tar.gz" "$smokeTestPackages"'
197+
# Temporarily disable smoke-tests until entire product builds.
198+
# See https://github.com/dotnet/source-build/issues/1552
199+
##tar --numeric-owner -zcf "/drop/tarball/$(tarballName)-smoke-test-prereqs.tar.gz" "$smokeTestPackages"'
188200
du -h $(rootDirectory) | sort -h | tail -n 50
189201
displayName: Copy tarball to output
190202
condition: and(succeeded(), eq(variables['sb.tarball'], true))
@@ -204,6 +216,7 @@ jobs:
204216
$(docker.run) $(docker.tb.map) $(docker.tb.work) $networkArg $(imageName) "$(tarballName)/build.sh" -- \
205217
/p:Configuration=$(sb.configuration) \
206218
/p:PortableBuild=$(sb.portable) \
219+
/p:UseSystemLibunwind=$(systemLibunwind) \
207220
/p:FailOnPrebuiltBaselineError=true \
208221
$poisonArg
209222
du -h $(rootDirectory) | sort -h | tail -n 50
@@ -212,16 +225,18 @@ jobs:
212225
condition: and(succeeded(), eq(variables['sb.tarball'], true))
213226
214227
# Run smoke tests.
215-
- script: |
216-
set -ex
217-
df -h
218-
$(docker.run) $(docker.tb.map) $(docker.tb.work) $(imageName) "$(tarballName)/smoke-test.sh" \
219-
--minimal \
220-
--projectOutput \
221-
--configuration $(sb.configuration)
222-
du -h $(rootDirectory) | sort -h | tail -n 50
223-
displayName: Run smoke-test in tarball
224-
condition: and(succeeded(), eq(variables['sb.tarball'], true))
228+
# Temporarily disable smoke-tests until entire product builds.
229+
# See https://github.com/dotnet/source-build/issues/1552
230+
# - script: |
231+
# set -ex
232+
# df -h
233+
# $(docker.run) $(docker.tb.map) $(docker.tb.work) $(imageName) "$(tarballName)/smoke-test.sh" \
234+
# --minimal \
235+
# --projectOutput \
236+
# --configuration $(sb.configuration)
237+
# du -h $(rootDirectory) | sort -h | tail -n 50
238+
# displayName: Run smoke-test in tarball
239+
# condition: and(succeeded(), eq(variables['sb.tarball'], true))
225240

226241
- script: df -h
227242
displayName: Check space (df -h)

.vsts.pipelines/jobs/ci-local.yml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,9 @@ parameters:
77
scriptSuffix: null
88
setupMac: false
99
setupWindows: false
10-
skipSmokeTest: false
10+
# Temporarily disable smoke-tests until entire product builds.
11+
# See https://github.com/dotnet/source-build/issues/1552
12+
skipSmokeTest: true
1113
failOnPrebuiltBaselineError: true
1214

1315
jobs:

NuGet.config

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -2,13 +2,6 @@
22
<configuration>
33
<packageSources>
44
<clear />
5-
<!--Begin: Package sources managed by Dependency Flow automation. Do not edit the sources below.-->
6-
<add key="darc-pub-microsoft-msbuild-e901037-3" value="https://pkgs.dev.azure.com/dnceng/public/_packaging/darc-pub-microsoft-msbuild-e901037f-3/nuget/v3/index.json" />
7-
<add key="darc-pub-dotnet-standard-a5b5f2e" value="https://pkgs.dev.azure.com/dnceng/public/_packaging/darc-pub-dotnet-standard-a5b5f2e1/nuget/v3/index.json" />
8-
<add key="darc-pub-dotnet-aspnetcore-tooling-2dab42e" value="https://pkgs.dev.azure.com/dnceng/public/_packaging/darc-pub-dotnet-aspnetcore-tooling-2dab42e1/nuget/v3/index.json" />
9-
<add key="darc-pub-dotnet-aspnetcore-c3acdca-2" value="https://pkgs.dev.azure.com/dnceng/public/_packaging/darc-pub-dotnet-aspnetcore-c3acdcac-2/nuget/v3/index.json" />
10-
<add key="darc-pub-aspnet-Extensions-1286a6f" value="https://pkgs.dev.azure.com/dnceng/public/_packaging/darc-pub-aspnet-Extensions-1286a6ff/nuget/v3/index.json" />
11-
<!--End: Package sources managed by Dependency Flow automation. Do not edit the sources above.-->
125
<add key="api.nuget.org" value="https://api.nuget.org/v3/index.json" />
136
<add key="nuget-build" value="https://dotnet.myget.org/F/nuget-build/api/v3/index.json" />
147
<add key="arcade" value="https://dotnetfeed.blob.core.windows.net/dotnet-tools-internal/index.json" />

build-source-tarball.sh

Lines changed: 4 additions & 40 deletions
Original file line numberDiff line numberDiff line change
@@ -239,7 +239,9 @@ find "$PWD" -maxdepth 1 -type d | grep -v reference-assemblies | grep -v netcore
239239
popd
240240

241241
echo 'Removing binaries from tarball src...'
242-
find $TARBALL_ROOT/src \( -type f \( \
242+
# coreclr and installer have two empty placeholder pdb files. Exclude these directories.
243+
find $TARBALL_ROOT/src -not -path "*/src/coreclr/src/.nuget/*" -not -path "*/src/installer/pkg/*" \
244+
\( -type f \( \
243245
-iname *.dll -o \
244246
-iname *.exe -o \
245247
-iname *.pdb -o \
@@ -299,8 +301,6 @@ find $SCRIPT_ROOT/bin/obj/$targetArchitecture/Release/nuget-packages -name '*.nu
299301
# Copy reference-packages from bin dir to reference-packages directory.
300302
# See corresponding change in dir.props to change ReferencePackagesBasePath conditionally in offline build.
301303
mkdir -p $TARBALL_ROOT/packages/reference
302-
cp -r $SCRIPT_ROOT/bin/obj/$targetArchitecture/Release/reference-packages/source $TARBALL_ROOT/packages/reference/source
303-
cp -r $SCRIPT_ROOT/bin/obj/$targetArchitecture/Release/reference-packages/staging $TARBALL_ROOT/packages/reference/staging
304304

305305
# Copy tarballs to ./packages/archive directory
306306
if [[ -d "$SCRIPT_ROOT/bin/obj/$targetArchitecture/Release/external-tarballs" && ! -z "$(find $SCRIPT_ROOT/bin/obj/$targetArchitecture/Release/external-tarballs -iname '*.tar.gz')" ]]; then
@@ -337,14 +337,7 @@ if [ $INCLUDE_LEAK_DETECTION -eq 1 ]; then
337337
"$CLI_PATH/dotnet" publish -o $FULL_TARBALL_ROOT/tools-local/tasks/Microsoft.DotNet.SourceBuild.Tasks.LeakDetection $SCRIPT_ROOT/tools-local/tasks/Microsoft.DotNet.SourceBuild.Tasks.LeakDetection/Microsoft.DotNet.SourceBuild.Tasks.LeakDetection.csproj
338338
fi
339339

340-
echo 'Removing reference-only packages from tarball prebuilts...'
341-
342-
for ref_package in $(find $SCRIPT_ROOT/bin/obj/$targetArchitecture/Release/reference-packages/packages-to-delete/ -name '*.nupkg' | tr '[:upper:]' '[:lower:]')
343-
do
344-
if [ -e $TARBALL_ROOT/packages/prebuilt/$(basename $ref_package) ]; then
345-
rm $TARBALL_ROOT/packages/prebuilt/$(basename $ref_package)
346-
fi
347-
done
340+
echo 'Removing reference packages from tarball prebuilts...'
348341

349342
if [ -d "$CUSTOM_REF_PACKAGES_DIR" ]; then
350343
allRefPkgs=(`ls "$CUSTOM_REF_PACKAGES_DIR" | tr '[:upper:]' '[:lower:]'`)
@@ -402,35 +395,6 @@ if [ $SKIP_PREBUILT_ENFORCEMENT -ne 1 ]; then
402395
fi
403396
fi
404397

405-
echo 'Removing source-built, previously source-built packages and reference packages from il pkg src...'
406-
OLDIFS=$IFS
407-
408-
allBuiltPkgs=(`ls $SCRIPT_ROOT/bin/obj/$targetArchitecture/Release/blob-feed/packages/*.nupkg | xargs -n1 basename | tr '[:upper:]' '[:lower:]'`)
409-
pushd $TARBALL_ROOT/packages/reference/staging/
410-
ilSrcPaths=(`find . -maxdepth 2 -mindepth 2`)
411-
popd
412-
413-
for path in ${ilSrcPaths[@]}; do
414-
IFS='/'
415-
read -a splitLine <<< "$path"
416-
remove=false
417-
if [[ " ${allRefPkgs[@]} " =~ " ${splitLine[1]}.${splitLine[2]}.nupkg " ]]; then
418-
remove=true
419-
fi
420-
if [[ " ${allSourceBuiltPkgs[@]} " =~ " ${splitLine[1]}.${splitLine[2]}.nupkg " ]]; then
421-
remove=true
422-
fi
423-
if [[ " ${allBuiltPkgs[@]} " =~ " ${splitLine[1]}.${splitLine[2]}.nupkg " ]]; then
424-
remove=true
425-
fi
426-
if [[ "$remove" == "true" ]]; then
427-
rm -rf "$TARBALL_ROOT/packages/reference/staging/$path"
428-
rm -rf "$TARBALL_ROOT/packages/reference/source/$path"
429-
fi
430-
done
431-
432-
IFS=$OLDIFS
433-
434398
echo 'Recording commits for the source-build repo and all submodules, to aid in reproducibility...'
435399

436400
cat >$TARBALL_ROOT/source-build-info.txt << EOF

build.proj

Lines changed: 0 additions & 93 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@
44
<Import Project="eng/Versions.props" Condition="'$(OfflineBuild)' != 'true'" />
55

66
<UsingTask AssemblyFile="$(LeakDetectionTasksAssembly)" TaskName="CheckForPoison" />
7-
<UsingTask AssemblyFile="$(XPlatSourceBuildTasksAssembly)" TaskName="CopyReferenceOnlyPackages" />
87
<UsingTask AssemblyFile="$(XPlatSourceBuildTasksAssembly)" TaskName="WriteUsageBurndownData" />
98
<UsingTask AssemblyFile="$(XPlatSourceBuildTasksAssembly)" TaskName="ReplaceTextInFile" />
109

@@ -53,98 +52,6 @@
5352
<RemoveDir Directories="$(BaseOutputPath)" />
5453
</Target>
5554

56-
<!--
57-
Workaround: Skip Windows_NT.
58-
59-
When trying to CopyReferenceOnlyPackages, it gets errors like:
60-
61-
System.IO.IOException: The process cannot access the file
62-
'<root>\packages\microsoft.codeanalysis.compilers\2.6.0-beta3-62316-02\microsoft.codeanalysis.compilers.nuspec'
63-
because it is being used by another process.
64-
65-
We don't support producing a tarball on Windows, so there's little value in fixing this.
66-
-->
67-
<Target Name="CopyAndDisassembleReferenceOnlyPackages"
68-
AfterTargets="Build"
69-
Condition="'$(OfflineBuild)' != 'true' and '$(ArchiveDownloadedPackages)' == 'true' and '$(OS)' != 'Windows_NT'">
70-
71-
<CopyReferenceOnlyPackages
72-
PackageCacheDir="$(PackagesDir)"
73-
DllDestinationDir="$(ReferencePackagesSourceDir)"
74-
IdentifiedPackagesDir="$(ReferencePackagesToDeleteDir)"
75-
DestinationDir="$(ReferencePackagesStagingDir)"
76-
/>
77-
78-
<!-- Ildasm has trouble writing to paths that are longer than 260 chars. (see https://github.com/dotnet/coreclr/issues/20397)
79-
Create a temporary path to write il output which will then be copied back to the reference-packages/source dir.
80-
-->
81-
<PropertyGroup>
82-
<TempPath>$([System.IO.Path]::GetTempPath())</TempPath>
83-
<IldasmTempOutputFolderName>$([System.IO.Path]::GetRandomFileName())</IldasmTempOutputFolderName>
84-
<IldasmTempOutputPath>$([System.IO.Path]::Combine($(TempPath),$(IldasmTempOutputFolderName)))/</IldasmTempOutputPath>
85-
</PropertyGroup>
86-
87-
<ItemGroup>
88-
<ReferenceOnlyPackages Include="$(ReferencePackagesToDeleteDir)**/*.nupkg" />
89-
<ReferenceOnlyPackageDlls Include="$(ReferencePackagesSourceDir)**/*.dll" />
90-
</ItemGroup>
91-
92-
<Message Importance="High" Text="Reference-only Packages:" />
93-
<Message Importance="High" Text="%(ReferenceOnlyPackages.Identity)" />
94-
95-
<Message Importance="High" Text="[$([System.DateTime]::Now.ToString('HH:mm:ss.ff'))] Disassembling @(ReferenceOnlyPackageDlls->Count()) dlls" />
96-
<MakeDir Directories="$(IldasmTempOutputPath)%(ReferenceOnlyPackageDlls.RecursiveDir)" />
97-
<Exec Command="$(IldasmPath) %(ReferenceOnlyPackageDlls.Identity) -all -out=$(IldasmTempOutputPath)%(ReferenceOnlyPackageDlls.RecursiveDir)%(ReferenceOnlyPackageDlls.Filename).il" />
98-
<Message Importance="High" Text="[$([System.DateTime]::Now.ToString('HH:mm:ss.ff'))] Disassembly done." />
99-
100-
<ItemGroup>
101-
<IlSourceFiles Include="$(IldasmTempOutputPath)/**/*.il" />
102-
<OldLicenseFiles Include="$(ReferencePackagesStagingDir)/**/dotnet_library_license.txt" />
103-
<OldLicenseFiles Include="$(ReferencePackagesStagingDir)/**/License.rtf" />
104-
<RefAssyNuspecFiles Include="$(ReferencePackagesStagingDir)/**/*.nuspec" />
105-
</ItemGroup>
106-
107-
<Message Importance="High" Text="[$([System.DateTime]::Now.ToString('HH:mm:ss.ff'))] Copying @(IlSourceFiles->Count()) IL source files" />
108-
<Copy SourceFiles="@(IlSourceFiles)" DestinationFiles="$(ReferencePackagesSourceDir)%(IlSourceFiles.RecursiveDir)%(IlSourceFiles.Filename).il" />
109-
<Message Importance="High" Text="[$([System.DateTime]::Now.ToString('HH:mm:ss.ff'))] Copying IL source files done." />
110-
111-
<Message Importance="High" Text="[$([System.DateTime]::Now.ToString('HH:mm:ss.ff'))] Deleting disassembled dlls and temp il source" />
112-
<Delete Files="@(ReferenceOnlyPackageDlls)" />
113-
<RemoveDir Directories="$(IldasmTempOutputPath)" />
114-
<Message Importance="High" Text="[$([System.DateTime]::Now.ToString('HH:mm:ss.ff'))] Deleting disassembled dlls and temp il source done." />
115-
116-
<!-- Update licenseUrl to MIT license where needed in nuspec files -->
117-
<ReplaceTextInFile InputFile="%(RefAssyNuspecFiles.Identity)"
118-
OldText="http://go.microsoft.com/fwlink/?LinkId=329770"
119-
NewText="https://microsoft.mit-license.org/" />
120-
<ReplaceTextInFile InputFile="%(RefAssyNuspecFiles.Identity)"
121-
OldText="https://www.microsoft.com/web/webpi/eula/net_library_eula_enu.htm"
122-
NewText="https://microsoft.mit-license.org/" />
123-
<ReplaceTextInFile InputFile="%(RefAssyNuspecFiles.Identity)"
124-
OldText="http://go.microsoft.com/fwlink/?LinkId=529443"
125-
NewText="https://microsoft.mit-license.org/" />
126-
</Target>
127-
128-
<Target Name="ReplaceLicenseFiles"
129-
AfterTargets="CopyAndDisassembleReferenceOnlyPackages"
130-
Outputs="%(OldLicenseFiles.Identity)"
131-
Condition="'$(OfflineBuild)' != 'true' and '$(ArchiveDownloadedPackages)' == 'true' and '$(OS)' != 'Windows_NT'">
132-
<!-- Create Item of all unique directories containing old licenses -->
133-
<CreateItem Include="%(OldLicenseFiles.RelativeDir)">
134-
<Output TaskParameter="Include" ItemName="DestinationDirs" />
135-
</CreateItem>
136-
137-
<PropertyGroup>
138-
<DestinationDirIdentity>%(DestinationDirs.Identity)</DestinationDirIdentity>
139-
</PropertyGroup>
140-
<ItemGroup>
141-
<NewLicenseFile Include="$(ProjectDir)LICENSE.txt" />
142-
</ItemGroup>
143-
<Copy SourceFiles="@(NewLicenseFile)" DestinationFiles="@(NewLicenseFile->'$(DestinationDirIdentity)%(RecursiveDir)%(Filename)%(Extension)')" />
144-
145-
<Delete Files="@(OldLicenseFiles)" />
146-
</Target>
147-
14855
<Target Name="DownloadSourceBuildReferencePackages"
14956
AfterTargets="Build"
15057
Condition="'$(OfflineBuild)' != 'true' and '$(OS)' != 'Windows_NT' and '$(SkipDownloadingReferencePackages)' != 'true'">

0 commit comments

Comments
 (0)