Fix automake program name transformations (#9190)
Automake can perform program name transformations at install time. However, arc_summary has its own name transformation taking place, which interferes with the automake transforms. The automake transforms must be taken into account in order to resolve the conflict. Signed-off-by: Ryan Moeller <ryan@ixsystems.com>
This commit is contained in:
commit
a3ba6e589f
|
@ -1,11 +1,17 @@
|
||||||
EXTRA_DIST = arc_summary2 arc_summary3
|
EXTRA_DIST = arc_summary2 arc_summary3
|
||||||
|
|
||||||
|
transform = $(program_transform_name)
|
||||||
|
|
||||||
if USING_PYTHON_2
|
if USING_PYTHON_2
|
||||||
dist_bin_SCRIPTS = arc_summary2
|
dist_bin_SCRIPTS = arc_summary2
|
||||||
install-exec-hook:
|
install-exec-hook:
|
||||||
mv $(DESTDIR)$(bindir)/arc_summary2 $(DESTDIR)$(bindir)/arc_summary
|
before=$$(echo arc_summary2 | sed '$(transform)'); \
|
||||||
|
after=$$(echo arc_summary | sed '$(transform)'); \
|
||||||
|
mv "$(DESTDIR)$(bindir)/$$before" "$(DESTDIR)$(bindir)/$$after"
|
||||||
else
|
else
|
||||||
dist_bin_SCRIPTS = arc_summary3
|
dist_bin_SCRIPTS = arc_summary3
|
||||||
install-exec-hook:
|
install-exec-hook:
|
||||||
mv $(DESTDIR)$(bindir)/arc_summary3 $(DESTDIR)$(bindir)/arc_summary
|
before=$$(echo arc_summary3 | sed '$(transform)'); \
|
||||||
|
after=$$(echo arc_summary | sed '$(transform)'); \
|
||||||
|
mv "$(DESTDIR)$(bindir)/$$before" "$(DESTDIR)$(bindir)/$$after"
|
||||||
endif
|
endif
|
||||||
|
|
Loading…
Reference in New Issue