File syn_version.h¶
FileList > src > syntropic > system > syn_version.h
Go to the source code of this file
Build version and metadata — compile-time constants. More...
#include <stdint.h>
Classes¶
| Type | Name |
|---|---|
| struct | SYN_Version Compile-time version information. |
Public Static Functions¶
| Type | Name |
|---|---|
| const SYN_Version * | syn_version (void) Get the compile-time version info. |
| int | syn_version_at_least (uint16_t year, uint8_t month, uint8_t rel) Check if running version is at least year.month.release. |
Macros¶
| Type | Name |
|---|---|
| define | SYN_APP_NAME "SyntropicOS" |
| define | SYN_BUILD_DATE \_\_DATE\_\_ |
| define | SYN_BUILD_TIME \_\_TIME\_\_ |
| define | SYN_GIT_HASH "unknown" |
| define | SYN_VERSION_CODE /* multi line expression */ |
| define | SYN_VERSION_MONTH 7Release month (CalVer). |
| define | SYN_VERSION_RELEASE 4Release number within the month (CalVer). |
| define | SYN_VERSION_YEAR 2026Release year (CalVer). |
Detailed Description¶
Provides version numbers, build date/time, and optional git hash. Users define these in their build system or syn_config.h.
** **
printf("SyntropicOS v%d.%d.%d built %s\n",
SYN_VERSION_YEAR, SYN_VERSION_MONTH, SYN_VERSION_RELEASE,
SYN_BUILD_DATE);
// Or use the struct:
const SYN_Version *v = syn_version();
printf("%s\n", v->string);
Public Static Functions Documentation¶
function syn_version¶
Get the compile-time version info.
Returns:
Pointer to static version struct.
function syn_version_at_least¶
Check if running version is at least year.month.release.
Parameters:
yearRequired year component.monthRequired month component.relRequired release component.
Returns:
Non-zero if the current version meets or exceeds the requirements.
Macro Definition Documentation¶
define SYN_APP_NAME¶
Application name.
define SYN_BUILD_DATE¶
Build date string (e.g., "Jun 27 2026").
define SYN_BUILD_TIME¶
Build time string (e.g., "14:30:00").
define SYN_GIT_HASH¶
Git hash (short). Override in build system: -DSYN_GIT_HASH="abc1234"
define SYN_VERSION_CODE¶
Packed version: 0xYYYYMMRR (year.month.release).
define SYN_VERSION_MONTH¶
Release month (CalVer).
define SYN_VERSION_RELEASE¶
Release number within the month (CalVer).
define SYN_VERSION_YEAR¶
Release year (CalVer).
The documentation for this class was generated from the following file src/syntropic/system/syn_version.h