Merge lp:~afrantzis/mir/versioned-platform-libraries-plus-server-abi-bump into lp:mir
- versioned-platform-libraries-plus-server-abi-bump
- Merge into development-branch
Proposed by
Alexandros Frantzis
Status: | Superseded |
---|---|
Proposed branch: | lp:~afrantzis/mir/versioned-platform-libraries-plus-server-abi-bump |
Merge into: | lp:mir |
Diff against target: |
552 lines (+80/-47) 29 files modified
CMakeLists.txt (+1/-1) debian/control (+10/-10) debian/libmirserver30.install (+1/-1) debian/mir-client-platform-android2.install (+1/-1) debian/mir-client-platform-mesa2.install (+1/-1) debian/mir-platform-graphics-android2.install (+1/-1) debian/mir-platform-graphics-mesa2.install (+1/-1) src/CMakeLists.txt (+5/-2) src/client/CMakeLists.txt (+1/-2) src/common/sharedlibrary/shared_library_prober.cpp (+9/-1) src/platform/graphics/platform_probe.cpp (+1/-1) src/platforms/CMakeLists.txt (+8/-1) src/platforms/android/client/CMakeLists.txt (+1/-0) src/platforms/android/server/CMakeLists.txt (+1/-0) src/platforms/mesa/client/CMakeLists.txt (+1/-0) src/platforms/mesa/server/CMakeLists.txt (+1/-0) src/server/CMakeLists.txt (+1/-1) src/server/symbols.map (+2/-7) tests/acceptance-tests/test_symbols_required_by_mesa.cpp (+1/-1) tests/include/mir_test_framework/client_platform_factory.h (+2/-2) tests/mir_test_framework/CMakeLists.txt (+2/-0) tests/mir_test_framework/executable_path.cpp (+12/-2) tests/unit-tests/client/test_client_platform.cpp (+2/-2) tests/unit-tests/client/test_probing_client_platform_factory.cpp (+2/-2) tests/unit-tests/graphics/android/test_platform.cpp (+2/-2) tests/unit-tests/graphics/mesa/test_platform.cpp (+2/-2) tests/unit-tests/graphics/test_platform_prober.cpp (+2/-2) tests/unit-tests/shared_library_test.cpp (+1/-1) tests/unit-tests/test_shared_library_prober.cpp (+5/-0) |
To merge this branch: | bzr merge lp:~afrantzis/mir/versioned-platform-libraries-plus-server-abi-bump |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Mir development team | Pending | ||
Review via email: mp+250440@code.launchpad.net |
This proposal has been superseded by a proposal from 2015-02-20.
Commit message
platforms: Use the ABI version in platform library names and packages + server ABI bump for testing CI
Description of the change
platforms: Use the ABI version in platform library names and packages + server ABI bump for testing CI
To post a comment you must log in.
Unmerged revisions
- 2334. By Alexandros Frantzis
-
Bump CI
- 2333. By Alexandros Frantzis
-
Bump mirserver ABI to 30
Preview Diff
[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1 | === modified file 'CMakeLists.txt' | |||
2 | --- CMakeLists.txt 2015-02-19 13:21:15 +0000 | |||
3 | +++ CMakeLists.txt 2015-02-20 12:45:33 +0000 | |||
4 | @@ -27,7 +27,7 @@ | |||
5 | 27 | set(LIBRARY_OUTPUT_PATH ${CMAKE_BINARY_DIR}/lib) | 27 | set(LIBRARY_OUTPUT_PATH ${CMAKE_BINARY_DIR}/lib) |
6 | 28 | 28 | ||
7 | 29 | set(MIR_VERSION_MAJOR 0) | 29 | set(MIR_VERSION_MAJOR 0) |
9 | 30 | set(MIR_VERSION_MINOR 12) # This should change at least with every MIRSERVER_ABI | 30 | set(MIR_VERSION_MINOR 13) # This should change at least with every MIRSERVER_ABI |
10 | 31 | set(MIR_VERSION_PATCH 0) | 31 | set(MIR_VERSION_PATCH 0) |
11 | 32 | 32 | ||
12 | 33 | add_definitions(-DMIR_VERSION_MAJOR=${MIR_VERSION_MAJOR}) | 33 | add_definitions(-DMIR_VERSION_MAJOR=${MIR_VERSION_MAJOR}) |
13 | 34 | 34 | ||
14 | === modified file 'debian/control' | |||
15 | --- debian/control 2015-02-19 10:37:47 +0000 | |||
16 | +++ debian/control 2015-02-20 12:45:33 +0000 | |||
17 | @@ -61,7 +61,7 @@ | |||
18 | 61 | 61 | ||
19 | 62 | #TODO: Packaging infrastructure for better dependency generation, | 62 | #TODO: Packaging infrastructure for better dependency generation, |
20 | 63 | # ala pkg-xorg's xviddriver:Provides and ABI detection. | 63 | # ala pkg-xorg's xviddriver:Provides and ABI detection. |
22 | 64 | Package: libmirserver29 | 64 | Package: libmirserver30 |
23 | 65 | Section: libs | 65 | Section: libs |
24 | 66 | Architecture: i386 amd64 armhf arm64 | 66 | Architecture: i386 amd64 armhf arm64 |
25 | 67 | Multi-Arch: same | 67 | Multi-Arch: same |
26 | @@ -127,7 +127,7 @@ | |||
27 | 127 | Architecture: i386 amd64 armhf arm64 | 127 | Architecture: i386 amd64 armhf arm64 |
28 | 128 | Multi-Arch: same | 128 | Multi-Arch: same |
29 | 129 | Pre-Depends: ${misc:Pre-Depends} | 129 | Pre-Depends: ${misc:Pre-Depends} |
31 | 130 | Depends: libmirserver29 (= ${binary:Version}), | 130 | Depends: libmirserver30 (= ${binary:Version}), |
32 | 131 | libmirplatform-dev (= ${binary:Version}), | 131 | libmirplatform-dev (= ${binary:Version}), |
33 | 132 | libmircommon-dev (= ${binary:Version}), | 132 | libmircommon-dev (= ${binary:Version}), |
34 | 133 | libglm-dev, | 133 | libglm-dev, |
35 | @@ -266,7 +266,7 @@ | |||
36 | 266 | Contains the shared libraries required for the Mir server and client. | 266 | Contains the shared libraries required for the Mir server and client. |
37 | 267 | 267 | ||
38 | 268 | # Longer-term these drivers should move out-of-tree | 268 | # Longer-term these drivers should move out-of-tree |
40 | 269 | Package: mir-platform-graphics-mesa | 269 | Package: mir-platform-graphics-mesa2 |
41 | 270 | Section: libs | 270 | Section: libs |
42 | 271 | Architecture: i386 amd64 armhf arm64 | 271 | Architecture: i386 amd64 armhf arm64 |
43 | 272 | Multi-Arch: same | 272 | Multi-Arch: same |
44 | @@ -280,7 +280,7 @@ | |||
45 | 280 | Contains the shared libraries required for the Mir server to interact with | 280 | Contains the shared libraries required for the Mir server to interact with |
46 | 281 | the hardware platform using the Mesa drivers. | 281 | the hardware platform using the Mesa drivers. |
47 | 282 | 282 | ||
49 | 283 | Package: mir-platform-graphics-android | 283 | Package: mir-platform-graphics-android2 |
50 | 284 | Section: libs | 284 | Section: libs |
51 | 285 | Architecture: i386 amd64 armhf | 285 | Architecture: i386 amd64 armhf |
52 | 286 | Multi-Arch: same | 286 | Multi-Arch: same |
53 | @@ -294,7 +294,7 @@ | |||
54 | 294 | Contains the shared libraries required for the Mir server to interact with | 294 | Contains the shared libraries required for the Mir server to interact with |
55 | 295 | the hardware platform using the Android drivers. | 295 | the hardware platform using the Android drivers. |
56 | 296 | 296 | ||
58 | 297 | Package: mir-client-platform-mesa | 297 | Package: mir-client-platform-mesa2 |
59 | 298 | Section: libs | 298 | Section: libs |
60 | 299 | Architecture: i386 amd64 armhf arm64 | 299 | Architecture: i386 amd64 armhf arm64 |
61 | 300 | Multi-Arch: same | 300 | Multi-Arch: same |
62 | @@ -323,7 +323,7 @@ | |||
63 | 323 | Contains header files required to use the platform specific capabilities of | 323 | Contains header files required to use the platform specific capabilities of |
64 | 324 | the Mir Mesa backend. | 324 | the Mir Mesa backend. |
65 | 325 | 325 | ||
67 | 326 | Package: mir-client-platform-android | 326 | Package: mir-client-platform-android2 |
68 | 327 | Section: libs | 327 | Section: libs |
69 | 328 | Architecture: i386 amd64 armhf | 328 | Architecture: i386 amd64 armhf |
70 | 329 | Multi-Arch: same | 329 | Multi-Arch: same |
71 | @@ -343,8 +343,8 @@ | |||
72 | 343 | Multi-Arch: same | 343 | Multi-Arch: same |
73 | 344 | Pre-Depends: ${misc:Pre-Depends} | 344 | Pre-Depends: ${misc:Pre-Depends} |
74 | 345 | Depends: ${misc:Depends}, | 345 | Depends: ${misc:Depends}, |
77 | 346 | mir-platform-graphics-mesa, | 346 | mir-platform-graphics-mesa2, |
78 | 347 | mir-client-platform-mesa, | 347 | mir-client-platform-mesa2, |
79 | 348 | Description: Display server for Ubuntu - desktop driver metapackage | 348 | Description: Display server for Ubuntu - desktop driver metapackage |
80 | 349 | Mir is a display server running on linux systems, with a focus on efficiency, | 349 | Mir is a display server running on linux systems, with a focus on efficiency, |
81 | 350 | robust operation and a well-defined driver model. | 350 | robust operation and a well-defined driver model. |
82 | @@ -358,8 +358,8 @@ | |||
83 | 358 | Multi-Arch: same | 358 | Multi-Arch: same |
84 | 359 | Pre-Depends: ${misc:Pre-Depends} | 359 | Pre-Depends: ${misc:Pre-Depends} |
85 | 360 | Depends: ${misc:Depends}, | 360 | Depends: ${misc:Depends}, |
88 | 361 | mir-platform-graphics-android, | 361 | mir-platform-graphics-android2, |
89 | 362 | mir-client-platform-android, | 362 | mir-client-platform-android2, |
90 | 363 | Description: Display server for Ubuntu - android driver metapackage | 363 | Description: Display server for Ubuntu - android driver metapackage |
91 | 364 | Mir is a display server running on linux systems, with a focus on efficiency, | 364 | Mir is a display server running on linux systems, with a focus on efficiency, |
92 | 365 | robust operation and a well-defined driver model. | 365 | robust operation and a well-defined driver model. |
93 | 366 | 366 | ||
94 | === renamed file 'debian/libmirserver29.install' => 'debian/libmirserver30.install' | |||
95 | --- debian/libmirserver29.install 2015-02-19 10:37:47 +0000 | |||
96 | +++ debian/libmirserver30.install 2015-02-20 12:45:33 +0000 | |||
97 | @@ -1,1 +1,1 @@ | |||
99 | 1 | usr/lib/*/libmirserver.so.29 | 1 | usr/lib/*/libmirserver.so.30 |
100 | 2 | 2 | ||
101 | === renamed file 'debian/mir-client-platform-android.install' => 'debian/mir-client-platform-android2.install' | |||
102 | --- debian/mir-client-platform-android.install 2015-01-21 07:34:50 +0000 | |||
103 | +++ debian/mir-client-platform-android2.install 2015-02-20 12:45:33 +0000 | |||
104 | @@ -1,1 +1,1 @@ | |||
106 | 1 | usr/lib/*/mir/client-platform/android.so | 1 | usr/lib/*/mir/client-platform/android.so.2 |
107 | 2 | 2 | ||
108 | === renamed file 'debian/mir-client-platform-mesa.install' => 'debian/mir-client-platform-mesa2.install' | |||
109 | --- debian/mir-client-platform-mesa.install 2015-01-21 07:34:50 +0000 | |||
110 | +++ debian/mir-client-platform-mesa2.install 2015-02-20 12:45:33 +0000 | |||
111 | @@ -1,1 +1,1 @@ | |||
113 | 1 | usr/lib/*/mir/client-platform/mesa.so | 1 | usr/lib/*/mir/client-platform/mesa.so.2 |
114 | 2 | 2 | ||
115 | === renamed file 'debian/mir-platform-graphics-android.install' => 'debian/mir-platform-graphics-android2.install' | |||
116 | --- debian/mir-platform-graphics-android.install 2015-01-14 13:09:48 +0000 | |||
117 | +++ debian/mir-platform-graphics-android2.install 2015-02-20 12:45:33 +0000 | |||
118 | @@ -1,1 +1,1 @@ | |||
120 | 1 | usr/lib/*/mir/server-platform/graphics-android.so | 1 | usr/lib/*/mir/server-platform/graphics-android.so.2 |
121 | 2 | 2 | ||
122 | === renamed file 'debian/mir-platform-graphics-mesa.install' => 'debian/mir-platform-graphics-mesa2.install' | |||
123 | --- debian/mir-platform-graphics-mesa.install 2015-01-14 13:09:48 +0000 | |||
124 | +++ debian/mir-platform-graphics-mesa2.install 2015-02-20 12:45:33 +0000 | |||
125 | @@ -1,1 +1,1 @@ | |||
127 | 1 | usr/lib/*/mir/server-platform/graphics-mesa.so | 1 | usr/lib/*/mir/server-platform/graphics-mesa.so.2 |
128 | 2 | 2 | ||
129 | === modified file 'src/CMakeLists.txt' | |||
130 | --- src/CMakeLists.txt 2015-02-18 03:04:18 +0000 | |||
131 | +++ src/CMakeLists.txt 2015-02-20 12:45:33 +0000 | |||
132 | @@ -1,5 +1,4 @@ | |||
135 | 1 | # We need MIRPLATFORM_ABI and MIR_PLATFORM_DRIVER_BINARY in both libmirplatform | 1 | # We need MIRPLATFORM_ABI in both libmirplatform and the platform implementations. |
134 | 2 | # and the platform implementations. | ||
136 | 3 | set(MIRPLATFORM_ABI 7) | 2 | set(MIRPLATFORM_ABI 7) |
137 | 4 | 3 | ||
138 | 5 | # We need MIR_CLIENT_PLATFORM_PATH in both libmirclient and the platform | 4 | # We need MIR_CLIENT_PLATFORM_PATH in both libmirclient and the platform |
139 | @@ -42,3 +41,7 @@ | |||
140 | 42 | set(MIR_COMMON_REFERENCES ${MIR_COMMON_REFERENCES} PARENT_SCOPE) | 41 | set(MIR_COMMON_REFERENCES ${MIR_COMMON_REFERENCES} PARENT_SCOPE) |
141 | 43 | set(MIR_CLIENT_PLATFORM_PATH ${MIR_CLIENT_PLATFORM_PATH} PARENT_SCOPE) | 42 | set(MIR_CLIENT_PLATFORM_PATH ${MIR_CLIENT_PLATFORM_PATH} PARENT_SCOPE) |
142 | 44 | set(MIR_SERVER_PLATFORM_PATH ${MIR_SERVER_PLATFORM_PATH} PARENT_SCOPE) | 43 | set(MIR_SERVER_PLATFORM_PATH ${MIR_SERVER_PLATFORM_PATH} PARENT_SCOPE) |
143 | 44 | |||
144 | 45 | # We need the ABI versions in the tests | ||
145 | 46 | set(MIR_SERVER_GRAPHICS_PLATFORM_ABI ${MIR_SERVER_GRAPHICS_PLATFORM_ABI} PARENT_SCOPE) | ||
146 | 47 | set(MIR_CLIENT_PLATFORM_ABI ${MIR_CLIENT_PLATFORM_ABI} PARENT_SCOPE) | ||
147 | 45 | 48 | ||
148 | === modified file 'src/client/CMakeLists.txt' | |||
149 | --- src/client/CMakeLists.txt 2015-02-13 06:12:34 +0000 | |||
150 | +++ src/client/CMakeLists.txt 2015-02-20 12:45:33 +0000 | |||
151 | @@ -24,11 +24,10 @@ | |||
152 | 24 | ) | 24 | ) |
153 | 25 | 25 | ||
154 | 26 | set(MIRCLIENT_ABI 8) | 26 | set(MIRCLIENT_ABI 8) |
155 | 27 | set(CLIENT_PLATFORM_VERSION "MIR_CLIENT_PLATFORM_2") | ||
156 | 28 | set(symbol_map ${CMAKE_SOURCE_DIR}/src/client/symbols.map) | 27 | set(symbol_map ${CMAKE_SOURCE_DIR}/src/client/symbols.map) |
157 | 29 | 28 | ||
158 | 30 | add_definitions(-DMIR_CLIENT_PLATFORM_PATH="${MIR_CLIENT_PLATFORM_PATH}/") | 29 | add_definitions(-DMIR_CLIENT_PLATFORM_PATH="${MIR_CLIENT_PLATFORM_PATH}/") |
160 | 31 | add_definitions(-DCLIENT_PLATFORM_VERSION="${CLIENT_PLATFORM_VERSION}") | 30 | add_definitions(-DCLIENT_PLATFORM_VERSION="${MIR_CLIENT_PLATFORM_VERSION}") |
161 | 32 | add_definitions(-DMIR_LOGGING_COMPONENT_FALLBACK="mirclient") | 31 | add_definitions(-DMIR_LOGGING_COMPONENT_FALLBACK="mirclient") |
162 | 33 | 32 | ||
163 | 34 | add_subdirectory(rpc/) | 33 | add_subdirectory(rpc/) |
164 | 35 | 34 | ||
165 | === modified file 'src/common/sharedlibrary/shared_library_prober.cpp' | |||
166 | --- src/common/sharedlibrary/shared_library_prober.cpp 2014-09-02 00:28:47 +0000 | |||
167 | +++ src/common/sharedlibrary/shared_library_prober.cpp 2015-02-20 12:45:33 +0000 | |||
168 | @@ -37,6 +37,14 @@ | |||
169 | 37 | } | 37 | } |
170 | 38 | return std::error_code{}; | 38 | return std::error_code{}; |
171 | 39 | } | 39 | } |
172 | 40 | |||
173 | 41 | // Libraries can be of the form libname.so(.X.Y) | ||
174 | 42 | bool path_has_library_extension(boost::filesystem::path const& path) | ||
175 | 43 | { | ||
176 | 44 | return path.extension().string() == ".so" || | ||
177 | 45 | path.string().find(".so.") != std::string::npos; | ||
178 | 46 | } | ||
179 | 47 | |||
180 | 40 | } | 48 | } |
181 | 41 | 49 | ||
182 | 42 | std::vector<std::shared_ptr<mir::SharedLibrary>> | 50 | std::vector<std::shared_ptr<mir::SharedLibrary>> |
183 | @@ -57,7 +65,7 @@ | |||
184 | 57 | std::vector<std::shared_ptr<mir::SharedLibrary>> libraries; | 65 | std::vector<std::shared_ptr<mir::SharedLibrary>> libraries; |
185 | 58 | for (; iterator != boost::filesystem::directory_iterator() ; ++iterator) | 66 | for (; iterator != boost::filesystem::directory_iterator() ; ++iterator) |
186 | 59 | { | 67 | { |
188 | 60 | if (iterator->path().extension().string() == ".so") | 68 | if (path_has_library_extension(iterator->path())) |
189 | 61 | { | 69 | { |
190 | 62 | try | 70 | try |
191 | 63 | { | 71 | { |
192 | 64 | 72 | ||
193 | === modified file 'src/platform/graphics/platform_probe.cpp' | |||
194 | --- src/platform/graphics/platform_probe.cpp 2014-12-17 13:48:10 +0000 | |||
195 | +++ src/platform/graphics/platform_probe.cpp 2015-02-20 12:45:33 +0000 | |||
196 | @@ -47,7 +47,7 @@ | |||
197 | 47 | { | 47 | { |
198 | 48 | // Tried to probe a SharedLibrary that isn't a platform module? | 48 | // Tried to probe a SharedLibrary that isn't a platform module? |
199 | 49 | ml::log(ml::Severity::warning, | 49 | ml::log(ml::Severity::warning, |
201 | 50 | std::string{"Failed to probe module. Not a platform library? Error: "} + err.what(), | 50 | std::string{"Failed to probe module. Not a platform library or incorrect ABI version? Error: "} + err.what(), |
202 | 51 | "Platform Probing"); | 51 | "Platform Probing"); |
203 | 52 | } | 52 | } |
204 | 53 | } | 53 | } |
205 | 54 | 54 | ||
206 | === modified file 'src/platforms/CMakeLists.txt' | |||
207 | --- src/platforms/CMakeLists.txt 2015-02-18 03:04:18 +0000 | |||
208 | +++ src/platforms/CMakeLists.txt 2015-02-20 12:45:33 +0000 | |||
209 | @@ -3,7 +3,9 @@ | |||
210 | 3 | # This ABI is much smaller than the full libmirplatform ABI. | 3 | # This ABI is much smaller than the full libmirplatform ABI. |
211 | 4 | # | 4 | # |
212 | 5 | # TODO: Add an extra driver-ABI check target. | 5 | # TODO: Add an extra driver-ABI check target. |
214 | 6 | set(MIR_SERVER_GRAPHICS_PLATFORM_VERSION "MIR_GRAPHICS_PLATFORM_2") | 6 | set(MIR_SERVER_GRAPHICS_PLATFORM_ABI 2) |
215 | 7 | set(MIR_SERVER_GRAPHICS_PLATFORM_ABI ${MIR_SERVER_GRAPHICS_PLATFORM_ABI} PARENT_SCOPE) | ||
216 | 8 | set(MIR_SERVER_GRAPHICS_PLATFORM_VERSION "MIR_GRAPHICS_PLATFORM_${MIR_SERVER_GRAPHICS_PLATFORM_ABI}") | ||
217 | 7 | set(MIR_SERVER_GRAPHICS_PLATFORM_VERSION ${MIR_SERVER_GRAPHICS_PLATFORM_VERSION} PARENT_SCOPE) | 9 | set(MIR_SERVER_GRAPHICS_PLATFORM_VERSION ${MIR_SERVER_GRAPHICS_PLATFORM_VERSION} PARENT_SCOPE) |
218 | 8 | 10 | ||
219 | 9 | set(MIR_SERVER_PLATFORM_PATH | 11 | set(MIR_SERVER_PLATFORM_PATH |
220 | @@ -14,6 +16,11 @@ | |||
221 | 14 | PARENT_SCOPE | 16 | PARENT_SCOPE |
222 | 15 | ) | 17 | ) |
223 | 16 | 18 | ||
224 | 19 | set(MIR_CLIENT_PLATFORM_ABI 2) | ||
225 | 20 | set(MIR_CLIENT_PLATFORM_ABI ${MIR_CLIENT_PLATFORM_ABI} PARENT_SCOPE) | ||
226 | 21 | set(MIR_CLIENT_PLATFORM_VERSION "MIR_CLIENT_PLATFORM_${MIR_CLIENT_PLATFORM_ABI}") | ||
227 | 22 | set(MIR_CLIENT_PLATFORM_VERSION ${MIR_CLIENT_PLATFORM_VERSION} PARENT_SCOPE) | ||
228 | 23 | |||
229 | 17 | set(server_common_include_dirs | 24 | set(server_common_include_dirs |
230 | 18 | ${PROJECT_SOURCE_DIR}/include/platform | 25 | ${PROJECT_SOURCE_DIR}/include/platform |
231 | 19 | ) | 26 | ) |
232 | 20 | 27 | ||
233 | === modified file 'src/platforms/android/client/CMakeLists.txt' | |||
234 | --- src/platforms/android/client/CMakeLists.txt 2015-02-13 06:12:34 +0000 | |||
235 | +++ src/platforms/android/client/CMakeLists.txt 2015-02-20 12:45:33 +0000 | |||
236 | @@ -26,6 +26,7 @@ | |||
237 | 26 | OUTPUT_NAME android | 26 | OUTPUT_NAME android |
238 | 27 | LIBRARY_OUTPUT_DIRECTORY ${LIBRARY_OUTPUT_PATH}/client-modules | 27 | LIBRARY_OUTPUT_DIRECTORY ${LIBRARY_OUTPUT_PATH}/client-modules |
239 | 28 | PREFIX "" | 28 | PREFIX "" |
240 | 29 | SUFFIX ".so.${MIR_CLIENT_PLATFORM_ABI}" | ||
241 | 29 | LINK_FLAGS "-Wl,--version-script,${symbol_map}" | 30 | LINK_FLAGS "-Wl,--version-script,${symbol_map}" |
242 | 30 | ) | 31 | ) |
243 | 31 | 32 | ||
244 | 32 | 33 | ||
245 | === modified file 'src/platforms/android/server/CMakeLists.txt' | |||
246 | --- src/platforms/android/server/CMakeLists.txt 2015-02-13 06:12:34 +0000 | |||
247 | +++ src/platforms/android/server/CMakeLists.txt 2015-02-20 12:45:33 +0000 | |||
248 | @@ -63,6 +63,7 @@ | |||
249 | 63 | OUTPUT_NAME graphics-android | 63 | OUTPUT_NAME graphics-android |
250 | 64 | LIBRARY_OUTPUT_DIRECTORY ${LIBRARY_OUTPUT_PATH}/server-modules | 64 | LIBRARY_OUTPUT_DIRECTORY ${LIBRARY_OUTPUT_PATH}/server-modules |
251 | 65 | PREFIX "" | 65 | PREFIX "" |
252 | 66 | SUFFIX ".so.${MIR_SERVER_GRAPHICS_PLATFORM_ABI}" | ||
253 | 66 | LINK_FLAGS "-Wl,--exclude-libs=ALL -Wl,--version-script,${symbol_map}" | 67 | LINK_FLAGS "-Wl,--exclude-libs=ALL -Wl,--version-script,${symbol_map}" |
254 | 67 | ) | 68 | ) |
255 | 68 | 69 | ||
256 | 69 | 70 | ||
257 | === modified file 'src/platforms/mesa/client/CMakeLists.txt' | |||
258 | --- src/platforms/mesa/client/CMakeLists.txt 2015-01-22 09:00:14 +0000 | |||
259 | +++ src/platforms/mesa/client/CMakeLists.txt 2015-02-20 12:45:33 +0000 | |||
260 | @@ -28,6 +28,7 @@ | |||
261 | 28 | OUTPUT_NAME mesa | 28 | OUTPUT_NAME mesa |
262 | 29 | LIBRARY_OUTPUT_DIRECTORY ${LIBRARY_OUTPUT_PATH}/client-modules | 29 | LIBRARY_OUTPUT_DIRECTORY ${LIBRARY_OUTPUT_PATH}/client-modules |
263 | 30 | PREFIX "" | 30 | PREFIX "" |
264 | 31 | SUFFIX ".so.${MIR_CLIENT_PLATFORM_ABI}" | ||
265 | 31 | LINK_FLAGS "-Wl,--version-script,${symbol_map}" | 32 | LINK_FLAGS "-Wl,--version-script,${symbol_map}" |
266 | 32 | ) | 33 | ) |
267 | 33 | 34 | ||
268 | 34 | 35 | ||
269 | === modified file 'src/platforms/mesa/server/CMakeLists.txt' | |||
270 | --- src/platforms/mesa/server/CMakeLists.txt 2015-02-13 06:12:34 +0000 | |||
271 | +++ src/platforms/mesa/server/CMakeLists.txt 2015-02-20 12:45:33 +0000 | |||
272 | @@ -64,6 +64,7 @@ | |||
273 | 64 | OUTPUT_NAME graphics-mesa | 64 | OUTPUT_NAME graphics-mesa |
274 | 65 | LIBRARY_OUTPUT_DIRECTORY ${LIBRARY_OUTPUT_PATH}/server-modules | 65 | LIBRARY_OUTPUT_DIRECTORY ${LIBRARY_OUTPUT_PATH}/server-modules |
275 | 66 | PREFIX "" | 66 | PREFIX "" |
276 | 67 | SUFFIX ".so.${MIR_SERVER_GRAPHICS_PLATFORM_ABI}" | ||
277 | 67 | LINK_FLAGS "-Wl,--exclude-libs=ALL -Wl,--version-script,${symbol_map}" | 68 | LINK_FLAGS "-Wl,--exclude-libs=ALL -Wl,--version-script,${symbol_map}" |
278 | 68 | ) | 69 | ) |
279 | 69 | 70 | ||
280 | 70 | 71 | ||
281 | === modified file 'src/server/CMakeLists.txt' | |||
282 | --- src/server/CMakeLists.txt 2015-02-19 13:21:15 +0000 | |||
283 | +++ src/server/CMakeLists.txt 2015-02-20 12:45:33 +0000 | |||
284 | @@ -106,7 +106,7 @@ | |||
285 | 106 | ${CMAKE_SOURCE_DIR}/include/server/mir DESTINATION "include/mirserver" | 106 | ${CMAKE_SOURCE_DIR}/include/server/mir DESTINATION "include/mirserver" |
286 | 107 | ) | 107 | ) |
287 | 108 | 108 | ||
289 | 109 | set(MIRSERVER_ABI 29) # Be sure to increment MIR_VERSION_MINOR at the same time | 109 | set(MIRSERVER_ABI 30) # Be sure to increment MIR_VERSION_MINOR at the same time |
290 | 110 | set(symbol_map ${CMAKE_CURRENT_SOURCE_DIR}/symbols.map) | 110 | set(symbol_map ${CMAKE_CURRENT_SOURCE_DIR}/symbols.map) |
291 | 111 | 111 | ||
292 | 112 | set_target_properties( | 112 | set_target_properties( |
293 | 113 | 113 | ||
294 | === modified file 'src/server/symbols.map' | |||
295 | --- src/server/symbols.map 2015-02-19 10:43:31 +0000 | |||
296 | +++ src/server/symbols.map 2015-02-20 12:45:33 +0000 | |||
297 | @@ -1,4 +1,4 @@ | |||
299 | 1 | MIR_SERVER_29 { | 1 | MIR_SERVER_30 { |
300 | 2 | global: | 2 | global: |
301 | 3 | extern "C++" { | 3 | extern "C++" { |
302 | 4 | # Symbols not yet picked up by script | 4 | # Symbols not yet picked up by script |
303 | @@ -226,6 +226,7 @@ | |||
304 | 226 | mir::scene::SurfaceCoordinator::operator*; | 226 | mir::scene::SurfaceCoordinator::operator*; |
305 | 227 | mir::scene::SurfaceCoordinator::raise*; | 227 | mir::scene::SurfaceCoordinator::raise*; |
306 | 228 | mir::scene::SurfaceCoordinator::remove_surface*; | 228 | mir::scene::SurfaceCoordinator::remove_surface*; |
307 | 229 | mir::scene::SurfaceCoordinator::surface_at*; | ||
308 | 229 | mir::scene::SurfaceCoordinator::?SurfaceCoordinator*; | 230 | mir::scene::SurfaceCoordinator::?SurfaceCoordinator*; |
309 | 230 | mir::scene::SurfaceCoordinator::SurfaceCoordinator*; | 231 | mir::scene::SurfaceCoordinator::SurfaceCoordinator*; |
310 | 231 | mir::scene::SurfaceCreationParameters::of_buffer_usage*; | 232 | mir::scene::SurfaceCreationParameters::of_buffer_usage*; |
311 | @@ -735,9 +736,3 @@ | |||
312 | 735 | }; | 736 | }; |
313 | 736 | local: *; | 737 | local: *; |
314 | 737 | }; | 738 | }; |
315 | 738 | |||
316 | 739 | MIR_SERVER_29.1 { | ||
317 | 740 | global: | ||
318 | 741 | mir::scene::SurfaceCoordinator::surface_at*; | ||
319 | 742 | local: *; | ||
320 | 743 | } MIR_SERVER_29; | ||
321 | 744 | 739 | ||
322 | === modified file 'tests/acceptance-tests/test_symbols_required_by_mesa.cpp' | |||
323 | --- tests/acceptance-tests/test_symbols_required_by_mesa.cpp 2015-02-13 06:12:34 +0000 | |||
324 | +++ tests/acceptance-tests/test_symbols_required_by_mesa.cpp 2015-02-20 12:45:33 +0000 | |||
325 | @@ -28,7 +28,7 @@ | |||
326 | 28 | 28 | ||
327 | 29 | TEST(SymbolsRequiredByMesa, are_exported_by_client_platform_mesa) | 29 | TEST(SymbolsRequiredByMesa, are_exported_by_client_platform_mesa) |
328 | 30 | { | 30 | { |
330 | 31 | auto const handle = dlopen(mtf::client_platform("mesa.so").c_str(), RTLD_LAZY); | 31 | auto const handle = dlopen(mtf::client_platform("mesa").c_str(), RTLD_LAZY); |
331 | 32 | ASSERT_THAT(handle, NotNull()); | 32 | ASSERT_THAT(handle, NotNull()); |
332 | 33 | 33 | ||
333 | 34 | auto const sym = dlsym(handle, "mir_client_mesa_egl_native_display_is_valid"); | 34 | auto const sym = dlsym(handle, "mir_client_mesa_egl_native_display_is_valid"); |
334 | 35 | 35 | ||
335 | === modified file 'tests/include/mir_test_framework/client_platform_factory.h' | |||
336 | --- tests/include/mir_test_framework/client_platform_factory.h 2015-02-13 06:12:34 +0000 | |||
337 | +++ tests/include/mir_test_framework/client_platform_factory.h 2015-02-20 12:45:33 +0000 | |||
338 | @@ -37,7 +37,7 @@ | |||
339 | 37 | mtd::MockClientContext ctx; | 37 | mtd::MockClientContext ctx; |
340 | 38 | ON_CALL(ctx, populate_server_package(_)) | 38 | ON_CALL(ctx, populate_server_package(_)) |
341 | 39 | .WillByDefault(Invoke([](MirPlatformPackage& package) { ::memset(&package, 0, sizeof(package)); })); | 39 | .WillByDefault(Invoke([](MirPlatformPackage& package) { ::memset(&package, 0, sizeof(package)); })); |
343 | 40 | platform_library = std::make_shared<mir::SharedLibrary>(client_platform("android.so")); | 40 | platform_library = std::make_shared<mir::SharedLibrary>(client_platform("android")); |
344 | 41 | auto platform_factory = platform_library->load_function<mir::client::CreateClientPlatform>("create_client_platform"); | 41 | auto platform_factory = platform_library->load_function<mir::client::CreateClientPlatform>("create_client_platform"); |
345 | 42 | return platform_factory(&ctx); | 42 | return platform_factory(&ctx); |
346 | 43 | } | 43 | } |
347 | @@ -46,7 +46,7 @@ | |||
348 | 46 | mir::client::ClientContext* client_context) | 46 | mir::client::ClientContext* client_context) |
349 | 47 | { | 47 | { |
350 | 48 | using namespace testing; | 48 | using namespace testing; |
352 | 49 | platform_library = std::make_shared<mir::SharedLibrary>(client_platform("mesa.so")); | 49 | platform_library = std::make_shared<mir::SharedLibrary>(client_platform("mesa")); |
353 | 50 | auto platform_factory = platform_library->load_function<mir::client::CreateClientPlatform>("create_client_platform"); | 50 | auto platform_factory = platform_library->load_function<mir::client::CreateClientPlatform>("create_client_platform"); |
354 | 51 | return platform_factory(client_context); | 51 | return platform_factory(client_context); |
355 | 52 | } | 52 | } |
356 | 53 | 53 | ||
357 | === modified file 'tests/mir_test_framework/CMakeLists.txt' | |||
358 | --- tests/mir_test_framework/CMakeLists.txt 2015-02-13 06:12:34 +0000 | |||
359 | +++ tests/mir_test_framework/CMakeLists.txt 2015-02-20 12:45:33 +0000 | |||
360 | @@ -14,6 +14,8 @@ | |||
361 | 14 | add_definitions( | 14 | add_definitions( |
362 | 15 | -DMIR_CLIENT_PLATFORM_PATH="${MIR_CLIENT_PLATFORM_PATH}" | 15 | -DMIR_CLIENT_PLATFORM_PATH="${MIR_CLIENT_PLATFORM_PATH}" |
363 | 16 | -DMIR_SERVER_PLATFORM_PATH="${MIR_SERVER_PLATFORM_PATH}" | 16 | -DMIR_SERVER_PLATFORM_PATH="${MIR_SERVER_PLATFORM_PATH}" |
364 | 17 | -DMIR_CLIENT_PLATFORM_ABI_STRING="${MIR_CLIENT_PLATFORM_ABI}" | ||
365 | 18 | -DMIR_SERVER_GRAPHICS_PLATFORM_ABI_STRING="${MIR_SERVER_GRAPHICS_PLATFORM_ABI}" | ||
366 | 17 | ) | 19 | ) |
367 | 18 | 20 | ||
368 | 19 | set( | 21 | set( |
369 | 20 | 22 | ||
370 | === modified file 'tests/mir_test_framework/executable_path.cpp' | |||
371 | --- tests/mir_test_framework/executable_path.cpp 2015-02-13 06:12:34 +0000 | |||
372 | +++ tests/mir_test_framework/executable_path.cpp 2015-02-20 12:45:33 +0000 | |||
373 | @@ -47,10 +47,15 @@ | |||
374 | 47 | 47 | ||
375 | 48 | std::string mir_test_framework::server_platform(std::string const& name) | 48 | std::string mir_test_framework::server_platform(std::string const& name) |
376 | 49 | { | 49 | { |
377 | 50 | std::string libname{name}; | ||
378 | 51 | |||
379 | 52 | if (libname.find(".so") == std::string::npos) | ||
380 | 53 | libname += ".so." MIR_SERVER_GRAPHICS_PLATFORM_ABI_STRING; | ||
381 | 54 | |||
382 | 50 | for (auto const& option : | 55 | for (auto const& option : |
383 | 51 | {library_path() + "/server-modules/", library_path() + "/server-platform/", std::string(MIR_SERVER_PLATFORM_PATH) + '/'}) | 56 | {library_path() + "/server-modules/", library_path() + "/server-platform/", std::string(MIR_SERVER_PLATFORM_PATH) + '/'}) |
384 | 52 | { | 57 | { |
386 | 53 | auto path_to_test = option + name; | 58 | auto path_to_test = option + libname; |
387 | 54 | if (boost::filesystem::exists(path_to_test)) | 59 | if (boost::filesystem::exists(path_to_test)) |
388 | 55 | return path_to_test; | 60 | return path_to_test; |
389 | 56 | } | 61 | } |
390 | @@ -60,10 +65,15 @@ | |||
391 | 60 | 65 | ||
392 | 61 | std::string mir_test_framework::client_platform(std::string const& name) | 66 | std::string mir_test_framework::client_platform(std::string const& name) |
393 | 62 | { | 67 | { |
394 | 68 | std::string libname{name}; | ||
395 | 69 | |||
396 | 70 | if (libname.find(".so") == std::string::npos) | ||
397 | 71 | libname += ".so." MIR_CLIENT_PLATFORM_ABI_STRING; | ||
398 | 72 | |||
399 | 63 | for (auto const& option : | 73 | for (auto const& option : |
400 | 64 | {library_path() + "/client-modules/", library_path() + "/client-platform/", std::string(MIR_CLIENT_PLATFORM_PATH) + '/'}) | 74 | {library_path() + "/client-modules/", library_path() + "/client-platform/", std::string(MIR_CLIENT_PLATFORM_PATH) + '/'}) |
401 | 65 | { | 75 | { |
403 | 66 | auto path_to_test = option + name; | 76 | auto path_to_test = option + libname; |
404 | 67 | if (boost::filesystem::exists(path_to_test)) | 77 | if (boost::filesystem::exists(path_to_test)) |
405 | 68 | return path_to_test; | 78 | return path_to_test; |
406 | 69 | } | 79 | } |
407 | 70 | 80 | ||
408 | === modified file 'tests/unit-tests/client/test_client_platform.cpp' | |||
409 | --- tests/unit-tests/client/test_client_platform.cpp 2015-02-13 06:12:34 +0000 | |||
410 | +++ tests/unit-tests/client/test_client_platform.cpp 2015-02-20 12:45:33 +0000 | |||
411 | @@ -79,7 +79,7 @@ | |||
412 | 79 | }; | 79 | }; |
413 | 80 | 80 | ||
414 | 81 | #ifdef MIR_BUILD_PLATFORM_ANDROID | 81 | #ifdef MIR_BUILD_PLATFORM_ANDROID |
416 | 82 | ClientPlatformTraits const android_platform{"android.so", | 82 | ClientPlatformTraits const android_platform{"android", |
417 | 83 | [](MirPlatformPackage& pkg) | 83 | [](MirPlatformPackage& pkg) |
418 | 84 | { | 84 | { |
419 | 85 | ::memset(&pkg, 0, sizeof(pkg)); | 85 | ::memset(&pkg, 0, sizeof(pkg)); |
420 | @@ -94,7 +94,7 @@ | |||
421 | 94 | #endif | 94 | #endif |
422 | 95 | 95 | ||
423 | 96 | #ifdef MIR_BUILD_PLATFORM_MESA | 96 | #ifdef MIR_BUILD_PLATFORM_MESA |
425 | 97 | ClientPlatformTraits const mesa_platform{"mesa.so", | 97 | ClientPlatformTraits const mesa_platform{"mesa", |
426 | 98 | [](MirPlatformPackage& pkg) | 98 | [](MirPlatformPackage& pkg) |
427 | 99 | { | 99 | { |
428 | 100 | ::memset(&pkg, 0, sizeof(pkg)); | 100 | ::memset(&pkg, 0, sizeof(pkg)); |
429 | 101 | 101 | ||
430 | === modified file 'tests/unit-tests/client/test_probing_client_platform_factory.cpp' | |||
431 | --- tests/unit-tests/client/test_probing_client_platform_factory.cpp 2015-02-13 06:12:34 +0000 | |||
432 | +++ tests/unit-tests/client/test_probing_client_platform_factory.cpp 2015-02-20 12:45:33 +0000 | |||
433 | @@ -36,10 +36,10 @@ | |||
434 | 36 | { | 36 | { |
435 | 37 | std::vector<std::shared_ptr<mir::SharedLibrary>> modules; | 37 | std::vector<std::shared_ptr<mir::SharedLibrary>> modules; |
436 | 38 | #ifdef MIR_BUILD_PLATFORM_MESA | 38 | #ifdef MIR_BUILD_PLATFORM_MESA |
438 | 39 | modules.push_back(std::make_shared<mir::SharedLibrary>(mtf::client_platform("mesa.so"))); | 39 | modules.push_back(std::make_shared<mir::SharedLibrary>(mtf::client_platform("mesa"))); |
439 | 40 | #endif | 40 | #endif |
440 | 41 | #ifdef MIR_BUILD_PLATFORM_ANDROID | 41 | #ifdef MIR_BUILD_PLATFORM_ANDROID |
442 | 42 | modules.push_back(std::make_shared<mir::SharedLibrary>(mtf::client_platform("android.so"))); | 42 | modules.push_back(std::make_shared<mir::SharedLibrary>(mtf::client_platform("android"))); |
443 | 43 | #endif | 43 | #endif |
444 | 44 | return modules; | 44 | return modules; |
445 | 45 | } | 45 | } |
446 | 46 | 46 | ||
447 | === modified file 'tests/unit-tests/graphics/android/test_platform.cpp' | |||
448 | --- tests/unit-tests/graphics/android/test_platform.cpp 2015-02-13 06:12:34 +0000 | |||
449 | +++ tests/unit-tests/graphics/android/test_platform.cpp 2015-02-20 12:45:33 +0000 | |||
450 | @@ -239,7 +239,7 @@ | |||
451 | 239 | 239 | ||
452 | 240 | ON_CALL(hwaccess, hw_get_module(_,_)).WillByDefault(Return(-1)); | 240 | ON_CALL(hwaccess, hw_get_module(_,_)).WillByDefault(Return(-1)); |
453 | 241 | 241 | ||
455 | 242 | mir::SharedLibrary platform_lib{mtf::server_platform("graphics-android.so")}; | 242 | mir::SharedLibrary platform_lib{mtf::server_platform("graphics-android")}; |
456 | 243 | auto probe = platform_lib.load_function<mg::PlatformProbe>(probe_platform); | 243 | auto probe = platform_lib.load_function<mg::PlatformProbe>(probe_platform); |
457 | 244 | EXPECT_EQ(mg::PlatformPriority::unsupported, probe()); | 244 | EXPECT_EQ(mg::PlatformPriority::unsupported, probe()); |
458 | 245 | } | 245 | } |
459 | @@ -248,7 +248,7 @@ | |||
460 | 248 | { | 248 | { |
461 | 249 | testing::NiceMock<mtd::HardwareAccessMock> hwaccess; | 249 | testing::NiceMock<mtd::HardwareAccessMock> hwaccess; |
462 | 250 | 250 | ||
464 | 251 | mir::SharedLibrary platform_lib{mtf::server_platform("graphics-android.so")}; | 251 | mir::SharedLibrary platform_lib{mtf::server_platform("graphics-android")}; |
465 | 252 | auto probe = platform_lib.load_function<mg::PlatformProbe>(probe_platform); | 252 | auto probe = platform_lib.load_function<mg::PlatformProbe>(probe_platform); |
466 | 253 | EXPECT_EQ(mg::PlatformPriority::best, probe()); | 253 | EXPECT_EQ(mg::PlatformPriority::best, probe()); |
467 | 254 | } | 254 | } |
468 | 255 | 255 | ||
469 | === modified file 'tests/unit-tests/graphics/mesa/test_platform.cpp' | |||
470 | --- tests/unit-tests/graphics/mesa/test_platform.cpp 2015-02-13 06:12:34 +0000 | |||
471 | +++ tests/unit-tests/graphics/mesa/test_platform.cpp 2015-02-20 12:45:33 +0000 | |||
472 | @@ -304,7 +304,7 @@ | |||
473 | 304 | { | 304 | { |
474 | 305 | mtf::UdevEnvironment udev_environment; | 305 | mtf::UdevEnvironment udev_environment; |
475 | 306 | 306 | ||
477 | 307 | mir::SharedLibrary platform_lib{mtf::server_platform("graphics-mesa.so")}; | 307 | mir::SharedLibrary platform_lib{mtf::server_platform("graphics-mesa")}; |
478 | 308 | auto probe = platform_lib.load_function<mg::PlatformProbe>(probe_platform); | 308 | auto probe = platform_lib.load_function<mg::PlatformProbe>(probe_platform); |
479 | 309 | EXPECT_EQ(mg::PlatformPriority::unsupported, probe()); | 309 | EXPECT_EQ(mg::PlatformPriority::unsupported, probe()); |
480 | 310 | } | 310 | } |
481 | @@ -315,7 +315,7 @@ | |||
482 | 315 | 315 | ||
483 | 316 | udev_environment.add_standard_device("standard-drm-devices"); | 316 | udev_environment.add_standard_device("standard-drm-devices"); |
484 | 317 | 317 | ||
486 | 318 | mir::SharedLibrary platform_lib{mtf::server_platform("graphics-mesa.so")}; | 318 | mir::SharedLibrary platform_lib{mtf::server_platform("graphics-mesa")}; |
487 | 319 | auto probe = platform_lib.load_function<mg::PlatformProbe>(probe_platform); | 319 | auto probe = platform_lib.load_function<mg::PlatformProbe>(probe_platform); |
488 | 320 | EXPECT_EQ(mg::PlatformPriority::best, probe()); | 320 | EXPECT_EQ(mg::PlatformPriority::best, probe()); |
489 | 321 | } | 321 | } |
490 | 322 | 322 | ||
491 | === modified file 'tests/unit-tests/graphics/test_platform_prober.cpp' | |||
492 | --- tests/unit-tests/graphics/test_platform_prober.cpp 2014-12-17 19:59:21 +0000 | |||
493 | +++ tests/unit-tests/graphics/test_platform_prober.cpp 2015-02-20 12:45:33 +0000 | |||
494 | @@ -47,10 +47,10 @@ | |||
495 | 47 | std::vector<std::shared_ptr<mir::SharedLibrary>> modules; | 47 | std::vector<std::shared_ptr<mir::SharedLibrary>> modules; |
496 | 48 | 48 | ||
497 | 49 | #ifdef MIR_BUILD_PLATFORM_MESA | 49 | #ifdef MIR_BUILD_PLATFORM_MESA |
499 | 50 | modules.push_back(std::make_shared<mir::SharedLibrary>(mtf::server_platform("graphics-mesa.so"))); | 50 | modules.push_back(std::make_shared<mir::SharedLibrary>(mtf::server_platform("graphics-mesa"))); |
500 | 51 | #endif | 51 | #endif |
501 | 52 | #ifdef MIR_BUILD_PLATFORM_ANDROID | 52 | #ifdef MIR_BUILD_PLATFORM_ANDROID |
503 | 53 | modules.push_back(std::make_shared<mir::SharedLibrary>(mtf::server_platform("graphics-android.so"))); | 53 | modules.push_back(std::make_shared<mir::SharedLibrary>(mtf::server_platform("graphics-android"))); |
504 | 54 | #endif | 54 | #endif |
505 | 55 | return modules; | 55 | return modules; |
506 | 56 | } | 56 | } |
507 | 57 | 57 | ||
508 | === modified file 'tests/unit-tests/shared_library_test.cpp' | |||
509 | --- tests/unit-tests/shared_library_test.cpp 2015-02-13 06:12:34 +0000 | |||
510 | +++ tests/unit-tests/shared_library_test.cpp 2015-02-20 12:45:33 +0000 | |||
511 | @@ -59,7 +59,7 @@ | |||
512 | 59 | public: | 59 | public: |
513 | 60 | SharedLibrary() | 60 | SharedLibrary() |
514 | 61 | : nonexistent_library{"imma_totally_not_a_library"}, | 61 | : nonexistent_library{"imma_totally_not_a_library"}, |
516 | 62 | existing_library{mtf::client_platform("mesa.so")}, | 62 | existing_library{mtf::client_platform("dummy.so")}, |
517 | 63 | nonexistent_function{"yo_dawg"}, | 63 | nonexistent_function{"yo_dawg"}, |
518 | 64 | existing_function{"create_client_platform"}, | 64 | existing_function{"create_client_platform"}, |
519 | 65 | existent_version{"MIR_CLIENT_PLATFORM_2"}, | 65 | existent_version{"MIR_CLIENT_PLATFORM_2"}, |
520 | 66 | 66 | ||
521 | === added file 'tests/unit-tests/test_data/libinvalid.so.3' | |||
522 | === modified file 'tests/unit-tests/test_shared_library_prober.cpp' | |||
523 | --- tests/unit-tests/test_shared_library_prober.cpp 2015-01-21 07:34:50 +0000 | |||
524 | +++ tests/unit-tests/test_shared_library_prober.cpp 2015-02-20 12:45:33 +0000 | |||
525 | @@ -162,6 +162,7 @@ | |||
526 | 162 | EXPECT_CALL(report, loading_library(FilenameMatches("libarmhf.so"))); | 162 | EXPECT_CALL(report, loading_library(FilenameMatches("libarmhf.so"))); |
527 | 163 | EXPECT_CALL(report, loading_library(FilenameMatches("libi386.so"))); | 163 | EXPECT_CALL(report, loading_library(FilenameMatches("libi386.so"))); |
528 | 164 | EXPECT_CALL(report, loading_library(FilenameMatches("libarm64.so"))); | 164 | EXPECT_CALL(report, loading_library(FilenameMatches("libarm64.so"))); |
529 | 165 | EXPECT_CALL(report, loading_library(FilenameMatches("libinvalid.so.3"))); | ||
530 | 165 | 166 | ||
531 | 166 | mir::libraries_for_path(library_path, report); | 167 | mir::libraries_for_path(library_path, report); |
532 | 167 | } | 168 | } |
533 | @@ -175,6 +176,7 @@ | |||
534 | 175 | bool amd64_failed{false}; | 176 | bool amd64_failed{false}; |
535 | 176 | bool i386_failed{false}; | 177 | bool i386_failed{false}; |
536 | 177 | bool arm64_failed{false}; | 178 | bool arm64_failed{false}; |
537 | 179 | bool invalid_failed{false}; | ||
538 | 178 | 180 | ||
539 | 179 | ON_CALL(report, loading_failed(FilenameMatches("libamd64.so"), _)) | 181 | ON_CALL(report, loading_failed(FilenameMatches("libamd64.so"), _)) |
540 | 180 | .WillByDefault(InvokeWithoutArgs([&amd64_failed]() { amd64_failed = true; })); | 182 | .WillByDefault(InvokeWithoutArgs([&amd64_failed]() { amd64_failed = true; })); |
541 | @@ -184,8 +186,11 @@ | |||
542 | 184 | .WillByDefault(InvokeWithoutArgs([&i386_failed]() { i386_failed = true; })); | 186 | .WillByDefault(InvokeWithoutArgs([&i386_failed]() { i386_failed = true; })); |
543 | 185 | ON_CALL(report, loading_failed(FilenameMatches("libarm64.so"), _)) | 187 | ON_CALL(report, loading_failed(FilenameMatches("libarm64.so"), _)) |
544 | 186 | .WillByDefault(InvokeWithoutArgs([&arm64_failed]() { arm64_failed = true; })); | 188 | .WillByDefault(InvokeWithoutArgs([&arm64_failed]() { arm64_failed = true; })); |
545 | 189 | ON_CALL(report, loading_failed(FilenameMatches("libinvalid.so.3"), _)) | ||
546 | 190 | .WillByDefault(InvokeWithoutArgs([&invalid_failed]() { invalid_failed = true; })); | ||
547 | 187 | 191 | ||
548 | 188 | mir::libraries_for_path(library_path, report); | 192 | mir::libraries_for_path(library_path, report); |
549 | 189 | 193 | ||
550 | 194 | EXPECT_TRUE(invalid_failed); | ||
551 | 190 | EXPECT_TRUE(i386_failed || amd64_failed || armhf_failed || arm64_failed); | 195 | EXPECT_TRUE(i386_failed || amd64_failed || armhf_failed || arm64_failed); |
552 | 191 | } | 196 | } |