summaryrefslogtreecommitdiff
path: root/deps/argon2/CMakeLists.txt
diff options
context:
space:
mode:
authorKargatum <dowlandtop@yandex.com>2021-05-13 07:57:10 +0700
committerGitHub <noreply@github.com>2021-05-12 18:57:10 -0600
commit26f2abaaa94478d8af4a5686b7f48dbefca98125 (patch)
tree5e84b6584ad32d60077a085e0941054cffccadb5 /deps/argon2/CMakeLists.txt
parent681c3237dfaf46bcad02f00ce717b97bdd899f40 (diff)
feat(Core/Authserver): TOTP rewrite (#5620)
Diffstat (limited to 'deps/argon2/CMakeLists.txt')
-rw-r--r--deps/argon2/CMakeLists.txt41
1 files changed, 41 insertions, 0 deletions
diff --git a/deps/argon2/CMakeLists.txt b/deps/argon2/CMakeLists.txt
new file mode 100644
index 0000000000..f133367f1c
--- /dev/null
+++ b/deps/argon2/CMakeLists.txt
@@ -0,0 +1,41 @@
+# This file is part of the WarheadCore Project. See AUTHORS file for Copyright information
+#
+# This file is free software; as a special exception the author gives
+# unlimited permission to copy and/or distribute it, with or without
+# modifications, as long as this notice is preserved.
+#
+# This program is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY, to the extent permitted by law; without even the
+# implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
+
+file(GLOB_RECURSE sources *.c)
+
+if(CMAKE_SYSTEM_PROCESSOR STREQUAL "aarch64")
+ list(REMOVE_ITEM sources
+ ${CMAKE_CURRENT_SOURCE_DIR}/argon2/opt.c)
+else()
+ list(REMOVE_ITEM sources
+ ${CMAKE_CURRENT_SOURCE_DIR}/argon2/ref.c)
+endif()
+
+add_library(argon2 STATIC
+ ${sources})
+
+target_compile_definitions(argon2
+ PRIVATE
+ -DARGON2_NO_THREADS)
+
+set_target_properties(argon2 PROPERTIES LINKER_LANGUAGE CXX)
+
+target_include_directories(argon2
+ PUBLIC
+ ${CMAKE_CURRENT_SOURCE_DIR})
+
+target_link_libraries(argon2
+ PRIVATE
+ acore-dependency-interface)
+
+set_target_properties(argon2
+ PROPERTIES
+ FOLDER
+ "deps")