Forums - Error: applying relocation `R_HEX_GPREL16_1' causes overflow on symbol

1 post / 0 new
Error: applying relocation `R_HEX_GPREL16_1' causes overflow on symbol
rajeshlakshigo
Join Date: 29 Apr 20
Posts: 1
Posted: Thu, 2020-06-11 02:34
Hi ,
 
      Iam using snapdragon Q820 kit , I generated library(static/common)  in Hexagon IDE using my sensorA algorithm C files. 
 
       I tired to link that generated lib file in ISLAND mode by modifiy the scons file as like below,
 
/***********************************************************************************************************************/
 
     sns_sensorA_island_enable = False
 
 
sns_sensorA_island_lib = env.AddBinaryLibrary(env['SSC_BUILD_TAGS'], '${BUILDPATH}/src/samplelib',[ ]) // mentioned the lib name here
 
 
if 'SNS_ISLAND_INCLUDE' in env:// included this macro in build
  sns_sensorA_island_enable = True
 
if 'USES_MEMSEG' in env:
  env.TagLibraryForMemorySegment(env['SSC_BUILD_TAGS'], 'ssc',sns_sensorA_island_lib)
else:
  env.AddIslandLibrary(env['SSC_BUILD_TAGS'], sns_sensorA_island_lib)  
 
if 'SSC_TARGET_HEXAGON' in env['CPPDEFINES']:
  env.AddSSCSU(inspect.getfile(inspect.currentframe()), 
               register_func_name = "sns_register_sesnorA", 
               binary_lib = False,
               add_island_files = sns_sensorA_island_enable)
 
/******************************************************************************************************************************/
 
 
While building in ISLAND mode  there is a linker error coming "Error: applying relocation `R_HEX_GPREL16_1' causes overflow on symbol `gdataRateRatio'"
 
gdataRateRatio' is a global variable declared and used in library in a single file.
 
 
Any one please provide your suggestion on above error.
  • Up0
  • Down0

Opinions expressed in the content posted here are the personal opinions of the original authors, and do not necessarily reflect those of Qualcomm Incorporated or its subsidiaries (“Qualcomm”). The content is provided for informational purposes only and is not meant to be an endorsement or representation by Qualcomm or any other party. This site may also provide links or references to non-Qualcomm sites and resources. Qualcomm makes no representations, warranties, or other commitments whatsoever about any non-Qualcomm sites or third-party resources that may be referenced, accessible from, or linked to this site.