diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2017-05-10 23:41:43 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2017-05-10 23:41:43 -0400 |
commit | 23ea3f62f3f90caaa7b4bf32690c341101228cca (patch) | |
tree | e9b0f5594ecb484b2c6e9c207560f2b91b7f0315 | |
parent | 593043d35ddff8ab033546c2a89bb1d4080d03e1 (diff) | |
parent | 9eb3c95896a337256489124857157f49616d2c6b (diff) |
Merge tag 'kbuild-misc-v4.12' of git://git.kernel.org/pub/scm/linux/kernel/git/masahiroy/linux-kbuild
Pull misc Kbuild updates from Masahiro Yamada:
- clean up builddeb script
- use full path for KBUILD_IMAGE to fix rpm-pkg build
- fix objdiff tool to ignore debug info
* tag 'kbuild-misc-v4.12' of git://git.kernel.org/pub/scm/linux/kernel/git/masahiroy/linux-kbuild:
builddeb: fix typo
builddeb: Update a few outdated and hardcoded strings
deb-pkg: Remove the KBUILD_IMAGE workaround
unicore32: Use full path in KBUILD_IMAGE definition
sh: Use full path in KBUILD_IMAGE definition
arc: Use full path in KBUILD_IMAGE definition
arm: Use full path in KBUILD_IMAGE definition
arm64: Use full path in KBUILD_IMAGE definition
scripts: objdiff: Ignore debug info when comparing
-rw-r--r-- | arch/arc/Makefile | 4 | ||||
-rw-r--r-- | arch/arm/Makefile | 8 | ||||
-rw-r--r-- | arch/arm64/Makefile | 6 | ||||
-rw-r--r-- | arch/sh/Makefile | 7 | ||||
-rw-r--r-- | arch/unicore32/Makefile | 4 | ||||
-rwxr-xr-x | scripts/objdiff | 5 | ||||
-rwxr-xr-x | scripts/package/builddeb | 16 |
7 files changed, 21 insertions, 29 deletions
diff --git a/arch/arc/Makefile b/arch/arc/Makefile index 19cce226d1a8..44ef35d33956 100644 --- a/arch/arc/Makefile +++ b/arch/arc/Makefile | |||
@@ -123,9 +123,9 @@ libs-y += arch/arc/lib/ $(LIBGCC) | |||
123 | boot := arch/arc/boot | 123 | boot := arch/arc/boot |
124 | 124 | ||
125 | #default target for make without any arguments. | 125 | #default target for make without any arguments. |
126 | KBUILD_IMAGE := bootpImage | 126 | KBUILD_IMAGE := $(boot)/bootpImage |
127 | 127 | ||
128 | all: $(KBUILD_IMAGE) | 128 | all: bootpImage |
129 | bootpImage: vmlinux | 129 | bootpImage: vmlinux |
130 | 130 | ||
131 | boot_targets += uImage uImage.bin uImage.gz | 131 | boot_targets += uImage uImage.bin uImage.gz |
diff --git a/arch/arm/Makefile b/arch/arm/Makefile index ab30cc634d02..65f4e2a4eb94 100644 --- a/arch/arm/Makefile +++ b/arch/arm/Makefile | |||
@@ -297,10 +297,11 @@ drivers-$(CONFIG_OPROFILE) += arch/arm/oprofile/ | |||
297 | libs-y := arch/arm/lib/ $(libs-y) | 297 | libs-y := arch/arm/lib/ $(libs-y) |
298 | 298 | ||
299 | # Default target when executing plain make | 299 | # Default target when executing plain make |
300 | boot := arch/arm/boot | ||
300 | ifeq ($(CONFIG_XIP_KERNEL),y) | 301 | ifeq ($(CONFIG_XIP_KERNEL),y) |
301 | KBUILD_IMAGE := xipImage | 302 | KBUILD_IMAGE := $(boot)/xipImage |
302 | else | 303 | else |
303 | KBUILD_IMAGE := zImage | 304 | KBUILD_IMAGE := $(boot)/zImage |
304 | endif | 305 | endif |
305 | 306 | ||
306 | # Build the DT binary blobs if we have OF configured | 307 | # Build the DT binary blobs if we have OF configured |
@@ -308,9 +309,8 @@ ifeq ($(CONFIG_USE_OF),y) | |||
308 | KBUILD_DTBS := dtbs | 309 | KBUILD_DTBS := dtbs |
309 | endif | 310 | endif |
310 | 311 | ||
311 | all: $(KBUILD_IMAGE) $(KBUILD_DTBS) | 312 | all: $(notdir $(KBUILD_IMAGE)) $(KBUILD_DTBS) |
312 | 313 | ||
313 | boot := arch/arm/boot | ||
314 | 314 | ||
315 | archheaders: | 315 | archheaders: |
316 | $(Q)$(MAKE) $(build)=arch/arm/tools uapi | 316 | $(Q)$(MAKE) $(build)=arch/arm/tools uapi |
diff --git a/arch/arm64/Makefile b/arch/arm64/Makefile index 7dedf2d8494e..f839ecd919f9 100644 --- a/arch/arm64/Makefile +++ b/arch/arm64/Makefile | |||
@@ -102,12 +102,12 @@ libs-y := arch/arm64/lib/ $(libs-y) | |||
102 | core-$(CONFIG_EFI_STUB) += $(objtree)/drivers/firmware/efi/libstub/lib.a | 102 | core-$(CONFIG_EFI_STUB) += $(objtree)/drivers/firmware/efi/libstub/lib.a |
103 | 103 | ||
104 | # Default target when executing plain make | 104 | # Default target when executing plain make |
105 | KBUILD_IMAGE := Image.gz | 105 | boot := arch/arm64/boot |
106 | KBUILD_IMAGE := $(boot)/Image.gz | ||
106 | KBUILD_DTBS := dtbs | 107 | KBUILD_DTBS := dtbs |
107 | 108 | ||
108 | all: $(KBUILD_IMAGE) $(KBUILD_DTBS) | 109 | all: Image.gz $(KBUILD_DTBS) |
109 | 110 | ||
110 | boot := arch/arm64/boot | ||
111 | 111 | ||
112 | Image: vmlinux | 112 | Image: vmlinux |
113 | $(Q)$(MAKE) $(build)=$(boot) $(boot)/$@ | 113 | $(Q)$(MAKE) $(build)=$(boot) $(boot)/$@ |
diff --git a/arch/sh/Makefile b/arch/sh/Makefile index 336f33a419d9..280bbff12102 100644 --- a/arch/sh/Makefile +++ b/arch/sh/Makefile | |||
@@ -94,7 +94,8 @@ defaultimage-$(CONFIG_SH_7206_SOLUTION_ENGINE) := vmlinux | |||
94 | defaultimage-$(CONFIG_SH_7619_SOLUTION_ENGINE) := vmlinux | 94 | defaultimage-$(CONFIG_SH_7619_SOLUTION_ENGINE) := vmlinux |
95 | 95 | ||
96 | # Set some sensible Kbuild defaults | 96 | # Set some sensible Kbuild defaults |
97 | KBUILD_IMAGE := $(defaultimage-y) | 97 | boot := arch/sh/boot |
98 | KBUILD_IMAGE := $(boot)/$(defaultimage-y) | ||
98 | 99 | ||
99 | # | 100 | # |
100 | # Choosing incompatible machines durings configuration will result in | 101 | # Choosing incompatible machines durings configuration will result in |
@@ -186,8 +187,6 @@ cpuincdir-y += cpu-common # Must be last | |||
186 | drivers-y += arch/sh/drivers/ | 187 | drivers-y += arch/sh/drivers/ |
187 | drivers-$(CONFIG_OPROFILE) += arch/sh/oprofile/ | 188 | drivers-$(CONFIG_OPROFILE) += arch/sh/oprofile/ |
188 | 189 | ||
189 | boot := arch/sh/boot | ||
190 | |||
191 | cflags-y += $(foreach d, $(cpuincdir-y), -Iarch/sh/include/$(d)) \ | 190 | cflags-y += $(foreach d, $(cpuincdir-y), -Iarch/sh/include/$(d)) \ |
192 | $(foreach d, $(machdir-y), -Iarch/sh/include/$(d)) | 191 | $(foreach d, $(machdir-y), -Iarch/sh/include/$(d)) |
193 | 192 | ||
@@ -211,7 +210,7 @@ BOOT_TARGETS = uImage uImage.bz2 uImage.gz uImage.lzma uImage.xz uImage.lzo \ | |||
211 | romImage | 210 | romImage |
212 | PHONY += $(BOOT_TARGETS) | 211 | PHONY += $(BOOT_TARGETS) |
213 | 212 | ||
214 | all: $(KBUILD_IMAGE) | 213 | all: $(notdir $(KBUILD_IMAGE)) |
215 | 214 | ||
216 | $(BOOT_TARGETS): vmlinux | 215 | $(BOOT_TARGETS): vmlinux |
217 | $(Q)$(MAKE) $(build)=$(boot) $(boot)/$@ | 216 | $(Q)$(MAKE) $(build)=$(boot) $(boot)/$@ |
diff --git a/arch/unicore32/Makefile b/arch/unicore32/Makefile index b6f5c4c1eaf9..98a5ca43ae87 100644 --- a/arch/unicore32/Makefile +++ b/arch/unicore32/Makefile | |||
@@ -43,9 +43,9 @@ boot := arch/unicore32/boot | |||
43 | 43 | ||
44 | # Default defconfig and target when executing plain make | 44 | # Default defconfig and target when executing plain make |
45 | KBUILD_DEFCONFIG := $(ARCH)_defconfig | 45 | KBUILD_DEFCONFIG := $(ARCH)_defconfig |
46 | KBUILD_IMAGE := zImage | 46 | KBUILD_IMAGE := $(boot)/zImage |
47 | 47 | ||
48 | all: $(KBUILD_IMAGE) | 48 | all: zImage |
49 | 49 | ||
50 | zImage Image uImage: vmlinux | 50 | zImage Image uImage: vmlinux |
51 | $(Q)$(MAKE) $(build)=$(boot) $(boot)/$@ | 51 | $(Q)$(MAKE) $(build)=$(boot) $(boot)/$@ |
diff --git a/scripts/objdiff b/scripts/objdiff index 62e51dae2138..4fb5d6796893 100755 --- a/scripts/objdiff +++ b/scripts/objdiff | |||
@@ -57,13 +57,15 @@ get_output_dir() { | |||
57 | do_objdump() { | 57 | do_objdump() { |
58 | dir=$(get_output_dir $1) | 58 | dir=$(get_output_dir $1) |
59 | base=${1##*/} | 59 | base=${1##*/} |
60 | stripped=$dir/${base%.o}.stripped | ||
60 | dis=$dir/${base%.o}.dis | 61 | dis=$dir/${base%.o}.dis |
61 | 62 | ||
62 | [ ! -d "$dir" ] && mkdir -p $dir | 63 | [ ! -d "$dir" ] && mkdir -p $dir |
63 | 64 | ||
64 | # remove addresses for a cleaner diff | 65 | # remove addresses for a cleaner diff |
65 | # http://dummdida.tumblr.com/post/60924060451/binary-diff-between-libc-from-scientificlinux-and | 66 | # http://dummdida.tumblr.com/post/60924060451/binary-diff-between-libc-from-scientificlinux-and |
66 | $OBJDUMP -D $1 | sed "s/^[[:space:]]\+[0-9a-f]\+//" > $dis | 67 | $STRIP -g $1 -R __bug_table -R .note -R .comment -o $stripped |
68 | $OBJDUMP -D $stripped | sed -e "s/^[[:space:]]\+[0-9a-f]\+//" -e "s:^$stripped:$1:" > $dis | ||
67 | } | 69 | } |
68 | 70 | ||
69 | dorecord() { | 71 | dorecord() { |
@@ -73,6 +75,7 @@ dorecord() { | |||
73 | 75 | ||
74 | CMT="`git rev-parse --short HEAD`" | 76 | CMT="`git rev-parse --short HEAD`" |
75 | 77 | ||
78 | STRIP="${CROSS_COMPILE}strip" | ||
76 | OBJDUMP="${CROSS_COMPILE}objdump" | 79 | OBJDUMP="${CROSS_COMPILE}objdump" |
77 | 80 | ||
78 | for d in $FILES; do | 81 | for d in $FILES; do |
diff --git a/scripts/package/builddeb b/scripts/package/builddeb index 676fc10c9514..aad67000e4dd 100755 --- a/scripts/package/builddeb +++ b/scripts/package/builddeb | |||
@@ -69,7 +69,7 @@ set_debarch() { | |||
69 | echo "" >&2 | 69 | echo "" >&2 |
70 | echo "** ** ** WARNING ** ** **" >&2 | 70 | echo "** ** ** WARNING ** ** **" >&2 |
71 | echo "" >&2 | 71 | echo "" >&2 |
72 | echo "Your architecture doesn't have it's equivalent" >&2 | 72 | echo "Your architecture doesn't have its equivalent" >&2 |
73 | echo "Debian userspace architecture defined!" >&2 | 73 | echo "Debian userspace architecture defined!" >&2 |
74 | echo "Falling back to using your current userspace instead!" >&2 | 74 | echo "Falling back to using your current userspace instead!" >&2 |
75 | echo "Please add support for $UTS_MACHINE to ${0} ..." >&2 | 75 | echo "Please add support for $UTS_MACHINE to ${0} ..." >&2 |
@@ -143,12 +143,7 @@ else | |||
143 | cp System.map "$tmpdir/boot/System.map-$version" | 143 | cp System.map "$tmpdir/boot/System.map-$version" |
144 | cp $KCONFIG_CONFIG "$tmpdir/boot/config-$version" | 144 | cp $KCONFIG_CONFIG "$tmpdir/boot/config-$version" |
145 | fi | 145 | fi |
146 | # Not all arches include the boot path in KBUILD_IMAGE | 146 | cp "$($MAKE -s image_name)" "$tmpdir/$installed_image_path" |
147 | if [ -e $KBUILD_IMAGE ]; then | ||
148 | cp $KBUILD_IMAGE "$tmpdir/$installed_image_path" | ||
149 | else | ||
150 | cp arch/$ARCH/boot/$KBUILD_IMAGE "$tmpdir/$installed_image_path" | ||
151 | fi | ||
152 | 147 | ||
153 | if grep -q "^CONFIG_OF=y" $KCONFIG_CONFIG ; then | 148 | if grep -q "^CONFIG_OF=y" $KCONFIG_CONFIG ; then |
154 | # Only some architectures with OF support have this target | 149 | # Only some architectures with OF support have this target |
@@ -265,7 +260,7 @@ This is a packacked upstream version of the Linux kernel. | |||
265 | The sources may be found at most Linux archive sites, including: | 260 | The sources may be found at most Linux archive sites, including: |
266 | https://www.kernel.org/pub/linux/kernel | 261 | https://www.kernel.org/pub/linux/kernel |
267 | 262 | ||
268 | Copyright: 1991 - 2015 Linus Torvalds and others. | 263 | Copyright: 1991 - 2017 Linus Torvalds and others. |
269 | 264 | ||
270 | The git repository for mainline kernel development is at: | 265 | The git repository for mainline kernel development is at: |
271 | git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git | 266 | git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git |
@@ -288,7 +283,6 @@ Section: kernel | |||
288 | Priority: optional | 283 | Priority: optional |
289 | Maintainer: $maintainer | 284 | Maintainer: $maintainer |
290 | Build-Depends: $build_depends | 285 | Build-Depends: $build_depends |
291 | Standards-Version: 3.8.4 | ||
292 | Homepage: http://www.kernel.org/ | 286 | Homepage: http://www.kernel.org/ |
293 | EOF | 287 | EOF |
294 | 288 | ||
@@ -296,7 +290,6 @@ if [ "$ARCH" = "um" ]; then | |||
296 | cat <<EOF >> debian/control | 290 | cat <<EOF >> debian/control |
297 | 291 | ||
298 | Package: $packagename | 292 | Package: $packagename |
299 | Provides: linux-image, linux-image-2.6, linux-modules-$version | ||
300 | Architecture: any | 293 | Architecture: any |
301 | Description: User Mode Linux kernel, version $version | 294 | Description: User Mode Linux kernel, version $version |
302 | User-mode Linux is a port of the Linux kernel to its own system call | 295 | User-mode Linux is a port of the Linux kernel to its own system call |
@@ -313,7 +306,6 @@ else | |||
313 | cat <<EOF >> debian/control | 306 | cat <<EOF >> debian/control |
314 | 307 | ||
315 | Package: $packagename | 308 | Package: $packagename |
316 | Provides: linux-image, linux-image-2.6, linux-modules-$version | ||
317 | Suggests: $fwpackagename | 309 | Suggests: $fwpackagename |
318 | Architecture: any | 310 | Architecture: any |
319 | Description: Linux kernel, version $version | 311 | Description: Linux kernel, version $version |
@@ -346,7 +338,6 @@ rm -f "$objtree/debian/hdrsrcfiles" "$objtree/debian/hdrobjfiles" | |||
346 | cat <<EOF >> debian/control | 338 | cat <<EOF >> debian/control |
347 | 339 | ||
348 | Package: $kernel_headers_packagename | 340 | Package: $kernel_headers_packagename |
349 | Provides: linux-headers, linux-headers-2.6 | ||
350 | Architecture: any | 341 | Architecture: any |
351 | Description: Linux kernel headers for $KERNELRELEASE on \${kernel:debarch} | 342 | Description: Linux kernel headers for $KERNELRELEASE on \${kernel:debarch} |
352 | This package provides kernel header files for $KERNELRELEASE on \${kernel:debarch} | 343 | This package provides kernel header files for $KERNELRELEASE on \${kernel:debarch} |
@@ -404,7 +395,6 @@ if [ -n "$BUILD_DEBUG" ] ; then | |||
404 | 395 | ||
405 | Package: $dbg_packagename | 396 | Package: $dbg_packagename |
406 | Section: debug | 397 | Section: debug |
407 | Provides: linux-debug, linux-debug-$version | ||
408 | Architecture: any | 398 | Architecture: any |
409 | Description: Linux kernel debugging symbols for $version | 399 | Description: Linux kernel debugging symbols for $version |
410 | This package will come in handy if you need to debug the kernel. It provides | 400 | This package will come in handy if you need to debug the kernel. It provides |