Version bump. Fixes to eliminate stackprotector from the kernel. init script updated...
authorDaniel Black <dragonheart@gentoo.org>
Fri, 7 Jan 2005 08:55:43 +0000 (08:55 +0000)
committerDaniel Black <dragonheart@gentoo.org>
Fri, 7 Jan 2005 08:55:43 +0000 (08:55 +0000)
app-crypt/bestcrypt/ChangeLog
app-crypt/bestcrypt/Manifest
app-crypt/bestcrypt/bestcrypt-1.5_p10.ebuild [new file with mode: 0644]
app-crypt/bestcrypt/bestcrypt-1.5_p9-r1.ebuild
app-crypt/bestcrypt/files/bcrypt3
app-crypt/bestcrypt/files/bestcrypt-1.5_p10-makefile_fix.patch [new file with mode: 0644]
app-crypt/bestcrypt/files/bestcrypt.devfs [new file with mode: 0644]
app-crypt/bestcrypt/files/digest-bestcrypt-1.5_p10 [new file with mode: 0644]

index ee0589811e36a1b990db20947a2da2f09317eafe..107adc2573bf49d84e654c53b6ee440ac7d0ff83 100644 (file)
@@ -1,6 +1,16 @@
 # ChangeLog for app-crypt/bestcrypt
 # Copyright 2002-2005 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/app-crypt/bestcrypt/ChangeLog,v 1.25 2005/01/04 06:07:29 dragonheart Exp $
+# $Header: /var/cvsroot/gentoo-x86/app-crypt/bestcrypt/ChangeLog,v 1.26 2005/01/07 08:55:43 dragonheart Exp $
+
+*bestcrypt-1.5_p10 (07 Jan 2005)
+
+  07 Jan 2005; Daniel Black <dragonheart@gentoo.org> files/bcrypt3,
+  +files/bestcrypt-1.5_p10-makefile_fix.patch, +files/bestcrypt.devfs,
+  +bestcrypt-1.5_p10.ebuild, bestcrypt-1.5_p9-r1.ebuild:
+  Version bump. Fixes to eliminate stackprotector from the kernel. init script
+  updated to not create modules on udev. Small devfs conf added. Stop
+  bestcrypt-1.5_p9-r1 from installing on 2.6.10 kernels that breaks. CFLAGS and
+  CXXFLAGS used by ebuild now.
 
 *bestcrypt-1.5_p9-r1 (04 Jan 2005)
 
index cee66e182fa04fec6a86db24cf23d3f7521eeeac..2173dc66143be10b55fd255a84e6d2540aaa3810 100644 (file)
@@ -1,15 +1,19 @@
 -----BEGIN PGP SIGNED MESSAGE-----
 Hash: SHA1
 
-MD5 b176ea85a31a981d0c741e9d50bf52d5 ChangeLog 4564
-MD5 3dbfc3e0c2b260e8b4b02f4cbc0ba58b bestcrypt-1.5_p9-r1.ebuild 2701
+MD5 5766f79b78b27fc656da9f0d16a1fa24 ChangeLog 5055
+MD5 0724faab72187ff84973336a5f7bf9fd bestcrypt-1.5_p9-r1.ebuild 2806
+MD5 2119a22c49876db50ac4996f89e7f847 bestcrypt-1.5_p10.ebuild 2871
 MD5 566cf4f89e44670d0aba4a745913d748 metadata.xml 224
 MD5 4b7a544fe93e1ed5f17e891d12bc880b bestcrypt-1.5_p7.ebuild 1498
 MD5 16da5a478d0f51c9156285ad82cc9612 bestcrypt-1.5_p7-r1.ebuild 1763
 MD5 c5fbab81816aa1d6f319f8434d2db2b2 files/bcrypt 3113
 MD5 5b4b4d2cf3a069dcc49e6803af149665 files/bcrypt2 3097
-MD5 0627a90c642911ade3f933e5b6ecd6c0 files/bcrypt3 3159
+MD5 063ae0f67213da39ed4dd75a594b3b07 files/bcrypt3 3246
 MD5 ca9e4e3d8a5d0f6e54e5b83d2fe21c58 files/digest-bestcrypt-1.5_p9-r1 136
+MD5 c9fdd7c76eb3731a6166cc9ff17bf722 files/digest-bestcrypt-1.5_p10 137
+MD5 e9585e8f08138f46bdda7b88ddd81cd8 files/bestcrypt-1.5_p10-makefile_fix.patch 1136
+MD5 dd6203d4ed27c1388b70b6b8207dfa54 files/bestcrypt.devfs 397
 MD5 ae0a806bcd924019822cdbfdc0dbcfec files/bestcrypt-1.5_p7-makefile_fix.patch 2519
 MD5 362ade933d7aab0a81b18a9e08d1e24f files/digest-bestcrypt-1.5_p7 67
 MD5 4b5ee352a3df35a5803d9013b763afec files/digest-bestcrypt-1.5_p7-r1 136
@@ -17,7 +21,7 @@ MD5 e9585e8f08138f46bdda7b88ddd81cd8 files/bestcrypt-1.5_p9-makefile_fix.patch 1
 -----BEGIN PGP SIGNATURE-----
 Version: GnuPG v1.4.0 (GNU/Linux)
 
-iD8DBQFB2jKnmdTrptrqvGERAgNSAKCGi2u9kW16rQU+x9Kx8Upb6evBMQCfZSt1
-zziwWZsPMeIIH5gYbrAA7ac=
-=tIjI
+iD8DBQFB3k6WmdTrptrqvGERAuOjAJ9aIfnrjaV5bPJ1wFuZbxjGhYO66QCgk3Of
+UyxAoirU+1zu6nVsPhyHxrQ=
+=belM
 -----END PGP SIGNATURE-----
diff --git a/app-crypt/bestcrypt/bestcrypt-1.5_p10.ebuild b/app-crypt/bestcrypt/bestcrypt-1.5_p10.ebuild
new file mode 100644 (file)
index 0000000..e3bdaa0
--- /dev/null
@@ -0,0 +1,100 @@
+# Copyright 1999-2005 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/app-crypt/bestcrypt/bestcrypt-1.5_p10.ebuild,v 1.1 2005/01/07 08:55:43 dragonheart Exp $
+
+inherit flag-o-matic eutils linux-mod toolchain-funcs
+
+MY_PN="bcrypt"
+DESCRIPTION="commercially licensed transparent filesystem encryption"
+HOMEPAGE="http://www.jetico.com/"
+SRC_URI="http://www.jetico.com/linux/BestCrypt-${PV/_p/-}.tar.gz
+       http://www.carceri.dk/files/bcrypt-rc6-serpent.diff.gz"
+
+LICENSE="bestcrypt"
+SLOT="0"
+IUSE=""
+KEYWORDS="~x86 ~amd64"
+
+DEPEND="virtual/linux-sources"
+
+S=${WORKDIR}/bcrypt
+
+#get-version
+MODULE_NAMES="bc(block:${S}/mod)
+               bc_des(block:${S}/mod/des)
+               bc_3des(block:${S}/mod/3des)
+               bc_bf128(block:${S}/mod/bf128)
+               bc_bf448(block:${S}/mod/bf448)
+               bc_blowfish(block:${S}/mod/blowfish)
+               bc_cast(block:${S}/mod/cast)
+               bc_gost(block:${S}/mod/gost)
+               bc_idea(block:${S}/mod/idea)
+               bc_rijn(block:${S}/mod/rijn)
+               bc_serpent(block:${S}/mod/serpent)
+               bc_rc6(block:${S}/mod/rc6)
+               bc_twofish(block:${S}/mod/twofish)"
+
+src_unpack() {
+       unpack BestCrypt-${PV/_p/-}.tar.gz
+       cd ${S}
+
+       epatch ${DISTDIR}/bcrypt-rc6-serpent.diff.gz
+       epatch ${FILESDIR}/${P}-makefile_fix.patch
+}
+
+src_compile() {
+
+       filter-flags -fforce-addr
+
+       emake -C kgsha EXTRA_CXXFLAGS="${CXXFLAGS}" || die "library compile failed"
+       emake -C src EXTRA_CFLAGS="${CFLAGS}" || die "bctool compile failed"
+
+       # Don't put stack protection in the kernel - it just is bad
+       append-flags -fno-stack-protector-all -fno-stack-protector
+
+       emake  -C mod SYMSRC=bc_dev${KV_MAJOR}${KV_MINOR}.c bc_dev.ver EXTRA_CFLAGS="${CFLAGS}" \
+               || die "compile failed"
+
+       emake  -C mod OBJS="bc_dev${KV_MAJOR}${KV_MINOR}.o bc_mgr.o" \
+               KERNEL_DIR=${KV_DIR} KEXT=${KV_OBJ} CC=$(tc-getCC) LD=$(tc-getLD) \
+               AS=$(tc-getAS) CPP=$(tc-getCXX) EXTRA_CFLAGS="${CFLAGS}" || die "compile failed"
+       einfo "Modules compiled"
+}
+
+src_install() {
+       linux-mod_src_install
+
+       cd ${S}
+       dodir /etc
+       cp etc/bc.conf ${D}/etc/bc.conf
+
+       dobin bin/bctool
+       insinto /usr/bin
+       for link in bcumount bcformat bcfsck bcnew bcpasswd bcinfo \
+               bclink bcunlink bcmake_hidden bcreencrypt;
+       do
+               dosym bctool /usr/bin/${link}
+       done
+
+
+       doman man/bctool.8
+       newinitd ${FILESDIR}/bcrypt3 bcrypt
+       dodoc README LICENSE HIDDEN_PART
+
+       insinto /etc/devfs.d
+       doins files/bestcrypt.devfs
+}
+
+
+pkg_postinst() {
+
+       einfo "If you are using the serpent or rc6 encryption modules and have any problems,"
+       einfo "please submit bugs to http://bugs.gentoo.org because these modules are not part"
+       einfo "of the standard distribution of BestCrypt for Linux released by Jetico."
+       einfo "For more information on these additional modules:"
+       einfo "visit http://www.carceri.dk/index.php?redirect=other_bestcrypt"
+
+       einfo
+       ewarn "The BestCrypt drivers are not free - Please purchace a license from "
+       ewarn "http://www.jetico.com/"
+}
index a13be646a28d562a31aa36786008da7aad051348..17741953be965e96f162b92ed43a83252fb56e14 100644 (file)
@@ -1,6 +1,6 @@
 # Copyright 1999-2005 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/app-crypt/bestcrypt/bestcrypt-1.5_p9-r1.ebuild,v 1.1 2005/01/04 06:07:29 dragonheart Exp $
+# $Header: /var/cvsroot/gentoo-x86/app-crypt/bestcrypt/bestcrypt-1.5_p9-r1.ebuild,v 1.2 2005/01/07 08:55:43 dragonheart Exp $
 
 inherit flag-o-matic eutils linux-mod toolchain-funcs
 
@@ -35,6 +35,12 @@ MODULE_NAMES="bc(block:${S}/mod)
                bc_twofish(block:${S}/mod/twofish)"
 
 src_unpack() {
+
+       if kernel_is ge 2.6.10;
+       then
+               die "Don't work with 2.6.10 - blkdev_open nolonger included and bestcrypt needs it"
+       fi
+
        unpack BestCrypt-${PV/_p/-}.tar.gz
        cd ${S}
 
@@ -44,24 +50,21 @@ src_unpack() {
 
 src_compile() {
 
-       echo -e "\nmodule: \$(OBJ)" >> mod/Makefile.alg
-
        filter-flags -fforce-addr
-       #BUILD_PARAMS=-I${S}/include KERNEL_DIR=${KV_DIR} -DKBUILD_MODNAME=bc_$$i" TARGET=bc_
-       #linux-mod_src_compile
 
-       emake  -C mod SYMSRC=bc_dev${KV_MAJOR}${KV_MINOR}.c bc_dev.ver || die "compile failed"
+       emake -C kgsha EXTRA_CXXFLAGS="${CXXFLAGS}" || die "library compile failed"
+       emake -C src EXTRA_CFLAGS="${CFLAGS}" || die "bctool compile failed"
+
+       # Don't put stack protection in the kernel - it just is bad
+       append-flags -fno-stack-protector-all -fno-stack-protector
+
+       emake  -C mod SYMSRC=bc_dev${KV_MAJOR}${KV_MINOR}.c bc_dev.ver EXTRA_CFLAGS="${CFLAGS}" \
+               || die "compile failed"
 
        emake  -C mod OBJS="bc_dev${KV_MAJOR}${KV_MINOR}.o bc_mgr.o" \
                KERNEL_DIR=${KV_DIR} KEXT=${KV_OBJ} CC=$(tc-getCC) LD=$(tc-getLD) \
-               AS=$(tc-getAS) CPP=$(tc-getCXX) || die "compile failed"
+               AS=$(tc-getAS) CPP=$(tc-getCXX) EXTRA_CFLAGS="${CFLAGS}" || die "compile failed"
        einfo "Modules compiled"
-
-
-       emake -C kgsha || die "library compile failed"
-       emake -C src || die "bctool compile failed"
-
-       #emake -j1 KERNEL_TMP= EXTRA_CFLAGS="${CFLAGS}" EXTRA_CXXFLAGS="${CXXFLAGS}" || die
 }
 
 src_install() {
index 50106161a247d0bfcc5485d7894cfeba15545ac1..f2be3464ddc438d1ba954d24ce93b3b0e88639a2 100644 (file)
@@ -4,7 +4,7 @@
 #
 # Version:      1.2
 #
-# Revision:  $Id: bcrypt3,v 1.1 2004/10/31 15:06:06 lostlogic Exp $
+# Revision:  $Id: bcrypt3,v 1.2 2005/01/07 08:55:43 dragonheart Exp $
 #
 # Author:       Jetico Inc. (support@jetico.com)
 #
@@ -45,7 +45,7 @@ start() {
          mknod -m 666 /dev/bcrypt14 b 7 142
          mknod -m 666 /dev/bcrypt15 b 7 143
         else
-         if [ ! -c /dev/.devfsd ]
+         if [ ! -c /dev/.devfsd ] && [ ! -e /dev/.udev ];
          then
             mknod -m 666 /dev/bcrypt0 b 188 0
             mknod -m 666 /dev/bcrypt1 b 188 1
@@ -95,7 +95,10 @@ stop() {
        for i in `lsmod |egrep "^bc_.*" |awk '{print $1}' `; do 
                rmmod $i
        done
-       rm -f /dev/bcrypt?* 2>/dev/null
+       if [ ! -c /dev/.devfsd ] && [ ! -e /dev/.udev ];
+       then
+               rm -f /dev/bcrypt?* 2>/dev/null
+       fi
        rmmod bc
        eend $?
 }
diff --git a/app-crypt/bestcrypt/files/bestcrypt-1.5_p10-makefile_fix.patch b/app-crypt/bestcrypt/files/bestcrypt-1.5_p10-makefile_fix.patch
new file mode 100644 (file)
index 0000000..6f1e4f3
--- /dev/null
@@ -0,0 +1,38 @@
+--- mod/Makefile.org   2004-07-07 20:49:59.000000000 +0200
++++ mod/Makefile       2004-07-07 20:53:58.000000000 +0200
+@@ -95,14 +96,6 @@
+ 
+ CFLAGS += -I$(CUR_DIR)/../include/ -I$(KERNEL_DIR)/include/
+ 
+-ifeq ($(ARCH), alpha)
+-CFLAGS += -O2 -pipe -fno-strict-aliasing -fno-common -mno-fp-regs -ffixed-8 -mcpu=ev5
+-else
+-ifeq ($(ARCH), x86_64)
+-CFLAGS += -O2 -fno-strength-reduce -fno-strict-aliasing -mcmodel=kernel
+-else
+-CFLAGS += -O6 -fno-strength-reduce -fno-strict-aliasing 
+-endif
+-endif
++CFLAGS += $(EXTRA_CFLAGS)
+ 
+ LDFLAGS = -d -r
+--- src/Makefile.org   2004-07-07 20:54:07.000000000 +0200
++++ src/Makefile       2004-07-07 20:54:24.000000000 +0200
+@@ -24,6 +24,7 @@
+ CFLAGS += -L../lib -I../include/ 
+ CFLAGS += -Wall -O2 -fno-strict-aliasing
+ #CFLAGS += -g -static -O6
++CFLAGS += $(EXTRA_CFLAGS)
+ LDFLAGS =
+ 
+ TARGETS = bctool
+--- kgsha/Makefile.org 2004-07-07 20:54:34.000000000 +0200
++++ kgsha/Makefile     2004-07-07 20:54:50.000000000 +0200
+@@ -20,6 +20,7 @@
+ 
+ CPP=g++
+ CPPFLAGS = -Wall -Werror -fno-strength-reduce -I../include -g 
++CPPFLAGS += $(EXTRA_CXXFLAGS)
+ 
+ TARGET = libkgsha.a
+ HEADERS = kg_defs.h kgsha.h kblock.h sha1.h random.h
diff --git a/app-crypt/bestcrypt/files/bestcrypt.devfs b/app-crypt/bestcrypt/files/bestcrypt.devfs
new file mode 100644 (file)
index 0000000..1d82c54
--- /dev/null
@@ -0,0 +1,8 @@
+# Under development. bctool needs /dev/bcrypt[0-9] and /dev/bcrypt/disc0/disc entries (same)
+# look at man devfsd devfsd.conf, and /usr/share/doc/devfsd*/devfsd.conf and submit an
+# answer to bugs.gentoo.org
+#
+# Of course the simplier solution is to migrate to udev.
+# http://www.gentoo.org/doc/en/udev-guide.xml
+#
+#LOOKUP ^bcrypt0$ CFUNCTION GLOBAL mksymlink ${mntpnt}/bcrypt/disc0/disc $devpath
diff --git a/app-crypt/bestcrypt/files/digest-bestcrypt-1.5_p10 b/app-crypt/bestcrypt/files/digest-bestcrypt-1.5_p10
new file mode 100644 (file)
index 0000000..d369aa8
--- /dev/null
@@ -0,0 +1,2 @@
+MD5 77ddc2bb846edded4921fa4adbf8320f BestCrypt-1.5-10.tar.gz 169899
+MD5 aa6e1f0e9ee797b409267bdba1f6534e bcrypt-rc6-serpent.diff.gz 5718