Permalink
Browse files

Merge branch 'master' of git.funtoo.org:funtoo-overlay

  • Loading branch information...
2 parents d8af898 + e2d6712 commit b28e361248d90fd680afa2ed1f3b298d8b82ff72 Ryan Harris committed Jul 1, 2013
View
5 profiles/package.mask/funtoo-staging
@@ -1,6 +1,11 @@
# Keep the most recent masks in a reverse chrono order
# newest on top
+# Oleg Vinichenko (1 Jul 2013)
+# FL-564
+# adding newer stable openvz kernel, masked for testing
+=sys-kernel/openvz-rhel6-stable-2.6.32.042.078.26
+
# Oleg Vinichenko (27 Jun 2013)
# vzctl update, masked, require newer ploop and openvz kernel FL-564
=sys-cluster/vzctl-4.3.1
View
1 profiles/profiles.eselect.desc
@@ -27,6 +27,7 @@ flavor funtoo/1.0/linux-gnu/flavor/minimal stable
flavor funtoo/1.0/linux-gnu/flavor/core stable
flavor funtoo/1.0/linux-gnu/flavor/desktop stable
flavor funtoo/1.0/linux-gnu/flavor/workstation stable
+flavor funtoo/1.0/linux-gnu/flavor/hardened exp
mix-ins funtoo/1.0/linux-gnu/mix-ins/audio stable
mix-ins funtoo/1.0/linux-gnu/mix-ins/console-extras stable
View
3 sys-kernel/openvz-rhel6-stable/Manifest
@@ -18,6 +18,8 @@ DIST config-2.6.32-042stab072.10.i686 107096 SHA256 4e685c2e68fa57a49224b3dcffc4
DIST config-2.6.32-042stab072.10.x86_64 102421 SHA256 a44106b0f1d74761f5cc2d698b94d123dda0c2c362d0b76463264c994174de84 SHA512 093426073d02b6910988b863c3d1812014363770a42650bacfdbba7bff009a8b477e309fcf4ddb53180bf54e872f2c5d2401e03aa4b56de610a2ff2e21219994 WHIRLPOOL eed68f29736de3c86b310e74eba4c0194db3e105c1d2379db35c617580c8da7994a3d818571eee66e04b8d044cd2aa25598e5d3a50722e7ad72c3b6c63bc8fe8
DIST config-2.6.32-042stab075.2.i686 107095 SHA256 440c991681a6b4652c90bd3ad64f86df2df112933b65469a447d82cc81a03ea3 SHA512 51d6831f6d95cfc105a3faff1b1f004124b4287b83e5201999c35b870e27d1eaddf6fc89b9744eb17fa059128860d5992574462fd1108b15a9d1853525987f1e WHIRLPOOL 07aec484a0e9d4b7b19bcb42a1de3b72f5a9cb332480bfd877f379da7a71fbe9de4ebef0163efd9e6d5053dcef3cc539816a05d33ce591fa289a160985bb7e3a
DIST config-2.6.32-042stab075.2.x86_64 102444 SHA256 97268f1f38f5bd317c1465e07b8c00cd19daa59705f186b377eb17d9ab9ac34e SHA512 3c2a04e8246282881194ad4f15fe95b8858f0eb73423dfa085f48e112e952e3c06ad3c6fb20016af17ff04313b9dd97152bb4aa564414590feaead33a25b5652 WHIRLPOOL fefb7cdd8e9d1c2095e1f011322760b4e6e14bbc3ec927f94bbb102b9f210e1817f68ea20ec29073064beda5c72aae9d7f6328e0ffbc2638455fd3cf75433557
+DIST config-2.6.32-042stab078.26.i686 109170 SHA256 0cfca56e828cd8ab0520d79fc5fb75c3a9517155075a5bcf0048a5423b5acbbe SHA512 4068b8a0ea061eb88186e1768fb1bf960ffdc5666c1180bc37e1dc50d168364ddb5f54a6bb79e98d1844e528643e2b2ae2fb83a202e432ee34439eabeaad2fbf WHIRLPOOL 624dd5e8d3140cb51a8bcf99e71cbac0d92fa414dc3a9117e243cce9e6066146b376a1508c1f78203a7e462d9536c435c9d878db19698ced73cf4bfa61e1aaac
+DIST config-2.6.32-042stab078.26.x86_64 104536 SHA256 8309c1bb500353ed56b727a39660921ffa5a5d6e081752b765c972a641daf4ff SHA512 2b27ef7540a21ec8d017c718140de7400125440ae7ca8276ad05a6d95c34690188be5e80f7b90fbfa21a0c17cf180ec0bb80b6ead8daee348f7a7ecb154f19fc WHIRLPOOL 90d3cce2e7d8f9553e227ca87a75852fb90ba8a857a15cd2c45042d33849404970214dd2f34d17eb153c269bf1e7608f704f2e1d189244b1ad36367ae4094f32
DIST linux-2.6.32.tar.bz2 64424138 SHA256 5099786d80b8407d98a619df00209c2353517f22d804fdd9533b362adcb4504e SHA512 739c67875dcb1a80412a034e7d3dddfb6aea4d7a77f12b572fb5afbb827e6ab5a682df7501c0982966e85948ddf7251b8dc5eeb064b2d264025160d8a903bc82 WHIRLPOOL 762dfd7f4c062fdcda00b7fc45ead0f8cb4e321027769a12d92640012f5768c2033da95f24491adfcd6eb453c2658978d4f170e73e4f8a5ccd263efcbe00429d
DIST patch-042stab039.10-combined.gz 15807030 SHA256 be0b5239baac4b371012d23b295414729fb3d8f68fa1765308c1e3f6f67651a5
DIST patch-042stab044.11-combined.gz 15840950 SHA256 43f3c1a83631b867d04141b00edb05a720eb1d23ce732f4b2feaf37a84ede40f
@@ -29,3 +31,4 @@ DIST patch-042stab055.12-combined.gz 24627778 SHA256 d40f6d89d4c8b6eb3b15203b452
DIST patch-042stab059.7-combined.gz 35337546 SHA256 46de5953c17bf62337eb42ee7520e39c4a1d9b99b9775c86c8fd13d1d6077e05 SHA512 9255a651b9c32d835f5942549916d752e8bd9b530894eaf7f047fd0709dd38897778cafeebd69d45bd03b86f753c3fb667f3f7656999dec368f634b6faac2608 WHIRLPOOL eb2eaa2d58b7ec31c87904c934155c1cff8c52d373d009a7276fe706ac0aacd5f66cc20e65b5d658a962781c8dc03d9ca91c20d618dd3f8036bb9c060375d64d
DIST patch-042stab072.10-combined.gz 35494090 SHA256 aa3bad74c37dd69f3b55f45e4017838cfb4f3bfd3488a9e25fe1ab5caac7be9f SHA512 f9facd3b655443d79f9417558d5befe255a51cf33f3e224dbd7c90c0c97ccb7c66638bf1def47bdfc27f261db5c0f92a3677f6e0bf381f95ac9d35bcfcf5824a WHIRLPOOL 925d048b8fc6f1a6e14c78a880d363b2abebdf63e0cc8a3b4f9c5a841c59377902c18b0e35ae73c8c758f05f0df5e72c625c81012fa49c92b75cc696198bc62a
DIST patch-042stab075.2-combined.gz 35532089 SHA256 01ea0c38f0f3aa8da5380efd5b00f916e89e0024ba38342de6ade2106fd83053 SHA512 85b632d3cbcbeddcb0689631f6920558b895202539f1b58c13e643a8ba2af7ef08c24fde1b48354607e7fbc1db48a9b33924f1d44999f03abc9f51a2929608fa WHIRLPOOL da77aae2273c1d5d76f0562300880fbf243e45ce2eeeb0e85702df766ac234b21b8c29d9fb5da886fc983b28a77acd81666c00ef0a7176a3585fe4bf655dea39
+DIST patch-042stab078.26-combined.gz 41693767 SHA256 6af16facd0b3de3d38ffe3cee5aac4ceb55fe9ebe4fc86c8e186a58289741e44 SHA512 66ff81d4567d7d243f1a854421adc3c17554e2f04673d7492634453d8a1dcc153b92ac0dfae54dda372e8ac64857c3c4ffd3593c20896ec2f293b92374b2ccc0 WHIRLPOOL 4de5bf1c60558727d4875a2201bd7b0996ec43641912fb6901894862b86a7e943cb3bf284006a60ee3a6afc76b83827899be80bd85a27d861c21f94366505d25
View
179 sys-kernel/openvz-rhel6-stable/openvz-rhel6-stable-2.6.32.042.078.26.ebuild
@@ -0,0 +1,179 @@
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=2
+
+inherit mount-boot
+
+SLOT=$PVR
+CKV=2.6.32
+OKV=$CKV
+OVZ_KERNEL="042stab078"
+OVZ_REV="26"
+OVZ_KV=${OVZ_KERNEL}.${OVZ_REV}
+KV_FULL=${PN}-${PVR}
+EXTRAVERSION=-${OVZ_KV}
+KERNEL_ARCHIVE="linux-${CKV}.tar.bz2"
+KERNEL_URI="http://ftp.osuosl.org/pub/funtoo/distfiles/${KERNEL_ARCHIVE}"
+RESTRICT="binchecks strip mirror"
+
+LICENSE="GPL-2"
+KEYWORDS="*"
+IUSE="binary"
+DEPEND="binary? ( >=sys-kernel/genkernel-3.4.40.1 )"
+RDEPEND="binary? ( >=sys-fs/udev-160 )"
+DESCRIPTION="Full Linux kernel sources - RHEL6 kernel with OpenVZ patchset"
+HOMEPAGE="http://www.openvz.org"
+MAINPATCH="patch-${OVZ_KV}-combined.gz"
+SRC_URI="${KERNEL_URI}
+ http://download.openvz.org/kernel/branches/rhel6-${CKV}/${OVZ_KV}/configs/config-${CKV}-${OVZ_KV}.i686
+ http://download.openvz.org/kernel/branches/rhel6-${CKV}/${OVZ_KV}/configs/config-${CKV}-${OVZ_KV}.x86_64
+ http://download.openvz.org/kernel/branches/rhel6-${CKV}/${OVZ_KV}/patches/$MAINPATCH"
+S="$WORKDIR/linux-${CKV}"
+
+K_EXTRAEINFO="
+This OpenVZ kernel uses RHEL6 (Red Hat Enterprise Linux 6) patch set.
+This patch set is maintained by Red Hat for enterprise use, and contains
+further modifications by the OpenVZ development team and the Funtoo
+Linux project.
+
+Red Hat typically only ensures that their kernels build using their
+own official kernel configurations. Significant variations from these
+configurations can result in build failures.
+
+For best results, always start with a .config provided by the OpenVZ
+team from:
+
+http://wiki.openvz.org/Download/kernel/rhel6/${OVZ_KERNEL}.
+
+On amd64 and x86 arches, one of these configurations has automatically been
+enabled in the kernel source tree that was just installed for you.
+
+Slight modifications to the kernel configuration necessary for booting
+are usually fine. If you are using genkernel, the default configuration
+should be sufficient for your needs."
+
+src_unpack() {
+ unpack ${KERNEL_ARCHIVE}
+}
+
+apply() {
+ p=$1; shift
+ case "${p##*.}" in
+ gz)
+ ca="gzip -dc"
+ ;;
+ bz2)
+ ca="bzip2 -dc"
+ ;;
+ xz)
+ ca="xz -dc"
+ ;;
+ *)
+ ca="cat"
+ ;;
+ esac
+ [ ! -e $p ] && die "patch $p not found"
+ echo "Applying patch $p"; $ca $p | patch -s $* || die "patch $p failed"
+}
+
+pkg_setup() {
+ case $ARCH in
+ x86)
+ defconfig_src=i686
+ ;;
+ amd64)
+ defconfig_src=x86_64
+ ;;
+ *)
+ die "unsupported ARCH: $ARCH"
+ ;;
+ esac
+ defconfig_src="${DISTDIR}/config-${CKV}-${OVZ_KV}.${defconfig_src}"
+ unset ARCH; unset LDFLAGS #will interfere with Makefile if set
+}
+
+src_prepare() {
+ apply $DISTDIR/$MAINPATCH -p1
+ apply ${FILESDIR}/rhel5-openvz-sources-2.6.18.028.064.7-bridgemac.patch -p1
+ # disable video4linux version 1 - deprecated as of linux-headers-2.6.38:
+ # http://forums.gentoo.org/viewtopic-t-872167.html?sid=60f2e6e08cf1f2e99b3e61772a1dc276
+ sed -i -e "s:video4linux/::g" Documentation/Makefile || die
+ sed -i -e "s:^\(EXTRAVERSION =\).*:\1 ${EXTRAVERSION}:" Makefile || die
+ sed -i -e 's:#export\tINSTALL_PATH:export\tINSTALL_PATH:' Makefile || die
+ cp $DISTDIR/config-${CKV}-${OVZ_KV}.i686 arch/x86/configs/i386_defconfig || die
+ cp $DISTDIR/config-${CKV}-${OVZ_KV}.x86_64 arch/x86/configs/x86_64_defconfig || die
+ rm -f .config >/dev/null
+ make -s mrproper || die "make mrproper failed"
+ make -s include/linux/version.h || die "make include/linux/version.h failed"
+}
+
+src_compile() {
+ ! use binary && return
+ install -d ${WORKDIR}/out/{lib,boot}
+ install -d ${T}/{cache,twork}
+ install -d $WORKDIR/build $WORKDIR/out/lib/firmware
+ DEFAULT_KERNEL_SOURCE="${S}" INSTALL_FW_PATH=${WORKDIR}/out/lib/firmware CMD_KERNEL_DIR="${S}" genkernel ${GKARGS} \
+ --no-save-config \
+ --kernel-config="$defconfig_src" \
+ --kernname="${PN}" \
+ --build-src="$S" \
+ --build-dst=${WORKDIR}/build \
+ --makeopts="${MAKEOPTS}" \
+ --firmware-dst=${WORKDIR}/out/lib/firmware \
+ --cachedir="${T}/cache" \
+ --tempdir="${T}/twork" \
+ --logfile="${WORKDIR}/genkernel.log" \
+ --bootdir="${WORKDIR}/out/boot" \
+ --lvm \
+ --luks \
+ --mdadm \
+ --iscsi \
+ --module-prefix="${WORKDIR}/out" \
+ all || die "genkernel failed"
+}
+
+src_install() {
+ # copy sources into place:
+ dodir /usr/src
+ cp -a ${S} ${D}/usr/src/linux-${P} || die
+ cd ${D}/usr/src/linux-${P}
+ # prepare for real-world use and 3rd-party module building:
+ make mrproper || die
+ cp $defconfig_src .config || die
+ yes "" | make oldconfig || die
+ # if we didn't use genkernel, we're done. The kernel source tree is left in
+ # an unconfigured state - you can't compile 3rd-party modules against it yet.
+ use binary || return
+ make prepare || die
+ make scripts || die
+ # OK, now the source tree is configured to allow 3rd-party modules to be
+ # built against it, since we want that to work since we have a binary kernel
+ # built.
+ cp -a ${WORKDIR}/out/* ${D}/ || die "couldn't copy output files into place"
+ # module symlink fixup:
+ rm -f ${D}/lib/modules/*/source || die
+ rm -f ${D}/lib/modules/*/build || die
+ cd ${D}/lib/modules
+ # module strip:
+ find -iname *.ko -exec strip --strip-debug {} \;
+ # back to the symlink fixup:
+ local moddir="$(ls -d 2*)"
+ ln -s /usr/src/linux-${P} ${D}/lib/modules/${moddir}/source || die
+ ln -s /usr/src/linux-${P} ${D}/lib/modules/${moddir}/build || die
+
+ # Fixes FL-14
+ cp "${WORKDIR}/build/System.map" "${D}/usr/src/linux-${P}/" || die
+ cp "${WORKDIR}/build/Module.symvers" "${D}/usr/src/linux-${P}/" || die
+}
+
+pkg_postinst() {
+ # if K_EXTRAEINFO is set then lets display it now
+ if [[ -n ${K_EXTRAEINFO} ]]; then
+ echo ${K_EXTRAEINFO} | fmt |
+ while read -s ELINE; do einfo "${ELINE}"; done
+ fi
+ if [ ! -e ${ROOT}usr/src/linux ]
+ then
+ ln -s linux-${P} ${ROOT}usr/src/linux
+ fi
+}

0 comments on commit b28e361

Please sign in to comment.