Create directories for coreclr / corefx
authorWoongsuk Cho <ws77.cho@samsung.com>
Mon, 8 Apr 2019 04:37:49 +0000 (13:37 +0900)
committer이형주/Common Platform Lab(SR)/Staff Engineer/삼성전자 <leee.lee@samsung.com>
Wed, 10 Apr 2019 00:36:21 +0000 (09:36 +0900)
 - /tmp/.dotnet : lockfiles for IPC is created under /tmp/.dotnet directory
 - /home/owner/.dotnet : intermediate cert and temporal cert chain is stored under /home/owner/.dotnet

packaging/dotnet-launcher.conf [new file with mode: 0755]
packaging/dotnet-launcher.spec

diff --git a/packaging/dotnet-launcher.conf b/packaging/dotnet-launcher.conf
new file mode 100755 (executable)
index 0000000..9833cd2
--- /dev/null
@@ -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"
index 1c4f4a4..3afa960 100644 (file)
@@ -6,6 +6,7 @@ Group:      Application Framework/Application State Management
 License:    Apache-2.0
 Source0:    %{name}-%{version}.tar.gz
 AutoReqProv: no
+Source1: %{name}.conf
 
 BuildRequires: cmake
 BuildRequires: pkgconfig(aul)
@@ -32,6 +33,7 @@ Requires: liblaunchpad
 
 Requires(post): /sbin/ldconfig
 Requires(post): /usr/bin/systemctl
+Requires(post): /usr/bin/chsmack
 Requires(postun): /sbin/ldconfig
 Requires(postun): /usr/bin/systemctl
 Requires(preun): /usr/bin/systemctl
@@ -57,6 +59,7 @@ and AOTC tools.
 
 %prep
 %setup -q
+cp %{SOURCE1} .
 
 %build
 
@@ -99,6 +102,13 @@ rm -rf %{buildroot}
 mkdir -p %{buildroot}%{_native_lib_dir}
 ln -sf %{_libdir}/libsqlite3.so.0 %{buildroot}%{_native_lib_dir}/libsqlite3.so
 
+mkdir -p %{buildroot}/etc/tmpfiles.d
+install -m 0644 %{name}.conf %{buildroot}/etc/tmpfiles.d/%{name}.conf
+
+%post
+mkdir -p /opt/etc/skel/.dotnet
+chsmack -t -a User::App::Shared /opt/etc/skel/.dotnet
+
 %files
 %manifest dotnet-launcher.manifest
 %{_loaderdir}/dotnet.loader
@@ -110,6 +120,7 @@ ln -sf %{_libdir}/libsqlite3.so.0 %{buildroot}%{_native_lib_dir}/libsqlite3.so
 %{_bindir}/dotnet-launcher
 %{_libdir}/libdotnet_launcher_util.so
 %{_libdir}/libni_common.so
+/etc/tmpfiles.d/%{name}.conf
 
 %files devel
 %manifest dotnet-launcher.manifest