#ifndef PROTOTYPE1_SRC_L1_SYSTEM_FSMANIP_H
#define PROTOTYPE1_SRC_L1_SYSTEM_FSMANIP_H

/* For posix */
#include <sys/stat.h>
#include <errno.h>
#include "../core/util.h"

/* Aborts on error */
void mkdir_nofail(const char* filename) {
    int ret = mkdir(filename, S_IRWXU | S_IRGRP | S_IXGRP);
    if (ret < 0 && errno != EEXIST)
        abortf("Unable to create directory   %s\n", filename);
}


#endif
