Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
F
frama-c
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Container Registry
Model registry
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
pub
frama-c
Commits
60bfe7c6
Commit
60bfe7c6
authored
3 years ago
by
Allan Blanchard
Browse files
Options
Downloads
Patches
Plain Diff
[ci] setup hook for plugins
parent
2a63f8b0
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
nix/frama-c.nix
+28
-2
28 additions, 2 deletions
nix/frama-c.nix
with
28 additions
and
2 deletions
nix/frama-c.nix
+
28
−
2
View file @
60bfe7c6
...
@@ -84,6 +84,8 @@ stdenv.mkDerivation rec {
...
@@ -84,6 +84,8 @@ stdenv.mkDerivation rec {
autoconf
autoconf
''
;
''
;
# Do not use default parallel building, but allow 2 cores for Frama-C build
enableParallelBuilding
=
false
;
buildPhase
=
''
buildPhase
=
''
make config.sed
make config.sed
dune build -j2 --display short @install
dune build -j2 --display short @install
...
@@ -104,9 +106,33 @@ stdenv.mkDerivation rec {
...
@@ -104,9 +106,33 @@ stdenv.mkDerivation rec {
cp -r $out/share/doc $out/doc
cp -r $out/share/doc $out/doc
''
;
''
;
#
Required so that Frama-C libs are found after install
#
Allow loading of external Frama-C plugins
setupHook
=
writeText
"setupHook.sh"
''
setupHook
=
writeText
"setupHook.sh"
''
export OCAMLPATH="
''$
{OCAMLPATH-}
''$
{OCAMLPATH:+:}
''$
1/lib"
has_dirs() {
for f do
[ -d "$f" ] && return
done
false
}
addFramaCPath () {
if test -d "
''$
1/lib/frama-c/plugins"; then
export FRAMAC_PLUGIN="
''$
{FRAMAC_PLUGIN-}
''$
{FRAMAC_PLUGIN:+:}
''$
1/lib/frama-c/plugins"
export OCAMLPATH="
''$
{OCAMLPATH-}
''$
{OCAMLPATH:+:}
''$
1/lib/frama-c/plugins"
fi
if has_dirs
''$
1/lib/frama-c-*; then
export OCAMLPATH="
''$
{OCAMLPATH-}
''$
{OCAMLPATH:+:}
''$
1/lib"
export DUNE_DIR_LOCATIONS="
''$
{DUNE_DIR_LOCATIONS-}
''$
{DUNE_DIR_LOCATIONS:+:}frama-c:lib:
''$
1/lib/frama-c"
fi
if test -d "
''$
1/share/frama-c/"; then
export FRAMAC_EXTRA_SHARE="
''$
{FRAMAC_EXTRA_SHARE-}
''$
{FRAMAC_EXTRA_SHARE:+:}
''$
1/share/frama-c"
fi
}
addEnvHooks "$targetOffset" addFramaCPath
''
;
''
;
meta
=
{
meta
=
{
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment