aboutsummaryrefslogtreecommitdiffstats
path: root/ice40/family.cmake
diff options
context:
space:
mode:
authorDavid Shah <davey1576@gmail.com>2018-06-07 13:20:16 +0200
committerDavid Shah <davey1576@gmail.com>2018-06-07 13:20:16 +0200
commit024ff8fa7d1aa7c9ae81afcac6f7c2499f44b624 (patch)
treece1416722cbb4e981714ad47e1b9b48917602853 /ice40/family.cmake
parentc3e02527030c11f0177e3bf8d8c5d9a5c9925dc4 (diff)
downloadnextpnr-024ff8fa7d1aa7c9ae81afcac6f7c2499f44b624.tar.gz
nextpnr-024ff8fa7d1aa7c9ae81afcac6f7c2499f44b624.tar.bz2
nextpnr-024ff8fa7d1aa7c9ae81afcac6f7c2499f44b624.zip
cmake: Add HX1K-only builds support
Signed-off-by: David Shah <davey1576@gmail.com>
Diffstat (limited to 'ice40/family.cmake')
-rw-r--r--ice40/family.cmake10
1 files changed, 9 insertions, 1 deletions
diff --git a/ice40/family.cmake b/ice40/family.cmake
index 870b69b9..05709388 100644
--- a/ice40/family.cmake
+++ b/ice40/family.cmake
@@ -1,4 +1,12 @@
-set(devices 384 1k 5k 8k)
+if(ICE40_HX1K_ONLY)
+ set(devices 1k)
+ foreach (target ${family_targets})
+ target_compile_definitions(${target} PRIVATE ICE40_HX1K_ONLY=1)
+ endforeach (target)
+else()
+ set(devices 384 1k 5k 8k)
+endif()
+
set(DB_PY ${CMAKE_CURRENT_SOURCE_DIR}/ice40/chipdb.py)
file(MAKE_DIRECTORY ice40/chipdbs/)
add_library(ice40_chipdb OBJECT ice40/chipdbs/)