gnucash master: Multiple changes pushed
Geert Janssens
gjanssens at code.gnucash.org
Tue Sep 17 11:50:03 EDT 2019
Updated via https://github.com/Gnucash/gnucash/commit/594388b7 (commit)
via https://github.com/Gnucash/gnucash/commit/79765413 (commit)
from https://github.com/Gnucash/gnucash/commit/6753b30b (commit)
commit 594388b7656a4776e80a4cd92b9f50d32d70001e
Author: Geert Janssens <geert at kobaltwit.be>
Date: Sat Sep 14 10:17:56 2019 +0200
Drop support for gettext older than 0.19.6
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 32fd2b631..ba7572a97 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -62,7 +62,6 @@ option (DISABLE_NLS "do not use Native Language Support" OFF)
option (DISABLE_DEPRECATED_GLIB "don't use deprecated glib functions" OFF)
option (DISABLE_DEPRECATED_GTK "don't use deprecated gtk, gdk or gdk-pixbuf functions" OFF)
option (DISABLE_DEPRECATED_GNOME "don't use deprecated gnome functions" OFF)
-option (ALLOW_OLD_GETTEXT "allow to configure build with a gettext version older than 0.19.6. Some files will not be translated!" OFF)
# ############################################################
# These are also settable from the command line in a similar way.
@@ -252,24 +251,7 @@ find_path (REGEX_INCLUDE_PATH NAMES regex.h
find_library (REGEX_LIBRARY NAMES regex)
# I18N
-if (ALLOW_OLD_GETTEXT)
- find_package (Gettext REQUIRED)
-else (ALLOW_OLD_GETTEXT)
- find_package (Gettext 0.19.6)
- if (NOT GETTEXT_FOUND)
- message (FATAL_ERROR "Note the build can be configured with an older version of gettext by setting ALLOW_OLD_GETTEXT=ON but then some files will not be translated:
- - gnucash.desktop (requires at least gettext 0.19)
- - gnucash.appdata.xml (requires at least gettext 0.19.6)")
- endif (NOT GETTEXT_FOUND)
-endif (ALLOW_OLD_GETTEXT)
-
-if (${GETTEXT_VERSION_STRING} VERSION_LESS 0.19)
- message (WARNING "Got gettext version ${GETTEXT_VERSION_STRING}, however you need at least gettext version 0.19 in order to handle translation of the gnucash.desktop file. The build will be configured with an untranslated gnucash.desktop file.")
-endif ()
-if (${GETTEXT_VERSION_STRING} VERSION_LESS 0.19.6)
- message (WARNING "Got gettext version ${GETTEXT_VERSION_STRING}, however you need at least gettext version 0.19.6 in order to handle translation of the gnucash.appdata file. The build will be configured with an untranslated gnucash.appdata file.")
-endif ()
-
+find_package (Gettext 0.19.6 REQUIRED)
find_path (LIBINTL_INCLUDE_PATH NAMES libintl.h
PATHS /usr/include /opt/gnome/include)
find_library (LIBINTL_LIBRARY NAMES intl)
diff --git a/README.dependencies b/README.dependencies
index 75e0cea40..e13aa2818 100644
--- a/README.dependencies
+++ b/README.dependencies
@@ -66,10 +66,7 @@ Libraries/Deps
gtk+3 3.14.0
guile 2.2.0 or 2.0.0
libxml2 2.5.10
- gettext 0.19.6 Can use older if you pass
- -DALLOW_OLD_GETTEXT to cmake;
- doesn't include all file types
- when building gnucash.pot.
+ gettext 0.19.6
libxslt, including xsltproc
ICU International Compnents for
Unicode
diff --git a/gnucash/gnome/CMakeLists.txt b/gnucash/gnome/CMakeLists.txt
index 8e1698822..32beaf79b 100644
--- a/gnucash/gnome/CMakeLists.txt
+++ b/gnucash/gnome/CMakeLists.txt
@@ -175,30 +175,17 @@ DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/gnucash.appdata.xml.in.in ${VCS_INFO_FILE}
-D SRC_DIR=${CMAKE_SOURCE_DIR}
-P ${CMAKE_SOURCE_DIR}/cmake/configure-appdata.cmake)
-if (${GETTEXT_VERSION_STRING} VERSION_LESS 0.19.6)
- # Gettext is too old to be able to merge an appdata file.
- # Fall back to providing an unmerged (and hence untranslated) appdata file.
- add_custom_command (
- OUTPUT gnucash.appdata.xml
- COMMAND ${CMAKE_COMMAND} -E copy_if_different
- ${CMAKE_CURRENT_BINARY_DIR}/gnucash.appdata.xml.in
- ${CMAKE_CURRENT_BINARY_DIR}/gnucash.appdata.xml
-
- DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/gnucash.appdata.xml.in ${VCS_INFO_FILE}
- )
-else()
- # FIXME: where does LC_ALL=C come from?
- add_custom_command (
- OUTPUT gnucash.appdata.xml
- COMMAND ${CMAKE_COMMAND} -E env
- LC_ALL=C
- ${GETTEXT_MSGFMT_EXECUTABLE}
- --xml --template ${CMAKE_CURRENT_BINARY_DIR}/gnucash.appdata.xml.in
- -d ${CMAKE_SOURCE_DIR}/po
- -o gnucash.appdata.xml
- DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/gnucash.appdata.xml.in ${VCS_INFO_FILE}
- )
-endif()
+# FIXME: where does LC_ALL=C come from?
+add_custom_command (
+ OUTPUT gnucash.appdata.xml
+ COMMAND ${CMAKE_COMMAND} -E env
+ LC_ALL=C
+ ${GETTEXT_MSGFMT_EXECUTABLE}
+ --xml --template ${CMAKE_CURRENT_BINARY_DIR}/gnucash.appdata.xml.in
+ -d ${CMAKE_SOURCE_DIR}/po
+ -o gnucash.appdata.xml
+ DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/gnucash.appdata.xml.in ${VCS_INFO_FILE}
+)
add_custom_target(gnucash-appdata ALL DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/gnucash.appdata.xml)
@@ -208,23 +195,16 @@ install(FILES ${CMAKE_CURRENT_BINARY_DIR}/gnucash.appdata.xml DESTINATION ${CMA
configure_file(gnucash.desktop.in.in gnucash.desktop.in)
-if (${GETTEXT_VERSION_STRING} VERSION_LESS 0.19)
- # Gettext is too old to be able to merge a desktop file.
- # Fall back to providing an unmerged (and hence untranslated) desktop file.
- configure_file (${CMAKE_CURRENT_BINARY_DIR}/gnucash.desktop.in
- ${CMAKE_CURRENT_BINARY_DIR}/gnucash.desktop COPYONLY)
-else()
- add_custom_command (
- OUTPUT gnucash.desktop
- COMMAND ${CMAKE_COMMAND} -E env
- LC_ALL=C
- ${GETTEXT_MSGFMT_EXECUTABLE}
- --desktop --template gnucash.desktop.in
- -d ${CMAKE_SOURCE_DIR}/po
- -o gnucash.desktop
- DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/gnucash.desktop.in
- )
-endif()
+add_custom_command (
+ OUTPUT gnucash.desktop
+ COMMAND ${CMAKE_COMMAND} -E env
+ LC_ALL=C
+ ${GETTEXT_MSGFMT_EXECUTABLE}
+ --desktop --template gnucash.desktop.in
+ -d ${CMAKE_SOURCE_DIR}/po
+ -o gnucash.desktop
+ DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/gnucash.desktop.in
+)
add_custom_target(gnucash-desktop ALL DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/gnucash.desktop)
commit 797654133b1044da9669a4347ac632e3cfa006a7
Author: Geert Janssens <geert at kobaltwit.be>
Date: Sat Sep 14 10:08:28 2019 +0200
Use newer cmake version checks
diff --git a/CMakeLists.txt b/CMakeLists.txt
index da3522d43..32fd2b631 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -736,7 +736,7 @@ set(PLATFORM_OSX 1)
set(HAVE_OSX_KEYCHAIN 1)
endif(APPLE)
-if(GLIB2_VERSION VERSION_GREATER 2.46.0 OR GLIB2_VERSION VERSION_EQUAL 2.46.0)
+if(GLIB2_VERSION VERSION_GREATER_EQUAL 2.46.0)
set(HAVE_GLIB_2_46 1)
endif()
diff --git a/common/cmake_modules/GncAddSchemeTargets.cmake b/common/cmake_modules/GncAddSchemeTargets.cmake
index 209370d45..12d053b33 100644
--- a/common/cmake_modules/GncAddSchemeTargets.cmake
+++ b/common/cmake_modules/GncAddSchemeTargets.cmake
@@ -159,8 +159,7 @@ function(make_scheme_targets _TARGET _SOURCE_FILES _OUTPUT_DIR _GUILE_DEPENDS
set(_GUILE_LOAD_PATH "${current_srcdir}" "${current_bindir}" "${current_bindir}/deprecated")
set(_GUILE_LOAD_COMPILED_PATH "${current_bindir}")
# VERSION_GREATER_EQUAL introduced in CMake 3.7.
- if(MINGW64 AND (${GUILE_EFFECTIVE_VERSION} VERSION_GREATER 2.2 OR
- ${GUILE_EFFECTIVE_VERSION} VERSION_EQUAL 2.2))
+ if(MINGW64 AND (${GUILE_EFFECTIVE_VERSION} VERSION_GREATER_EQUAL 2.2))
file(TO_CMAKE_PATH $ENV{GUILE_LOAD_PATH} guile_load_path)
file(TO_CMAKE_PATH $ENV{GUILE_LOAD_COMPILED_PATH} guile_load_compiled_path)
list(APPEND _GUILE_LOAD_PATH ${guile_load_path})
Summary of changes:
CMakeLists.txt | 22 +--------
README.dependencies | 5 +--
common/cmake_modules/GncAddSchemeTargets.cmake | 3 +-
gnucash/gnome/CMakeLists.txt | 62 +++++++++-----------------
4 files changed, 25 insertions(+), 67 deletions(-)
More information about the gnucash-changes
mailing list