moby / moby/vpnkit

Can't build vpnkit following the instructions

Open
#192 5 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
OCaml
Stars
1.2k
Forks
214
PR merge metrics
No merged PRs in 30d

Description

Hi! I use macOS Sierra. Installed opal and wget. Trying to build vpnkit I receive the following (what should I do to build it?):

➜  vpnkit git:(master) opam install --deps-only slirp                       
The following actions will be performed:
  - install hvsock         0.13.0
  - install datakit-server 0.9.0 
  - install dns-forward    0.8.1 
===== 3 to install =====
Do you want to continue ? [Y/n] Y

=-=- Gathering sources =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=

=-=- Processing actions -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
[ERROR] The compilation of dns-forward failed at "ocaml pkg/pkg.ml build --pinned false".
[ERROR] The compilation of datakit-server failed at "ocaml pkg/pkg.ml build --pinned false -n datakit-server".
[ERROR] The compilation of hvsock failed at "make".
Processing  3/3: [hvsock: ocamlfind remove]
#=== ERROR while installing datakit-server.0.9.0 ==============================#
# opam-version 1.2.2
# os           darwin
# command      ocaml pkg/pkg.ml build --pinned false -n datakit-server
# path         /Users/os/.opam/system/build/datakit-server.0.9.0
# compiler     system (4.04.0)
# exit-code    1
# env-file     /Users/os/.opam/system/build/datakit-server.0.9.0/datakit-server-57805-1872ec.env
# stdout-file  /Users/os/.opam/system/build/datakit-server.0.9.0/datakit-server-57805-1872ec.out
# stderr-file  /Users/os/.opam/system/build/datakit-server.0.9.0/datakit-server-57805-1872ec.err
### stdout ###
# [...]
# ocamlfind ocamlopt -shared -package protocol-9p.unix -package 'bytes lwt astring logs result cstruct fmt rresult' src/datakit-server/vfs.cmx -o src/datakit-server/vfs.cmxs
# ocamlfind ocamlc -c -g -bin-annot -safe-string -package protocol-9p.unix -package 'bytes lwt astring logs result cstruct fmt rresult' -warn-error +1..49-3 -w A-4-41-44 -I src/datakit-server -I src -o src/datakit-server/vfs.cmo src/datakit-server/vfs.ml
# ocamlfind ocamlc -a -package protocol-9p.unix -package 'bytes lwt astring logs result cstruct fmt rresult' src/datakit-server/vfs.cmo -o src/datakit-server/vfs.cma
# ocamlfind ocamldep -package protocol-9p.unix -package 'bytes lwt astring logs result cstruct fmt rresult' -modules src/datakit-server/fs9p.ml > src/datakit-server/fs9p.ml.depends
# ocamlfind ocamldep -package protocol-9p.unix -package 'bytes lwt astring logs result cstruct fmt rresult' -modules src/datakit-server/fs9p.mli > src/datakit-server/fs9p.mli.depends
# ocamlfind ocamlc -c -g -bin-annot -safe-string -package protocol-9p.unix -package 'bytes lwt astring logs result cstruct fmt rresult' -warn-error +1..49-3 -w A-4-41-44 -I src/datakit-server -I src -o src/datakit-server/fs9p.cmi src/datakit-server/fs9p.mli
# + ocamlfind ocamlc -c -g -bin-annot -safe-string -package protocol-9p.unix -package 'bytes lwt astring logs result cstruct fmt rresult' -warn-error +1..49-3 -w A-4-41-44 -I src/datakit-server -I src -o src/datakit-server/fs9p.cmi src/datakit-server/fs9p.mli
# File "src/datakit-server/fs9p.mli", line 17, characters 19-30:
# Error: Unbound module V1_LWT
# Command exited with code 2.
### stderr ###
# pkg.ml: [ERROR] cmd ['ocamlbuild' '-use-ocamlfind' '-classic-display' '-tag' 'debug'
# [...]
#      'src/datakit-server/vfs.a' 'src/datakit-server/vfs.cmxs'
#      'src/datakit-server/vfs.cmxa' 'src/datakit-server/vfs.cma'
#      'src/datakit-server/vfs.cmx' 'src/datakit-server/vfs.cmi'
#      'src/datakit-server/vfs.mli' 'src/datakit-server/fs9p.a'
#      'src/datakit-server/fs9p.cmxs' 'src/datakit-server/fs9p.cmxa'
#      'src/datakit-server/fs9p.cma' 'src/datakit-server/fs9p_error.cmx'
#      'src/datakit-server/fs9p_error.cmi' 'src/datakit-server/fs9p_error.mli'
#      'src/datakit-server/fs9p.cmx' 'src/datakit-server/fs9p.cmi'
#      'src/datakit-server/fs9p.mli']: exited with 10


#=== ERROR while installing dns-forward.0.8.1 =================================#
# opam-version 1.2.2
# os           darwin
# command      ocaml pkg/pkg.ml build --pinned false
# path         /Users/os/.opam/system/build/dns-forward.0.8.1
# compiler     system (4.04.0)
# exit-code    1
# env-file     /Users/os/.opam/system/build/dns-forward.0.8.1/dns-forward-57805-c61e7b.env
# stdout-file  /Users/os/.opam/system/build/dns-forward.0.8.1/dns-forward-57805-c61e7b.out
# stderr-file  /Users/os/.opam/system/build/dns-forward.0.8.1/dns-forward-57805-c61e7b.err
### stdout ###
# ocamlfind ocamldep -package 'dns mirage-flow cstruct.lwt channel io-page.unix' -package 'bytes lwt astring logs result cstruct fmt rresult ipaddr' -modules lib/dns_forward.ml > lib/dns_forward.ml.depends
# ocamlfind ocamldep -package ppx_sexp_conv -package 'dns mirage-flow cstruct.lwt channel io-page.unix' -package 'bytes lwt astring logs result cstruct fmt rresult ipaddr' -modules lib/dns_forward.mli > lib/dns_forward.mli.depends
# ocamlfind ocamlc -c -g -bin-annot -safe-string -package ppx_sexp_conv -package 'dns mirage-flow cstruct.lwt channel io-page.unix' -package 'bytes lwt astring logs result cstruct fmt rresult ipaddr' -warn-error +1..49 -w A-3-4-41-44 -I lib -I bin -o lib/dns_forward.cmi lib/dns_forward.mli
# + ocamlfind ocamlc -c -g -bin-annot -safe-string -package ppx_sexp_conv -package 'dns mirage-flow cstruct.lwt channel io-page.unix' -package 'bytes lwt astring logs result cstruct fmt rresult ipaddr' -warn-error +1..49 -w A-3-4-41-44 -I lib -I bin -o lib/dns_forward.cmi lib/dns_forward.mli
# findlib: [WARNING] Interface topdirs.cmi occurs in several directories: /usr/local/lib/ocaml, /usr/local/lib/ocaml/compiler-libs
# File "lib/dns_forward.mli", line 40, characters 12-38:
# Error: Unbound module Mirage_flow_s
# Command exited with code 2.
### stderr ###
# pkg.ml: [ERROR] cmd ['ocamlbuild' '-use-ocamlfind' '-classic-display' '-tag' 'debug'
# [...]
#      'lib/dns_forward_framing.cmx' 'lib/dns_forward_server.cmx'
#      'lib/dns_forward_resolver.cmx' 'lib/dns_forward_rpc.cmx'
#      'lib/dns_forward_free_id.cmx' 'lib/dns_forward_error.cmx'
#      'lib/dns_forward_config.cmx' 'lib/dns_forward.cmx' 'lib/dns_forward.cmi'
#      'lib/dns_forward.mli' 'lib/dns-forward-lwt-unix.a'
#      'lib/dns-forward-lwt-unix.cmxs' 'lib/dns-forward-lwt-unix.cmxa'
#      'lib/dns-forward-lwt-unix.cma' 'lib/dns_forward_lwt_unix.cmx'
#      'lib/dns_forward_lwt_unix.cmi' 'lib/dns_forward_lwt_unix.mli'
#      'bin/main.native']: exited with 10


#=== ERROR while installing hvsock.0.13.0 =====================================#
# opam-version 1.2.2
# os           darwin
# command      make
# path         /Users/os/.opam/system/build/hvsock.0.13.0
# compiler     system (4.04.0)
# exit-code    2
# env-file     /Users/os/.opam/system/build/hvsock.0.13.0/hvsock-57805-a00279.env
# stdout-file  /Users/os/.opam/system/build/hvsock.0.13.0/hvsock-57805-a00279.out
# stderr-file  /Users/os/.opam/system/build/hvsock.0.13.0/hvsock-57805-a00279.err
### stdout ###
# [...]
# /Users/os/.opam/system/bin/ocamlfind ocamldep -package unix -package threads -package mirage-types.lwt -package mirage-flow -package lwt -package logs -package duration -package cstruct -package bytes -modules lwt/lwt_hvsock.ml > lwt/lwt_hvsock.ml.depends
# /Users/os/.opam/system/bin/ocamlfind ocamldep -package unix -package threads -package mirage-types.lwt -package mirage-flow -package lwt -package logs -package duration -package cstruct -package bytes -modules lwt/flow_lwt_hvsock.mli > lwt/flow_lwt_hvsock.mli.depends
# /Users/os/.opam/system/bin/ocamlfind ocamlc -c -g -annot -bin-annot -thread -I lib -thread -package unix -package threads -package mirage-types.lwt -package mirage-flow -package lwt -package logs -package duration -package cstruct -package bytes -I lwt -I lib -o lwt/flow_lwt_hvsock.cmi lwt/flow_lwt_hvsock.mli
# /Users/os/.opam/system/bin/ocamlfind ocamldep -package unix -package threads -package mirage-types.lwt -package mirage-flow -package lwt -package logs -package duration -package cstruct -package bytes -modules lwt/flow_lwt_hvsock.ml > lwt/flow_lwt_hvsock.ml.depends
# /Users/os/.opam/system/bin/ocamlfind ocamldep -package unix -package threads -package mirage-types.lwt -package mirage-flow -package lwt -package logs -package duration -package cstruct -package bytes -modules lwt/flow_lwt_hvsock_shutdown.mli > lwt/flow_lwt_hvsock_shutdown.mli.depends
# /Users/os/.opam/system/bin/ocamlfind ocamlc -c -g -annot -bin-annot -thread -I lib -thread -package unix -package threads -package mirage-types.lwt -package mirage-flow -package lwt -package logs -package duration -package cstruct -package bytes -I lwt -I lib -o lwt/flow_lwt_hvsock_shutdown.cmi lwt/flow_lwt_hvsock_shutdown.mli
# + /Users/os/.opam/system/bin/ocamlfind ocamlc -c -g -annot -bin-annot -thread -I lib -thread -package unix -package threads -package mirage-types.lwt -package mirage-flow -package lwt -package logs -package duration -package cstruct -package bytes -I lwt -I lib -o lwt/flow_lwt_hvsock_shutdown.cmi lwt/flow_lwt_hvsock_shutdown.mli
# File "lwt/flow_lwt_hvsock_shutdown.mli", line 26, characters 10-36:
# Error: Unbound module Mirage_flow_s
# Command exited with code 2.
### stderr ###
# E: Failure("Command ''/Users/os/.opam/system/bin/ocamlbuild' lib/libhvsock_stubs.a lib/dllhvsock_stubs.so lib/hvsock.cma lib/hvsock.cmxa lib/hvsock.a lib/hvsock.cmxs lwt/hvsock_lwt.cma lwt/hvsock_lwt.cmxa lwt/hvsock_lwt.a lwt/hvsock_lwt.cmxs lwt_unix/hvsock_lwt_unix.cma lwt_unix/hvsock_lwt_unix.cmxa lwt_unix/hvsock_lwt_unix.a lwt_unix/hvsock_lwt_unix.cmxs src/hvcat.native lib_test/test.native -use-ocamlfind -tag debug -tag tests' terminated with error code 10")
# make: *** [build] Error 1



=-=- Error report -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
The following actions failed
  - install datakit-server 0.9.0 
  - install dns-forward    0.8.1 
  - install hvsock         0.13.0
No changes have been performed

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the documented vpnkit build instructions and reproduce opam install --deps-only slirp on macOS. Investigate the reported failures in datakit-server, dns-forward, and hvsock, especially the missing V1_LWT and Mirage_flow_s modules. Done means the dependencies install successfully and vpnkit builds following the instructions.

Written by the indexing model from the issue text.

Assessment

Tech stack
ocaml
Domain
build-system
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.