1 Star 0 Fork 1

码头喇叭/GPSTk

forked from mmmmachine/GPSTk 
加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
build_config.h.in 2.57 KB
一键复制 编辑 原始数据 按行查看 历史
johnk 提交于 2015-12-01 13:01 . remove deprecated config macros
#ifndef BUILD_CONFIG_H
#define BUILD_CONFIG_H
//------------------------------------------------------------
// Purpose:
// Define your source root and build root from CMake vars
// so you can pass paths from CMake into C++
//------------------------------------------------------------
// Notes:
// If you need these CMake variables for pure C code,
// then use the #define variables, otherwise, use the
// get methods defined in the gpstk namespace.
//------------------------------------------------------------
#include <string>
namespace gpstk
{
//----------------------------------------
// Purpose: get path separator character, e.g. ":" or ";"
// Usage: std::string file_sep = gpstk::getPathSep()
//----------------------------------------
inline std::string getPathSep( void )
{
#ifdef _WIN32
const std::string path_sep(";");
#else
const std::string path_sep(":");
#endif
return( path_sep );
}
//----------------------------------------
// Purpose: get file system file separator character, e.g. "/" or "\"
// Usage: std::string file_sep = gpstk::getFileSep()
//----------------------------------------
inline std::string getFileSep( void )
{
#ifdef _WIN32
const std::string file_sep("\\");
#else
const std::string file_sep("/");
#endif
return( file_sep );
}
//----------------------------------------
// Purpose: get file system path to top level of source tree
// Usage: std::string src_path = gpstk::getPathSrc()
//----------------------------------------
inline std::string getPathSrc( void )
{
return( "@PROJECT_SOURCE_DIR@" );
}
//----------------------------------------
// Purpose: get file system path to the CMake build dir
// Usage: std::string build_path = gpstk::getPathBuild()
//----------------------------------------
inline std::string getPathBuild( void )
{
return( "@PROJECT_BINARY_DIR@" );
}
//----------------------------------------
// Purpose: get file system path to location of gpstk data files
// Usage: std::string data_path = gpstk::getPathData()
//----------------------------------------
inline std::string getPathData( void )
{
return( "@GPSTK_TEST_DATA_DIR@" );
}
//----------------------------------------
// Purpose: get file system path to location to write temp test output
// Usage: std::string temp_path = gpstk::getPathTestTemp()
//----------------------------------------
inline std::string getPathTestTemp( void )
{
return( "@GPSTK_TEST_OUTPUT_DIR@" );
}
}
#endif // BUILD_CONFIG_H
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
C++
1
https://gitee.com/mtlb250/GPSTk.git
git@gitee.com:mtlb250/GPSTk.git
mtlb250
GPSTk
GPSTk
master

搜索帮助