/* OS glue functions declaration <_PDCLIB_glue.h>12This file is part of the Public Domain C Library (PDCLib).3Permission is granted to use, modify, and / or redistribute at will.4*/56#ifndef __PDCLIB_GLUE_H7#define __PDCLIB_GLUE_H __PDCLIB_GLUE_H89#include "_PDCLIB_int.h"10#include "_PDCLIB_io.h"1112#include <stdbool.h>13#include <stddef.h>1415#ifdef __cplusplus16extern "C" {17#endif1819/* -------------------------------------------------------------------------- */20/* OS "glue", part 2 */21/* These are the functions you will have to touch, as they are where PDCLib */22/* interfaces with the operating system. */23/* They operate on data types partially defined by _PDCLIB_config.h. */24/* -------------------------------------------------------------------------- */2526/* stdlib.h */2728/* A system call that terminates the calling process, returning a given status29to the environment.30*/31_PDCLIB_noreturn void _PDCLIB_Exit( int status );3233void *_PDCLIB_sbrk( size_t n );3435/* stdio.h */3637/* Open the file with the given name and mode. Return the file descriptor in38* *fd and a pointer to the operations structure in **ops on success.39*40* Return true on success and false on failure.41*/42bool _PDCLIB_open(43_PDCLIB_fd_t* fd, const _PDCLIB_fileops_t** ops,44char const * filename, unsigned int mode );4546/* A system call that removes a file identified by name. Return zero on success,47non-zero otherwise.48*/49int _PDCLIB_remove( const char * filename );5051/* A system call that renames a file from given old name to given new name.52Return zero on success, non-zero otherwise. In case of failure, the file53must still be accessible by old name. Any handling of open files etc. is54done by standard rename() already.55*/56int _PDCLIB_rename( const char * old, const char * newn);5758#ifdef __cplusplus59}60#endif6162#endif636465