@ -1113,7 +1113,7 @@ macro( tde_add_library _arg_target )
endif ( )
endif ( )
file ( RELATIVE_PATH _target_path "${CMAKE_BINARY_DIR}" "${_target_lib}" )
file ( RELATIVE_PATH _target_path "${CMAKE_BINARY_DIR}" "${_target_lib}" )
if ( NOT _exclude_from_all )
if ( TARGET ${ TDELFEDITOR_EXECUTABLE } AND NOT _exclude_from_all )
# c r e a t e t a r g e t f o r a l l m e t a d a t a w r i t e s
# c r e a t e t a r g e t f o r a l l m e t a d a t a w r i t e s
if ( NOT TARGET tdelfeditor-write )
if ( NOT TARGET tdelfeditor-write )
add_custom_target ( tdelfeditor-write
add_custom_target ( tdelfeditor-write
@ -1138,7 +1138,9 @@ macro( tde_add_library _arg_target )
C O M M A N D $ { T D E L F E D I T O R _ E X E C U T A B L E } - e $ { _ t a r g e t _ l i b } | | t r u e
C O M M A N D $ { T D E L F E D I T O R _ E X E C U T A B L E } - e $ { _ t a r g e t _ l i b } | | t r u e
C O M M E N T " S t o r i n g S C M m e t a d a t a i n $ { _ t a r g e t _ p a t h } "
C O M M E N T " S t o r i n g S C M m e t a d a t a i n $ { _ t a r g e t _ p a t h } "
)
)
add_dependencies ( ${ _target } ${ TDELFEDITOR_EXECUTABLE } )
if ( TARGET ${ TDELFEDITOR_EXECUTABLE } )
add_dependencies ( ${ _target } ${ TDELFEDITOR_EXECUTABLE } )
endif ( )
endif ( )
endif ( )
endif ( TDELFEDITOR_EXECUTABLE AND _soname )
endif ( TDELFEDITOR_EXECUTABLE AND _soname )
@ -1347,25 +1349,35 @@ macro( tde_add_executable _arg_target )
set ( ELF_EMBEDDING_METADATA "\" ${ _target } \" \"${_description}\" \"${_license}\" \"${_copyright}\" \"${_authors}\" \"${_product}\" \"${_organization}\" \"${_version}\" \"${_datetime}\" \"${_target}\" \"${TDE_SCM_MODULE_NAME}\" \"${TDE_SCM_MODULE_REVISION}\" \"${_notes}\"" )
set ( ELF_EMBEDDING_METADATA "\" ${ _target } \" \"${_description}\" \"${_license}\" \"${_copyright}\" \"${_authors}\" \"${_product}\" \"${_organization}\" \"${_version}\" \"${_datetime}\" \"${_target}\" \"${TDE_SCM_MODULE_NAME}\" \"${TDE_SCM_MODULE_REVISION}\" \"${_notes}\"" )
separate_arguments ( ELF_EMBEDDING_METADATA )
separate_arguments ( ELF_EMBEDDING_METADATA )
if ( TDELFEDITOR_EXECUTABLE )
if ( TDELFEDITOR_EXECUTABLE )
# c r e a t e t a r g e t f o r a l l m e t a d a t a w r i t e s
if ( NOT TARGET tdelfeditor-write )
add_custom_target ( tdelfeditor-write
W O R K I N G _ D I R E C T O R Y " $ { C M A K E _ B I N A R Y _ D I R } "
D E P E N D S $ { T D E L F E D I T O R _ E X E C U T A B L E }
C O M M E N T " W r i t e m e t a d a t a t o b i n a r i e s . . . "
)
endif ( )
get_filename_component ( _target_path ${ CMAKE_CURRENT_BINARY_DIR } / ${ _target } ABSOLUTE )
get_filename_component ( _target_path ${ CMAKE_CURRENT_BINARY_DIR } / ${ _target } ABSOLUTE )
file ( RELATIVE_PATH _target_path "${CMAKE_BINARY_DIR}" "${_target_path}" )
file ( RELATIVE_PATH _target_path "${CMAKE_BINARY_DIR}" "${_target_path}" )
add_custom_target (
if ( TARGET ${ TDELFEDITOR_EXECUTABLE } )
$ { _ t a r g e t } + m e t a d a t a A L L
# c r e a t e t a r g e t f o r a l l m e t a d a t a w r i t e s
C O M M A N D $ { T D E L F E D I T O R _ E X E C U T A B L E } - m $ { C M A K E _ C U R R E N T _ B I N A R Y _ D I R } / $ { _ t a r g e t } $ { E L F _ E M B E D D I N G _ M E T A D A T A } | | t r u e
if ( NOT TARGET tdelfeditor-write )
C O M M A N D $ { T D E L F E D I T O R _ E X E C U T A B L E } - e $ { C M A K E _ C U R R E N T _ B I N A R Y _ D I R } / $ { _ t a r g e t } | | t r u e
add_custom_target ( tdelfeditor-write
C O M M A N D $ { T D E L F E D I T O R _ E X E C U T A B L E } - t $ { C M A K E _ C U R R E N T _ B I N A R Y _ D I R } / $ { _ t a r g e t } $ { _ t a r g e t } | | t r u e
W O R K I N G _ D I R E C T O R Y " $ { C M A K E _ B I N A R Y _ D I R } "
C O M M E N T " S t o r i n g S C M m e t a d a t a i n $ { _ t a r g e t _ p a t h } "
D E P E N D S $ { T D E L F E D I T O R _ E X E C U T A B L E }
D E P E N D S t d e l f e d i t o r - w r i t e
C O M M E N T " W r i t e m e t a d a t a t o b i n a r i e s . . . "
)
)
add_dependencies ( tdelfeditor-write ${ _target } )
endif ( )
add_custom_target (
$ { _ t a r g e t } + m e t a d a t a A L L
C O M M A N D $ { T D E L F E D I T O R _ E X E C U T A B L E } - m $ { C M A K E _ C U R R E N T _ B I N A R Y _ D I R } / $ { _ t a r g e t } $ { E L F _ E M B E D D I N G _ M E T A D A T A } | | t r u e
C O M M A N D $ { T D E L F E D I T O R _ E X E C U T A B L E } - e $ { C M A K E _ C U R R E N T _ B I N A R Y _ D I R } / $ { _ t a r g e t } | | t r u e
C O M M E N T " S t o r i n g S C M m e t a d a t a i n $ { _ t a r g e t _ p a t h } "
D E P E N D S t d e l f e d i t o r - w r i t e
)
add_dependencies ( tdelfeditor-write ${ _target } )
else ( )
add_custom_command (
T A R G E T $ { _ t a r g e t }
P O S T _ B U I L D
C O M M A N D $ { T D E L F E D I T O R _ E X E C U T A B L E } - m $ { C M A K E _ C U R R E N T _ B I N A R Y _ D I R } / $ { _ t a r g e t } $ { E L F _ E M B E D D I N G _ M E T A D A T A } | | t r u e
C O M M A N D $ { T D E L F E D I T O R _ E X E C U T A B L E } - e $ { C M A K E _ C U R R E N T _ B I N A R Y _ D I R } / $ { _ t a r g e t } | | t r u e
C O M M A N D $ { T D E L F E D I T O R _ E X E C U T A B L E } - t $ { C M A K E _ C U R R E N T _ B I N A R Y _ D I R } / $ { _ t a r g e t } $ { _ t a r g e t } | | t r u e
C O M M E N T " S t o r i n g S C M m e t a d a t a i n $ { _ t a r g e t _ p a t h } "
)
endif ( )
endif ( TDELFEDITOR_EXECUTABLE )
endif ( TDELFEDITOR_EXECUTABLE )
endmacro ( tde_add_executable )
endmacro ( tde_add_executable )