forked from pool/kernel-source
GIT Revision: 6c33ac4c17512344a51413a39060e307da80c2a8
OBS-URL: https://build.opensuse.org/package/show/Kernel:HEAD/kernel-source?expand=0&rev=7137
This commit is contained in:
parent
eb21664016
commit
ad364baade
6
README.KSYMS
Normal file
6
README.KSYMS
Normal file
@ -0,0 +1,6 @@
|
||||
This file is a place holder for the kernel-syms{,-rt} package. It is used
|
||||
to group build dependencies for all kernel flavors.
|
||||
|
||||
The KMP build process will build KMPs against all installed kernel flavors
|
||||
automatically. If you don't need to build against other flavors than the
|
||||
ones you've already installed - it is safe to uninstall this package.
|
471
README.SUSE
Normal file
471
README.SUSE
Normal file
@ -0,0 +1,471 @@
|
||||
WORKING WITH THE SUSE 2.6.x KERNEL SOURCES
|
||||
|
||||
Andreas Gruenbacher <agruen@suse.de>, SUSE Labs, 2003, 2004, 2005, 2006
|
||||
Michal Marek <mmarek@suse.de>, SUSE Labs, 2010
|
||||
|
||||
|
||||
This document gives an overview of how SUSE Linux kernels are
|
||||
created, and describes tasks like building individual kernels
|
||||
and creating external kernel modules.
|
||||
|
||||
A companion HOWTO that describes how to build driver update disks (among
|
||||
other things) is available at:
|
||||
|
||||
http://developer.novell.com/wiki/index.php/Creating_a_Driver_Update_Disk_%28DUD%29
|
||||
|
||||
|
||||
TABLE OF CONTENTS
|
||||
|
||||
Overview
|
||||
Compiling your own kernel
|
||||
Building additional (external) modules
|
||||
Supported vs. unsupported modules
|
||||
Patch selection mechanism
|
||||
Where to find configuration files
|
||||
How to configure the kernel sources
|
||||
Module load paths
|
||||
|
||||
|
||||
OVERVIEW
|
||||
|
||||
The kernels for SUSE are generated from the vanilla Linux kernel sources
|
||||
found at http://ftp.kernel.org, on top of which a number of patches are
|
||||
applied. The resulting kernel source tree is configured and built,
|
||||
resulting in a binary kernel.
|
||||
|
||||
The add-on patches and configuration files are maintained in
|
||||
a GIT repository at
|
||||
|
||||
http://gitorious.org/opensuse/kernel-source
|
||||
|
||||
A script (scripts/tar-up.sh) packs up the files in the repository in a
|
||||
form suitable for rpmbuild. When building the RPM packages, the
|
||||
following binary packages get created:
|
||||
|
||||
* kernel-source
|
||||
|
||||
The kernel source tree, generated by unpacking the vanilla kernel
|
||||
sources and applying the patches. The kernel sources are used by
|
||||
a number of other packages. They can also be used for compiling
|
||||
additional kernel modules.
|
||||
|
||||
* kernel-$FLAVOR
|
||||
|
||||
A number of binary kernels (for example, kernel-default for
|
||||
uniprocessor machines, kernel-smp for smp machines, etc.). These
|
||||
packages are all generated from the same kernel sources, and
|
||||
differ in the kernel configurations used.
|
||||
|
||||
* kernel-$FLAVOR-base
|
||||
|
||||
A subset of kernel-$FLAVOR, for use in paravirtualized quests that
|
||||
only require a few device and filesystem drivers.
|
||||
|
||||
* kernel-$FLAVOR-devel
|
||||
|
||||
The files used for generating kernel module packages for use with
|
||||
kernel-$FLAVOR.
|
||||
|
||||
* kernel-syms
|
||||
|
||||
A meta package that pulls in the relevant kernel-$FLAVOR-devel
|
||||
packages for a given architecture.
|
||||
|
||||
|
||||
The repository contains the configuration files (.config) for all SUSE
|
||||
kernel flavors. All configuration files are included in the
|
||||
kernel-source package (see WHERE TO FIND CONFIGURATION FILES below).
|
||||
|
||||
|
||||
In the installed system, the kernel-source package installs files in the
|
||||
following directories:
|
||||
|
||||
|
||||
* /usr/src/linux-$VERSION-$RELEASE/
|
||||
|
||||
The kernel sources.
|
||||
|
||||
* /usr/src/linux
|
||||
|
||||
A symbolic link to /usr/src/linux-$VERSION-$RELEASE.
|
||||
|
||||
* /usr/src/linux-$VERSION-$RELEASE-obj/$ARCH/$FLAVOR/
|
||||
|
||||
Kernel build object files for one kernel flavor. These
|
||||
files are used for compiling additional kernel modules.
|
||||
|
||||
* /usr/src/linux-obj
|
||||
|
||||
A symbolic link to /usr/src/linux-$VERSION-$RELEASE-obj/$ARCH/$FLAVOR.
|
||||
|
||||
* /usr/share/doc/packages/kernel-source/
|
||||
|
||||
This document and an external kernel module example.
|
||||
|
||||
* /etc/init.d/running-kernel
|
||||
|
||||
Init script that adapts the kernel sources in /usr/src/linux to
|
||||
the running kernel.
|
||||
|
||||
|
||||
COMPILING YOUR OWN KERNEL
|
||||
|
||||
The kernel sources are found in the kernel-source package. The
|
||||
recommended way to produce a binary kernel is:
|
||||
|
||||
(1) Install kernel-source. Change to the /usr/src/linux directory.
|
||||
|
||||
(2) Create a build directory for use in configuring and building
|
||||
the kernel. Using /usr/src/linux directly requires root priviledges
|
||||
and will cause problems if you need to build kernel modules for
|
||||
other installed kernels.
|
||||
|
||||
(3) Configure the kernel (for example, ``make -C /usr/src/linux
|
||||
O=$(pwd) oldconfig'' or ``make -C /usr/src/linux O=$(pwd) cloneconfig'',
|
||||
see HOW TO CONFIGURE THE KERNEL SOURCES).
|
||||
|
||||
(4) Build the kernel and all its modules (``make'').
|
||||
|
||||
(5) Make sure that /etc/modprobe.d/unsupported-modules contains
|
||||
|
||||
allow_unsupported_modules 1
|
||||
|
||||
otherwise modprobe will refuse to load any modules.
|
||||
|
||||
(6) Install the kernel and the modules (``make modules_install'',
|
||||
followed by ``make install''). This will automatically create
|
||||
an initrd for the new kernel as well (see ``mkinitrd -h'').
|
||||
|
||||
(7) Add the kernel to the boot manager. When using lilo, run ``lilo''
|
||||
to update the boot map.
|
||||
|
||||
Instead of building binary kernels by hand, you can also build
|
||||
one of the kernel-$FLAVOR packages using RPM.
|
||||
|
||||
|
||||
BUILDING ADDITIONAL (EXTERNAL) MODULES
|
||||
|
||||
A single binary kernel module generally only works for a specific
|
||||
version of the kernel source tree, for a specific architecture and
|
||||
configuration. This means that for each binary kernel that SUSE ships, a
|
||||
custom module must be built. This requirement is to some extent relaxed
|
||||
by the modversion mechanism: modversions attach a checksum to each
|
||||
symbol (function or variable) exported to modules by the kernel. This
|
||||
allows to use kernel modules that have been built for a kernel with a
|
||||
different version or release number in many cases, as long as none of
|
||||
the symbols the module uses have changed between the two kernel
|
||||
versions.
|
||||
|
||||
When releasing maintenance or security update kernels for a specific
|
||||
product, we carefully try to keep the kernel ABI stable. Despite this,
|
||||
we sometimes have no choice but to break binary compatibility. In this
|
||||
case, those kernel modules must be rebuilt.
|
||||
|
||||
Additional kernel modules for one of the SUSE kernel flavors can be
|
||||
built in three different ways:
|
||||
|
||||
(1) by configuring the kernel sources in a separate build directory
|
||||
(see HOW TO CONFIGURE THE KERNEL SOURCES), or
|
||||
|
||||
(2) by using one of the standard configurations in
|
||||
/usr/src/linux-obj/$ARCH/$FLAVOR, or
|
||||
|
||||
(3) by creating a Kernel Module Package (KMP) as described in the
|
||||
Kernel Module Packages Manual, http://www.suse.de/~agruen/KMPM/.
|
||||
|
||||
|
||||
The first method involves the following steps:
|
||||
|
||||
(1) Install the kernel-source package.
|
||||
|
||||
(2) Configure the kernel, see HOW TO CONFIGURE THE KERNEL SOURCES.
|
||||
|
||||
(3) Create files required for compiling external modules:
|
||||
``make scripts'' and ``make prepare''.
|
||||
|
||||
(4) Compile the module(s) by changing into the module source directory
|
||||
and typing ``make -C $(your_build_dir) M=$(pwd)''.
|
||||
|
||||
(5) Install the module(s) by typing
|
||||
``make -C $(your_build_dir) M=$(pwd) modules_install''.
|
||||
|
||||
|
||||
The second method involves the following steps:
|
||||
|
||||
(1) Install the kernel-source package.
|
||||
|
||||
(2) Install kernel-syms.$ARCH.rpm. This package is necessary for
|
||||
symbol version information (CONFIG_MODVERSIONS).
|
||||
|
||||
(3) Compile the module(s) by changing into the module source directory
|
||||
and typing ``make -C /usr/src/linux-obj/$ARCH/$FLAVOR M=$(pwd)''.
|
||||
Substitute $ARCH and $FLAVOR with the architecture and flavor
|
||||
for which to build the module(s).
|
||||
|
||||
If the installed kernel sources match the running kernel, you
|
||||
can build modules for the running kernel by using the path
|
||||
/lib/modules/$(uname -r)/build as the -C option in the above
|
||||
command. (build is a symlink to /usr/src/linux-obj/$ARCH/$FLAVOR).
|
||||
|
||||
Starting with SuSE Linux 9.2 / SLES9 Service Pack 1, the
|
||||
modversion information for the running kernel is also
|
||||
contained in the kernel-$FLAVOR packages, and so for building
|
||||
modules for the running kernel, the kernel-syms package is no
|
||||
longer required.
|
||||
|
||||
(4) Install the module(s) with
|
||||
``make -C /usr/src/linux-obj/$ARCH/$FLAVOR M=$(pwd) modules_install''.
|
||||
|
||||
|
||||
Whenever building modules, please use the kernel build infrastructure as
|
||||
much as possible, and do not try to circumvent it. The
|
||||
Documentation/kbuild directory in the kernel sources documents kbuild
|
||||
makefiles.
|
||||
|
||||
Please take a look at the demo module installed under
|
||||
/usr/share/doc/packages/kernel-source for a simple example of an Kernel
|
||||
Module Package (KMP).
|
||||
|
||||
|
||||
SUPPORTED VS. UNSUPPORTED MODULES
|
||||
|
||||
As an extension to the mainline kernel, modules can be tagged as
|
||||
supported (directly by SUSE, or indirectly by a third party) or
|
||||
unsupported. Modules which are known to be flakey or for which SUSE does
|
||||
not have the necessary expertise are marked as unsupported. Modules for
|
||||
which SUSE has third-party support agreements are marked as externally
|
||||
supported. Modules for which SUSE provides direct support are marked as
|
||||
supported.
|
||||
|
||||
The support status of a module can be queried with the modinfo tool.
|
||||
Modinfo will report one of the following:
|
||||
|
||||
- direct support by SUSE: "supported: yes"
|
||||
- third-party support: "supported: external"
|
||||
- unsupported modules: no supported tag.
|
||||
|
||||
At runtime, the setting of the" unsupported" kernel command line
|
||||
parameter and /proc/sys/kernel/unsupported determines whether
|
||||
unsupported modules can be loaded or not, and whether or not loading an
|
||||
unsupported module causes a warning in the system log:
|
||||
|
||||
0 = only allow supported modules,
|
||||
1 = warn when loading unsupported modules,
|
||||
2 = don't warn.
|
||||
|
||||
Irrespective of this setting, loading an externally supported or unsupported
|
||||
module both set a kernel taint flag. The taint flags are included in
|
||||
Oopses. The taint status of the kernel can be inspected in
|
||||
/proc/sys/kernel/tainted: Bits 0 to 4 have the following meanings:
|
||||
|
||||
bit 0 = a module with a GPL-incompatible license was loaded (tainted & 1),
|
||||
bit 1 = module load was enforced (tainted & 2),
|
||||
bit 2 = an SMP-unsafe module was loaded (tainted & 4),
|
||||
bit 3 = (reserved),
|
||||
bit 4 = an unsupported module was loaded (tainted & 16),
|
||||
bit 5 = a module with third-party support was loaded (tainted & 32).
|
||||
bit 10 = a machine check exception has occurred (taint & 1024; x86_64 only
|
||||
so far).
|
||||
|
||||
The corresponding codes for the taint flags in Oopses are (x = unknown):
|
||||
|
||||
- "Pxxx" if bit 0 set or else
|
||||
"Gxxx" if bit 0 unset,
|
||||
|
||||
- "xFxx" if bit 1 set or else
|
||||
"x xx" if bit 1 unset,
|
||||
|
||||
- "xxSx" if set or else
|
||||
"xx x" if bit 2 unset,
|
||||
|
||||
- "xxxU" if bit 4 set or else
|
||||
"xxxX" if bit 5 set or else
|
||||
"xxx ".
|
||||
|
||||
By default, external modules will not have the supported flag (that is,
|
||||
they wil be marked as unsupported). For building externally supported
|
||||
modules, please get in touch with Kurt Garloff <garloff@suse.de>.
|
||||
|
||||
|
||||
PATCH SELECTION MECHANISM
|
||||
|
||||
The SUSE kernels consist of the vanilla kernel sources on top of which a
|
||||
number of patches is applied. The file series.conf determines which
|
||||
patches are applied and which are excluded. A script named "guards"
|
||||
converts series.conf into a plain list of patch files to be applied.
|
||||
Guards decides which patches to include and exclude based on a list of
|
||||
symbols. From the kernel-source.src.rpm package, a fully patched
|
||||
kernel source tree can be generated from vanilla sources + patches like
|
||||
this:
|
||||
|
||||
# Install the package:
|
||||
|
||||
$ rpm -i kernel-source.src.rpm
|
||||
|
||||
# Unpack the patches and the kernel sources:
|
||||
|
||||
$ cd /usr/src/packages/SOURCES
|
||||
$ for f in patches.*.tar.bz2; do \
|
||||
tar -xjf "$f" || break; \
|
||||
done
|
||||
$ tar -xjf linux-2.6.5.tar.bz2
|
||||
|
||||
# Apply the patches
|
||||
|
||||
$ for p in $(./guards < series.conf); do
|
||||
patch -d linux-2.6.5 -p1 < $p || break
|
||||
done
|
||||
|
||||
The configuration script config.conf which is similar to series.conf is
|
||||
used for configuration file selection. See the section WHERE TO FIND
|
||||
CONFIGURATION FILES.
|
||||
|
||||
The file format of series.conf and config.conf should be obvious from
|
||||
the comments in series.conf, and from the guards(1) manual page. (The
|
||||
guards(1) manual page can be generated by running pod2man on the guards
|
||||
script.)
|
||||
|
||||
|
||||
WHERE TO FIND CONFIGURATION FILES
|
||||
|
||||
Kernel configuration files are stored in the kernel GIT repository. When
|
||||
packing up the repository, they end up in config.tar.bz2.
|
||||
|
||||
The kernel-$FLAVOR packages are based on config/$ARCH/$FLAVOR.
|
||||
(kernel-default is based on config/$ARCH/default, for example). The
|
||||
kernel-$FLAVOR packages install their configuration files as
|
||||
/boot/config-$VER_STR (for example, /boot/config-2.6.5-99-default). The
|
||||
config is also packaged in the kernel-$FLAVOR-devel package as
|
||||
/usr/src/linux-obj/$ARCH/$FLAVOR/.config.
|
||||
|
||||
In addition, the running kernel exposes a gzip compressed version of its
|
||||
configuration file as /proc/config.gz. The kernel sources can be
|
||||
configured based on /proc/config.gz with ``make cloneconfig''.
|
||||
|
||||
|
||||
HOW TO CONFIGURE THE KERNEL SOURCES
|
||||
|
||||
Before a binary kernel is built or an additional loadable module
|
||||
for an existing kernel is created, the kernel must be configured.
|
||||
|
||||
In order for a loadable module to work with an existing kernel, it must
|
||||
be created with a configuration that is identical to the kernel's
|
||||
configuration, or at least very close to that. Each configuration is
|
||||
contained in a single file. The kernel-syms package installs
|
||||
configurations for all standard SUSE kernel variants, so for building
|
||||
only external kernel modules it is not necessary to configure the kernel
|
||||
sources.
|
||||
|
||||
Configuring the kernel sources for a specific configuration is
|
||||
straightfoward:
|
||||
|
||||
- Locate the configuration file you want to use. (See WHERE TO FIND
|
||||
CONFIGURATION FILES above).
|
||||
|
||||
- Copy the configuration to the file .config in your build directory.
|
||||
|
||||
- Run the following commands in sequence to apply the configuration,
|
||||
generate version information files, etc.:
|
||||
|
||||
make -C /usr/src/linux O=$PWD clean
|
||||
make -C /usr/src/linux O=$PWD oldconfig
|
||||
|
||||
Alternatively to ``make oldconfig'', you can also use ``make
|
||||
menuconfig'' for a text menu oriented user interface. If the kernel
|
||||
sources do not match the configuration file exactly, ``make
|
||||
oldconfig'' will prompt for settings that are undefined. Once this
|
||||
step is completed, a Makefile will have been created that eliminates
|
||||
the need to specify the locations of the kernel source and the build
|
||||
directory.
|
||||
|
||||
For configuring the kernel to match the running kernel, there is a
|
||||
shortcut ``make cloneconfig'' that expands the file /proc/config.gz
|
||||
into .config, and then runs ``make oldconfig''.
|
||||
|
||||
HOW TO ADD CUSTOM PATCHES
|
||||
|
||||
Typically patches are added to the appropriate patches.* directory (e.g.
|
||||
patches.fixes) and to series.conf. When the kernel-source package is
|
||||
exported from the git repository, the patch will be automatically added
|
||||
to the appropriate patch tarball.
|
||||
|
||||
If your goal is to create a kernel with only a few additional patches
|
||||
and you don't want to be bothered with using the git repository, there
|
||||
is an easier way.
|
||||
|
||||
The kernel-source SRPM ships with two empty archives that can be be
|
||||
filled and automatically expanded when building the kernel. You can use
|
||||
these to add your own patches and config options without disturbing the
|
||||
rest of the kernel package. This is useful if you are using the openSUSE
|
||||
Build Service and link to the main kernel-source project instead of
|
||||
creating your own branch. The advantage to this is that your project
|
||||
will automatically receive all the changes that go into the main project
|
||||
without any further effort.
|
||||
|
||||
To add a patch using this mechanism, just add it to the
|
||||
patches.addon.tar.bz2 archive and add an entry to the series.conf file.
|
||||
The archive will be expanded automatically with the other kernel patches
|
||||
when the source tree is constructed.
|
||||
|
||||
Some patches may add new Kconfig options. The config.addon.tar.bz2
|
||||
archive contains the same hierarchy as config.tar.bz2, but is under
|
||||
config.addon. You can add your new config options to files named after
|
||||
their config/ counterparts.
|
||||
|
||||
For example, the file used to configure the i386 default kernel is named
|
||||
config/i386/default. To add config options to that kernel, you would
|
||||
create a new file called config.addon/i386/default with the options as
|
||||
formatted in a normal Linux kernel .config file. This is important
|
||||
because the kernel build is non-interactive and will fail if it
|
||||
encounters new config options without entries in the config file.
|
||||
|
||||
MODULE LOAD PATHS
|
||||
|
||||
Modules that belong to a specific kernel release are installed in
|
||||
/lib/modules/2.6.5-99-smp and similar. Note that this path contains the
|
||||
kernel package release number. Modules from KMPs must be installed
|
||||
below /lib/modules/2.6.5-99-smp/updates/ and similar: modules below
|
||||
updates/ have priority over other modules.
|
||||
|
||||
When KMPs contain modules that are compatible between multiple installed
|
||||
kernels, symlinks are used to make those modules available to those
|
||||
compatible kernels like this:
|
||||
|
||||
/lib/modules/2.6.16-100-smp/weak-updates/foo.ko ->
|
||||
/lib/modules/2.6.16-99-smp/updates/foo.ko
|
||||
|
||||
Modules in the weak-updates directory have lower priority than modules
|
||||
in /lib/modules/2.6.16-100-smp/updates/, and higher priority than other
|
||||
modules in /lib/modules/2.6.16-100-smp.
|
||||
|
||||
|
||||
REFERENCES
|
||||
|
||||
General
|
||||
|
||||
Documentation in the kernel source tree.
|
||||
|
||||
Linux Documentation Project, http://www.tldp.org/
|
||||
|
||||
Linux Weekly News, http://lwn.net
|
||||
|
||||
Rusty's Remarkably Unreliable Guides (Kernel Hacking
|
||||
and Kernel Locking guides),
|
||||
http://www.netfilter.org/unreliable-guides/
|
||||
|
||||
Kernel newbies, http://www.kernelnewbies.org/
|
||||
|
||||
|
||||
Loadable Kernel Modules
|
||||
|
||||
Peter Jay Salzman and Ori Pomerantz: Linux Kernel Module
|
||||
Programming Guide, Version 2.4, April 2003,
|
||||
http://www.tldp.org/guides.html
|
||||
|
||||
|
||||
Kernel Module Packages
|
||||
|
||||
Andreas Gruenbacher: Kernel Module Packages Manual.
|
||||
Versions for CODE9 (SLES9, SUSE LINUX 10.0) and CODE10
|
||||
(SUSE Linux 10.1, SLES10),
|
||||
http://www.suse.de/~agruen/KMPM/
|
47
apply-patches
Normal file
47
apply-patches
Normal file
@ -0,0 +1,47 @@
|
||||
#!/bin/sh
|
||||
#
|
||||
# Given a series.conf file and a directory with patches, applies them to the
|
||||
# current directory.
|
||||
# Used by kernel-source.spec.in and kernel-binary.spec.in
|
||||
|
||||
USAGE="$0 [--vanilla] <series.conf> <patchdir> [symbol ...]"
|
||||
|
||||
set -e
|
||||
set -o pipefail
|
||||
vanilla=false
|
||||
if test "$1" == "--vanilla"; then
|
||||
vanilla=true
|
||||
shift
|
||||
fi
|
||||
if test $# -lt 2; then
|
||||
echo "$USAGE" >&2
|
||||
exit 1
|
||||
fi
|
||||
DIR="${0%/*}"
|
||||
SERIES_CONF=$1
|
||||
PATCH_DIR=$2
|
||||
shift 2
|
||||
|
||||
trap 'rm -f "$series"' EXIT
|
||||
series=$(mktemp)
|
||||
# support for patches in patches.addon/series
|
||||
cp "$SERIES_CONF" "$series"
|
||||
if ! $vanilla && test -e "$PATCH_DIR/patches.addon/series"; then
|
||||
# make it user-friendly and automatically prepend "patches.addon/"
|
||||
# if there is no "/"
|
||||
sed -r 's|^([[:space:]]*)([^#[:space:]][^/]*)$|\1patches.addon/\2|' \
|
||||
"$PATCH_DIR/patches.addon/series" >>"$series"
|
||||
fi
|
||||
|
||||
(
|
||||
echo "trap 'echo \"*** patch \$_ failed ***\"' ERR"
|
||||
echo "set -ex"
|
||||
"$DIR"/guards "$@" <"$series" | \
|
||||
if $vanilla; then
|
||||
egrep '^patches\.(kernel\.org|rpmify)/'
|
||||
else
|
||||
cat
|
||||
fi |\
|
||||
sed "s|^|patch -s -F0 -E -p1 --no-backup-if-mismatch -i $PATCH_DIR/|"
|
||||
) | sh
|
||||
|
45
arch-symbols
Normal file
45
arch-symbols
Normal file
@ -0,0 +1,45 @@
|
||||
#!/bin/sh
|
||||
|
||||
#############################################################################
|
||||
# Copyright (c) 2003-2005,2009 Novell, Inc.
|
||||
# All Rights Reserved.
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of version 2 of the GNU General Public License as
|
||||
# published by the Free Software Foundation.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, contact Novell, Inc.
|
||||
#
|
||||
# To contact Novell about this file by physical or electronic mail,
|
||||
# you may find current contact information at www.novell.com
|
||||
#############################################################################
|
||||
|
||||
# With --list, list all known architectures, otherwise print the generic
|
||||
# name for this architecture (or the one specified on command line).
|
||||
|
||||
if [ "$1" = "--list" ]; then
|
||||
# List all known architectures
|
||||
echo i386 mips{,64} sparc{,64} ppc{,64} s390{,x} ia64 x86_64 alpha parisc
|
||||
exit 0
|
||||
fi
|
||||
|
||||
if [ -n "$1" ]; then
|
||||
ARCH="$1"
|
||||
else
|
||||
ARCH="`arch`"
|
||||
fi
|
||||
case "$ARCH" in
|
||||
# from rpm --eval '%ix86'
|
||||
i?86 | pentium3 | pentium4 | athlon | geode)
|
||||
echo i386
|
||||
;;
|
||||
*)
|
||||
echo "$ARCH"
|
||||
;;
|
||||
esac
|
17
check-for-config-changes
Normal file
17
check-for-config-changes
Normal file
@ -0,0 +1,17 @@
|
||||
#! /bin/bash
|
||||
|
||||
# lines 4 contains a timestamp...
|
||||
differences="$(
|
||||
diff -bU0 <(sed -e '/^# .* is not set$/p' -e '/^$\|^#/d' "$1" | sort) \
|
||||
<(sed -e '/^# .* is not set$/p' -e '/^$\|^#/d' "$2" | sort) \
|
||||
| grep '^[-+][^-+]'
|
||||
)" || true
|
||||
if [ -n "$differences" ]; then
|
||||
echo
|
||||
echo "Changes after running \`make oldconfig':"
|
||||
echo "$differences"
|
||||
echo
|
||||
if echo "$differences" | grep -q '^+' ; then
|
||||
exit 1
|
||||
fi
|
||||
fi
|
36
check-supported-list
Normal file
36
check-supported-list
Normal file
@ -0,0 +1,36 @@
|
||||
#! /bin/sh
|
||||
|
||||
sourcedir=$1
|
||||
modpath=$2
|
||||
|
||||
# Check for modules not listed in supported.conf: First, for each module
|
||||
# in the list, set mod_$module=1
|
||||
for module in $($sourcedir/guards --list < $sourcedir/supported.conf \
|
||||
| sed -e 's,.*/,,'); do
|
||||
m=${module##*/}
|
||||
m=${m%.ko}
|
||||
eval mod_${m//-/_}=1
|
||||
done
|
||||
|
||||
# Check if any installed module was not listed
|
||||
status=
|
||||
cd $modpath
|
||||
for module in $(find . -name '*.ko' | sort); do
|
||||
case "$module" in
|
||||
./kernel/drivers/staging/* | ./kernel/Documentation/*)
|
||||
continue ;;
|
||||
esac
|
||||
module=${module%.ko}
|
||||
m=${module##*/}
|
||||
m=${m//-/_}
|
||||
m="mod_$m"
|
||||
if [ -z "${!m}" ]; then
|
||||
if [ -z "$status" ]; then
|
||||
echo "Modules not listed in supported.conf:"
|
||||
status=1
|
||||
fi
|
||||
echo ${module#./}
|
||||
fi
|
||||
done
|
||||
|
||||
exit $status
|
77
compute-PATCHVERSION.sh
Normal file
77
compute-PATCHVERSION.sh
Normal file
@ -0,0 +1,77 @@
|
||||
#! /bin/bash
|
||||
|
||||
export LANG=POSIX
|
||||
|
||||
path=(.)
|
||||
while test $# -gt 0; do
|
||||
case "$1" in
|
||||
--patches)
|
||||
path[${#path[@]}]=$2
|
||||
shift 2
|
||||
;;
|
||||
*)
|
||||
echo "Usage $0 [--patches <dir>]" >&2
|
||||
exit 1
|
||||
esac
|
||||
done
|
||||
if test "${path[*]}" = "."; then
|
||||
path=(. ..)
|
||||
fi
|
||||
|
||||
|
||||
source $(dirname $0)/config.sh
|
||||
parse_srcversion()
|
||||
{
|
||||
local IFS=.
|
||||
set -- ${SRCVERSION%%-*}
|
||||
VERSION=$1
|
||||
PATCHLEVEL=${2:-0}
|
||||
SUBLEVEL=${3:-0}
|
||||
EXTRAVERSION=${SRCVERSION#${SRCVERSION%%-*}}
|
||||
}
|
||||
parse_srcversion
|
||||
|
||||
EXTRA_SYMBOLS=$(set -- $([ -e $(dirname $0)/extra-symbols ] && cat $(dirname $0)/extra-symbols) ; echo $*)
|
||||
|
||||
series=$(mktemp)
|
||||
tmp_files="$series"
|
||||
trap 'rm -rf $tmp_files' EXIT
|
||||
warned=false
|
||||
while read patch; do
|
||||
dir=${patch%/*}
|
||||
for p in "${path[@]}"; do
|
||||
if test -d "$p/$dir"; then
|
||||
echo "$p/$patch"
|
||||
continue 2
|
||||
fi
|
||||
done
|
||||
for p in "${path[@]}"; do
|
||||
if test -e "$p/$dir.tar.bz2"; then
|
||||
echo "unpacking $p/$dir.tar.bz2" >&2
|
||||
if ! $warned; then
|
||||
echo "pass --patches <directory with unpacked tarballs> to avoid this" >&2
|
||||
warned=true
|
||||
fi
|
||||
tmp_files="$tmp_files $dir"
|
||||
tar -xjf "$p/$dir.tar.bz2"
|
||||
echo "$patch"
|
||||
continue 2
|
||||
fi
|
||||
done
|
||||
echo "Can't find $patch" >&2
|
||||
exit 1
|
||||
done >"$series" < <($(dirname $0)/guards $EXTRA_SYMBOLS <series.conf)
|
||||
|
||||
# Parse all the changes to KERNELRELEASE out of all patches and
|
||||
# convert them to shell code that can be evaluated. Evaluate it.
|
||||
eval "$(
|
||||
<"$series" xargs awk '
|
||||
/^--- |^\+\+\+ / \
|
||||
{ M = match($2, /^[^\/]+\/Makefile( \t|$)/) }
|
||||
M && /^+(VERSION|PATCHLEVEL|SUBLEVEL|EXTRAVERSION)/ \
|
||||
{ print }
|
||||
' \
|
||||
| sed -e 's,^+,,' -e 's, *= *\(.*\),="\1",'
|
||||
)"
|
||||
|
||||
echo "$VERSION.$PATCHLEVEL.$SUBLEVEL$EXTRAVERSION"
|
1407
config-options.changes.txt
Normal file
1407
config-options.changes.txt
Normal file
File diff suppressed because it is too large
Load Diff
3
config.addon.tar.bz2
Normal file
3
config.addon.tar.bz2
Normal file
@ -0,0 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:e1ddc0ec138354be50695298a844500f84b883a419c711785aba32e2c8e657f0
|
||||
size 129
|
65
config.conf
Normal file
65
config.conf
Normal file
@ -0,0 +1,65 @@
|
||||
# Kernel configuration file selection.
|
||||
# See the arch-symbols script for a list of symbols defined.
|
||||
# -syms excludes a flavor from the kernel-syms package (vanilla is excluded
|
||||
# automatically).
|
||||
|
||||
#
|
||||
# IMPORTANT: the subdirectory names map to cpuarch
|
||||
# kernel-binary and kernel-source rely on this
|
||||
#
|
||||
|
||||
+i386 i386/default
|
||||
+i386 i386/desktop
|
||||
+i386 i386/pae
|
||||
+i386 -syms i386/debug
|
||||
+i386 i386/xen
|
||||
+i386 -syms i386/ec2
|
||||
+i386 i386/vanilla
|
||||
+i386 -syms i386/trace
|
||||
|
||||
+ia64 ia64/default
|
||||
+ia64 -syms ia64/debug
|
||||
+ia64 ia64/vanilla
|
||||
+ia64 -syms ia64/trace
|
||||
|
||||
+x86_64 x86_64/default
|
||||
+x86_64 x86_64/desktop
|
||||
+x86_64 x86_64/xen
|
||||
+x86_64 -syms x86_64/ec2
|
||||
+x86_64 -syms x86_64/debug
|
||||
+x86_64 x86_64/vanilla
|
||||
+x86_64 -syms x86_64/trace
|
||||
|
||||
# openSuSE:
|
||||
# G3 G4 bPlan
|
||||
+ppc ppc/default
|
||||
# G5 PS3 pSeries
|
||||
+ppc ppc/ppc64
|
||||
# PS3 bootloader
|
||||
#+ppc -syms ppc/ps3
|
||||
# maybe the kernels above were patched to death?
|
||||
+ppc ppc/vanilla
|
||||
|
||||
# SLES
|
||||
# identical to ppc64 flavor, all KMP packages need a kernel-default
|
||||
# Up to now, the openSuSE 11.1 ppc media can not have a
|
||||
# kernel-default.ppc.rpm and a kernel-default.ppc64.rpm to continue
|
||||
# supporting 32bit and 64bit systems.
|
||||
+ppc64 ppc64/default
|
||||
# G5 pSeries
|
||||
+ppc64 ppc64/ppc64
|
||||
+ppc64 -syms ppc64/trace
|
||||
+ppc64 -syms ppc64/debug
|
||||
# maybe the kernels above were patched to death?
|
||||
+ppc64 ppc64/vanilla
|
||||
|
||||
+s390 s390/s390
|
||||
+s390 -syms s390/trace
|
||||
+s390 s390/vanilla
|
||||
+s390x s390x/default
|
||||
+s390x -syms s390x/trace
|
||||
+s390x s390x/vanilla
|
||||
|
||||
# Maintained by jengelh
|
||||
# +sparc64 sparc64/default
|
||||
# +sparc64 -syms sparc64/net
|
7
config.sh
Normal file
7
config.sh
Normal file
@ -0,0 +1,7 @@
|
||||
# The version of the main tarball to use
|
||||
SRCVERSION=3.1-rc8
|
||||
# variant of the kernel-source package, either empty or "-rt"
|
||||
VARIANT=
|
||||
# buildservice projects to build the kernel against
|
||||
OBS_PROJECT=openSUSE:Factory
|
||||
IBS_PROJECT=SUSE:Factory:Head
|
3
config.tar.bz2
Normal file
3
config.tar.bz2
Normal file
@ -0,0 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:bb2cecf5e53290976a7c8ed25f4dcbca409fb3b2d17ac03fac55f64c53fcfc82
|
||||
size 229573
|
60
configtool.pl
Normal file
60
configtool.pl
Normal file
@ -0,0 +1,60 @@
|
||||
#!/usr/bin/perl
|
||||
#
|
||||
# Merge two kernel configs, eliminating duplicated assignments.
|
||||
# TODO:
|
||||
# support for #include-style directives in config files, to make the
|
||||
# kernel configs more maintainable
|
||||
|
||||
use strict;
|
||||
use warnings;
|
||||
|
||||
# ( { source => <file> name => ... value => ...}, { comment => ...}, ... )
|
||||
my @lines;
|
||||
# references into the @lines array
|
||||
my %variables;
|
||||
|
||||
sub store_var {
|
||||
my ($file, $line, $name, $value) = @_;
|
||||
|
||||
if (exists($variables{$name})) {
|
||||
if ($variables{$name}->{source} eq $file) {
|
||||
print STDERR "$file:$line: warning: $name redefined\n";
|
||||
}
|
||||
} else {
|
||||
my $new = {};
|
||||
push(@lines, $new);
|
||||
$variables{$name} = $new;
|
||||
}
|
||||
$variables{$name}->{source} = $file;
|
||||
$variables{$name}->{name} = $name;
|
||||
$variables{$name}->{value} = $value;
|
||||
}
|
||||
|
||||
sub store_comment {
|
||||
my ($comment) = @_;
|
||||
|
||||
push(@lines, { comment => $comment });
|
||||
}
|
||||
|
||||
while (<>) {
|
||||
chomp;
|
||||
if (/^CONFIG_(\w+)=(.*)/) {
|
||||
store_var($ARGV, $., $1, $2);
|
||||
} elsif (/^# CONFIG_(\w+) is not set/) {
|
||||
store_var($ARGV, $., $1, 'n');
|
||||
} elsif (/^$|^#/) {
|
||||
store_comment($_);
|
||||
} else {
|
||||
print STDERR "$ARGV:$.: warning: ignoring unknown line\n";
|
||||
}
|
||||
}
|
||||
|
||||
for my $line (@lines) {
|
||||
if (exists($line->{comment})) {
|
||||
print "$line->{comment}\n";
|
||||
} elsif ($line->{value} eq 'n') {
|
||||
print "# CONFIG_$line->{name} is not set\n";
|
||||
} else {
|
||||
print "CONFIG_$line->{name}=$line->{value}\n";
|
||||
}
|
||||
}
|
16
devel-post.sh
Normal file
16
devel-post.sh
Normal file
@ -0,0 +1,16 @@
|
||||
relink() {
|
||||
if [ -h "$2" ]; then
|
||||
local old=$(readlink "$2")
|
||||
[ "$old" = "$1" ] && return 0
|
||||
echo "Changing symlink $2 from $old to $1"
|
||||
elif [ -e "$2" ]; then
|
||||
echo "Replacing file $2 with symlink to $1"
|
||||
fi
|
||||
rm -f "$2" \
|
||||
&& ln -s "$1" "$2"
|
||||
}
|
||||
|
||||
release="@KERNELRELEASE@@SRCVARIANT@-obj"
|
||||
arch_flavor="@CPU_ARCH_FLAVOR@"
|
||||
|
||||
relink ../../linux-$release/"$arch_flavor" /usr/src/linux-obj/"$arch_flavor"
|
4
devel-pre.sh
Normal file
4
devel-pre.sh
Normal file
@ -0,0 +1,4 @@
|
||||
# handle update from an older kernel-source with linux-obj as symlink
|
||||
if [ -h /usr/src/linux-obj ]; then
|
||||
rm -vf /usr/src/linux-obj
|
||||
fi
|
18
find-provides
Normal file
18
find-provides
Normal file
@ -0,0 +1,18 @@
|
||||
#! /bin/bash
|
||||
|
||||
trap 'rm -f "$filelist"' EXIT
|
||||
filelist=$(mktemp -t ${0##*/}.XXXXXXXXXX)
|
||||
grep -v '/kernel/drivers/staging/.*\.ko$' >"$filelist"
|
||||
shopt -s nullglob
|
||||
|
||||
# pretend that /boot/vmlinux-* is in the -base package and not in -devel
|
||||
if grep -q '/boot/System\.map\>' "$filelist"; then
|
||||
prefix=$(sed -rn 's:(.*)/boot/System\.map\>.*:\1:p; T; q' "$filelist")
|
||||
for f in "$prefix"/boot/vmlinux*; do
|
||||
echo "$f" >>"$filelist"
|
||||
done
|
||||
else
|
||||
perl -ni -e 'next if /\/boot\/vmlinux/ && !/\.debug$/; print' "$filelist"
|
||||
fi
|
||||
|
||||
/usr/lib/rpm/find-provides "$@" <"$filelist"
|
82
group-source-files.pl
Normal file
82
group-source-files.pl
Normal file
@ -0,0 +1,82 @@
|
||||
#!/usr/bin/perl
|
||||
|
||||
use Getopt::Long;
|
||||
use strict;
|
||||
|
||||
&main();
|
||||
sub main
|
||||
{
|
||||
my($dev_output, $ndev_output, $loc) = ("-", "-", ".");
|
||||
&Getopt::Long::Configure(qw(bundling));
|
||||
&GetOptions(
|
||||
"D=s" => \$dev_output,
|
||||
"N=s" => \$ndev_output,
|
||||
"L=s" => \$loc,
|
||||
);
|
||||
|
||||
my($dev, $ndev) = &scan($loc);
|
||||
&output($dev, $ndev, $dev_output, $ndev_output);
|
||||
}
|
||||
|
||||
sub scan
|
||||
{
|
||||
my $loc = shift @_;
|
||||
my(@dev, @ndev);
|
||||
|
||||
foreach $_ (`find "$loc"`)
|
||||
{
|
||||
chomp $_;
|
||||
if (!-f $_) {
|
||||
# Generate directory list later.
|
||||
next;
|
||||
}
|
||||
my $is_devel =
|
||||
m{^\Q$loc\E.*/Kconfig} ||
|
||||
m{^\Q$loc\E.*/Kbuild} ||
|
||||
m{^\Q$loc\E.*/Makefile} ||
|
||||
m{^\Q$loc\E/arch/[^/]+/include\b} ||
|
||||
m{^\Q$loc\E/include/[^/]+\b} ||
|
||||
m{^\Q$loc\E/scripts\b};
|
||||
if (substr($_, 0, 1) ne "/") {
|
||||
# We cannot use an absolute path during find,
|
||||
# but rpm wants one later.
|
||||
$_ = "/$_";
|
||||
}
|
||||
$is_devel ? push(@dev, $_) : push(@ndev, $_);
|
||||
}
|
||||
|
||||
push(@dev, &calc_dirs("/$loc", \@dev));
|
||||
push(@ndev, &calc_dirs("/$loc", \@ndev));
|
||||
return (\@dev, \@ndev);
|
||||
}
|
||||
|
||||
sub calc_dirs
|
||||
{
|
||||
my($base, $files) = @_;
|
||||
my %dirs;
|
||||
|
||||
foreach my $file (@$files) {
|
||||
my $path = $file;
|
||||
do {
|
||||
$path =~ s{/[^/]+$}{};
|
||||
$dirs{$path} = 1;
|
||||
} while ($path ne $base);
|
||||
# This loop also makes sure that $base itself is included.
|
||||
}
|
||||
|
||||
return map { "\%dir $_" } keys %dirs;
|
||||
}
|
||||
|
||||
sub output
|
||||
{
|
||||
my($dev, $ndev, $dev_out, $ndev_out) = @_;
|
||||
local *FH;
|
||||
|
||||
open(FH, "> $dev_out") || warn "Error writing to $dev_out: $!";
|
||||
print FH join("\n", @$dev), "\n";
|
||||
close FH;
|
||||
|
||||
open(FH, "> $ndev_out") || warn "Error writing to $ndev_out: $!";
|
||||
print FH join("\n", @$ndev), "\n";
|
||||
close FH;
|
||||
}
|
305
guards
Normal file
305
guards
Normal file
@ -0,0 +1,305 @@
|
||||
#!/usr/bin/perl -w
|
||||
#############################################################################
|
||||
# Copyright (c) 2003-2007,2009 Novell, Inc.
|
||||
# All Rights Reserved.
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of version 2 of the GNU General Public License as
|
||||
# published by the Free Software Foundation.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, contact Novell, Inc.
|
||||
#
|
||||
# To contact Novell about this file by physical or electronic mail,
|
||||
# you may find current contact information at www.novell.com
|
||||
#############################################################################
|
||||
#
|
||||
# Guards:
|
||||
#
|
||||
# +xxx include if xxx is defined
|
||||
# -xxx exclude if xxx is defined
|
||||
# +!xxx include if xxx is not defined
|
||||
# -!xxx exclude if xxx is not defined
|
||||
#
|
||||
|
||||
use FileHandle;
|
||||
use Getopt::Long;
|
||||
use strict;
|
||||
|
||||
# Prototypes
|
||||
sub files_in($$);
|
||||
sub parse($$);
|
||||
sub help();
|
||||
|
||||
#sub strip_ext($) {
|
||||
# local ($_) = @_;
|
||||
# s/\.(diff?|patch)$//;
|
||||
#}
|
||||
|
||||
#sub try_ext($) {
|
||||
# my ($path) = @_;
|
||||
# for my $p in (($path, "$path.diff", "$path.dif", "$path.patch")) {
|
||||
# return $p
|
||||
# if (-f $p);
|
||||
# }
|
||||
# return undef;
|
||||
#}
|
||||
|
||||
sub slashme($) {
|
||||
my ($dir) = @_;
|
||||
$dir =~ s#([^/])$#$&/#; # append a slash if necessary
|
||||
if ($dir eq './') {
|
||||
return '';
|
||||
} else {
|
||||
return $dir;
|
||||
}
|
||||
}
|
||||
|
||||
# Generate a list of files in a directory
|
||||
#
|
||||
sub files_in($$) {
|
||||
my ($dir, $path) = @_;
|
||||
my $dh = new FileHandle;
|
||||
my (@files, $file);
|
||||
|
||||
|
||||
opendir $dh, length("$dir$path") ? "$dir$path" : '.'
|
||||
or die "$dir$path: $!\n";
|
||||
while ($file = readdir($dh)) {
|
||||
next if $file =~ /^(\.|\.\.|\.#.*|CVS|.*~)$/;
|
||||
if (-d "$dir$path$file") {
|
||||
@files = (@files, files_in($dir, "$path$file/"));
|
||||
} else {
|
||||
#print "[$path$file]\n";
|
||||
push @files, "$path$file";
|
||||
}
|
||||
}
|
||||
closedir $dh;
|
||||
return @files;
|
||||
}
|
||||
|
||||
# Parse a configuration file
|
||||
# Callback called with ($patch, @guards) arguments
|
||||
#
|
||||
sub parse($$) {
|
||||
my ($fh, $callback) = @_;
|
||||
|
||||
my $line = "";
|
||||
|
||||
while (<$fh>) {
|
||||
chomp;
|
||||
s/(^|\s+)#.*//;
|
||||
if (s/\\$/ /) {
|
||||
$line .= $_;
|
||||
next;
|
||||
}
|
||||
$line .= $_;
|
||||
my @guards = ();
|
||||
foreach my $token (split /[\s\t\n]+/, $line) {
|
||||
next if $token eq "";
|
||||
if ($token =~ /^[-+]/) {
|
||||
push @guards, $token;
|
||||
} else {
|
||||
#print "[" . join(",", @guards) . "] $token\n";
|
||||
&$callback($token, @guards);
|
||||
}
|
||||
}
|
||||
$line = "";
|
||||
}
|
||||
}
|
||||
|
||||
# Command line options
|
||||
#
|
||||
my ($dir, $config, $default, $check, $list, $invert_match, $with_guards) =
|
||||
( '', '-', 1, 0, 0, 0, 0);
|
||||
my @path;
|
||||
|
||||
# Help text
|
||||
#
|
||||
sub help() {
|
||||
print "$0 - select from a list of files guarded by conditions\n";
|
||||
print "SYNOPSIS: $0 [--prefix=dir] [--path=dir1:dir2:...]\n" .
|
||||
" [--default=0|1] [--check|--list] [--invert-match]\n" .
|
||||
" [--with-guards] [--config=file] symbol ...\n\n" .
|
||||
" (Default values: --path='" . join(':', @path) . "', " .
|
||||
"--default=$default)\n";
|
||||
exit 0;
|
||||
}
|
||||
|
||||
# Parse command line options
|
||||
#
|
||||
Getopt::Long::Configure ("bundling");
|
||||
eval {
|
||||
unless (GetOptions (
|
||||
'd|prefix=s' => \$dir,
|
||||
'c|config=s' => \$config,
|
||||
'C|check' => \$check,
|
||||
'l|list' => \$list,
|
||||
'w|with-guards' => \$with_guards,
|
||||
'p|path=s' => \@path,
|
||||
'D|default=i' => \$default,
|
||||
'v|invert-match' => \$invert_match,
|
||||
'h|help' => sub { help(); exit 0; })) {
|
||||
help();
|
||||
exit 1;
|
||||
}
|
||||
};
|
||||
if ($@) {
|
||||
print "$@";
|
||||
help();
|
||||
exit 1;
|
||||
}
|
||||
|
||||
@path = ('.')
|
||||
unless (@path);
|
||||
@path = split(/:/, join(':', @path));
|
||||
|
||||
my $fh = ($config eq '-') ? \*STDIN : new FileHandle($config)
|
||||
or die "$config: $!\n";
|
||||
|
||||
$dir = slashme($dir);
|
||||
|
||||
if ($check) {
|
||||
# Check for duplicate files, or for files that are not referenced by
|
||||
# the specification.
|
||||
|
||||
my $problems = 0;
|
||||
my @files;
|
||||
|
||||
foreach (@path) {
|
||||
@files = (@files, files_in($dir, slashme($_)));
|
||||
}
|
||||
my %files = map { $_ => 0 } @files;
|
||||
|
||||
parse($fh, sub {
|
||||
my ($patch, @guards) = @_;
|
||||
if (exists $files{$patch}) {
|
||||
$files{$patch}++;
|
||||
} else {
|
||||
print "Not found: $dir$patch\n";
|
||||
$problems++;
|
||||
}});
|
||||
|
||||
$fh->close();
|
||||
|
||||
my ($file, $ref);
|
||||
while (($file, $ref) = each %files) {
|
||||
next if $ref == 1;
|
||||
|
||||
if ($ref == 0) {
|
||||
print "Unused: $file\n" if $ref == 0;
|
||||
$problems++;
|
||||
}
|
||||
if ($ref > 1) {
|
||||
print "Warning: multiple uses: $file\n" if $ref > 1;
|
||||
# This is not an error if the entries are mutually exclusive...
|
||||
}
|
||||
}
|
||||
exit $problems ? 1 : 0;
|
||||
|
||||
} elsif ($list) {
|
||||
parse($fh, sub {
|
||||
my ($patch, @guards) = @_;
|
||||
print join(' ', @guards), ' '
|
||||
if (@guards && $with_guards);
|
||||
print "$dir$patch\n";
|
||||
});
|
||||
} else {
|
||||
# Generate a list of patches to apply.
|
||||
|
||||
my %symbols = map { $_ => 1 } @ARGV;
|
||||
|
||||
parse($fh, sub {
|
||||
my ($patch, @guards) = @_;
|
||||
|
||||
my $selected;
|
||||
if (@guards) {
|
||||
# If the first guard is -xxx, the patch is included by default;
|
||||
# if it is +xxx, the patch is excluded by default.
|
||||
$selected = ($guards[0] =~ /^-/);
|
||||
|
||||
foreach (@guards) {
|
||||
/^([-+])(!?)(.*)?/
|
||||
or die "Bad guard '$_'\n";
|
||||
|
||||
# Check if the guard matches
|
||||
if (($2 eq '!' && !exists $symbols{$3}) ||
|
||||
($2 eq '' && ( $3 eq '' || exists $symbols{$3}))) {
|
||||
# Include or exclude
|
||||
$selected = ($1 eq '+');
|
||||
}
|
||||
}
|
||||
} else {
|
||||
# If there are no guards, use the specified default result.
|
||||
$selected = $default;
|
||||
}
|
||||
|
||||
print "$dir$patch\n"
|
||||
if $selected ^ $invert_match;
|
||||
});
|
||||
|
||||
$fh->close();
|
||||
|
||||
exit 0;
|
||||
}
|
||||
|
||||
__END__
|
||||
|
||||
=head1 NAME
|
||||
|
||||
guards - select from a list of files guarded by conditions
|
||||
|
||||
=head1 SYNOPSIS
|
||||
|
||||
F<guards> [--prefix=F<dir>] [--path=F<dir1:dir2:...>] [--default=<0|1>]
|
||||
[--check|--list] [--invert-match] [--with-guards] [--config=<file>]
|
||||
I<symbol> ...
|
||||
|
||||
|
||||
=head1 DESCRIPTION
|
||||
|
||||
The script reads a configuration file that may contain so-called guards, file
|
||||
names, and comments, and writes those file names that satisfy all guards to
|
||||
standard output. The script takes a list of symbols as its arguments. Each line
|
||||
in the configuration file is processed separately. Lines may start with a
|
||||
number of guards. The following guards are defined:
|
||||
|
||||
=over
|
||||
|
||||
+I<xxx> Include the file(s) on this line if the symbol I<xxx> is defined.
|
||||
|
||||
-I<xxx> Exclude the file(s) on this line if the symbol I<xxx> is defined.
|
||||
|
||||
+!I<xxx> Include the file(s) on this line if the symbol I<xxx> is not defined.
|
||||
|
||||
-!I<xxx> Exclude the file(s) on this line if the symbol I<xxx> is not defined.
|
||||
|
||||
- Exclude this file. Used to avoid spurious I<--check> messages.
|
||||
|
||||
=back
|
||||
|
||||
The guards are processed left to right. The last guard that matches determines
|
||||
if the file is included. If no guard is specified, the I<--default>
|
||||
setting determines if the file is included.
|
||||
|
||||
If no configuration file is specified, the script reads from standard input.
|
||||
|
||||
The I<--check> option is used to compare the specification file against the
|
||||
file system. If files are referenced in the specification that do not exist, or
|
||||
if files are not enlisted in the specification file warnings are printed. The
|
||||
I<--path> option can be used to specify which directory or directories to scan.
|
||||
Multiple directories are eparated by a colon (C<:>) character. The
|
||||
I<--prefix> option specifies the location of the files.
|
||||
|
||||
Use I<--list> to list all files independend of any rules. Use I<--invert-match>
|
||||
to list only the excluded patches. Use I<--with-guards> to also include all
|
||||
inclusion and exclusion rules.
|
||||
|
||||
=head1 AUTHOR
|
||||
|
||||
Andreas Gruenbacher <agruen@suse.de>, SUSE Labs
|
7
host-memcpy-hack.h
Normal file
7
host-memcpy-hack.h
Normal file
@ -0,0 +1,7 @@
|
||||
#ifdef __x86_64__
|
||||
/*
|
||||
* Force the linker to use the older memcpy variant, so that the user programs
|
||||
* work on older systems
|
||||
*/
|
||||
__asm__(".symver memcpy,memcpy@GLIBC_2.2.5");
|
||||
#endif
|
131
kabi.pl
Normal file
131
kabi.pl
Normal file
@ -0,0 +1,131 @@
|
||||
#!/usr/bin/perl
|
||||
use strict;
|
||||
use warnings;
|
||||
|
||||
use Getopt::Long;
|
||||
use Data::Dumper;
|
||||
|
||||
# ( { sym => regexp, mod => regexp, fail => 0/1 }, ... )
|
||||
my @rules;
|
||||
my ($opt_verbose, $opt_rules);
|
||||
|
||||
sub load_rules {
|
||||
my $file = shift;
|
||||
my $errors = 0;
|
||||
|
||||
xopen(my $fh, '<', $file);
|
||||
while (<$fh>) {
|
||||
chomp;
|
||||
s/#.*//;
|
||||
next if /^\s*$/;
|
||||
my ($pattern, $verdict) = split(/\s+/);
|
||||
my $new = {};
|
||||
if (uc($verdict) eq "PASS") {
|
||||
$new->{fail} = 0;
|
||||
} elsif (uc($verdict) eq "FAIL") {
|
||||
$new->{fail} = 1;
|
||||
} else {
|
||||
print STDERR "$file:$.: invalid verdict \"$verdict\", must be either PASS or FAIL.\n";
|
||||
$errors++;
|
||||
next;
|
||||
}
|
||||
# simple glob -> regexp conversion
|
||||
$pattern =~ s/\*/.*/g;
|
||||
$pattern =~ s/\?/./g;
|
||||
$pattern =~ s/.*/^$&\$/;
|
||||
if ($pattern =~ /\/|^vmlinux$/) {
|
||||
$new->{mod} = $pattern;
|
||||
} else {
|
||||
$new->{sym} = $pattern;
|
||||
}
|
||||
push(@rules, $new);
|
||||
}
|
||||
if ($errors && !@rules) {
|
||||
print STDERR "error: only garbage found in $file.\n";
|
||||
exit 1;
|
||||
}
|
||||
close($fh);
|
||||
}
|
||||
|
||||
sub load_symvers {
|
||||
my $file = shift;
|
||||
my %res;
|
||||
my $errors = 0;
|
||||
|
||||
xopen(my $fh, '<', $file);
|
||||
while (<$fh>) {
|
||||
my @l = split(/\s+/);
|
||||
if (@l < 3) {
|
||||
print STDERR "$file:$.: unknown line\n";
|
||||
$errors++;
|
||||
next;
|
||||
}
|
||||
my $new = { crc => $l[0], mod => $l[2] };
|
||||
$res{$l[1]} = $new;
|
||||
}
|
||||
if (!%res) {
|
||||
print STDERR "error: no symvers found in $file.\n";
|
||||
exit 1;
|
||||
}
|
||||
close($fh);
|
||||
return %res;
|
||||
}
|
||||
|
||||
my $kabi_errors = 0;
|
||||
sub kabi_change {
|
||||
my ($sym, $mod, $oldcrc, $newcrc) = @_;
|
||||
my $fail = 1;
|
||||
|
||||
for my $rule (@rules) {
|
||||
if ($rule->{mod} && $mod =~ $rule->{mod} ||
|
||||
$rule->{sym} && $sym =~ $rule->{sym}) {
|
||||
$fail = $rule->{fail};
|
||||
last;
|
||||
}
|
||||
}
|
||||
return unless $fail or $opt_verbose;
|
||||
print STDERR "KABI: symbol $sym($mod) ";
|
||||
if ($newcrc) {
|
||||
print STDERR "changed crc from $oldcrc to $newcrc"
|
||||
} else {
|
||||
print STDERR "lost";
|
||||
}
|
||||
if ($fail) {
|
||||
$kabi_errors++;
|
||||
print STDERR "\n";
|
||||
} else {
|
||||
print STDERR " (tolerated)\n";
|
||||
}
|
||||
}
|
||||
|
||||
sub xopen {
|
||||
open($_[0], $_[1], @_[2..$#_]) or die "$_[2]: $!\n";
|
||||
}
|
||||
|
||||
my $res = GetOptions(
|
||||
'verbose|v' => \$opt_verbose,
|
||||
'rules|r=s' => \$opt_rules,
|
||||
);
|
||||
if (!$res || @ARGV != 2) {
|
||||
print STDERR "Usage: $0 [--rules <rules file>] Module.symvers.old Module.symvers\n";
|
||||
exit 1;
|
||||
}
|
||||
if (defined($opt_rules)) {
|
||||
load_rules($opt_rules);
|
||||
}
|
||||
my %old = load_symvers($ARGV[0]);
|
||||
my %new = load_symvers($ARGV[1]);
|
||||
|
||||
for my $sym (sort keys(%old)) {
|
||||
if (!$new{$sym}) {
|
||||
kabi_change($sym, $old{$sym}->{mod}, $old{$sym}->{crc}, 0);
|
||||
} elsif ($old{$sym}->{crc} ne $new{$sym}->{crc}) {
|
||||
kabi_change($sym, $new{$sym}->{mod}, $old{$sym}->{crc},
|
||||
$new{$sym}->{crc});
|
||||
}
|
||||
}
|
||||
if ($kabi_errors) {
|
||||
print STDERR "KABI: aborting due to kabi changes.\n";
|
||||
exit 1;
|
||||
}
|
||||
exit 0;
|
3
kabi.tar.bz2
Normal file
3
kabi.tar.bz2
Normal file
@ -0,0 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:59d268a3fba95a4822be04a478e75c6875671e730955f3f7da59caccad496e28
|
||||
size 426
|
800
kernel-binary.spec.in
Normal file
800
kernel-binary.spec.in
Normal file
@ -0,0 +1,800 @@
|
||||
#
|
||||
# spec file for package kernel-@FLAVOR@ (Version @RPMVERSION@)
|
||||
#
|
||||
# Copyright (c) 2009 SUSE LINUX Products GmbH, Nuernberg, Germany.
|
||||
#
|
||||
# All modifications and additions to the file contributed by third parties
|
||||
# remain the property of their copyright owners, unless otherwise agreed
|
||||
# upon. The license for this file, and modifications and additions to the
|
||||
# file, is the same license as for the pristine package itself (unless the
|
||||
# license for the pristine package is not an Open Source License, in which
|
||||
# case the license is the MIT License). An "Open Source License" is a
|
||||
# license that conforms to the Open Source Definition (Version 1.9)
|
||||
# published by the Open Source Initiative.
|
||||
|
||||
# Please submit bugfixes or comments via http://bugs.opensuse.org/
|
||||
#
|
||||
|
||||
# norootforbuild
|
||||
|
||||
%define srcversion @SRCVERSION@
|
||||
%define patchversion @PATCHVERSION@
|
||||
%define variant @VARIANT@%{nil}
|
||||
|
||||
%include %_sourcedir/kernel-spec-macros
|
||||
|
||||
%define build_flavor @FLAVOR@
|
||||
%define build_kdump (%build_flavor == "kdump")
|
||||
%define build_xen (%build_flavor == "xen" || %build_flavor == "ec2")
|
||||
%define build_vanilla (%build_flavor == "vanilla")
|
||||
%define build_ps3 (%build_flavor == "ps3")
|
||||
|
||||
%define build_src_dir %my_builddir/linux-%srcversion
|
||||
%define src_install_dir /usr/src/linux-%kernelrelease%variant
|
||||
%define obj_install_dir %src_install_dir-obj
|
||||
%define rpm_install_dir %buildroot%obj_install_dir
|
||||
%define kernel_build_dir %my_builddir/linux-obj
|
||||
|
||||
%(chmod +x %_sourcedir/{@SCRIPTS@})
|
||||
|
||||
%global cpu_arch %(%_sourcedir/arch-symbols %_target_cpu)
|
||||
%define cpu_arch_flavor %cpu_arch/%build_flavor
|
||||
|
||||
# Define some CONFIG variables as rpm macros as well. (rpm cannot handle
|
||||
# defining them all at once.)
|
||||
%define config_vars CONFIG_MODULES CONFIG_KMSG_IDS CONFIG_SPLIT_PACKAGE CONFIG_ENTERPRISE_SUPPORT
|
||||
%{expand:%(eval "$(test -n "%cpu_arch_flavor" && tar -xjf %_sourcedir/config.tar.bz2 --to-stdout config/%cpu_arch_flavor)"; for config in %config_vars; do echo "%%global $config ${!config:-n}"; done)}
|
||||
%define split_base (%CONFIG_SPLIT_PACKAGE == "y")
|
||||
%define split_extra (%CONFIG_SPLIT_PACKAGE == "y" && %CONFIG_ENTERPRISE_SUPPORT == "y")
|
||||
|
||||
%ifarch %ix86 x86_64
|
||||
%define install_vdso 1
|
||||
%else
|
||||
%define install_vdso 0
|
||||
%endif
|
||||
|
||||
Name: kernel-@FLAVOR@
|
||||
Summary: @SUMMARY@
|
||||
Version: @RPMVERSION@
|
||||
%if %using_buildservice
|
||||
Release: @RELEASE_PREFIX@<RELEASE>
|
||||
%else
|
||||
Release: @RELEASE_PREFIX@0
|
||||
%endif
|
||||
License: GPL v2 only
|
||||
Group: System/Kernel
|
||||
Url: http://www.kernel.org/
|
||||
AutoReqProv: on
|
||||
BuildRequires: coreutils module-init-tools sparse
|
||||
BuildRequires: fdupes
|
||||
Provides: multiversion(kernel)
|
||||
Provides: %{name}_%_target_cpu = %version-%release
|
||||
Provides: %name = %version-%source_rel
|
||||
%if %split_base
|
||||
Provides: kernel-base = %version-%source_rel
|
||||
# Obsolete the -base subpackage from 11.1 and 11.2 development phase
|
||||
Obsoletes: %name-base <= 2.6.31
|
||||
%endif
|
||||
Requires(pre): coreutils awk
|
||||
# Need a module-init-tools with /usr/lib/module-init-tools/weak-modules2
|
||||
Requires(post): module-init-tools >= 3.4
|
||||
# This Requires is wrong, because the post/postun scripts have a
|
||||
# test -x update-bootloader, having perl-Bootloader is not a hard requirement.
|
||||
# But, there is no way to tell rpm or yast to schedule the installation
|
||||
# of perl-Bootloader before kernel-binary.rpm if both are in the list of
|
||||
# packages to install/update. Likewise, this is true for mkinitrd.
|
||||
# Need a perl-Bootloader with /usr/lib/bootloader/bootloader_entry
|
||||
Requires(post): perl-Bootloader >= 0.4.15
|
||||
Requires(post): mkinitrd
|
||||
# Do not install p-b and mkinitrd for the install check, the %post script is
|
||||
# able to handle this
|
||||
#!BuildIgnore: perl-Bootloader mkinitrd
|
||||
# Remove some packages that are installed automatically by the build system,
|
||||
# but are not needed to build the kernel
|
||||
#!BuildIgnore: autoconf automake gettext-runtime libtool cvs gettext-tools m4 udev fillup insserv
|
||||
|
||||
%ifarch ia64
|
||||
# arch/ia64/scripts/unwcheck.py
|
||||
BuildRequires: python
|
||||
%endif
|
||||
%ifarch s390 s390x
|
||||
%if %build_vanilla && 0%{?suse_version} < 1130
|
||||
BuildRequires: dwarfextract
|
||||
%endif
|
||||
%endif
|
||||
%if %build_xen
|
||||
%ifarch %ix86
|
||||
%if %build_flavor != "ec2"
|
||||
Provides: kernel-xenpae = %version
|
||||
Obsoletes: kernel-xenpae <= %version
|
||||
%endif
|
||||
%endif
|
||||
#!BuildIgnore: xen
|
||||
%endif
|
||||
|
||||
Provides: %name-nongpl
|
||||
Obsoletes: %name-nongpl
|
||||
%if %build_vanilla
|
||||
# force bzip2 instead of lzma compression to allow install on older dist versions
|
||||
%define _binary_payload w9.bzdio
|
||||
%endif
|
||||
# dead network if installed on SLES10, otherwise it will work (mostly)
|
||||
Conflicts: sysfsutils < 2.0
|
||||
%if ! %build_vanilla
|
||||
Conflicts: apparmor-profiles <= 2.1
|
||||
Conflicts: apparmor-parser < 2.3
|
||||
# root-lvm only works with newer udevs
|
||||
Conflicts: udev < 118
|
||||
Conflicts: lvm2 < 2.02.33
|
||||
%endif
|
||||
%ifarch %ix86
|
||||
Conflicts: libc.so.6()(64bit)
|
||||
%endif
|
||||
Provides: kernel = %version-%source_rel
|
||||
@PROVIDES_OBSOLETES@
|
||||
@SOURCES@
|
||||
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
||||
ExclusiveArch: @ARCHS@
|
||||
|
||||
# These files are found in the kernel-source package:
|
||||
@NOSOURCE@
|
||||
|
||||
# The following KMPs have been integrated into the kernel package,
|
||||
# grouped by the last product that contained them.
|
||||
# sles10 / 10.3
|
||||
Obsoletes: iwlwifi-kmp-%build_flavor
|
||||
Obsoletes: ipw3945-kmp-%build_flavor
|
||||
# sles10 / 11.0
|
||||
Obsoletes: uvcvideo-kmp-%build_flavor
|
||||
# 11.0
|
||||
Obsoletes: atl2-kmp-%build_flavor
|
||||
Obsoletes: wlan-ng-kmp-%build_flavor
|
||||
Obsoletes: et131x-kmp-%build_flavor
|
||||
Obsoletes: ivtv-kmp-%build_flavor
|
||||
Obsoletes: at76_usb-kmp-%build_flavor
|
||||
Obsoletes: pcc-acpi-kmp-%build_flavor
|
||||
Obsoletes: btusb-kmp-%build_flavor
|
||||
# sle11-ga
|
||||
Obsoletes: enic-kmp-%build_flavor
|
||||
Obsoletes: fnic-kmp-%build_flavor
|
||||
Obsoletes: brocade-bfa-kmp-%build_flavor
|
||||
Obsoletes: kvm-kmp-%build_flavor
|
||||
Obsoletes: perfmon-kmp-%build_flavor
|
||||
Obsoletes: iwlagn-2-6-27-kmp-%build_flavor
|
||||
Obsoletes: msi-wmi-kmp-%build_flavor
|
||||
# sle11
|
||||
Obsoletes: ocfs2-kmp-%build_flavor
|
||||
# 11.1
|
||||
Obsoletes: quickcam-kmp-%build_flavor < 0.6.7
|
||||
|
||||
# Provide the exported symbols as "ksym(symbol) = hash"
|
||||
%define __find_provides %_sourcedir/find-provides %name
|
||||
|
||||
# Will modules not listed in supported.conf abort the kernel build (0/1)?
|
||||
%define supported_modules_check 0
|
||||
|
||||
%description
|
||||
@DESCRIPTION@
|
||||
|
||||
%source_timestamp
|
||||
|
||||
%prep
|
||||
if ! [ -e %_sourcedir/linux-%srcversion.tar.bz2 ]; then
|
||||
echo "The %name-%version.nosrc.rpm package does not contain the" \
|
||||
"complete sources. Please install kernel-source-%version.src.rpm."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
SYMBOLS=
|
||||
if test -e %_sourcedir/extra-symbols; then
|
||||
SYMBOLS=$(cat %_sourcedir/extra-symbols)
|
||||
echo "extra symbol(s):" $SYMBOLS
|
||||
fi
|
||||
|
||||
# Unpack all sources and patches
|
||||
%setup -q -c -T -a 0 @UNPACK_PATCHES@
|
||||
|
||||
mkdir -p %kernel_build_dir
|
||||
|
||||
supported_conf() {
|
||||
%_sourcedir/guards $* < %_sourcedir/supported.conf | \
|
||||
sed 's,.*/,,; s,\.ko$,,' | sort -u
|
||||
}
|
||||
|
||||
# Generate the list of modules to be marked as supported
|
||||
{ supported_conf base
|
||||
supported_conf --default=0 external | sed 's/$/ external/'
|
||||
} > %kernel_build_dir/Module.supported
|
||||
supported_conf --default=0 base >%kernel_build_dir/Module.base
|
||||
|
||||
cd linux-%srcversion
|
||||
|
||||
%_sourcedir/apply-patches \
|
||||
%if %{build_vanilla}
|
||||
--vanilla \
|
||||
%endif
|
||||
%_sourcedir/series.conf .. $SYMBOLS
|
||||
|
||||
cd %kernel_build_dir
|
||||
|
||||
# Override the timestamp 'uname -v' reports with the source timestamp and
|
||||
# the commit hash.
|
||||
date=$(head -n 1 %_sourcedir/source-timestamp)
|
||||
commit=$(sed -n 's/GIT Revision: //p' %_sourcedir/source-timestamp)
|
||||
cat > .kernel-binary.spec.buildenv <<EOF
|
||||
export KBUILD_BUILD_TIMESTAMP="$(LANG=C date -d "$date") (${commit:0:7})"
|
||||
export KBUILD_VERBOSE=0
|
||||
export KBUILD_SYMTYPES=1
|
||||
export KBUILD_OVERRIDE=1
|
||||
export KBUILD_BUILD_USER=geeko
|
||||
export KBUILD_BUILD_HOST=buildhost
|
||||
export HOST_EXTRACFLAGS="-include %_sourcedir/host-memcpy-hack.h"
|
||||
EOF
|
||||
source .kernel-binary.spec.buildenv
|
||||
|
||||
if [ -f %_sourcedir/localversion ] ; then
|
||||
cat %_sourcedir/localversion > localversion
|
||||
fi
|
||||
|
||||
if test -e ../config.addon/%cpu_arch_flavor; then
|
||||
# FIXME: config.addon doesn't affect the %CONFIG_ macros defined at
|
||||
# the top of the specfile
|
||||
%_sourcedir/configtool.pl ../config{,.addon}/%cpu_arch_flavor >.config
|
||||
else
|
||||
cp ../config/%cpu_arch_flavor .config
|
||||
fi
|
||||
%build_src_dir/scripts/config \
|
||||
--set-str CONFIG_LOCALVERSION %release_num-%build_flavor \
|
||||
--enable CONFIG_SUSE_KERNEL \
|
||||
%if 0%{?__debug_package:1}
|
||||
--enable CONFIG_DEBUG_INFO \
|
||||
--disable CONFIG_DEBUG_INFO_REDUCED
|
||||
%else
|
||||
--disable CONFIG_DEBUG_INFO
|
||||
%endif
|
||||
|
||||
MAKE_ARGS="$MAKE_ARGS -C %build_src_dir O=$PWD"
|
||||
if test -e %_sourcedir/TOLERATE-UNKNOWN-NEW-CONFIG-OPTIONS; then
|
||||
yes '' | make oldconfig $MAKE_ARGS
|
||||
else
|
||||
cp .config .config.orig
|
||||
make silentoldconfig $MAKE_ARGS < /dev/null
|
||||
%_sourcedir/check-for-config-changes .config.orig .config
|
||||
rm .config.orig
|
||||
fi
|
||||
|
||||
make prepare $MAKE_ARGS
|
||||
make scripts $MAKE_ARGS
|
||||
krel=$(make -s kernelrelease $MAKE_ARGS)
|
||||
|
||||
if [ "$krel" != "%kernelrelease-%build_flavor" ]; then
|
||||
echo "Kernel release mismatch: $krel != %kernelrelease-%build_flavor" >&2
|
||||
exit 1
|
||||
fi
|
||||
|
||||
make clean $MAKE_ARGS
|
||||
|
||||
rm -f source
|
||||
find . ! -type d -printf '%%P\n' > %my_builddir/obj-files
|
||||
|
||||
%build
|
||||
cd %kernel_build_dir
|
||||
source .kernel-binary.spec.buildenv
|
||||
|
||||
# create *.symref files in the tree
|
||||
if test -e %my_builddir/kabi/%cpu_arch/symtypes-%build_flavor; then
|
||||
%_sourcedir/modversions --unpack . < $_
|
||||
fi
|
||||
|
||||
# The %{_smp_mflags} macro is defined to a number, make will spawn that many jobs.
|
||||
# There are several ways how to define it:
|
||||
# If you are using the build script:
|
||||
# build --jobs=N kernel-$flavor.spec
|
||||
# With plain rpmbuild:
|
||||
# rpmbuild -ba --define 'jobs N' kernel-$flavor.spec
|
||||
# To spawn as many jobs as there are cpu cores:
|
||||
# rpmbuild -ba --define "%_smp_mflags -j 0$(grep -Ec 'cpu[0-9]' /proc/stat)" \
|
||||
# kernel-$flavor.spec
|
||||
# You can also set this permanently in ~/.rpmmacros:
|
||||
# %_smp_mflags -j 0%(grep -Ec 'cpu[0-9]' /proc/stat)
|
||||
%if %CONFIG_KMSG_IDS == "y"
|
||||
chmod +x ../linux-%srcversion/scripts/kmsg-doc
|
||||
make %{?_smp_mflags} all $MAKE_ARGS CONFIG_DEBUG_SECTION_MISMATCH=y D=2
|
||||
%else
|
||||
make %{?_smp_mflags} all $MAKE_ARGS CONFIG_DEBUG_SECTION_MISMATCH=y
|
||||
%endif
|
||||
|
||||
|
||||
%install
|
||||
|
||||
# get rid of /usr/lib/rpm/brp-strip-debug
|
||||
# strip removes too much from the vmlinux ELF binary
|
||||
export NO_BRP_STRIP_DEBUG=true
|
||||
export STRIP_KEEP_SYMTAB='*/vmlinux-*'
|
||||
|
||||
# /lib/modules/%kernelrelease-%build_flavor/build will be a stale symlink until the
|
||||
# kernel-devel package is installed. Don't check for stale symlinks
|
||||
# in the brp-symlink check:
|
||||
export NO_BRP_STALE_LINK_ERROR=yes
|
||||
|
||||
cd %kernel_build_dir
|
||||
|
||||
mkdir -p %buildroot/boot
|
||||
# (Could strip out non-public symbols.)
|
||||
cp -p System.map %buildroot/boot/System.map-%kernelrelease-%build_flavor
|
||||
|
||||
add_vmlinux()
|
||||
{
|
||||
local vmlinux=boot/vmlinux-%kernelrelease-%build_flavor compressed=false
|
||||
|
||||
if test $1 == "--compressed"; then
|
||||
compressed=true
|
||||
fi
|
||||
cp vmlinux %buildroot/$vmlinux
|
||||
>%my_builddir/vmlinux.debug.files
|
||||
%if 0%{?__debug_package:1}
|
||||
if $compressed; then
|
||||
local vmlinux_debug=usr/lib/debug/$vmlinux.debug
|
||||
mkdir -p $(dirname %buildroot/$vmlinux_debug)
|
||||
/usr/lib/rpm/debugedit -b $RPM_BUILD_DIR -d /usr/src/debug \
|
||||
-l vmlinux.sourcefiles %buildroot/$vmlinux
|
||||
# FIXME: create and package build-id symlinks
|
||||
objcopy --only-keep-debug \
|
||||
%buildroot/$vmlinux \
|
||||
%buildroot/$vmlinux_debug || :
|
||||
objcopy --add-gnu-debuglink=%buildroot/$vmlinux_debug \
|
||||
--strip-debug \
|
||||
%buildroot/$vmlinux || :
|
||||
mkdir -p %buildroot/usr/src/debug
|
||||
LANG=C sort -z -u vmlinux.sourcefiles | grep -Ezv "<(built-in|stdin)>" \
|
||||
| ( cd %_builddir && cpio -pd0m %buildroot/usr/src/debug )
|
||||
find %buildroot/usr/src/debug -type d -print0 | xargs -0 -r chmod 0755
|
||||
find %buildroot/usr/src/debug -type f -print0 | xargs -0 -r chmod 0644
|
||||
echo -e "%%defattr(-, root, root)\\n/$vmlinux_debug" >%my_builddir/vmlinux.debug.files
|
||||
else
|
||||
# make vmlinux executable so that find-debuginfo.sh picks it up
|
||||
# (TODO: fix find-debuginfo.sh instead)
|
||||
chmod +x %buildroot/$vmlinux
|
||||
fi
|
||||
%endif
|
||||
if $compressed; then
|
||||
gzip -n -9 %buildroot/$vmlinux
|
||||
chmod a-x %buildroot/$vmlinux.gz
|
||||
fi
|
||||
}
|
||||
|
||||
%if %build_kdump
|
||||
add_vmlinux
|
||||
image=vmlinux
|
||||
%else
|
||||
|
||||
# architecture specifics
|
||||
%ifarch %ix86 x86_64
|
||||
add_vmlinux --compressed
|
||||
%if %build_xen
|
||||
image=vmlinuz
|
||||
%else
|
||||
image=bzImage
|
||||
%endif
|
||||
cp -p arch/x86/boot/$image %buildroot/boot/vmlinuz-%kernelrelease-%build_flavor
|
||||
image=vmlinuz
|
||||
%endif
|
||||
%ifarch alpha
|
||||
add_vmlinux --compressed
|
||||
cp -p arch/alpha/boot/vmlinux.gz %buildroot/boot/vmlinuz-%kernelrelease-%build_flavor
|
||||
image=vmlinuz
|
||||
%endif
|
||||
%ifarch ppc ppc64
|
||||
add_vmlinux
|
||||
image=vmlinux
|
||||
%endif
|
||||
%ifarch ia64
|
||||
add_vmlinux --compressed
|
||||
mv %buildroot/boot/vmlinux-%kernelrelease-%build_flavor.gz \
|
||||
%buildroot/boot/vmlinuz-%kernelrelease-%build_flavor
|
||||
image=vmlinuz
|
||||
%endif
|
||||
%ifarch s390 s390x
|
||||
add_vmlinux --compressed
|
||||
cp -p arch/s390/boot/image %buildroot/boot/image-%kernelrelease-%build_flavor
|
||||
image=image
|
||||
if test -e arch/s390/boot/kerntypes.o; then
|
||||
cp -p arch/s390/boot/kerntypes.o %buildroot/boot/Kerntypes-%kernelrelease-%build_flavor
|
||||
elif test -x "$(which dwarfextract 2>/dev/null)"; then
|
||||
dwarfextract vmlinux %buildroot/boot/Kerntypes-%kernelrelease-%build_flavor || echo "dwarfextract failed ($?)"
|
||||
fi
|
||||
%if %CONFIG_KMSG_IDS == "y"
|
||||
mkdir -p %buildroot/usr/share/man/man9
|
||||
find man -name '*.9' -exec install -m 644 -D '{}' %buildroot/usr/share/man/man9/ ';'
|
||||
%endif
|
||||
%endif
|
||||
%ifarch sparc64
|
||||
add_vmlinux --compressed
|
||||
image=zImage
|
||||
cp -p arch/sparc/boot/$image %buildroot/boot/vmlinuz-%kernelrelease-%build_flavor
|
||||
image=vmlinux
|
||||
%endif
|
||||
|
||||
# end of build_kdump
|
||||
%endif
|
||||
|
||||
for sub in '-base' '' '-extra'; do
|
||||
case "$sub" in
|
||||
'-base' | '') base_package=1 ;;
|
||||
*) base_package=0 ;;
|
||||
esac
|
||||
for script in preun postun pre post devel-pre devel-post; do
|
||||
sed -e "s:@KERNELRELEASE@:%kernelrelease:g" \
|
||||
-e "s:@IMAGE@:$image:g" \
|
||||
-e "s:@FLAVOR""@:%build_flavor:g" \
|
||||
-e "s:@SUBPACKAGE@:%name$sub:g" \
|
||||
-e "s:@BASE_PACKAGE@:$base_package:g" \
|
||||
-e "s:@RPM_VERSION_RELEASE@:%version-%release:g" \
|
||||
-e "s:@RPM_TARGET_CPU@:%_target_cpu:g" \
|
||||
-e "s:@CPU_ARCH_FLAVOR@:%cpu_arch_flavor:g" \
|
||||
-e "s:@SRCVARIANT@:%variant:g" \
|
||||
%_sourcedir/$script.sh > %my_builddir/$script$sub.sh
|
||||
done
|
||||
done
|
||||
|
||||
|
||||
%if %build_kdump || %build_xen || %build_vanilla || %build_ps3
|
||||
# keep this -suffix list in sync with post.sh and postun.sh
|
||||
suffix=-%build_flavor
|
||||
%endif
|
||||
ln -s $image$suffix %buildroot/boot/$image$suffix
|
||||
ln -s initrd$suffix %buildroot/boot/initrd$suffix
|
||||
|
||||
cp -p .config %buildroot/boot/config-%kernelrelease-%build_flavor
|
||||
sysctl_file=%buildroot/boot/sysctl.conf-%kernelrelease-%build_flavor
|
||||
for file in %my_builddir/sysctl/{defaults,%cpu_arch/arch-defaults,%cpu_arch_flavor}; do
|
||||
if [ -f "$file" ]; then
|
||||
cat "$file"
|
||||
fi
|
||||
done | sed '1i # Generated file - do not edit.' >$sysctl_file
|
||||
if [ ! -s $sysctl_file ]; then
|
||||
rm $sysctl_file
|
||||
fi
|
||||
|
||||
%if %install_vdso
|
||||
# Install the unstripped vdso's that are linked in the kernel image
|
||||
make vdso_install $MAKE_ARGS INSTALL_MOD_PATH=%buildroot
|
||||
%endif
|
||||
|
||||
# Create a dummy initrd with roughly the size the real one will have.
|
||||
# That way, YaST will know that this package requires some additional
|
||||
# space in /boot.
|
||||
dd if=/dev/zero of=%buildroot/boot/initrd-%kernelrelease-%build_flavor \
|
||||
bs=1024 seek=2047 count=1
|
||||
|
||||
if [ %CONFIG_MODULES = y ]; then
|
||||
mkdir -p %rpm_install_dir/%cpu_arch_flavor
|
||||
mkdir -p %buildroot/usr/src/linux-obj/%cpu_arch
|
||||
ln -s %build_flavor %buildroot/usr/src/linux-obj/%cpu_arch_flavor
|
||||
|
||||
gzip -n -c9 < Module.symvers > %buildroot/boot/symvers-%kernelrelease-%build_flavor.gz
|
||||
|
||||
make modules_install $MAKE_ARGS INSTALL_MOD_PATH=%buildroot
|
||||
|
||||
if ! %_sourcedir/check-supported-list \
|
||||
%_sourcedir %buildroot/lib/modules/%kernelrelease-%build_flavor; then
|
||||
%if %supported_modules_check
|
||||
exit 1
|
||||
%endif
|
||||
echo "Consistency check error: please update supported.conf."
|
||||
fi
|
||||
|
||||
%ifarch s390 s390x
|
||||
if test -e arch/s390/boot/kerntypes.o; then
|
||||
:
|
||||
elif test -x "$(which dwarfextract 2>/dev/null)" -a \
|
||||
-f %buildroot/boot/Kerntypes-%kernelrelease-%build_flavor; then
|
||||
find %buildroot -name "*.ko" > kofiles.list
|
||||
dwarfextract %buildroot/boot/Kerntypes-%kernelrelease-%build_flavor -C kofiles.list || echo "dwarfextract failed ($?)"
|
||||
fi
|
||||
%endif
|
||||
|
||||
# Also put the resulting file in %rpm_install_dir/%cpu_arch/%build_flavor
|
||||
# so that kernel-devel + kernel-%build_flavor is sufficient for building
|
||||
# modules that have modversions as well.
|
||||
mkdir -p %rpm_install_dir/%cpu_arch/%build_flavor
|
||||
cp Module.symvers %rpm_install_dir/%cpu_arch/%build_flavor
|
||||
|
||||
# Table of types used in exported symbols (for modversion debugging).
|
||||
%_sourcedir/modversions --pack . > %buildroot/boot/symtypes-%kernelrelease-%build_flavor
|
||||
if [ -s %buildroot/boot/symtypes-%kernelrelease-%build_flavor ]; then
|
||||
gzip -n -9 %buildroot/boot/symtypes-%kernelrelease-%build_flavor
|
||||
else
|
||||
rm -f %buildroot/boot/symtypes-%kernelrelease-%build_flavor
|
||||
fi
|
||||
|
||||
# Some architecture's $(uname -m) output is different from the ARCH
|
||||
# parameter that needs to be passed to kbuild. Create symlinks from
|
||||
# $(uname -m) to the ARCH directory.
|
||||
if [ ! -e %rpm_install_dir/%_target_cpu ]; then
|
||||
ln -sf %cpu_arch %rpm_install_dir/%_target_cpu
|
||||
ln -sf %cpu_arch %buildroot/usr/src/linux-obj/%_target_cpu
|
||||
fi
|
||||
|
||||
# We were building in %my_builddir/linux-%srcversion, but the sources will
|
||||
# later be installed in /usr/src/linux-%srcversion-%source_rel. Fix up the
|
||||
# build symlink.
|
||||
rm -f %buildroot/lib/modules/%kernelrelease-%build_flavor/{source,build}
|
||||
ln -s %src_install_dir \
|
||||
%buildroot/lib/modules/%kernelrelease-%build_flavor/source
|
||||
ln -s %obj_install_dir/%cpu_arch/%build_flavor \
|
||||
%buildroot/lib/modules/%kernelrelease-%build_flavor/build
|
||||
|
||||
# Abort if there are any undefined symbols
|
||||
msg="$(/sbin/depmod -F %buildroot/boot/System.map-%kernelrelease-%build_flavor \
|
||||
-b %buildroot -ae %kernelrelease-%build_flavor 2>&1)"
|
||||
if [ $? -ne 0 ] || echo "$msg" | grep 'needs unknown symbol'; then
|
||||
exit 1
|
||||
fi
|
||||
|
||||
%if %split_base
|
||||
%_sourcedir/split-modules -d %buildroot \
|
||||
-o %my_builddir \
|
||||
-b %kernel_build_dir/Module.base \
|
||||
%if ! %supported_modules_check
|
||||
-i \
|
||||
%endif
|
||||
-s %kernel_build_dir/Module.supported
|
||||
%if ! %split_extra
|
||||
cat %my_builddir/unsupported-modules >>%my_builddir/main-modules
|
||||
%endif
|
||||
|
||||
%else
|
||||
( cd %buildroot
|
||||
find lib/modules/%kernelrelease-%build_flavor -type f -name '*.ko' -printf '/%%p\n'
|
||||
) > %my_builddir/base-modules
|
||||
%endif
|
||||
|
||||
res=0
|
||||
if test -e %my_builddir/kabi/%cpu_arch/symvers-%build_flavor; then
|
||||
# check for kabi changes
|
||||
%_sourcedir/kabi.pl --rules %my_builddir/kabi/severities \
|
||||
%my_builddir/kabi/%cpu_arch/symvers-%build_flavor \
|
||||
Module.symvers || res=$?
|
||||
fi
|
||||
if [ $res -ne 0 ]; then
|
||||
if [ ! -e %my_builddir/kabi/%cpu_arch/ignore-%build_flavor -a \
|
||||
! -e %_sourcedir/IGNORE-KABI-BADNESS ]; then
|
||||
echo "Create a file IGNORE-KABI-BADNESS in the kernel-source" \
|
||||
"directory to build this kernel even though its badness is" \
|
||||
"higher than allowed for an official kernel."
|
||||
exit 1
|
||||
fi
|
||||
fi
|
||||
|
||||
tar -cf - -T %my_builddir/obj-files | \
|
||||
tar -xf - -C %rpm_install_dir/%cpu_arch_flavor
|
||||
# bnc#507084
|
||||
find %rpm_install_dir/%cpu_arch_flavor/scripts -type f -perm -111 | \
|
||||
while read f; do
|
||||
case "$(file -b "$f")" in
|
||||
ELF\ *\ executable*)
|
||||
strip "$f"
|
||||
esac
|
||||
done
|
||||
# Replace the absolute with a relative path
|
||||
sed -i "s,%build_src_dir,../../../linux-%kernelrelease%variant,g" \
|
||||
%rpm_install_dir/%cpu_arch_flavor/Makefile
|
||||
fi
|
||||
|
||||
add_dirs_to_filelist() {
|
||||
sed -rn '
|
||||
# print file name
|
||||
p
|
||||
# remove filelist macros
|
||||
s:%%[a-z]+(\([^)]+\))? ?::g
|
||||
# add %%dir prefix
|
||||
s:^:%%dir :
|
||||
# print all parents
|
||||
:a
|
||||
# skip directories owned by other packages
|
||||
s:^%%dir (/boot|/etc|/lib/(modules|firmware)|/usr/src)/[^/]+$::
|
||||
s:/[^/]+$::p
|
||||
ta
|
||||
' "$@" | sort -u
|
||||
}
|
||||
|
||||
# Collect the file lists.
|
||||
shopt -s nullglob
|
||||
> %my_builddir/kernel-devel.files
|
||||
for file in %buildroot/boot/vmlinux-*.gz %buildroot/boot/symtypes* \
|
||||
%buildroot/lib/modules/*/{build,source}; do
|
||||
f=${file##%buildroot}
|
||||
echo "$f" >> %my_builddir/kernel-devel.files
|
||||
done
|
||||
|
||||
{ cd %buildroot
|
||||
find boot \
|
||||
\( -type l -o -name 'initrd-*' \) -printf '%%%%ghost /%%p\n' -o \
|
||||
-type f -name 'vmlinux-*' -printf '%%%%attr(0644, root, root) /%%p\n' -o \
|
||||
-type f -printf '/%%p\n'
|
||||
|
||||
# Add the auto-generated (by mkdumprd) kdump initrd to %ghost so that
|
||||
# the file gets removed when uninstalling the kernel.
|
||||
echo '%%ghost /boot/initrd-%kernelrelease-kdump'
|
||||
touch $RPM_BUILD_ROOT/boot/initrd-%kernelrelease-kdump
|
||||
|
||||
if [ %CONFIG_MODULES = y ]; then
|
||||
find lib/modules/%kernelrelease-%build_flavor \
|
||||
-type d -o \
|
||||
\( -path '*/modules.*' ! -path '*/modules.order' \
|
||||
! -path '*/modules.builtin' \) -printf '%%%%ghost /%%p\n' \
|
||||
-o -name '*.ko' -prune -o -printf '/%%p\n'
|
||||
cat %my_builddir/base-modules
|
||||
fi
|
||||
test -d lib/firmware/%kernelrelease-%build_flavor && \
|
||||
find lib/firmware/%kernelrelease-%build_flavor \
|
||||
-type d -o \
|
||||
-printf '/%%p\n'
|
||||
if [ -e .%_docdir/%name ]; then
|
||||
echo "%%doc %_docdir/%name"
|
||||
fi
|
||||
} | sort -u >%my_builddir/tmp
|
||||
cat %my_builddir/tmp %my_builddir/kernel-devel.files | sort | uniq -u | \
|
||||
add_dirs_to_filelist >%my_builddir/kernel-base.files
|
||||
rm %my_builddir/tmp
|
||||
|
||||
%if %split_base
|
||||
add_dirs_to_filelist %my_builddir/{kernel-base.files,main-modules} \
|
||||
> %my_builddir/kernel-main.files
|
||||
%endif
|
||||
%if %split_extra
|
||||
add_dirs_to_filelist %my_builddir/unsupported-modules > %my_builddir/kernel-extra.files
|
||||
%endif
|
||||
|
||||
# Hardlink duplicate files automatically (from package fdupes): It doesn't save
|
||||
# much, but it keeps rpmlint from breaking the package build. Note that we skip
|
||||
# /usr/src/linux-obj intentionally, to not accidentally break timestamps there
|
||||
%fdupes $RPM_BUILD_ROOT/lib
|
||||
|
||||
%preun -f preun.sh
|
||||
%postun -f postun.sh
|
||||
%pre -f pre.sh
|
||||
%post -f post.sh
|
||||
|
||||
|
||||
%if %split_base
|
||||
%files -f kernel-main.files
|
||||
%else
|
||||
%files -f kernel-base.files
|
||||
%endif
|
||||
%defattr(-, root, root)
|
||||
|
||||
%package base
|
||||
Summary: @SUMMARY@ - base modules
|
||||
License: GPL v2 only
|
||||
Group: System/Kernel
|
||||
Url: http://www.kernel.org/
|
||||
AutoReqProv: on
|
||||
Provides: multiversion(kernel)
|
||||
Provides: kernel-base = %version-%source_rel
|
||||
Requires(pre): coreutils awk
|
||||
Requires(post): module-init-tools
|
||||
Requires(post): perl-Bootloader
|
||||
Requires(post): mkinitrd
|
||||
%ifarch %ix86
|
||||
Conflicts: libc.so.6()(64bit)
|
||||
%endif
|
||||
|
||||
%description base
|
||||
@DESCRIPTION@
|
||||
|
||||
This package contains only the base modules, required in all installs.
|
||||
|
||||
%source_timestamp
|
||||
|
||||
%preun base -f preun-base.sh
|
||||
%postun base -f postun-base.sh
|
||||
%pre base -f pre-base.sh
|
||||
%post base -f post-base.sh
|
||||
|
||||
%if %split_base
|
||||
%files base -f kernel-base.files
|
||||
%defattr(-, root, root)
|
||||
%endif
|
||||
|
||||
%package extra
|
||||
Summary: @SUMMARY@ - Unsupported kernel modules
|
||||
License: GPL v2 only
|
||||
Group: System/Kernel
|
||||
Url: http://www.kernel.org/
|
||||
AutoReqProv: on
|
||||
Provides: multiversion(kernel)
|
||||
Provides: %name-extra_%_target_cpu = %version-%release
|
||||
Provides: kernel-extra = %version-%source_rel
|
||||
Requires: %{name}_%_target_cpu = %version-%release
|
||||
Requires(pre): coreutils awk
|
||||
Requires(post): module-init-tools
|
||||
Requires(post): perl-Bootloader
|
||||
Requires(post): mkinitrd
|
||||
Supplements: packageand(product(SUSE_SLED):%{name}_%_target_cpu)
|
||||
%ifarch %ix86
|
||||
Conflicts: libc.so.6()(64bit)
|
||||
%endif
|
||||
|
||||
%description extra
|
||||
@DESCRIPTION@
|
||||
|
||||
This package contains additional modules not supported by Novell.
|
||||
|
||||
%source_timestamp
|
||||
|
||||
%preun extra -f preun-extra.sh
|
||||
%postun extra -f postun-extra.sh
|
||||
%pre extra -f pre-extra.sh
|
||||
%post extra -f post-extra.sh
|
||||
|
||||
%if %split_extra
|
||||
%files extra -f kernel-extra.files
|
||||
%defattr(-, root, root)
|
||||
%endif
|
||||
|
||||
%if %CONFIG_KMSG_IDS == "y"
|
||||
%package man
|
||||
Summary: The collection of man pages generated by the kmsg script.
|
||||
License: GPL v2 only
|
||||
Group: System/Kernel
|
||||
|
||||
%description man
|
||||
This package includes the man pages that have been generated from the
|
||||
kmsg message documentation comments.
|
||||
|
||||
%source_timestamp
|
||||
|
||||
%files man
|
||||
%defattr(-,root,root)
|
||||
/usr/share/man/man9/*
|
||||
%endif
|
||||
|
||||
%package devel
|
||||
Summary: Development files necessary for building kernel modules
|
||||
License: GPL v2 only
|
||||
Group: Development/Sources
|
||||
Provides: multiversion(kernel)
|
||||
Provides: %name-devel = %version-%source_rel
|
||||
Requires: kernel-devel%variant = %version-%source_rel
|
||||
Supplements: packageand(%name:kernel-devel%variant)
|
||||
AutoReqProv: on
|
||||
|
||||
%description devel
|
||||
This package contains files necessary for building kernel modules (and
|
||||
kernel module packages) against the %build_flavor flavor of the kernel.
|
||||
|
||||
%source_timestamp
|
||||
|
||||
%if %CONFIG_MODULES == "y"
|
||||
%pre devel -f devel-pre.sh
|
||||
%post devel -f devel-post.sh
|
||||
%files devel -f kernel-devel.files
|
||||
%defattr(-,root,root)
|
||||
%dir %obj_install_dir
|
||||
%dir %obj_install_dir/%cpu_arch
|
||||
%dir /usr/src/linux-obj
|
||||
%dir /usr/src/linux-obj/%cpu_arch
|
||||
%ghost /usr/src/linux-obj/%cpu_arch_flavor
|
||||
%obj_install_dir/%cpu_arch_flavor
|
||||
%if %_target_cpu != %cpu_arch
|
||||
%obj_install_dir/%_target_cpu
|
||||
/usr/src/linux-obj/%_target_cpu
|
||||
%endif
|
||||
%endif
|
||||
|
||||
%package devel-debuginfo
|
||||
# rpm doesn't notice that vmlinux.debug belongs to the gzipped vmlinux.gz
|
||||
Summary: Debug information for package %name-devel
|
||||
License: GPL v2 only
|
||||
Group: Development/Debug
|
||||
|
||||
%description devel-debuginfo
|
||||
Debug information for package %name-devel
|
||||
|
||||
%source_timestamp
|
||||
|
||||
%files devel-debuginfo -f vmlinux.debug.files
|
||||
|
||||
%changelog
|
24269
kernel-debug.changes
Normal file
24269
kernel-debug.changes
Normal file
File diff suppressed because it is too large
Load Diff
16441
kernel-debug.spec
Normal file
16441
kernel-debug.spec
Normal file
File diff suppressed because it is too large
Load Diff
24269
kernel-default.changes
Normal file
24269
kernel-default.changes
Normal file
File diff suppressed because it is too large
Load Diff
16454
kernel-default.spec
Normal file
16454
kernel-default.spec
Normal file
File diff suppressed because it is too large
Load Diff
24269
kernel-desktop.changes
Normal file
24269
kernel-desktop.changes
Normal file
File diff suppressed because it is too large
Load Diff
16474
kernel-desktop.spec
Normal file
16474
kernel-desktop.spec
Normal file
File diff suppressed because it is too large
Load Diff
24269
kernel-docs.changes
Normal file
24269
kernel-docs.changes
Normal file
File diff suppressed because it is too large
Load Diff
15662
kernel-docs.spec
Normal file
15662
kernel-docs.spec
Normal file
File diff suppressed because it is too large
Load Diff
101
kernel-docs.spec.in
Normal file
101
kernel-docs.spec.in
Normal file
@ -0,0 +1,101 @@
|
||||
#
|
||||
# spec file for package kernel-docs@VARIANT@ (Version @RPMVERSION@)
|
||||
#
|
||||
# Copyright (c) 2009 SUSE LINUX Products GmbH, Nuernberg, Germany.
|
||||
#
|
||||
# All modifications and additions to the file contributed by third parties
|
||||
# remain the property of their copyright owners, unless otherwise agreed
|
||||
# upon. The license for this file, and modifications and additions to the
|
||||
# file, is the same license as for the pristine package itself (unless the
|
||||
# license for the pristine package is not an Open Source License, in which
|
||||
# case the license is the MIT License). An "Open Source License" is a
|
||||
# license that conforms to the Open Source Definition (Version 1.9)
|
||||
# published by the Open Source Initiative.
|
||||
|
||||
# Please submit bugfixes or comments via http://bugs.opensuse.org/
|
||||
#
|
||||
|
||||
# norootforbuild
|
||||
|
||||
%define patchversion @PATCHVERSION@
|
||||
%define variant @VARIANT@%{nil}
|
||||
|
||||
%include %_sourcedir/kernel-spec-macros
|
||||
|
||||
Name: kernel-docs@VARIANT@
|
||||
Summary: Kernel Documentation
|
||||
Version: @RPMVERSION@
|
||||
%if %using_buildservice
|
||||
Release: @RELEASE_PREFIX@<RELEASE>
|
||||
%else
|
||||
Release: @RELEASE_PREFIX@0
|
||||
%endif
|
||||
BuildRequires: docbook-toys docbook-utils ghostscript_any libjpeg-devel texlive transfig xmlto xorg-x11-devel
|
||||
BuildRequires: kernel-source%variant
|
||||
Url: http://www.kernel.org/
|
||||
License: GPL v2 or later
|
||||
Group: Documentation/Man
|
||||
AutoReqProv: on
|
||||
Provides: %name = %version-%source_rel
|
||||
BuildArch: noarch
|
||||
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
||||
Source: kernel-spec-macros
|
||||
|
||||
%description
|
||||
These are the PDF documents and man pages (section 9) built from
|
||||
thecurrent kernel sources.
|
||||
|
||||
|
||||
|
||||
%prep
|
||||
cp -av /etc/texmf/web2c/texmf.cnf .
|
||||
cat << EOF >> texmf.cnf
|
||||
main_memory.pdfjadetex = 2500000
|
||||
hash_extra.pdfjadetex = 70000
|
||||
max_strings.pdfjadetex = 120000
|
||||
save_size.pdfjadetex = 10000
|
||||
EOF
|
||||
%setup -T -c
|
||||
|
||||
%build
|
||||
# use texmf.cnf from local source
|
||||
export TEXMFCNF=$RPM_BUILD_DIR
|
||||
export LANG=en_US
|
||||
make -C /usr/src/linux%variant O=$PWD -k -i mandocs %{?jobs:-j%jobs}
|
||||
make -C /usr/src/linux%variant O=$PWD -k -i pdfdocs %{?jobs:-j%jobs}
|
||||
|
||||
%install
|
||||
rm -rf $RPM_BUILD_ROOT
|
||||
install -d $RPM_BUILD_ROOT/%{_mandir}/man9
|
||||
# filter out obscure device drivers - they clutter up the rpm and don't add any real value
|
||||
find Documentation/DocBook/ -name '*.9.gz' |
|
||||
egrep -v 'man/(sis[69]|rio|fsl|struct_rio|RIO|mpc85|set_rx_mode|mdio_(read|write)|mii_ioctl|mca_|z8530|nand|sppp|piix|(read|write)_zs)' |
|
||||
while read i ; do
|
||||
cp $i $RPM_BUILD_ROOT/%{_mandir}/man9
|
||||
done
|
||||
install -d $RPM_BUILD_ROOT/usr/share/doc/kernel
|
||||
cp -a Documentation/DocBook/*.pdf $RPM_BUILD_ROOT/usr/share/doc/kernel || true
|
||||
if [ -d Documentation/kdb ] ; then
|
||||
for i in Documentation/kdb/*.m* ; do
|
||||
k=`basename $i`
|
||||
k=${k/man/9}
|
||||
k=${k/mm/9}
|
||||
cp $i $RPM_BUILD_ROOT/%{_mandir}/man9/$k
|
||||
done
|
||||
fi
|
||||
|
||||
ln -s /usr/share/man/man9/request_threaded_irq.9.gz $RPM_BUILD_ROOT/usr/share/man/man9/request_irq.9.gz
|
||||
|
||||
cp -a /usr/src/linux%variant/{COPYING,CREDITS,MAINTAINERS,README,REPORTING-BUGS} .
|
||||
|
||||
%clean
|
||||
rm -rf $RPM_BUILD_ROOT
|
||||
|
||||
%files
|
||||
%defattr(-,root,root)
|
||||
%doc COPYING CREDITS MAINTAINERS README REPORTING-BUGS
|
||||
%{_mandir}/man9/*
|
||||
%docdir /usr/share/doc/kernel
|
||||
/usr/share/doc/kernel
|
||||
|
||||
%changelog
|
24269
kernel-ec2.changes
Normal file
24269
kernel-ec2.changes
Normal file
File diff suppressed because it is too large
Load Diff
16444
kernel-ec2.spec
Normal file
16444
kernel-ec2.spec
Normal file
File diff suppressed because it is too large
Load Diff
75
kernel-module-subpackage
Normal file
75
kernel-module-subpackage
Normal file
@ -0,0 +1,75 @@
|
||||
%package -n %{-n*}-%1
|
||||
%define _this_kmp_version %{-v*}_k%(echo %2 | sed -r 'y/-/_/; s/^(2\.6\.[0-9]+)_/\\1.0_/; # use 2.6.x.0 for mainline kernels')
|
||||
Version: %_this_kmp_version
|
||||
Release: %{-r*}
|
||||
%(
|
||||
for spec in {%_sourcedir,%_specdir}/%name.spec /dev/null; do
|
||||
[ -e $spec ] && break
|
||||
done
|
||||
awk '
|
||||
BEGIN { tags["summary"] = "Summary: %summary"
|
||||
tags["group"] = "Group: %group" }
|
||||
/^%%/ { in_pkg_header = \
|
||||
($0 ~ /^%%package[ \t]+KMP[ \t]*$/ ||
|
||||
$0 ~ /^%%package[ \t]+-n[ \t]*%name-KMP[ \t]*$/)
|
||||
next }
|
||||
in_pkg_header && /^(Summary|Group):[ \t]*/ \
|
||||
{ tag = tolower($1) ; sub(/:$/, "", tag)
|
||||
tags[tag] = $0 }
|
||||
END { print tags["summary"]
|
||||
print tags["group"] }
|
||||
' $spec
|
||||
)
|
||||
Provides: %{-n*} = %_this_kmp_version
|
||||
Provides: multiversion(kernel)
|
||||
Requires: coreutils grep
|
||||
Enhances: kernel-%1
|
||||
AutoReqProv: on
|
||||
%{-p:%{expand:%(cd %_sourcedir; cat %{-p*})}}
|
||||
%description -n %{-n*}-%1
|
||||
%(
|
||||
for spec in {%_sourcedir,%_specdir}/%name.spec /dev/null; do
|
||||
[ -e $spec ] && break
|
||||
done
|
||||
awk '
|
||||
/^%%/ { in_desc = \
|
||||
($0 ~ /^%%description[ \t]+KMP[ \t]*$/ ||
|
||||
$0 ~ /^%%description[ \t]+-n[ \t]*%name-KMP[ \t]*$/)
|
||||
next }
|
||||
in_desc { print; good = 1 }
|
||||
END { exit(! good) }
|
||||
' $spec || \
|
||||
awk '
|
||||
/^%%/ { in_desc = \
|
||||
($0 ~ /^%%description[ \t]*$/ ||
|
||||
$0 ~ /^%%description[ \t]+-n[ \t]*%name[ \t]*$/)
|
||||
next }
|
||||
in_desc { print; good = 1 }
|
||||
END { exit(! good) }
|
||||
' $spec
|
||||
)
|
||||
%post -n %{-n*}-%1
|
||||
nvr=%{-n*}-%1-%_this_kmp_version-%{-r*}
|
||||
wm2=/usr/lib/module-init-tools/weak-modules2
|
||||
if [ -x $wm2 ]; then
|
||||
%{-b:KMP_NEEDS_MKINITRD=1} /bin/bash -${-/e/} $wm2 --add-kmp $nvr
|
||||
fi
|
||||
%preun -n %{-n*}-%1
|
||||
nvr=%{-n*}-%1-%_this_kmp_version-%{-r*}
|
||||
rpm -ql $nvr | sed -n '/\.ko$/p' > /var/run/rpm-$nvr-modules
|
||||
%postun -n %{-n*}-%1
|
||||
nvr=%{-n*}-%1-%_this_kmp_version-%{-r*}
|
||||
modules=( $(cat /var/run/rpm-$nvr-modules) )
|
||||
rm -f /var/run/rpm-$nvr-modules
|
||||
if [ ${#modules[*]} = 0 ]; then
|
||||
echo "WARNING: $nvr does not contain any kernel modules" >&2
|
||||
exit 0
|
||||
fi
|
||||
wm2=/usr/lib/module-init-tools/weak-modules2
|
||||
if [ -x $wm2 ]; then
|
||||
printf '%s\n' "${modules[@]}" | /bin/bash -${-/e/} $wm2 --remove-kmp $nvr
|
||||
fi
|
||||
%files -n %{-n*}-%1
|
||||
%{-f:%{expand:%(cd %_sourcedir; cat %{-f*})}}
|
||||
%{!-f:%defattr (-,root,root)}
|
||||
%{!-f:/lib/modules/%2-%1}
|
24269
kernel-pae.changes
Normal file
24269
kernel-pae.changes
Normal file
File diff suppressed because it is too large
Load Diff
16459
kernel-pae.spec
Normal file
16459
kernel-pae.spec
Normal file
File diff suppressed because it is too large
Load Diff
24269
kernel-ppc64.changes
Normal file
24269
kernel-ppc64.changes
Normal file
File diff suppressed because it is too large
Load Diff
16463
kernel-ppc64.spec
Normal file
16463
kernel-ppc64.spec
Normal file
File diff suppressed because it is too large
Load Diff
24269
kernel-s390.changes
Normal file
24269
kernel-s390.changes
Normal file
File diff suppressed because it is too large
Load Diff
16438
kernel-s390.spec
Normal file
16438
kernel-s390.spec
Normal file
File diff suppressed because it is too large
Load Diff
24269
kernel-source.changes
Normal file
24269
kernel-source.changes
Normal file
File diff suppressed because it is too large
Load Diff
2
kernel-source.rpmlintrc
Normal file
2
kernel-source.rpmlintrc
Normal file
@ -0,0 +1,2 @@
|
||||
# These zero-length files are correct:
|
||||
addFilter("zero-length /usr/src/linux-2\.6\..*obj/.*include/config.*h")
|
15819
kernel-source.spec
Normal file
15819
kernel-source.spec
Normal file
File diff suppressed because it is too large
Load Diff
258
kernel-source.spec.in
Normal file
258
kernel-source.spec.in
Normal file
@ -0,0 +1,258 @@
|
||||
#
|
||||
# spec file for package kernel-source@VARIANT@ (Version @RPMVERSION@)
|
||||
#
|
||||
# Copyright (c) 2009 SUSE LINUX Products GmbH, Nuernberg, Germany.
|
||||
#
|
||||
# All modifications and additions to the file contributed by third parties
|
||||
# remain the property of their copyright owners, unless otherwise agreed
|
||||
# upon. The license for this file, and modifications and additions to the
|
||||
# file, is the same license as for the pristine package itself (unless the
|
||||
# license for the pristine package is not an Open Source License, in which
|
||||
# case the license is the MIT License). An "Open Source License" is a
|
||||
# license that conforms to the Open Source Definition (Version 1.9)
|
||||
# published by the Open Source Initiative.
|
||||
|
||||
# Please submit bugfixes or comments via http://bugs.opensuse.org/
|
||||
#
|
||||
|
||||
# norootforbuild
|
||||
# icecream 0
|
||||
|
||||
%define srcversion @SRCVERSION@
|
||||
%define patchversion @PATCHVERSION@
|
||||
%define variant @VARIANT@%{nil}
|
||||
%define vanilla_only @VANILLA_ONLY@
|
||||
|
||||
%include %_sourcedir/kernel-spec-macros
|
||||
|
||||
%define src_install_dir usr/src/linux-%kernelrelease%variant
|
||||
|
||||
Name: kernel-source@VARIANT@
|
||||
Summary: The Linux Kernel Sources
|
||||
Version: @RPMVERSION@
|
||||
%if %using_buildservice
|
||||
Release: @RELEASE_PREFIX@<RELEASE>
|
||||
%else
|
||||
Release: @RELEASE_PREFIX@0
|
||||
%endif
|
||||
License: GPL v2 only
|
||||
Group: Development/Sources
|
||||
Url: http://www.kernel.org/
|
||||
AutoReqProv: off
|
||||
BuildRequires: coreutils sed
|
||||
BuildRequires: fdupes
|
||||
Requires(post): coreutils sed
|
||||
Provides: multiversion(kernel)
|
||||
Provides: linux
|
||||
Provides: %name = %version-%source_rel
|
||||
Source0: http://www.kernel.org/pub/linux/kernel/v2.6/linux-%srcversion.tar.bz2
|
||||
Source2: source-post.sh
|
||||
Source3: kernel-source.rpmlintrc
|
||||
Source8: devel-pre.sh
|
||||
Source9: devel-post.sh
|
||||
Source10: preun.sh
|
||||
Source11: postun.sh
|
||||
Source12: pre.sh
|
||||
Source13: post.sh
|
||||
Source14: series.conf
|
||||
Source16: guards
|
||||
Source17: apply-patches
|
||||
Source21: config.conf
|
||||
Source23: supported.conf
|
||||
Source33: check-for-config-changes
|
||||
Source34: check-supported-list
|
||||
Source35: group-source-files.pl
|
||||
Source37: README.SUSE
|
||||
Source38: README.KSYMS
|
||||
Source39: config-options.changes.txt
|
||||
Source40: source-timestamp
|
||||
Source44: find-provides
|
||||
Source45: split-modules
|
||||
Source46: modversions
|
||||
Source48: macros.kernel-source
|
||||
Source49: kernel-module-subpackage
|
||||
Source50: kabi.pl
|
||||
Source51: mkspec
|
||||
Source52: kernel-source%variant.changes
|
||||
Source53: kernel-source.spec.in
|
||||
Source54: kernel-binary.spec.in
|
||||
Source55: kernel-syms.spec.in
|
||||
Source56: kernel-docs.spec.in
|
||||
Source60: config.sh
|
||||
Source61: compute-PATCHVERSION.sh
|
||||
Source62: old-packages.conf
|
||||
Source63: arch-symbols
|
||||
Source64: package-descriptions
|
||||
Source65: kernel-spec-macros
|
||||
Source66: configtool.pl
|
||||
Source67: log.sh
|
||||
Source68: host-memcpy-hack.h
|
||||
Source100: config.tar.bz2
|
||||
Source101: config.addon.tar.bz2
|
||||
Source102: patches.arch.tar.bz2
|
||||
Source103: patches.drivers.tar.bz2
|
||||
Source104: patches.fixes.tar.bz2
|
||||
Source105: patches.rpmify.tar.bz2
|
||||
Source106: patches.suse.tar.bz2
|
||||
Source107: patches.xen.tar.bz2
|
||||
Source108: patches.addon.tar.bz2
|
||||
Source109: patches.kernel.org.tar.bz2
|
||||
Source110: patches.apparmor.tar.bz2
|
||||
Source111: patches.rt.tar.bz2
|
||||
Source112: patches.trace.tar.bz2
|
||||
Source113: patches.kabi.tar.bz2
|
||||
Source120: kabi.tar.bz2
|
||||
Source121: sysctl.tar.bz2
|
||||
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
||||
BuildArch: noarch
|
||||
Prefix: /usr/src
|
||||
# Source is only complete with devel files.
|
||||
Requires: kernel-devel = %version-%release
|
||||
|
||||
%(chmod +x %_sourcedir/{@SCRIPTS@})
|
||||
|
||||
%define symbols %(set -- $([ -e %_sourcedir/extra-symbols ] && cat %_sourcedir/extra-symbols) ; echo $*)
|
||||
%define variant_symbols %(case %name in (*-rt) echo "RT" ;; esac)
|
||||
|
||||
%define do_vanilla "%variant" == ""
|
||||
|
||||
%description
|
||||
Linux kernel sources with many fixes and improvements.
|
||||
|
||||
%source_timestamp
|
||||
|
||||
%package -n kernel-devel%variant
|
||||
Summary: Development files needed for building kernel modules
|
||||
License: GPL v2 only
|
||||
Group: Development/Sources
|
||||
AutoReqProv: off
|
||||
Provides: multiversion(kernel)
|
||||
Provides: kernel-devel%variant = %version-%source_rel
|
||||
|
||||
%description -n kernel-devel%variant
|
||||
Kernel-level headers and Makefiles required for development of
|
||||
external kernel modules.
|
||||
|
||||
%source_timestamp
|
||||
|
||||
%package vanilla
|
||||
Summary: Vanilla Linux kernel sources with minor build fixes.
|
||||
License: GPL v2 only
|
||||
Group: Development/Sources
|
||||
AutoReqProv: off
|
||||
Provides: multiversion(kernel)
|
||||
Provides: %name-vanilla = %version-%source_rel
|
||||
|
||||
%description vanilla
|
||||
Vanilla Linux kernel sources with minor build fixes.
|
||||
|
||||
%source_timestamp
|
||||
|
||||
%prep
|
||||
if ! [ -e %_sourcedir/linux-%srcversion.tar.bz2 ]; then
|
||||
echo "Please get a copy of linux-%srcversion.tar.bz2 from" \
|
||||
"ftp://ftp.kernel.org/pub/linux/kernel/v2.6/."
|
||||
fi
|
||||
|
||||
echo "Symbol(s): %symbols"
|
||||
|
||||
# Unpack all sources and patches
|
||||
%setup -q -c -T @UNPACK_PATCHES@
|
||||
|
||||
%build
|
||||
mkdir -p $RPM_BUILD_ROOT/usr/src
|
||||
cd $RPM_BUILD_ROOT/usr/src
|
||||
|
||||
# Unpack the vanilla kernel sources
|
||||
tar -xjf %_sourcedir/linux-%srcversion.tar.bz2
|
||||
if test "%srcversion" != "%kernelrelease%variant"; then
|
||||
mv linux-%srcversion linux-%kernelrelease%variant
|
||||
fi
|
||||
|
||||
|
||||
%if %do_vanilla
|
||||
%if %vanilla_only
|
||||
mv \
|
||||
%else
|
||||
cp -al \
|
||||
%endif
|
||||
linux-%kernelrelease%variant linux-%kernelrelease-vanilla
|
||||
cd linux-%kernelrelease-vanilla
|
||||
%_sourcedir/apply-patches --vanilla %_sourcedir/series.conf %my_builddir %symbols
|
||||
rm -f $(find . -name ".gitignore")
|
||||
cd ..
|
||||
%endif
|
||||
|
||||
%if ! %vanilla_only
|
||||
ln -sf linux%variant linux%variant # dummy symlink
|
||||
|
||||
cd linux-%kernelrelease%variant
|
||||
%_sourcedir/apply-patches %_sourcedir/series.conf %my_builddir %symbols
|
||||
rm -f $(find . -name ".gitignore")
|
||||
|
||||
if [ -f %_sourcedir/localversion ] ; then
|
||||
cat %_sourcedir/localversion > localversion
|
||||
fi
|
||||
%endif
|
||||
|
||||
# Hardlink duplicate files automatically (from package fdupes).
|
||||
%fdupes $RPM_BUILD_ROOT
|
||||
|
||||
%install
|
||||
%if ! %vanilla_only
|
||||
# Install the documentation and example Kernel Module Package.
|
||||
DOC=$RPM_BUILD_ROOT/usr/share/doc/packages/%name
|
||||
mkdir -p $DOC
|
||||
cp %_sourcedir/README.SUSE %_sourcedir/config-options.changes.txt $DOC
|
||||
ln -s /usr/share/doc/packages/%name/README.SUSE %buildroot/%src_install_dir/
|
||||
|
||||
install -m 755 -d $RPM_BUILD_ROOT/etc/rpm
|
||||
install -m 644 %_sourcedir/macros.kernel-source $RPM_BUILD_ROOT/etc/rpm/
|
||||
install -m 755 -d $RPM_BUILD_ROOT/usr/lib/rpm
|
||||
install -m 644 %_sourcedir/kernel-module-subpackage \
|
||||
$RPM_BUILD_ROOT/usr/lib/rpm/
|
||||
|
||||
for script in post; do
|
||||
sed -e "s:@KERNELRELEASE@:%kernelrelease:g" \
|
||||
-e "s:@SRCVARIANT@:%variant:g" \
|
||||
%_sourcedir/source-$script.sh > %name-$script.sh
|
||||
done
|
||||
|
||||
pushd "%buildroot"
|
||||
perl "%_sourcedir/group-source-files.pl" \
|
||||
-D "$OLDPWD/devel.files" -N "$OLDPWD/nondevel.files" \
|
||||
-L "%src_install_dir"
|
||||
popd
|
||||
|
||||
# kernel-source and kernel-$flavor-devel are built independently, but the
|
||||
# shipped sources (/usr/src/linux/) need to be older than generated files
|
||||
# (/usr/src/linux-obj). We rely on the git commit timestamp to not point into
|
||||
# the future and be thus lower than the timestamps of files built from the
|
||||
# source (bnc#669669).
|
||||
ts="$(head -n1 %_sourcedir/source-timestamp)"
|
||||
find %buildroot/usr/src/linux* ! -type l | xargs touch -d "$ts"
|
||||
|
||||
%post -f %name-post.sh
|
||||
|
||||
%post -n kernel-devel%variant -f %name-post.sh
|
||||
|
||||
%files -f nondevel.files
|
||||
%defattr(-, root, root)
|
||||
%ghost /usr/src/linux%variant
|
||||
/usr/src/linux%variant-%kernelrelease/README.SUSE
|
||||
|
||||
%files -n kernel-devel%variant -f devel.files
|
||||
%defattr(-,root,root)
|
||||
%ghost /usr/src/linux%variant
|
||||
/usr/share/doc/packages/%name
|
||||
/etc/rpm/macros.kernel-source
|
||||
/usr/lib/rpm/kernel-module-subpackage
|
||||
%endif
|
||||
|
||||
%if %do_vanilla
|
||||
%files vanilla
|
||||
%defattr(-, root, root)
|
||||
/usr/src/linux-%kernelrelease-vanilla
|
||||
%endif
|
||||
|
||||
%changelog
|
36
kernel-spec-macros
Normal file
36
kernel-spec-macros
Normal file
@ -0,0 +1,36 @@
|
||||
# This file is included by all the kernel-*.spec files
|
||||
|
||||
# Build with bash instead of sh as the shell: this turns on bash
|
||||
# extensions like <(...).
|
||||
%define _buildshell /bin/bash
|
||||
|
||||
%define using_buildservice 0%{?opensuse_bs}
|
||||
|
||||
# source_rel is the package release string, without the rebuild counter
|
||||
# generated by the build service. In non-official builds, the upstream
|
||||
# EXTRAVERSION component is also part of the release string,
|
||||
# e.g. next.20110101.9.6 (hyphens are replaced by periods). Builds in the
|
||||
# official distribution projects replace the release string though.
|
||||
%define source_rel %release
|
||||
%if %using_buildservice
|
||||
%define source_rel %(release=%release; echo ${release%.*})
|
||||
%endif
|
||||
|
||||
# release_num is the numeric source revision part of the release number,
|
||||
# i.e. source_rel without the upstream tags like -rcX. A hyphen is added
|
||||
# automatically for convenient use.
|
||||
# examples: rc3 -> "", rc3.1 -> -1, next.20110101.9 -> -9
|
||||
#
|
||||
# patchversion is inserted into the spec files by the mkspec script, it is the
|
||||
# upstream release string unchanged, e.g. 2.6.38-rc3
|
||||
%define release_num %(upstream=%patchversion; upstream=${upstream#%version}; upstream=${upstream#-}; upstream=${upstream//-/.}; rel="%source_rel" ; res="${rel#$upstream}"; res=${res#.}; echo ${res:+-}${res})
|
||||
|
||||
# how the kernel release string (uname -r) should look like
|
||||
%define kernelrelease %patchversion%release_num
|
||||
|
||||
%define my_builddir %_builddir/%{name}-%{version}
|
||||
|
||||
# macro to add the source timestamp to package descriptions
|
||||
%define source_timestamp %(sed '1s/^/Source Timestamp: /' %_sourcedir/source-timestamp || :)
|
||||
|
||||
# vim: ft=spec
|
24269
kernel-syms.changes
Normal file
24269
kernel-syms.changes
Normal file
File diff suppressed because it is too large
Load Diff
15644
kernel-syms.spec
Normal file
15644
kernel-syms.spec
Normal file
File diff suppressed because it is too large
Load Diff
66
kernel-syms.spec.in
Normal file
66
kernel-syms.spec.in
Normal file
@ -0,0 +1,66 @@
|
||||
#
|
||||
# spec file for package kernel-syms@VARIANT@ (Version @RPMVERSION@)
|
||||
#
|
||||
# Copyright (c) 2009 SUSE LINUX Products GmbH, Nuernberg, Germany.
|
||||
#
|
||||
# All modifications and additions to the file contributed by third parties
|
||||
# remain the property of their copyright owners, unless otherwise agreed
|
||||
# upon. The license for this file, and modifications and additions to the
|
||||
# file, is the same license as for the pristine package itself (unless the
|
||||
# license for the pristine package is not an Open Source License, in which
|
||||
# case the license is the MIT License). An "Open Source License" is a
|
||||
# license that conforms to the Open Source Definition (Version 1.9)
|
||||
# published by the Open Source Initiative.
|
||||
|
||||
# Please submit bugfixes or comments via http://bugs.opensuse.org/
|
||||
#
|
||||
|
||||
# norootforbuild
|
||||
|
||||
%define variant @VARIANT@%{nil}
|
||||
|
||||
%include %_sourcedir/kernel-spec-macros
|
||||
|
||||
Name: kernel-syms@VARIANT@
|
||||
Summary: Kernel Symbol Versions (modversions)
|
||||
Version: @RPMVERSION@
|
||||
%if %using_buildservice
|
||||
Release: @RELEASE_PREFIX@<RELEASE>
|
||||
%else
|
||||
%define kernel_source_release %(LC_ALL=C rpm -q kernel-devel%variant-%version --qf "%{RELEASE}" | grep -v 'not installed' || echo 0)
|
||||
Release: %kernel_source_release
|
||||
%endif
|
||||
License: GPL v2 only
|
||||
Group: Development/Sources
|
||||
Url: http://www.kernel.org/
|
||||
AutoReqProv: off
|
||||
BuildRequires: coreutils
|
||||
@REQUIRES@
|
||||
Provides: multiversion(kernel)
|
||||
Provides: %name = %version-%source_rel
|
||||
Source: README.KSYMS
|
||||
Requires: kernel-devel%variant = %version-%source_rel
|
||||
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
||||
ExclusiveArch: @ARCHS@
|
||||
Prefix: /usr/src
|
||||
|
||||
%description
|
||||
Kernel symbols, such as functions and variables, have version
|
||||
information attached to them. This package contains the symbol versions
|
||||
for the standard kernels.
|
||||
|
||||
This package is needed for compiling kernel module packages with proper
|
||||
package dependencies.
|
||||
|
||||
%source_timestamp
|
||||
|
||||
%prep
|
||||
%install
|
||||
install -m 644 -D %{SOURCE0} %buildroot/%_docdir/%name/README.SUSE
|
||||
|
||||
%files
|
||||
%defattr(-, root, root)
|
||||
%dir %_docdir/%name
|
||||
%_docdir/%name/README.SUSE
|
||||
|
||||
%changelog
|
24269
kernel-trace.changes
Normal file
24269
kernel-trace.changes
Normal file
File diff suppressed because it is too large
Load Diff
16446
kernel-trace.spec
Normal file
16446
kernel-trace.spec
Normal file
File diff suppressed because it is too large
Load Diff
24269
kernel-vanilla.changes
Normal file
24269
kernel-vanilla.changes
Normal file
File diff suppressed because it is too large
Load Diff
16442
kernel-vanilla.spec
Normal file
16442
kernel-vanilla.spec
Normal file
File diff suppressed because it is too large
Load Diff
24269
kernel-xen.changes
Normal file
24269
kernel-xen.changes
Normal file
File diff suppressed because it is too large
Load Diff
16444
kernel-xen.spec
Normal file
16444
kernel-xen.spec
Normal file
File diff suppressed because it is too large
Load Diff
3
linux-3.1-rc8.tar.bz2
Normal file
3
linux-3.1-rc8.tar.bz2
Normal file
@ -0,0 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:4a266339035e4e5523a097152c0ceb9a971211558fb472e88a33c151e8139d02
|
||||
size 77219233
|
Binary file not shown.
167
log.sh
Normal file
167
log.sh
Normal file
@ -0,0 +1,167 @@
|
||||
#! /bin/sh
|
||||
|
||||
# log.sh - Automate insertion of patches into a kernel rpm tree managed
|
||||
# with series.conf
|
||||
#
|
||||
# Usage example:
|
||||
#
|
||||
# osc branch openSUSE:11.3/kernel-source
|
||||
# osc co home:philipsb:branches:openSUSE:11.3:Update:Test/kernel-source
|
||||
# mv ~/linux-2.6/driver-fix-for-something.patch .
|
||||
# echo -e "\tpatches.drivers/driver-fix-for-something.patch" >> series.conf
|
||||
# ./log.sh
|
||||
# osc commit
|
||||
|
||||
#############################################################################
|
||||
# Copyright (c) 2004-2006,2008-2010 Novell, Inc.
|
||||
# All Rights Reserved.
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of version 2 of the GNU General Public License as
|
||||
# published by the Free Software Foundation.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, contact Novell, Inc.
|
||||
#
|
||||
# To contact Novell about this file by physical or electronic mail,
|
||||
# you may find current contact information at www.novell.com
|
||||
#############################################################################
|
||||
|
||||
# Construct a changes entry and commit log from a patch.
|
||||
|
||||
CHANGES=kernel-source.changes
|
||||
|
||||
trap 'rm -rf "$tmpdir"' EXIT
|
||||
tmpdir=$(mktemp -d /tmp/${0##*/}.XXXXXX)
|
||||
message=$tmpdir/message
|
||||
|
||||
log_entry() {
|
||||
local entry=$1
|
||||
|
||||
echo "$entry" \
|
||||
| fmt --width 65 \
|
||||
| sed -e '1s/^/- /' -e '2,$s/^/ /' \
|
||||
>> $message
|
||||
}
|
||||
|
||||
|
||||
patch_meta() {
|
||||
local patch=$1
|
||||
|
||||
subject=$(formail -c -x Subject < "$patch" \
|
||||
| sed -e 's, *\[[#/ A-Za-z0-9-]*\],,')
|
||||
subject=${subject## }
|
||||
subject=${subject%.}
|
||||
|
||||
set -- $(formail -c -x References -x Reference < "$patch")
|
||||
references="$*"
|
||||
}
|
||||
|
||||
patch_log_entry() {
|
||||
local patch=$1 subject references old_subj old_ref old_patch="$tmpdir/old"
|
||||
|
||||
git show "HEAD:$patch" >"$old_patch" 2>/dev/null
|
||||
patch_meta "$old_patch"
|
||||
old_subj="$subject"
|
||||
old_ref="$references"
|
||||
|
||||
patch_meta "$patch"
|
||||
|
||||
local msg
|
||||
if test -z "$subject" -o "$subject" != "$old_subj"; then
|
||||
msg="$subject${references:+ ($references)}"
|
||||
elif test "$references" != "$old_ref"; then
|
||||
if test -n "$references"; then
|
||||
msg="Update references ($references)"
|
||||
fi
|
||||
else
|
||||
msg="Refresh"
|
||||
fi
|
||||
|
||||
log_entry "$patch: $msg${msg:+.}"
|
||||
}
|
||||
|
||||
find_patches() {
|
||||
osc diff series.conf \
|
||||
| sed -n "s/^+\s*\(patches.*\)/\1/p"
|
||||
}
|
||||
|
||||
for file in "$@" $(find_patches); do
|
||||
dirname=$(dirname $file)
|
||||
basename=$(basename $file)
|
||||
archive=$dirname.tar.bz2
|
||||
|
||||
if [ ! -f $basename ]; then
|
||||
echo "ERROR: $basename added to series.conf but doesn't exist in $PWD"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [ ! -d $dirname ]; then
|
||||
tar xvf $archive
|
||||
fi
|
||||
|
||||
mv $basename $dirname
|
||||
rm $archive
|
||||
tar cfj $archive $dirname
|
||||
|
||||
files[${#files[@]}]=$file
|
||||
done
|
||||
|
||||
if [ ${#files[@]} -eq 0 ]; then
|
||||
echo "No modified files" >&2
|
||||
exit 1
|
||||
fi
|
||||
|
||||
for file in "${files[@]}"; do
|
||||
if [ "${file:0:1}" = - ]; then
|
||||
log_entry "${file:1}: Delete."
|
||||
else
|
||||
case "$file" in
|
||||
config/*)
|
||||
if [ -z "$configs_updated" ]; then
|
||||
log_entry "Update config files."
|
||||
configs_updated=1
|
||||
fi
|
||||
;;
|
||||
|
||||
patches.*)
|
||||
patch_log_entry "$file"
|
||||
;;
|
||||
|
||||
kabi/*/symvers-* | kabi/*/symtypes-* | kabi/*/symsets-* )
|
||||
if [ -z "$symvers_updated" ]; then
|
||||
log_entry "Update reference module symbol versions."
|
||||
symvers_updated=1
|
||||
fi
|
||||
;;
|
||||
|
||||
series.conf)
|
||||
# don't log changes in there
|
||||
;;
|
||||
|
||||
*)
|
||||
log_entry "$file: "
|
||||
;;
|
||||
esac
|
||||
fi
|
||||
done
|
||||
|
||||
if [ ! -s $message ]; then
|
||||
echo "- " >> $message
|
||||
fi
|
||||
|
||||
if osc vc $CHANGES $message; then
|
||||
entry=$(sed -ne '1,2d' -e '/^--*$/!p' -e '/^--*$/q' $CHANGES)
|
||||
entry=${entry##$'\n'}
|
||||
entry=${entry%%$'\n'}
|
||||
fi
|
||||
|
||||
for c in *.changes; do
|
||||
[ $c = $CHANGES ] && continue
|
||||
cp $CHANGES $c
|
||||
done
|
43
macros.kernel-source
Normal file
43
macros.kernel-source
Normal file
@ -0,0 +1,43 @@
|
||||
# A few cross-distro definitions:
|
||||
%kernel_module_package_release 1
|
||||
%kernel_module_package_buildreqs module-init-tools kernel-syms
|
||||
|
||||
# Defines %flavors_to_build and %kernel_source() as a side effect.
|
||||
%_kernel_module_package(n:v:r:t:f:Xp:b) \
|
||||
%{expand:%( \
|
||||
subpkg=%{-t*}%{!-t:/usr/lib/rpm/kernel-module-subpackage} \
|
||||
echo "%%define _suse_kernel_module_subpackage(n:v:r:f:p:b) %%{expand:%%(cd %_sourcedir; cat $subpkg; echo %%%%nil)}" \
|
||||
flavors_to_build= \
|
||||
flavors="%*" \
|
||||
for flavor in $(ls /usr/src/linux-obj/%_target_cpu 2>/dev/null); do \
|
||||
case " $flavors " in \
|
||||
(*" $flavor "*) \
|
||||
[ -n "%{-X}" ] && continue ;; \
|
||||
(*) \
|
||||
[ -z "%{-X}" -a -n "$flavors" ] && continue ;; \
|
||||
esac \
|
||||
krel=$(make -s -C /usr/src/linux-obj/%_target_cpu/$flavor kernelrelease) \
|
||||
kver=${krel%%-*} \
|
||||
flavors_to_build="$flavors_to_build $flavor" \
|
||||
echo "%%_suse_kernel_module_subpackage -n %{-n*}%{!-n:%name}-kmp -v %{-v*}%{!-v:%version} -r %{-r*}%{!-r:%release} %{-p} %{-b} $flavor $kver" \
|
||||
done \
|
||||
echo "%%global flavors_to_build${flavors_to_build:-%%nil}" \
|
||||
echo "%%{expand:%%(test -z '%flavors_to_build' && echo %%%%internal_kmp_error)}" \
|
||||
echo "%%global kernel_source() /usr/src/linux-obj/%_target_cpu/%%%%{1}" \
|
||||
echo "%%global kernel_module_package_moddir() updates" \
|
||||
\
|
||||
echo "%package -n %{-n*}%{!-n:%name}-kmp-_dummy_" \
|
||||
echo "Version: %version" \
|
||||
echo "Summary: %summary" \
|
||||
echo "Group: %group" \
|
||||
echo "%description -n %{-n*}%{!-n:%name}-kmp-_dummy_" \
|
||||
)}
|
||||
|
||||
# kernel_module_package: simply pass on all options and arguments.
|
||||
%kernel_module_package(n:v:r:t:f:xp:b) \
|
||||
%{expand:%%_kernel_module_package %{-x:-X} %{-n} %{-v} %{-r} %{-t} %{-f} %{-p} %*}
|
||||
|
||||
# suse_kernel_module_package: invert the meaning of the -x flag. (You are not
|
||||
# supposed to understand why a simple %{-x:}%{!-x:-x} won't work.)
|
||||
%suse_kernel_module_package(n:v:r:s:f:xp:b) \
|
||||
%{expand:%%_kernel_module_package %{-x: }%{!-x:-X} %{-n} %{-v} %{-r} %{-s:-t %{-s*}} %{-f} %{-p} %*}
|
329
mkspec
Normal file
329
mkspec
Normal file
@ -0,0 +1,329 @@
|
||||
#!/usr/bin/perl
|
||||
|
||||
use strict;
|
||||
use warnings;
|
||||
|
||||
use File::Copy;
|
||||
use Getopt::Long;
|
||||
|
||||
my $dir = ".";
|
||||
my $rpmrelease;
|
||||
my $patches="";
|
||||
|
||||
GetOptions(
|
||||
"patches=s" => \$patches,
|
||||
"release=s" => \$rpmrelease
|
||||
) or die "Usage: $0 [--release <release>] [--patches <dir>]\n";
|
||||
|
||||
# flavor -> [supported archs]
|
||||
my %flavor_archs = parse_config_conf();
|
||||
# subset to include in kernel-syms
|
||||
my %syms_flavor_archs = parse_config_conf("syms");
|
||||
|
||||
# template name -> template body
|
||||
my %templates = read_spec_templates();
|
||||
|
||||
# config.sh variables
|
||||
my %vars = parse_config_sh();
|
||||
my ($srcversion, $variant, $vanilla_only) =
|
||||
($vars{'SRCVERSION'}, $vars{'VARIANT'}, $vars{'VANILLA_ONLY'});
|
||||
$vanilla_only ||= "0";
|
||||
|
||||
# rpm changelog
|
||||
my $changelog = convert_changes();
|
||||
|
||||
# package name -> [summary, description]
|
||||
my %binary_descriptions = parse_descriptions();
|
||||
|
||||
$patches="--patches $patches" if $patches;
|
||||
my $patchversion = `$dir/compute-PATCHVERSION.sh $patches`;
|
||||
chomp $patchversion;
|
||||
my $rpmversion = $patchversion;
|
||||
# stuff the -rcX tag into the rpm version if possible;
|
||||
$rpmversion =~ s/\.0-rc/.rc/;
|
||||
$rpmversion =~ s/-rc\d+//;
|
||||
$rpmversion =~ s/-/./g;
|
||||
|
||||
if (defined($rpmrelease)) {
|
||||
# convince abuild that we really want this release number
|
||||
xopen(my $fh, '>', "$dir/get_release_number.sh");
|
||||
print $fh "#!/bin/sh\n";
|
||||
print $fh "echo \"$rpmrelease.0\"\n";
|
||||
close($fh);
|
||||
chmod(0755, "$dir/get_release_number.sh");
|
||||
} else {
|
||||
$rpmrelease = "";
|
||||
}
|
||||
$rpmrelease =~ s/[^.]$/$&./;
|
||||
$rpmrelease =~ s/-/./g;
|
||||
|
||||
my $sources = join("", $templates{source} =~ /\nSource\d+:[^\n]*/mg);
|
||||
# Find all SourceN: foo.tar.bz2 lines and generate the NoSource:
|
||||
# lines and the %setup line
|
||||
my @tarballs = ($sources =~ /\nSource(\d+):[^\n]*\.tar\.bz2/mg);
|
||||
my $nosource = join("\n", map { "NoSource: $_" } @tarballs);
|
||||
# Source0 (the linux tarball) is unpacked manually
|
||||
@tarballs = grep { $_ > 0 } @tarballs;
|
||||
my $unpack_patches = join(" ", map { "-a $_" } @tarballs);
|
||||
# List of scripts to automatically chmod +x before build
|
||||
my $scripts = join(",", grep { is_script($_) }
|
||||
($sources =~ /\nSource\d+:\s*([^\s]*)/mg));
|
||||
|
||||
my %macros = (
|
||||
VARIANT => $variant,
|
||||
VANILLA_ONLY => $vanilla_only,
|
||||
SRCVERSION => $srcversion,
|
||||
PATCHVERSION => $patchversion,
|
||||
RPMVERSION => $rpmversion,
|
||||
RELEASE_PREFIX => $rpmrelease,
|
||||
SOURCES => $sources,
|
||||
NOSOURCE => $nosource,
|
||||
UNPACK_PATCHES => $unpack_patches,
|
||||
SCRIPTS => $scripts,
|
||||
);
|
||||
|
||||
# binary spec files
|
||||
for my $flavor (sort keys(%flavor_archs)) {
|
||||
my ($summary, $description);
|
||||
if (!exists($binary_descriptions{"kernel-$flavor"})) {
|
||||
print STDERR "warning: no description for kernel-$flavor found\n";
|
||||
$summary = "The Linux Kernel";
|
||||
$description = "The Linux Kernel.";
|
||||
} else {
|
||||
$summary = $binary_descriptions{"kernel-$flavor"}->[0];
|
||||
$description = $binary_descriptions{"kernel-$flavor"}->[1];
|
||||
}
|
||||
|
||||
do_spec('binary', "kernel-$flavor.spec", %macros,
|
||||
FLAVOR => $flavor,
|
||||
SUMMARY => $summary,
|
||||
DESCRIPTION => $description,
|
||||
ARCHS => join(" ", arch2rpm(@{$flavor_archs{$flavor}})),
|
||||
PROVIDES_OBSOLETES => provides_obsoletes($flavor, @{$flavor_archs{$flavor}}),
|
||||
);
|
||||
}
|
||||
# kernel-source.spec
|
||||
do_spec('source', "kernel-source$variant.spec", %macros);
|
||||
|
||||
# kernel-docs.spec
|
||||
do_spec('docs', "kernel-docs$variant.spec", %macros);
|
||||
|
||||
# kernel-syms.spec
|
||||
{
|
||||
my $requires = "";
|
||||
my %all_archs;
|
||||
for my $flavor (sort keys(%syms_flavor_archs)) {
|
||||
next if $flavor eq "vanilla";
|
||||
my @archs = arch2rpm(@{$syms_flavor_archs{$flavor}});
|
||||
$all_archs{$_} = 1 for @archs;
|
||||
$requires .= "%ifarch @archs\n";
|
||||
$requires .= "Requires: kernel-$flavor-devel = \%version-\%source_rel\n";
|
||||
$requires .= "%endif\n";
|
||||
}
|
||||
chomp $requires;
|
||||
if (keys(%all_archs)) {
|
||||
do_spec('syms', "kernel-syms$variant.spec", %macros,
|
||||
REQUIRES => $requires,
|
||||
ARCHS => join(" ", sort(keys(%all_archs))));
|
||||
}
|
||||
}
|
||||
|
||||
exit 0;
|
||||
|
||||
|
||||
|
||||
sub parse_config_conf {
|
||||
my @symbols = @_;
|
||||
my $symbols = join(' ', @symbols);
|
||||
my %res;
|
||||
|
||||
for my $arch (split(/\s+/, `$dir/arch-symbols --list`)) {
|
||||
my @flavors = `$dir/guards $arch $symbols < $dir/config.conf`;
|
||||
next if @flavors == 0;
|
||||
chomp @flavors;
|
||||
@flavors = map { s/.*\///; $_ } @flavors;
|
||||
for my $flavor (@flavors) {
|
||||
$res{$flavor} ||= [];
|
||||
push(@{$res{$flavor}}, $arch);
|
||||
}
|
||||
}
|
||||
for my $flavor (keys(%res)) {
|
||||
$res{$flavor} = [sort @{$res{$flavor}}];
|
||||
}
|
||||
return %res;
|
||||
}
|
||||
|
||||
sub read_spec_templates {
|
||||
my %res;
|
||||
|
||||
for my $template (qw(binary source syms docs)) {
|
||||
xopen(my $fh, '<', "$dir/kernel-$template.spec.in");
|
||||
local $/ = undef;
|
||||
$res{$template} = <$fh>;
|
||||
close($fh);
|
||||
}
|
||||
return %res;
|
||||
}
|
||||
|
||||
# return a hash of config.sh variables
|
||||
sub parse_config_sh {
|
||||
my %res;
|
||||
|
||||
xopen(my $fh, '<', "$dir/config.sh");
|
||||
while (<$fh>) {
|
||||
chomp;
|
||||
if (/^\s*([A-Z_]+)=(.*)/) {
|
||||
$res{$1} = $2;
|
||||
}
|
||||
}
|
||||
close($fh);
|
||||
return %res;
|
||||
}
|
||||
|
||||
# convert kernel-source.changes to rpm changelog
|
||||
sub convert_changes {
|
||||
my $res = "\%changelog\n";
|
||||
my @progs = qw(/usr/lib/build/changelog2spec
|
||||
/work/src/bin/tools/convert_changes_to_rpm_changelog);
|
||||
|
||||
my $changesfile = "$dir/kernel-source$variant.changes";
|
||||
if (-e $changesfile) {
|
||||
for my $prog (@progs) {
|
||||
if (-x $prog) {
|
||||
$res .= `$prog $changesfile`;
|
||||
last;
|
||||
}
|
||||
}
|
||||
}
|
||||
chomp $res;
|
||||
return $res;
|
||||
}
|
||||
|
||||
sub parse_descriptions {
|
||||
my %res;
|
||||
my $current;
|
||||
my $blank = "";
|
||||
# 0 - expect summary, 1 - eating blank lines, 2 - reading description
|
||||
my $state = 0;
|
||||
|
||||
xopen(my $fh, '<', "$dir/package-descriptions");
|
||||
while (<$fh>) {
|
||||
next if /^\s*#/;
|
||||
|
||||
if (/^==+\s+([^\s]+)\s+==+\s*$/) {
|
||||
my $package = $1;
|
||||
if ($current) {
|
||||
chomp $current->[1];
|
||||
}
|
||||
$current = ["", ""];
|
||||
$res{$package} = $current;
|
||||
$state = 0;
|
||||
next;
|
||||
}
|
||||
if (/^$/) {
|
||||
if ($state == 2) {
|
||||
$blank .= $_;
|
||||
}
|
||||
next;
|
||||
}
|
||||
# non-blank line and not === package ===
|
||||
if ($state == 0) {
|
||||
chomp;
|
||||
$current->[0] = $_;
|
||||
$state = 1;
|
||||
} elsif ($state == 1) {
|
||||
$current->[1] = $_;
|
||||
$blank = "";
|
||||
$state = 2;
|
||||
} else {
|
||||
$current->[1] .= $blank;
|
||||
$blank = "";
|
||||
$current->[1] .= $_;
|
||||
}
|
||||
}
|
||||
if ($current) {
|
||||
chomp $current->[1];
|
||||
}
|
||||
close($fh);
|
||||
return %res;
|
||||
}
|
||||
|
||||
sub is_script {
|
||||
my $script = shift;
|
||||
|
||||
return undef if $script =~ /\.(tar\.(gz|bz2)|in|conf)$/;
|
||||
return undef if $script =~ /^README/;
|
||||
return 1 if $script =~ /\.pl$/;
|
||||
open(my $fh, '<', $script) or return undef;
|
||||
sysread($fh, my $shebang, 2);
|
||||
close($fh);
|
||||
return 1 if $shebang eq "#!";
|
||||
return undef;
|
||||
}
|
||||
|
||||
sub arch2rpm {
|
||||
if (wantarray) {
|
||||
return map { _arch2rpm($_) } @_;
|
||||
}
|
||||
return _arch2rpm($_[0]);
|
||||
}
|
||||
sub _arch2rpm {
|
||||
my $arch = shift;
|
||||
return "\%ix86" if $arch eq "i386";
|
||||
return $arch;
|
||||
}
|
||||
|
||||
sub append_changelog {
|
||||
my $changelog = $_[1];
|
||||
if ($_[0] =~ s/\%changelog$/$changelog/) {
|
||||
return;
|
||||
}
|
||||
$_[0] .= $changelog;
|
||||
}
|
||||
|
||||
sub provides_obsoletes {
|
||||
my $flavor = shift;
|
||||
my @archs = @_;
|
||||
my $res = "";
|
||||
|
||||
for my $arch (@archs) {
|
||||
my @packs = `$dir/guards $arch $flavor <$dir/old-packages.conf`;
|
||||
chomp @packs;
|
||||
next if (!@packs);
|
||||
my $rpmarch = arch2rpm($arch);
|
||||
chomp $rpmarch;
|
||||
$res .= "\%ifarch $rpmarch\n";
|
||||
$res .= "Provides: @packs\n";
|
||||
$res .= "Obsoletes: @packs\n";
|
||||
$res .= "\%endif\n";
|
||||
}
|
||||
chomp $res;
|
||||
return $res;
|
||||
}
|
||||
|
||||
sub do_spec {
|
||||
my $template = shift;
|
||||
my $specfile = shift;
|
||||
my %macros = @_;
|
||||
|
||||
my $text = $templates{$template};
|
||||
for my $m (keys %macros) {
|
||||
$text =~ s/\@$m\@/$macros{$m}/g;
|
||||
}
|
||||
append_changelog($text, $changelog);
|
||||
print "$specfile\n";
|
||||
xopen(my $fh, '>', "$dir/$specfile");
|
||||
print $fh $text;
|
||||
close($fh);
|
||||
|
||||
return if $specfile eq "kernel-source$variant.spec";
|
||||
my $changesfile = $specfile;
|
||||
$changesfile =~ s/\.spec$//;
|
||||
$changesfile .= ".changes";
|
||||
copy("$dir/kernel-source$variant.changes", $changesfile);
|
||||
}
|
||||
|
||||
sub xopen {
|
||||
open($_[0], $_[1], $_[2]) or die "$_[2]: $!\n";
|
||||
}
|
||||
|
158
modversions
Normal file
158
modversions
Normal file
@ -0,0 +1,158 @@
|
||||
#! /usr/bin/perl -w
|
||||
|
||||
use File::Basename;
|
||||
use File::Path;
|
||||
use File::Find;
|
||||
use Getopt::Long;
|
||||
use strict;
|
||||
|
||||
my %symbol_type_name = (
|
||||
n => 'normal', t => 'typedef', e => 'enum', s => 'struct', u => 'union',
|
||||
E => 'enum constant'
|
||||
);
|
||||
|
||||
my %definitions;
|
||||
my %override;
|
||||
my %override_locally;
|
||||
my %locally_unknown;
|
||||
my %locally_defined;
|
||||
|
||||
sub expand_types($);
|
||||
sub expand_types($) {
|
||||
my ($definition) = @_;
|
||||
local ($_, $1, $2);
|
||||
|
||||
my @defn = split ' ', $definition;
|
||||
for (@defn[1..$#defn]) {
|
||||
if (/^(.)#(.*)/) {
|
||||
#print "<<$defn[0] : $_>>\n";
|
||||
next if exists $locally_defined{$_};
|
||||
$locally_defined{$_} = 1;
|
||||
|
||||
if ($locally_unknown{$_}) {
|
||||
print "override " if $override_locally{$_};
|
||||
print "$_ $symbol_type_name{$1} $2 { UNKNOWN } \n";
|
||||
} else {
|
||||
if (!exists $definitions{$_}) {
|
||||
die "Missing definition of $symbol_type_name{$1} $2\n";
|
||||
}
|
||||
expand_types("$_ $definitions{$_}");
|
||||
}
|
||||
}
|
||||
}
|
||||
print "override " if $override_locally{$defn[0]};
|
||||
print "$definition\n";
|
||||
}
|
||||
|
||||
sub pack_dump($$) {
|
||||
my ($dir, $ext) = @_;
|
||||
my @files;
|
||||
|
||||
$ext = ".symtypes" unless defined $ext;
|
||||
$dir =~ s/\/+$//;
|
||||
|
||||
find(sub ($) { /\Q$ext\E$/ && push @files, $File::Find::name}, $dir);
|
||||
map { s/^\Q$dir\E\/(.*)\Q$ext\E$/$1/ } @files;
|
||||
|
||||
foreach my $file (sort @files) {
|
||||
print "/* $file.o */\n";
|
||||
|
||||
local *FD;
|
||||
open FD, "< $dir/$file$ext"
|
||||
or die "$dir/$file$ext: $!\n";
|
||||
while (<FD>) {
|
||||
chomp;
|
||||
|
||||
my $override = "";
|
||||
if (s/^override //) {
|
||||
$override = $&;
|
||||
}
|
||||
|
||||
if (/^(\S)#(\S+)\s*(.*)/) {
|
||||
my $sym = "$1#$2";
|
||||
my $definition = $3;
|
||||
|
||||
if (/^$sym\s+$symbol_type_name{$1}\s+$2\s+{\s+UNKNOWN\s+}\s*$/) {
|
||||
$_ = $override . substr($sym, 0, 1) . "##" . substr($sym, 2);
|
||||
} else {
|
||||
if (exists $definitions{$sym} && $definitions{$sym} eq $definition) {
|
||||
if (($override ne "") == (exists $override{$sym})) {
|
||||
next;
|
||||
}
|
||||
$_ = "$override$sym";
|
||||
} else {
|
||||
$definitions{$sym} = $definition;
|
||||
if ($override eq "") {
|
||||
delete $override{$sym};
|
||||
} else {
|
||||
$override{$sym} = 1;
|
||||
$_ = "$override$_";
|
||||
}
|
||||
}
|
||||
}
|
||||
} elsif ($override) {
|
||||
$_ = "$override$_";
|
||||
}
|
||||
print "$_\n";
|
||||
}
|
||||
close FD;
|
||||
print "\n";
|
||||
}
|
||||
}
|
||||
|
||||
sub unpack_dump($$) {
|
||||
my ($dir, $ext) = @_;
|
||||
|
||||
$ext = ".symref" unless defined $ext;
|
||||
|
||||
while (<STDIN>) {
|
||||
next if /^$/;
|
||||
chomp;
|
||||
|
||||
if (/^\/\* (.*)\.o \*\//) {
|
||||
close STDOUT;
|
||||
mkpath(dirname("$dir/$1$ext"));
|
||||
open STDOUT, "> $dir/$1$ext"
|
||||
or die "$dir/$1$ext: $!\n";
|
||||
%locally_defined = ();
|
||||
%locally_unknown = ();
|
||||
%override_locally = %override;
|
||||
next;
|
||||
}
|
||||
|
||||
my $override = /^override\s/;
|
||||
s/^override\s//;
|
||||
|
||||
if (/^([^ ])#(#?)([^ ]+) *(.*)$/) {
|
||||
my $sym = "$1#$3";
|
||||
|
||||
if ($4 ne "") {
|
||||
if (/\s+{\s+UNKNOWN\s+}\s*$/) {
|
||||
$locally_unknown{$sym} = 1;
|
||||
$override_locally{$sym} = $override;
|
||||
} else {
|
||||
$definitions{$sym} = $4;
|
||||
$locally_unknown{$sym} = 0;
|
||||
$override{$sym} = $override;
|
||||
$override_locally{$sym} = $override;
|
||||
}
|
||||
} else {
|
||||
$locally_unknown{$sym} = ($2 ne "");
|
||||
$override_locally{$sym} = $override;
|
||||
}
|
||||
next;
|
||||
} elsif (/^([^# ]*)/) {
|
||||
$override_locally{$1} = $override;
|
||||
}
|
||||
expand_types($_);
|
||||
}
|
||||
}
|
||||
|
||||
my ($pack, $unpack, $ext);
|
||||
GetOptions("pack" => \$pack, "unpack" => \$unpack, "ext:s" => \$ext)
|
||||
&& ($pack || $unpack) && @ARGV == 1
|
||||
or die "USAGE:\t$0 [--ext extension] --pack {dir} > file\n" .
|
||||
"\t$0 [--ext extension] --unpack {dir} < file\n";
|
||||
|
||||
pack_dump($ARGV[0], $ext) if $pack;
|
||||
unpack_dump($ARGV[0], $ext) if $unpack;
|
1
needed_space_in_mb
Normal file
1
needed_space_in_mb
Normal file
@ -0,0 +1 @@
|
||||
6144
|
36
old-packages.conf
Normal file
36
old-packages.conf
Normal file
@ -0,0 +1,36 @@
|
||||
# Defines which package names to include in the Provides and
|
||||
# Obsoletes tags of spec files.
|
||||
#
|
||||
# When generating Provides, `p' is defined. When generating
|
||||
# Obsoletes, `o' is defined.
|
||||
#
|
||||
# +ARCH: include only for this architecture.
|
||||
# -!symbol: exclude unless symbol is also defined.
|
||||
#
|
||||
# Guards are always evaluated from left to right; the last
|
||||
# guard that matches determines whether a line is included
|
||||
# or not.
|
||||
#
|
||||
# For testing this file, run scripts/old-config.sh.
|
||||
#
|
||||
|
||||
# i386 =================================================================
|
||||
+i386 -!default smp kernel-smp
|
||||
|
||||
+i386 -!pae kernel-bigsmp
|
||||
|
||||
# x86_64 ===============================================================
|
||||
+x86_64 -!default smp kernel-smp
|
||||
|
||||
# ia64 =================================================================
|
||||
+ia64 -!default kernel-sn2
|
||||
|
||||
# ppc/ppc64 ============================================================
|
||||
|
||||
+ppc -!ppc64 kernel-pmac64 kernel-pseries64 kernel-iseries64
|
||||
+ppc64 -vanilla kernel-kdump
|
||||
|
||||
# s390/s390x ===========================================================
|
||||
+s390 -!s390 kernel-32bit
|
||||
|
||||
+s390x -!s390x kernel-64bit
|
123
package-descriptions
Normal file
123
package-descriptions
Normal file
@ -0,0 +1,123 @@
|
||||
# Descriptions of the binary kernel packages. The format is
|
||||
#
|
||||
# === <package name> ===
|
||||
# Summary (single line)
|
||||
#
|
||||
# Long description (multiple
|
||||
# lines)
|
||||
#
|
||||
# Descriptions of the -base and -extra subpackages are derived from the
|
||||
# main descriptions.
|
||||
|
||||
=== kernel-debug ===
|
||||
A Debug Version of the Kernel
|
||||
|
||||
This kernel has several debug facilities enabled that hurt performance.
|
||||
Only use this kernel when investigating problems.
|
||||
|
||||
=== kernel-default ===
|
||||
The Standard Kernel
|
||||
|
||||
The standard kernel for both uniprocessor and multiprocessor systems.
|
||||
|
||||
=== kernel-desktop ===
|
||||
Kernel optimized for the desktop
|
||||
|
||||
This kernel is optimized for the desktop. It is configured for lower latency
|
||||
and has many of the features that aren't usually used on desktop machines
|
||||
disabled.
|
||||
|
||||
%ifarch %ix86
|
||||
This kernel supports up to 64GB of main memory. It requires Physical
|
||||
Addressing Extensions (PAE), which were introduced with the Pentium Pro
|
||||
processor.
|
||||
|
||||
PAE is not only more physical address space but also important for the
|
||||
"no execute" feature which disables execution of code that is marked as
|
||||
non-executable. Therefore, the PAE kernel should be used on any systems
|
||||
that support it, regardless of the amount of main memory.
|
||||
%endif
|
||||
|
||||
=== kernel-kdump ===
|
||||
kernel for kdump
|
||||
|
||||
This kernel is intended for kdump. It can not be booted with a normal
|
||||
bootloader, the kexec tool has to be used to load it. Once the system
|
||||
crashes, the loaded kernel will be started to grab debug info from the
|
||||
crashed kernel.
|
||||
|
||||
=== kernel-net ===
|
||||
Minimal kernel with disk and net support
|
||||
|
||||
This kernel carries only networking and disk drivers to fit into the
|
||||
standard Sun OpenBoot download buffer, and is intended for the
|
||||
initial install and rescue mode only.
|
||||
|
||||
=== kernel-pae ===
|
||||
Kernel with PAE Support
|
||||
|
||||
This kernel supports up to 64GB of main memory. It requires Physical
|
||||
Addressing Extensions (PAE), which were introduced with the Pentium Pro
|
||||
processor.
|
||||
|
||||
PAE is not only more physical address space but also important for the
|
||||
"no execute" feature which disables execution of code that is marked as
|
||||
non-executable. Therefore, the PAE kernel should be used on any systems
|
||||
that support it, regardless of the amount of main memory.
|
||||
|
||||
=== kernel-ppc64 ===
|
||||
Kernel for ppc64 Systems
|
||||
|
||||
This package contains the kernel for:
|
||||
|
||||
IBM pSeries 64bit machines IBM iSeries 64bit machines Apple G5 machines
|
||||
Sony Playstation 3
|
||||
|
||||
The boot file is /boot/vmlinux.
|
||||
|
||||
The home page of the ppc64 project is http://www.penguinppc.org/
|
||||
|
||||
=== kernel-ps3 ===
|
||||
kernel for ps3 bootloader
|
||||
|
||||
This package contains the kernel for the PS3 bootloader. PS3 systems
|
||||
only have 4MB of flash memory for the bootloader, so this kernel needs
|
||||
to be as small as possible and is _not_ meant to be installed in the
|
||||
final system.
|
||||
|
||||
=== kernel-s390 ===
|
||||
The Standard Kernel
|
||||
|
||||
The standard kernel.
|
||||
|
||||
=== kernel-trace ===
|
||||
The Standard Kernel with Tracing Features
|
||||
|
||||
This kernel has different tracing features enabled (e.g. utrace, ftrace).
|
||||
|
||||
=== kernel-vanilla ===
|
||||
The Standard Kernel - without any SUSE patches
|
||||
|
||||
The standard kernel - without any SUSE patches
|
||||
|
||||
=== kernel-xen ===
|
||||
The Xen Kernel
|
||||
|
||||
The Linux kernel for Xen paravirtualization.
|
||||
|
||||
This kernel can be used both as the domain0 ("xen0") and as an
|
||||
unprivileged ("xenU") kernel.
|
||||
|
||||
=== kernel-ec2 ===
|
||||
The Amazon EC2 Xen Kernel
|
||||
|
||||
The Linux kernel for Xen paravirtualization.
|
||||
|
||||
This kernel can only be used both as an unprivileged ("xenU")
|
||||
kernel (for Amazon EC2).
|
||||
|
||||
=== kernel-vmi ===
|
||||
VMI-enabled kernel
|
||||
|
||||
The Linux Kernel designed to run on top of a virtual machine
|
||||
interface layer (VMI).
|
3
patches.addon.tar.bz2
Normal file
3
patches.addon.tar.bz2
Normal file
@ -0,0 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:f40cf2e5bb426f03e8b22d891ab32ee3ed9a52de14a38ea09b826cf15ad00fb5
|
||||
size 129
|
3
patches.apparmor.tar.bz2
Normal file
3
patches.apparmor.tar.bz2
Normal file
@ -0,0 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:e983af76e408802b165419548b17ed95e8d7b5765022505f9e8665ee3bfbbae2
|
||||
size 8006
|
3
patches.arch.tar.bz2
Normal file
3
patches.arch.tar.bz2
Normal file
@ -0,0 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:2ebdb967856ac0c240facb7e8c715ce48dd7d11768d7074e0ba66413317f0e02
|
||||
size 73885
|
3
patches.drivers.tar.bz2
Normal file
3
patches.drivers.tar.bz2
Normal file
@ -0,0 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:4f6e0520039a0a8c9132e519f5c4870dfdfb76b7b101f1b4645fccdca4f0041f
|
||||
size 8125
|
3
patches.fixes.tar.bz2
Normal file
3
patches.fixes.tar.bz2
Normal file
@ -0,0 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:0e39c181a85b824637f0a98221735145247405f7823c3982ec8de6210e67e10a
|
||||
size 22095
|
3
patches.kabi.tar.bz2
Normal file
3
patches.kabi.tar.bz2
Normal file
@ -0,0 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:8f17122f387e72f1e0cb4acb99148e8363b2e0d5aeeef4543b5750be0e0f290e
|
||||
size 129
|
3
patches.kernel.org.tar.bz2
Normal file
3
patches.kernel.org.tar.bz2
Normal file
@ -0,0 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:9dde5510f9ad1aef9c1f1d3b2a8099a006fe55fdab5ebcf2c141624b999d057e
|
||||
size 136
|
3
patches.rpmify.tar.bz2
Normal file
3
patches.rpmify.tar.bz2
Normal file
@ -0,0 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:2e86f169745ea6c3ff4443990499f338833d5c32346e99a3ad0fec9f735a0dfa
|
||||
size 4336
|
3
patches.rt.tar.bz2
Normal file
3
patches.rt.tar.bz2
Normal file
@ -0,0 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:6a5f1b075a51886cf01e54334bddd9c8a8aa9494e87dcdf6f9a19a618e3594f4
|
||||
size 127
|
3
patches.suse.tar.bz2
Normal file
3
patches.suse.tar.bz2
Normal file
@ -0,0 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:320895a49a085e5abd93be597461e1977f5fd0bda3ce43bd1ccb2c39d042ebbc
|
||||
size 182402
|
3
patches.trace.tar.bz2
Normal file
3
patches.trace.tar.bz2
Normal file
@ -0,0 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:bd54649991cae30e0821c52287c3b16425206921d2cb1835feb6918e73855563
|
||||
size 131
|
3
patches.xen.tar.bz2
Normal file
3
patches.xen.tar.bz2
Normal file
@ -0,0 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:2f95b0875e23b1efc4e33deb9f13a31f615cdd4aab12e6599fecad7ddd6ea63d
|
||||
size 2039442
|
100
post.sh
Normal file
100
post.sh
Normal file
@ -0,0 +1,100 @@
|
||||
# Flag to trigger /etc/init.d/purge-kernels on next reboot (fate#312018)
|
||||
touch /boot/do_purge_kernels
|
||||
|
||||
# It must be possible to install different kernel.rpm packages in parallel.
|
||||
# But in this post install script, the /boot/vmlinux symlink is replaced.
|
||||
# On powerpc, the different kernels are for different board/firmware types
|
||||
# They are not compatible.
|
||||
wrong_boardtype() {
|
||||
echo "This kernel-@FLAVOR@.@RPM_TARGET_CPU@.rpm is for $1, it will not boot on this system."
|
||||
echo "The /boot/vmlinux symlink will not be created or updated."
|
||||
exit 0
|
||||
}
|
||||
if [ -f /proc/cpuinfo ]; then
|
||||
case "@FLAVOR@-@RPM_TARGET_CPU@" in
|
||||
vanilla-ppc64|default-ppc64|ps3-ppc64|ppc64-ppc64|kdump-ppc64|ps3-ppc|ppc64-ppc|kdump-ppc)
|
||||
if [ -d /proc/iSeries -o ! -d /proc/ppc64 ]; then
|
||||
wrong_boardtype "OpenFirmware based 64bit machines"
|
||||
fi
|
||||
;;
|
||||
vanilla-ppc|default-ppc)
|
||||
if [ -d /proc/ppc64 -o -d /proc/iSeries ]; then
|
||||
wrong_boardtype "32bit systems"
|
||||
fi
|
||||
;;
|
||||
*)
|
||||
;;
|
||||
esac
|
||||
fi
|
||||
|
||||
suffix=
|
||||
case @FLAVOR@ in
|
||||
kdump|ps3|xen*|ec2|vanilla)
|
||||
suffix=-@FLAVOR@
|
||||
;;
|
||||
esac
|
||||
for x in /boot/@IMAGE@ /boot/initrd; do
|
||||
rm -f $x$suffix
|
||||
ln -s ${x##*/}-@KERNELRELEASE@-@FLAVOR@ $x$suffix
|
||||
done
|
||||
|
||||
# Add symlinks of compatible modules to /lib/modules/$krel/weak-updates/,
|
||||
# run depmod and mkinitrd
|
||||
wm2=/usr/lib/module-init-tools/weak-modules2
|
||||
if [ -x $wm2 ]; then
|
||||
if [ @BASE_PACKAGE@ = 1 ]; then
|
||||
/bin/bash -${-/e/} $wm2 --add-kernel @KERNELRELEASE@-@FLAVOR@
|
||||
else
|
||||
nvr=@SUBPACKAGE@-@RPM_VERSION_RELEASE@
|
||||
rpm -ql $nvr | /bin/bash -${-/e/} $wm2 --add-kernel-modules @KERNELRELEASE@-@FLAVOR@
|
||||
fi
|
||||
else
|
||||
echo "$wm does not exist, please run depmod and mkinitrd manually" >&2
|
||||
fi
|
||||
|
||||
message_install_bl () {
|
||||
echo "You may need to setup and install the boot loader using the"
|
||||
echo "available bootloader for your platform (e.g. grub, lilo, zipl, ...)."
|
||||
}
|
||||
|
||||
run_bootloader () {
|
||||
if [ -f /etc/sysconfig/bootloader ] &&
|
||||
[ -f /boot/grub/menu.lst -o \
|
||||
-f /etc/lilo.conf -o \
|
||||
-f /etc/elilo.conf -o \
|
||||
-f /etc/zipl.conf ]
|
||||
then
|
||||
return 0
|
||||
else
|
||||
return 1
|
||||
fi
|
||||
}
|
||||
|
||||
# exit out early for Moblin as we don't want to touch the bootloader menu
|
||||
if [ -f /etc/SuSE-moblin-release ] ; then
|
||||
exit 0
|
||||
fi
|
||||
|
||||
if [ -f /etc/fstab -a ! -e /.buildenv ] ; then
|
||||
# only run the bootloader if the usual bootloader configuration
|
||||
# files are there -- this is different on every architecture
|
||||
initrd=initrd-@KERNELRELEASE@-@FLAVOR@
|
||||
if [ -e /boot/$initrd -o ! -e /lib/modules/@KERNELRELEASE@-@FLAVOR@ ] && \
|
||||
run_bootloader ; then
|
||||
[ -e /boot/$initrd ] || initrd=
|
||||
if [ -x /usr/lib/bootloader/bootloader_entry ]; then
|
||||
/usr/lib/bootloader/bootloader_entry \
|
||||
add \
|
||||
@FLAVOR@ \
|
||||
@KERNELRELEASE@-@FLAVOR@ \
|
||||
@IMAGE@-@KERNELRELEASE@-@FLAVOR@ \
|
||||
$initrd
|
||||
else
|
||||
message_install_bl
|
||||
fi
|
||||
fi
|
||||
else
|
||||
message_install_bl
|
||||
fi
|
||||
|
||||
# vim: set sts=4 sw=4 ts=8 noet:
|
44
postun.sh
Normal file
44
postun.sh
Normal file
@ -0,0 +1,44 @@
|
||||
# If a kernel package is removed before the next reboot, we assume that the
|
||||
# multiversion variable in /etc/zypp/zypp.conf is not configured and we delete
|
||||
# the flag again (fate#312018)
|
||||
rm -f /boot/do_purge_kernels
|
||||
|
||||
wm2=/usr/lib/module-init-tools/weak-modules2
|
||||
nvr=@SUBPACKAGE@-@RPM_VERSION_RELEASE@
|
||||
|
||||
if [ -e /boot/System.map-@KERNELRELEASE@-@FLAVOR@ ]; then
|
||||
# the same package was reinstalled or just rebuilt, otherwise the files
|
||||
# would have been deleted by now
|
||||
# do not remove anything in this case (bnc#533766)
|
||||
rm -f /var/run/rpm-$nvr-modules
|
||||
exit 0
|
||||
fi
|
||||
|
||||
if [ @BASE_PACKAGE@ = 0 ]; then
|
||||
if [ -x $wm2 ]; then
|
||||
/bin/bash -${-/e/} $wm2 --remove-kernel-modules @KERNELRELEASE@-@FLAVOR@ < /var/run/rpm-$nvr-modules
|
||||
fi
|
||||
rm -f /var/run/rpm-$nvr-modules
|
||||
exit 0
|
||||
fi
|
||||
# Remove symlinks from /lib/modules/$krel/weak-updates/.
|
||||
if [ -x $wm2 ]; then
|
||||
/bin/bash -${-/e/} $wm2 --remove-kernel @KERNELRELEASE@-@FLAVOR@
|
||||
fi
|
||||
|
||||
# exit out early for Moblin as we don't want to touch the bootloader menu
|
||||
if [ -f /etc/SuSE-moblin-release ] ; then
|
||||
exit 0
|
||||
fi
|
||||
|
||||
# remove fstab check once perl-Bootloader can cope with it
|
||||
if [ -f /etc/fstab ]; then
|
||||
if [ -x /usr/lib/bootloader/bootloader_entry ]; then
|
||||
/usr/lib/bootloader/bootloader_entry \
|
||||
remove \
|
||||
@FLAVOR@ \
|
||||
@KERNELRELEASE@-@FLAVOR@ \
|
||||
@IMAGE@-@KERNELRELEASE@-@FLAVOR@ \
|
||||
initrd-@KERNELRELEASE@-@FLAVOR@
|
||||
fi
|
||||
fi
|
21
pre.sh
Normal file
21
pre.sh
Normal file
@ -0,0 +1,21 @@
|
||||
# see bug #259303
|
||||
# this script runs when the kernel gets updated with YaST
|
||||
# YaST calls rpm always with -U
|
||||
# -U replaces all packages with the new one
|
||||
# rpm removes the files from the old packages after the postinstall script ran
|
||||
# this will double the required space below /boot
|
||||
# remove the files from the old packages to make room for the new initrd
|
||||
# rpm may complain about low disk space if /boot/vmlinux does not fit
|
||||
if [ @BASE_PACKAGE@ = 1 -a "$YAST_IS_RUNNING" != "" ]; then
|
||||
mydf="$( POSIXLY_CORRECT=1 df -P /boot/ | awk '/^(\/|-[[:blank:]])/{ print $4}' )"
|
||||
if test "$mydf" != "" ; then
|
||||
echo "Free diskspace below /boot: $mydf blocks"
|
||||
# echo "512 byte blocks: $(( 2 * 1024 * 20 ))"
|
||||
if test "$mydf" -lt "40960" ; then
|
||||
echo "make room for new kernel '@FLAVOR@' because there are less than 20MB available."
|
||||
# disabled because it breaks patch rpms
|
||||
#rm -fv /boot/@IMAGE@-*-@FLAVOR@
|
||||
rm -fv /boot/initrd-*-@FLAVOR@
|
||||
fi
|
||||
fi
|
||||
fi
|
4
preun.sh
Normal file
4
preun.sh
Normal file
@ -0,0 +1,4 @@
|
||||
if [ @BASE_PACKAGE@ = 0 ]; then
|
||||
nvr=@SUBPACKAGE@-@RPM_VERSION_RELEASE@
|
||||
rpm -ql $nvr | grep '\.ko$' > /var/run/rpm-$nvr-modules
|
||||
fi
|
789
series.conf
Normal file
789
series.conf
Normal file
@ -0,0 +1,789 @@
|
||||
# Kernel patches configuration file
|
||||
# vim: set ts=8 sw=8 noet:
|
||||
#
|
||||
# There are three kinds of rules (see guards.1 for details):
|
||||
# +symbol include this patch if symbol is defined; otherwise exclude.
|
||||
# -symbol exclude this patch if symbol is defined; otherwise include.
|
||||
# - exclude this patch.
|
||||
#
|
||||
# Using symbols means that an entirely different source tree will be
|
||||
# generated depending on which symbols are defined. This used to be
|
||||
# a good thing when arch-specific patches contained conflicts with other
|
||||
# patches, but we now have a policy that patches must build everywhere.
|
||||
# The result is a unified source tree that allows us to do neat things
|
||||
# like ship kernel module packages. Creating a divergent tree breaks
|
||||
# these # so you'd better have an extraordinary reason for using them.
|
||||
# For example, the openSUSE 10.3 kernel uses them for segregating the
|
||||
# -rt patches until they can be integrated completely, and these are
|
||||
# only applied at the very end of the series.
|
||||
#
|
||||
# The most common use in recent kernels is to disable a patch with a
|
||||
# username as the symbol to indicate responsbility. Another use is
|
||||
# to check in a patch for testing, but have it disabled in all but your
|
||||
# own build environment.
|
||||
|
||||
########################################################
|
||||
# latest standard kernel patches
|
||||
# DO NOT MODIFY THEM!
|
||||
# Send separate patches upstream if you find a problem...
|
||||
########################################################
|
||||
|
||||
########################################################
|
||||
# Build fixes that apply to the vanilla kernel too.
|
||||
# Patches in patches.rpmify are applied to both -vanilla
|
||||
# and patched flavors.
|
||||
########################################################
|
||||
patches.rpmify/apm-honor-config_apm_cpu_idle-n
|
||||
patches.rpmify/nouveau-make-vga_switcheroo-code-depend-on-vga_switcheroo
|
||||
patches.rpmify/pti-depends-on-x86-pci
|
||||
|
||||
########################################################
|
||||
# kABI consistency patches
|
||||
########################################################
|
||||
|
||||
########################################################
|
||||
#
|
||||
# packaging-specific patches (tweaks for autobuild,
|
||||
# CONFIG_SUSE_KERNEL, config/version tracking and other
|
||||
# build stuff like that ...).
|
||||
#
|
||||
# Note that every patch in the patches.rpmify directory
|
||||
# will be included in the vanilla package.
|
||||
########################################################
|
||||
patches.rpmify/firmware-path
|
||||
|
||||
patches.rpmify/rpm-kernel-config
|
||||
patches.rpmify/split-package
|
||||
patches.rpmify/cloneconfig.diff
|
||||
|
||||
########################################################
|
||||
# kbuild/module infrastructure fixes
|
||||
########################################################
|
||||
patches.suse/supported-flag
|
||||
patches.suse/supported-flag-enterprise
|
||||
patches.suse/genksyms-add-override-flag.diff
|
||||
patches.suse/kconfig-automate-kernel-desktop
|
||||
|
||||
########################################################
|
||||
# Simple export additions/removals
|
||||
########################################################
|
||||
|
||||
########################################################
|
||||
# Bug workarounds for binutils
|
||||
########################################################
|
||||
|
||||
########################################################
|
||||
# Scheduler / Core
|
||||
########################################################
|
||||
patches.suse/setuid-dumpable-wrongdir
|
||||
|
||||
########################################################
|
||||
# Architecture-specific patches. These used to be all
|
||||
# at the end of series.conf, but since we don't do
|
||||
# conditional builds anymore, there's no point.
|
||||
########################################################
|
||||
|
||||
|
||||
########################################################
|
||||
# ia64
|
||||
########################################################
|
||||
|
||||
########################################################
|
||||
# i386
|
||||
########################################################
|
||||
|
||||
|
||||
# amd64 | x86-64 | x86_64
|
||||
# 'Intel(r) Extended Memory 64 Technology' | 'Intel(r) EM64T'
|
||||
# x64
|
||||
# Intel 64
|
||||
# "the architecture with too many names"
|
||||
# TAWTMN
|
||||
|
||||
########################################################
|
||||
# x86_64/i386 biarch
|
||||
########################################################
|
||||
patches.arch/x86_64-hpet-64bit-timer.patch
|
||||
|
||||
+needs_update patches.arch/kvm-split-paravirt-ops-by-functionality
|
||||
+needs_update patches.arch/kvm-only-export-selected-pv-ops-feature-structs
|
||||
+needs_update patches.arch/kvm-split-the-KVM-pv-ops-support-by-feature
|
||||
+needs_update patches.arch/kvm-replace-kvm-io-delay-pv-ops-with-linux-magic
|
||||
|
||||
+trenn patches.arch/kill-__stop_machine.patch
|
||||
+trenn patches.arch/reorganize_stop_cpus.patch
|
||||
+trenn patches.arch/implement_stop_machine_from_offline_cpu.patch
|
||||
+trenn patches.arch/use_stop_machine_for_mtrr_rendezvous.patch
|
||||
|
||||
########################################################
|
||||
# x86 MCE/MCA (Machine Check Error/Architecture) extensions
|
||||
########################################################
|
||||
|
||||
|
||||
########################################################
|
||||
# x86_64/4096CPUS - from SGI
|
||||
########################################################
|
||||
patches.arch/x86-apic-force-bigsmp-apic-on-IBM-EXA3-4.patch
|
||||
|
||||
########################################################
|
||||
# x86 UV patches from SGI
|
||||
########################################################
|
||||
|
||||
########################################################
|
||||
# x86_64/i386 depending on the UV patchset
|
||||
########################################################
|
||||
|
||||
########################################################
|
||||
# powerpc/generic
|
||||
########################################################
|
||||
patches.suse/led_classdev.sysfs-name.patch
|
||||
patches.suse/radeon-monitor-jsxx-quirk.patch
|
||||
|
||||
patches.suse/8250-sysrq-ctrl_o.patch
|
||||
+needs_update? patches.suse/ppc-no-LDFLAGS_MODULE.patch
|
||||
patches.arch/ppc-pegasos-console-autodetection.patch
|
||||
patches.suse/ppc-powerbook-usb-fn-key-default.patch
|
||||
patches.drivers/ppc64-adb
|
||||
patches.suse/suse-ppc64-branding
|
||||
patches.arch/ppc64-xmon-dmesg-printing.patch
|
||||
patches.arch/ppc-prom-nodisplay.patch
|
||||
patches.fixes/ptrace-getsiginfo
|
||||
patches.arch/ppc-kvm-fix-big-section.patch
|
||||
patches.arch/ppc-kvm-fix-cbe.patch
|
||||
|
||||
########################################################
|
||||
# PS3
|
||||
########################################################
|
||||
|
||||
########################################################
|
||||
# S/390
|
||||
########################################################
|
||||
patches.arch/s390-message-catalog.diff
|
||||
patches.arch/s390-message-catalog-fix.diff
|
||||
patches.arch/s390-message-catalog-perl-fix.diff
|
||||
patches.arch/kmsg-fix-parameter-limitations
|
||||
|
||||
patches.suse/s390-Kerntypes.diff
|
||||
|
||||
########################################################
|
||||
# VM/FS patches
|
||||
########################################################
|
||||
patches.fixes/oom-warning
|
||||
patches.fixes/grab-swap-token-oops
|
||||
|
||||
patches.fixes/remount-no-shrink-dcache
|
||||
|
||||
patches.suse/readahead-request-tunables.patch
|
||||
patches.fixes/fs-partitions-efi-c-corrupted-guid-partition-tables-can-cause-kernel-oops
|
||||
patches.fixes/mm-Fix-assertion-mapping-nrpages-0-in-end_writeback.patch
|
||||
|
||||
########################################################
|
||||
# IPC patches
|
||||
########################################################
|
||||
|
||||
########################################################
|
||||
# nfsacl protocol (agruen)
|
||||
########################################################
|
||||
|
||||
########################################################
|
||||
# misc small fixes
|
||||
########################################################
|
||||
patches.suse/connector-read-mostly
|
||||
patches.suse/kbd-ignore-gfx.patch
|
||||
|
||||
########################################################
|
||||
#
|
||||
# ACPI patches
|
||||
#
|
||||
########################################################
|
||||
# Check resource conflicts between hwmon and ACPI OpRegs
|
||||
patches.arch/acpi_thinkpad_introduce_acpi_root_table_boot_param.patch
|
||||
|
||||
patches.arch/acpi_thermal_passive_blacklist.patch
|
||||
|
||||
patches.arch/acpi_fix_fadt_32_bit_zero_length.patch
|
||||
|
||||
# Adjust this patch for every new product (at least Enterprise
|
||||
# level) to provide OEMs a safety break so that they can add
|
||||
# for example SLE11 specific BIOS updates (if there is no other
|
||||
# way to safely solve an ACPI issue).
|
||||
+trenn patches.suse/acpi_osi_sle11_ident.patch
|
||||
patches.arch/acpi_srat-pxm-rev-store.patch
|
||||
patches.arch/acpi_srat-pxm-rev-ia64.patch
|
||||
patches.arch/acpi_srat-pxm-rev-x86-64.patch
|
||||
|
||||
# Queued for 2.6.36 -> just revert after some time
|
||||
patches.fixes/acpi_ec_sys_access_user_space_with_get_user.patch
|
||||
|
||||
patches.drivers/apei_allow_drivers_access_nvs_ram.patch
|
||||
|
||||
patches.arch/acpica_introduce_acpi_os_phys_table_override_function.patch
|
||||
patches.arch/acpica_fix_wrongly_mapped_acpi_table_header_when_overriding_via_initrd.patch
|
||||
patches.arch/acpi_implement_overriding_of_arbitrary_acpi_tables_via_initrd.patch
|
||||
|
||||
########################################################
|
||||
# CPUFREQ
|
||||
########################################################
|
||||
|
||||
patches.fixes/cpufreq_ondemand_performance_optimise_default_settings.patch
|
||||
|
||||
## cpuidle perf events cleanups and related
|
||||
patches.arch/perf_timechart_fix_zero_timestamps.patch
|
||||
|
||||
patches.fixes/intel_idle_lapic_param.patch
|
||||
patches.fixes/intel_idle_add_flush_tlb_param.patch
|
||||
|
||||
########################################################
|
||||
# AGP, graphics related stuff
|
||||
########################################################
|
||||
|
||||
########################################################
|
||||
# Suse specific stuff
|
||||
########################################################
|
||||
|
||||
########################################################
|
||||
# Networking, IPv6
|
||||
########################################################
|
||||
patches.fixes/bridge-module-get-put.patch
|
||||
|
||||
########################################################
|
||||
# NFS
|
||||
########################################################
|
||||
|
||||
+needs_update37 patches.fixes/nfsd-06-sunrpc-cache-retry-cache-lookups-that-return-ETIMEDO.patch
|
||||
patches.fixes/nfs-adaptive-readdir-plus
|
||||
|
||||
########################################################
|
||||
# lockd + statd
|
||||
########################################################
|
||||
|
||||
########################################################
|
||||
# cifs patches
|
||||
########################################################
|
||||
|
||||
########################################################
|
||||
# ext2/ext3
|
||||
########################################################
|
||||
# patches.suse/ext2-fsync-err
|
||||
|
||||
########################################################
|
||||
# ext4
|
||||
########################################################
|
||||
|
||||
########################################################
|
||||
# btrfs
|
||||
########################################################
|
||||
|
||||
########################################################
|
||||
# Reiserfs Patches
|
||||
########################################################
|
||||
patches.fixes/reiserfs-force-inode-evictions-before-umount-to-avoid-crash
|
||||
+needs_updating-39 patches.suse/reiser4-dependencies
|
||||
|
||||
########################################################
|
||||
# dlm
|
||||
########################################################
|
||||
|
||||
########################################################
|
||||
# ocfs2
|
||||
########################################################
|
||||
|
||||
########################################################
|
||||
# gfs2
|
||||
########################################################
|
||||
|
||||
########################################################
|
||||
# xfs
|
||||
########################################################
|
||||
|
||||
########################################################
|
||||
# other filesystem stuff: richacls
|
||||
########################################################
|
||||
patches.suse/0001-vfs-Hooks-for-more-fine-grained-directory-permission.patch
|
||||
patches.suse/0002-vfs-Add-generic-IS_ACL-test-for-acl-support.patch
|
||||
patches.suse/0003-vfs-Add-IS_RICHACL-test-for-richacl-support.patch
|
||||
patches.suse/0004-richacl-In-memory-representation-and-helper-function.patch
|
||||
patches.suse/0005-richacl-Permission-mapping-functions.patch
|
||||
patches.suse/0006-richacl-Compute-maximum-file-masks-from-an-acl.patch
|
||||
patches.suse/0007-richacl-Update-the-file-masks-in-chmod.patch
|
||||
patches.suse/0008-richacl-Permission-check-algorithm.patch
|
||||
patches.suse/0009-richacl-Helper-functions-for-implementing-richacl-in.patch
|
||||
patches.suse/0010-richacl-Create-time-inheritance.patch
|
||||
patches.suse/0011-richacl-Check-if-an-acl-is-equivalent-to-a-file-mode.patch
|
||||
patches.suse/0012-richacl-Automatic-Inheritance.patch
|
||||
patches.suse/0013-richacl-Restrict-access-check-algorithm.patch
|
||||
patches.suse/0014-richacl-xattr-mapping-functions.patch
|
||||
patches.suse/0015-ext4-Use-IS_POSIXACL-to-check-for-POSIX-ACL-support.patch
|
||||
patches.suse/0016-ext4-Implement-richacl-support-in-ext4.patch
|
||||
|
||||
########################################################
|
||||
# other filesystem stuff
|
||||
########################################################
|
||||
patches.fixes/hfs-avoid-crash-in-hfs_bnode_create
|
||||
|
||||
########################################################
|
||||
# Swap-over-NFS
|
||||
########################################################
|
||||
|
||||
########################################################
|
||||
# Netfilter
|
||||
########################################################
|
||||
|
||||
patches.suse/netfilter-ip_conntrack_slp.patch
|
||||
patches.fixes/netfilter-implement-rfc-1123-for-ftp-conntrack
|
||||
|
||||
########################################################
|
||||
#
|
||||
# Device drivers
|
||||
#
|
||||
########################################################
|
||||
|
||||
########################################################
|
||||
# Storage
|
||||
########################################################
|
||||
|
||||
# Block layer fixes
|
||||
patches.fixes/scsi-inquiry-too-short-ratelimit
|
||||
patches.suse/scsi-netlink-ml
|
||||
|
||||
patches.fixes/scsi-retry-alua-transition-in-progress
|
||||
|
||||
patches.fixes/scsi-dh-queuedata-accessors
|
||||
patches.fixes/scsi-evaluate-tpgs-setting
|
||||
patches.suse/scsi-dh-implement-match-callback
|
||||
patches.fixes/scsi-dh-alua-always-update-tpgs-status
|
||||
patches.fixes/scsi-dh-check-for-sdev-state-in-store_dh_state
|
||||
|
||||
patches.fixes/scsi-check-host-lookup-failure
|
||||
patches.drivers/megaraid-mbox-fix-SG_IO
|
||||
|
||||
# Remaining SCSI patches (garloff)
|
||||
patches.suse/scsi-error-test-unit-ready-timeout
|
||||
patches.fixes/scsi-scan-blist-update
|
||||
|
||||
patches.fixes/scsi-ibmvscsi-show-config.patch
|
||||
# bnc#362850
|
||||
patches.fixes/sd_liberal_28_sense_invalid.diff
|
||||
|
||||
patches.fixes/scsi-ibmvscsi-module_alias.patch
|
||||
|
||||
########################################################
|
||||
# DRM/Video
|
||||
########################################################
|
||||
|
||||
########################################################
|
||||
# video4linux
|
||||
########################################################
|
||||
|
||||
########################################################
|
||||
# Network
|
||||
########################################################
|
||||
patches.fixes/tulip-quad-NIC-ifdown
|
||||
patches.drivers/ehea-modinfo.patch
|
||||
|
||||
########################################################
|
||||
# Wireless Networking
|
||||
########################################################
|
||||
patches.suse/b43-missing-firmware-info.patch
|
||||
|
||||
########################################################
|
||||
# ISDN
|
||||
########################################################
|
||||
patches.fixes/misdn-add-support-for-group-membership-check
|
||||
|
||||
########################################################
|
||||
# iSCSI
|
||||
########################################################
|
||||
|
||||
########################################################
|
||||
# PCI and PCI hotplug
|
||||
########################################################
|
||||
|
||||
########################################################
|
||||
# sysfs / driver core
|
||||
########################################################
|
||||
|
||||
########################################################
|
||||
# USB
|
||||
########################################################
|
||||
|
||||
########################################################
|
||||
# I2C
|
||||
########################################################
|
||||
|
||||
########################################################
|
||||
# Input & Console
|
||||
########################################################
|
||||
patches.suse/SUSE-bootsplash
|
||||
patches.drivers/elousb.patch
|
||||
patches.suse/elousb-2.6.35-api-changes
|
||||
patches.fixes/input-add-acer-aspire-5710-to-nomux.patch
|
||||
patches.drivers/input-Add-LED-support-to-Synaptics-device
|
||||
|
||||
##########################################################
|
||||
# Sound
|
||||
##########################################################
|
||||
|
||||
########################################################
|
||||
# Char / serial
|
||||
########################################################
|
||||
|
||||
########################################################
|
||||
# Other driver fixes
|
||||
########################################################
|
||||
# http://git.kernel.org/?p=linux/kernel/git/gregkh/staging-2.6.git;a=history;f=drivers/staging/hv;hb=refs/heads/staging-next
|
||||
patches.suse/staging-hv-staging-next-20110825-0001-Staging-hv-vmbus-Don-t-wait-indefinitely-for-IRQ.patch
|
||||
patches.suse/staging-hv-staging-next-20110825-0002-Staging-hv-tools-Fix-a-checkpatch-warning-in-hv_k.patch
|
||||
patches.suse/staging-hv-staging-next-20110825-0003-Staging-hv-vmbus-Fix-checkpatch-warnings.patch
|
||||
patches.suse/staging-hv-staging-next-20110825-0004-Staging-hv-util-kvp-Fix-the-reported-OSVersion-s.patch
|
||||
patches.suse/staging-hv-staging-next-20110825-0005-Staging-hv-util-kvp-Cleanup-kvp_get_domain_name.patch
|
||||
patches.suse/staging-hv-staging-next-20110825-0006-Staging-hv-Fix-macros-tab-errors-and-warning-in-d.patch
|
||||
patches.suse/staging-hv-staging-next-20110825-0007-Staging-hv-vmbus-VMBUS-is-an-ACPI-enumerated-devi.patch
|
||||
patches.suse/staging-hv-staging-next-20110825-0008-Staging-hv-Replace-struct-hv_guid-with-the-uuid-ty.patch
|
||||
patches.suse/staging-hv-staging-next-20110825-0009-Staging-hv-vmbus-Introduce-vmbus-ID-space-in-stru.patch
|
||||
patches.suse/staging-hv-staging-next-20110825-0010-Staging-hv-blkvsc-Use-the-newly-introduced-vmbus.patch
|
||||
patches.suse/staging-hv-staging-next-20110825-0011-Staging-hv-storvsc-Use-the-newly-introduced-vmbus.patch
|
||||
patches.suse/staging-hv-staging-next-20110825-0012-Staging-hv-netvsc-Use-the-newly-introduced-vmbus.patch
|
||||
patches.suse/staging-hv-staging-next-20110825-0013-Staging-hv-mousevsc-Use-the-newly-introduced-vmbu.patch
|
||||
patches.suse/staging-hv-staging-next-20110825-0014-Staging-hv-util-Make-hv_utils-a-vmbus-device-driv.patch
|
||||
patches.suse/staging-hv-staging-next-20110825-0015-Staging-hv-create-VMBUS_DEVICE-macro-and-use-it.patch
|
||||
patches.suse/staging-hv-staging-next-20110825-0016-Staging-hv-vmbus-Cleanup-vmbus_match.patch
|
||||
patches.suse/staging-hv-staging-next-20110825-0017-Staging-hv-vmbus-Cleanup-vmbus_uevent-code.patch
|
||||
patches.suse/staging-hv-staging-next-20110825-0018-Staging-hv-vmbus-Support-the-notion-of-id-tables.patch
|
||||
patches.suse/staging-hv-staging-next-20110825-0019-Staging-hv-vmbus-Get-rid-of-an-unnecessary-includ.patch
|
||||
patches.suse/staging-hv-staging-next-20110825-0020-Staging-hv-storvsc-Get-rid-of-the-DMI-signature.patch
|
||||
patches.suse/staging-hv-staging-next-20110825-0021-Staging-hv-netvsc-Get-rid-of-the-PCI-signature.patch
|
||||
patches.suse/staging-hv-staging-next-20110825-0022-Staging-hv-netvsc-Get-rid-of-the-DMI-signature-in.patch
|
||||
patches.suse/staging-hv-staging-next-20110825-0023-Staging-hv-util-Get-rid-of-the-DMI-signature-in-h.patch
|
||||
patches.suse/staging-hv-staging-next-20110825-0024-Staging-hv-util-Get-rid-of-the-PCI-signature-in-h.patch
|
||||
patches.suse/staging-hv-staging-next-20110825-0025-Staging-hv-fix-up-driver-registering-mess.patch
|
||||
patches.suse/staging-hv-staging-next-20110825-0026-Staging-hv-vmbus-Get-rid-of-some-unnecessary-comm.patch
|
||||
patches.suse/staging-hv-staging-next-20110825-0027-Staging-hv-vmbus-Cleanup-unnecessary-comments-in.patch
|
||||
patches.suse/staging-hv-staging-next-20110825-0028-Staging-hv-vmbus-Cleanup-error-handling-in-hv_ini.patch
|
||||
patches.suse/staging-hv-staging-next-20110825-0029-Staging-hv-vmbus-Get-rid-of-unnecessay-comments-i.patch
|
||||
patches.suse/staging-hv-staging-next-20110825-0030-Staging-hv-vmbus-Get-rid-of-the-function-dump_gpa.patch
|
||||
patches.suse/staging-hv-staging-next-20110825-0031-Staging-hv-vmbus-Get-rid-of-the-function-dump_gpa.patch
|
||||
patches.suse/staging-hv-staging-next-20110825-0032-Staging-hv-vmbus-Rename-openMsg-to-open_msg-in-ch.patch
|
||||
patches.suse/staging-hv-staging-next-20110825-0033-Staging-hv-vmbus-Get-rid-of-unnecessary-comments.patch
|
||||
patches.suse/staging-hv-staging-next-20110825-0034-Staging-hv-vmbus-Change-the-variable-name-openInf.patch
|
||||
patches.suse/staging-hv-staging-next-20110825-0035-Staging-hv-vmbus-Cleanup-error-values-in-ringbuff.patch
|
||||
patches.suse/staging-hv-staging-next-20110825-0036-Staging-hv-vmbus-Cleanup-the-error-return-value-i.patch
|
||||
patches.suse/staging-hv-staging-next-20110825-0037-Staging-hv-netvsc-Get-rid-of-an-unnecessary-print.patch
|
||||
patches.suse/staging-hv-staging-next-20110825-0038-Staging-hv-vmbus-Retry-vmbus_post_msg-before-gi.patch
|
||||
patches.suse/staging-hv-staging-next-20110825-0039-Staging-hv-storvsc-Cleanup-error-handling-in-stor.patch
|
||||
patches.suse/staging-hv-staging-next-20110825-0040-Staging-hv-storvsc-Cleanup-error-handling-in-stor.patch
|
||||
patches.suse/staging-hv-staging-next-20110825-0041-Staging-hv-storvsc-Cleanup-error-handling-in-stor.patch
|
||||
patches.suse/staging-hv-staging-next-20110825-0042-Staging-hv-storvsc-Cleanup-error-handling-in-stor.patch
|
||||
patches.suse/staging-hv-staging-next-20110825-0043-Storage-hv-storvsc-Get-rid-of-some-unnecessary-DP.patch
|
||||
patches.suse/staging-hv-staging-next-20110825-0044-Staging-hv-storvsc-Fix-cleanup-some-dated-comment.patch
|
||||
patches.suse/staging-hv-staging-next-20110825-0045-Staging-hv-storvsc-Cleanup-returned-error-code-in.patch
|
||||
patches.suse/staging-hv-staging-next-20110825-0046-Staging-hv-storvsc-Cleanup-error-code-returned-in.patch
|
||||
patches.suse/staging-hv-staging-next-20110825-0047-Staging-hv-storvsc-Cleanup-returned-error-code-in.patch
|
||||
patches.suse/staging-hv-staging-next-20110825-0048-Staging-hv-netvsc-Cleanup-the-returned-error-code.patch
|
||||
patches.suse/staging-hv-staging-next-20110825-0049-Staging-hv-netvsc-Cleanup-error-return-codes-in-n.patch
|
||||
patches.suse/staging-hv-staging-next-20110825-0050-Staging-hv-netvsc-Cleanup-error-return-values-in.patch
|
||||
patches.suse/staging-hv-staging-next-20110825-0051-Staging-hv-netvsc-Cleanup-error-returns-in-netvsc.patch
|
||||
patches.suse/staging-hv-staging-next-20110825-0052-Staging-hv-netvsc-Cleanup-error-return-values-in.patch
|
||||
patches.suse/staging-hv-staging-next-20110825-0053-Staging-hv-netvsc-Cleanup-error-return-codes-in-n.patch
|
||||
patches.suse/staging-hv-staging-next-20110825-0054-Staging-hv-netvsc-Cleanup-error-codes-in-rndis_fi.patch
|
||||
patches.suse/staging-hv-staging-next-20110825-0055-Staging-hv-netvsc-Cleanup-error-code-in-rndis_fil.patch
|
||||
patches.suse/staging-hv-staging-next-20110825-0056-Staging-hv-netvsc-Cleanup-error-return-values-in.patch
|
||||
patches.suse/staging-hv-staging-next-20110825-0057-Staging-hv-netvsc-Cleanup-error-returns-in-rndis_.patch
|
||||
patches.suse/staging-hv-staging-next-20110825-0058-Staging-hv-netvsc-Cleanup-error-code-in-rndis_fil.patch
|
||||
patches.suse/staging-hv-staging-next-20110825-0059-Staging-hv-mouse-Change-the-jump-label-Cleanup-to.patch
|
||||
patches.suse/staging-hv-staging-next-20110825-0060-Staging-hv-netvsc-Change-the-jump-label-Cleanup-t.patch
|
||||
patches.suse/staging-hv-staging-next-20110825-0061-Staging-hv-netvsc-Change-the-jump-label-Exit-to-e.patch
|
||||
patches.suse/staging-hv-staging-next-20110825-0062-Staging-hv-mouse-Get-rid-of-the-unused-PCI-signat.patch
|
||||
patches.suse/staging-hv-staging-next-20110825-0063-Staging-hv-hv_mouse-remove-deviceinfo_callback-fu.patch
|
||||
patches.suse/staging-hv-staging-next-20110825-0064-Staging-hv-hv_mouse-remove-inputreport_callback-f.patch
|
||||
patches.suse/staging-hv-staging-next-20110825-0065-Staging-hv-hv_mouse-remove-a-forward-declaration.patch
|
||||
patches.suse/staging-hv-staging-next-20110825-0066-Staging-hv-hv_mouse-fix-up-remove-function.patch
|
||||
# module support patches outside of drivers/staging/hv
|
||||
patches.suse/staging-hv-staging-next-20110825-0562-Staging-hv-Add-struct-hv_vmbus_device_id-to-mod_de.patch
|
||||
patches.suse/staging-hv-staging-next-20110825-0563-Staging-hv-add-driver_data-to-hv_vmbus_device_id.patch
|
||||
patches.suse/staging-hv-staging-next-20110825-0568-Staging-hv-Add-code-to-parse-struct-hv_vmbus_devic.patch
|
||||
patches.suse/staging-hv-staging-next-20110825-0570-Staging-hv-file2alias-fix-up-alias-creation-logic.patch
|
||||
|
||||
patches.suse/staging-hv-staging-next-20110829-0303-Staging-hv-storvsc-Inline-free_stor_device.patch
|
||||
patches.suse/staging-hv-staging-next-20110829-0304-Staging-hv-storvsc-Do-not-aquire-an-unnecessary-r.patch
|
||||
patches.suse/staging-hv-staging-next-20110829-0305-Staging-hv-storvsc-Rename-must_get_stor_device.patch
|
||||
patches.suse/staging-hv-staging-next-20110829-0306-Staging-hv-storvsc-Rename-get_stor_device.patch
|
||||
patches.suse/staging-hv-staging-next-20110829-0307-Staging-hv-storvsc-Cleanup-alloc_stor_device.patch
|
||||
patches.suse/staging-hv-staging-next-20110829-0308-Staging-hv-storvsc-Introduce-state-to-manage-the.patch
|
||||
patches.suse/staging-hv-staging-next-20110829-0309-Staging-hv-storvsc-Prevent-outgoing-traffic-when.patch
|
||||
patches.suse/staging-hv-staging-next-20110829-0310-Staging-hv-storvsc-Get-rid-of-release_stor_device.patch
|
||||
patches.suse/staging-hv-staging-next-20110829-0311-Staging-hv-storvsc-Get-rid-of-final_release_stor_.patch
|
||||
patches.suse/staging-hv-staging-next-20110829-0312-Staging-hv-storvsc-Get-rid-of-the-reference-count.patch
|
||||
patches.suse/staging-hv-staging-next-20110829-0313-Staging-hv-netvsc-Inline-the-code-for-free_net_de.patch
|
||||
patches.suse/staging-hv-staging-next-20110829-0314-Staging-hv-netvsc-Cleanup-alloc_net_device.patch
|
||||
patches.suse/staging-hv-staging-next-20110829-0315-Staging-hv-netvsc-Introduce-state-to-manage-the-l.patch
|
||||
patches.suse/staging-hv-staging-next-20110829-0316-Staging-hv-netvsc-Prevent-outgoing-traffic-when-n.patch
|
||||
patches.suse/staging-hv-staging-next-20110829-0317-Staging-hv-netvsc-Get-rid-of-release_outbound_net.patch
|
||||
patches.suse/staging-hv-staging-next-20110829-0318-Staging-hv-netvsc-Get-rid-of-release_inbound_net_.patch
|
||||
patches.suse/staging-hv-staging-next-20110829-0319-Staging-hv-netvsc-Get-rid-of-the-refcnt-field-in.patch
|
||||
patches.suse/staging-hv-staging-next-20110829-0320-Staging-hv-storvsc-Add-code-to-handle-IDE-devices.patch
|
||||
patches.suse/staging-hv-staging-next-20110829-0321-Staging-hv-storvsc-Handle-IDE-devices-using-the-s.patch
|
||||
patches.suse/staging-hv-staging-next-20110829-0322-Staging-hv-blkvsc-Get-rid-of-blkvsc_drv.c-as-this.patch
|
||||
patches.suse/staging-hv-staging-next-20110829-0323-Staging-hv-storvsc-Optimize-bounce-buffer-handlin.patch
|
||||
patches.suse/staging-hv-staging-next-20110829-0324-Staging-hv-storvsc-Optimize-the-bounce-buffer-han.patch
|
||||
patches.suse/staging-hv-staging-next-20110829-0325-Staging-hv-storvsc-Include-storvsc.c-in-storvsc_d.patch
|
||||
patches.suse/staging-hv-staging-next-20110829-0326-Staging-hv-storvsc-Cleanup-storvsc_drv.c-after-ad.patch
|
||||
patches.suse/staging-hv-staging-next-20110829-0327-Staging-hv-storvsc-Add-the-contents-of-hyperv_sto.patch
|
||||
patches.suse/staging-hv-staging-next-20110829-0328-Staging-hv-storvsc-Cleanup-storvsc_drv.c-after-ad.patch
|
||||
patches.suse/staging-hv-staging-next-20110829-0329-Staging-hv-storvsc-Fixup-srb-and-scsi-status-for.patch
|
||||
patches.suse/staging-hv-staging-next-20110829-0330-Staging-hv-storvsc-Fix-a-typo.patch
|
||||
patches.suse/staging-hv-staging-next-20110829-0331-Staging-hv-storvsc-In-case-of-scsi-errors-offline.patch
|
||||
patches.suse/staging-hv-staging-next-20110829-0332-Staging-hv-storvsc-No-need-to-copy-from-bounce-bu.patch
|
||||
patches.suse/staging-hv-staging-next-20110829-0333-Staging-hv-util-Forcefully-shutdown-when-shutdown.patch
|
||||
patches.suse/staging-hv-staging-next-20110829-0334-Staging-hv-util-Adjust-guest-time-in-a-process-co.patch
|
||||
patches.suse/staging-hv-staging-next-20110829-0335-Staging-hv-vmbus-Check-before-invoking-the-channe.patch
|
||||
patches.suse/staging-hv-staging-next-20110829-0336-Staging-hv-vmbus-Properly-deal-with-de-registerin.patch
|
||||
patches.suse/staging-hv-staging-next-20110829-0337-Staging-hv-Fix-a-bug-in-vmbus_match.patch
|
||||
patches.suse/staging-hv-staging-next-20110829-0338-Staging-hv-vmbus-Get-rid-of-vmbus_on_isr-by-inl.patch
|
||||
patches.suse/staging-hv-staging-next-20110829-0339-Staging-hv-vmbus-Do-not-enable-auto-eoi.patch
|
||||
patches.suse/staging-hv-staging-next-20110829-0340-Staging-hv-vmbus-Fixup-indentation-in-vmbus_acpi_.patch
|
||||
patches.suse/staging-hv-staging-next-20110829-0341-Staging-hv-vmbus-Get-rid-of-some-dated-redundant.patch
|
||||
patches.suse/staging-hv-staging-next-20110829-0342-Staging-hv-vmbus-Get-rid-of-an-unnecessary-check.patch
|
||||
patches.suse/staging-hv-staging-next-20110829-0343-Staging-hv-vmbus-Fix-a-checkpatch-warning-in-ring.patch
|
||||
patches.suse/staging-hv-staging-next-20110829-0344-Staging-hv-vmbus-Fix-checkpatch-warnings-in-conne.patch
|
||||
patches.suse/staging-hv-staging-next-20110829-0345-Staging-hv-mousevsc-Fix-checkpatch-errors-and-war.patch
|
||||
patches.suse/staging-hv-staging-next-20110829-0346-Staging-hv-netvsc-return-negative-error-codes.patch
|
||||
|
||||
patches.suse/staging-hv-vmbus-modalias-show.patch
|
||||
patches.suse/staging-hv-pata_piix-ignore-disks.patch
|
||||
patches.fixes/parport-mutex
|
||||
|
||||
patches.suse/no-partition-scan
|
||||
|
||||
########################################################
|
||||
# Other drivers we have added to the tree
|
||||
########################################################
|
||||
|
||||
########################################################
|
||||
# Suspend/Resume stuff
|
||||
########################################################
|
||||
|
||||
########################################################
|
||||
# device-mapper
|
||||
########################################################
|
||||
patches.suse/dm-emulate-blkrrpart-ioctl
|
||||
patches.suse/dm-raid45-26-Nov-2009.patch
|
||||
patches.suse/dmraid45-dm_dirty_log_create-api-fix
|
||||
patches.suse/dmraid45-dm_get_device-takes-fewer-arguments
|
||||
patches.suse/dm-raid45-api-update-remove-dm_put-after-dm_table_get_md
|
||||
patches.suse/dm-raid45-api-update-no-barriers
|
||||
patches.suse/dm-raid45-api-2.6.39
|
||||
patches.suse/dm-raid45-api-3.0
|
||||
patches.fixes/dm-mpath-reattach-dh
|
||||
patches.suse/dm-mpath-leastpending-path-update
|
||||
patches.suse/dm-mpath-accept-failed-paths
|
||||
patches.suse/dm-mpath-detach-existing-hardware-handler
|
||||
patches.fixes/dm-table-switch-to-readonly
|
||||
patches.fixes/dm-release-map_lock-before-set_disk_ro
|
||||
patches.suse/dm-mpath-no-activate-for-offlined-paths
|
||||
patches.suse/dm-mpath-no-partitions-feature
|
||||
patches.suse/mpath-fix
|
||||
|
||||
########################################################
|
||||
# md
|
||||
########################################################
|
||||
|
||||
##########################################################
|
||||
#
|
||||
# Security stuff
|
||||
#
|
||||
##########################################################
|
||||
|
||||
##########################################################
|
||||
# Audit
|
||||
##########################################################
|
||||
|
||||
##########################################################
|
||||
# AppArmor
|
||||
##########################################################
|
||||
patches.apparmor/apparmor-compatibility-patch-for-v5-network-control
|
||||
patches.apparmor/apparmor-compatibility-patch-for-v5-interface
|
||||
patches.apparmor/apparmor-allow-dfa-backward-compatibility-with-broken-userspace
|
||||
|
||||
|
||||
########################################################
|
||||
# Address space layout randomization
|
||||
########################################################
|
||||
|
||||
########################################################
|
||||
# KDB v4.4
|
||||
########################################################
|
||||
|
||||
########################################################
|
||||
# Other patches for debugging
|
||||
########################################################
|
||||
patches.suse/crasher-26.diff
|
||||
patches.suse/stack-unwind
|
||||
patches.suse/revert-x86-remove-warning-and-warning_symbol-from-struct-stacktrace_ops
|
||||
patches.suse/no-frame-pointer-select
|
||||
patches.arch/x86_64-unwind-annotations
|
||||
|
||||
########################################################
|
||||
# Kdump
|
||||
########################################################
|
||||
|
||||
########################################################
|
||||
# cgroups
|
||||
########################################################
|
||||
|
||||
########################################################
|
||||
# audit subsystem
|
||||
########################################################
|
||||
|
||||
########################################################
|
||||
# Performance Monitoring, Tracing etc
|
||||
########################################################
|
||||
patches.fixes/ia64-configure-HAVE_UNSTABLE_SCHED_CLOCK-for-SGI_SN.patch
|
||||
|
||||
########################################################
|
||||
# KVM patches
|
||||
########################################################
|
||||
patches.fixes/kvm-ioapic.patch
|
||||
patches.fixes/kvm-macos.patch
|
||||
|
||||
########################################################
|
||||
# Staging tree patches
|
||||
# new drivers that are going upstream
|
||||
########################################################
|
||||
|
||||
########################################################
|
||||
# You'd better have a good reason for adding a patch
|
||||
# below here.
|
||||
########################################################
|
||||
|
||||
########################################################
|
||||
# XEN architecture, version 3
|
||||
########################################################
|
||||
|
||||
# xen patches, from xenbits mercurial repository.
|
||||
# http://xenbits.xensource.com/ext/linux-2.6-merge.hg
|
||||
#
|
||||
# everything named "xen3-auto-*" is auto-generated.
|
||||
# PLEASE DON'T EDIT THESE PATCHES. Create fixup patches
|
||||
# on top of them instead. This reduces workload when
|
||||
# re-basing to a newer xen tree.
|
||||
#
|
||||
### both uml framebuffer and xen need this one.
|
||||
patches.xen/add-console-use-vt
|
||||
|
||||
# split out patches
|
||||
patches.xen/kexec-move-segment-code-i386.patch
|
||||
patches.xen/kexec-move-segment-code-x86_64.patch
|
||||
patches.xen/frontswap-structure-changes
|
||||
patches.xen/frontswap-core
|
||||
patches.xen/frontswap-hooks
|
||||
patches.xen/frontswap-config
|
||||
patches.xen/ipv6-no-autoconf
|
||||
patches.xen/pci-guestdev
|
||||
patches.xen/pci-reserve
|
||||
|
||||
# bulk stuff, new files for xen
|
||||
patches.xen/xen3-auto-xen-arch.diff
|
||||
patches.xen/xen3-auto-xen-drivers.diff
|
||||
patches.xen/xen3-auto-include-xen-interface.diff
|
||||
patches.xen/xen3-auto-blktap2-pvops.diff
|
||||
|
||||
# kconfig bits for xen
|
||||
patches.xen/xen3-auto-xen-kconfig.diff
|
||||
|
||||
# common code changes
|
||||
patches.xen/xen3-auto-common.diff
|
||||
patches.xen/xen3-auto-arch-x86.diff
|
||||
patches.xen/xen3-auto-arch-i386.diff
|
||||
patches.xen/xen3-auto-arch-x86_64.diff
|
||||
|
||||
# fixups due to upstream Xen parts
|
||||
patches.xen/xen3-fixup-xen
|
||||
|
||||
# newer changeset backports
|
||||
|
||||
# changes outside arch/{i386,x86_64}/xen
|
||||
patches.xen/xen3-fixup-kconfig
|
||||
patches.xen/xen3-fixup-common
|
||||
patches.xen/xen3-fixup-arch-x86
|
||||
patches.xen/xen3-fixup-blktap2-pvops
|
||||
|
||||
# ports of other patches
|
||||
patches.xen/xen3-patch-2.6.18
|
||||
patches.xen/xen3-patch-2.6.19
|
||||
patches.xen/xen3-patch-2.6.20
|
||||
patches.xen/xen3-patch-2.6.21
|
||||
patches.xen/xen3-patch-2.6.22
|
||||
patches.xen/xen3-patch-2.6.23
|
||||
patches.xen/xen3-patch-2.6.24
|
||||
patches.xen/xen3-patch-2.6.25
|
||||
patches.xen/xen3-patch-2.6.26
|
||||
patches.xen/xen3-patch-2.6.27
|
||||
patches.xen/xen3-patch-2.6.28
|
||||
patches.xen/xen3-patch-2.6.29
|
||||
patches.xen/xen3-patch-2.6.30
|
||||
patches.xen/xen3-patch-2.6.31
|
||||
patches.xen/xen3-patch-2.6.32
|
||||
patches.xen/xen3-patch-2.6.33
|
||||
patches.xen/xen3-patch-2.6.34
|
||||
patches.xen/xen3-patch-2.6.35
|
||||
patches.xen/xen3-patch-2.6.36
|
||||
patches.xen/xen3-patch-2.6.37
|
||||
patches.xen/xen3-patch-2.6.38
|
||||
patches.xen/xen3-patch-2.6.39
|
||||
patches.xen/xen3-patch-3.0
|
||||
patches.xen/xen3-patch-3.1-rc5
|
||||
patches.xen/xen3-patch-3.1-rc6-rc7
|
||||
patches.xen/xen3-apei_allow_drivers_access_nvs_ram.patch
|
||||
patches.xen/xen3-acpi_implement_overriding_of_arbitrary_acpi_tables_via_initrd.patch
|
||||
patches.xen/xen3-stack-unwind
|
||||
patches.xen/xen3-x86_64-unwind-annotations
|
||||
|
||||
# bugfixes and enhancements
|
||||
patches.xen/xen-kconfig-compat
|
||||
patches.xen/xen-sys-suspend
|
||||
patches.xen/xen-ipi-per-cpu-irq
|
||||
patches.xen/xen-virq-per-cpu-irq
|
||||
patches.xen/xen-clockevents
|
||||
patches.xen/xen-spinlock-poll-early
|
||||
patches.xen/xen-pcpu-hotplug
|
||||
patches.xen/xen-mem-hotplug
|
||||
patches.xen/xen-swiotlb-heuristics
|
||||
patches.xen/xen-pci-multi-segment
|
||||
patches.xen/xen-configurable-guest-devices
|
||||
patches.xen/xen-setup-gsi
|
||||
patches.xen/xen-kzalloc
|
||||
patches.xen/xen-sections
|
||||
patches.xen/xen-unpriv-build
|
||||
patches.xen/xen-cpufreq-report
|
||||
patches.xen/xen-balloon-max-target
|
||||
patches.xen/xen-blkif-protocol-fallback-hack
|
||||
patches.xen/xen-blkback-cdrom
|
||||
patches.xen/xen-blktap-modular
|
||||
patches.xen/xen-blktap-write-barriers
|
||||
patches.xen/xen-blktap2-configurable-nr-devs
|
||||
patches.xen/xen-op-packet
|
||||
patches.xen/xen-blkfront-cdrom
|
||||
patches.xen/xen-blkfront-hvm-no-cdrom
|
||||
patches.xen/xen-netback-nr-irqs
|
||||
patches.xen/xen-netback-notify-multi
|
||||
patches.xen/xen-netback-generalize
|
||||
patches.xen/xen-netback-multiple-tasklets
|
||||
patches.xen/xen-netback-kernel-threads
|
||||
patches.xen/xen-cxgb3
|
||||
patches.xen/xen-dcdbas
|
||||
patches.xen/xen-floppy
|
||||
patches.xen/xen-x86-panic-no-reboot
|
||||
patches.xen/xen-x86-dcr-fallback
|
||||
patches.xen/xen-x86-no-lapic
|
||||
patches.xen/xen-x86-pmd-handling
|
||||
patches.xen/xen-x86-bigmem
|
||||
patches.xen/xen-x86-exit-mmap
|
||||
patches.xen/xen-x86-per-cpu-vcpu-info
|
||||
patches.xen/xen-x86-msr-on-pcpu
|
||||
patches.xen/xen-x86-EFI
|
||||
patches.xen/xen-x86_64-pgd-pin
|
||||
patches.xen/xen-x86_64-pgd-alloc-order
|
||||
patches.xen/xen-x86_64-dump-user-pgt
|
||||
patches.xen/xen-x86_64-note-init-p2m
|
||||
patches.xen/xen-x86_64-unmapped-initrd
|
13
source-post.sh
Normal file
13
source-post.sh
Normal file
@ -0,0 +1,13 @@
|
||||
relink() {
|
||||
if [ -h "$2" ]; then
|
||||
local old=$(readlink "$2")
|
||||
[ "$old" = "$1" ] && return 0
|
||||
echo "Changing symlink $2 from $old to $1"
|
||||
elif [ -e "$2" ]; then
|
||||
echo "Replacing file $2 with symlink to $1"
|
||||
fi
|
||||
rm -f "$2" \
|
||||
&& ln -s "$1" "$2"
|
||||
}
|
||||
|
||||
relink linux-@KERNELRELEASE@@SRCVARIANT@ /usr/src/linux@SRCVARIANT@
|
3
source-timestamp
Normal file
3
source-timestamp
Normal file
@ -0,0 +1,3 @@
|
||||
2011-10-03 18:22:13 +0200
|
||||
GIT Revision: 6c33ac4c17512344a51413a39060e307da80c2a8
|
||||
GIT Branch: master
|
107
split-modules
Normal file
107
split-modules
Normal file
@ -0,0 +1,107 @@
|
||||
#!/bin/bash
|
||||
#
|
||||
# given a Module.supported, Module.base and modules.dep, generate list
|
||||
# of base / supported / unsupported modules
|
||||
|
||||
set -e
|
||||
export LC_COLLATE=C
|
||||
|
||||
usage()
|
||||
{
|
||||
echo "Usage: ${0##*/} -b Module.base -s Module.supported [-d dir] [-i] [-o outdir]"
|
||||
}
|
||||
|
||||
options=$(getopt -o b:s:d:o:i -- "$@")
|
||||
if test $? -ne 0; then
|
||||
usage >&2
|
||||
exit 1
|
||||
fi
|
||||
eval set -- "$options"
|
||||
opt_base=
|
||||
opt_supp=
|
||||
opt_out=.
|
||||
opt_dir=.
|
||||
opt_ignore_errors=false
|
||||
while test $# -gt 0; do
|
||||
opt=$1
|
||||
shift
|
||||
case "$opt" in
|
||||
-b | -s | -d | -o | -D)
|
||||
arg=$1
|
||||
shift
|
||||
esac
|
||||
case "$opt" in
|
||||
-b)
|
||||
opt_base=$arg ;;
|
||||
-s)
|
||||
opt_supp=$arg ;;
|
||||
-d)
|
||||
opt_dir=$arg ;;
|
||||
-o)
|
||||
opt_out=$arg ;;
|
||||
-i)
|
||||
opt_ignore_errors=true ;;
|
||||
--)
|
||||
break ;;
|
||||
*)
|
||||
echo "Unknown option $opt" >&2
|
||||
exit 1
|
||||
esac
|
||||
done
|
||||
if test -z "$opt_base" -o -z "$opt_supp"; then
|
||||
usage >&2
|
||||
exit 1
|
||||
fi
|
||||
|
||||
trap 'rm -rf "$tmp"' EXIT
|
||||
tmp=$(mktemp -d)
|
||||
mkdir "$tmp/empty"
|
||||
|
||||
find "$opt_dir" -type f -name '*.ko' -printf '/%P\n' | \
|
||||
awk -F/ '{ n=$NF; gsub(/-/, "_", n); sub(/\.ko$/, "", n); print n " " $0; }' | \
|
||||
sort >"$tmp/all"
|
||||
|
||||
modules_dep=$(find "$opt_dir" -type f -name modules.dep)
|
||||
if test -z "$modules_dep"; then
|
||||
echo "Cannot find modules.dep in $opt_dir" >&2
|
||||
exit 1
|
||||
fi
|
||||
(
|
||||
echo '%:
|
||||
@echo $@
|
||||
ifdef EXPLAIN
|
||||
@for dep in $^; do echo "$$dep needed by $@"; done >> $(EXPLAIN)
|
||||
endif
|
||||
'
|
||||
sed -r 's:[^ ]*/([^/]*)\.ko\>:\1:g; y/-/_/' "$modules_dep"
|
||||
) >"$tmp/dep"
|
||||
|
||||
add_dependent_modules()
|
||||
{
|
||||
xargs -r make EXPLAIN=$1 -rRs -C "$tmp/empty" -f "$tmp/dep" | sort -u
|
||||
}
|
||||
|
||||
# base
|
||||
sed 'y/-/_/' <"$opt_base" | add_dependent_modules >"$tmp/base"
|
||||
join -j 1 -o 2.2 "$tmp/base" "$tmp/all" >"$opt_out/base-modules"
|
||||
|
||||
# main
|
||||
sed 's/ .*//; y/-/_/' "$opt_supp" | sort -u >"$tmp/supp"
|
||||
add_dependent_modules "$tmp/supp-explain" <"$tmp/supp" >"$tmp/supp-all"
|
||||
if ! cmp -s "$tmp/supp" "$tmp/supp-all"; then
|
||||
echo "The following unsupported modules are used by supported modules:" >&2
|
||||
join -j1 -a2 <(sort "$tmp/supp-explain") \
|
||||
<(join -v2 "$tmp/supp" "$tmp/supp-all") >&2
|
||||
echo "Please fix supported.conf." >&2
|
||||
if ! $opt_ignore_errors; then
|
||||
exit 1
|
||||
fi
|
||||
fi
|
||||
join -j 1 -o 2.2 "$tmp/supp-all" "$tmp/all" >"$opt_out/main-modules"
|
||||
|
||||
# unsupported
|
||||
join -j 1 -v 2 -o 2.2 "$tmp/supp-all" "$tmp/all" >"$opt_out/unsupported-modules"
|
||||
|
||||
exit 0
|
||||
|
||||
|
2724
supported.conf
Normal file
2724
supported.conf
Normal file
File diff suppressed because it is too large
Load Diff
3
sysctl.tar.bz2
Normal file
3
sysctl.tar.bz2
Normal file
@ -0,0 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:c486da73fb5a20a18ab975da3ff78a6c6c06165e0e16634606807364b170993b
|
||||
size 775
|
Loading…
Reference in New Issue
Block a user