acquire.sh 694 B

123456789101112131415161718192021222324252627
  1. #!/bin/bash
  2. set -e
  3. # Create sources directory
  4. mkdir -p sources
  5. # Download bzip2 source
  6. echo "Downloading bzip2-1.0.8 source..."
  7. wget -O sources/bzip2-1.0.8.tar.gz https://www.sourceware.org/pub/bzip2/bzip2-1.0.8.tar.gz
  8. # Download bzip2 documentation patch
  9. echo "Downloading bzip2 documentation patch..."
  10. wget -O sources/bzip2-1.0.8-install_docs-1.patch https://www.linuxfromscratch.org/patches/lfs/12.4/bzip2-1.0.8-install_docs-1.patch
  11. # Extract source code
  12. echo "Extracting bzip2 source..."
  13. cd sources
  14. tar -xzf bzip2-1.0.8.tar.gz
  15. # Copy patch to source directory
  16. cp bzip2-1.0.8-install_docs-1.patch bzip2-1.0.8/
  17. # Clean up
  18. rm bzip2-1.0.8.tar.gz
  19. cd ..
  20. echo "Source acquisition complete."