Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

src/bin/sage-env: Make SAGE_ROOT and SAGE_LOCAL optional #29951

Closed
mkoeppe opened this issue Jun 24, 2020 · 32 comments
Closed

src/bin/sage-env: Make SAGE_ROOT and SAGE_LOCAL optional #29951

mkoeppe opened this issue Jun 24, 2020 · 32 comments

Comments

@mkoeppe
Copy link
Contributor

mkoeppe commented Jun 24, 2020

We make SAGE_ROOT and SAGE_LOCAL optional. If one is unset, we skip setting the various environment variables that depend on it.

This change hopefully simplifies distribution packaging, with the goal of allowing unmodified scripts src/bin/sage and src/bin/sage-env to be shipped.

See also:

CC: @kiwifb @orlitzky @antonio-rojas @isuruf @tobihan @jhpalmieri @jamesjer

Component: scripts

Author: Matthias Koeppe

Branch/Commit: c8e6910

Reviewer: Dima Pasechnik, Jerry James

Issue created by migration from https://trac.sagemath.org/ticket/29951

@mkoeppe mkoeppe added this to the sage-9.2 milestone Jun 24, 2020
@mkoeppe
Copy link
Contributor Author

mkoeppe commented Jun 30, 2020

Dependencies: #25486

@mkoeppe

This comment has been minimized.

@mkoeppe
Copy link
Contributor Author

mkoeppe commented Jul 19, 2020

Changed dependencies from #25486 to #30128

@mkoeppe
Copy link
Contributor Author

mkoeppe commented Aug 12, 2020

Changed dependencies from #30128 to none

@mkoeppe

This comment has been minimized.

@mkoeppe mkoeppe changed the title src/bin/sage-env: Make sage-env-config and SAGE_LOCAL optional src/bin/sage-env: Make SAGE_ROOT and SAGE_LOCAL optional Aug 13, 2020
@mkoeppe
Copy link
Contributor Author

mkoeppe commented Aug 13, 2020

@mkoeppe

This comment has been minimized.

@mkoeppe
Copy link
Contributor Author

mkoeppe commented Aug 13, 2020

Author: Matthias Koeppe

@mkoeppe
Copy link
Contributor Author

mkoeppe commented Aug 13, 2020

New commits:

c6ed97fsrc/bin/sage-env: Make SAGE_ROOT and SAGE_LOCAL optional

@mkoeppe
Copy link
Contributor Author

mkoeppe commented Aug 13, 2020

Commit: c6ed97f

@mkoeppe

This comment has been minimized.

@mkoeppe
Copy link
Contributor Author

mkoeppe commented Aug 17, 2020

comment:10

Needs review.

@mkoeppe
Copy link
Contributor Author

mkoeppe commented Aug 22, 2020

comment:11

Hoping to get some feedback whether this change is helpful for distribution packaging

@kiwifb
Copy link
Member

kiwifb commented Aug 22, 2020

comment:12

I cannot talk about other distros. I have stopped using and shipping sage-env a while back in Gentoo. I only set the following with a patch in the sage executable these days

  • SAGE_STARTUP_FILE
  • SAGE_RC_FILE
  • SAGE_DEBUG
  • SAGE_BROWSER

For the rest, whatever is in env.py or sage_conf.py is enough.

The main issue is that a lot of stuff in there is not that useful at runtime. You need PATH properly set and a few other in case you compile something from inside sage but most of the stuff in sage-env is not useful anymore once at run-time. I guess you may want to load the sage variables if you start sage -sh but that's it.

@antonio-rojas
Copy link
Contributor

comment:13

same here, haven't installed sage-env for a long time

@mkoeppe mkoeppe modified the milestones: sage-9.2, sage-9.3 Sep 5, 2020
@sagetrac-git
Copy link
Mannequin

sagetrac-git mannequin commented Sep 12, 2020

Changed commit from c6ed97f to 53805b0

@sagetrac-git
Copy link
Mannequin

sagetrac-git mannequin commented Sep 12, 2020

Branch pushed to git repo; I updated commit sha1. This was a forced push. New commits:

53805b0src/bin/sage-env: Make SAGE_ROOT and SAGE_LOCAL optional

@sagetrac-git
Copy link
Mannequin

sagetrac-git mannequin commented Oct 2, 2020

Branch pushed to git repo; I updated commit sha1. New commits:

09584eaMerge tag '9.2.beta14' into t/29951/src_bin_sage_env__make_sage_env_config_and_sage_local_optional

@sagetrac-git
Copy link
Mannequin

sagetrac-git mannequin commented Oct 2, 2020

Changed commit from 53805b0 to 09584ea

@sagetrac-git
Copy link
Mannequin

sagetrac-git mannequin commented Oct 30, 2020

Branch pushed to git repo; I updated commit sha1. New commits:

a2571b1Merge tag '9.2' into t/29951/src_bin_sage_env__make_sage_env_config_and_sage_local_optional

@sagetrac-git
Copy link
Mannequin

sagetrac-git mannequin commented Oct 30, 2020

Changed commit from 09584ea to a2571b1

@sagetrac-git
Copy link
Mannequin

sagetrac-git mannequin commented Nov 1, 2020

Branch pushed to git repo; I updated commit sha1. New commits:

9ba8cf2Merge tag '9.3.beta0' into t/29951/src_bin_sage_env__make_sage_env_config_and_sage_local_optional

@sagetrac-git
Copy link
Mannequin

sagetrac-git mannequin commented Nov 1, 2020

Changed commit from a2571b1 to 9ba8cf2

@mkoeppe
Copy link
Contributor Author

mkoeppe commented Nov 2, 2020

comment:19

Let's get this in please, as a path toward unpatched installation of sagelib in downstream packaging.

@sagetrac-git
Copy link
Mannequin

sagetrac-git mannequin commented Nov 10, 2020

Changed commit from 9ba8cf2 to c8e6910

@sagetrac-git
Copy link
Mannequin

sagetrac-git mannequin commented Nov 10, 2020

Branch pushed to git repo; I updated commit sha1. New commits:

c8e6910Merge tag '9.3.beta1' into t/29951/src_bin_sage_env__make_sage_env_config_and_sage_local_optional

@dimpase
Copy link
Member

dimpase commented Nov 11, 2020

Reviewer: Dima Pasechnik

@dimpase
Copy link
Member

dimpase commented Nov 11, 2020

comment:22

lgtm

@jamesjer
Copy link
Mannequin

jamesjer mannequin commented Nov 11, 2020

comment:24

Thank you for thinking of distribution needs. Speaking for Fedora, I am in favor of this change.

@mkoeppe
Copy link
Contributor Author

mkoeppe commented Nov 11, 2020

comment:25

Thanks for the review!

@mkoeppe
Copy link
Contributor Author

mkoeppe commented Nov 11, 2020

Changed reviewer from Dima Pasechnik to Dima Pasechnik, Jerry James

@vbraun
Copy link
Member

vbraun commented Nov 20, 2020

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants