2015-12-07 11:17:08 -06:00
|
|
|
|
2018-05-03 16:18:15 -05:00
|
|
|
set(_BIN_FILES "")
|
2022-10-01 19:15:39 -05:00
|
|
|
foreach(file gnc-fq-update.in finance-quote-wrapper.in)
|
2018-05-03 16:18:15 -05:00
|
|
|
string(REPLACE ".in" "" _OUTPUT_FILE_NAME ${file})
|
|
|
|
set(_ABS_OUTPUT_FILE ${BINDIR_BUILD}/${_OUTPUT_FILE_NAME})
|
2017-12-22 13:31:35 -06:00
|
|
|
configure_file( ${file} ${_ABS_OUTPUT_FILE} @ONLY)
|
2018-05-03 16:18:15 -05:00
|
|
|
list(APPEND _BIN_FILES ${_ABS_OUTPUT_FILE})
|
|
|
|
endforeach(file)
|
2015-12-07 11:17:08 -06:00
|
|
|
|
2016-01-13 10:45:29 -06:00
|
|
|
|
2018-05-03 16:18:15 -05:00
|
|
|
set(_MAN_FILES "")
|
2022-10-01 19:15:39 -05:00
|
|
|
foreach(file finance-quote-wrapper)
|
2018-05-03 16:18:15 -05:00
|
|
|
set(_POD_INPUT ${BINDIR_BUILD}/${file})
|
|
|
|
set(_MAN_OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/${file}.1)
|
|
|
|
list(APPEND _MAN_FILES ${_MAN_OUTPUT})
|
|
|
|
add_custom_command(
|
2015-12-07 11:17:08 -06:00
|
|
|
OUTPUT ${_MAN_OUTPUT}
|
2023-02-26 10:26:48 -06:00
|
|
|
COMMAND ${PERL_EXECUTABLE} ${POD2MAN_EXECUTABLE} ${_POD_INPUT} ${_MAN_OUTPUT}
|
2015-12-07 11:17:08 -06:00
|
|
|
DEPENDS ${_POD_INPUT}
|
|
|
|
)
|
2018-05-03 16:18:15 -05:00
|
|
|
endforeach(file)
|
2015-12-07 11:17:08 -06:00
|
|
|
|
|
|
|
|
2018-05-03 16:18:15 -05:00
|
|
|
add_custom_target(quotes-man ALL DEPENDS ${_MAN_FILES})
|
|
|
|
add_custom_target(quotes-bin ALL DEPENDS ${_BIN_FILES})
|
|
|
|
install(FILES ${_MAN_FILES} DESTINATION ${CMAKE_INSTALL_MANDIR}/man1)
|
|
|
|
install(PROGRAMS ${_BIN_FILES} DESTINATION ${CMAKE_INSTALL_BINDIR})
|
2015-12-07 11:17:08 -06:00
|
|
|
|
2022-10-01 19:15:39 -05:00
|
|
|
set_dist_list(quotes_DIST CMakeLists.txt gnc-fq-update.in finance-quote-wrapper.in README)
|