Changeset View
Standalone View
src/qt/CMakeLists.txt
Show First 20 Lines • Show All 330 Lines • ▼ Show 20 Lines | set_target_properties(BitcoinABC-Qt PROPERTIES | ||||
RESOURCE "${BITCOINQT_BUNDLE_RESOURCES}" | RESOURCE "${BITCOINQT_BUNDLE_RESOURCES}" | ||||
) | ) | ||||
set_source_files_properties( | set_source_files_properties( | ||||
"${INFO_PLIST_STRINGS_PATH}" | "${INFO_PLIST_STRINGS_PATH}" | ||||
PROPERTIES | PROPERTIES | ||||
MACOSX_PACKAGE_LOCATION "Resources/${INFO_PLIST_STRINGS_FILE}" | MACOSX_PACKAGE_LOCATION "Resources/${INFO_PLIST_STRINGS_FILE}" | ||||
) | ) | ||||
add_custom_target(BitcoinABC-Qt-strip | |||||
COMMAND "${CMAKE_STRIP}" -u -r "$<TARGET_FILE:BitcoinABC-Qt>" | |||||
) | |||||
add_dependencies(BitcoinABC-Qt-strip BitcoinABC-Qt) | |||||
deadalnix: Considering this is something that is OSX specific, the names chosen are very confusing. It… | |||||
deadalnixUnsubmitted Not Done Inline ActionsThis doesn't looks like the original command. Can you explain what's up? It looks like it is modifying the file in place, which is usually a bad idea for dependency management reasons. deadalnix: This doesn't looks like the original command. Can you explain what's up?
It looks like it is… | |||||
FabienAuthorUnsubmitted Done Inline ActionsI should have put a comment regarding the name: this is for compatibility with what autotools produce (and what the content from the metadata file expects). This does not apply to the stripped target though, but it keeps the name consistent with the non stripped target. The strip parameters are specific to the OSX strip tool, which differ from the gnu strip. Unfortunately I have been unable to find a man page online, I had to run the man from an OSX machine. The parameters are the same that recent CMake versions use for executables, you can find some infos here: https://gitlab.kitware.com/cmake/cmake/merge_requests/2892. Yes it is modifying the file in place and is then exclusive with the non stripped version. Fabien: I should have put a comment regarding the name: this is for compatibility with what autotools… | |||||
include(DoOrFail) | include(DoOrFail) | ||||
find_program_or_fail(CMAKE_INSTALL_NAME_TOOL "install_name_tool") | find_program_or_fail(CMAKE_INSTALL_NAME_TOOL "install_name_tool") | ||||
find_program_or_fail(CMAKE_OTOOL "otool") | find_program_or_fail(CMAKE_OTOOL "otool") | ||||
set(QT_INSTALLER_SUPPORTED_LANGUAGES | set(QT_INSTALLER_SUPPORTED_LANGUAGES | ||||
"da" | "da" | ||||
"de" | "de" | ||||
"es" | "es" | ||||
▲ Show 20 Lines • Show All 55 Lines • ▼ Show 20 Lines | COMMAND | ||||
"${PYTHON_EXECUTABLE}" | "${PYTHON_EXECUTABLE}" | ||||
"${MACDEPLOYQTPLUS}" | "${MACDEPLOYQTPLUS}" | ||||
"$<TARGET_BUNDLE_DIR:BitcoinABC-Qt>" | "$<TARGET_BUNDLE_DIR:BitcoinABC-Qt>" | ||||
-translations-dir "${QT_TRANSLATION_DIR}" | -translations-dir "${QT_TRANSLATION_DIR}" | ||||
-add-qt-tr "${QT_LOCALES}" | -add-qt-tr "${QT_LOCALES}" | ||||
WORKING_DIRECTORY | WORKING_DIRECTORY | ||||
"${CMAKE_BINARY_DIR}" | "${CMAKE_BINARY_DIR}" | ||||
DEPENDS | DEPENDS | ||||
BitcoinABC-Qt | BitcoinABC-Qt-strip | ||||
) | ) | ||||
# Building the DMG background image requires several steps: | # Building the DMG background image requires several steps: | ||||
# 1/ The SVG file must be edited to display the package name | # 1/ The SVG file must be edited to display the package name | ||||
# 2/ The SVG file should be transformed into a couple PNG files, on for | # 2/ The SVG file should be transformed into a couple PNG files, on for | ||||
# low resolution screens and one for high resolution screens. | # low resolution screens and one for high resolution screens. | ||||
# 3/ The PNG files must be transformed into a multi-resolution TIFF file. | # 3/ The PNG files must be transformed into a multi-resolution TIFF file. | ||||
# The names are not set arbitrarily, they follow Apple's guidelines for | # The names are not set arbitrarily, they follow Apple's guidelines for | ||||
▲ Show 20 Lines • Show All 99 Lines • ▼ Show 20 Lines | add_custom_target(osx-dmg | ||||
-dmg | -dmg | ||||
-fancy "${MACDEPLOY_DIR}/fancy.plist" | -fancy "${MACDEPLOY_DIR}/fancy.plist" | ||||
-volname "${OSX_VOLNAME}" | -volname "${OSX_VOLNAME}" | ||||
WORKING_DIRECTORY | WORKING_DIRECTORY | ||||
"${CMAKE_BINARY_DIR}" | "${CMAKE_BINARY_DIR}" | ||||
DEPENDS | DEPENDS | ||||
"${BACKGROUND_TIFF_MULTIRES}" | "${BACKGROUND_TIFF_MULTIRES}" | ||||
) | ) | ||||
add_dependencies(osx-dmg BitcoinABC-Qt) | add_dependencies(osx-dmg BitcoinABC-Qt-strip) | ||||
endif() | endif() | ||||
endif() | endif() | ||||
# Test tests | # Test tests | ||||
add_subdirectory(test) | add_subdirectory(test) |
Considering this is something that is OSX specific, the names chosen are very confusing. It seems that this an OSX duplication of the bitcoin-qt target. You need to fix this before proceeding.