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

User avatar
By GeorgeIoak
#18077 I didn't totally wipe out the VM but I did do a make clean and "make STANDALONE=y" for the SDK. I followed your example yet I still get this error:

Code: Select allvagrant@vagrant-ubuntu-trusty-64:~/esp-open-sdk/sdk$ mv examples/at .
vagrant@vagrant-ubuntu-trusty-64:~/esp-open-sdk/sdk$ cd at/
vagrant@vagrant-ubuntu-trusty-64:~/esp-open-sdk/sdk/at$ make COMPILE=gcc BOOT=new APP=1 SPI_SPEED=40 SPI
_MODE=QIO SPI_SIZE=1024
../../Makefile:200: warning: overriding commands for target `clean'
../Makefile:258: warning: ignoring old commands for target `clean'
You cloned without --recursive, fetching submodules for you.
git submodule update --init --recursive
make -C crosstool-NG -f ../Makefile _ct-ng
make: *** crosstool-NG: No such file or directory.  Stop.
make: *** [crosstool-NG/ct-ng] Error 2
vagrant@vagrant-ubuntu-trusty-64:~/esp-open-sdk/sdk/at$


:cry:
User avatar
By GeorgeIoak
#18078 I'll assume that this is a directory structure issue so perhaps we could compare file locations. Here's what mine looks like:

from the user home directory:
Code: Select allvagrant@vagrant-ubuntu-trusty-64:~/esp-open-sdk$ cd
vagrant@vagrant-ubuntu-trusty-64:~$ ls -al
total 44
drwxr-xr-x  6 vagrant vagrant 4096 May 21 00:13 .
drwxr-xr-x  4 root    root    4096 May 20 15:55 ..
-rw-------  1 vagrant vagrant 3022 May 21 15:30 .bash_history
-rw-r--r--  1 vagrant vagrant  220 Apr  9  2014 .bash_logout
-rw-r--r--  1 vagrant vagrant 3637 Apr  9  2014 .bashrc
drwx------  2 vagrant vagrant 4096 May 20 15:55 .cache
drwxrwxr-x  9 vagrant vagrant 4096 May 21 15:55 esp-open-sdk
drwxrwxr-x 23 vagrant vagrant 4096 May 20 15:58 micropython
-rw-------  1 vagrant vagrant   29 May 21 16:14 .nano_history
-rw-r--r--  1 vagrant vagrant  954 May 21 00:24 .profile
drwx------  2 vagrant vagrant 4096 May 20 15:55 .ssh


from the esp-open-sdk directory:

Code: Select allvagrant@vagrant-ubuntu-trusty-64:~/esp-open-sdk$ ls -al
total 14072
drwxrwxr-x  9 vagrant vagrant    4096 May 21 15:55 .
drwxr-xr-x  6 vagrant vagrant    4096 May 21 00:13 ..
-rw-rw-r--  1 vagrant vagrant 5446552 May 20 23:02 at_v0.20_14_11_28.zip
drwxrwxr-x  8 vagrant vagrant    4096 May 20 23:03 at_v0.20_on_SDKv0.9.3
-rw-rw-r--  1 vagrant vagrant     199 May 20 15:57 crosstool-config-overrides
drwxrwxr-x 18 vagrant vagrant    4096 May 21 15:37 crosstool-NG
-rw-rw-r--  1 vagrant vagrant    1101 May 20 15:57 c_types-c99.patch
drwxrwxr-x 11 vagrant vagrant    4096 May 21 16:05 esp_iot_sdk_v1.0.1
-rw-rw-r--  1 vagrant vagrant 8880579 Apr 24 14:44 esp_iot_sdk_v1.0.1_15_04_24.zip
drwxrwxr-x  2 vagrant vagrant    4096 May 20 15:57 esptool
drwxrwxr-x  9 vagrant vagrant    4096 May 21 00:17 .git
-rw-rw-r--  1 vagrant vagrant     288 May 20 15:57 .gitmodules
drwxrwxr-x  6 vagrant vagrant    4096 May 21 15:55 lx106-hal
-rw-rw-r--  1 vagrant vagrant    7090 May 20 15:57 Makefile
-rw-rw-r--  1 vagrant vagrant    4469 May 20 15:57 README.md
-rw-rw-r--  1 vagrant vagrant   12265 Apr 24 22:19 release_note.txt
lrwxrwxrwx  1 vagrant vagrant      18 May 21 15:55 sdk -> esp_iot_sdk_v1.0.1
-rw-rw-r--  1 vagrant vagrant       0 May 21 15:55 .sdk_patch_1.0.1
drwxrwxr-x  8 vagrant vagrant    4096 May 21 15:55 xtensa-lx106-elf


and then in the actual SDK direcotry which I'm beginning to wonder if this really shouldn't be moved up 1 level:

Code: Select allvagrant@vagrant-ubuntu-trusty-64:~/esp-open-sdk/sdk$ ls -al
total 68
drwxrwxr-x 11 vagrant vagrant  4096 May 21 16:05 .
drwxrwxr-x  9 vagrant vagrant  4096 May 21 15:55 ..
drwxrwxr-x  2 vagrant vagrant  4096 Apr 24 17:05 app
drwxrwxr-x  4 vagrant vagrant  4096 Apr 24 17:05 at
drwxrwxr-x  4 vagrant vagrant  4096 Apr 24 17:09 bin
-rw-rw-r--  1 vagrant vagrant     0 May 21 15:55 .dir
drwxrwxr-x  4 vagrant vagrant  4096 Apr 24 22:11 document
drwxrwxr-x  4 vagrant vagrant  4096 May 21 16:05 examples
drwxrwxr-x  3 vagrant vagrant  4096 May 21 15:55 include
drwxrwxr-x  2 vagrant vagrant  4096 Apr 24 17:05 ld
drwxrwxr-x  2 vagrant vagrant  4096 Apr 24 19:51 lib
-rw-rw-r--  1 vagrant vagrant 11416 Nov 21 18:01 License
-rw-rw-r--  1 vagrant vagrant  8791 Jan 23 21:06 Makefile
drwxrwxr-x  2 vagrant vagrant  4096 Apr 24 17:05 tools
vagrant@vagrant-ubuntu-trusty-64:~/esp-open-sdk/sdk$
User avatar
By GeorgeIoak
#18095 Perfect suggestion, thanks Cal. Yes, commenting out the last line in the Makefile does allow this AT example firmware to compile.

Code: Select all!!!
Support boot_v1.2 and +
Generate user1.1024.new.bin successully in folder bin/upgrade.
boot.bin------------>0x00000
user1.1024.new.bin--->0x01000
!!!
make[1]: Leaving directory `/home/vagrant/esp-open-sdk/esp_iot_sdk_v1.0.1/at'


I've only flashed combined bins before. I assume from this that I can still use the NodeMCU Firmware Programmer (yes, I'm on a Windows machine) and just point these 2 files to the referenced memory locations. Is there somewhere that details why there are sometimes more than 1 file to flash? Ultimately I'd like to develop my own app but I fear with the struggles already encountered that could be a difficult task!