[![Build Status](https://travis-ci.org/gkostka/lwext4.svg)](https://travis-ci.org/gkostka/lwext4)
+![lwext4](https://cloud.githubusercontent.com/assets/8606098/11697327/68306d88-9eb9-11e5-8807-81a2887f077e.png)
+
About
=====
KaHo Ng (https://github.com/ngkaho1234):
* advanced extents implementation
* xattr support
-* metadata checksum suport
+* metadata checksum support
+* journal recovery
* many bugfixes & improvements
fuse-lwext4 project:
------------
* dir_prealloc: no
* imagic_inodes: no
-* has_journal: no
+* has_journal: yes (in progress)
* ext_attr: yes
* resize_inode: no
* dir_index: yes
Project tree
=====
* blockdev - block devices set, supported blockdev
-* demos - demo directory sources
-* fs_test - test suite
+* fs_test - test suite, mkfs and demo application
* lwext4 - internals of the lwext4 library
* toolchain - specific toolchain cmake files
* CMakeLists.txt - CMake config file
Compile
=====
-Windows
+Dependencies
------------
-* CMake: http://www.cmake.org/cmake/resources/software.html
-* MinGw: http://www.mingw.org/
-* GnuWin: http://gnuwin32.sourceforge.net/
+* Windows
-Linux
-------------
-* CMake, make, gcc
+Download MSYS-2: https://sourceforge.net/projects/msys2/
-Generate makefiles
-------------
+Install required packages is MSYS2 Shell package manager:
```bash
- make
- ```
+ pacman -S make gcc cmake p7zip
+ ```
+
+* Linux
-Compile
+Package installation (Debian):
+```bash
+ apt-get install make gcc cmake p7zip
+ ```
+
+Compile & install tools
------------
```bash
+ make generic
cd build_generic
make
+ sudo make install
```
-
-Generic demo application
+lwext4-generic demo application
=====
-Simple lwext4 library presentation:
+Simple lwext4 library test application:
* load ext2/3/4 images
* load linux block device with ext2/3/4 part
* load windows volume with ext2/3/4 filesystem
How to use for images/blockdevices:
```bash
- cd build_generic
- generic -i ext_images/ext2
- generic -i ext_images/ext3
- generic -i ext_images/ext4
+ lwext4-generic -i ext_images/ext2
+ lwext4-generic -i ext_images/ext3
+ lwext4-generic -i ext_images/ext4
```
+
+Show full option set:
+```bash
+ lwext4-generic --help
+ ```
-
-Build and run automatic tests
+Run automatic tests
=====
-Build automatic test tools:
- make
- cd build_generic
- make
-Uncompress ext/2/3/4 images:
- make unpack_images
-Run server for one of the image file:
- make server_ext2
- make server_ext3
- make server_ext4
-Execute tests:
+
+Execute tests for 100MB unpacked images:
+```bash
make test
+ ```
+Execute tests for autogenerated 1GB images (only on Linux targets) + fsck:
+```bash
+ make test_all
+ ```
+Using lwext4-mkfs tool
+=====
+It is possible to create ext2/3/4 partition by internal library tool.
+
+Generate empty file (1GB):
+```bash
+ dd if=/dev/zero of=ext_image bs=1M count=1024
+ ```
+Create ext2 partition:
+```bash
+ lwext4-mkfs -i ext_image -e 2
+ ```
+Create ext3 partition:
+```bash
+ lwext4-mkfs -i ext_image -e 3
+ ```
+Create ext4 partition:
+```bash
+ lwext4-mkfs -i ext_image -e 4
+ ```
+Show full option set:
+```bash
+ lwext4-mkfs --help
+ ```
Cross compile standalone library
=====