From: j-h.choi Date: Fri, 9 Dec 2022 05:40:34 +0000 (+0900) Subject: The Pre-Compiled is supported X-Git-Tag: accepted/tizen/unified/20221216.024044~4 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=9cac217c0e1fc6e505fe4f33f71094d81a318564;p=platform%2Fcore%2Fdotnet%2Fbuild-tools.git The Pre-Compiled is supported https://github.sec.samsung.net/dotnet/launcher/pull/444 Change-Id: I1707237bcdf3ededb327685e9d65dcc0f28ea6aa --- diff --git a/packaging/dotnet-build-tools.spec b/packaging/dotnet-build-tools.spec index 91d6b512..111388db 100644 --- a/packaging/dotnet-build-tools.spec +++ b/packaging/dotnet-build-tools.spec @@ -16,6 +16,10 @@ Source22: deps.tar.gz AutoReqProv: no BuildRequires: patchelf +BuildRequires: mscorlib +BuildRequires: corefx-managed +BuildRequires: csapi-tizenfx-full +BuildRequires: crossgen2-mic Requires: corefx-managed-ref Requires: libicu @@ -33,9 +37,14 @@ Provides dotnet-sdk for GBS environment %setup -q mkdir -p dotnet/deps +mkdir -p dotnet/crossgen2/ref tar xvfz %{SOURCE21} -C dotnet tar xvfz %{SOURCE22} -C dotnet/deps +cp -rf /opt/usr/dotnet/mic/* dotnet/crossgen2 +cp -rf /usr/share/dotnet.tizen/netcoreapp/*.dll dotnet/crossgen2/ref +cp -rf /usr/share/dotnet.tizen/framework/*.dll dotnet/crossgen2/ref + %build # Prepare dotnet-sdk %ifnarch x86_64 @@ -50,13 +59,21 @@ do chmod 0755 ${file} patchelf --set-rpath %{SDK_PATH}/deps/ ${file} done + +# Prepare crossgen2 +chmod 0755 ./dotnet/crossgen2/* -R +patchelf --set-interpreter %{SDK_PATH}/crossgen2/ld-linux-x86-64.so.2 ./dotnet/crossgen2/crossgen2 +patchelf --set-rpath %{SDK_PATH}/crossgen2/ ./dotnet/crossgen2/crossgen2 +for file in $( find ./dotnet/crossgen2 -type f \( -name "*.so" -or -name "*.so.*" \) -not -name "*.dbg" -not -name "ld-*.so*" ) +do + patchelf --set-rpath %{SDK_PATH}/crossgen2/ ${file} +done %endif # overrides cp -f overrides/Microsoft.Build.Tasks.Core.dll dotnet/sdk/*/Microsoft.Build.Tasks.Core.dll %install - mkdir -p %{buildroot}%{_bindir} mkdir -p %{buildroot}%{SDK_PATH} @@ -74,6 +91,11 @@ cp -fr ./tools/* %{buildroot}%{TOOLS_PATH} ln -s %{TOOLS_PATH}/dotnet-build.sh %{buildroot}%{_bindir}/dotnet-build 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 %files %config(noreplace) %{_sysconfdir}/rpm/macros.dotnet-build-tools diff --git a/targets/Tizen.Pre.AOT.Reference.targets b/targets/Tizen.Pre.AOT.Reference.targets new file mode 100644 index 00000000..5a036c16 --- /dev/null +++ b/targets/Tizen.Pre.AOT.Reference.targets @@ -0,0 +1,16 @@ + + + + + @(ReferencePath) + + + + + + + + + + diff --git a/targets/Tizen.Pre.AOT.targets b/targets/Tizen.Pre.AOT.targets new file mode 100644 index 00000000..0ae53958 --- /dev/null +++ b/targets/Tizen.Pre.AOT.targets @@ -0,0 +1,51 @@ + + + + + $(OutputPath)tpkroot/ + $(TpkRootPath)bin/ + $(TpkRootPath)lib/ + $(BinPath).native_image/ + $(LibPath).native_image/ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +