Package Base Details: linux-rt

Git Clone URL: https://aur.archlinux.org/linux-rt.git (read-only, click to copy)
Submitter: schivmeister
Maintainer: jhernberg (dvzrv)
Last Packager: dvzrv
Votes: 165
Popularity: 0.65
First Submitted: 2011-08-09 20:03
Last Updated: 2020-02-15 10:08

Pinned Comments

dvzrv commented on 2019-05-13 21:17

I have added a signed, unofficial user repository for linux-rt, backed by this PKGBUILD.

You can add it to your pacman.conf with:

[dvzrv]
Server = https://pkgbuild.com/~dvzrv/repo/$arch

I'll try to keep it as up-to-date as possible and retain old versions.

Enjoy!

Morgan_Cox commented on 2011-04-11 21:20

Here is an updated PKGBUILD - needed for nvidia-rt:-
---------------------------------------------------


# Maintainer: Ray Rashif <schiv@archlinux.org>
# Contributor: timbosa <tinny_tim@dodo.com.au>
# Contributor: Tobias Powalowski <tpowa@archlinux.org>
# Contributor: Thomas Baechler <thomas@archlinux.org>

pkgname=kernel26rt
_kernelname=${pkgname#kernel26}
_basekernel=2.6.33
_realkernel=2.6.33 # for rc builds, else same as _basekernel
_kernelpatch=.9 # leave blank if no upstream patch
_rtpatch=-rt31
pkgver=2.6.33.9_rt31
pkgrel=1

# If sources are rc, old rc, old rt, rc & old rt, old rc & old rt:
# rc, rc-old, rt-old, rc-rt-old, all-old or blank for default
_source=

# -- nothing to change below this line -- #

pkgdesc="The Linux Kernel and modules - with realtime preemption"
arch=('i686' 'x86_64')
license=('GPL2')
url="http://rt.wiki.kernel.org"
backup=(etc/mkinitcpio.d/$pkgname.preset)
depends=('coreutils' 'linux-firmware' 'module-init-tools' 'mkinitcpio')
optdepends=('crda: to set the correct wireless channels of your country')
provides=('kernel26rt-headers')
install=$pkgname.install
changelog=$pkgname.changelog

[ "$_source" = "rc" ] && _rc=testing/
[ "$_source" = "rc-old" ] && _rc=testing/v$_realkernel/
[ "$_source" = "rt-old" ] && _rt=older/
[ "$_source" = "rc-rt-old" ] && _rc=testing/ && _rt=older/
[ "$_source" = "all-old" ] && _rc=testing/v$_realkernel/ && _rt=older/
#[ -n "$_kernelpatch" ] && _kernpatchurl="ftp://ftp.kernel.org/pub/linux/kernel/v2.6/${_rc}patch-$_realkernel$_kernelpatch.bz2"
[ -n "$_kernelpatch" ] && _kernpatchurl="http://www.kernel.org/pub/linux/kernel/v2.6/longterm/v$_basekernel/${_rc}patch-$_realkernel$_kernelpatch.bz2"

options=(!strip)
source=(ftp://ftp.kernel.org/pub/linux/kernel/v2.6/linux-$_realkernel.tar.bz2
$_kernpatchurl
ftp://ftp.kernel.org/pub/linux/kernel/projects/rt/${_rt}patch-$_realkernel$_kernelpatch$_rtpatch.bz2
config
config.x86_64
$pkgname.preset
logo_linux_clut224.ppm
aufs2-base.patch
aufs2-standalone.patch)

build() {
cd "$srcdir/linux-$_realkernel"

# Add upstream patch
if [ -n "$_kernelpatch" ]; then
patch -Np1 -i ../patch-$_realkernel$_kernelpatch
fi

# Add support for AUFS2
patch -Np1 -i ../aufs2-base.patch
patch -Np1 -i ../aufs2-standalone.patch

# Add realtime patch
patch -Np1 -i ../patch-$_realkernel$_kernelpatch$_rtpatch

# Add our custom logo
cp ../logo_linux_clut224.ppm drivers/video/logo/

# Set up configuration
if [ "$CARCH" = "x86_64" ]; then
cat ../config.x86_64 > ./.config
else
cat ../config > ./.config
fi

if [ -f "$startdir/config.save" ]; then
msg "Using previously autosaved config"
cat "$startdir/config.save" > ./.config
fi

sed -i "s|EXTRAVERSION =.*|EXTRAVERSION =|g" Makefile
sed -i "s|CONFIG_LOCALVERSION=.*|CONFIG_LOCALVERSION=\"-$_kernelname\"|g" ./.config

# load configuration
_kernver=$_basekernel-$_kernelname
yes "" | make config
make menuconfig && cat ./.config > "$startdir/config.save"
#make xconfig
#make gconfig
#make oldconfig

# build!
make bzImage modules
}

package() {
cd "$srcdir/linux-$_realkernel"

KARCH=x86
_kernver=$_basekernel-$_kernelname

mkdir -p "$pkgdir"/{lib/modules,boot}
make INSTALL_MOD_PATH="$pkgdir" modules_install
cp System.map "$pkgdir/boot/System.map26$_kernelname"
cp arch/$KARCH/boot/bzImage "$pkgdir/boot/vmlinuz26$_kernelname"

# add vmlinux
install -m644 -D vmlinux "$pkgdir/usr/src/linux-$_kernver/vmlinux"

# install fallback mkinitcpio.conf file and preset file for kernel
install -m644 -D "$srcdir/$pkgname.preset" "$pkgdir/etc/mkinitcpio.d/$pkgname.preset"

# set correct depmod command for install
sed \
-e "s/KERNEL_NAME=.*/KERNEL_NAME=$_kernelname/g" \
-e "s/KERNEL_VERSION=.*/KERNEL_VERSION=$_kernver/g" \
-i "$startdir/$install"
sed \
-e "s|source .*|source /etc/mkinitcpio.d/kernel26$_kernelname.kver|g" \
-e "s|default_image=.*|default_image=\"/boot/$pkgname.img\"|g" \
-e "s|fallback_image=.*|fallback_image=\"/boot/$pkgname-fallback.img\"|g" \
-i "$pkgdir/etc/mkinitcpio.d/$pkgname.preset"

echo -e "# DO NOT EDIT THIS FILE\nALL_kver='$_kernver'" > "$pkgdir/etc/mkinitcpio.d/$pkgname.kver"

# remove build and source links
rm -f "$pkgdir"/lib/modules/$_kernver/{source,build}

# remove the firmware
rm -rf "$pkgdir/lib/firmware"

# -- package the headers --#

mkdir -p "$pkgdir/lib/modules/$_kernver"
cd "$pkgdir/lib/modules/$_kernver"
ln -sf ../../../usr/src/linux-$_kernver build
cd "$srcdir/linux-$_realkernel"
install -D -m644 Makefile \
"$pkgdir/usr/src/linux-$_kernver/Makefile"
install -D -m644 kernel/Makefile \
"$pkgdir/usr/src/linux-$_kernver/kernel/Makefile"
install -D -m644 .config \
"$pkgdir/usr/src/linux-$_kernver/.config"
mkdir -p "$pkgdir/usr/src/linux-$_kernver/include"

for i in acpi asm-generic config generated linux math-emu media net pcmcia scsi sound trace video; do
cp -a include/$i "$pkgdir/usr/src/linux-$_kernver/include/"
done

# copy arch includes for external modules
mkdir -p "$pkgdir/usr/src/linux-$_kernver/arch/x86"
cp -a arch/x86/include "$pkgdir/usr/src/linux-$_kernver/arch/x86/"

# copy files necessary for later builds, like nvidia and vmware
cp Module.symvers "$pkgdir/usr/src/linux-$_kernver"
cp -a scripts "$pkgdir/usr/src/linux-$_kernver"

# fix permissions on scripts dir
chmod og-w -R "$pkgdir/usr/src/linux-$_kernver/scripts"
mkdir -p "$pkgdir/usr/src/linux-$_kernver/.tmp_versions"

mkdir -p "$pkgdir/usr/src/linux-$_kernver/arch/$KARCH/kernel"

cp arch/$KARCH/Makefile "$pkgdir/usr/src/linux-$_kernver/arch/$KARCH/"

if [ "$CARCH" = "i686" ]; then
cp arch/$KARCH/Makefile_32.cpu "$pkgdir/usr/src/linux-$_kernver/arch/$KARCH/"
fi

cp arch/$KARCH/kernel/asm-offsets.s "$pkgdir/usr/src/linux-$_kernver/arch/$KARCH/kernel/"

# add headers for lirc package
mkdir -p "$pkgdir/usr/src/linux-$_kernver/drivers/media/video"
cp drivers/media/video/*.h "$pkgdir/usr/src/linux-$_kernver/drivers/media/video/"

for i in bt8xx cpia2 cx25840 cx88 em28xx et61x251 pwc saa7134 sn9c102 usbvideo zc0301; do
mkdir -p "$pkgdir/usr/src/linux-$_kernver/drivers/media/video/$i"
cp -a drivers/media/video/$i/*.h "$pkgdir/usr/src/linux-$_kernver/drivers/media/video/$i"
done

# add docbook makefile
install -D -m644 Documentation/DocBook/Makefile \
"$pkgdir/usr/src/linux-$_kernver/Documentation/DocBook/Makefile"

# add dm headers
mkdir -p "$pkgdir/usr/src/linux-$_kernver/drivers/md"
cp drivers/md/*.h "$pkgdir/usr/src/linux-$_kernver/drivers/md"

# add inotify.h
mkdir -p "$pkgdir/usr/src/linux-$_kernver/include/linux"
cp include/linux/inotify.h "$pkgdir/usr/src/linux-$_kernver/include/linux/"

# add wireless headers
mkdir -p "$pkgdir/usr/src/linux-$_kernver/net/mac80211/"
cp net/mac80211/*.h "$pkgdir/usr/src/linux-$_kernver/net/mac80211/"

# add dvb headers for external modules
# in reference to:
# http://bugs.archlinux.org/task/9912
mkdir -p "$pkgdir/usr/src/linux-$_kernver/drivers/media/dvb/dvb-core"
cp drivers/media/dvb/dvb-core/*.h "$pkgdir/usr/src/linux-$_kernver/drivers/media/dvb/dvb-core/"

# add dvb headers for external modules
# in reference to:
# http://bugs.archlinux.org/task/11194
mkdir -p "$pkgdir/usr/src/linux-$_kernver/include/config/dvb/"
cp include/config/dvb/*.h "$pkgdir/usr/src/linux-$_kernver/include/config/dvb/"

# add dvb headers for http://mcentral.de/hg/~mrec/em28xx-new
# in reference to:
# http://bugs.archlinux.org/task/13146
mkdir -p "$pkgdir/usr/src/linux-$_kernver/drivers/media/dvb/frontends/"
cp drivers/media/dvb/frontends/lgdt330x.h "$pkgdir/usr/src/linux-$_kernver/drivers/media/dvb/frontends/"
cp drivers/media/video/msp3400-driver.h "$pkgdir/usr/src/linux-$_kernver/drivers/media/dvb/frontends/"

# add xfs and shmem for aufs building
mkdir -p "$pkgdir/usr/src/linux-$_kernver/fs/xfs"
mkdir -p "$pkgdir/usr/src/linux-$_kernver/mm"
cp fs/xfs/xfs_sb.h "$pkgdir/usr/src/linux-$_kernver/fs/xfs/xfs_sb.h"

# add headers vor virtualbox
# in reference to:
# http://bugs.archlinux.org/task/14568
cp -a include/drm "$pkgdir/usr/src/linux-$_kernver/include/"

# add headers for broadcom wl
# in reference to:
# http://bugs.archlinux.org/task/14568
cp -a include/trace "$pkgdir/usr/src/linux-$_kernver/include/"

# copy in Kconfig files
for i in `find . -name "Kconfig*"`; do
mkdir -p "$pkgdir"/usr/src/linux-$_kernver/`echo $i | sed 's|/Kconfig.*||'`
cp $i "$pkgdir/usr/src/linux-$_kernver/$i"
done

chown -R root.root "$pkgdir/usr/src/linux-$_kernver"
find "$pkgdir/usr/src/linux-$_kernver" -type d -exec chmod 755 {} \;

# remove unneeded architectures
rm -rf "$pkgdir/usr/src/linux-$_kernver/arch/{alpha,arm,arm26,avr32,blackfin,cris,frv,h8300,ia64,m32r,m68k,m68knommu,mips,microblaze,mn10300,parisc,powerpc,ppc,s390,sh,sh64,sparc,sparc64,um,v850,xtensa}"
}

# vim:set ts=2 sw=2 et:
md5sums=('c3883760b18d50e8d78819c54d579b00'
'f6801744832f9cc7c7993fa2265e86c3'
'110380e5eeb2fbc019c7232037dc522c'
'18da80ac1d41cba0f74cace471862bba'
'bcfba8783fd7d0db1261de2f002ad717'
'a0921a7e563e7ae2d14c3a0603fa16ad'
'6a5a1925501fe20fafd04fdb3cb4f6ed'
'edb62063ec2a61fc82cc00b89920f729'
'e924c5a340f2731c245e6bff8002be13')

smoge commented on 2011-04-11 16:08

new release: http://www.kernel.org/pub/linux/kernel/projects/rt/

schivmeister commented on 2011-03-07 19:18

Err..that doesn't quite look official. No specific URL to a patch other than a git repo. Unflagging.

mango commented on 2011-03-07 14:12

http://marc.info/?l=linux-rt-users&m=129927746730587&w=2

Det commented on 2011-02-21 11:10

As long as you didn't change 'CONFIG_PREEMPT_RT=y' while at it.

Nareto commented on 2011-02-21 11:01

hello, noob question: if I simply exit in menuconfig without changing any options, will I get a real time capable kernel? (needed for audio)

Anonymous comment on 2011-02-01 16:53

it don't build with testing/make (3.82-2) with this error:

make[1]: *** No rule to make target `/tmp/yaourt-tmp-becks/aur-kernel26rt/pkg/lib/firmware/./', needed by `/tmp/yaourt-tmp-becks/aur-kernel26rt/pkg/lib/firmware/atmsar11.fw'. Stop.
make: *** [_modinst_post] Error 2
Aborting...

with core/make (3.81-5) build fine
thanks

Det commented on 2011-01-08 15:43

Anybody got a clue why are they staying with .33? Didn't really find anything by checking the website.

E: Nevermind found this: https://www.osadl.org/Single-View.111+M528d085a4d0.0.html - where it says (at least) (at the very end) that:
"Before you ask: Kernel versions 2.6.34 to 2.6.36 will be left out, the next "Latest Stable" real-time kernel will be based on 2.6.37."

Det commented on 2011-01-08 15:42

Anybody got a clue why are they staying with .33? Didn't really find anything by checking the website.

smoge commented on 2010-12-26 17:25

Thanks!!!