VBoxCAPIGlue.h.in revision 681bb0bf6e9ab5a590d8afcdf37634e2fc29f595
1f1c37d7ffc2ad3691d79dab619d2198d2d9671avboxsync/* $Revision$ */
ebb33f3aef3b410579a2865109426b798b9d4a9dvboxsync/** @file VBoxCAPIGlue.h
ebb33f3aef3b410579a2865109426b798b9d4a9dvboxsync * Glue for dynamically linking with VBoxCAPI.
ebb33f3aef3b410579a2865109426b798b9d4a9dvboxsync */
ebb33f3aef3b410579a2865109426b798b9d4a9dvboxsync
1f1c37d7ffc2ad3691d79dab619d2198d2d9671avboxsync/*
1f1c37d7ffc2ad3691d79dab619d2198d2d9671avboxsync * Copyright (C) 2008-2014 Oracle Corporation
1f1c37d7ffc2ad3691d79dab619d2198d2d9671avboxsync *
1f1c37d7ffc2ad3691d79dab619d2198d2d9671avboxsync * Permission is hereby granted, free of charge, to any person
1f1c37d7ffc2ad3691d79dab619d2198d2d9671avboxsync * obtaining a copy of this software and associated documentation
1f1c37d7ffc2ad3691d79dab619d2198d2d9671avboxsync * files (the "Software"), to deal in the Software without
1f1c37d7ffc2ad3691d79dab619d2198d2d9671avboxsync * restriction, including without limitation the rights to use,
e3d572a564407dd48032ee00624e305353dbf966vboxsync * copy, modify, merge, publish, distribute, sublicense, and/or sell
1f1c37d7ffc2ad3691d79dab619d2198d2d9671avboxsync * copies of the Software, and to permit persons to whom the
a74782eac5771b0de57834e8c8c0247c55e8dd57vboxsync * Software is furnished to do so, subject to the following
a74782eac5771b0de57834e8c8c0247c55e8dd57vboxsync * conditions:
a74782eac5771b0de57834e8c8c0247c55e8dd57vboxsync *
a74782eac5771b0de57834e8c8c0247c55e8dd57vboxsync * The above copyright notice and this permission notice shall be
a74782eac5771b0de57834e8c8c0247c55e8dd57vboxsync * included in all copies or substantial portions of the Software.
a74782eac5771b0de57834e8c8c0247c55e8dd57vboxsync *
a74782eac5771b0de57834e8c8c0247c55e8dd57vboxsync * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
1f1c37d7ffc2ad3691d79dab619d2198d2d9671avboxsync * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
1f1c37d7ffc2ad3691d79dab619d2198d2d9671avboxsync * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
1f1c37d7ffc2ad3691d79dab619d2198d2d9671avboxsync * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
1f1c37d7ffc2ad3691d79dab619d2198d2d9671avboxsync * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
1f1c37d7ffc2ad3691d79dab619d2198d2d9671avboxsync * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
1f1c37d7ffc2ad3691d79dab619d2198d2d9671avboxsync * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
1f1c37d7ffc2ad3691d79dab619d2198d2d9671avboxsync * OTHER DEALINGS IN THE SOFTWARE.
1f1c37d7ffc2ad3691d79dab619d2198d2d9671avboxsync */
1f1c37d7ffc2ad3691d79dab619d2198d2d9671avboxsync
1f1c37d7ffc2ad3691d79dab619d2198d2d9671avboxsync#ifndef ___VBoxCAPIGlue_h
1f1c37d7ffc2ad3691d79dab619d2198d2d9671avboxsync#define ___VBoxCAPIGlue_h
1f1c37d7ffc2ad3691d79dab619d2198d2d9671avboxsync
1f1c37d7ffc2ad3691d79dab619d2198d2d9671avboxsync#undef VBOX_WITH_GLUE
ebb33f3aef3b410579a2865109426b798b9d4a9dvboxsync#define VBOX_WITH_GLUE
ebb33f3aef3b410579a2865109426b798b9d4a9dvboxsync#include "VBoxCAPI_v@VBOX_API_VERSION@.h"
ebb33f3aef3b410579a2865109426b798b9d4a9dvboxsync
ebb33f3aef3b410579a2865109426b798b9d4a9dvboxsync#ifdef __cplusplus
1f1c37d7ffc2ad3691d79dab619d2198d2d9671avboxsyncextern "C" {
1f1c37d7ffc2ad3691d79dab619d2198d2d9671avboxsync#endif
1f1c37d7ffc2ad3691d79dab619d2198d2d9671avboxsync
9019681d4e9b8399b951793a9dd92b63c195e0eevboxsync/** The so/dynsym/dll handle for VBoxCAPI. */
1f1c37d7ffc2ad3691d79dab619d2198d2d9671avboxsync#ifndef WIN32
1cc3bd5463294790ba54c78fde5313264185e50cvboxsyncextern void *g_hVBoxCAPI;
1cc3bd5463294790ba54c78fde5313264185e50cvboxsync#else
c239ce2529e2ea4f9180a28c3ec89876bbb47938vboxsyncextern HMODULE g_hVBoxCAPI;
c239ce2529e2ea4f9180a28c3ec89876bbb47938vboxsync#endif
c239ce2529e2ea4f9180a28c3ec89876bbb47938vboxsync/** The last load error. */
c239ce2529e2ea4f9180a28c3ec89876bbb47938vboxsyncextern char g_szVBoxErrMsg[256];
c239ce2529e2ea4f9180a28c3ec89876bbb47938vboxsync/** Pointer to the VBOXCAPI function table. */
c239ce2529e2ea4f9180a28c3ec89876bbb47938vboxsyncextern PCVBOXCAPI g_pVBoxFuncs;
c239ce2529e2ea4f9180a28c3ec89876bbb47938vboxsync/** Pointer to VBoxGetCAPIFunctions for the loaded VBoxCAPI so/dylib/dll. */
c239ce2529e2ea4f9180a28c3ec89876bbb47938vboxsyncextern PFNVBOXGETCAPIFUNCTIONS g_pfnGetFunctions;
c239ce2529e2ea4f9180a28c3ec89876bbb47938vboxsync
c239ce2529e2ea4f9180a28c3ec89876bbb47938vboxsync
c239ce2529e2ea4f9180a28c3ec89876bbb47938vboxsyncint VBoxCGlueInit(void);
c239ce2529e2ea4f9180a28c3ec89876bbb47938vboxsyncvoid VBoxCGlueTerm(void);
1f1c37d7ffc2ad3691d79dab619d2198d2d9671avboxsync
1f1c37d7ffc2ad3691d79dab619d2198d2d9671avboxsync
1cc3bd5463294790ba54c78fde5313264185e50cvboxsync#ifdef __cplusplus
681bb0bf6e9ab5a590d8afcdf37634e2fc29f595vboxsync}
1f1c37d7ffc2ad3691d79dab619d2198d2d9671avboxsync#endif
ebb33f3aef3b410579a2865109426b798b9d4a9dvboxsync
ebb33f3aef3b410579a2865109426b798b9d4a9dvboxsync#endif
ebb33f3aef3b410579a2865109426b798b9d4a9dvboxsync
ebb33f3aef3b410579a2865109426b798b9d4a9dvboxsync