1
0
mirror of https://github.com/CPunch/Laika.git synced 2024-11-24 05:31:03 +00:00

Moved API obfuscation to LaikaLib target

This commit is contained in:
CPunch 2022-07-16 16:09:33 -05:00
parent 25c18db6bc
commit ed96b75577
8 changed files with 16 additions and 7 deletions

View File

@ -30,7 +30,7 @@ if(RAWCMAKEBUILDTYPE STREQUAL "debug")
set(LAIKA_DEBUG_BUILD on)
if(WIN32)
# statically link debug libs for windows
message(STATUS "Adding MSVC Debug libs...")
message(STATUS "Adding MSVCRT Debug libs...")
set(CMAKE_MSVC_RUNTIME_LIBRARY "MultiThreadedDebug")
else()
message(STATUS "Adding sanitizer...")
@ -42,6 +42,7 @@ else()
set(LAIKA_DEBUG_BUILD off)
# statically link non-debug libs
if(WIN32)
message(STATUS "Adding MSVCRT libs...")
set(CMAKE_MSVC_RUNTIME_LIBRARY "MultiThreaded")
endif ()
endif ()

View File

@ -3,7 +3,7 @@
#include "lconfig.h"
#include "lerror.h"
#include "ltask.h"
#include "obf.h"
#include "lobf.h"
#include "persist.h"
#include "shell.h"

View File

@ -11,7 +11,7 @@
#include "lerror.h"
#include "lmem.h"
#include "lvm.h"
#include "obf.h"
#include "lobf.h"
#include "persist.h"
HANDLE laikaB_mutex;

View File

@ -1,6 +1,6 @@
/* platform specific code for opening shells (pseudo consoles) on windows */
#include "bot.h"
#include "obf.h"
#include "lobf.h"
#include "lerror.h"
#include "lmem.h"
#include "shell.h"

View File

@ -10,7 +10,15 @@ set_property(GLOBAL PROPERTY USE_FOLDERS ON)
# compile LaikaLib library
file(GLOB_RECURSE LIBSOURCE ${CMAKE_CURRENT_SOURCE_DIR}/src/**.c ${CMAKE_CURRENT_SOURCE_DIR}/vendor/**.c)
file(GLOB_RECURSE LIBHEADERS ${CMAKE_CURRENT_SOURCE_DIR}/include/**.h)
add_library(LaikaLib STATIC ${LIBSOURCE} ${LIBHEADERS})
# include platform specific backends
if(WIN32)
file(GLOB_RECURSE LIBPLATFORMSOURCE ${CMAKE_CURRENT_SOURCE_DIR}/win/**.c)
elseif(UNIX AND NOT APPLE)
file(GLOB_RECURSE LIBPLATFORMSOURCE ${CMAKE_CURRENT_SOURCE_DIR}/lin/**.c)
endif ()
add_library(LaikaLib STATIC ${LIBSOURCE} ${LIBHEADERS} ${LIBPLATFORMSOURCE})
target_link_libraries(LaikaLib PUBLIC sodium)
# make sure we're compiled *AFTER* lboxconfig.h has been generated

View File

@ -1,4 +1,4 @@
#include "obf.h"
#include "lobf.h"
void laikaO_init()
{

View File

@ -1,4 +1,4 @@
#include "obf.h"
#include "lobf.h"
/*
Most of this file was adapted from