diff options
author | Sam James <sam@gentoo.org> | 2022-01-28 04:30:14 +0000 |
---|---|---|
committer | Sam James <sam@gentoo.org> | 2022-01-28 05:16:29 +0000 |
commit | 3e3c7d01664a47ae626abb734747ce1f98e1c2dd (patch) | |
tree | 08ac82bebda38b0c8fca9dc52a65e1db9723f7e8 /app-forensics | |
parent | dev-python/yara-python: new ebuild (diff) | |
download | gentoo-3e3c7d01664a47ae626abb734747ce1f98e1c2dd.tar.gz gentoo-3e3c7d01664a47ae626abb734747ce1f98e1c2dd.tar.bz2 gentoo-3e3c7d01664a47ae626abb734747ce1f98e1c2dd.zip |
app-forensics/yara: run tests; misc. other changes
- Run tests (needs static linked lib for now, but we delete it anyway)
- Use more generic dependency
- Define subslot
Closes: https://bugs.gentoo.org/576956
See: https://github.com/gentoo/gentoo/pull/23800
Signed-off-by: Sam James <sam@gentoo.org>
Diffstat (limited to 'app-forensics')
-rw-r--r-- | app-forensics/yara/yara-4.1.3.ebuild | 26 | ||||
-rw-r--r-- | app-forensics/yara/yara-4.2.0_rc1.ebuild | 33 |
2 files changed, 44 insertions, 15 deletions
diff --git a/app-forensics/yara/yara-4.1.3.ebuild b/app-forensics/yara/yara-4.1.3.ebuild index 0e064fd15d7b..e11e07efff40 100644 --- a/app-forensics/yara/yara-4.1.3.ebuild +++ b/app-forensics/yara/yara-4.1.3.ebuild @@ -10,17 +10,18 @@ HOMEPAGE="http://virustotal.github.io/yara/" SRC_URI="https://github.com/virustotal/yara/archive/v${PV}.tar.gz -> ${P}.tar.gz" LICENSE="Apache-2.0" -SLOT="0" +SLOT="0/8" KEYWORDS="~amd64 ~x86" -IUSE="+dex +dotnet +cuckoo +macho +magic profiling python" +IUSE="+dex +dotnet +cuckoo +macho +magic profiling python test" +RESTRICT="!test? ( test )" DEPEND=" - dev-libs/openssl:0= + dev-libs/openssl:= cuckoo? ( dev-libs/jansson:= ) - magic? ( sys-apps/file:0= ) + magic? ( sys-apps/file:= ) " RDEPEND="${DEPEND}" -PDEPEND="python? ( =dev-python/yara-python-4* )" +PDEPEND="python? ( =dev-python/yara-python-$(ver_cut 1)* )" src_prepare() { default @@ -34,5 +35,18 @@ src_configure() { $(use_enable magic) \ $(use_enable dotnet) \ $(use_enable macho) \ - $(use_enable dex) + $(use_enable dex) \ + $(use_enable test static) +} + +src_test() { + emake check +} + +src_install() { + default + + # TODO: Allow tests to work against dyn. lib rather than building + # statically just for tests. + find "${ED}" -name '*.a' -delete || die } diff --git a/app-forensics/yara/yara-4.2.0_rc1.ebuild b/app-forensics/yara/yara-4.2.0_rc1.ebuild index a514ff8e4690..8bac51561719 100644 --- a/app-forensics/yara/yara-4.2.0_rc1.ebuild +++ b/app-forensics/yara/yara-4.2.0_rc1.ebuild @@ -8,21 +8,23 @@ inherit autotools DESCRIPTION="A malware identification and classification tool" HOMEPAGE="http://virustotal.github.io/yara/" SRC_URI="https://github.com/virustotal/yara/archive/v${PV/_/-}.tar.gz -> ${P}.tar.gz" +S="${WORKDIR}/${PN}-${PV/_/-}" LICENSE="Apache-2.0" -SLOT="0" -KEYWORDS="" -IUSE="+dex +dotnet +cuckoo +macho +magic profiling python" +SLOT="0/8" +if [[ ${PV} != *_rc* ]] ; then + KEYWORDS="~amd64 ~x86" +fi +IUSE="+dex +dotnet +cuckoo +macho +magic profiling python test" +RESTRICT="!test? ( test )" DEPEND=" - dev-libs/openssl:0= + dev-libs/openssl:= cuckoo? ( dev-libs/jansson:= ) - magic? ( sys-apps/file:0= ) + magic? ( sys-apps/file:= ) " RDEPEND="${DEPEND}" -PDEPEND="python? ( =dev-python/yara-python-4* )" - -S="${WORKDIR}/${PN}-${PV/_/-}" +PDEPEND="python? ( =dev-python/yara-python-$(ver_cut 1)* )" src_prepare() { default @@ -36,5 +38,18 @@ src_configure() { $(use_enable magic) \ $(use_enable dotnet) \ $(use_enable macho) \ - $(use_enable dex) + $(use_enable dex) \ + $(use_enable test static) +} + +src_test() { + emake check +} + +src_install() { + default + + # TODO: Allow tests to work against dyn. lib rather than building + # statically just for tests. + find "${ED}" -name '*.a' -delete || die } |