diff mbox series

[bionic/master-next,1/1] UBUNTU: [Packaging] include the retpoline extractor in the headers

Message ID 20180403165249.15489-5-apw@canonical.com
State New
Headers show
Series [bionic/master-next,1/1] UBUNTU: [Packaging] include the retpoline extractor in the headers | expand

Commit Message

Andy Whitcroft April 3, 2018, 4:52 p.m. UTC
BugLink: http://bugs.launchpad.net/bugs/1760876
Signed-off-by: Andy Whitcroft <apw@canonical.com>
---
 debian/rules                    | 6 +++++-
 debian/rules.d/2-binary-arch.mk | 2 ++
 scripts/Makefile.build          | 2 +-
 3 files changed, 8 insertions(+), 2 deletions(-)

Comments

Seth Forshee April 3, 2018, 6:28 p.m. UTC | #1
On Tue, Apr 03, 2018 at 05:52:44PM +0100, Andy Whitcroft wrote:
> BugLink: http://bugs.launchpad.net/bugs/1760876
> Signed-off-by: Andy Whitcroft <apw@canonical.com>

Applied to bionic/master-next and unastable/master, thanks!
diff mbox series

Patch

diff --git a/debian/rules b/debian/rules
index 61680be586f0..7519bc4a9d32 100755
--- a/debian/rules
+++ b/debian/rules
@@ -119,6 +119,9 @@  clean: debian/control
 	# Install the copyright information.
 	cp $(DEBIAN)/copyright debian/copyright
 
+	# Install the retpoline extractor.
+	cp $(DROOT)/scripts/retpoline-extract-one scripts/ubuntu-retpoline-extract-one
+
 	# If we have a reconstruct script use it.
 	[ -f $(DEBIAN)/reconstruct ] && bash $(DEBIAN)/reconstruct
 
@@ -127,7 +130,8 @@  clean: debian/control
 
 distclean: clean
 	rm -rf $(DROOT)/control debian/changelog \
-		debian/control debian/control.stub debian/copyright
+		debian/control debian/control.stub debian/copyright \
+		scripts/ubuntu-retpoline-extract-one
 
 # Builds the image, arch headers and debug packages
 include $(DROOT)/rules.d/2-binary-arch.mk
diff --git a/debian/rules.d/2-binary-arch.mk b/debian/rules.d/2-binary-arch.mk
index e829dc73d889..72e55fc6815c 100644
--- a/debian/rules.d/2-binary-arch.mk
+++ b/debian/rules.d/2-binary-arch.mk
@@ -327,6 +327,8 @@  ifeq ($(build_arch),powerpc)
 	mkdir -p $(hdrdir)/arch/powerpc/lib
 	cp $(builddir)/build-$*/arch/powerpc/lib/*.o $(hdrdir)/arch/powerpc/lib
 endif
+	# Copy over the new retpoline extractor.
+	cp scripts/ubuntu-retpoline-extract-one $(hdrdir)/scripts
 	# Script to symlink everything up
 	$(SHELL) $(DROOT)/scripts/link-headers "$(hdrdir)" "$(indeppkg)" "$*"
 	# The build symlink
diff --git a/scripts/Makefile.build b/scripts/Makefile.build
index 9dc3f41f4ff5..e79e11fbd22c 100644
--- a/scripts/Makefile.build
+++ b/scripts/Makefile.build
@@ -298,7 +298,7 @@  objtool_dep = $(objtool_obj)					\
 			 include/config/stack/validation.h)
 
 ifdef CONFIG_RETPOLINE
-cmd_ubuntu_retpoline = $(CONFIG_SHELL) $(srctree)/debian/scripts/retpoline-extract-one $(@) $(<) "$(filter -m16 %code16gcc.h,$(a_flags))";
+cmd_ubuntu_retpoline = $(CONFIG_SHELL) $(srctree)/scripts/ubuntu-retpoline-extract-one $(@) $(<) "$(filter -m16 %code16gcc.h,$(a_flags))";
 else
 cmd_ubuntu_retpoline =
 endif