From add222dfb8c34d9f6a6cb58914b0583ed988a8f9 Mon Sep 17 00:00:00 2001 From: krispy Date: Sat, 1 Jun 2024 18:53:59 +0200 Subject: [PATCH] sceZlibInitialize stub --- modules/libSceZlib/CMakeLists.txt | 8 ++++++++ modules/libSceZlib/codes.h | 4 ++++ modules/libSceZlib/entry.cpp | 18 ++++++++++++++++++ modules/libSceZlib/types.h | 2 ++ 4 files changed, 32 insertions(+) create mode 100644 modules/libSceZlib/CMakeLists.txt create mode 100644 modules/libSceZlib/codes.h create mode 100644 modules/libSceZlib/entry.cpp create mode 100644 modules/libSceZlib/types.h diff --git a/modules/libSceZlib/CMakeLists.txt b/modules/libSceZlib/CMakeLists.txt new file mode 100644 index 0000000..d5b5c6a --- /dev/null +++ b/modules/libSceZlib/CMakeLists.txt @@ -0,0 +1,8 @@ +set(libName libSceZlib) +include(../setupModule.cmake) + +project(${libName}) + +add_library(${libName} SHARED entry.cpp) + +setupModule(${libName}) diff --git a/modules/libSceZlib/codes.h b/modules/libSceZlib/codes.h new file mode 100644 index 0000000..f158822 --- /dev/null +++ b/modules/libSceZlib/codes.h @@ -0,0 +1,4 @@ +#pragma once +#include + +namespace Err {} // namespace Err \ No newline at end of file diff --git a/modules/libSceZlib/entry.cpp b/modules/libSceZlib/entry.cpp new file mode 100644 index 0000000..7dcc8c9 --- /dev/null +++ b/modules/libSceZlib/entry.cpp @@ -0,0 +1,18 @@ +#include "common.h" +#include "logging.h" +#include "types.h" + +LOG_DEFINE_MODULE(libSceZlib); + +namespace {} // namespace + +extern "C" { + +EXPORT const char* MODULE_NAME = "libSceZlib"; + +EXPORT SYSV_ABI int32_t sceZlibInitialize(const void* buffer, size_t length) { + LOG_USE_MODULE(libSceZlib); + LOG_ERR(L"todo %S", __FUNCTION__); + return Ok; +} +} \ No newline at end of file diff --git a/modules/libSceZlib/types.h b/modules/libSceZlib/types.h new file mode 100644 index 0000000..7832fd4 --- /dev/null +++ b/modules/libSceZlib/types.h @@ -0,0 +1,2 @@ +#pragma once +#include "codes.h"