Skip to content

Commit 981a20e

Browse files
committed
chore: Modify compilation issues
Modify compilation issues
1 parent d014963 commit 981a20e

1 file changed

Lines changed: 6 additions & 4 deletions

File tree

src/CMakeLists.txt

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,12 @@ cmake_minimum_required(VERSION 3.7)
33
set(VERSION "3.0.0" CACHE STRING "define project version")
44
project(dde-network-core6)
55

6-
set(CMAKE_CXX_STANDARD 11)
6+
set(CMAKE_THREAD_LIBS_INIT "-lpthread")
7+
set(CMAKE_HAVE_THREADS_LIBRARY 1)
8+
set(CMAKE_USE_PTHREADS_INIT 1)
9+
set(CMAKE_PREFER_PTHREAD_FLAG ON)
10+
11+
set(CMAKE_CXX_STANDARD 14)
712
set(CMAKE_INCLUDE_CURRENT_DIR ON)
813
set(CMAKE_AUTOMOC ON)
914
set(CMAKE_AUTORCC ON)
@@ -12,9 +17,6 @@ include(GNUInstallDirs)
1217

1318
file(GLOB_RECURSE SOURCEFILES "*.h" "*.cpp")
1419

15-
16-
17-
1820
add_library(${PROJECT_NAME} SHARED ${SOURCEFILES})
1921

2022
find_package(Qt6 COMPONENTS Core DBus Network Gui LinguistTools REQUIRED)

0 commit comments

Comments
 (0)