We help IT Professionals succeed at work.
Get Started

I need your assistance and comment how I can enhance the Visual Studio Project

mjs2011
mjs2011 asked
on
44 Views
Last Modified: 2020-09-26
Hello I have an issue when I tried to compiled Visual studio project , I got from GitHub and I follow all instruction but still I have an issues attached

Visual studio cannot debugging because target  file exe file is missing , Please build the project and retry

Severity      Code      Description      Project      File      Line      Suppression State
Error      C2733      'CreateEnclave': you cannot overload a function with 'extern "C"' linkage      EnclaveLink      C:\Users\m_swe\source\repos\Trustee\TLSLIB\Include\enclaveapi.h      117      


// begin_1_0

/********************************************************************************

*                                                                               *

* enclaveapi.h -- ApiSet Contract for api-ms-win-core-enclave-l1-1-0            *

*                                                                               *

* Copyright (c) Microsoft Corporation. All rights reserved.                     *

*                                                                               *

********************************************************************************/



#ifdef _MSC_VER

#pragma once

#endif // _MSC_VER



#ifndef _ENCLAVEAPI_H_

#define _ENCLAVEAPI_H_



#include <apiset.h>

#include <apisetcconv.h>

#include <minwindef.h>

#include <minwinbase.h>



/* APISET_NAME: api-ms-win-core-enclave-l1 */



#if !defined(RC_INVOKED)



#ifndef _APISET_ENCLAVE_VER

#ifdef _APISET_TARGET_VERSION

#if _APISET_TARGET_VERSION >= _APISET_TARGET_VERSION_WINTHRESHOLD

#define _APISET_ENCLAVE_VER 0x0100

#endif

#endif

#endif



#endif // !defined(RC_INVOKED)





#ifdef __cplusplus

extern "C" {

#endif



#pragma region Desktop Family or OneCore Family



#if WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_DESKTOP | WINAPI_PARTITION_SYSTEM)



    WINBASEAPI

        _Success_(return != FALSE)

        BOOL

        WINAPI

        IsEnclaveTypeSupported(

            _In_ DWORD flEnclaveType

        );





    WINBASEAPI

        _Ret_maybenull_ _Post_writable_byte_size_(dwSize)

        LPVOID

        WINAPI

        CreateEnclave(

            _In_ HANDLE hProcess,

            _In_opt_ LPVOID lpAddress,

            _In_ SIZE_T dwSize,

            _In_ SIZE_T dwInitialCommitment,

            _In_ DWORD flEnclaveType,

            _In_reads_bytes_(dwInfoLength) LPCVOID lpEnclaveInformation,

            _In_ DWORD dwInfoLength,

            _Out_opt_ LPDWORD lpEnclaveError

        );





    WINBASEAPI

        _Success_(return != FALSE)

        BOOL

        WINAPI

        LoadEnclaveData(

            _In_ HANDLE hProcess,

            _In_ LPVOID lpAddress,

            _In_reads_bytes_(nSize) LPCVOID lpBuffer,

            _In_ SIZE_T nSize,

            _In_ DWORD flProtect,

            _In_reads_bytes_(dwInfoLength) LPCVOID lpPageInformation,

            _In_ DWORD dwInfoLength,

            _Out_ PSIZE_T lpNumberOfBytesWritten,

            _Out_opt_ LPDWORD lpEnclaveError

        );





    WINBASEAPI

        _Success_(return != FALSE)

        BOOL

        WINAPI

        InitializeEnclave(

            _In_ HANDLE hProcess,

            _In_ LPVOID lpAddress,

            _In_reads_bytes_(dwInfoLength) LPCVOID lpEnclaveInformation,

            _In_ DWORD dwInfoLength,

            _Out_opt_ LPDWORD lpEnclaveError

        );





#endif /* WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_DESKTOP | WINAPI_PARTITION_SYSTEM) */

#pragma endregion



#ifdef __cplusplus

}

#endif



#endif // _ENCLAVEAPI_H_

// end_1_0

Open in new window


GitHub link for project : https://github.com/HSG88/Trustee
error1.jpg
error2.jpg
Comment
Watch Question
CERTIFIED EXPERT
Top Expert 2016
Commented:
This problem has been solved!
Unlock 1 Answer and 3 Comments.
See Answer
Why Experts Exchange?

Experts Exchange always has the answer, or at the least points me in the correct direction! It is like having another employee that is extremely experienced.

Jim Murphy
Programmer at Smart IT Solutions

When asked, what has been your best career decision?

Deciding to stick with EE.

Mohamed Asif
Technical Department Head

Being involved with EE helped me to grow personally and professionally.

Carl Webster
CTP, Sr Infrastructure Consultant

An Experts Exchange subscription includes unlimited access to online courses.

Get Started
Ask ANY Question

Connect with Certified Experts to gain insight and support on specific technology challenges including:

  • Troubleshooting
  • Research
  • Professional Opinions
Did You Know?

We've partnered with two important charities to provide clean water and computer science education to those who need it most. READ MORE