- Sat Nov 01, 2014 5:04 pm
#2135
jcmvbkbc wrote:If you want the root shell to expand its own environment, try this: sudo bash -c 'echo $PATH'
Damn, Linux continues to fool me.
Now I understand why SUDO MAKE cannot find XT-XCC.
Thanks jcmvbkbc.
Code: Select allesp8266@esp8266-VirtualBox:~$ echo $PATH
/opt/xtensa-lx106-elf/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games
esp8266@esp8266-VirtualBox:~$ sudo bash -c 'echo $PATH'
[sudo] password for esp8266:
/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
UPDATE : IT'S COMPILING NOW!
Inspired by the tip from jcmvbkbc I switched to the root environment with SUDO-S. XT-XCC is in $PATH, and MAKE in the APP directory compiles, and generates BIN files. I'm over this hurdle now, time to call it quits for today. Thanks for the inspiration in my hour of need.
Code: Select allesp8266@esp8266-VirtualBox:~$ sudo -s
root@esp8266-VirtualBox:~# echo $PATH
/opt/xtensa-lx106-elf/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
root@esp8266-VirtualBox:~# cd Share/esp_iot_sdk_v0.9.2/app
root@esp8266-VirtualBox:~/Share/esp_iot_sdk_v0.9.2/app# makeroot@esp8266-VirtualBox:~/Share/esp_iot_sdk_v0.9.2/app# make
make[1]: Entering directory `/mnt/Share/esp_iot_sdk_v0.9.2/app/user'
DEPEND: xt-xcc -M -Os -g -O2 -Wpointer-arith -Wundef -Werror -Wl,-EL -fno-inline-functions -nostdlib -mlongcalls -mtext-section-literals -D__ets__ -DICACHE_FLASH -DLWIP_OPEN_SRC -DPBUF_RSV_FOR_WLAN -DEBUF_LWIP -I include -I ./ -I ../../include/ets -I ../include -I ./ -I ../../include -I ../../include/eagle user_webserver.c
DEPEND: xt-xcc -M -Os -g -O2 -Wpointer-arith -Wundef -Werror -Wl,-EL -fno-inline-functions -nostdlib -mlongcalls -mtext-section-literals -D__ets__ -DICACHE_FLASH -DLWIP_OPEN_SRC -DPBUF_RSV_FOR_WLAN -DEBUF_LWIP -I include -I ./ -I ../../include/ets -I ../include -I ./ -I ../../include -I ../../include/eagle user_sensor.c
<BIG SNIP>
xt-objcopy -O binary .output/eagle/debug/image/eagle.app.v6.out .output/eagle/debug/bin/eagle.app.v6.bin
root@esp8266-VirtualBox:~/Share/esp_iot_sdk_v0.9.2/app#