CyberEngineMkIII
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
CYBModuleDefinitions.hpp
Go to the documentation of this file.
1 #pragma once
3 
4 namespace CYB {
5  namespace Platform {
6  namespace Modules {
11  template <unsigned int AUnused> class AMFake {};
12  };
13  };
14 };
16 //Posix generation is weird here
17 
18 DEFINE_WINDOWS_MODULE(Kernel32, u8"kernel32", Win32, false, true,
19  CreateThread,
20  WaitForSingleObject, Sleep, SwitchToThread, GetSystemInfo, GetLastError,
21  CloseHandle,
22  InitializeCriticalSection, DeleteCriticalSection, EnterCriticalSection, TryEnterCriticalSection, LeaveCriticalSection,
23  InitializeConditionVariable, WakeConditionVariable, WakeAllConditionVariable, SleepConditionVariableCS,
24  VirtualAlloc, VirtualFree, VirtualProtect, VirtualQuery, GetProcessId,
25  MultiByteToWideChar, WideCharToMultiByte,
26  CreateProcessW, GetExitCodeProcess,
27  GetModuleHandleW, GetModuleFileNameW,
28  GetTempPathW, GetCurrentDirectoryW,
29  FindFirstFileW, FindNextFileW, FindClose,
30  CreateDirectoryW, RemoveDirectoryW, GetFileAttributesExW, SetFileAttributesW, DeleteFileW,
31  CreateFileW, GetFileSizeEx, SetFilePointerEx, ReadFile, WriteFile,
32  AllocConsole, FreeConsole, AttachConsole, WriteConsoleA, GetStdHandle, SetConsoleOutputCP)
33 DEFINE_WINDOWS_MODULE(Kernel32Extended, u8"kernel32", Win32, true, true, DiscardVirtualMemory)
34 DEFINE_WINDOWS_MODULE(Shell, u8"shell32", Win32, false, true, ShellExecuteExW, SHGetKnownFolderPath)
35 DEFINE_WINDOWS_MODULE(Ole32, u8"Ole32", Win32, false, true, CoTaskMemFree)
36 DEFINE_WINDOWS_MODULE(ShellAPI, u8"shlwapi", Win32, false, true, PathRemoveFileSpecW, PathCanonicalizeW, PathFileExistsW, PathFindFileNameW, PathFindExtensionW, PathIsRootW)
37 
38 DEFINE_POSIX_MODULE(LibC, LIBC_SO, Posix, false, false,
39  kill, getpid, waitpid, usleep,
40  mmap, mprotect, munmap, madvise,
41  readlink, mkdir, realpath, rmdir, unlink,
42  opendir, readdir, closedir,
43  getuid, getpwuid_r, getenv, sysconf,
44  posix_spawn,
45  open, close, lseek, read, write)
46 DEFINE_POSIX_MODULE(PThread, LIBPTHREAD_SO, Posix, false, false,
47  pthread_mutex_init, pthread_mutex_destroy, pthread_mutex_lock, pthread_mutex_trylock, pthread_mutex_unlock,
48  pthread_create, pthread_join,
49  pthread_cond_init, pthread_cond_destroy, pthread_cond_wait, pthread_cond_signal, pthread_cond_broadcast)
50 DEFINE_LINUX_MODULE(RT, LIBRT_SO, Posix, false, false, sched_yield)
51 DEFINE_OSX_MODULE(System, u8"libSystem", Posix, false, true, sched_yield)
52 DEFINE_OSX_MODULE(DyLD, u8"/usr/lib/system/libdyld", Posix, false, true, _NSGetExecutablePath)
53 OVERRIDE_OSX_FUNCTION_NAMES(LibC,
54  nullptr, nullptr, nullptr, nullptr, nullptr, nullptr, nullptr, nullptr, nullptr, nullptr, nullptr, nullptr, nullptr, nullptr,
55  "readdir$INODE64",
56  nullptr, nullptr, nullptr, nullptr, nullptr, nullptr,
57  nullptr, nullptr, nullptr, nullptr, nullptr, nullptr)
58 
59 //! @endcond
Fake AutoModule used in place of other Platform's AutoModules.