mirror of
https://github.com/gentoo-mirror/gentoo.git
synced 2026-11-09 06:37:10 -08:00
sys-block/thin-provisioning-tools: don't use emake to install binary
For USE=debug to work, portage needs to run cargo_src_compile(), but if `emake` is used in src_install(), it will trigger a rebuild without debug. If cargo_src_install() is used instead, manpages and symlinks won't be installed and the binary would have to be moved since there's no way to make cargo install to /usr/sbin. So remove $(PDATA_TOOLS) dependency in Makefile instead. Might as well patch out $(STRIP) too. Signed-off-by: Peter Levine <plevine457@gmail.com> Signed-off-by: Sam James <sam@gentoo.org>
This commit is contained in:
+21
@@ -0,0 +1,21 @@
|
||||
For USE=debug to work, portage needs to run cargo_src_compile(), but if `emake`
|
||||
is used in src_install(), it will trigger a rebuild without debug. If
|
||||
cargo_src_install() is used instead, manpages and symlinks won't be installed
|
||||
and the binary would have to be moved since there's no way to make cargo install
|
||||
to /usr/sbin. So remove $(PDATA_TOOLS) dependency in Makefile instead. Might as
|
||||
well patch out $(STRIP) too.
|
||||
|
||||
--- a/Makefile
|
||||
+++ b/Makefile
|
||||
@@ -56,10 +56,9 @@
|
||||
|
||||
MANPAGES:=$(patsubst %,man8/%.8,$(TOOLS))
|
||||
|
||||
-install: $(PDATA_TOOLS) $(MANPAGES)
|
||||
+install: $(MANPAGES)
|
||||
$(INSTALL_DIR) $(BINDIR)
|
||||
$(INSTALL_PROGRAM) $(PDATA_TOOLS) $(BINDIR)
|
||||
- $(STRIP) $(BINDIR)/pdata_tools
|
||||
ln -s -f pdata_tools $(BINDIR)/cache_check
|
||||
ln -s -f pdata_tools $(BINDIR)/cache_dump
|
||||
ln -s -f pdata_tools $(BINDIR)/cache_metadata_size
|
||||
@@ -153,6 +153,8 @@ LICENSE="Apache-2.0 BSD GPL-3 MIT Unicode-DFS-2016"
|
||||
SLOT="0"
|
||||
IUSE="io-uring"
|
||||
|
||||
PATCHES=( "${FILESDIR}/${PN}-1.0.6-build-with-cargo.patch" )
|
||||
|
||||
# Rust
|
||||
QA_FLAGS_IGNORED="usr/sbin/pdata_tools"
|
||||
|
||||
@@ -171,5 +173,9 @@ src_configure() {
|
||||
}
|
||||
|
||||
src_install() {
|
||||
emake V= DESTDIR="${D}" DATADIR="${ED}/usr/share" STRIP=true install
|
||||
emake \
|
||||
DESTDIR="${D}" \
|
||||
DATADIR="${ED}/usr/share" \
|
||||
PDATA_TOOLS="target/$(usex debug debug release)/pdata_tools" \
|
||||
install
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user