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.

60 line
2.3KB

  1. SHELL:=/bin/bash
  2. UBUNTU_VERSION ?= 2404
  3. CODENAME ?= noble
  4. VERSION:=1.0.2
  5. build: $(CODENAME)/cppse-caf_$(VERSION)_amd64.deb
  6. $(CODENAME)/cppse-caf_$(VERSION)_amd64.deb:
  7. mkdir -p $(CODENAME)
  8. make caf
  9. caf:
  10. git clone https://github.com/actor-framework/actor-framework || true
  11. pushd actor-framework && git checkout 1.0.2
  12. bash ../ubuntu$(UBUNTU_VERSION).sh make impl
  13. make package
  14. impl:
  15. switch-to-latest-clang
  16. pushd actor-framework && \
  17. CXX="$(which c++)" ./configure --cxx-flags="-stdlib=libstdc++" --disable-shared-libs --prefix=$$PWD/caf_out && \
  18. echo patch CMakeLists.txt ../caf-cmakefile.patch && \
  19. mkdir -p build && \
  20. pushd build && \
  21. cmake -DCAF_LOG_LEVEL=TRACE -DCMAKE_INSTALL_PREFIX=$$PWD/caf_out .. && \
  22. DO_NOT_SPECIFY_CMAKE_CXX_FLAGS_HERE="" make -j $$(nproc) && \
  23. make install
  24. # works: CXX="$(which c++)" ./configure --cxx-flags="-stdlib=libc++" --disable-shared-libs --prefix=$$PWD/caf_out && \
  25. # changed to libstdc++ (the gnu version)
  26. # until my question is answered here: https://groups.google.com/forum/#!topic/v8-users/Do5MvAvYFgs
  27. # i will not use libc++
  28. #
  29. # was: CMAKE_CXX_FLAGS="-std=c++17 -stdlib=libc++" make -j $$(nproc) && \
  30. # CMAKE_CXX_FLAGS="-std=c++17 -stdlib=libc++ -DGLIBCXX_USE_CXX11_ABI=1 -D_GLIBCXX_USE_CXX11_ABI=1" make -j $$(nproc) && \
  31. #-DCAF_NO_AUTO_LIBCPP=yes \
  32. #GLIBCXX_USE_CXX11_ABI=1 CMAKE_CXX_FLAGS="-std=c++17 -stdlib=libc++" make -j $$(nproc) && \
  33. #make install
  34. #CMAKE_CXX_FLAGS="-std=c++17 -stdlib=libc++" make -j $$(nproc) && \
  35. package:
  36. rm -rf out
  37. mkdir -p out/opt/cppse/build/caf
  38. cp -prv actor-framework/build/caf_out/* out/opt/cppse/build/caf/
  39. # workaround for https://groups.google.com/forum/#!topic/actor-framework/xOmdVFRD7lc
  40. # cp -prv actor-framework/build/caf/detail/build_config.hpp out/opt/cppse/build/caf/include/caf/detail/
  41. rm -rf $(CODENAME)/cppse-caf_*_amd64.deb
  42. docker run -v "$$(pwd):/src/" rayburgemeestre/fpm-ubuntu:24.04 fpm -f -v $(VERSION) --iteration $(CODENAME) -s dir -t deb -n cppse-caf --license MPL2 --maintainer "Ray Burgemeestre <ray@cppse.nl>" --description "caf - build dependency" --url "https://github.com/liballeg/caf.git" --deb-generate-changes -C /src/out
  43. cp -prv cppse-caf_*_amd64.deb $(CODENAME)/
  44. clean:
  45. rm -rf actor-framework
  46. rm -rf out
  47. shell:
  48. FLAGS="-i --privileged" bash ../ubuntu$(UBUNTU_VERSION).sh /bin/bash