OpenSDE Framework (without history before r20070)
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

95 lines
2.1 KiB

  1. #!/bin/bash
  2. # --- T2-COPYRIGHT-NOTE-BEGIN ---
  3. # This copyright note is auto-generated by ./scripts/Create-CopyPatch.
  4. #
  5. # T2 SDE: misc/archive/regtest.sh
  6. # Copyright (C) 2006 The T2 SDE Project
  7. #
  8. # More information can be found in the files COPYING and README.
  9. #
  10. # This program is free software; you can redistribute it and/or modify
  11. # it under the terms of the GNU General Public License as published by
  12. # the Free Software Foundation; version 2 of the License. A copy of the
  13. # GNU General Public License can be found in the file COPYING.
  14. # --- T2-COPYRIGHT-NOTE-END ---
  15. # Tiny regression testsuite driver used by some core developers to track
  16. # breakage, sometimes even automated on a nightly basis.
  17. # - Rene Rebe
  18. set -e
  19. embedded=0
  20. while [ "$1" ]; do
  21. case $1 in
  22. -embedded)
  23. embedded=1
  24. ;;
  25. *) echo "Unknown option $1"
  26. exit
  27. ;;
  28. esac
  29. shift
  30. done
  31. mkdir -p regtest
  32. build()
  33. {
  34. if [ ! -e regtest/$x.finished ]; then
  35. mkdir -p config/regtest-$x
  36. cat > config/regtest-$x/config <<-EOT
  37. SDECFG_ARCH=$x
  38. SDECFG_CROSSBUILD=1
  39. SDECFG_PKG_CCACHE_USEIT=1
  40. SDECFG_ABORT_ON_ERROR_AFTER=0
  41. SDECFG_ALWAYS_CLEAN=1
  42. SDECFG_XTRACE=1
  43. SDECFG_EXPERT=1
  44. SDECFG_OPT="lazy" # slightly speed up the test builds
  45. EOT
  46. if [ $embedded -eq 1 ]; then
  47. cat >> config/regtest-$x/config <<-EOT
  48. SDECFG_TARGET='embedded'
  49. SDECFG_TARGET_EMBEDDED_STYLE='dietlibc'
  50. SDECFG_PKGSEL='1'
  51. EOT
  52. cat > config/regtest-$x/pkgsel <<-EOT
  53. O linux2*
  54. EOT
  55. fi
  56. ./scripts/Config -cfg regtest-$x -oldconfig
  57. ./scripts/Download -cfg regtest-$x -required >> regtest/$x.log 2>&1
  58. echo "Running build ..."
  59. ./scripts/Build-Target -cfg regtest-$x 2>&1 | tee regtest/$x.log |
  60. grep '> Building\|> Finished'
  61. # id=`grep SDECFG_ID config/regtest-$x/config`
  62. # eval $id
  63. touch regtest/$x.finished
  64. fi
  65. ./scripts/Create-ErrList -cfg regtest-$x | grep " builds "
  66. }
  67. for x in architecture/*/ ; do
  68. [[ $x = *share* ]] && continue
  69. x=${x#*/}; x=${x%/*}
  70. if [ $embedded -eq 1 ]; then
  71. case $x in
  72. cris|hppa*|m68k|mips64|sh*) # no diet support
  73. echo "Skipping $x (for now)"
  74. continue
  75. ;;
  76. esac
  77. fi
  78. echo "Processing $x ..."
  79. build $x
  80. done