2 # This file and its contents are supplied under the terms of the
3 # Common Development and Distribution License ("CDDL"), version 1.0.
4 # You may only use this file in accordance with the terms of version
7 # A full copy of the text of the CDDL should have accompanied this
8 # source. A copy of the CDDL is also available via the Internet at
9 # http://www.illumos.org/license/CDDL.
13 # Copyright 2023 Marcel Telka
17 # Rename section 1 man page(s) to contain version number
18 COMPONENT_POST_INSTALL_ACTION += \
19 for f in $(PROTOUSRSHAREMAN1DIR)/*.1 ; do \
20 [[ -f $$f ]] || continue ; \
21 for v in $(PYTHON_VERSIONS) ; do \
22 [[ "$$f" == "$${f%%$$v.1}" ]] || continue 2 ; \
24 $(MV) $$f $${f%%.1}-$(PYTHON_VERSION).1 ; \
27 # This project does not support tox so we need to provide test requirements
29 TEST_REQUIREMENTS_EXTRAS += test
31 # Random temporary file name
32 COMPONENT_TEST_TRANSFORMS += "-e 's|\(/tmp/tmp\).\{8\}\.py|\1XXXXXXXX.py|'"
34 # Create mediated symlinks
35 printf '<transform file path=(usr/share/man/man1/)([^/]+)-(3\\.\\d+)\\.1$ -> emit link path=%%<1>%%<2>.1 target=%%<2>-%%<3>.1 mediator=python mediator-version=%%<3> >\n' >> "$DISTRIBUTION-PYVER.p5m"