Merge pull request #404 from smunaut/fix_prefix_default

build: Default the ECP5 and iCE40 roots to the install prefix
This commit is contained in:
David Shah 2020-03-04 07:21:36 +00:00 committed by GitHub
commit c06827cd50
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 3 deletions

View File

@ -2,8 +2,8 @@ if (NOT EXTERNAL_CHIPDB)
set(devices 25k 45k 85k)
if (NOT DEFINED TRELLIS_INSTALL_PREFIX)
message(STATUS "TRELLIS_INSTALL_PREFIX not defined using -DTRELLIS_INSTALL_PREFIX=/path-prefix/to/prjtrellis-installation. Default to /usr/local or reset by -DCMAKE_INSTALL_PREFIX when building prjtrellis/libtrellis")
set(TRELLIS_INSTALL_PREFIX "/usr/local")
message(STATUS "TRELLIS_INSTALL_PREFIX not defined using -DTRELLIS_INSTALL_PREFIX=/path-prefix/to/prjtrellis-installation. Defaulted to ${CMAKE_INSTALL_PREFIX}")
set(TRELLIS_INSTALL_PREFIX ${CMAKE_INSTALL_PREFIX})
endif()
if (NOT DEFINED PYTRELLIS_LIBDIR)

View File

@ -10,7 +10,7 @@ if (NOT EXTERNAL_CHIPDB)
set(DB_PY ${CMAKE_CURRENT_SOURCE_DIR}/ice40/chipdb.py)
set(ICEBOX_ROOT "/usr/local/share/icebox" CACHE STRING "icebox location root")
set(ICEBOX_ROOT ${CMAKE_INSTALL_PREFIX}/share/icebox CACHE STRING "icebox location root")
file(MAKE_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/ice40/chipdbs/)
add_library(ice40_chipdb OBJECT ${CMAKE_CURRENT_BINARY_DIR}/ice40/chipdbs/)
target_compile_definitions(ice40_chipdb PRIVATE NEXTPNR_NAMESPACE=nextpnr_${family})