De-duplicate macro _CRT_SECURE_NO_WARNINGS / _CRT_SECURE_NO_DEPRECATE (#136)
* De-duplicate macro _CRT_SECURE_NO_WARNINGS / _CRT_SECURE_NO_DEPRECATE * Move all macros to base.h * Fix CI
This commit is contained in:
committed by
GitHub
parent
8fe7f5dc43
commit
74bf00a5ab
19
include/rabit/base.h
Normal file
19
include/rabit/base.h
Normal file
@@ -0,0 +1,19 @@
|
||||
/*!
|
||||
* Copyright (c) 2020 by Contributors
|
||||
* \file base.h
|
||||
* \brief Macros common to all headers
|
||||
*
|
||||
* \author Hyunsu Cho
|
||||
*/
|
||||
|
||||
#ifndef RABIT_BASE_H_
|
||||
#define RABIT_BASE_H_
|
||||
|
||||
#ifndef _CRT_SECURE_NO_WARNINGS
|
||||
#define _CRT_SECURE_NO_WARNINGS
|
||||
#endif // _CRT_SECURE_NO_WARNINGS
|
||||
#ifndef _CRT_SECURE_NO_DEPRECATE
|
||||
#define _CRT_SECURE_NO_DEPRECATE
|
||||
#endif // _CRT_SECURE_NO_DEPRECATE
|
||||
|
||||
#endif // RABIT_BASE_H_
|
||||
@@ -6,7 +6,8 @@
|
||||
*/
|
||||
#ifndef RABIT_INTERNAL_UTILS_H_
|
||||
#define RABIT_INTERNAL_UTILS_H_
|
||||
#define _CRT_SECURE_NO_WARNINGS
|
||||
|
||||
#include <rabit/base.h>
|
||||
#include <string.h>
|
||||
#include <cstdio>
|
||||
#include <string>
|
||||
|
||||
Reference in New Issue
Block a user