patching file Makefile gcc -fpic -fPIC -Wall -Winline -O2 -g -D_FILE_OFFSET_BITS=64 -c blocksort.c gcc -fpic -fPIC -Wall -Winline -O2 -g -D_FILE_OFFSET_BITS=64 -c huffman.c gcc -fpic -fPIC -Wall -Winline -O2 -g -D_FILE_OFFSET_BITS=64 -c crctable.c gcc -fpic -fPIC -Wall -Winline -O2 -g -D_FILE_OFFSET_BITS=64 -c randtable.c gcc -fpic -fPIC -Wall -Winline -O2 -g -D_FILE_OFFSET_BITS=64 -c compress.c gcc -fpic -fPIC -Wall -Winline -O2 -g -D_FILE_OFFSET_BITS=64 -c decompress.c gcc -fpic -fPIC -Wall -Winline -O2 -g -D_FILE_OFFSET_BITS=64 -c bzlib.c In function 'mainSort': blocksort.c:347:6: warning: inlining failed in call to 'mainGtU.part.0': call is unlikely and code size would grow [-Winline] Bool mainGtU ( UInt32 i1, ^ cc1: warning: called from here [-Winline] blocksort.c:347:6: warning: inlining failed in call to 'mainGtU.part.0': call is unlikely and code size would grow [-Winline] Bool mainGtU ( UInt32 i1, ^ cc1: warning: called from here [-Winline] blocksort.c:347:6: warning: inlining failed in call to 'mainGtU.part.0': call is unlikely and code size would grow [-Winline] Bool mainGtU ( UInt32 i1, ^ cc1: warning: called from here [-Winline] gcc -shared -Wl,-soname -Wl,libbz2.so.1.0 -o libbz2.so.1.0.6 blocksort.o huffman.o crctable.o randtable.o compress.o decompress.o bzlib.o gcc -fpic -fPIC -Wall -Winline -O2 -g -D_FILE_OFFSET_BITS=64 -o bzip2-shared bzip2.c libbz2.so.1.0.6 bzip2.c: In function 'testStream': bzip2.c:557:37: warning: variable 'nread' set but not used [-Wunused-but-set-variable] Int32 bzerr, bzerr_dummy, ret, nread, streamNo, i; ^ rm -f libbz2.so.1.0 ln -s libbz2.so.1.0.6 libbz2.so.1.0 rm -f *.o libbz2.a bzip2 bzip2recover \ sample1.rb2 sample2.rb2 sample3.rb2 \ sample1.tst sample2.tst sample3.tst gcc -Wall -Winline -O2 -g -D_FILE_OFFSET_BITS=64 -c huffman.c gcc -Wall -Winline -O2 -g -D_FILE_OFFSET_BITS=64 -c crctable.c gcc -Wall -Winline -O2 -g -D_FILE_OFFSET_BITS=64 -c randtable.c If compilation produces errors, or a large number of warnings, please read README.COMPILATION.PROBLEMS -- you might be able to adjust the flags in this Makefile to improve matters. Also in README.COMPILATION.PROBLEMS are some hints that may help if your build produces an executable which is unable to correctly handle so-called 'large files' -- files of size 2GB or more. gcc -Wall -Winline -O2 -g -D_FILE_OFFSET_BITS=64 -c blocksort.c gcc -Wall -Winline -O2 -g -D_FILE_OFFSET_BITS=64 -c compress.c gcc -Wall -Winline -O2 -g -D_FILE_OFFSET_BITS=64 -c decompress.c gcc -Wall -Winline -O2 -g -D_FILE_OFFSET_BITS=64 -c bzlib.c In function 'mainSort': blocksort.c:347:6: warning: inlining failed in call to 'mainGtU.part.0': call is unlikely and code size would grow [-Winline] Bool mainGtU ( UInt32 i1, ^ cc1: warning: called from here [-Winline] blocksort.c:347:6: warning: inlining failed in call to 'mainGtU.part.0': call is unlikely and code size would grow [-Winline] Bool mainGtU ( UInt32 i1, ^ cc1: warning: called from here [-Winline] blocksort.c:347:6: warning: inlining failed in call to 'mainGtU.part.0': call is unlikely and code size would grow [-Winline] Bool mainGtU ( UInt32 i1, ^ cc1: warning: called from here [-Winline] gcc -Wall -Winline -O2 -g -D_FILE_OFFSET_BITS=64 -c bzip2.c bzip2.c: In function 'testStream': bzip2.c:557:37: warning: variable 'nread' set but not used [-Wunused-but-set-variable] Int32 bzerr, bzerr_dummy, ret, nread, streamNo, i; ^ gcc -Wall -Winline -O2 -g -D_FILE_OFFSET_BITS=64 -c bzip2recover.c gcc -Wall -Winline -O2 -g -D_FILE_OFFSET_BITS=64 -o bzip2recover bzip2recover.o rm -f libbz2.a ar cq libbz2.a blocksort.o huffman.o crctable.o randtable.o compress.o decompress.o bzlib.o ranlib libbz2.a gcc -Wall -Winline -O2 -g -D_FILE_OFFSET_BITS=64 -o bzip2 bzip2.o -L. -lbz2 Doing 6 tests (3 compress, 3 uncompress) ... If there's a problem, things might stop at this point. ./bzip2 -1 < sample1.ref > sample1.rb2 ./bzip2 -2 < sample2.ref > sample2.rb2 ./bzip2 -3 < sample3.ref > sample3.rb2 ./bzip2 -d < sample1.bz2 > sample1.tst ./bzip2 -d < sample2.bz2 > sample2.tst ./bzip2 -ds < sample3.bz2 > sample3.tst cmp sample1.bz2 sample1.rb2 cmp sample2.bz2 sample2.rb2 cmp sample3.bz2 sample3.rb2 cmp sample1.tst sample1.ref cmp sample2.tst sample2.ref cmp sample3.tst sample3.ref If you got this far and the 'cmp's didn't complain, it looks like you're in business. To install in /usr/local/bin, /usr/local/lib, /usr/local/man and /usr/local/include, type make install To install somewhere else, eg, /xxx/yyy/{bin,lib,man,include}, type make install PREFIX=/xxx/yyy If you are (justifiably) paranoid and want to see what 'make install' is going to do, you can first do make -n install or make -n install PREFIX=/xxx/yyy respectively. The -n instructs make to show the commands it would execute, but not actually execute them. Instructions for use are in the preformatted manual page, in the file bzip2.txt. For more detailed documentation, read the full manual. It is available in Postscript form (manual.ps), PDF form (manual.pdf), and HTML form (manual.html). You can also do "bzip2 --help" to see some helpful information. "bzip2 -L" displays the software license. if ( test ! -d /usr/bin ) ; then mkdir -p /usr/bin ; fi if ( test ! -d /usr/lib ) ; then mkdir -p /usr/lib ; fi if ( test ! -d /usr/share/man ) ; then mkdir -p /usr/share/man ; fi if ( test ! -d /usr/share/man/man1 ) ; then mkdir -p /usr/share/man/man1 ; fi if ( test ! -d /usr/share/doc/bzip2-1.0.6 ) ; then mkdir -p /usr/share/doc/bzip2-1.0.6; fi if ( test ! -d /usr/include ) ; then mkdir -p /usr/include ; fi cp -f bzip2 /usr/bin/bzip2 cp -f bzip2 /usr/bin/bunzip2 cp -f bzip2 /usr/bin/bzcat cp -f bzip2recover /usr/bin/bzip2recover chmod a+x /usr/bin/bzip2 chmod a+x /usr/bin/bunzip2 chmod a+x /usr/bin/bzcat chmod a+x /usr/bin/bzip2recover cp -f bzip2.1 /usr/share/man/man1 chmod a+r /usr/share/man/man1/bzip2.1 cp -f bzlib.h /usr/include chmod a+r /usr/include/bzlib.h cp -f libbz2.a /usr/lib chmod a+r /usr/lib/libbz2.a cp -f bzgrep /usr/bin/bzgrep ln -s -f bzgrep /usr/bin/bzegrep ln -s -f bzgrep /usr/bin/bzfgrep chmod a+x /usr/bin/bzgrep cp -f bzmore /usr/bin/bzmore ln -s -f bzmore /usr/bin/bzless chmod a+x /usr/bin/bzmore cp -f bzdiff /usr/bin/bzdiff ln -s -f bzdiff /usr/bin/bzcmp chmod a+x /usr/bin/bzdiff cp -f bzgrep.1 bzmore.1 bzdiff.1 /usr/share/man/man1 chmod a+r /usr/share/man/man1/bzgrep.1 chmod a+r /usr/share/man/man1/bzmore.1 chmod a+r /usr/share/man/man1/bzdiff.1 echo ".so man1/bzgrep.1" > /usr/share/man/man1/bzegrep.1 echo ".so man1/bzgrep.1" > /usr/share/man/man1/bzfgrep.1 echo ".so man1/bzmore.1" > /usr/share/man/man1/bzless.1 echo ".so man1/bzdiff.1" > /usr/share/man/man1/bzcmp.1 cp -f manual.html /usr/share/doc/bzip2-1.0.6 cp -f manual.pdf /usr/share/doc/bzip2-1.0.6 cp -f manual.ps /usr/share/doc/bzip2-1.0.6 cp -f bzip2.txt /usr/share/doc/bzip2-1.0.6 chmod a+r /usr/share/doc/bzip2-1.0.6/manual.html chmod a+r /usr/share/doc/bzip2-1.0.6/manual.pdf chmod a+r /usr/share/doc/bzip2-1.0.6/manual.ps chmod a+r /usr/share/doc/bzip2-1.0.6/bzip2.txt 'bzip2-shared' -> '/bin/bzip2' 'libbz2.so.1.0' -> '/lib/libbz2.so.1.0' 'libbz2.so.1.0.6' -> '/lib/libbz2.so.1.0.6' '/usr/lib/libbz2.so' -> '../../lib/libbz2.so.1.0' removed '/usr/bin/bunzip2' removed '/usr/bin/bzcat' removed '/usr/bin/bzip2' '/bin/bunzip2' -> 'bzip2' '/bin/bzcat' -> 'bzip2' real 0m5.315s user 0m11.622s sys 0m0.299s