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

pkgconf: Update to 1.8.0, remove runtime dep on environment variable SAGE_LOCAL #29779

Closed
mkoeppe opened this issue Jun 2, 2020 · 23 comments
Closed

Comments

@mkoeppe
Copy link
Contributor

mkoeppe commented Jun 2, 2020

(from #29411)

We upgrade pkgconf from the ancient version 0.9.7 and make it work outside of sage-env.

CC: @orlitzky @dimpase @vbraun

Component: packages: standard

Keywords: sd111

Author: Matthias Koeppe

Branch/Commit: 9c123af

Reviewer: Dima Pasechnik

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

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

comment:2

It looks like we can specify the *.pc file location at build time using --with-pkg-config-dir:

https://github.com/pkgconf/pkgconf/blob/master/configure.ac

Afterwards, we can probably just symlink pkgconf to "pkg-config", and then rely on PATH to choose the right one.

@orlitzky
Copy link
Contributor

comment:3

src/bin/sage-env already prepends the sage-specific *.pc file path to PKG_CONFIG_PATH in case the system pkg-config is used. From pkgconf's spkg-configure.m4:

AS_IF([test -z "$ac_cv_path_PKGCONF"], [
   sage_spkg_install_pkgconf=yes
   AC_SUBST(SAGE_PKG_CONFIG_PATH, [''])
   AC_MSG_RESULT([installing pkgconf spkg])], [
dnl the following as needed as long as Sage creates .pc files during build and/or configure
   AC_SUBST(SAGE_PKG_CONFIG_PATH, ['$SAGE_LOCAL/lib/pkgconfig'])
   AC_MSG_RESULT([using pkg-config from the system])
])

Then in sage-env,

if [ -n "$SAGE_PKG_CONFIG_PATH" ]; then
    # set up external pkg-config to look into SAGE_LOCAL/lib/pkgconfig/
    # (Sage's pkgconf spkg takes care of this, if installed)
    export PKG_CONFIG_PATH="$SAGE_PKG_CONFIG_PATH${PKG_CONFIG_PATH:+:$PKG_CONFIG_PATH}"
fi

So we "shouldn't" be hurt by ditching the pkgconf wrapper script and hard-coding the full list of paths into pkgconf at build time.

@mkoeppe
Copy link
Contributor Author

mkoeppe commented Jul 14, 2020

comment:4

Sounds right to me

@mkoeppe mkoeppe modified the milestones: sage-9.2, sage-9.3 Oct 24, 2020
@mkoeppe
Copy link
Contributor Author

mkoeppe commented Dec 6, 2020

Changed keywords from none to sd111

@mkoeppe
Copy link
Contributor Author

mkoeppe commented Dec 6, 2020

comment:6

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

@mkoeppe
Copy link
Contributor Author

mkoeppe commented Mar 24, 2021

comment:7

Sage development has entered the release candidate phase for 9.3. Setting a new milestone for this ticket based on a cursory review of ticket status, priority, and last modification date.

@mkoeppe mkoeppe modified the milestones: sage-9.3, sage-9.4 Mar 24, 2021
@mkoeppe
Copy link
Contributor Author

mkoeppe commented May 27, 2021

comment:8

Any progress here?

@mkoeppe mkoeppe modified the milestones: sage-9.4, sage-9.5 Jul 19, 2021
@mkoeppe mkoeppe modified the milestones: sage-9.5, sage-9.6 Dec 18, 2021
@mkoeppe mkoeppe modified the milestones: sage-9.6, sage-9.7 Apr 7, 2022
@mkoeppe
Copy link
Contributor Author

mkoeppe commented Apr 27, 2022

comment:12

@orlitzky, it sounds like you have some free time. Care to work on this ticket?

@orlitzky
Copy link
Contributor

comment:13

I never wanted to work on it in the first place. pkg-config is a standard, stable, system utility that's available everywhere. We should delete the SPKG and require that the user have it installed. Treadmill tickets like these are a complete waste of time, but not mine.

@mkoeppe mkoeppe changed the title pkg-config installed from SPKG pkgconf should not depend on environment variable SAGE_LOCAL pkgconf: Update to 1.8.0, remove runtime dep on environment variable SAGE_LOCAL May 9, 2022
@mkoeppe
Copy link
Contributor Author

mkoeppe commented May 9, 2022

@mkoeppe
Copy link
Contributor Author

mkoeppe commented May 9, 2022

Author: Matthias Koeppe

@mkoeppe

This comment has been minimized.

@mkoeppe
Copy link
Contributor Author

mkoeppe commented May 9, 2022

New commits:

eeb61dfbuild/pkgs/pkgconf: Update to 1.8.0
0e26f83build/pkgs/pkgconf: Use SAGE_LOCAL at build time, not run time

@mkoeppe
Copy link
Contributor Author

mkoeppe commented May 9, 2022

Commit: 0e26f83

@dimpase
Copy link
Member

dimpase commented May 11, 2022

comment:17

there are changes of $SAGE_LOCAL to unprefixed by $. What does it do - if it was to be substituted I'd expect @SAGE_LOCAL@?

@mkoeppe
Copy link
Contributor Author

mkoeppe commented May 11, 2022

comment:18

These are resolved as m4 macros - see the m4 invocation in spkg-postinst.in

@sagetrac-git
Copy link
Mannequin

sagetrac-git mannequin commented May 19, 2022

Changed commit from 0e26f83 to 9c123af

@sagetrac-git
Copy link
Mannequin

sagetrac-git mannequin commented May 19, 2022

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

9c123afbuild/pkgs/sagelib/spkg-install: Poison SAGE_LOCAL

@mkoeppe
Copy link
Contributor Author

mkoeppe commented Jun 26, 2022

comment:20

Let's get this in please

@dimpase
Copy link
Member

dimpase commented Jun 28, 2022

comment:21

lgtm

@dimpase
Copy link
Member

dimpase commented Jun 28, 2022

Reviewer: Dima Pasechnik

@mkoeppe
Copy link
Contributor Author

mkoeppe commented Jun 28, 2022

comment:22

Thanks!

@vbraun
Copy link
Member

vbraun commented Jul 3, 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