From baa9f37987615c0cd8858524a6504f9f7f9b7e34 Mon Sep 17 00:00:00 2001 From: Sam James Date: Wed, 24 Nov 2021 00:13:29 +0000 Subject: sci-electronics/kicad: fix tests Closes: https://bugs.gentoo.org/826966 Signed-off-by: Sam James --- sci-electronics/kicad/kicad-6.0.0_rc1.ebuild | 15 ++++++++------- sci-electronics/kicad/kicad-9999.ebuild | 15 ++++++++------- 2 files changed, 16 insertions(+), 14 deletions(-) (limited to 'sci-electronics') diff --git a/sci-electronics/kicad/kicad-6.0.0_rc1.ebuild b/sci-electronics/kicad/kicad-6.0.0_rc1.ebuild index 20f40d536dc9..5286a402f8bc 100644 --- a/sci-electronics/kicad/kicad-6.0.0_rc1.ebuild +++ b/sci-electronics/kicad/kicad-6.0.0_rc1.ebuild @@ -128,6 +128,14 @@ src_compile() { fi } +src_test() { + # Test cannot find library in Portage's sandbox. Let's create a link so test can run. + ln -s "${BUILD_DIR}/eeschema/_eeschema.kiface" "${BUILD_DIR}/qa/eeschema/_eeschema.kiface" || die + + # LD_LIBRARY_PATH is there to help it pick up the just-built libraries + LD_LIBRARY_PATH="${BUILD_DIR}/3d-viewer/3d_cache/sg:${LD_LIBRARY_PATH}" cmake_src_test +} + src_install() { cmake_src_install use python && python_optimize @@ -138,13 +146,6 @@ src_install() { fi } -src_test() { - # Test cannot find library in Portage's sandbox. Let's create a link so test can run. - ln -s "${S}_build/eeschema/_eeschema.kiface" "${S}_build/qa/eeschema/_eeschema.kiface" || die - - default -} - pkg_postinst() { optfeature "Component symbols library" sci-electronics/kicad-symbols optfeature "Component footprints library" sci-electronics/kicad-footprints diff --git a/sci-electronics/kicad/kicad-9999.ebuild b/sci-electronics/kicad/kicad-9999.ebuild index 20f40d536dc9..5286a402f8bc 100644 --- a/sci-electronics/kicad/kicad-9999.ebuild +++ b/sci-electronics/kicad/kicad-9999.ebuild @@ -128,6 +128,14 @@ src_compile() { fi } +src_test() { + # Test cannot find library in Portage's sandbox. Let's create a link so test can run. + ln -s "${BUILD_DIR}/eeschema/_eeschema.kiface" "${BUILD_DIR}/qa/eeschema/_eeschema.kiface" || die + + # LD_LIBRARY_PATH is there to help it pick up the just-built libraries + LD_LIBRARY_PATH="${BUILD_DIR}/3d-viewer/3d_cache/sg:${LD_LIBRARY_PATH}" cmake_src_test +} + src_install() { cmake_src_install use python && python_optimize @@ -138,13 +146,6 @@ src_install() { fi } -src_test() { - # Test cannot find library in Portage's sandbox. Let's create a link so test can run. - ln -s "${S}_build/eeschema/_eeschema.kiface" "${S}_build/qa/eeschema/_eeschema.kiface" || die - - default -} - pkg_postinst() { optfeature "Component symbols library" sci-electronics/kicad-symbols optfeature "Component footprints library" sci-electronics/kicad-footprints -- cgit v1.2.3-65-gdbad