[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Minios-devel] [UNIKRAFT/LIBCXXABI PATCH 2/2] Initial public release: configuration and build files



Hi Vlad,

The patch looks generally good, just a couple of issues:

1. This library depends on others (e.g., libunwind), could you please make 
these dependencies explicit in Config.uk (like you do for instance for libcxx) 
and also put an error statement in Makefile.uk the way you did for libunwind?

2. Could you please provide an exportsyms.uk file?

Thanks,

-- Felipe

On 29.03.19, 02:00, "Vlad-Andrei BĂDOIU (78692)" 
<vlad_andrei.badoiu@xxxxxxxxxxxxxxx> wrote:

    This is our initial port of libcxxabi to Unikraft as external
    library. Libc is requiered for it to work.
    
    In the dependency list it should stay as follows:
    ...:$(UK_LIBS)/libunwind:$(UK_LIBS)/compiler-rt:
    $(UK_LIBS)/libcxxabi:$(UK_LIBS)/libcxx:$(UK_LIBS)/newlib:...
    
    Signed-off-by: Vlad-Andrei Badoiu <vlad_andrei.badoiu@xxxxxxxxxxxxxxx>
    ---
     Config.uk   |  3 ++
     Makefile.uk | 89 +++++++++++++++++++++++++++++++++++++++++++++++++++++
     2 files changed, 92 insertions(+)
     create mode 100644 Config.uk
     create mode 100644 Makefile.uk
    
    diff --git a/Config.uk b/Config.uk
    new file mode 100644
    index 0000000..c03d4f7
    --- /dev/null
    +++ b/Config.uk
    @@ -0,0 +1,3 @@
    +menuconfig LIBCXXABI
    +    bool "libcxxabi - c++ abi"
    +    default n
    diff --git a/Makefile.uk b/Makefile.uk
    new file mode 100644
    index 0000000..35e5333
    --- /dev/null
    +++ b/Makefile.uk
    @@ -0,0 +1,89 @@
    +#  libcxxabi Makefile.uk
    +#
    +#  Authors: Vlad-Andrei Badoiu <vlad_andrei.badoiu@xxxxxxxxxxxxxxx>
    +#
    +#  Copyright (c) 2019, NEC Europe Ltd., NEC Corporation. All rights 
reserved.
    +#
    +#  Redistribution and use in source and binary forms, with or without
    +#  modification, are permitted provided that the following conditions
    +#  are met:
    +#
    +#  1. Redistributions of source code must retain the above copyright
    +#     notice, this list of conditions and the following disclaimer.
    +#  2. Redistributions in binary form must reproduce the above copyright
    +#     notice, this list of conditions and the following disclaimer in the
    +#     documentation and/or other materials provided with the distribution.
    +#  3. Neither the name of the copyright holder nor the names of its
    +#     contributors may be used to endorse or promote products derived from
    +#     this software without specific prior written permission.
    +#
    +#  THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS 
IS"
    +#  AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, 
THE
    +#  IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR 
PURPOSE
    +#  ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS 
BE
    +#  LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
    +#  CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
    +#  SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
    +#  INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
    +#  CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
    +#  ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF 
THE
    +#  POSSIBILITY OF SUCH DAMAGE.
    +#
    +#  THIS HEADER MAY NOT BE EXTRACTED OR MODIFIED IN ANY WAY.
    +#
    +
    
+################################################################################
    +# Library registration
    
+################################################################################
    +$(eval $(call addlib_s,libcxxabi,$(CONFIG_LIBCXXABI)))
    +
    
+################################################################################
    +# Sources
    
+################################################################################
    +LIBCXXABI_VERSION=7.0.0
    
+LIBCXXABI_URL=http://releases.llvm.org/$(LIBCXXABI_VERSION)/libcxxabi-$(LIBCXXABI_VERSION).src.tar.xz
    +LIBCXXABI_PATCHDIR=$(LIBCXXABI_BASE)/patches
    +$(eval $(call fetch,libcxxabi,$(LIBCXXABI_URL)))
    +
    
+################################################################################
    +# Helpers
    
+################################################################################
    +LIBCXXABI_SUBDIR=libcxxabi-$(LIBCXXABI_VERSION).src
    +LIBCXXABI_SRC=$(LIBCXXABI_ORIGIN)/$(LIBCXXABI_SUBDIR)
    +
    
+################################################################################
    +# Library includes
    
+################################################################################
    +CINCLUDES-$(CONFIG_LIBCXXABI) += -I$(LIBCXXABI_SRC)/src
    +CINCLUDES-$(CONFIG_LIBCXXABI) += -I$(LIBCXXABI_SRC)/include
    +CXXINCLUDES-$(CONFIG_LIBCXXABI) += -I$(LIBCXXABI_SRC)/src
    +CXXINCLUDES-$(CONFIG_LIBCXXABI) += -I$(LIBCXXABI_SRC)/include
    +
    
+################################################################################
    +# Global flags
    
+################################################################################
    +CONFIG_FLAGS       +=      -D _LIBCXXABI_HAS_NO_THREADS
    +LIBCXXABI_CFLAGS-y    +=  $(CONFIG_FLAGS)
    +LIBCXXABI_CXXFLAGS-y    +=  $(CONFIG_FLAGS)
    +
    
+################################################################################
    +# Library sources
    
+################################################################################
    +LIBCXXABI_SRCS-y += $(LIBCXXABI_SRC)/src/cxa_exception.cpp
    +LIBCXXABI_SRCS-y += $(LIBCXXABI_SRC)/src/cxa_exception_storage.cpp
    +LIBCXXABI_SRCS-y += $(LIBCXXABI_SRC)/src/cxa_virtual.cpp
    +LIBCXXABI_SRCS-y += $(LIBCXXABI_SRC)/src/abort_message.cpp
    +LIBCXXABI_SRCS-y += $(LIBCXXABI_SRC)/src/stdlib_exception.cpp
    +LIBCXXABI_SRCS-y += $(LIBCXXABI_SRC)/src/cxa_demangle.cpp
    +LIBCXXABI_SRCS-y += $(LIBCXXABI_SRC)/src/stdlib_typeinfo.cpp
    +LIBCXXABI_SRCS-y += $(LIBCXXABI_SRC)/src/fallback_malloc.cpp
    +LIBCXXABI_SRCS-y += $(LIBCXXABI_SRC)/src/cxa_aux_runtime.cpp
    +LIBCXXABI_SRCS-y += $(LIBCXXABI_SRC)/src/stdlib_new_delete.cpp
    +LIBCXXABI_SRCS-y += $(LIBCXXABI_SRC)/src/cxa_personality.cpp
    +LIBCXXABI_SRCS-y += $(LIBCXXABI_SRC)/src/cxa_vector.cpp
    +LIBCXXABI_SRCS-y += $(LIBCXXABI_SRC)/src/stdlib_stdexcept.cpp
    +LIBCXXABI_SRCS-y += $(LIBCXXABI_SRC)/src/cxa_unexpected.cpp
    +LIBCXXABI_SRCS-y += $(LIBCXXABI_SRC)/src/private_typeinfo.cpp
    +LIBCXXABI_SRCS-y += $(LIBCXXABI_SRC)/src/cxa_handlers.cpp
    +LIBCXXABI_SRCS-y += $(LIBCXXABI_SRC)/src/cxa_default_handlers.cpp
    +LIBCXXABI_SRCS-y += $(LIBCXXABI_SRC)/src/cxa_guard.cpp
    -- 
    2.20.1
    
    

_______________________________________________
Minios-devel mailing list
Minios-devel@xxxxxxxxxxxxxxxxxxxx
https://lists.xenproject.org/mailman/listinfo/minios-devel

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.