Skip to content

Commit

Permalink
Clean up build script
Browse files Browse the repository at this point in the history
  • Loading branch information
jchristopherson committed Feb 28, 2024
1 parent f123c6d commit eebd177
Show file tree
Hide file tree
Showing 5 changed files with 1 addition and 90 deletions.
3 changes: 0 additions & 3 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -37,9 +37,6 @@ target_link_libraries(
)
link_library(${PROJECT_NAME} ${ferror_LIBRARY} ${ferror_INCLUDE_DIR})

# Installation
add_subdirectory(install)

# Testing
option(BUILD_TESTING "Build tests")
include(CTest)
Expand Down
16 changes: 1 addition & 15 deletions dependencies/ferror/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -7,28 +7,14 @@ FetchContent_Declare(
ferror
GIT_REPOSITORY "https://github.com/jchristopherson/ferror"
)

FetchContent_MakeAvailable(ferror)

if (WIN32)
if (BUILD_SHARED_LIBS)
add_custom_command(
TARGET ${PROJECT_NAME} POST_BUILD
COMMAND ${CMAKE_COMMAND} -E copy_if_different
$<TARGET_FILE:ferror>
$<TARGET_FILE_DIR:${PROJECT_NAME}
)
endif()
endif()

set(ferror_INCLUDE_DIR ${ferror_BINARY_DIR}/include)
set(ferror_INCLUDE_DIR ${ferror_INCLUDE_DIR} PARENT_SCOPE)
configure_file(
"${ferror_SOURCE_DIR}/include/ferror.h"
"${ferror_INCLUDE_DIR}/ferror.h"
COPYONLY
)

# Make a parent-scope variable for the library
set(ferror_LIBRARY ferror)
set(ferror_INCLUDE_DIR ${ferror_INCLUDE_DIR} PARENT_SCOPE)
set(ferror_LIBRARY ${ferror_LIBRARY} PARENT_SCOPE)
59 changes: 0 additions & 59 deletions install/CMakeLists.txt

This file was deleted.

3 changes: 0 additions & 3 deletions install/linalgConfig.cmake.in

This file was deleted.

10 changes: 0 additions & 10 deletions install/template.pc

This file was deleted.

0 comments on commit eebd177

Please sign in to comment.