0002-Add-PREFIX-to-host-paths.patch 2.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354
  1. From a221304344b3f9db7e86d928cf97d77542bcf456 Mon Sep 17 00:00:00 2001
  2. From: Adam Duskett <aduskett@gmail.com>
  3. Date: Mon, 9 Oct 2017 16:47:19 -0400
  4. Subject: [PATCH] Add PREFIX to host paths
  5. Updates the remaining hardcoded host paths used in the build to be
  6. prefixed with a PREFIX path to allow cross compilation.
  7. Updated to work with version 3.2
  8. Signed-off-by: Clayton Shotwell <clayton.shotwell@rockwellcollins.com>
  9. Signed-off-by: Niranjan Reddy <niranjan.reddy@rockwellcollins.com>
  10. Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
  11. [Update for 2.8]
  12. Signed-off-by: Adam Duskett <aduskett@gmail.com>
  13. [Update for 3.2]
  14. ---
  15. newrole/Makefile | 4 ++--
  16. run_init/Makefile | 4 ++--
  17. 2 files changed, 4 insertions(+), 4 deletions(-)
  18. diff --git a/newrole/Makefile b/newrole/Makefile
  19. index 0e7ebce..3188cec 100644
  20. --- a/newrole/Makefile
  21. +++ b/newrole/Makefile
  22. @@ -4,8 +4,8 @@ PREFIX ?= /usr
  23. BINDIR ?= $(PREFIX)/bin
  24. MANDIR ?= $(PREFIX)/share/man
  25. ETCDIR ?= /etc
  26. -LOCALEDIR = $(DESTDIR)$(PREFIX)/share/locale
  27. -INCLUDEDIR ?= $(PREFIX)/include
  28. +LOCALEDIR = $(DESTDIR)$(PREFIX)
  29. +INCLUDEDIR ?= $(LOCALEDIR)/include
  30. PAMH ?= $(shell test -f $(INCLUDEDIR)/security/pam_appl.h && echo y)
  31. AUDITH ?= $(shell test -f $(INCLUDEDIR)/libaudit.h && echo y)
  32. # Enable capabilities to permit newrole to generate audit records.
  33. diff --git a/run_init/Makefile b/run_init/Makefile
  34. index e86364a..20a64d4 100644
  35. --- a/run_init/Makefile
  36. +++ b/run_init/Makefile
  37. @@ -6,8 +6,8 @@ SBINDIR ?= $(PREFIX)/sbin
  38. MANDIR ?= $(PREFIX)/share/man
  39. ETCDIR ?= /etc
  40. LOCALEDIR ?= $(DESTDIR)$(PREFIX)/share/locale
  41. -PAMH ?= $(shell test -f /usr/include/security/pam_appl.h && echo y)
  42. -AUDITH ?= $(shell test -f /usr/include/libaudit.h && echo y)
  43. +PAMH ?= $(shell test -f $(DESTDIR)$(PREFIX)/include/security/pam_appl.h && echo y)
  44. +AUDITH ?= $(shell test -f $(DESTDIR)$(PREFIX)/include/libaudit.h && echo y)
  45. CFLAGS ?= -Werror -Wall -W
  46. override CFLAGS += -DUSE_NLS -DLOCALEDIR="\"$(LOCALEDIR)\"" -DPACKAGE="\"policycoreutils\""
  47. --
  48. 2.31.1