Merge lp:~cjwatson/ubuntu-app-launch/porting into lp:ubuntu-app-launch/14.04

Proposed by Colin Watson
Status: Rejected
Rejected by: Ted Gould
Proposed branch: lp:~cjwatson/ubuntu-app-launch/porting
Merge into: lp:ubuntu-app-launch/14.04
Diff against target: 99 lines (+30/-15)
5 files modified
CMakeLists.txt (+2/-2)
cmake/UseLttngGenTp.cmake (+20/-12)
debian/control (+1/-1)
null-tracepoint.c (+3/-0)
null-tracepoint.h (+4/-0)
To merge this branch: bzr merge lp:~cjwatson/ubuntu-app-launch/porting
Reviewer Review Type Date Requested Status
Colin Watson Disapprove
Dimitri John Ledkov Needs Information
Ted Gould (community) Approve
PS Jenkins bot (community) continuous-integration Approve
Review via email: mp+210385@code.launchpad.net

Commit message

Use LTTng only on architectures where it is available.

Description of the change

Use LTTng only on architectures where it is available. This should let upstart-app-launch build on all architectures again (it lost arm64 support since saucy).

To post a comment you must log in.
Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :
review: Approve (continuous-integration)
Revision history for this message
Ted Gould (ted) wrote :

A little worried we may need arm64 support, but not going to solve that problem today :-)

review: Approve
Revision history for this message
Dimitri John Ledkov (xnox) wrote :

liblttng-ust-dev is available on ppc64el. No longer needed...

review: Needs Information
Revision history for this message
Colin Watson (cjwatson) wrote :

I'd like to withdraw this, as Dimitri ported ust to arm64 and ppc64el over the weekend, and so upstart-app-launch now builds without this.

review: Disapprove

Unmerged revisions

136. By Colin Watson

Use LTTng only on architectures where it is available.

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 2014-02-13 22:43:55 +0000
3+++ CMakeLists.txt 2014-03-11 12:30:44 +0000
4@@ -17,7 +17,6 @@
5 include(UseGlibGeneration)
6 include(UseGdbusCodegen)
7 include(UseConstantBuilder)
8-include(UseLttngGenTp)
9
10 # Workaround for libexecdir on debian
11 if (EXISTS "/etc/debian_version")
12@@ -61,8 +60,9 @@
13 pkg_check_modules(DBUSTEST REQUIRED dbustest-1>=14.04.0)
14 include_directories(${DBUSTEST_INCLUDE_DIRS})
15
16-pkg_check_modules(LTTNG REQUIRED lttng-ust)
17+pkg_check_modules(LTTNG lttng-ust)
18 include_directories(${LTTNG_INCLUDE_DIRS})
19+include(UseLttngGenTp)
20
21 include_directories(${CMAKE_CURRENT_SOURCE_DIR})
22
23
24=== modified file 'cmake/UseLttngGenTp.cmake'
25--- cmake/UseLttngGenTp.cmake 2013-12-04 11:58:40 +0000
26+++ cmake/UseLttngGenTp.cmake 2014-03-11 12:30:44 +0000
27@@ -3,22 +3,30 @@
28 cmake_policy(SET CMP0011 NEW)
29 endif(POLICY CMP0011)
30
31-find_program(LTTNG_GEN_TP NAMES lttng-gen-tp DOC "lttng-gen-tp executable")
32-if(NOT LTTNG_GEN_TP)
33- message(FATAL_ERROR "Excutable lttng-gen-top not found")
34+if(LTTNG_FOUND)
35+ find_program(LTTNG_GEN_TP NAMES lttng-gen-tp DOC "lttng-gen-tp executable")
36+ if(NOT LTTNG_GEN_TP)
37+ message(FATAL_ERROR "Excutable lttng-gen-top not found")
38+ endif()
39 endif()
40
41 function(add_lttng_gen_tp)
42 set(_one_value NAME)
43 cmake_parse_arguments (arg "" "${_one_value}" "" ${ARGN})
44
45- add_custom_command(
46- OUTPUT "${CMAKE_CURRENT_BINARY_DIR}/${arg_NAME}.h" "${CMAKE_CURRENT_BINARY_DIR}/${arg_NAME}.c"
47- COMMAND "${LTTNG_GEN_TP}"
48- -o "${arg_NAME}.h"
49- -o "${arg_NAME}.c"
50- "${CMAKE_CURRENT_SOURCE_DIR}/${arg_NAME}.tp"
51- WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}
52- DEPENDS "${arg_NAME}.tp"
53- )
54+ if(LTTNG_FOUND)
55+ add_custom_command(
56+ OUTPUT "${CMAKE_CURRENT_BINARY_DIR}/${arg_NAME}.h" "${CMAKE_CURRENT_BINARY_DIR}/${arg_NAME}.c"
57+ COMMAND "${LTTNG_GEN_TP}"
58+ -o "${arg_NAME}.h"
59+ -o "${arg_NAME}.c"
60+ "${CMAKE_CURRENT_SOURCE_DIR}/${arg_NAME}.tp"
61+ WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}
62+ DEPENDS "${arg_NAME}.tp"
63+ )
64+ else()
65+ configure_file("${CMAKE_SOURCE_DIR}/null-tracepoint.c" "${CMAKE_CURRENT_BINARY_DIR}/${arg_NAME}.c")
66+ configure_file("${CMAKE_SOURCE_DIR}/null-tracepoint.h" "${CMAKE_CURRENT_BINARY_DIR}/${arg_NAME}.h")
67+ set_directory_properties(PROPERTIES ADDITIONAL_MAKE_CLEAN_FILES "${CMAKE_CURRENT_BINARY_DIR}/${arg_NAME}.c;${CMAKE_CURRENT_BINARY_DIR}/${arg_NAME}.h")
68+ endif()
69 endfunction(add_lttng_gen_tp)
70
71=== modified file 'debian/control'
72--- debian/control 2014-02-11 03:14:30 +0000
73+++ debian/control 2014-03-11 12:30:44 +0000
74@@ -13,7 +13,7 @@
75 libglib2.0-dev,
76 libgtest-dev,
77 libjson-glib-dev,
78- liblttng-ust-dev,
79+ liblttng-ust-dev [amd64 armhf i386 powerpc],
80 libnih-dbus-dev,
81 libnih-dev,
82 libupstart-dev,
83
84=== added file 'null-tracepoint.c'
85--- null-tracepoint.c 1970-01-01 00:00:00 +0000
86+++ null-tracepoint.c 2014-03-11 12:30:44 +0000
87@@ -0,0 +1,3 @@
88+/* Dummy substitute for a C source file generated by lttng-gen-tp, used on
89+ * architectures where the real thing is not available.
90+ */
91
92=== added file 'null-tracepoint.h'
93--- null-tracepoint.h 1970-01-01 00:00:00 +0000
94+++ null-tracepoint.h 2014-03-11 12:30:44 +0000
95@@ -0,0 +1,4 @@
96+/* Dummy substitute for a header file generated by lttng-gen-tp, used on
97+ * architectures where the real thing is not available.
98+ */
99+#define tracepoint(provider, name, ...)

Subscribers

People subscribed via source and target branches