{"id":13560162,"url":"https://github.com/gap-system/gap","last_synced_at":"2026-01-17T01:16:50.359Z","repository":{"id":27781516,"uuid":"31270208","full_name":"gap-system/gap","owner":"gap-system","description":"Main development repository for GAP - Groups, Algorithms, Programming, a System for Computational Discrete Algebra","archived":false,"fork":false,"pushed_at":"2025-10-20T12:57:06.000Z","size":440847,"stargazers_count":913,"open_issues_count":497,"forks_count":175,"subscribers_count":37,"default_branch":"master","last_synced_at":"2025-10-21T20:50:36.277Z","etag":null,"topics":["algebra","computer-algebra","computer-algebra-system","discrete-mathematics","group-theory","math","mathematics","representation-theory"],"latest_commit_sha":null,"homepage":"https://www.gap-system.org","language":"GAP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/gap-system.png","metadata":{"files":{"readme":"README.buildsys.md","changelog":"CHANGES.md","contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":"CITATION","codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":"COPYRIGHT","agents":null,"dco":null,"cla":null}},"created_at":"2015-02-24T16:47:50.000Z","updated_at":"2025-10-20T12:57:08.000Z","dependencies_parsed_at":"2023-01-17T01:00:22.925Z","dependency_job_id":"c9adb489-d64d-4465-b88d-1894821e4fbc","html_url":"https://github.com/gap-system/gap","commit_stats":{"total_commits":9327,"total_committers":70,"mean_commits":"133.24285714285713","dds":0.5343626031950253,"last_synced_commit":"d284d81f318fd482aaecd139de86b841123df803"},"previous_names":[],"tags_count":125,"template":false,"template_full_name":null,"purl":"pkg:github/gap-system/gap","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gap-system%2Fgap","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gap-system%2Fgap/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gap-system%2Fgap/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gap-system%2Fgap/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/gap-system","download_url":"https://codeload.github.com/gap-system/gap/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gap-system%2Fgap/sbom","scorecard":{"id":418547,"data":{"date":"2025-08-11","repo":{"name":"github.com/gap-system/gap","commit":"ced173041690a4af06c073088d01cc40b2574fb0"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":4.8,"checks":[{"name":"Code-Review","score":9,"reason":"Found 23/24 approved changesets -- score normalized to 9","details":null,"documentation":{"short":"Determines if the project requires human code review before pull requests (aka merge requests) are merged.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#code-review"}},{"name":"Maintained","score":10,"reason":"30 commit(s) and 16 issue activity found in the last 90 days -- score normalized to 10","details":null,"documentation":{"short":"Determines if the project is \"actively maintained\".","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#maintained"}},{"name":"Packaging","score":-1,"reason":"packaging workflow not detected","details":["Warn: no GitHub/GitLab publishing workflow detected."],"documentation":{"short":"Determines if the project is published as a package that others can easily download, install, easily update, and uninstall.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#packaging"}},{"name":"Dangerous-Workflow","score":10,"reason":"no dangerous workflow patterns detected","details":null,"documentation":{"short":"Determines if the project's GitHub Action workflows avoid dangerous patterns.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#dangerous-workflow"}},{"name":"Security-Policy","score":0,"reason":"security policy file not detected","details":["Warn: no security policy file detected","Warn: no security file to analyze","Warn: no security file to analyze","Warn: no security file to analyze"],"documentation":{"short":"Determines if the project has published a security policy.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#security-policy"}},{"name":"CII-Best-Practices","score":2,"reason":"badge detected: InProgress","details":null,"documentation":{"short":"Determines if the project has an OpenSSF (formerly CII) Best Practices Badge.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#cii-best-practices"}},{"name":"License","score":10,"reason":"license file detected","details":["Info: project has a license file: LICENSE:0","Info: FSF or OSI recognized license: GNU General Public License v2.0: LICENSE:0"],"documentation":{"short":"Determines if the project has defined a license.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#license"}},{"name":"Token-Permissions","score":0,"reason":"detected GitHub workflow tokens with excessive permissions","details":["Warn: no topLevel permission defined: .github/workflows/CI.yml:1","Warn: no topLevel permission defined: .github/workflows/gapjl.yml:1","Warn: no topLevel permission defined: .github/workflows/lint.yml:1","Warn: no topLevel permission defined: .github/workflows/release.yml:1","Info: topLevel 'contents' permission set to 'read': .github/workflows/update-gh-pages.yml:16","Info: no jobLevel write permissions found"],"documentation":{"short":"Determines if the project's workflows follow the principle of least privilege.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#token-permissions"}},{"name":"Signed-Releases","score":0,"reason":"Project has not signed or included provenance with any releases.","details":["Warn: release artifact v4.14.0 not signed: https://api.github.com/repos/gap-system/gap/releases/189140798","Warn: release artifact v4.14.0-beta1 not signed: https://api.github.com/repos/gap-system/gap/releases/185478124","Warn: release artifact v4.13.1 not signed: https://api.github.com/repos/gap-system/gap/releases/160281668","Warn: release artifact v4.13.0 not signed: https://api.github.com/repos/gap-system/gap/releases/146781085","Warn: release artifact v4.13.0-alpha2 not signed: https://api.github.com/repos/gap-system/gap/releases/142589587","Warn: release artifact v4.14.0 does not have provenance: https://api.github.com/repos/gap-system/gap/releases/189140798","Warn: release artifact v4.14.0-beta1 does not have provenance: https://api.github.com/repos/gap-system/gap/releases/185478124","Warn: release artifact v4.13.1 does not have provenance: https://api.github.com/repos/gap-system/gap/releases/160281668","Warn: release artifact v4.13.0 does not have provenance: https://api.github.com/repos/gap-system/gap/releases/146781085","Warn: release artifact v4.13.0-alpha2 does not have provenance: https://api.github.com/repos/gap-system/gap/releases/142589587"],"documentation":{"short":"Determines if the project cryptographically signs release artifacts.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#signed-releases"}},{"name":"Branch-Protection","score":-1,"reason":"internal error: error during GetBranch(stable-4.11): error during branchesHandler.query: internal error: githubv4.Query: Resource not accessible by integration","details":null,"documentation":{"short":"Determines if the default and release branches are protected with GitHub's branch protection settings.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#branch-protection"}},{"name":"Binary-Artifacts","score":10,"reason":"no binaries found in the repo","details":null,"documentation":{"short":"Determines if the project has generated executable (binary) artifacts in the source repository.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#binary-artifacts"}},{"name":"Fuzzing","score":0,"reason":"project is not fuzzed","details":["Warn: no fuzzer integrations found"],"documentation":{"short":"Determines if the project uses fuzzing.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#fuzzing"}},{"name":"Vulnerabilities","score":5,"reason":"5 existing vulnerabilities detected","details":["Warn: Project is vulnerable to: PYSEC-2014-14 / GHSA-652x-xj99-gmcc","Warn: Project is vulnerable to: GHSA-9hjg-9r4m-mvj7","Warn: Project is vulnerable to: GHSA-9wx4-h78v-vm56","Warn: Project is vulnerable to: PYSEC-2014-13 / GHSA-cfj3-7x9c-4p3h","Warn: Project is vulnerable to: PYSEC-2018-28 / GHSA-x84v-xcm2-53pg"],"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#vulnerabilities"}},{"name":"Pinned-Dependencies","score":0,"reason":"dependency not pinned by hash detected -- score normalized to 0","details":["Warn: third-party GitHubAction not pinned by hash: .github/workflows/CI.yml:292: update your workflow using https://app.stepsecurity.io/secureworkflow/gap-system/gap/CI.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/CI.yml:302: update your workflow using https://app.stepsecurity.io/secureworkflow/gap-system/gap/CI.yml/master?enable=pin","Warn: third-party GitHubAction not pinned by hash: .github/workflows/CI.yml:331: update your workflow using https://app.stepsecurity.io/secureworkflow/gap-system/gap/CI.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/CI.yml:368: update your workflow using https://app.stepsecurity.io/secureworkflow/gap-system/gap/CI.yml/master?enable=pin","Warn: third-party GitHubAction not pinned by hash: .github/workflows/CI.yml:379: update your workflow using https://app.stepsecurity.io/secureworkflow/gap-system/gap/CI.yml/master?enable=pin","Warn: third-party GitHubAction not pinned by hash: .github/workflows/CI.yml:414: update your workflow using https://app.stepsecurity.io/secureworkflow/gap-system/gap/CI.yml/master?enable=pin","Warn: third-party GitHubAction not pinned by hash: .github/workflows/CI.yml:422: update your workflow using https://app.stepsecurity.io/secureworkflow/gap-system/gap/CI.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/CI.yml:144: update your workflow using https://app.stepsecurity.io/secureworkflow/gap-system/gap/CI.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/CI.yml:147: update your workflow using https://app.stepsecurity.io/secureworkflow/gap-system/gap/CI.yml/master?enable=pin","Warn: third-party GitHubAction not pinned by hash: .github/workflows/CI.yml:151: update your workflow using https://app.stepsecurity.io/secureworkflow/gap-system/gap/CI.yml/master?enable=pin","Warn: third-party GitHubAction not pinned by hash: .github/workflows/CI.yml:237: update your workflow using https://app.stepsecurity.io/secureworkflow/gap-system/gap/CI.yml/master?enable=pin","Warn: third-party GitHubAction not pinned by hash: .github/workflows/CI.yml:251: update your workflow using https://app.stepsecurity.io/secureworkflow/gap-system/gap/CI.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/CI.yml:257: update your workflow using https://app.stepsecurity.io/secureworkflow/gap-system/gap/CI.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/CI.yml:268: update your workflow using https://app.stepsecurity.io/secureworkflow/gap-system/gap/CI.yml/master?enable=pin","Warn: third-party GitHubAction not pinned by hash: .github/workflows/CI.yml:279: update your workflow using https://app.stepsecurity.io/secureworkflow/gap-system/gap/CI.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/gapjl.yml:47: update your workflow using https://app.stepsecurity.io/secureworkflow/gap-system/gap/gapjl.yml/master?enable=pin","Warn: third-party GitHubAction not pinned by hash: .github/workflows/gapjl.yml:51: update your workflow using https://app.stepsecurity.io/secureworkflow/gap-system/gap/gapjl.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/lint.yml:18: update your workflow using https://app.stepsecurity.io/secureworkflow/gap-system/gap/lint.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/lint.yml:20: update your workflow using https://app.stepsecurity.io/secureworkflow/gap-system/gap/lint.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/release.yml:38: update your workflow using https://app.stepsecurity.io/secureworkflow/gap-system/gap/release.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/release.yml:41: update your workflow using https://app.stepsecurity.io/secureworkflow/gap-system/gap/release.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/release.yml:71: update your workflow using https://app.stepsecurity.io/secureworkflow/gap-system/gap/release.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/release.yml:97: update your workflow using https://app.stepsecurity.io/secureworkflow/gap-system/gap/release.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/release.yml:147: update your workflow using https://app.stepsecurity.io/secureworkflow/gap-system/gap/release.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/release.yml:156: update your workflow using https://app.stepsecurity.io/secureworkflow/gap-system/gap/release.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/release.yml:191: update your workflow using https://app.stepsecurity.io/secureworkflow/gap-system/gap/release.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/release.yml:202: update your workflow using https://app.stepsecurity.io/secureworkflow/gap-system/gap/release.yml/master?enable=pin","Warn: third-party GitHubAction not pinned by hash: .github/workflows/release.yml:208: update your workflow using https://app.stepsecurity.io/secureworkflow/gap-system/gap/release.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/release.yml:234: update your workflow using https://app.stepsecurity.io/secureworkflow/gap-system/gap/release.yml/master?enable=pin","Warn: third-party GitHubAction not pinned by hash: .github/workflows/release.yml:242: update your workflow using https://app.stepsecurity.io/secureworkflow/gap-system/gap/release.yml/master?enable=pin","Warn: third-party GitHubAction not pinned by hash: .github/workflows/release.yml:264: update your workflow using https://app.stepsecurity.io/secureworkflow/gap-system/gap/release.yml/master?enable=pin","Warn: third-party GitHubAction not pinned by hash: .github/workflows/release.yml:272: update your workflow using https://app.stepsecurity.io/secureworkflow/gap-system/gap/release.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/update-gh-pages.yml:44: update your workflow using https://app.stepsecurity.io/secureworkflow/gap-system/gap/update-gh-pages.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/update-gh-pages.yml:56: update your workflow using https://app.stepsecurity.io/secureworkflow/gap-system/gap/update-gh-pages.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/update-gh-pages.yml:70: update your workflow using https://app.stepsecurity.io/secureworkflow/gap-system/gap/update-gh-pages.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/update-gh-pages.yml:84: update your workflow using https://app.stepsecurity.io/secureworkflow/gap-system/gap/update-gh-pages.yml/master?enable=pin","Warn: pipCommand not pinned by hash: .github/workflows/lint.yml:25","Warn: pipCommand not pinned by hash: .github/workflows/release.yml:47","Warn: pipCommand not pinned by hash: .github/workflows/release.yml:48","Warn: pipCommand not pinned by hash: .github/workflows/release.yml:102","Info:   0 out of  22 GitHub-owned GitHubAction dependencies pinned","Info:   0 out of  14 third-party GitHubAction dependencies pinned","Info:   0 out of   4 pipCommand dependencies pinned"],"documentation":{"short":"Determines if the project has declared and pinned the dependencies of its build process.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#pinned-dependencies"}},{"name":"SAST","score":0,"reason":"SAST tool is not run on all commits -- score normalized to 0","details":["Warn: 0 commits out of 30 are checked with a SAST tool"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#sast"}}]},"last_synced_at":"2025-08-19T00:34:17.081Z","repository_id":27781516,"created_at":"2025-08-19T00:34:17.081Z","updated_at":"2025-08-19T00:34:17.081Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":280333493,"owners_count":26312845,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-10-21T02:00:06.614Z","response_time":58,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["algebra","computer-algebra","computer-algebra-system","discrete-mathematics","group-theory","math","mathematics","representation-theory"],"created_at":"2024-08-01T13:00:38.573Z","updated_at":"2025-10-21T20:51:07.662Z","avatar_url":"https://github.com/gap-system.png","language":"GAP","readme":"# The GAP build system\n\nThis file is meant to give an overview of how the GAP build system works. It\nis targeted at people who need to work on the build system itself (to extend\nit, fixes bugs in it, etc.). It should not be necessary to read this if all\nyou want to do is compile GAP and work on the GAP library and kernel.\n\nNote that this really is just an overview; for details, please refer to the\ncomments inside the various parts of the build system.\n\n\n## Prerequisites\n\nIn order to work on the build system, you need at least the following:\n\n* GNU autoconf (we recommend 2.69 or later)\n* GNU make\n\nNote that we extensively use features provided by GNU make, so in general\nanother version of make, such as BSD make, is not suitable.\n\n\n## Quick start: building GAP with no frills\n\nIf you are working with a fresh clone of the GAP repository, you need to\nrun the `autogen.sh` script first, which will generate the `configure`\nscript. Afterwards, or if you are using a release version of GAP, you\ncan follow the standard procedure:\n\n    ./configure\n    make\n\n\n== Overview of the files constituting the GAP build system\n\n* `autogen.sh`: sets up the build system; typically the first thing to run in\n  a fresh clone of the GAP repository. It runs `autoconf` and `autoheader`.\n\n* `configure`: generated by `autogen.sh` from `configure.ac`.\n\n* `configure.ac`: the GNU autoconf source of our configure script.\n\n* `GNUmakefile`, `GNUmakefile.in`: The former file is generated from the\n  latter by `configure`. It is the primary Makefile (GNU make prefers it\n  over `Makefile`). It only contains variables and vpath settings, and\n  includes `Makefile.rules` for the actual build rules.\n\n* `Makefile`: This is a placeholder file, and serves two purposes:\n   1. If the user runs `make` before `configure`, it prints a warning.\n   2. If `configure` did run, but `make` is not GNU make, it produces\n      a corresponding error message.\n\n* `Makefile.rules`: This is the core of the build system. If you want\n  to add or remove a kernel C source file, you need to add or remove\n  its name here and only here.\n\n* `cnf/`: All files in this directory are part of the build system.\n\n* `extern/`: External libraries we bundle with GAP (such as GMP) are\n  put in here.\n\n* `build/`: Generated code (such as `config.h` and `version.c`) is put\n  into this directory.\n\n* `build/obj/`: All `*.o` resp. `*.lo` files are placed into this directory.\n\n- `build/deps/` directories contain `*.d` files generated by the build system,\n  and which are used to track dependencies, e.g. of C source files on header\n  files.\n\n\n## Out-of-tree builds\n\nThe old GAP build system had a concept of \"configs\" and \"CONFIGNAME\", which\nallowed you to build GAP in different configurations from a single set of\nsources. This is gone in the current build system. However, a similar goal can\nbe achieved by using so-called \"out-of-tree builds\".\n\nIn the following and also in the files that make up the build system, \"srcdir\"\nrefers to the directory containing the GAP files, i.e. it contains this\nREADME, the src and lib directories and more.\n\nTo create a new out-of-tree build, create a new directory anywhere\nin your filesystem. A typical setup places the out-of-tree dirs into\nsubdirectories of a \"build\" directory inside the srcdir. So you might\nhave directories\n\n    srcdir/build/default\n    srcdir/build/default32\n    srcdir/build/hpcgap\n    srcdir/build/hpcgap32\n    ...\n\nWe will refer to this directory from now on as the \"builddir\".\n\nTo initialize the out-of-tree build, change into the builddir and\nexecute the configure script from the srcdir, like this:\n\n    cd $builddir\n    $srcdir/configure\n\nYou can pass any additional options you like to configure, e.g. `ABI=32`\nor `--enable-hpcgap`.\n\nOnce the configure script has completed, you can run `make` as usual,\nand all the object files and the gap executable will be placed inside\nbuilddir. Your srcdir will remain untouched.\n\n\n## Dependency tracking\n\nThe build system tracks dependencies between files, such as between C source and\nheader files, via `*.d` files stored in `build/deps/`.\nThese files are mostly generated by the compiler; for this, the compiler needs\nto support the relevant flags (gcc, clang, icc all do so).\n\nFor a detailed explanation of a very similar scheme, see here:\n\u003chttps://make.mad-scientist.net/papers/advanced-auto-dependency-generation/\u003e\n\n\n## HPC-GAP integration\n\nOne of the main features of the new build system is that it optionally allows\nto build HPC-GAP instead of plain GAP. HPC-GAP is an experimental fork of GAP\nwhich implements concurrent programming, multi-threading, etc..\n\nThe HPC-GAP kernel and library were forked from the GAP kernel and library and\ndeveloped semi-independently for several years, with occasional merges between\nthe two. In order to recombine the two, we merged the HPC-GAP fork into a\nsubdirectory `hpcgap` of the GAP repository.  Then, all files inside `hpcgap`\nwhich were identical to their counterparts in the GAP repository were deleted\n(e.g. `hpcgap/src/ariths.c` was deleted as it was identical to `src/ariths.c`).\nAt this point, `hpcgap/src` has been fully merged, but there are still files\nin `hpcgap/lib/` which differ from their counterparts in `lib/`\n\nThe new build system can optionally be instructed to build HPC-GAP, by\npassing the `--enable-hpcgap` flag to the `configure` script. For the\nresulting HPC-GAP binary to work, a trick is used:  HPC-GAP mode uses multiple\nGAP root paths. Specifically, the GAP kernel function `SySetGapRootPath` was\nmodified so that for every root directory `FOO` that gets added, we first add\n`FOO/hpcgap` to the list of root directories. This way, `GAPROOT/hpcgap/lib`\nis searched first for files, and only if no matching file is found there does\nGAP also search in `GAPROOT/lib`.\n\n\n## Cross compilation\n\nThe GAP build system supports cross compilation by leveraging the GNU autoconf\nsupport for this (please consult the GNU autoconf manual for details).\nWhen building GAP from a release archive, everything should just work (if\nit doesn't, please report it to us as a bug).\n\nHowever, for development versions of GAP built directly from its git sources,\nthere is a complication: GAP uses a few C source files which are the output of\nthe GAP-to-C compiler `gac`, which in turn needs a working `gap` executable.\nThis requires a bootstrapping process, which works because GAP can actually be\nbuilt and used without those files, they are merely a performance\noptimization. So what our build system does is to first compile a version of\nGAP without those files, then run that to generate those files (if they are\nmissing or not up-to-date). Then finally the actual GAP executable is compiled.\n\nUnfortunately, this poses a problem for cross compilation: when compiling GAP\non one computer (the \"build\" architecture) for a different computer with a\ndifferent OS / CPU architecture / whatnot (the \"host\" architecture), then the\nfirst GAP executable needs to be built for the \"build\" architecture, so that\nit can run during the build process and generated code; while the second GAP\nexecutable needs to be compiled for the \"host\" architecture.\n\nA second cross compilation obstacle is that there files `build/ffdata.c` and\n`build/ffdata.h` are generated by a C program `ffgen` that thus needs to be\nbuilt for the \"build\" architecture.\n\nTo overcome these obstacles, you may proceed as follows:\n\n1. First build GAP for the \"build\" architecture as usual.\n2. This produces files `build/c_*.c` and `build/ffdata.*` which you should\n   copy into the `src` directory.\n3. Clean all build artifacts (alternatively, perform steps 1 \u0026 2 in an\n   out-of-tree build directory)\n3. Build GAP a second time, for the \"host\" architecture. The build system\n   will detect the files you copied into `src` in step 2, and will then not\n   attempt to generate them.\n\nHere is a minimal example to illustrate this:\n\n    ./configure \u0026\u0026 make                 # build native GAP\n    cp build/c_*.c build/ffdata.* src   # copy the generated code\n    make clean\n    ./configure --host=HOST_ARCH        # build for the \"host\" architecture\n    make\n\nNote that this is really a minimalistic example; for actual cross compilation,\nyou may need to provide further flags to the `configure` script and/or set\nenvironment variables, e.g. to ensure it finds dependencies like GMP or GNU\nreadline, or to specify an installation prefix, and so on.\n\nOne final remark: some of the generated files differ for HPC-GAP. If you want\nto cross compile HPC-GAP, you need to generate them with HPC-GAP, and place\nthem into `src/hpc` instead of `src`, like in this example:\n\n    ./configure --enable-hpcgap\n    make\n    cp build/c_*.c src/hpc/\n    cp build/ffdata.* src/\n    make clean\n    ./configure --host=HOST_ARCH --enable-hpcgap\n    make\n\n\n## Open tasks\n\nThere are many things that still need to be done in the new build system. For\nan overview, see\n\u003chttps://github.com/gap-system/gap/issues?q=is%3Aopen+is%3Aissue+label%3A%22topic%3A+build+system%22\u003e\n","funding_links":[],"categories":["Applications","GAP","应用"],"sub_categories":["Education","教育"],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgap-system%2Fgap","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgap-system%2Fgap","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgap-system%2Fgap/lists"}