Commit graph

1329 commits

Author SHA1 Message Date
Patrick Ohly 881cc77be3 more build dependencies fixes
We do depend on libsoup-2.4 after all: the API and ABI
changed considerably between 2.2->2.4.

Building D-Bus service depends on xsltproc. Added
to README and added an AC_ERROR in configure, to avoid
compile errors later on.
2009-07-14 11:05:42 +02:00
Chen Congwu 166280482c Use raw type for updated item, buggzilla #4282 2009-07-14 10:36:50 +02:00
Chen Congwu 4157ab9b10 Testing: fix a typo, bugzilla #2421 2009-07-14 10:36:34 +02:00
Jussi Kukkonen 668a8dbf79 improve translator docs
Partly fixes #4184
2009-07-14 10:35:57 +02:00
Jussi Kukkonen 7a44a3210d do not set password if user hasn't defined one in UI
when user sets password in UI, "-" gets written to the config
as password (meaning AskPassword() should be used). This
shouldn't be done if the user does not modify the password in UI:
this way cli client and gtk ui can both be used for same configs.

Fixes #4217
2009-07-14 10:35:46 +02:00
Jussi Kukkonen 523efc39c0 set the "need connection to sync" label width
GtkLabel cannot wrap at container width: This commit requests
a specific width for the label.

Fixes #4270
2009-07-14 10:35:39 +02:00
Jussi Kukkonen b331be408d don't use username/password from template in UI
Should not use the username/password from syncevolution default
template when creating new service: The hint string is not
translatable.

Fixes #4273
2009-07-14 10:35:32 +02:00
Patrick Ohly 76e190ebaf testing: avoid running Retry and Suspend tests for ScheduleWorld and Funambol
These tests are both slow and tend to fail with these servers
because of deficiencies in the servers. Disabled these tests
as discussed in Bugzilla #4282.
2009-07-14 10:02:16 +02:00
Patrick Ohly 2dbb186ab2 testing: run distcheck with building GUI
distcheck is useful to ensure that all files are distributed,
the result builds and cleans up properly. Doing this with
building of the GUI is important to avoid surprises during
packaging.
2009-07-14 10:02:16 +02:00
Patrick Ohly af682ad395 testing: added suppressions
Added some more suppressions necessary for Debian Lenny,
Evolution 2.22, valgrind 3.3.1.
2009-07-14 08:50:49 +02:00
Patrick Ohly bc5b7aaff1 build fixes
Several files created as part of the GUI build were not
properly removed during "make clean". Found with distcheck
when using DISTCHECK_CONFIGURE_FLAGS=--enable-gui

distcheck also complained about an untranslated .xml file
that it found after building the GUI. The .xml is
generated from .glade, which is translated, so the .xml
file can be ignored via POTFILES.skip.
2009-07-14 08:47:37 +02:00
Patrick Ohly 975290fa17 README: updated information on required packages 2009-07-13 18:31:48 +02:00
Patrick Ohly c602de1c3e testing: skip certain tests by listing them in CLIENT_TEST_SKIP
The only way that I found not to execute a test was not to register
it in CPPUnit. FilterTest() does this by replacing a valid test
or test group with a dummy one, SkipTest, which just prints the
test name and that it is skipped.

Registering tests has to be intercepted at multiple levels:
- CPPUNIT_TEST in test suites
- ADD_TEST in ClientTest
- addTest in ClientTest

Not currently intercepted are complete test suites (CPPUNIT_TEST_SUITE).

The main purpose of this patch is to avoid running the time consuming
suspend and interrupt tests, but this feature might also be useful for
other tests, which is why it was implemented in a more general way.
2009-07-13 18:31:48 +02:00
Patrick Ohly 8c3157d93f testing: ignore EvolutionCalendarTest::testOpenDefaultMemo failure
This is currently broken because opening the default system
addressbook depends on e_cal_new_system_memos(), which is
not available in all Evolution versions.

It could be added, but first we should sort out issue #3732.
2009-07-13 15:30:56 +02:00
Patrick Ohly 53573ba030 testing: enable ical20 and itodo20 for Funambol testing 2009-07-13 15:29:22 +02:00
Patrick Ohly b7f06f02b6 sync.desktop: fixed "make dist" after recent rename
The file which has to be distributed is "sync.desktop.in" now,
not "sync.desktop".
2009-07-13 14:32:10 +02:00
Patrick Ohly adeeb3330c autgen.sh: wipe out old files before recreating them
The main reason for this is that libtoolize gets confused when it
finds files from a more recent libtool, which can happen when
running autogen.sh on one distro and then again on an older one,
using the same source directory.
2009-07-13 12:55:21 +02:00
Patrick Ohly 2a6617fbd0 LogRedirect: fixed compiler warning
gcc on Debian Lenny (incorrectly) warned about an uninitialized
variable. Initialized the variable to keep the compiler happy.
2009-07-13 11:30:01 +02:00
Patrick Ohly f9da1b8f84 HTTPS transport: added SSL certificate checking
- when libsoup is used (as on Moblin), the configure script sets
  a default search for the SSLServerCertificates option which works
  on Debian and Red Hat:
  /etc/ssl/certs/ca-certificates.crt:/usr/share/ssl/certs/ca-bundle.crt
- with libcurl the library's own default is used; SSLServerCertificates
  is empty, but can be set to override the default
- libsoup enables checking when either SSLVerifyServer or SSLVerifyHost
  is on (does not support more control over checking), refuses to work
  if no CA certificates file was found
- libcurl supports both strict checking (both options on) and less
  strict checking (only check certificate, but not hostname)
2009-07-10 13:44:42 +02:00
Patrick Ohly 8dcce52419 testing: extended valgrind suppression rules
Did real sync tests (ical20 + vcard30 testItems) with Ubuntu 8.04,
valgrind valgrind-3.4.1.SVN-9098-1883, 64 bit mode. Some issues in
libsynthesis could be fixed, others (like writing uninitialized
data into binfiles) hopefully can be ignored.
2009-07-10 13:14:07 +02:00
Patrick Ohly 014c86d625 EvolutionSyncSource: memory handling
First, there was a memory leak in EvolutionSyncSource::nextItem().
Second, the item constructed there needlessly was filled with the
item content even if the Synthesis engine only needed the UID.
2009-07-10 11:48:33 +02:00
Patrick Ohly 5039b323d7 Synthesis bridge: fixed leak
From valgrind:
==27587== 4 bytes in 4 blocks are definitely lost in loss record 1 of 47
==27587==    at 0x4C232CB: malloc (vg_replace_malloc.c:207)
==27587==    by 0x6ED017: StrAllocN (SDK_util.c:145)
==27587==    by 0x6ED065: StrAlloc (SDK_util.c:154)
==27587==    by 0x67D421: SyncEvolution_ReadNextItemAsKey (SynthesisDBPlugin.cpp:623)
==27587==    by 0x793603: sysync::TDB_Api::ReadNextItemAsKey(sysync::TDB_Api_ItemID&, sysync::KeyType*, int&, bool) (dbapi.cpp:1705)

The leak occurs because our caller ignores the item ID in the EOF case.
The bridge used to return a dup of the empty luid. Now it returns NULL
for all empty luids.
2009-07-10 10:42:25 +02:00
Patrick Ohly 87685d59f5 fixed compile error due to missing header 2009-07-10 08:43:37 +02:00
Patrick Ohly 06de3dc6e5 logging: catch more redirected output when shutting down
Catch fatal signals (SIGSEGV, SIGABRT, SIGBUS) and in the signal
handler, flush and process output.

Flushing is done each time redirection is removed and thus
also catches output that is pending in either C or C++ output
streams during a normal application shutdown.

The abort-redirect test program covers such a scenario. It does
a double free, which depending on libc causes a segfault or
error message. The source is in "test" (like the rest of the
test programs) while the binary is built with "make abort-redirect"
in "src". It would be nicer if the test folder was a subdirectory of
src and wouldn't require its own Makefile, but that's a different issues...

Note that glib's double free report is written to the console
regardless whether stdout/stderr redirection is enabled. It seems
that glibc does not use FDs 1 or 2 for that, redirecting them in
the shell has no effect either. Catching the signal and flushing
is useful nevertheless.
2009-07-10 08:43:37 +02:00
Patrick Ohly 50f95180b5 logging: set SYNCEVOLUTION_DEBUG to disable redirection
The environment variable SYNCEVOLUTION_DEBUG is checked by
LogRedirect itself (instead of in its caller) so that all
users of the class behave identically. The value of the variable
currently doesn't matter. Later it might also be used to enable
or disable specific debugging aspects.
2009-07-10 08:43:37 +02:00
Patrick Ohly 30fc2561a2 logging: cleaned up source
Use macro names instead of 1 and 2 numbers.
Added more comments explaining the code.
2009-07-10 08:43:37 +02:00
Patrick Ohly 3d706cb5ca logging: enabled redirecting of stderr for command line (Bugzilla #1333)
glib messages are recognized and logged at DEV level with a "glib" prefix.
Other, unclassified stderr messages use DEBUG and "stderr" prefix. The
Synthesis HTML log currently ignores the prefix, though.
2009-07-10 08:43:37 +02:00
Patrick Ohly e93f4c0423 logging: intercept stdout and stderr (Buzilla #1333)
Added a LogRedirect class which intercepts file descriptors
1 and 2 and channels the data through either a UDP or Unix Domain
datagram socket (UDP being the default, see patch) into the
normal log.

EvolutionSyncClient has to call the parent logger instead of
creating its own LogStdout to get messages to the user.

Currently LogRedirect is not actually used, because it is
a bit too effective (intercepts much of the normal syncevolution
output) and that output is split into different messages (cout
does lots of small writes).
2009-07-10 08:43:37 +02:00
Patrick Ohly 3d55c62ec9 logging: pass all available information to new (and tentative) Synthesis call (Bugzilla #3474)
The SyncEvolution debug levels are translated to "hot" messages (WARNING, INFO,
appear as bold in HTML) and "error" messages (ERROR, in red). DEV, DEBUG are
normal log lines.

The other information is not currently used by the engine.
2009-07-10 08:43:36 +02:00
Patrick Ohly d288278c1e logging: write a single sysync_linux.html log (Bugzilla #3474)
client.log is gone completely. All of the messages written to that
file now also appear in the .html log. The Synthesis engine is told
to write just one log file for global events and the session, using
the new <logsessionstoglobal> option.

The way logging works now is that as soon as possible, SyncEvolution
creates a Synthesis engine without datastores but with correct debug log
settings. Latter that engine is re-initialized with a more complete
XML config which also defines datastores.

The LogDir class implements the SyncEvolution logging base class
and registers itself as the the active logger. It prints to stdout
out and in addition, also into the Synthesis log if one is currently
available via the EvolutionSyncClient.
2009-07-10 08:43:36 +02:00
Patrick Ohly b89a3fe077 Merge commit 'origin/moblin-transifex' 2009-07-09 15:10:03 +02:00
Patrick Ohly b6339214a3 configure: --enable-gui implies --enable-dbus-service, docs
Compiling the GUI only works if the dbus library was built first,
so changed the default of --enable-dbus-service to "yes" if the GUI
is enabled. Added error check for conflicting configure options.

Documented dependency on GNOME keyring.
2009-07-09 15:05:19 +02:00
Patrick Ohly b6230cf43b translation: install localized version of sync.desktop (Bugzilla #4133)
Install a translated sync.desktop derived from a sync.desktop.in.
The two strings are marked with an underscore; somehow they are already
translated even though the sync.desktop file was not listed in po/POTFILES.in.
2009-07-09 15:00:08 +02:00
Patrick Ohly 7364e24ac7 bumped version (0.8.1+0.9+beta2+20090709) and added 0.9 beta 3 NEWS 2009-07-09 14:14:22 +02:00
Patrick Ohly c6c1a59fb7 testing: updated valgrind regression rules
Tested with local tests (Client::Source SyncEvolution), valgrind 3.4.1.SVN-9098-1883,
Evolution 2.22.3.1, on Ubuntu 8.04 in 64 bit mode. Some stack backtraces were
slightly different, some problems are new. None seem to be caused by us.
2009-07-09 13:49:32 +02:00
Patrick Ohly 00d46e1870 testing: minor improvements for patching test cases
First, fabricate a dummy unified diff header to keep "patch" happy.
It worked before, but printed a warning.

Second, make testcase2patch depend on generating the patched files
first. Avoids potential problems in parallel build.
2009-07-09 12:12:16 +02:00
Patrick Ohly a49bd48873 test/testcases/README: fixed typo (.ics -> .tem) 2009-07-09 12:00:58 +02:00
Patrick Ohly e9e8ad72fb testing: better handling of test case cases (Bugzilla #2421)
This patch fully automates all work when running make inside the
src directory. It achieves that by not letting make check dependencies.
Instead shell commands check what needs to be updated. By using
touch with the patched file as reference, the regenerated patch
is never newer than it, thus cycles of repeatedly writing files
is avoided.

One drawback is that client-test is needlessly rebuilt, because
it now depends on a phony target. This is not optimal, but better
than not rebuilding files that have to be rebuild, as before.
2009-07-09 10:44:58 +02:00
Jussi Kukkonen 5e70fe896f really fix build in src/dbus/interfaces
forgot to add syncevo-marshal.list to EXTRA_DIST
2009-07-09 10:40:00 +02:00
Jussi Kukkonen dc750a5fa8 use ConsumerReady flag in dbus api and UI
support isConsumerReady in dbus api (GetServers, GetTemplates
and also in the options in GetServerConfig). Use the flag in
sync-ui to hide non-ready templates.

Fix #3336
2009-07-09 10:40:00 +02:00
Jussi Kukkonen fe067595a5 fix build: don't remove syncevo-marshal.list on clean 2009-07-09 10:40:00 +02:00
Patrick Ohly 5ce8bca59a configuration: added "ConsumerReady" option
A property of server template configs. True if the server is
ready for use by "normal" users (everyone can get an account
and some kind of support, we have tested the server well
enough, ...).

Currently the ScheduleWorld and Funambol configs qualify.
Synthesis is not generally available, Memotoo has to be retested
and included in the nightly regression testing.
2009-07-09 10:40:00 +02:00
margie dc03f30b2a test po file for Hungarian
Transmitted-via: Transifex (translate.moblin.org)
2009-07-09 00:13:56 +00:00
Patrick Ohly 2ae283ee2c testing: callers of getItems() need to know which file was used (Bugzilla #2421)
Without that information, the wrong files are compared, leading to false
test failures. Because getItems() is also called indirectly via import(),
this change ripples through several functions.
2009-07-08 18:38:58 +02:00
Chen Congwu 445bceb9a8 Test case files: better handling of test cases, bugzilla #2421
We were using the same set of test cases for different server, this
is a bit limited; now importItem will first check a server specific
test case file and will fallback to the general case file if failed.
The makefile is also changed.
2009-07-08 18:15:20 +02:00
Patrick Ohly a79c625588 README.funambol: added some links and mention lost ACTION
With the links to our and Funambol's bug tracker it is easier
for someone who only has the README to verify what the current
status is. The ACTION issue was not mentioned in the README.
2009-07-08 18:09:14 +02:00
Patrick Ohly 1ba96c44e6 Funambol: force iCalendar 2.0 mode in the config template
As testing shows, results are better when sending items as
iCalendar 2.0 even though the server claims that it prefers
vCalendar 1.0.
2009-07-08 17:56:49 +02:00
Patrick Ohly 0c6c37680d coding style: always use curly brackets
Added some curly brackets, in order to be consistent with the rest
of SyncEvolution. The rationale is that a) always using them
avoids mistakes and b) keeps patches shorter when brackets become
necessary later.
2009-07-08 17:15:40 +02:00
Zhu, Yongsheng 161445071b Funambol: Fix a comparison for completeness (Bug #2424)
Check the value of the environment variable 'CLIENT_TEST_MAX_ITEMSIZE'
is not negative for completeness
2009-07-08 11:01:18 +08:00
Zhu, Yongsheng 77788938eb Funambol: Refine README.funambol (Bug #2422)
Add limitations, lost properties, failed cases, and others
for Funambol interoperability test
2009-07-08 10:02:29 +08:00