Ви не можете вибрати більше 25 тем Теми мають розпочинатися з літери або цифри, можуть містити дефіси (-) і не повинні перевищувати 35 символів.

93 lines
3.2KB

  1. SHELL:=/bin/bash
  2. ubuntu1804:
  3. # below URL is unreliable
  4. # wget "https://dl.bintray.com/boostorg/release/1.72.0/source/boost_1_72_0.tar.bz2"
  5. #tar -xf boost_1_72_0.tar.bz2
  6. git clone --branch boost-1.73.0 --recursive https://github.com/boostorg/boost
  7. bash ../ubuntu1804.sh make impl
  8. make package-ubuntu1804
  9. ubuntu2004:
  10. git clone --branch boost-1.73.0 --recursive https://github.com/boostorg/boost
  11. bash ../ubuntu2004.sh make impl
  12. make package-ubuntu2004
  13. bash ../ubuntu2004.sh make fix_permissions
  14. impl:
  15. update-alternatives --install /usr/bin/c++ c++ /usr/bin/clang++-10 40
  16. update-alternatives --install /usr/bin/cc cc /usr/bin/clang-10 40
  17. update-alternatives --install /usr/bin/clang++ clang++ /usr/bin/clang++-10 40
  18. update-alternatives --install /usr/bin/clang clang /usr/bin/clang-10 40
  19. update-alternatives --install /usr/bin/ld ld /usr/bin/ld.lld-10 40
  20. pushd boost && \
  21. mkdir -p target && \
  22. CXX=$$(which c++) ./bootstrap.sh --prefix=$$PWD/target/ --with-toolset=clang && \
  23. ./b2 clean && \
  24. ./b2 --prefix=$$PWD/target/ toolset=clang cxxflags="-std=c++17 -stdlib=libstdc++" linkflags="-stdlib=libstdc++" --with-program_options \
  25. --with-system \
  26. --with-date_time \
  27. --with-thread \
  28. --with-chrono || true
  29. # do not use -D_GLIBCXX_USE_CXX11_ABI=0 , other libs I now compile with libstdc++ don't do it either.
  30. # with stdlib: \
  31. #./b2 --prefix=$$PWD/target/ toolset=clang cxxflags="-D_GLIBCXX_USE_CXX11_ABI=0 -stdlib=libc++ -std=c++17" linkflags="-stdlib=libc++" || true
  32. # without:
  33. #./b2 --prefix=$$PWD/target/ toolset=clang || true
  34. # ^ ||true because with clang I saw a few libraries not compile correctly, we can ignore those.
  35. #./b2 --with-program_options --prefix=$$PWD/target/ toolset=clang cxxflags="-stdlib=libc++ -std=c++17" linkflags="-stdlib=libc++"
  36. # also from; ./b2 --show-libraries && \
  37. #- atomic
  38. #- container
  39. #- context
  40. #- contract
  41. #- coroutine
  42. #- exception
  43. #- fiber
  44. #- filesystem
  45. #- graph
  46. #- graph_parallel
  47. #- headers
  48. #- iostreams
  49. #- locale
  50. #- log
  51. #- math
  52. #- mpi
  53. #- nowide
  54. #- python
  55. #- random
  56. #- regex
  57. #- serialization
  58. #- stacktrace
  59. #- test
  60. #- timer
  61. #- type_erasure
  62. #- wave
  63. package-ubuntu1804:
  64. rm -rf out
  65. mkdir -p out/opt/cppse/build/boost/include/
  66. cp -L -prv boost/stage/lib out/opt/cppse/build/boost/
  67. cp -L -prv boost/boost out/opt/cppse/build/boost/include/
  68. rm -rf boost_*_amd64.deb
  69. docker run -v "$$(pwd):/src/" rayburgemeestre/fpm-ubuntu:18.04 fpm -v 1.1 -s dir -t deb -n boost --license MPL2 --maintainer "Ray Burgemeestre <ray@cppse.nl>" --description "boost - build dependency" --url "https://github.com/liballeg/boost.git" --deb-generate-changes -C /src/out
  70. package-ubuntu2004:
  71. rm -rf out
  72. mkdir -p out/opt/cppse/build/boost/include/
  73. cp -L -prv boost/stage/lib out/opt/cppse/build/boost/
  74. cp -L -prv boost/boost out/opt/cppse/build/boost/include/
  75. rm -rf boost_*_amd64.deb
  76. docker run -v "$$(pwd):/src/" rayburgemeestre/fpm-ubuntu:20.04 fpm -v 1.1 -s dir -t deb -n boost --license MPL2 --maintainer "Ray Burgemeestre <ray@cppse.nl>" --description "boost - build dependency" --url "https://github.com/liballeg/boost.git" --deb-generate-changes -C /src/out
  77. fix_permissions:
  78. chown $$(id -u):$$(id -g) . -R
  79. clean:
  80. rm -rf boost
  81. rm -rf out
  82. shell:
  83. FLAGS="-i --privileged" bash ../ubuntu1804.sh /bin/bash