unikraft / app-helloworld-cpp

kraft-ready repo for building c++ applications with Unikraft
3 stars 16 forks source link

Reorder external library in kraft.yaml file #9

Closed flpostolache closed 1 year ago

flpostolache commented 1 year ago

With the current order of external libraries in the kraft.yaml file, the app won't build because _LIBCPP_BEGIN_NAMESPACE_STD is not defined. This is caused because plat/kvm/x86/time.c includes stdlib.h and since libcxx is placed before musl, the header is included from libcxx's origin code. This causes a problem because, when trying to compile time.c source, it will use the stdlib.h header from libcxx and not define the macro. Later on, when trying to parse the next header file that uses that define, it will stop the build process. This PR reorders the external libraries in the correct order.

Signed-off-by: Florin Postolache florin.postolache80@gmail.com