Compiling linux buildroot for esp32 gives error

timl12332
Posts: 27
Joined: Wed May 10, 2017 3:05 pm

Compiling linux buildroot for esp32 gives error

Postby timl12332 » Thu May 11, 2017 7:50 pm

hello,

I thought it would be fun to see if i can get buildroot linux to compile for esp32.
I already know i will probably get memory errors if i try to upload it but still i want to compile it. :D
BUt it throws an error when building buildroot:

Code: Select all

/usr/xtensa-buildroot-linux-uclibc/bin/ -B/home/tim/Desktop/linuxforesp32/buildroot-build/host/usr/xtensa-buildroot-linux-uclibc/lib/ -isystem /home/tim/Desktop/linuxforesp32/buildroot-build/host/usr/xtensa-buildroot-linux-uclibc/include -isystem /home/tim/Desktop/linuxforesp32/buildroot-build/host/usr/xtensa-buildroot-linux-uclibc/sys-include    -g -Os -O2  -g -Os -DIN_GCC -DCROSS_DIRECTORY_STRUCTURE  -W -Wall -Wno-narrowing -Wwrite-strings -Wcast-qual -Wstrict-prototypes -Wmissing-prototypes -Wold-style-definition  -isystem ./include   -fPIC -g -DIN_LIBGCC2 -fbuilding-libgcc -fno-stack-protector -Dinhibit_libc  -fPIC -I. -I. -I../.././gcc -I../../../libgcc -I../../../libgcc/. -I../../../libgcc/../gcc -I../../../libgcc/../include    -o _mulxc3.o -MT _mulxc3.o -MD -MP -MF _mulxc3.dep -DL_mulxc3 -c ../../../libgcc/libgcc2.c -fvisibility=hidden -DHIDE_EXPORTS
/home/tim/Desktop/linuxforesp32/buildroot-build/build/host-gcc-initial-4.8.3/build/./gcc/xgcc -B/home/tim/Desktop/linuxforesp32/buildroot-build/build/host-gcc-initial-4.8.3/build/./gcc/ -B/home/tim/Desktop/linuxforesp32/buildroot-build/host/usr/xtensa-buildroot-linux-uclibc/bin/ -B/home/tim/Desktop/linuxforesp32/buildroot-build/host/usr/xtensa-buildroot-linux-uclibc/lib/ -isystem /home/tim/Desktop/linuxforesp32/buildroot-build/host/usr/xtensa-buildroot-linux-uclibc/include -isystem /home/tim/Desktop/linuxforesp32/buildroot-build/host/usr/xtensa-buildroot-linux-uclibc/sys-include    -g -Os -O2  -g -Os -DIN_GCC -DCROSS_DIRECTORY_STRUCTURE  -W -Wall -Wno-narrowing -Wwrite-strings -Wcast-qual -Wstrict-prototypes -Wmissing-prototypes -Wold-style-definition  -isystem ./include   -fPIC -g -DIN_LIBGCC2 -fbuilding-libgcc -fno-stack-protector -Dinhibit_libc  -fPIC -I. -I. -I../.././gcc -I../../../libgcc -I../../../libgcc/. -I../../../libgcc/../gcc -I../../../libgcc/../include    -o _multc3.o -MT _multc3.o -MD -MP -MF _multc3.dep -DL_multc3 -c ../../../libgcc/libgcc2.c -fvisibility=hidden -DHIDE_EXPORTS
/tmp/cckLVToT.s: Assembler messages:
/tmp/cckLVToT.s:51: Error: unknown opcode or format name 'div.s'
Makefile:460: recipe for target '_powisf2.o' failed
make[2]: *** [_powisf2.o] Error 1
make[2]: *** Waiting for unfinished jobs....
make[2]: Leaving directory '/home/tim/Desktop/linuxforesp32/buildroot-build/build/host-gcc-initial-4.8.3/build/xtensa-buildroot-linux-uclibc/libgcc'
Makefile:9969: recipe for target 'all-target-libgcc' failed
make[1]: *** [all-target-libgcc] Error 2
make[1]: Leaving directory '/home/tim/Desktop/linuxforesp32/buildroot-build/build/host-gcc-initial-4.8.3/build'
package/pkg-generic.mk:182: recipe for target '/home/tim/Desktop/linuxforesp32/buildroot-build/build/host-gcc-initial-4.8.3/.stamp_built' failed
make: *** [/home/tim/Desktop/linuxforesp32/buildroot-build/build/host-gcc-initial-4.8.3/.stamp_built] Error 2
make: Leaving directory '/home/tim/Desktop/linuxforesp32/buildroot'
i am following this tutorial: http://wiki.linux-xtensa.org/index.php/ ... ting_Linux
And i am using the esp32 overlay file from here: server.soud.co.uk/esp8266/esp-open-sdk- ... /overlays/
I used this command to built buildroot:

Code: Select all

make -C buildroot O=$(pwd)/buildroot-build
I am running ubuntu 16.04(amd64).
Could someone help me resolve this error?
I dont realy know what information to provide you with so if i am missing something then you can ask for it.

I hope to hear soon from you peaple,


thanks in advance

ESP_Sprite
Posts: 9749
Joined: Thu Nov 26, 2015 4:08 am

Re: Compiling linux buildroot for esp32 gives error

Postby ESP_Sprite » Fri May 12, 2017 2:26 am

FYI, this is not going to work at all, not without massive work on the Linux-kernel. Buildroot is a way to build a Linux-based OS, and Linux needs the Xtensa-native MMU to work. We do have an (external to the CPU) MMU, but it is too rudimentary to support Linux.

timl12332
Posts: 27
Joined: Wed May 10, 2017 3:05 pm

Re: Compiling linux buildroot for esp32 gives error

Postby timl12332 » Fri May 12, 2017 1:09 pm

well, okay thanks.

I dont have much knowledge on building linux so i probably wont be able to do it.
Do you(or someone else at espressif) have plans to build linux for it?
Running something like openwrt(or another linux os) would be absolute fantastic!

WiFive
Posts: 3529
Joined: Tue Dec 01, 2015 7:35 am

Re: Compiling linux buildroot for esp32 gives error

Postby WiFive » Fri May 12, 2017 2:55 pm

Try uclinux if you really really want, even then you will need external ram. Otherwise abandon the dream its not going to work.

timl12332
Posts: 27
Joined: Wed May 10, 2017 3:05 pm

Re: Compiling linux buildroot for esp32 gives error

Postby timl12332 » Fri May 12, 2017 4:14 pm

Would love to try that,
Do you know a tutorial or someting?

ESP_Sprite
Posts: 9749
Joined: Thu Nov 26, 2015 4:08 am

Re: Compiling linux buildroot for esp32 gives error

Postby ESP_Sprite » Sat May 13, 2017 2:58 am

You would need to port uclinux first; this means diving deep into the kernel and modifying/writing a fair amount of code.

madscientist_42
Posts: 95
Joined: Tue Feb 21, 2017 10:17 pm

Re: Compiling linux buildroot for esp32 gives error

Postby madscientist_42 » Mon May 15, 2017 4:20 pm

Other than the, "because I could," aspect of a port, I don't know if there's any value there. Not enough RAM.

Now, if you wanted to port Zephyr or one of the other nifty IOT platforms... >:-D

While IDF is shaping up nicely, I'm sure they'd still welcome a bit of competition from some of the other platforms there.

NuttX is allegedly already there. I say allegedly mainly because they claim it, but I've not seen/tried it myself yet...yet.

Might be interesting to see the Linux or Apache Foundation's IoT RTOS on this silicon.

ESP_igrr
Posts: 2072
Joined: Tue Dec 01, 2015 8:37 am

Re: Compiling linux buildroot for esp32 gives error

Postby ESP_igrr » Tue May 16, 2017 4:48 am

madscientist_42 wrote:Now, if you wanted to port Zephyr or one of the other nifty IOT platforms... >:-D
https://jira.zephyrproject.org/browse/ZEP-2030

madscientist_42
Posts: 95
Joined: Tue Feb 21, 2017 10:17 pm

Re: Compiling linux buildroot for esp32 gives error

Postby madscientist_42 » Wed May 17, 2017 6:52 pm

ESP_igrr wrote:
madscientist_42 wrote:Now, if you wanted to port Zephyr or one of the other nifty IOT platforms... >:-D
https://jira.zephyrproject.org/browse/ZEP-2030
X-D

Oh, this gets better by the minute- thanks for sharing that. I didn't have enough insight into their community to know what they were/weren't doing. Makes for more sales of the SoC...which is a win for pretty much everyone.

As an aside, they have a complete, functioning minimal Dual-mode stack for BT. I'm looking at the guts of it for an alternate for IDF...just the start because I've already too much on my plate right now. Looks like it's able to be bolted on with a few re-works.

juiceRv
Posts: 3
Joined: Sat Jul 17, 2021 9:11 am

Re: Compiling linux buildroot for esp32 gives error

Postby juiceRv » Sat Jul 17, 2021 9:15 am


Who is online

Users browsing this forum: No registered users and 68 guests