Merge lp:~nskaggs/ubuntu-filemanager-app/add-dep-cache into lp:ubuntu-filemanager-app

Proposed by Nicholas Skaggs
Status: Superseded
Proposed branch: lp:~nskaggs/ubuntu-filemanager-app/add-dep-cache
Merge into: lp:ubuntu-filemanager-app
Diff against target: 134 lines (+45/-27)
5 files modified
CMakeLists.txt (+34/-16)
README-Mergeproposal (+4/-0)
tests/autopilot/filemanager/__init__.py (+1/-1)
tests/autopilot/filemanager/tests/__init__.py (+2/-0)
tests/autopilot/filemanager/tests/test_filemanager.py (+4/-10)
To merge this branch: bzr merge lp:~nskaggs/ubuntu-filemanager-app/add-dep-cache
Reviewer Review Type Date Requested Status
Jenkins Bot continuous-integration Needs Fixing
Ubuntu File Manager Developers Pending
Review via email: mp+288713@code.launchpad.net

This proposal has been superseded by a proposal from 2016-03-10.

Commit message

Add dependency cache for click depends downloads

Description of the change

Add dependency cache for click depends downloads

To post a comment you must log in.
Revision history for this message
Jenkins Bot (ubuntu-core-apps-jenkins-bot) wrote :
review: Needs Fixing (continuous-integration)
533. By Nicholas Skaggs

add mkdir for cache

534. By Nicholas Skaggs

use make directory

Unmerged revisions

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'CMakeLists.txt'
--- CMakeLists.txt 2015-10-20 18:28:30 +0000
+++ CMakeLists.txt 2016-03-10 22:12:44 +0000
@@ -73,22 +73,40 @@
7373
74 install(FILES ${CMAKE_CURRENT_BINARY_DIR}/manifest.json filemanager.apparmor ${CONTENT_HUB_EXPORTER} DESTINATION ${CMAKE_INSTALL_PREFIX})74 install(FILES ${CMAKE_CURRENT_BINARY_DIR}/manifest.json filemanager.apparmor ${CONTENT_HUB_EXPORTER} DESTINATION ${CMAKE_INSTALL_PREFIX})
7575
76 MESSAGE("Grabbing upstream libs to ${CMAKE_CURRENT_BINARY_DIR}/upstream-libs")76 set(UPSTREAM_LIBS_DIR ${CMAKE_BINARY_DIR}/upstream-libs)
77 execute_process(77
78 COMMAND mkdir ${CMAKE_CURRENT_BINARY_DIR}/upstream-libs78 #grab dependencies
79 COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/get-click-deps -d ${CMAKE_CURRENT_SOURCE_DIR}/filemanager-libs.json ${CLICK_ARCH} ${CMAKE_CURRENT_BINARY_DIR}/upstream-libs79 set(GET_CLICK_DEPS_TOOL ${CMAKE_SOURCE_DIR}/get-click-deps)
80 )80 set(DEPS_MANIFEST ${CMAKE_CURRENT_SOURCE_DIR}/filemanager-libs.json)
81 MESSAGE("Installing upstream libs from ${CMAKE_CURRENT_BINARY_DIR}/upstream-libs/usr/lib/${ARCH_TRIPLET}/ to ${DATA_DIR}lib/${ARCH_TRIPLET}")81 MESSAGE("Grabbing upstream libs to ${UPSTREAM_LIBS_DIR}")
82 file(GLOB_RECURSE UPSTREAM_LIBS "${CMAKE_CURRENT_BINARY_DIR}/upstream-libs/usr/lib/${ARCH_TRIPLET}/*")82
83 foreach(ITEM ${UPSTREAM_LIBS})83 get_filename_component(BLD_CONFIGURATION_NAME ${CMAKE_BINARY_DIR} NAME)
84 IF( IS_DIRECTORY "${ITEM}" )84 set(UPSTREAM_CACHE $ENV{HOME}/dev/upstream-libs-filemanager/${BLD_CONFIGURATION_NAME})
85 LIST( APPEND DIRS_TO_DEPLOY "${ITEM}" )85 MESSAGE("Upstream libs cache path: ${UPSTREAM_CACHE}")
86 ELSE()86
87 LIST( APPEND FILES_TO_DEPLOY "${ITEM}" )87 if(EXISTS "${UPSTREAM_CACHE}")
88 ENDIF()88 MESSAGE("Upstream libs cache exists.")
89 endforeach()89 file(COPY ${UPSTREAM_CACHE}/upstream-libs/ DESTINATION ${UPSTREAM_LIBS_DIR} PATTERN * )
90 MESSAGE("Following files to install:- ${FILES_TO_DEPLOY}")90 else()
91 INSTALL( FILES ${FILES_TO_DEPLOY} DESTINATION ${DATA_DIR}lib/${ARCH_TRIPLET} )91 MESSAGE("Cache miss, downloading from network.")
92 execute_process(
93 COMMAND mkdir ${UPSTREAM_LIBS_DIR}
94 COMMAND ${GET_CLICK_DEPS_TOOL} -d ${DEPS_MANIFEST} ${CLICK_ARCH} ${UPSTREAM_LIBS_DIR}
95 )
96 # Cache for next usage.
97 file(COPY ${UPSTREAM_LIBS_DIR} DESTINATION ${UPSTREAM_CACHE} )
98 endif()
99 MESSAGE("Installing upstream libs from ${CMAKE_CURRENT_BINARY_DIR}/upstream-libs/usr/lib/${ARCH_TRIPLET}/ to ${DATA_DIR}lib/${ARCH_TRIPLET}")
100 file(GLOB_RECURSE UPSTREAM_LIBS "${CMAKE_CURRENT_BINARY_DIR}/upstream-libs/usr/lib/${ARCH_TRIPLET}/*")
101 foreach(ITEM ${UPSTREAM_LIBS})
102 IF( IS_DIRECTORY "${ITEM}" )
103 LIST( APPEND DIRS_TO_DEPLOY "${ITEM}" )
104 ELSE()
105 LIST( APPEND FILES_TO_DEPLOY "${ITEM}" )
106 ENDIF()
107 endforeach()
108 MESSAGE("Following files to install:- ${FILES_TO_DEPLOY}")
109 INSTALL( FILES ${FILES_TO_DEPLOY} DESTINATION ${DATA_DIR}lib/${ARCH_TRIPLET} )
92else(CLICK_MODE)110else(CLICK_MODE)
93 execute_process(111 execute_process(
94 COMMAND qmake -query QT_INSTALL_QML112 COMMAND qmake -query QT_INSTALL_QML
95113
=== modified file 'README-Mergeproposal'
--- README-Mergeproposal 2015-12-19 07:34:45 +0000
+++ README-Mergeproposal 2016-03-10 22:12:44 +0000
@@ -26,3 +26,7 @@
26The above checklist is more of a guideline to help file manager app trunk stay buildable,26The above checklist is more of a guideline to help file manager app trunk stay buildable,
27stable and up to date.27stable and up to date.
2828
29
30Jenkins
31=======
32In addition to manual reviews, merge proposals are subject to being run in jenkins to ensure the application builds and any unit tests are successful. For more information on jenkins and how it works, see the [Core Apps Jenkins Wiki](https://wiki.ubuntu.com/Touch/CoreApps/Jenkins)
2933
=== modified file 'tests/autopilot/filemanager/__init__.py'
--- tests/autopilot/filemanager/__init__.py 2016-01-14 16:44:26 +0000
+++ tests/autopilot/filemanager/__init__.py 2016-03-10 22:12:44 +0000
@@ -606,7 +606,7 @@
606 """FileDetailsPopover Autopilot emulator."""606 """FileDetailsPopover Autopilot emulator."""
607607
608 def get_path(self):608 def get_path(self):
609 return self.select_single('Label', objectName='pathLabel').text609 return self.select_single('UCLabel', objectName='pathLabel').text
610610
611611
612class PathBar(ubuntuuitoolkit.UbuntuUIToolkitCustomProxyObjectBase):612class PathBar(ubuntuuitoolkit.UbuntuUIToolkitCustomProxyObjectBase):
613613
=== modified file 'tests/autopilot/filemanager/tests/__init__.py'
--- tests/autopilot/filemanager/tests/__init__.py 2015-03-12 20:58:23 +0000
+++ tests/autopilot/filemanager/tests/__init__.py 2016-03-10 22:12:44 +0000
@@ -32,6 +32,8 @@
3232
33import filemanager33import filemanager
34from filemanager import fixture_setup as fm_fixtures34from filemanager import fixture_setup as fm_fixtures
35import gi
36gi.require_version('Click', '0.4')
35from gi.repository import Click37from gi.repository import Click
3638
37logger = logging.getLogger(__name__)39logger = logging.getLogger(__name__)
3840
=== modified file 'tests/autopilot/filemanager/tests/test_filemanager.py'
--- tests/autopilot/filemanager/tests/test_filemanager.py 2015-03-10 21:41:40 +0000
+++ tests/autopilot/filemanager/tests/test_filemanager.py 2016-03-10 22:12:44 +0000
@@ -312,13 +312,10 @@
312312
313 def test_copy_directory(self):313 def test_copy_directory(self):
314 # Set up a directory to copy and a directory to copy it into.314 # Set up a directory to copy and a directory to copy it into.
315 destination_dir_path = os.path.join(self.fakehome,315 destination_dir_path = self.make_directory_in_home()
316 'destination')
317 destination_dir_name = os.path.basename(destination_dir_path)316 destination_dir_name = os.path.basename(destination_dir_path)
318 os.mkdir(destination_dir_path)317 dir_to_copy_path = self.make_directory_in_home()
319 dir_to_copy_path = os.path.join(self.fakehome, 'to_copy')
320 dir_to_copy_name = os.path.basename(dir_to_copy_path)318 dir_to_copy_name = os.path.basename(dir_to_copy_path)
321 os.mkdir(dir_to_copy_path)
322319
323 folder_list_page = self.app.main_view.get_folder_list_page()320 folder_list_page = self.app.main_view.get_folder_list_page()
324 self._assert_number_of_files(2)321 self._assert_number_of_files(2)
@@ -349,13 +346,10 @@
349346
350 def test_cut_directory(self):347 def test_cut_directory(self):
351 # Set up a directory to cut and a directory to move it into.348 # Set up a directory to cut and a directory to move it into.
352 destination_dir_path = os.path.join(self.fakehome,349 destination_dir_path = self.make_directory_in_home()
353 'destination')
354 destination_dir_name = os.path.basename(destination_dir_path)350 destination_dir_name = os.path.basename(destination_dir_path)
355 os.mkdir(destination_dir_path)351 dir_to_cut_path = self.make_directory_in_home()
356 dir_to_cut_path = os.path.join(self.fakehome, 'to_cut')
357 dir_to_cut_name = os.path.basename(dir_to_cut_path)352 dir_to_cut_name = os.path.basename(dir_to_cut_path)
358 os.mkdir(dir_to_cut_path)
359353
360 folder_list_page = self.app.main_view.get_folder_list_page()354 folder_list_page = self.app.main_view.get_folder_list_page()
361 self._assert_number_of_files(2)355 self._assert_number_of_files(2)

Subscribers

People subscribed via source and target branches