Discuss here different C compiler set ups, and compiling executables for the ESP8266

User avatar
By zarya
#1141 still having some issues compiling some of the examples

using this makefile (works for the at example) https://gist.github.com/zarya/7e1a08160bf3b7ac220f

if i try to compile the IoT Demo or https://github.com/cnlohr/dumbcraft8266 i am getting the error:

Code: Select allzarya@esp8266:~/source/IoT_Demo$ make
CC driver/adc.c
CC driver/gpio16.c
CC driver/i2c_master.c
CC driver/key.c
/tmp/ccLFnipI.s: Assembler messages:
/tmp/ccLFnipI.s:183: Error: literal pool location required for text-section-literals; specify with .literal_position
make: *** [build/driver/key.o] Error 1
User avatar
By tinhead
#1143 try -mtext-section-literals

http://gcc.gnu.org/onlinedocs/gcc-4.1.2 ... tions.html
User avatar
By jcmvbkbc
#1144
zarya wrote:if i try to compile the IoT Demo or https://github.com/cnlohr/dumbcraft8266 i am getting the error:

Code: Select allCC driver/key.c
/tmp/ccLFnipI.s: Assembler messages:
/tmp/ccLFnipI.s:183: Error: literal pool location required for text-section-literals; specify with .literal_position
make: *** [build/driver/key.o] Error 1

Please share the complete command line used to compile driver/key.c and preprocessed source of the driver/key.c with that command line (just replace -c with -E to get it).
User avatar
By mikelelere
#1147 I was experiencing the very same issue and the solution was including the -mno-text-section-literals in CFLAGS. This flag instructs the compiler to place literals in separate sections in the output file, rather than including them in the .text section (which is the effect of the -mtext-section-literals). Include such flag in CFLAGS and you should be able to compile.