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

configure: Handle the case of SAGE_LOCAL = a system directory with gcc better #33361

Closed
mkoeppe opened this issue Feb 16, 2022 · 22 comments
Closed

Comments

@mkoeppe
Copy link
Member

mkoeppe commented Feb 16, 2022

(split out from #30845)

git grep SAGE_LOCAL src/sage shows that there are still a few leftover places in the Sage library that hardcode SAGE_LOCAL as the directory where some executables etc. are found, notably gap.

In some settings, this forces us to set SAGE_LOCAL to a system location when ideally it should ideally be unset (as in distribution packaging). In particular, in the (experimental) set up of Conda for Sage developers described in https://wiki.sagemath.org/Conda, we would set SAGE_LOCAL to CONDA_PREFIX.

We adjust the configure script for this situation.

CC: @isuruf @tobiasdiez @kiwifb @orlitzky @dimpase

Component: build: configure

Author: Matthias Koeppe

Branch/Commit: ce6f8fd

Reviewer: Dima Pasechnik

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

@mkoeppe mkoeppe added this to the sage-9.6 milestone Feb 16, 2022
@mkoeppe
Copy link
Member Author

mkoeppe commented Feb 16, 2022

@mkoeppe
Copy link
Member Author

mkoeppe commented Feb 16, 2022

Author: Matthias Koeppe

@mkoeppe
Copy link
Member Author

mkoeppe commented Feb 16, 2022

Commit: ce6f8fd

@mkoeppe
Copy link
Member Author

mkoeppe commented Feb 16, 2022

New commits:

d547541build/pkgs/gcc/spkg-configure.m4: Handle the case of SAGE_LOCAL = a system directory with gcc better
ce6f8fdbuild/pkgs/gcc/spkg-configure.m4: Handle the case of SAGE_LOCAL = a system directory with gcc better (fixup)

@mkoeppe

This comment has been minimized.

@kiwifb
Copy link
Member

kiwifb commented Feb 16, 2022

comment:4

It is difficult for me to comment on that part of the configure script from the point of view of sage-on-gentoo since I don't use it at all.

@mkoeppe
Copy link
Member Author

mkoeppe commented Feb 28, 2022

comment:6

Let's get this in please

@dimpase
Copy link
Member

dimpase commented Mar 4, 2022

comment:7

is there an easy obvious way to test this?

@mkoeppe
Copy link
Member Author

mkoeppe commented Mar 4, 2022

comment:8

"Conda for Sage developers" instructions at https://wiki.sagemath.org/Conda?

@mkoeppe
Copy link
Member Author

mkoeppe commented Mar 4, 2022

comment:9

Or use configure --prefix=/usr in a discardable VM/container

@dimpase
Copy link
Member

dimpase commented Mar 15, 2022

comment:10

Replying to @mkoeppe:

Or use configure --prefix=/usr in a discardable VM/container

just tried in a Docker container, and ran into

config.status: /usr/lib64 is not a symlink, see Trac #19782
config.status: error: Cannot perform incremental update, run "make distclean && make"

not sure if this is a bug for this branch.

@mkoeppe
Copy link
Member Author

mkoeppe commented Mar 15, 2022

comment:11

Not a bug.

@mkoeppe
Copy link
Member Author

mkoeppe commented Mar 15, 2022

comment:12

Use a different distro for testing that does not have this

@dimpase
Copy link
Member

dimpase commented Mar 15, 2022

comment:13

I'd say it is a bug in this case. Trying now with

--- a/configure.ac
+++ b/configure.ac
@@ -530,7 +530,7 @@ AC_CONFIG_COMMANDS(mkdirs,
         if test -d "$SAGE_LOCAL/lib64"; then
             if test ! -L "$SAGE_LOCAL/lib64"; then
                 AC_MSG_NOTICE([[$SAGE_LOCAL/lib64 is not a symlink, see Trac #19782]])
-                AC_MSG_ERROR([[Cannot perform incremental update, run "make distclean && make"]])
+             dnl   AC_MSG_ERROR([[Cannot perform incremental update, run "make distclean && make"]])
             fi
         else
             AC_MSG_NOTICE([[creating symbolic link lib64 -> lib]])

@dimpase
Copy link
Member

dimpase commented Mar 15, 2022

comment:14

Replying to @mkoeppe:

Not a bug.

it ought to work if we don't error out here in case of --prefix=/usr.

@mkoeppe
Copy link
Member Author

mkoeppe commented Mar 15, 2022

comment:15

... but we do not want to support this configuration for users, it's just a quick way for you to test the ticket. The actual use case is installation into a conda environment, #30845.

@dimpase
Copy link
Member

dimpase commented Mar 15, 2022

comment:16

ok, it works

@dimpase
Copy link
Member

dimpase commented Mar 15, 2022

Reviewer: Dima Pasechnik

@dimpase
Copy link
Member

dimpase commented Mar 15, 2022

comment:17

by the way, do we know how to report opensuse-tumbleweed bugs? There gphelp, a part of pari/gp, does not work.
(it doesn't seem to work on the recent homebrew, too)

@mkoeppe
Copy link
Member Author

mkoeppe commented Mar 15, 2022

comment:18

Thank you!

@mkoeppe
Copy link
Member Author

mkoeppe commented Mar 15, 2022

comment:19

Replying to @dimpase:

by the way, do we know how to report opensuse-tumbleweed bugs?

Yes, https://bugzilla.opensuse.org; so far no competent response to an issue that I reported for #33153 though

@vbraun
Copy link
Member

vbraun commented Mar 21, 2022

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

4 participants