diff options
| author | Amlal El Mahrouss <amlal@nekernel.org> | 2025-11-29 21:15:44 -0500 |
|---|---|---|
| committer | Amlal El Mahrouss <amlal@nekernel.org> | 2025-11-29 21:15:44 -0500 |
| commit | 1b5097d5035cb73a4845e914021851bf81186bfb (patch) | |
| tree | 20a18b5820519da8127a11c72ab1ebd523050ca9 /include/NeBuildKit/Config.h | |
| parent | d27494728d3822bb13d615a27e5d5d6584f5a804 (diff) | |
chore: NeBuildKit: Architectural improvements over {Defines+Includes}.h
Signed-off-by: Amlal El Mahrouss <amlal@nekernel.org>
Diffstat (limited to 'include/NeBuildKit/Config.h')
| -rw-r--r-- | include/NeBuildKit/Config.h | 48 |
1 files changed, 48 insertions, 0 deletions
diff --git a/include/NeBuildKit/Config.h b/include/NeBuildKit/Config.h new file mode 100644 index 0000000..00be9de --- /dev/null +++ b/include/NeBuildKit/Config.h @@ -0,0 +1,48 @@ +// ============================================================= // +// nebuild +// Copyright (C) 2024-2025, Amlal El Mahrouss, licensed under BSD-3 license. +// ============================================================= // + +#pragma once + +/// =========================================================== /// +/// @author Amlal El Mahrouss +/// =========================================================== /// + +#include <rang/rang.h> +#include <cassert> +#include <cstddef> +#include <cstdio> +#include <fstream> +#include <iostream> +#include <sstream> +#include <string> +#include <thread> + +#define LIKELY(ARG) ((ARG) ? assert(false) : ((void) 0)) +#define UNLIKELY(ARG) LIKELY(!(ARG)) + +#define LIBNEBUILD_VERSION "v0.0.7-buildkit" + +#define LIBNEBUILD_VERSION_BCD 0x0007 + +#define LIBNEBUILD_VERSION_MAJOR 0 +#define LIBNEBUILD_VERSION_MINOR 0 +#define LIBNEBUILD_VERSION_PATCH 7 + +#define LIBNEBUILD_EXPORT_C extern "C" + +#define LIBNEBUILD_UNUSED(X) ((void) X) + +namespace NeBuild {} + +namespace NeBuild::Logger { +/// @brief replacement for std::cout for NeBuild logging. +inline std::ostream& info() noexcept { + auto& out = std::cout; + out << rang::fg::red << "nebuild: " << rang::style::reset; + return out; +} +} // namespace NeBuild::Logger + + |
