test build

This commit is contained in:
2026-08-27 20:14:05 +02:00
parent 6a007c2cd8
commit 80a413efdc
56 changed files with 24520 additions and 0 deletions
+49
View File
@@ -0,0 +1,49 @@
/**
* @file concord-once.h
* @author Cogmasters
* @brief Initialized once
*/
#ifndef CONCORD_ONCE_H
#define CONCORD_ONCE_H
#include "concord-error.h"
/** Callback function type for user initialization */
typedef CCORDcode (*ccord_once_cb)(long flags);
/**
* @brief Register a user callback for initialization
*
* This callback will be executed exactly once during initialization
* after all internal initializations have been performed.
* Multiple callbacks can be registered from different modules, and they will
* be executed in the order they were registered.
*
* @param callback The function to call during initialization
* @param flags Flag to pass to the callback, that will be passed to the
* callback function
* @CCORD_return
*/
CCORDcode ccord_once_set_callback(ccord_once_cb callback, long flags);
/**
* @brief Initialize context once
*
* @param once Pointer to a static boolean flag that will be set to true if the
* initialization was successful. This flag should be used to ensure that
* the initialization is only performed once.
* @CCORD_return
*/
CCORDcode ccord_once(_Bool *once);
/**
* @brief Cleanup once context
*
* This function will be called to cleanup the once context.
* It will be called when the program is exiting, and it will
* cleanup all registered callbacks.
*/
void ccord_once_cleanup(void);
#endif /* CONCORD_ONCE_H */