updated on Tue Jan 17 16:10:12 UTC 2012
[aur-mirror.git] / plymouth-systemd-git / plymouth.initcpio_install
blob182ad199bfd44cb67595e2efd474fef0fae309a9
1 build() {
2         add_dir /dev/pts
3         add_dir /usr/share/plymouth/themes
5         DATADIR="/usr/share"
6         PLYMOUTH_LOGO_FILE="${DATADIR}/plymouth/arch-logo.png"
7         PLYMOUTH_THEME_NAME="$(/usr/sbin/plymouth-set-default-theme)"
8         PLYMOUTH_MODULE_NAME="$(grep "ModuleName *= *" ${DATADIR}/plymouth/themes/${PLYMOUTH_THEME_NAME}/${PLYMOUTH_THEME_NAME}.plymouth | sed 's/ModuleName *= *//')"
9         PLYMOUTH_PLUGIN_PATH="$(plymouth --get-splash-plugin-path)"
11         add_binary /sbin/plymouthd
12         add_binary /bin/plymouth
14         add_file ${DATADIR}/plymouth/themes/text/text.plymouth
15         add_binary ${PLYMOUTH_PLUGIN_PATH}/text.so
16         add_file ${DATADIR}/plymouth/themes/details/details.plymouth
17         add_binary ${PLYMOUTH_PLUGIN_PATH}/details.so
20         add_file "${PLYMOUTH_LOGO_FILE}"
21         add_file /etc/system-release /etc/system-release
22         add_file /etc/plymouth/plymouthd.conf
23         add_file ${DATADIR}/plymouth/plymouthd.defaults
25         if [ ! -f ${PLYMOUTH_PLUGIN_PATH}/${PLYMOUTH_MODULE_NAME}.so ]; then
26             echo "The default plymouth plugin (${PLYMOUTH_MODULE_NAME}) doesn't exist" > /dev/stderr
27             exit 1
28         fi
30         add_binary ${PLYMOUTH_PLUGIN_PATH}/${PLYMOUTH_MODULE_NAME}.so
32         add_binary ${PLYMOUTH_PLUGIN_PATH}/renderers/drm.so
33         #add_binary ${PLYMOUTH_PLUGIN_PATH}/renderers/x11.so
34         add_binary ${PLYMOUTH_PLUGIN_PATH}/renderers/frame-buffer.so
36         if [ -d ${DATADIR}/plymouth/themes/${PLYMOUTH_THEME_NAME} ]; then
37             for x in ${DATADIR}/plymouth/themes/${PLYMOUTH_THEME_NAME}/* ; do
38                 [ ! -f "$x" ] && break
39                 add_file $x
40             done
41         fi
43         # suppress a warning in glib (which the label control uses)
44         # about uid 0 by building a dummy NSS stack (LP #649917)
45         add_file /etc/passwd
46         add_file /etc/nsswitch.conf
47         add_binary "$(readlink -e /lib/libnss_files.so.2)"
48         add_file /lib/libnss_files.so.2
50         SCRIPT='plymouth'
53 help() {
54         echo "This hook includes plymouth in the initramfs image."
57 # vim: set ft=sh:
58 #EOF