History

Merge tag 'kbuild-v5.6' of git://git.kernel.org/pub/scm/linux/kernel/git/masahiroy/linux-kbuild

Pull Kbuild updates from Masahiro Yamada: - detect missing include guard in UAPI headers - do not create orphan built-in.a or obj-y objects - generate modules.builtin more simply, and drop tristate.conf - simplify built-in initramfs creation - make linux-headers deb package thinner - optimize the deb package build script - misc cleanups * tag 'kbuild-v5.6' of git://git.kernel.org/pub/scm/linux/kernel/git/masahiroy/linux-kbuild: (34 commits) builddeb: split libc headers deployment out into a function builddeb: split kernel headers deployment out into a function builddeb: remove redundant make for ARCH=um builddeb: avoid invoking sub-shells where possible builddeb: remove redundant $objtree/ builddeb: match temporary directory name to the package name builddeb: remove unneeded files in hdrobjfiles for headers package kbuild: use -S instead of -E for precise cc-option test in Kconfig builddeb: allow selection of .deb compressor kbuild: remove 'Building modules, stage 2.' log kbuild: remove *.tmp file when filechk fails kbuild: remove PYTHON2 variable modpost: assume STT_SPARC_REGISTER is defined gen_initramfs.sh: remove intermediate cpio_list on errors initramfs: refactor the initramfs build rules gen_initramfs.sh: always output cpio even without -o option initramfs: add default_cpio_list, and delete -d option support initramfs: generate dependency list and cpio at the same time initramfs: specify $(src)/gen_initramfs.sh as a prerequisite in Makefile initramfs: make initramfs compression choice non-optional ...

Linus Torvalds committed 6 years ago

Commit 368d0602 parents acd7750 451dff320 files · +281 −449Browse files

Showing the changes to scripts (10 of 20 files). Show all

Unified · Split

10 files
  1. scripts/Kbuild.include +11 −14
  2. scripts/Kconfig.include +1 −1
  3. scripts/Makefile.build +2 −2
  4. scripts/Makefile.lib +14 −7
  5. scripts/Makefile.modbuiltin +0 −57
  6. scripts/Makefile.modpost +0 −1
  7. scripts/kconfig/confdata.c +2 −43
  8. scripts/link-vmlinux.sh +4 −0
  9. scripts/mod/modpost.c +1 −7
  10. scripts/package/builddeb +63 −43
scripts/Kbuild.include+11−14
@@ -32,6 +32,10 @@ real-prereqs = $(filter-out $(PHONY), $^) · 31 unmodified lines
3232 # Escape single quote for use in echo statements
3333 escsq = $(subst $(squote),'\$(squote)',$1)
3434
35+###
36+# Quote a string to pass it to C files. foo => '"foo"'
37+stringify = $(squote)$(quote)$1$(quote)$(squote)
38+
3539 ###
3640 # Easy method for doing a status message
3741 kecho := :
@@ -55,14 +59,13 @@ kecho := $($(quiet)kecho) · 17 unmodified lines
5559 # - stdin is piped in from the first prerequisite ($<) so one has
5660 # to specify a valid file as first prerequisite (often the kbuild file)
5761 define filechk
58− $(Q)set -e; \
59− mkdir -p $(dir $@); \
60− { $(filechk_$(1)); } > $@.tmp; \
61− if [ -r $@ ] && cmp -s $@ $@.tmp; then \
62− rm -f $@.tmp; \
63− else \
64− $(kecho) ' UPD $@'; \
65− mv -f $@.tmp $@; \
62+ $(Q)set -e; \
63+ mkdir -p $(dir $@); \
64+ trap "rm -f $(dot-target).tmp" EXIT; \
65+ { $(filechk_$(1)); } > $(dot-target).tmp; \
66+ if [ ! -r $@ ] || ! cmp -s $@ $(dot-target).tmp; then \
67+ $(kecho) ' UPD $@'; \
68+ mv -f $(dot-target).tmp $@; \
6669 fi
6770 endef
6871
@@ -159,12 +162,6 @@ ld-ifversion = $(shell [ $(ld-version) $(1) $(2) ] && echo $(3) || echo $(4)) · 90 unmodified lines
159162 # $(Q)$(MAKE) $(build)=dir
160163 build := -f $(srctree)/scripts/Makefile.build obj
161164
162−###
163−# Shorthand for $(Q)$(MAKE) -f scripts/Makefile.modbuiltin obj=
164−# Usage:
165−# $(Q)$(MAKE) $(modbuiltin)=dir
166−modbuiltin := -f $(srctree)/scripts/Makefile.modbuiltin obj
167−
168165 ###
169166 # Shorthand for $(Q)$(MAKE) -f scripts/Makefile.dtbinst obj=
170167 # Usage:
scripts/Kconfig.include+1−1
@@ -25,7 +25,7 @@ failure = $(if-success,$(1),n,y) · 24 unmodified lines
2525
2626 # $(cc-option,<flag>)
2727 # Return y if the compiler supports <flag>, n otherwise
28−cc-option = $(success,$(CC) -Werror $(CLANG_FLAGS) $(1) -E -x c /dev/null -o /dev/null)
28+cc-option = $(success,$(CC) -Werror $(CLANG_FLAGS) $(1) -S -x c /dev/null -o /dev/null)
2929
3030 # $(ld-option,<flag>)
3131 # Return y if the linker supports <flag>, n otherwise
scripts/Makefile.build+2−2
@@ -66,7 +66,7 @@ lib-target := $(obj)/lib.a · 65 unmodified lines
6666 real-obj-y += $(obj)/lib-ksyms.o
6767 endif
6868
69−ifneq ($(strip $(real-obj-y) $(need-builtin)),)
69+ifdef need-builtin
7070 builtin-target := $(obj)/built-in.a
7171 endif
7272
@@ -372,7 +372,7 @@ $(obj)/%.asn1.c $(obj)/%.asn1.h: $(src)/%.asn1 $(objtree)/scripts/asn1_compiler · 299 unmodified lines
372372 # ---------------------------------------------------------------------------
373373
374374 # To build objects in subdirs, we need to descend into the directories
375−$(sort $(subdir-obj-y)): $(subdir-ym) ;
375+$(obj)/%/built-in.a: $(obj)/% ;
376376
377377 #
378378 # Rule to compile a set of .o files into one .a file (without symbol table)
scripts/Makefile.lib+14−7
@@ -35,7 +35,11 @@ __subdir-y := $(patsubst %/,%,$(filter %/, $(obj-y))) · 34 unmodified lines
3535 subdir-y += $(__subdir-y)
3636 __subdir-m := $(patsubst %/,%,$(filter %/, $(obj-m)))
3737 subdir-m += $(__subdir-m)
38+ifdef need-builtin
3839 obj-y := $(patsubst %/, %/built-in.a, $(obj-y))
40+else
41+obj-y := $(filter-out %/, $(obj-y))
42+endif
3943 obj-m := $(filter-out %/, $(obj-m))
4044
4145 # Subdirectories we need to descend into
@@ -80,12 +84,14 @@ multi-used-m := $(addprefix $(obj)/,$(multi-used-m)) · 38 unmodified lines
8084 subdir-ym := $(addprefix $(obj)/,$(subdir-ym))
8185
8286 # Finds the multi-part object the current object will be linked into.
83−# If the object belongs to two or more multi-part objects, all of them are
84−# concatenated with a colon separator.
85−modname-multi = $(subst $(space),:,$(sort $(foreach m,$(multi-used),\
86− $(if $(filter $*.o, $($(m:.o=-objs)) $($(m:.o=-y)) $($(m:.o=-m))),$(m:.o=)))))
87+# If the object belongs to two or more multi-part objects, list them all.
88+modname-multi = $(sort $(foreach m,$(multi-used),\
89+ $(if $(filter $*.o, $($(m:.o=-objs)) $($(m:.o=-y)) $($(m:.o=-m))),$(m:.o=))))
90+
91+__modname = $(if $(modname-multi),$(modname-multi),$(basetarget))
8792
88−modname = $(if $(modname-multi),$(modname-multi),$(basetarget))
93+modname = $(subst $(space),:,$(__modname))
94+modfile = $(addprefix $(obj)/,$(__modname))
8995
9096 # target with $(obj)/ and its suffix stripped
9197 target-stem = $(basename $(patsubst $(obj)/%,%,$@))
@@ -93,9 +99,10 @@ target-stem = $(basename $(patsubst $(obj)/%,%,$@)) · 1 unmodified line
9399 # These flags are needed for modversions and compiling, so we define them here
94100 # $(modname_flags) defines KBUILD_MODNAME as the name of the module it will
95101 # end up in (or would, if it gets compiled in)
96−name-fix = $(squote)$(quote)$(subst $(comma),_,$(subst -,_,$1))$(quote)$(squote)
102+name-fix = $(call stringify,$(subst $(comma),_,$(subst -,_,$1)))
97103 basename_flags = -DKBUILD_BASENAME=$(call name-fix,$(basetarget))
98104 modname_flags = -DKBUILD_MODNAME=$(call name-fix,$(modname))
105+modfile_flags = -DKBUILD_MODFILE=$(call stringify,$(modfile))
99106
100107 orig_c_flags = $(KBUILD_CPPFLAGS) $(KBUILD_CFLAGS) \
101108 $(ccflags-y) $(CFLAGS_$(target-stem).o)
@@ -154,7 +161,7 @@ quiet_modtag = $(if $(part-of-module),[M], ) · 52 unmodified lines
154161 modkern_cflags = \
155162 $(if $(part-of-module), \
156163 $(KBUILD_CFLAGS_MODULE) $(CFLAGS_MODULE), \
157− $(KBUILD_CFLAGS_KERNEL) $(CFLAGS_KERNEL))
164+ $(KBUILD_CFLAGS_KERNEL) $(CFLAGS_KERNEL) $(modfile_flags))
158165
159166 modkern_aflags = $(if $(part-of-module), \
160167 $(KBUILD_AFLAGS_MODULE) $(AFLAGS_MODULE), \
scripts/Makefile.modbuiltin+0−57
@@ -1,57 +0,0 @@
1−# SPDX-License-Identifier: GPL-2.0
2−# ==========================================================================
3−# Generating modules.builtin
4−# ==========================================================================
5−
6−src := $(obj)
7−
8−PHONY := __modbuiltin
9−__modbuiltin:
10−
11−include include/config/auto.conf
12−# tristate.conf sets tristate variables to uppercase 'Y' or 'M'
13−# That way, we get the list of built-in modules in obj-Y
14−include include/config/tristate.conf
15−
16−include scripts/Kbuild.include
17−
18−ifdef building_out_of_srctree
19−# Create output directory if not already present
20−_dummy := $(shell [ -d $(obj) ] || mkdir -p $(obj))
21−endif
22−
23−# The filename Kbuild has precedence over Makefile
24−kbuild-dir := $(if $(filter /%,$(src)),$(src),$(srctree)/$(src))
25−kbuild-file := $(if $(wildcard $(kbuild-dir)/Kbuild),$(kbuild-dir)/Kbuild,$(kbuild-dir)/Makefile)
26−include $(kbuild-file)
27−
28−include scripts/Makefile.lib
29−__subdir-Y := $(patsubst %/,%,$(filter %/, $(obj-Y)))
30−subdir-Y += $(__subdir-Y)
31−subdir-ym := $(sort $(subdir-y) $(subdir-Y) $(subdir-m))
32−subdir-ym := $(addprefix $(obj)/,$(subdir-ym))
33−obj-Y := $(addprefix $(obj)/,$(obj-Y))
34−
35−modbuiltin-subdirs := $(patsubst %,%/modules.builtin, $(subdir-ym))
36−modbuiltin-mods := $(filter %.ko, $(obj-Y:.o=.ko))
37−modbuiltin-target := $(obj)/modules.builtin
38−
39−__modbuiltin: $(modbuiltin-target) $(subdir-ym)
40− @:
41−
42−$(modbuiltin-target): $(subdir-ym) FORCE
43− $(Q)(for m in $(modbuiltin-mods); do echo $$m; done; \
44− cat /dev/null $(modbuiltin-subdirs)) > $@
45−
46−PHONY += FORCE
47−
48−FORCE:
49−
50−# Descending
51−# ---------------------------------------------------------------------------
52−
53−PHONY += $(subdir-ym)
54−$(subdir-ym):
55− $(Q)$(MAKE) $(modbuiltin)=$@
56−
57−.PHONY: $(PHONY)
scripts/Makefile.modpost+0−1
@@ -90,7 +90,6 @@ quiet_cmd_modpost = MODPOST $(words $(modules)) modules · 89 unmodified lines
9090 cmd_modpost = sed 's/ko$$/o/' $(MODORDER) | $(MODPOST)
9191
9292 __modpost:
93− @$(kecho) ' Building modules, stage 2.'
9493 $(call cmd,modpost)
9594 ifneq ($(KBUILD_MODPOST_NOFINAL),1)
9695 $(Q)$(MAKE) -f $(srctree)/scripts/Makefile.modfinal
scripts/kconfig/confdata.c+2−43
@@ -710,25 +710,6 @@ static struct conf_printer header_printer_cb = · 709 unmodified lines
710710 .print_comment = header_print_comment,
711711 };
712712
713−/*
714− * Tristate printer
715− *
716− * This printer is used when generating the `include/config/tristate.conf' file.
717− */
718−static void
719−tristate_print_symbol(FILE *fp, struct symbol *sym, const char *value, void *arg)
720−{
721−
722− if (sym->type == S_TRISTATE && *value != 'n')
723− fprintf(fp, "%s%s=%c\n", CONFIG_, sym->name, (char)toupper(*value));
724−}
725−
726−static struct conf_printer tristate_printer_cb =
727−{
728− .print_symbol = tristate_print_symbol,
729− .print_comment = kconfig_print_comment,
730−};
731−
732713 static void conf_write_symbol(FILE *fp, struct symbol *sym,
733714 struct conf_printer *printer, void *printer_arg)
734715 {
@@ -1062,7 +1043,7 @@ int conf_write_autoconf(int overwrite) · 327 unmodified lines
10621043 struct symbol *sym;
10631044 const char *name;
10641045 const char *autoconf_name = conf_get_autoconfig_name();
1065− FILE *out, *tristate, *out_h;
1046+ FILE *out, *out_h;
10661047 int i;
10671048
10681049 if (!overwrite && is_present(autoconf_name))
@@ -1077,23 +1058,13 @@ int conf_write_autoconf(int overwrite) · 8 unmodified lines
10771058 if (!out)
10781059 return 1;
10791060
1080− tristate = fopen(".tmpconfig_tristate", "w");
1081− if (!tristate) {
1082− fclose(out);
1083− return 1;
1084− }
1085−
10861061 out_h = fopen(".tmpconfig.h", "w");
10871062 if (!out_h) {
10881063 fclose(out);
1089− fclose(tristate);
10901064 return 1;
10911065 }
10921066
10931067 conf_write_heading(out, &kconfig_printer_cb, NULL);
1094−
1095− conf_write_heading(tristate, &tristate_printer_cb, NULL);
1096−
10971068 conf_write_heading(out_h, &header_printer_cb, NULL);
10981069
10991070 for_all_symbols(i, sym) {
@@ -1101,15 +1072,11 @@ int conf_write_autoconf(int overwrite) · 1 unmodified line
11011072 if (!(sym->flags & SYMBOL_WRITE) || !sym->name)
11021073 continue;
11031074
1104− /* write symbol to auto.conf, tristate and header files */
1075+ /* write symbols to auto.conf and autoconf.h */
11051076 conf_write_symbol(out, sym, &kconfig_printer_cb, (void *)1);
1106−
1107− conf_write_symbol(tristate, sym, &tristate_printer_cb, (void *)1);
1108−
11091077 conf_write_symbol(out_h, sym, &header_printer_cb, NULL);
11101078 }
11111079 fclose(out);
1112− fclose(tristate);
11131080 fclose(out_h);
11141081
11151082 name = getenv("KCONFIG_AUTOHEADER");
@@ -1120,14 +1087,6 @@ int conf_write_autoconf(int overwrite) · 4 unmodified lines
11201087 if (rename(".tmpconfig.h", name))
11211088 return 1;
11221089
1123− name = getenv("KCONFIG_TRISTATE");
1124− if (!name)
1125− name = "include/config/tristate.conf";
1126− if (make_parent_dir(name))
1127− return 1;
1128− if (rename(".tmpconfig_tristate", name))
1129− return 1;
1130−
11311090 if (make_parent_dir(autoconf_name))
11321091 return 1;
11331092 /*
scripts/link-vmlinux.sh+4−0
@@ -250,6 +250,10 @@ ${MAKE} -f "${srctree}/scripts/Makefile.modpost" MODPOST_VMLINUX=1 · 249 unmodified lines
250250
251251 info MODINFO modules.builtin.modinfo
252252 ${OBJCOPY} -j .modinfo -O binary vmlinux.o modules.builtin.modinfo
253+info GEN modules.builtin
254+# The second line aids cases where multiple modules share the same object.
255+tr '\0' '\n' < modules.builtin.modinfo | sed -n 's/^[[:alnum:]:_]*\.file=//p' |
256+ tr ' ' '\n' | uniq | sed -e 's:^:kernel/:' -e 's/$/.ko/' > modules.builtin
253257
254258 btf_vmlinux_bin_o=""
255259 if [ -n "${CONFIG_DEBUG_INFO_BTF}" ]; then
scripts/mod/modpost.c+1−7
@@ -12,6 +12,7 @@ · 11 unmodified lines
1212 */
1313
1414 #define _GNU_SOURCE
15+#include <elf.h>
1516 #include <stdio.h>
1617 #include <ctype.h>
1718 #include <string.h>
@@ -729,12 +730,6 @@ static void handle_symbol(struct module *mod, struct elf_info *info, · 711 unmodified lines
729730 break;
730731 if (ignore_undef_symbol(info, symname))
731732 break;
732−/* cope with newer glibc (2.3.4 or higher) STT_ definition in elf.h */
733−#if defined(STT_REGISTER) || defined(STT_SPARC_REGISTER)
734−/* add compatibility with older glibc */
735−#ifndef STT_SPARC_REGISTER
736−#define STT_SPARC_REGISTER STT_REGISTER
737−#endif
738733 if (info->hdr->e_machine == EM_SPARC ||
739734 info->hdr->e_machine == EM_SPARCV9) {
740735 /* Ignore register directives. */
@@ -747,7 +742,6 @@ static void handle_symbol(struct module *mod, struct elf_info *info, · 6 unmodified lines
747742 symname = munged;
748743 }
749744 }
750−#endif
751745
752746 mod->unres = alloc_symbol(symname,
753747 ELF_ST_BIND(sym->st_info) == STB_WEAK,
scripts/package/builddeb+63−43
@@ -43,17 +43,66 @@ create_package() { · 42 unmodified lines
4343
4444 # Create the package
4545 dpkg-gencontrol -p$pname -P"$pdir"
46− dpkg --build "$pdir" ..
46+ dpkg-deb ${KDEB_COMPRESS:+-Z$KDEB_COMPRESS} --build "$pdir" ..
47+}
48+
49+deploy_kernel_headers () {
50+ pdir=$1
51+
52+ rm -rf $pdir
53+
54+ (
55+ cd $srctree
56+ find . arch/$SRCARCH -maxdepth 1 -name Makefile\*
57+ find include scripts -type f -o -type l
58+ find arch/$SRCARCH -name module.lds -o -name Kbuild.platforms -o -name Platform
59+ find $(find arch/$SRCARCH -name include -o -name scripts -type d) -type f
60+ ) > debian/hdrsrcfiles
61+
62+ {
63+ if is_enabled CONFIG_STACK_VALIDATION; then
64+ echo tools/objtool/objtool
65+ fi
66+
67+ find arch/$SRCARCH/include Module.symvers include scripts -type f
68+
69+ if is_enabled CONFIG_GCC_PLUGINS; then
70+ find scripts/gcc-plugins -name \*.so
71+ fi
72+ } > debian/hdrobjfiles
73+
74+ destdir=$pdir/usr/src/linux-headers-$version
75+ mkdir -p $destdir
76+ tar -c -f - -C $srctree -T debian/hdrsrcfiles | tar -xf - -C $destdir
77+ tar -c -f - -T debian/hdrobjfiles | tar -xf - -C $destdir
78+ rm -f debian/hdrsrcfiles debian/hdrobjfiles
79+
80+ # copy .config manually to be where it's expected to be
81+ cp $KCONFIG_CONFIG $destdir/.config
82+
83+ mkdir -p $pdir/lib/modules/$version/
84+ ln -s /usr/src/linux-headers-$version $pdir/lib/modules/$version/build
85+}
86+
87+deploy_libc_headers () {
88+ pdir=$1
89+
90+ rm -rf $pdir
91+
92+ $MAKE -f $srctree/Makefile headers
93+ $MAKE -f $srctree/Makefile headers_install INSTALL_HDR_PATH=$pdir/usr
94+
95+ # move asm headers to /usr/include/<libc-machine>/asm to match the structure
96+ # used by Debian-based distros (to support multi-arch)
97+ host_arch=$(dpkg-architecture -a$(cat debian/arch) -qDEB_HOST_MULTIARCH)
98+ mkdir $pdir/usr/include/$host_arch
99+ mv $pdir/usr/include/asm $pdir/usr/include/$host_arch/
47100 }
48101
49102 version=$KERNELRELEASE
50−tmpdir="$objtree/debian/tmp"
51−kernel_headers_dir="$objtree/debian/hdrtmp"
52−libc_headers_dir="$objtree/debian/headertmp"
53−dbg_dir="$objtree/debian/dbgtmp"
103+tmpdir=debian/linux-image
104+dbg_dir=debian/linux-image-dbg
54105 packagename=linux-image-$version
55−kernel_headers_packagename=linux-headers-$version
56−libc_headers_packagename=linux-libc-dev
57106 dbg_packagename=$packagename-dbg
58107
59108 if [ "$ARCH" = "um" ] ; then
@@ -77,15 +126,13 @@ esac · 17 unmodified lines
77126 BUILD_DEBUG=$(if_enabled_echo CONFIG_DEBUG_INFO Yes)
78127
79128 # Setup the directory structure
80−rm -rf "$tmpdir" "$kernel_headers_dir" "$libc_headers_dir" "$dbg_dir" $objtree/debian/files
129+rm -rf "$tmpdir" "$dbg_dir" debian/files
81130 mkdir -m 755 -p "$tmpdir/DEBIAN"
82131 mkdir -p "$tmpdir/lib" "$tmpdir/boot"
83−mkdir -p "$kernel_headers_dir/lib/modules/$version/"
84132
85−# Build and install the kernel
133+# Install the kernel
86134 if [ "$ARCH" = "um" ] ; then
87135 mkdir -p "$tmpdir/usr/lib/uml/modules/$version" "$tmpdir/usr/bin" "$tmpdir/usr/share/doc/$packagename"
88− $MAKE linux
89136 cp System.map "$tmpdir/usr/lib/uml/modules/$version/System.map"
90137 cp $KCONFIG_CONFIG "$tmpdir/usr/share/doc/$packagename/config"
91138 gzip "$tmpdir/usr/share/doc/$packagename/config"
@@ -129,16 +176,6 @@ if is_enabled CONFIG_MODULES; then · 37 unmodified lines
129176 fi
130177 fi
131178
132−if [ "$ARCH" != "um" ]; then
133− $MAKE -f $srctree/Makefile headers
134− $MAKE -f $srctree/Makefile headers_install INSTALL_HDR_PATH="$libc_headers_dir/usr"
135− # move asm headers to /usr/include/<libc-machine>/asm to match the structure
136− # used by Debian-based distros (to support multi-arch)
137− host_arch=$(dpkg-architecture -a$(cat debian/arch) -qDEB_HOST_MULTIARCH)
138− mkdir $libc_headers_dir/usr/include/$host_arch
139− mv $libc_headers_dir/usr/include/asm $libc_headers_dir/usr/include/$host_arch/
140−fi
141−
142179 # Install the maintainer scripts
143180 # Note: hook scripts under /etc/kernel are also executed by official Debian
144181 # kernel packages, as well as kernel packages built using make-kpkg.
@@ -164,29 +201,12 @@ EOF · 19 unmodified lines
164201 chmod 755 "$tmpdir/DEBIAN/$script"
165202 done
166203
167−# Build kernel header package
168−(cd $srctree; find . -name Makefile\* -o -name Kconfig\* -o -name \*.pl) > "$objtree/debian/hdrsrcfiles"
169−(cd $srctree; find arch/*/include include scripts -type f -o -type l) >> "$objtree/debian/hdrsrcfiles"
170−(cd $srctree; find arch/$SRCARCH -name module.lds -o -name Kbuild.platforms -o -name Platform) >> "$objtree/debian/hdrsrcfiles"
171−(cd $srctree; find $(find arch/$SRCARCH -name include -o -name scripts -type d) -type f) >> "$objtree/debian/hdrsrcfiles"
172−if is_enabled CONFIG_STACK_VALIDATION; then
173− (cd $objtree; find tools/objtool -type f -executable) >> "$objtree/debian/hdrobjfiles"
174−fi
175−(cd $objtree; find arch/$SRCARCH/include Module.symvers include scripts -type f) >> "$objtree/debian/hdrobjfiles"
176−if is_enabled CONFIG_GCC_PLUGINS; then
177− (cd $objtree; find scripts/gcc-plugins -name \*.so -o -name gcc-common.h) >> "$objtree/debian/hdrobjfiles"
178−fi
179−destdir=$kernel_headers_dir/usr/src/linux-headers-$version
180−mkdir -p "$destdir"
181−(cd $srctree; tar -c -f - -T -) < "$objtree/debian/hdrsrcfiles" | (cd $destdir; tar -xf -)
182−(cd $objtree; tar -c -f - -T -) < "$objtree/debian/hdrobjfiles" | (cd $destdir; tar -xf -)
183−(cd $objtree; cp $KCONFIG_CONFIG $destdir/.config) # copy .config manually to be where it's expected to be
184−ln -sf "/usr/src/linux-headers-$version" "$kernel_headers_dir/lib/modules/$version/build"
185−rm -f "$objtree/debian/hdrsrcfiles" "$objtree/debian/hdrobjfiles"
186−
187204 if [ "$ARCH" != "um" ]; then
188− create_package "$kernel_headers_packagename" "$kernel_headers_dir"
189− create_package "$libc_headers_packagename" "$libc_headers_dir"
205+ deploy_kernel_headers debian/linux-headers
206+ create_package linux-headers-$version debian/linux-headers
207+
208+ deploy_libc_headers debian/linux-libc-dev
209+ create_package linux-libc-dev debian/linux-libc-dev
190210 fi
191211
192212 create_package "$packagename" "$tmpdir"

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t