From 6ea68d219dc3a1bcc0deef1683e8442082025940 Mon Sep 17 00:00:00 2001 From: Amlal EL Mahrouss Date: Tue, 30 Jul 2024 10:01:42 +0200 Subject: [IMP] SCIKit: SharedInterface1 and UnknownInterface, both are defined in foreign SOs. [REFACTOR] IPCEP is just now IPC. Signed-off-by: Amlal EL Mahrouss --- .vscode/c_cpp_properties.json | 6 +- Kernel/HALKit/AMD64/HalKernelMain.cxx | 4 +- Kernel/HALKit/ARM64/HalKernelMain.cxx | 4 +- Kernel/KernelKit/User.hxx | 1 + Kernel/NetworkKit/IPC.hxx | 80 ++++++++++++++++++++++ Kernel/NetworkKit/IPCEP.hxx | 79 ---------------------- Kernel/NetworkKit/NetworkDevice.hpp | 2 +- Kernel/Sources/Network/IPC.cxx | 68 +++++++++++++++++++ Kernel/Sources/Network/IPCEP.cxx | 68 ------------------- SCIKit/ErrorTypes.cxx | 9 +++ SCIKit/ErrorTypes.hxx | 8 +-- SCIKit/SharedInterface1.hxx | 87 ++++++++++++++++++++++++ SCIKit/StandardInterface.hxx | 123 ---------------------------------- SCIKit/Types.hxx | 69 +++++++++++++++++++ SCIKit/makefile | 7 ++ 15 files changed, 330 insertions(+), 285 deletions(-) create mode 100644 Kernel/NetworkKit/IPC.hxx delete mode 100644 Kernel/NetworkKit/IPCEP.hxx create mode 100644 Kernel/Sources/Network/IPC.cxx delete mode 100644 Kernel/Sources/Network/IPCEP.cxx create mode 100644 SCIKit/ErrorTypes.cxx create mode 100644 SCIKit/SharedInterface1.hxx delete mode 100644 SCIKit/StandardInterface.hxx create mode 100644 SCIKit/Types.hxx create mode 100644 SCIKit/makefile diff --git a/.vscode/c_cpp_properties.json b/.vscode/c_cpp_properties.json index 1c195e89..2cb9e3a7 100644 --- a/.vscode/c_cpp_properties.json +++ b/.vscode/c_cpp_properties.json @@ -1,10 +1,9 @@ { "configurations": [ { - "name": "MicroKernel (Macintosh)", + "name": "Kernel (Macintosh)", "includePath": [ "${workspaceFolder}/Kernel/**", - "${workspaceFolder}/Drv/**", "${workspaceFolder}/Boot/**", "${workspaceFolder}/**" ], @@ -25,9 +24,8 @@ "intelliSenseMode": "gcc-x64" }, { - "name": "MicroKernel (Windows)", + "name": "Kernel (Windows)", "includePath": [ - "${workspaceFolder}/Drv/**", "${workspaceFolder}/Kernel/**", "${workspaceFolder}/Boot/**", "${workspaceFolder}/**" diff --git a/Kernel/HALKit/AMD64/HalKernelMain.cxx b/Kernel/HALKit/AMD64/HalKernelMain.cxx index 1628e5e9..a4067c84 100644 --- a/Kernel/HALKit/AMD64/HalKernelMain.cxx +++ b/Kernel/HALKit/AMD64/HalKernelMain.cxx @@ -17,7 +17,7 @@ #include #include #include -#include +#include #include #define mInitKernel(X) \ @@ -141,7 +141,7 @@ EXTERN_C void hal_init_platform( }; kSyscalls[cLPCSanitizeMsg].Leak().Leak()->fProc = [](Kernel::VoidPtr rdx) -> void { - Kernel::ipc_sanitize_packet(reinterpret_cast(rdx)); + Kernel::ipc_sanitize_packet(reinterpret_cast(rdx)); }; kSyscalls[cNewInterrupt].Leak().Leak()->fProc = [](Kernel::VoidPtr rdx) -> void { diff --git a/Kernel/HALKit/ARM64/HalKernelMain.cxx b/Kernel/HALKit/ARM64/HalKernelMain.cxx index a2d215f6..a5285f0f 100644 --- a/Kernel/HALKit/ARM64/HalKernelMain.cxx +++ b/Kernel/HALKit/ARM64/HalKernelMain.cxx @@ -17,7 +17,7 @@ #include #include #include -#include +#include #define KERNEL_INIT(X) \ X; \ @@ -99,7 +99,7 @@ EXTERN_C void hal_init_platform( }; kSyscalls[cLPCSanitizeMsg].Leak().Leak()->fProc = [](Kernel::VoidPtr rdx) -> void { - Kernel::ipc_sanitize_packet(reinterpret_cast(rdx)); + Kernel::ipc_sanitize_packet(reinterpret_cast(rdx)); }; kSyscalls[cNewInterrupt].Leak().Leak()->fProc = [](Kernel::VoidPtr rdx) -> void { diff --git a/Kernel/KernelKit/User.hxx b/Kernel/KernelKit/User.hxx index 861fd17a..c84910c5 100644 --- a/Kernel/KernelKit/User.hxx +++ b/Kernel/KernelKit/User.hxx @@ -57,6 +57,7 @@ namespace Kernel public: /// @brief Get software ring const RingKind& Ring() noexcept; + /// @brief Get user name StringView& Name() noexcept; diff --git a/Kernel/NetworkKit/IPC.hxx b/Kernel/NetworkKit/IPC.hxx new file mode 100644 index 00000000..e53d8f1c --- /dev/null +++ b/Kernel/NetworkKit/IPC.hxx @@ -0,0 +1,80 @@ +/* ------------------------------------------- + + Copyright ZKA Technologies. + + File: IPC.hxx. + Purpose: IPC protocol. + +------------------------------------------- */ + +#ifndef _INC_IPC_ENDPOINT_HXX_ +#define _INC_IPC_ENDPOINT_HXX_ + +#include +#include + +/// @file IPC.hxx +/// @brief IPC protocol. + +/// IA separator. +#define cRemoteSeparator "." + +/// Interchange address, consists of PID:TEAM. +#define cRemoteInvalid "00:00" + +#define cRemoteHeaderMagic (0x4950434) + +namespace Kernel +{ + /// @brief 128-bit IPC address. + struct PACKED IPC_ADDRESS_STRUCT final + { + UInt64 ProcessID; + UInt64 ProcessTeam; + + //////////////////////////////////// + // some operators. + //////////////////////////////////// + + bool operator==(const IPC_ADDRESS_STRUCT& addr) noexcept + { + return addr.ProcessID == this->ProcessID && addr.ProcessTeam == this->ProcessTeam; + } + + bool operator==(IPC_ADDRESS_STRUCT& addr) noexcept + { + return addr.ProcessID == this->ProcessID && addr.ProcessTeam == this->ProcessTeam; + } + }; + + typedef struct IPC_ADDRESS_STRUCT IPCEPAddressKind; + + enum + { + eIPCEPLittleEndian = 0, + eIPCEPBigEndian = 1 + }; + + constexpr auto cIPCEPMsgSize = 6094U; + + /// @brief IPC connection header, message cannot be greater than 6K. + typedef struct IPC_MESSAGE_STRUCT final + { + UInt32 IpcHeaderMagic; // cRemoteHeaderMagic + UInt8 IpcEndianess; // 0 : LE, 1 : BE + SizeT IpcPacketSize; + IPCEPAddressKind IpcFrom; + IPCEPAddressKind IpcTo; + UInt32 IpcCRC32; + UInt32 IpcMsg; + UInt32 IpcMsgSz; + UInt8 IpcData[cIPCEPMsgSize]; + } PACKED IPC_MESSAGE_STRUCT; + + /// @brief Sanitize packet function + /// @retval true packet is correct. + /// @retval false packet is incorrect and process has crashed. + Bool ipc_sanitize_packet(IPC_MESSAGE_STRUCT* pckt); +} // namespace Kernel + +#endif // _INC_IPC_ENDPOINT_HXX_ diff --git a/Kernel/NetworkKit/IPCEP.hxx b/Kernel/NetworkKit/IPCEP.hxx deleted file mode 100644 index 7a7d8fc9..00000000 --- a/Kernel/NetworkKit/IPCEP.hxx +++ /dev/null @@ -1,79 +0,0 @@ -/* ------------------------------------------- - - Copyright ZKA Technologies. - - File: IPCEP.hxx. - Purpose: IPC protocol. - -------------------------------------------- */ - -#ifndef _INC_IPC_ENDPOINT_HXX_ -#define _INC_IPC_ENDPOINT_HXX_ - -#include -#include - -/// @brief IPC Endpoint Protocol (IPCEP for short). - -/// IA separator. -#define cRemoteSeparator "." - -/// Interchange address, consists of PID:TEAM. -#define cRemoteInvalid "00:00" - -#define cRemoteHeaderMagic (0x4950434) - -namespace Kernel -{ - /// @brief 128-bit IPC address. - struct PACKED IPCEPAddress final - { - UInt64 ProcessID; - UInt64 ProcessTeam; - - //////////////////////////////////// - // some operators. - //////////////////////////////////// - - bool operator==(const IPCEPAddress& addr) noexcept - { - return addr.ProcessID == this->ProcessID && addr.ProcessTeam == this->ProcessTeam; - } - - bool operator==(IPCEPAddress& addr) noexcept - { - return addr.ProcessID == this->ProcessID && addr.ProcessTeam == this->ProcessTeam; - } - }; - - typedef struct IPCEPAddress IPCEPAddressType; - - enum - { - eIPCEPLittleEndian = 0, - eIPCEPBigEndian = 1 - }; - - constexpr auto cIPCEPMsgSize = 6094U; - - /// @brief IPCEP connection header, message cannot be greater than 6K. - typedef struct IPCEPMessageHeader final - { - UInt32 IpcHeaderMagic; // cRemoteHeaderMagic - UInt8 IpcEndianess; // 0 : LE, 1 : BE - SizeT IpcPacketSize; - IPCEPAddressType IpcFrom; - IPCEPAddressType IpcTo; - UInt32 IpcCRC32; - UInt32 IpcMsg; - UInt32 IpcMsgSz; - UInt8 IpcData[cIPCEPMsgSize]; - } PACKED IPCEPMessageHeader; - - /// @brief Sanitize packet function - /// @retval true packet is correct. - /// @retval false packet is incorrect and process has crashed. - Bool ipc_sanitize_packet(IPCEPMessageHeader* pckt); -} // namespace Kernel - -#endif // _INC_IPC_ENDPOINT_HXX_ diff --git a/Kernel/NetworkKit/NetworkDevice.hpp b/Kernel/NetworkKit/NetworkDevice.hpp index 956475aa..eed5f071 100644 --- a/Kernel/NetworkKit/NetworkDevice.hpp +++ b/Kernel/NetworkKit/NetworkDevice.hpp @@ -62,7 +62,7 @@ namespace Kernel /// @brief PPP device. using PPPNetworkDevice = NetworkDevice; - /// @brief IPCEP device. + /// @brief IPC device. using IPCEPNetworkDevice = NetworkDevice; /// @brief GRPS device. diff --git a/Kernel/Sources/Network/IPC.cxx b/Kernel/Sources/Network/IPC.cxx new file mode 100644 index 00000000..12ec6c1a --- /dev/null +++ b/Kernel/Sources/Network/IPC.cxx @@ -0,0 +1,68 @@ +/* ------------------------------------------- + + Copyright ZKA Technologies + +------------------------------------------- */ + +#include +#include +#include + +using namespace Kernel; + +/// @internal +/// @brief The internal sanitize function. +Bool ipc_int_sanitize_packet(IPC_MESSAGE_STRUCT* pckt) +{ + auto endian = DEDUCE_ENDIAN(pckt, ((char*)pckt)[0]); + + switch (endian) + { + case Endian::kEndianBig: { + if (pckt->IpcEndianess == eIPCEPLittleEndian) + goto ipc_check_failed; + + break; + } + case Endian::kEndianLittle: { + if (pckt->IpcEndianess == eIPCEPBigEndian) + goto ipc_check_failed; + + break; + } + case Endian::kEndianMixed: + break; + default: + goto ipc_check_failed; + } + + if (pckt->IpcFrom == pckt->IpcTo || + pckt->IpcPacketSize > cIPCEPMsgSize) + { + goto ipc_check_failed; + } + + return pckt->IpcPacketSize > 1 && pckt->IpcHeaderMagic == cRemoteHeaderMagic; + +ipc_check_failed: + ErrLocal() = kErrorIPC; + return false; +} + +namespace Kernel +{ + /// @brief Sanitize packet function + /// @retval true packet is correct. + /// @retval false packet is incorrect and process has crashed. + Bool ipc_sanitize_packet(IPC_MESSAGE_STRUCT* pckt) + { + if (!pckt || + !ipc_int_sanitize_packet(pckt)) + { + ProcessScheduler::The().Leak().TheCurrent().Leak().Crash(); + return false; + } + + return true; + } +} // namespace Kernel diff --git a/Kernel/Sources/Network/IPCEP.cxx b/Kernel/Sources/Network/IPCEP.cxx deleted file mode 100644 index 5271be05..00000000 --- a/Kernel/Sources/Network/IPCEP.cxx +++ /dev/null @@ -1,68 +0,0 @@ -/* ------------------------------------------- - - Copyright ZKA Technologies - -------------------------------------------- */ - -#include -#include -#include - -using namespace Kernel; - -/// @internal -/// @brief The internal sanitize function. -Bool ipc_int_sanitize_packet(IPCEPMessageHeader* pckt) -{ - auto endian = DEDUCE_ENDIAN(pckt, ((char*)pckt)[0]); - - switch (endian) - { - case Endian::kEndianBig: { - if (pckt->IpcEndianess == eIPCEPLittleEndian) - goto ipc_check_failed; - - break; - } - case Endian::kEndianLittle: { - if (pckt->IpcEndianess == eIPCEPBigEndian) - goto ipc_check_failed; - - break; - } - case Endian::kEndianMixed: - break; - default: - goto ipc_check_failed; - } - - if (pckt->IpcFrom == pckt->IpcTo || - pckt->IpcPacketSize > cIPCEPMsgSize) - { - goto ipc_check_failed; - } - - return pckt->IpcPacketSize > 1 && pckt->IpcHeaderMagic == cRemoteHeaderMagic; - -ipc_check_failed: - ErrLocal() = kErrorIPC; - return false; -} - -namespace Kernel -{ - /// @brief Sanitize packet function - /// @retval true packet is correct. - /// @retval false packet is incorrect and process has crashed. - Bool ipc_sanitize_packet(IPCEPMessageHeader* pckt) - { - if (!pckt || - !ipc_int_sanitize_packet(pckt)) - { - ProcessScheduler::The().Leak().TheCurrent().Leak().Crash(); - return false; - } - - return true; - } -} // namespace Kernel diff --git a/SCIKit/ErrorTypes.cxx b/SCIKit/ErrorTypes.cxx new file mode 100644 index 00000000..7bd4146a --- /dev/null +++ b/SCIKit/ErrorTypes.cxx @@ -0,0 +1,9 @@ +/* ------------------------------------------- + + Copyright ZKA Technologies + +------------------------------------------- */ + +#include + +HError kLastError = 0; \ No newline at end of file diff --git a/SCIKit/ErrorTypes.hxx b/SCIKit/ErrorTypes.hxx index 041786ba..4473722a 100644 --- a/SCIKit/ErrorTypes.hxx +++ b/SCIKit/ErrorTypes.hxx @@ -6,11 +6,7 @@ #pragma once -#include - -#ifdef __KERNEL__ -#error !!! including header in kernel mode !!! -#endif // __KERNEL__ +#include #define ErrLocalIsOk() (kLastError == kErrorSuccess) #define ErrLocalFailed() (kLastError != kErrorSuccess) @@ -50,4 +46,4 @@ inline constexpr HError kErrorSign = 60; inline constexpr HError kErrorInvalidCreds = 61; inline constexpr HError kErrorUnimplemented = 0; -inline HError kLastError = 0; +IMPORT_C HError kLastError; diff --git a/SCIKit/SharedInterface1.hxx b/SCIKit/SharedInterface1.hxx new file mode 100644 index 00000000..b1f7ce9d --- /dev/null +++ b/SCIKit/SharedInterface1.hxx @@ -0,0 +1,87 @@ +/* ------------------------------------------- + +Copyright ZKA Technologies. + +File: StandardInterface1.hxx. +Purpose: System Call Interface Version 1. + +------------------------------------------- */ + +#ifndef __SCI_STD_HXX__ +#define __SCI_STD_HXX__ + +#include + +/** + @brief System call class. +*/ +class __attribute__((uuid_of(SharedInterface1))) SharedInterface1 : public UnknownInterface +{ +public: + explicit SharedInterface1() = default; + virtual ~SharedInterface1() = default; + + SharedInterface1& operator=(const SharedInterface1&) = default; + SharedInterface1(const SharedInterface1&) = default; + +public: + /// @brief disable device. + virtual UInt0 PowerOff(PowerID) = 0; + + /// @brief enable device. + virtual UInt0 PowerOn(PowerID) = 0; + + /// @brief reboot device. + virtual UInt0 PowerReboot(PowerID) = 0; + + /// @brief check if MBCI device is wokeup. + virtual Bool PowerIsWokeup(PowerID) = 0; + + /// @brief probe MBCI/ACPI device from device. + virtual PowerID PowerProbeDevice(const char* namezpace, const int index) = 0; + + // THOSE DOESNT REQUIRE PERMISSIONS FROM THE USER. // + + /// @brief terminate app. + virtual UInt0 Terminate() = 0; + + /// @brief exit thread. + virtual Bool Exit(FD code) = 0; + + /// @brief alloc pointer. + virtual UInt0* New(long long sz) = 0; + + /// @brief free pointer. + virtual UInt0 Delete(void* ptr) = 0; + + // THOSE MAY REQUIRE PERMISSIONS FROM THE USER. // + + /// @brief Open descriptor. + virtual FD OpenStorage(const char* path, const UInt32 restr) = 0; + + /// @brief Close descriptor. + virtual UInt0 CloseStorage(FD descriptorType) = 0; + + /// @brief Execute from shell. + virtual FD URLExecute(const UTFChar* shellLink) = 0; + + /// @brief Read descriptor. + virtual UInt0* ReadStorage(const UTFChar* cmdNameOrData, SizeT cmdSize, FD descriptorType) = 0; + + /// @brief Seek in storage file + virtual UInt64 SeekStorage(FD descriptorType, UInt64 offset) = 0; + + /// @brief Tell storage cursor. + virtual UInt64 TellStorage(FD descriptorType) = 0; + + /// @brief Remove stored file. + virtual UInt64 RemoveStorage(FD descriptorType) = 0; + + /// @brief Create stored file. + virtual FD CreateStorage(const UTFChar* fileName, UInt64 flags) = 0; + + /// @brief Write descriptor. + virtual UInt0* WriteStorage(const UTFChar* cmdNameOrData, SizeT cmdSize, FD descriptorType) = 0; +}; + +#endif // ifndef __SCI_STD_HXX__ diff --git a/SCIKit/StandardInterface.hxx b/SCIKit/StandardInterface.hxx deleted file mode 100644 index 9e792546..00000000 --- a/SCIKit/StandardInterface.hxx +++ /dev/null @@ -1,123 +0,0 @@ -/* ------------------------------------------- - -Copyright ZKA Technologies. - -File: newstd.hxx. -Purpose: System Call Interface. - -------------------------------------------- */ - -#ifndef __SCI_STD_HXX__ -#define __SCI_STD_HXX__ - -#ifdef __KERNEL__ -#error !!! including header in kernel mode !!! -#endif // __KERNEL__ - -#define IMPORT_CXX extern "C++" -#define IMPORT_C extern "C" - -#define cRestrictR "r" -#define cRestrictRB "rb" -#define cRestrictW "w" -#define cRestrictRW "rw" - -class SCISharedInterface; /// @brief System call class. - -typedef long long int FD; -typedef bool Bool; -typedef void UInt0; - -typedef __UINT64_TYPE__ UInt64; -typedef __UINT32_TYPE__ UInt32; -typedef __UINT16_TYPE__ UInt16; -typedef __UINT8_TYPE__ UInt8; - -typedef __SIZE_TYPE__ SizeT; - -typedef __INT64_TYPE__ SInt64; -typedef __INT32_TYPE__ SInt32; -typedef __INT16_TYPE__ SInt16; -typedef __INT8_TYPE__ SInt8; - -typedef char UTFChar; - -typedef UInt32 PowerID; - -/** - @brief System call class. -*/ -class SCISharedInterface -{ -public: - explicit SCISharedInterface() = default; - virtual ~SCISharedInterface() = default; - - SCISharedInterface& operator=(const SCISharedInterface&) = default; - SCISharedInterface(const SCISharedInterface&) = default; - -public: - /// @brief disable device. - virtual UInt0 PowerOff(PowerID) = 0; - - /// @brief enable device. - virtual UInt0 PowerOn(PowerID) = 0; - - /// @brief reboot device. - virtual UInt0 PowerReboot(PowerID) = 0; - - /// @brief check if MBCI device is wokeup. - virtual Bool PowerIsWokeup(PowerID) = 0; - - /// @brief probe MBCI/ACPI device from phone. - virtual PowerID PowerProbeDevice(const char* namepace, const int index) = 0; - - // THOSE DOESNT REQUIRE PERMISSIONS FROM THE USER. // - - /// @brief terminate app. - virtual UInt0 Terminate() = 0; - - /// @brief exit thread. - virtual Bool Exit(FD code) = 0; - - /// @brief alloc pointer. - virtual UInt0* New(long long sz) = 0; - - /// @brief free pointer. - virtual UInt0 Delete(void* ptr) = 0; - - // THOSE MAY REQUIRE PERMISSIONS FROM THE USER. // - - /// @brief Open descriptor. - virtual FD OpenStorage(const char* path, const char* restr) = 0; - - /// @brief Close descriptor. - virtual UInt0 CloseStorage(FD descriptorType) = 0; - - /// @brief Execute from shell. - virtual FD URLExecute(const UTFChar* shellLink) = 0; - - /// @brief Read descriptor. - virtual UInt0* ReadStorage(const UTFChar* cmdNameOrData, SizeT cmdSize, FD descriptorType) = 0; - - /// @brief Seek in storage file - virtual UInt64 SeekStorage(FD descriptorType, UInt64 offset) = 0; - - /// @brief Tell storage cursor. - virtual UInt64 TellStorage(FD descriptorType) = 0; - - /// @brief Remove stored file. - virtual UInt64 RemoveStorage(FD descriptorType) = 0; - - /// @brief Create stored file. - virtual FD CreateStorage(const UTFChar* fileName, UInt64 flags) = 0; - - /// @brief Write descriptor. - virtual UInt0* WriteStorage(const UTFChar* cmdNameOrData, SizeT cmdSize, FD descriptorType) = 0; -}; - -/// @brief Get shared syscall object. -/// @return Syscall implementation. -IMPORT_C SCISharedInterface* SCIGetSharedInterface(UInt0); - -#endif // ifndef __SCI_STD_HXX__ diff --git a/SCIKit/Types.hxx b/SCIKit/Types.hxx new file mode 100644 index 00000000..c6c93fdc --- /dev/null +++ b/SCIKit/Types.hxx @@ -0,0 +1,69 @@ +/* ------------------------------------------- + +Copyright ZKA Technologies. + +File: Types.hxx. +Purpose: System Call types. + +------------------------------------------- */ + + +#pragma once + +#define IMPORT_CXX extern "C++" +#define IMPORT_C extern "C" + +#define cRestrictR 1 +#define cRestrictRB 2 +#define cRestrictW 4 +#define cRestrictRW 6 + +typedef long long int FD; +typedef bool Bool; +typedef void UInt0; + +typedef __UINT64_TYPE__ UInt64; +typedef __UINT32_TYPE__ UInt32; +typedef __UINT16_TYPE__ UInt16; +typedef __UINT8_TYPE__ UInt8; + +typedef __SIZE_TYPE__ SizeT; + +typedef __INT64_TYPE__ SInt64; +typedef __INT32_TYPE__ SInt32; +typedef __INT16_TYPE__ SInt16; +typedef __INT8_TYPE__ SInt8; + +typedef char UTFChar; + +typedef UInt32 PowerID; + +// Interfaces are divided between classes. +// So that they aren't too big. + +class SharedInterface1; +class SharedInterface2; +class SharedInterface3; +class UnknownInterface; +class EncodingInterface; + +class __attribute__((uuid_of(UnknownInterface))) UnknownInterface +{ +public: + explicit UnknownInterface() = default; + virtual ~UnknownInterface() = default; + + UnknownInterface& operator=(const UnknownInterface&) = default; + UnknownInterface(const UnknownInterface&) = default; + + SInt32 Release() { return -1; } + + template + SInt32 Release(TCLS* cls) { return -1; } + + template + TCLS* QueryInterface(UCLSID uclsidOfCls) { return nullptr; } +}; + +template +TCLS* SciGetClassFromCLSID(UCLSID uclsidOfCls); \ No newline at end of file diff --git a/SCIKit/makefile b/SCIKit/makefile new file mode 100644 index 00000000..2989d18c --- /dev/null +++ b/SCIKit/makefile @@ -0,0 +1,7 @@ +###################### +# (C) ZKA +###################### + +.PHONY: build-sci +build-sci: + g++ *.cxx -I../ -shared -fPIC -o libSCI.so \ No newline at end of file -- cgit v1.2.3