summaryrefslogtreecommitdiffstats
path: root/meta/recipes-core/base-files
diff options
context:
space:
mode:
authorChen Qi <Qi.Chen@windriver.com>2018-08-01 13:25:35 +0800
committerRichard Purdie <richard.purdie@linuxfoundation.org>2018-08-14 11:36:31 +0100
commit96eb506b5b213a2e15d74c1bbf940f563a3b7869 (patch)
treef5c2ce8ad354cb9821382499f0e84762ea750899 /meta/recipes-core/base-files
parentb6fbb3f3d4d6367b0fd7921078f67057551c7ede (diff)
downloadpoky-96eb506b5b213a2e15d74c1bbf940f563a3b7869.tar.gz
base-files: fix handling of resize
The current handling of resize is incorrect. Using `resize > /dev/null 2>&1 && resize > /dev/null' will cause the second resize command to not execute because 'resize > /dev/null 2>&1' will fail for resize utility from busybox. What we really should do is just to check whether ${bindir}/resize is executable and execute it if so. Using '-x' is sufficient. (From OE-Core rev: 41688279cba3a5afc4fdc65fd245b9bb6ada695e) Signed-off-by: Chen Qi <Qi.Chen@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-core/base-files')
-rw-r--r--meta/recipes-core/base-files/base-files/profile6
-rw-r--r--meta/recipes-core/base-files/base-files_3.0.14.bb1
2 files changed, 2 insertions, 5 deletions
diff --git a/meta/recipes-core/base-files/base-files/profile b/meta/recipes-core/base-files/base-files/profile
index e14cb2d878..9e4283e0c7 100644
--- a/meta/recipes-core/base-files/base-files/profile
+++ b/meta/recipes-core/base-files/base-files/profile
@@ -24,11 +24,7 @@ fi
24# /dev/tty[A-z]), otherwise we confuse e.g. the eclipse launcher which tries do 24# /dev/tty[A-z]), otherwise we confuse e.g. the eclipse launcher which tries do
25# use ssh 25# use ssh
26case $(tty 2>/dev/null) in 26case $(tty 2>/dev/null) in
27 # The first invocation of resize verifies that it exists, the second 27 /dev/tty[A-z]*) [ -x @BINDIR@/resize ] && @BINDIR@/resize >/dev/null;;
28 # does the actual resizing. This is due to that resize uses stderr to
29 # determine the size of the tty, which does not work if it is redirected
30 # to /dev/null.
31 /dev/tty[A-z]*) resize >/dev/null 2>&1 && resize >/dev/null;;
32esac 28esac
33 29
34export PATH PS1 OPIEDIR QPEDIR QTDIR EDITOR TERM 30export PATH PS1 OPIEDIR QPEDIR QTDIR EDITOR TERM
diff --git a/meta/recipes-core/base-files/base-files_3.0.14.bb b/meta/recipes-core/base-files/base-files_3.0.14.bb
index 1c0863b1c7..05c0562661 100644
--- a/meta/recipes-core/base-files/base-files_3.0.14.bb
+++ b/meta/recipes-core/base-files/base-files_3.0.14.bb
@@ -121,6 +121,7 @@ do_install () {
121 install -m 0644 ${WORKDIR}/usbd ${D}${sysconfdir}/default/usbd 121 install -m 0644 ${WORKDIR}/usbd ${D}${sysconfdir}/default/usbd
122 install -m 0644 ${WORKDIR}/profile ${D}${sysconfdir}/profile 122 install -m 0644 ${WORKDIR}/profile ${D}${sysconfdir}/profile
123 sed -i 's#ROOTHOME#${ROOT_HOME}#' ${D}${sysconfdir}/profile 123 sed -i 's#ROOTHOME#${ROOT_HOME}#' ${D}${sysconfdir}/profile
124 sed -i 's#@BINDIR@#${bindir}#g' ${D}${sysconfdir}/profile
124 install -m 0644 ${WORKDIR}/shells ${D}${sysconfdir}/shells 125 install -m 0644 ${WORKDIR}/shells ${D}${sysconfdir}/shells
125 install -m 0755 ${WORKDIR}/share/dot.profile ${D}${sysconfdir}/skel/.profile 126 install -m 0755 ${WORKDIR}/share/dot.profile ${D}${sysconfdir}/skel/.profile
126 install -m 0755 ${WORKDIR}/share/dot.bashrc ${D}${sysconfdir}/skel/.bashrc 127 install -m 0755 ${WORKDIR}/share/dot.bashrc ${D}${sysconfdir}/skel/.bashrc