initial commit

Signed-off-by: Ian Moffett <ian@mirocom.org>
This commit is contained in:
2026-03-21 06:15:27 -04:00
commit 0fa8ad12ca
8 changed files with 190 additions and 0 deletions

17
include/common/knobs.h Normal file
View File

@@ -0,0 +1,17 @@
/*
* Copyright (c) 2026, Mirocom Laboratories
* Provided under the BSD-3 clause
*
* Abstract:
* This header defines settings related to quips operation.
* Author:
* Ian M. Moffett <ian@mirocom.org>
*/
#ifndef COMMON_KNOBS_H
#define COMMON_KNOBS_H 1
#define QUIP_VERSION "0.0.1"
#define QUIP_FILEPATH "build.quip"
#endif /* !_COMMON_KNOBS_H_ */

43
include/common/state.h Normal file
View File

@@ -0,0 +1,43 @@
/*
* Copyright (c) 2026, Mirocom Laboratories
* Provided under the BSD-3 clause
*
* Abstract:
* This header defines the quip state machine
* Author:
* Ian M. Moffett <ian@mirocom.org>
*/
#ifndef COMMON_STATE_H
#define COMMON_STATE_H 1
#include <stdint.h>
#include <stddef.h>
/*
* Represents the build state machine
*
* @in_fd: Input file descriptor of build file
* @line_num: Current line number
*/
struct quip_state {
int in_fd;
size_t line_num;
};
/*
* Initialize the quip state machine
*
* @build_file: Path to build file
* @state: State instance to initialize
*
* Returns zero on success
*/
int quip_state_init(const char *build_file, struct quip_state *state);
/*
* Destroy a quip state
*/
void quip_state_destroy(struct quip_state *state);
#endif /* !COMMON_STATE_H */