From e8f2b7ceaf882ce3f031b4c988abbc780bccf9d4 Mon Sep 17 00:00:00 2001 From: Alcaro Date: Mon, 13 Jan 2020 14:40:05 +0100 Subject: [PATCH] Fix some pointless DLL dependencies --- flips.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/flips.cpp b/flips.cpp index 9f074a9..6a1024b 100644 --- a/flips.cpp +++ b/flips.cpp @@ -10,7 +10,12 @@ //get rid of dependencies on libstdc++, they waste 200KB on this platform void* operator new(size_t n) { return malloc(n); } // forget allocation failures, let them segfault. void operator delete(void * p) { free(p); } +void operator delete(void * p, size_t n) { free(p); } extern "C" void __cxa_pure_virtual() { abort(); } + +#if __GNUC__ && (__cpp_rtti || __cpp_exceptions) +#warning "Consider building with -fno-exceptions -fno-rtti, to avoid dependencies on libgcc_s_sjlj-1.dll and libstdc++-6.dll." +#endif #endif //TODO: source ROM chooser