GUI in ocaml ? What is used?

Hello Cammels ,

may i ask what GUI is recommended for building user interfaces ?

Are there binding in oCaml. Is there i main Library recommended?

WBR
MHE

This seems to be a Frequently Asked Question.

I think the general answer is “there’s some stuff you can use but it isn’t fabulous.”

See the answers to these two earlier questions:

Hello perry ,
i have tried it to install. There are packages not to get. Debian Linux
Here my description :slight_smile:

  1. LablQt ./configure Qt5Quick cannot be installed - dont know where to get ?

  2. wxoCaml ./configure error : please install OCaml tool 'ocp-build’
    Then i have installed ocp-build version 1.99.19-beta with opam but
    the same message appeared. - not installed

Tk is not working. Only GTK2 is working here.Have pasted a code from tutorial.

How to install theese files for the other GUI tools. QT and WX are a good choice.

Want to RUN qt and wx tools as soon as possible.

WBR
MHE ------- files/packages missing — - qt5quick ----- ocp-build

@MHE do you know how to use opam?

here the code for WX GUI LIBRARY : ocp-build missing - but installed

root@mx1:/home/hans/Downloads/ocplib-wxOCaml-master# ls
api config.ocp docs Makefile README.md wxStubsGen
autoconf config.ocp.win64 examples META README.ocpwin wxWidgets_cpp
build.ocp configure INSTALL.md ocp-autoconf.ac README.x86 wxWidgets_ml
CHANGES.txt configure-wxMSW LICENSE ocp-autoconf.config wxConfig wxwin.m4
root@mx1:/home/hans/Downloads/ocplib-wxOCaml-master# ./configure
checking for gcc… gcc
checking whether the C compiler works… yes
checking for C compiler default output file name… a.out
checking for suffix of executables…
checking whether we are cross compiling… no
checking for suffix of object files… o
checking whether we are using the GNU C compiler… yes
checking whether gcc accepts -g… yes
checking for gcc option to accept ISO C89… none needed
checking for ocamlc… ocamlc
OCaml version is 4.01.0
OCaml library path is /usr/lib/ocaml
checking for ocamlopt… ocamlopt
checking for ocamlc.opt… no
checking for ocamlopt.opt… no
checking for ocaml… ocaml
checking for ocamldep… ocamldep
checking for ocamldep.opt… no
checking for ocamlmktop… ocamlmktop
checking for ocamlmklib… ocamlmklib
checking for ocamldoc… ocamldoc
checking for ocamlbuild… ocamlbuild
checking for a sed that does not truncate output… /bin/sed
checking Major version… 4
checking Minor version… 01
checking Point version… 0
checking for gawk… gawk
checking for ocamlfind… ocamlfind
initializing metadir from ocamlfind config
checking for ocp-build… no
configure: error: Please install OCaml tool ‘ocp-build’.
root@mx1:/home/hans/Downloads/ocplib-wxOCaml-master# exit
exit
hans@mx1:~/Downloads/ocplib-wxOCaml-master
$ ls
api config.ocp docs Makefile README.md wxStubsGen
autoconf config.ocp.win64 examples META README.ocpwin wxWidgets_cpp
build.ocp configure INSTALL.md ocp-autoconf.ac README.x86 wxWidgets_ml
CHANGES.txt configure-wxMSW LICENSE ocp-autoconf.config wxConfig wxwin.m4
hans@mx1:~/Downloads/ocplib-wxOCaml-master
$ cd /
hans@mx1:/
$ ls
bin dev etc initrd.img lost+found mnt proc run sys usr vmlinuz
boot Documents home lib media opt root sbin tmp var
hans@mx1:/
$ opam install ocp-build
[NOTE] Package ocp-build is already installed (current version is 1.99.19-beta).
hans@mx1:/

Here the session QT GUI Bindings : QT5Quick missing - [dont know from where to get]

hans@mx1:~/Downloads/lablqml-master
$ ls
CHANGELOG configure CONTRIBUTING.md demos lib Makefile.install opam ppx README.md
hans@mx1:~/Downloads/lablqml-master
$ ./configure
N.B. Don’t forget to export right LD_LIBRARY_PATH and PKG_CONFIG_PATH for Qt5 before running this!
OCaml 4.01.0 found.
ocamlfind found.
qmake found for Qt 5.3.2
Compiling test C++&Qt application…
Package Qt5Quick was not found in the pkg-config search path.
Perhaps you should add the directory containing Qt5Quick.pc' to the PKG_CONFIG_PATH environment variable No package 'Qt5Quick' found Package Qt5Quick was not found in the pkg-config search path. Perhaps you should add the directory containingQt5Quick.pc’
to the PKG_CONFIG_PATH environment variable
No package ‘Qt5Quick’ found
testQtDeclarative.cpp:1:32: fatal error: QtQuick/qquickview.h: No such file or directory
#include <QtQuick/qquickview.h>
^
compilation terminated.
Building test C++&Qt application failed.
N.B. If you are using Ubuntu 13.04 or precompiled Qt5 from website there is a possibility that file ‘Qt5Core.pc’ has bug. You can consider to substitute line
Libs: -L${libdir} -lQt5Core
for
Libs: -Wl,-rpath,${libdir} -L${libdir} -lQt5Core

hans@mx1:~/Downloads/lablqml-master

@MHE I asked if you know how to use opam. Please answer? You should be using opam to install things, not trying to do it by hand.

(I also will mention that from what it looks like, your OCaml setup isn’t very recent.)

Yes of course. I have all installed with opam.

Opam cannot find Qt5Quick. apt-get install fails too. Internet search for this packet ? no result.

Opam says there is ocp-build already installed.

You can be shure that i want to install theese packets in a normal way but it fails.

I make an update yet first.

Thanks for your attention. I am back soon.

WBR
MHE

Hi again.

i have made an update opam update opam upgrade

The same error appears while i want to install wxOCaml.

I should install oCaml tool ocp-bulid.

When i do opam install ocp-build the message is that it is already installed with version 1.99.19 beta.

ocaml is already installed / opam is already installed and upgrated /

wx and Qt bindings are not working because of install problem 2 specified packages/files.

What to do ?

MHE