Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Iris
ci
Commits
b968ab46
Commit
b968ab46
authored
Oct 06, 2020
by
Ralf Jung
Browse files
adjust to new-style package builddep name
parent
82035bb9
Changes
2
Hide whitespace changes
Inline
Side-by-side
buildjob
View file @
b968ab46
...
...
@@ -55,6 +55,8 @@ fi
mkdir
-p
.git/info
cat
>>
.git/info/exclude
<<
EOF
ci/
builddep/
build-dep/
_opam/
build-env.txt
build-log.txt
...
...
prepare-opam.sh
View file @
b968ab46
...
...
@@ -52,14 +52,17 @@ echo
if
test
-f
opam
;
then
# Old-style package: a single opam file
make build-dep/opam
# Copy it to new-style location
mkdir
-p
builddep
cp
build-dep/opam builddep/opam
else
# New-style package has a dedicated target to just generate the files
make build
-
dep-opamfiles
make builddep-opamfiles
fi
# Update old opam, if we got a cache.
if
[[
-z
"
$FRESH_OPAM
"
]]
;
then
# skip if this is a fresh opam root
# Update repositories and reinit. build
-
dep/* must exist here because it
# Update repositories and reinit. builddep/* must exist here because it
# might be installed, and opam would complain if it had went missing.
opam init
--no-setup
--disable-sandboxing
--reinit
-y
# We need `opam update` anyway to update git branches.
...
...
@@ -99,18 +102,18 @@ while (( "$#" )); do # while there are arguments left
done
echo
# Pin build
-
dep and install everything.
warn
"[prepare-opam] Pinning and installing build
-
dep and upgrading everything"
if
!
opam pin add
-y
-n
build
-
dep/
;
then
# we have to do this first, or `opam upgrade` cannot pick it up, see opam issue #3613.
panic
"'pin add build
-
dep/' failed'"
# Pin builddep and install everything.
warn
"[prepare-opam] Pinning and installing builddep and upgrading everything"
if
!
opam pin add
-y
-n
builddep/
;
then
# we have to do this first, or `opam upgrade` cannot pick it up, see opam issue #3613.
panic
"'pin add builddep/' failed'"
fi
# We would really like to do these two in one transaction, but that does not work -- see opam issue #3737.
# Also, we have to list the packages we pinned explicitly here, or else opam fails to upgrade them if they
# are pinned to a git branch (it ignores changes in the git branch) -- see opam issue #3727.
if
!
opam upgrade
-y
build
-
dep/
$PINNED_PACKAGES
;
then
if
!
opam upgrade
-y
builddep/
$PINNED_PACKAGES
;
then
echo
"opam state:"
opam pin
&&
opam list
panic
"'opam upgrade build
-
dep/
$PINNED_PACKAGES
' failed"
panic
"'opam upgrade builddep/
$PINNED_PACKAGES
' failed"
fi
opam upgrade
-y
echo
...
...
Write
Preview
Supports
Markdown
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