Du kannst nicht mehr als 25 Themen auswählen Themen müssen entweder mit einem Buchstaben oder einer Ziffer beginnen. Sie können Bindestriche („-“) enthalten und bis zu 35 Zeichen lang sein.
 
 
 

52 Zeilen
1.7 KiB

  1. #!/bin/csh
  2. setenv TARGET amd64
  3. setenv MAKEOBJDIRPREFIX /tmp/${TARGET}-objdir
  4. setenv __MAKE_CONF /dev/null
  5. setenv DESTDIR /tmp/${TARGET}-kernel
  6. @ __freebsd_mk_jobs = `sysctl -n kern.smp.cpus` + 1
  7. set current_dir = `pwd`
  8. set _current_dir = `echo ${current_dir} | sed -e 's|\(.*/\)\(.*\.git\)\(/.*\)*|\2|g'`
  9. set _current_realdir = `echo ${current_dir} | sed -e 's|\(.*/\)\(.*\.git\)\(/.*\)*|\1/\2|g'`
  10. set _check_toolchain = "${MAKEOBJDIRPREFIX}/___kernel-toolchain_DONE"
  11. set _date=`date "+%Y%m%d%H%M%S"`
  12. set _log="/tmp/${TARGET}-cc-log-${_current_dir}-${_date}"
  13. set _log_last="/tmp/${TARGET}-cc-log-${_current_dir}.last"
  14. set _KERNCONF="OP-HBSD"
  15. if ( "`sysctl -n security.bsd.hardlink_check_uid`" == "1" ) then
  16. echo "build will fail, due to hard security checks"
  17. echo "sysctl security.bsd.hardlink_check_uid=0"
  18. exit
  19. endif
  20. if ( "`sysctl -n security.bsd.hardlink_check_gid`" == "1" ) then
  21. echo "build will fail, due to hard security checks"
  22. echo "sysctl security.bsd.hardlink_check_gid=0"
  23. exit
  24. endif
  25. if ( (${_current_dir} != "hardenedBSD.git")) then
  26. if ((${_current_dir} != "opBSD.git")) then
  27. set _current_dir = "hardenedBSD.git"
  28. endif
  29. endif
  30. echo "build source dir: ${_current_dir}"
  31. sleep 1
  32. if ( ! -d $MAKEOBJDIRPREFIX ) then
  33. mkdir $MAKEOBJDIRPREFIX
  34. endif
  35. ln -sf ${_log} ${_log_last}
  36. if ( ! -f ${_check_toolchain} ) then
  37. (cd /usr/data/source/git/opBSD/${_current_dir}; make -j$__freebsd_mk_jobs -DNO_ROOT KERNCONF=${_KERNCONF} kernel-toolchain) |& tee ${_log} || exit
  38. touch ${_check_toolchain}
  39. else
  40. echo "skip make kernel-toolchain"
  41. sleep 1
  42. endif
  43. (cd /usr/data/source/git/opBSD/${_current_dir}; make -j$__freebsd_mk_jobs -DNO_ROOT KERNCONF=${_KERNCONF} kernel) |& tee -a ${_log}