加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
该仓库未声明开源许可证文件(LICENSE),使用请关注具体项目描述及其代码上游依赖。
克隆/下载
0029-Pin-server-Adaptation-to-gcc12-only-solves-the-build.patch 1.36 KB
一键复制 编辑 原始数据 按行查看 历史
From 868531920b4f5a16f636219d44fbf36a9abd401b Mon Sep 17 00:00:00 2001
From: dingguangya <dingguangya1@huawei.com>
Date: Mon, 7 Aug 2023 17:02:15 +0800
Subject: [PATCH 2/2] [Pin-server] Adaptation to gcc12 only solves the build
problem
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 233f345..0a72863 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -17,7 +17,7 @@ include(cmake/common.cmake)
#-------------------------------------------------------------------------------
set(CMAKE_BUILD_WITH_INSTALL_NAME_DIR ON)
-set(CMAKE_CXX_STANDARD 14 CACHE STRING "C++ standard to conform to")
+set(CMAKE_CXX_STANDARD 17 CACHE STRING "C++ standard to conform to")
find_package(MLIR REQUIRED CONFIG)
message(STATUS "Using MLIRConfig.cmake in: ${MLIR_DIR}")
@@ -46,7 +46,7 @@ add_definitions(${LLVM_DEFINITIONS})
include_directories(include)
-add_compile_options(-std=c++14 -Wall -fPIC)
+add_compile_options(-std=c++17 -Wall -fPIC)
# Proto file
get_filename_component(plg_proto "protos/plugin.proto" ABSOLUTE)
get_filename_component(plg_proto_path "${plg_proto}" PATH)
diff --git a/cmake/common.cmake b/cmake/common.cmake
index f18c25b..cf48699 100644
--- a/cmake/common.cmake
+++ b/cmake/common.cmake
@@ -1,6 +1,6 @@
cmake_minimum_required(VERSION 3.5.1)
-set (CMAKE_CXX_STANDARD 14)
+set (CMAKE_CXX_STANDARD 17)
find_package(Threads REQUIRED)
--
2.33.0.windows.2
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化