9864d2c6f3
This reverts commit521a85395d
. Having libraries resolved to absolute file paths by configure has annoying consequences: 1. The Qt installer needs to unabsolutify paths in all kinds of files. This is error-prone and fragile. 2. It hurts Qt's relocatabilty. The absolute paths are unlikely to be right on different systems. 3. Qt's configure must imitate linker behavior correctly to do the resolution right on every platform, which is hard to get right. Consequently, the disadvantages of521a8539
outweigh the advantages. Task-number: QTBUG-72903 Change-Id: I3e159c46a1348963615b95614e56f026ecb2aefd Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io> Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
39 lines
1.3 KiB
Plaintext
39 lines
1.3 KiB
Plaintext
suffix =
|
|
for(ever) {
|
|
CC_USES =
|
|
LD_USES =
|
|
for (use, QMAKE_USE$${suffix}) {
|
|
use = $$split(use, /)
|
|
name = $$take_first(use)
|
|
nu = $$upper($$replace(name, -, _))
|
|
!contains(use, linkonly): CC_USES += $$nu
|
|
!contains(use, nolink): LD_USES += $$nu
|
|
}
|
|
CC_USES = $$resolve_depends(CC_USES, QMAKE_DEPENDS_, _CC)
|
|
for (nu, CC_USES) {
|
|
!defined(QMAKE_LIBS_$$nu, var): \
|
|
error("Library '$$lower($$replace(nu, _, -))' is not defined.")
|
|
|
|
DEFINES += $$eval(QMAKE_DEFINES_$${nu})
|
|
INCLUDEPATH += $$eval(QMAKE_INCDIR_$${nu})
|
|
}
|
|
LD_USES = $$resolve_depends(LD_USES, QMAKE_DEPENDS_, _LD)
|
|
for (nu, LD_USES) {
|
|
!defined(QMAKE_LIBS_$$nu, var): \
|
|
error("Library '$$lower($$replace(nu, _, -))' is not defined.")
|
|
|
|
QMAKE_LIBDIR += $$eval(QMAKE_LIBDIR_$$nu)
|
|
|
|
android {
|
|
ABI_LIBS = $$eval(QMAKE_LIBS_$${nu}_$${QT_ARCH})
|
|
isEmpty(ABI_LIBS): ABI_LIBS = $$eval(QMAKE_LIBS_$${nu})
|
|
LIBS$${suffix} += $$ABI_LIBS
|
|
} else: debug: \
|
|
LIBS$${suffix} += $$eval(QMAKE_LIBS_$${nu}_DEBUG) $$eval(QMAKE_LIBS_$$nu)
|
|
else: \
|
|
LIBS$${suffix} += $$eval(QMAKE_LIBS_$${nu}_RELEASE) $$eval(QMAKE_LIBS_$$nu)
|
|
}
|
|
!isEmpty(suffix): break()
|
|
suffix = "_PRIVATE"
|
|
}
|