Cutecash: Switch from guile to xml to manage our iso-currencies source file

Copies 87520cdde4 into the cmake build system.
This commit is contained in:
Christian Stimming 2015-04-22 22:33:58 +02:00
parent 274113b347
commit e9b6ee74ad
2 changed files with 7 additions and 2 deletions

View File

@ -94,6 +94,11 @@ ENDIF (NOT GUILE_EXECUTABLE)
# ############################################################
# xsltproc
FIND_PROGRAM (XSLTPROC xsltproc)
# ############################################################
# libdbi
FIND_PATH (LIBDBI_INCLUDE_PATH dbi/dbi.h)
FIND_LIBRARY (LIBDBI_LIBRARY dbi)

View File

@ -76,9 +76,9 @@ GNC_ADD_SWIG_COMMAND (${SWIG_ENGINE_C} ${CMAKE_CURRENT_SOURCE_DIR}/engine.i ${li
SET (ISO_4217_C ${CMAKE_CURRENT_BINARY_DIR}/iso-4217-currencies.c)
ADD_CUSTOM_COMMAND (
OUTPUT ${ISO_4217_C}
DEPENDS iso-4217-currencies.scm iso-currencies-to-c.in
DEPENDS iso-4217-currencies.xml iso-currencies-to-c.xsl
COMMAND
${GUILE_EXECUTABLE} -s "${CMAKE_CURRENT_SOURCE_DIR}/iso-currencies-to-c.in" "${CMAKE_CURRENT_SOURCE_DIR}"
${XSLTPROC} -o ${ISO_4217_C} "${CMAKE_CURRENT_SOURCE_DIR}/iso-currencies-to-c.xsl" "${CMAKE_CURRENT_SOURCE_DIR}/iso-4217-currencies.xml"
)
# Add dependency on iso-4217-currencies.c
SET_SOURCE_FILES_PROPERTIES (gnc-commodity.c PROPERTIES OBJECT_DEPENDS ${ISO_4217_C})