hook-avro.py 981 B

123456789101112131415161718192021222324252627
  1. # ------------------------------------------------------------------
  2. # Copyright (c) 2020 PyInstaller Development Team.
  3. #
  4. # This file is distributed under the terms of the GNU General Public
  5. # License (version 2.0 or later).
  6. #
  7. # The full license is available in LICENSE, distributed with
  8. # this software.
  9. #
  10. # SPDX-License-Identifier: GPL-2.0-or-later
  11. # ------------------------------------------------------------------
  12. """
  13. Avro is a serialization and RPC framework.
  14. """
  15. import os
  16. from PyInstaller.utils.hooks import get_module_file_attribute
  17. res_loc = os.path.dirname(get_module_file_attribute("avro"))
  18. # see https://github.com/apache/avro/blob/master/lang/py3/setup.py
  19. datas = [
  20. # Include the version.txt file, used to set __version__
  21. (os.path.join(res_loc, "VERSION.txt"), "avro"),
  22. # The handshake schema is needed for IPC communication
  23. (os.path.join(res_loc, "HandshakeRequest.avsc"), "avro"),
  24. (os.path.join(res_loc, "HandshakeResponse.avsc"), "avro"),
  25. ]