[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-changelog] [xen master] xenlight_stubs.c: Allow it to build with ocaml 3.09.3
commit 3413b6a923839446c51a7612b19c5dc33b8aa6bc Author: Don Slutz <dslutz@xxxxxxxxxxx> AuthorDate: Fri Feb 7 16:51:51 2014 -0500 Commit: Ian Campbell <ian.campbell@xxxxxxxxxx> CommitDate: Tue Feb 11 12:44:46 2014 +0000 xenlight_stubs.c: Allow it to build with ocaml 3.09.3 This code was copied from: http://docs.camlcity.org/docs/godisrc/oasis-ocaml-fd-1.1.1.tar.gz/ocaml-fd-1.1.1/lib/fd_stubs.c Signed-off-by: Don Slutz <dslutz@xxxxxxxxxxx> Acked-by: David Scott <dave.scott@xxxxxxxxxx> Acked-by: Ian Campbell <ian.campbell@xxxxxxxxxx> --- tools/ocaml/libs/xl/xenlight_stubs.c | 13 +++++++++++++ 1 files changed, 13 insertions(+), 0 deletions(-) diff --git a/tools/ocaml/libs/xl/xenlight_stubs.c b/tools/ocaml/libs/xl/xenlight_stubs.c index 23f253a..8e825ae 100644 --- a/tools/ocaml/libs/xl/xenlight_stubs.c +++ b/tools/ocaml/libs/xl/xenlight_stubs.c @@ -35,6 +35,19 @@ #include "caml_xentoollog.h" +/* + * Starting with ocaml-3.09.3, CAMLreturn can only be used for ``value'' + * types. CAMLreturnT was only added in 3.09.4, so we define our own + * version here if needed. + */ +#ifndef CAMLreturnT +#define CAMLreturnT(type, result) do { \ + type caml__temp_result = (result); \ + caml_local_roots = caml__frame; \ + return (caml__temp_result); \ +} while (0) +#endif + /* The following is equal to the CAMLreturn macro, but without the return */ #define CAMLdone do{ \ caml_local_roots = caml__frame; \ -- generated by git-patchbot for /home/xen/git/xen.git#master _______________________________________________ Xen-changelog mailing list Xen-changelog@xxxxxxxxxxxxx http://lists.xensource.com/xen-changelog
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |