From 758bb59ab8544901755b55eea0a50535ff6601ee Mon Sep 17 00:00:00 2001 From: Dima Pasechnik Date: Tue, 29 Jul 2025 13:23:11 -0500 Subject: [PATCH 1/3] update libsemigroups to 2.7.4 --- build/pkgs/libsemigroups/checksums.ini | 4 ++-- build/pkgs/libsemigroups/package-version.txt | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/build/pkgs/libsemigroups/checksums.ini b/build/pkgs/libsemigroups/checksums.ini index f34a1ed428d..fe85246c0df 100644 --- a/build/pkgs/libsemigroups/checksums.ini +++ b/build/pkgs/libsemigroups/checksums.ini @@ -1,4 +1,4 @@ tarball=libsemigroups-VERSION.tar.gz -sha1=9c8e73b18a4964135b63e03b2f36b874742edd62 -sha256=d4d88a11651c7d7d497f847fea97e3ff60a39b25b851c1d0d7ccf41e052612be +sha1=e3856b817638d64016ff53c84cb2c895676ae7c8 +sha256=a2d7a1e5b41360a89af0ea836cfddb4669a30516b35d4b9ff73422624ed1aa12 upstream_url=https://github.com/libsemigroups/libsemigroups/releases/download/vVERSION/libsemigroups-VERSION.tar.gz diff --git a/build/pkgs/libsemigroups/package-version.txt b/build/pkgs/libsemigroups/package-version.txt index 2c9b4ef42ec..a4dd9dba4fb 100644 --- a/build/pkgs/libsemigroups/package-version.txt +++ b/build/pkgs/libsemigroups/package-version.txt @@ -1 +1 @@ -2.7.3 +2.7.4 From 2c075bb95aa9ffaf8193e9b6fa6453daaf5a7843 Mon Sep 17 00:00:00 2001 From: Dima Pasechnik Date: Tue, 29 Jul 2025 14:48:22 -0500 Subject: [PATCH 2/3] sping GAP's semigroups package into a separate spkg --- build/pkgs/gap_packages/SPKG.rst | 28 +--------- build/pkgs/gap_packages/dependencies | 2 +- build/pkgs/gap_packages/spkg-install.in | 4 +- build/pkgs/semigroups/SPKG.rst | 61 ++++++++++++++++++++++ build/pkgs/semigroups/checksums.ini | 4 ++ build/pkgs/semigroups/dependencies | 4 ++ build/pkgs/semigroups/distros/conda.txt | 1 + build/pkgs/semigroups/distros/fedora.txt | 27 ++++++++++ build/pkgs/semigroups/distros/gentoo.txt | 1 + build/pkgs/semigroups/distros/repology.txt | 1 + build/pkgs/semigroups/math | 0 build/pkgs/semigroups/package-version.txt | 1 + build/pkgs/semigroups/spkg-install.in | 47 +++++++++++++++++ build/pkgs/semigroups/type | 1 + 14 files changed, 152 insertions(+), 30 deletions(-) create mode 100644 build/pkgs/semigroups/SPKG.rst create mode 100644 build/pkgs/semigroups/checksums.ini create mode 100644 build/pkgs/semigroups/dependencies create mode 100644 build/pkgs/semigroups/distros/conda.txt create mode 100644 build/pkgs/semigroups/distros/fedora.txt create mode 100644 build/pkgs/semigroups/distros/gentoo.txt create mode 100644 build/pkgs/semigroups/distros/repology.txt create mode 100644 build/pkgs/semigroups/math create mode 100644 build/pkgs/semigroups/package-version.txt create mode 100644 build/pkgs/semigroups/spkg-install.in create mode 100644 build/pkgs/semigroups/type diff --git a/build/pkgs/gap_packages/SPKG.rst b/build/pkgs/gap_packages/SPKG.rst index 10a952c508b..e13ad765238 100644 --- a/build/pkgs/gap_packages/SPKG.rst +++ b/build/pkgs/gap_packages/SPKG.rst @@ -173,33 +173,7 @@ Adriaan de Graaf) repsn - The package provides GAP functions for computing characteristic zero matrix representations of finite groups. (Author: Vahid Dabbaghian) -Semigroups - This is a GAP package for semigroups, and monoids. There are -particularly efficient methods for finitely presented semigroups and monoids, -and for semigroups and monoids consisting of transformations, partial -permutations, bipartitions, partitioned binary relations, subsemigroups of -regular Rees 0-matrix semigroups, and matrices of various semirings including -boolean matrices, matrices over finite fields, and certain tropical matrices. -Semigroups contains efficient methods for creating semigroups, monoids, and -inverse semigroups and monoids, calculating their Green's structure, ideals, -size, elements, group of units, small generating sets, testing membership, -finding the inverses of a regular element, factorizing elements over the -generators, and so on. It is possible to test if a semigroup satisfies a -particular property, such as if it is regular, simple, inverse, completely -regular, and a large number of further properties. There are methods for -finding presentations for a semigroup, the congruences of a semigroup, the -maximal subsemigroups of a finite semigroup, smaller degree partial -permutation representations, and the character tables of inverse semigroups. -There are functions for producing pictures of the Green's structure of a -semigroup, and for drawing graphical representations of certain types of -elements. (Authors: James Mitchell, Marina Anagnostopoulou-Merkouri, -Thomas Breuer, Stuart Burrell, Reinis Cirpons, Tom Conti-Leslie, -Joseph Edwards, Attila Egri-Nagy, Luke Elliott, Fernando Flores Brito, -Tillman Froehlich, Nick Ham, Robert Hancock, Max Horn, Christopher Jefferson, -Julius Jonusas, Chinmaya Nagpal, Olexandr Konovalov, Artemis Konstantinidi, -Hyeokjun Kwon, Dima V. Pasechnik, Markus Pfeiffer, Christopher Russell, -Jack Schmidt, Sergio Siccha, Finn Smith, Ben Spiers, Nicolas Thiéry, -Maria Tsalakou, Chris Wensley, Murray Whyte, Wilf A. Wilson, Tianrun Yang, -Michael Young and Fabian Zickgraf) +Semigroups - split out as a separate optional spkg sla - a package for doing computations with simple Lie algebras (Author: Willem Adriaan de Graaf) diff --git a/build/pkgs/gap_packages/dependencies b/build/pkgs/gap_packages/dependencies index 342d2c8edd1..36c60797391 100644 --- a/build/pkgs/gap_packages/dependencies +++ b/build/pkgs/gap_packages/dependencies @@ -1,4 +1,4 @@ -gap libsemigroups planarity | $(SAGERUNTIME) +gap planarity | $(SAGERUNTIME) ---------- All lines of this file are ignored except the first. diff --git a/build/pkgs/gap_packages/spkg-install.in b/build/pkgs/gap_packages/spkg-install.in index 2a73f074f77..300d1d69b5d 100644 --- a/build/pkgs/gap_packages/spkg-install.in +++ b/build/pkgs/gap_packages/spkg-install.in @@ -114,11 +114,11 @@ done # io : none # semigroups needs to use external libsemigroups # digraphs needs to use external planarity -pararr=( " " " " "--with-external-planarity" "--with-external-libsemigroups" ) +pararr=( " " " " "--with-external-planarity" ) ############################################################################## parind=0 -for pkg in nq io digraphs semigroups +for pkg in nq io digraphs do echo "Building GAP package $pkg" cd "$PKG_SRC_DIR/$pkg" diff --git a/build/pkgs/semigroups/SPKG.rst b/build/pkgs/semigroups/SPKG.rst new file mode 100644 index 00000000000..0e93e92a523 --- /dev/null +++ b/build/pkgs/semigroups/SPKG.rst @@ -0,0 +1,61 @@ +semigroups: An optional GAP package +=================================== + +Description +----------- + +Installing this SPKG will install the corresponding GAP package, but +before you can use them in Sage, they still have to be loaded into +either the GAP interface or libgap:: + + sage: gap.eval('LoadPackage("semigroups")') # optional - semigroups + 'true' + sage: libgap.LoadPackage("semigroups") # optional - semigroups + true + +Those correspond to:: + + gap> LoadPackage("semigroups"); + +within the GAP interface and libgap, respectively. + +Upstream Contact +---------------- + +See https://semigroups.github.io/Semigroups/ + +Dependencies +------------ + +- GAP (a standard spkg), gap_packages and libsemigroups (optional packages) + +Notes +----------- +This is a GAP package for semigroups, and monoids. There are +particularly efficient methods for finitely presented semigroups and monoids, +and for semigroups and monoids consisting of transformations, partial +permutations, bipartitions, partitioned binary relations, subsemigroups of +regular Rees 0-matrix semigroups, and matrices of various semirings including +boolean matrices, matrices over finite fields, and certain tropical matrices. +Semigroups contains efficient methods for creating semigroups, monoids, and +inverse semigroups and monoids, calculating their Green's structure, ideals, +size, elements, group of units, small generating sets, testing membership, +finding the inverses of a regular element, factorizing elements over the +generators, and so on. It is possible to test if a semigroup satisfies a +particular property, such as if it is regular, simple, inverse, completely +regular, and a large number of further properties. There are methods for +finding presentations for a semigroup, the congruences of a semigroup, the +maximal subsemigroups of a finite semigroup, smaller degree partial +permutation representations, and the character tables of inverse semigroups. +There are functions for producing pictures of the Green's structure of a +semigroup, and for drawing graphical representations of certain types of +elements. +(Authors: James Mitchell, Marina Anagnostopoulou-Merkouri, +Thomas Breuer, Stuart Burrell, Reinis Cirpons, Tom Conti-Leslie, +Joseph Edwards, Attila Egri-Nagy, Luke Elliott, Fernando Flores Brito, +Tillman Froehlich, Nick Ham, Robert Hancock, Max Horn, Christopher Jefferson, +Julius Jonusas, Chinmaya Nagpal, Olexandr Konovalov, Artemis Konstantinidi, +Hyeokjun Kwon, Dima V. Pasechnik, Markus Pfeiffer, Christopher Russell, +Jack Schmidt, Sergio Siccha, Finn Smith, Ben Spiers, Nicolas Thiéry, +Maria Tsalakou, Chris Wensley, Murray Whyte, Wilf A. Wilson, Tianrun Yang, +Michael Young and Fabian Zickgraf) diff --git a/build/pkgs/semigroups/checksums.ini b/build/pkgs/semigroups/checksums.ini new file mode 100644 index 00000000000..e5ab61704b5 --- /dev/null +++ b/build/pkgs/semigroups/checksums.ini @@ -0,0 +1,4 @@ +tarball=semigroups-VERSION.tar.gz +sha1=9bd365a9691b489989d9c652f67ed5ac011c936a +sha256=c237dd642668fd9aa5ebd7a7346467ab4261116892359d4480f0a265a91ed8d3 +upstream_url=https://github.com/semigroups/Semigroups/releases/download/vVERSION/semigroups-VERSION.tar.gz diff --git a/build/pkgs/semigroups/dependencies b/build/pkgs/semigroups/dependencies new file mode 100644 index 00000000000..c31fb6393b0 --- /dev/null +++ b/build/pkgs/semigroups/dependencies @@ -0,0 +1,4 @@ +gap gap_packages libsemigroups | $(SAGERUNTIME) + +---------- +All lines of this file are ignored except the first. diff --git a/build/pkgs/semigroups/distros/conda.txt b/build/pkgs/semigroups/distros/conda.txt new file mode 100644 index 00000000000..ea4feae733f --- /dev/null +++ b/build/pkgs/semigroups/distros/conda.txt @@ -0,0 +1 @@ +gap diff --git a/build/pkgs/semigroups/distros/fedora.txt b/build/pkgs/semigroups/distros/fedora.txt new file mode 100644 index 00000000000..24d6af73b6b --- /dev/null +++ b/build/pkgs/semigroups/distros/fedora.txt @@ -0,0 +1,27 @@ +gap-pkg-cohomolo +gap-pkg-corelg +gap-pkg-crime +gap-pkg-cryst +gap-pkg-ctbllib +gap-pkg-design +gap-pkg-factint +GAPDoc +gap-pkg-gbnp +gap-pkg-grape +gap-pkg-guava +gap-pkg-hap +gap-pkg-hapcryst +gap-pkg-hecke +gap-pkg-laguna +gap-pkg-liealgdb +gap-pkg-liepring +gap-pkg-liering +gap-pkg-loops +gap-pkg-mapclass +gap-pkg-polymaking +gap-pkg-qpa +gap-pkg-quagroup +gap-pkg-repsn +gap-pkg-sla +gap-pkg-sonata +gap-pkg-toric diff --git a/build/pkgs/semigroups/distros/gentoo.txt b/build/pkgs/semigroups/distros/gentoo.txt new file mode 100644 index 00000000000..5f1e84c0881 --- /dev/null +++ b/build/pkgs/semigroups/distros/gentoo.txt @@ -0,0 +1 @@ +dev-gap/semigroups diff --git a/build/pkgs/semigroups/distros/repology.txt b/build/pkgs/semigroups/distros/repology.txt new file mode 100644 index 00000000000..ea4feae733f --- /dev/null +++ b/build/pkgs/semigroups/distros/repology.txt @@ -0,0 +1 @@ +gap diff --git a/build/pkgs/semigroups/math b/build/pkgs/semigroups/math new file mode 100644 index 00000000000..e69de29bb2d diff --git a/build/pkgs/semigroups/package-version.txt b/build/pkgs/semigroups/package-version.txt new file mode 100644 index 00000000000..d4e50692a98 --- /dev/null +++ b/build/pkgs/semigroups/package-version.txt @@ -0,0 +1 @@ +5.5.3 diff --git a/build/pkgs/semigroups/spkg-install.in b/build/pkgs/semigroups/spkg-install.in new file mode 100644 index 00000000000..f8bda5d77a6 --- /dev/null +++ b/build/pkgs/semigroups/spkg-install.in @@ -0,0 +1,47 @@ +# Ask GAP for the directory where sysinfo.gap lives. This is to +# support system GAP installations. This root-path gathering +# command is borrowed from gap's spkg-configure.m4 and modified +# to separate the paths with spaces. +GAPRUN="gap -r -q --bare --nointeract -c" +_cmd='Display(JoinStringsWithSeparator(GAPInfo.RootPaths," "));' +GAP_ROOT_PATHS=$(${GAPRUN} "${_cmd}") + +# Loop though GAP_ROOT_PATHS looking for sysinfo.gap +GAP_ROOT="" +for grp in $GAP_ROOT_PATHS; do + if [ -f "${grp}/sysinfo.gap" ]; then + GAP_ROOT=$grp + echo "found GAP root $GAP_ROOT" + break + fi +done + +# Try the old sage default if nothing else worked. +if [ -z "$GAP_ROOT" ]; then + GAP_ROOT="$SAGE_LOCAL/lib/gap" + echo "falling back to GAP root $GAP_ROOT" +fi + +# And finally, throw an error ASAP if the build is going to fail anyway. +if [ ! -f "${GAP_ROOT}/sysinfo.gap" ]; then + sdh_die "no sysinfo.gap in your gap root" +fi + +# Where to install these packages +PKG_DIR="$SAGE_LOCAL/lib/gap/pkg" + +install_compiled_pkg() +{ + local pkg="$1" + # Install the bin/ dir (where compiled modules should end up) + # under /lib/gap; we then symlink to it later + sdh_install * "$SAGE_LOCAL/lib/gap/pkg/$pkg" +} + +# Build and install + +cd src +echo "Building GAP package semigroups" +sdh_configure --with-gaproot="$GAP_ROOT" --with-external-libsemigroups +sdh_make +install_compiled_pkg semigroups diff --git a/build/pkgs/semigroups/type b/build/pkgs/semigroups/type new file mode 100644 index 00000000000..134d9bc32d5 --- /dev/null +++ b/build/pkgs/semigroups/type @@ -0,0 +1 @@ +optional From 66fb284b01487a25a0e30d99ae9dcba0ef745ab3 Mon Sep 17 00:00:00 2001 From: Dima Pasechnik Date: Tue, 29 Jul 2025 14:18:23 -0700 Subject: [PATCH 3/3] remove obsolete comment --- build/pkgs/gap_packages/spkg-install.in | 1 - 1 file changed, 1 deletion(-) diff --git a/build/pkgs/gap_packages/spkg-install.in b/build/pkgs/gap_packages/spkg-install.in index 300d1d69b5d..c67a1176a69 100644 --- a/build/pkgs/gap_packages/spkg-install.in +++ b/build/pkgs/gap_packages/spkg-install.in @@ -112,7 +112,6 @@ done # # nq : none # io : none -# semigroups needs to use external libsemigroups # digraphs needs to use external planarity pararr=( " " " " "--with-external-planarity" ) ##############################################################################