__init__.py 1.0 KB

12345678910111213141516171819202122232425262728293031323334353637
  1. import os.path
  2. from devtools.yamaker.modules import GLOBAL
  3. from devtools.yamaker.project import CMakeNinjaNixProject
  4. def post_install(self):
  5. with self.yamakes["."] as snappy:
  6. # snappy is patched to support TString
  7. snappy.NO_UTIL = False
  8. # At the time, contrib/libs/snappy goes to ADDINCL GLOBAL
  9. # due to presense in INTERFACE_INCLUDE_DIRECTORIES.txt.
  10. #
  11. # Replacing it with ADDINCL to newly generate inclink directory.
  12. snappy.ADDINCL = [GLOBAL(os.path.join(self.arcdir, "include"))]
  13. snappy.PEERDIR.add("library/cpp/sanitizer/include")
  14. snappy = CMakeNinjaNixProject(
  15. owners=["g:cpp-contrib"],
  16. arcdir="contrib/libs/snappy",
  17. nixattr="snappy",
  18. platform_dispatchers=["config.h"],
  19. inclink={
  20. "include": [
  21. "snappy.h",
  22. "snappy-c.h",
  23. "snappy-sinksource.h",
  24. "snappy-stubs-public.h",
  25. ]
  26. },
  27. # Do not install unittests
  28. install_targets=["snappy"],
  29. post_install=post_install,
  30. )