18 CPPFLAGS
= $(EXTRA_CPPFLAGS
) -DSLJIT_CONFIG_AUTO
=1 -Isljit_src
20 REGEX_CFLAGS
+= $(CFLAGS
) -fshort-wchar
21 LDFLAGS
= $(EXTRA_LDFLAGS
)
23 TARGET
= sljit_test regex_test
30 SLJIT_HEADERS
= $(SRCDIR
)/sljitLir.h
$(SRCDIR
)/sljitConfig.h
$(SRCDIR
)/sljitConfigInternal.h
32 SLJIT_LIR_FILES
= $(SRCDIR
)/sljitLir.c
$(SRCDIR
)/sljitExecAllocator.c
$(SRCDIR
)/sljitUtils.c \
33 $(SRCDIR
)/sljitNativeARM_32.c
$(SRCDIR
)/sljitNativeARM_T2_32.c
$(SRCDIR
)/sljitNativeARM_64.c \
34 $(SRCDIR
)/sljitNativeMIPS_common.c
$(SRCDIR
)/sljitNativeMIPS_32.c
$(SRCDIR
)/sljitNativeMIPS_64.c \
35 $(SRCDIR
)/sljitNativePPC_common.c
$(SRCDIR
)/sljitNativePPC_32.c
$(SRCDIR
)/sljitNativePPC_64.c \
36 $(SRCDIR
)/sljitNativeSPARC_common.c
$(SRCDIR
)/sljitNativeSPARC_32.c \
37 $(SRCDIR
)/sljitNativeTILEGX_64.c \
38 $(SRCDIR
)/sljitNativeX86_common.c
$(SRCDIR
)/sljitNativeX86_32.c
$(SRCDIR
)/sljitNativeX86_64.c
40 all: $(BINDIR
) $(TARGET
)
45 $(BINDIR
)/sljitLir.o
: $(BINDIR
) $(SLJIT_LIR_FILES
) $(SLJIT_HEADERS
)
46 $(CC
) $(CPPFLAGS
) $(CFLAGS
) -c
-o
$@
$(SRCDIR
)/sljitLir.c
48 $(BINDIR
)/sljitMain.o
: $(TESTDIR
)/sljitMain.c
$(BINDIR
) $(SLJIT_HEADERS
)
49 $(CC
) $(CPPFLAGS
) $(CFLAGS
) -c
-o
$@
$(TESTDIR
)/sljitMain.c
51 $(BINDIR
)/sljitTest.o
: $(TESTDIR
)/sljitTest.c
$(BINDIR
) $(SLJIT_HEADERS
)
52 $(CC
) $(CPPFLAGS
) $(CFLAGS
) -c
-o
$@
$(TESTDIR
)/sljitTest.c
54 $(BINDIR
)/regexMain.o
: $(REGEXDIR
)/regexMain.c
$(BINDIR
) $(SLJIT_HEADERS
)
55 $(CC
) $(CPPFLAGS
) $(CFLAGS
) $(REGEX_CFLAGS
) -c
-o
$@
$(REGEXDIR
)/regexMain.c
57 $(BINDIR
)/regexJIT.o
: $(REGEXDIR
)/regexJIT.c
$(BINDIR
) $(SLJIT_HEADERS
) $(REGEXDIR
)/regexJIT.h
58 $(CC
) $(CPPFLAGS
) $(CFLAGS
) $(REGEX_CFLAGS
) -c
-o
$@
$(REGEXDIR
)/regexJIT.c
61 rm -f
$(BINDIR
)/*.o
$(BINDIR
)/sljit_test
$(BINDIR
)/regex_test
63 sljit_test
: $(BINDIR
)/sljitMain.o
$(BINDIR
)/sljitTest.o
$(BINDIR
)/sljitLir.o
64 $(CC
) $(CFLAGS
) $(LDFLAGS
) $(BINDIR
)/sljitMain.o
$(BINDIR
)/sljitTest.o
$(BINDIR
)/sljitLir.o
-o
$(BINDIR
)/$@
-lm
-lpthread
66 regex_test
: $(BINDIR
)/regexMain.o
$(BINDIR
)/regexJIT.o
$(BINDIR
)/sljitLir.o
67 $(CC
) $(CFLAGS
) $(LDFLAGS
) $(BINDIR
)/regexMain.o
$(BINDIR
)/regexJIT.o
$(BINDIR
)/sljitLir.o
-o
$(BINDIR
)/$@
-lm
-lpthread