2 OSNAME
= $(shell uname
-s
)
4 ifeq ($(OSNAME
), SunOS
)
6 CPlusFlags
= -O2
-w
$(COMPILER_FLAG
)
7 SYSLIBS
=-ldl
-lnsl
-lsocket
-lposix4
10 ifeq ($(OSNAME
), Linux
)
13 SYSLIBS
= -rdynamic
-lrt
-lpthread
-lcrypt
-ldl
16 ifeq ($(OSNAME
), FreeBSD
)
19 SYSLIBS
= -rdynamic
-lrt
-lpthread
-lcrypt
-ldl
24 INCL
= -I
$(CSQL_INSTALL_ROOT
)/include -I..
/..
/..
/include
25 LIBS
= -L
$(CSQL_INSTALL_ROOT
)/lib
-lcsql
38 test012 test012a test013 \
39 test001a test002a test003a \
40 test004a test004b test004c \
41 test005a test005b test005c
44 ifeq ($(PlatForm
), supported
)
48 echo
"CSQL is not supported on $(OSNAME) platform"
52 test001
: uniqueindex1.c common.h
53 $(CPlus
) $(CPlusFlags
) -o
$@
$< $(INCL
) $(LIBS
) $(SYSLIBS
)
54 test001a
: uniqueindex1.c common.h
55 $(CPlus
) $(CPlusFlags
) -DTREEINDEX
-o
$@
$< $(INCL
) $(LIBS
) $(SYSLIBS
)
56 test002
: uniqueindex2.c common.h
57 $(CPlus
) $(CPlusFlags
) -o
$@
$< $(INCL
) $(LIBS
) $(SYSLIBS
)
58 test002a
: uniqueindex2.c common.h
59 $(CPlus
) $(CPlusFlags
) -DTREEINDEX
-o
$@
$< $(INCL
) $(LIBS
) $(SYSLIBS
)
60 test003
: uniqueindex3.c common.h
61 $(CPlus
) $(CPlusFlags
) -o
$@
$< $(INCL
) $(LIBS
) $(SYSLIBS
)
62 test003a
: uniqueindex3.c common.h
63 $(CPlus
) $(CPlusFlags
) -DTREEINDEX
-o
$@
$< $(INCL
) $(LIBS
) $(SYSLIBS
)
65 $(CPlus
) $(CPlusFlags
) -o
$@
$< $(INCL
) $(LIBS
) $(SYSLIBS
)
67 $(CPlus
) $(CPlusFlags
) -DF1TREE
-o
$@
$< $(INCL
) $(LIBS
) $(SYSLIBS
)
69 $(CPlus
) $(CPlusFlags
) -DF2TREE
-o
$@
$< $(INCL
) $(LIBS
) $(SYSLIBS
)
71 $(CPlus
) $(CPlusFlags
) -DF1TREE
-DF2TREE
-o
$@
$< $(INCL
) $(LIBS
) $(SYSLIBS
)
73 $(CPlus
) $(CPlusFlags
) -o
$@
$< $(INCL
) $(LIBS
) $(SYSLIBS
)
75 $(CPlus
) $(CPlusFlags
) -DF1TREE
-o
$@
$< $(INCL
) $(LIBS
) $(SYSLIBS
)
77 $(CPlus
) $(CPlusFlags
) -DF2TREE
-o
$@
$< $(INCL
) $(LIBS
) $(SYSLIBS
)
79 $(CPlus
) $(CPlusFlags
) -DF1TREE
-DF2TREE
-o
$@
$< $(INCL
) $(LIBS
) $(SYSLIBS
)
81 $(CPlus
) $(CPlusFlags
) -o
$@
$< $(INCL
) $(LIBS
) $(SYSLIBS
)
83 $(CPlus
) $(CPlusFlags
) -DTREEINDEX
-o
$@
$< $(INCL
) $(LIBS
) $(SYSLIBS
)
85 $(CPlus
) $(CPlusFlags
) -o
$@
$< $(INCL
) $(LIBS
) $(SYSLIBS
)
87 $(CPlus
) $(CPlusFlags
) -DTREEINDEX
-o
$@
$< $(INCL
) $(LIBS
) $(SYSLIBS
)
88 test008
: compositekeyindex1.c
89 $(CPlus
) $(CPlusFlags
) -o
$@
$< $(INCL
) $(LIBS
) $(SYSLIBS
)
90 test008a
: compositekeyindex1.c
91 $(CPlus
) $(CPlusFlags
) -DTREEINDEX
-o
$@
$< $(INCL
) $(LIBS
) $(SYSLIBS
)
92 test009
: createindexnotexist.c
93 $(CPlus
) $(CPlusFlags
) -o
$@
$< $(INCL
) $(LIBS
) $(SYSLIBS
)
94 test009a
: createindexnotexist.c
95 $(CPlus
) $(CPlusFlags
) -DTREEINDEX
-o
$@
$< $(INCL
) $(LIBS
) $(SYSLIBS
)
96 test010
: createindexnofld.c
97 $(CPlus
) $(CPlusFlags
) -o
$@
$< $(INCL
) $(LIBS
) $(SYSLIBS
)
98 test010a
: createindexnofld.c
99 $(CPlus
) $(CPlusFlags
) -DTREEINDEX
-o
$@
$< $(INCL
) $(LIBS
) $(SYSLIBS
)
100 test011
: primarynonunique.c
101 $(CPlus
) $(CPlusFlags
) -o
$@
$< $(INCL
) $(LIBS
) $(SYSLIBS
)
102 test012
: index1.c common.h
103 $(CPlus
) $(CPlusFlags
) -o
$@
$< $(INCL
) $(LIBS
) $(SYSLIBS
)
104 test012a
: index1.c common.h
105 $(CPlus
) $(CPlusFlags
) -DTREEINDEX
-o
$@
$< $(INCL
) $(LIBS
) $(SYSLIBS
)
106 test013
:multiplecompositeindex1.c
107 $(CPlus
) $(CPlusFlags
) -o
$@
$< $(INCL
) $(LIBS
) $(SYSLIBS
)