diff options
author | Bernd Waibel <waebbl-gentoo@posteo.net> | 2023-03-24 18:58:20 +0100 |
---|---|---|
committer | Joonas Niilola <juippis@gentoo.org> | 2023-04-06 09:54:22 +0300 |
commit | a834e3baa2c0cad3d1f954866687d79b18682b28 (patch) | |
tree | 6565c14714b62806f1c3daae292b16902d22347b /media-gfx | |
parent | dev-ml/ocamlgraph: drop 1.8.8-r2 (diff) | |
download | gentoo-a834e3baa2c0cad3d1f954866687d79b18682b28.tar.gz gentoo-a834e3baa2c0cad3d1f954866687d79b18682b28.tar.bz2 gentoo-a834e3baa2c0cad3d1f954866687d79b18682b28.zip |
media-gfx/openscad: allow experimental features
add experimental USE flag to enable newer features
update ebuild to reflect upstream changes
Thanks to Michael Moon for pointing this out.
Suggested-by: Michael Moon <triffid.hunter@gmail.com>
Closes: https://bugs.gentoo.org/899658
Signed-off-by: Bernd Waibel <waebbl-gentoo@posteo.net>
Closes: https://github.com/gentoo/gentoo/pull/30334
Signed-off-by: Joonas Niilola <juippis@gentoo.org>
Diffstat (limited to 'media-gfx')
-rw-r--r-- | media-gfx/openscad/metadata.xml | 16 | ||||
-rw-r--r-- | media-gfx/openscad/openscad-9999.ebuild | 55 |
2 files changed, 43 insertions, 28 deletions
diff --git a/media-gfx/openscad/metadata.xml b/media-gfx/openscad/metadata.xml index 817a36f21ccf..0b965cbf4ac8 100644 --- a/media-gfx/openscad/metadata.xml +++ b/media-gfx/openscad/metadata.xml @@ -21,11 +21,23 @@ Mac OS X. </longdescription> <use> + <flag name="egl"> + Build using EGL instead of GLX + </flag> + <flag name="experimental"> + Enable experimental features + </flag> <flag name="gamepad"> Add support for gamepads through <pkg>dev-qt/qtgamepad</pkg> </flag> - <flag name="headless"> - Build a binary without GUI + <flag name="gui"> + Enable or disable building of the GUI + </flag> + <flag name="hidapi"> + Build in support for HID-Class devices using <pkg>dev-libs/hidapi</pkg> + </flag> + <flag name="mimalloc"> + Build using <pkg>dev-libs/mimalloc</pkg> as memory allocator </flag> <flag name="spacenav"> Add support for space navigator devices through diff --git a/media-gfx/openscad/openscad-9999.ebuild b/media-gfx/openscad/openscad-9999.ebuild index 425d55c09f81..94342d5766f0 100644 --- a/media-gfx/openscad/openscad-9999.ebuild +++ b/media-gfx/openscad/openscad-9999.ebuild @@ -1,11 +1,15 @@ -# Copyright 1999-2022 Gentoo Authors +# Copyright 1999-2023 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 -EAPI=8 +# TODO's +# package and unbundle manifold +# package Emacs scad-mode (and scad-dbus) and re-add emacs USE flag +# set up proper testing +# set up OFFLINE_DOCS and add doc USE flag -inherit cmake elisp-common git-r3 xdg +EAPI=8 -SITEFILE="50${PN}-gentoo.el" +inherit cmake git-r3 xdg DESCRIPTION="The Programmers Solid 3D CAD Modeller" HOMEPAGE="https://www.openscad.org/" @@ -16,11 +20,14 @@ EGIT_REPO_URI="https://github.com/openscad/openscad.git" LICENSE="GPL-3+ LGPL-2.1" SLOT="0" KEYWORDS="" -IUSE="cairo dbus emacs gamepad headless spacenav" +# TODO: emacs mode files have been moved to a separate repo: github://openscad/emacs-scad-mode +IUSE="cairo dbus egl experimental gamepad gui hidapi mimalloc spacenav" RESTRICT="test" # 32 out 1300+ tests fail REQUIRED_USE=" - headless? ( !dbus !gamepad !spacenav ) + dbus? ( gui ) + gamepad? ( gui ) + spacenav? ( gui ) " RDEPEND=" @@ -39,8 +46,7 @@ RDEPEND=" sci-mathematics/cgal:= virtual/opengl cairo? ( x11-libs/cairo ) - emacs? ( app-editors/emacs:* ) - !headless? ( + gui? ( dev-qt/qtconcurrent:5 dev-qt/qtcore:5 dev-qt/qtgui:5[-gles2-only] @@ -49,10 +55,13 @@ RDEPEND=" dev-qt/qtopengl:5 dev-qt/qtsvg:5 dev-qt/qtwidgets:5 + x11-libs/libX11 x11-libs/qscintilla:= dbus? ( dev-qt/qtdbus:5 ) gamepad? ( dev-qt/qtgamepad:5 ) ) + hidapi? ( dev-libs/hidapi ) + mimalloc? ( dev-libs/mimalloc:= ) spacenav? ( dev-libs/libspnav ) " DEPEND="${RDEPEND}" @@ -65,24 +74,33 @@ BDEPEND=" " DOCS=( + README.md RELEASE_NOTES.md doc/TODO.txt doc/contributor_copyright.txt doc/hacking.md doc/testing.txt + doc/translation.txt ) src_configure() { local mycmakeargs=( -DCLANG_TIDY=OFF -DENABLE_CAIRO=$(usex cairo) + -DENABLE_EGL=$(usex egl) + -DENABLE_HIDAPI=$(usex hidapi) + # needs python deps, unbundle first before enabling + -DENABLE_MANIFOLD=OFF -DENABLE_SPNAV=$(usex spacenav) -DENABLE_TESTS=OFF - -DHEADLESS=$(usex headless) + -DEXPERIMENTAL=$(usex experimental) + -DHEADLESS=$(usex gui OFF ON) + -DOFFLINE_DOCS=OFF -DUSE_CCACHE=OFF + -DUSE_MIMALLOC=$(usex mimalloc) ) - if use !headless; then + if use gui; then mycmakeargs+=( -DENABLE_GAMEPAD=$(usex gamepad) -DENABLE_QTDBUS=$(usex dbus) @@ -92,36 +110,21 @@ src_configure() { cmake_src_configure } -src_compile() { - cmake_src_compile - - if use emacs ; then - elisp-compile contrib/*.el - fi -} - src_install() { DOCS+=( doc/*.pdf ) cmake_src_install mv -i "${ED}"/usr/share/openscad/locale "${ED}"/usr/share || die "failed to move locales" - ln -sf ../locale "${ED}"/usr/share/openscad/locale || die - - if use emacs; then - elisp-site-file-install "${FILESDIR}/${SITEFILE}" - elisp-install ${PN} contrib/*.el contrib/*.elc - fi + dosym -r /usr/share/locale /usr/share/openscad/locale } pkg_postinst() { - use emacs && elisp-site-regen xdg_desktop_database_update xdg_icon_cache_update xdg_mimeinfo_database_update } pkg_postrm() { - use emacs && elisp-site-regen xdg_desktop_database_update xdg_icon_cache_update xdg_mimeinfo_database_update |