AUI Framework
develop
Cross-platform module-based framework for developing C++20 desktop applications
|
AUI provides set of AUI_PLATFORM_*
and AUI_COMPILER_*
definitions for platform and compiler checking to use in both CMake and C++.
Platform | C++ | CMake | Platform specific dir |
---|---|---|---|
Windows | #if AUI_PLATFORM_WIN
// ...
#endif
| if(AUI_PLATFORM_WIN)
# ...
endif()
|
|
Linux (not Android) | #if AUI_PLATFORM_LINUX
// ...
#endif
| if(AUI_PLATFORM_LINUX)
# ...
endif()
|
|
macOS | #if AUI_PLATFORM_MACOS
// ...
#endif
| if(AUI_PLATFORM_MACOS)
# ...
endif()
|
|
Android | #if AUI_PLATFORM_ANDROID
// ...
#endif
| if(AUI_PLATFORM_ANDROID)
# ...
endif()
|
|
iOS (both iPhone and iPad) | #if AUI_PLATFORM_IOS
// ...
#endif
| if(AUI_PLATFORM_IOS)
# ...
endif()
|
|
Apple (macOS, iOS) | #if AUI_PLATFORM_APPLE
// ...
#endif
| if(AUI_PLATFORM_APPLE)
# ...
endif()
|
|
Unix (Linux, Android, macOS, iOS) | #if AUI_PLATFORM_UNIX
// ...
#endif
| if(AUI_PLATFORM_UNIX)
# ...
endif()
|
|
Emscripten | #if AUI_PLATFORM_EMSCRIPTEN
// ...
#endif
| if(AUI_PLATFORM_EMSCRIPTEN)
# ...
endif()
| Platform/emscripten |
With AUI, the platform dependent code can be placed in src/Platform/<PLATFORM_NAME>
dir, where <PLATFORM_NAME>
is one of the supported platforms (see the table above).
Compiler | C++ | CMake |
---|---|---|
MSVC | #if AUI_COMPILER_MSVC
// ...
#endif
| if(AUI_COMPILER_MSVC)
# ...
endif()
|
GCC (including MinGW) | #if AUI_COMPILER_GCC
// ...
#endif
| if(AUI_COMPILER_GCC)
# ...
endif()
|
CLANG | #if AUI_COMPILER_CLANG
// ...
#endif
| if(AUI_COMPILER_CLANG)
# ...
endif()
|
Target name exposed by aui_module and aui_executable.
dllexport
(on Windows) or visibility
(on other platforms) policy for the symbol.