Skip to content
GitLab
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
  • Kea Kea
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 559
    • Issues 559
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 62
    • Merge requests 62
  • Deployments
    • Deployments
    • Releases
  • Packages and registries
    • Packages and registries
    • Container Registry
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Commits
  • Issue Boards
Collapse sidebar
  • ISC Open Source ProjectsISC Open Source Projects
  • KeaKea
  • Merge requests
  • !1881

Set a deterministic path for installed Kea python files

  • Review changes

  • Download
  • Email patches
  • Plain diff
Merged Andrei Pavel requested to merge 2669-set-a-deterministic-path-for-installed-kea-python-files into master Jan 03, 2023
  • Overview 11
  • Commits 2
  • Pipelines 0
  • Changes 3

Closes #2669 (closed).

Explanation of changes:

  • Moved PYTHON_PREFIX and PYTHON_EXEC_PREFIX to configure.ac. They are there for MacOS compatibility. See Kea issue 2012. My reasoning was that as long as we set them, it should affect all python files. We don't have any others than kea-shell at the moment, but it's good to address future issues caused by forgetting to set them when other python scripts are added. It would be great if this could be tested on MacOS.
  • Reduced the list of python interpreters to the ones containing at most the major version, in order of preference. This is because distributions are starting to get python3.10 and above, and we can't tractably address all of the major+minor combinations. The 2.7+ version constraint is still enforced by AM_PATH_PYTHON([2.7]).
  • Used with_site_packages value in AC_ARG_WITH. The previous pythondir and pkgpythondir values that were used, are also set by AM_PATH_PYTHON.
  • The distinction above is necessary to add a fix default value for pythondir: pythondir="${prefix}/lib/python${PYTHON_VERSION}/site-packages". This is the originally intended fix.
  • --with-site-packages didn't work before. I think the lack of distinction above had something to do with it. That is - if the flag was mentioned, the python files were not installed at the given location. I kindly ask the reviewer to verify this. The command cycle is short and can be repeated with celerity for testing purposes: git clean -dffx .; autoreconf -fi; ./configure --enable-shell [--with-site-packages=...]; make install -C src/bin/shell. If the solution gets accepted, I'd like to change the description of the issue to also say that this has fixed --with-site-packages.
  • Exanded pythondir instead of PKGPYTHONDIR so that everything based on pythondir also ends up expanded. This made more sense during development, but now it's equivalent to the prior behavior. I still prefer it this way and would keep it, but I don't insist.
Edited Jan 04, 2023 by Andrei Pavel
Assignee
Assign to
Reviewers
Request review from
Time tracking
Source branch: 2669-set-a-deterministic-path-for-installed-kea-python-files