-DVERSION_MINOR=$(VERSION_MINOR) \
-DVERSION_PATCH=$(VERSION_PATCH) \
-DVERSION=$(VERSION) \
+ -DLWEXT4_BUILD_SHARED_LIB=ON \
define generate_common
rm -R -f build_$(1)
endif()
aux_source_directory(. BLOCKDEV_SRC)
-add_library(blockdev ${BLOCKDEV_SRC})
+add_library(blockdev SHARED ${BLOCKDEV_SRC})
#ifndef FILE_DEV_H_
#define FILE_DEV_H_
-#include <ext4_config.h>
-#include <ext4_blockdev.h>
+#include "ext4_config.h"
+#include "ext4_blockdev.h"
#include <stdint.h>
#include <stdbool.h>
#include <stdint.h>
#include <stddef.h>
-#include <ext4_config.h>
-#include <ext4_types.h>
-#include <ext4_errno.h>
-#include <ext4_oflags.h>
-#include <ext4_debug.h>
+#include "ext4_config.h"
+#include "ext4_types.h"
+#include "ext4_errno.h"
+#include "ext4_oflags.h"
+#include "ext4_debug.h"
-#include <ext4_blockdev.h>
+#include "ext4_blockdev.h"
/********************************OS LOCK INFERFACE***************************/
extern "C" {
#endif
-#include <ext4_config.h>
-#include <ext4_types.h>
+#include "ext4_config.h"
+#include "ext4_types.h"
-#include <ext4_fs.h>
+#include "ext4_fs.h"
#include <stdint.h>
#include <stdbool.h>
extern "C" {
#endif
-#include <ext4_config.h>
+#include "ext4_config.h"
#include <stdint.h>
#include <stdbool.h>
-#include <misc/tree.h>
-#include <misc/queue.h>
+#include "misc/tree.h"
+#include "misc/queue.h"
#define EXT4_BLOCK_ZERO() \
{.lb_id = 0, .data = 0}
extern "C" {
#endif
-#include <ext4_config.h>
+#include "ext4_config.h"
#include <stdint.h>
#include <stdbool.h>
extern "C" {
#endif
-#include <ext4_config.h>
-#include <ext4_types.h>
-#include <ext4_super.h>
+#include "ext4_config.h"
+#include "ext4_types.h"
+#include "ext4_super.h"
#include <stdint.h>
#include <stdbool.h>
extern "C" {
#endif
-#include <ext4_config.h>
-#include <ext4_bcache.h>
+#include "ext4_config.h"
+#include "ext4_bcache.h"
#include <stdbool.h>
#include <stdint.h>
extern "C" {
#endif
-#include <ext4_config.h>
+#include "ext4_config.h"
#include <stdint.h>
extern "C" {
#endif
-#include <ext4_config.h>
-#include <ext4_errno.h>
+#include "ext4_config.h"
+#include "ext4_errno.h"
#if !CONFIG_HAVE_OWN_ASSERT
#include <assert.h>
extern "C" {
#endif
-#include <ext4_config.h>
-#include <ext4_types.h>
-#include <ext4_misc.h>
-#include <ext4_blockdev.h>
-#include <ext4_super.h>
+#include "ext4_config.h"
+#include "ext4_types.h"
+#include "ext4_misc.h"
+#include "ext4_blockdev.h"
+#include "ext4_super.h"
#include <stdint.h>
extern "C" {
#endif
-#include <ext4_config.h>
-#include <ext4_types.h>
+#include "ext4_config.h"
+#include "ext4_types.h"
-#include <ext4_fs.h>
-#include <ext4_dir.h>
+#include "ext4_fs.h"
+#include "ext4_dir.h"
#include <stdint.h>
#include <stdbool.h>
extern "C" {
#endif
-#include <ext4_config.h>
+#include "ext4_config.h"
#if !CONFIG_HAVE_OWN_ERRNO
#include <errno.h>
extern "C" {
#endif
-#include <ext4_config.h>
-#include <ext4_types.h>
-#include <ext4_inode.h>
+#include "ext4_config.h"
+#include "ext4_types.h"
+#include "ext4_inode.h"
void ext4_extent_tree_init(struct ext4_inode_ref *inode_ref);
extern "C" {
#endif
-#include <ext4_config.h>
-#include <ext4_types.h>
-#include <ext4_misc.h>
+#include "ext4_config.h"
+#include "ext4_types.h"
+#include "ext4_misc.h"
#include <stdint.h>
#include <stdbool.h>
extern "C" {
#endif
-#include <ext4_config.h>
+#include "ext4_config.h"
#include <stdint.h>
extern "C" {
#endif
-#include <ext4_config.h>
-#include <ext4_types.h>
+#include "ext4_config.h"
+#include "ext4_types.h"
/**@brief Calculate and set checksum of inode bitmap.
* @param sb superblock pointer.
extern "C" {
#endif
-#include <ext4_config.h>
-#include <ext4_types.h>
+#include "ext4_config.h"
+#include "ext4_types.h"
#include <stdint.h>
extern "C" {
#endif
-#include <ext4_config.h>
-#include <ext4_types.h>
-#include <misc/queue.h>
-#include <misc/tree.h>
+#include "ext4_config.h"
+#include "ext4_types.h"
+#include "misc/queue.h"
+#include "misc/tree.h"
struct jbd_fs {
struct ext4_blockdev *bdev;
extern "C" {
#endif
-#include <ext4_config.h>
-#include <ext4_blockdev.h>
+#include "ext4_config.h"
+#include "ext4_blockdev.h"
/**@brief Master boot record block devices descriptor*/
struct ext4_mbr_bdevs {
extern "C" {
#endif
-#include <ext4_config.h>
-#include <ext4_types.h>
+#include "ext4_config.h"
+#include "ext4_types.h"
-#include <ext4_blockdev.h>
-#include <ext4_fs.h>
+#include "ext4_blockdev.h"
+#include "ext4_fs.h"
#include <stdbool.h>
#include <stdint.h>
extern "C" {
#endif
-#include <ext4_config.h>
-#include <ext4_types.h>
-#include <ext4_misc.h>
+#include "ext4_config.h"
+#include "ext4_types.h"
+#include "ext4_misc.h"
/**@brief Blocks count get stored in superblock.
* @param s superblock descriptor
extern "C" {
#endif
-#include <ext4_config.h>
-#include <ext4_types.h>
+#include "ext4_config.h"
+#include "ext4_types.h"
/**@brief Mark a buffer dirty and add it to the current transaction.
extern "C" {
#endif
-#include <ext4_config.h>
-#include <ext4_blockdev.h>
-#include <misc/tree.h>
+#include "ext4_config.h"
+#include "ext4_blockdev.h"
+#include "misc/tree.h"
#include <stddef.h>
#include <stdint.h>
extern "C" {
#endif
-#include <ext4_config.h>
-#include <ext4_types.h>
-#include <ext4_inode.h>
+#include "ext4_config.h"
+#include "ext4_types.h"
+#include "ext4_inode.h"
struct ext4_xattr_info {
uint8_t name_index;
set(AR ar)
set(OBJCOPY objcopy)
set(OBJDUMP objdump)
-set(SIZE size)
+# set(SIZE size)
set(CMAKE_C_FLAGS "-std=gnu99 -fdata-sections -ffunction-sections" CACHE INTERNAL "c compiler flags")
set(CMAKE_CXX_FLAGS "-fdata-sections -ffunction-sections" CACHE INTERNAL "cxx compiler flags")
# Name of the target
set(CMAKE_SYSTEM_NAME Windows)
-set(TOOLCHAIN_PREFIX x86_64-w64-mingw32)
+set(TOOLCHAIN_PREFIX /opt/mxe/usr/bin/x86_64-w64-mingw32.shared)
set(CMAKE_SYSTEM_PROCESSOR mingw)
# Toolchain settings
set(OBJDUMP objdump)
set(SIZE size)
-set(CMAKE_FIND_ROOT_PATH /usr/${TOOLCHAIN_PREFIX})
+set(CMAKE_FIND_ROOT_PATH /opt/mxe/usr/${TOOLCHAIN_PREFIX})
set(CMAKE_C_FLAGS "-std=gnu99 -fdata-sections -ffunction-sections" CACHE INTERNAL "c compiler flags")
set(CMAKE_CXX_FLAGS "-fdata-sections -ffunction-sections" CACHE INTERNAL "cxx compiler flags")