Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!uwm.edu!gem.mps.ohio-state.edu!ginosko!uunet!nuchat!sugar!karl From: karl@sugar.hackercorp.com (Karl Lehenbauer) Newsgroups: comp.sources.d Subject: Re: v08i093: System V disk compactor Summary: patches to fast packdisk for Unix System V/3.2 Keywords: packdisk pcc patches Message-ID: <4381@sugar.hackercorp.com> Date: 18 Oct 89 01:08:02 GMT References: <69626@uunet.UU.NET> <1383@rebel.UUCP> <1989Oct12.214412.29101@ddsw1.MCS.COM> Organization: Sugar Land Unix - Houston Lines: 98 Here is a patch to the version of packdisk that was recently posted containing i286 fixes and radical performance improvements. This patch makes packdisk compile under Unix System V/386 release 3.2, and may apply to other 3.2 release. The #ifdef'ed code is activated by doing a -DI386 on the command line. Also there was a problem in that the small memory changes made the normal large memory stuff not compile. The problem was that the MB macro was not defined if large model. This is a great tool, thanks to the author and those producing patches, especially the performance improvements. Again, remember to always backup before using and run fsck before and after. -karl ---------------------------- cut here ---------------------------- *** packdisk.c.orig Tue Oct 17 20:01:28 1989 --- packdisk.c Mon Oct 16 01:25:33 1989 *************** *** 34,39 #endif #include #include #include #include #include --- 34,44 ----- #endif #include #include + #ifdef I386 + #include + #include + #include + #else #include #endif #include *************** *** 35,40 #include #include #include #include #include #include --- 40,46 ----- #include #else #include + #endif #include #include #include *************** *** 39,44 #include #include #ifndef OLDC #define FsBSIZEdev FsBSIZE(dev) #else --- 45,54 ----- #include #include + #ifdef I386 + #define ROOTINO S5ROOTINO + #endif + #ifndef OLDC #define FsBSIZEdev FsBSIZE(dev) #else *************** *** 82,87 #define MAXINT 2147483647 /* Size of an integer */ long *map; /* a map from block numbers to referencing inode/indir block */ int *ref; /* a map from block numbers to referencing inode/indir block */ #endif #ifndef OLDC --- 92,98 ----- #define MAXINT 2147483647 /* Size of an integer */ long *map; /* a map from block numbers to referencing inode/indir block */ int *ref; /* a map from block numbers to referencing inode/indir block */ + #define MB(BLN) (BLN) #endif #ifndef OLDC -- -- uunet!sugar!karl "There is hopeful symbolism in the fact that -- flags do not wave in a vacuum." -- Arthur C. Clarke -- Usenet access: (713) 438-5018