Install GDE*.o instead of GDE*.m

This commit is contained in:
Brad King 2012-06-15 16:26:42 -04:00
parent 43ee63fc02
commit 8371effcd1
2 changed files with 41 additions and 2 deletions

View File

@ -376,8 +376,12 @@ foreach(m ${m_files_port})
DEPENDS ${GTM_SOURCE_DIR}/sr_port/${m}
COMMAND ${CMAKE_COMMAND} -E copy ${GTM_SOURCE_DIR}/sr_port/${m} "${m_out}"
)
install(FILES "${m_out}" DESTINATION ${GTM_INSTALL_DIR})
list(APPEND files_to_place "${m_out}")
if("${m}" MATCHES "^gde")
list(APPEND gde_routines "${m_out}")
else()
install(FILES "${m_out}" DESTINATION ${GTM_INSTALL_DIR})
endif()
endforeach()
file(GLOB m_files_unix RELATIVE ${GTM_SOURCE_DIR}/sr_unix ${GTM_SOURCE_DIR}/sr_unix/*.m)
@ -389,8 +393,12 @@ foreach(m ${m_files_unix})
DEPENDS ${GTM_SOURCE_DIR}/sr_unix/${m}
COMMAND ${CMAKE_COMMAND} -E copy ${GTM_SOURCE_DIR}/sr_unix/${m} "${m_out}"
)
install(FILES "${m_out}" DESTINATION ${GTM_INSTALL_DIR})
list(APPEND files_to_place "${m_out}")
if("${m}" MATCHES "^gde")
list(APPEND gde_routines "${m_out}")
else()
install(FILES "${m_out}" DESTINATION ${GTM_INSTALL_DIR})
endif()
endforeach()
# <r>.mpt -> _<R>.m
@ -453,6 +461,22 @@ foreach(f
endforeach()
install(FILES ${files} DESTINATION ${GTM_INSTALL_DIR})
foreach(in ${gde_routines})
string(REPLACE ".m" ".o" out "${in}")
add_custom_command(
OUTPUT ${out}
DEPENDS ${in}
COMMAND ${CMAKE_COMMAND}
-D gtm_dist=${GTM_BINARY_DIR}
-D mumps=$<TARGET_FILE:mumps>
-D input=${in}
-P ${GTM_SOURCE_DIR}/sr_port/mumps.cmake
VERBATIM
)
list(APPEND files_to_place ${out})
install(FILES "${out}" DESTINATION ${GTM_INSTALL_DIR})
endforeach()
set(GTM_TOP "${GTM_BINARY_DIR}")
configure_file(sr_unix/gpgagent.tab.in plugin/gpgagent.tab @ONLY)
set(GTM_TOP "${CMAKE_INSTALL_PREFIX}/${GTM_INSTALL_DIR}")

15
sr_port/mumps.cmake Normal file
View File

@ -0,0 +1,15 @@
#################################################################
# #
# Copyright 2012 Fidelity Information Services, Inc #
# #
# This source code contains the intellectual property #
# of its copyright holder(s), and is made available #
# under a license. If you do not know the terms of #
# the license, please stop and do not read further. #
# #
#################################################################
set(ENV{gtm_dist} "${gtm_dist}")
set(ENV{gtmroutines} ".")
execute_process(
COMMAND ${mumps} ${input}
)