I have a new project I'm trying to compile with OASIS. All my packages but one are installed with opam.
My _oasis
file looks like this :
(* usual package fields *)
Executable myexe
Path: src
BuildTools: ocamlbuild
MainIs: myexe.ml
BuildDepends:
some_packages_installed_with_opam
mylocalpackage
I tried oasis setup
then ./configure
but OCamlfind answered that it couldn't find mylocalpackage
. So I decided to take a look at where OCamlfind looks for packages and found out that you can set an OCAMLPATH
variable to add directories where packages might be installed. So I did export OCAMLPATH=path_to_mylocalpackage:$OCAMLPATH
and tried again.
oasis setup
gives me this result :
findlib: [WARNING] While parsing 'path_to_my_local_package/META.in':
The `directory' directive is required in this META definition
and ocamlfind query mylocalpackage
gives me this result :
ocamlfind: Package `mylocalpackage' not found
I don't know if I should write in _oasis
where to find this package or if changing the OCAMLPATH
variable is the solution. But if it is, I don't understand the warning.
Steps to reproduce
For those who would like to try it :
Download why3
./configure --enable-local make
Create a new project with this
_oasis
fileOASISFormat: 0.4 Name: myexe Version: 0.1 Synopsis: test file Authors: SO License: CC-BY-NC-SA Plugins: StdFiles (0.4), DevFiles (0.4) Alphafeatures: ocamlbuild_more_args XOCamlbuildExtraArgs: -use-ocamlfind Executable myexe Path: src BuildTools: ocamlbuild MainIs: myexe.ml BuildDepends: unix, str, num, dynlink, zip, menhirLib, why3 NativeOpt: -dtypes -g -annot ByteOpt: -dtypes -g -annot CompiledObject: best
oasis setup ./configure
- You should have this error :
ocamlfind: Package 'why3' not found