diff options
| author | Lexi Winter <lexi@le-fay.org> | 2025-06-29 19:19:23 +0100 |
|---|---|---|
| committer | Lexi Winter <lexi@le-fay.org> | 2025-06-29 19:19:23 +0100 |
| commit | a8b0ea58e60bb0326b7f7c8f3c736d89ce9ef1df (patch) | |
| tree | 6dafcf2674780649dcdc2649855722357837a68e /nihil.core | |
| parent | 4fa6821e0645ff61a9380cd090abff472205c630 (diff) | |
| download | nihil-a8b0ea58e60bb0326b7f7c8f3c736d89ce9ef1df.tar.gz nihil-a8b0ea58e60bb0326b7f7c8f3c736d89ce9ef1df.tar.bz2 | |
wip macOS port
Diffstat (limited to 'nihil.core')
| -rw-r--r-- | nihil.core/CMakeLists.txt | 1 | ||||
| -rw-r--r-- | nihil.core/nihil.hh | 26 |
2 files changed, 27 insertions, 0 deletions
diff --git a/nihil.core/CMakeLists.txt b/nihil.core/CMakeLists.txt index 4564640..2a7b3e2 100644 --- a/nihil.core/CMakeLists.txt +++ b/nihil.core/CMakeLists.txt @@ -1,6 +1,7 @@ # This source code is released into the public domain. add_library(nihil.core STATIC) +target_include_directories(nihil.core PUBLIC ${CMAKE_CURRENT_SOURCE_DIR}) target_sources(nihil.core PUBLIC FILE_SET modules TYPE CXX_MODULES FILES nihil.core.ccm diff --git a/nihil.core/nihil.hh b/nihil.core/nihil.hh new file mode 100644 index 0000000..cd7e789 --- /dev/null +++ b/nihil.core/nihil.hh @@ -0,0 +1,26 @@ +/* +* This source code is released into the public domain. + */ + +#ifndef NIHIL_HH_INCLUDED +#define NIHIL_HH_INCLUDED + +#if __has_include(<sys/param.h>) +# include <sys/param.h> +#endif + +#if defined(__FreeBSD_version) + +/* fexecve() added in FreeBSD 8.0 */ +#if (__FreeBSD_version >= 800000) +# define NIHIL_HAVE_FEXECVE +#endif + +/* getenv_r() added in FreeBSD 15.0 */ +#if (__FreeBSD_version >= 1500000) +# define NIHIL_HAVE_GETENV_R +#endif + +#endif // defined(__FreeBSD_version) + +#endif // !NIHIL_HH_INCLUDED |
