test POSIX ABI compatibility in libucontext itself, too

pull/25/head
Ariadne Conill 2021-01-08 02:37:47 -07:00
parent 39a2958561
commit 78e880a29f
2 changed files with 15 additions and 1 deletions

1
.gitignore vendored
View File

@ -3,6 +3,7 @@ include/libucontext/bits.h
examples/cooperative_threading
test_libucontext
test_libucontext_posix
test_libucontext_bare_posixabi
libucontext.a
libucontext.so
libucontext.so.*

View File

@ -134,7 +134,7 @@ ${LIBUCONTEXT_POSIX_STATIC_NAME}_clean:
libucontext_posix_obj_clean:
rm -f ${LIBUCONTEXT_POSIX_OBJ}
check_clean: check_bare_clean check_posix_clean
check_clean: check_bare_clean check_posix_clean check_bare_posixabi_clean
check_bare_clean:
rm -f test_libucontext
@ -142,6 +142,9 @@ check_bare_clean:
check_posix_clean:
rm -f test_libucontext_posix
check_bare_posixabi_clean:
rm -f test_libucontext_bare_posixabi
docs_clean:
rm -f ${MANPAGES}
@ -187,6 +190,16 @@ test_libucontext_posix: test_libucontext_posix.c ${LIBUCONTEXT_POSIX_NAME}
$(CC) -std=gnu99 -D_BSD_SOURCE ${CFLAGS} ${CPPFLAGS} $@.c -o $@ -L. -lucontext -lucontext_posix
endif
ifeq ($(EXPORT_UNPREFIXED),yes)
check: check_libucontext_bare_posixabi
check_libucontext_bare_posixabi: test_libucontext_bare_posixabi ${LIBUCONTEXT_SONAME}
env LD_LIBRARY_PATH=$(shell pwd) ./test_libucontext_bare_posixabi
test_libucontext_bare_posixabi: test_libucontext_posix.c ${LIBUCONTEXT_NAME}
$(CC) -std=gnu99 -D_BSD_SOURCE ${CFLAGS} ${CPPFLAGS} test_libucontext_posix.c -o $@ -L. -lucontext
endif
check: test_libucontext ${LIBUCONTEXT_SONAME}
env LD_LIBRARY_PATH=$(shell pwd) ./test_libucontext