Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
I
Iris
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Incidents
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Rodolphe Lepigre
Iris
Commits
6f58f693
Commit
6f58f693
authored
Sep 20, 2017
by
Ralf Jung
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
try to fix opam
parent
7418e9c7
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
19 additions
and
11 deletions
+19
-11
Makefile
Makefile
+12
-7
build/opam-ci.sh
build/opam-ci.sh
+7
-4
No files found.
Makefile
View file @
6f58f693
...
@@ -4,11 +4,13 @@
...
@@ -4,11 +4,13 @@
all
:
Makefile.coq
all
:
Makefile.coq
+@make
-f
Makefile.coq all
+@make
-f
Makefile.coq all
.PHONY
:
all
clean
:
Makefile.coq
clean
:
Makefile.coq
+@make
-f
Makefile.coq clean
+@make
-f
Makefile.coq clean
find theories
\(
-name
"*.v.d"
-o
-name
"*.vo"
-o
-name
"*.aux"
-o
-name
"*.cache"
-o
-name
"*.glob"
-o
-name
"*.vio"
\)
-print
-delete
find theories
\(
-name
"*.v.d"
-o
-name
"*.vo"
-o
-name
"*.aux"
-o
-name
"*.cache"
-o
-name
"*.glob"
-o
-name
"*.vio"
\)
-print
-delete
rm
-f
Makefile.coq
rm
-f
Makefile.coq
.PHONY
:
clean
# Create Coq Makefile. POSIX awk can't do in-place editing, but coq_makefile wants the real
# Create Coq Makefile. POSIX awk can't do in-place editing, but coq_makefile wants the real
# filename, so we do some file gymnastics.
# filename, so we do some file gymnastics.
...
@@ -17,16 +19,19 @@ Makefile.coq: _CoqProject Makefile awk.Makefile
...
@@ -17,16 +19,19 @@ Makefile.coq: _CoqProject Makefile awk.Makefile
mv
Makefile.coq Makefile.coq.tmp
&&
awk
-f
awk.Makefile Makefile.coq.tmp
>
Makefile.coq
&&
rm
Makefile.coq.tmp
mv
Makefile.coq Makefile.coq.tmp
&&
awk
-f
awk.Makefile Makefile.coq.tmp
>
Makefile.coq
&&
rm
Makefile.coq.tmp
# Install build-dependencies
# Install build-dependencies
build-dep
:
phony
build-dep/opam
:
# Create the build-dep package.
@
mkdir
-p
build-dep
@
sed
<opam
's/^\(build\|install\|remove\):.*/\1: []/; s/^name: *"\(.*\)" */name: "\1-builddep"/'
>
build-dep/opam
@
fgrep builddep build-dep/opam
>
/dev/null
||
(
echo
"sed failed to fix the package name"
&&
exit
1
)
# sanity check
build-dep
:
build-dep/opam phony
@
# We want opam to not just instal the build-deps now, but to also keep satisfying these
@
# We want opam to not just instal the build-deps now, but to also keep satisfying these
@
# constraints. Otherwise, `opam upgrade` may well update some packages to versions
@
# constraints. Otherwise, `opam upgrade` may well update some packages to versions
@
# that are incompatible with our build requirements.
@
# that are incompatible with our build requirements.
@
# To achieve this, we create a fake opam package that has our build-dependencies as
@
# To achieve this, we create a fake opam package that has our build-dependencies as
@
# dependencies, but does not actually install anything.
@
# dependencies, but does not actually install anything.
mkdir
-p
build-dep
# Add the pin and
(
re
)
install
build-dep package.
# Create the build-dep package, add the pin and
(
re
)
install
it.
@
sed
<opam
's/^\(build\|install\|remove\):.*/\1: []/; s/^name: *"\(.*\)" */name: "\1-builddep"/'
>
build-dep/opam
@
fgrep builddep build-dep/opam
>
/dev/null
||
(
echo
"sed failed to fix the package name"
&&
exit
1
)
# sanity check
@
# Reinstallation is needed in case the pin already exists, but the builddep package changed.
@
# Reinstallation is needed in case the pin already exists, but the builddep package changed.
@
BUILD_DEP_PACKAGE
=
"
$$
(egrep "
^name:
" build-dep/opam | sed 's/^name: *"
\(
.
*
\)
" */
\1
/')"
;
\
@
BUILD_DEP_PACKAGE
=
"
$$
(egrep "
^name:
" build-dep/opam | sed 's/^name: *"
\(
.
*
\)
" */
\1
/')"
;
\
opam pin add
"
$$
BUILD_DEP_PACKAGE"
"
$
$(pwd)
/build-dep"
-k
path
$(OPAMFLAGS)
&&
\
opam pin add
"
$$
BUILD_DEP_PACKAGE"
"
$
$(pwd)
/build-dep"
-k
path
$(OPAMFLAGS)
&&
\
...
@@ -37,6 +42,6 @@ Makefile: ;
...
@@ -37,6 +42,6 @@ Makefile: ;
_CoqProject
:
;
_CoqProject
:
;
awk.Makefile
:
;
awk.Makefile
:
;
# Phony
targets (i.e. targets that should be run no matter the timestamps of the involved files)
# Phony
wildcard targets
phony
:
;
phony
:
;
.PHONY
:
all clean
phony
.PHONY
:
phony
build/opam-ci.sh
View file @
6f58f693
...
@@ -43,15 +43,18 @@ while (( "$#" )); do # while there are arguments left
...
@@ -43,15 +43,18 @@ while (( "$#" )); do # while there are arguments left
fi
fi
done
done
# Install build-dependencies.
# Make sure the pin for the builddep package is not stale.
echo
make build-dep/opam
echo
"[opam-ci] Installing build-dependencies"
make build-dep
OPAMFLAGS
=
-y
# Upgrade cached things.
# Upgrade cached things.
echo
"[opam-ci] Upgrading opam"
echo
"[opam-ci] Upgrading opam"
opam upgrade
-y
opam upgrade
-y
# Install build-dependencies.
echo
echo
"[opam-ci] Installing build-dependencies"
make build-dep
OPAMFLAGS
=
-y
# done
# done
echo
echo
coqc
-v
coqc
-v
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment