Skip to content

Merge pynac sources as src/sage/symbolic/ginac #32386

@mkoeppe

Description

@mkoeppe

Pynac has a compile-time dependency on the Python library but is not installed using Python package infrastructure. This is problematic because Python users cannot install it using standard Python tools - for example for testing different Python versions.

Pynac has no other uses than as the core of the symbolic expressions facility of Sage; and cannot even be tested without Sage.

We merge Pynac (i.e., the directory https://github.com/pynac/pynac/tree/master/ginac) into the Sage library as src/sage/symbolic/ginac. It is not a very big package - one flat directory with 100 *.h and *.cpp files, a total of 50kLOC. (The existing !Python/Cython symbolics code in sage.symbolic, sage.calculus, sage.functions is about 60kLOC.)

The Pynac sources are compiled like other C++ sources that are already in the Sage source tree. They are linked into a single Python extension module, sage.symbolic.expression. All other extension modules that used to link to pynac (sage.libs.pynac.pynac, sage.symbolic.function, sage.symbolic.series etc.) are

This solves the same issues that #30534 tried to address, which ran into unresolved technical difficulties.

It will also make it easier for Sage developers to make changes to Pynac and the related symbolic implementation.

Follow-up: #32387 Remove pynac spkg

Depends on #32391
Depends on #32407
Depends on #32461

CC: @kliem @kiwifb @antonio-rojas @DaveWitteMorris @slel @dimpase @tscrim @egourgoulhon @nbruin

Component: symbolics

Author: Matthias Koeppe, Jonathan Kliem

Branch: 0d0b58f

Reviewer: Dima Pasechnik

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

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions