Merge ~alfonsosanchezbeato/snappy-hwe-snaps/+git/locationd:fix-caracalla into ~snappy-hwe-team/snappy-hwe-snaps/+git/locationd:master

Proposed by Alfonso Sanchez-Beato
Status: Merged
Approved by: Roberto Mier Escandon
Approved revision: bacf7daf478b6a8a6057ca160c3fb4f0bd9ecdf8
Merged at revision: ab80ed4afe8fc20b8d3df8fa8c8c2a478b6325d7
Proposed branch: ~alfonsosanchezbeato/snappy-hwe-snaps/+git/locationd:fix-caracalla
Merge into: ~snappy-hwe-team/snappy-hwe-snaps/+git/locationd:master
Diff against target: 111 lines (+22/-14)
3 files modified
prebuilt/meta/hooks/configure (+19/-12)
snapcraft.yaml (+1/-1)
src/location/providers/ubx/provider.cpp (+2/-1)
Reviewer Review Type Date Requested Status
System Enablement Bot continuous-integration Approve
Roberto Mier Escandon (community) Approve
Simon Fels Approve
Review via email: mp+332549@code.launchpad.net

Description of the change

Fix for regression in caracalla (LP: #1715724)

To post a comment you must log in.
Revision history for this message
Simon Fels (morphis) wrote :

LGTM

review: Approve
Revision history for this message
System Enablement Bot (system-enablement-ci-bot) wrote :
review: Needs Fixing (continuous-integration)
Revision history for this message
Roberto Mier Escandon (rmescandon) wrote :

looks good

review: Approve
Revision history for this message
System Enablement Bot (system-enablement-ci-bot) wrote :

PASSED: Successfully build documentation, rev: bacf7daf478b6a8a6057ca160c3fb4f0bd9ecdf8

Generated documentation is available at https://jenkins.canonical.com/system-enablement/job/snappy-hwe-snaps-snap-docs/874/

Revision history for this message
System Enablement Bot (system-enablement-ci-bot) wrote :
review: Needs Fixing (continuous-integration)
Revision history for this message
System Enablement Bot (system-enablement-ci-bot) wrote :

PASSED: Successfully build documentation, rev: bacf7daf478b6a8a6057ca160c3fb4f0bd9ecdf8

Generated documentation is available at https://jenkins.canonical.com/system-enablement/job/snappy-hwe-snaps-snap-docs/875/

Revision history for this message
System Enablement Bot (system-enablement-ci-bot) wrote :
review: Approve (continuous-integration)

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
diff --git a/prebuilt/meta/hooks/configure b/prebuilt/meta/hooks/configure
index e17071f..e414551 100755
--- a/prebuilt/meta/hooks/configure
+++ b/prebuilt/meta/hooks/configure
@@ -9,6 +9,13 @@ export LD_LIBRARY_PATH=$SNAP_LIBRARY_PATH:$LD_LIBRARY_PATH
99
10ubx_enable=$(snapctl get ubx.provider.enable)10ubx_enable=$(snapctl get ubx.provider.enable)
11ubx_device=$(snapctl get ubx.provider.device)11ubx_device=$(snapctl get ubx.provider.device)
12# Keep compatibility with old name
13if [ -z "$ubx_device" ]; then
14 ubx_device=$(snapctl get ubx.provider.path)
15 if [ -n "$ubx_device" ]; then
16 snapctl set ubx.provider.device="$ubx_device"
17 fi
18fi
12ubx_protocol=$(snapctl get ubx.provider.protocol)19ubx_protocol=$(snapctl get ubx.provider.protocol)
13ubx_assist_enable=$(snapctl get ubx.provider.assistnow.enable)20ubx_assist_enable=$(snapctl get ubx.provider.assistnow.enable)
14ubx_assist_token=$(snapctl get ubx.provider.assistnow.token)21ubx_assist_token=$(snapctl get ubx.provider.assistnow.token)
@@ -23,39 +30,39 @@ mls_host=$(snapctl get mls.provider.host)
23mls_api_key=$(snapctl get mls.provider.apikey)30mls_api_key=$(snapctl get mls.provider.apikey)
2431
25if [ -n "$ubx_enable" ]; then32if [ -n "$ubx_enable" ]; then
26 $SNAP/bin/locationd set --key=ubx.provider.enable --value="$ubx_enable"33 "$SNAP"/bin/locationd set --key=ubx.provider.enable --value="$ubx_enable"
27fi34fi
2835
29if [ -n "$ubx_device" ]; then36if [ -n "$ubx_device" ]; then
30 $SNAP/bin/locationd set --key=ubx.provider.device --value="$ubx_device"37 "$SNAP"/bin/locationd set --key=ubx.provider.device --value="$ubx_device"
31fi38fi
3239
33if [ -n "$ubx_protocol" ]; then40if [ -n "$ubx_protocol" ]; then
34 $SNAP/bin/locationd set --key=ubx.provider.protocol --value="$ubx_protocol"41 "$SNAP"/bin/locationd set --key=ubx.provider.protocol --value="$ubx_protocol"
35fi42fi
3643
37if [ -n "$ubx_assist_enable" ]; then44if [ -n "$ubx_assist_enable" ]; then
38 $SNAP/bin/locationd set --key=ubx.provider.assist_now.enable --value="$ubx_assist_enable"45 "$SNAP"/bin/locationd set --key=ubx.provider.assist_now.enable --value="$ubx_assist_enable"
39fi46fi
4047
41if [ -n "$ubx_assist_token" ]; then48if [ -n "$ubx_assist_token" ]; then
42 $SNAP/bin/locationd set --key=ubx.provider.assist_now.token --value="$ubx_assist_token"49 "$SNAP"/bin/locationd set --key=ubx.provider.assist_now.token --value="$ubx_assist_token"
43fi50fi
4451
45if [ -n "$ubx_assist_timeout" ]; then52if [ -n "$ubx_assist_timeout" ]; then
46 $SNAP/bin/locationd set --key=ubx.provider.assist_now.timeout --value="$ubx_assist_timeout"53 "$SNAP"/bin/locationd set --key=ubx.provider.assist_now.timeout --value="$ubx_assist_timeout"
47fi54fi
4855
49if [ -n "$sirf_enable" ]; then56if [ -n "$sirf_enable" ]; then
50 $SNAP/bin/locationd set --key=sirf.provider.enable --value="$sirf_enable"57 "$SNAP"/bin/locationd set --key=sirf.provider.enable --value="$sirf_enable"
51fi58fi
5259
53if [ -n "$sirf_device" ]; then60if [ -n "$sirf_device" ]; then
54 $SNAP/bin/locationd set --key=sirf.provider.device --value="$sirf_device"61 "$SNAP"/bin/locationd set --key=sirf.provider.device --value="$sirf_device"
55fi62fi
5663
57if [ -n "$sirf_protocol" ]; then64if [ -n "$sirf_protocol" ]; then
58 $SNAP/bin/locationd set --key=sirf.provider.protocol --value="$sirf_protocol"65 "$SNAP"/bin/locationd set --key=sirf.provider.protocol --value="$sirf_protocol"
59fi66fi
6067
61# Disable Mozilla Location Service provider by default to prevent68# Disable Mozilla Location Service provider by default to prevent
@@ -66,13 +73,13 @@ if [ -z "$mls_enable" ]; then
66fi73fi
6774
68if [ -n "$mls_enable" ]; then75if [ -n "$mls_enable" ]; then
69 $SNAP/bin/locationd set --key=mls.provider.enable --value="$mls_enable"76 "$SNAP"/bin/locationd set --key=mls.provider.enable --value="$mls_enable"
70fi77fi
7178
72if [ -n "$mls_host" ]; then79if [ -n "$mls_host" ]; then
73 $SNAP/bin/locationd set --key=mls.provider.host --value="$mls_host"80 "$SNAP"/bin/locationd set --key=mls.provider.host --value="$mls_host"
74fi81fi
7582
76if [ -n "$mls_api_key" ]; then83if [ -n "$mls_api_key" ]; then
77 $SNAP/bin/locationd set --key=mls.provider.api_key --value="$mls_api_key"84 "$SNAP"/bin/locationd set --key=mls.provider.api_key --value="$mls_api_key"
78fi85fi
diff --git a/snapcraft.yaml b/snapcraft.yaml
index 8fbe3f9..923b97c 100644
--- a/snapcraft.yaml
+++ b/snapcraft.yaml
@@ -6,7 +6,7 @@ summary: Location service mediates access to positioning providers.
6description: |6description: |
7 Location service mediates access to positioning providers.7 Location service mediates access to positioning providers.
88
9 Please find the source for this snap at https://code.launchpad.net/~snappy-hwe-team/snappy-hwe-snaps/+git/location-service9 Please find the source for this snap at https://code.launchpad.net/~snappy-hwe-team/snappy-hwe-snaps/+git/locationd
1010
11apps:11apps:
12 run:12 run:
diff --git a/src/location/providers/ubx/provider.cpp b/src/location/providers/ubx/provider.cpp
index c5000cc..720c173 100644
--- a/src/location/providers/ubx/provider.cpp
+++ b/src/location/providers/ubx/provider.cpp
@@ -217,7 +217,8 @@ location::Provider::Ptr ubx::Provider::create_instance(const util::settings::Sou
217{217{
218 Configuration configuration218 Configuration configuration
219 {219 {
220 settings.get_value<Protocol>(options::protocol, Protocol::ubx),220 // Production devices in the field use nmea by default
221 settings.get_value<Protocol>(options::protocol, Protocol::nmea),
221 settings.get_value<std::string>(options::device, "/dev/ttyACM1"),222 settings.get_value<std::string>(options::device, "/dev/ttyACM1"),
222 {223 {
223 settings.get_value<bool>(options::assist_now::enable, false),224 settings.get_value<bool>(options::assist_now::enable, false),

Subscribers

People subscribed via source and target branches