|
4 | 4 | include $(srctree)/scripts/Kbuild.include
|
5 | 5 | include $(srctree)/scripts/Makefile.lib
|
6 | 6 |
|
7 |
| -KERNELPATH := kernel-$(subst -,_,$(KERNELRELEASE)) |
8 |
| -# Include only those top-level files that are needed by make, plus the GPL copy |
9 |
| -TAR_CONTENT := Documentation LICENSES arch block certs crypto drivers fs \ |
10 |
| - include init io_uring ipc kernel lib mm net rust \ |
11 |
| - samples scripts security sound tools usr virt \ |
12 |
| - .config Makefile \ |
13 |
| - Kbuild Kconfig COPYING $(wildcard localversion*) |
14 |
| - |
15 |
| -quiet_cmd_src_tar = TAR $(2).tar.gz |
16 |
| - cmd_src_tar = \ |
17 |
| -if test "$(objtree)" != "$(srctree)"; then \ |
18 |
| - echo >&2; \ |
19 |
| - echo >&2 " ERROR:"; \ |
20 |
| - echo >&2 " Building source tarball is not possible outside the"; \ |
21 |
| - echo >&2 " kernel source tree. Don't set KBUILD_OUTPUT"; \ |
22 |
| - echo >&2; \ |
23 |
| - false; \ |
24 |
| -fi ; \ |
25 |
| -tar -I $(KGZIP) -c $(RCS_TAR_IGNORE) -f $(2).tar.gz \ |
26 |
| - --transform 's:^:$(2)/:S' $(TAR_CONTENT) $(3) |
27 |
| - |
28 | 7 | # Git
|
29 | 8 | # ---------------------------------------------------------------------------
|
30 | 9 |
|
@@ -157,9 +136,8 @@ snap-pkg:
|
157 | 136 | rm -rf $(objtree)/snap
|
158 | 137 | mkdir $(objtree)/snap
|
159 | 138 | $(MAKE) clean
|
160 |
| - $(call cmd,src_tar,$(KERNELPATH)) |
161 | 139 | sed "s@KERNELRELEASE@$(KERNELRELEASE)@; \
|
162 |
| - s@SRCTREE@$(shell realpath $(KERNELPATH).tar.gz)@" \ |
| 140 | + s@SRCTREE@$(abs_srctree)@" \ |
163 | 141 | $(srctree)/scripts/package/snapcraft.template > \
|
164 | 142 | $(objtree)/snap/snapcraft.yaml
|
165 | 143 | cd $(objtree)/snap && \
|
|
0 commit comments