# Sample of 'gnssTest' building failed

**URL:** <https://forum.legato.io/t/sample-of-gnsstest-building-failed/2466>\
**Category:** Legato Application Framework\
**Created:** [May 22, 2017, 2:58am UTC](https://forum.legato.io/t/sample-of-gnsstest-building-failed/2466 "2017-05-22T02:58:28Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![lumao](https://sea1.discourse-cdn.com/flex019/user_avatar/forum.legato.io/lumao/32/167_2.png) [@lumao](https://forum.legato.io/u/lumao)\
**Post date:** [May 22, 2017, 2:58am UTC](https://forum.legato.io/t/sample-of-gnsstest-building-failed/2466/1 "2017-05-22T02:58:28Z")

</div>

Hi,  
I am following the ’ Import existing as Legato Project’ import the gnss Test sample, direction:  
/home/os-freya/legato/packages/legato.framework.16.7.0.201609081601/resources/legato/apps/test/positioning/gnssTest

I used all of the original code. But after ’ Building Project’ , there are 7 errors:  
Description Resource Path Location Type  
Symbol ‘LE\_GNSS\_SV\_INFO\_MAX\_LEN’ could not be resolved gnssTest.c /gnssTest/gnssTest line 309 Semantic Error  
Symbol ‘LE\_GNSS\_SV\_INFO\_MAX\_LEN’ could not be resolved gnssTest.c /gnssTest/gnssTest line 311 Semantic Error  
Symbol ‘LE\_GNSS\_SV\_INFO\_MAX\_LEN’ could not be resolved gnssTest.c /gnssTest/gnssTest line 313 Semantic Error  
Symbol ‘LE\_GNSS\_SV\_INFO\_MAX\_LEN’ could not be resolved gnssTest.c /gnssTest/gnssTest line 315 Semantic Error  
Symbol ‘LE\_GNSS\_SV\_INFO\_MAX\_LEN’ could not be resolved gnssTest.c /gnssTest/gnssTest line 317 Semantic Error  
Symbol ‘LE\_GNSS\_SV\_INFO\_MAX\_LEN’ could not be resolved gnssTest.c /gnssTest/gnssTest line 319 Semantic Error  
Symbol ‘LE\_GNSS\_SV\_INFO\_MAX\_LEN’ could not be resolved gnssTest.c /gnssTest/gnssTest line 356 Semantic Error

 ![](https://us1.discourse-cdn.com/flex019/uploads/legato1/original/1X/064f2b7ee420889eb6b712a532c473fa627b86a5.png)  
It seems that the ‘LE\_GNSS\_SV\_INFO\_MAX\_LEN’ did not declare, but I can really found that the declaration in the le\_gnss\_interface.h file by press F3.

So I added the le\_gnss\_interface.h in the gnssTest.c  
/\*\*

- This module implements a test for GNSS device starting.
- 
- Copyright (C) Sierra Wireless Inc. Use of this work is subject to license.
- 

\*/

#include “legato.h”  
#include “interfaces.h”

#include “le\_gnss\_interface.h”  
// Include macros for printing out values  
#include “le\_print.h”

static le\_gnss\_PositionHandlerRef\_t PositionHandlerRef = NULL;

//Wait up to 60 seconds for a 3D fix  
#define GNSS\_WAIT\_MAX\_FOR\_3DFIX 60

the errors was solved, however when I run the app in legato it was failed, following the logs:  
Jan 6 02:54:59 | supervisor[461]/supervisor T=main | app.c CreateTmpFs() 1104 | Mounted tmpfs at /legato/systems/current/appsWriteable/gnssTest/tmp.  
Jan 6 02:54:59 | supervisor[461]/supervisor T=main | app.c CreateFileLink() 1411 | Created file link ‘/tmp/legato/serviceDirectoryServer’ to ‘/legato/systems/current/appsWriteable/gnssTest/tmp/legato/serviceDirectoryServer’.  
Jan 6 02:54:59 | supervisor[461]/supervisor T=main | app.c CreateFileLink() 1411 | Created file link ‘/tmp/legato/serviceDirectoryClient’ to ‘/legato/systems/current/appsWriteable/gnssTest/tmp/legato/serviceDirectoryClient’.  
Jan 6 02:54:59 | supervisor[461]/supervisor T=main | resourceLimits.c SetRLimitValue() 282 | Setting resource limit maxCoreDumpFileBytes to value 102400.  
Jan 6 02:54:59 | supervisor[461]/supervisor T=main | resourceLimits.c SetRLimitValue() 282 | Setting resource limit maxFileBytes to value 102400.  
Jan 6 02:54:59 | supervisor[461]/supervisor T=main | resourceLimits.c SetRLimitValue() 282 | Setting resource limit maxLockedMemoryBytes to value 8192.  
Jan 6 02:54:59 | supervisor[461]/supervisor T=main | resourceLimits.c SetRLimitValue() 282 | Setting resource limit maxFileDescriptors to value 256.  
Jan 6 02:54:59 | supervisor[461]/supervisor T=main | resourceLimits.c SetRLimitValue() 282 | Setting resource limit maxMQueueBytes to value 512.  
Jan 6 02:54:59 | supervisor[461]/supervisor T=main | resourceLimits.c SetRLimitValue() 282 | Setting resource limit maxThreads to value 20.  
Jan 6 02:54:59 | supervisor[461]/supervisor T=main | resourceLimits.c SetRLimitValue() 282 | Setting resource limit maxQueuedSignals to value 100.  
Jan 6 02:54:59 | supervisor[461]/supervisor T=main | proc.c proc\_Start() 1104 | Starting process ‘gnssTest’ with pid 29330  
Jan 6 02:54:59 | supervisor[29330]/supervisor T=main | proc.c proc\_Start() 1072 | Execing ‘gnssTest’  
Jan 6 02:54:59 | _UNKNOWN_[29330]/framework T=unknown | mem.c InitPool() 303 | Memory pool name ‘framework.hashMap\_refPathIteratorMap’ is truncated to ‘framework.hashMap\_refPathIterat’  
Jan 6 02:54:59 | _UNKNOWN_[29330]/framework T=main | mem.c InitPool() 303 | Memory pool name ‘framework.hashMap\_refEventHandlers’ is truncated to ‘framework.hashMap\_refEventHandl’  
Jan 6 02:54:59 | _UNKNOWN_[29330]/framework T=main | mem.c InitPool() 303 | Memory pool name ‘framework.MessagingClientInterfaces’ is truncated to ‘framework.MessagingClientInterf’  
Jan 6 02:54:59 | _UNKNOWN_[29330]/framework T=main | mem.c InitPool() 303 | Memory pool name ‘framework.hashMap\_refHandlersRef’ is truncated to ‘framework.hashMap\_refHandlersRe’  
Jan 6 02:54:59 | _UNKNOWN_[29330]/framework T=main | mem.c InitPool() 303 | Memory pool name ‘framework.hashMap\_MessagingServices’ is truncated to ‘framework.hashMap\_MessagingServ’  
Jan 6 02:54:59 | _UNKNOWN_[29330]/framework T=main | mem.c InitPool() 303 | Memory pool name ‘framework.hashMap\_MessagingClients’ is truncated to ‘framework.hashMap\_MessagingClie’  
Jan 6 02:54:59 | _UNKNOWN_[29330]/framework T=main | mem.c InitPool() 303 | Memory pool name ‘framework.PipelineSIGCHLD-reports’ is truncated to ‘framework.PipelineSIGCHLD-repor’  
Jan 6 02:54:59 | _UNKNOWN_[29330]/framework T=main | mem.c le\_mem\_ForceAlloc() 841 | Memory pool ‘framework.DestructorObjs’ overflowed. Expanded to 1 blocks.  
Jan 6 02:54:59 | _UNKNOWN_[29330]/ T=main | \_componentMain.c \_gnssTest\_Init() 35 | Initializing gnssTest component library.  
Jan 6 02:54:59 | _UNKNOWN_[29330]/framework T=main | mem.c InitPool() 303 | Memory pool name ‘framework.hashMap\_refle\_pos\_ClientHandler’ is truncated to ‘framework.hashMap\_refle\_pos\_Cli’  
Jan 6 02:54:59 | _UNKNOWN_[29330]/framework T=main | messagingMessage.c msgMessage\_CreatePool() 112 | Pool name truncated to ‘msgs-43630c2afa038107ba82a60b59’ for protocol ‘43630c2afa038107ba82a60b59813b6a’.  
Jan 6 02:54:59 | _UNKNOWN_[29330]/framework T=main | mem.c InitPool() 303 | Memory pool name ‘framework.msgs-43630c2afa038107ba82a60b59’ is truncated to ‘framework.msgs-43630c2afa038107’  
Jan 6 02:54:59 | serviceDirectory[479]/serviceDirectory\_exe T=main | serviceDirectory.c DispatchToServer() 713 | Client (uid 1019 ‘appgnssTest’, pid 29330) disagrees with server (uid 0 ‘root’, pid 522) on protocol ID of service 'gnssTes  
Jan 6 02:54:59 | _UNKNOWN_[29330]/framework T=main | messagingSession.c ReceiveSessionOpenResponse() 684 | Unexpected server response: -6 (LE\_FAULT).  
Jan 6 02:54:59 | supervisor[461]/supervisor T=main | proc.c proc\_SigChildHandler() 1777 | Process ‘gnssTest’ (PID: 29330) has exited with exit code 1.  
Jan 6 02:54:59 | supervisor[461]/supervisor T=main | proc.c GetFaultAction() 1593 | No fault action specified for process ‘gnssTest’. Assuming ‘ignore’.  
Jan 6 02:54:59 | supervisor[461]/supervisor T=main | app.c app\_SigChildHandler() 2982 | Process ‘gnssTest’ in app ‘gnssTest’ faulted: Ignored.  
Jan 6 02:54:59 | supervisor[461]/supervisor T=main | apps.c DeactivateAppContainer() 209 | Application ‘gnssTest’ has stopped.

 ![](https://us1.discourse-cdn.com/flex019/uploads/legato1/original/1X/131fec76f48bc6797b12e5257f1820e41b322dd7.png)  
Any advises for this issue? thank you.

Regards!

---

<div class="post-metadata">

**Author:** ![pinkesh](https://sea1.discourse-cdn.com/flex019/user_avatar/forum.legato.io/pinkesh/32/221_2.png) [@pinkesh](https://forum.legato.io/u/pinkesh)\
**Post date:** [December 18, 2017, 9:19am UTC](https://forum.legato.io/t/sample-of-gnsstest-building-failed/2466/2 "2017-12-18T09:19:33Z")

</div>

**Jan 6 02:54:59 | serviceDirectory[479]/serviceDirectory\_exe T=main | serviceDirectory.c DispatchToServer() 713 | Client (uid 1019 ‘appgnssTest’, pid 29330) disagrees with server (uid 0 ‘root’, pid 522) on protocol ID of service 'gnssTes**

From the log it can be seen that there is a mismatch between Application version and legato version which are installed on target.  
Due to this reason Client disagrees with the Server.

The legato version of the file where you build your application should match with version on the target. Can you conform which version of legato using on target and which version you are building. These both should match. Please check the toolchain which you are using should be compatible with legato version.

---

<div class="post-metadata">

**Author:** ![lumao](https://sea1.discourse-cdn.com/flex019/user_avatar/forum.legato.io/lumao/32/167_2.png) [@lumao](https://forum.legato.io/u/lumao)\
**Post date:** [December 25, 2017, 2:20am UTC](https://forum.legato.io/t/sample-of-gnsstest-building-failed/2466/4 "2017-12-25T02:20:44Z")

</div>

hi pinkesh,

you are correct! This issue had been solved when I upgraded the legato version. Thank you.
