C++学习(四零五)编译选项use-cxa-atexit no-use-cxa-atexit

Posted hankern

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了C++学习(四零五)编译选项use-cxa-atexit no-use-cxa-atexit相关的知识,希望对你有一定的参考价值。

GCC docs中,

-fuse-cxa-atexit

Register destructors for objects with static storage duration with the __cxa_atexit function rather than the atexit function. This option is required for fully standards-compliant handling of static destructors, but only works if your C library supports __cxa_atexit.

在clang的参考手册Clang command line argument reference — Clang 13 documentation中,

Override the default ABI to return small structs in registers

-fregister-global-dtors-with-atexit, -fno-register-global-dtors-with-atexit

Use atexit or __cxa_atexit to register global destructors

-fuse-cxa-atexit, -fno-use-cxa-atexit

以上是关于C++学习(四零五)编译选项use-cxa-atexit no-use-cxa-atexit的主要内容,如果未能解决你的问题,请参考以下文章

C++学习(四零七)ALL_BUILDINSTALLZERO_CHECK

C++学习(四零二)记录20211024

C++学习(四零八)CMake操作系统类型android windows ios

C++学习(四零六)AI三大法则

C++学习(四零九)CMAKE_SYSTEM_NAME确定操作系统类型

C++学习(四四零)android studio如何关联cmake