Skip to content

Commit

Permalink
go back to libdash.install approach
Browse files Browse the repository at this point in the history
  • Loading branch information
mgree committed Feb 25, 2020
1 parent 448724b commit d384c3b
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 6 deletions.
4 changes: 3 additions & 1 deletion libdash.opam
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ depends: [
"ocamlfind" {>= "1.8.0"}
"ctypes" {>= "0.11.5"}
"ctypes-foreign" {>= "0.4.0"}
"opam-installer" {>= "2.0.0"}
"conf-autoconf" {build}
# "conf-libtool" {build}
]
Expand All @@ -27,11 +28,12 @@ build: [
[make]
[make "install"] # into _build
[make "-C" "ocaml" "all"]
["./mk_dot_install.sh"]
["./ldconfig.sh"] # fix up .so files if ldconfig didn't do it
[make "-C" "ocaml" "test"] {with-test}
]
install: [
["./libdash_install.sh"] # autotools borks if we call it install.sh, lol
["opam-installer" "--prefix=%{prefix}%" "libdash.install"]
[make "-C" "test" "test"] {with-test}
]
dev-repo: "git+https:///github.com/mgree/libdash"
Expand Down
13 changes: 8 additions & 5 deletions libdash_install.sh → mk_dot_install.sh
Original file line number Diff line number Diff line change
@@ -1,19 +1,22 @@
#!/bin/bash
#!/bin/sh

set -ex
set -e

libdash_files=$(ls _build/lib)
bindings_files="META dash.cmxa dash.cma dash.a dash.mli dash.cmi dash.cmo dash.cmx ast.mli ast.cmi ast.cmo ast.cmx"

files=
for f in ${libdash_files}
do
files="${files} _build/lib/${f}"
files="${files} \"_build/lib/${f}\""
done

for f in ${bindings_files}
do
files="${files} ocaml/${f}"
files="${files} \"ocaml/${f}\""
done

ocamlfind install libdash -nodll $files
cat >libdash.install <<EOF
lib: [${files} ]
EOF

0 comments on commit d384c3b

Please sign in to comment.