gnucash unstable: Multiple changes pushed

John Ralls jralls at code.gnucash.org
Sat Mar 17 17:54:48 EDT 2018


Updated	 via  https://github.com/Gnucash/gnucash/commit/25d9431d (commit)
	 via  https://github.com/Gnucash/gnucash/commit/a4b043c3 (commit)
	 via  https://github.com/Gnucash/gnucash/commit/6b46299e (commit)
	from  https://github.com/Gnucash/gnucash/commit/8fe2cb6f (commit)



commit 25d9431dc108343caccf3bf51549e84bc7dbb40a
Merge: a4b043c 6b46299
Author: John Ralls <jralls at ceridwen.us>
Date:   Sat Mar 17 14:18:11 2018 -0700

    Merge Luciano Santos's 'compile-schema-patch' PR into unstable.


commit a4b043c3f053c7ada8bb2b2b13ce8343f36c5aa2
Author: John Ralls <jralls at ceridwen.us>
Date:   Sat Mar 17 14:10:56 2018 -0700

    Bug 794236 - Import a log file
    
    The crash was caused by the timezone constructor encountering a
    newline on the timezone. Prevent this by removing all whitespace
    from the end of the input string.

diff --git a/gnucash/import-export/log-replay/gnc-log-replay.c b/gnucash/import-export/log-replay/gnc-log-replay.c
index d79fa22..00bbb2b 100644
--- a/gnucash/import-export/log-replay/gnc-log-replay.c
+++ b/gnucash/import-export/log-replay/gnc-log-replay.c
@@ -384,11 +384,13 @@ static void  process_trans_record(  FILE *log_file)
     while ( record_ended == FALSE)
     {
         read_retval = fgets(read_buf, sizeof(read_buf), log_file);
-        if (read_retval != NULL && strncmp(record_end_str, read_buf, strlen(record_end_str)) != 0) /* If we are not at the end of the record */
+        if (read_retval != NULL &&
+            strncmp(record_end_str, read_buf, strlen(record_end_str)) != 0) /* If we are not at the end of the record */
         {
             split_num++;
             /*DEBUG("process_trans_record(): Line read: %s%s",read_buf ,"\n");*/
-            record = interpret_split_record( read_buf);
+
+            record = interpret_split_record(g_strchomp(read_buf));
             dump_split_record( record);
             if (record.log_action_present)
             {

commit 6b46299e8dd78cd0202c0c75f6a27d885ca931df
Author: luc14n0 <luc14n0 at linuxmail.org>
Date:   Sat Mar 17 00:14:25 2018 -0300

    Add COMPILE_SCHEMA to allow disabling gschema compilation

diff --git a/CMakeLists.txt b/CMakeLists.txt
index 370a6d1..4bd2e9f 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -71,6 +71,9 @@ OPTION (ALLOW_OLD_GETTEXT "allow to configure build with a gettext version older
 
 # These are also settable from the command line in a similar way.
 
+# Use gsettings-desktop-schema for a better integration with GNOME
+SET(COMPILE_SCHEMA ON CACHE BOOL "Compile the GSettings schema")
+
 SET(GNUCASH_BUILD_ID "" CACHE STRING "Overrides the GnuCash build identification (Build ID) which defaults to a description of the vcs commit from which gnucash is built. Distributions may want to insert a package management based version number instead")
 # GENERATE_SWIG_WRAPPERS - Controls whether to generate the swig wrappers for guile and python. If not set the wrappers will only be generated when building from a git worktree, commented out here, but will be evaluated later on in this file
 
diff --git a/gnucash/gschemas/CMakeLists.txt b/gnucash/gschemas/CMakeLists.txt
index 9f68bb7..b7668f1 100644
--- a/gnucash/gschemas/CMakeLists.txt
+++ b/gnucash/gschemas/CMakeLists.txt
@@ -22,23 +22,25 @@ SET(gschema_SOURCES
 add_gschema_targets("${gschema_SOURCES}")
 
 # Handle gschemas.compiled
-set(CMAKE_COMMAND_TMP "")
-if (${CMAKE_VERSION} VERSION_GREATER 3.1)
-    set(CMAKE_COMMAND_TMP ${CMAKE_COMMAND} -E env)
-endif()
-
-add_custom_command(
-    OUTPUT ${SCHEMADIR_BUILD}/gschemas.compiled
-    COMMAND ${CMAKE_COMMAND_TMP} ${GLIB_COMPILE_SCHEMAS} ${SCHEMADIR_BUILD}
-    DEPENDS ${gschema_depends}
-)
+if (COMPILE_SCHEMA)
+    set(CMAKE_COMMAND_TMP "")
+    if (${CMAKE_VERSION} VERSION_GREATER 3.1)
+        set(CMAKE_COMMAND_TMP ${CMAKE_COMMAND} -E env)
+    endif()
+
+    add_custom_command(
+        OUTPUT ${SCHEMADIR_BUILD}/gschemas.compiled
+        COMMAND ${CMAKE_COMMAND_TMP} ${GLIB_COMPILE_SCHEMAS} ${SCHEMADIR_BUILD}
+        DEPENDS ${gschema_depends}
+    )
 
-add_custom_target(compiled-schemas ALL DEPENDS ${SCHEMADIR_BUILD}/gschemas.compiled)
+    add_custom_target(compiled-schemas ALL DEPENDS ${SCHEMADIR_BUILD}/gschemas.compiled)
 
 
-install(CODE "execute_process(
-    COMMAND ${SHELL} -c \"echo Compiling gschema files in $DESTDIR${CMAKE_INSTALL_FULL_DATADIR}/glib-2.0/schemas ;
-                          ${GLIB_COMPILE_SCHEMAS} $DESTDIR${CMAKE_INSTALL_FULL_DATADIR}/glib-2.0/schemas\")")
+    install(CODE "execute_process(
+        COMMAND ${SHELL} -c \"echo Compiling gschema files in $DESTDIR${CMAKE_INSTALL_FULL_DATADIR}/glib-2.0/schemas ;
+                              ${GLIB_COMPILE_SCHEMAS} $DESTDIR${CMAKE_INSTALL_FULL_DATADIR}/glib-2.0/schemas\")")
+endif ()
 
 SET(gschemas_DIST_local "")
 FOREACH(file ${gschema_SOURCES})



Summary of changes:
 CMakeLists.txt                                    |  3 +++
 gnucash/gschemas/CMakeLists.txt                   | 30 ++++++++++++-----------
 gnucash/import-export/log-replay/gnc-log-replay.c |  6 +++--
 3 files changed, 23 insertions(+), 16 deletions(-)



More information about the gnucash-changes mailing list