Cmake Question
Robert Fewell
14ubobit at gmail.com
Tue Sep 26 16:26:09 EDT 2017
Hi,
I have managed to convert the use of css files to using a gresource file
that gets compiled in and thought it would be good idea to use css files
when compiled with DEBUG enabled.
So I moved the two css files to the gnucash directory and added #ifdef
DEBUG statements to gnc-gnome-utils.c to enable using css files but wanted
to only copy them when in DEBUG so added this to CmakeLists.txt
IF(CMAKE_BUILD_TYPE MATCHES DEBUG)
FILE(GLOB CSS_FILES "*.css")
FILE(COPY ${CSS_FILES}
DESTINATION ${DATADIR_BUILD}/gnucash/ui)
INSTALL(FILES ${CSS_FILES}
DESTINATION share/gnucash/ui)
ENDIF(CMAKE_BUILD_TYPE MATCHES DEBUG)
which does not work, removing the if/endif does copy them so that is OK, if
I add the following to the top level CmakeLists.txt
SET (CMAKE_BUILD_TYPE DEBUG)
it works, so how should that be set ?
There is this line in the file...
OPTION (ENABLE_DEBUG "compile with debugging flags set" OFF)
Should that then do the SET ?
Regards,
Bob
More information about the gnucash-devel
mailing list