mirror of
https://github.com/Gnucash/gnucash.git
synced 2025-02-25 18:55:30 -06:00
Drop intltool in favour or using modern gettext
This requires at least gettext 0.19.6, and will break our ubuntu 14.04LTS test instance on Travis. The next commit will work around this.
This commit is contained in:
parent
3462abe7ad
commit
ba799feb2a
1
.gitignore
vendored
1
.gitignore
vendored
@ -66,6 +66,7 @@ make-gnucash-potfiles
|
|||||||
missing
|
missing
|
||||||
mkinstalldirs
|
mkinstalldirs
|
||||||
po/.intltool-merge-cache
|
po/.intltool-merge-cache
|
||||||
|
po/LINGUAS
|
||||||
po/Makefile.in.in
|
po/Makefile.in.in
|
||||||
po/POTFILES
|
po/POTFILES
|
||||||
po/POTFILES.in
|
po/POTFILES.in
|
||||||
|
@ -172,8 +172,6 @@ IF (WIN32)
|
|||||||
SET(REGEX_LDFLAGS "-L${REGEX_LIB_PATH} -lregex")
|
SET(REGEX_LDFLAGS "-L${REGEX_LIB_PATH} -lregex")
|
||||||
#SET(LIBXSLT_INCLUDE_DIR ${CMAKE_PREFIX_PATH}/libxslt/include)
|
#SET(LIBXSLT_INCLUDE_DIR ${CMAKE_PREFIX_PATH}/libxslt/include)
|
||||||
#SET(LIBXSLT_XSLTPROC_EXECUTABLE ${CMAKE_PREFIX_PATH}/libxslt/bin/xsltproc)
|
#SET(LIBXSLT_XSLTPROC_EXECUTABLE ${CMAKE_PREFIX_PATH}/libxslt/bin/xsltproc)
|
||||||
# I have not yet debugged the intltool-merge file generation process on Windows.
|
|
||||||
SET(NO_INTLTOOL TRUE)
|
|
||||||
#Prevent creating a console window on startup.
|
#Prevent creating a console window on startup.
|
||||||
SET(CMAKE_EXE_LINKER_FLAGS -mwindows)
|
SET(CMAKE_EXE_LINKER_FLAGS -mwindows)
|
||||||
ENDIF(WIN32)
|
ENDIF(WIN32)
|
||||||
@ -249,12 +247,8 @@ ENDIF()
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
FIND_PROGRAM(INTLTOOL_MERGE NAMES intltool-merge HINTS ${CMAKE_PREFIX_PATH}/gnome/bin)
|
|
||||||
FIND_PROGRAM(GLIB_COMPILE_SCHEMAS glib-compile-schemas HINTS ${CMAKE_PREFIX_PATH}/gnome/bin)
|
FIND_PROGRAM(GLIB_COMPILE_SCHEMAS glib-compile-schemas HINTS ${CMAKE_PREFIX_PATH}/gnome/bin)
|
||||||
FIND_PROGRAM(MSGFMT msgfmt)
|
FIND_PROGRAM(MSGFMT msgfmt)
|
||||||
IF(NOT INTLTOOL_MERGE)
|
|
||||||
MESSAGE(SEND_ERROR "Can't find intltool-merge program. Please set INTLTOOL_MERGE.")
|
|
||||||
ENDIF(NOT INTLTOOL_MERGE)
|
|
||||||
|
|
||||||
IF (NOT GLIB_COMPILE_SCHEMAS)
|
IF (NOT GLIB_COMPILE_SCHEMAS)
|
||||||
MESSAGE(SEND_ERROR "Can't find glib-compile-schemas program. Please set GLIB_COMPILE_SCHEMAS.")
|
MESSAGE(SEND_ERROR "Can't find glib-compile-schemas program. Please set GLIB_COMPILE_SCHEMAS.")
|
||||||
|
@ -11,17 +11,9 @@ macro(add_gschema_targets _gschema_INPUTS)
|
|||||||
SET(CMAKE_COMMAND_TMP ${CMAKE_COMMAND} -E env)
|
SET(CMAKE_COMMAND_TMP ${CMAKE_COMMAND} -E env)
|
||||||
ENDIF()
|
ENDIF()
|
||||||
FOREACH(file ${_gschema_INPUTS})
|
FOREACH(file ${_gschema_INPUTS})
|
||||||
configure_file(${file}.in.in ${file}.in @ONLY)
|
|
||||||
|
|
||||||
set(_OUTPUT_FILE ${DATADIR_BUILD}/glib-2.0/schemas/${file})
|
set(_OUTPUT_FILE ${DATADIR_BUILD}/glib-2.0/schemas/${file})
|
||||||
ADD_CUSTOM_COMMAND(
|
configure_file(${file}.in ${_OUTPUT_FILE} @ONLY)
|
||||||
OUTPUT ${_OUTPUT_FILE}
|
|
||||||
COMMAND ${CMAKE_COMMAND_TMP}
|
|
||||||
LC_ALL=C
|
|
||||||
${PERL_EXECUTABLE} ${INTLTOOL_MERGE} -x -u ${INITTOOL_OPTIONS} ${CMAKE_CURRENT_BINARY_DIR}/${file}.in ${_OUTPUT_FILE}
|
|
||||||
DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/${file}.in
|
|
||||||
MAIN_DEPENDENCY ${CMAKE_CURRENT_SOURCE_DIR}/${file}.in.in
|
|
||||||
)
|
|
||||||
list(APPEND _gschema_OUTPUTS ${_OUTPUT_FILE})
|
list(APPEND _gschema_OUTPUTS ${_OUTPUT_FILE})
|
||||||
|
|
||||||
string(REPLACE ".xml" ".valid" file_no_xml ${file})
|
string(REPLACE ".xml" ".valid" file_no_xml ${file})
|
||||||
|
@ -19,7 +19,7 @@ SET(doc_DATA
|
|||||||
|
|
||||||
SET(doc_noinst_DATA
|
SET(doc_noinst_DATA
|
||||||
build-aix.txt build-solaris.txt CMakeLists.txt gnc-fq-dump.1 gnc-fq-helper.1 gnucash.1.in
|
build-aix.txt build-solaris.txt CMakeLists.txt gnc-fq-dump.1 gnc-fq-helper.1 gnucash.1.in
|
||||||
misc-notes.txt README.HBCI README.OFX README.translator.txt tip_of_the_day.list.in
|
misc-notes.txt README.HBCI README.OFX README.translator.txt tip_of_the_day.list.c
|
||||||
TRANSLATION_HOWTO)
|
TRANSLATION_HOWTO)
|
||||||
|
|
||||||
INSTALL(FILES ${doc_DATA} DESTINATION ${CMAKE_INSTALL_DOCDIR})
|
INSTALL(FILES ${doc_DATA} DESTINATION ${CMAKE_INSTALL_DOCDIR})
|
||||||
@ -32,7 +32,7 @@ FILE(COPY ${doc_DATA} DESTINATION ${DATADIR_BUILD}/doc/gnucash)
|
|||||||
# Generate the tip of the day file.
|
# Generate the tip of the day file.
|
||||||
|
|
||||||
EXECUTE_PROCESS(
|
EXECUTE_PROCESS(
|
||||||
COMMAND ${CMAKE_C_COMPILER} -E -P -x c -DN_\(x\)=x -o ${CMAKE_CURRENT_BINARY_DIR}/tip_of_the_day.list.tmp ${CMAKE_CURRENT_SOURCE_DIR}/tip_of_the_day.list.in
|
COMMAND ${CMAKE_C_COMPILER} -E -P -x c -DN_\(x\)=x -o ${CMAKE_CURRENT_BINARY_DIR}/tip_of_the_day.list.tmp ${CMAKE_CURRENT_SOURCE_DIR}/tip_of_the_day.list.c
|
||||||
)
|
)
|
||||||
|
|
||||||
FILE(STRINGS ${CMAKE_CURRENT_BINARY_DIR}/tip_of_the_day.list.tmp TIP_OF_THE_DAY_LINES)
|
FILE(STRINGS ${CMAKE_CURRENT_BINARY_DIR}/tip_of_the_day.list.tmp TIP_OF_THE_DAY_LINES)
|
||||||
|
@ -10,21 +10,21 @@ gnc_add_swig_guile_command (swig-gnome-utils-c
|
|||||||
${CMAKE_CURRENT_SOURCE_DIR}/gnome-utils.i
|
${CMAKE_CURRENT_SOURCE_DIR}/gnome-utils.i
|
||||||
)
|
)
|
||||||
|
|
||||||
SET (WARNINGS_SCHEMA ../gschemas/org.gnucash.warnings.gschema.xml.in)
|
SET (WARNINGS_SCHEMA ${DATADIR_BUILD}/glib-2.0/schemas/org.gnucash.warnings.gschema.xml)
|
||||||
SET (GNC_WARNINGS_C ${CMAKE_CURRENT_BINARY_DIR}/gnc-warnings.c)
|
SET (GNC_WARNINGS_C ${CMAKE_CURRENT_BINARY_DIR}/gnc-warnings.c)
|
||||||
SET (GNC_WARNINGS_H ${CMAKE_CURRENT_BINARY_DIR}/gnc-warnings.h)
|
SET (GNC_WARNINGS_H ${CMAKE_CURRENT_BINARY_DIR}/gnc-warnings.h)
|
||||||
|
|
||||||
ADD_CUSTOM_COMMAND(
|
ADD_CUSTOM_COMMAND(
|
||||||
OUTPUT ${GNC_WARNINGS_C}
|
OUTPUT ${GNC_WARNINGS_C}
|
||||||
DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/${WARNINGS_SCHEMA} make-gnc-warnings-c.xsl
|
DEPENDS ${WARNINGS_SCHEMA} make-gnc-warnings-c.xsl
|
||||||
COMMAND
|
COMMAND
|
||||||
${LIBXSLT_XSLTPROC_EXECUTABLE} -o ${GNC_WARNINGS_C} ${CMAKE_CURRENT_SOURCE_DIR}/make-gnc-warnings-c.xsl ${CMAKE_CURRENT_BINARY_DIR}/${WARNINGS_SCHEMA}
|
${LIBXSLT_XSLTPROC_EXECUTABLE} -o ${GNC_WARNINGS_C} ${CMAKE_CURRENT_SOURCE_DIR}/make-gnc-warnings-c.xsl ${WARNINGS_SCHEMA}
|
||||||
)
|
)
|
||||||
ADD_CUSTOM_COMMAND(
|
ADD_CUSTOM_COMMAND(
|
||||||
OUTPUT ${GNC_WARNINGS_H}
|
OUTPUT ${GNC_WARNINGS_H}
|
||||||
DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/${WARNINGS_SCHEMA} make-gnc-warnings-h.xsl
|
DEPENDS ${WARNINGS_SCHEMA} make-gnc-warnings-h.xsl
|
||||||
COMMAND
|
COMMAND
|
||||||
${LIBXSLT_XSLTPROC_EXECUTABLE} -o ${GNC_WARNINGS_H} ${CMAKE_CURRENT_SOURCE_DIR}/make-gnc-warnings-h.xsl ${CMAKE_CURRENT_BINARY_DIR}/${WARNINGS_SCHEMA}
|
${LIBXSLT_XSLTPROC_EXECUTABLE} -o ${GNC_WARNINGS_H} ${CMAKE_CURRENT_SOURCE_DIR}/make-gnc-warnings-h.xsl ${WARNINGS_SCHEMA}
|
||||||
)
|
)
|
||||||
|
|
||||||
#GTK before 3.14 didn't have GDK_MODIFIER_INTENT_DEFAULT_MOD_MASK
|
#GTK before 3.14 didn't have GDK_MODIFIER_INTENT_DEFAULT_MOD_MASK
|
||||||
|
@ -171,8 +171,9 @@ ADD_CUSTOM_COMMAND(
|
|||||||
OUTPUT gnucash.appdata.xml
|
OUTPUT gnucash.appdata.xml
|
||||||
COMMAND ${CMAKE_COMMAND_TMP}
|
COMMAND ${CMAKE_COMMAND_TMP}
|
||||||
LC_ALL=C
|
LC_ALL=C
|
||||||
${PERL_EXECUTABLE} ${INTLTOOL_MERGE} -x -u -c ${CMAKE_SOURCE_DIR}/po/.intltool-merge-cache ${CMAKE_SOURCE_DIR}/po
|
${MSGFMT} --xml --template ${CMAKE_CURRENT_SOURCE_DIR}/gnucash.appdata.xml.in
|
||||||
${CMAKE_CURRENT_SOURCE_DIR}/gnucash.appdata.xml.in gnucash.appdata.xml
|
-d ${CMAKE_SOURCE_DIR}/po
|
||||||
|
-o gnucash.appdata.xml
|
||||||
DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/gnucash.appdata.xml.in
|
DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/gnucash.appdata.xml.in
|
||||||
)
|
)
|
||||||
|
|
||||||
@ -188,8 +189,9 @@ ADD_CUSTOM_COMMAND(
|
|||||||
OUTPUT gnucash.desktop
|
OUTPUT gnucash.desktop
|
||||||
COMMAND ${CMAKE_COMMAND_TMP}
|
COMMAND ${CMAKE_COMMAND_TMP}
|
||||||
LC_ALL=C
|
LC_ALL=C
|
||||||
${PERL_EXECUTABLE} ${INTLTOOL_MERGE} -d -u -c ${CMAKE_SOURCE_DIR}/po/.intltool-merge-cache ${CMAKE_SOURCE_DIR}/po
|
${MSGFMT} --desktop --template gnucash.desktop.in
|
||||||
gnucash.desktop.in gnucash.desktop
|
-d ${CMAKE_SOURCE_DIR}/po
|
||||||
|
-o gnucash.desktop
|
||||||
DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/gnucash.desktop.in
|
DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/gnucash.desktop.in
|
||||||
)
|
)
|
||||||
|
|
||||||
|
@ -6,22 +6,22 @@
|
|||||||
<name>GnuCash</name>
|
<name>GnuCash</name>
|
||||||
<summary>Manage your finances, accounts, and investments</summary>
|
<summary>Manage your finances, accounts, and investments</summary>
|
||||||
<description>
|
<description>
|
||||||
<_p>
|
<p>
|
||||||
GnuCash is a program for personal and small-business financial-accounting.
|
GnuCash is a program for personal and small-business financial-accounting.
|
||||||
</_p>
|
</p>
|
||||||
<_p>
|
<p>
|
||||||
Designed to be easy to use, yet powerful and flexible, GnuCash allows you to track bank accounts, stocks, income and expenses. As quick and intuitive to use as a checkbook register, it is based on professional accounting principles like double-entry
|
Designed to be easy to use, yet powerful and flexible, GnuCash allows you to track bank accounts, stocks, income and expenses. As quick and intuitive to use as a checkbook register, it is based on professional accounting principles like double-entry
|
||||||
accounting to ensure balanced books and accurate reports.
|
accounting to ensure balanced books and accurate reports.
|
||||||
</_p>
|
</p>
|
||||||
<_p>With GnuCash you can (but are not limited to):</_p>
|
<p>With GnuCash you can (but are not limited to):</p>
|
||||||
<ul>
|
<ul>
|
||||||
<_li>Keep track of your day to day personal income and expenses</_li>
|
<li>Keep track of your day to day personal income and expenses</li>
|
||||||
<_li>Manage your stock, bond and mutual fund accounts with ease</_li>
|
<li>Manage your stock, bond and mutual fund accounts with ease</li>
|
||||||
<_li>Keep your small business' accounting up to date</_li>
|
<li>Keep your small business' accounting up to date</li>
|
||||||
<_li>Create accurate reports and graphs from your financial data</_li>
|
<li>Create accurate reports and graphs from your financial data</li>
|
||||||
<_li>Set up scheduled transactions to avoid repeated data entry</_li>
|
<li>Set up scheduled transactions to avoid repeated data entry</li>
|
||||||
<_li>QIF/OFX/HBCI Import, Transaction Matching</_li>
|
<li>QIF/OFX/HBCI Import, Transaction Matching</li>
|
||||||
<_li>Perform financial calculations, such as a loan repayment</_li>
|
<li>Perform financial calculations, such as a loan repayment</li>
|
||||||
</ul>
|
</ul>
|
||||||
</description>
|
</description>
|
||||||
<categories>
|
<categories>
|
||||||
|
@ -2,9 +2,9 @@
|
|||||||
Type=Application
|
Type=Application
|
||||||
MimeType=application/x-gnucash;
|
MimeType=application/x-gnucash;
|
||||||
Version=0.9.4
|
Version=0.9.4
|
||||||
_Name=GnuCash
|
Name=GnuCash
|
||||||
_GenericName=Finance Management
|
GenericName=Finance Management
|
||||||
_Comment=Manage your finances, accounts, and investments
|
Comment=Manage your finances, accounts, and investments
|
||||||
Exec=gnucash %f
|
Exec=gnucash %f
|
||||||
Icon=gnucash-icon
|
Icon=gnucash-icon
|
||||||
StartupNotify=true
|
StartupNotify=true
|
||||||
|
@ -38,6 +38,6 @@ install(CODE "execute_process(
|
|||||||
|
|
||||||
SET(gschemas_DIST_local "")
|
SET(gschemas_DIST_local "")
|
||||||
FOREACH(file ${gschema_SOURCES})
|
FOREACH(file ${gschema_SOURCES})
|
||||||
LIST(APPEND gschemas_DIST_local ${file}.in.in)
|
LIST(APPEND gschemas_DIST_local ${file}.in)
|
||||||
ENDFOREACH()
|
ENDFOREACH()
|
||||||
SET_DIST_LIST(gschemas_DIST CMakeLists.txt ${gschemas_DIST_local})
|
SET_DIST_LIST(gschemas_DIST CMakeLists.txt ${gschemas_DIST_local})
|
||||||
|
@ -5,4 +5,4 @@ IF (WITH_AQBANKING)
|
|||||||
add_gschema_targets("${aqb_GSCHEMA}")
|
add_gschema_targets("${aqb_GSCHEMA}")
|
||||||
ENDIF(WITH_AQBANKING)
|
ENDIF(WITH_AQBANKING)
|
||||||
|
|
||||||
SET_DIST_LIST(aqbanking_gschema_DIST CMakeLists.txt org.gnucash.dialogs.import.hbci.gschema.xml.in.in)
|
SET_DIST_LIST(aqbanking_gschema_DIST CMakeLists.txt org.gnucash.dialogs.import.hbci.gschema.xml.in)
|
||||||
|
@ -3,4 +3,4 @@ SET(csv_exp_GSCHEMA org.gnucash.dialogs.export.csv.gschema.xml)
|
|||||||
|
|
||||||
add_gschema_targets("${csv_exp_GSCHEMA}")
|
add_gschema_targets("${csv_exp_GSCHEMA}")
|
||||||
|
|
||||||
SET_DIST_LIST(csv_exp_gschema_DIST CMakeLists.txt org.gnucash.dialogs.export.csv.gschema.xml.in.in)
|
SET_DIST_LIST(csv_exp_gschema_DIST CMakeLists.txt org.gnucash.dialogs.export.csv.gschema.xml.in)
|
||||||
|
@ -2,4 +2,4 @@ SET(csv_imp_GSCHEMA org.gnucash.dialogs.import.csv.gschema.xml)
|
|||||||
|
|
||||||
add_gschema_targets("${csv_imp_GSCHEMA}")
|
add_gschema_targets("${csv_imp_GSCHEMA}")
|
||||||
|
|
||||||
SET_DIST_LIST(csv_import_gschema_DIST CMakeLists.txt org.gnucash.dialogs.import.csv.gschema.xml.in.in)
|
SET_DIST_LIST(csv_import_gschema_DIST CMakeLists.txt org.gnucash.dialogs.import.csv.gschema.xml.in)
|
||||||
|
@ -3,4 +3,4 @@ SET(generic_import_GSCHEMA org.gnucash.dialogs.import.generic.gschema.xml)
|
|||||||
|
|
||||||
add_gschema_targets("${generic_import_GSCHEMA}")
|
add_gschema_targets("${generic_import_GSCHEMA}")
|
||||||
|
|
||||||
SET_DIST_LIST(generic_import_gschema_DIST CMakeLists.txt org.gnucash.dialogs.import.generic.gschema.xml.in.in)
|
SET_DIST_LIST(generic_import_gschema_DIST CMakeLists.txt org.gnucash.dialogs.import.generic.gschema.xml.in)
|
||||||
|
@ -5,4 +5,4 @@ IF (WITH_OFX)
|
|||||||
add_gschema_targets("${ofx_GSCHEMA}")
|
add_gschema_targets("${ofx_GSCHEMA}")
|
||||||
ENDIF (WITH_OFX)
|
ENDIF (WITH_OFX)
|
||||||
|
|
||||||
SET_DIST_LIST(ofx_gschema_DIST CMakeLists.txt org.gnucash.dialogs.import.ofx.gschema.xml.in.in)
|
SET_DIST_LIST(ofx_gschema_DIST CMakeLists.txt org.gnucash.dialogs.import.ofx.gschema.xml.in)
|
||||||
|
@ -3,4 +3,4 @@ set(qif_imp_GSCHEMA org.gnucash.dialogs.import.qif.gschema.xml)
|
|||||||
|
|
||||||
add_gschema_targets("${qif_imp_GSCHEMA}")
|
add_gschema_targets("${qif_imp_GSCHEMA}")
|
||||||
|
|
||||||
SET_DIST_LIST(qif_import_gschema_DIST CMakeLists.txt org.gnucash.dialogs.import.qif.gschema.xml.in.in)
|
SET_DIST_LIST(qif_import_gschema_DIST CMakeLists.txt org.gnucash.dialogs.import.qif.gschema.xml.in)
|
||||||
|
@ -9,6 +9,8 @@ SET (NEW_LINGUAS as brx doi es_NI kok kok@latin ks mai mni mni@bengali)
|
|||||||
|
|
||||||
SET (ALL_LINGUAS ${TP_LINGUAS} ${GC_LINGUAS} ${NEW_LINGUAS})
|
SET (ALL_LINGUAS ${TP_LINGUAS} ${GC_LINGUAS} ${NEW_LINGUAS})
|
||||||
|
|
||||||
|
file (WRITE LINGUAS "${ALL_LINGUAS}")
|
||||||
|
|
||||||
SET (CATALOGS "")
|
SET (CATALOGS "")
|
||||||
SET (BUILD_CATALOGS "")
|
SET (BUILD_CATALOGS "")
|
||||||
|
|
||||||
@ -18,12 +20,14 @@ IF (${CMAKE_VERSION} VERSION_GREATER 3.1)
|
|||||||
ENDIF()
|
ENDIF()
|
||||||
|
|
||||||
SET(po_SOURCES "")
|
SET(po_SOURCES "")
|
||||||
|
file (WRITE LINGUAS "")
|
||||||
FOREACH(lingua ${ALL_LINGUAS})
|
FOREACH(lingua ${ALL_LINGUAS})
|
||||||
LIST(APPEND po_SOURCES ${lingua}.po)
|
LIST(APPEND po_SOURCES ${lingua}.po)
|
||||||
|
file (APPEND LINGUAS "${lingua} ")
|
||||||
ENDFOREACH()
|
ENDFOREACH()
|
||||||
|
|
||||||
SET_LOCAL_DIST(po_DIST_local ${po_SOURCES} CMakeLists.txt ChangeLog Makevars
|
SET_LOCAL_DIST(po_DIST_local ${po_SOURCES} CMakeLists.txt ChangeLog Makevars
|
||||||
POTFILES.ignore POTFILES.in POTFILES.skip README check-po.cmake gnucash-pot.cmake)
|
POTFILES.ignore POTFILES.in POTFILES.skip README gnucash-pot.cmake)
|
||||||
SET(po_DIST ${po_DIST_local} ${po_glossary_DIST} PARENT_SCOPE)
|
SET(po_DIST ${po_DIST_local} ${po_glossary_DIST} PARENT_SCOPE)
|
||||||
|
|
||||||
FOREACH(lingua ${ALL_LINGUAS})
|
FOREACH(lingua ${ALL_LINGUAS})
|
||||||
@ -71,7 +75,7 @@ FUNCTION(MAKE_GNUCASH_POTFILES)
|
|||||||
# Create a list of candidate translation files
|
# Create a list of candidate translation files
|
||||||
FILE(GLOB_RECURSE FILES_IN RELATIVE ${CMAKE_SOURCE_DIR}
|
FILE(GLOB_RECURSE FILES_IN RELATIVE ${CMAKE_SOURCE_DIR}
|
||||||
${CMAKE_SOURCE_DIR}/*.c ${CMAKE_SOURCE_DIR}/*.cpp ${CMAKE_SOURCE_DIR}/*.glade ${CMAKE_SOURCE_DIR}/*.desktop.in
|
${CMAKE_SOURCE_DIR}/*.c ${CMAKE_SOURCE_DIR}/*.cpp ${CMAKE_SOURCE_DIR}/*.glade ${CMAKE_SOURCE_DIR}/*.desktop.in
|
||||||
${CMAKE_SOURCE_DIR}/*.keys.in ${CMAKE_SOURCE_DIR}/*.gschema.xml.in.in ${CMAKE_SOURCE_DIR}/*.scm)
|
${CMAKE_SOURCE_DIR}/*.keys.in ${CMAKE_SOURCE_DIR}/*.gschema.xml.in ${CMAKE_SOURCE_DIR}/*.scm)
|
||||||
|
|
||||||
# Only consider files in the common, libgnucash, and gnucash/ directories. Also check against list of ignore patterns
|
# Only consider files in the common, libgnucash, and gnucash/ directories. Also check against list of ignore patterns
|
||||||
SET(FILES "")
|
SET(FILES "")
|
||||||
@ -119,7 +123,7 @@ FUNCTION(MAKE_GNUCASH_POTFILES)
|
|||||||
"gnucash/gnome/gnucash.appdata.xml.in"
|
"gnucash/gnome/gnucash.appdata.xml.in"
|
||||||
"gnucash/gnome/gnucash.desktop.in.in"
|
"gnucash/gnome/gnucash.desktop.in.in"
|
||||||
"libgnucash/engine/qofbookslots.h"
|
"libgnucash/engine/qofbookslots.h"
|
||||||
"doc/tip_of_the_day.list.in")
|
"doc/tip_of_the_day.list.c")
|
||||||
|
|
||||||
# Write out the final list.
|
# Write out the final list.
|
||||||
# intltool-update insists that this file be in the source directory. :-(
|
# intltool-update insists that this file be in the source directory. :-(
|
||||||
@ -131,11 +135,6 @@ FUNCTION(MAKE_GNUCASH_POTFILES)
|
|||||||
set(POTFILE_DEPS "")
|
set(POTFILE_DEPS "")
|
||||||
FOREACH(path ${POTFILES})
|
FOREACH(path ${POTFILES})
|
||||||
list(APPEND POTFILE_DEPS ${CMAKE_SOURCE_DIR}/${path})
|
list(APPEND POTFILE_DEPS ${CMAKE_SOURCE_DIR}/${path})
|
||||||
STRING(REGEX MATCH gschema.xml.in.in IS_GSCHEMA ${path})
|
|
||||||
IF(IS_GSCHEMA)
|
|
||||||
# Force parse type for gsettings files
|
|
||||||
SET(path "[type: gettext/gsettings]${path}")
|
|
||||||
ENDIF()
|
|
||||||
FILE(APPEND ${POTFILES_IN_PATH} "${path}\n")
|
FILE(APPEND ${POTFILES_IN_PATH} "${path}\n")
|
||||||
ENDFOREACH()
|
ENDFOREACH()
|
||||||
|
|
||||||
@ -144,36 +143,24 @@ FUNCTION(MAKE_GNUCASH_POTFILES)
|
|||||||
set(gnucash_pot_depends ${POTFILE_DEPS} CACHE INTERNAL "List of files with translatable strings. If any of these change, gnucash.pot should be regenerated")
|
set(gnucash_pot_depends ${POTFILE_DEPS} CACHE INTERNAL "List of files with translatable strings. If any of these change, gnucash.pot should be regenerated")
|
||||||
ENDFUNCTION()
|
ENDFUNCTION()
|
||||||
|
|
||||||
find_program(INTLTOOL_UPDATE NAMES intltool-update)
|
|
||||||
IF (${INTLTOOL_UPDATE} STREQUAL "INTLTOOL_UPDATE-NOTFOUND")
|
|
||||||
MESSAGE(FATAL_ERROR "Can't find the 'intltool-update' program.")
|
|
||||||
ENDIF ()
|
|
||||||
|
|
||||||
IF(BUILDING_FROM_VCS)
|
IF(BUILDING_FROM_VCS)
|
||||||
|
|
||||||
MAKE_GNUCASH_POTFILES()
|
MAKE_GNUCASH_POTFILES()
|
||||||
|
|
||||||
find_program(INTLTOOL_EXTRACT NAMES intltool-extract)
|
|
||||||
find_program(XGETTEXT xgettext)
|
find_program(XGETTEXT xgettext)
|
||||||
configure_file (${CMAKE_CURRENT_SOURCE_DIR}/Makevars
|
configure_file (${CMAKE_CURRENT_SOURCE_DIR}/Makevars
|
||||||
${CMAKE_CURRENT_BINARY_DIR}/Makevars COPYONLY)
|
${CMAKE_CURRENT_BINARY_DIR}/Makevars COPYONLY)
|
||||||
|
|
||||||
IF (${INTLTOOL_EXTRACT} STREQUAL "INTLTOOL_EXTRACT-NOTFOUND")
|
|
||||||
MESSAGE(FATAL_ERROR "Can't find the 'intltool-extract' program.")
|
|
||||||
ENDIF ()
|
|
||||||
|
|
||||||
IF (${XGETTEXT} STREQUAL "XGETTEXT-NOTFOUND")
|
IF (${XGETTEXT} STREQUAL "XGETTEXT-NOTFOUND")
|
||||||
MESSAGE(FATAL_ERROR "Can't find the 'xgettext' program.")
|
MESSAGE(FATAL_ERROR "Can't find the 'xgettext' program.")
|
||||||
ENDIF ()
|
ENDIF ()
|
||||||
|
|
||||||
add_custom_command(OUTPUT gnucash.pot
|
add_custom_command(OUTPUT gnucash.pot
|
||||||
COMMAND ${CMAKE_COMMAND}
|
COMMAND ${CMAKE_COMMAND}
|
||||||
-D INTLTOOL_EXTRACT=${INTLTOOL_EXTRACT}
|
-D TOP_SRC_DIR=${CMAKE_SOURCE_DIR}
|
||||||
-D INTLTOOL_UPDATE=${INTLTOOL_UPDATE}
|
|
||||||
-D PO_SRC_DIR=${CMAKE_CURRENT_SOURCE_DIR}
|
-D PO_SRC_DIR=${CMAKE_CURRENT_SOURCE_DIR}
|
||||||
-D PO_BIN_DIR=${CMAKE_CURRENT_BINARY_DIR}
|
-D PO_BIN_DIR=${CMAKE_CURRENT_BINARY_DIR}
|
||||||
-D PACKAGE=${PACKAGE}
|
-D PACKAGE=${PACKAGE}
|
||||||
-D PERL=${PERL_EXECUTABLE}
|
|
||||||
-D XGETTEXT=${XGETTEXT}
|
-D XGETTEXT=${XGETTEXT}
|
||||||
-P ${CMAKE_CURRENT_SOURCE_DIR}/gnucash-pot.cmake
|
-P ${CMAKE_CURRENT_SOURCE_DIR}/gnucash-pot.cmake
|
||||||
DEPENDS ${gnucash_pot_depends}
|
DEPENDS ${gnucash_pot_depends}
|
||||||
@ -182,13 +169,3 @@ IF(BUILDING_FROM_VCS)
|
|||||||
add_custom_target (pot DEPENDS gnucash.pot)
|
add_custom_target (pot DEPENDS gnucash.pot)
|
||||||
ENDIF()
|
ENDIF()
|
||||||
dist_add_generated (${BUILDING_FROM_VCS} gnucash.pot)
|
dist_add_generated (${BUILDING_FROM_VCS} gnucash.pot)
|
||||||
|
|
||||||
ADD_CUSTOM_TARGET(check-po
|
|
||||||
COMMAND ${CMAKE_COMMAND}
|
|
||||||
-D INTLTOOL_UPDATE=${INTLTOOL_UPDATE}
|
|
||||||
-D PO_DIR=${CMAKE_CURRENT_SOURCE_DIR}
|
|
||||||
-P check-po.cmake
|
|
||||||
WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}
|
|
||||||
)
|
|
||||||
|
|
||||||
add_dependencies(check check-po)
|
|
||||||
|
@ -238,19 +238,19 @@ gnucash/gnome-utils/search-param.c
|
|||||||
gnucash/gnome-utils/tree-view-utils.c
|
gnucash/gnome-utils/tree-view-utils.c
|
||||||
gnucash/gnome-utils/window-main-summarybar.c
|
gnucash/gnome-utils/window-main-summarybar.c
|
||||||
gnucash/gnucash-bin.c
|
gnucash/gnucash-bin.c
|
||||||
[type: gettext/gsettings]gnucash/gschemas/org.gnucash.dialogs.business.gschema.xml.in.in
|
gnucash/gschemas/org.gnucash.dialogs.business.gschema.xml.in
|
||||||
[type: gettext/gsettings]gnucash/gschemas/org.gnucash.dialogs.checkprinting.gschema.xml.in.in
|
gnucash/gschemas/org.gnucash.dialogs.checkprinting.gschema.xml.in
|
||||||
[type: gettext/gsettings]gnucash/gschemas/org.gnucash.dialogs.commodities.gschema.xml.in.in
|
gnucash/gschemas/org.gnucash.dialogs.commodities.gschema.xml.in
|
||||||
[type: gettext/gsettings]gnucash/gschemas/org.gnucash.dialogs.gschema.xml.in.in
|
gnucash/gschemas/org.gnucash.dialogs.gschema.xml.in
|
||||||
[type: gettext/gsettings]gnucash/gschemas/org.gnucash.dialogs.reconcile.gschema.xml.in.in
|
gnucash/gschemas/org.gnucash.dialogs.reconcile.gschema.xml.in
|
||||||
[type: gettext/gsettings]gnucash/gschemas/org.gnucash.dialogs.sxs.gschema.xml.in.in
|
gnucash/gschemas/org.gnucash.dialogs.sxs.gschema.xml.in
|
||||||
[type: gettext/gsettings]gnucash/gschemas/org.gnucash.dialogs.totd.gschema.xml.in.in
|
gnucash/gschemas/org.gnucash.dialogs.totd.gschema.xml.in
|
||||||
[type: gettext/gsettings]gnucash/gschemas/org.gnucash.general.finance-quote.gschema.xml.in.in
|
gnucash/gschemas/org.gnucash.general.finance-quote.gschema.xml.in
|
||||||
[type: gettext/gsettings]gnucash/gschemas/org.gnucash.gschema.xml.in.in
|
gnucash/gschemas/org.gnucash.gschema.xml.in
|
||||||
[type: gettext/gsettings]gnucash/gschemas/org.gnucash.history.gschema.xml.in.in
|
gnucash/gschemas/org.gnucash.history.gschema.xml.in
|
||||||
[type: gettext/gsettings]gnucash/gschemas/org.gnucash.warnings.gschema.xml.in.in
|
gnucash/gschemas/org.gnucash.warnings.gschema.xml.in
|
||||||
[type: gettext/gsettings]gnucash/gschemas/org.gnucash.window.pages.account.tree.gschema.xml.in.in
|
gnucash/gschemas/org.gnucash.window.pages.account.tree.gschema.xml.in
|
||||||
[type: gettext/gsettings]gnucash/gschemas/org.gnucash.window.pages.gschema.xml.in.in
|
gnucash/gschemas/org.gnucash.window.pages.gschema.xml.in
|
||||||
gnucash/html/gnc-html.c
|
gnucash/html/gnc-html.c
|
||||||
gnucash/html/gnc-html-factory.c
|
gnucash/html/gnc-html-factory.c
|
||||||
gnucash/html/gnc-html-history.c
|
gnucash/html/gnc-html-history.c
|
||||||
@ -272,7 +272,7 @@ gnucash/import-export/aqb/gnc-file-aqb-import.c
|
|||||||
gnucash/import-export/aqb/gnc-gwen-gui.c
|
gnucash/import-export/aqb/gnc-gwen-gui.c
|
||||||
gnucash/import-export/aqb/gncmod-aqbanking.c
|
gnucash/import-export/aqb/gncmod-aqbanking.c
|
||||||
gnucash/import-export/aqb/gnc-plugin-aqbanking.c
|
gnucash/import-export/aqb/gnc-plugin-aqbanking.c
|
||||||
[type: gettext/gsettings]gnucash/import-export/aqb/gschemas/org.gnucash.dialogs.import.hbci.gschema.xml.in.in
|
gnucash/import-export/aqb/gschemas/org.gnucash.dialogs.import.hbci.gschema.xml.in
|
||||||
gnucash/import-export/bi-import/dialog-bi-import.c
|
gnucash/import-export/bi-import/dialog-bi-import.c
|
||||||
gnucash/import-export/bi-import/dialog-bi-import-gui.c
|
gnucash/import-export/bi-import/dialog-bi-import-gui.c
|
||||||
gnucash/import-export/bi-import/dialog-bi-import-helper.c
|
gnucash/import-export/bi-import/dialog-bi-import-helper.c
|
||||||
@ -285,7 +285,7 @@ gnucash/import-export/csv-exp/csv-transactions-export.c
|
|||||||
gnucash/import-export/csv-exp/csv-tree-export.c
|
gnucash/import-export/csv-exp/csv-tree-export.c
|
||||||
gnucash/import-export/csv-exp/gncmod-csv-export.c
|
gnucash/import-export/csv-exp/gncmod-csv-export.c
|
||||||
gnucash/import-export/csv-exp/gnc-plugin-csv-export.c
|
gnucash/import-export/csv-exp/gnc-plugin-csv-export.c
|
||||||
[type: gettext/gsettings]gnucash/import-export/csv-exp/gschemas/org.gnucash.dialogs.export.csv.gschema.xml.in.in
|
gnucash/import-export/csv-exp/gschemas/org.gnucash.dialogs.export.csv.gschema.xml.in
|
||||||
gnucash/import-export/csv-imp/assistant-csv-account-import.c
|
gnucash/import-export/csv-imp/assistant-csv-account-import.c
|
||||||
gnucash/import-export/csv-imp/assistant-csv-account-import.glade
|
gnucash/import-export/csv-imp/assistant-csv-account-import.glade
|
||||||
gnucash/import-export/csv-imp/assistant-csv-price-import.cpp
|
gnucash/import-export/csv-imp/assistant-csv-price-import.cpp
|
||||||
@ -308,7 +308,7 @@ gnucash/import-export/csv-imp/gnc-price-props.cpp
|
|||||||
gnucash/import-export/csv-imp/gnc-tokenizer.cpp
|
gnucash/import-export/csv-imp/gnc-tokenizer.cpp
|
||||||
gnucash/import-export/csv-imp/gnc-trans-props.cpp
|
gnucash/import-export/csv-imp/gnc-trans-props.cpp
|
||||||
gnucash/import-export/csv-imp/gnc-tx-import.cpp
|
gnucash/import-export/csv-imp/gnc-tx-import.cpp
|
||||||
[type: gettext/gsettings]gnucash/import-export/csv-imp/gschemas/org.gnucash.dialogs.import.csv.gschema.xml.in.in
|
gnucash/import-export/csv-imp/gschemas/org.gnucash.dialogs.import.csv.gschema.xml.in
|
||||||
gnucash/import-export/customer-import/dialog-customer-import.c
|
gnucash/import-export/customer-import/dialog-customer-import.c
|
||||||
gnucash/import-export/customer-import/dialog-customer-import-gui.c
|
gnucash/import-export/customer-import/dialog-customer-import-gui.c
|
||||||
gnucash/import-export/customer-import/gncmod-customer-import.c
|
gnucash/import-export/customer-import/gncmod-customer-import.c
|
||||||
@ -316,7 +316,7 @@ gnucash/import-export/customer-import/gnc-plugin-customer-import.c
|
|||||||
gnucash/import-export/customer-import/gtkbuilder/dialog-customer-import-gui.glade
|
gnucash/import-export/customer-import/gtkbuilder/dialog-customer-import-gui.glade
|
||||||
gnucash/import-export/dialog-import.glade
|
gnucash/import-export/dialog-import.glade
|
||||||
gnucash/import-export/gncmod-generic-import.c
|
gnucash/import-export/gncmod-generic-import.c
|
||||||
[type: gettext/gsettings]gnucash/import-export/gschemas/org.gnucash.dialogs.import.generic.gschema.xml.in.in
|
gnucash/import-export/gschemas/org.gnucash.dialogs.import.generic.gschema.xml.in
|
||||||
gnucash/import-export/import-account-matcher.c
|
gnucash/import-export/import-account-matcher.c
|
||||||
gnucash/import-export/import-backend.c
|
gnucash/import-export/import-backend.c
|
||||||
gnucash/import-export/import-commodity-matcher.c
|
gnucash/import-export/import-commodity-matcher.c
|
||||||
@ -334,7 +334,7 @@ gnucash/import-export/ofx/gncmod-ofx-import.c
|
|||||||
gnucash/import-export/ofx/gnc-ofx-import.c
|
gnucash/import-export/ofx/gnc-ofx-import.c
|
||||||
gnucash/import-export/ofx/gnc-ofx-kvp.c
|
gnucash/import-export/ofx/gnc-ofx-kvp.c
|
||||||
gnucash/import-export/ofx/gnc-plugin-ofx.c
|
gnucash/import-export/ofx/gnc-plugin-ofx.c
|
||||||
[type: gettext/gsettings]gnucash/import-export/ofx/gschemas/org.gnucash.dialogs.import.ofx.gschema.xml.in.in
|
gnucash/import-export/ofx/gschemas/org.gnucash.dialogs.import.ofx.gschema.xml.in
|
||||||
gnucash/import-export/qif/qif-context.c
|
gnucash/import-export/qif/qif-context.c
|
||||||
gnucash/import-export/qif/qif-file.c
|
gnucash/import-export/qif/qif-file.c
|
||||||
gnucash/import-export/qif/qif-objects.c
|
gnucash/import-export/qif/qif-objects.c
|
||||||
@ -344,7 +344,7 @@ gnucash/import-export/qif-imp/dialog-account-picker.c
|
|||||||
gnucash/import-export/qif-imp/dialog-account-picker.glade
|
gnucash/import-export/qif-imp/dialog-account-picker.glade
|
||||||
gnucash/import-export/qif-imp/gncmod-qif-import.c
|
gnucash/import-export/qif-imp/gncmod-qif-import.c
|
||||||
gnucash/import-export/qif-imp/gnc-plugin-qif-import.c
|
gnucash/import-export/qif-imp/gnc-plugin-qif-import.c
|
||||||
[type: gettext/gsettings]gnucash/import-export/qif-imp/gschemas/org.gnucash.dialogs.import.qif.gschema.xml.in.in
|
gnucash/import-export/qif-imp/gschemas/org.gnucash.dialogs.import.qif.gschema.xml.in
|
||||||
gnucash/import-export/qif-imp/qif-dialog-utils.scm
|
gnucash/import-export/qif-imp/qif-dialog-utils.scm
|
||||||
gnucash/import-export/qif-imp/qif-file.scm
|
gnucash/import-export/qif-imp/qif-file.scm
|
||||||
gnucash/import-export/qif-imp/qif-guess-map.scm
|
gnucash/import-export/qif-imp/qif-guess-map.scm
|
||||||
@ -707,4 +707,4 @@ libgnucash/tax/us/us.scm
|
|||||||
gnucash/gnome/gnucash.appdata.xml.in
|
gnucash/gnome/gnucash.appdata.xml.in
|
||||||
gnucash/gnome/gnucash.desktop.in.in
|
gnucash/gnome/gnucash.desktop.in.in
|
||||||
libgnucash/engine/qofbookslots.h
|
libgnucash/engine/qofbookslots.h
|
||||||
doc/tip_of_the_day.list.in
|
doc/tip_of_the_day.list.c
|
||||||
|
@ -1,23 +0,0 @@
|
|||||||
|
|
||||||
# Run intltool-update -m to check for missing files in POTFILES.in
|
|
||||||
# We detect failure by looking for the presence of a 'missing' file.
|
|
||||||
|
|
||||||
# Intltool returns a zero status whether or not the check failed.
|
|
||||||
|
|
||||||
FILE(REMOVE ${PO_DIR}/missing)
|
|
||||||
IF (${CMAKE_VERSION} VERSION_GREATER 3.1)
|
|
||||||
EXECUTE_PROCESS(
|
|
||||||
COMMAND ${CMAKE_COMMAND} -E env ${INTLTOOL_UPDATE} -m
|
|
||||||
WORKING_DIRECTORY ${PO_DIR}
|
|
||||||
)
|
|
||||||
ELSE()
|
|
||||||
EXECUTE_PROCESS(
|
|
||||||
COMMAND ${INTLTOOL_UPDATE} -m
|
|
||||||
WORKING_DIRECTORY ${PO_DIR}
|
|
||||||
RESULT_VARIABLE UPDATE_RESULT
|
|
||||||
)
|
|
||||||
MESSAGE("UPDATE_RESULT = ${UPDATE_RESULT}")
|
|
||||||
ENDIF()
|
|
||||||
IF (EXISTS ${PO_DIR}/missing)
|
|
||||||
MESSAGE(FATAL_ERROR "POTFILES.in is missing files. See 'missing' in ${PO_DIR}")
|
|
||||||
ENDIF()
|
|
@ -1,13 +1,32 @@
|
|||||||
# Note: the set commands below can be integrated in the execute process
|
|
||||||
# the day we require cmake > 3.1
|
|
||||||
# The command would then become
|
|
||||||
# COMMAND {CMAKE_COMMAND} -E env INTLTOOL_EXTRACT=${INTLTOOL_EXTRACT} .... ${PERL} ${INTLTOOL_UPDATE} ....
|
|
||||||
|
|
||||||
set(ENV{INTLTOOL_EXTRACT} ${INTLTOOL_EXTRACT})
|
|
||||||
set(ENV{XGETTEXT} ${XGETTEXT})
|
|
||||||
set(ENV{srcdir} ${PO_SRC_DIR})
|
|
||||||
execute_process(
|
execute_process(
|
||||||
COMMAND ${PERL} ${INTLTOOL_UPDATE} -x --gettext-package ${PACKAGE} --pot
|
COMMAND ${XGETTEXT} --add-comments
|
||||||
|
--directory=${TOP_SRC_DIR}
|
||||||
|
--default-domain=${PACKAGE}
|
||||||
|
--output=${PACKAGE}.pot
|
||||||
|
--files-from=${PO_SRC_DIR}/POTFILES.in
|
||||||
|
--from-code=UTF-8
|
||||||
|
--flag=g_strdup_printf:1:c-format
|
||||||
|
--flag=g_string_printf:2:c-format
|
||||||
|
--flag=g_string_append_printf:2:c-format
|
||||||
|
--flag=g_error_new:3:c-format
|
||||||
|
--flag=g_set_error:4:c-format
|
||||||
|
--flag=g_markup_printf_escaped:1:c-format
|
||||||
|
--flag=g_log:3:c-format
|
||||||
|
--flag=g_print:1:c-format
|
||||||
|
--flag=g_printerr:1:c-format
|
||||||
|
--flag=g_printf:1:c-format
|
||||||
|
--flag=g_fprintf:2:c-format
|
||||||
|
--flag=g_sprintf:2:c-format
|
||||||
|
--flag=g_snprintf:3:c-format
|
||||||
|
--flag=g_scanner_error:2:c-format
|
||||||
|
--flag=g_scanner_warn:2:c-format
|
||||||
|
--keyword=_
|
||||||
|
--keyword=N_
|
||||||
|
--keyword=Q_
|
||||||
|
--keyword=translate:1,1t
|
||||||
|
--keyword=translate:1c,2,2t
|
||||||
|
--keyword=translate:1,2,3t
|
||||||
|
--keyword=translate:1c,2,3,4t
|
||||||
WORKING_DIRECTORY ${PO_BIN_DIR}
|
WORKING_DIRECTORY ${PO_BIN_DIR}
|
||||||
RESULT_VARIABLE GNUCASH_POT_RESULT
|
RESULT_VARIABLE GNUCASH_POT_RESULT
|
||||||
)
|
)
|
||||||
|
Loading…
Reference in New Issue
Block a user