summaryrefslogtreecommitdiff
path: root/dev-libs/OpenNI
diff options
context:
space:
mode:
Diffstat (limited to 'dev-libs/OpenNI')
-rw-r--r--dev-libs/OpenNI/Manifest10
-rw-r--r--dev-libs/OpenNI/OpenNI-1.5.7.10.ebuild108
-rw-r--r--dev-libs/OpenNI/OpenNI-9999.ebuild108
-rw-r--r--dev-libs/OpenNI/files/OpenNI-1.5.7.10-gcc6.patch145
-rw-r--r--dev-libs/OpenNI/files/jpeg.patch23
-rw-r--r--dev-libs/OpenNI/files/soname.patch13
-rw-r--r--dev-libs/OpenNI/files/tinyxml.patch29
-rw-r--r--dev-libs/OpenNI/metadata.xml11
8 files changed, 447 insertions, 0 deletions
diff --git a/dev-libs/OpenNI/Manifest b/dev-libs/OpenNI/Manifest
new file mode 100644
index 000000000000..ca55718dfebf
--- /dev/null
+++ b/dev-libs/OpenNI/Manifest
@@ -0,0 +1,10 @@
+AUX OpenNI-1.5.7.10-gcc6.patch 5012 SHA256 b9ae20648097e88d927df2502068412ee38243b766fef349321eb9a6d9ab8ed1 SHA512 129eedc33941df3b3a126528f8d0503c2808930276aa0350c89af42b9b34642eafb8304610443699b839f0158c0412a38bf3a4722af7497534519ecf753e99ac WHIRLPOOL c2fb992035b83753c4b3ba0f65c8d8c7ff3eadc938d1091a514e1a466d7287e65acc9305b0906c7b9767698efb882f3a17d690d6b76e194f0cfac6b1754da9d1
+AUX jpeg.patch 704 SHA256 53d6f27ae283cde53a4af4e0683fc4c59c70076ab4803065591c554dd814cabd SHA512 4276584d5252fd2ce9f7fc7b4389d079276f3626fe140344bd7ba5083f7190455a82aee98742bbf3e8f527947c3128281f63e940c114e85f92be94f71819a117 WHIRLPOOL 3358626df6b6445f588d596b4489459ac5e29e42f8540ed28116657711ee13d16afda45872f4579d814e744f4c86fb07b5a4940be7257990c2a94b673a9c8906
+AUX soname.patch 670 SHA256 b1d2ade0664746b3b2e96bbd842a69f7def8af08282110cd7e09a1f0a66cba1a SHA512 422c90b220b9366320f2513798d00c2d8a17b0db0ccb87150038c2f237d22c7f0d28206e6d00a7c73b758b6b021886a666a8860586f27fe9b57ddb14094ba7f4 WHIRLPOOL 08b54c500f9d282ac33ac6951fd2ce3f48f44fd2d092dae609ce45b368a7a761ba137cf775d488a8be06974b3d65b125055891e7ab5f1deff0db44e954f1c87b
+AUX tinyxml.patch 828 SHA256 33cb114f2d990034c9de47ebb5b716024d117690d45bbc34baaa72403f1660ab SHA512 97cdcbbcd1d4ab4990c7a96ce21c4da983347f73c8064959bbb66d49cc9cda5e293b0273f19d1595ef5b26a6c32267b54cdd45fd4a86b2d8881501a3cea5724a WHIRLPOOL bdfb27cd365cca87797808bfc9fe460ae0cdf275abfe14b845a0127e9205ef76a69c9a71dd46cc404a628697f7ea0c01b7e96db5b1a9aa1e80fe31d4077ef412
+DIST OpenNI-1.5.7.10.tar.gz 23378582 SHA256 34b0bbf68633bb213dcb15408f979d5384bdceb04e151fa519e107a12e225852 SHA512 f7b6106198c4314584cf327744e9d8b193ff9f2e8d416769aafb2aeeda0593ccbb37c3187ed75f1960d2ae8e80e8f30e0fced9ff82e20fe6f24c54246f77d512 WHIRLPOOL 663025a0f388792054e0e628597bce692ddaadf2b51655c6fe1f6ffb74c054e9dd7889feb7652024aad24919701c02813e19d430292079e12f47c677c041c55e
+EBUILD OpenNI-1.5.7.10.ebuild 2493 SHA256 7a8d3533ea14cd84812c917d0fbaa02732bdbf958a3b6374285c2c1b2394adb6 SHA512 7c3a7fae1543ee80ee72f3d783d4089a5dcd572c7650aa393e273f219cabccc167ad2298efc7b8723787862f55ded18a85242ebf6c5c1d1ca3ce02726eadc32e WHIRLPOOL 4b7bb66e4ddfef4be892fd3f86666747be5c09f7310a990989fb0de34df3319b0609a3ea58d7337359e72bfdf8e0fa33d1197091f7b2fb538a466c1c3d7f8c7b
+EBUILD OpenNI-9999.ebuild 2503 SHA256 a900e0f1e3fd28c1ad3284724687729df81696c3d0f72843a9d6a3dde0f819bb SHA512 c668a4786e46f12107a1452225bb9292af2c680ff9f7cadd9cc0bfd93afdbeab56cdadac57f4118bd289cc624c3af28f225cdba095ef5ca6c6e723758501cffd WHIRLPOOL d99bd27351856c35051b016560def6e555e010af9ca84885d7e797bdf6c0d42bd39e3fe0f1016ae5f3cfe7a2bb2b2e1990ffe224aec0705e663c4d5322d51398
+MISC ChangeLog 2291 SHA256 dc33c74f8622b8eecf2cb1565f0e95f23b221cb7a9d0762db0c07ed061d9d8df SHA512 79925698dc5e71e86694056221a40747b9f6552647c947f98e7226f0e0280792255050ffa34605893c199c6b6dcecfb4828a71f4144259a41357cf30e9e068ec WHIRLPOOL 710e91669d9e923f88c94dbac4e3d709594efe1031596c72d25597aacf1be10c6e369adca82f084a5213ec84f20b91d1cc65905cf6b75238ca061cb3f674a35c
+MISC ChangeLog-2015 712 SHA256 1cdb39ea5594b590ead7145590a1bcbfe10c6789c78c472dd90e44c609244a81 SHA512 6795d387aa306d0306a01aa56254a16334a8826a663fe7041f0e2c97c7eddc1ecef9d04625c68ec1f5527fa97fede80408fada80f4076079b9a2b2dcdd73fed5 WHIRLPOOL 59ed0a1a675d4d2e3f9521fd7510be1878f64da4f450dde7cfef666b92cc1d3a9fa755b7e96e7395471fb45643ee5b1a1e6a7160789f414c505253d1b2ceebce
+MISC metadata.xml 337 SHA256 bb09f55187e8f76f17bebf3de26e2acd905283d6e0b998bf9fd285f6fbe37b44 SHA512 31029665f81cf415898ab97a48804b3ddd5efae31f7800348a7b96dfd3a7faf1d4ae3275f039a8397040c6a3c83868252671ce1dcd35b6f1135d221b325ba5b8 WHIRLPOOL cafdd2ea35b8269f0b1dd3c3abe70b08e5608587e1de28fec9183054c305064b2a3a7ae786d26848d3fce59c4af64189f6a79baa6f0cc609ecd7103f88255974
diff --git a/dev-libs/OpenNI/OpenNI-1.5.7.10.ebuild b/dev-libs/OpenNI/OpenNI-1.5.7.10.ebuild
new file mode 100644
index 000000000000..af12cd1ce875
--- /dev/null
+++ b/dev-libs/OpenNI/OpenNI-1.5.7.10.ebuild
@@ -0,0 +1,108 @@
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=5
+
+SCM=""
+if [ "${PV#9999}" != "${PV}" ] ; then
+ SCM="git-r3"
+ EGIT_REPO_URI="https://github.com/OpenNI/OpenNI"
+fi
+
+inherit ${SCM} toolchain-funcs eutils multilib java-pkg-opt-2
+
+if [ "${PV#9999}" != "${PV}" ] ; then
+ KEYWORDS=""
+ SRC_URI=""
+else
+ KEYWORDS="~amd64 ~arm"
+ SRC_URI="https://github.com/OpenNI/OpenNI/archive/Stable-${PV}.tar.gz -> ${P}.tar.gz"
+ S="${WORKDIR}/${PN}-Stable-${PV}"
+fi
+
+DESCRIPTION="OpenNI SDK"
+HOMEPAGE="https://github.com/OpenNI/OpenNI"
+LICENSE="Apache-2.0"
+SLOT="0"
+IUSE="doc java opengl"
+
+RDEPEND="
+ virtual/libusb:1
+ virtual/libudev
+ virtual/jpeg:0
+ dev-libs/tinyxml
+ opengl? ( media-libs/freeglut !dev-libs/OpenNI2[opengl] )
+ java? ( >=virtual/jre-1.5 )
+"
+DEPEND="${RDEPEND}
+ dev-lang/python
+ doc? ( app-doc/doxygen )
+ java? ( >=virtual/jdk-1.5 )"
+
+src_prepare() {
+ epatch \
+ "${FILESDIR}/tinyxml.patch" \
+ "${FILESDIR}/jpeg.patch" \
+ "${FILESDIR}/soname.patch" \
+ "${FILESDIR}/${P}-gcc6.patch"
+
+ rm -rf External/{LibJPEG,TinyXml}
+ for i in Platform/Linux/Build/Common/Platform.* Externals/PSCommon/Linux/Build/Platform.* ; do
+ echo "" > ${i}
+ done
+
+ find . -type f -print0 | xargs -0 sed -i "s:\".*/SamplesConfig.xml:\"${EPREFIX}/usr/share/${PN}/SamplesConfig.xml:" || die
+}
+
+src_compile() {
+ emake -C "${S}/Platform/Linux/Build" \
+ CC="$(tc-getCC)" \
+ CXX="$(tc-getCXX)" \
+ GLUT_SUPPORTED="$(usex opengl 1 0)" \
+ $(usex java "" ALL_JAVA_PROJS="") \
+ $(usex java "" JAVA_SAMPLES="") \
+ ALL_MONO_PROJS="" \
+ MONO_SAMPLES="" \
+ MONO_FORMS_SAMPLES=""
+
+ if use doc ; then
+ cd "${S}/Source/DoxyGen"
+ doxygen || die
+ fi
+}
+
+src_install() {
+ dolib.so "${S}/Platform/Linux/Bin/"*Release/*.so
+
+ insinto /usr/include/openni
+ doins -r Include/*
+
+ dobin "${S}/Platform/Linux/Bin/"*Release/{ni*,Ni*,Sample-*}
+
+ if use java ; then
+ java-pkg_dojar "${S}/Platform/Linux/Bin/"*Release/*.jar
+ echo "java -jar ${JAVA_PKG_JARDEST}/org.openni.Samples.SimpleViewer.jar" > org.openni.Samples.SimpleViewer
+ dobin org.openni.Samples.SimpleViewer
+ fi
+
+ insinto /usr/share/${PN}
+ doins Data/*
+
+ dodoc Documentation/OpenNI_UserGuide.pdf CHANGES NOTICE README
+
+ if use doc ; then
+ dohtml -r "${S}/Source/DoxyGen/html/"*
+ dodoc Source/DoxyGen/Text/*.txt
+ fi
+
+ keepdir /var/lib/ni
+}
+
+pkg_postinst() {
+ if [ "${ROOT:-/}" = "/" ] ; then
+ for i in "${EROOR}/usr/$(get_libdir)"/libnim*.so ; do
+ einfo "Registering module ${i}"
+ niReg -r "${i}"
+ done
+ fi
+}
diff --git a/dev-libs/OpenNI/OpenNI-9999.ebuild b/dev-libs/OpenNI/OpenNI-9999.ebuild
new file mode 100644
index 000000000000..79a0be764ee3
--- /dev/null
+++ b/dev-libs/OpenNI/OpenNI-9999.ebuild
@@ -0,0 +1,108 @@
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=5
+
+SCM=""
+if [ "${PV#9999}" != "${PV}" ] ; then
+ SCM="git-r3"
+ EGIT_REPO_URI="https://github.com/OpenNI/OpenNI"
+fi
+
+inherit ${SCM} toolchain-funcs eutils multilib java-pkg-opt-2
+
+if [ "${PV#9999}" != "${PV}" ] ; then
+ KEYWORDS=""
+ SRC_URI=""
+else
+ KEYWORDS="~amd64 ~arm"
+ SRC_URI="https://github.com/OpenNI/OpenNI/archive/Stable-${PV}.tar.gz -> ${P}.tar.gz"
+ S="${WORKDIR}/${PN}-Stable-${PV}"
+fi
+
+DESCRIPTION="OpenNI SDK"
+HOMEPAGE="https://github.com/OpenNI/OpenNI"
+LICENSE="Apache-2.0"
+SLOT="0"
+IUSE="doc java opengl"
+
+RDEPEND="
+ virtual/libusb:1
+ virtual/libudev
+ virtual/jpeg:0
+ dev-libs/tinyxml
+ opengl? ( media-libs/freeglut !dev-libs/OpenNI2[opengl] )
+ java? ( >=virtual/jre-1.5 )
+"
+DEPEND="${RDEPEND}
+ dev-lang/python
+ doc? ( app-doc/doxygen )
+ java? ( >=virtual/jdk-1.5 )"
+
+src_prepare() {
+ epatch \
+ "${FILESDIR}/tinyxml.patch" \
+ "${FILESDIR}/jpeg.patch" \
+ "${FILESDIR}/soname.patch" \
+ "${FILESDIR}/${PN}-1.5.7.10-gcc6.patch"
+
+ rm -rf External/{LibJPEG,TinyXml}
+ for i in Platform/Linux/Build/Common/Platform.* Externals/PSCommon/Linux/Build/Platform.* ; do
+ echo "" > ${i}
+ done
+
+ find . -type f -print0 | xargs -0 sed -i "s:\".*/SamplesConfig.xml:\"${EPREFIX}/usr/share/${PN}/SamplesConfig.xml:" || die
+}
+
+src_compile() {
+ emake -C "${S}/Platform/Linux/Build" \
+ CC="$(tc-getCC)" \
+ CXX="$(tc-getCXX)" \
+ GLUT_SUPPORTED="$(usex opengl 1 0)" \
+ $(usex java "" ALL_JAVA_PROJS="") \
+ $(usex java "" JAVA_SAMPLES="") \
+ ALL_MONO_PROJS="" \
+ MONO_SAMPLES="" \
+ MONO_FORMS_SAMPLES=""
+
+ if use doc ; then
+ cd "${S}/Source/DoxyGen"
+ doxygen || die
+ fi
+}
+
+src_install() {
+ dolib.so "${S}/Platform/Linux/Bin/"*Release/*.so
+
+ insinto /usr/include/openni
+ doins -r Include/*
+
+ dobin "${S}/Platform/Linux/Bin/"*Release/{ni*,Ni*,Sample-*}
+
+ if use java ; then
+ java-pkg_dojar "${S}/Platform/Linux/Bin/"*Release/*.jar
+ echo "java -jar ${JAVA_PKG_JARDEST}/org.openni.Samples.SimpleViewer.jar" > org.openni.Samples.SimpleViewer
+ dobin org.openni.Samples.SimpleViewer
+ fi
+
+ insinto /usr/share/${PN}
+ doins Data/*
+
+ dodoc Documentation/OpenNI_UserGuide.pdf CHANGES NOTICE README
+
+ if use doc ; then
+ dohtml -r "${S}/Source/DoxyGen/html/"*
+ dodoc Source/DoxyGen/Text/*.txt
+ fi
+
+ keepdir /var/lib/ni
+}
+
+pkg_postinst() {
+ if [ "${ROOT:-/}" = "/" ] ; then
+ for i in "${EROOR}/usr/$(get_libdir)"/libnim*.so ; do
+ einfo "Registering module ${i}"
+ niReg -r "${i}"
+ done
+ fi
+}
diff --git a/dev-libs/OpenNI/files/OpenNI-1.5.7.10-gcc6.patch b/dev-libs/OpenNI/files/OpenNI-1.5.7.10-gcc6.patch
new file mode 100644
index 000000000000..2b93d8c642b9
--- /dev/null
+++ b/dev-libs/OpenNI/files/OpenNI-1.5.7.10-gcc6.patch
@@ -0,0 +1,145 @@
+Bug: https://bugs.gentoo.org/594988
+Upstream PR: https://github.com/OpenNI/OpenNI/pull/122
+
+diff -Naur a/Samples/NiUserSelection/glh/glh_linear.h b/Samples/NiUserSelection/glh/glh_linear.h
+--- a/Samples/NiUserSelection/glh/glh_linear.h 2013-11-12 11:30:03.000000000 -0500
++++ b/Samples/NiUserSelection/glh/glh_linear.h 2017-06-22 18:43:34.470107723 -0400
+@@ -77,7 +77,7 @@
+ #define GLH_EPSILON GLH_REAL(10e-6)
+ #define GLH_PI GLH_REAL(3.1415926535897932384626433832795)
+
+-#define equivalent(a,b) (((a < b + GLH_EPSILON) && (a > b - GLH_EPSILON)) ? true : false)
++#define is_equivalent(a,b) (((a < b + GLH_EPSILON) && (a > b - GLH_EPSILON)) ? true : false)
+
+ namespace glh
+ {
+@@ -1093,7 +1093,7 @@
+
+ real norm = q[0] * q[0] + q[1] * q[1] + q[2] * q[2] + q[3] * q[3];
+
+- s = (equivalent(norm,GLH_ZERO)) ? GLH_ZERO : ( GLH_TWO / norm );
++ s = (is_equivalent(norm,GLH_ZERO)) ? GLH_ZERO : ( GLH_TWO / norm );
+
+ xs = q[0] * s;
+ ys = q[1] * s;
+@@ -1194,7 +1194,7 @@
+ theta *= real(0.5);
+ real sin_theta = real(sin(theta));
+
+- if (!equivalent(sqnorm,GLH_ONE))
++ if (!is_equivalent(sqnorm,GLH_ONE))
+ sin_theta /= real(sqrt(sqnorm));
+ x = sin_theta * axis.v[0];
+ y = sin_theta * axis.v[1];
+@@ -1216,14 +1216,14 @@
+
+ alpha = p1.dot(p2);
+
+- if(equivalent(alpha,GLH_ONE))
++ if(is_equivalent(alpha,GLH_ONE))
+ {
+ *this = identity();
+ return *this;
+ }
+
+ // ensures that the anti-parallel case leads to a positive dot
+- if(equivalent(alpha,-GLH_ONE))
++ if(is_equivalent(alpha,-GLH_ONE))
+ {
+ vec3 v;
+
+@@ -1280,7 +1280,7 @@
+ void normalize()
+ {
+ real rnorm = GLH_ONE / real(sqrt(w * w + x * x + y * y + z * z));
+- if (equivalent(rnorm, GLH_ZERO))
++ if (is_equivalent(rnorm, GLH_ZERO))
+ return;
+ x *= rnorm;
+ y *= rnorm;
+@@ -1439,10 +1439,10 @@
+ inline
+ bool operator == ( const quaternion & q1, const quaternion & q2 )
+ {
+- return (equivalent(q1.x, q2.x) &&
+- equivalent(q1.y, q2.y) &&
+- equivalent(q1.z, q2.z) &&
+- equivalent(q1.w, q2.w) );
++ return (is_equivalent(q1.x, q2.x) &&
++ is_equivalent(q1.y, q2.y) &&
++ is_equivalent(q1.z, q2.z) &&
++ is_equivalent(q1.w, q2.w) );
+ }
+
+ inline
+diff -Naur a/Samples/NiViewer/glh/glh_linear.h b/Samples/NiViewer/glh/glh_linear.h
+--- a/Samples/NiViewer/glh/glh_linear.h 2013-11-12 11:30:03.000000000 -0500
++++ b/Samples/NiViewer/glh/glh_linear.h 2017-06-22 18:43:34.470107723 -0400
+@@ -77,7 +77,7 @@
+ #define GLH_EPSILON GLH_REAL(10e-6)
+ #define GLH_PI GLH_REAL(3.1415926535897932384626433832795)
+
+-#define equivalent(a,b) (((a < b + GLH_EPSILON) && (a > b - GLH_EPSILON)) ? true : false)
++#define is_equivalent(a,b) (((a < b + GLH_EPSILON) && (a > b - GLH_EPSILON)) ? true : false)
+
+ namespace glh
+ {
+@@ -1093,7 +1093,7 @@
+
+ real norm = q[0] * q[0] + q[1] * q[1] + q[2] * q[2] + q[3] * q[3];
+
+- s = (equivalent(norm,GLH_ZERO)) ? GLH_ZERO : ( GLH_TWO / norm );
++ s = (is_equivalent(norm,GLH_ZERO)) ? GLH_ZERO : ( GLH_TWO / norm );
+
+ xs = q[0] * s;
+ ys = q[1] * s;
+@@ -1194,7 +1194,7 @@
+ theta *= real(0.5);
+ real sin_theta = real(sin(theta));
+
+- if (!equivalent(sqnorm,GLH_ONE))
++ if (!is_equivalent(sqnorm,GLH_ONE))
+ sin_theta /= real(sqrt(sqnorm));
+ x = sin_theta * axis.v[0];
+ y = sin_theta * axis.v[1];
+@@ -1216,14 +1216,14 @@
+
+ alpha = p1.dot(p2);
+
+- if(equivalent(alpha,GLH_ONE))
++ if(is_equivalent(alpha,GLH_ONE))
+ {
+ *this = identity();
+ return *this;
+ }
+
+ // ensures that the anti-parallel case leads to a positive dot
+- if(equivalent(alpha,-GLH_ONE))
++ if(is_equivalent(alpha,-GLH_ONE))
+ {
+ vec3 v;
+
+@@ -1280,7 +1280,7 @@
+ void normalize()
+ {
+ real rnorm = GLH_ONE / real(sqrt(w * w + x * x + y * y + z * z));
+- if (equivalent(rnorm, GLH_ZERO))
++ if (is_equivalent(rnorm, GLH_ZERO))
+ return;
+ x *= rnorm;
+ y *= rnorm;
+@@ -1439,10 +1439,10 @@
+ inline
+ bool operator == ( const quaternion & q1, const quaternion & q2 )
+ {
+- return (equivalent(q1.x, q2.x) &&
+- equivalent(q1.y, q2.y) &&
+- equivalent(q1.z, q2.z) &&
+- equivalent(q1.w, q2.w) );
++ return (is_equivalent(q1.x, q2.x) &&
++ is_equivalent(q1.y, q2.y) &&
++ is_equivalent(q1.z, q2.z) &&
++ is_equivalent(q1.w, q2.w) );
+ }
+
+ inline
diff --git a/dev-libs/OpenNI/files/jpeg.patch b/dev-libs/OpenNI/files/jpeg.patch
new file mode 100644
index 000000000000..46f5dfd3d873
--- /dev/null
+++ b/dev-libs/OpenNI/files/jpeg.patch
@@ -0,0 +1,23 @@
+Index: OpenNI-9999/Platform/Linux/Build/Modules/nimCodecs/Makefile
+===================================================================
+--- OpenNI-9999.orig/Platform/Linux/Build/Modules/nimCodecs/Makefile
++++ OpenNI-9999/Platform/Linux/Build/Modules/nimCodecs/Makefile
+@@ -2,15 +2,13 @@ BIN_DIR = ../../../Bin
+
+ INC_DIRS = \
+ ../../../../../Include \
+- ../../../../../Source \
+- ../../../../../Externals/LibJPEG
++ ../../../../../Source
+
+ SRC_FILES = \
+- ../../../../../Source/Modules/nimCodecs/*.cpp \
+- ../../../../../Externals/LibJPEG/*.c
++ ../../../../../Source/Modules/nimCodecs/*.cpp
+
+ LIB_NAME = nimCodecs
+-USED_LIBS = OpenNI
++USED_LIBS = OpenNI jpeg
+
+ include ../../Common/CommonCppMakefile
+
diff --git a/dev-libs/OpenNI/files/soname.patch b/dev-libs/OpenNI/files/soname.patch
new file mode 100644
index 000000000000..b12a1e892e0f
--- /dev/null
+++ b/dev-libs/OpenNI/files/soname.patch
@@ -0,0 +1,13 @@
+Index: OpenNI-9999/Platform/Linux/Build/Common/CommonCppMakefile
+===================================================================
+--- OpenNI-9999.orig/Platform/Linux/Build/Common/CommonCppMakefile
++++ OpenNI-9999/Platform/Linux/Build/Common/CommonCppMakefile
+@@ -78,7 +78,7 @@ ifneq "$(LIB_NAME)" ""
+ ifneq ("$(OSTYPE)","Darwin")
+ LDFLAGS += -Wl,--no-undefined
+ OUTPUT_NAME = lib$(LIB_NAME).so
+- OUTPUT_COMMAND = $(CXX) -o $(OUTPUT_FILE) $(OBJ_FILES) $(LDFLAGS) -shared
++ OUTPUT_COMMAND = $(CXX) -o $(OUTPUT_FILE) $(OBJ_FILES) -Wl,-soname,$(notdir $(OUTPUT_FILE)) $(LDFLAGS) -shared
+ else
+ LDFLAGS += -undefined error
+ OUTPUT_NAME = lib$(LIB_NAME).dylib
diff --git a/dev-libs/OpenNI/files/tinyxml.patch b/dev-libs/OpenNI/files/tinyxml.patch
new file mode 100644
index 000000000000..801cabbd7708
--- /dev/null
+++ b/dev-libs/OpenNI/files/tinyxml.patch
@@ -0,0 +1,29 @@
+Index: OpenNI-9999/Platform/Linux/Build/OpenNI/Makefile
+===================================================================
+--- OpenNI-9999.orig/Platform/Linux/Build/OpenNI/Makefile
++++ OpenNI-9999/Platform/Linux/Build/OpenNI/Makefile
+@@ -4,13 +4,11 @@ BIN_DIR = ../../Bin
+
+ INC_DIRS = \
+ ../../../../Include \
+- ../../../../Source \
+- ../../../../Externals/TinyXml
++ ../../../../Source
+
+ SRC_FILES = \
+ ../../../../Source/OpenNI/*.cpp \
+- ../../../../Source/OpenNI/Linux/*.cpp \
+- ../../../../Externals/TinyXml/*.cpp
++ ../../../../Source/OpenNI/Linux/*.cpp
+
+ ifeq ("$(OSTYPE)","Darwin")
+ INC_DIRS += /opt/local/include
+@@ -19,7 +17,7 @@ ifeq ("$(OSTYPE)","Darwin")
+ endif
+
+ LIB_NAME = OpenNI
+-USED_LIBS = usb-1.0 dl pthread
++USED_LIBS = usb-1.0 dl pthread tinyxml
+ ifneq ("$(OSTYPE)","Darwin")
+ USED_LIBS += rt
+ endif
diff --git a/dev-libs/OpenNI/metadata.xml b/dev-libs/OpenNI/metadata.xml
new file mode 100644
index 000000000000..201349bea285
--- /dev/null
+++ b/dev-libs/OpenNI/metadata.xml
@@ -0,0 +1,11 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <maintainer type="person">
+ <email>aballier@gentoo.org</email>
+ <name>Alexis Ballier</name>
+ </maintainer>
+ <upstream>
+ <remote-id type="github">OpenNI/OpenNI</remote-id>
+ </upstream>
+</pkgmetadata>