summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorWoongsuk Cho <ws77.cho@samsung.com>2019-01-10 10:38:05 (GMT)
committerAlexander Soldatov/AI Ecosystem Lab /SRR/Staff Engineer/삼성전자 <soldatov.a@samsung.com>2019-02-14 17:24:48 (GMT)
commit201263c27e970e9d2e50c6bccdc82ecdab2893e0 (patch)
treed9642612924d862a72496d9090f154a66147f93b
parente37665f85413aac581ebaec05f46ed05c3136aa1 (diff)
downloadcoreclr-201263c27e970e9d2e50c6bccdc82ecdab2893e0.zip
coreclr-201263c27e970e9d2e50c6bccdc82ecdab2893e0.tar.gz
coreclr-201263c27e970e9d2e50c6bccdc82ecdab2893e0.tar.bz2
[Tizen] create "/tmp/.dotnet/lockfiles" directory while system bootup.
If "/tmp/.dotnet/lockfiles" directory does not exist, a directory is created when the first named mutex file is created. The generated directory has the smack label of the process that created it. Therefore, access deny occurs when another application tries to access the directory to create or use a named mutex. To solve this problem, create "/tmp/.dotnet/lockfiles" directory in the tempfs while system boot up
-rwxr-xr-xpackaging/coreclr.conf13
-rwxr-xr-xpackaging/coreclr.spec5
2 files changed, 18 insertions, 0 deletions
diff --git a/packaging/coreclr.conf b/packaging/coreclr.conf
new file mode 100755
index 0000000..9833cd2
--- /dev/null
+++ b/packaging/coreclr.conf
@@ -0,0 +1,13 @@
+d /tmp/.dotnet 1777 root users
+t /tmp/.dotnet - - - - security.SMACK64="User::App::Shared"
+t /tmp/.dotnet - - - - security.SMACK64TRANSMUTE="TRUE"
+d /tmp/.dotnet/lockfiles 1777 root users
+t /tmp/.dotnet/lockfiles - - - - security.SMACK64="User::App::Shared"
+d /tmp/.dotnet/lockfiles/global 1777 root users
+t /tmp/.dotnet/lockfiles/global - - - - security.SMACK64="User::App::Shared"
+t /tmp/.dotnet/lockfiles/global - - - - security.SMACK64TRANSMUTE="TRUE"
+d /tmp/.dotnet/shm 1777 root users
+t /tmp/.dotnet/shm - - - - security.SMACK64="User::App::Shared"
+d /tmp/.dotnet/shm/global 1777 root users
+t /tmp/.dotnet/shm/global - - - - security.SMACK64="User::App::Shared"
+t /tmp/.dotnet/shm/global - - - - security.SMACK64TRANSMUTE="TRUE"
diff --git a/packaging/coreclr.spec b/packaging/coreclr.spec
index 212e9f8..ad54d76 100755
--- a/packaging/coreclr.spec
+++ b/packaging/coreclr.spec
@@ -17,6 +17,7 @@ License: MIT
URL: http://github.com/dotnet/coreclr
Source0: %{name}-%{version}.tar.gz
Source1: %{name}.manifest
+Source2: %{name}.conf
ExcludeArch: aarch64
@@ -105,6 +106,7 @@ The MSCORLIB.DLL for .NET Core Runtime (coreclr)
%prep
%setup -q -n %{name}-%{version}
cp %{SOURCE1} .
+cp %{SOURCE2} .
%if 0%{skipmscorlib}
@@ -210,6 +212,8 @@ mkdir -p %{buildroot}%{_datadir}/%{dotnettizendir}
mkdir -p %{buildroot}%{_datadir}/%{dotnetfwdir}
mkdir -p %{buildroot}%{_datadir}/%{dotnettestdir}
ln -sf %{_datadir}/%{netcoreappdir} %{buildroot}%{_datadir}/%{dotnettizendir}/netcoreapp
+mkdir -p %{buildroot}/etc/tmpfiles.d
+install -m 0644 %{name}.conf %{buildroot}/etc/tmpfiles.d/%{name}.conf
# symlink to .NET version for compatibility
ln -sf %{dotnet_version} %{buildroot}%{_datadir}/%{netshareddir}/Microsoft.NETCore.App/2.0.0
@@ -284,6 +288,7 @@ cp %{_reldir}/SOS.NETCore.dll %{buildroot}%{_datadir}/%{netcoreappdir}
%{_datadir}/%{dotnetfwdir}/crossgen
%{_datadir}/%{netcoreappdir}/*.so
%{_datadir}/%{dotnettizendir}/netcoreapp
+/etc/tmpfiles.d/%{name}.conf
# symlink to .NET version for compatibility
%dir %{_datadir}/%{netshareddir}/Microsoft.NETCore.App/2.0.0