f3
f3 copied to clipboard
Porting f3probe and f3fix to other platforms
When will f3probe and f3fix be available for mac?
Non-Linux developers, please step in.
I'm a Linux-only developer.
While we're at it, I wonder if anyone could do something similar for android. Where I live, many people don't have access to desktop computers.
Actually I had no problems compiling it for OS X Yosemite. I am using macports.
Hi @yozik04,
Could you document the steps you followed? It'll help other Mac users.
Nothing specific:
- git clone https://github.com/AltraMayor/f3.git
- cd f3
- make
- ./f3read ...
Ahh. You were asking about experimental features. I got it wrong. No I do not have solution for that. Sorry...
I get error on make experimental
cc -std=c99 -Wall -Wextra -pedantic -MMD -ggdb -c -o libdevs.o libdevs.c
libdevs.c:19:10: fatal error: 'linux/fs.h' file not found
#include <linux/fs.h>
Looking at http://www.manpages.info/macosx/fs.5.html it seems there should be a ufs/fs.h
but I doubt it's compatible.
Looks like one OS X application included linux/fs.h
: https://github.com/sv99/dosfstools-osx/blob/master/include/linux/fs.h . Perhaps you can try doing the same.
In last version of Fedora I can make extra without error but after make install I only have f3write and f3read, anybody can help me?
make install
only installs f3write and f3read. Use make install-extra
for the extra applications.
Just for information, I created a f3 port for MacPorts: for the standard f3 tools: https://trac.macports.org/browser/trunk/dports/sysutils/f3/Portfile
So if you have MacPorts, installing f3 is now as easy as calling "ports install f3".
I didn't look into the experimental and extra tools though.
Hi @ocroquette,
Thank you for the contribution! If you want to issue a pull request to update the README file with the news, I'll quickly merge it.
Sure, here you go: https://github.com/ocroquette/f3/pull/1
Hi @ocroquette,
The changes you've made to the README file are great, but the pull request you issued is against your own repository, not mine. Could you reissue the pull request against my repository, so I can merge it?
Ups, sorry, I hope I did it right this time: https://github.com/AltraMayor/f3/pull/54
Merged. Thank you, @ocroquette!
I've written a quick hack in Python that fills flash drive with data - https://github.com/techtonik/discovery/blob/master/disk/check/h2test.py - it is public domain, so maybe it will inspire somebody for alternative implementation.
Forget it. I just realized that f3fix
and f3probe
is not f3write
.
forgive my ignorance, but isn't it as simple as writing to the /dev/disk device until you hit the end of file and then read and compare?
If f3probe
did that, it wouldn't be as fast as it is. The algorithm of f3probe
isn't straightforward, but you can think of it as a game in which f3probe
asks a lot of questions of the drive to see if the drive gives an answer that is inconsistent with the previous answers.
Very bad it's not possible to install f3prob et f3fix on Mac OS X. I try to fix with f3write and fread keeping bad files and hiddening. But there is much space lost and it doesn't work very well. If somebody have solution, i'm very interested because i bought 20 stick USB 64 Go in FOREST USB and they have all errors with very bad chipset or memory. It's necessary to fix bad clusters. So when i want install extra i have : $ make install-extra cc -std=c99 -Wall -Wextra -pedantic -MMD -ggdb -I/usr/local/include -c -o libdevs.o libdevs.c libdevs.c:19:10: fatal error: 'linux/fs.h' file not found #include <linux/fs.h> ^ 1 error generated. make: *** [libdevs.o] Error 1
So how is it possible to have missing fs.h and where is that file waited ? Thank you for help.
Not a fix, but you can always install Debian or some other supported OS in a VM on Mac. That's what I ended up doing, and it worked well.