Separate setjmp/longjmp from libc into own library

This commit is contained in:
Sebastian Sumpf 2012-05-23 15:54:37 +02:00 committed by Norman Feske
parent 376983ae4c
commit 3bffcc17de
8 changed files with 58 additions and 4 deletions

View File

@ -0,0 +1,33 @@
#
# Add generic libc headers to standard include search paths
#
REP_INC_DIR += include/libc
#
# Add platform-specific libc headers to standard include search paths
#
ifeq ($(filter-out $(SPECS),x86),)
ifeq ($(filter-out $(SPECS),32bit),)
LIBC_REP_INC_DIR = include/libc-i386
endif # 32bit
ifeq ($(filter-out $(SPECS),64bit),)
LIBC_REP_INC_DIR = include/libc-amd64
endif # 32bit
LIBC_REP_INC_DIR += include/libc-x86
endif # x86
ifeq ($(filter-out $(SPECS),arm),)
LIBC_REP_INC_DIR = include/libc-arm
endif # ARM
#
# If we found no valid include path for the configured target platform,
# we have to prevent the build system from building the target. This is
# done by adding an artificial requirement.
#
ifeq ($(LIBC_REP_INC_DIR),)
REQUIRES += libc_support_for_your_target_platform
endif
REP_INC_DIR += $(LIBC_REP_INC_DIR)

View File

@ -3,7 +3,7 @@ include $(REP_DIR)/lib/mk/libc-gen.inc
LIBC_GEN_ARM_DIR = $(LIBC_DIR)/libc/arm/gen
#FILTER_OUT_S += rfork_thread.S sigsetjmp.S setjmp.S _setjmp.S divsi3.S
FILTER_OUT_S += rfork_thread.S sigsetjmp.S divsi3.S
FILTER_OUT_S += rfork_thread.S sigsetjmp.S divsi3.S setjmp.S _setjmp.S
FILTER_OUT_C += _set_tp.c fabs.c frexp.c modf.c
SRC_S += $(filter-out $(FILTER_OUT_S),$(notdir $(wildcard $(LIBC_GEN_ARM_DIR)/*.S)))

View File

@ -0,0 +1,7 @@
LIBC_GEN_ARM_DIR = $(LIBC_DIR)/libc/arm/gen
SRC_S = _setjmp.S setjmp.S
include $(REP_DIR)/lib/mk/libc-common.inc
vpath %.S $(LIBC_GEN_ARM_DIR)

View File

@ -3,7 +3,7 @@
#
LIBS = libc-string libc-locale libc-stdlib libc-stdio libc-gen libc-gdtoa \
libc-inet libc-stdtime libc-regex libc-compat
libc-inet libc-stdtime libc-regex libc-compat libc-setjmp
LIBS += timed_semaphore cxx
#

View File

@ -2,7 +2,7 @@ include $(REP_DIR)/lib/mk/libc-gen.inc
LIBC_GEN_I386_DIR = $(LIBC_DIR)/libc/i386/gen
FILTER_OUT_S += rfork_thread.S sigsetjmp.S
FILTER_OUT_S += rfork_thread.S sigsetjmp.S _setjmp.S setjmp.S
FILTER_OUT_C += _set_tp.c
#

View File

@ -0,0 +1,7 @@
LIBC_GEN_I386_DIR = $(LIBC_DIR)/libc/i386/gen
SRC_S = _setjmp.S setjmp.S
include $(REP_DIR)/lib/mk/libc-common.inc
vpath %.S $(LIBC_GEN_I386_DIR)

View File

@ -2,7 +2,7 @@ include $(REP_DIR)/lib/mk/libc-gen.inc
LIBC_GEN_AMD64_DIR = $(LIBC_DIR)/libc/amd64/gen
FILTER_OUT_S += rfork_thread.S sigsetjmp.S
FILTER_OUT_S += rfork_thread.S sigsetjmp.S setjmp.S _setjmp.S
FILTER_OUT_C += _set_tp.c
#

View File

@ -0,0 +1,7 @@
LIBC_GEN_AMD64_DIR = $(LIBC_DIR)/libc/amd64/gen
SRC_S = _setjmp.S setjmp.S
include $(REP_DIR)/lib/mk/libc-common.inc
vpath %.S $(LIBC_GEN_AMD64_DIR)