Commit Graph

53 Commits

Author SHA1 Message Date
Frank H. Ellenberger
7f64cceeea Merge L10N_et into maint ...
Fix the copyright line and update from a fresh pot:
487 translated messages, 11 fuzzy translations, 5031 untranslated
messages.
2020-09-12 00:55:13 +02:00
triyanwn
bc7533c6f1 Indonesian translation for GnuCash 2020-09-05 11:43:46 +07:00
Frank H. Ellenberger
d9b652de45 L10N:et: Create Estonian translation
Only filled with common parts from GOffice and GTK
2020-08-29 06:18:55 +02:00
Geert Janssens
809ea8dbf9 Mark Dutch translation as non-TP managed 2020-08-18 15:30:03 +02:00
Frank H. Ellenberger
5bf009a9b5 I18N: update LINGUAS
TP has no longer an az team, all NEW_LINGUAS were reported.
2020-07-05 19:34:01 +02:00
c-holtermann
41dc6ddbe2 implement gettext localization for python
make gnc_path_get_localedir() and GETTEXT_PACKAGE available for python
to access locales. Import gettext module to provide _ as translator
method. Provide null _-method returning english text in case of missing gettext.
Make a lot of messages translatable by adding _-method. Include python
files to create .pot-files.
2020-05-28 18:41:34 +02:00
John Ralls
c12ae077f7 Exclude mock files from translation. 2020-05-24 13:45:32 -07:00
Geert Janssens
8243496ed0 Rework our gettext tests
- only abort configuration if gettext is older than 0.18.1 (required for string extraction from scheme files)
- otherwise always continue but disable a few other build steps depending on the gettext version
- use feature variables to more clearly convey what is enabled or disabled
2020-02-08 13:19:23 +01:00
Geert Janssens
90e95ba8ef CMake - remove parameter repetition in else() and endif() statements - part 2
This follows Professional CMake's recommended practises
I missed plenty of these in my first commit. This one should fix
these remaining occurrences.
2020-02-06 16:16:36 +01:00
Geert Janssens
d8a304c2c9 Housekeeping - reduce the number of PACKAGE and VERSION related cmake variables
This starts by setting the gnucash version number in the 'project' call.
This will result in a number of variables set by cmake. The remainder
of this commit is to reuse the auto-generated
PROJECT_NAME, PROJECT_VERSION, PROJECT_VERSION_MAJOR
PROJECT_VERSION_MINOR, PROJECT_VERSION_PATCH and PROJECT_VERSION_TWEAK
instead of all the various instances of PACKAGE, GNUCASH_MAJOR_VERSION
and so on.

One parameter is worth mentioning - GETTEXT_PACKAGE
GnuCash is not using this directly (any more) but it has to be set before
including gi18n-lib.h.
2020-01-17 18:15:27 +01:00
Christian Stimming
d9345c1691 Minor translation improvements
- Glossary needs "aging" as term
- Header gnc-commodity.h contains translatable strings
2019-12-30 00:39:11 +01:00
Geert Janssens
54dae108a6 Properly mark the renamed appdata.xml.in.in for translation 2019-08-26 19:01:38 +02:00
Geert Janssens
8447f42674 Bug 797126 - It is annoying to run cmake to get an updated mo file
Add missing dependency in order to make the po-gmo and po-gmo-build targets acually work.
2019-05-27 14:50:36 +02:00
Geert Janssens
b7479e8fb0 Bump minimum cmake version to 3.5
This version is available for all supported platforms and distros
(CentOS can have a version via EPEL, which is required anyway)

Advantages:
- one cmake version for all platforms
- we can drop all conditions based on cmake version
2019-05-25 12:04:51 +02:00
Frank H. Ellenberger
b4ae45d556 Drop po/ChangeLog
It is no longer required by make dist.
Probably it was a requirement of IntlTool.
2019-04-26 18:13:27 +02:00
Frank H. Ellenberger
e3e11afcb5 [L12N] Romanian is now maintained by Translation Project
https://lists.gnucash.org/pipermail/gnucash-devel/2019-April/043701.html
2019-04-16 20:06:02 +02:00
Frank H. Ellenberger
33a376bddf add hr.po's to CMakeLists.txt 2019-02-22 22:37:14 +01:00
Geert Janssens
67174dd0b1 Prevent temporary editor files from being picked up for POTFILES.in generation
Aparently cmake's file glob also picks up hidden files and doesn't have
an easy way to avoid that.
2018-11-04 13:07:36 +01:00
Frank H. Ellenberger
295f8e38d8 Update LINGUAS explanation to the last version we had in autotools 2018-10-17 07:33:38 +02:00
Geert Janssens
a9f35ed7ae Lowercase cmake commands
A huge bikeshed fest but it distracted me enough to do it anyway.
2018-05-03 23:18:15 +02:00
Geert Janssens
13e6880b34 Bug 745941 - Review of po Headers / make pot 2018-03-01 18:31:49 +01:00
Geert Janssens
f111e5958d Simplify POTFILES.in generation
As part of this also:
- Drop POTFILIES.ignore. Relevant lines have been moved to POTFILES.skip
- Remove skip lines for scm file links. With intltool out of the way these are never picked up any more.
2018-02-28 13:40:20 +01:00
Geert Janssens
02c69a7933 Handle situation where gettext 0.19.6 is not available
By default we require gettext 0.19.6 as this is needed to generate a translated version of gnucash.desktop and gnucash.appdata.xml.
However this version is not available on some platforms (most notably our own ubuntu 14.04LTS travis instance).
By setting ALLOW_OLD_GETTEXT=ON, the build configuration falls back to generating untranslated versions of said files instead.
2018-02-27 22:38:27 +01:00
Geert Janssens
ba799feb2a 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.
2018-02-27 22:30:06 +01:00
Geert Janssens
61a21d12c6 Look for user editable config files in gnc_userconfig_dir instead of gnc_userdata_dir
At present these are
- log.conf
- config-user.scm (previously config.user-2.0)

Implement one-time migration of these files to the proper directory if they previously exist
Look for a log.conf file in gnc_userconfig_dir instead of gnc_userdata_dir

Note this commit also uses boost::locale::translate for the first time.
We may need to fine-tune our use, but in the current state strings marked
for translation using that function are already picked up for gnucash.pot.
2018-02-24 20:39:26 +01:00
John Ralls
f4965ae2ac Move direct check dependencies to the originating CMakeLists.txt.
Removing transitive dependencies from being declared direct.
2018-02-18 22:16:27 -08:00
Geert Janssens
ff24970f5f Add GENERATE_SWIG_WRAPPERS option to control the generation of swig wrappers independently of whether we're building from git
The swig wrappers don't really depend on git (but rather on swig) and there can be
situations the builder wants to generate the wrappers also from a tar ball.
2018-01-31 16:16:59 +01:00
Geert Janssens
99ebeb6b5d gnucash.pot target improvements
- add simple target called 'pot' so translators can run 'make pot'
- make gnucash.pot depend on all files with translatable strings. So whenever
  one of these files is changed the potfile will automatically be regenerated
  (if the current target depends on it, like 'pot' or 'dist')

Note the default target (make without anything) does not depend on gnucash.pot
so the potfile will not automatically be (re)generated when building that target.
2018-01-29 21:51:38 +01:00
Geert Janssens
4317d8a8f6 Improve handling of generated distributable files
- the two dist_add_... macros now both take a list of file names
as argument so more files can be added at once to the dist tarball.
- dist_add_generated now creates the right target by itself. There's
  no need to pass one any more
- make the swig generated *.py module files explicit output files
- change a couple of custom_targets into custom_commands. The only
  reason they were defined as targets was to ensure they got built
  before the dist tarball. This is now properly handled by the
  dist_add_... macros.
- correctly handle dependency on swig-runtime.h (using OBJECT_DEPENDS
  was not the way to do it according to that property's help page)
2018-01-29 19:46:44 +01:00
Geert Janssens
3dff4e5211 Fix make dist on a clean checkout
cmake with unix makefiles fails to resolve dist dependencies
added from COPY_FROM_BUILD if these dependencies aren't built yet.

This commit replaces the COPY_FROM_BUILD based logic with two new functions
'dist_add_configured' and 'dist_add_generated' to indicate which files should
be included in the dist tarball. The latter also adds a target level dependency
to the dist tarball custom command. Hence the former should
be used for files that get generated during a cmake run while the latter
should be used for files generated as the result of a 'make/ninja-build' run
(like files for which an add_custom_command rule exists).

Note: this commit also temporarily disables the dist target when building
from a tarball (and hence it won't be tested in distcheck either). This
will be handled in a future commit.
2018-01-29 19:46:44 +01:00
Geert Janssens
1258a2adfd Make potfile generation a custom target, and make the dist target depend on it 2018-01-29 19:46:44 +01:00
Geert Janssens
85bfbd8e82 Some minor cleanups after the autotools removal
This includes removal of the now unused make-gnucash-potfiles.in,
checking for CMakeLists.txt rather than Makefile.am in gnc-vcs-info,
upating the HACKING file,
and generally updating references to autotools.

I have kept "Makefile.*" exclude patterns in our CMakeLists.txt files
because they may still be lingering in the source directory from
previous autogen.sh runs. At some point these should probably be
removed as well still, together with the gitignore references to them.
2018-01-26 18:22:48 +01:00
John Ralls
9b0a8723a4 More GNUInstallDirs path fixes. 2017-12-01 13:56:52 -08:00
Geert Janssens
545b24fe97 Merge branch maint into unstable
Resolved conflicts:
2017-10-05 16:29:36 +02:00
Geert Janssens
e56cb37813 Additional changes to use commit date rather than build date
This effectively replaces the use of GNUCASH_BUILD_DATE with GNUCASH_SCM_REV_DATE.
The latter is extracted from the current commit if building from some kind of vcs
(currently only works correctly for svn and git). The info extracted while building
from vcs is then also added to the dist tarball so it's available when building
from tarball as well (via the file libgnucash/core-utils/gnc-vcs-info.h).

The same date is also used to set the date in gnucash' man page document.
A practical detail: I have changed the substitution variables in the man page template
from @- -@ to ${} so we could leverage CONFIGURE_FILE in cmake. The necessary
related adjustments have also been made to Makefile.am's substitution rules.
2017-10-05 15:51:55 +02:00
Geert Janssens
7650d76582 Fix gnucash.pot generation from cmake build.
intltool-update should be run from the build directory, not the source directory.
If run from the source directory it will omit glade messages that have a context attribute
so all msgids with a msgctxt comment would be missing.
2017-10-03 22:56:35 +02:00
John Ralls
1dea835c31 Re-enable generation of POTFILES.in
With a hack to get the right line-endings on Windows.
2017-09-12 14:28:05 -07:00
John Ralls
ac86ca949f Disable regeneration of POTFILES.in
On Windows CMake converts "\n" to CRLF, which causes xgettext to
mangle paths with [type: gettext/gsettings] in front of them and
also dirties the source directory with uncommittable changes.
The autotools build doesn't regenerate POTFILES.in and we've historically
maintained it by hand.
2017-09-11 12:18:57 -07:00
Geert Janssens
22b11427cb Merge branch 'maint' 2017-09-09 14:09:13 +02:00
Rob Gowin
739ce35f6a Fix problems that occur when running out of CMake build dir 2017-09-09 14:08:28 +02:00
John Ralls
e1ba2ed4bd Append to string the pre-cmake-3.4 way. 2017-09-06 14:51:26 -07:00
Geert Janssens
f28896fbde Fix cmake run on Ubuntu 16.04 (and possibly other distros)
Apparently that platform trips over a missing newline at the end of the generated POTFILES.in.in file.
Adding one allows cmake to complete configuration and appears to be fine on Fedora as well
(although it worked fine without the newline too).

Thanks go to Michael Jung <gnucash-devel@mailinglists.mjung.org> for reporting this and proposing the fix.
2017-08-21 16:41:08 +02:00
Geert Janssens
f943ba61ae Rename directory for code from external projects
'lib' is also being used by the cmake build, so there was a
theoretical risk for file conflicts. The new name is 'borrowed'.
2017-08-17 15:25:49 +02:00
Geert Janssens
83d14e1c1c Restructure the src directory
It is split into
- /libgnucash (for the non-gui bits)
- /gnucash (for the gui)
- /common (misc source files used by both)
- /bindings (currently only holds python bindings)

This is the first step in restructuring the code. It will need much
more fine tuning later on.
2017-08-10 18:45:00 +02:00
Geert Janssens
9de9f5362e Drop the cutecash experiment and the gtkmm optional bindings
These are currently unmaintained, cutecash us based on the obsolete qt4
and gtkmm is only used by cutecash. Whenever someone wishes to revive
this experiment it can be recovered from git history and be brought
into a separate repository.
2017-08-09 16:09:32 +02:00
Geert Janssens
8687dfb1da Merge qof directory into engine
They are both about handling core gnucash objects. Qof was once split out
in an attempt to make it a separate library. This hasn't worked out so there's
no good reason any more to keep this artificial separation.

A few considerations:
- The qof tests are merged into the engine test directory but they are kept as
  a separate test entity for now. Several assumptions made in the qof tests
  are no longer valid in the context of the engine. (For example if the
  pricedb test is added in the same test executable as the qofbook test,
  the book creation test fails because it now has 2 collections (pricedb and
  book) instead of only one. There are plenty of others like this so merging
  the tests needs more careful review and is perhaps best done while converting
  to c++/Google test.
- I had to use unique names for the MockBackend classes because apparently the tests were
  using a MockClass from another file in the cmake builds, causing several
  tests to fail.
2017-08-09 15:37:39 +02:00
Geert Janssens
16b98cc5a4 Tweak cmake/autotools so they produce the same output for POTFILES.in 2017-08-03 18:19:06 +02:00
John Ralls
c8402ad62e Merge CMake Distcheck from 'maint'.
Conflicts:
	CMakeLists.txt
	src/app-utils/CMakeLists.txt
	src/backend/sql/test/CMakeLists.txt
	src/backend/xml/test/CMakeLists.txt
	src/gnome-utils/CMakeLists.txt
	src/import-export/aqb/CMakeLists.txt
	src/import-export/csv-imp/CMakeLists.txt
	src/import-export/csv-imp/test/Makefile.am
	src/import-export/ofx/CMakeLists.txt
	src/import-export/qif-imp/CMakeLists.txt
	src/libqof/CMakeLists.txt
	src/register/ledger-core/CMakeLists.txt
	src/register/register-core/CMakeLists.txt
	src/register/register-gnome/CMakeLists.txt
	src/report/business-reports/CMakeLists.txt
	src/report/locale-specific/us/CMakeLists.txt
	src/report/report-gnome/CMakeLists.txt
	src/report/standard-reports/CMakeLists.txt
	src/report/stylesheets/CMakeLists.txt
2017-07-04 18:36:35 -07:00
Rob Gowin
6b14dc5b59 Implement 'dist', 'distcheck' and 'uninstall' targets for CMake 2017-07-03 16:15:17 -07:00
RobGowin
ed8e79c671 [cmake] Reflect commit db0fd2 (Replace the TP pt.po ...) in CMake build. 2016-01-22 09:46:00 -06:00