Removed preprocessor library (#8845)
This commit is contained in:
parent
5e91ef4640
commit
909dea8b5d
@ -2,9 +2,8 @@
|
||||
# SPDX-License-Identifier: Apache-2.0
|
||||
#
|
||||
|
||||
add_subdirectory(pp)
|
||||
add_subdirectory(itt)
|
||||
add_subdirectory(conditional_compilation)
|
||||
add_subdirectory(util)
|
||||
|
||||
openvino_developer_export_targets(COMPONENT openvino_common TARGETS openvino::pp openvino::itt openvino::conditional_compilation)
|
||||
openvino_developer_export_targets(COMPONENT openvino_common TARGETS openvino::itt openvino::conditional_compilation)
|
||||
|
@ -10,7 +10,7 @@ add_library(${TARGET_NAME} STATIC ${SOURCES})
|
||||
|
||||
add_library(openvino::itt ALIAS ${TARGET_NAME})
|
||||
|
||||
target_link_libraries(${TARGET_NAME} PUBLIC openvino::pp openvino::util)
|
||||
target_link_libraries(${TARGET_NAME} PUBLIC openvino::util)
|
||||
|
||||
if(TARGET ittnotify)
|
||||
target_link_libraries(${TARGET_NAME} PUBLIC ittnotify)
|
||||
|
@ -1,14 +0,0 @@
|
||||
# Copyright (C) 2018-2021 Intel Corporation
|
||||
# SPDX-License-Identifier: Apache-2.0
|
||||
#
|
||||
|
||||
set(TARGET_NAME openvino_preprocessor)
|
||||
|
||||
add_library(${TARGET_NAME} INTERFACE)
|
||||
|
||||
add_library(openvino::pp ALIAS ${TARGET_NAME})
|
||||
|
||||
target_include_directories(${TARGET_NAME} INTERFACE
|
||||
$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/include>)
|
||||
|
||||
ov_install_static_lib(${TARGET_NAME} ngraph)
|
@ -1,49 +0,0 @@
|
||||
// Copyright (C) 2018-2021 Intel Corporation
|
||||
// SPDX-License-Identifier: Apache-2.0
|
||||
//
|
||||
|
||||
/**
|
||||
* @brief Set of macro used by openvino
|
||||
* @file pp.hpp
|
||||
*/
|
||||
|
||||
#pragma once
|
||||
|
||||
// Macros for string conversion
|
||||
#define OV_PP_TOSTRING(...) OV_PP_TOSTRING_(__VA_ARGS__)
|
||||
#define OV_PP_TOSTRING_(...) #__VA_ARGS__
|
||||
|
||||
#define OV_PP_EXPAND(X) X
|
||||
|
||||
#define OV_PP_NARG(...) OV_PP_EXPAND( OV_PP_NARG_(__VA_ARGS__, OV_PP_RSEQ_N()) )
|
||||
#define OV_PP_NARG_(...) OV_PP_EXPAND( OV_PP_ARG_N(__VA_ARGS__) )
|
||||
#define OV_PP_ARG_N(_0, _1, _2, _3, _4, N, ...) N
|
||||
#define OV_PP_RSEQ_N() 0, 4, 3, 2, 1, 0
|
||||
#define OV_PP_NO_ARGS(NAME) ,,,,
|
||||
|
||||
// Macros for names concatenation
|
||||
#define OV_PP_CAT_(x, y) x ## y
|
||||
#define OV_PP_CAT(x, y) OV_PP_CAT_(x, y)
|
||||
#define OV_PP_CAT3_(x, y, z) x ## y ## z
|
||||
#define OV_PP_CAT3(x, y, z) OV_PP_CAT3_(x, y, z)
|
||||
#define OV_PP_CAT4_(x, y, z, w) x ## y ## z ## w
|
||||
#define OV_PP_CAT4(x, y, z, w) OV_PP_CAT4_(x, y, z, w)
|
||||
|
||||
#define OV_PP_OVERLOAD(NAME, ...) OV_PP_EXPAND( OV_PP_CAT3(NAME, _, OV_PP_EXPAND( OV_PP_NARG(OV_PP_NO_ARGS __VA_ARGS__ (NAME)) ))(__VA_ARGS__) )
|
||||
|
||||
// Placeholder for first macro argument
|
||||
#define OV_PP_ARG_PLACEHOLDER_1 0,
|
||||
|
||||
// This macro returns second argument, first argument is ignored
|
||||
#define OV_PP_SECOND_ARG(...) OV_PP_EXPAND(OV_PP_SECOND_ARG_(__VA_ARGS__, 0))
|
||||
#define OV_PP_SECOND_ARG_(...) OV_PP_EXPAND(OV_PP_SECOND_ARG_GET(__VA_ARGS__))
|
||||
#define OV_PP_SECOND_ARG_GET(ignored, val, ...) val
|
||||
|
||||
// Return macro argument value
|
||||
#define OV_PP_IS_ENABLED(x) OV_PP_IS_ENABLED1(x)
|
||||
|
||||
// Generate junk macro or {0, } sequence if val is 1
|
||||
#define OV_PP_IS_ENABLED1(val) OV_PP_IS_ENABLED2(OV_PP_CAT(OV_PP_ARG_PLACEHOLDER_, val))
|
||||
|
||||
// Return second argument from possible sequences {1, 0}, {0, 1, 0}
|
||||
#define OV_PP_IS_ENABLED2(arg1_or_junk) OV_PP_SECOND_ARG(arg1_or_junk 1, 0)
|
Loading…
Reference in New Issue
Block a user