Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

jsoo 3.0 #16

Closed
wants to merge 2 commits into from
Closed

jsoo 3.0 #16

wants to merge 2 commits into from

Conversation

meadofpoetry
Copy link
Contributor

As far as I can see js_of_ocaml, js_of_ocaml-ocamlbuild and js_of_ocaml-ppx are sufficient for successful building.

@dbuenzli
Copy link
Owner

dbuenzli commented Aug 8, 2017

This doesn't work here. It seems they renamed js_of_ocaml to js_of_ocaml.exe (!?). But somehow the ocamlbuild plugin was not updated.

> topkg build 
ocamlfind ocamlopt -shared -linkall -package gg -package bytes -package uchar -package result -I src src/vg.cmxa -o src/vg.cmxs
ocamlfind ocamlopt -shared -linkall -package gg -package bytes -package uchar -package result -I src src/vgr_svg.cmxa -o src/vgr_svg.cmxs
ocamlfind ocamlopt -shared -linkall -package uutf -package otfm -package gg -package bytes -package uchar -package result -I src src/vgr_pdf.cmxa -o src/vgr_pdf.cmxs
ocamlfind ocamlopt -shared -linkall -package js_of_ocaml.ppx -package gg -package bytes -package uchar -package result -I src src/vgr_htmlc.cmxa -o src/vgr_htmlc.cmxs
ocamlfind ocamlopt -shared -linkall -package cairo2 -package gg -package bytes -package uchar -package result -I src src/vgr_cairo.cmxa -o src/vgr_cairo.cmxs
js_of_ocaml --no-runtime --pretty --debug-info --source-map +js_of_ocaml-compiler/runtime.js -o test/min_htmlc.js test/min_htmlc.byte
+ js_of_ocaml --no-runtime --pretty --debug-info --source-map +js_of_ocaml-compiler/runtime.js -o test/min_htmlc.js test/min_htmlc.byte
/bin/sh: js_of_ocaml: command not found
Command exited with code 127.
pkg.ml: [ERROR] cmd ['ocamlbuild' '-use-ocamlfind' '-classic-display' '-tag' 'debug'
     '-build-dir' '_build' '-plugin-tag' 'package(js_of_ocaml.ocamlbuild)'
     'opam' 'pkg/META' 'CHANGES.md' 'LICENSE.md' 'README.md' 'src/vg.a'
     'src/vg.cmxs' 'src/vg.cmxa' 'src/vg.cma' 'src/vg.cmx' 'src/vg.cmi'
     'src/vg.mli' 'src/vgr_svg.a' 'src/vgr_svg.cmxs' 'src/vgr_svg.cmxa'
     'src/vgr_svg.cma' 'src/vgr_svg.cmx' 'src/vgr_svg.cmi' 'src/vgr_svg.mli'
     'src/vgr_pdf.a' 'src/vgr_pdf.cmxs' 'src/vgr_pdf.cmxa' 'src/vgr_pdf.cma'
     'src/vgr_pdf.cmx' 'src/vgr_pdf.cmi' 'src/vgr_pdf.mli' 'src/vgr_htmlc.a'
     'src/vgr_htmlc.cmxs' 'src/vgr_htmlc.cmxa' 'src/vgr_htmlc.cma'
     'src/vgr_htmlc.cmx' 'src/vgr_htmlc.cmi' 'src/vgr_htmlc.mli'
     'src/vgr_cairo.a' 'src/vgr_cairo.cmxs' 'src/vgr_cairo.cmxa'
     'src/vgr_cairo.cma' 'src/vgr_cairo.cmx' 'src/vgr_cairo.cmi'
     'src/vgr_cairo.mli' 'test/vecho.native' 'test/examples.ml'
     'test/min_htmlc.html' 'test/min_htmlc.ml' 'test/min_pdf.ml'
     'test/min_svg.ml' 'test/min_cairo_png.ml' 'test/min_cairo_mem.ml'
     'test/fglyphs.ml' 'test/vecho.ml' 'test/min_svg.native'
     'test/min_pdf.native' 'test/min_cairo_png.native'
     'test/min_cairo_mem.native' 'test/rsvg.native' 'test/rpdf.native'
     'test/rcairo.native' 'test/examples.native' 'fglyphs.native'
     'test/min_htmlc.html' 'test/min_htmlc.js' 'test/sqc.html' 'test/sqc.js'
     'test/rhtmlc.html' 'test/rhtmlc.js']: exited with 10

@dbuenzli
Copy link
Owner

dbuenzli commented Aug 8, 2017

Thanks for you help @Freyr666.

Note that if this manages to get fixed upstream then it seems we don't need to make a new release. We should simply update the constraints in the opam-repository. But please keep this open for now.

@meadofpoetry
Copy link
Contributor Author

meadofpoetry commented Aug 8, 2017

@dbuenzli

It seems they renamed js_of_ocaml to js_of_ocaml.exe (!?). But somehow the ocamlbuild plugin was not updated.

Ah, I see. It seems we also need js_of_ocaml-compiler package. At least I have js_of_ocaml binary along with the js_of_ocaml.exe, and vg compiles just fine. I've added js_of_ocaml-compiler in deps, does it work now?

@dbuenzli
Copy link
Owner

dbuenzli commented Aug 8, 2017

This doesn't work here the build fails as above with:

> opam list | grep js_of_ocaml 
js_of_ocaml             3.0           Compiler from OCaml bytecode to Javascript
js_of_ocaml-compiler    3.0           Compiler from OCaml bytecode to Javascript
js_of_ocaml-ocamlbuild  3.0           Compiler from OCaml bytecode to Javascript
js_of_ocaml-ppx         3.0           Compiler from OCaml bytecode to Javascript

on which platform are you ?

@meadofpoetry
Copy link
Contributor Author

meadofpoetry commented Aug 8, 2017

on which platform are you ?

fedora 26, amd64. That is strange since

$ which js_of_ocaml
~/.opam/main/bin/js_of_ocaml
$ js_of_ocaml --version
3.0
$ opam list | grep js_of_ocaml 
js_of_ocaml             3.0               Compiler from OCaml bytecode to Javascript
js_of_ocaml-compiler    3.0               Compiler from OCaml bytecode to Javascript
js_of_ocaml-ocamlbuild  3.0               Compiler from OCaml bytecode to Javascript
js_of_ocaml-ppx         3.0               Compiler from OCaml bytecode to Javascript
js_of_ocaml-tyxml       3.0               Compiler from OCaml bytecode to Javascrip

@dbuenzli
Copy link
Owner

dbuenzli commented Aug 8, 2017

Thanks I now understand the issue, see the monologue here ocsigen/js_of_ocaml#613. In any case your constraints are in as 29277f4 and I submited ocaml/opam-repository#10056 on the opam repo to make vg.0.9.0. use jsoo 3.0. Thanks for the help.

@dbuenzli dbuenzli closed this Aug 8, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants