.travis.yml 3.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142
  1. language: c
  2. os: linux
  3. dist: trusty
  4. compiler: gcc
  5. env:
  6. global:
  7. - KERNEL_GIT="https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git"
  8. matrix:
  9. include:
  10. # Older version of the kernel
  11. # - name: "Kernel 2.6.13"
  12. # env: KERNEL_BRANCH="v2.6.13" GCC_VER="gcc-4.9"
  13. # addons:
  14. # apt:
  15. # packages:
  16. # - gcc-4.9
  17. # sources:
  18. # - ubuntu-toolchain-r-test
  19. - name: "Kernel 2.6.32"
  20. env: KERNEL_BRANCH="v2.6.32" GCC_VER="gcc-4.9"
  21. addons:
  22. apt:
  23. packages:
  24. - gcc-4.9
  25. sources:
  26. - ubuntu-toolchain-r-test
  27. - name: "Kernel 3.10.0"
  28. env: KERNEL_BRANCH="v3.10" GCC_VER="gcc-4.9"
  29. addons:
  30. apt:
  31. packages:
  32. - gcc-4.9
  33. sources:
  34. - ubuntu-toolchain-r-test
  35. # Here are actively supported kernel
  36. - name: "Kernel 3.16.y LTS"
  37. env: KERNEL_BRANCH="linux-3.16.y" GCC_VER="gcc-5"
  38. addons:
  39. apt:
  40. packages:
  41. - gcc-5
  42. sources:
  43. - ubuntu-toolchain-r-test
  44. - name: "Kernel 4.4.y LTS"
  45. env: KERNEL_BRANCH="linux-4.4.y" GCC_VER="gcc-5"
  46. addons:
  47. apt:
  48. packages:
  49. - gcc-5
  50. sources:
  51. - ubuntu-toolchain-r-test
  52. - name: "Kernel 4.9.y LTS"
  53. env: KERNEL_BRANCH="linux-4.9.y" GCC_VER="gcc-6"
  54. addons:
  55. apt:
  56. packages:
  57. - gcc-6
  58. sources:
  59. - ubuntu-toolchain-r-test
  60. - name: "Kernel 4.14.y LTS"
  61. env: KERNEL_BRANCH="linux-4.14.y" GCC_VER="gcc-7"
  62. addons:
  63. apt:
  64. packages:
  65. - libelf-dev
  66. - gcc-7
  67. sources:
  68. - ubuntu-toolchain-r-test
  69. - name: "Kernel 4.19.y LTS"
  70. env: KERNEL_BRANCH="linux-4.19.y" GCC_VER="gcc-7"
  71. addons:
  72. apt:
  73. packages:
  74. - libelf-dev
  75. - gcc-7
  76. sources:
  77. - ubuntu-toolchain-r-test
  78. - name: "Kernel 5.4.y LTS"
  79. env: KERNEL_BRANCH="linux-5.4.y" GCC_VER="gcc-8"
  80. addons:
  81. apt:
  82. packages:
  83. - libelf-dev
  84. - gcc-8
  85. sources:
  86. - ubuntu-toolchain-r-test
  87. # Stable versions
  88. - name: "Kernel 5.7.y STABLE"
  89. env: KERNEL_BRANCH="linux-5.7.y" GCC_VER="gcc-8"
  90. addons:
  91. apt:
  92. packages:
  93. - libelf-dev
  94. - gcc-8
  95. sources:
  96. - ubuntu-toolchain-r-test
  97. - name: "Kernel 5.8.y STABLE"
  98. env: KERNEL_BRANCH="linux-5.8.y" GCC_VER="gcc-8"
  99. addons:
  100. apt:
  101. packages:
  102. - libelf-dev
  103. - gcc-8
  104. sources:
  105. - ubuntu-toolchain-r-test
  106. allow_failures:
  107. - name: "Kernel 5.8.y STABLE"
  108. # Here checkout kernels
  109. before_script:
  110. - eval "export CC=${GCC_VER}"
  111. - eval "${CC} --version"
  112. - git clone ${KERNEL_GIT} --depth=1 --branch=${KERNEL_BRANCH} ${KERNEL_BRANCH}
  113. - pushd .
  114. - cd $KERNEL_BRANCH
  115. - yes "" | make oldconfig CC=${GCC_VER}
  116. - make prepare CC=${GCC_VER}
  117. - make scripts CC=${GCC_VER}
  118. - popd
  119. # Now build with kernel sources
  120. script:
  121. - make KDIR=${PWD}/${KERNEL_BRANCH} CC=${GCC_VER}
  122. # Not sure if I should cache the kernel source tree...
  123. #cache:
  124. # directories:
  125. # - '$HOME/.sonar/cache'