Skip to content

Commit

Permalink
Add install targets to CMakeLists
Browse files Browse the repository at this point in the history
  • Loading branch information
kulp committed Mar 22, 2024
1 parent 18721c6 commit 37fc471
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 0 deletions.
1 change: 1 addition & 0 deletions hw/vpi/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ add_library(vpidevices
${CMAKE_SOURCE_DIR}/src/asm.c
${CMAKE_SOURCE_DIR}/src/obj.c
)
install(TARGETS vpidevices LIBRARY DESTINATION lib)

set_target_properties(vpidevices PROPERTIES PREFIX "" SUFFIX .vpi)

Expand Down
3 changes: 3 additions & 0 deletions src/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ add_executable(tld

obj.c
)
install(TARGETS tld)
target_link_libraries(tld PUBLIC common)

find_package(FLEX)
Expand All @@ -47,6 +48,7 @@ add_executable(tas
${FLEX_scanner_OUTPUTS}
${BISON_parser_OUTPUTS}
)
install(TARGETS tas)

target_include_directories(tas PRIVATE ${CMAKE_CURRENT_BINARY_DIR})

Expand All @@ -68,6 +70,7 @@ add_executable(tsim
devices/sparseram.c
devices/zero_word.c
)
install(TARGETS tsim)

target_link_libraries(tsim PUBLIC common)
# Plugin support needs -ldl.
Expand Down
2 changes: 2 additions & 0 deletions src/devices/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,10 @@ if(SDL)
find_package(SDL2_image REQUIRED)

add_library(tenyrsdlled MODULE sdlled.c)
install(TARGETS tenyrsdlled LIBRARY DESTINATION lib)
target_link_libraries(tenyrsdlled PUBLIC common-pic)
add_library(tenyrsdlvga MODULE sdlvga.c)
install(TARGETS tenyrsdlvga LIBRARY DESTINATION lib)
target_link_libraries(tenyrsdlvga PUBLIC common-pic)

# Place libraries alongside the `tsim` binary in order to be found.
Expand Down

0 comments on commit 37fc471

Please sign in to comment.