Skip to content

Commit 3b12597

Browse files
committed
Merge pull request #74 from djs55/release.0.9.28
Release.0.9.28
2 parents bae5270 + 60d3011 commit 3b12597

File tree

10 files changed

+221
-141
lines changed

10 files changed

+221
-141
lines changed

CHANGES

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,18 @@
1-
0.9.27 (8-Oct-2014)
1+
0.9.28 (20-Nov-2014):
2+
* xenlight: improve error message when parsing an invalid enum
3+
* xentoollog: make this a toplevel ocamlfind package
4+
5+
0.9.27 (8-Oct-2014):
26
* Fix build on Fedora 21 (by removing -DBSD_SOURCE)
37
* Fix 'configure' on OS X
48

5-
0.9.26 (10-Sep-2014)
9+
0.9.26 (10-Sep-2014):
610
* improve configure to detect libxc backports
711

8-
0.9.22 (23-Aug-2014)
12+
0.9.22 (23-Aug-2014):
913
* only build xenlight on xen-4.4 and xen-4.5 (xen-4.2 is too old)
1014

11-
0.9.21 (20-Aug-2014)
15+
0.9.21 (20-Aug-2014):
1216
* experimental support for xen 4.5 (currently in development)
1317

1418
0.9.20 (4-Jul-2014):

_oasis

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
OASISFormat: 0.3
22
Name: xen-lowlevel-libs
3-
Version: 0.9.27
3+
Version: 0.9.28
44
Synopsis: Xen low-level bindings
55
Authors: see xen-unstable.hg
66
License: LGPL-2.1 with OCaml linking exception

_tags

Lines changed: 16 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
11
# OASIS_START
2-
# DO NOT EDIT (digest: f6c047538f172bb38d227f6df44ea396)
2+
# DO NOT EDIT (digest: dcd3ef160e8ae5b99cd33fed790be7b6)
33
# Ignore VCS directories, you can use the same kind of rule outside
44
# OASIS_START/STOP if you want to exclude directories that contains
55
# useless stuff for the build process
6+
true: annot, bin_annot
67
<**/.svn>: -traverse
78
<**/.svn>: not_hygienic
89
".bzr": -traverse
@@ -15,7 +16,7 @@
1516
"_darcs": not_hygienic
1617
# Library xenctrl
1718
"lib/xenctrl.cmxs": use_xenctrl
18-
<lib/*.ml{,i}>: oasis_library_xenctrl_ccopt
19+
<lib/*.ml{,i,y}>: oasis_library_xenctrl_ccopt
1920
"lib/xenmmap_stubs.c": oasis_library_xenctrl_ccopt
2021
"lib/xenctrl_stubs.c": oasis_library_xenctrl_ccopt
2122
<lib/xenctrl.{cma,cmxa}>: oasis_library_xenctrl_cclib
@@ -24,9 +25,9 @@
2425
"lib/libxenctrl_stubs.a": oasis_library_xenctrl_cclib
2526
"lib/dllxenctrl_stubs.so": oasis_library_xenctrl_cclib
2627
<lib/xenctrl.{cma,cmxa}>: use_libxenctrl_stubs
27-
<lib/*.ml{,i}>: pkg_bigarray
28-
<lib/*.ml{,i}>: pkg_lwt
29-
<lib/*.ml{,i}>: pkg_unix
28+
<lib/*.ml{,i,y}>: pkg_bigarray
29+
<lib/*.ml{,i,y}>: pkg_lwt
30+
<lib/*.ml{,i,y}>: pkg_unix
3031
"lib/xenmmap_stubs.c": pkg_bigarray
3132
"lib/xenmmap_stubs.c": pkg_lwt
3233
"lib/xenmmap_stubs.c": pkg_unix
@@ -49,7 +50,7 @@
4950
"xenlight/libxenlight_stubs.a": oasis_library_xenlight_cclib
5051
"xenlight/dllxenlight_stubs.so": oasis_library_xenlight_cclib
5152
<xenlight/xenlight.{cma,cmxa}>: use_libxenlight_stubs
52-
<xenlight/*.ml{,i}>: use_xentoollog
53+
<xenlight/*.ml{,i,y}>: use_xentoollog
5354
"xenlight/xenlight_stubs.c": use_xentoollog
5455
# Library xenguest42
5556
"xenguest-4.2/xenguest42.cmxs": use_xenguest42
@@ -65,21 +66,21 @@
6566
<xenguest-4.2/xenguest_main.{native,byte}>: pkg_unix
6667
<xenguest-4.2/xenguest_main.{native,byte}>: use_xenctrl
6768
<xenguest-4.2/xenguest_main.{native,byte}>: use_xenguest42
68-
<xenguest-4.2/*.ml{,i}>: pkg_bigarray
69-
<xenguest-4.2/*.ml{,i}>: pkg_lwt
70-
<xenguest-4.2/*.ml{,i}>: pkg_unix
71-
<xenguest-4.2/*.ml{,i}>: use_xenctrl
72-
<xenguest-4.2/*.ml{,i}>: use_xenguest42
69+
<xenguest-4.2/*.ml{,i,y}>: pkg_bigarray
70+
<xenguest-4.2/*.ml{,i,y}>: pkg_lwt
71+
<xenguest-4.2/*.ml{,i,y}>: pkg_unix
72+
<xenguest-4.2/*.ml{,i,y}>: use_xenctrl
73+
<xenguest-4.2/*.ml{,i,y}>: use_xenguest42
7374
<xenguest-4.2/xenguest_main.{native,byte}>: custom
7475
# Executable test_hvm_check_pvdriver
7576
<test/test_hvm_check_pvdriver.{native,byte}>: pkg_bigarray
7677
<test/test_hvm_check_pvdriver.{native,byte}>: pkg_lwt
7778
<test/test_hvm_check_pvdriver.{native,byte}>: pkg_unix
7879
<test/test_hvm_check_pvdriver.{native,byte}>: use_xenctrl
79-
<test/*.ml{,i}>: pkg_bigarray
80-
<test/*.ml{,i}>: pkg_lwt
81-
<test/*.ml{,i}>: pkg_unix
82-
<test/*.ml{,i}>: use_xenctrl
80+
<test/*.ml{,i,y}>: pkg_bigarray
81+
<test/*.ml{,i,y}>: pkg_lwt
82+
<test/*.ml{,i,y}>: pkg_unix
83+
<test/*.ml{,i,y}>: use_xenctrl
8384
<test/test_hvm_check_pvdriver.{native,byte}>: custom
8485
# OASIS_STOP
8586
<configure.*>: not_hygienic

lib/META

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# OASIS_START
2-
# DO NOT EDIT (digest: 87531aa00c7638cca3c97f1251236560)
3-
version = "0.9.27"
2+
# DO NOT EDIT (digest: 63cf6d08ce51ba1896c6512b631d38f0)
3+
version = "0.9.28"
44
description = "Xen low-level bindings"
55
requires = "unix lwt bigarray"
66
archive(byte) = "xenctrl.cma"

myocamlbuild.ml

Lines changed: 51 additions & 37 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
(* OASIS_START *)
2-
(* DO NOT EDIT (digest: 6b9712fdcc5513f395197a91737c8fc6) *)
2+
(* DO NOT EDIT (digest: ea1ac9da767156053202faa58b513a28) *)
33
module OASISGettext = struct
44
(* # 22 "src/oasis/OASISGettext.ml" *)
55

@@ -249,6 +249,9 @@ module MyOCamlbuildFindlib = struct
249249
*)
250250
open Ocamlbuild_plugin
251251

252+
type conf =
253+
{ no_automatic_syntax: bool;
254+
}
252255

253256
(* these functions are not really officially exported *)
254257
let run_and_read =
@@ -315,7 +318,7 @@ module MyOCamlbuildFindlib = struct
315318

316319
(* This lists all supported packages. *)
317320
let find_packages () =
318-
List.map before_space (split_nl & run_and_read "ocamlfind list")
321+
List.map before_space (split_nl & run_and_read (exec_from_conf "ocamlfind" ^ " list"))
319322

320323

321324
(* Mock to list available syntaxes. *)
@@ -338,7 +341,7 @@ module MyOCamlbuildFindlib = struct
338341
]
339342

340343

341-
let dispatch =
344+
let dispatch conf =
342345
function
343346
| After_options ->
344347
(* By using Before_options one let command line options have an higher
@@ -357,31 +360,39 @@ module MyOCamlbuildFindlib = struct
357360
* -linkpkg *)
358361
flag ["ocaml"; "link"; "program"] & A"-linkpkg";
359362

360-
(* For each ocamlfind package one inject the -package option when
361-
* compiling, computing dependencies, generating documentation and
362-
* linking. *)
363-
List.iter
364-
begin fun pkg ->
365-
let base_args = [A"-package"; A pkg] in
366-
(* TODO: consider how to really choose camlp4o or camlp4r. *)
367-
let syn_args = [A"-syntax"; A "camlp4o"] in
368-
let args =
369-
(* Heuristic to identify syntax extensions: whether they end in
370-
".syntax"; some might not.
371-
*)
372-
if Filename.check_suffix pkg "syntax" ||
373-
List.mem pkg well_known_syntax then
374-
syn_args @ base_args
375-
else
376-
base_args
377-
in
378-
flag ["ocaml"; "compile"; "pkg_"^pkg] & S args;
379-
flag ["ocaml"; "ocamldep"; "pkg_"^pkg] & S args;
380-
flag ["ocaml"; "doc"; "pkg_"^pkg] & S args;
381-
flag ["ocaml"; "link"; "pkg_"^pkg] & S base_args;
382-
flag ["ocaml"; "infer_interface"; "pkg_"^pkg] & S args;
383-
end
384-
(find_packages ());
363+
if not (conf.no_automatic_syntax) then begin
364+
(* For each ocamlfind package one inject the -package option when
365+
* compiling, computing dependencies, generating documentation and
366+
* linking. *)
367+
List.iter
368+
begin fun pkg ->
369+
let base_args = [A"-package"; A pkg] in
370+
(* TODO: consider how to really choose camlp4o or camlp4r. *)
371+
let syn_args = [A"-syntax"; A "camlp4o"] in
372+
let (args, pargs) =
373+
(* Heuristic to identify syntax extensions: whether they end in
374+
".syntax"; some might not.
375+
*)
376+
if Filename.check_suffix pkg "syntax" ||
377+
List.mem pkg well_known_syntax then
378+
(syn_args @ base_args, syn_args)
379+
else
380+
(base_args, [])
381+
in
382+
flag ["ocaml"; "compile"; "pkg_"^pkg] & S args;
383+
flag ["ocaml"; "ocamldep"; "pkg_"^pkg] & S args;
384+
flag ["ocaml"; "doc"; "pkg_"^pkg] & S args;
385+
flag ["ocaml"; "link"; "pkg_"^pkg] & S base_args;
386+
flag ["ocaml"; "infer_interface"; "pkg_"^pkg] & S args;
387+
388+
(* TODO: Check if this is allowed for OCaml < 3.12.1 *)
389+
flag ["ocaml"; "compile"; "package("^pkg^")"] & S pargs;
390+
flag ["ocaml"; "ocamldep"; "package("^pkg^")"] & S pargs;
391+
flag ["ocaml"; "doc"; "package("^pkg^")"] & S pargs;
392+
flag ["ocaml"; "infer_interface"; "package("^pkg^")"] & S pargs;
393+
end
394+
(find_packages ());
395+
end;
385396

386397
(* Like -package but for extensions syntax. Morover -syntax is useless
387398
* when linking. *)
@@ -546,12 +557,13 @@ module MyOCamlbuildBase = struct
546557

547558
(* When ocaml link something that use the C library, then one
548559
need that file to be up to date.
560+
This holds both for programs and for libraries.
549561
*)
550-
dep ["link"; "ocaml"; "program"; tag_libstubs lib]
551-
[dir/"lib"^(nm_libstubs lib)^"."^(!Options.ext_lib)];
562+
dep ["link"; "ocaml"; tag_libstubs lib]
563+
[dir/"lib"^(nm_libstubs lib)^"."^(!Options.ext_lib)];
552564

553-
dep ["compile"; "ocaml"; "program"; tag_libstubs lib]
554-
[dir/"lib"^(nm_libstubs lib)^"."^(!Options.ext_lib)];
565+
dep ["compile"; "ocaml"; tag_libstubs lib]
566+
[dir/"lib"^(nm_libstubs lib)^"."^(!Options.ext_lib)];
555567

556568
(* TODO: be more specific about what depends on headers *)
557569
(* Depends on .h files *)
@@ -580,18 +592,18 @@ module MyOCamlbuildBase = struct
580592
()
581593

582594

583-
let dispatch_default t =
595+
let dispatch_default conf t =
584596
dispatch_combine
585597
[
586598
dispatch t;
587-
MyOCamlbuildFindlib.dispatch;
599+
MyOCamlbuildFindlib.dispatch conf;
588600
]
589601

590602

591603
end
592604

593605

594-
# 594 "myocamlbuild.ml"
606+
# 606 "myocamlbuild.ml"
595607
open Ocamlbuild_plugin;;
596608
let package_default =
597609
{
@@ -695,8 +707,10 @@ let package_default =
695707
}
696708
;;
697709

698-
let dispatch_default = MyOCamlbuildBase.dispatch_default package_default;;
710+
let conf = {MyOCamlbuildFindlib.no_automatic_syntax = false}
711+
712+
let dispatch_default = MyOCamlbuildBase.dispatch_default conf package_default;;
699713

700-
# 701 "myocamlbuild.ml"
714+
# 715 "myocamlbuild.ml"
701715
(* OASIS_STOP *)
702716
Ocamlbuild_plugin.dispatch dispatch_default;;

opam

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
opam-version: "1"
2+
maintainer: "[email protected]"
3+
tags: [
4+
"org:mirage"
5+
"org:xapi-project"
6+
]
7+
build: [
8+
["./configure"]
9+
[make]
10+
[make "install" "BINDIR=%{bin}%"]
11+
]
12+
remove: [
13+
[make "uninstall"]
14+
]
15+
depends: [
16+
"ocamlfind"
17+
"lwt"
18+
"cmdliner"
19+
]
20+
depexts: [
21+
[["debian"] ["libxen-dev" "uuid-dev"]]
22+
[["ubuntu"] ["libxen-dev" "uuid-dev"]]
23+
[["centos"] ["xen-devel"]]
24+
[["xenserver"] ["xen-dom0-libs-devel" "xen-libs-devel"]]
25+
]
26+
ocaml-version: [>= "4.00.0"]

0 commit comments

Comments
 (0)