diff options
author | V3n3RiX <venerix@redcorelinux.org> | 2019-09-14 18:52:15 +0100 |
---|---|---|
committer | V3n3RiX <venerix@redcorelinux.org> | 2019-09-14 18:52:15 +0100 |
commit | d00821e77f72d4af4ea30158c1c6e18ffff0875b (patch) | |
tree | b28b6cb077ae6b2457e30d49028fc978d8e2b59b /media-libs/glm/glm-0.9.9.6.ebuild | |
parent | 36ac65103bf5503e5bad1ecc7e8cb9e7643f6840 (diff) | |
parent | 6a339b4f9ec107438bb71a6f9ca72fd42fbfd436 (diff) |
Merge branch 'next'
Diffstat (limited to 'media-libs/glm/glm-0.9.9.6.ebuild')
-rw-r--r-- | media-libs/glm/glm-0.9.9.6.ebuild | 48 |
1 files changed, 48 insertions, 0 deletions
diff --git a/media-libs/glm/glm-0.9.9.6.ebuild b/media-libs/glm/glm-0.9.9.6.ebuild new file mode 100644 index 000000000000..7049a117fce1 --- /dev/null +++ b/media-libs/glm/glm-0.9.9.6.ebuild @@ -0,0 +1,48 @@ +# Copyright 1999-2019 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +inherit cmake-utils + +DESCRIPTION="OpenGL Mathematics" +HOMEPAGE="http://glm.g-truc.net/" +SRC_URI="https://github.com/g-truc/glm/archive/${PV}.tar.gz -> ${P}.tar.gz" + +LICENSE="|| ( HappyBunny MIT )" +SLOT="0" +KEYWORDS="~amd64 ~arm ~arm64 ~ppc64 ~x86" +IUSE="test cpu_flags_x86_sse2 cpu_flags_x86_sse3 cpu_flags_x86_avx cpu_flags_x86_avx2" + +RDEPEND="virtual/opengl" + +PATCHES=( "${FILESDIR}"/${P}-simd.patch ) + +src_prepare() { + cmake-utils_src_prepare + sed \ + -e "s:@CMAKE_INSTALL_PREFIX@:${EPREFIX}/usr:" \ + -e "s:@GLM_VERSION@:0.9.9:" \ + "${FILESDIR}"/glm.pc.in > glm.pc || die +} + +src_configure() { + if use test; then + local mycmakeargs=( + -DGLM_TEST_ENABLE=ON + -DGLM_TEST_ENABLE_SIMD_SSE2="$(usex cpu_flags_x86_sse2 ON OFF)" + -DGLM_TEST_ENABLE_SIMD_SSE3="$(usex cpu_flags_x86_sse3 ON OFF)" + -DGLM_TEST_ENABLE_SIMD_AVX="$(usex cpu_flags_x86_avx ON OFF)" + -DGLM_TEST_ENABLE_SIMD_AVX2="$(usex cpu_flags_x86_avx2 ON OFF)" + ) + fi + + cmake-utils_src_configure +} + +src_install() { + doheader -r glm + dodoc -r *md doc/* + insinto /usr/$(get_libdir)/pkgconfig + doins glm.pc +} |