forked from easysoft/phpmicro
-
Notifications
You must be signed in to change notification settings - Fork 9
/
Makefile.frag
29 lines (23 loc) · 822 Bytes
/
Makefile.frag
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
micro: $(SAPI_MICRO_PATH)
$(SAPI_MICRO_PATH): $(PHP_GLOBAL_OBJS) $(PHP_BINARY_OBJS) $(PHP_MICRO_OBJS)
$(BUILD_MICRO)
MICRO_EXES = sapi/micro/tests/simpleecho.exe sapi/micro/tests/fakecmd.exe
$(MICRO_EXES): $(SAPI_MICRO_PATH)
@binname=$@;\
cat $(SAPI_MICRO_PATH) $${binname%.exe}.php > $@ || {\
rm $@; \
exit 1; \
}
@chmod 0755 $@
MICRO_FAKECMD=sapi/micro/tests/fakecmd.exe
micro_test: $(SAPI_MICRO_PATH) $(MICRO_EXES)
@[ x"hello world" = "x`sapi/micro/tests/simpleecho.exe nonce world`" ] || {\
echo sanity check for micro.sfx failed, the sfx generated may be corrupt. >&2 ;\
exit 1;\
}
@SKIP_IO_CAPTURE_TESTS=yes \
TEST_PHP_EXECUTABLE=$(MICRO_FAKECMD) \
TEST_PHP_SRCDIR=$(top_srcdir) \
CC="$(CC)" \
$(MICRO_FAKECMD) -n $(PHP_TEST_SETTINGS) $(top_srcdir)/run-tests.php -n $(TESTS); \
exit $$?;