diff options
author | andersen <andersen@69ca8d6d-28ef-0310-b511-8ec308f3f277> | 2001-10-24 05:00:29 +0000 |
---|---|---|
committer | andersen <andersen@69ca8d6d-28ef-0310-b511-8ec308f3f277> | 2001-10-24 05:00:29 +0000 |
commit | 1e2799601614452a40df7862e6ca180ecb08c04d (patch) | |
tree | 153a573095afac8d8d0ea857759ecabd77fb28b7 /tests | |
parent | 47f91d1f7fc06cf27e2a6c3c2ada99226ba50cb9 (diff) | |
download | busybox-w32-1e2799601614452a40df7862e6ca180ecb08c04d.tar.gz busybox-w32-1e2799601614452a40df7862e6ca180ecb08c04d.tar.bz2 busybox-w32-1e2799601614452a40df7862e6ca180ecb08c04d.zip |
Major rework of the directory structure and the entire build system.
-Erik
git-svn-id: svn://busybox.net/trunk/busybox@3561 69ca8d6d-28ef-0310-b511-8ec308f3f277
Diffstat (limited to 'tests')
-rwxr-xr-x | tests/multibuild.pl | 8 | ||||
-rwxr-xr-x | tests/multifeat.pl | 8 | ||||
-rw-r--r-- | tests/testcases | 2 | ||||
-rwxr-xr-x | tests/tester.sh | 14 |
4 files changed, 16 insertions, 16 deletions
diff --git a/tests/multibuild.pl b/tests/multibuild.pl index 94930bd95..a3e49a625 100755 --- a/tests/multibuild.pl +++ b/tests/multibuild.pl | |||
@@ -12,13 +12,13 @@ | |||
12 | 12 | ||
13 | $logfile = "multibuild.log"; | 13 | $logfile = "multibuild.log"; |
14 | 14 | ||
15 | # How to handle all the BB_FEATURE_FOO lines | 15 | # How to handle all the CONFIG_FEATURE_FOO lines |
16 | if ($ARGV[0] eq "-all" ) { shift(@ARGV); $choice="all"; } | 16 | if ($ARGV[0] eq "-all" ) { shift(@ARGV); $choice="all"; } |
17 | if ($ARGV[0] eq "-none") { shift(@ARGV); $choice="none"; } | 17 | if ($ARGV[0] eq "-none") { shift(@ARGV); $choice="none"; } |
18 | # neither means, leave that part of Config.h alone | 18 | # neither means, leave that part of Config.h alone |
19 | 19 | ||
20 | # Support building from pristine source | 20 | # Support building from pristine source |
21 | $make_opt = "-f $ARGV[0]/Makefile BB_SRC_DIR=$ARGV[0]" if ($ARGV[0] ne ""); | 21 | $make_opt = "-f $ARGV[0]/Makefile CONFIG_SRC_DIR=$ARGV[0]" if ($ARGV[0] ne ""); |
22 | 22 | ||
23 | # Move the config file to a safe place | 23 | # Move the config file to a safe place |
24 | -e "Config.h.orig" || 0==system("mv -f Config.h Config.h.orig") || die; | 24 | -e "Config.h.orig" || 0==system("mv -f Config.h Config.h.orig") || die; |
@@ -38,7 +38,7 @@ while (<C>) { | |||
38 | $trailer .= $_; | 38 | $trailer .= $_; |
39 | } else { | 39 | } else { |
40 | $in_trailer=1 if /End of Applications List/; | 40 | $in_trailer=1 if /End of Applications List/; |
41 | if (/^\/*#define BB_([A-Z0-9_]*)/) { | 41 | if (/^\/*#define CONFIG_([A-Z0-9_]*)/) { |
42 | push @apps, $1; | 42 | push @apps, $1; |
43 | } | 43 | } |
44 | } | 44 | } |
@@ -50,7 +50,7 @@ $failed_tests=0; | |||
50 | for $a (@apps) { | 50 | for $a (@apps) { |
51 | # print "Testing build of applet $a ...\n"; | 51 | # print "Testing build of applet $a ...\n"; |
52 | open (O, ">Config.h") || die; | 52 | open (O, ">Config.h") || die; |
53 | print O "#define BB_$a\n", $trailer; | 53 | print O "#define CONFIG_$a\n", $trailer; |
54 | close O; | 54 | close O; |
55 | system("echo -e '\n***\n$a\n***' >>$logfile"); | 55 | system("echo -e '\n***\n$a\n***' >>$logfile"); |
56 | # With a fast computer and 1-second resolution on file timestamps, this | 56 | # With a fast computer and 1-second resolution on file timestamps, this |
diff --git a/tests/multifeat.pl b/tests/multifeat.pl index adcb30bbd..875b4a277 100755 --- a/tests/multifeat.pl +++ b/tests/multifeat.pl | |||
@@ -11,14 +11,14 @@ | |||
11 | 11 | ||
12 | $logfile = "multifeat.log"; | 12 | $logfile = "multifeat.log"; |
13 | 13 | ||
14 | # How to handle all the BB_APPLET lines | 14 | # How to handle all the CONFIG_APPLET lines |
15 | # (most thorough testing occurs when you call it with the -all switch) | 15 | # (most thorough testing occurs when you call it with the -all switch) |
16 | if ($ARGV[0] eq "-all" ) { shift(@ARGV); $choice="all"; } | 16 | if ($ARGV[0] eq "-all" ) { shift(@ARGV); $choice="all"; } |
17 | if ($ARGV[0] eq "-none") { shift(@ARGV); $choice="none"; } | 17 | if ($ARGV[0] eq "-none") { shift(@ARGV); $choice="none"; } |
18 | # neither means, leave that part of Config.h alone | 18 | # neither means, leave that part of Config.h alone |
19 | 19 | ||
20 | # Support building from pristine source | 20 | # Support building from pristine source |
21 | $make_opt = "-f $ARGV[0]/Makefile BB_SRC_DIR=$ARGV[0]" if ($ARGV[0] ne ""); | 21 | $make_opt = "-f $ARGV[0]/Makefile CONFIG_SRC_DIR=$ARGV[0]" if ($ARGV[0] ne ""); |
22 | 22 | ||
23 | # Move the config file to a safe place | 23 | # Move the config file to a safe place |
24 | -e "Config.h.orig" || 0==system("mv -f Config.h Config.h.orig") || die; | 24 | -e "Config.h.orig" || 0==system("mv -f Config.h Config.h.orig") || die; |
@@ -42,7 +42,7 @@ while (<C>) { | |||
42 | } | 42 | } |
43 | } | 43 | } |
44 | elsif ($in_features) { | 44 | elsif ($in_features) { |
45 | if (/^\/*#define BB_FEATURE_([A-Z0-9_]*)/) { | 45 | if (/^\/*#define CONFIG_FEATURE_([A-Z0-9_]*)/) { |
46 | push @features, $1; | 46 | push @features, $1; |
47 | } | 47 | } |
48 | if (/End of Features List/) { | 48 | if (/End of Features List/) { |
@@ -60,7 +60,7 @@ $failed_tests=0; | |||
60 | for $f (@features) { | 60 | for $f (@features) { |
61 | # print "Testing build with feature $f ...\n"; | 61 | # print "Testing build with feature $f ...\n"; |
62 | open (O, ">Config.h") || die; | 62 | open (O, ">Config.h") || die; |
63 | print O $header, "#define BB_FEATURE_$f\n", $trailer; | 63 | print O $header, "#define CONFIG_FEATURE_$f\n", $trailer; |
64 | close O; | 64 | close O; |
65 | system("echo -e '\n***\n$f\n***' >>$logfile"); | 65 | system("echo -e '\n***\n$f\n***' >>$logfile"); |
66 | # With a fast computer and 1-second resolution on file timestamps, this | 66 | # With a fast computer and 1-second resolution on file timestamps, this |
diff --git a/tests/testcases b/tests/testcases index 2aad9b651..2c28bf389 100644 --- a/tests/testcases +++ b/tests/testcases | |||
@@ -199,7 +199,7 @@ id -un | |||
199 | 199 | ||
200 | 200 | ||
201 | # ifconfig | 201 | # ifconfig |
202 | # requires BB_FEATURE_IFCONFIG_STATUS | 202 | # requires CONFIG_FEATURE_IFCONFIG_STATUS |
203 | ifconfig | 203 | ifconfig |
204 | #ifconfig -a | 204 | #ifconfig -a |
205 | #ifconfig eth0 | 205 | #ifconfig eth0 |
diff --git a/tests/tester.sh b/tests/tester.sh index a767c6c7f..09ba750ec 100755 --- a/tests/tester.sh +++ b/tests/tester.sh | |||
@@ -10,7 +10,7 @@ | |||
10 | BUSYBOX=../busybox | 10 | BUSYBOX=../busybox |
11 | TESTCASES=testcases | 11 | TESTCASES=testcases |
12 | LOGFILE=tester.log | 12 | LOGFILE=tester.log |
13 | BB_OUT=bb.out | 13 | CONFIG_OUT=bb.out |
14 | GNU_OUT=gnu.out | 14 | GNU_OUT=gnu.out |
15 | SETUP="" | 15 | SETUP="" |
16 | CLEANUP="" | 16 | CLEANUP="" |
@@ -25,7 +25,7 @@ do | |||
25 | p) BUSYBOX=$OPTARG; ;; | 25 | p) BUSYBOX=$OPTARG; ;; |
26 | t) TESTCASES=$OPTARG; ;; | 26 | t) TESTCASES=$OPTARG; ;; |
27 | l) LOGFILE=$OPTARG; ;; | 27 | l) LOGFILE=$OPTARG; ;; |
28 | # b) BB_OUT=$OPTARG; ;; | 28 | # b) CONFIG_OUT=$OPTARG; ;; |
29 | # g) GNU_OUT=$OPTARG; ;; | 29 | # g) GNU_OUT=$OPTARG; ;; |
30 | s) SETUP=$OPTARG; ;; | 30 | s) SETUP=$OPTARG; ;; |
31 | c) CLEANUP=$OPTARG; ;; | 31 | c) CLEANUP=$OPTARG; ;; |
@@ -59,7 +59,7 @@ then | |||
59 | echo "BUSYBOX=$BUSYBOX" | 59 | echo "BUSYBOX=$BUSYBOX" |
60 | echo "TESTCASES=$TESTCASES" | 60 | echo "TESTCASES=$TESTCASES" |
61 | echo "LOGFILE=$LOGFILE" | 61 | echo "LOGFILE=$LOGFILE" |
62 | echo "BB_OUT=$BB_OUT" | 62 | echo "CONFIG_OUT=$CONFIG_OUT" |
63 | echo "GNU_OUT=$GNU_OUT" | 63 | echo "GNU_OUT=$GNU_OUT" |
64 | echo "SETUP=$SETUP" | 64 | echo "SETUP=$SETUP" |
65 | echo "CLEANUP=$CLEANUP" | 65 | echo "CLEANUP=$CLEANUP" |
@@ -129,14 +129,14 @@ do | |||
129 | 129 | ||
130 | # execute line using busybox programs | 130 | # execute line using busybox programs |
131 | [ $DEBUG -ge 2 ] && echo "testing: $line" | tee -a $LOGFILE | 131 | [ $DEBUG -ge 2 ] && echo "testing: $line" | tee -a $LOGFILE |
132 | sh -c "$line" > $BB_OUT | 132 | sh -c "$line" > $CONFIG_OUT |
133 | 133 | ||
134 | # see if they match | 134 | # see if they match |
135 | diff -q $BB_OUT $GNU_OUT > /dev/null | 135 | diff -q $CONFIG_OUT $GNU_OUT > /dev/null |
136 | if [ $? -eq 1 ] | 136 | if [ $? -eq 1 ] |
137 | then | 137 | then |
138 | [ $DEBUG -ge 1 ] && echo "FAILED: $line" | tee -a $LOGFILE | 138 | [ $DEBUG -ge 1 ] && echo "FAILED: $line" | tee -a $LOGFILE |
139 | diff -u $BB_OUT $GNU_OUT >> $LOGFILE | 139 | diff -u $CONFIG_OUT $GNU_OUT >> $LOGFILE |
140 | fi | 140 | fi |
141 | fi | 141 | fi |
142 | fi | 142 | fi |
@@ -147,7 +147,7 @@ done | |||
147 | 147 | ||
148 | 148 | ||
149 | # do normal cleanup | 149 | # do normal cleanup |
150 | [ "$KEEPTMPFILES" = "no" ] && rm -f $BB_OUT $GNU_OUT | 150 | [ "$KEEPTMPFILES" = "no" ] && rm -f $CONFIG_OUT $GNU_OUT |
151 | 151 | ||
152 | 152 | ||
153 | # do extra cleanup (if any) | 153 | # do extra cleanup (if any) |