tests/helpers: do not trigger WOSS on warning message
This commit is contained in:
parent
5b0fe7eebd
commit
360156366a
|
@ -6,6 +6,7 @@ include ../libversion.mk
|
|||
ALLSRC := $(wildcard *.c)
|
||||
HELPSRC := helpers.c
|
||||
HELPOBJ := $(O_DIR)/helpers.o
|
||||
HELPOBJ_ESHI := $(O_DIR)/helpers-eshi.o
|
||||
TESTSRC := $(filter-out $(HELPSRC),$(ALLSRC))
|
||||
FPSRC := fault.c
|
||||
ESHISRC := $(shell cat eshi.list)
|
||||
|
@ -34,7 +35,7 @@ ESHI_CFLAGS := $(ESHI_CPPFLAGS) $(BASE_CFLAGS)
|
|||
|
||||
all: output-Makefile $(TARGETS)
|
||||
|
||||
$(TARGETS): $(HELPOBJ)
|
||||
$(TARGETS): $(HELPOBJ) $(HELPOBJ_ESHI)
|
||||
|
||||
install: all
|
||||
$(call inst-cmd,tests,$(Q)for bin in $(TESTSRC:%.c=%); do \
|
||||
|
@ -47,6 +48,9 @@ install: all
|
|||
clean clobber mrproper:
|
||||
$(Q)$(RM) -f $(TARGETS) $(DEPFILES) $(HELPOBJ)
|
||||
|
||||
$(HELPOBJ_ESHI): $(HELPSRC)
|
||||
$(call cc-cmd,$@,$(Q)$(CC) -o $(@) $< -c $(ESHI_CFLAGS))
|
||||
|
||||
$(O_DIR)/%.o: %.c
|
||||
$(call cc-cmd,$@,$(Q)$(CC) -o $(@) $< -c $(CFLAGS))
|
||||
|
||||
|
@ -54,6 +58,6 @@ $(O_DIR)/%: %.c
|
|||
$(call ccld-cmd,$@,$(Q)$(CC) -o $(@) $< $(HELPOBJ) $(TEST_CFLAGS) $(TEST_LDFLAGS))
|
||||
|
||||
$(O_DIR)/%.eshi: %.c
|
||||
$(call ccld-cmd,$@,$(Q)$(CC) -o $(@) $< $(HELPOBJ) $(ESHI_CFLAGS) $(ESHI_LDFLAGS))
|
||||
$(call ccld-cmd,$@,$(Q)$(CC) -o $(@) $< $(HELPOBJ_ESHI) $(ESHI_CFLAGS) $(ESHI_LDFLAGS))
|
||||
|
||||
-include $(DEPFILES)
|
||||
|
|
|
@ -10,14 +10,23 @@
|
|||
#include <string.h>
|
||||
#include <errno.h>
|
||||
#include <pthread.h>
|
||||
#include <linux/ioctl.h>
|
||||
#include <evl/proxy.h>
|
||||
|
||||
#define EXIT_NO_SUPPORT 42
|
||||
|
||||
#define __stringify_1(x...) #x
|
||||
#define __stringify(x...) __stringify_1(x)
|
||||
|
||||
#define warn_failed(__fmt, __args...) \
|
||||
fprintf(stderr, "%s:%d: FAILED: " __fmt "\n", __FILE__, __LINE__, ##__args)
|
||||
#ifdef __ESHI__
|
||||
#define warn_failed(__fmt, __args...) \
|
||||
fprintf(stderr, "%s:%d: FAILED: " __fmt "\n", \
|
||||
__FILE__, __LINE__, ##__args)
|
||||
#else
|
||||
#define warn_failed(__fmt, __args...) \
|
||||
evl_print_proxy(proxy_errfd, "%s:%d: FAILED: " __fmt "\n", \
|
||||
__FILE__, __LINE__, ##__args)
|
||||
#endif
|
||||
|
||||
#define abort_test() exit(1)
|
||||
|
||||
|
|
Loading…
Reference in New Issue