Você não pode selecionar mais de 25 tópicos Os tópicos devem começar com uma letra ou um número, podem incluir traços ('-') e podem ter até 35 caracteres.

44 linhas
1.6KB

  1. SHELL:=/bin/bash
  2. UBUNTU_VERSION ?= 2404
  3. CODENAME ?= noble
  4. VERSION:=1.0.0
  5. build: $(CODENAME)/cppse-inotify-cpp_$(VERSION)_amd64.deb
  6. $(CODENAME)/cppse-inotify-cpp_$(VERSION)_amd64.deb:
  7. mkdir -p $(CODENAME)
  8. make ubuntu$(UBUNTU_VERSION)
  9. ubuntu$(UBUNTU_VERSION):
  10. # check out revision that is master at the time of writing
  11. git clone https://github.com/erikzenker/inotify-cpp || true
  12. pushd inotify-cpp && \
  13. git checkout 1a4413637a08f6303526a2be140806f5abaaffd5 && \
  14. popd && \
  15. bash ../ubuntu$(UBUNTU_VERSION).sh make impl
  16. make package-ubuntu$(UBUNTU_VERSION)
  17. impl:
  18. dpkg -i ../boost/cppse-boost_*.deb
  19. pushd inotify-cpp && \
  20. cmake -DCMAKE_INSTALL_PREFIX=$$PWD/../inotify-cpp_out -DBUILD_EXAMPLE=OFF -DBUILD_TEST=OFF -DBUILD_SHARED_LIBS=OFF -DBUILD_STATIC_LIBS=ON -DUSE_BOOST_FILESYSTEM=OFF -DBoost_USE_STATIC_LIBS=ON -DBOOST_ROOT="/opt/cppse/build/boost/" -DBoost_INCLUDE_DIR="/opt/cppse/build/boost/include" . && \
  21. make -j8 && \
  22. make install
  23. package-ubuntu$(UBUNTU_VERSION):
  24. rm -rf out
  25. mkdir -p out/opt/cppse/build/inotify-cpp
  26. cp -prv inotify-cpp_out/* out/opt/cppse/build/inotify-cpp/
  27. rm -rf $(CODENAME)/cppse-inotify-cpp_*_amd64.deb
  28. docker run -v "$$(pwd):/src/" rayburgemeestre/fpm-ubuntu:24.04 fpm -f -v $(VERSION) --iteration $(CODENAME) -s dir -t deb -n cppse-inotify-cpp --license MPL2 --maintainer "Ray Burgemeestre <ray@cppse.nl>" --description "inotify-cpp - build dependency" --url "https://github.com/erikzenker/inotify-cpp" --deb-generate-changes -C /src/out
  29. cp -prv cppse-inotify-cpp_*_amd64.deb $(CODENAME)/
  30. clean:
  31. sudo rm -rf inotify-cpp*
  32. sudo rm -rf out
  33. shell:
  34. FLAGS="-i --privileged" bash ../ubuntu$(UBUNTU_VERSION).sh /bin/bash