summaryrefslogtreecommitdiffhomepage
path: root/dev/Kernel/CFKit
diff options
context:
space:
mode:
Diffstat (limited to 'dev/Kernel/CFKit')
-rw-r--r--dev/Kernel/CFKit/GUIDWizard.hxx22
-rw-r--r--dev/Kernel/CFKit/GUIDWrapper.hxx58
-rw-r--r--dev/Kernel/CFKit/LoaderUtils.hxx54
-rw-r--r--dev/Kernel/CFKit/Property.hxx47
-rw-r--r--dev/Kernel/CFKit/URL.hxx33
-rw-r--r--dev/Kernel/CFKit/compile_flags.txt5
6 files changed, 0 insertions, 219 deletions
diff --git a/dev/Kernel/CFKit/GUIDWizard.hxx b/dev/Kernel/CFKit/GUIDWizard.hxx
deleted file mode 100644
index 034aceea..00000000
--- a/dev/Kernel/CFKit/GUIDWizard.hxx
+++ /dev/null
@@ -1,22 +0,0 @@
-/* -------------------------------------------
-
- Copyright ZKA Technologies.
-
-------------------------------------------- */
-
-#pragma once
-
-#include <CFKit/GUIDWrapper.hxx>
-#include <NewKit/Array.hxx>
-#include <NewKit/ArrayList.hxx>
-#include <NewKit/Defines.hxx>
-#include <NewKit/ErrorOr.hxx>
-#include <NewKit/Ref.hxx>
-#include <NewKit/Stream.hxx>
-#include <NewKit/String.hxx>
-
-namespace Kernel::XRN::Version1
-{
- Ref<GUIDSequence*> cf_make_sequence(const ArrayList<UInt32>& seq);
- ErrorOr<Ref<Kernel::StringView>> cf_try_guid_to_string(Ref<GUIDSequence*>& guid);
-} // namespace Kernel::XRN::Version1
diff --git a/dev/Kernel/CFKit/GUIDWrapper.hxx b/dev/Kernel/CFKit/GUIDWrapper.hxx
deleted file mode 100644
index 8810f303..00000000
--- a/dev/Kernel/CFKit/GUIDWrapper.hxx
+++ /dev/null
@@ -1,58 +0,0 @@
-/* -------------------------------------------
-
- Copyright ZKA Technologies.
-
-------------------------------------------- */
-
-#pragma once
-
-#include <NewKit/Defines.hxx>
-#include <NewKit/Ref.hxx>
-#include <NewKit/Stream.hxx>
-
-/* GUID for C++ Components */
-
-#define kXRNNil "@{........-....-M...-N...-............}"
-
-// eXtensible Resource Information
-namespace Kernel::XRN
-{
- union GUIDSequence {
- alignas(8) UShort u8[16];
- alignas(8) UShort u16[8];
- alignas(8) UInt u32[4];
- alignas(8) ULong u64[2];
-
- struct
- {
- alignas(8) UInt fMs1;
- UShort fMs2;
- UShort fMs3;
- UChar fMs4[8];
- };
- };
-
- class GUID final
- {
- public:
- explicit GUID() = default;
- ~GUID() = default;
-
- public:
- GUID& operator=(const GUID&) = default;
- GUID(const GUID&) = default;
-
- public:
- GUIDSequence& operator->() noexcept
- {
- return fUUID;
- }
- GUIDSequence& Leak() noexcept
- {
- return fUUID;
- }
-
- private:
- GUIDSequence fUUID;
- };
-} // namespace Kernel::XRN
diff --git a/dev/Kernel/CFKit/LoaderUtils.hxx b/dev/Kernel/CFKit/LoaderUtils.hxx
deleted file mode 100644
index 3edacc67..00000000
--- a/dev/Kernel/CFKit/LoaderUtils.hxx
+++ /dev/null
@@ -1,54 +0,0 @@
-#ifndef __CFKIT_LOADER_UTILS_HXX__
-#define __CFKIT_LOADER_UTILS_HXX__
-
-#include <KernelKit/PE.hxx>
-#include <KernelKit/MSDOS.hxx>
-
-namespace Kernel
-{
- /// @brief Find the PE header inside the blob.
- inline auto ldr_find_exec_header(DosHeaderPtr ptrDos) -> ExecHeaderPtr
- {
- if (!ptrDos)
- return nullptr;
-
- if (ptrDos->eMagic[0] != kMagMz0)
- return nullptr;
-
- if (ptrDos->eMagic[1] != kMagMz1)
- return nullptr;
-
- return (ExecHeaderPtr)(VoidPtr)(&ptrDos->eLfanew + 1);
- }
-
- /// @brief Find the PE optional header inside the blob.
- inline auto ldr_find_opt_exec_header(DosHeaderPtr ptrDos) -> ExecOptionalHeaderPtr
- {
- if (!ptrDos)
- return nullptr;
-
- auto exec = ldr_find_exec_header(ptrDos);
-
- if (!exec)
- return nullptr;
-
- return (ExecOptionalHeaderPtr)(VoidPtr)(&exec->mCharacteristics + 1);
- }
-
- /// @brief Find the PE header inside the blob.
- /// @note overloaded function.
- inline auto ldr_find_exec_header(const Char* ptrDos) -> ExecHeaderPtr
- {
- return ldr_find_exec_header((DosHeaderPtr)ptrDos);
- }
-
-
- /// @brief Find the PE header inside the blob.
- /// @note overloaded function.
- inline auto ldr_find_opt_exec_header(const Char* ptrDos) -> ExecOptionalHeaderPtr
- {
- return ldr_find_opt_exec_header((DosHeaderPtr)ptrDos);
- }
-} // namespace Kernel
-
-#endif // ifndef __CFKIT_LOADER_UTILS_HXX__
diff --git a/dev/Kernel/CFKit/Property.hxx b/dev/Kernel/CFKit/Property.hxx
deleted file mode 100644
index 602c061f..00000000
--- a/dev/Kernel/CFKit/Property.hxx
+++ /dev/null
@@ -1,47 +0,0 @@
-/* -------------------------------------------
-
- Copyright ZKA Technologies.
-
-------------------------------------------- */
-
-#ifndef __INC_PROPS_HPP__
-#define __INC_PROPS_HPP__
-
-#include <NewKit/Array.hxx>
-#include <NewKit/Defines.hxx>
-#include <NewKit/Function.hxx>
-#include <NewKit/String.hxx>
-
-#define cMaxPropLen 4096
-
-namespace Kernel
-{
- /// @brief handle to anything (number, ptr, string...)
- using PropertyId = UIntPtr;
-
- /// @brief Kernel property class.
- /// @example \Properties\SmpCores or \Properties\KernelVersion
- class Property
- {
- public:
- Property() = default;
- virtual ~Property();
-
- public:
- Property& operator=(const Property&) = default;
- Property(const Property&) = default;
-
- bool StringEquals(StringView& name);
- PropertyId& GetValue();
- StringView& GetKey();
-
- private:
- StringView fName{cMaxPropLen};
- PropertyId fAction{No};
- };
-
- template <SizeT N>
- using PropertyArray = Array<Property, N>;
-} // namespace Kernel
-
-#endif // !__INC_PROPS_HPP__
diff --git a/dev/Kernel/CFKit/URL.hxx b/dev/Kernel/CFKit/URL.hxx
deleted file mode 100644
index 02cced28..00000000
--- a/dev/Kernel/CFKit/URL.hxx
+++ /dev/null
@@ -1,33 +0,0 @@
-/* -------------------------------------------
-
- Copyright ZKA Technologies.
-
-------------------------------------------- */
-
-#ifndef _INC_URL_HPP_
-#define _INC_URL_HPP_
-
-#include <NewKit/Defines.hxx>
-#include <NewKit/String.hxx>
-
-namespace Kernel
-{
- class URL final
- {
- public:
- explicit URL(StringView& strUrl);
- ~URL();
-
- public:
- Ref<ErrorOr<StringView>> Location() noexcept;
- Ref<ErrorOr<StringView>> Protocol() noexcept;
-
- private:
- Ref<StringView> fUrlView;
- };
-
- ErrorOr<StringView> url_extract_location(const Char* url);
- ErrorOr<StringView> url_extract_protocol(const Char* url);
-} // namespace Kernel
-
-#endif /* ifndef _INC_URL_HPP_ */
diff --git a/dev/Kernel/CFKit/compile_flags.txt b/dev/Kernel/CFKit/compile_flags.txt
deleted file mode 100644
index a37ae6bf..00000000
--- a/dev/Kernel/CFKit/compile_flags.txt
+++ /dev/null
@@ -1,5 +0,0 @@
--nostdlib
--ffreestanding
--std=c++20
--I./
--I../