Skip to content

Commit d4b3b61

Browse files
Fix size reporting on Windows
1 parent 9d2eb10 commit d4b3b61

File tree

1 file changed

+9
-2
lines changed

1 file changed

+9
-2
lines changed

tests/common.sh

+9-2
Original file line numberDiff line numberDiff line change
@@ -32,8 +32,10 @@ function print_size_info()
3232
fi
3333

3434
elf_name=$(basename $elf_file)
35+
ls -l $elf_name
3536
sketch_name="${elf_name%.*}"
3637
# echo $sketch_name
38+
echo $PATH
3739
declare -A segments
3840
while read -a tokens; do
3941
seg=${tokens[0]}
@@ -44,7 +46,6 @@ function print_size_info()
4446
segments[$seg]=$size
4547
fi
4648

47-
4849
done < <(xtensa-lx106-elf-size --format=sysv $elf_file)
4950

5051
total_ram=$((${segments[data]} + ${segments[rodata]} + ${segments[bss]}))
@@ -203,7 +204,13 @@ function install_ide()
203204
echo -e "\n----\n"
204205
cd esp8266/tools
205206
python3 get.py -q
206-
export PATH="$ide_path:$core_path/tools/xtensa-lx106-elf/bin:$PATH"
207+
if [ "$WINDOWS" = "1" ]; then
208+
# Because the symlinks don't work well under Win32, we need to add the path to this copy, not the original...
209+
relbin=$(realpath $PWD/xtensa-lx106-elf/bin)
210+
export PATH="$ide_path:$relbin:$PATH"
211+
else
212+
export PATH="$ide_path:$core_path/tools/xtensa-lx106-elf/bin:$PATH"
213+
fi
207214
}
208215

209216
function install_arduino()

0 commit comments

Comments
 (0)