Merge ~santoshbit2007/oxide:uitk_build_fix_cross_compile into oxide:master

Proposed by Santosh
Status: Merged
Approved by: Chris Coulson
Approved revision: 8de5c57401b9f5a1246d15d0bc0a939accc01be7
Merge reported by: Santosh
Merged at revision: not available
Proposed branch: ~santoshbit2007/oxide:uitk_build_fix_cross_compile
Merge into: oxide:master
Diff against target: 33 lines (+14/-3)
1 file modified
build/cmake/qt/ProjectInit.cmake (+14/-3)
Reviewer Review Type Date Requested Status
Chris Coulson Approve
Review via email: mp+316919@code.launchpad.net

Description of the change

I encountered error while cross-compiling for arm when uitk is enabled

No such file or directory
AUTORCC: error: process for /home/oxide_git_arm/oxide_src/src/objdir_release/oxide/qt/uitk/lib/qrc_resources.cpp failed:
No such file or directory
Generating moc_oxideubuntuwebcontextmenu.cpp
Generating moc_oxideubuntuwebcontextmenuitem.cpp
Generating moc_oxideubuntuwebview.cpp
Generating moc_uitk_before_unload_dialog.cpp
Generating moc_uitk_file_picker.cpp
Generating moc_uitk_javascript_dialog.cpp
Generating moc_uitk_web_context_menu.cpp
Generating moc_uitk_web_popup_menu.cpp
rcc failed...
oxide/qt/uitk/lib/CMakeFiles/OxideUbuntuUITK_automoc.dir/build.make:49: recipe for target 'oxide/qt/uitk/lib/CMakeFiles/OxideUbuntuUITK_automoc' failed
make[2]: *** [oxide/qt/uitk/lib/CMakeFiles/OxideUbuntuUITK_automoc] Error 1
CMakeFiles/Makefile2:3435: recipe for target 'oxide/qt/uitk/lib/CMakeFiles/OxideUbuntuUITK_automoc.dir/all' failed
make[1]: *** [oxide/qt/uitk/lib/CMakeFiles/OxideUbuntuUITK_automoc.dir/all] Error 2
Makefile:117: recipe for target 'all' failed
make: *** [all] Error 2

To post a comment you must log in.
Revision history for this message
Chris Coulson (chrisccoulson) :
review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1diff --git a/build/cmake/qt/ProjectInit.cmake b/build/cmake/qt/ProjectInit.cmake
2index ca86364..023952e 100644
3--- a/build/cmake/qt/ProjectInit.cmake
4+++ b/build/cmake/qt/ProjectInit.cmake
5@@ -25,9 +25,6 @@ if(CMAKE_CROSSCOMPILING)
6 if(NOT TARGET Qt5::qmake)
7 add_executable(Qt5::qmake IMPORTED)
8 endif()
9- if(NOT TARGET Qt5::rcc)
10- add_executable(Qt5::rcc IMPORTED)
11- endif()
12 if(NOT TARGET Qt5::uic)
13 add_executable(Qt5::uic IMPORTED)
14 endif()
15@@ -58,4 +55,18 @@ if(CMAKE_CROSSCOMPILING)
16 IMPORTED_LOCATION "${QT_MOC_EXECUTABLE}")
17 unset(QT_MOC_EXECUTABLE)
18 endif()
19+
20+ if(NOT TARGET Qt5::rcc)
21+ find_program(
22+ QT_RCC_EXECUTABLE rcc
23+ PATHS /usr/lib/qt5/bin /usr/lib/${OXIDE_LIBRARY_HOST_ARCHITECTURE}/qt5/bin
24+ NO_DEFAULT_PATH)
25+ if(QT_RCC_EXECUTABLE STREQUAL "QT_RCC_EXECUTABLE-NOTFOUND")
26+ message(FATAL_ERROR "Can't find a rcc executable for the host arch")
27+ endif()
28+ add_executable(Qt5::rcc IMPORTED)
29+ set_target_properties(Qt5::rcc PROPERTIES
30+ IMPORTED_LOCATION "${QT_RCC_EXECUTABLE}")
31+ unset(QT_RCC_EXECUTABLE)
32+ endif()
33 endif()

Subscribers

People subscribed via source and target branches

to all changes: