Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for compilation on Windows #11

Merged
merged 2 commits into from
Jan 15, 2017
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Fixed firmware size calculation
  • Loading branch information
ashtuchkin committed Jan 15, 2017
commit a28ceabf8a38bbeda7331a7919b18be84ac76d4a
2 changes: 1 addition & 1 deletion teensy-arm.toolchain.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ function(add_firmware_targets TARGET_NAME)
set(HEX_OPTS -O ihex -R .eeprom)

if(NOT (CMAKE_HOST_SYSTEM_NAME STREQUAL "Windows"))
set(PROCESS_SIZE_CMD_OUTPUT [[ | tail -1 | xargs bash -c "TEXT=$0; DATA=$1; BSS=$2; TOTAL_FLASH=262144; TOTAL_RAM=65536; FLASH=$((TEXT+DATA)); RAM=$((DATA+BSS)); echo \"FLASH: $FLASH ($((FLASH*100/TOTAL_FLASH))%); RAM: $RAM ($((RAM*100/TOTAL_RAM))%); Free RAM: $((TOTAL_RAM-RAM))\";" ]])
set(PROCESS_SIZE_CMD_OUTPUT | tail -1 | xargs bash -c [[ TEXT=$0\; DATA=$1\; BSS=$2\; TOTAL_FLASH=262144\; TOTAL_RAM=65536\; FLASH=$((TEXT+DATA))\; RAM=$((DATA+BSS))\; echo "FLASH: $FLASH ($((FLASH*100/TOTAL_FLASH))%), RAM: $RAM ($((RAM*100/TOTAL_RAM))%), Free RAM: $((TOTAL_RAM-RAM))" ]])
endif()

add_custom_target(${TARGET_NAME}_Firmware ALL
Expand Down