Skip to content

Commit

Permalink
Update kernel module checking (#45)
Browse files Browse the repository at this point in the history
  • Loading branch information
Joseph-Edwards authored Aug 26, 2024
1 parent e8d556e commit 4177530
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 14 deletions.
3 changes: 0 additions & 3 deletions .github/workflows/CI.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,9 +27,6 @@ jobs:
- master
- stable-4.13
- stable-4.12
- stable-4.11
- stable-4.10
- stable-4.9
ABI: ['']
include:
- gap-branch: master
Expand Down
9 changes: 5 additions & 4 deletions PackageInfo.g
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ PackageDoc := rec(
),

Dependencies := rec(
GAP := ">=4.10",
GAP := ">=4.12",
NeededOtherPackages := [
["GAPDoc", ">= 1.2"],
["IO", ">= 4.1"],
Expand All @@ -111,9 +111,10 @@ Dependencies := rec(
),

AvailabilityTest := function()
if not "cvec" in SHOW_STAT() and
Filename(DirectoriesPackagePrograms("cvec"), "cvec.so") = fail then
#Info(InfoWarning, 1, "cvec: kernel cvec functions not available.");
if not IsKernelExtensionAvailable("cvec") then
LogPackageLoadingMessage(PACKAGE_WARNING,
["the kernel module is not compiled, ",
"the package cannot be loaded."]);
return fail;
fi;
return true;
Expand Down
9 changes: 2 additions & 7 deletions init.g
Original file line number Diff line number Diff line change
Expand Up @@ -13,13 +13,8 @@
################################

# load kernel function if it is installed:
if (not IsBound(CVEC)) and ("cvec" in SHOW_STAT()) then
# try static module
LoadStaticModule("cvec");
fi;
if (not IsBound(CVEC)) and
(Filename(DirectoriesPackagePrograms("cvec"), "cvec.so") <> fail) then
LoadDynamicModule(Filename(DirectoriesPackagePrograms("cvec"), "cvec.so"));
if not LoadKernelExtension("cvec") then
Error("failed to load the cvec package kernel extension");
fi;

#
Expand Down

0 comments on commit 4177530

Please sign in to comment.