Browse Source

dune: port to dune

Spiros Eliopoulos 2 years ago
parent
commit
e521d4f703
17 changed files with 60 additions and 81 deletions
  1. 6 7
      Makefile
  2. 5 0
      async/dune
  3. 0 9
      async/jbuild
  4. 8 0
      examples/dune
  5. 0 11
      examples/jbuild
  6. 4 4
      faraday-async.opam
  7. 4 4
      faraday-lwt-unix.opam
  8. 4 4
      faraday-lwt.opam
  9. 4 4
      faraday.opam
  10. 5 0
      lib/dune
  11. 0 8
      lib/jbuild
  12. 10 0
      lib_test/dune
  13. 0 12
      lib_test/jbuild
  14. 5 0
      lwt/dune
  15. 0 9
      lwt/jbuild
  16. 5 0
      lwt_unix/dune
  17. 0 9
      lwt_unix/jbuild

+ 6 - 7
Makefile

@@ -1,25 +1,24 @@
 .PHONY: all build clean test examples
 
 build:
-	jbuilder build @install --dev
+	dune build @install
 
 all: build
 
 doc:
-	jbuilder build @doc
+	dune build @doc
 
 test:
-	jbuilder runtest --dev
+	dune runtest
 
 examples:
-	jbuilder build @examples
+	dune build @examples
 
 install:
-	jbuilder install
+	dune install
 
 uninstall:
-	jbuilder uninstall
+	dune uninstall
 
 clean:
 	rm -rf _build *.install
-

+ 5 - 0
async/dune

@@ -0,0 +1,5 @@
+(library
+ (name        faraday_async)
+ (public_name faraday-async)
+ (libraries   faraday async)
+ (flags (:standard -safe-string)))

+ 0 - 9
async/jbuild

@@ -1,9 +0,0 @@
-(jbuild_version 1)
-
-(library
- ((name        faraday_async)
-  (public_name faraday-async)
-  (wrapped false)
-  (libraries 
-    (faraday async))
-  (flags (:standard -safe-string))))

+ 8 - 0
examples/dune

@@ -0,0 +1,8 @@
+(library
+ (name      RFC7159)
+ (modules   RFC7159)
+ (libraries faraday))
+
+(alias
+ (name examples)
+ (deps RFC7159.cmxa))

+ 0 - 11
examples/jbuild

@@ -1,11 +0,0 @@
-(jbuild_version 1)
-
-(library
- ((name RFC7159)
-  (wrapped false)
-  (modules RFC7159)
-  (libraries (faraday))))
-
-(alias
- ((name examples)
-  (deps (RFC7159.cmxa))))

+ 4 - 4
faraday-async.opam

@@ -6,13 +6,13 @@ homepage: "https://github.com/inhabitedtype/faraday"
 bug-reports: "https://github.com/inhabitedtype/faraday/issues"
 dev-repo: "git+https://github.com/inhabitedtype/faraday.git"
 build: [
-  ["jbuilder" "subst" "-p" name] {pinned}
-  ["jbuilder" "build" "-p" name "-j" jobs]
-  ["jbuilder" "runtest" "-p" name] {with-test}
+  ["dune" "subst"] {pinned}
+  ["dune" "build" "-p" name "-j" jobs]
+  ["dune" "runtest" "-p" name] {with-test}
 ]
 depends: [
   "ocaml" {>= "4.02.0"}
-  "jbuilder" {build & >= "1.0+beta10"}
+  "dune" {build & >= "1.0"}
   "faraday" {>= "0.5.0"}
   "async" {>= "v0.9.0"}
 ]

+ 4 - 4
faraday-lwt-unix.opam

@@ -6,13 +6,13 @@ homepage: "https://github.com/inhabitedtype/faraday"
 bug-reports: "https://github.com/inhabitedtype/faraday/issues"
 dev-repo: "git+https://github.com/inhabitedtype/faraday.git"
 build: [
-  ["jbuilder" "subst" "-p" name] {pinned}
-  ["jbuilder" "build" "-p" name "-j" jobs]
-  ["jbuilder" "runtest" "-p" name] {with-test}
+  ["dune" "subst"] {pinned}
+  ["dune" "build" "-p" name "-j" jobs]
+  ["dune" "runtest" "-p" name] {with-test}
 ]
 depends: [
   "ocaml" {>= "4.02.0"}
-  "jbuilder" {build & >= "1.0+beta10"}
+  "dune" {build & >= "1.0"}
   "faraday-lwt"
   "lwt" {>= "2.7.0"}
   "base-unix"

+ 4 - 4
faraday-lwt.opam

@@ -6,13 +6,13 @@ homepage: "https://github.com/inhabitedtype/faraday"
 bug-reports: "https://github.com/inhabitedtype/faraday/issues"
 dev-repo: "git+https://github.com/inhabitedtype/faraday.git"
 build: [
-  ["jbuilder" "subst" "-p" name] {pinned}
-  ["jbuilder" "build" "-p" name "-j" jobs]
-  ["jbuilder" "runtest" "-p" name] {with-test}
+  ["dune" "subst"] {pinned}
+  ["dune" "build" "-p" name "-j" jobs]
+  ["dune" "runtest" "-p" name] {with-test}
 ]
 depends: [
   "ocaml" {>= "4.02.0"}
-  "jbuilder" {build & >= "1.0+beta10"}
+  "dune" {build & >= "1.0+beta10"}
   "faraday" {>= "0.5.0"}
   "lwt"
 ]

+ 4 - 4
faraday.opam

@@ -6,13 +6,13 @@ homepage: "https://github.com/inhabitedtype/faraday"
 bug-reports: "https://github.com/inhabitedtype/faraday/issues"
 dev-repo: "git+https://github.com/inhabitedtype/faraday.git"
 build: [
-  ["jbuilder" "subst" "-p" name] {pinned}
-  ["jbuilder" "build" "-p" name "-j" jobs]
-  ["jbuilder" "runtest" "-p" name] {with-test}
+  ["dune" "subst"] {pinned}
+  ["dune" "build" "-p" name "-j" jobs]
+  ["dune" "runtest" "-p" name] {with-test}
 ]
 depends: [
   "ocaml" {>= "4.02.0"}
-  "jbuilder" {build & >= "1.0+beta10"}
+  "dune" {build & >= "1.0"}
   "alcotest" {with-test & >= "0.4.1"}
   "bigstringaf"
 ]

+ 5 - 0
lib/dune

@@ -0,0 +1,5 @@
+(library
+ (name        faraday)
+ (public_name faraday)
+ (libraries   bigstringaf)
+ (flags (:standard -safe-string)))

+ 0 - 8
lib/jbuild

@@ -1,8 +0,0 @@
-(jbuild_version 1)
-
-(library
- ((name        faraday)
-  (public_name faraday)
-  (libraries
-    (bigstringaf))
-  (flags (:standard -safe-string))))

+ 10 - 0
lib_test/dune

@@ -0,0 +1,10 @@
+(executables
+ (libraries alcotest faraday)
+ (modules   test_faraday)
+ (names     test_faraday))
+
+(alias
+ (name    runtest)
+ (package faraday)
+ (deps    test_faraday.exe)
+ (action  (run ${<})))

+ 0 - 12
lib_test/jbuild

@@ -1,12 +0,0 @@
-(jbuild_version 1)
-
-(executables
- ((libraries (alcotest faraday))
-  (modules (test_faraday))
-  (names (test_faraday))))
-
-(alias
- ((name    runtest)
-  (package faraday)
-  (deps    (test_faraday.exe))
-  (action  (run ${<}))))

+ 5 - 0
lwt/dune

@@ -0,0 +1,5 @@
+(library
+ (name        faraday_lwt)
+ (public_name faraday-lwt)
+ (libraries   faraday lwt)
+ (flags (:standard -safe-string)))

+ 0 - 9
lwt/jbuild

@@ -1,9 +0,0 @@
-(jbuild_version 1)
-
-(library
- ((name        faraday_lwt)
-  (public_name faraday-lwt)
-  (wrapped false)
-  (libraries
-    (faraday lwt))
-  (flags (:standard -safe-string))))

+ 5 - 0
lwt_unix/dune

@@ -0,0 +1,5 @@
+(library
+ (name        faraday_lwt_unix)
+ (public_name faraday-lwt-unix)
+ (libraries   faraday lwt lwt.unix faraday-lwt)
+ (flags (:standard -safe-string)))

+ 0 - 9
lwt_unix/jbuild

@@ -1,9 +0,0 @@
-(jbuild_version 1)
-
-(library
- ((name        faraday_lwt_unix)
-  (public_name faraday-lwt-unix)
-  (wrapped false)
-  (libraries
-    (faraday lwt lwt.unix faraday-lwt))
-  (flags (:standard -safe-string))))