mirror of
https://github.com/Mauler125/r5sdk.git
synced 2025-02-09 19:15:03 +01:00
Floating point bitwise functions are now inline, also implemented a 'PopCount' function, which replicates the '__popcnt' instruction, but does not require the CPU to feature the instruction. This was mainly added as the SDK launcher doesn't check the CPU for SSSe3/popcnt, as it doesn't involve any instruction sets past SSE2.
69 lines
1.2 KiB
CMake
69 lines
1.2 KiB
CMake
cmake_minimum_required( VERSION 3.16 )
|
|
add_module( "lib" "mathlib" "" ${FOLDER_CONTEXT} TRUE TRUE )
|
|
|
|
start_sources()
|
|
|
|
add_sources( SOURCE_GROUP "Hash"
|
|
"adler32.cpp"
|
|
"adler32.h"
|
|
"crc32.cpp"
|
|
"crc32.h"
|
|
"IceKey.cpp"
|
|
"IceKey.H"
|
|
"sha1.cpp"
|
|
"sha1.h"
|
|
"sha256.cpp"
|
|
"sha256.h"
|
|
)
|
|
|
|
add_sources( SOURCE_GROUP "RNG"
|
|
"halton.cpp"
|
|
"halton.h"
|
|
"randsse.cpp"
|
|
"ssenoise.cpp"
|
|
)
|
|
|
|
add_sources( SOURCE_GROUP "Vector"
|
|
"bitvec.h"
|
|
"color.h"
|
|
"color_conversion.cpp"
|
|
"compressed_vector.h"
|
|
"fltx4.h"
|
|
"ssemath.h"
|
|
"ssequaternion.h"
|
|
"transform.cpp"
|
|
"transform.h"
|
|
"vector.h"
|
|
"vector2d.h"
|
|
"vector4d.h"
|
|
"vmatrix.cpp"
|
|
"vmatrix.h"
|
|
"vplane.h"
|
|
)
|
|
|
|
add_sources( SOURCE_GROUP "Math"
|
|
"almostequal.cpp"
|
|
"bits.h"
|
|
"fbits.h"
|
|
"math_pfns.h"
|
|
"mathlib.h"
|
|
"mathlib_base.cpp"
|
|
"noisedata.h"
|
|
"parallel_for.h"
|
|
"powsse.cpp"
|
|
"sseconst.cpp"
|
|
"ssemath.h"
|
|
"swap.h"
|
|
)
|
|
|
|
end_sources()
|
|
whole_program_optimization()
|
|
|
|
target_precompile_headers( ${PROJECT_NAME} PRIVATE
|
|
"mathlib_pch.h"
|
|
)
|
|
target_compile_definitions( ${PROJECT_NAME} PRIVATE
|
|
"BUILDING_MATHLIB"
|
|
$<$<OR:$<CONFIG:Debug>,$<CONFIG:Profile>>:DEBUG_MATHLIB>
|
|
)
|