Add policy versioning 70/88670/1
authorZofia Abramowska <z.abramowska@samsung.com>
Tue, 6 Sep 2016 09:33:24 +0000 (11:33 +0200)
committerRafal Krypa <r.krypa@samsung.com>
Tue, 20 Sep 2016 07:35:13 +0000 (00:35 -0700)
Policy versioning will be used to reload policy when the
way it is generated changes. Additional script for reloading policy
between versions will be provided when policy generation is changed.

Change-Id: I778b6ebcdf6233924223921f65e2a037df0345b3

packaging/security-manager.spec
policy/CMakeLists.txt
policy/policy-version [new file with mode: 0644]

index 112fdc05e55b4152f2bed78b1a729f6a23de645c..4642dbccd202b37e1821cf6f9f72cf4b13625a2e 100644 (file)
@@ -221,5 +221,6 @@ fi
 
 %files -n security-manager-policy
 %manifest %{name}.manifest
+%config(noreplace) %{TZ_SYS_VAR}/security-manager/policy-version
 %{_datadir}/security-manager/policy
 %attr(755,root,root) %{_bindir}/security-manager-policy-reload
index 8daa099571efade3ce9496bf84e77f2659d97491..60f3540c2fd493a90a8e4e7da96daf3a2ebc9547 100644 (file)
@@ -7,4 +7,5 @@ INSTALL(FILES "app-rules-template.smack" DESTINATION ${POLICY_DIR})
 INSTALL(FILES "pkg-rules-template.smack" DESTINATION ${POLICY_DIR})
 INSTALL(FILES "author-rules-template.smack" DESTINATION ${POLICY_DIR})
 INSTALL(FILES "privilege-group.list" DESTINATION ${POLICY_DIR})
+INSTALL(FILES "policy-version" DESTINATION ${LOCAL_STATE_DIR}/security-manager/)
 INSTALL(PROGRAMS security-manager-policy-reload DESTINATION ${BIN_INSTALL_DIR})
diff --git a/policy/policy-version b/policy/policy-version
new file mode 100644 (file)
index 0000000..d00491f
--- /dev/null
@@ -0,0 +1 @@
+1