2023-01-23 12:47:04 +00:00
|
|
|
isEmpty(QMAKE_INFO_PLIST)|!exists($$QMAKE_INFO_PLIST): \
|
2022-05-10 13:02:43 +00:00
|
|
|
return()
|
|
|
|
|
|
|
|
for(plugin, QT_PLUGINS) {
|
|
|
|
!equals(QT_PLUGIN.$${plugin}.TYPE, permissions): \
|
|
|
|
next()
|
|
|
|
|
|
|
|
usage_descriptions = $$eval(QT_PLUGIN.$${plugin}.usage_descriptions)
|
2023-01-16 13:24:54 +00:00
|
|
|
|
|
|
|
found_usage_description = false
|
2022-05-10 13:02:43 +00:00
|
|
|
for(usage_description_key, usage_descriptions) {
|
|
|
|
usage_description = $$system("/usr/libexec/PlistBuddy" \
|
2023-01-16 13:24:54 +00:00
|
|
|
"-c 'print $$usage_description_key' $$QMAKE_INFO_PLIST 2>/dev/null", \
|
|
|
|
singleLine, exit_code)
|
|
|
|
|
|
|
|
!equals(exit_code, 0): \
|
|
|
|
next()
|
|
|
|
|
|
|
|
!isEmpty(usage_description) {
|
|
|
|
found_usage_description = true
|
2022-05-10 13:02:43 +00:00
|
|
|
break()
|
2023-01-16 13:24:54 +00:00
|
|
|
}
|
2022-05-10 13:02:43 +00:00
|
|
|
}
|
|
|
|
|
2023-01-16 13:24:54 +00:00
|
|
|
!$$found_usage_description: \
|
2022-05-10 13:02:43 +00:00
|
|
|
next()
|
|
|
|
|
|
|
|
request_flag = $$eval(QT_PLUGIN.$${plugin}.request_flag)
|
|
|
|
|
|
|
|
QTPLUGIN += $$plugin
|
|
|
|
QMAKE_LFLAGS += $$request_flag
|
|
|
|
|
|
|
|
QMAKE_INTERNAL_INCLUDED_FILES *= $$QMAKE_INFO_PLIST
|
|
|
|
}
|