[oe-commits] : libxml2-native all silence duplicated function warning by refactoring into .inc

OE GIT Trial gittrial at amethyst.openembedded.net
Fri Sep 26 18:52:10 UTC 2008


Module: OE.dev
Branch: org.openembedded.dev
Commit: 27e7dac84470c3d4d9f4030c762eea56099f9057
URL:    http://gitweb.openembedded.net//OE.dev.git/?a=commit;h=27e7dac84470c3d4d9f4030c762eea56099f9057

Author:  <mickeyl at openembedded.org>
Date:   Fri Sep 26 18:41:12 2008 +0000

libxml2-native all silence duplicated function warning by refactoring into .inc

---

 packages/libxml/libxml2-native.inc       |   24 ++++++++++++++++++++++++
 packages/libxml/libxml2-native_2.6.29.bb |   24 +-----------------------
 packages/libxml/libxml2-native_2.6.32.bb |   24 +-----------------------
 3 files changed, 26 insertions(+), 46 deletions(-)

diff --git a/packages/libxml/libxml2-native.inc b/packages/libxml/libxml2-native.inc
new file mode 100644
index 0000000..5672792
--- /dev/null
+++ b/packages/libxml/libxml2-native.inc
@@ -0,0 +1,24 @@
+DESCRIPTION = "GNOME XML library"
+DEPENDS = "python-native"
+FILESDIR = "${@os.path.dirname(bb.data.getVar('FILE',d,1))}/libxml2-${PV}"
+PR = "r3"
+
+SRC_URI = "ftp://xmlsoft.org/libxml2/libxml2-${PV}.tar.gz"
+S = "${WORKDIR}/libxml2-${PV}"
+
+inherit autotools native pkgconfig
+
+def libxml2_native_python_dir(d):
+        import os, bb
+        staging_incdir = bb.data.getVar( "STAGING_INCDIR", d, 1 )
+        if os.path.exists( "%s/python2.5" % staging_incdir ): return "python2.5"
+        if os.path.exists( "%s/python2.4" % staging_incdir ): return "python2.4"
+        if os.path.exists( "%s/python2.3" % staging_incdir ): return "python2.3"
+        raise "No Python in STAGING_INCDIR. Forgot to build python-native ?"
+
+EXTRA_OECONF = "--with-python=${STAGING_INCDIR}/${@libxml2_native_python_dir(d)} \
+                --without-debug --without-legacy --without-catalog --without-docbook --with-c14n"
+
+do_stage () {
+	oe_runmake install
+}
diff --git a/packages/libxml/libxml2-native_2.6.29.bb b/packages/libxml/libxml2-native_2.6.29.bb
index 5672792..f82c4e0 100644
--- a/packages/libxml/libxml2-native_2.6.29.bb
+++ b/packages/libxml/libxml2-native_2.6.29.bb
@@ -1,24 +1,2 @@
-DESCRIPTION = "GNOME XML library"
-DEPENDS = "python-native"
-FILESDIR = "${@os.path.dirname(bb.data.getVar('FILE',d,1))}/libxml2-${PV}"
+require libxml2-native.inc
 PR = "r3"
-
-SRC_URI = "ftp://xmlsoft.org/libxml2/libxml2-${PV}.tar.gz"
-S = "${WORKDIR}/libxml2-${PV}"
-
-inherit autotools native pkgconfig
-
-def libxml2_native_python_dir(d):
-        import os, bb
-        staging_incdir = bb.data.getVar( "STAGING_INCDIR", d, 1 )
-        if os.path.exists( "%s/python2.5" % staging_incdir ): return "python2.5"
-        if os.path.exists( "%s/python2.4" % staging_incdir ): return "python2.4"
-        if os.path.exists( "%s/python2.3" % staging_incdir ): return "python2.3"
-        raise "No Python in STAGING_INCDIR. Forgot to build python-native ?"
-
-EXTRA_OECONF = "--with-python=${STAGING_INCDIR}/${@libxml2_native_python_dir(d)} \
-                --without-debug --without-legacy --without-catalog --without-docbook --with-c14n"
-
-do_stage () {
-	oe_runmake install
-}
diff --git a/packages/libxml/libxml2-native_2.6.32.bb b/packages/libxml/libxml2-native_2.6.32.bb
index 914a301..48e3598 100644
--- a/packages/libxml/libxml2-native_2.6.32.bb
+++ b/packages/libxml/libxml2-native_2.6.32.bb
@@ -1,24 +1,2 @@
-DESCRIPTION = "GNOME XML library"
-DEPENDS = "python-native"
-FILESDIR = "${@os.path.dirname(bb.data.getVar('FILE',d,1))}/libxml2-${PV}"
+require libxml2-native.inc
 PR = "r0"
-
-SRC_URI = "ftp://xmlsoft.org/libxml2/libxml2-${PV}.tar.gz"
-S = "${WORKDIR}/libxml2-${PV}"
-
-inherit autotools native pkgconfig
-
-def libxml2_native_python_dir(d):
-        import os, bb
-        staging_incdir = bb.data.getVar( "STAGING_INCDIR", d, 1 )
-        if os.path.exists( "%s/python2.5" % staging_incdir ): return "python2.5"
-        if os.path.exists( "%s/python2.4" % staging_incdir ): return "python2.4"
-        if os.path.exists( "%s/python2.3" % staging_incdir ): return "python2.3"
-        raise "No Python in STAGING_INCDIR. Forgot to build python-native ?"
-
-EXTRA_OECONF = "--with-python=${STAGING_INCDIR}/${@libxml2_native_python_dir(d)} \
-                --without-debug --without-legacy --without-catalog --without-docbook --with-c14n"
-
-do_stage () {
-	oe_runmake install
-}





More information about the Openembedded-commits mailing list