Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update to first major version 1.0.0 #60

Merged
merged 6 commits into from
Nov 10, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 19 additions & 0 deletions src/lib/version.c
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
#include <stddef.h>
#include <assert.h>

#include "version.h"

#define STATIC_ASSERT(COND,MSG) typedef char static_assertion[(COND)?1:-1]

#define STRINGIFY(x) #x
#define TOSTRING(x) STRINGIFY(x)
#define LIBRDB_COMPOSED_VERSION_STRING TOSTRING(LIBRDB_MAJOR_VERSION) "." \
TOSTRING(LIBRDB_MINOR_VERSION) "." \
TOSTRING(LIBRDB_PATCH_VERSION)

/* Verify that the composed version string matches the individual version components */
STATIC_ASSERT(
(sizeof(LIBRDB_VERSION_STRING) == sizeof(LIBRDB_COMPOSED_VERSION_STRING)) &&
(__builtin_strcmp(LIBRDB_VERSION_STRING, LIBRDB_COMPOSED_VERSION_STRING) == 0),
"LIBRDB_VERSION_STRING does not match the individual version components"
);
6 changes: 3 additions & 3 deletions src/lib/version.h
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
#define LIBRDB_MAJOR_VERSION 0
#define LIBRDB_MAJOR_VERSION 1
#define LIBRDB_MINOR_VERSION 0
#define LIBRDB_PATCH_VERSION 1
#define LIBRDB_PATCH_VERSION 0

/* Keep direct value for external readers */
#define LIBRDB_VERSION_STRING "0.0.1"
#define LIBRDB_VERSION_STRING "1.0.0"

/* Update Maximum supported RDB version */
#define LIBRDB_SUPPORT_MAX_RDB_VER 12
Loading