diff options
author | V3n3RiX <venerix@redcorelinux.org> | 2017-10-09 18:53:29 +0100 |
---|---|---|
committer | V3n3RiX <venerix@redcorelinux.org> | 2017-10-09 18:53:29 +0100 |
commit | 4f2d7949f03e1c198bc888f2d05f421d35c57e21 (patch) | |
tree | ba5f07bf3f9d22d82e54a462313f5d244036c768 /dev-libs/OpenNI2 |
reinit the tree, so we can have metadata
Diffstat (limited to 'dev-libs/OpenNI2')
-rw-r--r-- | dev-libs/OpenNI2/Manifest | 12 | ||||
-rw-r--r-- | dev-libs/OpenNI2/OpenNI2-2.2_beta2.ebuild | 100 | ||||
-rw-r--r-- | dev-libs/OpenNI2/OpenNI2-9999.ebuild | 98 | ||||
-rw-r--r-- | dev-libs/OpenNI2/files/c++14.patch | 145 | ||||
-rw-r--r-- | dev-libs/OpenNI2/files/jpeg.patch | 90 | ||||
-rw-r--r-- | dev-libs/OpenNI2/files/libopenni2.pc.in | 10 | ||||
-rw-r--r-- | dev-libs/OpenNI2/files/pthread.patch | 26 | ||||
-rw-r--r-- | dev-libs/OpenNI2/files/rpath.patch | 13 | ||||
-rw-r--r-- | dev-libs/OpenNI2/files/soname.patch | 13 | ||||
-rw-r--r-- | dev-libs/OpenNI2/metadata.xml | 11 |
10 files changed, 518 insertions, 0 deletions
diff --git a/dev-libs/OpenNI2/Manifest b/dev-libs/OpenNI2/Manifest new file mode 100644 index 000000000000..26bf18f38039 --- /dev/null +++ b/dev-libs/OpenNI2/Manifest @@ -0,0 +1,12 @@ +AUX c++14.patch 4647 SHA256 0c439b55ad2686dd33b77616b069bcdf0b5d6d065b507ac81332881ba5dcc11a SHA512 528aa9640dc5fa0e502da02dac8a49dbed1761b149f44705e709c2d9109981dea2c42f4f9a16ab00bb040205fda3a0fdb696b8b797e4ac08655f5d940900b22a WHIRLPOOL 39192f29ee8491b1f2be141763d62673dd3f4afe2376e38d2db114ca0771c7a6dcae4c1bcc28709ffaa55562aa24e11d4d7050368408cca741ad0a3f524f9bb5 +AUX jpeg.patch 2579 SHA256 09ff186c3f9ca99f4e9cd4e0bc87e8291b0e7e0fd3cedcbeab8a304f345bcb07 SHA512 caf822ff7781acee8b676a0d786ab3cd72dfaf83bcd4b53247d6b83aaace2649c430f9f88c4f79d59fe53f049fb884c178b4e1877d9442f7c8d8fce5c0729b70 WHIRLPOOL 1c48bca8600ea1d3191db45ce1f0ff72e7e28c301419cb4457f3424c16b9f4af9e320311f7f421be110ec58d79ac05000319b7227207d2784e26d5047a1c37dd +AUX libopenni2.pc.in 311 SHA256 2e46e2aa0d26a52867753ff3a583349271dc61527ed74fe56bdff755ecb720e5 SHA512 5532f380b1a69862bf55f1db3f775913e31d2969dc0b824d205637925d9787441c07beb8fcedb8a727b908bf98b5408caaa58f85f2da3b36b864fa1d4d37568a WHIRLPOOL 4ba1d2d55959f629f7b9475c673c3c29b51c8fbac791fe73f71ab572dc20e5368504509032a0a0381154f4d86c9d8db182fb47b4017ed354ab06ec53ded2ddab +AUX pthread.patch 977 SHA256 cbfde950035ec0f2963ed64762612cb50c69bec302f7d92027ccff5fe49c3e62 SHA512 d2f91c57e262399e454aac99bec8b8a054e80a60329c89eee9498ab5344b3711485d13502861fe96d452f9ba2693cab3c93726ded56cd278448cd4cf1d43fb14 WHIRLPOOL 26a9b1c884a59c470c6b93a93196e321a5c38b809cb4cc7cd1d6d9043c2eb781296f55655c70ce393d5cd66f3a72ac5d5fb8a4f5c6f5d9454cf009baa873abaf +AUX rpath.patch 569 SHA256 e2c9558c6b3d535376ed22a9d418e0d38f6d9a65797f287c1498e8bda7e97e98 SHA512 86adda790d6814b0339ff969e262b78282c977ff4dc16268d4e7831e1086886aefee5c37c5bae9e97b7caf3e9f22e922f87e429e586fafc8e5503b4f99ef4adc WHIRLPOOL 2219f319122cdddb4e537541080809e75bd9c57b713b77cf707329e4bd7aeec5ff9a29ccddb4631c15af74bfe965369704684f2f229124f98429c86f1e0f9019 +AUX soname.patch 674 SHA256 74c2cb1f2d8eed1c891a6cca7543f3aa13a52232b7313ef3ad3528f996b56253 SHA512 fec4ab17efd29e1fc05a880584aa63559d311a248ef6def36af9c7c652f93aa0ba77f600115f0e4093b7c5c0b446955a4d36d9663196882f5c460a26d99498be WHIRLPOOL 2efab9503cdd831788d8eb47361f6f2ce237a7911dd3bb659b43b68694c5137d2a98ec57d25208d2c7b9c6587070e7db606db811e681f3ad52a88782b597d0e9 +DIST OpenNI2-2.2_beta2.tar.gz 8681740 SHA256 28302633ddfbcba5fc1ea82737e783fe031714ef49fbbee78ee4309171b7c5f7 SHA512 60a3a3043679f3069aea869e92dc5881328ce4393d4140ea8d089027321ac501ae27d283657214e2834d216d0d49bf4f29a4b3d3e43df27a6ed21f889cd0083f WHIRLPOOL f166b70b921b17a32c417baf084d1caec05dd5456429e16b3dbe6bef8f1bfa099aeb6f8856d167355ccc1d768b00143ac5a085a36cb1464d7d828bdae1c81001 +EBUILD OpenNI2-2.2_beta2.ebuild 2499 SHA256 0058cb4841cdb731d6dba30539ec095fe30b45e2425b03152864cc2961e67aad SHA512 5707c58d8e03eabc28b992edc4de00ec5d25dfd13482ac7cbfa3c90d9333c503315f4963de63cec260874e5c333b363c3bbdd25990e958f8a42ae51677bc3c46 WHIRLPOOL b40571f939c39a700bcd004e142958009d6babf95f2f3a53190fff82fbffe5a85ed1dcd54a2e5c007c3616974a3e94b2f1e1628c52be01f140f764dbd35b328e +EBUILD OpenNI2-9999.ebuild 2440 SHA256 b9f356421dde88c022d3d6ca6977a9cbd2e262542ecd54c08bd5962450834b21 SHA512 81b2e21a7a7eeba981203ac950ece70956036daaf6bdbabb83b89b9c04ff10d1d3484843e856f8337c6f8bd57752414d6f2300b9ef41da1f066477b7ac8c096c WHIRLPOOL ad4d8b65433a25e75cb15a2d41191bcffb9c3012d7ec0d6fbf8b68e96fab718c6a27056bacda7056ce314bb1cb35820897d8159786913905052a3f984e533e4b +MISC ChangeLog 2345 SHA256 accb6e27bfe5e961b31d62d06fc7b877119a8de41b99c44c518674228756ec66 SHA512 51a2f22653a44c084df93828d85911d333b9d3d175c6e675bb73dadad266f07d293f5279e640c55abb116565cd2a763d70713a73a2813f7f4af4b0d97ee16303 WHIRLPOOL 2f6c6ceafe4b971550dc95e5135dab20b2f531e01fdcb44aa6bc5c96cf5f4b74e07b1bbdf51dfbf0b7e91f208b5a966818370296555229e4c83519bfd7b74305 +MISC ChangeLog-2015 627 SHA256 af9ad78e8bcc2208ab2d3c0b54e20706fab2e43837601310d52e3f9d13611b48 SHA512 d2955766f2b9007f6bb07ff94ff76460e573cf3393da06c2621b567ed6e6967f01b5f77ecd908abb5bcb9fa0f189ffe63cc47ea487dce638fc6ce81660d2feac WHIRLPOOL d0ac7ec5d3f7753747e19493dde212b5a00ff4dd6e1ea5298036387d8f5eef5c58802fd14eb07e7c7782b91a2aab8c4235fa33bd18ce0ee483fd43b2440cec21 +MISC metadata.xml 341 SHA256 1dcb30ec3fdada566d7878a3ac7133d95f13a0d33296a7450793bcd60839cfff SHA512 414b64e60046dc1628494ab50ae5f4c5594b9fe71daf7cdc844428200e6122bc471e27f982fa4eaaed6db6f93fb53312118a35dd52e01c576e8597f3e21b23c8 WHIRLPOOL bc615205d9ecf6ae88301ec2e26c7f67e97b982a299ffd5f3a812ae44b3941795251ba51a28702441902f287134e01bb826c3a63b254fd96068d83fd357e7e8b diff --git a/dev-libs/OpenNI2/OpenNI2-2.2_beta2.ebuild b/dev-libs/OpenNI2/OpenNI2-2.2_beta2.ebuild new file mode 100644 index 000000000000..218a3a477fa7 --- /dev/null +++ b/dev-libs/OpenNI2/OpenNI2-2.2_beta2.ebuild @@ -0,0 +1,100 @@ +# 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/occipital/openni2" +fi + +inherit ${SCM} toolchain-funcs eutils multilib java-pkg-opt-2 flag-o-matic + +if [ "${PV#9999}" != "${PV}" ] ; then + KEYWORDS="" + SRC_URI="" +else + KEYWORDS="~amd64 ~arm" + SRC_URI="https://github.com/occipital/OpenNI2/archive/${PV/_/-}.tar.gz -> ${P}.tar.gz" + S="${WORKDIR}/${P/_/-}" +fi + +DESCRIPTION="OpenNI2 SDK" +HOMEPAGE="http://structure.io/openni" +LICENSE="Apache-2.0" +SLOT="0" +IUSE="doc java neon opengl static-libs" + +RDEPEND=" + virtual/libusb:1 + virtual/libudev + virtual/jpeg:0 + opengl? ( media-libs/freeglut ) + java? ( >=virtual/jre-1.5:* ) +" +DEPEND="${RDEPEND} + dev-lang/python + doc? ( app-doc/doxygen ) + java? ( >=virtual/jdk-1.5:* )" + +src_prepare() { + epatch \ + "${FILESDIR}/jpeg.patch" \ + "${FILESDIR}/rpath.patch" \ + "${FILESDIR}/soname.patch" \ + "${FILESDIR}/pthread.patch" \ + "${FILESDIR}/c++14.patch" + + rm -rf ThirdParty/LibJPEG + for i in ThirdParty/PSCommon/BuildSystem/Platform.* ; do + echo "" > ${i} + done +} + +src_compile() { + use neon && export CFLAGS="${CFLAGS} -DXN_NEON" + emake \ + CC="$(tc-getCC)" \ + CXX="$(tc-getCXX)" \ + ALLOW_WARNINGS=1 \ + GLUT_SUPPORTED="$(usex opengl 1 0)" \ + $(usex java "" ALL_WRAPPERS="") \ + $(usex java "" JAVA_SAMPLES="") + + if use doc ; then + cd "${S}/Source/Documentation" + doxygen || die + fi +} + +src_install() { + dolib.so "${S}/Bin/"*Release/*.so + cp -a "${S}/Bin/"*Release/OpenNI2 "${ED}/usr/$(get_libdir)" + + use static-libs && dolib.a "${S}/Bin/"*Release/*.a + + insinto /usr/include/openni2 + doins -r Include/* + + dobin "${S}/Bin/"*Release/{PS1080Console,PSLinkConsole,SimpleRead,EventBasedRead,MultipleStreamRead,MWClosestPointApp} + use opengl && dobin "${S}/Bin/"*Release/{NiViewer,SimpleViewer,MultiDepthViewer,ClosestPointViewer} + + if use java ; then + java-pkg_dojar "${S}/Bin/"*Release/*.jar + echo "java -jar ${JAVA_PKG_JARDEST}/org.openni.Samples.SimpleViewer.jar" > org.openni.Samples.SimpleViewer + dobin org.openni.Samples.SimpleViewer + fi + + dodoc CHANGES.txt NOTICE README ReleaseNotes.txt Source/Documentation/Text/*.txt + + if use doc ; then + dohtml -r "${S}/Source/Documentation/html/"* + fi + + dodir /usr/$(get_libdir)/pkgconfig + sed \ + -e "s/@libdir@/$(get_libdir)/" \ + -e "s/@version@/${PV}/" \ + "${FILESDIR}/libopenni2.pc.in" > "${ED}/usr/$(get_libdir)/pkgconfig/libopenni2.pc" || die +} diff --git a/dev-libs/OpenNI2/OpenNI2-9999.ebuild b/dev-libs/OpenNI2/OpenNI2-9999.ebuild new file mode 100644 index 000000000000..ced4cfb2c9ef --- /dev/null +++ b/dev-libs/OpenNI2/OpenNI2-9999.ebuild @@ -0,0 +1,98 @@ +# 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/occipital/openni2" +fi + +inherit ${SCM} toolchain-funcs eutils multilib java-pkg-opt-2 flag-o-matic + +if [ "${PV#9999}" != "${PV}" ] ; then + KEYWORDS="" + SRC_URI="" +else + KEYWORDS="~amd64 ~arm" + SRC_URI="https://github.com/occipital/OpenNI2/archive/${PV/_/-}.tar.gz -> ${P}.tar.gz" + S="${WORKDIR}/${P/_/-}" +fi + +DESCRIPTION="OpenNI2 SDK" +HOMEPAGE="http://structure.io/openni" +LICENSE="Apache-2.0" +SLOT="0" +IUSE="doc java neon opengl static-libs" + +RDEPEND=" + virtual/libusb:1 + virtual/libudev + virtual/jpeg:0 + opengl? ( media-libs/freeglut ) + java? ( >=virtual/jre-1.5:* ) +" +DEPEND="${RDEPEND} + dev-lang/python + doc? ( app-doc/doxygen ) + java? ( >=virtual/jdk-1.5:* )" + +src_prepare() { + epatch \ + "${FILESDIR}/jpeg.patch" \ + "${FILESDIR}/rpath.patch" \ + "${FILESDIR}/soname.patch" + + rm -rf ThirdParty/LibJPEG + for i in ThirdParty/PSCommon/BuildSystem/Platform.* ; do + echo "" > ${i} + done +} + +src_compile() { + use neon && export CFLAGS="${CFLAGS} -DXN_NEON" + emake \ + CC="$(tc-getCC)" \ + CXX="$(tc-getCXX)" \ + ALLOW_WARNINGS=1 \ + GLUT_SUPPORTED="$(usex opengl 1 0)" \ + $(usex java "" ALL_WRAPPERS="") \ + $(usex java "" JAVA_SAMPLES="") + + if use doc ; then + cd "${S}/Source/Documentation" + doxygen || die + fi +} + +src_install() { + dolib.so "${S}/Bin/"*Release/*.so + cp -a "${S}/Bin/"*Release/OpenNI2 "${ED}/usr/$(get_libdir)" + + use static-libs && dolib.a "${S}/Bin/"*Release/*.a + + insinto /usr/include/openni2 + doins -r Include/* + + dobin "${S}/Bin/"*Release/{PS1080Console,PSLinkConsole,SimpleRead,EventBasedRead,MultipleStreamRead,MWClosestPointApp} + use opengl && dobin "${S}/Bin/"*Release/{NiViewer,SimpleViewer,MultiDepthViewer,ClosestPointViewer} + + if use java ; then + java-pkg_dojar "${S}/Bin/"*Release/*.jar + echo "java -jar ${JAVA_PKG_JARDEST}/org.openni.Samples.SimpleViewer.jar" > org.openni.Samples.SimpleViewer + dobin org.openni.Samples.SimpleViewer + fi + + dodoc CHANGES.txt NOTICE README.md ReleaseNotes.txt Source/Documentation/Text/*.txt + + if use doc ; then + dohtml -r "${S}/Source/Documentation/html/"* + fi + + dodir /usr/$(get_libdir)/pkgconfig + sed \ + -e "s/@libdir@/$(get_libdir)/" \ + -e "s/@version@/${PV}/" \ + "${FILESDIR}/libopenni2.pc.in" > "${ED}/usr/$(get_libdir)/pkgconfig/libopenni2.pc" || die +} diff --git a/dev-libs/OpenNI2/files/c++14.patch b/dev-libs/OpenNI2/files/c++14.patch new file mode 100644 index 000000000000..95343a60059a --- /dev/null +++ b/dev-libs/OpenNI2/files/c++14.patch @@ -0,0 +1,145 @@ +The 'equivalent' macro clashes with equivalent() member functions of the +std::error_category::equivalent class in C++11 and above. +See also: +https://bugs.gentoo.org/show_bug.cgi?id=594910 + +--- a/ThirdParty/GL/glh/glh_linear.h ++++ b/ThirdParty/GL/glh/glh_linear.h +@@ -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 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 = (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 (!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(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(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 (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 (equivalent_(q1.x, q2.x) && ++ equivalent_(q1.y, q2.y) && ++ equivalent_(q1.z, q2.z) && ++ equivalent_(q1.w, q2.w) ); + } + + inline +--- a/ThirdParty/PSCommon/XnLib/ThirdParty/GL/glh/glh_linear.h ++++ b/ThirdParty/PSCommon/XnLib/ThirdParty/GL/glh/glh_linear.h +@@ -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 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 = (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 (!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(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(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 (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 (equivalent_(q1.x, q2.x) && ++ equivalent_(q1.y, q2.y) && ++ equivalent_(q1.z, q2.z) && ++ equivalent_(q1.w, q2.w) ); + } + + inline diff --git a/dev-libs/OpenNI2/files/jpeg.patch b/dev-libs/OpenNI2/files/jpeg.patch new file mode 100644 index 000000000000..e7f4f35ea7dd --- /dev/null +++ b/dev-libs/OpenNI2/files/jpeg.patch @@ -0,0 +1,90 @@ +Index: OpenNI2-9999/Source/Core/Makefile +=================================================================== +--- OpenNI2-9999.orig/Source/Core/Makefile ++++ OpenNI2-9999/Source/Core/Makefile +@@ -5,14 +5,12 @@ BIN_DIR = ../../Bin + INC_DIRS = \ + ../../Include \ + ../../ThirdParty/PSCommon/XnLib/Include \ +- ../Drivers/OniFile/Formats \ +- ../../ThirdParty/LibJPEG ++ ../Drivers/OniFile/Formats + + SRC_FILES = \ + *.cpp \ + ../Drivers/OniFile/Formats/XnCodec.cpp \ +- ../Drivers/OniFile/Formats/XnStreamCompression.cpp \ +- ../../ThirdParty/LibJPEG/*.c \ ++ ../Drivers/OniFile/Formats/XnStreamCompression.cpp + + ifeq ("$(OSTYPE)","Darwin") + INC_DIRS += /opt/local/include +@@ -23,7 +21,7 @@ endif + LIB_NAME = OpenNI2 + + LIB_DIRS = ../../ThirdParty/PSCommon/XnLib/Bin/$(PLATFORM)-$(CFG) +-USED_LIBS = XnLib dl pthread ++USED_LIBS = XnLib jpeg dl pthread + ifneq ("$(OSTYPE)","Darwin") + USED_LIBS += rt + endif +Index: OpenNI2-9999/Source/Drivers/OniFile/Makefile +=================================================================== +--- OpenNI2-9999.orig/Source/Drivers/OniFile/Makefile ++++ OpenNI2-9999/Source/Drivers/OniFile/Makefile +@@ -6,14 +6,12 @@ INC_DIRS = \ + . \ + ../../../Include \ + ../../../ThirdParty/PSCommon/XnLib/Include \ +- ../../../ThirdParty/LibJPEG \ + Formats + + SRC_FILES = \ + *.cpp \ + Formats/*.cpp \ +- XnLibExtensions/*.cpp \ +- ../../../ThirdParty/LibJPEG/*.c ++ XnLibExtensions/*.cpp + + + ifeq ("$(OSTYPE)","Darwin") +@@ -25,7 +23,7 @@ endif + LIB_NAME = OniFile + + LIB_DIRS = ../../../ThirdParty/PSCommon/XnLib/Bin/$(PLATFORM)-$(CFG) +-USED_LIBS = XnLib pthread ++USED_LIBS = XnLib jpeg pthread + ifneq ("$(OSTYPE)","Darwin") + USED_LIBS += rt + endif +Index: OpenNI2-9999/Source/Drivers/PS1080/Makefile +=================================================================== +--- OpenNI2-9999.orig/Source/Drivers/PS1080/Makefile ++++ OpenNI2-9999/Source/Drivers/PS1080/Makefile +@@ -7,7 +7,6 @@ INC_DIRS = \ + Include \ + ../../../Include \ + ../../../ThirdParty/PSCommon/XnLib/Include \ +- ../../../ThirdParty/LibJPEG \ + ../../DepthUtils + + SRC_FILES = \ +@@ -16,8 +15,7 @@ SRC_FILES = \ + DriverImpl/*.cpp\ + Formats/*.cpp \ + Include/*.cpp \ +- Sensor/*.cpp \ +- ../../../ThirdParty/LibJPEG/*.c ++ Sensor/*.cpp + + + ifeq ("$(OSTYPE)","Darwin") +@@ -30,7 +28,7 @@ LIB_NAME = PS1080 + + LIB_DIRS += ../../../ThirdParty/PSCommon/XnLib/Bin/$(PLATFORM)-$(CFG) + LIB_DIRS += $(BIN_DIR)/$(PLATFORM)-$(CFG) +-USED_LIBS = XnLib dl pthread DepthUtils ++USED_LIBS = XnLib jpeg dl pthread DepthUtils + ifneq ("$(OSTYPE)","Darwin") + USED_LIBS += rt usb-1.0 udev + else diff --git a/dev-libs/OpenNI2/files/libopenni2.pc.in b/dev-libs/OpenNI2/files/libopenni2.pc.in new file mode 100644 index 000000000000..550b13df60df --- /dev/null +++ b/dev-libs/OpenNI2/files/libopenni2.pc.in @@ -0,0 +1,10 @@ +prefix=/usr +exec_prefix=${prefix} +libdir=${exec_prefix}/@libdir@ +includedir=${prefix}/include/openni2 + +Name: OpenNI2 +Description: A general purpose driver for all OpenNI cameras. +Version: @version@ +Cflags: -I${includedir} +Libs: -L${libdir} -lOpenNI2 -L${libdir}/OpenNI2/Drivers -lDummyDevice -lOniFile -lPS1080 diff --git a/dev-libs/OpenNI2/files/pthread.patch b/dev-libs/OpenNI2/files/pthread.patch new file mode 100644 index 000000000000..62d8a0c86789 --- /dev/null +++ b/dev-libs/OpenNI2/files/pthread.patch @@ -0,0 +1,26 @@ +commit 716cffb2888bb2a0fa3264a22085caf8ce26368f +Author: Pedro Asad <pasad@cos.ufrj.br> +Date: Wed Oct 8 18:18:57 2014 -0300 + + Added a missing -lpthread flag to one Makefile + + The lack of the -lpthread flag on Source/Tools/NiViewer/Makefile prevented the + whole project from compiling correctly on Ubuntu 14.04 64 bit. Just added the + missing flag to this Makefile, according to the same solution for issue 47 of + the old OpenNI2 Github repository, that boils down to a similar problem and + can be found here, on Github + https://github.com/OpenNI/OpenNI2/issues/47 + +diff --git a/Source/Tools/NiViewer/Makefile b/Source/Tools/NiViewer/Makefile +index 1eba049..1b5714d 100644 +--- a/Source/Tools/NiViewer/Makefile ++++ b/Source/Tools/NiViewer/Makefile +@@ -26,7 +26,7 @@ else + endif + + LIB_DIRS += ../../../ThirdParty/PSCommon/XnLib/Bin/$(PLATFORM)-$(CFG) +-USED_LIBS += OpenNI2 XnLib ++USED_LIBS += OpenNI2 XnLib pthread + + EXE_NAME = NiViewer + diff --git a/dev-libs/OpenNI2/files/rpath.patch b/dev-libs/OpenNI2/files/rpath.patch new file mode 100644 index 000000000000..9203733ee80e --- /dev/null +++ b/dev-libs/OpenNI2/files/rpath.patch @@ -0,0 +1,13 @@ +Index: OpenNI2-9999/ThirdParty/PSCommon/BuildSystem/CommonCppMakefile +=================================================================== +--- OpenNI2-9999.orig/ThirdParty/PSCommon/BuildSystem/CommonCppMakefile ++++ OpenNI2-9999/ThirdParty/PSCommon/BuildSystem/CommonCppMakefile +@@ -93,8 +93,6 @@ ifneq "$(LIB_NAME)" "" + endif + ifneq "$(EXE_NAME)" "" + OUTPUT_NAME = $(EXE_NAME) +- # We want the executables to look for the .so's locally first: +- LDFLAGS += -Wl,-rpath ./ + OUTPUT_COMMAND = $(CXX) -o $(OUTPUT_FILE) $(OBJ_FILES) $(LDFLAGS) + endif + ifneq "$(SLIB_NAME)" "" diff --git a/dev-libs/OpenNI2/files/soname.patch b/dev-libs/OpenNI2/files/soname.patch new file mode 100644 index 000000000000..248ac631af58 --- /dev/null +++ b/dev-libs/OpenNI2/files/soname.patch @@ -0,0 +1,13 @@ +Index: OpenNI2-9999/ThirdParty/PSCommon/BuildSystem/CommonCppMakefile +=================================================================== +--- OpenNI2-9999.orig/ThirdParty/PSCommon/BuildSystem/CommonCppMakefile ++++ OpenNI2-9999/ThirdParty/PSCommon/BuildSystem/CommonCppMakefile +@@ -84,7 +84,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,$(OUTPUT_NAME) $(LDFLAGS) -shared + else + LDFLAGS += -undefined error + OUTPUT_NAME = lib$(LIB_NAME).dylib diff --git a/dev-libs/OpenNI2/metadata.xml b/dev-libs/OpenNI2/metadata.xml new file mode 100644 index 000000000000..561873a856c0 --- /dev/null +++ b/dev-libs/OpenNI2/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">occipital/OpenNI2</remote-id> + </upstream> +</pkgmetadata> |