gobject-introspection: Use /usr/bin/env for python
authorTom Rini <tom_rini@mentor.com>
Wed, 17 Nov 2010 23:15:38 +0000 (16:15 -0700)
committerTom Rini <tom_rini@mentor.com>
Wed, 17 Nov 2010 23:17:32 +0000 (16:17 -0700)
Scripts that do #!@PERL@ or #!@PYTHON@ and replace that with
a full path are in danger of breaking in certain environments
(such as some autobuilders) and should instead use /usr/bin/env.
While in here, use GNOME_MIRROR for the sources.

Signed-off-by: Tom Rini <tom_rini@mentor.com>
recipes/gobject-introspection/gobject-introspection/use-usr-bin-env-for-python.patch [new file with mode: 0644]
recipes/gobject-introspection/gobject-introspection_0.9.10.bb

diff --git a/recipes/gobject-introspection/gobject-introspection/use-usr-bin-env-for-python.patch b/recipes/gobject-introspection/gobject-introspection/use-usr-bin-env-for-python.patch
new file mode 100644 (file)
index 0000000..67b8547
--- /dev/null
@@ -0,0 +1,20 @@
+Index: gobject-introspection-0.9.10/tools/g-ir-annotation-tool.in
+===================================================================
+--- gobject-introspection-0.9.10.orig/tools/g-ir-annotation-tool.in
++++ gobject-introspection-0.9.10/tools/g-ir-annotation-tool.in
+@@ -1,4 +1,4 @@
+-#!@PYTHON@
++#!/usr/bin/env python
+ # -*- Mode: Python -*-
+ # GObject-Introspection - a framework for introspecting GObject libraries
+ # Copyright (C) 2008  Johan Dahlin
+Index: gobject-introspection-0.9.10/tools/g-ir-scanner.in
+===================================================================
+--- gobject-introspection-0.9.10.orig/tools/g-ir-scanner.in
++++ gobject-introspection-0.9.10/tools/g-ir-scanner.in
+@@ -1,4 +1,4 @@
+-#!@PYTHON@
++#!/usr/bin/env python
+ # -*- Mode: Python -*-
+ # GObject-Introspection - a framework for introspecting GObject libraries
+ # Copyright (C) 2008  Johan Dahlin
index b982ce9..72836d5 100644 (file)
@@ -4,12 +4,14 @@ DEPENDS = "glib-2.0 libffi"
 BBCLASSEXTEND = "native"
 DEPENDS_virtclass-native = "glib-2.0-native libffi-native"
 LICENSE = "LGPL"
+PR = "r1"
 
 SRC_URI[md5sum] = "e5cd63d6bcc5c105e898e7c33cf42175"
 SRC_URI[sha256sum] = "4bf244db75df04499dea704e7734376c0fc5a3a17fb59be2123c8d76111e6fb8"
 
 SRC_URI = "\
-  http://ftp.acc.umu.se/pub/GNOME/sources/gobject-introspection/0.9/${BPN}-${PV}.tar.bz2 \
+  ${GNOME_MIRROR}/gobject-introspection/0.9/${BPN}-${PV}.tar.bz2 \
+  file://use-usr-bin-env-for-python.patch \
 "
 S = "${WORKDIR}/${BPN}-${PV}"