-
Notifications
You must be signed in to change notification settings - Fork 12
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add new Makefile in tests/ARP, and modify arp.sh accordingly. Added Makefile infrastructure for all tests: CPU, FS, IF, MEM, MISC, ROUTE, STAT, VM. Modified their *.sh files accordingly. Signed-off-by: Anjali Kulkarni <[email protected]>
- Loading branch information
Showing
17 changed files
with
128 additions
and
44 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
CC = gcc | ||
export LD_LIBRARY_PATH = `git rev-parse --show-toplevel` | ||
CFLAGS = -g -Wall -Werror -I $(LD_LIBRARY_PATH) -std=gnu99 -L $(LD_LIBRARY_PATH) | ||
REXE = arp_test | ||
MFILES = arp_info.* | ||
|
||
arp_test: arp_test.c | ||
$(CC) $(CFLAGS) -o $@ $^ -lresource | ||
|
||
clean: | ||
rm -rf $(MFILES) $(REXE) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
CC = gcc | ||
export LD_LIBRARY_PATH = `git rev-parse --show-toplevel` | ||
CFLAGS = -g -Wall -Werror -I $(LD_LIBRARY_PATH) -std=gnu99 -L $(LD_LIBRARY_PATH) | ||
REXE = cpu_test | ||
MFILES = cpu_info.* | ||
|
||
cpu_test: cpu_test.c | ||
$(CC) $(CFLAGS) -o $@ $^ -lresource | ||
|
||
clean: | ||
rm -rf $(MFILES) $(REXE) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,10 @@ | ||
# Enable #define TESTING and the recompile library - make | ||
export LD_LIBRARY_PATH=`git rev-parse --show-toplevel` | ||
cd $LD_LIBRARY_PATH | ||
cd tests/CPU | ||
rm -f cpu_test | ||
cc -I $LD_LIBRARY_PATH -std=gnu99 -o cpu_test cpu_test.c -L $LD_LIBRARY_PATH -lresource | ||
rm -f ./cpu_info.orig | ||
rm -f ./cpu_info.txt | ||
cd $LD_LIBRARY_PATH/tests/CPU | ||
|
||
make clean | ||
make cpu_test | ||
|
||
cat /proc/cpuinfo > ./cpu_info.orig | ||
./cpu_test | ||
diff ./cpu_info.orig ./cpu_info.txt |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
CC = gcc | ||
export LD_LIBRARY_PATH = `git rev-parse --show-toplevel` | ||
CFLAGS = -g -Wall -Werror -I $(LD_LIBRARY_PATH) -std=gnu99 -L $(LD_LIBRARY_PATH) | ||
REXE = fs_test | ||
MFILES = fs_info.* | ||
|
||
fs_test: fs_test.c | ||
$(CC) $(CFLAGS) -o $@ $^ -lresource | ||
|
||
clean: | ||
rm -rf $(MFILES) $(REXE) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,8 @@ | ||
# Enable #define TESTING and the recompile library - make | ||
export LD_LIBRARY_PATH=`git rev-parse --show-toplevel` | ||
cd $LD_LIBRARY_PATH | ||
cd tests/FS | ||
rm -f fs_test | ||
cc -I $LD_LIBRARY_PATH -std=gnu99 -o fs_test fs_test.c -L $LD_LIBRARY_PATH -lresource | ||
cd $LD_LIBRARY_PATH/tests/FS | ||
|
||
make clean | ||
make fs_test | ||
|
||
./fs_test |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
CC = gcc | ||
export LD_LIBRARY_PATH = `git rev-parse --show-toplevel` | ||
CFLAGS = -g -Wall -Werror -I $(LD_LIBRARY_PATH) -std=gnu99 -L $(LD_LIBRARY_PATH) | ||
REXE = if_test | ||
MFILES = if_info.* | ||
|
||
if_test: if_test.c | ||
$(CC) $(CFLAGS) -o $@ $^ -lresource | ||
|
||
clean: | ||
rm -rf $(MFILES) $(REXE) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,8 @@ | ||
# Enable -DTESTING in Makefile and the recompile library - make | ||
export LD_LIBRARY_PATH=`git rev-parse --show-toplevel` | ||
cd $LD_LIBRARY_PATH | ||
cd tests/IF | ||
rm -f ./if_test | ||
rm -f ./if_info.txt | ||
cc -I $LD_LIBRARY_PATH -std=gnu99 -o if_test if_test.c -L $LD_LIBRARY_PATH -lresource | ||
cd $LD_LIBRARY_PATH/tests/IF | ||
|
||
make clean | ||
make if_test | ||
|
||
./if_test |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
CC = gcc | ||
export LD_LIBRARY_PATH = `git rev-parse --show-toplevel` | ||
CFLAGS = -g -Wall -Werror -I $(LD_LIBRARY_PATH) -std=gnu99 -L $(LD_LIBRARY_PATH) | ||
REXE = tests | ||
MFILES = vm_info.orig | ||
|
||
tests: tests.c | ||
$(CC) $(CFLAGS) -o $@ $^ -lresource | ||
|
||
clean: | ||
rm -rf $(MFILES) $(REXE) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,9 @@ | ||
# Enable -DTESTING in Makefile and the recompile library - make | ||
export LD_LIBRARY_PATH=`git rev-parse --show-toplevel` | ||
cd $LD_LIBRARY_PATH | ||
cd tests/MISC | ||
rm -f tests | ||
rm -f ./vm_info.orig | ||
cd $LD_LIBRARY_PATH/tests/MISC | ||
|
||
make clean | ||
make tests | ||
|
||
cat /proc/vmstat > ./vm_info.orig | ||
cc -I $LD_LIBRARY_PATH -std=gnu99 -o tests tests.c -L $LD_LIBRARY_PATH -lresource | ||
./tests |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
CC = gcc | ||
export LD_LIBRARY_PATH = `git rev-parse --show-toplevel` | ||
CFLAGS = -g -Wall -Werror -I $(LD_LIBRARY_PATH) -std=gnu99 -L $(LD_LIBRARY_PATH) | ||
REXE = route_test | ||
MFILES = route_info.* | ||
|
||
route_test: route_test.c | ||
$(CC) $(CFLAGS) -o $@ $^ -lresource | ||
|
||
clean: | ||
rm -rf $(MFILES) $(REXE) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
CC = gcc | ||
export LD_LIBRARY_PATH = `git rev-parse --show-toplevel` | ||
CFLAGS = -g -Wall -Werror -I $(LD_LIBRARY_PATH) -std=gnu99 -L $(LD_LIBRARY_PATH) | ||
REXE = stat_test | ||
MFILES = stat_info.* | ||
|
||
stat_test: stat_test.c | ||
$(CC) $(CFLAGS) -o $@ $^ -lresource | ||
|
||
clean: | ||
rm -rf $(MFILES) $(REXE) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
CC = gcc | ||
export LD_LIBRARY_PATH = `git rev-parse --show-toplevel` | ||
CFLAGS = -g -Wall -Werror -I $(LD_LIBRARY_PATH) -std=gnu99 -L $(LD_LIBRARY_PATH) | ||
REXE = vm_test | ||
MFILES = vm_info.* | ||
|
||
vm_test: vm_test.c | ||
$(CC) $(CFLAGS) -o $@ $^ -lresource | ||
|
||
clean: | ||
rm -rf $(MFILES) $(REXE) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters