From e49fcc14840801654fe23701f409db65e52421b3 Mon Sep 17 00:00:00 2001 From: Bertrand Jacquin Date: Thu, 26 Dec 2013 15:26:06 +0100 Subject: sys-kernel/longterm-sources: Version bump Package-Manager: portage-2.2.7 RepoMan-Options: --force --- sys-kernel/longterm-sources/ChangeLog | 8 + sys-kernel/longterm-sources/Manifest | 10 +- .../longterm-sources-3.10.24.ebuild | 197 --------------------- .../longterm-sources-3.10.25.ebuild | 197 +++++++++++++++++++++ .../longterm-sources-3.4.74.ebuild | 197 --------------------- .../longterm-sources-3.4.75.ebuild | 197 +++++++++++++++++++++ 6 files changed, 407 insertions(+), 399 deletions(-) delete mode 100644 sys-kernel/longterm-sources/longterm-sources-3.10.24.ebuild create mode 100644 sys-kernel/longterm-sources/longterm-sources-3.10.25.ebuild delete mode 100644 sys-kernel/longterm-sources/longterm-sources-3.4.74.ebuild create mode 100644 sys-kernel/longterm-sources/longterm-sources-3.4.75.ebuild (limited to 'sys-kernel/longterm-sources') diff --git a/sys-kernel/longterm-sources/ChangeLog b/sys-kernel/longterm-sources/ChangeLog index 5695b9a0..ec1776ca 100644 --- a/sys-kernel/longterm-sources/ChangeLog +++ b/sys-kernel/longterm-sources/ChangeLog @@ -2,6 +2,14 @@ # Copyright 1999-2013 Gentoo Foundation; Distributed under the GPL v2 # $Header: $ +*longterm-sources-3.10.25 (26 Dec 2013) +*longterm-sources-3.4.75 (26 Dec 2013) + + 26 Dec 2013; Bertrand Jacquin + +longterm-sources-3.10.25.ebuild, +longterm-sources-3.4.75.ebuild, + -longterm-sources-3.10.24.ebuild, -longterm-sources-3.4.74.ebuild: + sys-kernel/longterm-sources: Version bump + *longterm-sources-3.10.24 (14 Dec 2013) *longterm-sources-3.4.74 (14 Dec 2013) diff --git a/sys-kernel/longterm-sources/Manifest b/sys-kernel/longterm-sources/Manifest index c64e2081..77ec9f3e 100644 --- a/sys-kernel/longterm-sources/Manifest +++ b/sys-kernel/longterm-sources/Manifest @@ -3,12 +3,12 @@ DIST linux-3.10.tar.xz 73175088 SHA256 df27fa92d27a9c410bfe6c4a89f141638500d7ead DIST linux-3.2.tar.xz 65065516 SHA256 dd96ed02b53fb5d57762e4b1f573460909de472ca588f81ec6660e4a172e7ba7 WHIRLPOOL 7cc68baac4441740e2171fbbc4195ee6c0351de099aadaee8cb3487f6d1f8b7e1d3144ee54ba38dbd24d6be431a1ea3b921ffce82ff84df21a98da7bc61c1d17 DIST linux-3.4.tar.xz 66748028 SHA256 ff3dee6a855873d12487a6f4070ec2f7996d073019171361c955639664baa0c6 WHIRLPOOL a36e62fe197ba7c08d498a79034da58091a94348f69542241067c9ebef683f86371b2c0a3b3fb6c4611e2fb885d9b74eee5c1f46a493c72dfb76c5665f0b8a6a DIST patch-3.0.101.xz 938412 SHA256 76de0e0179f991501a77c9ea2b52857d2fb5565ec3fba9b9a7123b7b3ea17f53 WHIRLPOOL 99f71b4323cdd2c521bdfc6156ecce9e97e51cabac9b98655e09236afcf8d865e41c9c67380cd5f1e8821449eeab9353474eae8e7e88a0b4cc20e0708d1cfd28 -DIST patch-3.10.24.xz 464636 SHA256 7c86e95d1e94350c47b509f070977fc75b1be3f30665cde86c15a9a110e6d296 WHIRLPOOL 59d130b039f78451aeb1f2dacb98847b2395b670d338c5e24a4a342ea54cd88eb57cf01120912033073c667357abf6451dc98cd5554ee5b7bcb7f4259cd3a6a4 +DIST patch-3.10.25.xz 481296 SHA256 58323f60a2c5156e9e46b5947e7b3d81be44895c2b5dc31ced8d0e5346ca4d43 WHIRLPOOL 66d87c7194f4b414005ab7e43cc23dede8527c9f32b85090bc8585f9c1f88077971f7e6f655f6a478ae4832da52f7dab09fac2f608c43812ec24b2dbef9aba8e DIST patch-3.2.53.xz 1040524 SHA256 8724807db73a9658dde155570bd2169d407ebe60bf1aed90702b257663b6d039 WHIRLPOOL 6ac0ec247ed53f3ef26055d69d49bca435f985740c3dd62bae725d2d4b764a680edf3dd5d78ddc7410c00ed8a941055e903f6e3f3ffe700fd7a91c9834e787cd -DIST patch-3.4.74.xz 835740 SHA256 18184af72dbe9db38ce9c81beb4d51a02b8c2ed798206e6b040bcf9aa3736b60 WHIRLPOOL f7892414b197ea7e517be20cde513e0df80cf2018654b7f1c26260e286491cd5e8d2bda2e21a7da998132d9ed723922e763b52f502edc6f0d0946d9fb00d9614 +DIST patch-3.4.75.xz 842148 SHA256 f6de97c78c968ec65c2dd4e89dd254526d229272abe8c219e4f95a25862435ab WHIRLPOOL 6e8923e49fbb275a60574b4dc2a162365b866fd39ec07bf2f199a83666687ea5739cf3c02a2175af408e0ddb6306738ce224ad0d01ddb1856e7fc0d29bb4c03e EBUILD longterm-sources-3.0.101.ebuild 4484 SHA256 cb8e63ca9e42d910d477884d37087630d40cdf584107466b2925e2a209594950 WHIRLPOOL 0bec9d26ddcd1bb8db9bd1e7b0c967a69e9f73a0d771ff671e3961ddf28f78b98730521dcec02ab7080370584c0811071c7aaeb3c306932bf22b21d9617cb964 -EBUILD longterm-sources-3.10.24.ebuild 4484 SHA256 cb8e63ca9e42d910d477884d37087630d40cdf584107466b2925e2a209594950 WHIRLPOOL 0bec9d26ddcd1bb8db9bd1e7b0c967a69e9f73a0d771ff671e3961ddf28f78b98730521dcec02ab7080370584c0811071c7aaeb3c306932bf22b21d9617cb964 +EBUILD longterm-sources-3.10.25.ebuild 4484 SHA256 cb8e63ca9e42d910d477884d37087630d40cdf584107466b2925e2a209594950 WHIRLPOOL 0bec9d26ddcd1bb8db9bd1e7b0c967a69e9f73a0d771ff671e3961ddf28f78b98730521dcec02ab7080370584c0811071c7aaeb3c306932bf22b21d9617cb964 EBUILD longterm-sources-3.2.53.ebuild 4484 SHA256 cb8e63ca9e42d910d477884d37087630d40cdf584107466b2925e2a209594950 WHIRLPOOL 0bec9d26ddcd1bb8db9bd1e7b0c967a69e9f73a0d771ff671e3961ddf28f78b98730521dcec02ab7080370584c0811071c7aaeb3c306932bf22b21d9617cb964 -EBUILD longterm-sources-3.4.74.ebuild 4484 SHA256 cb8e63ca9e42d910d477884d37087630d40cdf584107466b2925e2a209594950 WHIRLPOOL 0bec9d26ddcd1bb8db9bd1e7b0c967a69e9f73a0d771ff671e3961ddf28f78b98730521dcec02ab7080370584c0811071c7aaeb3c306932bf22b21d9617cb964 -MISC ChangeLog 18604 SHA256 5fcff2ef4c2267aeba5ca7764588cf007e0eb057e1b76e1eb96c15f5cc62747a WHIRLPOOL 40c0775dfedded541a82ba3da06926ee581c48cdb7e0dccbaf6f2fe0e17f39435d632a3f70f003caf7fc5c4144dd7ef0e225f0ae73b6875ab028045ab3227b96 +EBUILD longterm-sources-3.4.75.ebuild 4484 SHA256 cb8e63ca9e42d910d477884d37087630d40cdf584107466b2925e2a209594950 WHIRLPOOL 0bec9d26ddcd1bb8db9bd1e7b0c967a69e9f73a0d771ff671e3961ddf28f78b98730521dcec02ab7080370584c0811071c7aaeb3c306932bf22b21d9617cb964 +MISC ChangeLog 18920 SHA256 8e8db09a9d9de40fe282207f89248f46fa136d8de6eeec54b6e20692b074b188 WHIRLPOOL 6fcfcf2c1d57496d87fa7b519a76ed62baa2c534071af0c52ef6e63a92b4be105b9468b9c17fbc2f5098a7573c17428bf8a651984952bc36524f52004f24ad22 MISC metadata.xml 254 SHA256 c56bc3d6780712c960298c70bb86867aeb6661e97a317cc624516b0e16b72fcc WHIRLPOOL 2ebbfaa14ef0c1847284fe64a79f052cd7e73b25a724fba728c084aaaf2dd0692e068eedcf42ccef7e205077f00c35780ded7ec69118dc01ddb988b4802e46ae diff --git a/sys-kernel/longterm-sources/longterm-sources-3.10.24.ebuild b/sys-kernel/longterm-sources/longterm-sources-3.10.24.ebuild deleted file mode 100644 index a9afb2a9..00000000 --- a/sys-kernel/longterm-sources/longterm-sources-3.10.24.ebuild +++ /dev/null @@ -1,197 +0,0 @@ -# Copyright 1999-2013 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Header: $ - -EAPI=5 -ETYPE="sources" - -inherit savedconfig kernel-2 -detect_version - -SLOT="${PV%.*}" - -DESCRIPTION="Kernel stable sources and build" -HOMEPAGE="http://www.kernel.org" -SRC_URI="${KERNEL_URI} ${GENPATCHES_URI} ${ARCH_URI}" - -KEYWORDS="amd64 x86" - -SRCDIR="${WORKDIR}/linux-${KV_FULL}" -BUILDDIR="${WORKDIR}/build" - -KV_EXTRA="${EXTRAVERSION}" -S="${SRCDIR}" - -IUSE="build source zlib lzma" -REQUIRED_USE=" - ?? ( zlib lzma ) - zlib? ( build ) - lzma? ( build ) - symlink? ( source ) - " - -DEPEND=" - sys-devel/bc - || ( - sys-apps/kmod[zlib?,lzma?] - sys-apps/module-init-tools - )" - -configval () { - local _v="CONFIG_$1" - - # Export only the needed config value - # when not already define - declare -p ${_v} > /dev/null 2>&1 \ - || . <(sed -n "/^${_v}=/ p" ${BUILDDIR}/.config) - - case "${!_v}" in - "") declare "$_v=n" ; export $_v ; return 1 ;; - *) export $_v ; return 0 ;; - esac -} - -do_prepare_build () { - mkdir "${BUILDDIR}" - - restore_config "${BUILDDIR}/.config" - if [ ! -e "${BUILDDIR}/.config" ] ; then - ewarn "Generate .config using 'defconfig'" - emake defconfig "${myopt[@]}" - fi - - mkdir "${WORKDIR}/boot" - - if configval CMDLINE_BOOL && configval CMDLINE ; then - einfo "Creating kernel.arg" - einfo " CONFIG_CMDLINE='${CONFIG_CMDLINE}'" - echo "${CONFIG_CMDLINE}" > "${WORKDIR}/boot/kernel.arg" - fi - - configval MODULES || ewarn "CONFIG_MODULES is not set" - configval UEVENT_HELPER_PATH \ - && ewarn "CONFIG_UEVENT_HELPER_PATH should be empty" -} - -src_prepare () { - bopt=( - -C "${BUILDDIR}" - -f "${SRCDIR}/Makefile" - KBUILD_SRC="${SRCDIR}" - KCONFIG_CONFIG="${BUILDDIR}/.config" - - KBUILD_BUILD_USER="${KBUILD_BUILD_USER:-$PORTAGE_USERNAME}" - ) - - copt=( - CC="$(tc-getCC)" HOSTCC="${CBUILD}-gcc" CROSS_COMPILE="${CHOST}-" - ARCH="$(tc-arch-kernel)" SUBARCH="$(tc-arch-kernel)" - ) - - vopt=( - EXTRAVERSION="${KV_EXTRA}" - LOCALVERSION= CONFIG_LOCALVERSION= - ) - - myopt=( "${bopt[@]}" "${copt[@]}" "${vopt[@]}" ) - - use build && do_prepare_build -} - -do_compile_build () { - einfo "Checking configuration file" - emake oldconfig "${myopt[@]}" < /dev/null - - if diff -Nu0 "${BUILDDIR}/.config.old" "${BUILDDIR}/.config" \ - | egrep -q '^(\-|\+)CONFIG_' ; then - eerror "You configuration is not up to date" - diff -Nu "${BUILDDIR}/.config.old" "${BUILDDIR}/.config" - die "Bad configuration" - fi - - einfo "Building kernel" - emake bzImage "${myopt[@]}" - - if configval MODULES ; then - einfo "Building modules" - emake modules "${myopt[@]}" - fi -} - -src_compile () { - use build && do_compile_build -} - -do_install_sources () { - kernel-2_src_install -} - -do_install_build () { - einfo "Installing kernel" - emake install "${myopt[@]}" \ - INSTALL_PATH="${WORKDIR}/boot" - - insinto "/boot/${KV_FULL}" - - newins "${WORKDIR}/boot/config-${KV_FULL}" kernel.cfg - newins "${WORKDIR}/boot/vmlinuz-${KV_FULL}" kernel.img - newins "${WORKDIR}/boot/System.map-${KV_FULL}" System.map - - if configval CMDLINE_BOOL && configval CMDLINE ; then - doins "${WORKDIR}/boot/kernel.arg" - fi - - if configval MODULES ; then - einfo "Installing modules" - emake modules_install "${myopt[@]}" \ - INSTALL_MOD_PATH="${WORKDIR}" \ - INSTALL_MOD_STRIP="${PORTAGE_STRIP_FLAGS}" - - # kmod only support zlib and lzma - # See libkmod/libkmod-util.c / struct kmod_ext kmod_exts - if use zlib || use lzma ; then - use zlib && { local cmp="gzip -9c" ; local ext="gz" ; } - use lzma && { local cmp="xz -9c" ; local ext="xz" ; } - - einfo "Compressing modules" - find "${WORKDIR}/lib/modules" \ - -type f -name "*.ko" \ - | while read ; do - ${cmp} < "${REPLY}" > "${REPLY}.${ext}" \ - || die "${cmp} ${REPLY} failed" - rm "${REPLY}" - done - fi - - einfo "Generating modules.dep" - depmod -ae -F "${BUILDDIR}/System.map" -b "${WORKDIR}" "${KV_FULL}" \ - || die "depmod failed" - - rm "${WORKDIR}/lib/modules/${KV_FULL}/build" - rm "${WORKDIR}/lib/modules/${KV_FULL}/source" - - insinto /lib - doins -r "${WORKDIR}/lib/modules" - - # No need to make firmware_install, make modules_install does - if [ -e "${WORKDIR}/lib/firmware" ] ; then - einfo "Installing firmwares" - - insinto /lib - doins -r "${WORKDIR}/lib/firmware" - fi - fi -} - -src_install () { - use build && do_install_build - use source && do_install_sources - use savedconfig && save_config "${BUILDDIR}/.config" -} - -pkg_postinst () { - kernel-2_pkg_postinst - - einfo "You may need to:" - einfo " make menuconfig ${copt[@]}" -} diff --git a/sys-kernel/longterm-sources/longterm-sources-3.10.25.ebuild b/sys-kernel/longterm-sources/longterm-sources-3.10.25.ebuild new file mode 100644 index 00000000..a9afb2a9 --- /dev/null +++ b/sys-kernel/longterm-sources/longterm-sources-3.10.25.ebuild @@ -0,0 +1,197 @@ +# Copyright 1999-2013 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: $ + +EAPI=5 +ETYPE="sources" + +inherit savedconfig kernel-2 +detect_version + +SLOT="${PV%.*}" + +DESCRIPTION="Kernel stable sources and build" +HOMEPAGE="http://www.kernel.org" +SRC_URI="${KERNEL_URI} ${GENPATCHES_URI} ${ARCH_URI}" + +KEYWORDS="amd64 x86" + +SRCDIR="${WORKDIR}/linux-${KV_FULL}" +BUILDDIR="${WORKDIR}/build" + +KV_EXTRA="${EXTRAVERSION}" +S="${SRCDIR}" + +IUSE="build source zlib lzma" +REQUIRED_USE=" + ?? ( zlib lzma ) + zlib? ( build ) + lzma? ( build ) + symlink? ( source ) + " + +DEPEND=" + sys-devel/bc + || ( + sys-apps/kmod[zlib?,lzma?] + sys-apps/module-init-tools + )" + +configval () { + local _v="CONFIG_$1" + + # Export only the needed config value + # when not already define + declare -p ${_v} > /dev/null 2>&1 \ + || . <(sed -n "/^${_v}=/ p" ${BUILDDIR}/.config) + + case "${!_v}" in + "") declare "$_v=n" ; export $_v ; return 1 ;; + *) export $_v ; return 0 ;; + esac +} + +do_prepare_build () { + mkdir "${BUILDDIR}" + + restore_config "${BUILDDIR}/.config" + if [ ! -e "${BUILDDIR}/.config" ] ; then + ewarn "Generate .config using 'defconfig'" + emake defconfig "${myopt[@]}" + fi + + mkdir "${WORKDIR}/boot" + + if configval CMDLINE_BOOL && configval CMDLINE ; then + einfo "Creating kernel.arg" + einfo " CONFIG_CMDLINE='${CONFIG_CMDLINE}'" + echo "${CONFIG_CMDLINE}" > "${WORKDIR}/boot/kernel.arg" + fi + + configval MODULES || ewarn "CONFIG_MODULES is not set" + configval UEVENT_HELPER_PATH \ + && ewarn "CONFIG_UEVENT_HELPER_PATH should be empty" +} + +src_prepare () { + bopt=( + -C "${BUILDDIR}" + -f "${SRCDIR}/Makefile" + KBUILD_SRC="${SRCDIR}" + KCONFIG_CONFIG="${BUILDDIR}/.config" + + KBUILD_BUILD_USER="${KBUILD_BUILD_USER:-$PORTAGE_USERNAME}" + ) + + copt=( + CC="$(tc-getCC)" HOSTCC="${CBUILD}-gcc" CROSS_COMPILE="${CHOST}-" + ARCH="$(tc-arch-kernel)" SUBARCH="$(tc-arch-kernel)" + ) + + vopt=( + EXTRAVERSION="${KV_EXTRA}" + LOCALVERSION= CONFIG_LOCALVERSION= + ) + + myopt=( "${bopt[@]}" "${copt[@]}" "${vopt[@]}" ) + + use build && do_prepare_build +} + +do_compile_build () { + einfo "Checking configuration file" + emake oldconfig "${myopt[@]}" < /dev/null + + if diff -Nu0 "${BUILDDIR}/.config.old" "${BUILDDIR}/.config" \ + | egrep -q '^(\-|\+)CONFIG_' ; then + eerror "You configuration is not up to date" + diff -Nu "${BUILDDIR}/.config.old" "${BUILDDIR}/.config" + die "Bad configuration" + fi + + einfo "Building kernel" + emake bzImage "${myopt[@]}" + + if configval MODULES ; then + einfo "Building modules" + emake modules "${myopt[@]}" + fi +} + +src_compile () { + use build && do_compile_build +} + +do_install_sources () { + kernel-2_src_install +} + +do_install_build () { + einfo "Installing kernel" + emake install "${myopt[@]}" \ + INSTALL_PATH="${WORKDIR}/boot" + + insinto "/boot/${KV_FULL}" + + newins "${WORKDIR}/boot/config-${KV_FULL}" kernel.cfg + newins "${WORKDIR}/boot/vmlinuz-${KV_FULL}" kernel.img + newins "${WORKDIR}/boot/System.map-${KV_FULL}" System.map + + if configval CMDLINE_BOOL && configval CMDLINE ; then + doins "${WORKDIR}/boot/kernel.arg" + fi + + if configval MODULES ; then + einfo "Installing modules" + emake modules_install "${myopt[@]}" \ + INSTALL_MOD_PATH="${WORKDIR}" \ + INSTALL_MOD_STRIP="${PORTAGE_STRIP_FLAGS}" + + # kmod only support zlib and lzma + # See libkmod/libkmod-util.c / struct kmod_ext kmod_exts + if use zlib || use lzma ; then + use zlib && { local cmp="gzip -9c" ; local ext="gz" ; } + use lzma && { local cmp="xz -9c" ; local ext="xz" ; } + + einfo "Compressing modules" + find "${WORKDIR}/lib/modules" \ + -type f -name "*.ko" \ + | while read ; do + ${cmp} < "${REPLY}" > "${REPLY}.${ext}" \ + || die "${cmp} ${REPLY} failed" + rm "${REPLY}" + done + fi + + einfo "Generating modules.dep" + depmod -ae -F "${BUILDDIR}/System.map" -b "${WORKDIR}" "${KV_FULL}" \ + || die "depmod failed" + + rm "${WORKDIR}/lib/modules/${KV_FULL}/build" + rm "${WORKDIR}/lib/modules/${KV_FULL}/source" + + insinto /lib + doins -r "${WORKDIR}/lib/modules" + + # No need to make firmware_install, make modules_install does + if [ -e "${WORKDIR}/lib/firmware" ] ; then + einfo "Installing firmwares" + + insinto /lib + doins -r "${WORKDIR}/lib/firmware" + fi + fi +} + +src_install () { + use build && do_install_build + use source && do_install_sources + use savedconfig && save_config "${BUILDDIR}/.config" +} + +pkg_postinst () { + kernel-2_pkg_postinst + + einfo "You may need to:" + einfo " make menuconfig ${copt[@]}" +} diff --git a/sys-kernel/longterm-sources/longterm-sources-3.4.74.ebuild b/sys-kernel/longterm-sources/longterm-sources-3.4.74.ebuild deleted file mode 100644 index a9afb2a9..00000000 --- a/sys-kernel/longterm-sources/longterm-sources-3.4.74.ebuild +++ /dev/null @@ -1,197 +0,0 @@ -# Copyright 1999-2013 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Header: $ - -EAPI=5 -ETYPE="sources" - -inherit savedconfig kernel-2 -detect_version - -SLOT="${PV%.*}" - -DESCRIPTION="Kernel stable sources and build" -HOMEPAGE="http://www.kernel.org" -SRC_URI="${KERNEL_URI} ${GENPATCHES_URI} ${ARCH_URI}" - -KEYWORDS="amd64 x86" - -SRCDIR="${WORKDIR}/linux-${KV_FULL}" -BUILDDIR="${WORKDIR}/build" - -KV_EXTRA="${EXTRAVERSION}" -S="${SRCDIR}" - -IUSE="build source zlib lzma" -REQUIRED_USE=" - ?? ( zlib lzma ) - zlib? ( build ) - lzma? ( build ) - symlink? ( source ) - " - -DEPEND=" - sys-devel/bc - || ( - sys-apps/kmod[zlib?,lzma?] - sys-apps/module-init-tools - )" - -configval () { - local _v="CONFIG_$1" - - # Export only the needed config value - # when not already define - declare -p ${_v} > /dev/null 2>&1 \ - || . <(sed -n "/^${_v}=/ p" ${BUILDDIR}/.config) - - case "${!_v}" in - "") declare "$_v=n" ; export $_v ; return 1 ;; - *) export $_v ; return 0 ;; - esac -} - -do_prepare_build () { - mkdir "${BUILDDIR}" - - restore_config "${BUILDDIR}/.config" - if [ ! -e "${BUILDDIR}/.config" ] ; then - ewarn "Generate .config using 'defconfig'" - emake defconfig "${myopt[@]}" - fi - - mkdir "${WORKDIR}/boot" - - if configval CMDLINE_BOOL && configval CMDLINE ; then - einfo "Creating kernel.arg" - einfo " CONFIG_CMDLINE='${CONFIG_CMDLINE}'" - echo "${CONFIG_CMDLINE}" > "${WORKDIR}/boot/kernel.arg" - fi - - configval MODULES || ewarn "CONFIG_MODULES is not set" - configval UEVENT_HELPER_PATH \ - && ewarn "CONFIG_UEVENT_HELPER_PATH should be empty" -} - -src_prepare () { - bopt=( - -C "${BUILDDIR}" - -f "${SRCDIR}/Makefile" - KBUILD_SRC="${SRCDIR}" - KCONFIG_CONFIG="${BUILDDIR}/.config" - - KBUILD_BUILD_USER="${KBUILD_BUILD_USER:-$PORTAGE_USERNAME}" - ) - - copt=( - CC="$(tc-getCC)" HOSTCC="${CBUILD}-gcc" CROSS_COMPILE="${CHOST}-" - ARCH="$(tc-arch-kernel)" SUBARCH="$(tc-arch-kernel)" - ) - - vopt=( - EXTRAVERSION="${KV_EXTRA}" - LOCALVERSION= CONFIG_LOCALVERSION= - ) - - myopt=( "${bopt[@]}" "${copt[@]}" "${vopt[@]}" ) - - use build && do_prepare_build -} - -do_compile_build () { - einfo "Checking configuration file" - emake oldconfig "${myopt[@]}" < /dev/null - - if diff -Nu0 "${BUILDDIR}/.config.old" "${BUILDDIR}/.config" \ - | egrep -q '^(\-|\+)CONFIG_' ; then - eerror "You configuration is not up to date" - diff -Nu "${BUILDDIR}/.config.old" "${BUILDDIR}/.config" - die "Bad configuration" - fi - - einfo "Building kernel" - emake bzImage "${myopt[@]}" - - if configval MODULES ; then - einfo "Building modules" - emake modules "${myopt[@]}" - fi -} - -src_compile () { - use build && do_compile_build -} - -do_install_sources () { - kernel-2_src_install -} - -do_install_build () { - einfo "Installing kernel" - emake install "${myopt[@]}" \ - INSTALL_PATH="${WORKDIR}/boot" - - insinto "/boot/${KV_FULL}" - - newins "${WORKDIR}/boot/config-${KV_FULL}" kernel.cfg - newins "${WORKDIR}/boot/vmlinuz-${KV_FULL}" kernel.img - newins "${WORKDIR}/boot/System.map-${KV_FULL}" System.map - - if configval CMDLINE_BOOL && configval CMDLINE ; then - doins "${WORKDIR}/boot/kernel.arg" - fi - - if configval MODULES ; then - einfo "Installing modules" - emake modules_install "${myopt[@]}" \ - INSTALL_MOD_PATH="${WORKDIR}" \ - INSTALL_MOD_STRIP="${PORTAGE_STRIP_FLAGS}" - - # kmod only support zlib and lzma - # See libkmod/libkmod-util.c / struct kmod_ext kmod_exts - if use zlib || use lzma ; then - use zlib && { local cmp="gzip -9c" ; local ext="gz" ; } - use lzma && { local cmp="xz -9c" ; local ext="xz" ; } - - einfo "Compressing modules" - find "${WORKDIR}/lib/modules" \ - -type f -name "*.ko" \ - | while read ; do - ${cmp} < "${REPLY}" > "${REPLY}.${ext}" \ - || die "${cmp} ${REPLY} failed" - rm "${REPLY}" - done - fi - - einfo "Generating modules.dep" - depmod -ae -F "${BUILDDIR}/System.map" -b "${WORKDIR}" "${KV_FULL}" \ - || die "depmod failed" - - rm "${WORKDIR}/lib/modules/${KV_FULL}/build" - rm "${WORKDIR}/lib/modules/${KV_FULL}/source" - - insinto /lib - doins -r "${WORKDIR}/lib/modules" - - # No need to make firmware_install, make modules_install does - if [ -e "${WORKDIR}/lib/firmware" ] ; then - einfo "Installing firmwares" - - insinto /lib - doins -r "${WORKDIR}/lib/firmware" - fi - fi -} - -src_install () { - use build && do_install_build - use source && do_install_sources - use savedconfig && save_config "${BUILDDIR}/.config" -} - -pkg_postinst () { - kernel-2_pkg_postinst - - einfo "You may need to:" - einfo " make menuconfig ${copt[@]}" -} diff --git a/sys-kernel/longterm-sources/longterm-sources-3.4.75.ebuild b/sys-kernel/longterm-sources/longterm-sources-3.4.75.ebuild new file mode 100644 index 00000000..a9afb2a9 --- /dev/null +++ b/sys-kernel/longterm-sources/longterm-sources-3.4.75.ebuild @@ -0,0 +1,197 @@ +# Copyright 1999-2013 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: $ + +EAPI=5 +ETYPE="sources" + +inherit savedconfig kernel-2 +detect_version + +SLOT="${PV%.*}" + +DESCRIPTION="Kernel stable sources and build" +HOMEPAGE="http://www.kernel.org" +SRC_URI="${KERNEL_URI} ${GENPATCHES_URI} ${ARCH_URI}" + +KEYWORDS="amd64 x86" + +SRCDIR="${WORKDIR}/linux-${KV_FULL}" +BUILDDIR="${WORKDIR}/build" + +KV_EXTRA="${EXTRAVERSION}" +S="${SRCDIR}" + +IUSE="build source zlib lzma" +REQUIRED_USE=" + ?? ( zlib lzma ) + zlib? ( build ) + lzma? ( build ) + symlink? ( source ) + " + +DEPEND=" + sys-devel/bc + || ( + sys-apps/kmod[zlib?,lzma?] + sys-apps/module-init-tools + )" + +configval () { + local _v="CONFIG_$1" + + # Export only the needed config value + # when not already define + declare -p ${_v} > /dev/null 2>&1 \ + || . <(sed -n "/^${_v}=/ p" ${BUILDDIR}/.config) + + case "${!_v}" in + "") declare "$_v=n" ; export $_v ; return 1 ;; + *) export $_v ; return 0 ;; + esac +} + +do_prepare_build () { + mkdir "${BUILDDIR}" + + restore_config "${BUILDDIR}/.config" + if [ ! -e "${BUILDDIR}/.config" ] ; then + ewarn "Generate .config using 'defconfig'" + emake defconfig "${myopt[@]}" + fi + + mkdir "${WORKDIR}/boot" + + if configval CMDLINE_BOOL && configval CMDLINE ; then + einfo "Creating kernel.arg" + einfo " CONFIG_CMDLINE='${CONFIG_CMDLINE}'" + echo "${CONFIG_CMDLINE}" > "${WORKDIR}/boot/kernel.arg" + fi + + configval MODULES || ewarn "CONFIG_MODULES is not set" + configval UEVENT_HELPER_PATH \ + && ewarn "CONFIG_UEVENT_HELPER_PATH should be empty" +} + +src_prepare () { + bopt=( + -C "${BUILDDIR}" + -f "${SRCDIR}/Makefile" + KBUILD_SRC="${SRCDIR}" + KCONFIG_CONFIG="${BUILDDIR}/.config" + + KBUILD_BUILD_USER="${KBUILD_BUILD_USER:-$PORTAGE_USERNAME}" + ) + + copt=( + CC="$(tc-getCC)" HOSTCC="${CBUILD}-gcc" CROSS_COMPILE="${CHOST}-" + ARCH="$(tc-arch-kernel)" SUBARCH="$(tc-arch-kernel)" + ) + + vopt=( + EXTRAVERSION="${KV_EXTRA}" + LOCALVERSION= CONFIG_LOCALVERSION= + ) + + myopt=( "${bopt[@]}" "${copt[@]}" "${vopt[@]}" ) + + use build && do_prepare_build +} + +do_compile_build () { + einfo "Checking configuration file" + emake oldconfig "${myopt[@]}" < /dev/null + + if diff -Nu0 "${BUILDDIR}/.config.old" "${BUILDDIR}/.config" \ + | egrep -q '^(\-|\+)CONFIG_' ; then + eerror "You configuration is not up to date" + diff -Nu "${BUILDDIR}/.config.old" "${BUILDDIR}/.config" + die "Bad configuration" + fi + + einfo "Building kernel" + emake bzImage "${myopt[@]}" + + if configval MODULES ; then + einfo "Building modules" + emake modules "${myopt[@]}" + fi +} + +src_compile () { + use build && do_compile_build +} + +do_install_sources () { + kernel-2_src_install +} + +do_install_build () { + einfo "Installing kernel" + emake install "${myopt[@]}" \ + INSTALL_PATH="${WORKDIR}/boot" + + insinto "/boot/${KV_FULL}" + + newins "${WORKDIR}/boot/config-${KV_FULL}" kernel.cfg + newins "${WORKDIR}/boot/vmlinuz-${KV_FULL}" kernel.img + newins "${WORKDIR}/boot/System.map-${KV_FULL}" System.map + + if configval CMDLINE_BOOL && configval CMDLINE ; then + doins "${WORKDIR}/boot/kernel.arg" + fi + + if configval MODULES ; then + einfo "Installing modules" + emake modules_install "${myopt[@]}" \ + INSTALL_MOD_PATH="${WORKDIR}" \ + INSTALL_MOD_STRIP="${PORTAGE_STRIP_FLAGS}" + + # kmod only support zlib and lzma + # See libkmod/libkmod-util.c / struct kmod_ext kmod_exts + if use zlib || use lzma ; then + use zlib && { local cmp="gzip -9c" ; local ext="gz" ; } + use lzma && { local cmp="xz -9c" ; local ext="xz" ; } + + einfo "Compressing modules" + find "${WORKDIR}/lib/modules" \ + -type f -name "*.ko" \ + | while read ; do + ${cmp} < "${REPLY}" > "${REPLY}.${ext}" \ + || die "${cmp} ${REPLY} failed" + rm "${REPLY}" + done + fi + + einfo "Generating modules.dep" + depmod -ae -F "${BUILDDIR}/System.map" -b "${WORKDIR}" "${KV_FULL}" \ + || die "depmod failed" + + rm "${WORKDIR}/lib/modules/${KV_FULL}/build" + rm "${WORKDIR}/lib/modules/${KV_FULL}/source" + + insinto /lib + doins -r "${WORKDIR}/lib/modules" + + # No need to make firmware_install, make modules_install does + if [ -e "${WORKDIR}/lib/firmware" ] ; then + einfo "Installing firmwares" + + insinto /lib + doins -r "${WORKDIR}/lib/firmware" + fi + fi +} + +src_install () { + use build && do_install_build + use source && do_install_sources + use savedconfig && save_config "${BUILDDIR}/.config" +} + +pkg_postinst () { + kernel-2_pkg_postinst + + einfo "You may need to:" + einfo " make menuconfig ${copt[@]}" +} -- cgit v1.2.3