patterns/generic-middleware: remove security-server
[platform/upstream/meta-generic.git] / scripts / generic-base.post
index 5ed3d5c..83ef275 100644 (file)
@@ -1,6 +1,17 @@
 #!/bin/sh
 echo "#################### generic-base.post ####################"
 
+build_ts=$(date -u +%s)
+build_date=$(date -u --date @$build_ts +%Y%m%d_%H%M%S)
+build_time=$(date -u --date @$build_ts +%H:%M:%S)
+
+sed -ri \
+       -e 's|@BUILD_ID[@]|@BUILD_ID@|g' \
+       -e "s|@BUILD_DATE[@]|$build_date|g" \
+       -e "s|@BUILD_TIME[@]|$build_time|g" \
+       -e "s|@BUILD_TS[@]|$build_ts|g" \
+       /etc/tizen-build.conf
+
 # setup systemd default target for user session
 cat <<'EOF' >>/lib/systemd/user/default.target
 [Unit]
@@ -19,33 +30,6 @@ ln -sf /proc/self/mounts /etc/mtab
 # sdx: fix smack labels on /var/log
 chsmack -a '*' /var/log
 
-# workaround for bug PTREL-763
-patch -b -p1 -d/ <<'EOF'
---- bad/etc/pam.d/systemd-user 2014-03-20 10:01:36.657843073 +0100
-+++ good/etc/pam.d/systemd-user 2014-03-20 10:06:51.586121696 +0100
-@@ -4,5 +4,6 @@
- account include system-auth
- session include system-auth
-+session required pam_systemd.so
- auth required pam_deny.so
- password required pam_deny.so
-EOF
-
-# extra fix to avoid root and display sessions (PTREL-763)
-patch -b -p1 -d/ <<'EOF'
---- bad/etc/pam.d/system-auth  2014-04-07 06:16:51.888018876 -0700
-+++ good/etc/pam.d/system-auth 2014-04-07 06:16:46.335018503 -0700
-@@ -11,7 +11,6 @@
- password    required      pam_deny.so
- session     optional      pam_keyinit.so revoke
--session     optional      pam_systemd.so
- session     required      pam_limits.so
- session     [success=1 default=ignore] pam_succeed_if.so service in crond quiet use_uid
- session     required      pam_unix.so
-EOF
-
 # create appfw dirs inside homes
 function generic_base_user_exists() {
        user=$1
@@ -62,6 +46,7 @@ function generic_base_fix_user_homedir() {
        generic_base_user_exists $user || return 1
 
        homedir=$(generic_base_user_home $user)
+       mkdir -p $homedir/apps_rw
        for appdir in desktop manifest dbspace; do
                mkdir -p $homedir/.applications/$appdir
        done
@@ -69,3 +54,10 @@ function generic_base_fix_user_homedir() {
        chown -R $user:users $homedir
        return 0
 }
+
+# fix TC-320 for SDK
+. /etc/tizen-build.conf
+[ "${TZ_BUILD_WITH_EMULATOR}" == "1" ] && generic_base_fix_user_homedir developer
+
+# Add info.ini for system-info CAPI (TC-2047)
+/etc/make_info_file.sh