Browse Source

cmake add -Wno-deprecated-declarations

tags/v1.1.0
zhengyuanhua 4 years ago
parent
commit
022648b3ef
6 changed files with 17 additions and 9 deletions
  1. +2
    -0
      ge/common/CMakeLists.txt
  2. +8
    -4
      ge/common/ge_common.mk
  3. +1
    -0
      ge/executor/CMakeLists.txt
  4. +4
    -4
      ge/executor/module.mk
  5. +1
    -0
      ge/offline/CMakeLists.txt
  6. +1
    -1
      ge/offline/module.mk

+ 2
- 0
ge/common/CMakeLists.txt View File

@@ -78,6 +78,7 @@ target_compile_options(ge_common PRIVATE
-fvisibility=hidden
-O2
-Werror
-Wno-deprecated-declarations
)

target_include_directories(ge_common PRIVATE
@@ -132,6 +133,7 @@ target_compile_options(ge_common_static PRIVATE
-fvisibility=hidden
-O2
-Werror
-Wno-deprecated-declarations
)

target_include_directories(ge_common_static PRIVATE


+ 8
- 4
ge/common/ge_common.mk View File

@@ -82,8 +82,9 @@ include $(CLEAR_VARS)

LOCAL_MODULE := libge_common

LOCAL_CFLAGS += -Werror -DFMK_SUPPORT_DUMP
LOCAL_CFLAGS += -Werror -DFMK_SUPPORT_DUMP -Wno-deprecated-declarations
LOCAL_CFLAGS += -DPROTOBUF_INLINE_NOT_IN_HEADERS=0 -O2 -Dgoogle=ascend_private

ifeq ($(DEBUG), 1)
LOCAL_CFLAGS += -g -O0
else
@@ -123,8 +124,9 @@ include $(CLEAR_VARS)

LOCAL_MODULE := libge_common

LOCAL_CFLAGS += -Werror -DFMK_SUPPORT_DUMP
LOCAL_CFLAGS += -Werror -DFMK_SUPPORT_DUMP -Wno-deprecated-declarations
LOCAL_CFLAGS += -DPROTOBUF_INLINE_NOT_IN_HEADERS=0 -O2 -Dgoogle=ascend_private

ifeq ($(DEBUG), 1)
LOCAL_CFLAGS += -g -O0
else
@@ -169,8 +171,9 @@ include $(CLEAR_VARS)

LOCAL_MODULE := libge_common

LOCAL_CFLAGS += -Werror -DFMK_SUPPORT_DUMP
LOCAL_CFLAGS += -Werror -DFMK_SUPPORT_DUMP -Wno-deprecated-declarations
LOCAL_CFLAGS += -DPROTOBUF_INLINE_NOT_IN_HEADERS=0 -O2 -Dgoogle=ascend_private

ifeq ($(DEBUG), 1)
LOCAL_CFLAGS += -g -O0
endif
@@ -211,8 +214,9 @@ include $(CLEAR_VARS)

LOCAL_MODULE := libge_common

LOCAL_CFLAGS += -Werror -DFMK_SUPPORT_DUMP
LOCAL_CFLAGS += -Werror -DFMK_SUPPORT_DUMP -Wno-deprecated-declarations
LOCAL_CFLAGS += -DPROTOBUF_INLINE_NOT_IN_HEADERS=0 -O2 -Dgoogle=ascend_private

ifeq ($(DEBUG), 1)
LOCAL_CFLAGS += -g -O0
endif


+ 1
- 0
ge/executor/CMakeLists.txt View File

@@ -81,6 +81,7 @@ add_library(ge_executor STATIC ${SRC_LIST} ${PROTO_HDRS})
target_compile_options(ge_executor PRIVATE
-Werror
-O2
-Wno-deprecated-declarations
)

target_compile_definitions(ge_executor PRIVATE


+ 4
- 4
ge/executor/module.mk View File

@@ -105,7 +105,7 @@ local_ge_executor_ldflags := -lrt -ldl \
include $(CLEAR_VARS)

LOCAL_MODULE := libge_executor
LOCAL_CFLAGS += -Werror
LOCAL_CFLAGS += -Werror -Wno-deprecated-declarations
LOCAL_CFLAGS += -DPROTOBUF_INLINE_NOT_IN_HEADERS=0 -O2 -DDAVINCI_SUPPORT_PROFILING -Dgoogle=ascend_private

LOCAL_SRC_FILES := $(local_ge_executor_src_files)
@@ -131,7 +131,7 @@ include $(BUILD_SHARED_LIBRARY)
include $(CLEAR_VARS)

LOCAL_MODULE := libge_executor
LOCAL_CFLAGS += -Werror
LOCAL_CFLAGS += -Werror -Wno-deprecated-declarations
LOCAL_CFLAGS += -DPROTOBUF_INLINE_NOT_IN_HEADERS=0 -DDAVINCI_SUPPORT_PROFILING -Dgoogle=ascend_private
ifeq ($(DEBUG), 1)
LOCAL_CFLAGS += -g -O0
@@ -167,7 +167,7 @@ include $(BUILD_HOST_SHARED_LIBRARY)
include $(CLEAR_VARS)

LOCAL_MODULE := libge_executor
LOCAL_CFLAGS += -Werror
LOCAL_CFLAGS += -Werror -Wno-deprecated-declarations
LOCAL_CFLAGS += -DPROTOBUF_INLINE_NOT_IN_HEADERS=0 -DDAVINCI_SUPPORT_PROFILING -Dgoogle=ascend_private
ifeq ($(DEBUG), 1)
LOCAL_CFLAGS += -g -O0
@@ -200,7 +200,7 @@ include $(BUILD_HOST_STATIC_LIBRARY)
include $(CLEAR_VARS)

LOCAL_MODULE := libge_executor
LOCAL_CFLAGS += -Werror
LOCAL_CFLAGS += -Werror -Wno-deprecated-declarations
LOCAL_CFLAGS += -DPROTOBUF_INLINE_NOT_IN_HEADERS=0 -DDAVINCI_SUPPORT_PROFILING -Dgoogle=ascend_private
ifeq ($(DEBUG), 1)
LOCAL_CFLAGS += -g -O0


+ 1
- 0
ge/offline/CMakeLists.txt View File

@@ -20,6 +20,7 @@ add_executable(atc ${SRC_LIST} ${PROTO_HDRS})
target_compile_options(atc PRIVATE
-Werror
-O2
-Wno-deprecated-declarations
)

target_compile_definitions(atc PRIVATE


+ 1
- 1
ge/offline/module.mk View File

@@ -5,7 +5,7 @@ include $(CLEAR_VARS)

LOCAL_MODULE := atc

LOCAL_CFLAGS += -Werror
LOCAL_CFLAGS += -Werror -Wno-deprecated-declarations
LOCAL_CFLAGS += -DPROTOBUF_INLINE_NOT_IN_HEADERS=0 -DCOMPILE_OMG_PACKAGE -O2 -Dgoogle=ascend_private

LOCAL_SRC_FILES := \


Loading…
Cancel
Save