44 $dtrace -h -s prov.d
45 if [ $? -ne 0 ]; then
46 print -u2 "failed to generate header file"
47 exit 1
48 fi
49
50 cat > test.c <<EOF
51 #include <sys/types.h>
52 #include "prov.h"
53
54 int
55 main(int argc, char **argv)
56 {
57 if (TEST_PROV_GO_ENABLED())
58 return (2);
59
60 return (0);
61 }
62 EOF
63
64 gcc -c test.c
65 if [ $? -ne 0 ]; then
66 print -u2 "failed to compile test.c"
67 exit 1
68 fi
69 $dtrace -G -32 -s prov.d test.o
70 if [ $? -ne 0 ]; then
71 print -u2 "failed to create DOF"
72 exit 1
73 fi
74 gcc -o test test.o prov.o
75 if [ $? -ne 0 ]; then
76 print -u2 "failed to link final executable"
77 exit 1
78 fi
79
80 cd /
81 /usr/bin/rm -rf $DIR
|
44 $dtrace -h -s prov.d
45 if [ $? -ne 0 ]; then
46 print -u2 "failed to generate header file"
47 exit 1
48 fi
49
50 cat > test.c <<EOF
51 #include <sys/types.h>
52 #include "prov.h"
53
54 int
55 main(int argc, char **argv)
56 {
57 if (TEST_PROV_GO_ENABLED())
58 return (2);
59
60 return (0);
61 }
62 EOF
63
64 gcc -m32 -c test.c
65 if [ $? -ne 0 ]; then
66 print -u2 "failed to compile test.c"
67 exit 1
68 fi
69 $dtrace -G -32 -s prov.d test.o
70 if [ $? -ne 0 ]; then
71 print -u2 "failed to create DOF"
72 exit 1
73 fi
74 gcc -m32 -o test test.o prov.o
75 if [ $? -ne 0 ]; then
76 print -u2 "failed to link final executable"
77 exit 1
78 fi
79
80 cd /
81 /usr/bin/rm -rf $DIR
|