2019-05-19 13:07:45 +01:00
|
|
|
|
2005-04-16 15:20:36 -07:00
|
|
|
|
2019-08-21 16:02:04 +09:00
|
|
|
|
|
|
|
|
|
2023-03-16 00:50:18 +09:00
|
|
|
|
2005-04-16 15:20:36 -07:00
|
|
|
|
2011-05-04 13:48:11 -07:00
|
|
|
|
2013-04-12 14:12:50 +02:00
|
|
|
|
2022-09-25 03:19:09 +09:00
|
|
|
|
2022-11-24 07:00:44 +09:00
|
|
|
|
|
|
|
|
|
2023-01-22 23:14:21 +09:00
|
|
|
|
2013-04-12 14:12:50 +02:00
|
|
|
|
2005-04-16 15:20:36 -07:00
|
|
|
|
2015-09-02 12:57:08 +03:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2017-12-06 19:32:57 +09:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2023-02-15 10:20:26 +09:00
|
|
|
|
2017-12-06 19:32:57 +09:00
|
|
|
|
2015-09-02 12:57:08 +03:00
|
|
|
|
|
|
|
|
|
kbuild: fix broken builds because of GZIP,BZIP2,LZOP variables
Redefine GZIP, BZIP2, LZOP variables as KGZIP, KBZIP2, KLZOP resp.
GZIP, BZIP2, LZOP env variables are reserved by the tools. The original
attempt to redefine them internally doesn't work in makefiles/scripts
intercall scenarios, e.g., "make GZIP=gzip bindeb-pkg" and results in
broken builds. There can be other broken build commands because of this,
so the universal solution is to use non-reserved env variables for the
compression tools.
Fixes: 8dfb61dcbace ("kbuild: add variables for compression tools")
Signed-off-by: Denis Efremov <efremov@linux.com>
Tested-by: Guenter Roeck <linux@roeck-us.net>
Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>
2020-06-08 12:59:44 +03:00
|
|
|
|
2023-01-22 23:14:21 +09:00
|
|
|
|
2015-09-02 12:57:08 +03:00
|
|
|
|
2023-03-16 00:50:18 +09:00
|
|
|
|
|
|
|
|
|
2023-02-15 10:20:24 +09:00
|
|
|
|
2023-03-16 00:50:18 +09:00
|
|
|
|
2023-02-15 10:20:30 +09:00
|
|
|
|
2023-03-16 00:50:18 +09:00
|
|
|
|
|
|
|
|
|
2023-02-15 10:20:30 +09:00
|
|
|
|
2023-03-16 00:50:18 +09:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2023-02-15 10:20:30 +09:00
|
|
|
|
2023-04-17 23:25:48 +09:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2023-04-07 19:16:28 +09:00
|
|
|
|
2023-04-07 19:16:27 +09:00
|
|
|
|
2023-04-07 19:16:28 +09:00
|
|
|
|
2023-04-20 02:04:24 +09:00
|
|
|
|
2023-04-07 19:16:27 +09:00
|
|
|
|
2023-04-17 23:25:48 +09:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2023-02-15 10:20:24 +09:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2023-04-17 23:25:48 +09:00
|
|
|
|
2023-04-07 19:16:28 +09:00
|
|
|
|
|
|
|
|
|
2023-04-20 02:04:24 +09:00
|
|
|
|
2023-04-07 19:16:28 +09:00
|
|
|
|
2023-04-07 19:16:27 +09:00
|
|
|
|
2023-02-15 10:20:24 +09:00
|
|
|
|
2023-07-22 13:48:05 +09:00
|
|
|
|
2006-03-08 18:39:05 +01:00
|
|
|
|
2022-11-21 09:48:45 -05:00
|
|
|
|
2023-07-22 13:48:05 +09:00
|
|
|
|
2023-09-30 19:38:47 +09:00
|
|
|
|
2023-07-22 13:48:05 +09:00
|
|
|
|
2023-09-30 19:38:47 +09:00
|
|
|
|
2023-07-22 13:48:05 +09:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2023-09-30 19:38:47 +09:00
|
|
|
|
|
|
|
|
|
2023-07-22 13:48:05 +09:00
|
|
|
|
|
|
|
|
|
2023-07-22 13:48:06 +09:00
|
|
|
|
|
|
|
|
|
2023-07-22 13:48:05 +09:00
|
|
|
|
2017-09-30 10:10:10 +09:00
|
|
|
|
2023-04-17 23:25:47 +09:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2023-04-17 23:25:48 +09:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2023-02-15 10:20:27 +09:00
|
|
|
|
kbuild: give up untracked files for source package builds
When the source tree is dirty and contains untracked files, package
builds may fail, for example, when a broken symlink exists, a file
path contains whitespaces, etc.
Since commit 05e96e96a315 ("kbuild: use git-archive for source package
creation"), the source tarball only contains committed files because
it is created by 'git archive'. scripts/package/gen-diff-patch tries
to address the diff from HEAD, but including untracked files by the
hand-crafted script introduces more complexity. I wrote a patch [1] to
make it work in most cases, but still wonder if this is what we should
aim for.
To simplify the code, this patch just gives up untracked files. Going
forward, it is your responsibility to do 'git add' for what you want in
the source package. The script shows a warning just in case you forgot
to do so. It should be checked only when building source packages.
[1]: https://lore.kernel.org/all/CAK7LNAShbZ56gSh9PrbLnBDYKnjtTkHMoCXeGrhcxMvqXGq9=g@mail.gmail.com/2-0001-kbuild-make-package-builds-more-robust.patch
Fixes: 05e96e96a315 ("kbuild: use git-archive for source package creation")
Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>
Reviewed-by: Nicolas Schier <nicolas@fjasle.eu>
2023-04-10 21:09:07 +09:00
|
|
|
|
2023-02-15 10:20:27 +09:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2023-04-17 23:25:48 +09:00
|
|
|
|
kbuild: give up untracked files for source package builds
When the source tree is dirty and contains untracked files, package
builds may fail, for example, when a broken symlink exists, a file
path contains whitespaces, etc.
Since commit 05e96e96a315 ("kbuild: use git-archive for source package
creation"), the source tarball only contains committed files because
it is created by 'git archive'. scripts/package/gen-diff-patch tries
to address the diff from HEAD, but including untracked files by the
hand-crafted script introduces more complexity. I wrote a patch [1] to
make it work in most cases, but still wonder if this is what we should
aim for.
To simplify the code, this patch just gives up untracked files. Going
forward, it is your responsibility to do 'git add' for what you want in
the source package. The script shows a warning just in case you forgot
to do so. It should be checked only when building source packages.
[1]: https://lore.kernel.org/all/CAK7LNAShbZ56gSh9PrbLnBDYKnjtTkHMoCXeGrhcxMvqXGq9=g@mail.gmail.com/2-0001-kbuild-make-package-builds-more-robust.patch
Fixes: 05e96e96a315 ("kbuild: use git-archive for source package creation")
Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>
Reviewed-by: Nicolas Schier <nicolas@fjasle.eu>
2023-04-10 21:09:07 +09:00
|
|
|
|
2023-04-17 23:25:48 +09:00
|
|
|
|
2023-02-15 10:20:28 +09:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2023-02-15 10:20:27 +09:00
|
|
|
|
2023-04-17 23:25:47 +09:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2015-09-02 12:57:24 +03:00
|
|
|
|
2023-04-17 23:25:47 +09:00
|
|
|
|
2023-02-15 10:20:27 +09:00
|
|
|
|
2023-04-17 23:25:47 +09:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2023-04-17 23:25:48 +09:00
|
|
|
|
2023-04-17 23:25:47 +09:00
|
|
|
|
kbuild: deb-pkg: support DEB_BUILD_OPTIONS=parallel=N in debian/rules
'make srcdeb-pkg' generates a source package, which you can build
later by using dpkg-buildpackage.
In older dpkg versions, 'dpkg-buildpackage --jobs=N' sets not only
DEB_BUILD_OPTIONS but also MAKEFLAGS. Hence, passing -j or --jobs
to dpkg-buildpackage was enough for kicking the parallel execution.
The behavior was changed by commit 1d0ea9b2ba3f ("dpkg-buildpackage:
Change -j, --jobs semantics to non-force mode") of dpkg project. [1]
Since then, 'dpkg-buildpackage --jobs=N' sets only DEB_BUILD_OPTIONS,
which is not parsed by the current debian/rules. To build the package
in parallel, you need to pass the alternative --jobs-force option or
set the MAKEFLAGS environment variable.
Debian policy [2] suggests the following code snippet for debian/rules.
ifneq (,$(filter parallel=%,$(DEB_BUILD_OPTIONS)))
NUMJOBS = $(patsubst parallel=%,%,$(filter parallel=%,$(DEB_BUILD_OPTIONS)))
MAKEFLAGS += -j$(NUMJOBS)
endif
I tweaked the code to filter out parallel=1 and passed --jobs=1 to
dpkg-buildpackage from scripts/Makefile.package. It is needed to force
'make deb-pkg' without the -j option to run in serial. Please note that
dpkg-buildpackage sets parallel=<nproc> in DEB_BUILD_OPTIONS by default
(that is, --jobs=auto is the default) and --jobs=1 is needed to restore
the serial execution. When dpkg-buildpackage is invoked from Kbuild,
the number of jobs is inherited from the top level Makefile. Passing
--jobs=1 to dpkg-buildpackage allows debian/rules to skip parsing
DEB_BUILD_OPTIONS.
[1] https://salsa.debian.org/dpkg-team/dpkg/-/commit/1d0ea9b2ba3f6a2de5b1a6ff55f3df7b71f73db6
[2] https://www.debian.org/doc/debian-policy/ch-source.html#s-debianrules-options
Reported-by: Bastian Germann <bage@linutronix.de>
Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>
2023-08-21 07:18:02 +09:00
|
|
|
|
2023-04-17 23:25:47 +09:00
|
|
|
|
|
|
|
|
|
2018-04-05 14:22:29 +03:00
|
|
|
|
scripts/package: snap-pkg target
Following in footsteps of other targets like 'deb-pkg, 'rpm-pkg' and 'tar-pkg',
this patch adds a 'snap-pkg' target for the creation of a Linux kernel snap
package using the kbuild infrastructure.
A snap, in its general form, is a self contained, sandboxed, universal package
and it is intended to work across multiple distributions and/or devices. A snap
package is distributed as a single compressed squashfs filesystem.
A kernel snap is a snap package carrying the Linux kernel, kernel modules,
accessory files (DTBs, System.map, etc) and a manifesto file. The purpose of a
kernel snap is to carry the Linux kernel during the creation of a system image,
eg. Ubuntu Core, and its subsequent upgrades.
For more information on snap packages: https://snapcraft.io/docs/
Signed-off-by: Paolo Pisati <paolo.pisati@canonical.com>
Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
2017-11-27 12:07:34 +01:00
|
|
|
|
|
|
|
|
|
2019-08-21 16:02:03 +09:00
|
|
|
|
|
|
|
|
|
scripts/package: snap-pkg target
Following in footsteps of other targets like 'deb-pkg, 'rpm-pkg' and 'tar-pkg',
this patch adds a 'snap-pkg' target for the creation of a Linux kernel snap
package using the kbuild infrastructure.
A snap, in its general form, is a self contained, sandboxed, universal package
and it is intended to work across multiple distributions and/or devices. A snap
package is distributed as a single compressed squashfs filesystem.
A kernel snap is a snap package carrying the Linux kernel, kernel modules,
accessory files (DTBs, System.map, etc) and a manifesto file. The purpose of a
kernel snap is to carry the Linux kernel during the creation of a system image,
eg. Ubuntu Core, and its subsequent upgrades.
For more information on snap packages: https://snapcraft.io/docs/
Signed-off-by: Paolo Pisati <paolo.pisati@canonical.com>
Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
2017-11-27 12:07:34 +01:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2023-02-15 10:20:31 +09:00
|
|
|
|
2005-05-24 11:27:37 +02:00
|
|
|
|
2023-02-15 10:20:31 +09:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2023-04-07 19:16:29 +09:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2023-03-16 00:50:18 +09:00
|
|
|
|
2023-04-07 19:16:29 +09:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2023-03-16 00:50:18 +09:00
|
|
|
|
2023-04-07 19:16:29 +09:00
|
|
|
|
2023-03-16 00:50:18 +09:00
|
|
|
|
|
|
|
|
|
2023-02-15 10:20:31 +09:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2023-03-16 00:50:18 +09:00
|
|
|
|
|
|
|
|
|
2023-02-15 10:20:31 +09:00
|
|
|
|
|
|
|
|
|
2023-03-16 00:50:18 +09:00
|
|
|
|
|
|
|
|
|
2005-05-24 11:27:37 +02:00
|
|
|
|
2023-02-15 10:20:30 +09:00
|
|
|
|
2010-05-31 11:13:21 -03:00
|
|
|
|
|
|
|
|
|
2023-03-16 00:50:18 +09:00
|
|
|
|
|
|
|
|
|
2023-02-15 10:20:30 +09:00
|
|
|
|
2023-03-16 00:50:18 +09:00
|
|
|
|
|
|
|
|
|
2023-02-15 10:20:30 +09:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2023-03-16 00:50:18 +09:00
|
|
|
|
2023-02-15 10:20:30 +09:00
|
|
|
|
|
|
|
|
|
2023-03-16 00:50:18 +09:00
|
|
|
|
2023-02-15 10:20:30 +09:00
|
|
|
|
|
|
|
|
|
2023-04-07 19:16:27 +09:00
|
|
|
|
2023-03-16 00:50:18 +09:00
|
|
|
|
|
|
|
|
|
2023-02-15 10:20:30 +09:00
|
|
|
|
2023-04-07 19:16:28 +09:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2023-04-20 02:04:24 +09:00
|
|
|
|
2023-04-07 19:16:28 +09:00
|
|
|
|
2023-04-07 19:16:27 +09:00
|
|
|
|
2023-03-16 00:50:18 +09:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2023-02-15 10:20:30 +09:00
|
|
|
|
2023-03-16 00:50:18 +09:00
|
|
|
|
|
|
|
|
|
2010-05-31 11:13:21 -03:00
|
|
|
|
2005-04-16 15:20:36 -07:00
|
|
|
|
|
|
|
|
|
2019-08-21 16:02:03 +09:00
|
|
|
|
|
|
|
|
|
2010-05-31 11:13:21 -03:00
|
|
|
|
2022-12-27 17:21:57 +08:00
|
|
|
|
2015-09-02 12:57:24 +03:00
|
|
|
|
|
|
|
|
|
2023-04-17 23:25:47 +09:00
|
|
|
|
2015-09-02 12:57:24 +03:00
|
|
|
|
2019-10-25 13:52:32 +02:00
|
|
|
|
|
|
|
|
|
2019-11-04 14:11:44 +01:00
|
|
|
|
2010-05-31 11:13:21 -03:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2011-01-30 12:18:51 +01:00
|
|
|
|
2021-10-08 13:37:59 +02:00
|
|
|
|
2023-02-15 10:20:30 +09:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2019-08-21 16:02:04 +09:00
|
|
|
|
2023-02-15 10:20:24 +09:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2023-03-16 00:50:18 +09:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2019-08-21 16:02:04 +09:00
|
|
|
|