diff options
author | Thomas Sachau <tommy@gentoo.org> | 2007-11-26 00:29:40 +0000 |
---|---|---|
committer | Thomas Sachau <tommy@gentoo.org> | 2007-11-26 00:29:40 +0000 |
commit | cf6eef80138cd6b2686f79fe9ed686bb5854aac7 (patch) | |
tree | 8654254c104f41db63acfe9d5614f156029a7774 /sys-fs | |
parent | sys-fs/aufs: Version bump to work with kernel-2.6.22 (svn-tarball, report and... (diff) | |
download | sunrise-cf6eef80138cd6b2686f79fe9ed686bb5854aac7.tar.gz sunrise-cf6eef80138cd6b2686f79fe9ed686bb5854aac7.tar.bz2 sunrise-cf6eef80138cd6b2686f79fe9ed686bb5854aac7.zip |
sys-fs/aufs: Keep old version as the patches do not apply to the new version + drop old patches
svn path=/sunrise/; revision=5121
Diffstat (limited to 'sys-fs')
-rw-r--r-- | sys-fs/aufs/ChangeLog | 6 | ||||
-rw-r--r-- | sys-fs/aufs/Manifest | 6 | ||||
-rw-r--r-- | sys-fs/aufs/aufs-20070402.ebuild | 150 | ||||
-rw-r--r-- | sys-fs/aufs/files/aufs-20070212-ksize.patch | 7 | ||||
-rw-r--r-- | sys-fs/aufs/files/aufs-20070212-lhash.patch | 41 |
5 files changed, 159 insertions, 51 deletions
diff --git a/sys-fs/aufs/ChangeLog b/sys-fs/aufs/ChangeLog index c2f368148..704f36dc5 100644 --- a/sys-fs/aufs/ChangeLog +++ b/sys-fs/aufs/ChangeLog @@ -2,6 +2,12 @@ # Copyright 1999-2007 Gentoo Foundation; Distributed under the GPL v2 # $Header: $ + 26 Nov 2007; (Tommy[D]) tommy100@gmx.de -files/aufs-20070212-ksize.patch, + -files/aufs-20070212-lhash.patch, -files/aufs-20070402-ksize.patch, + -files/aufs-20070402-lhash.patch, +aufs-20070402.ebuild: + Keep old version as the patches do not apply to the new version + drop old + patches + 26 Nov 2007; (Tommy[D]) tommy100@gmx.de ++, -aufs-20070402.ebuild: Version bump to work with kernel-2.6.22 (svn-tarball, report and request from mcfletch in #gentoo-sunrise) diff --git a/sys-fs/aufs/Manifest b/sys-fs/aufs/Manifest index 5a6fc586c..ac835dbb1 100644 --- a/sys-fs/aufs/Manifest +++ b/sys-fs/aufs/Manifest @@ -1,8 +1,8 @@ -AUX aufs-20070212-ksize.patch 215 RMD160 aface602421301ed1e226194e9f8457f4a9dffd5 SHA1 d39db4cb4472b3dce1072d96c4f3198939b26bbe SHA256 0b50c428e0a23d825320c4b7960e3e8ead11fdb274ab92e927e0a86663f0a7a2 -AUX aufs-20070212-lhash.patch 1707 RMD160 17589fed81c0602db71e8937279200658e3bbc66 SHA1 f9e3d5eb25df9bf0ace036deaf0c1c75be9f514a SHA256 6a963eb4e5fa08357b6ff3d6c02ed0a04c7b5abffdb1c9d9f0435ed988821965 AUX aufs-20070402-ksize.patch 215 RMD160 aface602421301ed1e226194e9f8457f4a9dffd5 SHA1 d39db4cb4472b3dce1072d96c4f3198939b26bbe SHA256 0b50c428e0a23d825320c4b7960e3e8ead11fdb274ab92e927e0a86663f0a7a2 AUX aufs-20070402-lhash.patch 1707 RMD160 17589fed81c0602db71e8937279200658e3bbc66 SHA1 f9e3d5eb25df9bf0ace036deaf0c1c75be9f514a SHA256 6a963eb4e5fa08357b6ff3d6c02ed0a04c7b5abffdb1c9d9f0435ed988821965 +DIST aufs-20070402.tar.bz2 120097 RMD160 13f3a1cc7a581b1b96255262af01d90c3f601a22 SHA1 496b01279214d0a5836498ea233176e3424a3280 SHA256 c11e7c5835196873a60ac3ccae147ba4941239a0bee23beec8747bc95997eb62 DIST aufs-20071125.tar.bz2 174584 RMD160 bac7b997a13979d1ada38654bdafe2084335c3aa SHA1 749d51a15703fc60bb913b435eec850eb060bc30 SHA256 f3422fd5861d1f6027f2cffaa36707b3bb22ec7c3484f10e833e51a5e11a56ce +EBUILD aufs-20070402.ebuild 4164 RMD160 363ba107e92d07a02bf76a412c64d5846231c1bb SHA1 923e37e45f6f9182bb615d96d42734b0f496e5b5 SHA256 0c9869ef548e954824d80ec1c790c3c0448d2b7df2cc507ac02fe19898f8fac1 EBUILD aufs-20071125.ebuild 4161 RMD160 16baddabd05ff60fd06919aeb41e63231b00e879 SHA1 7b32cd87e6313ecbbc12059ab9d454f5d46b252f SHA256 1bd27dd15c2b636c86c1b34708e64b46b7d4487fe3975f7af41f1ab053f38220 -MISC ChangeLog 1559 RMD160 6518ba55e9e6d5bdb2bc356560663a1c57f337b3 SHA1 102f6330420b4ecf68be06f6afd5f9febe92261e SHA256 29e5dc5d38040d5172c6408e0be35aedb872b732c97e7b96db5314c3f6ceb7a4 +MISC ChangeLog 1852 RMD160 5a50e846a99c2895154973f261212215e2aef1d3 SHA1 7da657c14969455547eb8e86cc1de094f656d23f SHA256 71663599aa9814cc1925656c322254efa5fb20bf4fe2b599fa9ba31f38e1e398 MISC metadata.xml 170 RMD160 645927a396fdc21cdeb089fe42c5397332420ea6 SHA1 ac7f48a14fec325926f9ce1be8fbf1f311b4f2e4 SHA256 d797a2ec6f9dc516c9f9c1a758ee87ad3e8c43101b5dc76c2f872d5bd4639b42 diff --git a/sys-fs/aufs/aufs-20070402.ebuild b/sys-fs/aufs/aufs-20070402.ebuild new file mode 100644 index 000000000..29de8dccf --- /dev/null +++ b/sys-fs/aufs/aufs-20070402.ebuild @@ -0,0 +1,150 @@ +# Copyright 1999-2007 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: $ + +inherit eutils linux-mod + +DESCRIPTION="An entirely re-designed and re-implemented Unionfs." +HOMEPAGE="http://aufs.sourceforge.net/" +SRC_URI="http://www.fh-kl.de/~torsten.kockler/gentoo/${P}.tar.bz2" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="~amd64 ~x86" +IUSE="hinotify ksize nfs nfsexport" + +MODULE_NAMES="aufs(addon/fs/${PN}:)" +BUILD_PARAMS="KDIR=${KV_DIR} -f local.mk" +BUILD_TARGETS="all" + +check_patch() { + get_version + + # Check if ksize Patch has to be applied + if use ksize ; then + APPLY_KSIZE_PATCH="n" + # If ksize patch is not applied + if ! grep -qs "EXPORT_SYMBOL(ksize);" "${KV_DIR}/mm/slab.c" ; then + APPLY_KSIZE_PATCH="y" + fi + fi + + # Check if lhash Patch has to be applied + if use nfs && kernel_is ge 2 6 19 ; then + APPLY_LHASH_PATCH="n" + # If lhash patch is not applied + if ! grep -qs "EXPORT_SYMBOL(__lookup_hash);" "${KV_DIR}/fs/namei.c" \ + && ! grep -qs "struct dentry * __lookup_hash(struct qstr *name, struct dentry + * base, struct nameidata *nd);" "${KV_DIR}/fs/namei.h" ; then + APPLY_LHASH_PATCH="y" + fi + fi +} + +pkg_setup() { + # kernel version check + if kernel_is lt 2 6 16 ; then + eerror "${PN} is being developed and tested on linux-2.6.16 and later." + eerror "Make sure you have a proper kernel version!" + die "Wrong kernel version" + fi + + check_patch + + # If a patch has to be applied + if [[ ${APPLY_KSIZE_PATCH} == "y" ]] || [[ ${APPLY_LHASH_PATCH} == "y" ]] ; then + ewarn "Patching your kernel..." + cd ${KV_DIR} + fi + + # If the ksize patch has to be applied + if [[ ${APPLY_KSIZE_PATCH} == "y" ]] ; then + epatch "${FILESDIR}"/${P}-ksize.patch + fi + + # If the lhash patch has to be applied + if [[ ${APPLY_LHASH_PATCH} == "y" ]] ; then + epatch "${FILESDIR}"/${P}-lhash.patch + fi + + linux-mod_pkg_setup +} + +src_unpack(){ + unpack ${A} + cd "${S}" + + # Enable ksize Patch in priv_def.mk + if use ksize ; then + echo "CONFIG_AUFS_KSIZE_PATCH = y" >> priv_def.mk || die "setting ksize in priv_def.mk failed!" + fi + + # Enable lhash Patch in priv_def.mk + if use nfs && kernel_is ge 2 6 19 ; then + echo "CONFIG_AUFS_LHASH_PATCH = y" >> priv_def.mk || die "setting lhash in priv_def.mk failed!" + fi + + # Enable hinotify in priv_def.mk + if use hinotify && kernel_is ge 2 6 18 ; then + echo "CONFIG_AUFS_HINOTIFY = y" >> priv_def.mk || die "setting hinotify in priv_def.mk failed!" + fi + + # Enable nfsexport in priv_def.mk + if use nfsexport && kernel_is ge 2 6 18 ; then + echo "CONFIG_AUFS_EXPORT = y" >> priv_def.mk || die "setting nfsexport in priv_def.mk failed!" + fi + + # Disable SYSAUFS for kernel less than 2.6.18 + if kernel_is lt 2 6 18 ; then + echo "CONFIG_AUFS_SYSAUFS = " >> priv_def.mk || die "unsetting sysaufs in priv_def.mk failed!" + fi + + # Check if a vserver-kernel is installed + if [[ -e ${KV_DIR}/include/linux/vserver ]] ; then + einfo "vserver kernel seems to be installed" + einfo "using vserver patch" + echo "AUFS_DEF_CONFIG = -DVSERVER" >> priv_def.mk || die "setting vserver in priv_def.mk failed!" + fi +} + +src_install() { + exeinto /sbin + exeopts -m0500 + doexe mount.aufs umount.aufs auplink aulchown + doman aufs.5 + linux-mod_src_install +} + +pkg_postinst() { + elog "To be able to use aufs, you have to load the kernel module by typing:" + elog "modprobe aufs" + elog "For further information refer to the aufs man page" + + # Tell the user to recompile his kernel + if [[ ${APPLY_KSIZE_PATCH} == "y" ]] || [[ ${APPLY_LHASH_PATCH} == "y" ]] ; then + echo + ewarn "Remember to re-compile your kernel to make the patch(es) work" + ewarn + fi + + linux-mod_pkg_postinst +} + +pkg_prerm() { + built_with_use -o =${CATEGORY}/${PF} ksize nfs && DO_CHECK="y" +} + +pkg_postrm() { + # Tell the user that his kernel has already been patched + if [[ DO_CHECK == "y" ]] ; then + check_patch + if [[ ${APPLY_KSIZE_PATCH} == "n" ]] || [[ ${APPLY_LHASH_PATCH} == "n" ]] ; then + ewarn "Your kernel has been patched previously by this ebuild." + ewarn "You can undo the patches by executing the following:" + echo + ewarn "cd ${KV_DIR}; make mrproper, re-emerge and re-compile your kernel - ${KV_FULL}" + fi + fi + + linux-mod_pkg_postrm +} diff --git a/sys-fs/aufs/files/aufs-20070212-ksize.patch b/sys-fs/aufs/files/aufs-20070212-ksize.patch deleted file mode 100644 index 2b92800d9..000000000 --- a/sys-fs/aufs/files/aufs-20070212-ksize.patch +++ /dev/null @@ -1,7 +0,0 @@ ---- mm/slab.c 9 Apr 2006 01:09:51 -0000 1.1 -+++ mm/slab.c 9 Apr 2006 01:10:33 -0000 1.2 -@@ -3861,3 +3861,4 @@ unsigned int ksize(const void *objp) - - return obj_size(virt_to_cache(objp)); - } -+EXPORT_SYMBOL(ksize); diff --git a/sys-fs/aufs/files/aufs-20070212-lhash.patch b/sys-fs/aufs/files/aufs-20070212-lhash.patch deleted file mode 100644 index ddcd872bf..000000000 --- a/sys-fs/aufs/files/aufs-20070212-lhash.patch +++ /dev/null @@ -1,41 +0,0 @@ -Index: fs/namei.c -=================================================================== -RCS file: linux-2.6.19/fs/namei.c,v -retrieving revision 1.1 -retrieving revision 1.3 -diff -u -p -r1.1 -r1.3 ---- fs/namei.c 1 Dec 2006 11:38:24 -0000 1.1 -+++ fs/namei.c 8 Dec 2006 07:47:33 -0000 1.3 -@@ -1251,7 +1251,7 @@ int __user_path_lookup_open(const char _ - * needs parent already locked. Doesn't follow mounts. - * SMP-safe. - */ --static struct dentry * __lookup_hash(struct qstr *name, struct dentry * base, struct nameidata *nd) -+struct dentry * __lookup_hash(struct qstr *name, struct dentry * base, struct nameidata *nd) - { - struct dentry * dentry; - struct inode *inode; -@@ -2761,6 +2761,7 @@ EXPORT_SYMBOL(follow_up); - EXPORT_SYMBOL(get_write_access); /* binfmt_aout */ - EXPORT_SYMBOL(getname); - EXPORT_SYMBOL(lock_rename); -+EXPORT_SYMBOL(__lookup_hash); - EXPORT_SYMBOL(lookup_one_len); - EXPORT_SYMBOL(page_follow_link_light); - EXPORT_SYMBOL(page_put_link); -Index: include/linux/namei.h -=================================================================== -RCS file: linux-2.6.19/include/linux/namei.h,v -retrieving revision 1.1 -retrieving revision 1.3 -diff -u -p -r1.1 -r1.3 ---- include/linux/namei.h 1 Dec 2006 11:38:24 -0000 1.1 -+++ include/linux/namei.h 8 Dec 2006 07:47:33 -0000 1.3 -@@ -76,6 +76,7 @@ extern struct file *lookup_instantiate_f - extern struct file *nameidata_to_filp(struct nameidata *nd, int flags); - extern void release_open_intent(struct nameidata *); - -+struct dentry * __lookup_hash(struct qstr *name, struct dentry * base, struct nameidata *nd); - extern struct dentry * lookup_one_len(const char *, struct dentry *, int); - - extern int follow_down(struct vfsmount **, struct dentry **); |