diff --git a/.travis-ci.sh b/.travis-ci.sh index ef051c2..f881a6f 100644 --- a/.travis-ci.sh +++ b/.travis-ci.sh @@ -14,15 +14,15 @@ case "$TRAVIS_OS_NAME" in ;; osx) brew update > /dev/null - brew install opam # 'gmp' and 'coreutils' are already installed on travis + brew install opam libffi depqbf # 'gmp' and 'coreutils' are already installed on travis ;; esac opam init -y eval `opam config env` -opam install -y ocamlfind ounit +opam install -y ocamlfind ounit ctypes ctypes-foreign -./configure --enable-quantor --enable-tests +./configure --enable-quantor --enable-tests --enable-depqbf make make test diff --git a/.travis.yml b/.travis.yml index 665e3ef..2eaafa0 100644 --- a/.travis.yml +++ b/.travis.yml @@ -7,6 +7,8 @@ addons: packages: - ocaml - opam + - libffi-dev + - depqbf script: bash -ex .travis-ci.sh matrix: diff --git a/_oasis b/_oasis index f9c6213..0f14387 100644 --- a/_oasis +++ b/_oasis @@ -60,9 +60,12 @@ Library "qbf-depqbf" BuildDepends: qbf, ctypes, ctypes.foreign FindlibName: depqbf FindlibParent: qbf - CCLib: -L/usr/local/lib -lqdpll Build$: flag(depqbf) Install$: flag(depqbf) + if system(macosx) + CCLib: -force_load /usr/local/lib/libqdpll.a + else + CCLib: -L/usr/local/lib -lqdpll Library "qbf-random" Path: src/random/ diff --git a/libs/quantor-3.2/configure b/libs/quantor-3.2/configure index 391aff6..48698fe 100755 --- a/libs/quantor-3.2/configure +++ b/libs/quantor-3.2/configure @@ -223,7 +223,7 @@ RAWCC=unknown for cc in $CC do case $cc in - *gcc* | *cc*) RAWCC=$cc; break;; + *gcc* | *cc* | *clang*) RAWCC=$cc; break;; *) ;; esac done diff --git a/myocamlbuild.ml b/myocamlbuild.ml index 3ee1daf..e4cb8d7 100644 --- a/myocamlbuild.ml +++ b/myocamlbuild.ml @@ -1,5 +1,5 @@ (* OASIS_START *) -(* DO NOT EDIT (digest: 20db17568fe48367d23ee78777635427) *) +(* DO NOT EDIT (digest: 11a9f54dabb16e5b905c670ece0d3cb3) *) module OASISGettext = struct (* # 22 "src/oasis/OASISGettext.ml" *) @@ -925,13 +925,28 @@ let package_default = ]); (["oasis_library_qbf_depqbf_cclib"; "link"], [ - (OASISExpr.EBool true, + (OASISExpr.EBool true, S []); + (OASISExpr.ETest ("system", "macosx"), + S + [ + A "-cclib"; + A "-force_load"; + A "-cclib"; + A "/usr/local/lib/libqdpll.a" + ]); + (OASISExpr.ENot (OASISExpr.ETest ("system", "macosx")), S [A "-cclib"; A "-L/usr/local/lib"; A "-cclib"; A "-lqdpll" ]) ]); (["oasis_library_qbf_depqbf_cclib"; "ocamlmklib"; "c"], - [(OASISExpr.EBool true, S [A "-L/usr/local/lib"; A "-lqdpll"])]) + [ + (OASISExpr.EBool true, S []); + (OASISExpr.ETest ("system", "macosx"), + S [A "-force_load"; A "/usr/local/lib/libqdpll.a"]); + (OASISExpr.ENot (OASISExpr.ETest ("system", "macosx")), + S [A "-L/usr/local/lib"; A "-lqdpll"]) + ]) ]; includes = [ @@ -948,6 +963,6 @@ let conf = {MyOCamlbuildFindlib.no_automatic_syntax = false} let dispatch_default = MyOCamlbuildBase.dispatch_default conf package_default;; -# 952 "myocamlbuild.ml" +# 967 "myocamlbuild.ml" (* OASIS_STOP *) Ocamlbuild_plugin.dispatch dispatch_default;; diff --git a/setup.ml b/setup.ml index 77f5789..61321e2 100644 --- a/setup.ml +++ b/setup.ml @@ -1,9 +1,9 @@ (* setup.ml generated for the first time by OASIS v0.4.5 *) (* OASIS_START *) -(* DO NOT EDIT (digest: 14ce46a41e04f605c23fdafce0b3eff0) *) +(* DO NOT EDIT (digest: 05029dd4d92564ba7404305910398aec) *) (* - Regenerated by OASIS v0.4.9~HEAD + Regenerated by OASIS v0.4.10 Visit http://oasis.forge.ocamlcore.org for more information and documentation about functions used in this file. *) @@ -6010,17 +6010,14 @@ module InternalInstallPlugin = struct let install = - let in_destdir = + let in_destdir fn = try - let destdir = - destdir () - in - (* Practically speaking destdir is prepended - * at the beginning of the target filename - *) - fun fn -> destdir^fn + (* Practically speaking destdir is prepended at the beginning of the + target filename + *) + (destdir ())^fn with PropList.Not_set _ -> - fun fn -> fn + fn in let install_file ~ctxt ?(prepend_destdir=true) ?tgt_fn src_file envdir = @@ -6465,7 +6462,7 @@ module InternalInstallPlugin = struct end -# 6468 "setup.ml" +# 6465 "setup.ml" module OCamlbuildCommon = struct (* # 22 "src/plugins/ocamlbuild/OCamlbuildCommon.ml" *) @@ -6837,7 +6834,7 @@ module OCamlbuildDocPlugin = struct end -# 6840 "setup.ml" +# 6837 "setup.ml" module CustomPlugin = struct (* # 22 "src/plugins/custom/CustomPlugin.ml" *) @@ -6969,7 +6966,7 @@ module CustomPlugin = struct end -# 6972 "setup.ml" +# 6969 "setup.ml" open OASISTypes;; let setup_t = @@ -7577,7 +7574,11 @@ let setup_t = bs_ccopt = [(OASISExpr.EBool true, [])]; bs_cclib = [ - (OASISExpr.EBool true, + (OASISExpr.EBool true, []); + (OASISExpr.ETest ("system", "macosx"), + ["-force_load"; "/usr/local/lib/libqdpll.a"]); + (OASISExpr.ENot + (OASISExpr.ETest ("system", "macosx")), ["-L/usr/local/lib"; "-lqdpll"]) ]; bs_dlllib = [(OASISExpr.EBool true, [])]; @@ -8242,8 +8243,9 @@ let setup_t = plugin_data = [] }; oasis_fn = Some "_oasis"; - oasis_version = "0.4.9~HEAD"; - oasis_digest = Some "@\138*M\253b\147\182\215\148?,|t\157k"; + oasis_version = "0.4.10"; + oasis_digest = + Some "\001\r\206\219\027\011\185'\236s\139\r\164\225\018\241"; oasis_exec = None; oasis_setup_args = []; setup_update = false @@ -8251,7 +8253,7 @@ let setup_t = let setup () = BaseSetup.setup setup_t;; -# 8255 "setup.ml" +# 8257 "setup.ml" let setup_t = BaseCompat.Compat_0_4.adapt_setup_t setup_t open BaseCompat.Compat_0_4 (* OASIS_STOP *) diff --git a/tests/depqbf/test_depqbf3.ml b/tests/depqbf/test_depqbf3.ml index 205d292..9237e5b 100644 --- a/tests/depqbf/test_depqbf3.ml +++ b/tests/depqbf/test_depqbf3.ml @@ -10,6 +10,7 @@ let add_clause s l = let test_depqbf3 _ = let s = D.create () in D.configure s "--incremental-use"; + D.configure s "--dep-man=simple"; let level1 = D.new_scope s Qbf.Forall in D.add s (mk 1); D.add s (mk 2);