Opened 2 years ago

Last modified 5 months ago

#29924 new enhancement

sage_setup: Do not fail if sage.env, sage.* are not available

Reported by: mkoeppe Owned by:
Priority: major Milestone: sage-9.7
Component: build Keywords: sd111
Cc: Merged in:
Authors: Reviewers:
Report Upstream: N/A Work issues:
Branch: u/mkoeppe/sage_setup_without_sage_env_etc (Commits, GitHub, GitLab) Commit: cb16b915315b3535460f76ab93907ed5075fb8cb
Dependencies: #29847 Stopgaps:

Status badges

Description

... so that it can be used as a build system for the most fundamental distributions of parts of sagelib such as sage-objects, sage-categories without artificially including sage.env there (which is still done as of #29865).

This will require taking care of some dependencies:

We remove some dependencies on sage.* that are still in sage_setup:

./library_order.py:77:from sage.env import cython_aliases
./command/sage_build_cython.py:21:from sage.env import (SAGE_INC, cython_aliases, sage_include_directories)

... by handling the case that the functions sage_include_directories, cython_aliases cannot be imported from sage.env

... and removing the use of SAGE_INC by using instead the environment variables set in sage-build-env-config (this is #29855; see also #29711).

Harmless dependencies on sage.*:

./docbuild/ ........
  (will be invoked later, when sage.* is installed)
./optional_extension.py:22:from sage.misc.package import list_packages
./optional_extension.py:44:    from sage.misc.package import is_package_installed
  (no longer used, only kept around in case user packages use it)
./autogen/interpreters/__main__.py:4:from sage.env import SAGE_SRC
  (only used when invoked interactively)
./command/sage_install.py:28:        from sage.repl.ipython_kernel.install import SageKernelSpec
  (just need to make sure that `sage_setup.command.sage_install` is only used by the distribution that installs `sage.repl.ipython_kernel`)

(split out from #29847)

Change History (6)

comment:1 Changed 2 years ago by mkoeppe

  • Branch set to u/mkoeppe/sage_setup_without_sage_env_etc

comment:2 Changed 21 months ago by mkoeppe

  • Commit set to cb16b915315b3535460f76ab93907ed5075fb8cb
  • Milestone changed from sage-9.3 to sage-9.4

New commits:

bb6cc0cMerge branch 't/29785/move_extension_options_from_src_module_list_py_to__distutils___directives_in_the_individual_files__part_3__get_rid_of_uname_specific_' into t/29847/install_sage_setup_with_pip__move_sage_include_directories__cython_aliases_from_sage_env_to_sage_setup
4a9dd3aMerge branch 't/29855/sagelib_setup_py__fix_dependencies_on_header_files_of_packages_gmp__ntl' into t/29847/install_sage_setup_with_pip__move_sage_include_directories__cython_aliases_from_sage_env_to_sage_setup
f04ea03sage_setup.library_order: Do not fail if cython_aliases cannot be imported
cb16b91sage_setup.sage_build_cython: Do not fail if cython_aliases, sage_include_directories cannot be imported

comment:3 Changed 21 months ago by mkoeppe

  • Keywords sd111 added

Hoping we can make progress on this ticket this week - https://wiki.sagemath.org/days111

comment:4 Changed 13 months ago by mkoeppe

  • Milestone changed from sage-9.4 to sage-9.5

comment:5 Changed 8 months ago by mkoeppe

  • Milestone changed from sage-9.5 to sage-9.6

comment:6 Changed 5 months ago by mkoeppe

  • Milestone changed from sage-9.6 to sage-9.7
Note: See TracTickets for help on using tickets.