Actually sorting out what goes where still needs to be done.
--- /dev/null
+/* Blue Sky: File Systems in the Cloud
+ *
+ * Copyright (C) 2009 The Regents of the University of California
+ * Written by Michael Vrable <mvrable@cs.ucsd.edu>
+ *
+ * TODO: Licensing
+ */
+
+/* Declarations internal to the BlueSky library. This header file should not
+ * be included by any users of the library (such as any filesystem
+ * proxy)--external users should only include bluesky.h. */
+
+#ifndef _BLUESKY_PRIVATE_H
+#define _BLUESKY_PRIVATE_H
+
+#include "bluesky.h"
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+BlueSkyFS *bluesky_new_fs(gchar *name);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif
BlueSkyRCStr *data; /* Pointer to data in memory if cached */
} BlueSkyBlock;
-BlueSkyFS *bluesky_new_fs(gchar *name);
BlueSkyFS *bluesky_init_fs(gchar *name, BlueSkyStore *store);
void bluesky_superblock_flush(BlueSkyFS *fs);
#include <string.h>
#include <gcrypt.h>
-#include "bluesky.h"
+#include "bluesky-private.h"
static int DISABLE_CRYPTO = 1;
#include <inttypes.h>
#include <glib.h>
-#include "bluesky.h"
+#include "bluesky-private.h"
/* Core filesystem: handling of directories. */
#include <glib.h>
#include <string.h>
-#include "bluesky.h"
+#include "bluesky-private.h"
/* Core filesystem: handling of regular files and caching of file data. */
#include <glib.h>
#include <string.h>
-#include "bluesky.h"
+#include "bluesky-private.h"
/* BlueSky library initialization. */
#include <glib.h>
#include <string.h>
-#include "bluesky.h"
+#include "bluesky-private.h"
/* Core filesystem. Different proxies, such as the NFSv3 one, interface to
* this, but the core actually tracks the data which is stored. So far we just
#include <stdint.h>
#include <glib.h>
-#include "bluesky.h"
+#include "bluesky-private.h"
/* Small test program for BlueSkyFS. Doesn't do much useful. */
#include <glib.h>
#include <string.h>
-#include "bluesky.h"
+#include "bluesky-private.h"
#include "libs3.h"
/* Interface to Amazon S3 storage. */
#include <glib.h>
#include <string.h>
-#include "bluesky.h"
+#include "bluesky-private.h"
/* Serialization of in-memory filesystem data structures to bytestrings which
* can be written to persistent storage. All data is stored in little-endian
#include <glib.h>
#include <string.h>
-#include "bluesky.h"
+#include "bluesky-private.h"
/* Interaction with cloud storage. We expose very simple GET/PUT style
* interface, which different backends can implement. Available backends
#include <glib.h>
#include <string.h>
-#include "bluesky.h"
+#include "bluesky-private.h"
/* Miscellaneous useful functions that don't really fit anywhere else. */
void register_rpc();
BlueSkyFS *fs;
+BlueSkyStore *store;
static uint8_t filesystem_key[16];
int main(int argc, char *argv[])
}
printf("\n");
- fs = bluesky_new_fs("export");
+ store = bluesky_store_new("file");
+ fs = bluesky_init_fs("export", store);
fs->encryption_key = filesystem_key;
BlueSkyInode *root;