I'm trying to determine if any data corruption has occurred on my old recording archives, which include copious quantities of Sound Designer II (SD2) files. In the SD2 file format, the resource fork is as vital as the data fork, so I need to use file comparison/diff tools which check both the data and resource forks and flag changes to either.

Not surprisingly, most modern file comparison tools don't even mention the (now deprecated) resource fork in their documentation. Are any tools available which definitely scan the resource fork on HFS+ volumes?

1 Answer 1


The Eclectic Light Company offers a number of extended attribute utilities, including one named cmpxat that compares all extended attributes, including the resource fork. From what I can determine, it won't show the exact differences, but will report whether there are any differences, including whether an extended attribute exists on only one file. The current version of cmpxat always exits successfully, so to determine whether there is a difference, you'll need to check the output (which you'd need to do anyway to check whether there's a difference in the resource fork specifically).

Another option is to compare the files from the command line, appending ..namedfork/rsrc to each pathname. For example, you can get a list of differing files using find. With the files in directory $root and the archive in $archive, and assuming the directory structures are the same:

cd $root;
find . -exec diff -q {}/..namedfork/rsrc \
          "$archive"/{}/..namedfork/rsrc \; \
    | sed -e 's/^Files (.*) and .* differ/\1/'

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .