I did compile mmeeks/ext2tools and they seem to work doing a quick test.

Instructions for compiling:
- download a zip archive from github and unpack into ext2tools (rename 
ext2tools-master)
- use djgpp (set the required environment variables etc.)
patch the mmeeks/ext2tools sources a bit:
- add "int errno;" to ep2\ep2.h
- comment out line 129 in ext2fs\llseek.c
- copy ext2_fs.h into the ext2tools\src directory (or correct the Makefile)

- then enter make in the ext2tools directory

Then do a "strip *.exe" on the generated files in the src directory.

I prefer to generate an ext2tools\bin directory:
   cp ext2tools\src\*.exe ext2tools\bin
and add cwsdpmi.exe into this bin directory.

Instructions for testing:
I did use qemu and a metados.img for this.
- add the files in the ext2tools\bin directory to the metados.img
- have an ext2 formatted hard disk image with files handy
(I did boot Linux in Qemu and used fdisk and mke2fs on a hard disk image 
plus copy some files to it)
- get qemu to boot from the metados.img floppy image and see the ext2 hard 
disk image
after DOS has booted enter at the A: prompt:
- "e2part 128" should show your ext2 formatted disk image
- "set E2DEV=/dev/sda1" to "mount" your ext2 disk for mmeeks/ext2tools
- "e2ls -l /" will list the files on the ext2 disk image
- "e2cat /foo.dat" will print the file foo.dat in root on the ext2 disk 
image onto the console
- "e2cp /foo.dat test.dat" will copy the file foo.dat from the ext2 disk 
image to the metados floppy image naming it test.dat.

You will get the warning that the cwsdpmi.swp file cannot be opened but it 
works anyway.

Currently Linux systems will use ext3/ext4 (or more) and mmeeks/ext2tools 
will not work on these since it only supports ext2.

The patches mentioned will get mmeeks/ext2tools to compile but one should 
check the warnings and see to make better patches.

Have fun!

Georg


>I think mmeeks/ext2tools is a good find, it should be easier to debug this 
>than to write something from scratch. Once done, you could port newer 
>versions of ext2tools to DOS based on this. This would bring ext3/ext4 
>support to DOS.
>
>


------------------------------------------------------------------------------
Go from Idea to Many App Stores Faster with Intel(R) XDK
Give your users amazing mobile app experiences with Intel(R) XDK.
Use one codebase in this all-in-one HTML5 development environment.
Design, debug & build mobile apps & 2D/3D high-impact games for multiple OSs.
http://pubads.g.doubleclick.net/gampad/clk?id=254741911&iu=/4140
_______________________________________________
Freedos-devel mailing list
Freedos-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/freedos-devel

Reply via email to