summaryrefslogtreecommitdiffstats
path: root/meta/recipes-bsp/qemu-config
diff options
context:
space:
mode:
Diffstat (limited to 'meta/recipes-bsp/qemu-config')
-rw-r--r--meta/recipes-bsp/qemu-config/qemu-config.bb36
-rw-r--r--meta/recipes-bsp/qemu-config/qemu-config/anjuta-remote-run7
-rw-r--r--meta/recipes-bsp/qemu-config/qemu-config/distcc.sh4
-rw-r--r--meta/recipes-bsp/qemu-config/qemu-config/exports1
-rwxr-xr-xmeta/recipes-bsp/qemu-config/qemu-config/qemu-autostart37
-rw-r--r--meta/recipes-bsp/qemu-config/qemu-config/qemuarm/shutdown.desktop10
-rw-r--r--meta/recipes-bsp/qemu-config/qemu-config/shutdown.desktop10
7 files changed, 105 insertions, 0 deletions
diff --git a/meta/recipes-bsp/qemu-config/qemu-config.bb b/meta/recipes-bsp/qemu-config/qemu-config.bb
new file mode 100644
index 0000000000..fc59320282
--- /dev/null
+++ b/meta/recipes-bsp/qemu-config/qemu-config.bb
@@ -0,0 +1,36 @@
1DESCRIPTION = "Adds scripts to use distcc on the host system under qemu"
2LICENSE = "GPL"
3RDEPENDS = "distcc task-poky-nfs-server oprofileui-server rsync bash"
4PR = "r17"
5
6SRC_URI = "file://distcc.sh \
7 file://anjuta-remote-run \
8 file://exports \
9 file://shutdown.desktop \
10 file://qemu-autostart"
11
12S = "${WORKDIR}"
13
14COMPATIBLE_MACHINE = "(qemuarm|qemux86)"
15PACKAGE_ARCH = "all"
16
17do_install() {
18 install -d ${D}${sysconfdir}/profile.d
19
20 install -m 0755 distcc.sh ${D}${sysconfdir}/profile.d/
21 install -m 0644 exports ${D}${sysconfdir}/
22
23 install -d ${D}${bindir}
24 install -m 0755 anjuta-remote-run ${D}${bindir}/
25
26 install -d ${D}${datadir}/applications
27 install -m 0644 shutdown.desktop ${D}${datadir}/applications/
28
29 install -d ${D}/etc/init.d
30 install qemu-autostart ${D}/etc/init.d/
31}
32
33inherit update-rc.d
34
35INITSCRIPT_NAME = "qemu-autostart"
36INITSCRIPT_PARAMS = "start 999 5 2 . stop 20 0 1 6 ."
diff --git a/meta/recipes-bsp/qemu-config/qemu-config/anjuta-remote-run b/meta/recipes-bsp/qemu-config/qemu-config/anjuta-remote-run
new file mode 100644
index 0000000000..620e3a705b
--- /dev/null
+++ b/meta/recipes-bsp/qemu-config/qemu-config/anjuta-remote-run
@@ -0,0 +1,7 @@
1#!/bin/sh
2
3. /etc/profile
4export DISPLAY=:0
5dbus-launch $@
6
7
diff --git a/meta/recipes-bsp/qemu-config/qemu-config/distcc.sh b/meta/recipes-bsp/qemu-config/qemu-config/distcc.sh
new file mode 100644
index 0000000000..a2b543d6b8
--- /dev/null
+++ b/meta/recipes-bsp/qemu-config/qemu-config/distcc.sh
@@ -0,0 +1,4 @@
1DISTCC_HOSTS="192.168.7.1"
2#DISTCC_VERBOSE="1"
3
4export DISTCC_HOSTS
diff --git a/meta/recipes-bsp/qemu-config/qemu-config/exports b/meta/recipes-bsp/qemu-config/qemu-config/exports
new file mode 100644
index 0000000000..b7257aa008
--- /dev/null
+++ b/meta/recipes-bsp/qemu-config/qemu-config/exports
@@ -0,0 +1 @@
/ *(rw,no_root_squash,async)
diff --git a/meta/recipes-bsp/qemu-config/qemu-config/qemu-autostart b/meta/recipes-bsp/qemu-config/qemu-config/qemu-autostart
new file mode 100755
index 0000000000..db2668eb4e
--- /dev/null
+++ b/meta/recipes-bsp/qemu-config/qemu-config/qemu-autostart
@@ -0,0 +1,37 @@
1#!/bin/sh
2### BEGIN INIT INFO
3# Provides: hddtemp
4# Required-Start: $network
5# Required-Stop: $network
6# Default-Start: 2 3 4 5
7# Default-Stop: 0 1 6
8# Short-Description: OProfile server
9# Description:
10### END INIT INFO
11
12. /etc/init.d/functions
13
14case "$1" in
15 start)
16 echo "Starting automatic qemu services"
17 . /etc/profile
18 /usr/bin/oprofile-server &
19 ;;
20
21 stop)
22 echo "Stopping qemu services"
23 killproc oprofile-server
24 ;;
25
26 restart)
27 $0 stop
28 sleep 1
29 $0 start
30 ;;
31
32 *)
33 echo "usage: $0 { start | stop | restart }"
34 ;;
35esac
36
37exit 0
diff --git a/meta/recipes-bsp/qemu-config/qemu-config/qemuarm/shutdown.desktop b/meta/recipes-bsp/qemu-config/qemu-config/qemuarm/shutdown.desktop
new file mode 100644
index 0000000000..b973d4318e
--- /dev/null
+++ b/meta/recipes-bsp/qemu-config/qemu-config/qemuarm/shutdown.desktop
@@ -0,0 +1,10 @@
1[Desktop Entry]
2Encoding=UTF-8
3Type=Application
4Name=Shutdown
5Comment=Close down the machine safely
6Exec=reboot
7Icon=system-shutdown
8Terminal=false
9Categories=Utility;
10StartupNotify=true \ No newline at end of file
diff --git a/meta/recipes-bsp/qemu-config/qemu-config/shutdown.desktop b/meta/recipes-bsp/qemu-config/qemu-config/shutdown.desktop
new file mode 100644
index 0000000000..272688922c
--- /dev/null
+++ b/meta/recipes-bsp/qemu-config/qemu-config/shutdown.desktop
@@ -0,0 +1,10 @@
1[Desktop Entry]
2Encoding=UTF-8
3Type=Application
4Name=Shutdown
5Comment=Close down the machine safely
6Exec=halt
7Icon=system-shutdown
8Terminal=false
9Categories=Utility;
10StartupNotify=true \ No newline at end of file