mirror of
https://github.com/ibm-s390-linux/s390-tools.git
synced 2026-08-05 02:14:52 +00:00
The dracut installation directory is referenced from `chreipl-fcp-mpath`, `zdev`, and `zipl`; in each with its own individual definition and variable name. This makes it unnecessarily hard to change it when installing from the top level directory of s390-tools and passing variable overwrites via the command line. Fix this by defining a common `DRACUTDIR` variable in the shared `common.mak` file, and referencing this in each tool as base directory. With this a user can simply pass `DRACUTDIR=/foo/bar/baz` on the commandline and change the installation for all three tools. Further, also derive common `DRACUTCONFDIR` and `DRACUTMODDIR` variables from `DRACUTDIR` in `common.mak`, so that `zdev` and `zipl` don't use different variable names for the same directory anymore, and all these are defined together in a common place. Semantically nothing changes for a default build/installation. Signed-off-by: Benjamin Block <bblock@linux.ibm.com> Reviewed-by: Peter Oberparleiter <oberpar@linux.ibm.com> Signed-off-by: Jan Höppner <hoeppner@linux.ibm.com>
30 lines
1002 B
Makefile
30 lines
1002 B
Makefile
|
|
include ../../common.mak
|
|
|
|
NGDUMPDIR := 99ngdump
|
|
|
|
# HAVE_DRACUT
|
|
#
|
|
# This install time parameter determines whether the ngdump dracut module is
|
|
# installed (HAVE_DRACUT=1) or not (default). When installed, the module
|
|
# performs the following functions when dracut is run:
|
|
#
|
|
# - install the systemd service that initiates the dump at boot
|
|
# - install the dump script that is run by the new systemd service at boot
|
|
#
|
|
ifeq ($(HAVE_DRACUT),1)
|
|
install:
|
|
$(INSTALL) -m 755 zipl_helper.prepare-ngdump \
|
|
$(DESTDIR)$(TOOLS_LIBDIR)
|
|
$(INSTALL) -m 755 -d $(DESTDIR)$(DRACUTMODDIR)/
|
|
$(INSTALL) -m 755 -d $(DESTDIR)$(DRACUTMODDIR)/$(NGDUMPDIR)
|
|
$(INSTALL) -m 755 $(NGDUMPDIR)/module-setup.sh \
|
|
$(DESTDIR)$(DRACUTMODDIR)/$(NGDUMPDIR)/
|
|
$(INSTALL) -m 644 $(NGDUMPDIR)/ngdump.service \
|
|
$(DESTDIR)$(DRACUTMODDIR)/$(NGDUMPDIR)/
|
|
$(INSTALL) -m 755 $(NGDUMPDIR)/ngdump.sh \
|
|
$(DESTDIR)$(DRACUTMODDIR)/$(NGDUMPDIR)/
|
|
$(INSTALL) -m 755 $(NGDUMPDIR)/ngdump-reipl.sh \
|
|
$(DESTDIR)$(DRACUTMODDIR)/$(NGDUMPDIR)/
|
|
endif
|