Optimize code and rename files 90/285390/1
authorj-h.choi <j-h.choi@samsung.com>
Mon, 12 Dec 2022 05:13:35 +0000 (14:13 +0900)
committerj-h.choi <j-h.choi@samsung.com>
Mon, 12 Dec 2022 05:13:35 +0000 (14:13 +0900)
Change-Id: I2d3818568dc931a6b6b1a01dc364b114c025e2ed

packaging/dotnet-build-tools.spec
targets/Tizen.Pre.Compiled.Reference.targets [moved from targets/Tizen.Pre.AOT.Reference.targets with 77% similarity]
targets/Tizen.Pre.Compiled.targets [moved from targets/Tizen.Pre.AOT.targets with 78% similarity]

index 111388d..189d840 100644 (file)
@@ -93,9 +93,9 @@ ln -s %{TOOLS_PATH}/dotnet-wrapper.sh %{buildroot}%{_bindir}/dotnet
 ln -s %{TOOLS_PATH}/dotnet-validate-struct.sh %{buildroot}%{_bindir}/dotnet-validate-struct
 ln -s %{SDK_PATH}/crossgen2/crossgen2 %{buildroot}%{_bindir}/crossgen2
 
-# Tizen.Pre.AOT.BuildTasks
-install -p -m 644 ./targets/Tizen.Pre.AOT.targets %{buildroot}%{SDK_PATH}/sdk/*/Current/Microsoft.Common.targets/ImportAfter
-install -p -m 644 ./targets/Tizen.Pre.AOT.Reference.targets %{buildroot}%{SDK_PATH}/sdk/*/Current/Microsoft.Common.targets/ImportAfter
+# Tizen.Pre.Compiled.BuildTasks
+install -p -m 644 ./targets/Tizen.Pre.Compiled.targets %{buildroot}%{SDK_PATH}/sdk/*/Current/Microsoft.Common.targets/ImportAfter
+install -p -m 644 ./targets/Tizen.Pre.Compiled.Reference.targets %{buildroot}%{SDK_PATH}/sdk/*/Current/Microsoft.Common.targets/ImportAfter
 
 %files
 %config(noreplace) %{_sysconfdir}/rpm/macros.dotnet-build-tools
similarity index 77%
rename from targets/Tizen.Pre.AOT.Reference.targets
rename to targets/Tizen.Pre.Compiled.Reference.targets
index 5a036c1..822db36 100644 (file)
@@ -1,6 +1,7 @@
 <Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
-  <Target Name="PreAOTReference"
-          AfterTargets="coreGenerateSatelliteAssemblies">
+  <Target Name="PreCompiledReference"
+          AfterTargets="coreGenerateSatelliteAssemblies"
+          Condition="'$(TizenGBSBuildArch)' !=''">
 
     <PropertyGroup>
       <AppReferencePath>@(ReferencePath)</AppReferencePath>
similarity index 78%
rename from targets/Tizen.Pre.AOT.targets
rename to targets/Tizen.Pre.Compiled.targets
index 0ae5395..cfb8240 100644 (file)
@@ -1,7 +1,8 @@
 <Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
-  <Target Name="PreAOT"
+  <Target Name="PreCompiled"
           AfterTargets="_TizenPrepareTpkPackage"
-          BeforeTargets="TizenPrepareCertificate">
+          BeforeTargets="TizenPrepareCertificate"
+          Condition="'$(TizenGBSBuildArch)' !=''">
 
     <PropertyGroup>
       <TpkRootPath>$(OutputPath)tpkroot/</TpkRootPath>
     </PropertyGroup>
 
     <Exec Command ="find $(BinPath) -maxdepth 1 -name '*.dll'" ConsoleToMSBuild="true" >
-      <Output TaskParameter="ConsoleOutput" PropertyName="FindDllOfBin" />
+      <Output TaskParameter="ConsoleOutput" ItemName="DllListOfBin" />
     </Exec>
     <Exec Command ="find $(LibPath) -maxdepth 1 -name '*.dll'" ConsoleToMSBuild="true" >
-      <Output TaskParameter="ConsoleOutput" PropertyName="FindDllOfLib" />
+      <Output TaskParameter="ConsoleOutput" ItemName="DllListOfLib" />
     </Exec>
     <Exec Command ="find $(BinPath) -maxdepth 1 -name '*.pdb'" ConsoleToMSBuild="true" >
-      <Output TaskParameter="ConsoleOutput" PropertyName="FindPdbOfBin" />
+      <Output TaskParameter="ConsoleOutput" ItemName="PdbListOfBin" />
     </Exec>
     <Exec Command ="find $(LibPath) -maxdepth 1 -name '*.pdb'" ConsoleToMSBuild="true" >
-      <Output TaskParameter="ConsoleOutput" PropertyName="FindPdbOfLib" />
+      <Output TaskParameter="ConsoleOutput" ItemName="PdbListOfLib" />
     </Exec>
 
-    <ItemGroup>
-      <DllListOfBin Include="$(FindDllOfBin)" />
-    </ItemGroup>
-    <ItemGroup>
-      <DllListOfLib Include="$(FindDllOfLib)" />
-    </ItemGroup>
-    <ItemGroup>
-      <PdbListOfBin Include="$(FindPdbOfBin)" />
-    </ItemGroup>
-    <ItemGroup>
-      <PdbListOfLib Include="$(FindPdbOfLib)" />
-    </ItemGroup>
-
     <Exec Command="mkdir $(BinNativeImagePath)" Condition="@(DllListOfBin->Count()) != 0 OR @(PdbListOfBin->Count()) != 0" />
     <Exec Command="mkdir $(LibNativeImagePath)" Condition="@(DllListOfLib->Count()) != 0 OR @(PdbListOfLib->Count()) != 0" />