buildrelease.sh 489 B

123456789101112131415161718192021222324
  1. #!/bin/sh
  2. ARCH=`arch -s`
  3. DESTDIR=/usr/local/storage/dest/base/${ARCH}
  4. RELEASEDIR=/usr/local/storage/release/${ARCH}
  5. export DESTDIR
  6. export RELEASEDIR
  7. test -d "${DESTDIR}" && sudo mv "${DESTDIR}" "${DESTDIR}-" \
  8. && sudo rm -rf "${DESTDIR}-" &
  9. sudo mkdir -p "${DESTDIR}" "${RELEASEDIR}"
  10. cd /usr/src/etc && sudo nice make release
  11. if [ $? -ne 0 ]; then
  12. unset RELEASEDIR DESTDIR
  13. exit 1
  14. fi
  15. cd /usr/src/distrib/sets && sudo sh checkflist
  16. RESULT=$?
  17. unset RELEASEDIR DESTDIR
  18. exit ${RESULT}