Skip to content

Commit 3fe4932

Browse files
committed
Fix _ocamlver() for Pacman 5.1.0
Makepkg apparently now parses the PKGBUILDS in advance and doesn't like seeing empty pkgvers for dependencies. With our split package for the OCaml bindings we declare a dependency on the installed OCaml version, so that upgrades to OCaml wouldn't break the bindings. When llvm-ocaml is built, OCaml is installed and thus _ocamlver() returns a valid version. But now we also need to return a valid version before OCaml is installed. It doesn't need to be meaningful, as it'll get updated again to the real version if package_llvm-ocaml-svn() gets to be run later.
1 parent fce2db1 commit 3fe4932

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

PKGBUILD

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,8 @@ _py_sitepkg_dir="/usr/lib/python2.7/site-packages"
7777
# Determine the installed OCaml package version
7878
# Arguments: NONE
7979
_ocamlver() {
80-
pacman -Q ocaml | awk '{ print $2 }' | cut -d - -f 1 | cut -d . -f 1,2,3
80+
{ pacman -Q ocaml 2>/dev/null || echo 'ocaml 0.0.0-0' ;} \
81+
| awk '{ print $2 }' | cut -d - -f 1 | cut -d . -f 1,2,3
8182
}
8283

8384
# Fix the Python interpreter path in .py files to point to python2

0 commit comments

Comments
 (0)