scratcbox-compat.bbclass: New bbclass.
authorRobert Schuster <thebohemian@gmx.net>
Wed, 27 Aug 2008 15:37:07 +0000 (15:37 +0000)
committerRobert Schuster <thebohemian@gmx.net>
Wed, 27 Aug 2008 15:37:07 +0000 (15:37 +0000)
classes/scratchbox-compat.bbclass [new file with mode: 0644]

diff --git a/classes/scratchbox-compat.bbclass b/classes/scratchbox-compat.bbclass
new file mode 100644 (file)
index 0000000..6cf92bd
--- /dev/null
@@ -0,0 +1,13 @@
+# By adding this class to your build all binaries get the special rpath
+# "/scratchbox/host_shared/lib/:/scratchbox/tools/lib/"
+# Doing so makes libraries and programs runnable inside the Scratchbox
+# environment as native binaries (not for the CPU that Scratchbox is
+# emulating).
+
+do_configure_prepend () {
+  export LD_RUN_PATH="/scratchbox/host_shared/lib:/scratchbox/tools/lib"
+}
+
+do_compile_prepend () {
+  export LD_RUN_PATH="/scratchbox/host_shared/lib:/scratchbox/tools/lib"
+}