lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <20180820132320.31688-1-lczerner@redhat.com>
Date:   Mon, 20 Aug 2018 15:23:20 +0200
From:   Lukas Czerner <lczerner@...hat.com>
To:     linux-ext4@...r.kernel.org
Subject: [PATCH] scrub: fix Makefile to respect PREFIX

Currently Makefile in scrub will not take PREFIX into consideration
when initializing paths to udev rules, crond configuration and systemd
unit files. Fix it by adding $(root_prefix).

Also MKINSTALLDIRS variable does not exist in scrub/Makefile for
creating the directories. Use MKDIR_P instead.

Signed-off-by: Lukas Czerner <lczerner@...hat.com>
---
 MCONFIG.in        |  6 +++---
 scrub/Makefile.in | 20 ++++++++++----------
 2 files changed, 13 insertions(+), 13 deletions(-)

diff --git a/MCONFIG.in b/MCONFIG.in
index 7ca86ac6..508f2a9e 100644
--- a/MCONFIG.in
+++ b/MCONFIG.in
@@ -35,11 +35,11 @@ pkgconfigdir = $(libdir)/pkgconfig
 pkglibdir = $(libdir)/e2fsprogs
 
 HAVE_UDEV = @have_udev@
-UDEV_RULES_DIR = @pkg_udev_rules_dir@
+UDEV_RULES_DIR = $(root_prefix)@pkg_udev_rules_dir@
 HAVE_CROND = @have_crond@
-CROND_DIR = @crond_dir@
+CROND_DIR = $(root_prefix)@crond_dir@
 HAVE_SYSTEMD = @have_systemd@
-SYSTEMD_SYSTEM_UNIT_DIR = @systemd_system_unit_dir@
+SYSTEMD_SYSTEM_UNIT_DIR = $(root_prefix)@systemd_system_unit_dir@
 
 @SET_MAKE@
 
diff --git a/scrub/Makefile.in b/scrub/Makefile.in
index f58331de..fc8cbcfd 100644
--- a/scrub/Makefile.in
+++ b/scrub/Makefile.in
@@ -85,24 +85,24 @@ e2scrub_all_cron: e2scrub_all_cron.in
 	$(Q) $(SUBSTITUTE_UPTIME) $< $@
 
 installdirs-udev:
-	$(E) "	MKINSTALLDIRS $(UDEV_RULES_DIR)"
-	$(Q) $(MKINSTALLDIRS) $(DESTDIR)$(UDEV_RULES_DIR)
+	$(E) "	$(MKDIR_P) $(DESTDIR)$(UDEV_RULES_DIR)"
+	$(Q) $(MKDIR_P) $(DESTDIR)$(UDEV_RULES_DIR)
 
 installdirs-crond:
-	$(E) "	MKINSTALLDIRS $(CROND_DIR)"
-	$(Q) $(MKINSTALLDIRS) $(DESTDIR)$(CROND_DIR)
+	$(E) "	$(MKDIR_P) $(CROND_DIR)"
+	$(Q) $(MKDIR_P) $(DESTDIR)$(CROND_DIR)
 
 installdirs-libprogs:
-	$(E) "	MKINSTALLDIRS $(pkglibdir)"
-	$(Q) $(MKINSTALLDIRS) $(DESTDIR)$(pkglibdir)
+	$(E) "	$(MKDIR_P) $(pkglibdir)"
+	$(Q) $(MKDIR_P) $(DESTDIR)$(pkglibdir)
 
 installdirs-systemd:
-	$(E) "	MKINSTALLDIRS $(SYSTEMD_SYSTEM_UNIT_DIR)"
-	$(Q) $(MKINSTALLDIRS) $(DESTDIR)$(SYSTEMD_SYSTEM_UNIT_DIR)
+	$(E) "	$(MKDIR_P) $(SYSTEMD_SYSTEM_UNIT_DIR)"
+	$(Q) $(MKDIR_P) $(DESTDIR)$(SYSTEMD_SYSTEM_UNIT_DIR)
 
 installdirs: $(INSTALLDIRS_TGT)
-	$(E) "	MKINSTALLDIRS $(root_sbindir) $(man8dir) $(root_sysconfdir)"
-	$(Q) $(MKINSTALLDIRS) $(DESTDIR)$(root_sbindir) \
+	$(E) "	$(MKDIR_P) $(root_sbindir) $(man8dir) $(root_sysconfdir)"
+	$(Q) $(MKDIR_P) $(DESTDIR)$(root_sbindir) \
 		$(DESTDIR)$(man8dir) $(DESTDIR)$(root_sysconfdir)
 
 install-udev:
-- 
2.17.1

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ