diff --git a/.gitignore b/.gitignore index 43f58abcafe..0e00d5965b4 100644 --- a/.gitignore +++ b/.gitignore @@ -223,6 +223,7 @@ build/bin/sage-build-env-config /pkgs/sagemath-categories/pyproject.toml /pkgs/sagemath-environment/pyproject.toml /pkgs/sagemath-repl/pyproject.toml +/pkgs/sagemath-standard/pyproject.toml /pkgs/sagemath-objects/requirements.txt /pkgs/sagemath-bliss/requirements.txt /pkgs/sagemath-coxeter3/requirements.txt diff --git a/pkgs/sagemath-standard/pyproject.toml b/pkgs/sagemath-standard/pyproject-monolithic.toml similarity index 100% rename from pkgs/sagemath-standard/pyproject.toml rename to pkgs/sagemath-standard/pyproject-monolithic.toml diff --git a/pkgs/sagemath-standard/pyproject-monolithic.toml.m4 b/pkgs/sagemath-standard/pyproject-monolithic.toml.m4 new file mode 120000 index 00000000000..25dbae84866 --- /dev/null +++ b/pkgs/sagemath-standard/pyproject-monolithic.toml.m4 @@ -0,0 +1 @@ +../../src/pyproject.toml.m4 \ No newline at end of file diff --git a/pkgs/sagemath-standard/pyproject.toml.m4 b/pkgs/sagemath-standard/pyproject.toml.m4 deleted file mode 120000 index 25dbae84866..00000000000 --- a/pkgs/sagemath-standard/pyproject.toml.m4 +++ /dev/null @@ -1 +0,0 @@ -../../src/pyproject.toml.m4 \ No newline at end of file diff --git a/pkgs/sagemath-standard/pyproject.toml.m4 b/pkgs/sagemath-standard/pyproject.toml.m4 new file mode 100644 index 00000000000..f96a5c18ca8 --- /dev/null +++ b/pkgs/sagemath-standard/pyproject.toml.m4 @@ -0,0 +1,30 @@ +[build-system] +# Minimum requirements for the build system to execute. +requires = [ + "sage_setup[autogen]", + # Some version of sage-conf is required. + # Note that PEP517/518 have no notion of optional sage_spkg dependencies: + # https://github.com/pypa/pip/issues/6144 + esyscmd(`sage-get-system-packages install-requires-toml \ + sage_conf \ + setuptools \ + wheel \ + sage_setup \ + sagemath_environment \ + cypari \ + cysignals \ + cython \ + gmpy2 \ + jinja2 \ + jupyter_core \ + numpy \ + pkgconfig \ + pplpy \ + memory_allocator \ + ')] +build-backend = "setuptools.build_meta" + +[tool.conda-lock] +platforms = [ + 'osx-64', 'linux-64', 'linux-aarch64', 'osx-arm64' +] diff --git a/pkgs/sagemath-standard/setup.py b/pkgs/sagemath-standard/setup.py index 7f6318a0fa0..bf121ead51b 100755 --- a/pkgs/sagemath-standard/setup.py +++ b/pkgs/sagemath-standard/setup.py @@ -28,9 +28,6 @@ ### Set source directory ######################################################### -# PEP 517 builds do not have . in sys.path -sys.path.insert(0, os.path.dirname(__file__)) - import sage.env sage.env.SAGE_SRC = os.getcwd() from sage.env import * diff --git a/src/MANIFEST.in b/src/MANIFEST.in index 07a135dbf07..5b2fe278ecd 100644 --- a/src/MANIFEST.in +++ b/src/MANIFEST.in @@ -7,6 +7,8 @@ prune sage_setup prune sage_docbuild prune doc +exclude pyproject-monolithic* + # # Most C and C++ files are generated by Cython and should not # be included in the sdist.