Skip to content

Commit

Permalink
modified CMakeLists.txt
Browse files Browse the repository at this point in the history
  • Loading branch information
treelin611 committed Oct 8, 2024
1 parent f0a9ca8 commit 9131e74
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 20 deletions.
21 changes: 3 additions & 18 deletions libs/libopenfpgacapnproto/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ endif()
# Create generated headers from capnp schema files
#
# Each schema used should appear here.

set(CAPNP_DEFS
gen/unique_blocks_uxsdcxx.capnp
)
Expand All @@ -28,8 +29,6 @@ capnp_generate_cpp(CAPNP_SRCS CAPNP_HDRS
)


set(IC_DIR ${CMAKE_CURRENT_SOURCE_DIR}/../../vtr-verilog-to-routing/libs/EXTERNAL/libinterchange/interchange)
set(CAPNPC_SRC_PREFIX ${IC_DIR})

find_program(WGET wget REQUIRED)
find_package(ZLIB REQUIRED)
Expand All @@ -52,20 +51,6 @@ add_custom_target(
set(CAPNPC_IMPORT_DIRS)
list(APPEND CAPNPC_IMPORT_DIRS ${CMAKE_CURRENT_BINARY_DIR}/schema)

set(IC_PROTOS)
set(IC_SRCS)
set(IC_HDRS)
foreach(PROTO ${IC_PROTOS})
capnp_generate_cpp(
IC_SRC
IC_HDR
${IC_DIR}/${PROTO}
)
list(APPEND IC_SRCS ${IC_SRC})
list(APPEND IC_HDRS ${IC_HDR})
list(APPEND CAPNP_DEFS ${IC_DIR}/${PROTO})
endforeach()


install(FILES ${CAPNP_DEFS} DESTINATION ${CMAKE_INSTALL_DATADIR}/openfpga)

Expand Down Expand Up @@ -108,7 +93,7 @@ add_custom_target(
unique_blocks_capnproto_generate/unique_blocks_uxsdcxx_capnp.h
unique_blocks_capnproto_generate/unique_blocks_uxsdcxx_interface.h
${CMAKE_CURRENT_SOURCE_DIR}/gen
COMMAND ${CMAKE_COMMAND} -E copy unique_blocks_capnproto_generate/unique_blocks_uxsdcxx.capnp ${CMAKE_CURRENT_SOURCE_DIR}/gen
COMMAND ${CMAKE_COMMAND} -E copy unique_blocks_capnproto_generate/unique_blocks_uxsdcxx.capnp ${CMAKE_CURRENT_SOURCE_DIR}/../libopenfpgacapnproto/gen
DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/gen/unique_blocks.xsd
WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}
)
)
2 changes: 1 addition & 1 deletion libs/libopenfpgacapnproto/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ Capnproto schemas
-----------------

libopenfpgacapnproto should contain all capnproto schema definitions used within
VTR. To add a new schema:
Openfpga. To add a new schema:
1. Add the schema to git in `libs/libopenfpgacapnproto/`
2. Add the schema file name to `capnp_generate_cpp` invocation in
`libs/libopenfpgacapnproto/CMakeLists.txt`.
Expand Down
2 changes: 1 addition & 1 deletion libs/libopenfpgacapnproto/gen/unique_blocks.xsd
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
<xs:attribute name="y" type="xs:unsignedInt"/>
</xs:complexType>

<!-- UniqueBlockPacked Structure (blockInfo as element, instance list as sequence) -->
<!-- UniqueBlockPacked Structure (blockInfo, list of instances) -->
<xs:complexType name="UniqueBlockPacked">
<xs:sequence>
<xs:element name="blockInfo" type="BlockInfo"/>
Expand Down
Empty file.

0 comments on commit 9131e74

Please sign in to comment.