fsanalyze on unixpc

John B. Milton jbm at uncle.UUCP
Mon Mar 20 09:09:05 AEST 1989


In article <5375 at hcr.UUCP> john at hcr.UUCP (John R. MacMillan) writes:
>
>I know I'm a bit slow, but I just compiled fsanalyze (version 4.1 from
>comp.sources.misc) and it gives ridiculous results (wrong number of
>inodes, negative average seeks, etc.).  Before I delve into it, has
>anyone else already got it running correctly, and if so, could you
>send me the diffs?

I'll post, as this is a neat program, with not so obvious fixes. First, config
for ATT, per docs. Add -DUNIX_PC to the appropriate lines in the Makefile, then:

In fsanalyze.h, add this line before <sys/param>:

#define KERNEL /* needed for UNIXpc */
--
Find the IS_SPECIAL stuff, same file and use this version (compiler bug):
#ifdef UNIX_PC
#define IS_SPECIAL(a) \
        ( \
	((((a) & S_IFMT) == S_IFBLK) + \
        (((a) & S_IFMT) == S_IFCHR) + \
        (((a) & S_IFMT) == S_IFIFO) + \
        IS_NAM(a) + IS_LNK(a) + IS_SOK(a)) \
	!=0)
#else
--
Find the stuff in fsconfig.h and add one of these for the UNIX_PC:
#   ifdef UNIX_PC
#    define is_ok(fs) (TRUE)
#   else
--

I have off-lined the original source, or I would have posted patch food.

John
-- 
John Bly Milton IV, jbm at uncle.UUCP, n8emr!uncle!jbm at osu-cis.cis.ohio-state.edu
(614) h:294-4823, w:764-2933; AMPR: 44.70.0.52;  Don't FLAME, inform!



More information about the Unix-pc.general mailing list