Browse Source

Import upstream version 11

Anthony Wright 17 years ago
parent
commit
add8d15323
4 changed files with 18 additions and 13 deletions
  1. 1 0
      Makefile
  2. 13 9
      NEWS
  3. 3 3
      aoe-mkshelf.in
  4. 1 1
      aoe-stat

+ 1 - 0
Makefile

@@ -52,6 +52,7 @@ configure :
 	  sh -xc "sed -e 's!@devdir@!${DEVDIR}!g' -e 's!@npershelf@!${NPERSHELF}!g' $$f.in > $$f" || break; \
 	done
 
+# DESTDIR was put in for Rob Holland to make gentoo packaging easier
 install : all
 	mkdir -p ${SBINDIR}
 	mkdir -p ${MANDIR}/man8

+ 13 - 9
NEWS

@@ -1,43 +1,47 @@
+2006-09-07 Anthony Wright <anthony@communitymesh.com>
+	use POSIX shell math instead of relying on dc or bc
+	release 11
+
 2006-05-25 "Ed L. Cashin" <ecashin@coraid.com>
-	release 10
 	update README: aoetools are for 2.6 systems
+	release 10
 
 2006-01-18 "Ed L. Cashin" <ecashin@coraid.com>
-	release 9
 	aoe-revalidate: notice error in writing to revalidate device
+	release 9
 
 2005-11-09 Sam Hopkins <sah@coraid.com>
-	release 8
 	add aoe-revalidate
 	document driver compatibility
+	release 8
 
 2005-08-18 "Ed L. Cashin" <ecashin@coraid.com>
-	release 7
 	format sub-gigabyte device sizes correctly
+	release 7
 
 2005-08-17 "Ed L. Cashin" <ecashin@coraid.com>
-	release 6
 	make aoe-stat show device size
+	release 6
 
 2005-07-13 "Ed L. Cashin" <ecashin@coraid.com>
-	release 5
 	make number of slots per shelf configurable
 	Rob Holland <tigger@gentoo.org>: install using PREFIX
 	"make install" builds aoeping
 	avoid gcc 4 warnings by specifying uchar in params
+	release 5
 
 2005-05-17 "Ed L. Cashin" <ecashin@coraid.com>
-	release 4
 	fix typo in Makefile preventing aoeping installation: s/PROG/PROGS/
 	add TODO file
+	release 4
 
 2005-04-14 "Ed L. Cashin" <ecashin@coraid.com>
-	release 3
 	add very basic SMART support to aoeping
+	release 3
 
 2005-04-12 "Ed L. Cashin" <ecashin@coraid.com>
-	release 2
 	add aoeping, a userland tool for simple AoE communications
+	release 2
 
 2005-03-23 "Ed L. Cashin" <ecashin@coraid.com>
 	initial release of aoetools, version 1

+ 3 - 3
aoe-mkshelf.in

@@ -9,13 +9,13 @@ n_partitions=${n_partitions:-16}
 dir=$1
 shelf=$2
 nslots=@npershelf@
-maxslot=`echo $nslots - 1 | bc`
+maxslot=$((nslots - 1))
 MAJOR=152
 
 set -e
 
-minor=`echo $nslots \* $shelf \* $n_partitions | bc`
-endp=`echo $n_partitions - 1 | bc`
+minor=$((nslots * shelf * n_partitions))
+endp=$((n_partitions - 1))
 for slot in `seq 0 $maxslot`; do
 	for part in `seq 0 $endp`; do
 		name=e$shelf.$slot

+ 1 - 1
aoe-stat

@@ -21,7 +21,7 @@ for d in `ls -d $sysd/block/etherd* 2>/dev/null | grep -v p` end; do
 
 	dev=`echo "$d" | sed 's/.*!//'`
 	sectors="`cat \"$d/size\"`"
-	psize=`echo "(512000 * $sectors) / (1000 * 1000 * 1000)" | bc`
+	psize=$(((512000 * sectors) / (1000 * 1000 * 1000)))
 	psize=`printf "%04d\n" $psize | sed 's!\(...\)$!.\1!'`
 	printf "$format" \
 		"$dev" \