summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Robbins <drobbins@gentoo.org>2002-03-12 18:22:16 +0000
committerDaniel Robbins <drobbins@gentoo.org>2002-03-12 18:22:16 +0000
commitb67bee1331815669f903a1164451d2d06d29280e (patch)
tree216caf9ddc47422c1bd14ee4f8c733b30e954a9e /sys-kernel/linux-sources
parentChanged dependency to ~net-www/mozilla-0.9.8 (diff)
downloadgentoo-2-b67bee1331815669f903a1164451d2d06d29280e.tar.gz
gentoo-2-b67bee1331815669f903a1164451d2d06d29280e.tar.bz2
gentoo-2-b67bee1331815669f903a1164451d2d06d29280e.zip
new reworked linux-sources ebuilds. No version bump since the sources themselves
haven't changed.
Diffstat (limited to 'sys-kernel/linux-sources')
-rw-r--r--sys-kernel/linux-sources/ChangeLog15
-rw-r--r--sys-kernel/linux-sources/linux-sources-2.4.17-r5.ebuild81
-rw-r--r--sys-kernel/linux-sources/linux-sources-2.4.18.ebuild87
3 files changed, 71 insertions, 112 deletions
diff --git a/sys-kernel/linux-sources/ChangeLog b/sys-kernel/linux-sources/ChangeLog
index afd94391b3aa..1c54a0970666 100644
--- a/sys-kernel/linux-sources/ChangeLog
+++ b/sys-kernel/linux-sources/ChangeLog
@@ -1,6 +1,19 @@
# ChangeLog for sys-kernel/linux-sources
# Copyright 2002 Gentoo Technologies, Inc.; Distributed under the GPL
-# $Header: /var/cvsroot/gentoo-x86/sys-kernel/linux-sources/ChangeLog,v 1.5 2002/02/28 18:10:52 g2boojum Exp $
+# $Header: /var/cvsroot/gentoo-x86/sys-kernel/linux-sources/ChangeLog,v 1.6 2002/03/12 18:22:16 drobbins Exp $
+
+*linux-sources-2.4.17-r5 (12 Mar 2002)
+*linux-sources-2.4.18 (12 Mar 2002)
+
+ 12 Mar 2002; Daniel Robbins <drobbins@gentoo.org>: Reworked internals of
+ 2.4.17-r5 and 2.4.18 ebuilds but did not bump version since the actual kernel
+ sources are the same. A lot of streamlining. In addition, we now use the
+ existing .config of the currently-active (pointed to by /usr/src/linux)
+ kernel if available. Many things were moved to pkg_postinst() as they fit
+ better there. We now do a "make dep" after the kernel sources are installed.
+ This closes bug #1045, which will cause any kernel module-related ebuild
+ merges to fail if linux-sources has been updated without the user doing a
+ manual "make dep".
*linux-sources-2.2.x (28 Feb 2002)
diff --git a/sys-kernel/linux-sources/linux-sources-2.4.17-r5.ebuild b/sys-kernel/linux-sources/linux-sources-2.4.17-r5.ebuild
index 2f2896fb84a6..57f78b537be0 100644
--- a/sys-kernel/linux-sources/linux-sources-2.4.17-r5.ebuild
+++ b/sys-kernel/linux-sources/linux-sources-2.4.17-r5.ebuild
@@ -1,7 +1,7 @@
# Copyright 1999-2002 Gentoo Technologies, Inc.
# Distributed under the terms of the GNU General Public License, v2 or later
# Maintainer: Daniel Robbins <drobbins@gentoo.org>
-# $Header: /var/cvsroot/gentoo-x86/sys-kernel/linux-sources/linux-sources-2.4.17-r5.ebuild,v 1.1 2002/02/15 05:41:58 drobbins Exp $
+# $Header: /var/cvsroot/gentoo-x86/sys-kernel/linux-sources/linux-sources-2.4.17-r5.ebuild,v 1.2 2002/03/12 18:22:16 drobbins Exp $
#OKV=original kernel version, KV=patched kernel version. They can be the same.
#we use this next variable to avoid duplicating stuff on cvs
@@ -9,7 +9,6 @@ GFILESDIR=${PORTDIR}/sys-kernel/linux-sources/files
OKV=${PV}
KV=${PVR}
S=${WORKDIR}/linux-${KV}
-S2=${WORKDIR}/linux-${KV}-extras
# What's in this kernel?
@@ -42,38 +41,26 @@ XFSV=20020124
if [ $PN = "linux-sources" ] && [ -z "`use build`" ]
then
- #console-tools is needed to solve the loadkeys fiasco.
- #binutils version needed to avoid Athlon/PIII/SSE assembler bugs.
- DEPEND=">=sys-devel/binutils-2.11.90.0.31 sys-apps/console-tools >=sys-apps/modutils-2.4.2 sys-devel/perl"
- RDEPEND=">=sys-libs/ncurses-5.2 >=sys-apps/xfsprogs-${XFSV} >=sys-apps/dmapi-${XFSV} >=sys-apps/attr-${XFSV} >=sys-apps/acl-${XFSV} >=sys-apps/xfsdump-${XFSV}"
+ #console-tools is needed to solve the loadkeys fiasco; binutils version needed to avoid Athlon/PIII/SSE assembler bugs.
+ DEPEND=">=sys-devel/binutils-2.11.90.0.31"
+ RDEPEND=">=sys-libs/ncurses-5.2 sys-devel/perl >=sys-apps/xfsprogs-${XFSV} sys-apps/kbd >=sys-apps/dmapi-${XFSV} >=sys-apps/modutils-2.4.2 sys-devel/make >=sys-apps/attr-${XFSV} >=sys-apps/acl-${XFSV} >=sys-apps/xfsdump-${XFSV}"
fi
[ -z "$LINUX_HOSTCFLAGS" ] && LINUX_HOSTCFLAGS="-Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -I${S}/include"
src_unpack() {
- mkdir ${S2}
-
cd ${WORKDIR}
unpack linux-${OKV}.tar.bz2
mv linux linux-${KV} || die
- dodir /usr/src/linux-${KV}-extras
- if [ "$MOSIX" ]
- then
- cd ${S2}
- tar -xz --no-same-owner -f ${DISTDIR}/MOSIX-${MOSV}.tar.gz MOSIX-${MOSV}/patches.${OKV}
- fi
cd ${S}
cat ${DISTDIR}/linux-gentoo-${KV}.patch.bz2 | bzip2 -d | patch -p1 || die
- echo "Preparing for compilation..."
#sometimes we have icky kernel symbols; this seems to get rid of them
make mrproper || die
- #linux-sources needs to be fully configured, too. This is the configuration for the default kernel
- cp ${S}/arch/i386/defconfig .config || die
- yes "" | make oldconfig
- echo "Ignore any errors from the yes command above."
-
+ #this file is required for other things to build properly, so we autogenerate it
+ make include/linux/version.h || die
+
#fix silly permissions in tarball
cd ${WORKDIR}
chown -R 0.0 *
@@ -86,14 +73,6 @@ src_unpack() {
Makefile.orig >Makefile || die # test, remove me if Makefile ok
rm Makefile.orig
}
-
-src_compile() {
- if [ "${PN}" = "linux-headers" ]
- then
- cd ${S}
- make include/linux/autoconf.h include/linux/version.h || die
- fi
-}
src_install() {
if [ "$PN" = "linux-sources" ]
@@ -102,45 +81,39 @@ src_install() {
cd ${S}
echo ">>> Copying sources..."
mv ${WORKDIR}/* ${D}/usr/src
- elif [ "$PN" = "linux-headers" ]
- then
+ else
+ #linux-headers
dodir /usr/include/linux
cp -ax ${S}/include/linux/* ${D}/usr/include/linux
dodir /usr/include/asm
cp -ax ${S}/include/asm-i386/* ${D}/usr/include/asm
fi
- if [ -d ${D}/usr/src/linux-${KV} ]
- then
- cd ${D}/usr/src/linux-${KV}
- if [ -e .config ]
- then
- mv .config .config.eg
- fi
- fi
}
pkg_preinst() {
- if [ "$PN" = "linux-headers" ]
- then
- if [ -L ${ROOT}usr/include/linux ]
- then
- rm ${ROOT}usr/include/linux
- fi
- if [ -L ${ROOT}usr/include/asm ]
- then
- rm ${ROOT}usr/include/asm
- fi
- fi
+ [ "$PN" = "linux-sources" ] && return
+ [ -L ${ROOT}usr/include/linux ] && rm ${ROOT}usr/include/linux
+ [ -L ${ROOT}usr/include/asm ] && rm ${ROOT}usr/include/asm
+ return
}
pkg_postinst() {
[ "$PN" = "linux-headers" ] && return
+ cd ${ROOT}usr/src/linux-${KV}
+ if [ -e "${ROOT}usr/src/linux/.config" ]
+ then
+ cp "${ROOT}usr/src/linux/.config" .config
+ else
+ cp "${ROOT}usr/src/linux-${KV}/arch/i386/defconfig" .config
+ fi
+ #The default setting will be selected.
+ yes "" | make oldconfig
+ echo "Ignore any errors from the yes command above."
+ #remove /usr/src/linux symlink
rm -f ${ROOT}/usr/src/linux
+ #set up a new one
ln -sf linux-${KV} ${ROOT}/usr/src/linux
- #copy over our .config if one isn't already present
+ #this will generate include/linux/modversions.h, among other things:
cd ${ROOT}/usr/src/linux-${KV}
- if [ "${PN}" = "linux-sources" ] && [ -e .config.eg ] && [ ! -e .config ]
- then
- cp -a .config.eg .config
- fi
+ make dep
}
diff --git a/sys-kernel/linux-sources/linux-sources-2.4.18.ebuild b/sys-kernel/linux-sources/linux-sources-2.4.18.ebuild
index 37db59b9c5a8..d02c0f4811c8 100644
--- a/sys-kernel/linux-sources/linux-sources-2.4.18.ebuild
+++ b/sys-kernel/linux-sources/linux-sources-2.4.18.ebuild
@@ -1,15 +1,14 @@
# Copyright 1999-2002 Gentoo Technologies, Inc.
# Distributed under the terms of the GNU General Public License, v2 or later
# Maintainer: Daniel Robbins <drobbins@gentoo.org>
-# $Header: /var/cvsroot/gentoo-x86/sys-kernel/linux-sources/linux-sources-2.4.18.ebuild,v 1.1 2002/02/25 21:55:50 drobbins Exp $
+# $Header: /var/cvsroot/gentoo-x86/sys-kernel/linux-sources/linux-sources-2.4.18.ebuild,v 1.2 2002/03/12 18:22:16 drobbins Exp $
#OKV=original kernel version, KV=patched kernel version. They can be the same.
#we use this next variable to avoid duplicating stuff on cvs
GFILESDIR=${PORTDIR}/sys-kernel/linux-sources/files
-OKV=${PV}
+OKV=2.4.17
KV=${PVR}
S=${WORKDIR}/linux-${KV}
-S2=${WORKDIR}/linux-${KV}-extras
# What's in this kernel?
@@ -32,7 +31,7 @@ S2=${WORKDIR}/linux-${KV}-extras
# loopback device deadlock fixes from akpm / are these included in aa's patches?
DESCRIPTION="Full sources for the Gentoo Linux kernel"
-SRC_URI="http://www.kernel.org/pub/linux/kernel/v2.4/linux-2.4.17.tar.bz2 http://www.ibiblio.org/gentoo/distfiles/linux-gentoo-${KV}.patch.bz2"
+SRC_URI="http://www.kernel.org/pub/linux/kernel/v2.4/linux-${OKV}.tar.bz2 http://www.ibiblio.org/gentoo/distfiles/linux-gentoo-${KV}.patch.bz2"
PROVIDE="virtual/kernel"
HOMEPAGE="http://www.kernel.org/ http://www.gentoo.org/"
@@ -40,38 +39,26 @@ XFSV=20020124
if [ $PN = "linux-sources" ] && [ -z "`use build`" ]
then
- #console-tools is needed to solve the loadkeys fiasco.
- #binutils version needed to avoid Athlon/PIII/SSE assembler bugs.
- DEPEND=">=sys-devel/binutils-2.11.90.0.31 sys-apps/console-tools >=sys-apps/modutils-2.4.2 sys-devel/perl"
- RDEPEND=">=sys-libs/ncurses-5.2 >=sys-apps/xfsprogs-${XFSV} >=sys-apps/dmapi-${XFSV} >=sys-apps/attr-${XFSV} >=sys-apps/acl-${XFSV} >=sys-apps/xfsdump-${XFSV}"
+ #console-tools is needed to solve the loadkeys fiasco; binutils version needed to avoid Athlon/PIII/SSE assembler bugs.
+ DEPEND=">=sys-devel/binutils-2.11.90.0.31"
+ RDEPEND=">=sys-libs/ncurses-5.2 sys-devel/perl >=sys-apps/xfsprogs-${XFSV} sys-apps/kbd >=sys-apps/dmapi-${XFSV} >=sys-apps/modutils-2.4.2 sys-devel/make >=sys-apps/attr-${XFSV} >=sys-apps/acl-${XFSV} >=sys-apps/xfsdump-${XFSV}"
fi
[ -z "$LINUX_HOSTCFLAGS" ] && LINUX_HOSTCFLAGS="-Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -I${S}/include"
src_unpack() {
- mkdir ${S2}
-
cd ${WORKDIR}
- unpack linux-2.4.17.tar.bz2
+ unpack linux-${OKV}.tar.bz2
mv linux linux-${KV} || die
- dodir /usr/src/linux-${KV}-extras
- if [ "$MOSIX" ]
- then
- cd ${S2}
- tar -xz --no-same-owner -f ${DISTDIR}/MOSIX-${MOSV}.tar.gz MOSIX-${MOSV}/patches.${OKV}
- fi
cd ${S}
cat ${DISTDIR}/linux-gentoo-${KV}.patch.bz2 | bzip2 -d | patch -p1 || die
- echo "Preparing for compilation..."
#sometimes we have icky kernel symbols; this seems to get rid of them
make mrproper || die
- #linux-sources needs to be fully configured, too. This is the configuration for the default kernel
- cp ${S}/arch/i386/defconfig .config || die
- yes "" | make oldconfig
- echo "Ignore any errors from the yes command above."
-
+ #this file is required for other things to build properly, so we autogenerate it
+ make include/linux/version.h || die
+
#fix silly permissions in tarball
cd ${WORKDIR}
chown -R 0.0 *
@@ -84,14 +71,6 @@ src_unpack() {
Makefile.orig >Makefile || die # test, remove me if Makefile ok
rm Makefile.orig
}
-
-src_compile() {
- if [ "${PN}" = "linux-headers" ]
- then
- cd ${S}
- make include/linux/autoconf.h include/linux/version.h || die
- fi
-}
src_install() {
if [ "$PN" = "linux-sources" ]
@@ -100,45 +79,39 @@ src_install() {
cd ${S}
echo ">>> Copying sources..."
mv ${WORKDIR}/* ${D}/usr/src
- elif [ "$PN" = "linux-headers" ]
- then
+ else
+ #linux-headers
dodir /usr/include/linux
cp -ax ${S}/include/linux/* ${D}/usr/include/linux
dodir /usr/include/asm
cp -ax ${S}/include/asm-i386/* ${D}/usr/include/asm
fi
- if [ -d ${D}/usr/src/linux-${KV} ]
- then
- cd ${D}/usr/src/linux-${KV}
- if [ -e .config ]
- then
- mv .config .config.eg
- fi
- fi
}
pkg_preinst() {
- if [ "$PN" = "linux-headers" ]
- then
- if [ -L ${ROOT}usr/include/linux ]
- then
- rm ${ROOT}usr/include/linux
- fi
- if [ -L ${ROOT}usr/include/asm ]
- then
- rm ${ROOT}usr/include/asm
- fi
- fi
+ [ "$PN" = "linux-sources" ] && return
+ [ -L ${ROOT}usr/include/linux ] && rm ${ROOT}usr/include/linux
+ [ -L ${ROOT}usr/include/asm ] && rm ${ROOT}usr/include/asm
+ return
}
pkg_postinst() {
[ "$PN" = "linux-headers" ] && return
+ cd ${ROOT}usr/src/linux-${KV}
+ if [ -e "${ROOT}usr/src/linux/.config" ]
+ then
+ cp "${ROOT}usr/src/linux/.config" .config
+ else
+ cp "${ROOT}usr/src/linux-${KV}/arch/i386/defconfig" .config
+ fi
+ #The default setting will be selected.
+ yes "" | make oldconfig
+ echo "Ignore any errors from the yes command above."
+ #remove /usr/src/linux symlink
rm -f ${ROOT}/usr/src/linux
+ #set up a new one
ln -sf linux-${KV} ${ROOT}/usr/src/linux
- #copy over our .config if one isn't already present
+ #this will generate include/linux/modversions.h, among other things:
cd ${ROOT}/usr/src/linux-${KV}
- if [ "${PN}" = "linux-sources" ] && [ -e .config.eg ] && [ ! -e .config ]
- then
- cp -a .config.eg .config
- fi
+ make dep
}