1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
|
From 9ef91351545ef5543b469ef24282334b3d068a2b Mon Sep 17 00:00:00 2001
From: Michal Klocek <michal.klocek@qt.io>
Date: Fri, 17 May 2019 15:49:23 +0200
Subject: [PATCH] Make linker call look great again
Fix issues with messed up linker path:
* do not use LIBS_PRIVATE on linux at least for passing object
and archive responses files.
* do not use QT and QT_PRIVATE with same libs, it simply
includes libs in LIB and LIB_PRIVATE so doubles linker libs.
* remove bogus dependency for gui and core for webengineheaders pseudo module.
* remove unused egl config flag
Fixes: QTBUG-75832
Task-number: QTBUG-75357
Change-Id: I1720394e636e3f89d546f372b10932dd4ad395fe
Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
---
src/core/core_chromium.pri | 2 --
src/core/core_common.pri | 4 ++--
src/core/core_headers.pro | 1 +
src/core/core_module.pro | 13 ++++++-------
4 files changed, 9 insertions(+), 11 deletions(-)
diff --git a/src/core/core_chromium.pri b/src/core/core_chromium.pri
index 4d8db0d1..d8ef25d8 100644
--- a/src/core/core_chromium.pri
+++ b/src/core/core_chromium.pri
@@ -33,8 +33,6 @@ RCC_DIR = $$OUT_PWD/$$getConfigDir()/.rcc
# whenever we are cross compiling.
qtConfig(webengine-embedded-build): DEFINES += QTWEBENGINE_EMBEDDED_SWITCHES
-qtConfig(egl): CONFIG += egl
-
INCLUDEPATH += $$PWD $$PWD/api
clang_cl {
diff --git a/src/core/core_common.pri b/src/core/core_common.pri
index 8375d89e..51f5e21b 100644
--- a/src/core/core_common.pri
+++ b/src/core/core_common.pri
@@ -2,8 +2,8 @@
# gyp/ninja will take care of the compilation, qmake/make will finish with linking and install.
TARGET = QtWebEngineCore
-QT += qml quick
-QT_PRIVATE += quick-private gui-private core-private webenginecoreheaders-private
+QT += qml-private quick-private gui-private core-private
+QT_PRIVATE += webenginecoreheaders-private
qtConfig(webengine-geolocation): QT += positioning
qtConfig(webengine-webchannel): QT += webchannel
diff --git a/src/core/core_headers.pro b/src/core/core_headers.pro
index 21b5d58c..cd5352eb 100644
--- a/src/core/core_headers.pro
+++ b/src/core/core_headers.pro
@@ -1,5 +1,6 @@
TARGET = QtWebEngineCore
CONFIG += no_private_module header_module internal_module no_plist
+QT -= core gui
MODULE = webenginecoreheaders
MODULE_CFG_FILE = qtwebenginecore-config
load(qt_module)
diff --git a/src/core/core_module.pro b/src/core/core_module.pro
index 10169a49..2bfbc65b 100644
--- a/src/core/core_module.pro
+++ b/src/core/core_module.pro
@@ -10,8 +10,6 @@ linking_pri = $$OUT_PWD/$$getConfigDir()/$${TARGET}.pri
error("Could not find the linking information that gn should have generated.")
}
-load(qt_module)
-
api_library_name = qtwebenginecoreapi$$qtPlatformTargetSuffix()
api_library_path = $$OUT_PWD/api/$$getConfigDir()
@@ -32,10 +30,10 @@ RSP_ARCHIVE_FILE = $$OUT_PWD/$$getConfigDir()/$${TARGET}_a.rsp
for(archive, NINJA_ARCHIVES): RSP_A_CONTENT += $$archive
write_file($$RSP_ARCHIVE_FILE, RSP_A_CONTENT)
macos:LIBS_PRIVATE += -Wl,-filelist,$$shell_quote($$RSP_OBJECT_FILE)
-linux:LIBS_PRIVATE += @$${RSP_OBJECT_FILE}
+linux:QMAKE_LFLAGS += @$${RSP_OBJECT_FILE}
# QTBUG-58710 add main rsp file on windows
win32:QMAKE_LFLAGS += @$${RSP_OBJECT_FILE}
-linux: LIBS_PRIVATE += -Wl,--start-group @$${RSP_ARCHIVE_FILE} -Wl,--end-group
+linux:QMAKE_LFLAGS += -Wl,--start-group @$${RSP_ARCHIVE_FILE} -Wl,--end-group
else: LIBS_PRIVATE += $$NINJA_ARCHIVES
LIBS_PRIVATE += $$NINJA_LIB_DIRS $$NINJA_LIBS
# GN's LFLAGS doesn't always work across all the Linux configurations we support.
@@ -74,7 +72,7 @@ osx {
# API library as response file to the linker.
QMAKE_LFLAGS += @$${api_library_path}$${QMAKE_DIR_SEP}$${api_library_name}.lib.objects
} else {
- LIBS_PRIVATE += -Wl,-whole-archive -l$$api_library_name -Wl,-no-whole-archive
+ QMAKE_LFLAGS += -Wl,-whole-archive -l$$api_library_name -Wl,-no-whole-archive
}
win32 {
@@ -87,8 +85,6 @@ win32 {
# and doesn't let Chromium get access to libc symbols through dlsym.
CONFIG -= bsymbolic_functions
-qtConfig(egl): CONFIG += egl
-
linux:qtConfig(separate_debug_info): QMAKE_POST_LINK="cd $(DESTDIR) && $(STRIP) --strip-unneeded $(TARGET)"
REPACK_DIR = $$OUT_PWD/$$getConfigDir()
@@ -157,3 +153,6 @@ OTHER_FILES = \
$$files(../3rdparty/chromium/*.gypi, true) \
$$files(../3rdparty/chromium/*.gn, true) \
$$files(../3rdparty/chromium/*.gni, true)
+
+load(qt_module)
+
|