[boinc] 01/04: Imported Upstream version 7.6.17+dfsg

Gianfranco Costamagna locutusofborg-guest at moszumanska.debian.org
Sat Nov 21 22:14:48 UTC 2015


This is an automated email from the git hooks/post-receive script.

locutusofborg-guest pushed a commit to branch master
in repository boinc.

commit 6080f6d1e0829a20a7965c4778596f7a44c59b9a
Author: Gianfranco Costamagna <costamagnagianfranco at yahoo.it>
Date:   Sat Nov 21 19:39:56 2015 +0100

    Imported Upstream version 7.6.17+dfsg
---
 android/BOINC/AndroidManifest.xml                  |    4 +-
 android/BOINC/res/drawable-hdpi/acctmgrw.png       |  Bin 871 -> 0 bytes
 android/BOINC/res/drawable-hdpi/attentionb.png     |  Bin 4059 -> 0 bytes
 android/BOINC/res/drawable-hdpi/boinc.png          |  Bin 10150 -> 0 bytes
 android/BOINC/res/drawable-hdpi/bugb.png           |  Bin 4449 -> 0 bytes
 android/BOINC/res/drawable-hdpi/bugw.png           |  Bin 4101 -> 0 bytes
 android/BOINC/res/drawable-hdpi/chartb.png         |  Bin 4249 -> 0 bytes
 android/BOINC/res/drawable-hdpi/checkb.png         |  Bin 3846 -> 0 bytes
 android/BOINC/res/drawable-hdpi/cogsb.png          |  Bin 4418 -> 0 bytes
 android/BOINC/res/drawable-hdpi/cogw.png           |  Bin 3824 -> 0 bytes
 .../BOINC/res/drawable-hdpi/connectchargerb.png    |  Bin 4088 -> 0 bytes
 android/BOINC/res/drawable-hdpi/copyw.png          |  Bin 3413 -> 0 bytes
 android/BOINC/res/drawable-hdpi/desktopb.png       |  Bin 3553 -> 0 bytes
 android/BOINC/res/drawable-hdpi/failedb.png        |  Bin 3644 -> 0 bytes
 android/BOINC/res/drawable-hdpi/helpb.png          |  Bin 3964 -> 0 bytes
 android/BOINC/res/drawable-hdpi/helpw.png          |  Bin 1275 -> 0 bytes
 android/BOINC/res/drawable-hdpi/ic_drawer.png      |  Bin 2842 -> 0 bytes
 .../drawable-hdpi/ic_stat_notify_boinc_normal.png  |  Bin 11590 -> 0 bytes
 .../drawable-hdpi/ic_stat_notify_boinc_paused.png  |  Bin 10120 -> 0 bytes
 android/BOINC/res/drawable-hdpi/infob.png          |  Bin 3812 -> 0 bytes
 android/BOINC/res/drawable-hdpi/infow.png          |  Bin 3739 -> 0 bytes
 android/BOINC/res/drawable-hdpi/magnifierb.png     |  Bin 3999 -> 0 bytes
 android/BOINC/res/drawable-hdpi/mailb.png          |  Bin 4101 -> 0 bytes
 android/BOINC/res/drawable-hdpi/mailsmallw.png     |  Bin 3415 -> 0 bytes
 android/BOINC/res/drawable-hdpi/mailw.png          |  Bin 3616 -> 0 bytes
 android/BOINC/res/drawable-hdpi/nextb.png          |  Bin 4099 -> 0 bytes
 android/BOINC/res/drawable-hdpi/offb.png           |  Bin 4056 -> 0 bytes
 android/BOINC/res/drawable-hdpi/offw.png           |  Bin 3688 -> 0 bytes
 android/BOINC/res/drawable-hdpi/pausew.png         |  Bin 3105 -> 0 bytes
 android/BOINC/res/drawable-hdpi/playw.png          |  Bin 3319 -> 0 bytes
 android/BOINC/res/drawable-hdpi/plusw.png          |  Bin 902 -> 0 bytes
 android/BOINC/res/drawable-hdpi/previousb.png      |  Bin 4163 -> 0 bytes
 android/BOINC/res/drawable-hdpi/projects.png       |  Bin 1365 -> 0 bytes
 android/BOINC/res/drawable-hdpi/projectsb.png      |  Bin 1287 -> 0 bytes
 android/BOINC/res/drawable-hdpi/refreshw.png       |  Bin 3397 -> 0 bytes
 android/BOINC/res/drawable-hdpi/screenb.png        |  Bin 3244 -> 0 bytes
 android/BOINC/res/drawable-hdpi/speechbubbleb.png  |  Bin 3964 -> 0 bytes
 android/BOINC/res/drawable-hdpi/sqplusb.png        |  Bin 3341 -> 0 bytes
 android/BOINC/res/drawable-hdpi/status.png         |  Bin 638 -> 0 bytes
 android/BOINC/res/drawable-hdpi/statusb.png        |  Bin 592 -> 0 bytes
 android/BOINC/res/drawable-hdpi/tabsettings.png    |  Bin 998 -> 0 bytes
 android/BOINC/res/drawable-hdpi/tabsettingsb.png   |  Bin 876 -> 0 bytes
 android/BOINC/res/drawable-hdpi/tabtask.png        |  Bin 494 -> 0 bytes
 android/BOINC/res/drawable-hdpi/tabtaskb.png       |  Bin 480 -> 0 bytes
 android/BOINC/res/drawable-hdpi/wirelessb.png      |  Bin 3584 -> 0 bytes
 android/BOINC/res/values-uk/strings.xml            |   78 +-
 client/client_state.cpp                            |   21 +-
 client/client_state.h                              |    1 -
 client/cs_prefs.cpp                                |    2 +-
 client/cs_scheduler.cpp                            |    4 +-
 client/gpu_nvidia.cpp                              |    1 +
 client/log_flags.cpp                               |    4 +
 clientgui/DlgItemProperties.cpp                    |   13 +-
 clientgui/MainDocument.cpp                         |    2 +-
 clientgui/browser.cpp                              |    2 +
 clientgui/sg_ProjectPanel.cpp                      |    2 +
 clientgui/sg_TaskPanel.cpp                         |    2 +
 configure.ac                                       |    2 +-
 coverity-model.cpp                                 |   42 +
 dcapi/.gitattributes                               |   25 -
 dcapi/COPYING                                      |  119 --
 dcapi/INSTALL                                      |  234 ---
 dcapi/Makefile.am                                  |   25 -
 dcapi/README-MinGW32                               |   71 -
 dcapi/_autosetup.sh                                |    4 -
 dcapi/boinc/Makefile.am                            |   39 -
 dcapi/boinc/client.C                               |  712 -------
 dcapi/boinc/common_defs.h                          |   40 -
 dcapi/boinc/config.C                               |   80 -
 dcapi/boinc/db.C                                   |  224 ---
 dcapi/boinc/dc.c                                   |  348 ----
 dcapi/boinc/dc_boinc.h                             |  219 ---
 dcapi/boinc/dcapi-boinc-client.pc.in               |   11 -
 dcapi/boinc/dcapi-boinc-master.pc.in               |   12 -
 dcapi/boinc/events.C                               |  453 -----
 dcapi/boinc/local.conf                             |   21 -
 dcapi/boinc/result.c                               |  248 ---
 dcapi/boinc/wu.C                                   | 2016 --------------------
 dcapi/cf/boinc.m4                                  |  108 --
 dcapi/cf/java.m4                                   |   96 -
 dcapi/common/Makefile.am                           |   29 -
 dcapi/common/cfg-client.c                          |  189 --
 dcapi/common/cfg-master.c                          |  312 ---
 dcapi/common/logger.c                              |  175 --
 dcapi/common/master.sym                            |   42 -
 dcapi/common/util.c                                |  217 ---
 dcapi/condor/Makefile.am                           |   60 -
 dcapi/condor/condor_common.c                       |  111 --
 dcapi/condor/condor_common.h                       |   73 -
 dcapi/condor/condor_defs.h                         |  126 --
 dcapi/condor/condor_event.c                        |   85 -
 dcapi/condor/condor_event.h                        |   37 -
 dcapi/condor/condor_log.cc                         |  279 ---
 dcapi/condor/condor_log.h                          |   35 -
 dcapi/condor/condor_managewu.c                     |  240 ---
 dcapi/condor/condor_master.c                       | 1356 -------------
 dcapi/condor/condor_master.h                       |   37 -
 dcapi/condor/condor_result.c                       |   36 -
 dcapi/condor/condor_result.h                       |   33 -
 dcapi/condor/condor_slave.c                        |  365 ----
 dcapi/condor/condor_slave.h                        |   31 -
 dcapi/condor/condor_utils.c                        |  474 -----
 dcapi/condor/condor_utils.h                        |   54 -
 dcapi/condor/condor_wu.c                           |  628 ------
 dcapi/condor/condor_wu.h                           |   59 -
 dcapi/condor/dcapi-condor-client.pc.in             |   11 -
 dcapi/condor/dcapi-condor-master.pc.in             |   11 -
 dcapi/condor/ls_lR.sh                              |    2 -
 dcapi/condor/t.conf                                |   40 -
 dcapi/condor/tc.c                                  |   58 -
 dcapi/condor/tc.h                                  |   18 -
 dcapi/condor/test_input.txt                        |    2 -
 dcapi/condor/tm.c                                  |  355 ----
 dcapi/condor/tmpl.txt                              |   16 -
 dcapi/condor/ts.c                                  |  165 --
 dcapi/condor/tss.c                                 |  163 --
 dcapi/configure.ac                                 |  154 --
 dcapi/dcapi-deploy                                 |  166 --
 dcapi/dcapi.m4                                     |  109 --
 dcapi/doc/Makefile.am                              |  106 -
 dcapi/doc/boinc.xml                                |  728 -------
 dcapi/doc/concepts.xml                             |  202 --
 dcapi/doc/condor.xml                               |  440 -----
 dcapi/doc/config.xml                               |  267 ---
 dcapi/doc/customize.xsl                            |    7 -
 dcapi/doc/dc-api-docs.xml                          |   32 -
 dcapi/doc/dc-api-overrides.txt                     |    0
 dcapi/doc/dc-api-sections.txt                      |  108 --
 dcapi/doc/intro.xml                                |   45 -
 dcapi/doc/local.xml                                |  188 --
 dcapi/doc/states.fig                               |  108 --
 dcapi/doc/tmpl/dc-unused.sgml                      |    0
 dcapi/doc/tmpl/dc.sgml                             |  608 ------
 dcapi/doc/tmpl/dc_client.sgml                      |  238 ---
 dcapi/doc/tmpl/dc_common.sgml                      |  207 --
 dcapi/doc/using.xml                                |   48 -
 dcapi/doc/windows.xml                              |  233 ---
 dcapi/examples/message-example/Makefile.am         |   45 -
 dcapi/examples/message-example/client.c            |  155 --
 dcapi/examples/message-example/common.h            |   12 -
 dcapi/examples/message-example/configure.ac        |   35 -
 dcapi/examples/message-example/dc-api.conf         |   39 -
 dcapi/examples/message-example/input.txt           |    5 -
 dcapi/examples/message-example/master.c            |  184 --
 .../message-example/message-example-client.xml.in  |   27 -
 .../message-example/message-example-master.xml.in  |   41 -
 dcapi/examples/serialize-example/Makefile.am       |   45 -
 dcapi/examples/serialize-example/client.c          |  130 --
 dcapi/examples/serialize-example/common.h          |   12 -
 dcapi/examples/serialize-example/configure.ac      |   35 -
 dcapi/examples/serialize-example/dc-api.conf       |   39 -
 dcapi/examples/serialize-example/input.txt         |    1 -
 dcapi/examples/serialize-example/master.c          |  216 ---
 .../serialize-example-client.xml.in                |   27 -
 .../serialize-example-master.xml.in                |   41 -
 dcapi/examples/uppercase-with-callback/Makefile.am |   45 -
 dcapi/examples/uppercase-with-callback/client.c    |  258 ---
 dcapi/examples/uppercase-with-callback/common.h    |   12 -
 .../examples/uppercase-with-callback/configure.ac  |   35 -
 dcapi/examples/uppercase-with-callback/dc-api.conf |   39 -
 dcapi/examples/uppercase-with-callback/input.txt   |  233 ---
 dcapi/examples/uppercase-with-callback/master.c    |  283 ---
 .../uppercase-example-client.xml.in                |   27 -
 .../uppercase-example-master.xml.in                |   41 -
 dcapi/gtk-doc.make                                 |  173 --
 dcapi/include/Makefile.am                          |    2 -
 dcapi/include/dc.h                                 |  217 ---
 dcapi/include/dc_client.h                          |   96 -
 dcapi/include/dc_common.h                          |  148 --
 dcapi/include/dc_internal.h                        |   82 -
 dcapi/include/dc_win32.h                           |   40 -
 dcapi/java/Makefile.am                             |  181 --
 dcapi/java/client.c                                |  483 -----
 dcapi/java/example/boinc-java-launcher             |   17 -
 dcapi/java/example/compile                         |    5 -
 dcapi/java/example/manifest                        |    1 -
 dcapi/java/example/uppercase.java                  |  157 --
 dcapi/java/hu/sztaki/lpds/dc/DCException.java      |   45 -
 dcapi/java/hu/sztaki/lpds/dc/FileMode.java         |   29 -
 dcapi/java/hu/sztaki/lpds/dc/FileType.java         |   29 -
 .../java/hu/sztaki/lpds/dc/RuntimeDCException.java |   42 -
 dcapi/java/hu/sztaki/lpds/dc/client/DCClient.java  |   43 -
 dcapi/java/hu/sztaki/lpds/dc/client/Event.java     |   37 -
 .../java/hu/sztaki/lpds/dc/client/Version.java.in  |   30 -
 dcapi/java/hu/sztaki/lpds/dc/client/package.html   |    6 -
 dcapi/java/hu/sztaki/lpds/dc/overview.html         |   23 -
 dcapi/java/hu/sztaki/lpds/dc/package.html          |    6 -
 dcapi/java/jre-boinc/jre_for_boinc_guide.txt       |   41 -
 dcapi/java/util.c                                  |  350 ----
 dcapi/java/util.h                                  |  155 --
 dcapi/local/Makefile.am                            |   38 -
 dcapi/local/dcapi-local-client.pc.in               |   11 -
 dcapi/local/dcapi-local-master.pc.in               |   11 -
 dcapi/local/local_client.c                         |  373 ----
 dcapi/local/local_common.c                         |   62 -
 dcapi/local/local_common.h                         |  119 --
 dcapi/local/local_events.c                         |  532 ------
 dcapi/local/local_master.c                         |  845 --------
 dcapi/local/local_master.h                         |  147 --
 dcapi/local/local_result.c                         |  217 ---
 dcapi/local/local_result.h                         |   33 -
 dcapi/local/local_utils.c                          |  479 -----
 dcapi/local/local_utils.h                          |   52 -
 dcapi/local/local_wu.c                             |   45 -
 dcapi/local/local_wu.h                             |   33 -
 dcapi/python/DCAPI/BOINC_Backend.py                |   27 -
 dcapi/python/DCAPI/Condor_Backend.py               |   19 -
 dcapi/python/DCAPI/DCAPI_Backend.py                |   17 -
 dcapi/python/DCAPI/__init__.py                     |    3 -
 dcapi/python/DCAPI/local_Backend.py                |   16 -
 dcapi/tmp/dc_client_fortran.c                      |  251 ---
 html/bt/INSTALL                                    |   25 -
 html/bt/README                                     |   47 -
 html/bt/announce.php                               |  100 -
 html/bt/config.php.example                         |   81 -
 html/bt/database/bittorrent_files.sql              |    9 -
 html/bt/database/bittorrent_ipbans.sql             |    5 -
 html/bt/database/bittorrent_peers.sql              |   13 -
 html/bt/filters/allfilesfilefilter.php             |   16 -
 html/bt/filters/filefilter.php                     |   13 -
 html/bt/inc/bdictionary.php                        |   53 -
 html/bt/inc/belement.php                           |   29 -
 html/bt/inc/binteger.php                           |   35 -
 html/bt/inc/blist.php                              |  102 -
 html/bt/inc/bstring.php                            |   36 -
 html/bt/inc/checks.php                             |   31 -
 html/bt/inc/illegalargumentexception.php           |    9 -
 html/bt/inc/torrent.php                            |   89 -
 html/bt/index.php                                  |   78 -
 html/bt/scrape.php                                 |   47 -
 html/bt/torrent_cache.php                          |   71 -
 html/queue/README                                  |  102 -
 html/queue/create_queue.sql                        |   20 -
 html/queue/inc/queue.inc                           |  145 --
 html/queue/inc/user.inc                            |  364 ----
 html/queue/ops/ops_queue_remove_job.php            |   52 -
 html/queue/ops/ops_queue_show_job.php              |  126 --
 html/queue/ops/ops_queue_show_queue.php            |   71 -
 html/queue/user/queue_new_job_form.php             |   95 -
 html/queue/user/queue_new_job_form_action.php      |  158 --
 html/queue/user/queue_remove_job.php               |   67 -
 html/queue/user/queue_show_job.php                 |  138 --
 html/queue/user/queue_show_queue.php               |   93 -
 lib/app_ipc.cpp                                    |    5 +-
 lib/cc_config.cpp                                  |    5 +
 lib/cc_config.h                                    |    1 +
 lib/common_defs.h                                  |   22 +
 lib/coproc.cpp                                     |    4 +
 lib/coproc.h                                       |    5 +-
 lib/crypt.cpp                                      |    5 +-
 lib/crypt_prog.cpp                                 |   19 +-
 lib/diagnostics.cpp                                |    4 +-
 lib/error_numbers.h                                |    2 +
 lib/filesys.cpp                                    |   16 +-
 lib/gui_rpc_client.cpp                             |    9 +-
 lib/gui_rpc_client_ops.cpp                         |   22 +-
 lib/mfile.cpp                                      |    6 +-
 lib/miofile.cpp                                    |    2 +
 lib/msg_log.cpp                                    |    1 +
 lib/network.cpp                                    |   14 +-
 lib/notice.cpp                                     |    1 +
 lib/parse.cpp                                      |    6 +-
 lib/prefs.cpp                                      |    2 +
 lib/prefs.h                                        |    2 +-
 lib/procinfo.h                                     |    5 +-
 lib/str_util.cpp                                   |    7 +
 locale/de/BOINC-Project-Generic.po                 |  360 ++--
 locale/it_IT/BOINC-Client.mo                       |  Bin 4948 -> 5012 bytes
 locale/it_IT/BOINC-Client.po                       |   56 +-
 locale/it_IT/BOINC-Drupal.po                       |    4 +-
 locale/it_IT/BOINC-Manager.mo                      |  Bin 79391 -> 79467 bytes
 locale/it_IT/BOINC-Manager.po                      |  105 +-
 locale/it_IT/BOINC-Project-Generic.po              |   46 +-
 locale/it_IT/BOINC-Web.mo                          |  Bin 36770 -> 36770 bytes
 locale/it_IT/BOINC-Web.po                          |    2 +-
 locale/nl/BOINC-Project-Generic.po                 |    2 +-
 locale/pt_PT/BOINC-Manager.mo                      |  Bin 79146 -> 79628 bytes
 locale/pt_PT/BOINC-Manager.po                      | 1185 ++++++------
 locale/ru/BOINC-Project-Generic.po                 |    7 +-
 locale/sr at latin/BOINC-Client.mo                    |  Bin 0 -> 4755 bytes
 locale/{it_IT => sr at latin}/BOINC-Client.po         |   78 +-
 locale/sr at latin/BOINC-Setup.mo                     |  Bin 0 -> 3091 bytes
 locale/{uk => sr at latin}/BOINC-Setup.po             |   45 +-
 locale/tr/BOINC-Project-Generic.po                 |    2 +-
 locale/uk/BOINC-Client.mo                          |  Bin 6318 -> 6345 bytes
 locale/uk/BOINC-Client.po                          |   21 +-
 locale/uk/BOINC-Setup.mo                           |  Bin 3871 -> 3917 bytes
 locale/uk/BOINC-Setup.po                           |   15 +-
 rboinc/client/boinc_lib.pl                         |  253 ---
 rboinc/client/boinc_retrieve.pl                    |  589 ------
 rboinc/client/boinc_submit.pl                      |  554 ------
 rboinc/monitoring/Text/Aligner.pm                  |  426 -----
 rboinc/monitoring/Text/Table.pm                    | 1026 ----------
 rboinc/monitoring/duplicate_late.sh                |   43 -
 rboinc/monitoring/generate_error_table.sh          |   14 -
 rboinc/monitoring/monitoring_compute.sql           |  102 -
 rboinc/monitoring/monitoring_cron.sh               |  250 ---
 rboinc/monitoring/monitoring_errors.pl             |   94 -
 rboinc/monitoring/monitoring_errors_table.pm       |  128 --
 rboinc/monitoring/monitoring_functions.sql         |  104 -
 rboinc/monitoring/monitoring_schema.sql            |   29 -
 rboinc/monitoring/monitoring_status.sql            |  167 --
 rboinc/notes.txt                                   |    2 -
 rboinc/server/boinc_authentication.pl              |  310 ---
 rboinc/server/boinc_configuration.pl               |   67 -
 rboinc/server/boinc_configuration_template.pl      |   69 -
 rboinc/server/boinc_retrieve_server.pl             |  738 -------
 rboinc/server/boinc_submit_server.pl               |  825 --------
 rboinc/server/etc/default_COPYRIGHT                |   33 -
 rboinc/server/etc/default_LICENSE                  |  229 ---
 rboinc/server/etc/default_hills_file               |    0
 rboinc/server/etc/default_idx_file                 |  Bin 4 -> 0 bytes
 rboinc/server/etc/default_metadata_file            |    1 -
 rboinc/server/etc/default_metainp_file             |    2 -
 rboinc/server/etc/rboinc_httpd_conf                |  102 -
 rboinc/server/etc/templates/rboinc_metabeta_result |  110 --
 rboinc/server/etc/templates/rboinc_metabeta_wu     |  115 --
 rboinc/server/etc/user.passwd                      |    1 -
 rboinc/server/test/test.cgi                        |    5 -
 rboinc/server/test/test_authentication.pl          |   20 -
 sched/adjust_user_priority.cpp                     |    2 +-
 sched/assimilator.cpp                              |    1 +
 sched/db_dump.cpp                                  |   53 +-
 sched/db_purge.cpp                                 |   10 +-
 sched/edf_sim.h                                    |   15 +-
 sched/feeder.cpp                                   |   15 +-
 sched/file_deleter.cpp                             |    3 +-
 sched/file_upload_handler.cpp                      |   32 +-
 sched/message_handler.cpp                          |    1 +
 sched/sample_assimilator.cpp                       |    1 +
 sched/sample_bitwise_validator.cpp                 |    1 +
 sched/sample_work_generator.cpp                    |    4 +-
 sched/sched_array.cpp                              |    2 +-
 sched/sched_config.cpp                             |    4 +-
 sched/sched_driver.cpp                             |    6 +-
 sched/sched_main.cpp                               |    4 +-
 sched/sched_send.cpp                               |    1 +
 sched/sched_types.cpp                              |   50 +-
 sched/sched_types.h                                |    7 +-
 sched/sched_util_basic.cpp                         |   21 +-
 sched/sched_util_basic.h                           |    2 +-
 sched/sched_version.cpp                            |    2 +-
 sched/single_job_assimilator.cpp                   |    4 +
 sched/size_regulator.cpp                           |    4 +-
 sched/start                                        |   63 +-
 sched/time_stats_log.cpp                           |    4 +-
 sched/time_stats_log.h                             |    2 +-
 sched/trickle_handler.cpp                          |    1 +
 sched/validator.cpp                                |    6 +
 tools/backend_lib.cpp                              |    2 +-
 tools/cancel_jobs.cpp                              |    2 +-
 tools/create_work.cpp                              |   16 +-
 tools/dir_hier_move.cpp                            |    2 +-
 tools/process_input_template.cpp                   |    2 +
 tools/process_result_template.cpp                  |    5 +-
 vda/ssim.cpp                                       |    2 +
 vda/vda.cpp                                        |    2 +-
 version.log                                        |    2 +-
 358 files changed, 1522 insertions(+), 32688 deletions(-)

diff --git a/android/BOINC/AndroidManifest.xml b/android/BOINC/AndroidManifest.xml
index 58da526..a184f24 100644
--- a/android/BOINC/AndroidManifest.xml
+++ b/android/BOINC/AndroidManifest.xml
@@ -20,8 +20,8 @@
 <manifest xmlns:android="http://schemas.android.com/apk/res/android"
     package="edu.berkeley.boinc"
     android:installLocation="internalOnly"
-    android:versionCode="129"
-    android:versionName="7.6.15" > <!-- installation on SD card would break boot receiver -->
+    android:versionCode="131"
+    android:versionName="7.6.17" > <!-- installation on SD card would break boot receiver -->
 
 
     <!-- Add Google Play store metadata informing the store we can run on tablets and other large screen devices -->
diff --git a/android/BOINC/res/drawable-hdpi/acctmgrw.png b/android/BOINC/res/drawable-hdpi/acctmgrw.png
deleted file mode 100644
index ea1c845..0000000
Binary files a/android/BOINC/res/drawable-hdpi/acctmgrw.png and /dev/null differ
diff --git a/android/BOINC/res/drawable-hdpi/attentionb.png b/android/BOINC/res/drawable-hdpi/attentionb.png
deleted file mode 100644
index f098f8a..0000000
Binary files a/android/BOINC/res/drawable-hdpi/attentionb.png and /dev/null differ
diff --git a/android/BOINC/res/drawable-hdpi/boinc.png b/android/BOINC/res/drawable-hdpi/boinc.png
deleted file mode 100644
index edde236..0000000
Binary files a/android/BOINC/res/drawable-hdpi/boinc.png and /dev/null differ
diff --git a/android/BOINC/res/drawable-hdpi/bugb.png b/android/BOINC/res/drawable-hdpi/bugb.png
deleted file mode 100644
index 67a4a7a..0000000
Binary files a/android/BOINC/res/drawable-hdpi/bugb.png and /dev/null differ
diff --git a/android/BOINC/res/drawable-hdpi/bugw.png b/android/BOINC/res/drawable-hdpi/bugw.png
deleted file mode 100644
index e1d8f4f..0000000
Binary files a/android/BOINC/res/drawable-hdpi/bugw.png and /dev/null differ
diff --git a/android/BOINC/res/drawable-hdpi/chartb.png b/android/BOINC/res/drawable-hdpi/chartb.png
deleted file mode 100644
index a84a332..0000000
Binary files a/android/BOINC/res/drawable-hdpi/chartb.png and /dev/null differ
diff --git a/android/BOINC/res/drawable-hdpi/checkb.png b/android/BOINC/res/drawable-hdpi/checkb.png
deleted file mode 100644
index cfc5ff4..0000000
Binary files a/android/BOINC/res/drawable-hdpi/checkb.png and /dev/null differ
diff --git a/android/BOINC/res/drawable-hdpi/cogsb.png b/android/BOINC/res/drawable-hdpi/cogsb.png
deleted file mode 100644
index e683595..0000000
Binary files a/android/BOINC/res/drawable-hdpi/cogsb.png and /dev/null differ
diff --git a/android/BOINC/res/drawable-hdpi/cogw.png b/android/BOINC/res/drawable-hdpi/cogw.png
deleted file mode 100644
index b8d0266..0000000
Binary files a/android/BOINC/res/drawable-hdpi/cogw.png and /dev/null differ
diff --git a/android/BOINC/res/drawable-hdpi/connectchargerb.png b/android/BOINC/res/drawable-hdpi/connectchargerb.png
deleted file mode 100644
index 708cc7f..0000000
Binary files a/android/BOINC/res/drawable-hdpi/connectchargerb.png and /dev/null differ
diff --git a/android/BOINC/res/drawable-hdpi/copyw.png b/android/BOINC/res/drawable-hdpi/copyw.png
deleted file mode 100644
index d9a3083..0000000
Binary files a/android/BOINC/res/drawable-hdpi/copyw.png and /dev/null differ
diff --git a/android/BOINC/res/drawable-hdpi/desktopb.png b/android/BOINC/res/drawable-hdpi/desktopb.png
deleted file mode 100644
index 113659d..0000000
Binary files a/android/BOINC/res/drawable-hdpi/desktopb.png and /dev/null differ
diff --git a/android/BOINC/res/drawable-hdpi/failedb.png b/android/BOINC/res/drawable-hdpi/failedb.png
deleted file mode 100644
index 58c1dce..0000000
Binary files a/android/BOINC/res/drawable-hdpi/failedb.png and /dev/null differ
diff --git a/android/BOINC/res/drawable-hdpi/helpb.png b/android/BOINC/res/drawable-hdpi/helpb.png
deleted file mode 100644
index 91d7126..0000000
Binary files a/android/BOINC/res/drawable-hdpi/helpb.png and /dev/null differ
diff --git a/android/BOINC/res/drawable-hdpi/helpw.png b/android/BOINC/res/drawable-hdpi/helpw.png
deleted file mode 100644
index 0ca61c5..0000000
Binary files a/android/BOINC/res/drawable-hdpi/helpw.png and /dev/null differ
diff --git a/android/BOINC/res/drawable-hdpi/ic_drawer.png b/android/BOINC/res/drawable-hdpi/ic_drawer.png
deleted file mode 100644
index ff7b1de..0000000
Binary files a/android/BOINC/res/drawable-hdpi/ic_drawer.png and /dev/null differ
diff --git a/android/BOINC/res/drawable-hdpi/ic_stat_notify_boinc_normal.png b/android/BOINC/res/drawable-hdpi/ic_stat_notify_boinc_normal.png
deleted file mode 100644
index b87ea6f..0000000
Binary files a/android/BOINC/res/drawable-hdpi/ic_stat_notify_boinc_normal.png and /dev/null differ
diff --git a/android/BOINC/res/drawable-hdpi/ic_stat_notify_boinc_paused.png b/android/BOINC/res/drawable-hdpi/ic_stat_notify_boinc_paused.png
deleted file mode 100644
index 33780f9..0000000
Binary files a/android/BOINC/res/drawable-hdpi/ic_stat_notify_boinc_paused.png and /dev/null differ
diff --git a/android/BOINC/res/drawable-hdpi/infob.png b/android/BOINC/res/drawable-hdpi/infob.png
deleted file mode 100644
index 071cb87..0000000
Binary files a/android/BOINC/res/drawable-hdpi/infob.png and /dev/null differ
diff --git a/android/BOINC/res/drawable-hdpi/infow.png b/android/BOINC/res/drawable-hdpi/infow.png
deleted file mode 100644
index 28c8146..0000000
Binary files a/android/BOINC/res/drawable-hdpi/infow.png and /dev/null differ
diff --git a/android/BOINC/res/drawable-hdpi/magnifierb.png b/android/BOINC/res/drawable-hdpi/magnifierb.png
deleted file mode 100644
index 9d9e881..0000000
Binary files a/android/BOINC/res/drawable-hdpi/magnifierb.png and /dev/null differ
diff --git a/android/BOINC/res/drawable-hdpi/mailb.png b/android/BOINC/res/drawable-hdpi/mailb.png
deleted file mode 100644
index 4b2ced4..0000000
Binary files a/android/BOINC/res/drawable-hdpi/mailb.png and /dev/null differ
diff --git a/android/BOINC/res/drawable-hdpi/mailsmallw.png b/android/BOINC/res/drawable-hdpi/mailsmallw.png
deleted file mode 100644
index 865a773..0000000
Binary files a/android/BOINC/res/drawable-hdpi/mailsmallw.png and /dev/null differ
diff --git a/android/BOINC/res/drawable-hdpi/mailw.png b/android/BOINC/res/drawable-hdpi/mailw.png
deleted file mode 100644
index dc50fcb..0000000
Binary files a/android/BOINC/res/drawable-hdpi/mailw.png and /dev/null differ
diff --git a/android/BOINC/res/drawable-hdpi/nextb.png b/android/BOINC/res/drawable-hdpi/nextb.png
deleted file mode 100644
index 8442bc9..0000000
Binary files a/android/BOINC/res/drawable-hdpi/nextb.png and /dev/null differ
diff --git a/android/BOINC/res/drawable-hdpi/offb.png b/android/BOINC/res/drawable-hdpi/offb.png
deleted file mode 100644
index ee14ac0..0000000
Binary files a/android/BOINC/res/drawable-hdpi/offb.png and /dev/null differ
diff --git a/android/BOINC/res/drawable-hdpi/offw.png b/android/BOINC/res/drawable-hdpi/offw.png
deleted file mode 100644
index d48867d..0000000
Binary files a/android/BOINC/res/drawable-hdpi/offw.png and /dev/null differ
diff --git a/android/BOINC/res/drawable-hdpi/pausew.png b/android/BOINC/res/drawable-hdpi/pausew.png
deleted file mode 100644
index c2b9866..0000000
Binary files a/android/BOINC/res/drawable-hdpi/pausew.png and /dev/null differ
diff --git a/android/BOINC/res/drawable-hdpi/playw.png b/android/BOINC/res/drawable-hdpi/playw.png
deleted file mode 100644
index 75fa515..0000000
Binary files a/android/BOINC/res/drawable-hdpi/playw.png and /dev/null differ
diff --git a/android/BOINC/res/drawable-hdpi/plusw.png b/android/BOINC/res/drawable-hdpi/plusw.png
deleted file mode 100644
index 6d290f8..0000000
Binary files a/android/BOINC/res/drawable-hdpi/plusw.png and /dev/null differ
diff --git a/android/BOINC/res/drawable-hdpi/previousb.png b/android/BOINC/res/drawable-hdpi/previousb.png
deleted file mode 100644
index d8a1c7a..0000000
Binary files a/android/BOINC/res/drawable-hdpi/previousb.png and /dev/null differ
diff --git a/android/BOINC/res/drawable-hdpi/projects.png b/android/BOINC/res/drawable-hdpi/projects.png
deleted file mode 100644
index 45ec0b1..0000000
Binary files a/android/BOINC/res/drawable-hdpi/projects.png and /dev/null differ
diff --git a/android/BOINC/res/drawable-hdpi/projectsb.png b/android/BOINC/res/drawable-hdpi/projectsb.png
deleted file mode 100644
index 63cabe4..0000000
Binary files a/android/BOINC/res/drawable-hdpi/projectsb.png and /dev/null differ
diff --git a/android/BOINC/res/drawable-hdpi/refreshw.png b/android/BOINC/res/drawable-hdpi/refreshw.png
deleted file mode 100644
index c8a88b9..0000000
Binary files a/android/BOINC/res/drawable-hdpi/refreshw.png and /dev/null differ
diff --git a/android/BOINC/res/drawable-hdpi/screenb.png b/android/BOINC/res/drawable-hdpi/screenb.png
deleted file mode 100644
index 0c59fc5..0000000
Binary files a/android/BOINC/res/drawable-hdpi/screenb.png and /dev/null differ
diff --git a/android/BOINC/res/drawable-hdpi/speechbubbleb.png b/android/BOINC/res/drawable-hdpi/speechbubbleb.png
deleted file mode 100644
index 91d7126..0000000
Binary files a/android/BOINC/res/drawable-hdpi/speechbubbleb.png and /dev/null differ
diff --git a/android/BOINC/res/drawable-hdpi/sqplusb.png b/android/BOINC/res/drawable-hdpi/sqplusb.png
deleted file mode 100644
index 1228e5a..0000000
Binary files a/android/BOINC/res/drawable-hdpi/sqplusb.png and /dev/null differ
diff --git a/android/BOINC/res/drawable-hdpi/status.png b/android/BOINC/res/drawable-hdpi/status.png
deleted file mode 100644
index f00263e..0000000
Binary files a/android/BOINC/res/drawable-hdpi/status.png and /dev/null differ
diff --git a/android/BOINC/res/drawable-hdpi/statusb.png b/android/BOINC/res/drawable-hdpi/statusb.png
deleted file mode 100644
index c0dc4ee..0000000
Binary files a/android/BOINC/res/drawable-hdpi/statusb.png and /dev/null differ
diff --git a/android/BOINC/res/drawable-hdpi/tabsettings.png b/android/BOINC/res/drawable-hdpi/tabsettings.png
deleted file mode 100644
index e36e0d9..0000000
Binary files a/android/BOINC/res/drawable-hdpi/tabsettings.png and /dev/null differ
diff --git a/android/BOINC/res/drawable-hdpi/tabsettingsb.png b/android/BOINC/res/drawable-hdpi/tabsettingsb.png
deleted file mode 100644
index 26701ce..0000000
Binary files a/android/BOINC/res/drawable-hdpi/tabsettingsb.png and /dev/null differ
diff --git a/android/BOINC/res/drawable-hdpi/tabtask.png b/android/BOINC/res/drawable-hdpi/tabtask.png
deleted file mode 100644
index 24f75c7..0000000
Binary files a/android/BOINC/res/drawable-hdpi/tabtask.png and /dev/null differ
diff --git a/android/BOINC/res/drawable-hdpi/tabtaskb.png b/android/BOINC/res/drawable-hdpi/tabtaskb.png
deleted file mode 100644
index 726193c..0000000
Binary files a/android/BOINC/res/drawable-hdpi/tabtaskb.png and /dev/null differ
diff --git a/android/BOINC/res/drawable-hdpi/wirelessb.png b/android/BOINC/res/drawable-hdpi/wirelessb.png
deleted file mode 100644
index 675127e..0000000
Binary files a/android/BOINC/res/drawable-hdpi/wirelessb.png and /dev/null differ
diff --git a/android/BOINC/res/values-uk/strings.xml b/android/BOINC/res/values-uk/strings.xml
index 806b122..287bb83 100644
--- a/android/BOINC/res/values-uk/strings.xml
+++ b/android/BOINC/res/values-uk/strings.xml
@@ -3,7 +3,7 @@
   <!--app global-->
   <string name="app_name">BOINC</string>
   <!--generic. used by multiple Activities/tabs-->
-  <string name="generic_loading">Завантаження! Зачекайте, будь-ласка...</string>
+  <string name="generic_loading">Завантаження! Зачекайте, будь ласка...</string>
   <string name="generic_button_continue">Продовжити</string>
   <string name="generic_button_finish">Готово</string>
   <!--attach project-->
@@ -13,7 +13,7 @@
   <string name="attachproject_list_manual_button">Додати проект за адресою (URL)</string>
   <string name="attachproject_list_manual_dialog_title">Введіть адресу (URL) проекту:</string>
   <string name="attachproject_list_manual_dialog_button">Додати проект</string>
-  <string name="attachproject_list_manual_no_url">Додати менеджер проектів</string>
+  <string name="attachproject_list_manual_no_url">Будь ласка, введіть адресу (URL) проекту:</string>
   <string name="attachproject_list_acctmgr_button">Додати менеджер проектів</string>
   <string name="attachproject_list_no_internet">Відсутнє з’єднання з Інтернетом</string>
   <!--credential input-->
@@ -35,8 +35,8 @@
   <string name="attachproject_hints_header">Порада</string>
   <!--e.g. Hint 1/2-->
   <string name="attachproject_hint_contribtion_header">Як прийняти участь:</string>
-  <string name="attachproject_hint_contribtion_wifi">1. Підключитися до WiFi</string>
-  <string name="attachproject_hint_contribtion_charger">2. Підключити до джерела живлення</string>
+  <string name="attachproject_hint_contribtion_wifi">1. Підключити пристрій до WiFi</string>
+  <string name="attachproject_hint_contribtion_charger">2. Підключити пристрій до джерела живлення</string>
   <string name="attachproject_hint_contribtion_screen">3. Вимкнути екран</string>
   <string name="attachproject_hint_projectwebsite_header">Відвідати інтернет сторінку проекту:</string>
   <string name="attachproject_hint_projectwebsite_science">Дізнатися більше про науковий аспект</string>
@@ -50,10 +50,10 @@
   <string name="attachproject_login_header_specific_area">Спеціальна область:</string>
   <string name="attachproject_login_header_description">Опис:</string>
   <string name="attachproject_login_header_home">Домівка:</string>
-  <string name="attachproject_login_header_url">Веб-сайт:</string>
+  <string name="attachproject_login_header_url">Веб-сторінка:</string>
   <string name="attachproject_login_header_platform">Android:</string>
-  <string name="attachproject_login_platform_supported">Цей проект підтримує пристрої, на базі Android</string>
-  <string name="attachproject_login_platform_not_supported">Цей проект не підтримує пристрої, на базі Android</string>
+  <string name="attachproject_login_platform_supported">Цей проект підтримує пристрої на базі Android</string>
+  <string name="attachproject_login_platform_not_supported">Цей проект не підтримує пристрої на базі Android</string>
   <string name="attachproject_login_category_terms_of_use">Умови використання для</string>
   <string name="attachproject_login_accept_terms_of_use">Створюючи обліковий запис у цьому проекті, Ви приймаєте умови використання, що викладені вище.</string>
   <string name="attachproject_login_category_login">Увійти з існуючим обліковим записом</string>
@@ -92,13 +92,13 @@
   <string name="attachproject_error_no_internet">Невдала спроба зв’язку</string>
   <string name="attachproject_error_pwd_no_match">Паролі не збігаються</string>
   <string name="attachproject_error_pwd_no_retype">Будь ласка, введіть пароль ще раз</string>
-  <string name="attachproject_error_no_url">Будь-ласка, введіть адресу (URL)</string>
+  <string name="attachproject_error_no_url">Будь ласка, введіть адресу (URL)</string>
   <string name="attachproject_error_no_email">Будь ласка, вкажіть адресу електронної пошти</string>
-  <string name="attachproject_error_no_pwd">Будь-ласка, введіть пароль</string>
-  <string name="attachproject_error_no_name">Будь-ласка, введіть ім\'я користувача</string>
+  <string name="attachproject_error_no_pwd">Будь ласка, введіть пароль</string>
+  <string name="attachproject_error_no_name">Будь ласка, введіть ім\'я користувача</string>
   <string name="attachproject_error_unknown">невдало</string>
   <string name="attachproject_error_bad_username">Ім\'я користувача відхилене</string>
-  <string name="attachproject_error_email_in_use">Електронна адреса вже використовується</string>
+  <string name="attachproject_error_email_in_use">Адреса електронної пошти вже використовується</string>
   <string name="attachproject_error_project_down">Проект поза мережею</string>
   <string name="attachproject_error_email_bad_syntax">Адресу електронної пошти відхилено</string>
   <string name="attachproject_error_bad_pwd">Пароль відхилено</string>
@@ -138,7 +138,7 @@
   <string name="status_idle">Нема роботи</string>
   <string name="status_idle_long">Очікування завдань…</string>
   <string name="status_computing_disabled">Призупинено</string>
-  <string name="status_computing_disabled_long">Натисніть кнопку Грати для відновлення мережі і обчислень.</string>
+  <string name="status_computing_disabled_long">Натисніть кнопку Грати для відновлення обчислень та зв’язку з мережею.</string>
   <string name="status_launching">Запуск…</string>
   <string name="status_noproject">Оберіть проект для прийняття участі в ньому.</string>
   <string name="status_closing">Закриття...</string>
@@ -156,21 +156,21 @@
   <string name="prefs_category_storage">Диск</string>
   <string name="prefs_category_memory">Пам`ять</string>
   <string name="prefs_category_debug">Діагностика</string>
-  <string name="prefs_show_advanced_header">Показати додаткові налаштування і елементи керування...</string>
+  <string name="prefs_show_advanced_header">Показати додаткові налаштування та елементи керування...</string>
   <string name="prefs_suspend_when_screen_on">Призупиняти обчислення, коли екран увімкнуто</string>
   <string name="prefs_stationary_device_mode_header">Стаціонарний режим роботи пристрою</string>
-  <string name="prefs_stationary_device_mode_description">Дозволяє робити обчислення не дивлячись на налаштування Живлення. Вмикати, тільки якщо пристрой на має акумулятора</string>
+  <string name="prefs_stationary_device_mode_description">Дозволяє робити обчислення не дивлячись на налаштування Живлення. Вмикати, тільки якщо пристрой не має акумулятора.</string>
   <string name="prefs_power_source_header">Джерела живлення для обчислювання</string>
   <string name="prefs_power_source_description">Оберіть джерела живлення, які BOINC може використовувати для обчислення.</string>
   <string name="prefs_power_source_ac">Розетка</string>
   <string name="prefs_power_source_usb">Підключення по USB</string>
   <string name="prefs_power_source_wireless">Бездротовий зарядний пристрій</string>
   <string name="prefs_power_source_battery">Акумулятор</string>
-  <string name="battery_charge_min_pct_header">Низький заряд батареї</string>
+  <string name="battery_charge_min_pct_header">Мін. заряд батареї</string>
   <string name="battery_charge_min_pct_description">BOINC призупиняє обчислення нижче визначеного рівня заряду акумулятора.</string>
   <string name="battery_temperature_max_header">Макс. температура батареї</string>
   <string name="battery_temperature_max_description">BOINC призупинить розрахунки, коли температура батареї перевищить вказаний рівень. Не рекомендовано змінювати це значення.</string>
-  <string name="prefs_disk_max_pct_header">Макс. використаний об’єм диска</string>
+  <string name="prefs_disk_max_pct_header">Макс. об’єм диска для використання</string>
   <string name="prefs_disk_max_pct_description">Скільки відсотків дискового простору може використовувати BOINC?</string>
   <string name="prefs_disk_min_free_gb_header">Мін. запас дискового простору</string>
   <string name="prefs_disk_min_free_gb_description">Скільки вашого дискового простору повинно залишитися вільним?</string>
@@ -184,11 +184,11 @@
   <string name="prefs_show_notification_suspended_header">Сповіщати навіть коли призупинено</string>
   <string name="prefs_cpu_number_cpus_header">Використано ядер ЦП</string>
   <string name="prefs_cpu_number_cpus_description">Обмежує кількість ядер ЦП, які BOINC використовує для обчислень.</string>
-  <string name="prefs_cpu_other_load_suspension_header">Використання ЦП призупинене</string>
-  <string name="prefs_cpu_other_load_suspension_description">Визначає, коли BOINC призупиняє обчислення через використання процессора іншими додатками</string>
+  <string name="prefs_cpu_other_load_suspension_header">Призупиняти, коли використання ЦП вище, ніж</string>
+  <string name="prefs_cpu_other_load_suspension_description">Визначає, коли BOINC призупиняє обчислення через використання процессора іншими додатками.</string>
   <string name="prefs_cpu_time_max_header">Обмеження ЦП</string>
   <string name="prefs_cpu_time_max_description">Обмежує процесорний час роботи, який BOINC використовує для обчислень.</string>
-  <string name="prefs_memory_max_idle_header">обмеження RAM</string>
+  <string name="prefs_memory_max_idle_header">Обмеження RAM</string>
   <string name="prefs_memory_max_idle_description">Обмеження кількості RAM, доступної для використання.</string>
   <string name="prefs_client_log_flags_header">Прапорці журналу клієнта BOINC</string>
   <string name="prefs_gui_log_level_header">Рівень журналу GUI</string>
@@ -197,18 +197,18 @@
   <string name="prefs_unit_gb">Гб</string>
   <string name="prefs_unit_pct">%</string>
   <string name="prefs_unit_celcius">°C</string>
-  <string name="prefs_unit_seconds">секунд</string>
+  <string name="prefs_unit_seconds">сек.</string>
   <!--projects tab strings-->
   <string name="projects_loading">Читання проектів...</string>
   <string name="projects_add">Додати проект</string>
-  <string name="projects_icon">Значок проекту</string>
+  <string name="projects_icon">Іконка проекту</string>
   <string name="projects_credits_header">Бали:</string>
   <string name="projects_credits_host_header">(на цьому пристрої)</string>
   <string name="projects_credits_user_header">(загалом)</string>
   <!--project status strings-->
   <string name="projects_status_suspendedviagui">Призупинено користувачем</string>
-  <string name="projects_status_dontrequestmorework">Не приймає нові завдання</string>
-  <string name="projects_status_ended">Проект завершений - Гаразд для видалення</string>
+  <string name="projects_status_dontrequestmorework">Не приймати нові завдання</string>
+  <string name="projects_status_ended">Проект завершено - можна видаляти</string>
   <string name="projects_status_detachwhendone">Буде видалено після завершення завдань</string>
   <string name="projects_status_schedrpcpending">Запит інформації у планувальника</string>
   <string name="projects_status_schedrpcinprogress">Відбувається запит інформації у планувальника</string>
@@ -216,10 +216,10 @@
   <string name="projects_status_backoff">Зв’язок за розкладом:</string>
   <!--project controls-->
   <string name="projects_control_dialog_title">Команди проекту:</string>
-  <string name="projects_control_visit_website">Відвідати веб-сайт</string>
+  <string name="projects_control_visit_website">Відвідати веб-сторінку</string>
   <string name="projects_control_update">Оновити</string>
   <string name="projects_control_remove">Видалити</string>
-  <string name="projects_control_suspend">Призупинено</string>
+  <string name="projects_control_suspend">Призупинити</string>
   <string name="projects_control_resume">Відновити</string>
   <string name="projects_control_nonewtasks">Не завантажувати нові завдання</string>
   <string name="projects_control_allownewtasks">Отримувати нові завдання</string>
@@ -235,7 +235,7 @@
   <string name="projects_confirm_reset_title">Перезапустити проект</string>
   <string name="projects_confirm_reset_message">Ви справді хочете перезапустити</string>
   <string name="projects_confirm_reset_message2">\?</string>
-  <string name="projects_confirm_reset_confirm">Скинути</string>
+  <string name="projects_confirm_reset_confirm">Перезапустити</string>
   <string name="projects_confirm_remove_acctmgr_title">Відключити менеджер проектів</string>
   <string name="projects_confirm_remove_acctmgr_message">Ви впевнені, що бажаєте припинити використання</string>
   <string name="projects_confirm_remove_acctmgr_message2">\?</string>
@@ -245,11 +245,11 @@
   <string name="tasks_header_elapsed_time">Витрачено часу:</string>
   <string name="tasks_header_project_paused">(призупинено)</string>
   <string name="tasks_header_deadline">Кінцевий термін:</string>
-  <string name="tasks_result_new">новий</string>
+  <string name="tasks_result_new">нове</string>
   <string name="tasks_result_files_downloading">очікування завантаження</string>
   <string name="tasks_result_files_downloaded">звантаження завершене</string>
   <string name="tasks_result_compute_error">помилка обчислень</string>
-  <string name="tasks_result_files_uploading">Відправлення</string>
+  <string name="tasks_result_files_uploading">відправлення</string>
   <string name="tasks_result_files_uploaded">відправлення завершене</string>
   <string name="tasks_result_aborted">перервано</string>
   <string name="tasks_result_upload_failed">невдала спроба відправлення</string>
@@ -271,7 +271,7 @@
   <string name="trans_loading">Читання передач...</string>
   <string name="trans_upload">Відправлення</string>
   <string name="trans_download">Завантаження</string>
-  <string name="trans_retryin">повтор через</string>
+  <string name="trans_retryin">повторна спроба через</string>
   <string name="trans_failed">невдало</string>
   <string name="trans_suspended">призупинено</string>
   <string name="trans_active">активна</string>
@@ -283,7 +283,7 @@
   <string name="confirm_abort_trans_message">Перервати файл:</string>
   <string name="confirm_abort_trans_confirm">Перервати</string>
   <!--notices tab strings-->
-  <string name="notices_loading">Читальні примітки...</string>
+  <string name="notices_loading">Читання приміток...</string>
   <!--eventlog tab strings-->
   <string name="eventlog_loading">Завантаження повідомлень журналу...</string>
   <string name="eventlog_client_header">Повідомлення клієнта</string>
@@ -292,7 +292,7 @@
   <string name="eventlog_email_subject">Журнал подій для BOINC на Android:</string>
   <!--suspend reasons-->
   <string name="suspend_unknown">Обчислення призупинене.</string>
-  <string name="suspend_batteries">Підключіть свій пристрій до зарядного для продовження розрахунків.</string>
+  <string name="suspend_batteries">Підключіть свій пристрій до зарядного пристрою для продовження обчислення.</string>
   <string name="suspend_screen_on">Вимкніть екран для продовження обчислення.</string>
   <string name="suspend_useractive">Працює користувач.</string>
   <string name="suspend_tod">Закінчився час, виділений для обчислень.</string>
@@ -306,12 +306,12 @@
   <string name="suspend_network_quota">BOINC досяг межі передачі даних мережею.</string>
   <string name="suspend_os">Зупинено Android-ом.</string>
   <string name="suspend_wifi">Відсутнє підключення до WiFi.</string>
-  <string name="suspend_battery_charging">Очікування більшого рівня заряду акумулятора</string>
-  <string name="suspend_battery_charging_long">Розрахунки продовжаться, коли заряд батареї досягне</string>
+  <string name="suspend_battery_charging">Очікування більшого рівня заряду акумулятора.</string>
+  <string name="suspend_battery_charging_long">Обчислення продовжаться, коли заряд батареї досягне</string>
   <string name="suspend_battery_charging_long2"></string>
   <string name="suspend_battery_charging_current">зараз</string>
-  <string name="suspend_battery_overheating">Очікування охолодження батареї</string>
-  <string name="suspend_user_req">Поновлення розрахунків...</string>
+  <string name="suspend_battery_overheating">Очікування охолодження акумулятора</string>
+  <string name="suspend_user_req">Поновлення обчислень...</string>
   <string name="suspend_network_user_req">вручну.</string>
   <!--rpc reasons-->
   <string name="rpcreason_userreq">На вимогу користувача</string>
@@ -330,15 +330,15 @@
   <string name="menu_exit">Вийти з BOINC</string>
   <string name="menu_run_mode_disable">Призупинити</string>
   <string name="menu_run_mode_enable">Відновити</string>
-  <string name="menu_about">Про</string>
+  <string name="menu_about">Про додаток</string>
   <string name="menu_help">Довідка</string>
   <!--about dialog-->
   <string name="about_button">Повернутися</string>
-  <string name="about_title">Про</string>
+  <string name="about_title">Про додаток</string>
   <string name="about_name">BOINC</string>
   <string name="about_version">Версія</string>
   <string name="about_name_long">Відкрита інфраструктура для розподілених обчислень університету Берклі</string>
-  <string name="about_copyright">© 2003-2013 Університет Каліфорнії, Берклі.\nВсі права захищено.</string>
+  <string name="about_copyright">© 2003-2014 Університет Каліфорнії, Берклі.\nВсі права захищено.</string>
   <string name="about_copyright_reserved">Всі права захищені.</string>
   <string name="about_credits">Дякуємо Max Planck Institute for Gravitational Physics, IBM Corporation та HTC Corporation за їх підтримку.</string>
   <!--notice notification-->
@@ -348,7 +348,7 @@
   <!--e.g. 3 new notices-->
   <!--multi BOINC compitability-->
   <string name="nonexcl_dialog_header">Знайдено додаток добровільних обчислень</string>
-  <string name="nonexcl_dialog_text">Інший додаток добровільних обчислень вже працює на цїому пристрої. Тільки один додаток може працювати одночасно.</string>
+  <string name="nonexcl_dialog_text">Інший додаток добровільних обчислень вже працює на цьому пристрої. Тільки один додаток може працювати одночасно.</string>
   <string name="nonexcl_dialog_exit">Вийти</string>
   <!--social integration-->
   <string name="social_invite_button">Запросити друзів</string>
diff --git a/client/client_state.cpp b/client/client_state.cpp
index 56d4b28..2a120ec 100644
--- a/client/client_state.cpp
+++ b/client/client_state.cpp
@@ -188,13 +188,6 @@ CLIENT_STATE::CLIENT_STATE()
 #endif
 }
 
-CLIENT_STATE::~CLIENT_STATE() {
-    delete pers_file_xfers;
-#ifndef SIM
-    delete scheduler_op;
-#endif
-}
-
 void CLIENT_STATE::show_host_info() {
     char buf[256], buf2[256];
 
@@ -404,14 +397,14 @@ bool CLIENT_STATE::is_new_client() {
 }
 
 #ifdef _WIN32
-typedef DWORD (WINAPI *SPC)(HANDLE, DWORD);
+typedef DWORD (WINAPI *STP)(HANDLE, DWORD);
 #endif
 
 static void set_client_priority() {
 #ifdef _WIN32
-    SPC spc = (SPC) GetProcAddress(GetModuleHandle(_T("kernel32.dll")), "SetPriorityClass");
-    if (!spc) return;
-    if (spc(GetCurrentProcess(), PROCESS_MODE_BACKGROUND_BEGIN)) {
+    STP stp = (STP) GetProcAddress(GetModuleHandle(_T("kernel32.dll")), "SetThreadPriority");
+    if (!stp) return;
+    if (stp(GetCurrentThread(), THREAD_MODE_BACKGROUND_BEGIN)) {
         msg_printf(NULL, MSG_INFO, "Running at background priority");
     } else {
         msg_printf(NULL, MSG_INFO, "Failed to set background priority");
@@ -467,9 +460,9 @@ int CLIENT_STATE::init() {
 
     msg_printf(NULL, MSG_INFO, "Libraries: %s", curl_version());
 
-#ifdef _WIN32
-    set_client_priority();
-#endif
+    if (!cc_config.dont_lower_client_priority) {
+        set_client_priority();
+    }
 
     if (executing_as_daemon) {
 #ifdef _WIN32
diff --git a/client/client_state.h b/client/client_state.h
index f428a05..db1533c 100644
--- a/client/client_state.h
+++ b/client/client_state.h
@@ -246,7 +246,6 @@ struct CLIENT_STATE {
 
 // --------------- client_state.cpp:
     CLIENT_STATE();
-    ~CLIENT_STATE();
     void show_host_info();
     bool is_new_client();
     int init();
diff --git a/client/cs_prefs.cpp b/client/cs_prefs.cpp
index 036b2e4..8572b2f 100644
--- a/client/cs_prefs.cpp
+++ b/client/cs_prefs.cpp
@@ -704,7 +704,7 @@ void CLIENT_STATE::read_global_prefs(
     if (global_prefs.max_bytes_sec_up) {
         msg_printf(NULL, MSG_INFO,
             "   max upload rate: %.0f bytes/sec",
-            global_prefs.max_bytes_sec_up, 0
+            global_prefs.max_bytes_sec_up
         );
     }
 #ifndef SIM
diff --git a/client/cs_scheduler.cpp b/client/cs_scheduler.cpp
index fb44134..d782829 100644
--- a/client/cs_scheduler.cpp
+++ b/client/cs_scheduler.cpp
@@ -605,8 +605,8 @@ int CLIENT_STATE::handle_scheduler_reply(
                     sr.master_url
                 );
             } else {
-                msg_printf(project, MSG_INFO,
-                    _("You used the wrong URL for this project.  When convenient, remove this project, then add %s"),
+                msg_printf(project, MSG_USER_ALERT,
+                    _("This project is using an old URL.  When convenient, remove the project, then add %s"),
                     sr.master_url
                 );
             }
diff --git a/client/gpu_nvidia.cpp b/client/gpu_nvidia.cpp
index 8d7f16b..d12ab11 100644
--- a/client/gpu_nvidia.cpp
+++ b/client/gpu_nvidia.cpp
@@ -455,6 +455,7 @@ void COPROC_NVIDIA::correlate(
     //
     bool first = true;
     for (i=0; i<nvidia_gpus.size(); i++) {
+        nvidia_gpus[i].is_used = COPROC_IGNORED;
         if (in_vector(nvidia_gpus[i].device_num, ignore_devs)) continue;
 #ifdef __APPLE__
         if ((nvidia_gpus[i].cuda_version >= 6050) && nvidia_gpus[i].prop.major < 2) {
diff --git a/client/log_flags.cpp b/client/log_flags.cpp
index fa4b41f..7bc128b 100644
--- a/client/log_flags.cpp
+++ b/client/log_flags.cpp
@@ -188,6 +188,9 @@ void CC_CONFIG::show() {
     if (dont_check_file_sizes) {
         msg_printf(NULL, MSG_INFO, "Config: don't check file sizes");
     }
+    if (dont_lower_client_priority) {
+        msg_printf(NULL, MSG_INFO, "Config: don't lower client priority");
+    }
     if (dont_suspend_nci) {
         msg_printf(NULL, MSG_INFO, "Config: don't suspend NCI tasks");
     }
@@ -346,6 +349,7 @@ int CC_CONFIG::parse_options_client(XML_PARSER& xp) {
         if (xp.parse_bool("disallow_attach", disallow_attach)) continue;
         if (xp.parse_bool("dont_check_file_sizes", dont_check_file_sizes)) continue;
         if (xp.parse_bool("dont_contact_ref_site", dont_contact_ref_site)) continue;
+        if (xp.parse_bool("dont_lower_client_priority", dont_lower_client_priority)) continue;
         if (xp.parse_bool("dont_suspend_nci", dont_suspend_nci)) continue;
         if (xp.parse_bool("dont_use_vbox", dont_use_vbox)) continue;
         if (xp.match_tag("exclude_gpu")) {
diff --git a/clientgui/DlgItemProperties.cpp b/clientgui/DlgItemProperties.cpp
index 393dd84..538a1ef 100644
--- a/clientgui/DlgItemProperties.cpp
+++ b/clientgui/DlgItemProperties.cpp
@@ -393,7 +393,7 @@ void CDlgItemProperties::renderInfos(RESULT* result) {
             addProperty(_("Elapsed time"), FormatTime(result->elapsed_time));
         }
         addProperty(_("Estimated time remaining"), FormatTime(result->estimated_cpu_time_remaining));
-        addProperty(_("Fraction done"), wxString::Format(wxT("%.3f %%"), result->fraction_done*100));
+        addProperty(_("Fraction done"), wxString::Format(wxT("%.3f%%"), result->fraction_done*100));
         addProperty(_("Virtual memory size"), FormatDiskSpace(result->swap_size));
         addProperty(_("Working set size"), FormatDiskSpace(result->working_set_size_smoothed));
         if (result->slot >= 0) {
@@ -402,6 +402,17 @@ void CDlgItemProperties::renderInfos(RESULT* result) {
         if (result->pid) {
             addProperty(_("Process ID"), wxString::Format(wxT("%d"), result->pid));
         }
+        if (result->progress_rate) {
+            // express rate in the largest time unit (hr/min/sec) for which rate < 100%
+            //
+            if (result->progress_rate*3600 < 1) {
+                addProperty(_("Progress rate"), wxString::Format(wxT("%.3f%% %s"), 100*3600*result->progress_rate, _("per hour")));
+            } else if (result->progress_rate*60 < 1) {
+                addProperty(_("Progress rate"), wxString::Format(wxT("%.3f%% %s"), 100*60*result->progress_rate, _("per minute")));
+            } else {
+                addProperty(_("Progress rate"), wxString::Format(wxT("%.3f%% %s"), 100*result->progress_rate, _("per second")));
+            }
+        }
     } else if (result->state >= RESULT_COMPUTE_ERROR) {
         addProperty(_("CPU time"), FormatTime(result->final_cpu_time));
         addProperty(_("Elapsed time"), FormatTime(result->final_elapsed_time));
diff --git a/clientgui/MainDocument.cpp b/clientgui/MainDocument.cpp
index c3d38f1..9fa22c4 100644
--- a/clientgui/MainDocument.cpp
+++ b/clientgui/MainDocument.cpp
@@ -2683,7 +2683,7 @@ wxBitmap GetScaledBitmapFromXPMData(const char** XPMData) {
 }
 
 wxString FormatTime(double secs) {
-    if (secs < 0) {
+    if (secs <= 0) {
         return wxT("---");
     }
     wxInt32 iHour = (wxInt32)(secs / (60 * 60));
diff --git a/clientgui/browser.cpp b/clientgui/browser.cpp
index 9c1841e..312c6e3 100644
--- a/clientgui/browser.cpp
+++ b/clientgui/browser.cpp
@@ -346,6 +346,8 @@ int MOZILLA_PROFILES::parse(MIOFILE& in) {
             p = new MOZILLA_PROFILE;
             if (!p->parse( in )) {
                 profiles.push_back( p );
+            } else {
+                delete p;
             }
         }
     }
diff --git a/clientgui/sg_ProjectPanel.cpp b/clientgui/sg_ProjectPanel.cpp
index 8ee07f9..41a22fc 100644
--- a/clientgui/sg_ProjectPanel.cpp
+++ b/clientgui/sg_ProjectPanel.cpp
@@ -251,6 +251,7 @@ void CSimpleProjectPanel::UpdateInterface() {
         if (strcmp(m_CurrentSelectedProjectURL, ctrl_url)) {
             b_needMenuRebuild = true;
             strncpy(m_CurrentSelectedProjectURL, ctrl_url, sizeof(m_CurrentSelectedProjectURL));
+            m_CurrentSelectedProjectURL[sizeof(m_CurrentSelectedProjectURL)-1] = '\0';
         }
         
         PROJECT* project = pDoc->state.lookup_project(ctrl_url);
@@ -459,6 +460,7 @@ void CSimpleProjectPanel::UpdateProjectList() {
 #endif
                 selData = new ProjectSelectionData;
                 strncpy(selData->project_url, project->master_url, sizeof(selData->project_url));
+                selData->project_url[sizeof(selData->project_url)-1] = '\0';
                 selData->project_files_downloaded_time = project->project_files_downloaded_time;
                 wxBitmap* projectBM = GetProjectSpecificBitmap(selData->project_url);
 #if SORTPROJECTLIST
diff --git a/clientgui/sg_TaskPanel.cpp b/clientgui/sg_TaskPanel.cpp
index aca12c1..86a5fd8 100644
--- a/clientgui/sg_TaskPanel.cpp
+++ b/clientgui/sg_TaskPanel.cpp
@@ -1012,7 +1012,9 @@ void CSimpleTaskPanel::UpdateTaskSelectionList(bool reskin) {
             selData = new TaskSelectionData;
             selData->result = result;
             strncpy(selData->result_name, result->name, sizeof(selData->result_name));
+            selData->result_name[sizeof(selData->result_name)-1] = '\0';
             strncpy(selData->project_url, result->project_url, sizeof(selData->project_url));
+            selData->project_url[sizeof(selData->project_url)-1] = '\0';
             selData->dotColor = -1;
             FindSlideShowFiles(selData);
             project = pDoc->state.lookup_project(result->project_url);
diff --git a/configure.ac b/configure.ac
index bb5fb7d..5a79eac 100644
--- a/configure.ac
+++ b/configure.ac
@@ -6,7 +6,7 @@ dnl not sure exactly what the minimum version is (but 2.13 wont work)
 AC_PREREQ(2.58)
 
 dnl Set the BOINC version here.  You can also use the set-version script.
-AC_INIT(BOINC, 7.6.15)
+AC_INIT(BOINC, 7.6.17)
 AC_CONFIG_MACRO_DIR([m4])
 LIBBOINC_VERSION=`echo ${PACKAGE_VERSION} | sed 's/\./:/g'`
 AC_SUBST([LIBBOINC_VERSION])
diff --git a/coverity-model.cpp b/coverity-model.cpp
new file mode 100644
index 0000000..8ef4f4b
--- /dev/null
+++ b/coverity-model.cpp
@@ -0,0 +1,42 @@
+// This file is part of BOINC.
+// http://boinc.berkeley.edu
+// Copyright (C) 2015 University of California
+//
+// BOINC is free software; you can redistribute it and/or modify it
+// under the terms of the GNU Lesser General Public License
+// as published by the Free Software Foundation,
+// either version 3 of the License, or (at your option) any later version.
+//
+// BOINC is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
+// See the GNU Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public License
+// along with BOINC.  If not, see <http://www.gnu.org/licenses/>.
+
+/*
+ * Coverity Scan Modeling file for BOINC
+ * 
+ * This defines behaviour of functions that Coverity Scan is not aware of.
+ * 
+ * For how to create a model see: 
+ * https://scan.coverity.com/tune and https://scan.coverity.com/models#overriding
+ * 
+ * If you add anything here it has no immediate effect. A user with the 
+ * Maintainer/Owner role on scan.coverity.com has to upload the file to 
+ * https://scan.coverity.com/projects/boinc-boinc?tab=analysis_settings
+ * 
+ **/
+
+// the dir string is kind of sanitized here
+// prevents tainted string defects involving SCHED_CONFIG::project_path()
+//
+bool is_project_dir(const char *dir) {
+    bool ok_string;
+    if (ok_string == true) {
+        __coverity_tainted_string_sanitize_content__((void*)dir);
+        return true;
+    }
+    return false;
+}
\ No newline at end of file
diff --git a/dcapi/.gitattributes b/dcapi/.gitattributes
deleted file mode 100644
index 1665cfe..0000000
--- a/dcapi/.gitattributes
+++ /dev/null
@@ -1,25 +0,0 @@
-# Specify a generic set of rules to help avoid line feed issues across
-# various IDEs.
-#
-
-# Source files
-#
-*.cpp                   text eol=lf
-*.h                     text eol=lf
-*.rc                    text eol=lf
-*.php                   text eol=lf
-*.c                     text eol=lf
-
-# Project files
-#
-*.vcproj                text eol=crlf
-*.sln                   text eol=crlf
-*.ac                    text eol=lf
-*.am                    text eol=lf
-*.in                    text eol=lf
-*.m4                    text eol=lf
-
-# Commit Notes
-#
-checkin_notes           text eol=lf
-checkin_notes_2012      text eol=lf
diff --git a/dcapi/COPYING b/dcapi/COPYING
deleted file mode 100644
index cf0118f..0000000
--- a/dcapi/COPYING
+++ /dev/null
@@ -1,119 +0,0 @@
-END USER LICENSE AGREEMENT FOR THE ACADEMIC VERSION OF DC-API SOFTWARE
-
-WARNING: ACADEMIC VERSION OF DC-API SOFTWARE IS FOR NON-COMMERCIAL USE ONLY
-
-This End User License Agreement ("EULA") is a legal agreement between you
-("LICENSEE") (either an individual or a single entity) and MTA SZTAKI, Computer
-and Automation Research Institute, Hungarian Academy of Sciences, Hungary ("MTA
-SZTAKI") for academic use of the software product DC-API development toolset,
-which includes computer software, sample applications and electronic
-documentation (collectively the "SOFTWARE").
-
-For your guidance
-- Academic use includes any activities where fees are not charged, including
-  but not limited to;
-  a) Research activities where the research results are available for free
-     distribution.
-  b) Educational teaching activities (as distinct from Training Programmes
-     below).
-- Commercial use includes any activities where fees are charged, including but
-  not limited to;
-  a) Consultancy
-  b) Training programmes
-  c) Research activities where the research results are not available for free
-     distribution.
-  d) Research activities where research results are released in such a manner
-     that commercial advantage can be gained by a receiving organisation.
-
-You agree that the aggregation of Academic use and Commercial use constitutes
-all uses or potential uses of the SOFTWARE.
-
-Concerning Academic use; any academic report, publication, webpage, or other
-academic disclosure of results obtained with this SOFTWARE must acknowledge
-this SOFTWARE's use by an appropriate citation.
-
-Read the EULA carefully before completing the installation process and using
-the SOFTWARE. If you did not obtain this copy of the SOFTWARE legally, please
-destroy the copy immediately. By installing, copying, or otherwise using the
-SOFTWARE, you agree to be bound by the terms of this EULA.
-
-If you do not agree to the terms of this EULA, MTA SZTAKI is unwilling to
-license the SOFTWARE. In such event, you may not install, copy or otherwise use
-the SOFTWARE.
-
-YOU AGREE THAT YOUR USE OF THE SOFTWARE ACKNOWLEDGES THAT YOU HAVE READ THIS
-LICENSE, UNDERSTOOD IT, AND AGREE TO BE BOUND BY ITS TERMS AND CONDITIONS.
-
-Furthermore you hereby declare that you understand that this is an academic
-license and that a commercial license for the use of this software exists. You
-agree that contravention of the academic license may result in a liability
-arising for historic, current and future license payments under the terms of
-the prevailing commercial license that was in effect during the time period of
-the contravention.
-
-1. License
-
-Subject to the terms and conditions of this EULA, MTA SZTAKI grants you,
-LICENSEE, a non-exclusive, non-transferable limited license to install and use
-one (1) copy of the SOFTWARE, solely for demonstration, testing, educational,
-evaluation purposes and for academic research. LICENSEE may make one (1) copy
-of the SOFTWARE solely for backup or archival purposes, provided that LICENSEE
-reproduces and includes all copyright and other proprietary notice(s) on the
-copy.
-
-2. Restrictions
-
-LICENSEE may NOT:
-  (i) Rent, lease, lend, transfer, distribute or otherwise transfer rights to the
-      SOFTWARE for any purposes.
- (ii) Remove any proprietary notices or labels on the SOFTWARE.
-(iii) Modify the SOFTWARE.
- (iv) Reverse engineer or decompile, decrypt, disassemble or otherwise reduce
-      the SOFTWARE to human-readable form.
-  (v) Use the software for commercial purposes.
-
-3. Ownership
-
-The SOFTWARE is licensed, NOT sold. The foregoing EULA gives LICENSEE limited
-rights to use the SOFTWARE. All rights, title and interest, including all
-copyrights, in and to the SOFTWARE and any copies LICENSEE is permitted to make
-herein are exclusively owned by MTA SZTAKI. MTA SZTAKI retains all rights not
-expressly granted to LICENSEE in this EULA.
-
-4. Disclaimer of Warranties
-
-THE SOFTWARE IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND. TO THE MAXIMUM
-EXTENT PERMITTED BY APPLICABLE LAW, MTA SZTAKI DISCLAIMS ALL WARRANTIES, EITHER
-EXPRESS OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, IMPLIED WARRANTIES OF
-PERFORMANCE OR MERCHANDABILITY, FITNESS FOR A PARTICULAR PURPOSE, OR
-NON-INFRINGEMENT WITH REGARD TO THE SOFTWARE. ANY OTHER SOFTWARE, ANY OTHER
-HARDWARE, AND ANY OTHER WRITTEN MATERIAL FURNISHED WITH OR ACCOMPANYING THE
-SOFTWARE IS NOT WARRANTED BY MTA SZTAKI. MTA SZTAKI DOES NOT WARRANT THAT THE
-SOFTWARE WILL MEET LICENSEE REQUIREMENTS, OPERATE WITHOUT INTERRUPTION OR BE
-ERROR-FREE.
-
-5. Limitation of Liability
-
-TO THE MAXIMUM EXTENT PERMITTED BY APPLICABLE LAW, IN NO EVENT SHALL MTA SZTAKI
-BE LIABLE FOR ANY CONSEQUENTIAL, INCIDENTAL, DIRECT, INDIRECT, SPECIAL,
-PUNITIVE OR OTHER DAMAGES WHATSOEVER (INCLUDING WITHOUT LIMITATION DAMAGES FOR
-LOSS OF BUSINESS PROFITS, BUSINESS INTERRUPTION, LOSS OF BUSINESS INFORMATION
-OR OTHER PECUNIARY LOSS) ARISING OUT OF THIS AGREEMENT OR CAUSED BY THE USE OR
-INABILITY TO USE THE SOFTWARE, EVEN IF MTA SZTAKI HAS BEEN ADVISED OF THE
-POSSIBILITY OF SUCH DAMAGES.
-
-6. Entire Agreement
-
-This EULA constitutes the entire agreement between LICENSEE and MTA SZTAKI and
-supersedes any other prior agreements or understandings, whether oral or
-written, regarding the SOFTWARE. If a provision of this agreement is deemed
-null and void, invalid or without effect, the remainder of this agreement shall
-remain in effect. This Agreement shall be governed by and construed under
-Hungarian law.
-
-7. Termination
-
-Without prejudice to any other rights, MTA SZTAKI may terminate this EULA if
-the licensee fails to comply with the terms and conditions of this EULA. In
-such an event, the LICENSEE must destroy all copies of the SOFTWARE and all of
-its component parts.
diff --git a/dcapi/INSTALL b/dcapi/INSTALL
deleted file mode 100644
index 5458714..0000000
--- a/dcapi/INSTALL
+++ /dev/null
@@ -1,234 +0,0 @@
-Installation Instructions
-*************************
-
-Copyright (C) 1994, 1995, 1996, 1999, 2000, 2001, 2002, 2004, 2005,
-2006 Free Software Foundation, Inc.
-
-This file is free documentation; the Free Software Foundation gives
-unlimited permission to copy, distribute and modify it.
-
-Basic Installation
-==================
-
-Briefly, the shell commands `./configure; make; make install' should
-configure, build, and install this package.  The following
-more-detailed instructions are generic; see the `README' file for
-instructions specific to this package.
-
-   The `configure' shell script attempts to guess correct values for
-various system-dependent variables used during compilation.  It uses
-those values to create a `Makefile' in each directory of the package.
-It may also create one or more `.h' files containing system-dependent
-definitions.  Finally, it creates a shell script `config.status' that
-you can run in the future to recreate the current configuration, and a
-file `config.log' containing compiler output (useful mainly for
-debugging `configure').
-
-   It can also use an optional file (typically called `config.cache'
-and enabled with `--cache-file=config.cache' or simply `-C') that saves
-the results of its tests to speed up reconfiguring.  Caching is
-disabled by default to prevent problems with accidental use of stale
-cache files.
-
-   If you need to do unusual things to compile the package, please try
-to figure out how `configure' could check whether to do them, and mail
-diffs or instructions to the address given in the `README' so they can
-be considered for the next release.  If you are using the cache, and at
-some point `config.cache' contains results you don't want to keep, you
-may remove or edit it.
-
-   The file `configure.ac' (or `configure.in') is used to create
-`configure' by a program called `autoconf'.  You need `configure.ac' if
-you want to change it or regenerate `configure' using a newer version
-of `autoconf'.
-
-The simplest way to compile this package is:
-
-  1. `cd' to the directory containing the package's source code and type
-     `./configure' to configure the package for your system.
-
-     Running `configure' might take a while.  While running, it prints
-     some messages telling which features it is checking for.
-
-  2. Type `make' to compile the package.
-
-  3. Optionally, type `make check' to run any self-tests that come with
-     the package.
-
-  4. Type `make install' to install the programs and any data files and
-     documentation.
-
-  5. You can remove the program binaries and object files from the
-     source code directory by typing `make clean'.  To also remove the
-     files that `configure' created (so you can compile the package for
-     a different kind of computer), type `make distclean'.  There is
-     also a `make maintainer-clean' target, but that is intended mainly
-     for the package's developers.  If you use it, you may have to get
-     all sorts of other programs in order to regenerate files that came
-     with the distribution.
-
-Compilers and Options
-=====================
-
-Some systems require unusual options for compilation or linking that the
-`configure' script does not know about.  Run `./configure --help' for
-details on some of the pertinent environment variables.
-
-   You can give `configure' initial values for configuration parameters
-by setting variables in the command line or in the environment.  Here
-is an example:
-
-     ./configure CC=c99 CFLAGS=-g LIBS=-lposix
-
-   *Note Defining Variables::, for more details.
-
-Compiling For Multiple Architectures
-====================================
-
-You can compile the package for more than one kind of computer at the
-same time, by placing the object files for each architecture in their
-own directory.  To do this, you can use GNU `make'.  `cd' to the
-directory where you want the object files and executables to go and run
-the `configure' script.  `configure' automatically checks for the
-source code in the directory that `configure' is in and in `..'.
-
-   With a non-GNU `make', it is safer to compile the package for one
-architecture at a time in the source code directory.  After you have
-installed the package for one architecture, use `make distclean' before
-reconfiguring for another architecture.
-
-Installation Names
-==================
-
-By default, `make install' installs the package's commands under
-`/usr/local/bin', include files under `/usr/local/include', etc.  You
-can specify an installation prefix other than `/usr/local' by giving
-`configure' the option `--prefix=PREFIX'.
-
-   You can specify separate installation prefixes for
-architecture-specific files and architecture-independent files.  If you
-pass the option `--exec-prefix=PREFIX' to `configure', the package uses
-PREFIX as the prefix for installing programs and libraries.
-Documentation and other data files still use the regular prefix.
-
-   In addition, if you use an unusual directory layout you can give
-options like `--bindir=DIR' to specify different values for particular
-kinds of files.  Run `configure --help' for a list of the directories
-you can set and what kinds of files go in them.
-
-   If the package supports it, you can cause programs to be installed
-with an extra prefix or suffix on their names by giving `configure' the
-option `--program-prefix=PREFIX' or `--program-suffix=SUFFIX'.
-
-Optional Features
-=================
-
-Some packages pay attention to `--enable-FEATURE' options to
-`configure', where FEATURE indicates an optional part of the package.
-They may also pay attention to `--with-PACKAGE' options, where PACKAGE
-is something like `gnu-as' or `x' (for the X Window System).  The
-`README' should mention any `--enable-' and `--with-' options that the
-package recognizes.
-
-   For packages that use the X Window System, `configure' can usually
-find the X include and library files automatically, but if it doesn't,
-you can use the `configure' options `--x-includes=DIR' and
-`--x-libraries=DIR' to specify their locations.
-
-Specifying the System Type
-==========================
-
-There may be some features `configure' cannot figure out automatically,
-but needs to determine by the type of machine the package will run on.
-Usually, assuming the package is built to be run on the _same_
-architectures, `configure' can figure that out, but if it prints a
-message saying it cannot guess the machine type, give it the
-`--build=TYPE' option.  TYPE can either be a short name for the system
-type, such as `sun4', or a canonical name which has the form:
-
-     CPU-COMPANY-SYSTEM
-
-where SYSTEM can have one of these forms:
-
-     OS KERNEL-OS
-
-   See the file `config.sub' for the possible values of each field.  If
-`config.sub' isn't included in this package, then this package doesn't
-need to know the machine type.
-
-   If you are _building_ compiler tools for cross-compiling, you should
-use the option `--target=TYPE' to select the type of system they will
-produce code for.
-
-   If you want to _use_ a cross compiler, that generates code for a
-platform different from the build platform, you should specify the
-"host" platform (i.e., that on which the generated programs will
-eventually be run) with `--host=TYPE'.
-
-Sharing Defaults
-================
-
-If you want to set default values for `configure' scripts to share, you
-can create a site shell script called `config.site' that gives default
-values for variables like `CC', `cache_file', and `prefix'.
-`configure' looks for `PREFIX/share/config.site' if it exists, then
-`PREFIX/etc/config.site' if it exists.  Or, you can set the
-`CONFIG_SITE' environment variable to the location of the site script.
-A warning: not all `configure' scripts look for a site script.
-
-Defining Variables
-==================
-
-Variables not defined in a site shell script can be set in the
-environment passed to `configure'.  However, some packages may run
-configure again during the build, and the customized values of these
-variables may be lost.  In order to avoid this problem, you should set
-them in the `configure' command line, using `VAR=value'.  For example:
-
-     ./configure CC=/usr/local2/bin/gcc
-
-causes the specified `gcc' to be used as the C compiler (unless it is
-overridden in the site shell script).
-
-Unfortunately, this technique does not work for `CONFIG_SHELL' due to
-an Autoconf bug.  Until the bug is fixed you can use this workaround:
-
-     CONFIG_SHELL=/bin/bash /bin/bash ./configure CONFIG_SHELL=/bin/bash
-
-`configure' Invocation
-======================
-
-`configure' recognizes the following options to control how it operates.
-
-`--help'
-`-h'
-     Print a summary of the options to `configure', and exit.
-
-`--version'
-`-V'
-     Print the version of Autoconf used to generate the `configure'
-     script, and exit.
-
-`--cache-file=FILE'
-     Enable the cache: use and save the results of the tests in FILE,
-     traditionally `config.cache'.  FILE defaults to `/dev/null' to
-     disable caching.
-
-`--config-cache'
-`-C'
-     Alias for `--cache-file=config.cache'.
-
-`--quiet'
-`--silent'
-`-q'
-     Do not print messages saying which checks are being made.  To
-     suppress all normal output, redirect it to `/dev/null' (any error
-     messages will still be shown).
-
-`--srcdir=DIR'
-     Look for the package's source code in directory DIR.  Usually
-     `configure' can determine that directory automatically.
-
-`configure' also accepts some other, not widely useful, options.  Run
-`configure --help' for more details.
-
diff --git a/dcapi/Makefile.am b/dcapi/Makefile.am
deleted file mode 100644
index 7769f7c..0000000
--- a/dcapi/Makefile.am
+++ /dev/null
@@ -1,25 +0,0 @@
-ACLOCAL_AMFLAGS = -I cf
-AUTOMAKE_OPTIONS = foreign 1.7
-
-SUBDIRS = include common doc
-
-EXTRA_DIST = _autosetup.sh
-
-if WITH_BOINC
-SUBDIRS += boinc
-endif
-
-if WITH_CONDOR
-SUBDIRS += condor
-endif
-
-if WITH_LOCAL
-SUBDIRS += local
-endif
-
-if HAVE_JAVA
-SUBDIRS += java
-endif
-
-aclocaldir = $(datadir)/aclocal
-dist_aclocal_DATA = dcapi.m4
diff --git a/dcapi/README-MinGW32 b/dcapi/README-MinGW32
deleted file mode 100644
index 6b50b88..0000000
--- a/dcapi/README-MinGW32
+++ /dev/null
@@ -1,71 +0,0 @@
-
- This README details the instructions required for compiling DC-API BOINC client libs 
- on MinGW32. Alternatively we provide a package containing precompiled libraries (see
- http://doc.desktopgrid.hu/doku.php?id=manual:dc-api&#linux_mingw32cross-compiling_for_windows
- for details.)
-
-
- 1. Requirements
-
- - Debian 6.0
-
-
- 2. Compiling DC-API on MinGW32
-
- 2.1 As root run:
-
- $> apt-get update && apt-get upgrade
- $> apt-get install mingw32
- $> apt-get install autoconf libtool make
- $> apt-get install libglib2.0-dev  # DC-API: only needed for autoreconf to finish 
-                                    # (it would complain about missing glib2 libs)
- $> apt-get install gtk-doc-tools   # only needed for autoreconf to finish (it would 
-                                    # complain about gtk-doc missing)
-
-
- 2.2. Switch to some non-privileged user. You don't need to be root from now on. 
- Next run:
-
- $> cd ${HOME}
- $> mkdir -p w32-root/include
- $> mkdir -p w32-root/lib
-
-
- 2.3. Get the DC-API source and put it in ${HOME}/dcapi-trunk
-
-
- 2.4. Run:
-
- $> wget http://mirror.vcu.edu/pub/windows/cygwin/release/util-linux/libuuid-devel/libuuid-devel-2.21.2-1.tar.bz2
-
- Uncompress and copy include files to ${HOME}/w32-root/include/uuid/ and libraries to ${HOME}/w32-root/lib/
-
-
- 2.5. Get pthreads-w32-2.9.0-mingw32-pre-20110507-2-dev.tar.lzma from 
- http://sourceforge.net/projects/mingw/files/MinGW/Base/pthreads-w32/ Uncompress and 
- copy include files to ${HOME}/w32-root/include/ and libraries to ${HOME}/w32-root/lib/
-
-
- 2.6. Get our boinc lib package from (link is at the bottom of the section):
-
- http://doc.desktopgrid.hu/doku.php?id=manual:dc-api#linux_mingw32cross-compiling_for_windows
-
- uncompress, build the package following the instructions found in the README file.
- Finally copy includes to ${HOME}/w32-root/include/boinc/ and libraries to 
- ${HOME}/w32-root/lib.
-
-
- 2.7. Modify "-pthread" in dcapi-trunk/cf/boinc.m4 to "-lpthread" (at two places)
-
-
- 2.8. Finally execute the following:
-
- $> cd dcapi-trunk
- $> autoreconf --install --force --symlink
- $> ./configure --host=i586-mingw32msvc --disable-master --disable-backend-local \
-       --enable-backend-boinc --with-boinc=${HOME}/w32-root/ LDFLAGS=-L${HOME}/w32-root/lib \
-       --prefix=${HOME}/w32-root/ CPPFLAGS=-I${HOME}/w32-root/include/ LIBS="-lpsapi"
- $> make
- $> make install
-
-
diff --git a/dcapi/_autosetup.sh b/dcapi/_autosetup.sh
deleted file mode 100755
index f0c5d47..0000000
--- a/dcapi/_autosetup.sh
+++ /dev/null
@@ -1,4 +0,0 @@
-#!/bin/sh
-
-gtkdocize --copy
-autoreconf --install --force --symlink
diff --git a/dcapi/boinc/Makefile.am b/dcapi/boinc/Makefile.am
deleted file mode 100644
index 5655010..0000000
--- a/dcapi/boinc/Makefile.am
+++ /dev/null
@@ -1,39 +0,0 @@
-lib_LTLIBRARIES =
-
-AM_CPPFLAGS = -I$(top_srcdir)/include $(GLIB_CFLAGS)
-
-if BUILD_MASTER
-lib_LTLIBRARIES += libdcapi-boinc.la
-endif
-
-if BUILD_CLIENT
-lib_LTLIBRARIES += libdcapi-client-boinc.la
-endif
-
-pkgconfigdir = ${libdir}/pkgconfig
-pkgconfig_DATA = dcapi-boinc-client.pc dcapi-boinc-master.pc
-
-AM_LDFLAGS = $(BOINC_LDFLAGS) $(GLIB_LIBS)
-
-noinst_HEADERS = common_defs.h dc_boinc.h
-
-libdcapi_boinc_la_SOURCES = \
-		config.C \
-		dc.c \
-		db.C \
-		events.C \
-		result.c \
-		wu.C
-libdcapi_boinc_la_LIBADD = \
-		../common/libdcapi-common-master.la \
-		-lsched -lboinc -lcrypto -luuid -lm
-libdcapi_boinc_la_CPPFLAGS = $(AM_CPPFLAGS) $(BOINC_SERVER_CPPFLAGS)
-libdcapi_boinc_la_LDFLAGS = -version-info 1:1:0 -export-symbols $(top_srcdir)/common/master.sym
-
-libdcapi_client_boinc_la_SOURCES = \
-		client.C
-libdcapi_client_boinc_la_LIBADD = \
-		../common/libdcapi-common-client.la \
-		$(BOINC_CLIENT_LIBS)
-libdcapi_client_boinc_la_CPPFLAGS = $(AM_CPPFLAGS) $(BOINC_CPPFLAGS)
-libdcapi_client_boinc_la_LDFLAGS = -static
diff --git a/dcapi/boinc/client.C b/dcapi/boinc/client.C
deleted file mode 100644
index ac2172e..0000000
--- a/dcapi/boinc/client.C
+++ /dev/null
@@ -1,712 +0,0 @@
-/*
- * client.c - Client side of the BOINC DC-API backend
- *
- * Authors:
- *	Gábor Gombás <gombasg at sztaki.hu>
- *
- * Copyright (c) 2006 MTA SZTAKI
- */
-#ifdef HAVE_CONFIG_H
-#include <config.h>
-#endif
-
-#include <sys/types.h>
-#include <sys/stat.h>
-#include <stdlib.h>
-#include <string.h>
-#include <limits.h>
-#include <stdio.h>
-#include <unistd.h>
-
-#ifndef _WIN32
-#include <dirent.h>
-#endif
-
-/* BOINC includes */
-#ifdef _WIN32
-#include <boinc_win.h>
-#include <util.h>
-#endif
-
-#include <boinc_api.h>
-#include <filesys.h>
-#include <diagnostics.h>
-#include <graphics2.h>
-#include <parse.h>
-
-#include <dc_client.h>
-#include <dc_internal.h>
-
-#include "common_defs.h"
-
-/********************************************************************
- * Constants
- */
-
-typedef enum {
-	STATE_NORMAL,
-	STATE_SUSPEND,
-	STATE_FINISH
-} client_event_state;
-
-#define LAST_CKPT_FILE		"dc_lastckpt"
-
-#ifdef _WIN32
-#define PATHSEP			'\\'
-#define __func__		"DC-API"
-#else
-#define PATHSEP			'/'
-#endif
-
-
-/********************************************************************
- * Global variables
- */
-
-/* Checkpoint file generation counter */
-static int ckpt_generation;
-/* Name of the last completed checkpoint file */
-static char *last_complete_ckpt;
-/* Name of the active (not yet completed) checkpoint file */
-static char active_ckpt[PATH_MAX];
-/* Number of subresults already sent */
-static int subresult_cnt;
-/* Maximum number of allowed subresults */
-static int max_subresults;
-/* Name of the current work unit */
-static char wu_name[256];
-/* State machine for suspend */
-static client_event_state client_state;
-
-
-/********************************************************************
- * Common API functions
- */
-
-int DC_getMaxMessageSize(void)
-{
-	return MAX_MESSAGE_SIZE;
-}
-
-#ifdef _WIN32
-static void count_subresults(void)
-{
-	WIN32_FIND_DATA fdata;
-	HANDLE hfind;
-
-	hfind = FindFirstFile("*", &fdata);
-	if (hfind == INVALID_HANDLE_VALUE)
-		return;
-	do {
-		DC_log(LOG_DEBUG, "\t%s", fdata.cFileName);
-		if (!strncmp(fdata.cFileName, SUBRESULT_PFX,
-				strlen(SUBRESULT_PFX)))
-			max_subresults++;
-	} while (FindNextFile(hfind, &fdata));
-	FindClose(hfind);
-}
-#else
-static void count_subresults(void)
-{
-	struct dirent *d;
-	DIR *dir;
-
-	dir = opendir(".");
-	if (!dir)
-		return;
-
-	DC_log(LOG_DEBUG, "Workdir contents:");
-	while ((d = readdir(dir)))
-	{
-		DC_log(LOG_DEBUG, "\t%s", d->d_name);
-		if (!strncmp(d->d_name, SUBRESULT_PFX, strlen(SUBRESULT_PFX)))
-			max_subresults++;
-	}
-	closedir(dir);
-}
-#endif
-
-/* Determine the number of allowed subresults by counting all output files
- * that have a name starting with SUBRESULT_PFX */
-int DC_getMaxSubresults(void)
-{
-	if (max_subresults)
-		return max_subresults - subresult_cnt;
-
-	count_subresults();
-	return max_subresults;
-}
-
-unsigned DC_getGridCapabilities(void)
-{
-	char path[PATH_MAX];
-	unsigned caps;
-
-	caps = DC_GC_EXITCODE | DC_GC_MESSAGING;
-	if (DC_getMaxSubresults())
-		caps |= DC_GC_SUBRESULT;
-
-	if (!boinc_resolve_filename(DC_LABEL_STDOUT, path, sizeof(path)))
-		caps |= DC_GC_STDOUT;
-	if (!boinc_resolve_filename(DC_LABEL_STDERR, path, sizeof(path)))
-		caps |= DC_GC_STDERR;
-	if (!boinc_resolve_filename(DC_LABEL_CLIENTLOG, path, sizeof(path)))
-		caps |= DC_GC_LOG;
-
-	return caps;
-}
-
-/********************************************************************
- * Client API functions
- */
-
-int DC_initClient(void)
-{
-	char path[PATH_MAX], *buf, label[32];
-	int i, ret;
-	FILE *f;
-
-	/* We leave the redirection to BOINC and only copy stdout.txt/stderr.txt
-	 * to the final output location in DC_finishClient(). This means BOINC
-	 * can rotate the files so they won't grow too big. */
-	if (boinc_init_diagnostics(BOINC_DIAG_REDIRECTSTDERR |
-			BOINC_DIAG_REDIRECTSTDOUT))
-		return DC_ERR_INTERNAL;
-
-	if (boinc_init())
-		return DC_ERR_INTERNAL;
-
-	/* Parse the config file if the master sent one */
-	buf = DC_resolveFileName(DC_FILE_IN, DC_CONFIG_FILE);
-	if (buf)
-	{
-		ret = _DC_parseCfg(buf);
-		if (ret && ret != DC_ERR_SYSTEM)
-			return ret;
-	}
-	free(buf);
-
-	/* Check if we are starting from a checkpoint file */
-	if ((f = boinc_fopen(LAST_CKPT_FILE, "r")))
-	{
-		fgets(path, sizeof(path), f);
-		fclose(f);
-		if (strlen(path))
-			last_complete_ckpt = strdup(path);
-	}
-	/* If the application did not generate a checkpoint file before, check
-	 * if the master sent one */
-	else
-		last_complete_ckpt = DC_resolveFileName(DC_FILE_IN, CKPT_LABEL_IN);
-
-	if (last_complete_ckpt)
-		DC_log(LOG_INFO, "Found initial checkpoint file %s",
-			last_complete_ckpt);
-
-	/* Extract the WU name from init_data.xml */
-	if (boinc_is_standalone())
-	{
-		DC_log(LOG_NOTICE, "Running in stand-alone mode, some "
-			"functions are not available");
-		wu_name[0] = '\0';
-	}
-	else
-	{
-		APP_INIT_DATA init_data;
-
-		boinc_get_init_data(init_data);
-		strncpy(wu_name, init_data.wu_name, sizeof(wu_name));
-	}
-
-	/* Initialize all optional output files as empty to prevent
-	 * <file_xfer_error>s */
-	for (i = 0; i < DC_getMaxSubresults(); i++)
-	{
-		snprintf(label, sizeof(label), "%s%d", SUBRESULT_PFX, i);
-		if (boinc_resolve_filename(label, path, sizeof(path)))
-			continue;
-		f = boinc_fopen(path, "w");
-		if (f)
-			fclose(f);
-	}
-	ret = boinc_resolve_filename(CKPT_LABEL_OUT, path, sizeof(path));
-	if (!ret)
-	{
-		f = boinc_fopen(path, "w");
-		if (f)
-			fclose(f);
-	}
-
-	DC_log(LOG_INFO, "DC-API initialized for work unit %s", wu_name);
-
-	return 0;
-}
-
-char *DC_resolveFileName(DC_FileType type, const char *logicalFileName)
-{
-	char buf[PATH_MAX];
-	int ret;
-
-	if (!logicalFileName)
-	{
-		DC_log(LOG_ERR, "%s: Missing logical file name", __func__);
-		return NULL;
-	}
-
-	if (!strcmp(logicalFileName, DC_CHECKPOINT_FILE))
-	{
-		if (type == DC_FILE_IN)
-		{
-			if (last_complete_ckpt)
-				return strdup(last_complete_ckpt);
-			return NULL;
-		}
-		else if (type == DC_FILE_OUT)
-		{
-			/* Remove the previous checkpoint if it was not
-			 * finished */
-			if (strlen(active_ckpt))
-				unlink(active_ckpt);
-
-			snprintf(active_ckpt, sizeof(active_ckpt), "dc_ckpt_%d",
-				++ckpt_generation);
-			DC_log(LOG_DEBUG, "Opened new checkpoint file %s",
-				active_ckpt);
-			return strdup(active_ckpt);
-		}
-		else
-			return NULL;
-	}
-
-	/* Temporary files can be created in the current directory */
-	if (type == DC_FILE_TMP)
-		return strdup(logicalFileName);
-
-	ret = boinc_resolve_filename(logicalFileName, buf, sizeof(buf));
-	if (!ret) {
-        if (type == DC_FILE_IN) {
-    	    if (FILE * file = fopen(buf, "r")) 
-    	    {
-                fclose(file);
-        		return strdup(buf);	    
-    	    }
-            return NULL;
-    	}
-		return strdup(buf);	    
-	}
-
-	/* Do not fail for missing output files in stand-alone mode */
-	if (!wu_name[0] && type == DC_FILE_OUT)
-		return strdup(logicalFileName);
-	return NULL;
-}
-
-int DC_sendResult(const char *logicalFileName, const char *path,
-	DC_FileMode mode)
-{
-	char label[32], new_path[PATH_MAX], msg[PATH_MAX], *p;
-	int ret;
-
-	if (!logicalFileName)
-	{
-		DC_log(LOG_ERR, "%s: Missing logical file name", __func__);
-		return DC_ERR_BADPARAM;
-	}
-	if (!path)
-	{
-		DC_log(LOG_ERR, "%s: Missing path", __func__);
-		return DC_ERR_BADPARAM;
-	}
-
-	if (!DC_getMaxSubresults())
-	{
-		DC_log(LOG_ERR, "No more subresults are allowed to be sent");
-		return DC_ERR_NOTIMPL;
-	}
-
-	/* We have to use the subresult labels that were defined by the
-	 * master for doing the upload */
-	snprintf(label, sizeof(label), "%s%d", SUBRESULT_PFX, ++subresult_cnt);
-	if (boinc_resolve_filename(label, new_path, sizeof(new_path)))
-		return DC_ERR_INTERNAL;
-
-	/* We need the file name that will appear on the server */
-	p = strrchr(new_path, PATHSEP);
-	if (!p)
-	{
-		DC_log(LOG_ERR, "Failed to determine the on-server file name "
-			"of the subresult");
-		return DC_ERR_INTERNAL;
-	}
-	p++;
-
-	switch (mode)
-	{
-		case DC_FILE_REGULAR:
-			ret = _DC_copyFile(path, new_path);
-			if (ret)
-				return DC_ERR_SYSTEM;
-			break;
-		case DC_FILE_PERSISTENT:
-#ifndef _WIN32
-			ret = link(path, new_path);
-			if (!ret)
-				break;
-#endif
-			/* The client system may not support hard links so
-			 * fall back to copying silently */
-			ret = _DC_copyFile(path, new_path);
-			if (ret)
-				return DC_ERR_SYSTEM;
-			break;
-		case DC_FILE_VOLATILE:
-			ret = rename(path, new_path);
-			if (!ret)
-				break;
-			/* If renaming fails, fall back to copying, but in this
-			 * case we are also responsible for deleting the
-			 * original */
-			ret = _DC_copyFile(path, new_path);
-			if (ret)
-				return DC_ERR_SYSTEM;
-			break;
-		case DC_FILE_REMOTE:
-			/* Ignore this case, entirely handled by BOINC */
-			break;
-	}
-
-	/* Stupid C++ */
-	std::string str = label;
-	ret = boinc_upload_file(str);
-	if (ret)
-	{
-		unlink(new_path);
-		return DC_ERR_INTERNAL;
-	}
-
-	DC_log(LOG_INFO, "File %s (%s) has been scheduled for upload",
-		logicalFileName, label);
-
-	snprintf(msg, sizeof(msg), "%s:%s:%s:%s", DCAPI_MSG_PFX, DC_MSG_UPLOAD,
-		p, logicalFileName);
-	DC_sendMessage(msg);
-
-	/* If we had to copy volatile files, delete the original only when
-	 * we are sure the upload will happen */
-	if (mode == DC_FILE_VOLATILE)
-		unlink(path);
-	return 0;
-}
-
-int DC_sendMessage(const char *message)
-{
-	char *xml, *msg;
-	int ret, len;
-
-	if (!message)
-	{
-		DC_log(LOG_ERR, "%s: Missing message", __func__);
-		return DC_ERR_BADPARAM;
-	}
-
-	if (!wu_name[0])
-	{
-		DC_log(LOG_ERR, "Messaging is not available in stand-alone mode");
-		return DC_ERR_NOTIMPL;
-	}
-
-	int buflen = 6 * strlen(message) + 1;
-	xml = (char *)malloc(buflen);
-	if (!xml)
-	{
-		DC_log(LOG_ERR, "Sending message: Out of memory");
-		return DC_ERR_INTERNAL;
-	}
-
-	xml_escape(message, xml, buflen);
-	len = strlen(xml) + 24;
-	msg = (char *)malloc(len);
-	if (!msg)
-	{
-		DC_log(LOG_ERR, "Sending message: Out of memory");
-		free(xml);
-		return DC_ERR_INTERNAL;
-	}
-	snprintf(msg, len, "<message>%s</message>", xml);
-
-	/* We use the WU's name as the variety */
-	ret = boinc_send_trickle_up(wu_name, msg);
-	free(msg);
-	free(xml);
-	if (ret)
-	{
-		DC_log(LOG_ERR, "Failed to send trickle-up message");
-		return DC_ERR_INTERNAL;
-	}
-	return 0;
-}
-
-static DC_ClientEvent *new_event(DC_ClientEventType type)
-{
-	DC_ClientEvent *event;
-
-	event = (DC_ClientEvent *)calloc(1, sizeof(DC_ClientEvent));
-	event->type = type;
-	return event;
-}
-
-static DC_ClientEvent *handle_special_msg(const char *message)
-{
-	if (!strncmp(message, DC_MSG_CANCEL, strlen(DC_MSG_CANCEL)) &&
-			message[strlen(DC_MSG_CANCEL)] == ':')
-	{
-		if (strcmp(message + strlen(DC_MSG_CANCEL) + 1, wu_name))
-		{
-			DC_log(LOG_WARNING, "Received CANCEL message for "
-				"unknown WU %s",
-				message + strlen(DC_MSG_CANCEL) + 1);
-			return NULL;
-		}
-		DC_log(LOG_NOTICE, "Received cancel request from the master");
-		client_state = STATE_FINISH;
-		return new_event(DC_CLIENT_FINISH);
-	}
-	if (!strcmp(message, DC_MSG_SUSPEND))
-	{
-		DC_log(LOG_NOTICE, "Received suspend request from the master");
-		client_state = STATE_SUSPEND;
-		return new_event(DC_CLIENT_CHECKPOINT);
-	}
-
-	DC_log(LOG_WARNING, "Received unknown control message %s", message);
-
-	return NULL;
-}
-
-DC_ClientEvent *DC_checkClientEvent(void)
-{
-	DC_ClientEvent *event;
-	char *buf, *msg;
-	int ret;
-
-	/* Check for checkpoint requests */
-	if (boinc_time_to_checkpoint())
-	{
-		DC_log(LOG_DEBUG, "Core client requested checkpoint");
-		return new_event(DC_CLIENT_CHECKPOINT);
-	}
-
-	/* Check for messages */
-	buf = (char *)malloc(MAX_MESSAGE_SIZE);
-	if (!buf)
-		/* Let's hope the error is transient and we can deliver the
-		 * message when DC_checkClientEvent() is called for the next time */
-		return NULL;
-
-	/* Check for trickle-down messages and also handle internal
-	 * communication */
-	ret = boinc_receive_trickle_down(buf, MAX_MESSAGE_SIZE);
-	if (ret)
-	{
-		msg = (char *)malloc(MAX_MESSAGE_SIZE);
-		if (!msg)
-		{
-			free(buf);
-			return NULL;
-		}
-		ret = parse_str(buf, "<message>", msg, MAX_MESSAGE_SIZE);
-		if (!ret)
-		{
-			DC_log(LOG_WARNING, "Failed to parse message %s", buf);
-			free(buf);
-			free(msg);
-			return NULL;
-		}
-
-		if (!strncmp(msg, DCAPI_MSG_PFX, strlen(DCAPI_MSG_PFX)) &&
-				msg[strlen(DCAPI_MSG_PFX)] == ':')
-		{
-			event = handle_special_msg(msg +
-				strlen(DCAPI_MSG_PFX) + 1);
-			free(msg);
-			return event;
-		}
-
-		DC_log(LOG_DEBUG, "Received trickle message");
-
-		event = new_event(DC_CLIENT_MESSAGE);
-		event->message = buf;
-		return event;
-	}
-	free(buf);
-
-	if (client_state == STATE_FINISH)
-		return new_event(DC_CLIENT_FINISH);
-
-	return NULL;
-}
-
-void DC_destroyClientEvent(DC_ClientEvent *event)
-{
-	if (!event)
-		return;
-
-	switch (event->type)
-	{
-		case DC_CLIENT_MESSAGE:
-			free(event->message);
-			break;
-		default:
-			break;
-	}
-}
-
-void DC_checkpointMade(const char *filename)
-{
-	FILE *f;
-
-	if (!filename)
-	{
-		/* No file name - reset the checkpoint logic */
-		if (active_ckpt[0])
-			unlink(active_ckpt);
-		active_ckpt[0] = '\0';
-
-		if (last_complete_ckpt)
-		{
-			unlink(last_complete_ckpt);
-			free(last_complete_ckpt);
-			last_complete_ckpt = NULL;
-		}
-
-		boinc_checkpoint_completed();
-		return;
-	}
-
-	if (strcmp(filename, active_ckpt))
-	{
-		DC_log(LOG_ERR, "DC_checkpointMade: bad checkpoint file %s "
-			"(expected %s)", filename, active_ckpt);
-		boinc_checkpoint_completed();
-		return;
-	}
-
-	DC_log(LOG_INFO, "Completed checkpoint %s", filename);
-
-	/* Remember which was the last completed checkpoint */
-	f = boinc_fopen(LAST_CKPT_FILE, "w");
-	if (f)
-	{
-		fprintf(f, "%s", filename);
-		fclose(f);
-	}
-
-	if (last_complete_ckpt)
-	{
-		unlink(last_complete_ckpt);
-		free(last_complete_ckpt);
-	}
-	last_complete_ckpt = strdup(filename);
-
-	/* Reset the active checkpoint */
-	active_ckpt[0] = '\0';
-
-	boinc_checkpoint_completed();
-	
-	if (client_state == STATE_SUSPEND)
-		client_state = STATE_FINISH;
-}
-
-void DC_fractionDone(double fraction)
-{
-	boinc_fraction_done(fraction);
-}
-
-void DC_finishClient(int exitcode)
-{
-	char path[PATH_MAX];
-	int ret;
-
-	/* Rename/copy the checkpoint file to the label CKPT_LABEL_OUT
-	 * so it will be uploaded together with the result(s) */
-	if (last_complete_ckpt &&
-		!boinc_resolve_filename(CKPT_LABEL_OUT, path, sizeof(path)))
-	{
-#ifndef _WIN32
-		ret = link(last_complete_ckpt, path);
-		if (ret)
-#endif
-		ret = _DC_copyFile(last_complete_ckpt, path);
-
-		DC_log(LOG_DEBUG, "Uploading last complete checkpoint %s",
-			last_complete_ckpt);
-	}
-
-	/* Delete files that we have created */
-	if (last_complete_ckpt)
-		unlink(last_complete_ckpt);
-	if (strlen(active_ckpt))
-		unlink(active_ckpt);
-	unlink(LAST_CKPT_FILE);
-
-	/* Make sure the output is on disk */
-	DC_log(LOG_DEBUG, "Flushing stdout/stderr");
-	fflush(stdout);
-	fflush(stderr);
-
-	if (!boinc_resolve_filename(DC_LABEL_STDOUT, path, sizeof(path)))
-	{
-		DC_log(LOG_DEBUG, "Uploading stdout.txt");
-		_DC_copyFile("stdout.txt", path);
-	}
-
-	if (!boinc_resolve_filename(DC_LABEL_STDERR, path, sizeof(path)))
-	{
-		DC_log(LOG_DEBUG, "Uploading stderr.txt");
-		_DC_copyFile("stderr.txt", path);
-	}
-
-	DC_log(LOG_INFO, "DC-API: Application finished with exit code %d",
-		exitcode);
-	boinc_finish(exitcode);
-	/* We should never get here, but boinc_finish() is not marked
-	 * with "noreturn" so this avoids a GCC warning */
-	exit(exitcode);
-}
-
-/********************************************************************
- * Provide empty implementation for some functions required by the
- * BOINC libraries
- */
-
-void app_graphics_init(void)
-{
-}
-
-void app_graphics_resize(int width, int height)
-{
-}
-
-void app_graphics_render(int xs, int ys, double time_of_day)
-{
-}
-
-void app_graphics_reread_prefs(void)
-{
-}
-
-void boinc_app_mouse_move(int x, int y, bool left, bool middle, bool right)
-{
-}
-
-void boinc_app_mouse_button(int x, int y, int which, bool is_down)
-{
-}
-
-void boinc_app_key_press(int x, int y)
-{
-}
-
-void boinc_app_key_release(int x, int y)
-{
-}
diff --git a/dcapi/boinc/common_defs.h b/dcapi/boinc/common_defs.h
deleted file mode 100644
index 2b3dbe3..0000000
--- a/dcapi/boinc/common_defs.h
+++ /dev/null
@@ -1,40 +0,0 @@
-/*
- * common_defs.h - Definitions common for both the server and client side
- *
- * Authors:
- *	Gábor Gombás <gombasg at sztaki.hu>
- *
- * Copyright (c) 2006 MTA SZTAKI
- */
-#ifndef COMMON_DEFS_H
-#define COMMON_DEFS_H
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-/* Prefix of subresult file labels */
-#define SUBRESULT_PFX		"dc_subresult_"
-
-/* Logical names of the checkpoint file */
-#define CKPT_LABEL_IN		"dc_ckpt_in"
-#define CKPT_LABEL_OUT		"dc_ckpt_out"
-
-/* Maximum allowed message length */
-#define MAX_MESSAGE_SIZE	16384
-
-/* Prefix for internal messages between the client-side and master-side DC-API */
-#define DCAPI_MSG_PFX		"__dcapi__"
-
-/* Internal message that a subresult has been uploaded */
-#define DC_MSG_UPLOAD		"UPLOAD"
-/* Internal message telling that the client should suspend */
-#define DC_MSG_SUSPEND		"SUSPEND"
-/* Internal message for cancelling the client computation */
-#define DC_MSG_CANCEL		"CANCEL"
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif /* COMMON_DEFS_H */
diff --git a/dcapi/boinc/config.C b/dcapi/boinc/config.C
deleted file mode 100644
index 5c626ef..0000000
--- a/dcapi/boinc/config.C
+++ /dev/null
@@ -1,80 +0,0 @@
-/*
- * config. C - Wrapper code for accessing Boinc project configuration values
- *
- * Authors:
- *	Gábor Gombás <gombasg at sztaki.hu>
- *
- * Copyright (c) 2006 MTA SZTAKI
- */
-#ifdef HAVE_CONFIG_H
-#include <config.h>
-#endif
-
-#include <stdio.h>
-
-#include <sched_config.h>
-#include <sched_util.h>
-
-#include "dc_boinc.h"
-
-SCHED_CONFIG dc_boinc_config G_GNUC_INTERNAL;
-
-int _DC_parseConfigXML(void)
-{
-	int ret;
-
-	ret = dc_boinc_config.parse_file();
-	if (ret)
-	{
-		DC_log(LOG_ERR, "Failed to locate/parse the Boinc project configuration file");
-		return DC_ERR_CONFIG;
-	}
-	return 0;
-}
-
-char *_DC_getUploadDir(void)
-{
-	return dc_boinc_config.upload_dir;
-}
-
-char *_DC_getDownloadDir(void)
-{
-	return dc_boinc_config.download_dir;
-}
-
-int _DC_getUldlDirFanout(void)
-{
-	return dc_boinc_config.uldl_dir_fanout;
-}
-
-char *_DC_getDBName(void)
-{
-	return dc_boinc_config.db_name;
-}
-
-char *_DC_getDBHost(void)
-{
-	return dc_boinc_config.db_host;
-}
-
-char *_DC_getDBUser(void)
-{
-	return dc_boinc_config.db_user;
-}
-
-char *_DC_getDBPasswd(void)
-{
-	return dc_boinc_config.db_passwd;
-}
-
-char *_DC_hierPath(const char *src, int upload)
-{
-	char path[PATH_MAX];
-
-	/* Simplification: always create the directory in the download
-	 * hierarchy, but never in the upload hierarchy */
-	dir_hier_path(src, upload ? dc_boinc_config.upload_dir :
-			dc_boinc_config.download_dir,
-		dc_boinc_config.uldl_dir_fanout, path, upload ? FALSE : TRUE);
-	return g_strdup(path);
-}
diff --git a/dcapi/boinc/db.C b/dcapi/boinc/db.C
deleted file mode 100644
index 2637a48..0000000
--- a/dcapi/boinc/db.C
+++ /dev/null
@@ -1,224 +0,0 @@
-/*
- * db.C - Wrapper code for accessing the Boinc database from C
- *
- * Authors:
- *	Gábor Gombás <gombasg at sztaki.hu>
- *
- * Copyright (c) 2006 MTA SZTAKI
- */
-#ifdef HAVE_CONFIG_H
-#include <config.h>
-#endif
-
-#include <stdio.h>
-#include <string>
-
-#include <sched_config.h>
-#include <boinc_db.h>
-#include <parse.h>
-
-#include "dc_boinc.h"
-
-int _DC_initDB(void)
-{
-	int ret;
-
-	ret = boinc_db.open(_DC_getDBName(), _DC_getDBHost(), _DC_getDBUser(),
-		_DC_getDBPasswd());
-	if (ret)
-	{
-		DC_log(LOG_ERR, "Failed to connect to the Boinc database "
-			"(error #%d)", ret);
-		return DC_ERR_DATABASE;
-	}
-	return 0;
-}
-
-static int lookup_db_id(DC_Workunit *wu)
-{
-	char *query, *name;
-	DB_WORKUNIT dbwu;
-	int ret;
-
-	if (wu->db_id)
-		return 0;
-
-	name = _DC_getWUName(wu);
-	query = g_strdup_printf("WHERE name = '%s'", name);
-	g_free(name);
-	ret = dbwu.lookup(query);
-	g_free(query);
-
-	if (ret)
-	{
-		char *name = _DC_getWUName(wu);
-
-		DC_log(LOG_ERR, "Failed to look up the ID of WU %s", name);
-		g_free(name);
-		wu->state = DC_WU_UNKNOWN;
-		return DC_ERR_DATABASE;
-	}
-	wu->db_id = dbwu.get_id();
-	return 0;
-}
-
-int _DC_getDBid(DC_Workunit *wu)
-{
-	return lookup_db_id(wu);
-}
-
-void _DC_resultCompleted(DC_Result *result)
-{
-	char *query;
-	int ret;
-
-	ret = lookup_db_id(result->wu);
-	if (ret)
-		return;
-
-	/* We could use DB_WORKUNIT but that would require doing a SELECT
-	 * before the UPDATE, which is unneccessary */
-	query = g_strdup_printf("UPDATE workunit "
-		"SET assimilate_state = %d, transition_time = %d "
-		"WHERE id = %d", ASSIMILATE_DONE, (int)time(NULL),
-		result->wu->db_id);
-	boinc_db.do_query(query);
-	g_free(query);
-
-	result->wu->state = DC_WU_FINISHED;
-}
-
-void _DC_updateWUState(DC_Workunit *wu)
-{
-	DB_WORKUNIT dbwu;
-	int ret;
-
-	if (!wu->submitted)
-	{
-		wu->state = DC_WU_READY;
-		return;
-	}
-
-	if (wu->db_id)
-		ret = dbwu.lookup_id(wu->db_id);
-	else
-	{
-		char *name, *query;
-
-		/* Open-code lookup_db_id to avoid a second database lookup */
-		name = _DC_getWUName(wu);
-		query = g_strdup_printf("WHERE name = '%s'", name);
-		g_free(name);
-		ret = dbwu.lookup(query);
-		g_free(query);
-		if (!ret)
-			wu->db_id = dbwu.id;
-	}
-
-	if (ret)
-		wu->state = DC_WU_UNKNOWN;
-	else if (dbwu.error_mask)
-		/* If any bits in the error mask are set, the scheduler won't
-		 * send out new results */
-		wu->state = DC_WU_ABORTED;
-	else if (dbwu.assimilate_state == ASSIMILATE_DONE)
-		wu->state = DC_WU_FINISHED;
-	else
-		wu->state = DC_WU_RUNNING;
-}
-
-int DC_cancelWU(DC_Workunit *wu)
-{
-	char *query, *name;
-	int ret;
-
-	if (!wu)
-	{
-		DC_log(LOG_ERR, "%s: Missing WU", __func__);
-		return DC_ERR_BADPARAM;
-	}
-
-	ret = lookup_db_id(wu);
-	if (ret)
-		return ret;
-
-	name = _DC_getWUName(wu);
-	query = g_strdup_printf("%s:%s:%s", DCAPI_MSG_PFX, DC_MSG_CANCEL, name);
-	DC_sendWUMessage(wu, query);
-	g_free(name);
-	g_free(query);
-
-	query = g_strdup_printf("UPDATE result "
-		"SET server_state = %d, outcome = %d "
-		"WHERE server_state = %d AND workunitid = %d",
-		RESULT_SERVER_STATE_OVER, RESULT_OUTCOME_DIDNT_NEED,
-		RESULT_SERVER_STATE_UNSENT, wu->db_id);
-	boinc_db.do_query(query);
-	g_free(query);
-
-	query = g_strdup_printf("UPDATE workunit "
-		"SET error_mask = error_mask | %d "
-		"WHERE id = %d",
-		WU_ERROR_CANCELLED, wu->db_id);
-	boinc_db.do_query(query);
-	g_free(query);
-
-	wu->state = DC_WU_ABORTED;
-	return 0;
-}
-
-int DC_sendWUMessage(DC_Workunit *wu, const char *message)
-{
-	char *query, *name;
-	DB_RESULT result;
-	int ret;
-
-	if (!wu)
-	{
-		DC_log(LOG_ERR, "%s: Missing WU", __func__);
-		return DC_ERR_BADPARAM;
-	}
-
-	ret = lookup_db_id(wu);
-	if (ret)
-		return ret;
-
-	name = _DC_getWUName(wu);
-	query = g_strdup_printf("WHERE workunitid = %d AND server_state = %d",
-		wu->db_id, RESULT_SERVER_STATE_IN_PROGRESS);
-	while (!result.enumerate(query))
-	{
-		DB_MSG_TO_HOST msg;
-		char *xmlout;
-		int buflen;
-
-		msg.clear();
-		msg.create_time = time(NULL);
-		msg.hostid = result.hostid;
-		msg.handled = false;
-
-		/* BOINC tells output buffer should be 6x input size */
-		buflen = 6 * strlen(message) + 1;
-		xmlout = g_new(char, buflen);
-		if (!xmlout)
-		{
-			DC_log(LOG_WARNING, "Failed to send message because "
-				"ran out of memory");
-			break;
-		}
-
-		xml_escape(message, xmlout, buflen);
-		snprintf(msg.xml, sizeof(msg.xml), "<message>%s</message>", xmlout);
-		g_free(xmlout);
-
-		snprintf(msg.variety, sizeof(msg.variety), "%s", name);
-
-		if (msg.insert())
-			DC_log(LOG_WARNING, "Failed to send message to host %d",
-				result.hostid);
-	}
-	g_free(name);
-	g_free(query);
-
-	return 0;
-}
diff --git a/dcapi/boinc/dc.c b/dcapi/boinc/dc.c
deleted file mode 100644
index 6041432..0000000
--- a/dcapi/boinc/dc.c
+++ /dev/null
@@ -1,348 +0,0 @@
-/*
- * dc.c - Master side of the BOINC DC-API backend
- *
- * Authors:
- *	Gábor Gombás <gombasg at sztaki.hu>
- *
- * Copyright (c) 2006 MTA SZTAKI
- */
-#ifdef HAVE_CONFIG_H
-#include <config.h>
-#endif
-
-#include <stdlib.h>
-#include <string.h>
-#include <unistd.h>
-#include <errno.h>
-#include <glib.h>
-
-#include "dc_boinc.h"
-
-/********************************************************************
- * Data type definitions
- */
-
-/* Current element being parsed. We are not interested in most of the elements
- * and also assume that the XML document is always valid */
-typedef enum
-{
-	UNKNOWN,
-	NAME,
-	FILE_NAME,
-	OPEN_NAME
-} element_type;
-
-typedef enum
-{
-	INSIDE_FILE_INFO	= (1 << 0),
-	GENERATED_LOCALLY	= (1 << 1),
-	UPLOAD_WHEN_PRESENT	= (1 << 2)
-} element_flags;
-
-/* The private state of the XML parser */
-typedef struct _fileref_ctx	fileref_ctx;
-struct _fileref_ctx
-{
-	element_type		element;
-	element_flags		flags;
-	char			*label;
-	char			*path;
-	GList			*file_list;
-	int			num_files;
-	GHashTable		*file_info;
-};
-
-
-/********************************************************************
- * Prototypes
- */
-
-/* XML parser callback functions */
-static void fileref_start(GMarkupParseContext *ctx, const char *element_name,
-	const char **attr_names, const char **attr_values, void *ptr,
-	GError **error);
-static void fileref_end(GMarkupParseContext *ctx, const char *element_name,
-	void *ptr, GError **error);
-static void fileref_text(GMarkupParseContext *ctx, const char *text,
-	gsize text_len, void *ptr, GError **error);
-
-
-/********************************************************************
- * Global variables
- */
-
-DC_ResultCallback	_dc_resultcb;
-DC_SubresultCallback	_dc_subresultcb;
-DC_MessageCallback	_dc_messagecb;
-
-uuid_t project_uuid;
-char project_uuid_str[37];
-
-/* XML parser descriptor */
-static const GMarkupParser fileref_parser =
-{
-	fileref_start,
-	fileref_end,
-	fileref_text,
-	NULL,
-	NULL
-};
-
-
-/********************************************************************
- * API functions
- */
-
-int DC_initMaster(const char *config_file)
-{
-	char *cfgval;
-	int ret;
-
-	if (!config_file)
-		config_file = DC_CONFIG_FILE;
-
-	ret = _DC_parseCfg(config_file);
-	if (ret)
-	{
-		DC_log(LOG_ERR, "The DC-API cannot be initialized without a "
-			"config file");
-		return ret;
-	}
-
-	cfgval = DC_getCfgStr(CFG_PROJECTROOT);
-	if (cfgval)
-		setenv("BOINC_PROJECT_DIR", cfgval, 1);
-	free(cfgval);
-
-	/* Check & switch to the working directory */
-	cfgval = DC_getCfgStr(CFG_WORKDIR);
-	if (!cfgval)
-	{
-		DC_log(LOG_ERR, "%s is not specified in the config file",
-			CFG_WORKDIR);
-		return DC_ERR_CONFIG;
-	}
-
-	if (*cfgval != G_DIR_SEPARATOR)
-	{
-		DC_log(LOG_ERR, "The working directory must be an "
-			"absolute path");
-		return DC_ERR_CONFIG;
-	}
-
-	/* If we are started as a BOINC daemon, then the current dir is
-	 * <projectroot>/bin, so we must change to the working directory */
-	if (chdir(cfgval))
-	{
-		DC_log(LOG_ERR, "Failed to set the current directory to %s: %s",
-			cfgval, strerror(errno));
-		free(cfgval);
-		return DC_ERR_CONFIG;
-	}
-	free(cfgval);
-
-	/* Check the project UUID */
-	cfgval = DC_getCfgStr(CFG_INSTANCEUUID);
-	if (!cfgval)
-	{
-		DC_log(LOG_ERR, "%s is not set in the config file",
-			CFG_INSTANCEUUID);
-		return DC_ERR_CONFIG;
-	}
-
-	ret = uuid_parse((char *)cfgval, project_uuid);
-	if (ret)
-	{
-		DC_log(LOG_ERR, "Invalid project UUID %s", cfgval);
-		free(cfgval);
-		return DC_ERR_CONFIG;
-	}
-	free(cfgval);
-
-	/* Enforce a canonical string representation of the UUID */
-	uuid_unparse_lower(project_uuid, project_uuid_str);
-
-	ret = _DC_parseConfigXML();
-	if (ret)
-		return ret;
-
-	/* Now connect to the Boinc database */
-	ret = _DC_initDB();
-	if (ret)
-		return ret;
-	ret = _DC_initWUs();
-	if (ret)
-		return ret;
-
-	return 0;
-}
-
-int DC_getMaxMessageSize(void)
-{
-	return 32768; /* XXX */
-}
-
-int DC_getMaxSubresults(void)
-{
-	return 100; /* XXX */
-}
-
-unsigned DC_getGridCapabilities(void)
-{
-	return DC_GC_EXITCODE | DC_GC_SUBRESULT | DC_GC_MESSAGING |
-		DC_GC_STDOUT | DC_GC_STDERR | DC_GC_LOG;
-}
-
-void DC_setMasterCb(DC_ResultCallback resultcb,
-	DC_SubresultCallback subresultcb, DC_MessageCallback msgcb)
-{
-	_dc_resultcb = resultcb;
-	_dc_subresultcb = subresultcb;
-	_dc_messagecb = msgcb;
-}
-
-void DC_setResultCb(DC_ResultCallback cb)
-{
-	_dc_resultcb = cb;
-}
-
-void DC_setSubresultCb(DC_SubresultCallback cb)
-{
-	_dc_subresultcb = cb;
-}
-
-void DC_setMessageCb(DC_MessageCallback cb)
-{
-	_dc_messagecb = cb;
-}
-
-
-/********************************************************************
- * XML file definition parser
- */
-
-static void fileref_start(GMarkupParseContext *ctx, const char *element_name,
-	const char **attr_names, const char **attr_values, void *ptr,
-	GError **error)
-{
-	fileref_ctx *fctx = ptr;
-
-	if (attr_names && attr_names[0])
-	{
-		*error = g_error_new(G_MARKUP_ERROR,
-			G_MARKUP_ERROR_UNKNOWN_ATTRIBUTE,
-			"Attributes are not recognized in BOINC-generated XML");
-		return;
-	}
-
-	if (!strcmp(element_name, "file_ref"))
-	{
-		g_free(fctx->label);
-		g_free(fctx->path);
-		fctx->label = NULL;
-		fctx->path = NULL;
-	}
-	else if (!strcmp(element_name, "file_name"))
-		fctx->element = FILE_NAME;
-	else if (!strcmp(element_name, "open_name"))
-		fctx->element = OPEN_NAME;
-	else if (!strcmp(element_name, "file_info"))
-		fctx->flags |= INSIDE_FILE_INFO;
-	else if (fctx->flags & INSIDE_FILE_INFO)
-	{
-		if (!strcmp(element_name, "name"))
-			fctx->element = NAME;
-		else if (!strcmp(element_name, "generated_locally"))
-			fctx->flags |= GENERATED_LOCALLY;
-		else if (!strcmp(element_name, "upload_when_present"))
-			fctx->flags |= UPLOAD_WHEN_PRESENT;
-	}
-}
-
-static void fileref_end(GMarkupParseContext *ctx, const char *element_name,
-	void *ptr, GError **error)
-{
-	fileref_ctx *fctx = ptr;
-
-	if (!strcmp(element_name, "file_ref"))
-	{
-		DC_PhysicalFile *file;
-
-		file = _DC_createPhysicalFile(fctx->label, fctx->path);
-		g_free(fctx->label);
-		g_free(fctx->path);
-		fctx->label = NULL;
-		fctx->path = NULL;
-		fctx->file_list = g_list_append(fctx->file_list, file);
-		fctx->num_files++;
-	}
-	else if (!strcmp(element_name, "file_info"))
-	{
-		fctx->flags = 0;
-
-		g_hash_table_insert(fctx->file_info, fctx->path,
-			GINT_TO_POINTER(fctx->flags));
-		fctx->path = NULL;
-	}
-
-	fctx->element = UNKNOWN;
-}
-
-static void fileref_text(GMarkupParseContext *ctx, const char *text,
-	gsize text_len, void *ptr, GError **error)
-{
-	fileref_ctx *fctx = ptr;
-
-	switch (fctx->element)
-	{
-		case NAME:
-		case FILE_NAME:
-			fctx->path = g_strndup(text, text_len);
-			break;
-		case OPEN_NAME:
-			fctx->label = g_strndup(text, text_len);
-			break;
-		default:
-			break;
-	}
-}
-
-GList *_DC_parseFileRefs(const char *xml_doc, int *num_files)
-{
-	GMarkupParseContext *ctx;
-	fileref_ctx fctx;
-	GError *error = NULL;
-
-	memset(&fctx, 0, sizeof(fctx));
-	fctx.file_info = g_hash_table_new_full(g_str_hash, g_str_equal,
-		g_free, NULL);
-
-	ctx = g_markup_parse_context_new(&fileref_parser, 0, &fctx, NULL);
-	if (!g_markup_parse_context_parse(ctx, xml_doc, strlen(xml_doc),
-			&error))
-		goto error;
-	if (!g_markup_parse_context_end_parse(ctx, &error))
-		goto error;
-	if (num_files)
-		*num_files = fctx.num_files;
-
-out:
-	g_markup_parse_context_free(ctx);
-	g_hash_table_destroy(fctx.file_info);
-	g_free(fctx.label);
-	g_free(fctx.path);
-	return fctx.file_list;
-
-error:
-	while (fctx.file_list)
-	{
-		_DC_destroyPhysicalFile(fctx.file_list->data);
-		fctx.file_list = g_list_delete_link(fctx.file_list,
-			fctx.file_list);
-	}
-
-	DC_log(LOG_ERR, "Failed to parse result XML description: %s",
-		error->message);
-	g_error_free(error);
-	goto out;
-}
diff --git a/dcapi/boinc/dc_boinc.h b/dcapi/boinc/dc_boinc.h
deleted file mode 100644
index 9c41ca8..0000000
--- a/dcapi/boinc/dc_boinc.h
+++ /dev/null
@@ -1,219 +0,0 @@
-/*
- * dc_boinc.h - Common definitions for the master side of the BOINC DC-API backend
- *
- * Authors:
- *	Gábor Gombás <gombasg at sztaki.hu>
- *
- * Copyright (c) 2006 MTA SZTAKI
- */
-#ifndef __DC_BOINC_H_
-#define __DC_BOINC_H_
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-#include <dc.h>
-#include <dc_internal.h>
-#include <uuid/uuid.h>
-#include <glib.h>
-
-#include "common_defs.h"
-
-/********************************************************************
- * Constants
- */
-
-/* The root direcory of the BOINC project */
-#define CFG_PROJECTROOT		    "ProjectRootDir"
-/* Level of redundancy (per-client) variant 1. */
-#define CFG_REDUNDANCY		    "Redundancy"
-/* Level of redundancy (per-client) variant 2.: fine tune parameters */
-#define CFG_MIN_QUORUM          "MinQuorum"
-#define CFG_TARGET_NRESULTS     "TargetNResults"
-#define CFG_MAX_ERROR_RESULTS   "MaxErrorResults"
-#define CFG_MAX_TOTAL_RESULTS   "MaxTotalResults"
-#define CFG_MAX_SUCCESS_RESULTS "MaxSuccessResults"
-/* Max. size of output files, including subresults & checkpoint (per-client) */
-#define CFG_MAXOUTPUT		"MaxOutputSize"
-/* Max. memory usage (per-client) */
-#define CFG_MAXMEMUSAGE		"MaxMemUsage"
-/* Max. disk usage (per-client) */
-#define CFG_MAXDISKUSAGE	"MaxDiskUsage"
-/* Estimated number of floating point operations */
-#define CFG_FPOPS_EST		"EstimatedFPOps"
-/* Max. number of floating point operations */
-#define CFG_MAXFPOPS		"MaxFPOps"
-/* WU deadline */
-#define CFG_DELAYBOUND		"DelayBound"
-/* Suspending enabled or not */
-#define CFG_ENABLESUSPEND	"EnableSuspend"
-/* Client uses native BOINC API instead of DC-API */
-#define CFG_NATIVECLIENT	"NativeClient"
-/* Remote file rewrite regexp match string */
-#define CFG_REGEXPMATCH		"InputURLRewriteRegExpMatch"
-/* Remote file rewrite regexp replace string */
-#define CFG_REGEXPREPLACE	"InputURLRewriteRegExpReplace"
-/* Upload URL configuration option */
-#define CFG_UPLOADURL		"UploadURL"
-
-/* File types in the working directory */
-typedef enum
-{
-	FILE_IN,
-	FILE_OUT,
-	FILE_CKPT,
-	FILE_DCAPI
-} WorkdirFile;
-
-
-/********************************************************************
- * Data types
- */
-
-struct _DC_Workunit
-{
-	/* Arguments passed to DC_createWU() */
-	char			*client_name;
-	char			**argv;
-	int			argc;
-	char			*tag;
-	int			subresults;
-	int			priority;
-
-	int			serialized : 1;
-	int			submitted : 1;
-	int			suspended : 1;
-	int			nosuspend : 1;
-	int			nativeclient : 1;
-
-	/* The WU's UUID */
-	uuid_t			uuid;
-	/* State of the WU */
-	DC_WUState		state;
-	/* The WU's working directory */
-	char			*workdir;
-	/* The WU's ID in the Boinc database */
-	int			db_id;
-	
-	/* Batch value of the workunit */
-	int 			batch;
-
-	/* Input file definitions. Elements are of type DC_PhysicalFile */
-	GList			*input_files;
-	int			num_inputs;
-
-	/* Remote input file definitions. Elements are of type DC_RemoteFile */
-	GList			*remote_input_files;
-	int			num_remote_inputs;
-
-	/* Output file definitions. Elements are of type char * */
-	GList			*output_files;
-	int			num_outputs;
-
-	/* Name of the checkpoint file, if exists (relative to workdir) */
-	char			*ckpt_name;
-
-	/* Reference count */
-	int			refcnt;
-
-	/* Mapping <optional/> attribute to output files  */
-	GHashTable              *is_optional;
-};
-
-struct _DC_Result
-{
-	DC_Workunit		*wu;
-
-	int			exit_code;
-	double			cpu_time;
-
-	/* List of output files. Elements are of type DC_PhysicalFile */
-	GList			*output_files;
-	int			num_outputs;
-};
-
-
-/********************************************************************
- * Global variables
- */
-
-extern DC_ResultCallback _dc_resultcb G_GNUC_INTERNAL;
-extern DC_SubresultCallback _dc_subresultcb G_GNUC_INTERNAL;
-extern DC_MessageCallback _dc_messagecb G_GNUC_INTERNAL;
-
-extern char project_uuid_str[] G_GNUC_INTERNAL;
-extern uuid_t project_uuid G_GNUC_INTERNAL;
-
-
-/********************************************************************
- * Function prototypes
- */
-
-/* Parses the project's config.xml */
-int _DC_parseConfigXML(void) G_GNUC_INTERNAL;
-
-/* Returns the Boinc upload directory */
-char *_DC_getUploadDir(void) G_GNUC_INTERNAL;
-
-/* Returns the Boinc download directory */
-char *_DC_getDownloadDir(void) G_GNUC_INTERNAL;
-
-/* Returns the Boinc upload/download hashing */
-int _DC_getUldlDirFanout(void) G_GNUC_INTERNAL;
-
-/* Returns the database name */
-char *_DC_getDBName(void) G_GNUC_INTERNAL;
-
-/* Returns the database host */
-char *_DC_getDBHost(void) G_GNUC_INTERNAL;
-
-/* Returns the database user ID */
-char *_DC_getDBUser(void) G_GNUC_INTERNAL;
-
-/* Returns the database password */
-char *_DC_getDBPasswd(void) G_GNUC_INTERNAL;
-
-/* Initializes the database connection */
-int _DC_initDB(void) G_GNUC_INTERNAL;
-
-/* Initializes the WU manager */
-int _DC_initWUs(void) G_GNUC_INTERNAL;
-
-/* Creates a new DC_Result */
-DC_Result *_DC_createResult(const char *wu_name, int db_id,
-	const char *xml_doc_in, double cpu_time) G_GNUC_INTERNAL;
-
-/* Destroys a DC_Result */
-void _DC_destroyResult(DC_Result *result) G_GNUC_INTERNAL;
-
-/* Get the name of the WU used in the database */
-char *_DC_getWUName(const DC_Workunit *wu) G_GNUC_INTERNAL;
-
-/* Looks up a WU by name */
-DC_Workunit *_DC_getWUByName(const char *name) G_GNUC_INTERNAL;
-
-/* Looks up the id of a wu */
-int _DC_getDBid(DC_Workunit *wu) G_GNUC_INTERNAL;
-
-/* Parses <file_ref> definitions in an XML document */
-GList *_DC_parseFileRefs(const char *xml_doc, int *num_files) G_GNUC_INTERNAL;
-
-/* Marks a work unit as completed in the database */
-void _DC_resultCompleted(DC_Result *result) G_GNUC_INTERNAL;
-
-/* Updates the WU state from the database */
-void _DC_updateWUState(DC_Workunit *wu) G_GNUC_INTERNAL;
-
-/* C wrapper around dir_hier_path() */
-char *_DC_hierPath(const char *src, int upload) G_GNUC_INTERNAL;
-
-/* Get the full path of a file in the WU's working directory */
-char *_DC_workDirPath(const DC_Workunit *wu, const char *label, WorkdirFile type)
-	G_GNUC_INTERNAL;
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif /* __DC_BOINC_H_ */
diff --git a/dcapi/boinc/dcapi-boinc-client.pc.in b/dcapi/boinc/dcapi-boinc-client.pc.in
deleted file mode 100644
index 78b1e87..0000000
--- a/dcapi/boinc/dcapi-boinc-client.pc.in
+++ /dev/null
@@ -1,11 +0,0 @@
-prefix=@prefix@
-exec_prefix=@exec_prefix@
-libdir=@libdir@
-includedir=@includedir@
-
-Name: DC-API BOINC Client
-Description: BOINC client implementation for DC-API
-Version: @PACKAGE_VERSION@
-Libs: -L${libdir} -ldcapi-client-boinc
-Libs.private: @BOINC_CLIENT_LIBS@
-Cflags: -I${includedir}
diff --git a/dcapi/boinc/dcapi-boinc-master.pc.in b/dcapi/boinc/dcapi-boinc-master.pc.in
deleted file mode 100644
index 466fff2..0000000
--- a/dcapi/boinc/dcapi-boinc-master.pc.in
+++ /dev/null
@@ -1,12 +0,0 @@
-prefix=@prefix@
-exec_prefix=@exec_prefix@
-libdir=@libdir@
-includedir=@includedir@
-
-Name: DC-API BOINC Master
-Description: BOINC master implementation for DC-API
-Version: @PACKAGE_VERSION@
-Requires: glib-2.0 uuid
-Libs: -L${libdir} -ldcapi-boinc
-Libs.private: @BOINC_SERVER_LIBS@ -lm
-Cflags: -I${includedir}
diff --git a/dcapi/boinc/events.C b/dcapi/boinc/events.C
deleted file mode 100644
index fd25418..0000000
--- a/dcapi/boinc/events.C
+++ /dev/null
@@ -1,453 +0,0 @@
-/*
- * events.C - BOINC event handling
- *
- * Authors:
- *	Gábor Gombás <gombasg at sztaki.hu>
- *
- * Copyright (c) 2006 MTA SZTAKI
- */
-#ifdef HAVE_CONFIG_H
-#include <config.h>
-#endif
-
-#include <unistd.h>
-#include <strings.h>
-
-#include "dc_boinc.h"
-
-#include <boinc_db.h>
-#include <sched_util.h>
-#include <sched_msgs.h>
-#include <parse.h>
-
-/* Be nice to the database and sleep for a long time */
-#define SLEEP_UNIT		15
-
-static void mark_wu_complete(DB_WORKUNIT &dbwu, int do_callback)
-{
-	DC_Workunit *wu;
-
-	/* Invoke the callback with an empty result so the application knows
-	 * that the WU has failed */
-	wu = _DC_getWUByName(dbwu.name);
-	if (wu && _dc_resultcb && do_callback)
-		_dc_resultcb(wu, NULL);
-
-	dbwu.assimilate_state = ASSIMILATE_DONE;
-	dbwu.transition_time = time(NULL);
-	dbwu.update();
-}
-
-static int wu_has_failed(DB_WORKUNIT &wu)
-{
-	if (wu.error_mask & WU_ERROR_CANCELLED)
-	{
-		DC_log(LOG_INFO, "Acknowledging cancelled WU %s", wu.name);
-		return TRUE;
-	}
-
-	if (wu.error_mask & WU_ERROR_TOO_MANY_ERROR_RESULTS)
-	{
-		DC_log(LOG_WARNING, "There are too many errors for WU %s",
-			wu.name);
-		return TRUE;
-	}
-
-	if (wu.error_mask & WU_ERROR_TOO_MANY_TOTAL_RESULTS)
-	{
-		DC_log(LOG_WARNING, "There are too many results for WU %s",
-			wu.name);
-		return TRUE;
-	}
-
-	if (wu.error_mask & WU_ERROR_COULDNT_SEND_RESULT)
-	{
-		if (wu.canonical_resultid)
-			return FALSE;
-
-		/* XXX We could count the results that still have a chance to
-		 * complete and error out only if there are fewer than
-		 * min_quorum, but that's complex */
-		DC_log(LOG_WARNING, "One or more results for WU %s coudln't "
-			"be sent", wu.name);
-		return TRUE;
-	}
-
-	if (!wu.canonical_resultid)
-	{
-		DC_log(LOG_WARNING, "No canonical result for WU %s", wu.name);
-		return TRUE;
-	}
-
-	return FALSE;
-}
-
-static int process_results(void)
-{
-	DC_Result *result;
-	DB_WORKUNIT wu;
-	char *query;
-	int done;
-
-	/* XXX Check LIMIT value */
-	query = g_strdup_printf("WHERE name LIKE '%s\\_%%' "
-		"AND assimilate_state = %d LIMIT 100", project_uuid_str,
-		ASSIMILATE_READY);
-	done = 0;
-	while (!wu.enumerate(query))
-	{
-		DB_RESULT canonical_result;
-
-		if (wu_has_failed(wu))
-		{
-			mark_wu_complete(wu, TRUE);
-			continue;
-		}
-
-		if (canonical_result.lookup_id(wu.canonical_resultid))
-		{
-			DC_log(LOG_ERR, "Result #%d is not in the database",
-				wu.canonical_resultid);
-			mark_wu_complete(wu, TRUE);
-			continue;
-		}
-
-		/* Call the callback function */
-		result = _DC_createResult(wu.name, wu.id,
-			canonical_result.xml_doc_in, canonical_result.cpu_time);
-		if (!result)
-		{
-			mark_wu_complete(wu, TRUE);
-			continue;
-		}
-		_dc_resultcb(result->wu, result);
-		_DC_destroyResult(result);
-		done++;
-	}
-
-	g_free(query);
-	return done;
-}
-
-static void handle_special_msg(DC_Workunit *wu, const char *msg)
-{
-	if (!strncmp(msg, DC_MSG_UPLOAD, strlen(DC_MSG_UPLOAD)) &&
-			_dc_subresultcb)
-	{
-		const char *p = strchr(msg, ':');
-		if (!p)
-			return;
-		const char *q = strchr(p + 1, ':');
-		if (!q)
-			return;
-
-		char *subresult_name = g_strndup(p + 1, (q - p) - 1);
-		char *client_label = g_strdup(q + 1);
-
-		/* Paranoia; the XML signature should already prevent the
-		 * client from tampering with the destination path */
-		if (strchr(subresult_name, G_DIR_SEPARATOR))
-		{
-			DC_log(LOG_ERR, "Client sent insecure subresult name, "
-				"ignoring");
-			g_free(subresult_name);
-			g_free(client_label);
-			return;
-		}
-
-		char *path = _DC_hierPath(subresult_name, TRUE);
-		_dc_subresultcb(wu, client_label, path);
-
-		g_free(subresult_name);
-		g_free(client_label);
-		g_free(path);
-	}
-	else
-		DC_log(LOG_WARNING, "Received unknown control message %s", msg);
-}
-
-static int process_messages(void)
-{
-	DB_MSG_FROM_HOST msg;
-	char *query, *buf;
-	DC_Workunit *wu;
-	int done, ret;
-
-	query = g_strdup_printf("WHERE variety LIKE '%s\\_%%' AND handled = 0",
-		project_uuid_str);
-	buf = (char *)g_malloc(MAX_MESSAGE_SIZE);
-	done = 0;
-	while (!msg.enumerate(query))
-	{
-		wu = _DC_getWUByName(msg.variety);
-		if (!wu)
-		{
-			DC_log(LOG_WARNING, "Received message for unknown "
-				"WU %s", msg.variety);
-			goto handled;
-		}
-
-		ret = parse_str(msg.xml, "<message>", buf, MAX_MESSAGE_SIZE);
-		if (!ret)
-		{
-			DC_log(LOG_WARNING, "Failed to parse message %s",
-				msg.xml);
-			goto handled;
-		}
-
-		if (!strncmp(buf, DCAPI_MSG_PFX, strlen(DCAPI_MSG_PFX)))
-			handle_special_msg(wu, buf + strlen(DCAPI_MSG_PFX) + 1);
-		else if (_dc_messagecb)
-			_dc_messagecb(wu, buf);
-		done++;
-handled:
-		msg.handled = 1;
-		msg.update();
-	}
-	g_free(query);
-	g_free(buf);
-	return done;
-}
-
-int DC_processMasterEvents(int timeout)
-{
-	time_t end, now;
-	static int once;
-	int done;
-
-	if (!_dc_resultcb && !_dc_subresultcb && !_dc_messagecb)
-	{
-		DC_log(LOG_ERR, "%s: callbacks are not initialized", __func__);
-		return DC_ERR_CONFIG;
-	}
-
-	/* Warn the user whether she knows what she is doing */
-	if (!once)
-	{
-		if (!_dc_resultcb)
-			DC_log(LOG_NOTICE, "The result callback is not set, "
-				"completed WUs will not be reported");
-		if (!_dc_subresultcb)
-			DC_log(LOG_NOTICE, "The subresult callback is not "
-				"set, subresults will not be reported");
-		if (!_dc_messagecb)
-			DC_log(LOG_NOTICE, "The message callback is not set, "
-				"messages will not be reported");
-		once = 1;
-	}
-
-	end = time(NULL) + timeout;
-	done = 0;
-	while (1)
-	{
-		if (_dc_resultcb)
-			done += process_results();
-		if (_dc_subresultcb || _dc_messagecb)
-			done += process_messages();
-		if (done)
-			break;
-
-		now = time(NULL);
-		if (now >= end)
-			break;
-		sleep(MIN(end - now, SLEEP_UNIT));
-	}
-
-	return done ? 0 : DC_ERR_TIMEOUT;
-}
-
-/* Look for a single result that matches the filter */
-static DC_MasterEvent *look_for_results(const char *wuFilter, const char *wuName)
-{
-	DC_MasterEvent *event;
-	DB_RESULT result;
-	DB_WORKUNIT wu;
-	char *query;
-
-	if (wuFilter)
-		query = g_strdup_printf("WHERE name LIKE '%s\\_%%\\_%s' "
-			"AND assimilate_state = %d LIMIT 1", project_uuid_str,
-			wuFilter, ASSIMILATE_READY);
-	else if (wuName)
-		query = g_strdup_printf("WHERE name LIKE '%s\\_%s%%' "
-			"AND assimilate_state = %d LIMIT 1", project_uuid_str,
-			wuName, ASSIMILATE_READY);
-	else
-		query = g_strdup_printf("WHERE name LIKE '%s\\_%%' "
-			"AND assimilate_state = %d LIMIT 1", project_uuid_str,
-			ASSIMILATE_READY);
-
-	if (wu.enumerate(query))
-	{
-		g_free(query);
-		return NULL;
-	}
-	g_free(query);
-
-	if (wu_has_failed(wu))
-	{
-		mark_wu_complete(wu, FALSE);
-		return NULL;
-	}
-
-	if (result.lookup_id(wu.canonical_resultid))
-	{
-		DC_log(LOG_ERR, "Result #%d is not in the database",
-			wu.canonical_resultid);
-		mark_wu_complete(wu, FALSE);
-		return NULL;
-	}
-
-	event = g_new(DC_MasterEvent, 1);
-	event->type = DC_MASTER_RESULT;
-	event->result = _DC_createResult(wu.name, wu.id, result.xml_doc_in,
-		result.cpu_time);
-	if (!event->result)
-	{
-		mark_wu_complete(wu, FALSE);
-		g_free(event);
-		return NULL;
-	}
-	event->wu = event->result->wu;
-
-	return event;
-}
-
-static DC_MasterEvent *look_for_messages(const char *wuFilter, const char *wuName)
-{
-	DC_MasterEvent *event;
-	DB_MSG_FROM_HOST msg;
-	char *query, *buf;
-	DC_Workunit *wu;
-	int ret;
-
-restart:
-	if (wuFilter)
-		query = g_strdup_printf("WHERE variety LIKE '%s\\_%%\\_%s' "
-			"AND handled = 0", project_uuid_str, wuFilter);
-	else if (wuName)
-		query = g_strdup_printf("WHERE variety LIKE '%s\\_%s%%' "
-			"AND handled = 0", project_uuid_str, wuName);
-	else
-		query = g_strdup_printf("WHERE variety LIKE '%s\\_%%' "
-			"AND handled = 0", project_uuid_str);
-
-	if (msg.enumerate(query))
-	{
-		g_free(query);
-		return NULL;
-	}
-	g_free(query);
-
-	wu = _DC_getWUByName(msg.variety);
-	if (!wu)
-	{
-		DC_log(LOG_WARNING, "Received message for unknown WU %s",
-			msg.variety);
-		msg.handled = 1;
-		msg.update();
-		return NULL;
-	}
-
-	buf = (char *)g_malloc(MAX_MESSAGE_SIZE);
-	ret = parse_str(msg.xml, "<message>", buf, MAX_MESSAGE_SIZE);
-	if (!ret)
-	{
-		DC_log(LOG_WARNING, "Failed to parse message %s", msg.xml);
-		g_free(buf);
-		msg.handled = 1;
-		msg.update();
-		return NULL;
-	}
-
-	if (!strncmp(buf, DCAPI_MSG_PFX, strlen(DCAPI_MSG_PFX)))
-	{
-		handle_special_msg(wu, buf + strlen(DCAPI_MSG_PFX) + 1);
-		g_free(buf);
-		msg.handled = 1;
-		msg.update();
-		goto restart;
-	}
-
-	event = g_new(DC_MasterEvent, 1);
-	event->wu = wu;
-	event->type = DC_MASTER_MESSAGE;
-	event->message = buf;
-	return event;
-}
-
-DC_MasterEvent *DC_waitMasterEvent(const char *wuFilter, int timeout)
-{
-	time_t end, now;
-	DC_MasterEvent *event;
-
-	end = time(NULL) + timeout;
-	while (1)
-	{
-		event = look_for_results(wuFilter, NULL);
-		if (event)
-			break;
-		event = look_for_messages(wuFilter, NULL);
-		if (event)
-			break;
-		now = time(NULL);
-		if (now >= end)
-			break;
-		sleep(MIN(end - now, SLEEP_UNIT));
-	}
-	return event;
-}
-
-DC_MasterEvent *DC_waitWUEvent(DC_Workunit *wu, int timeout)
-{
-	char uuid_str[36];
-	DC_MasterEvent *event;
-	time_t end, now;
-
-	if (!wu)
-	{
-		DC_log(LOG_ERR, "%s: Missing WU", __func__);
-		return NULL;
-	}
-
-	uuid_unparse_lower(wu->uuid, uuid_str);
-
-	end = time(NULL) + timeout;
-	while (1)
-	{
-		event = look_for_results(NULL, uuid_str);
-		if (event)
-			break;
-		event = look_for_messages(NULL, uuid_str);
-		if (event)
-			break;
-		now = time(NULL);
-		if (now >= end)
-			break;
-		sleep(MIN(end - now, SLEEP_UNIT));
-	}
-	return event;
-}
-
-void DC_destroyMasterEvent(DC_MasterEvent *event)
-{
-	if (!event)
-		return;
-
-	switch (event->type)
-	{
-		case DC_MASTER_RESULT:
-			_DC_destroyResult(event->result);
-			break;
-		case DC_MASTER_SUBRESULT:
-			_DC_destroyPhysicalFile(event->subresult);
-			break;
-		case DC_MASTER_MESSAGE:
-			g_free(event->message);
-			break;
-		default:
-			DC_log(LOG_ERR, "%s: Unknown event type %d",
-				__func__, event->type);
-			break;
-	}
-}
diff --git a/dcapi/boinc/local.conf b/dcapi/boinc/local.conf
deleted file mode 100644
index fa0024b..0000000
--- a/dcapi/boinc/local.conf
+++ /dev/null
@@ -1,21 +0,0 @@
-# Template
-# Configuration file for local implementation of DC
-#
-
-BoincRoot = /home/pnorbert/SETI/boinc
-BoincTools = /home/pnorbert/SETI/boinc/tools
-
-#
-# Client code 
-#
-
-#    Executable is the client program to be executed
-Executable = proba2client
-
-
-# 
-# Working directory
-#
-
-WorkingDirectory = /home/pnorbert/SETI/workdir
-
diff --git a/dcapi/boinc/result.c b/dcapi/boinc/result.c
deleted file mode 100644
index b46cfed..0000000
--- a/dcapi/boinc/result.c
+++ /dev/null
@@ -1,248 +0,0 @@
-/*
- * result.c - BOINC result management
- *
- * Authors:
- *	Gábor Gombás <gombasg at sztaki.hu>
- *
- * Copyright (c) 2006 MTA SZTAKI
- */
-#ifdef HAVE_CONFIG_H
-#include <config.h>
-#endif
-
-#include <sys/types.h>
-#include <sys/stat.h>
-#include <stdlib.h>
-#include <string.h>
-#include <unistd.h>
-#include <stdio.h>
-#include <errno.h>
-
-#include "dc_boinc.h"
-
-/********************************************************************
- * Functions
- */
-
-DC_Result *_DC_createResult(const char *wu_name, int db_id,
-	const char *xml_doc_in, double cpu_time)
-{
-	DC_Result *result;
-	GList *l;
-
-	result = g_new0(DC_Result, 1);
-	result->wu = _DC_getWUByName(wu_name);
-	if (!result->wu)
-	{
-		DC_log(LOG_ERR, "Received result for unknown WU %s", wu_name);
-		g_free(result);
-		return NULL;
-	}
-
-	/* Make sure the WU remains valid while the result lives */
-	result->wu->refcnt++;
-
-	if (!result->wu->db_id)
-		result->wu->db_id = db_id;
-
-	result->wu->state = DC_WU_FINISHED;
-	result->cpu_time = cpu_time;
-
-	result->output_files = _DC_parseFileRefs(xml_doc_in,
-		&result->num_outputs);
-	if (!result->output_files)
-	{
-		_DC_destroyResult(result);
-		return NULL;
-	}
-
-	for (l = result->output_files; l; l = l->next)
-	{
-		char *upload_path, *workdir_path;
-		DC_PhysicalFile *file;
-		int ret;
-
-		file = l->data;
-		workdir_path = _DC_workDirPath(result->wu, file->label,
-			FILE_OUT);
-		upload_path = _DC_hierPath(file->path, TRUE);
-
-		ret = link(upload_path, workdir_path);
-		if (ret && errno != ENOENT)
-		{
-			ret = _DC_copyFile(upload_path, workdir_path);
-			if (ret)
-				DC_log(LOG_ERR, "Failed to copy the output "
-					"file %s to %s", upload_path,
-					workdir_path);
-		}
-		g_free(workdir_path);
-		g_free(upload_path);
-	}
-	return result;
-}
-
-void _DC_destroyResult(DC_Result *result)
-{
-	/* Mark the work unit as completed in the database */
-	_DC_resultCompleted(result);
-	/* Drop the reference on the WU */
-	DC_destroyWU(result->wu);
-
-	while (result->output_files)
-	{
-		_DC_destroyPhysicalFile(result->output_files->data);
-		result->output_files = g_list_delete_link(result->output_files,
-			result->output_files);
-	}
-	g_free(result);
-}
-
-DC_GridCapabilities DC_getResultCapabilities(const DC_Result *result)
-{
-	unsigned caps;
-	char *path;
-
-	if (!result)
-	{
-		DC_log(LOG_ERR, "%s: Missing result", __func__);
-		return 0;
-	}
-
-	caps = DC_GC_EXITCODE;
-	path = DC_getResultOutput(result, DC_LABEL_STDOUT);
-	if (path)
-	{
-		caps |= DC_GC_STDOUT;
-		free(path);
-	}
-	path = DC_getResultOutput(result, DC_LABEL_STDERR);
-	if (path)
-	{
-		caps |= DC_GC_STDERR;
-		free(path);
-	}
-	path = DC_getResultOutput(result, DC_LABEL_CLIENTLOG);
-	if (path)
-	{
-		caps |= DC_GC_LOG;
-		free(path);
-	}
-
-	return caps;
-}
-
-DC_Workunit *DC_getResultWU(DC_Result *result)
-{
-	if (!result)
-	{
-		DC_log(LOG_ERR, "%s: Missing result", __func__);
-		return NULL;
-	}
-
-	return result->wu;
-}
-
-int DC_getResultExit(const DC_Result *result)
-{
-	if (!result)
-	{
-		DC_log(LOG_ERR, "%s: Missing result", __func__);
-		return -1;
-	}
-
-	return result->exit_code;
-}
-
-char *DC_getResultOutput(const DC_Result *result, const char *logicalFileName)
-{
-	char *path, *wuname;
-	struct stat st;
-	int fd;
-	GList *l;
-	int ret;
-
-	if (!result)
-	{
-		DC_log(LOG_ERR, "%s: Missing result", __func__);
-		return NULL;
-	}
-	if (!logicalFileName)
-	{
-		DC_log(LOG_ERR, "%s: Missing logical file name", __func__);
-		return NULL;
-	}
-
-	for (l = result->output_files; l; l = l->next)
-	{
-		DC_PhysicalFile *file = l->data;
-
-		if (strcmp(file->label, logicalFileName))
-			continue;
-
-		path = _DC_workDirPath(result->wu, file->label, FILE_OUT);
-
-		/*
-		  BOINC will not upload an output file if it's empty.
-
-		  Higher level applications might report an error because of the
-		  missing file, while the result is actually successful.
-
-		  Create an empty output file if it's missing.
-		 */
-		ret = stat(path, &st);
-		if (ret)
-		{
-			if (ENOENT == errno)
-				/* does not exist */
-			{
-				DC_log(LOG_WARNING,
-				       "File '%s' does not exists; it was probably empty. Creating it",
-				       path);
-				if (0 > (fd = creat(path, 0660)))
-				{
-					DC_log(LOG_ERR, "Could not create empty file '%s': open: %s",
-					       path, strerror(errno));
-					g_free(path);
-					return NULL;
-				}
-				else
-					close(fd);
-			}
-			else
-			{
-				DC_log(LOG_ERR, "Error opening output file '%s': stat: %s",
-				       path, strerror(errno));
-				g_free(path);
-				return NULL;
-			}
-		}
-
-		if (!g_mem_is_system_malloc())
-		{
-			char *tmp;
-
-			tmp = strdup(path);
-			g_free(path);
-			path = tmp;
-		}
-		return path;
-	}
-
-	wuname = _DC_getWUName(result->wu);
-	DC_log(LOG_WARNING, "WU %s does not have an output file named '%s'",
-		wuname, logicalFileName);
-	g_free(wuname);
-	return NULL;
-}
-
-double DC_getResultCPUTime(const DC_Result *result)
-{
-	if (!result)
-	{
-		DC_log(LOG_ERR, "%s: Missing result", __func__);
-		return 0.0;
-	}
-
-	return result->cpu_time;
-}
diff --git a/dcapi/boinc/wu.C b/dcapi/boinc/wu.C
deleted file mode 100644
index 64a0d18..0000000
--- a/dcapi/boinc/wu.C
+++ /dev/null
@@ -1,2016 +0,0 @@
-/*
- * wu.C - BOINC work unit management
- *
- * Authors:
- *	Gábor Gombás <gombasg at sztaki.hu>
- *
- * Copyright (c) 2006 MTA SZTAKI
- */
-#ifdef HAVE_CONFIG_H
-#include <config.h>
-#endif
-
-#include <sys/types.h>
-#include <sys/stat.h>
-#include <unistd.h>
-#include <string.h>
-#include <stdlib.h>
-#include <stdio.h>
-#include <errno.h>
-#include <glib.h>
-#include <math.h>
-
-#include <openssl/sha.h>
-
-#include <sched_util.h>
-#include <sched_config.h>
-#include <backend_lib.h>
-#include <md5_file.h>
-
-#include "dc_boinc.h"
-
-/********************************************************************
- * Constants
- */
-
-typedef enum
-{
-	WU_NOTAG = -1,
-	WU_WUDESC,
-	WU_INPUT_LABEL,
-	WU_REMOTE_IN_LABEL,
-	WU_OUTPUT_LABEL,
-	WU_TAG,
-	WU_CLIENT_NAME,
-	WU_CLIENT_ARG,
-	WU_SUBRESULTS,
-	WU_SUBMITTED,
-	WU_SERIALIZED,
-	WU_SUSPENDED,
-	WU_NOSUSPEND,
-	WU_NATIVECLIENT,
-	WU_PRIORITY,
-	WU_BATCH
-} wu_tag;
-
-#define WU_DESC_FILE		"wu_desc.xml"
-
-
-/********************************************************************
- * Data type definitions
- */
-
-struct tag_desc
-{
-	wu_tag			id;
-	const char		*name;
-};
-
-struct parser_state
-{
-	wu_tag			curr_tag;
-	DC_FileMode		curr_mode;
-	DC_Workunit		*wu;
-	char			*curr_url;
-	char			*curr_md5;
-	size_t			curr_size;
-};
-
-struct wu_params
-{
-	/* Resource control */
-	double			rsc_fpops_est;
-	double			rsc_fpops_bound;
-	double			rsc_memory_bound;
-	double			rsc_disk_bound;
-
-	/* Redundancy */
-	int			delay_bound;
-	int			min_quorum;
-	int			target_nresults;
-	int			max_error_results;
-	int			max_total_results;
-	int			max_success_results;
-};
-
-
-/********************************************************************
- * Prototypes
- */
-
-int DC_addWUOutputExt(DC_Workunit *wu, const char *logicalFileName, int flags);
-
-/* XML parser callback functions */
-static void wudesc_start(GMarkupParseContext *ctx, const char *element_name,
-	const char **attr_names, const char **attr_values, void *ptr,
-	GError **error);
-static void wudesc_end(GMarkupParseContext *ctx, const char *element_name,
-	void *ptr, GError **error);
-static void wudesc_text(GMarkupParseContext *ctx, const char *text,
-	gsize text_len, void *ptr, GError **error);
-
-
-/********************************************************************
- * Global variables
- */
-
-extern SCHED_CONFIG dc_boinc_config G_GNUC_INTERNAL;
-
-static GHashTable *wu_table;
-static int num_wus;
-
-static const struct tag_desc tags[] =
-{
-	{ WU_WUDESC,		"wudesc" },
-	{ WU_INPUT_LABEL,	"input_label" },
-	{ WU_REMOTE_IN_LABEL,	"remote_input_label" },
-	{ WU_OUTPUT_LABEL,	"output_label" },
-	{ WU_TAG,		"tag" },
-	{ WU_CLIENT_NAME,	"client_name" },
-	{ WU_CLIENT_ARG,	"client_arg" },
-	{ WU_SUBRESULTS,	"subresults" },
-	{ WU_SUBMITTED,		"submitted" },
-	{ WU_SUSPENDED,		"suspended" },
-	{ WU_SERIALIZED,	"serialized" },
-	{ WU_NOSUSPEND,		"nosuspend" },
-	{ WU_NATIVECLIENT,	"nativeclient" },
-	{ WU_PRIORITY,		"priority" },
-	{ WU_BATCH,		"batch" }
-};
-
-static const GMarkupParser wudesc_parser =
-{
-	wudesc_start,
-	wudesc_end,
-	wudesc_text,
-	NULL,
-	NULL
-};
-
-
-/********************************************************************
- * Helper functions
- */
-
-/* Calculate & create the working directory. The working directory has the
- * form: <project work dir>/.dcapi-<project uuid>/<hash>/<wu uuid> Where <hash>
- * is the first 2 hex digits of the uuid
- */
-static char *get_workdir(const uuid_t uuid, int create)
-{
-	char *tmp, uuid_str[37], *cfgval;
-	GString *str;
-	int ret;
-
-	uuid_unparse_lower(uuid, uuid_str);
-
-	cfgval = DC_getCfgStr(CFG_WORKDIR);
-	if (!cfgval)
-		return NULL;
-	str = g_string_new(cfgval);
-	free(cfgval);
-
-	if (create)
-	{
-		ret = mkdir(str->str, 0755);
-		if (ret && errno != EEXIST)
-			goto error;
-	}
-
-	g_string_append_c(str, G_DIR_SEPARATOR);
-	g_string_append(str, ".dcapi-");
-	g_string_append(str, project_uuid_str);
-	if (create)
-	{
-		ret = mkdir(str->str, 0755);
-		if (ret && errno != EEXIST)
-			goto error;
-	}
-
-	g_string_append_c(str, G_DIR_SEPARATOR);
-	g_string_append_printf(str, "%02x", uuid[0]);
-	if (create)
-	{
-		ret = mkdir(str->str, 0755);
-		if (ret && errno != EEXIST)
-			goto error;
-	}
-
-	g_string_append_c(str, G_DIR_SEPARATOR);
-	g_string_append(str, uuid_str);
-	if (create)
-	{
-		ret = mkdir(str->str, 0755);
-		if (ret && errno != EEXIST)
-			goto error;
-	}
-
-	tmp = str->str;
-	g_string_free(str, FALSE);
-	return tmp;
-
-error:
-	DC_log(LOG_ERR, "Failed to create WU working directory %s: %s",
-		str->str, strerror(errno));
-	g_string_free(str, TRUE);
-	return NULL;
-}
-
-/* Get the full path of a file in the WU's working directory */
-char *_DC_workDirPath(const DC_Workunit *wu, const char *label, WorkdirFile type)
-{
-	static const char *const pfx[] = { "in_", "out_", "checkpoint", "dc_" };
-
-	if (type == FILE_CKPT)
-		return g_strdup_printf("%s%ccheckpoint", wu->workdir,
-			G_DIR_SEPARATOR);
-
-	return g_strdup_printf("%s%c%s%s", wu->workdir, G_DIR_SEPARATOR,
-		pfx[type], label);
-}
-
-/* Open a file in the WU's working directory */
-static FILE *open_workdir_file(const DC_Workunit *wu, const char *label,
-	WorkdirFile type, const char *mode)
-{
-	char *name;
-	FILE *f;
-
-	name = _DC_workDirPath(wu, label, type);
-	f = fopen(name, mode);
-	if (!f)
-		DC_log(LOG_ERR, "Failed to open %s (mode %s): %s",
-			name, mode, strerror(errno));
-	g_free(name);
-	return f;
-}
-
-/* Returns the unique per-wu file name in the BOINC download hierarchy,
- * without path components */
-static char *get_input_download_name(DC_Workunit *wu, const char *label, const char *physicalfilename)
-{
-	char uuid_str[37];
-
-	if (physicalfilename)
-		return g_strdup(physicalfilename);
-	else
-	{
-		uuid_unparse_lower(wu->uuid, uuid_str);
-		return g_strdup_printf("%s_%s", label, uuid_str);
-	}
-}
-
-/* Returns the full path of the input file in the BOINC download hierarchy */
-static char *get_input_download_path(DC_Workunit *wu, const char *label, const char *physicalfilename)
-{
-	char *filename, *path;
-
-	filename = get_input_download_name(wu, label, physicalfilename);
-	path = _DC_hierPath(filename, FALSE);
-	g_free(filename);
-	return path;
-}
-
-static int wu_uuid_equal(const void *a, const void *b)
-{
-	return uuid_compare((const unsigned char *)a,
-		(const unsigned char *)b) == 0;
-}
-
-static unsigned wu_uuid_hash(const void *ptr)
-{
-	guint32 *h = (guint *)ptr;
-
-	return h[0] ^ h[1] ^ h[2] ^ h[3];
-}
-
-static DC_Workunit *alloc_wu(void)
-{
-	DC_Workunit *wu;
-
-	wu = g_new0(DC_Workunit, 1);
-	wu->is_optional = g_hash_table_new_full(g_str_hash, g_str_equal, g_free, NULL);
-	wu->refcnt = 1;
-	return wu;
-}
-
-/**
- * Perform regular expression replacement for a given URL.
- * @param url the URL to perform the replace on
- * @return NULL-terminated string array of replacement result(s)
- */
-static gchar **replace_regex(const char *url)
-{
-	if (!url)
-		return NULL;
-
-	char *regex = DC_getCfgStr(CFG_REGEXPMATCH);
-	if (!regex)
-		return NULL;
-
-	char *replace = DC_getCfgStr(CFG_REGEXPREPLACE);
-	if (!replace)
-	{
-		g_free(regex);
-		return NULL;
-	}
-
-	GRegex *reg = g_regex_new(regex, (GRegexCompileFlags)0, (GRegexMatchFlags)0, NULL);
-	if (!reg)
-	{
-		g_free(regex);
-		g_free(replace);
-		return NULL;
-	}
-
-	gchar *res = g_regex_replace(reg, url, -1, 0, replace, (GRegexMatchFlags)0, NULL);
-	if (!res)
-	{
-		g_free(regex);
-		g_free(replace);
-		return NULL;
-	}
-
-	return g_strsplit(res, "\n", 0);
-}
-
-/********************************************************************
- * The WU description parser
- */
-
-static void wudesc_start(GMarkupParseContext *ctx, const char *element_name,
-	const char **attr_names, const char **attr_values, void *ptr,
-	GError **error)
-{
-	struct parser_state *pctx = (struct parser_state *)ptr;
-	int i;
-
-	for (i = 0; i < (int)(sizeof(tags) / sizeof(tags[0])); i++)
-		if (!strcmp(tags[i].name, element_name))
-			break;
-	if (i >= (int)(sizeof(tags) / sizeof(tags[0])))
-	{
-		*error = g_error_new(G_MARKUP_ERROR,
-			G_MARKUP_ERROR_UNKNOWN_ELEMENT,
-			"Unknown element %s", element_name);
-		return;
-	}
-
-	if (tags[i].id == WU_INPUT_LABEL)
-	{
-		if (attr_names && attr_names[0] && !strcmp(attr_names[0], "type"))
-			pctx->curr_mode = (DC_FileMode)atoi(attr_values[0]);
-		else
-			pctx->curr_mode = DC_FILE_REGULAR;
-	}
-	else if (tags[i].id == WU_REMOTE_IN_LABEL)
-	{
-		int j = 0;
-		for (; j < 3; j++) {
-			if (attr_names && attr_names[j] && !strcmp(attr_names[j], "url"))
-				pctx->curr_url = g_strdup(attr_values[j]);
-			if (attr_names && attr_names[j] && !strcmp(attr_names[j], "md5"))
-				pctx->curr_md5 = g_strdup(attr_values[j]);
-			if (attr_names && attr_names[j] && !strcmp(attr_names[j], "size"))
-				pctx->curr_size = atoll(attr_values[j]);
-		}
-	}
-	else if (attr_names && attr_names[0])
-	{
-		*error = g_error_new(G_MARKUP_ERROR,
-			G_MARKUP_ERROR_UNKNOWN_ATTRIBUTE,
-			"Element %s does not take attributes", element_name);
-		return;
-	}
-
-	switch (tags[i].id)
-	{
-		case WU_SERIALIZED:
-			pctx->wu->serialized = TRUE;
-			break;
-		case WU_SUBMITTED:
-			pctx->wu->submitted = TRUE;
-			break;
-		case WU_SUSPENDED:
-			pctx->wu->suspended = TRUE;
-			break;
-		case WU_NOSUSPEND:
-			pctx->wu->nosuspend = TRUE;
-			break;
-		case WU_NATIVECLIENT:
-			pctx->wu->nativeclient = TRUE;
-			break;
-		default:
-			break;
-	}
-
-	pctx->curr_tag = tags[i].id;
-}
-
-static void wudesc_end(GMarkupParseContext *ctx, const char *element_name,
-	void *ptr, GError **error)
-{
-	struct parser_state *pctx = (struct parser_state *)ptr;
-
-	pctx->curr_tag = WU_NOTAG;
-}
-
-static void wudesc_text(GMarkupParseContext *ctx, const char *text,
-	gsize text_len, void *ptr, GError **error)
-{
-	struct parser_state *pctx = (struct parser_state *)ptr;
-	DC_PhysicalFile *file;
-	DC_RemoteFile *rfile;
-	char *tmp, *label;
-
-	switch (pctx->curr_tag)
-	{
-		case WU_INPUT_LABEL:
-			label = g_strndup(text, text_len);
-			tmp = _DC_workDirPath(pctx->wu, label, FILE_IN);
-			file = _DC_createPhysicalFile(label, tmp);
-			g_free(tmp);
-			g_free(label);
-			file->mode = pctx->curr_mode;
-			pctx->wu->input_files =
-				g_list_append(pctx->wu->input_files, file);
-			pctx->wu->num_inputs++;
-			break;
-		case WU_REMOTE_IN_LABEL:
-			label = g_strndup(text, text_len);
-			rfile = _DC_createRemoteFile(label, pctx->curr_url,
-				pctx->curr_md5, pctx->curr_size);
-			pctx->wu->remote_input_files =
-				g_list_append(pctx->wu->remote_input_files, rfile);
-			pctx->wu->num_remote_inputs++;
-			break;
-		case WU_OUTPUT_LABEL:
-			label = g_strndup(text, text_len);
-			pctx->wu->output_files =
-				g_list_append(pctx->wu->output_files, label);
-			pctx->wu->num_outputs++;
-			break;
-		case WU_TAG:
-			pctx->wu->tag = g_strndup(text, text_len);
-			break;
-		case WU_CLIENT_NAME:
-			pctx->wu->client_name = g_strndup(text, text_len);
-			break;
-		case WU_CLIENT_ARG:
-			pctx->wu->argv = g_renew(char *, pctx->wu->argv,
-				pctx->wu->argc + 2);
-			pctx->wu->argv[pctx->wu->argc++] = g_strndup(text, text_len);
-			pctx->wu->argv[pctx->wu->argc] = NULL;
-			break;
-		case WU_SUBRESULTS:
-			tmp = g_strndup(text, text_len);
-			pctx->wu->subresults = atoi(tmp);
-			g_free(tmp);
-			break;
-		case WU_PRIORITY:
-			tmp = g_strndup(text, text_len);
-			pctx->wu->priority = atoi(tmp);
-			g_free(tmp);
-			break;
-		case WU_BATCH:
-			tmp = g_strndup(text, text_len);
-			pctx->wu->batch = atoi(tmp);
-			g_free(tmp);
-			break;
-		case WU_WUDESC:
-			break;
-		case WU_SUSPENDED:
-		case WU_SUBMITTED:
-		case WU_SERIALIZED:
-		case WU_NOSUSPEND:
-		case WU_NATIVECLIENT:
-			/* XXX Emit error? */
-			break;
-		default:
-			break;
-	}
-}
-
-static int write_wudesc(const DC_Workunit *wu)
-{
-	DC_PhysicalFile *file;
-	DC_RemoteFile *rfile;
-	GList *l;
-	FILE *f;
-	int i;
-
-	f = open_workdir_file(wu, WU_DESC_FILE, FILE_DCAPI, "w");
-	if (!f)
-		return DC_ERR_SYSTEM;
-
-	fprintf(f, "<wudesc>\n");
-	if (wu->serialized)
-		fprintf(f, "\t<serialized/>\n");
-	if (wu->submitted)
-		fprintf(f, "\t<submitted/>\n");
-	if (wu->suspended)
-		fprintf(f, "\t<suspended/>\n");
-	if (wu->nosuspend)
-		fprintf(f, "\t<nosuspend/>\n");
-	if (wu->nativeclient)
-		fprintf(f, "\t<nativeclient/>\n");
-	fprintf(f, "\t<tag>%s</tag>\n", wu->tag);
-
-	fprintf(f, "\t<client_name>%s</client_name>\n", wu->client_name);
-	for (i = 0; i < wu->argc; i++)
-		fprintf(f, "\t<client_arg>%s</client_arg>\n", wu->argv[i]);
-
-	for (l = wu->input_files; l; l = l->next)
-	{
-		file = (DC_PhysicalFile *)l->data;
-		fprintf(f, "\t<input_label type=\"%d\">%s</input_label>\n",
-			file->mode, file->label);
-	}
-
-	for (l = wu->remote_input_files; l; l = l->next)
-	{
-		rfile = (DC_RemoteFile *)l->data;
-		fprintf(f, "\t<remote_input_label url=\"%s\" md5=\"%s\" size=\"%zu\">%s</remote_input_label>\n",
-			rfile->url, rfile->remotefilehash, rfile->remotefilesize, rfile->label);
-	}
-
-	for (l = wu->output_files; l; l = l->next)
-		fprintf(f, "\t<output_label>%s</output_label>\n", (char *)l->data);
-
-	fprintf(f, "\t<subresults>%d</subresults>\n", wu->subresults);
-	fprintf(f, "\t<priority>%d</priority>\n", wu->priority);
-	fprintf(f, "\t<batch>%d</batch>\n", wu->batch);
-
-	fprintf(f, "</wudesc>\n");
-	fclose(f);
-	return 0;
-}
-
-/********************************************************************
- * API functions
- */
-
-static int generate_client_config(DC_Workunit *wu)
-{
-	DC_PhysicalFile *file;
-	char *workpath;
-	FILE *f;
-
-	workpath = _DC_workDirPath(wu, DC_CONFIG_FILE, FILE_IN);
-	file = _DC_createPhysicalFile(DC_CONFIG_FILE, workpath);
-	g_free(workpath);
-	if (!file)
-		return DC_ERR_INTERNAL;
-	file->mode = DC_FILE_VOLATILE;
-
-	f = fopen(file->path, "w");
-	if (!f)
-	{
-		DC_log(LOG_ERR, "Failed to create file %s: %s", file->path,
-			strerror(errno));
-		return DC_ERR_SYSTEM;
-	}
-	fprintf(f, "# This file is generated by the master-side DC-API\n");
-	fprintf(f, "%s = %s\n", CFG_LOGFILE, DC_LABEL_CLIENTLOG);
-
-	_DC_initClientConfig(wu->client_name, f);
-	fclose(f);
-
-	wu->input_files = g_list_append(wu->input_files, file);
-	wu->num_inputs++;
-	return 0;
-}
-
-DC_Workunit *DC_createWU(const char *clientName, const char *arguments[],
-	int subresults, const char *tag)
-{
-	DC_Workunit *wu;
-	int ret;
-
-	if (!wu_table)
-	{
-		DC_log(LOG_ERR, "%s: Library is not initialized", __func__);
-		return NULL;
-	}
-	if (!clientName)
-	{
-		DC_log(LOG_ERR, "%s: Missing client name", __func__);
-		return NULL;
-	}
-
-	wu = alloc_wu();
-	wu->client_name = g_strdup(clientName);
-	wu->argv = g_strdupv((char **)arguments);
-
-	for (wu->argc = 0; arguments && arguments[wu->argc]; wu->argc++)
-		/* Nothing */;
-
-	wu->subresults = subresults;
-	wu->tag = g_strdup(tag);
-
-	uuid_generate(wu->uuid);
-
-	wu->workdir = get_workdir(wu->uuid, TRUE);
-	if (!wu->workdir)
-	{
-		DC_destroyWU(wu);
-		return NULL;
-	}
-
-	/* Set the default priority */
-	wu->priority = DC_getClientCfgInt(clientName, CFG_DEFAULTPRIO, 0, TRUE);
-
-	/* Set the default batch value */
-	wu->batch = 0;
-
-	/* Add the internal output files */
-	if (DC_getClientCfgBool(clientName, CFG_NATIVECLIENT, FALSE, TRUE))
-	{
-		wu->nativeclient = TRUE;
-		wu->nosuspend = TRUE;
-	}
-	else
-	{
-		/* Add the client config as an internal input file */
-		ret = generate_client_config(wu);
-		if (ret)
-		{
-			DC_destroyWU(wu);
-			return NULL;
-		}
-
-		DC_addWUOutputExt(wu, DC_LABEL_STDOUT, DC_OUTFILE_OPTIONAL);
-		DC_addWUOutputExt(wu, DC_LABEL_STDERR, DC_OUTFILE_OPTIONAL);
-		DC_addWUOutputExt(wu, DC_LABEL_CLIENTLOG, DC_OUTFILE_OPTIONAL);
-		if (DC_getClientCfgBool(clientName, CFG_ENABLESUSPEND, FALSE, TRUE))
-			DC_addWUOutput(wu, CKPT_LABEL_OUT);
-		else
-			wu->nosuspend = TRUE;
-	}
-
-	g_hash_table_insert(wu_table, wu->uuid, wu);
-	++num_wus;
-
-	return wu;
-}
-
-void DC_destroyWU(DC_Workunit *wu)
-{
-	if (!wu || --wu->refcnt > 0)
-		return;
-
-	g_hash_table_remove(wu_table, wu->uuid);
-	--num_wus;
-
-	switch (wu->state)
-	{
-		case DC_WU_RUNNING:
-			DC_cancelWU(wu);
-			break;
-		default:
-			break;
-	}
-
-	g_hash_table_destroy(wu->is_optional);
-
-	while (wu->input_files)
-	{
-		DC_PhysicalFile *file = (DC_PhysicalFile *)wu->input_files->data;
-
-		unlink(file->path);
-		wu->input_files = g_list_delete_link(wu->input_files,
-			wu->input_files);
-		_DC_destroyPhysicalFile(file);
-	}
-
-	while (wu->remote_input_files)
-	{
-		DC_RemoteFile *file = (DC_RemoteFile *)wu->remote_input_files->data;
-
-		wu->remote_input_files = g_list_delete_link(wu->remote_input_files,
-			wu->remote_input_files);
-		_DC_destroyRemoteFile(file);
-	}
-
-	while (wu->output_files)
-	{
-		g_free(wu->output_files->data);
-		wu->output_files = g_list_delete_link(wu->output_files,
-			wu->output_files);
-	}
-
-	if (wu->ckpt_name)
-	{
-		char *path = _DC_workDirPath(wu, wu->ckpt_name, FILE_CKPT);
-		unlink(path);
-		g_free(path);
-		g_free(wu->ckpt_name);
-	}
-
-	if (wu->workdir)
-	{
-		const char *name;
-		GDir *dir;
-		int ret;
-
-		dir = g_dir_open(wu->workdir, 0, NULL);
-		while (dir && (name = g_dir_read_name(dir)))
-		{
-			GString *str = g_string_new(wu->workdir);
-			g_string_append_c(str, G_DIR_SEPARATOR);
-			g_string_append(str, name);
-			unlink(str->str);
-			g_string_free(str, TRUE);
-		}
-		if (dir)
-			g_dir_close(dir);
-
-		ret = rmdir(wu->workdir);
-		if (ret)
-			DC_log(LOG_WARNING, "Failed to remove WU working "
-				"directory %s: %s", wu->workdir,
-				strerror(errno));
-		g_free(wu->workdir);
-	}
-
-	g_free(wu->client_name);
-	if (wu->argv)
-		g_strfreev(wu->argv);
-	g_free(wu->tag);
-
-	g_free(wu);
-}
-
-/* Check if the logical name is not already registered */
-static int check_logical_name(DC_Workunit *wu, const char *logicalFileName)
-{
-	GList *l;
-
-	if (strchr(logicalFileName, '/') || strchr(logicalFileName, '\\'))
-	{
-		DC_log(LOG_ERR, "Illegal characters in logical file name %s",
-			logicalFileName);
-		return DC_ERR_BADPARAM;
-	}
-	for (l = wu->input_files; l; l = l->next)
-	{
-		DC_PhysicalFile *file = (DC_PhysicalFile *)l->data;
-		if (!strcmp(file->label, logicalFileName))
-		{
-			DC_log(LOG_ERR, "File %s is already registered as an "
-				"input file", logicalFileName);
-			return DC_ERR_BADPARAM;
-		}
-	}
-	for (l = wu->remote_input_files; l; l = l->next)
-	{
-		DC_RemoteFile *file = (DC_RemoteFile *)l->data;
-		if (!strcmp(file->label, logicalFileName))
-		{
-			DC_log(LOG_ERR, "File %s is already registered as a "
-				"remote input file", logicalFileName);
-			return DC_ERR_BADPARAM;
-		}
-	}
-	for (l = wu->output_files; l; l = l->next)
-	{
-		if (!strcmp((char *)l->data, logicalFileName))
-		{
-			DC_log(LOG_ERR, "File %s is already registered as an "
-				"output file", logicalFileName);
-			return DC_ERR_BADPARAM;
-		}
-	}
-	return 0;
-}
-
-int DC_addWUInput(DC_Workunit *wu, const char *logicalFileName, const char *URL,
-        DC_FileMode fileMode, ...)
-{
-	int ret;
-	va_list ap;
-	char *workpath;
-	DC_PhysicalFile *file = NULL;
-	DC_RemoteFile *rfile = NULL;
-    int persistent_on_client = 0;
-
-    if (fileMode & DC_FILE_PERSISTENT_CLIENT) 
-    {
-        persistent_on_client = 1;
-        fileMode ^= DC_FILE_PERSISTENT_CLIENT;
-    }
-	/* Sanity checks */
-	if (!wu || !logicalFileName)
-	{
-		DC_log(LOG_ERR, "%s: Missing arguments", __func__);
-		return DC_ERR_BADPARAM;
-	}
-	ret = check_logical_name(wu, logicalFileName);
-	if (ret)
-		return ret;
-
-	/* XXX Check if the wu->num_inputs + wu->num_outputs + wu->subresults
-	 * does not exceed the max. number of file slots */
-
-	/* Handle remote http:// files */
-	if (fileMode == DC_FILE_REMOTE && !strncmp("http://", URL, 7))
-	{
-		va_start(ap, fileMode);
-		char *md5 = va_arg(ap, char *);
-		size_t size = va_arg(ap, size_t);
-		va_end(ap);
-
-		rfile = _DC_createRemoteFile(logicalFileName, URL, md5, size);
-		if (!rfile)
-			return DC_ERR_INTERNAL;
-
-        if (persistent_on_client) 
-        {
-            rfile->persistentonclient = 1;
-        }
-
-		wu->remote_input_files = g_list_append(wu->remote_input_files, rfile);
-		wu->num_remote_inputs++;
-
-		if (wu->serialized)
-		write_wudesc(wu);
-
-		return 0;
-	}
-
-	/* Now handle local and attic files */
-	workpath = _DC_workDirPath(wu, logicalFileName, FILE_IN);
-	file = _DC_createPhysicalFile(logicalFileName, workpath);
-	g_free(workpath);
-	if (!file)
-		return DC_ERR_INTERNAL;
-
-	/* Handle remote attic:// files */
-	if (fileMode == DC_FILE_REMOTE && !strncmp("attic://", URL, 8))
-	{
-		va_start(ap, fileMode);
-		char *md5 = va_arg(ap, char *);
-		size_t size = va_arg(ap, size_t);
-		va_end(ap);
-
-		// If regular expression for the Attic file gives valid substitutions,
-		// use substitued URLs and keep the file remote
-		gchar **repl = replace_regex(URL);
-		if (repl)
-		{
-			g_strfreev(repl);
-			_DC_destroyPhysicalFile(file);
-
-			rfile = _DC_createRemoteFile(logicalFileName, URL, md5, size);
-			if (!rfile)
-				return DC_ERR_INTERNAL;
-
-            if (persistent_on_client) 
-            {
-                rfile->persistentonclient = 1;
-            }
-
-			wu->remote_input_files = g_list_append(wu->remote_input_files, rfile);
-			wu->num_remote_inputs++;
-
-			if (wu->serialized)
-			write_wudesc(wu);
-
-			return 0;
-		}
-
-		char *physicalFileName = g_strrstr(URL,"/");
-		if (!physicalFileName)
-		{
-			DC_log(LOG_ERR, "URL of attic file has wrong format! URL: '%s'", URL);
-			return DC_ERR_BADPARAM;
-		}
-		physicalFileName++;
-		physicalFileName = g_strdup(physicalFileName);
-
-		char *physicalFileHashString = g_strdup_printf("%s %i\n", md5, (int)size);
-
-		DC_log(LOG_DEBUG, "Attic file details: logic: %s, url:%s, md5:%s, size:%i, file:%s, filecont:%s",
-			logicalFileName, URL, md5, (int)size, physicalFileName, physicalFileHashString);
-
-		file->physicalfilename = strdup(physicalFileName);
-		g_free(physicalFileName);
-
-		if (!physicalFileHashString)
-		{
-			DC_log(LOG_ERR, "%s: Hash of attic file "
-				"'%s' not found", __func__, logicalFileName);
-			return DC_ERR_BADPARAM;
-		}
-		file->physicalfilehash = strdup(physicalFileHashString);
-		g_free(physicalFileHashString);
-	}
-	else if (fileMode == DC_FILE_REMOTE)
-	{
-		DC_log(LOG_ERR, "%s: Unsupported URL received: '%s'",
-			__func__, URL);
-		_DC_destroyPhysicalFile(file);
-		return DC_ERR_BADPARAM;
-	}
-
-    if (persistent_on_client) 
-    {
-        file->persistentonclient = 1;
-    }
-
-	switch (fileMode)
-	{
-		case DC_FILE_PERSISTENT:
-			ret = link(URL, file->path);
-			if (!ret)
-			{
-				/* Remember the file mode */
-				file->mode = DC_FILE_PERSISTENT;
-				break;
-			}
-
-			DC_log(LOG_DEBUG, "Hardlinking failed for input file %s: %s; "
-				"falling back to copy", URL, strerror(errno));
-			/* Fall through */
-		case DC_FILE_REGULAR:
-			ret = _DC_copyFile(URL, file->path);
-			if (ret)
-			{
-				DC_log(LOG_ERR, "Failed to copy the input file %s to %s",
-					URL, file->path);
-				_DC_destroyPhysicalFile(file);
-				return ret;
-			}
-			break;
-		case DC_FILE_VOLATILE:
-			ret = rename(URL, file->path);
-			if (!ret)
-				break;
-			DC_log(LOG_DEBUG, "Renaming failed for input file %s: %s; "
-				"falling back to copy/delete", URL, strerror(errno));
-			ret = _DC_copyFile(URL, file->path);
-			if (ret)
-			{
-				DC_log(LOG_ERR, "Failed to copy the input file %s to %s",
-					URL, file->path);
-				_DC_destroyPhysicalFile(file);
-				return ret;
-			}
-			unlink(URL);
-			break;
-		case DC_FILE_REMOTE:
-			break;
-		default:
-			DC_log(LOG_ERR, "Invalid file mode %d", fileMode);
-			return DC_ERR_BADPARAM;
-	}
-
-	file->mode = fileMode;
-	wu->input_files = g_list_append(wu->input_files, file);
-	wu->num_inputs++;
-
-	if (wu->serialized)
-		write_wudesc(wu);
-
-	return 0;
-}
-
-int DC_addWUOutputExt(DC_Workunit *wu, const char *logicalFileName, int flags)
-{
-	int ret;
-
-	/* Sanity checks */
-	if (!wu || !logicalFileName)
-	{
-		DC_log(LOG_ERR, "%s: Missing arguments", __func__);
-		return DC_ERR_BADPARAM;
-	}
-	ret = check_logical_name(wu, logicalFileName);
-	if (ret)
-		return ret;
-
-	if (flags & DC_OUTFILE_OPTIONAL)
-		g_hash_table_replace(wu->is_optional,
-				     g_strdup(logicalFileName),
-				     (void*)1);
-
-	/* XXX Check if the wu->num_inputs + wu->num_outputs + wu->subresults
-	 * does not exceed the max. number of file slots */
-
-	wu->output_files = g_list_append(wu->output_files,
-		g_strdup(logicalFileName));
-	wu->num_outputs++;
-
-	if (wu->serialized)
-		write_wudesc(wu);
-
-	return 0;
-}
-int DC_addWUOutput(DC_Workunit *wu, const char *logicalFileName)
-{
-	return DC_addWUOutputExt(wu, logicalFileName, 0);
-}
-
-/* This function installs input files to the Boinc download directory */
-static int install_input_files(DC_Workunit *wu)
-{
-	char *dest;
-	GList *l;
-	int ret;
-
-	for (l = wu->input_files; l; l = l->next)
-	{
-		DC_PhysicalFile *file = (DC_PhysicalFile *)l->data;
-
-		/* This also creates the directory if needed */
-		dest = get_input_download_path(wu, file->label, file->physicalfilename);
-		/* By creating the hard link ourselves we prevent BOINC from
-		 * copying the file later */
-		ret = link(file->path, dest);
-		if (ret)
-		{
-			if (file->physicalfilename)
-			{
-				if (errno == EEXIST)
-				{
-					DC_log(LOG_NOTICE, "File %s already exists under Boinc at %s. Skipping...",file->physicalfilename,dest);
-				}
-				else if (errno == ENOENT)
-				{
-					FILE *f;
-					f = fopen(dest, "w");
-					if (!f)
-					{
-						DC_log(LOG_ERR, "Cannot create file %s: %s",dest,strerror(errno));
-						g_free(dest);
-						return DC_ERR_INTERNAL;
-					}
-					fprintf(f, "This file has been generated by DC-API.\nOriginal location of this file:%s", dest);
-					fclose(f);
-					DC_log(LOG_DEBUG, "File %s has been created by DC-API under Boinc.",dest);
-				}
-				else
-				{
-					DC_log(LOG_ERR, "---Failed to install file %s to the "
-						"Boinc download directory at %s: %s",
-						file->path, dest, strerror(errno));
-					g_free(dest);
-					return DC_ERR_INTERNAL;
-				}
-			}
-			else
-			{
-				DC_log(LOG_ERR, "Failed to install file %s to the "
-					"Boinc download directory at %s: %s",
-					file->path, dest, strerror(errno));
-				g_free(dest);
-				return DC_ERR_INTERNAL;
-			}
-		}
-		if (file->physicalfilehash)
-		{
-			const char *hashFileExt=".md5";
-			GString *hashFile;
-			FILE *f;
-
-			hashFile = g_string_new(dest);
-			g_string_append(hashFile, hashFileExt);
-
-			f = fopen(hashFile->str, "w");
-			if (!f)
-			{
-				if (errno == EEXIST && file->physicalfilename)
-				{
-					DC_log(LOG_NOTICE, "File %s already exists under Boinc. Skipping...",hashFile->str);
-				}
-				else
-				{
-					DC_log(LOG_ERR, "Failed to create hash file %s: %s", hashFile->str,strerror(errno));
-					g_string_free(hashFile, TRUE);
-					g_free(dest);
-					return DC_ERR_INTERNAL;
-				}
-			}
-			else
-			{
-				fprintf(f, "%s", file->physicalfilehash);
-				fclose(f);
-				DC_log(LOG_DEBUG, "Hash file \"%s\" has been created with content \"%s\".", hashFile->str, file->physicalfilehash);
-			}
-
-			g_string_free(hashFile, TRUE);
-		}
-		g_free(dest);
-	}
-
-	/* During resume, we have to install the checkpoint file as well */
-	if (wu->ckpt_name)
-	{
-		char *src;
-
-		src = _DC_workDirPath(wu, wu->ckpt_name, FILE_CKPT);
-		dest = get_input_download_path(wu, wu->ckpt_name, NULL);
-		ret = link(src, dest);
-		if (ret)
-		{
-			DC_log(LOG_ERR, "Failed to install file %s to the "
-				"Boinc download directory at %s: %s",
-				src, dest, strerror(errno));
-			g_free(src);
-			g_free(dest);
-			return DC_ERR_INTERNAL;
-		}
-		g_free(src);
-		g_free(dest);
-	}
-
-	return 0;
-}
-
-static void fill_wu_params(const DC_Workunit *wu, struct wu_params *params)
-{
-    int min_quorum = 0;
-	memset(params, 0, sizeof(*params));
-
-	params->rsc_fpops_est = DC_getClientCfgDouble(wu->client_name,
-		CFG_FPOPS_EST, 1e13, TRUE);
-	params->rsc_fpops_bound = DC_getClientCfgDouble(wu->client_name,
-		CFG_MAXFPOPS, 1e15, TRUE);
-	params->rsc_memory_bound = DC_getClientCfgDouble(wu->client_name,
-		CFG_MAXMEMUSAGE, 128 << 20, TRUE);
-	params->rsc_disk_bound = DC_getClientCfgDouble(wu->client_name,
-		CFG_MAXDISKUSAGE, 64 << 20, TRUE);
-	params->delay_bound = DC_getClientCfgInt(wu->client_name,
-		CFG_DELAYBOUND, 4 * 7 * 24 * 60 * 60, TRUE);
-
-	min_quorum = DC_getClientCfgInt(wu->client_name,
-		CFG_MIN_QUORUM, -1, FALSE);
-		
-    if (min_quorum != -1) 
-    {
-    	params->min_quorum = min_quorum;
-    	if (params->min_quorum < 1)
-    		params->min_quorum = 1;
-    		
-    	params->target_nresults = DC_getClientCfgInt(wu->client_name,
-    		CFG_TARGET_NRESULTS, 1, FALSE);
-    	if (params->target_nresults < params->min_quorum)
-            params->target_nresults = params->min_quorum;
-
-    	params->max_error_results = DC_getClientCfgInt(wu->client_name,
-    		CFG_MAX_ERROR_RESULTS, 0, FALSE);
-    	if (params->max_error_results < 0)
-    		params->max_error_results = 0;
-
-    	params->max_total_results = DC_getClientCfgInt(wu->client_name,
-    		CFG_MAX_TOTAL_RESULTS, 1, FALSE);
-    	if (params->max_total_results < params->min_quorum)
-            params->max_total_results = params->min_quorum;
-            
-    	params->max_success_results = DC_getClientCfgInt(wu->client_name,
-    		CFG_MAX_SUCCESS_RESULTS, 1, FALSE);
-    	if (params->max_success_results < params->min_quorum)
-            params->max_success_results = params->min_quorum;
-    } else {
-    	params->min_quorum = DC_getClientCfgInt(wu->client_name,
-    		CFG_REDUNDANCY, 1, TRUE);
-    	if (params->min_quorum < 1)
-    		params->min_quorum = 1;
-
-    	params->target_nresults = params->min_quorum;
-
-    	/* Calculate with logarithmic error */
-    	params->max_error_results = params->target_nresults +
-    		(int)log(params->min_quorum + 2) + 1;
-    	params->max_total_results = (params->target_nresults +
-    		(int)log(params->min_quorum + 2)) * 2;
-    	params->max_success_results = params->target_nresults +
-    		(int)log(params->min_quorum + 2) + 1;
-    }
-}
-
-static void append_wu_file_info(GString *tmpl, int idx, DC_PhysicalFile *file)
-{
-	g_string_append(tmpl, "<file_info>\n");
-	g_string_append_printf(tmpl, "\t<number>%d</number>\n", idx);
-    if (file != NULL && file->persistentonclient == 1) 
-    {
-        g_string_append(tmpl, "\t<sticky/>\n");
-        g_string_append(tmpl, "\t<no_delete/>\n");
-    }
-	g_string_append(tmpl, "</file_info>\n");
-}
-
-static void append_wu_remote_file_info(GString *tmpl, int idx, DC_RemoteFile *file)
-{
-	g_string_append(tmpl, "<file_info>\n");
-	g_string_append_printf(tmpl, "\t<number>%d</number>\n", idx);
-    if (file != NULL && file->persistentonclient == 1) 
-    {
-        g_string_append(tmpl, "\t<sticky/>\n");
-        g_string_append(tmpl, "\t<no_delete/>\n");
-    }
-	gchar **alts = replace_regex(file->url);
-	if (!alts)
-	{
-		g_string_append_printf(tmpl, "\t<url>%s</url>\n", file->url);
-	}
-	else
-	{
-		int i;
-		for (i = 0; alts[i]; i++)
-			g_string_append_printf(tmpl, "\t<url>%s</url>\n", alts[i]);
-		g_strfreev(alts);
-	}
-	g_string_append_printf(tmpl, "\t<md5_cksum>%s</md5_cksum>\n", file->remotefilehash);
-	g_string_append_printf(tmpl, "\t<nbytes>%lu</nbytes>\n", file->remotefilesize);
-	g_string_append(tmpl, "</file_info>\n");
-}
-
-static void append_wu_file_ref(GString *tmpl, int idx, const char *label)
-{
-	g_string_append(tmpl, "\t<file_ref>\n");
-	g_string_append_printf(tmpl, "\t\t<file_number>%d</file_number>\n", idx);
-	g_string_append_printf(tmpl, "\t\t<open_name>%s</open_name>\n", label);
-	g_string_append(tmpl, "\t</file_ref>\n");
-}
-
-static char *generate_wu_template(DC_Workunit *wu)
-{
-	struct wu_params params;
-	GString *tmpl, *cmd;
-	int i, num_inputs, num_remote_inputs;
-	GList *l;
-	char *p;
-
-	fill_wu_params(wu, &params);
-
-	/* Generate the file info block */
-	num_inputs = wu->num_inputs;
-	num_remote_inputs = wu->num_remote_inputs;
-	if (wu->ckpt_name)
-		num_inputs++;
-
-	tmpl = g_string_new("");
-	for (i = 0, l = wu->input_files; l && i < num_inputs; l = l->next, i++)
-	{
-		DC_PhysicalFile *file = (DC_PhysicalFile *)l->data;
-        append_wu_file_info(tmpl, i, file);
-    }
-    
-	for (l = wu->remote_input_files; l && i < num_inputs + num_remote_inputs;
-			l = l->next, i++)
-	{
-		DC_RemoteFile *file = (DC_RemoteFile *)l->data;
-		append_wu_remote_file_info(tmpl, i, file);
-	}
-	/* Checkpoint file, if exists */
-	if (wu->ckpt_name)
-		append_wu_file_info(tmpl, i++, NULL);
-
-	/* Generate the workunit description */
-	g_string_append(tmpl, "<workunit>\n");
-	for (i = 0, l = wu->input_files; l && i < num_inputs;
-			l = l->next, i++)
-	{
-		DC_PhysicalFile *file = (DC_PhysicalFile *)l->data;
-		append_wu_file_ref(tmpl, i, file->label);
-	}
-
-	for (l = wu->remote_input_files; l && i < num_inputs + num_remote_inputs;
-			l = l->next, i++)
-	{
-		DC_PhysicalFile *file = (DC_PhysicalFile *)l->data;
-		append_wu_file_ref(tmpl, i, file->label);
-	}
-
-	/* Checkpoint file */
-	if (wu->ckpt_name)
-		append_wu_file_ref(tmpl, i++, CKPT_LABEL_IN);
-
-	/* Concatenate the shell-quoted argv elements into a single string */
-	cmd = g_string_new("");
-	for (i = 0; i < wu->argc; i++)
-	{
-		if (i)
-			g_string_append_c(cmd, ' ');
-		g_string_append(cmd, wu->argv[i]);
-	}
-	g_string_append_printf(tmpl,
-		"\t<command_line>%s</command_line>\n", cmd->str);
-	g_string_free(cmd, TRUE);
-
-	g_string_append_printf(tmpl,
-		"\t<rsc_fpops_est>%g</rsc_fpops_est>\n", params.rsc_fpops_est);
-	g_string_append_printf(tmpl,
-		"\t<rsc_fpops_bound>%g</rsc_fpops_bound>\n",
-		params.rsc_fpops_bound);
-	g_string_append_printf(tmpl,
-		"\t<rsc_memory_bound>%g</rsc_memory_bound>\n",
-		params.rsc_memory_bound);
-	g_string_append_printf(tmpl,
-		"\t<rsc_disk_bound>%g</rsc_disk_bound>\n",
-		params.rsc_disk_bound);
-	g_string_append_printf(tmpl,
-		"\t<delay_bound>%d</delay_bound>\n", params.delay_bound);
-	g_string_append_printf(tmpl,
-		"\t<min_quorum>%d</min_quorum>\n", params.min_quorum);
-	g_string_append_printf(tmpl,
-		"\t<target_nresults>%d</target_nresults>\n",
-		params.target_nresults);
-	g_string_append_printf(tmpl,
-		"\t<max_error_results>%d</max_error_results>\n",
-		params.max_error_results);
-	g_string_append_printf(tmpl,
-		"\t<max_success_results>%d</max_success_results>\n",
-		params.max_success_results);
-	g_string_append_printf(tmpl,
-		"\t<max_total_results>%d</max_total_results>\n",
-		params.max_total_results);
-
-	g_string_append(tmpl, "</workunit>\n");
-
-	p = tmpl->str;
-	g_string_free(tmpl, FALSE);
-	return p;
-}
-
-static void append_result_file_info(GString *tmpl, int idx, int auto_upload,
-	double max_output)
-{
-	g_string_append(tmpl, "<file_info>\n");
-	g_string_append_printf(tmpl, "\t<name><OUTFILE_%d/></name>\n", idx);
-	g_string_append(tmpl, "\t<generated_locally/>\n");
-	if (auto_upload)
-		g_string_append(tmpl, "\t<upload_when_present/>\n");
-	g_string_append_printf(tmpl, "\t<max_nbytes>%g</max_nbytes>\n", max_output);
-
-	gchar *uploadURL = DC_getCfgStr(CFG_UPLOADURL);
-	if (!uploadURL)
-		g_string_append(tmpl, "\t<url><UPLOAD_URL/></url>\n");
-	else
-	{
-		g_string_append_printf(tmpl, "\t<url>%s</url>\n", uploadURL);
-		free(uploadURL);
-	}
-
-	g_string_append(tmpl, "</file_info>\n");
-}
-
-static void append_result_file_ref(GString *tmpl, int idx, int optional, const char *fmt, ...)
-	G_GNUC_PRINTF(4, 5);
-static void append_result_file_ref(GString *tmpl, int idx, int optional, const char *fmt, ...)
-{
-	char buf[1024];
-	va_list ap;
-
-	g_string_append(tmpl, "\t<file_ref>\n");
-	g_string_append_printf(tmpl, "\t\t<file_name><OUTFILE_%d/></file_name>\n", idx);
-	g_string_append(tmpl, "\t\t<open_name>");
-
-	va_start(ap, fmt);
-	vsnprintf(buf, sizeof(buf), fmt, ap);
-	va_end(ap);
-	g_string_append(tmpl, buf);
-
-	g_string_append(tmpl, "</open_name>\n");
-	if (optional)
-		g_string_append(tmpl, "<optional>1</optional>");
-	g_string_append(tmpl, "\t</file_ref>\n");
-}
-
-static char *generate_result_template(DC_Workunit *wu)
-{
-	unsigned char digest[SHA_DIGEST_LENGTH];
-	int i, file_cnt;
-    // support output files larger than 2GB
-    double max_output_size;
-	GString *path, *tmpl;
-	char *file, *cfgval;
-	SHA_CTX sha;
-	GList *l;
-
-	cfgval = DC_getCfgStr(CFG_PROJECTROOT);
-	if (!cfgval)
-	{
-		/* Should never happen here */
-		DC_log(LOG_ERR, "Internal error: project root is not set");
-		return NULL;
-	}
-
-	max_output_size = DC_getClientCfgDouble(wu->client_name, CFG_MAXOUTPUT,
-		256 * 1024, TRUE);
-	file_cnt = 0;
-
-	tmpl = g_string_new("");
-
-	/* Slots for output files */
-	for (i = 0; i < wu->num_outputs; i++)
-		append_result_file_info(tmpl, file_cnt++, TRUE, max_output_size);
-	/* Slots for subresults - no automatic uploading */
-	for (i = 0; i < wu->subresults; i++)
-		append_result_file_info(tmpl, file_cnt++, FALSE, max_output_size);
-
-	g_string_append(tmpl, "<result>\n");
-	file_cnt = 0;
-	/* The output templates */
-	for (l = wu->output_files; l; l = l->next)
-	{
-		char *lname = (char*)l->data;
-	        int optional = 0 != g_hash_table_lookup(wu->is_optional, lname);							
-		append_result_file_ref(tmpl, file_cnt++, optional, "%s", lname);
-	}
-
-	/* The subresult templates */
-	for (i = 0; i < wu->subresults; i++)
-		append_result_file_ref(tmpl, file_cnt++, 0, "%s%d", SUBRESULT_PFX, i);
-
-	g_string_append(tmpl, "</result>\n");
-
-	/* Use the hash of the template's contents as the file name,
-	 * so we can avoid generating lots of files with the same
-	 * content */
-	SHA1_Init(&sha);
-	SHA1_Update(&sha, tmpl->str, strlen(tmpl->str));
-	SHA1_Final(digest, &sha);
-
-	path = g_string_new(cfgval);
-	g_string_append_printf(path, "%ctemplates%cdcapi_",
-		G_DIR_SEPARATOR, G_DIR_SEPARATOR);
-	for (i = 0; i < SHA_DIGEST_LENGTH; i += 2)
-		g_string_append_printf(path, "%02x%02x", digest[i], digest[i + 1]);
-	g_string_append(path, ".xml");
-
-	if (access(path->str, R_OK))
-	{
-		FILE *f = fopen(path->str, "w");
-		if (!f)
-		{
-			DC_log(LOG_ERR, "Failed to create result template %s: %s",
-				path->str, strerror(errno));
-			g_string_free(tmpl, TRUE);
-			g_string_free(path, TRUE);
-			free(cfgval);
-			return NULL;
-		}
-
-		fprintf(f, "%s", tmpl->str);
-		fclose(f);
-	}
-
-	file = g_strdup(path->str + strlen(cfgval) + 1);
-	free(cfgval);
-	g_string_free(path, TRUE);
-	return file;
-}
-
-static int lookup_appid(DC_Workunit *wu)
-{
-	char *query;
-	DB_APP app;
-
-	query = g_strdup_printf("WHERE name = '%s'", wu->client_name);
-	if (app.lookup(query))
-	{
-		DC_log(LOG_ERR, "Failed to look up application %s",
-			wu->client_name);
-		g_free(query);
-		return -1;
-	}
-	g_free(query);
-	return app.get_id();
-}
-
-char *_DC_getWUName(const DC_Workunit *wu)
-{
-	char uuid_str[37];
-
-	uuid_unparse_lower(wu->uuid, uuid_str);
-	if (wu->tag)
-		return g_strdup_printf("%s_%s_%s", project_uuid_str, uuid_str,
-			wu->tag);
-	else
-		return g_strdup_printf("%s_%s", project_uuid_str, uuid_str);
-}
-
-int DC_submitWU(DC_Workunit *wu)
-{
-	char *wu_template, *result_template_file, **infiles, *result_path,
-	     *name, *cfgval;
-	struct wu_params params;
-	int i, ret, ninputs;
-	DB_WORKUNIT dbwu;
-	GList *l;
-
-	if (!wu)
-	{
-		DC_log(LOG_ERR, "%s: Missing WU", __func__);
-		return DC_ERR_BADPARAM;
-	}
-
-	ret = install_input_files(wu);
-	if (ret)
-		return ret;
-
-	dbwu.clear();
-
-	name = _DC_getWUName(wu);
-	snprintf(dbwu.name, sizeof(dbwu.name), "%s", name);
-	g_free(name);
-
-	dbwu.appid = lookup_appid(wu);
-	if (dbwu.appid == -1)
-		return DC_ERR_DATABASE;
-
-	fill_wu_params(wu, &params);
-	dbwu.rsc_fpops_est = params.rsc_fpops_est;
-	dbwu.rsc_fpops_bound = params.rsc_fpops_bound;
-	dbwu.rsc_memory_bound = params.rsc_memory_bound;
-	dbwu.rsc_disk_bound = params.rsc_disk_bound;
-	dbwu.delay_bound = params.delay_bound;
-
-	dbwu.priority = wu->priority;
-	dbwu.batch = wu->batch;
-
-	wu_template = generate_wu_template(wu);
-	result_template_file = generate_result_template(wu);
-	if (!result_template_file)
-	{
-		g_free(wu_template);
-		return DC_ERR_INTERNAL;
-	}
-	cfgval = DC_getCfgStr(CFG_PROJECTROOT);
-	if (!cfgval)
-	{
-		g_free(wu_template);
-		g_free(result_template_file);
-		errno = ENOMEM;
-		return DC_ERR_SYSTEM;
-	}
-	result_path = g_strdup_printf("%s%c%s", cfgval, G_DIR_SEPARATOR,
-		result_template_file);
-	free(cfgval);
-
-	/* Create the input file name array as required by create_work() */
-	ninputs = wu->num_inputs + wu->num_remote_inputs;
-	if (wu->ckpt_name)
-		ninputs++;
-
-	infiles = g_new0(char *, ninputs + 1);
-	for (l = wu->input_files, i = 0; l && i < wu->num_inputs;
-			l = l->next, i++)
-	{
-		DC_PhysicalFile *file = (DC_PhysicalFile *)l->data;
-		infiles[i] = get_input_download_name(wu, file->label, file->physicalfilename);
-	}
-	for (l = wu->remote_input_files; l && i < wu->num_remote_inputs+wu->num_inputs;
-			l = l->next, i++)
-	{
-		DC_RemoteFile *file = (DC_RemoteFile *)l->data;
-		infiles[i] = g_strdup_printf("%s_%s", file->label, md5_string(file->url).c_str());
-	}
-	if (wu->ckpt_name)
-		infiles[i++] = get_input_download_name(wu, wu->ckpt_name, NULL);
-	/* Terminator so we can use g_strfreev() later */
-	infiles[i] = NULL;
-
-	ret = create_work(dbwu, wu_template, result_template_file, result_path,
-		const_cast<const char **>(infiles), ninputs, dc_boinc_config);
-	g_free(result_path);
-	g_strfreev(infiles);
-	g_free(result_template_file);
-	g_free(wu_template);
-
-	if (ret)
-	{
-		DC_log(LOG_ERR, "Failed to create Boinc work unit");
-		return DC_ERR_DATABASE;
-	}
-
-	wu->state = DC_WU_RUNNING;
-
-	wu->submitted = TRUE;
-
-	_DC_getDBid(wu);
-	
-	write_wudesc(wu);
-
-	return 0;
-}
-
-char *DC_serializeWU(DC_Workunit *wu)
-{
-	char id[2 * 36 + 2];
-
-	if (!wu)
-	{
-		DC_log(LOG_ERR, "%s: Missing WU", __func__);
-		return NULL;
-	}
-
-	if (write_wudesc(wu))
-		return NULL;
-
-	wu->serialized = TRUE;
-
-	strncpy(id, project_uuid_str, sizeof(id));
-	id[36] = '_';
-	uuid_unparse_lower(wu->uuid, id + 37);
-	return strdup(id);
-}
-
-DC_Workunit *DC_deserializeWU(const char *buf)
-{
-	if (!wu_table)
-	{
-		DC_log(LOG_ERR, "%s: Library is not initialized", __func__);
-		return NULL;
-	}
-	if (!buf)
-	{
-		DC_log(LOG_ERR, "%s: No serialized data", __func__);
-		return NULL;
-	}
-
-	return _DC_getWUByName(buf);
-}
-
-static DC_Workunit *load_from_boinc_db(const uuid_t uuid)
-{
-	char uuid_str[37], *query, *result_template, *cfgval, *filename;
-	GList *output_files;
-	DB_WORKUNIT db_wu;
-	DC_Workunit *wu;
-	DB_APP app;
-	int ret;
-
-	uuid_unparse_lower(uuid, uuid_str);
-	query = g_strdup_printf("WHERE name LIKE '%s\\_%s%%'", project_uuid_str,
-		uuid_str);
-	ret = db_wu.lookup(query);
-	g_free(query);
-	if (ret)
-	{
-		DC_log(LOG_WARNING, "Could not load WU %s_%s from the BOINC "
-			"database", project_uuid_str, uuid_str);
-		return NULL;
-	}
-
-	ret = app.lookup_id(db_wu.appid);
-	if (ret)
-	{
-		DC_log(LOG_WARNING, "Could not find application ID %d",
-			db_wu.appid);
-		return NULL;
-	}
-
-	cfgval = DC_getCfgStr(CFG_PROJECTROOT);
-	if (!cfgval)
-	{
-		/* Should never happen here */
-		DC_log(LOG_ERR, "Internal error: project root is not set");
-		return NULL;
-	}
-
-	filename = g_strdup_printf("%s%c%s", cfgval, G_DIR_SEPARATOR,
-		db_wu.result_template_file);
-	free(cfgval);
-	ret = g_file_get_contents(filename, &result_template, NULL, NULL);
-	if (!ret)
-	{
-		DC_log(LOG_ERR, "Result template file %s is missing", filename);
-		g_free(filename);
-		return NULL;
-	}
-	g_free(filename);
-
-	wu = alloc_wu();
-	wu->client_name = g_strdup(app.name);
-	memcpy(wu->uuid, uuid, sizeof(wu->uuid));
-
-	/* If the WU is in the database then it was submitted... */
-	wu->submitted = TRUE;
-
-	if (strlen(db_wu.name) > 74)
-		wu->tag = g_strdup(db_wu.name + 74);
-
-	/* Always create the WU's work dir */
-	wu->workdir = get_workdir(wu->uuid, TRUE);
-	if (!wu->workdir)
-	{
-		DC_destroyWU(wu);
-		g_free(result_template);
-		return NULL;
-	}
-
-	output_files = _DC_parseFileRefs(result_template, NULL);
-	g_free(result_template);
-	if (!output_files)
-	{
-		DC_log(LOG_ERR, "Failed to parse the output files for WU %s_%s",
-			project_uuid_str, uuid_str);
-		DC_destroyWU(wu);
-		return NULL;
-	}
-
-	while (output_files)
-	{
-		DC_PhysicalFile *file = (DC_PhysicalFile *)output_files->data;
-
-		DC_addWUOutput(wu, file->label);
-		_DC_destroyPhysicalFile(file);
-		output_files = g_list_delete_link(output_files, output_files);
-	}
-
-	/* We may no longer have the input files, this WU can not be suspended */
-	wu->nosuspend = TRUE;
-
-	g_hash_table_insert(wu_table, wu->uuid, wu);
-	++num_wus;
-
-	_DC_updateWUState(wu);
-
-	return wu;
-}
-
-static DC_Workunit *load_from_disk(const uuid_t uuid)
-{
-	GMarkupParseContext *ctx;
-	struct parser_state pctx;
-	char *workdir, buf[256];
-	DC_Workunit *wu;
-	GError *error = NULL;
-	FILE *f;
-
-	workdir = get_workdir(uuid, FALSE);
-	if (!g_file_test(workdir, G_FILE_TEST_IS_DIR))
-	{
-		g_free(workdir);
-		return NULL;
-	}
-
-	wu = alloc_wu();
-	wu->workdir = workdir;
-	memcpy(wu->uuid, uuid, sizeof(wu->uuid));
-
-	f = open_workdir_file(wu, WU_DESC_FILE, FILE_DCAPI, "r");
-	if (!f)
-	{
-		DC_destroyWU(wu);
-		return NULL;
-	}
-
-	memset(&pctx, 0, sizeof(pctx));
-	pctx.wu = wu;
-	ctx = g_markup_parse_context_new(&wudesc_parser, (GMarkupParseFlags)0,
-		&pctx, NULL);
-	while (fgets(buf, sizeof(buf), f))
-	{
-		if (!g_markup_parse_context_parse(ctx, buf, strlen(buf),
-				&error))
-			goto error;
-	}
-	if (!g_markup_parse_context_end_parse(ctx, &error))
-		goto error;
-
-	g_markup_parse_context_free(ctx);
-	fclose(f);
-
-	g_hash_table_insert(wu_table, wu->uuid, wu);
-	++num_wus;
-
-	_DC_updateWUState(wu);
-
-	return wu;
-
-error:
-	g_markup_parse_context_free(ctx);
-	fclose(f);
-	DC_destroyWU(wu);
-	DC_log(LOG_ERR, "Failed to parse WU description: %s",
-		error->message);
-	g_error_free(error);
-	return NULL;
-}
-
-DC_Workunit *_DC_getWUByName(const char *name)
-{
-	DC_Workunit *wu;
-	char *uuid_str;
-	uuid_t uuid;
-	int ret;
-
-	/* Check if the WU belongs to this application */
-	uuid_str = g_strndup(name, 36);
-	ret = uuid_parse(uuid_str, uuid);
-	g_free(uuid_str);
-	if (ret)
-	{
-		DC_log(LOG_ERR, "WU name '%s' contains illegal UUID", name);
-		return NULL;
-	}
-
-	if (uuid_compare(uuid, project_uuid))
-	{
-		DC_log(LOG_WARNING, "WU '%s' does not belong to this "
-			"application", name);
-		return NULL;
-	}
-
-	/* WU name syntax: <uuid> '_' <uuid> [ '_' <tag> ] */
-	if (name[36] != '_' || (strlen(name) > 73 && name[73] != '_'))
-	{
-		DC_log(LOG_ERR, "Illegal WU name syntax in '%s'", name);
-		return NULL;
-	}
-
-	/* Check the WU's UUID */
-	uuid_str = g_strndup(name + 37, 36);
-	ret = uuid_parse(uuid_str, uuid);
-	g_free(uuid_str);
-	if (ret)
-	{
-		DC_log(LOG_ERR, "WU name '%s' contains illegal UUID", name);
-		return NULL;
-	}
-
-	wu = (DC_Workunit *)g_hash_table_lookup(wu_table, uuid);
-	if (wu)
-		return wu;
-	wu = load_from_disk(uuid);
-	if (wu)
-		return wu;
-	return load_from_boinc_db(uuid);
-}
-
-static void count_ready(void *key, void *value, void *ptr)
-{
-	DC_Workunit *wu = (DC_Workunit *)value;
-	int *count = (int *)ptr;
-
-	if (wu->state == DC_WU_READY)
-		++(*count);
-}
-
-int DC_getWUNumber(DC_WUState state)
-{
-	DB_BASE db("", &boinc_db);
-	int val, ret;
-	char *query;
-
-	switch (state)
-	{
-		case DC_WU_READY:
-			val = 0;
-			g_hash_table_foreach(wu_table, count_ready, &val);
-			return val;
-		case DC_WU_RUNNING:
-			query = g_strdup_printf("SELECT COUNT(DISTINCT wu.id) "
-				"FROM result res FORCE INDEX(ind_res_st), workunit wu "
-				"WHERE res.workunitid = wu.id AND "
-					"wu.name LIKE '%s\\_%%' AND "
-					"(res.server_state = %d OR res.server_state = %d)",
-				project_uuid_str, RESULT_SERVER_STATE_UNSENT,
-				RESULT_SERVER_STATE_IN_PROGRESS);
-			ret = db.get_integer(query, val);
-			g_free(query);
-			if (ret)
-				return -1;
-			return val;
-		case DC_WU_FINISHED:
-			query = g_strdup_printf("SELECT COUNT(*) "
-				"FROM workunit wu WHERE "
-				"wu.name LIKE '%s\\_%%' AND "
-				"wu.assimilate_state = %d",
-				project_uuid_str, ASSIMILATE_READY);
-			ret = db.get_integer(query, val);
-			g_free(query);
-			if (ret)
-				return -1;
-			return val;
-		case DC_WU_ABORTED:
-			query = g_strdup_printf("SELECT COUNT(*) "
-				"FROM workunit wu WHERE "
-				"wu.name LIKE '%s\\_%%' AND "
-				"wu.error_mask != 0",
-				project_uuid_str);
-			ret = db.get_integer(query, val);
-			g_free(query);
-			if (ret)
-				return -1;
-			return val;
-		case DC_WU_SUSPENDED:
-			/* XXX */
-		case DC_WU_UNKNOWN:
-		default:
-			return -1;
-	}
-}
-
-char *DC_getWUTag(const DC_Workunit *wu)
-{
-	if (!wu)
-	{
-		DC_log(LOG_ERR, "%s: Missing WU", __func__);
-		return NULL;
-	}
-
-	return strdup(wu->tag);
-}
-
-char *DC_getWUId(const DC_Workunit *wu)
-{
-	if (!wu)
-	{
-		DC_log(LOG_ERR, "%s: Missing WU", __func__);
-		return NULL;
-	}
-	
-	if (wu->db_id)
-		return g_strdup_printf("%i",wu->db_id);
-	else
-		return NULL;
-}
-
-int DC_setWUPriority(DC_Workunit *wu, int priority)
-{
-	if (!wu)
-	{
-		DC_log(LOG_ERR, "%s: Missing WU", __func__);
-		return DC_ERR_BADPARAM;
-	}
-
-	wu->priority = priority;
-	if (wu->serialized)
-		write_wudesc(wu);
-	return 0;
-}
-
-int DC_setWUBatch(DC_Workunit *wu, int batch)
-{
-        if (!wu)
-        {
-                DC_log(LOG_ERR, "%s: Missing WU", __func__);
-                return DC_ERR_BADPARAM;
-        }
-
-        wu->batch = batch;
-        if (wu->serialized)
-                write_wudesc(wu);
-        return 0;
-}
-
-
-DC_WUState DC_getWUState(DC_Workunit *wu)
-{
-	if (!wu)
-	{
-		DC_log(LOG_ERR, "%s: Missing WU", __func__);
-		return DC_WU_UNKNOWN;
-	}
-
-	return wu->state;
-}
-
-int DC_suspendWU(DC_Workunit *wu)
-{
-	if (!wu)
-	{
-		DC_log(LOG_ERR, "%s: Missing WU", __func__);
-		return DC_ERR_BADPARAM;
-	}
-
-	if (wu->nosuspend)
-	{
-		char *name = _DC_getWUName(wu);
-		DC_log(LOG_ERR, "Work unit %s can not be suspended", name);
-		g_free(name);
-		return DC_ERR_BADPARAM;
-	}
-
-	return DC_ERR_NOTIMPL;
-}
-
-int DC_resumeWU(DC_Workunit *wu)
-{
-	if (!wu)
-	{
-		DC_log(LOG_ERR, "%s: Missing WU", __func__);
-		return DC_ERR_BADPARAM;
-	}
-	if (!wu->suspended)
-	{
-		char *name = _DC_getWUName(wu);
-		DC_log(LOG_ERR, "Work unit %s is not suspended, cannot resume", name);
-		g_free(name);
-		return DC_ERR_BADPARAM;
-	}
-
-	return DC_ERR_NOTIMPL;
-}
-
-int _DC_initWUs(void)
-{
-	wu_table = g_hash_table_new_full(wu_uuid_hash, wu_uuid_equal, NULL, NULL);
-	return 0;
-}
diff --git a/dcapi/cf/boinc.m4 b/dcapi/cf/boinc.m4
deleted file mode 100644
index 3d04cdc..0000000
--- a/dcapi/cf/boinc.m4
+++ /dev/null
@@ -1,108 +0,0 @@
-dnl
-dnl Check for BOINC components
-dnl
-
-dnl
-dnl SZDG_BOINC_COMMON
-dnl
-dnl Check for components common for the client and server API
-dnl
-AC_DEFUN([SZDG_BOINC_COMMON], [
-	AC_ARG_WITH([boinc], AS_HELP_STRING([--with-boinc@<:@=DIR@:>@],
-		[Use BOINC (compiled or installed in DIR)]),, [with_boinc=auto])
-
-	no_boinc=
-	if test "$with_boinc" = no; then
-		no_boinc=yes
-	fi
-
-	if test "$no_boinc" != yes; then
-		case "$with_boinc" in
-			yes|auto)
-				BOINC_INCLUDES="/usr/include/boinc"
-				BOINC_CPPFLAGS="-I/usr/include/boinc"
-				BOINC_LDFLAGS=
-				;;
-			*)
-				# Check if this is an installed or just a compiled-in-place
-				# version
-				if test -d "$with_boinc/sched"; then
-					BOINC_CPPFLAGS="-I$with_boinc/api -I$with_boinc/lib -I$with_boinc/sched -I$with_boinc/tools -I$with_boinc/db"
-					BOINC_LDFLAGS="-L$with_boinc/api -L$with_boinc/lib -L$with_boinc/sched"
-				else
-					BOINC_CPPFLAGS="-I$with_boinc/include/boinc"
-					BOINC_LDFLAGS="-L$with_boinc/lib"
-				fi
-				;;
-		esac
-	fi
-
-	if test "$no_boinc" != yes; then
-		BOINC_COMMON_LIBS="-lboinc -lcrypto"
-	fi
-
-	AC_SUBST([BOINC_CPPFLAGS])
-	AC_SUBST([BOINC_LDFLAGS])
-])
-
-dnl
-dnl SZDG_BOINC_SERVER
-dnl
-dnl Check for BOINC server-side API
-dnl
-AC_DEFUN([SZDG_BOINC_SERVER], [
-	AC_REQUIRE([SZDG_BOINC_COMMON])
-
-	dnl
-	dnl First check for MySQL
-	dnl
-	AC_PATH_PROG([MYSQL_CONFIG], [mysql_config])
-	if test "$MYSQL_CONFIG" = ""; then
-		no_boinc=yes
-	else
-		MYSQL_CPPFLAGS="`$MYSQL_CONFIG --include`"
-		MYSQL_LIBS=`$MYSQL_CONFIG --libs | sed -e 's,-L/usr/lib , ,'`
-	fi
-	AC_SUBST([MYSQL_CPPFLAGS])
-	AC_SUBST([MYSQL_LIBS])
-
-	if test "$no_boinc" != yes; then
-		BOINC_SERVER_CPPFLAGS="$BOINC_CPPFLAGS $MYSQL_CPPFLAGS"
-		BOINC_SERVER_LIBS="-lsched $BOINC_COMMON_LIBS -lstdc++ $MYSQL_LIBS"
-	fi
-
-	AC_SUBST([BOINC_SERVER_CPPFLAGS])
-	AC_SUBST([BOINC_SERVER_LIBS])
-
-	if test "$with_boinc" = yes && test "$no_boinc" = yes; then
-		AC_MSG_ERROR([BOINC development environment was not found])
-	fi
-])
-
-dnl
-dnl SZDG_BOINC_CLIENT
-dnl
-dnl Check for BOINC client-side API
-dnl
-AC_DEFUN([SZDG_BOINC_CLIENT], [
-	AC_REQUIRE([SZDG_BOINC_COMMON])
-
-	save_CPPFLAGS="$CPPFLAGS"
-	CPPFLAGS="$CPPFLAGS $BOINC_CPPFLAGS"
-	save_LDFLAGS="$LDFLAGS $BOINC_LDFLAGS"
-	LDFLAGS="$LDFLAGS $BOINC_LDFLAGS"
-	AC_CHECK_HEADERS([boinc_api.h filesys.h diagnostics.h],, [no_boinc=yes])
-	AC_LANG_PUSH([C++])
-	AC_CHECK_LIB([boinc_api], [boinc_init], [true], [no_boinc=yes],
-		[-lboinc -lm -pthread])
-	AC_LANG_POP([C++])
-	LDFLAGS="$save_LDFLAGS"
-	CPPFLAGS="$save_CPPFLAGS"
-
-	if test "$with_boinc" = yes && test "$no_boinc" = yes; then
-		AC_MSG_ERROR([BOINC development environment was not found])
-	fi
-
-	BOINC_CLIENT_LIBS="-lboinc_api $BOINC_COMMON_LIBS -lstdc++ -lm -pthread"
-	AC_SUBST([BOINC_CLIENT_LIBS])
-])
diff --git a/dcapi/cf/java.m4 b/dcapi/cf/java.m4
deleted file mode 100644
index 10f361c..0000000
--- a/dcapi/cf/java.m4
+++ /dev/null
@@ -1,96 +0,0 @@
-dnl
-dnl MON_PKG_JAVA
-dnl
-dnl Check for a Java SDK
-dnl
-AC_DEFUN([MON_PKG_JAVA], [
-	AC_ARG_ENABLE([java], AS_HELP_STRING([--enable-java],
-		[Enable Java support @<:@auto@:>@]),
-		[enable_java=$enableval],
-		[enable_java=auto])
-
-	AC_ARG_WITH([java_includes], AS_HELP_STRING([--with-java-includes=DIR],
-		[Where to find jni.h]),
-		[JAVA_INC=-I$withval],
-		[JAVA_INC=])
-
-	no_java=
-
-	# Check the value of --enable-java
-	if test "$enable_shared" = no; then
-		# The JNI module cannot be built if there is no shared lib support
-		AC_MSG_NOTICE([JNI support requires dynamic linking])
-		no_java=yes
-	fi
-	if test "$enable_java" = no; then
-		no_java=yes
-	fi
-
-	# Look for Java programs
-	if test -z "$no_java"; then
-		save_PATH="$PATH"
-		if test "$JAVA_HOME" != ""; then
-			PATH="$JAVA_HOME/bin:$PATH"
-			export PATH
-		fi
-
-		# The java command is not needed for the build but is needed
-		# to run the examples
-		AC_PATH_PROG([JAVA], [java], [none])
-
-		AC_PATH_PROG([JAVAC], [javac], [none])
-		AC_PATH_PROG([JAVAH], [javah], [none])
-		AC_PATH_PROG([JAR], [jar], [none])
-		AC_PATH_PROG([JAVADOC], [javadoc], [none])
-
-		PATH="$save_PATH"
-		export PATH
-
-		if test "$JAVAC" = none || test "$JAVAH" = none || \
-				test "$JAR" = none || test "$JAVADOC" = none; then
-			no_java=yes
-		fi
-	fi
-
-	# Look for <jni.h>
-	if test -z "$no_java"; then
-		if test -z "$JAVA_INC"; then
-			j=`echo $JAVAC | sed -e 's!/bin.*$!!'` #'
-			JAVA_INC="-I$j/include"
-		fi
-
-		# Check for the arch-specific subdirectory containing <jni_md.h>
-		JAVA_INC_ARCH=`echo $JAVA_INC | cut -c 3-`
-		for i in "$JAVA_INC_ARCH"/*; do
-			test -f "$i"/jni_md.h && JAVA_INC="$JAVA_INC -I$i"
-		done
-
-		save_CPPFLAGS="$CPPFLAGS"
-		CPPFLAGS="$CPPFLAGS $JAVA_INC"
-		AC_CHECK_HEADER([jni.h],, [no_java=yes])
-		CPPFLAGS="$save_CPPFLAGS"
-	fi
-
-	if test -z "$no_java"; then
-		AC_CACHE_CHECK([for javah version], [mon_cv_javah_version],
-			[mon_cv_javah_version=`$JAVAH -version | cut -d'"' -f2`])
-		AH_TEMPLATE([HAVE_JDK_15], [Define if using JDK 1.5.x])
-		case "$mon_cv_javah_version" in
-			1.[[56789]].*)
-				AC_DEFINE([HAVE_JDK_15])
-				;;
-		esac
-	fi
-
-	if test "$enable_java" = yes && test "$no_java" = yes; then
-		AC_MSG_ERROR([Java development tools were not found])
-	fi
-
-	if test -n "$no_java"; then
-		JAVA_INC=
-		AC_MSG_NOTICE([Java support is disabled])
-	fi
-
-	AC_SUBST([JAVA_INC])
-	AM_CONDITIONAL([HAVE_JAVA], [test -z "$no_java"])
-])
diff --git a/dcapi/common/Makefile.am b/dcapi/common/Makefile.am
deleted file mode 100644
index 0905d6b..0000000
--- a/dcapi/common/Makefile.am
+++ /dev/null
@@ -1,29 +0,0 @@
-noinst_LTLIBRARIES =
-
-AM_CPPFLAGS = -I$(top_srcdir)/include
-
-# Symbol file for the master side
-EXTRA_DIST = master.sym
-
-if BUILD_MASTER
-
-noinst_LTLIBRARIES += libdcapi-common-master.la
-libdcapi_common_master_la_CPPFLAGS = $(AM_CPPFLAGS) $(GLIB_CFLAGS) -DMASTER
-libdcapi_common_master_la_SOURCES = \
-		cfg-master.c \
-		logger.c \
-		util.c
-libdcapi_common_master_la_LIBADD = $(GLIB_LIBS)
-
-endif
-
-if BUILD_CLIENT
-
-noinst_LTLIBRARIES += libdcapi-common-client.la
-libdcapi_common_client_la_CPPFLAGS = $(AM_CPPFLAGS) -DCLIENT
-libdcapi_common_client_la_SOURCES = \
-		cfg-client.c \
-		logger.c \
-		util.c
-
-endif
diff --git a/dcapi/common/cfg-client.c b/dcapi/common/cfg-client.c
deleted file mode 100644
index f883347..0000000
--- a/dcapi/common/cfg-client.c
+++ /dev/null
@@ -1,189 +0,0 @@
-/*
- * cfg-client.c
- *
- * Simple config file parser for the client
- */
-
-#ifdef HAVE_CONFIG_H
-#include <config.h>
-#endif
-
-#include <string.h>
-#include <stdlib.h>
-#include <stdio.h>
-#include <errno.h>
-#include <ctype.h>
-
-#include <dc_internal.h>
-#include <dc_common.h>
-
-/********************************************************************
- * Data type definitions
- */
-
-struct pair
-{
-	char			*key;
-	char			*value;
-};
-
-
-/********************************************************************
- * Global variables
- */
-
-static struct pair *pairs;
-static int n_pairs;
-
-
-/********************************************************************
- * Implementation
- */
-
-static void cut_trailing_whitespace(char *p)
-{
-	char *end;
-
-	end = p + strlen(p) - 1;
-	while (end >= p && *end && isspace(*end))
-		*end-- = '\0';
-}
-
-int _DC_parseCfg(const char *cfgfile)
-{
-	char line[1024], *key, *value;
-	struct pair *tmp;
-	int linecnt, ret;
-	FILE *f;
-
-	/* Should not happen */
-	if (!cfgfile)
-		return DC_ERR_INTERNAL;
-
-	f = fopen(cfgfile, "r");
-	if (!f)
-	{
-		ret = errno;
-		DC_log(LOG_ERR, "Config file %s cannot be opened: %s",
-			cfgfile, strerror(ret));
-		errno = ret;
-		return DC_ERR_SYSTEM;
-	}
-
-	linecnt = 0;
-	while (fgets(line, 1024, f) != NULL)
-	{
-		linecnt++;
-
-		/* Cut leading white space */
-		for (key = line; isspace(*key); key++)
-			/* Nothing */;
-
-		/* Skip empty lines and comments */
-		if (!*key || *key == '\n' || *key == '#')
-			continue;
-
-		value = strchr(line, '=');
-		if (!value)
-		{
-			DC_log(LOG_ERR, "Syntax error in config file %s "
-				"line %d: '=' is missing", cfgfile, linecnt);
-			fclose(f);
-			return DC_ERR_CONFIG;
-		}
-
-		*value++ = '\0';
-		/* Cut leading white space */
-		while (isspace(*value))
-			value++;
-
-		cut_trailing_whitespace(key);
-		cut_trailing_whitespace(value);
-
-		tmp = realloc(pairs, (n_pairs + 1) * sizeof(*tmp));
-		if (!tmp)
-		{
-			DC_log(LOG_ERR, "Out of memory while parsing the "
-				"config file");
-			fclose(f);
-			errno = ENOMEM;
-			return DC_ERR_SYSTEM;
-		}
-
-		tmp[n_pairs].key = strdup(key);
-		tmp[n_pairs].value = strdup(value);
-		pairs = tmp;
-		n_pairs++;
-	}
-
-	fclose(f);
-	return 0;
-}
-
-char *DC_getCfgStr(const char *key)
-{
-	int i;
-
-	if (!key)
-		return NULL;
-
-	for (i = 0; i < n_pairs; i++)
-	{
-		if (pairs[i].key && !strcmp(pairs[i].key, key))
-			return strdup(pairs[i].value);
-	}
-	return NULL;
-}
-
-int DC_getCfgInt(const char *key, int defaultValue)
-{
-	long val;
-	char *p;
-	int i;
-
-	if (!key)
-		return defaultValue;
-
-	for (i = 0; i < n_pairs; i++)
-	{
-		if (pairs[i].key && !strcmp(pairs[i].key, key))
-			break;
-	}
-	if (i >= n_pairs)
-		return defaultValue;
-
-	val = strtol(pairs[i].value, &p, 10);
-	/* Check for unit suffixes */
-	if (p && *p)
-	{
-		long mult = (long) _DC_processSuffix(p);
-		if (mult == -1)
-		{
-			DC_log(LOG_WARNING, "Configuration value for key %s "
-				"is not a valid number, ignoring", key);
-			return defaultValue;
-		}
-		val *= mult;
-	}
-	return val;
-}
-
-int DC_getCfgBool(const char *key, int defaultValue)
-{
-	int i, retval;
-
-	if (!key)
-		return !!defaultValue;
-
-	for (i = 0; i < n_pairs; i++)
-	{
-		if (pairs[i].key && !strcmp(pairs[i].key, key))
-		{
-			retval = _DC_parseBoolean(pairs[i].value);
-			if (retval == -1)
-				retval = defaultValue;
-			return !!retval;
-		}
-	}
-	return !!defaultValue;
-}
diff --git a/dcapi/common/cfg-master.c b/dcapi/common/cfg-master.c
deleted file mode 100644
index 2ca7306..0000000
--- a/dcapi/common/cfg-master.c
+++ /dev/null
@@ -1,312 +0,0 @@
-/*
- * cfg-client.c
- *
- * Simple config file parser for the client
- */
-
-#ifdef HAVE_CONFIG_H
-#include <config.h>
-#endif
-
-#include <stdlib.h>
-#include <string.h>
-
-#include <dc.h>
-#include <dc_internal.h>
-
-#include <glib.h>
-
-/********************************************************************
- * Constants
- */
-
-/* Name of the group holding the master's configuration */
-#define MASTER_GROUP		"Master"
-
-
-/********************************************************************
- * Global variables
- */
-
-static GKeyFile *config;
-
-
-/********************************************************************
- * Implementation
- */
-
-int _DC_parseCfg(const char *cfgfile)
-{
-	GError *error = NULL;
-	int ret;
-
-	/* Should not happen */
-	if (!cfgfile)
-		return DC_ERR_INTERNAL;
-
-	config = g_key_file_new();
-	ret = g_key_file_load_from_file(config, cfgfile, G_KEY_FILE_NONE,
-		&error);
-	if (!ret)
-	{
-		DC_log(LOG_ERR, "Failed to load the config file %s: %s",
-			cfgfile, error->message);
-		g_error_free(error);
-		return DC_ERR_CONFIG;
-	}
-	return 0;
-}
-
-static char *getCfgStr(const char *group, const char *key)
-{
-	char *value, *tmp;
-
-	if (!config || !key)
-		return NULL;
-
-	value = g_key_file_get_value(config, group, key, NULL);
-	if (!value || g_mem_is_system_malloc())
-		return value;
-	tmp = strdup(value);
-	g_free(value);
-	return tmp;
-}
-
-static int getCfgInt(const char *group, const char *key, int defaultValue,
-	int *err)
-{
-	char *value, *p;
-	long retval;
-
-	if (!config || !key)
-		return defaultValue;
-
-	value = g_key_file_get_value(config, group, key, NULL);
-	if (!value)
-	{
-		*err = 1;
-		return defaultValue;
-	}
-
-	retval = strtol(value, &p, 10);
-	/* Check for unit suffixes */
-	if (p && *p)
-	{
-		long mult = _DC_processSuffix(p);
-		if (mult == -1)
-		{
-			DC_log(LOG_WARNING, "Configuration value for key %s "
-				"is not a valid number, ignoring", key);
-			g_free(value);
-			*err = 1;
-			return defaultValue;
-		}
-		retval *= mult;
-	}
-
-	g_free(value);
-	*err = 0;
-	return retval;
-}
-
-static double getCfgDouble(const char *group, const char *key,
-	double defaultValue, int *err)
-{
-	char *value, *p;
-	double retval;
-
-	if (!config || !key)
-		return defaultValue;
-
-	value = g_key_file_get_value(config, group, key, NULL);
-	if (!value)
-	{
-		*err = 1;
-		return defaultValue;
-	}
-
-	retval = strtod(value, &p);
-	if (p && *p)
-	{
-		long long mult = _DC_processSuffix(p);
-		if (mult == -1)
-		{
-			DC_log(LOG_WARNING, "Configuration value for key %s "
-				"is not a valid number, ignoring", key);
-			g_free(value);
-			*err = 1;
-			return defaultValue;
-		}
-		retval *= mult;
-	}
-
-	g_free(value);
-	*err = 0;
-	return retval;
-}
-
-static int getCfgBool(const char *group, const char *key, int defaultValue,
-	int *err)
-{
-	char *value;
-	int retval;
-
-	if (!config || !key)
-		return !!defaultValue;
-
-	value = g_key_file_get_value(config, group, key, NULL);
-	if (!value)
-	{
-		*err = 1;
-		return !!defaultValue;
-	}
-
-	retval = _DC_parseBoolean(value);
-	g_free(value);
-	if (retval == -1)
-	{
-		*err = 1;
-		return !!defaultValue;
-	}
-	*err = 0;
-	return retval;
-}
-
-char *DC_getCfgStr(const char *key)
-{
-	return getCfgStr(MASTER_GROUP, key);
-}
-
-int DC_getCfgInt(const char *key, int defaultValue)
-{
-	int err;
-
-	return getCfgInt(MASTER_GROUP, key, defaultValue, &err);
-}
-
-int DC_getCfgBool(const char *key, int defaultValue)
-{
-	int err;
-
-	return getCfgBool(MASTER_GROUP, key, defaultValue, &err);
-}
-
-char *DC_getClientCfgStr(const char *clientName, const char *key,
-	int fallbackGlobal)
-{
-	char *group, *val;
-
-	if (!clientName)
-		return NULL;
-
-	group = g_strdup_printf("Client-%s", clientName);
-	val = getCfgStr(group, key);
-	g_free(group);
-	if (!val && fallbackGlobal)
-		val = getCfgStr(MASTER_GROUP, key);
-	return val;
-}
-
-int DC_getClientCfgInt(const char *clientName, const char *key,
-	int defaultValue, int fallbackGlobal)
-{
-	int val, err;
-	char *group;
-
-	if (!clientName)
-		return defaultValue;
-
-	group = g_strdup_printf("Client-%s", clientName);
-	val = getCfgInt(group, key, defaultValue, &err);
-	g_free(group);
-	if (err && fallbackGlobal)
-		val = getCfgInt(MASTER_GROUP, key, defaultValue, &err);
-	return val;
-}
-
-double DC_getClientCfgDouble(const char *clientName, const char *key,
-	double defaultValue, int fallbackGlobal)
-{
-	char *group;
-	double val;
-	int err;
-
-	if (!clientName)
-		return defaultValue;
-
-	group = g_strdup_printf("Client-%s", clientName);
-	val = getCfgDouble(group, key, defaultValue, &err);
-	g_free(group);
-	if (err && fallbackGlobal)
-		val = getCfgDouble(MASTER_GROUP, key, defaultValue, &err);
-	return val;
-}
-
-int DC_getClientCfgBool(const char *clientName, const char *key,
-	int defaultValue, int fallbackGlobal)
-{
-	int val, err;
-	char *group;
-
-	if (!clientName)
-		return !!defaultValue;
-
-	group = g_strdup_printf("Client-%s", clientName);
-	val = getCfgBool(group, key, defaultValue, &err);
-	g_free(group);
-	if (err && fallbackGlobal)
-		val = getCfgBool(MASTER_GROUP, key, defaultValue, &err);
-	return val;
-}
-
-int _DC_initClientConfig(const char *clientName, FILE *f)
-{
-	char **keys, *group, *val;
-	gsize i, cnt;
-
-	if (!clientName)
-		return DC_ERR_BADPARAM;
-
-	group = g_strdup_printf("Client-%s", clientName);
-	keys = g_key_file_get_string_list(config, group, CFG_SENDKEYS, &cnt,
-		NULL);
-
-	/* Always set LogLevel */
-	val = g_key_file_get_value(config, group, CFG_LOGLEVEL, NULL);
-	if (!val)
-		val = g_key_file_get_value(config, MASTER_GROUP, CFG_LOGLEVEL,
-			NULL);
-	if (val)
-	{
-		fprintf(f, "%s = %s\n", CFG_LOGLEVEL, val);
-		g_free(val);
-	}
-
-	/* Copy the values of the requested keys */
-	for (i = 0; keys && i < cnt; i++)
-	{
-		char *p;
-
-		/* Strip white space from the key name */
-		p = keys[i] + strlen(keys[i]) - 1;
-		while (*p == ' ' || *p == '\t')
-			*p-- = '\0';
-		p = keys[i];
-		while (*p == ' ' || *p == '\t')
-			p++;
-
-		val = g_key_file_get_value(config, group, p, NULL);
-		if (!val)
-			val = g_key_file_get_value(config, MASTER_GROUP, p,
-				NULL);
-		if (val)
-		{
-			fprintf(f, "%s = %s\n", p, val);
-			g_free(val);
-		}
-	}
-
-	g_strfreev(keys);
-	g_free(group);
-	return 0;
-}
diff --git a/dcapi/common/logger.c b/dcapi/common/logger.c
deleted file mode 100644
index 17d54cb..0000000
--- a/dcapi/common/logger.c
+++ /dev/null
@@ -1,175 +0,0 @@
-#ifdef HAVE_CONFIG_H
-#include <config.h>
-#endif
-
-#include <string.h>
-#include <stdlib.h>
-#include <stdarg.h>
-#include <stdio.h>
-#include <errno.h>
-#include <time.h>
-
-#ifndef _WIN32
-#include <unistd.h>
-#include <sys/syslog.h>
-#endif
-
-#include <dc_common.h>
-#include <dc_internal.h>
-
-#ifdef CLIENT
-#include <dc_client.h>
-#else
-#include <glib.h>
-#endif
-
-/* Set the log level to -1 so the first call to DC_log() will call init_log() */
-static int loglevel = -1;
-static FILE *logfile;
-
-#ifndef CLIENT
-G_LOCK_DEFINE_STATIC(logfile);
-#endif
-
-/* Stupid Visual C compiler */
-#ifdef _MSC_VER
-#define INIT(x, y)		y
-#else
-#define INIT(x, y)		[x] = y
-#endif
-
-static const char *levels[] =
-{
-	INIT(LOG_DEBUG, "Debug"),
-	INIT(LOG_INFO, "Info"),
-	INIT(LOG_NOTICE, "Notice"),
-	INIT(LOG_WARNING, "Warning"),
-	INIT(LOG_ERR, "Error"),
-	INIT(LOG_CRIT, "Critical")
-};
-
-static void init_log(void)
-{
-	char *val;
-
-	/* Default level */
-	loglevel = LOG_NOTICE;
-
-	val = DC_getCfgStr(CFG_LOGLEVEL);
-	if (val)
-	{
-		if (val[0] >= '0' && val[0] <= '9')
-			loglevel = atoi(val);
-		else
-		{
-			unsigned i;
-
-			for (i = 0; i < sizeof(levels) / sizeof(levels[0]); i++)
-			{
-				if (levels[i] && !strcasecmp(levels[i], val))
-				{
-					loglevel = i;
-					break;
-				}
-			}
-
-			if (i >= sizeof(levels) / sizeof(levels[0]))
-				fprintf(stderr, "WARNING: Unknown log level "
-					"specified in the config file, "
-					"using 'Notice'\n");
-		}
-		free(val);
-	}
-
-	val = DC_getCfgStr(CFG_LOGFILE);
-	if (val)
-	{
-		char *tmp;
-
-#if MASTER
-		/* If the log file is not an absolute path, open it
-		 * inside the working directory */
-		if (val[0] != '/')
-		{
-			char *dir;
-
-			dir = DC_getCfgStr(CFG_WORKDIR);
-			if (dir)
-			{
-				tmp = malloc(strlen(dir) + 1 + strlen(val) + 1);
-				sprintf(tmp, "%s/%s", dir, val);
-				free(dir);
-				free(val);
-				val = tmp;
-			}
-		}
-#endif /* MASTER */
-#if CLIENT
-		/* Try to resolve the file name first as an output file, and
-		 * if that fails, as a temporary file. If both fail, use the
-		 * file name verbatim. */
-		tmp = DC_resolveFileName(DC_FILE_OUT, val);
-		if (!tmp)
-			tmp = DC_resolveFileName(DC_FILE_TMP, val);
-		if (tmp)
-		{
-			free(val);
-			val = tmp;
-		}
-#endif /* CLIENT */
-
-		logfile = fopen(val, "a");
-		if (!logfile)
-		{
-			fprintf(stderr, "Failed to open the log file %s: %s\n",
-				val, strerror(errno));
-			exit(1);
-		}
-		free(val);
-	}
-	else
-		logfile = stdout;
-}
-
-void DC_log(int level, const char *fmt, ...)
-{
-	va_list ap;
-
-	va_start(ap, fmt);
-	DC_vlog(level, fmt, ap);
-	va_end(ap);
-}
-
-void DC_vlog(int level, const char *fmt, va_list ap)
-{
-	const char *levstr;
-	char timebuf[32];
-	struct tm *tm;
-	time_t now;
-
-	if (loglevel < 0)
-		init_log();
-	if ((LOG_DEBUG > LOG_ERR && level > loglevel) ||
-			(LOG_DEBUG < LOG_ERR && level < loglevel))
-		return;
-
-	if (level >= 0 && level < (int)(sizeof(levels) / sizeof(levels[0])) && levels[level])
-		levstr = levels[level];
-	else
-		levstr = "Unknown";
-
-	now = time(NULL);
-	tm = localtime(&now);
-	strftime(timebuf, sizeof(timebuf), "%Y-%m-%d %H:%M:%S", tm);
-
-#ifndef CLIENT
-	G_LOCK(logfile);
-#endif
-	fprintf(logfile, "%s [%s] ", timebuf, levstr);
-	vfprintf(logfile, fmt, ap);
-	fprintf(logfile, "\n");
-	fflush(logfile);
-#ifndef CLIENT
-	G_UNLOCK(logfile);
-#endif
-}
diff --git a/dcapi/common/master.sym b/dcapi/common/master.sym
deleted file mode 100644
index 09791be..0000000
--- a/dcapi/common/master.sym
+++ /dev/null
@@ -1,42 +0,0 @@
-DC_getMaxMessageSize
-DC_getMaxSubresults
-DC_getGridCapabilities
-DC_log
-DC_vlog
-DC_getCfgStr
-DC_getCfgInt
-DC_getCfgBool
-DC_initMaster
-DC_setMasterCb
-DC_setResultCb
-DC_setSubresultCb
-DC_setMessageCb
-DC_getWUNumber
-DC_getClientCfgStr
-DC_getClientCfgInt
-DC_getClientCfgDouble
-DC_getClientCfgBool
-DC_processMasterEvents
-DC_waitMasterEvent
-DC_waitWUEvent
-DC_destroyMasterEvent
-DC_createWU
-DC_addWUInput
-DC_addWUOutput
-DC_setWUPriority
-DC_serializeWU
-DC_deserializeWU
-DC_getWUState
-DC_submitWU
-DC_getWUId
-DC_getWUTag
-DC_cancelWU
-DC_suspendWU
-DC_resumeWU
-DC_destroyWU
-DC_sendWUMessage
-DC_getResultCapabilities
-DC_getResultWU
-DC_getResultExit
-DC_getResultOutput
-DC_getResultCPUTime
diff --git a/dcapi/common/util.c b/dcapi/common/util.c
deleted file mode 100644
index c7ff481..0000000
--- a/dcapi/common/util.c
+++ /dev/null
@@ -1,217 +0,0 @@
-#ifdef HAVE_CONFIG_H
-#include <config.h>
-#endif
-
-#include <sys/types.h>
-#include <sys/stat.h>
-#include <string.h>
-#include <stdlib.h>
-#include <errno.h>
-#include <fcntl.h>
-
-#ifdef _WIN32
-#include <windows.h>
-#else
-#include <unistd.h>
-#endif
-
-#include <dc_internal.h>
-#include <dc_common.h>
-
-/********************************************************************
- * Constants
- */
-
-/* Buffer size used when copying a file */
-#define COPY_BUFSIZE		65536
-
-
-/********************************************************************
- * Functions
- */
-
-#ifdef _WIN32
-int _DC_copyFile(const char *src, const char *dst)
-{
-	if (CopyFile(src, dst, FALSE))
-		return 0;
-	return DC_ERR_SYSTEM;
-}
-#else
-int _DC_copyFile(const char *src, const char *dst)
-{
-	struct stat s;
-	int sfd, dfd;
-	ssize_t ret;
-	char *buf;
-
-	buf = (char *)malloc(COPY_BUFSIZE);
-	if (!buf)
-	{
-		DC_log(LOG_ERR, "_DC_copyFile: Out of memory");
-		return DC_ERR_SYSTEM;
-	}
-
-	sfd = open(src, O_RDONLY);
-	if (sfd == -1)
-	{
-		DC_log(LOG_ERR, "_DC_copyFile: failed to open source file %s: %s",
-			src, strerror(errno));
-		free(buf);
-		return DC_ERR_SYSTEM;
-	}
-
-	fstat(sfd, &s);
-	dfd = open(dst, O_WRONLY | O_CREAT | O_TRUNC, s.st_mode);
-	if (dfd == -1)
-	{
-		DC_log(LOG_ERR, "_DC_copyFile: failed to create destination file %s: %s",
-			dst, strerror(errno));
-		free(buf);
-		close(sfd);
-		return DC_ERR_SYSTEM;
-	}
-
-	while ((ret = read(sfd, buf, COPY_BUFSIZE)) > 0)
-	{
-		char *ptr = buf;
-		while (ret)
-		{
-			ssize_t ret2 = write(dfd, ptr, ret);
-			if (ret2 < 0)
-				goto error;
-			ret -= ret2;
-			ptr += ret2;
-		}
-	}
-
-	if (ret < 0)
-		goto error;
-
-	free(buf);
-	close(sfd);
-	if (close(dfd))
-	{
-		DC_log(LOG_ERR, "_DC_copyFile: I/O error: %s", strerror(errno));
-		unlink(dst);
-		return DC_ERR_SYSTEM;
-	}
-	return 0;
-
-error:
-	DC_log(LOG_ERR, "_DC_copyFile: I/O error: %s", strerror(errno));
-	free(buf);
-	close(sfd);
-	close(dfd);
-	unlink(dst);
-	return DC_ERR_SYSTEM;
-}
-#endif /* _WIN32 */
-
-long long _DC_processSuffix(const char *suffix)
-{
-	while (*suffix == ' ' || *suffix == '\t')
-		suffix++;
-	if (!strcasecmp(suffix, "kb") || !strcasecmp(suffix, "kib"))
-		return 1ll << 10;
-	else if (!strcasecmp(suffix, "mb") || !strcasecmp(suffix, "mib"))
-		return 1ll << 20;
-	else if (!strcasecmp(suffix, "gb") || !strcasecmp(suffix, "gib"))
-		return 1ll << 30;
-	else if (!strcasecmp(suffix, "min"))
-		return 60ll;
-	else if (!strcasecmp(suffix, "h") || !strcasecmp(suffix, "hour"))
-		return 60ll * 60;
-	else if (!strcasecmp(suffix, "day"))
-		return 24ll * 60 * 60;
-	return -1;
-}
-
-int _DC_parseBoolean(const char *value)
-{
-	static const char *truevals[] = {"true", "yes", "on"};
-	static const char *falsevals[] = {"false", "no", "off"};
-	unsigned i;
-
-	for (i = 0; i < sizeof(truevals) / sizeof(truevals[0]); i++)
-		if (!strcasecmp(value, truevals[i]))
-			return 1;
-	for (i = 0; i < sizeof(falsevals) / sizeof(falsevals[0]); i++)
-		if (!strcasecmp(value, falsevals[i]))
-			return 0;
-	return -1;
-}
-
-DC_PhysicalFile *_DC_createPhysicalFile(const char *label,
-	const char *path)
-{
-	DC_PhysicalFile *file;
-
-	file = malloc(sizeof(*file));
-	if (!file)
-		return NULL;
-
-	file->label = strdup(label);
-	file->path = strdup(path);
-	file->physicalfilename = NULL;
-	file->physicalfilehash = NULL;
-    file->persistentonclient = 0;
-
-	if (!file->label || !file->path)
-	{
-		_DC_destroyPhysicalFile(file);
-		return NULL;
-	}
-	file->mode = DC_FILE_REGULAR;
-
-	return file;
-}
-
-DC_RemoteFile *_DC_createRemoteFile(const char *label,
-	const char *url, const char *md5, const size_t size)
-{
-	DC_RemoteFile *file;
-
-	file = malloc(sizeof(*file));
-	if (!file)
-		return NULL;
-
-	file->label = strdup(label);
-	file->url = strdup(url);
-	file->remotefilehash = strdup(md5);
-	file->remotefilesize = size;
-    file->persistentonclient = 0;
-
-	if (!file->label || !file->url || !file->remotefilehash)
-	{
-		_DC_destroyRemoteFile(file);
-		return NULL;
-	}
-
-	return file;
-}
-
-void _DC_destroyPhysicalFile(DC_PhysicalFile *file)
-{
-	if (!file)
-		return;
-
-	free(file->label);
-	free(file->path);
-	if (file->physicalfilename)
-		free(file->physicalfilename);
-	if (file->physicalfilehash)
-		free(file->physicalfilehash);
-	free(file);
-}
-
-void _DC_destroyRemoteFile(DC_RemoteFile *file)
-{
-	if (!file)
-		return;
-
-	free(file->label);
-	free(file->url);
-	free(file->remotefilehash);
-	free(file);
-}
diff --git a/dcapi/condor/Makefile.am b/dcapi/condor/Makefile.am
deleted file mode 100644
index 875a1f5..0000000
--- a/dcapi/condor/Makefile.am
+++ /dev/null
@@ -1,60 +0,0 @@
-lib_LTLIBRARIES =
-
-if BUILD_MASTER
-lib_LTLIBRARIES += libdcapi-condor.la
-endif
-
-if BUILD_CLIENT
-lib_LTLIBRARIES += libdcapi-client-condor.la
-endif
-
-pkgconfigdir = ${libdir}/pkgconfig
-pkgconfig_DATA = dcapi-condor-client.pc dcapi-condor-master.pc
-
-AM_CPPFLAGS	= -I$(top_srcdir)/include $(GLIB_CFLAGS) $(CONDOR_CPPFLAGS)
-AM_LDFLAGS	= $(GLIB_LIBS) $(CONDOR_LDFLAGS)
-
-noinst_HEADERS	= condor_common.h \
-		  condor_defs.h \
-		  condor_master.h \
-		  condor_wu.h \
-		  condor_log.h \
-		  condor_utils.h \
-		  condor_result.h \
-		  condor_slave.h \
-		  condor_event.h
-
-libdcapi_condor_la_SOURCES = condor_master.c \
-			  condor_common.c \
-			  condor_wu.c \
-			  condor_managewu.c \
-			  condor_log.cc \
-			  condor_utils.c \
-			  condor_result.c \
-			  condor_event.c
-
-libdcapi_condor_la_LIBADD = ../common/libdcapi-common-master.la \
-			 $(GLIB_LIBS) \
-			 -lcondorapi
-
-libdcapi_client_condor_la_SOURCES = condor_slave.c \
-				 condor_common.c \
-				 condor_utils.c
-
-libdcapi_client_condor_la_LIBADD = ../common/libdcapi-common-client.la
-libdcapi_client_condor_la_LDFLAGS = -static
-
-#appdir		= $(libdir)/dcapi/condor
-#app_PROGRAMS	= tss tm
-
-#tss_SOURCES	= tss.c tc.c
-#tss_LDADD	= ../common/libdcapi-common-client.la libdcapi-client-condor.la
-
-#tm_SOURCES 	= tm.c tc.c
-#tm_LDADD	= ../common/libdcapi-common-master.la libdcapi-condor.la -L. -ldl -luuid -lstdc++
-
-dd: all
-	ssh root at emma 'make -C /home/staff/drdani/prj/szdg/dcapi/trunk/condor install'
-	$(MAKE) -C ../../../apps/uppercase-demo/trunk clean all
-	cp ../../../apps/uppercase-demo/trunk/src/uppercase-demo-client uppercase-demo
-	cp ../../../apps/uppercase-demo/trunk/src/uppercase-demo-master .
diff --git a/dcapi/condor/condor_common.c b/dcapi/condor/condor_common.c
deleted file mode 100644
index 1c09c2c..0000000
--- a/dcapi/condor/condor_common.c
+++ /dev/null
@@ -1,111 +0,0 @@
-/*
- * condor/condor_common.c
- *
- * DC-API functions common for master and slave side
- *
- * (c) Daniel Drotos, 2006
- */
-
-/*#include <glib.h>*/
-
-/*
-#include <stdio.h>
-#include <stdlib.h>
-#include <unistd.h>
-#include <sys/types.h>
-#include <sys/stat.h>
-#include <fcntl.h>
-#include <string.h>
-#include <errno.h>
-*/
-
-#include "dc_common.h"
-
-#include "condor_common.h"
-
-
-struct _DC_s_param _DC_params[cfg_nuof];
-
-
-void
-_DC_init_common(void)
-{
-	int i;
-	
-	for (i= 0; i < cfg_nuof; i++)
-	{
-		_DC_params[i].name= 0;
-		_DC_params[i].def= 0;
-		_DC_params[i].lvalue= 0;
-		_DC_params[i].gvalue= 0;
-	}
-	_DC_params[cfg_client_message_box].name= "ClientMessageBox";
-	_DC_params[cfg_client_message_box].def= "_dcapi_client_messages";
-
-	_DC_params[cfg_master_message_box].name= "MasterMessageBox";
-	_DC_params[cfg_master_message_box].def= "_dcapi_master_messages";
-
-	_DC_params[cfg_subresults_box].name= "SubresultBox";
-	_DC_params[cfg_subresults_box].def= "_dcapi_client_subresults";
-
-	_DC_params[cfg_management_box].name= "SystemMessageBox";
-	_DC_params[cfg_management_box].def= "_dcapi_system_messages";
-
-	_DC_params[cfg_architectures].name= "Architectures";
-	_DC_params[cfg_architectures].def= "Client_%s_%s";/* client_name, architecture */
-
-	_DC_params[cfg_submit_file].name= "SubmitFile";
-	_DC_params[cfg_submit_file].def= "_dcapi_condor_submit.txt";
-
-	_DC_params[cfg_executable].name= "Executable";
-	_DC_params[cfg_executable].def= 0/*NULL*/;
-	
-	_DC_params[cfg_leave_files].name= "LeaveFiles";
-	_DC_params[cfg_leave_files].def= "0";
-
-	_DC_params[cfg_condor_log].name= "CondorLog";
-	_DC_params[cfg_condor_log].def= "_dcapi_internal_log.txt";
-
-	_DC_params[cfg_checkpoint_file].name= "CheckpointFile";
-	_DC_params[cfg_checkpoint_file].def= "_dcapi_checkpoint";
-
-	_DC_params[cfg_output_cache].name= "SavedOutputs";
-	_DC_params[cfg_output_cache].def= "_dcapi_saved_output";
-
-	_DC_params[cfg_condor_submit_template].name= "CondorSubmitTemplate";
-	_DC_params[cfg_condor_submit_template].def= 0;
-}
-
-
-/* Determines the maximum allowed message length. */
-int DC_getMaxMessageSize(void)
-{
-	return(16384);
-}
-
-
-/* Determines the maximum number of sub-results. */
-int DC_getMaxSubresults(void)
-{
-	return(100);
-}
-
-
-/* Determines the basic capabilities of the underlying grid infrastructure. */
-unsigned DC_getGridCapabilities(void)
-{
-	int cap;
-
-	cap= DC_GC_STDOUT | DC_GC_STDERR;
-	cap|= DC_GC_MESSAGING | DC_GC_LOG | DC_GC_SUBRESULT;
-	cap|= DC_GC_EXITCODE;
-
-	return(cap);
-}
-
-
-/* End of condor/condor_common.c */
-
-/* Local variables: */
-/* c-file-style: "linux" */
-/* End: */
diff --git a/dcapi/condor/condor_common.h b/dcapi/condor/condor_common.h
deleted file mode 100644
index 79479e0..0000000
--- a/dcapi/condor/condor_common.h
+++ /dev/null
@@ -1,73 +0,0 @@
-/*
- * condor/condor_common.h
- *
- * DC-API functions common for master and slave side
- *
- * (c) Daniel Drotos, 2006
- */
-
-
-#ifndef _DC_API_CONDOR_COMMON_H_
-#define _DC_API_CONDOR_COMMON_H_
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-
-#define CLIENT_CONFIG_NAME	"_dcapi_configfile.txt"
-
-
-enum _DC_e_param {
-	cfg_client_message_box= 0,
-	cfg_master_message_box,
-	cfg_subresults_box,
-	cfg_management_box,
-	cfg_architectures,
-	cfg_submit_file,
-	cfg_executable,
-	cfg_leave_files,
-	cfg_condor_log,
-	cfg_checkpoint_file,
-	cfg_output_cache,
-	cfg_condor_submit_template,
-	cfg_nuof
-};
-
-struct _DC_s_param {
-	char *name;
-	char *def;
-	char *lvalue;
-	char *gvalue;
-};
-
-
-extern struct _DC_s_param _DC_params[cfg_nuof];
-
-extern void _DC_init_common(void);
-
-
-#define _DCAPI_MSG_MESSAGE	"message"
-#define _DCAPI_MSG_LOGICAL	"logical_name"
-#define _DCAPI_MSG_COMMAND	"command"
-#define _DCAPI_MSG_ACK		"acknowledge"
-
-#define _DCAPI_CMD_SUSPEND	"suspend"
-#define _DCAPI_ACK_SUSPEND	"suspending"
-
-#define _DCAPI_CMD_RESUME	"resume"
-
-#define _DCAPI_SIG_SERIALIZED	"serialized"
-
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif
-
-/* End of condor/condor_common.h */
-
-/* Local variables: */
-/* c-file-style: "linux" */
-/* End: */
diff --git a/dcapi/condor/condor_defs.h b/dcapi/condor/condor_defs.h
deleted file mode 100644
index e981437..0000000
--- a/dcapi/condor/condor_defs.h
+++ /dev/null
@@ -1,126 +0,0 @@
-/*
- * condor/condor_defs.h
- *
- * DC-API type definitions for master side
- *
- * (c) Daniel Drotos, 2006
- */
-
-
-#ifndef __DC_API_CONDOR_DEFS_H_
-#define __DC_API_CONDOR_DEFS_H_
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-#include <time.h>
-#include <sys/time.h>
-#include <uuid/uuid.h>
-#include "glib.h"
-
-#include "dc.h"
-#include "dc_internal.h"
-
-
-extern char project_uuid_str[37];
-
-struct _DC_condor_event
-{
-	int event;
-	int cluster;
-	int proc;
-	int subproc;
-	time_t time;
-	gboolean reported;
-	union
-	{
-		struct
-		{
-			gboolean normal;
-			int exit_code;
-		} exit_info;
-		struct
-		{
-			char *reason;
-		} abort_info;
-		struct
-		{
-			char *host;
-		} exec_info;
-	};
-};
-
-struct _DC_wu_data
-{
-	char *name;		// generated by Create
-	char *client_name;	// reference to the config file group
-	char *tag;		// Parameter from the app
-	int argc;
-	int subresults;
-	/*uuid_t uuid;*/
-	char *uuid_str;
-	char *workdir;
-	DC_WUState state;
-};
-
-struct _DC_Workunit
-{
-	int magic;
-	struct _DC_wu_data data;
-	char **argv;
-    
-	gboolean asked_to_suspend;
-
-	/*char *condor_id;*/
-	GArray *condor_events;
-     
-	GList *input_files;
-	GList *output_files;
-	int chk;
-};
-
-struct _DC_Result
-{
-	DC_Workunit *wu;
-};
-
-typedef enum
-{
-	FILE_IN,
-	FILE_OUT,
-	FILE_CKPT,
-	FILE_DCAPI
-} WorkdirFile;
-
-
-typedef enum
-{
-	st_name= 0,
-	st_workdir,
-	st_tag,
-	st_client_name,
-	st_argc,
-	st_argv,
-	st_state,
-	st_state_name,
-	st_nuof_reported,
-	st_reported,
-	st_uuid_str
-} _DC_serialized_token;
-
-
-/*#define DC_LABEL_INTLOG		"internal_log.txt"*/
-
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif
-
-/* End of condor/condor_defs.h */
-
-/* Local variables: */
-/* c-file-style: "linux" */
-/* End: */
diff --git a/dcapi/condor/condor_event.c b/dcapi/condor/condor_event.c
deleted file mode 100644
index cdec87b..0000000
--- a/dcapi/condor/condor_event.c
+++ /dev/null
@@ -1,85 +0,0 @@
-/*
- * condor/condor_event.c
- *
- * DC-API functions to handle DC_MasterEvent data type
- *
- * (c) Daniel Drotos, 2006
- */
-
-
-#include <glib.h>
-
-#include "dc.h"
-
-#include "condor_result.h"
-#include "condor_event.h"
-
-
-DC_MasterEvent *
-_DC_event_create(DC_Workunit *wu,
-		 DC_Result *result,
-		 DC_PhysicalFile *subresult,
-		 char *message)
-{
-	DC_MasterEvent *e;
-
-	if ((e= g_new0(DC_MasterEvent, 1)) == NULL)
-		return(NULL);
-	e->wu= wu;
-	if (result)
-	{
-		e->type= DC_MASTER_RESULT;
-		e->result= result;
-	}
-	else if (subresult)
-	{
-		e->type= DC_MASTER_SUBRESULT;
-		e->subresult= subresult;
-	}
-	else if (message)
-	{
-		e->type= DC_MASTER_MESSAGE;
-		e->message= g_strdup(message);
-	}
-	else
-	{
-		DC_log(LOG_ERR, "Wrong invokation of _DC_event_create("
-		       "%p,%p,%p,%p)", wu, result, subresult, message);
-		g_free(e);
-		return(NULL);
-	}
-	return(e);
-}
-
-
-void
-_DC_event_destroy(DC_MasterEvent *event)
-{
-	if (!event)
-		return;
-	switch (event->type)
-	{
-	case DC_MASTER_RESULT:
-		if (event->result)
-			_DC_result_destroy(event->result);
-		break;
-	case DC_MASTER_SUBRESULT:
-		if (event->subresult)
-			_DC_destroyPhysicalFile(event->subresult);
-		break;
-	case DC_MASTER_MESSAGE:
-		if (event->message)
-			g_free(event->message);
-		break;
-	default:
-		break;
-	}
-	g_free(event);
-}
-
-
-/* End of condor/condor_event.h */
-
-/* Local variables: */
-/* c-file-style: "linux" */
-/* End: */
diff --git a/dcapi/condor/condor_event.h b/dcapi/condor/condor_event.h
deleted file mode 100644
index a9257ec..0000000
--- a/dcapi/condor/condor_event.h
+++ /dev/null
@@ -1,37 +0,0 @@
-/*
- * condor/condor_event.h
- *
- * DC-API functions to handle DC_MasterEvent data type
- *
- * (c) Daniel Drotos, 2006
- */
-
-
-#ifndef _DC_API_CONDOR_EVENT_H_
-#define _DC_API_CONDOR_EVENT_H_
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-#include "dc.h"
-
-
-extern DC_MasterEvent *_DC_event_create(DC_Workunit *wu,
-					DC_Result *result,
-					DC_PhysicalFile *subresult,
-					char *message);
-extern void _DC_event_destroy(DC_MasterEvent *event);
-
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif
-
-/* End of condor/condor_event.h */
-
-/* Local variables: */
-/* c-file-style: "linux" */
-/* End: */
diff --git a/dcapi/condor/condor_log.cc b/dcapi/condor/condor_log.cc
deleted file mode 100644
index 48d864c..0000000
--- a/dcapi/condor/condor_log.cc
+++ /dev/null
@@ -1,279 +0,0 @@
-/*
- * condor/condor_log.cc
- *
- * DC-API utils to read and process condor "user log" file
- *
- * (c) Daniel Drotos, 2006
- */
-
-
-#include <stdio.h>
-#include <time.h>
-#include <sys/time.h>
-#include <glib.h>
-#include <string.h>
-#include <unistd.h>
-#include <stdlib.h>
-
-#include "read_user_log.h"
-
-#include "dc.h"
-#include "dc_common.h"
-
-#include "condor_log.h"
-
-#include "condor_defs.h"
-#include "condor_event.h"
-#include "condor_result.h"
-#include "condor_wu.h"
-#include "condor_utils.h"
-
-
-void
-_DC_wu_update_condor_events(DC_Workunit *wu)
-{
-	ReadUserLog log;
-	GString *fn_org, *fn_tmp;
-	char t[100];
-	int res;
-	unsigned int i;
-
-	if (!wu) {
-        DC_log(LOG_DEBUG, "Invalid work unit passed.");
-		return;	    
-	}
-	
-	fn_org= g_string_new(wu->data.workdir);
-	fn_org= g_string_append(fn_org, "/");
-	fn_org= g_string_append(fn_org, _DC_wu_cfg(wu, cfg_condor_log));
-	strcpy(t, "/tmp/condor_dc_api_XXXXXX");
-	res= mkstemp(t);
-	fn_tmp= g_string_new(t);
-	close(res);
-	_DC_copyFile(fn_org->str, fn_tmp->str);
-	res= log.initialize(fn_tmp->str);
-	if (res != 1)
-	{
-		DC_log(LOG_ERR, "Condor user log file reader "
-		       "initialization failed for %s", fn_tmp->str);
-		unlink(fn_tmp->str);
-		g_string_free(fn_org, TRUE);
-		g_string_free(fn_tmp, TRUE);
-		return;
-	}
-
-	i= 1;
-	ULogEvent *event;
-	ULogEventOutcome result;
-	while ((result = log.readEvent(event)) != ULOG_NO_EVENT)
-	{
-        switch (result) 
-        {
-	        case ULOG_RD_ERROR:
-                DC_log(LOG_ERR, "read error in the log");
-	            break;
-	        case ULOG_UNK_ERROR:
-                DC_log(LOG_ERR, "unknown error in the log");
-                break;	        
-	        case ULOG_OK: 
-        		if (wu->condor_events->len < i)
-        		{
-        			struct _DC_condor_event e;
-        			e.event= event->eventNumber;
-        			e.cluster= event->cluster;
-        			e.proc= event->proc;
-        			e.subproc= event->subproc;
-        			e.time= mktime(&(event->eventTime));
-        			e.reported= FALSE;
-        			if (e.event == ULOG_JOB_TERMINATED)
-        			{
-        				class TerminatedEvent *te=
-        					dynamic_cast<class TerminatedEvent *>
-        					(event);
-        				if (te)
-        				{
-        					e.exit_info.normal= te->normal;
-        					e.exit_info.exit_code= te->returnValue;
-        				}
-        			}
-        			if (e.event == ULOG_JOB_ABORTED)
-        			{
-        				class JobAbortedEvent *ae=
-        					dynamic_cast<class JobAbortedEvent *>
-        					(event);
-        				if (ae)
-        				{
-        					e.abort_info.reason=
-        						g_strdup(ae->getReason());
-        				}
-        			}
-        			if (e.event == ULOG_EXECUTE)
-        			{
-        				class ExecuteEvent *ae=
-        					dynamic_cast<class ExecuteEvent *>
-        					(event);
-        				if (ae)
-        				{
-        					e.exec_info.host=
-        						g_strdup(ae->getExecuteHost());
-        				}
-        			}
-        			g_array_append_val(wu->condor_events, e);
-        			DC_log(LOG_DEBUG, "Condor event %d %s of %p-\"%s\"",
-        			       event->eventNumber,
-        			       ULogEventNumberNames[event->eventNumber],
-        			       wu, wu->data.name);
-        		} 
-        		i++;
-                delete event;
-                break;
-	        default:
-	            DC_log(LOG_ERR, "should never get here.");
-                break;
-	    }
-	} 
-	unlink(fn_tmp->str);
-	g_string_free(fn_org, TRUE);
-	g_string_free(fn_tmp, TRUE);
-	return;
-}
-
-
-DC_MasterEvent *
-_DC_wu_condor2api_event(DC_Workunit *wu)
-{
-	unsigned int i;
-
-	if (!_DC_wu_check(wu))
-		return(NULL);
-	for (i= 0; i < wu->condor_events->len; i++)
-	{
-		struct _DC_condor_event *ce;
-		ce= &g_array_index(wu->condor_events,
-				   struct _DC_condor_event,
-				   i);
-		if (ce->reported)
-			continue;
-		ce->reported= TRUE;
-		if (ce->event == ULOG_JOB_TERMINATED)
-		{
-			DC_log(LOG_DEBUG, "Job terminated, "
-			       "asked to susp=%d",
-			       wu->asked_to_suspend);
-			GString *s;
-			s= g_string_new("");
-			g_string_printf(s, "%s/%s", wu->data.workdir,
-					_DC_wu_cfg(wu, cfg_management_box));
-			char *message;
-			if ((message= _DC_read_message(s->str,
-						       (char *)_DCAPI_MSG_ACK,
-						       FALSE)))
-			{
-				DC_log(LOG_DEBUG, "Acknowledge exists: %s",
-				       message);
-				if (strcmp(message, _DCAPI_ACK_SUSPEND) == 0)
-				{
-					DC_log(LOG_DEBUG, "Suspend "
-					       "acknowledged");
-					_DC_read_message(s->str,
-							 (char *)_DCAPI_MSG_ACK,
-							 TRUE);
-					wu->asked_to_suspend= TRUE;
-				}
-			}
-			g_string_free(s, TRUE);
-
-			if (wu->asked_to_suspend)
-			{
-				_DC_wu_set_state(wu, DC_WU_SUSPENDED);
-				wu->asked_to_suspend= FALSE;
-			}
-			else
-			{
-				DC_MasterEvent *e;
-				e= _DC_event_create(wu, _DC_result_create(wu),
-						    NULL, NULL);
-				DC_log(LOG_DEBUG, "Result event created: "
-				       "%p for wu (%p-\"%s\")",
-				       e, wu, wu->data.name);
-				DC_log(LOG_DEBUG, "Result of the event: %p",
-				       e->result);
-				_DC_wu_set_state(wu, DC_WU_FINISHED);
-				return(e);
-			}
-		}
-		if (ce->event == ULOG_EXECUTE)
-		{
-			/* Fix #1105 */
-			/*_DC_wu_set_state(wu, DC_WU_RUNNING);*/
-		}
-
-	}
-	return(NULL);
-}
-
-
-int
-_DC_wu_exit_code(DC_Workunit *wu, int *res)
-{
-	unsigned int i;
-
-	if (!_DC_wu_check(wu))
-		return(DC_ERR_UNKNOWN_WU);
-	if (!res)
-		return(DC_OK);
-	for (i= 0; i < wu->condor_events->len; i++)
-	{
-		struct _DC_condor_event *ce;
-		ce= &g_array_index(wu->condor_events,
-				   struct _DC_condor_event,
-				   i);
-		if (ce->event == ULOG_JOB_TERMINATED)
-		{
-			*res= ce->exit_info.exit_code;
-		}
-	}
-	return(DC_OK);
-}
-
-
-/* Returns the CPU time used for computing the result, in seconds. */
-
-double
-DC_getResultCPUTime(const DC_Result *result)
-{
-	DC_Workunit *wu;
-	unsigned int i;
-	time_t start= (time_t)-1, end= (time_t)-1;
-
-	if (result == NULL)
-		return(0.0);
-	wu= result->wu;
-	if (wu == NULL)
-		return(0.0);
-
-	for (i= 0; i < wu->condor_events->len; i++)
-	{
-		struct _DC_condor_event *ce;
-		ce= &g_array_index(wu->condor_events,
-				   struct _DC_condor_event,
-				   i);
-		if (ce->event == ULOG_EXECUTE)
-			start= ce->time;
-		if (ce->event == ULOG_JOB_TERMINATED ||
-		    ce->event == ULOG_JOB_ABORTED)
-			end= ce->time;
-	}
-	if (start == (time_t)-1 ||
-	    end == (time_t)-1)
-		return(0.0);
-	
-	return difftime(end, start);
-}
-
-
-/* End of condor_log.cc */
-
-/* Local variables: */
-/* c-file-style: "linux" */
-/* End: */
diff --git a/dcapi/condor/condor_log.h b/dcapi/condor/condor_log.h
deleted file mode 100644
index 4880dcc..0000000
--- a/dcapi/condor/condor_log.h
+++ /dev/null
@@ -1,35 +0,0 @@
-/*
- * condor/condor_log.h
- *
- * DC-API utils to read and process condor "user log" file
- *
- * (c) Daniel Drotos, 2006
- */
-
-
-#ifndef _DC_API_CONDOR_LOG_H_
-#define _DC_API_CONDOR_LOG_H_
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-#include "dc.h"
-
-
-extern void _DC_wu_update_condor_events(DC_Workunit *wu);
-extern DC_MasterEvent *_DC_wu_condor2api_event(DC_Workunit *wu);
-extern int _DC_wu_exit_code(DC_Workunit *wu, int *res);
-
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif
-
-/* End of condor/condor_log.h */
-
-/* Local variables: */
-/* c-file-style: "linux" */
-/* End: */
diff --git a/dcapi/condor/condor_managewu.c b/dcapi/condor/condor_managewu.c
deleted file mode 100644
index 522c3ae..0000000
--- a/dcapi/condor/condor_managewu.c
+++ /dev/null
@@ -1,240 +0,0 @@
-/*
- * condor/condor_managewu.c
- *
- * DC-API wu management functions
- *
- * (c) Daniel Drotos, 2006
- */
-
-
-#include <stdio.h>
-#include <stdlib.h>
-#include <unistd.h>
-
-#include <glib.h>
-
-#include "dc.h"
-
-#include "condor_log.h"
-#include "condor_wu.h"
-#include "condor_utils.h"
-
-
-/*************************************************************** Manage WUs */
-
-static int
-_DC_start_condor_job(DC_Workunit *wu)
-{
-	int ret;
-	GString *cmd;
-	gchar *act, *act2;
-
-	cmd= g_string_new("condor_submit");
-	cmd= g_string_append(cmd, " ");
-	cmd= g_string_append(cmd, _DC_wu_cfg(wu, cfg_submit_file));
-	act= getcwd(NULL, 0);
-	chdir(wu->data.workdir);
-	act2= getcwd(NULL, 0);
-	DC_log(LOG_DEBUG, "Calling \"%s\" in %s...",
-	       cmd->str, act2);
-	ret= system(cmd->str);
-	DC_log(LOG_DEBUG, "Returned %d", ret);
-	chdir(act);
-	g_free(act);
-	g_free(act2);
-	g_string_free(cmd, TRUE);
-
-	return ret;
-}
-
-/* Submits a work unit. */
-int
-DC_submitWU(DC_Workunit *wu)
-{
-	int ret;
-	/*GString *fn;*/
-	char *id;
-    int tries;
-    int sleeptime;
-    int maxtries;
-
-	if (!_DC_wu_check(wu))
-		return(DC_ERR_UNKNOWN_WU);
-
-	DC_log(LOG_DEBUG, "DC_submitWU(%p-\"%s\")", wu, wu->data.name);
-
-	if (wu->data.state != DC_WU_READY)
-	{
-		DC_log(LOG_INFO, "Re-submission of %s", wu->data.name);
-		return(DC_ERR_BADPARAM);
-	}
-
-	ret= _DC_wu_gen_condor_submit(wu);
-	if (ret)
-	{
-		DC_log(LOG_ERR, "Submit file generation failed");
-		return(ret);
-	}
-
-	/*fn= g_string_new(wu->workdir);*/
-	/*fn= g_string_append(fn, "/condor_submit.txt");*/
-    tries=0;
-    sleeptime= DC_getCfgInt("SubmitRetrySleepTime", 2); 
-    maxtries = DC_getCfgInt("SubmitRetry", 5);    
-    do 
-    {
-    	ret= _DC_start_condor_job(wu);
-        tries++;
-        if (ret != 0)
-        {
-            if (tries > maxtries)
-                break;
-            DC_log(LOG_INFO, "Failed to submit WU to Condor. Sleeping for %d seconds and retrying (%d of %d)", 
-                sleeptime, tries, maxtries);
-            sleep(sleeptime);
-            sleeptime*=2;
-        }        
-    } while (ret != 0);
-	if (ret == 0)
-	{
-		/* Fix #1105 */
-		_DC_wu_set_state(wu, DC_WU_RUNNING);
-		_DC_wu_update_condor_events(wu);
-		while (wu->condor_events->len == 0)
-		{
-			sleep(1);
-			_DC_wu_update_condor_events(wu);
-		}
-		/*_DC_wu_set_state(wu, DC_WU_RUNNING);*/
-		id= DC_getWUId(wu);
-		DC_log(LOG_INFO, "Condor id of wu's job: %s", id);
-		g_free(id);
-	}
-	return(ret);
-}
-
-
-static int
-_DC_stop_condor_job(DC_Workunit *wu)
-{
-	char *id;
-	GString *cmd;
-	int ret;
-
-	if (!_DC_wu_check(wu))
-		return(DC_ERR_UNKNOWN_WU);
-
-	id= DC_getWUId(wu);
-	if (!id)
-		return(DC_ERR_UNKNOWN_WU);
-	cmd= g_string_new("condor_rm ");
-	cmd= g_string_append(cmd, id);
-	DC_log(LOG_DEBUG, "Calling \"%s\"...", cmd->str);
-	ret= system(cmd->str);
-	DC_log(LOG_DEBUG, "Returned %d", ret);
-	g_string_free(cmd, TRUE);
-	g_free(id);
-	return((ret==0)?DC_OK:DC_ERR_BADPARAM);
-}
-
-
-/* Cancels all computations for a given work unit. */
-int
-DC_cancelWU(DC_Workunit *wu)
-{
-	int ret;
-
-	if (!_DC_wu_check(wu))
-		return(DC_ERR_UNKNOWN_WU);
-
-	DC_log(LOG_DEBUG, "DC_cancelWU(%p-\"%s\")", wu, wu->data.name);
-
-	if (wu->data.state != DC_WU_RUNNING &&
-	    wu->data.state != DC_WU_SUSPENDED)
-	{
-		DC_log(LOG_NOTICE, "Can not cancel a non-running/non-suspended wu");
-		return(DC_ERR_INTERNAL);
-	}
-	ret= _DC_stop_condor_job(wu);
-	if (wu->data.state == DC_WU_SUSPENDED)
-		ret= 0;
-	_DC_wu_set_state(wu, DC_WU_ABORTED);
-	return((ret==0)?DC_OK:DC_ERR_BADPARAM);
-}
-
-
-/* Temporarily suspends the execution of a work unit. */
-int
-DC_suspendWU(DC_Workunit *wu)
-{
-	GString *dn;
-
-	if (!_DC_wu_check(wu))
-		return(DC_ERR_UNKNOWN_WU);
-
-	DC_log(LOG_DEBUG, "DC_suspendWU(%p-\"%s\")", wu, wu->data.name);
-
-	if (wu->data.state != DC_WU_RUNNING)
-	{
-		DC_log(LOG_NOTICE, "Can not suspend a non-running wu");
-		return(DC_ERR_INTERNAL);
-	}
-	dn= g_string_new(wu->data.workdir);
-	g_string_append(dn, "/");
-	g_string_append(dn, _DC_wu_cfg(wu, cfg_management_box));
-	_DC_create_message(dn->str, _DCAPI_MSG_COMMAND, _DCAPI_CMD_SUSPEND,
-			   NULL);
-	g_string_free(dn, TRUE);
-	/*wu->asked_to_suspend= TRUE;*/
-	return(DC_OK);
-}
-
-
-/* Resumes computation of a previously suspended work unit. */
-int
-DC_resumeWU(DC_Workunit *wu)
-{
-	int ret;
-	char *id;
-	GString *dn;
-
-	if (!_DC_wu_check(wu))
-		return(DC_ERR_UNKNOWN_WU);
-
-	DC_log(LOG_DEBUG, "DC_resumeWU(%p-\"%s\")", wu, wu->data.name);
-
-	if (wu->data.state != DC_WU_SUSPENDED)
-	{
-		DC_log(LOG_NOTICE, "Can not resume a non-suspended wu");
-		return(DC_ERR_INTERNAL);
-	}
-	dn= g_string_new(wu->data.workdir);
-	g_string_append(dn, "/");
-	g_string_append(dn, _DC_wu_cfg(wu, cfg_management_box));
-	_DC_create_message(dn->str, _DCAPI_MSG_COMMAND, _DCAPI_CMD_RESUME,
-			   NULL);
-	g_string_free(dn, TRUE);
-	ret= _DC_start_condor_job(wu);
-	if (ret == 0)
-	{
-		_DC_wu_update_condor_events(wu);
-		while (wu->condor_events->len == 0)
-		{
-			sleep(1);
-			_DC_wu_update_condor_events(wu);
-		}
-		DC_log(LOG_DEBUG, "DC_ResumeWU...");
-		_DC_wu_set_state(wu, DC_WU_RUNNING);
-		id= DC_getWUId(wu);
-		DC_log(LOG_INFO, "Condor id of wu's job: %s", id);
-		g_free(id);
-	}
-	return(ret);
-}
-
-
-/* End of condor/condor_managewu.c */
-
-/* Local variables: */
-/* c-file-style: "linux" */
-/* End: */
diff --git a/dcapi/condor/condor_master.c b/dcapi/condor/condor_master.c
deleted file mode 100644
index bb57e6f..0000000
--- a/dcapi/condor/condor_master.c
+++ /dev/null
@@ -1,1356 +0,0 @@
-/*
- * condor/condor_master.c
- *
- * DC-API functions of master side
- *
- * (c) Daniel Drotos, 2006
- */
-
-
-#include <glib.h>
-#include <stdio.h>
-#include <stdlib.h>
-#include <unistd.h>
-#include <string.h>
-#include <errno.h>
-#include <dirent.h>
-#include <sys/stat.h>
-
-#include "dc.h"
-
-#include "condor_master.h"
-#include "condor_common.h"
-#include "condor_defs.h"
-#include "condor_wu.h"
-#include "condor_log.h"
-#include "condor_utils.h"
-#include "condor_event.h"
-
-
-/* some utils */
-
-static struct {
-	DC_WUState state;
-	char *name;
-}
-_DC_state_names[]= {
-	{ DC_WU_READY, "READY" },
-	{ DC_WU_RUNNING, "RUNNING" },
-	{ DC_WU_FINISHED, "FINISHED" },
-	{ DC_WU_SUSPENDED, "SUSPENDED" },
-	{ DC_WU_ABORTED, "ABORTED" },
-	{ DC_WU_UNKNOWN, "UNKNOWN" },
-	{ 0, NULL }
-};
-
-
-char *
-_DC_state_name(DC_WUState state)
-{
-	int i;
-	for (i= 0; _DC_state_names[i].name; i++)
-		if (_DC_state_names[i].state == state)
-			return(_DC_state_names[i].name);
-	return("(unknown)");
-}
-
-
-/********************************************************************* INIT */
-
-static GHashTable *_DC_wu_table= NULL;
-uuid_t _DC_project_uuid;
-char *_DC_project_uuid_str= NULL;
-char *_DC_config_file= NULL;
-
-DC_ResultCallback	_DC_result_callback= NULL;
-DC_SubresultCallback	_DC_subresult_callback= NULL;
-DC_MessageCallback	_DC_message_callback= NULL;
-
-
-
-/* Initializes the DC-API. */
-int
-DC_initMaster(const char *configFile)
-{
-	int ret;
-	char *cfgval= NULL;
-	GString *gs;
-
-	if (!configFile)
-		configFile= DC_CONFIG_FILE;
-	if (configFile[0] != '/')
-	{
-		gs= g_string_new(g_get_current_dir());
-		g_string_append(gs, "/");
-		g_string_append(gs, configFile);
-	}
-	else
-		gs= g_string_new(configFile);
-	_DC_config_file= gs->str;
-	g_string_free(gs, FALSE);
-
-	ret= _DC_parseCfg(configFile);
-	if (ret)
-	{
-		DC_log(LOG_ERR, "DC-API config file (%s) parse error",
-		       configFile);
-		return(ret);
-	}
-	DC_log(LOG_DEBUG, "DC_initMaster(%s)", configFile);
-
-	_DC_init_utils();
-	_DC_init_common();
-
-	if (!_DC_wu_table)
-		_DC_wu_table= g_hash_table_new_full(g_str_hash,
-						    g_str_equal,
-						    NULL,
-						    NULL);
-
-	cfgval= DC_getCfgStr(CFG_INSTANCEUUID);
-	if (!cfgval)
-	{
-		DC_log(LOG_ERR, "Setting of %s is missing from config file %s",
-		       CFG_INSTANCEUUID, configFile);
-		return(DC_ERR_CONFIG);
-	}
-	/*
-	ret= uuid_parse((char *)cfgval, _DC_project_uuid);
-	if (ret)
-	{
-		DC_log(LOG_ERR, "Invalid project UUID");
-		g_free(cfgval);
-		return(DC_ERR_CONFIG);
-	}
-	*/
-	if (_DC_project_uuid_str)
-		g_free(_DC_project_uuid_str);
-	_DC_project_uuid_str= g_strdup(cfgval);
-	g_free(cfgval);
-
-	/* Enforce a canonical string representation of the UUID */
-	/*uuid_unparse_lower(_DC_project_uuid, _DC_project_uuid_str);*/
-	uuid_parse(_DC_project_uuid_str, _DC_project_uuid);
-
-	return(DC_OK);
-}
-
-
-/****************************************************** Manage WU structure */
-
-/* Creates one work unit. */
-DC_Workunit *
-DC_createWU(const char *clientName,
-	    const char *arguments[], int subresults, const char *tag)
-{
-	DC_Workunit *wu;
-	char uuid_str[37];
-	uuid_t wu_uuid;
-	int ret;
-
-	wu= g_new0(DC_Workunit, 1);
-	_DC_wu_changed(wu);
-
-	DC_log(LOG_DEBUG, "DC_createWU(%s, %p, %d, %s)=%p",
-	       clientName, arguments, subresults, tag, wu);
-
-	_DC_wu_set_client_name(wu, clientName);
-
-	wu->argv= g_strdupv((char **)arguments);
-	for (_DC_wu_set_argc(wu, 0);
-	     arguments && arguments[wu->data.argc];
-	     _DC_wu_set_argc(wu, wu->data.argc+1))
-		;
-	_DC_wu_set_subresults(wu, subresults);
-	_DC_wu_set_tag(wu, g_strdup(tag));
-	
-	uuid_generate(wu_uuid);
-	uuid_unparse_lower(wu_uuid, uuid_str);
-	{
-		char *wd= DC_getCfgStr(CFG_WORKDIR);
-		GString *s= g_string_new("");
-		GString *d= g_string_new("");
-
-		g_string_printf(d, "%s/.dcapi-%s/%.2s/%s", wd,
-				_DC_project_uuid_str, uuid_str, uuid_str);
-		g_string_printf(s, "%s", uuid_str);
-
-		_DC_wu_set_uuid_str(wu, s->str);
-		g_string_free(s, FALSE);
-		/*g_string_free(hd, TRUE);*/
-		_DC_wu_set_workdir(wu, d->str);
-		g_string_free(d, FALSE);
-		free(wd);
-	}
-
-	GString *wu_name;
-	wu_name = g_string_new("");
-	if (tag)
-		g_string_printf(wu_name, "%s_%s_%s",_DC_project_uuid_str,	
-			wu->data.uuid_str, tag);
-	else 
-		g_string_printf(wu_name, "%s_%s", _DC_project_uuid_str,
-			wu->data.uuid_str);
-	wu->data.name = strdup(wu_name->str);
-
-	wu->condor_events= g_array_new(FALSE, FALSE,
-				       sizeof(struct _DC_condor_event));
-
-	if (!_DC_wu_table)
-		DC_initMaster(NULL);
-	g_hash_table_insert(_DC_wu_table, wu_name->str, wu);
-
-	g_string_free(wu_name, FALSE);
-
-	ret= _DC_mkdir_with_parents(wu->data.workdir, 0700);
-	if (ret)
-	{
-		DC_log(LOG_ERR,
-		       "Failed to create WU working directory %s: %s",
-		       wu->data.workdir, strerror(errno));
-		DC_destroyWU(wu);
-		return(NULL);
-	}
-
-	_DC_wu_make_client_config(wu);
-	_DC_wu_make_client_executables(wu);
-	_DC_wu_set_state(wu, DC_WU_READY);
-
-	return(wu);
-}
-
-
-/* Releases internal resources allocated to a work unit. */
-void
-DC_destroyWU(DC_Workunit *wu)
-{
-	int i;
-	GString *s;
-	int serialized= FALSE;
-
-	if (!_DC_wu_check(wu))
-		return;
-	DC_log(LOG_DEBUG, "DC_destroyWU(%p-\"%s\")", wu, wu->data.name);
-
-	if (_DC_wu_table)
-		g_hash_table_remove(_DC_wu_table, wu->data.name);
-
-	s= g_string_new("");
-
-	g_string_printf(s, "%s/%s", wu->data.workdir,
-			_DC_wu_cfg(wu, cfg_management_box));
-	if ((i= _DC_nuof_messages(s->str, _DCAPI_SIG_SERIALIZED)) > 0)
-	{
-		DC_log(LOG_NOTICE, "destroying a serialized "
-		       "wu: %s", wu->data.name);
-		serialized= TRUE;
-	}
-
-	g_string_printf(s, "%s/%s", wu->data.workdir,
-			_DC_wu_cfg(wu, cfg_master_message_box));
-	if ((i= _DC_nuof_messages(s->str, _DCAPI_MSG_MESSAGE)) > 0)
-		DC_log(LOG_NOTICE, "%d master messages unhandled by "
-		       "destroying wu: %s", i, wu->data.name);
-
-	g_string_printf(s, "%s/%s", wu->data.workdir,
-			_DC_wu_cfg(wu, cfg_client_message_box));
-	if ((i= _DC_nuof_messages(s->str, _DCAPI_MSG_MESSAGE)) > 0)
-		DC_log(LOG_NOTICE, "%d client messages unhandled of wu: %s",
-		       i, wu->data.name);
-
-	g_string_printf(s, "%s/%s", wu->data.workdir,
-			_DC_wu_cfg(wu, cfg_subresults_box));
-	if ((i= _DC_nuof_messages(s->str, _DCAPI_MSG_LOGICAL)) > 0)
-		DC_log(LOG_NOTICE, "%d client subresults unhandled of wu: %s",
-		       i, wu->data.name);
-	g_string_free(s, TRUE);
-
-	if (wu->data.state == DC_WU_READY ||
-	    wu->data.state == DC_WU_UNKNOWN)
-		DC_log(LOG_NOTICE, "Destroying an unstarted wu: %s", wu->data.name);
-
-	if (wu->data.state == DC_WU_RUNNING ||
-	    wu->data.state == DC_WU_SUSPENDED)
-	{
-		DC_log(LOG_NOTICE, "Destroying a started but not yet "
-		       "finished wu: %s", wu->data.name);
-		DC_log(LOG_INFO, "WU has been started but not finished "
-		       "not removing its workdir %s", wu->data.workdir);
-	}
-	else if (wu->data.workdir)
-	{
-		const char *name;
-		char *exec;
-		GDir *dir;
-		int ret, i;
-		GString *fn;
-		int leave;
-
-		leave= strtol(_DC_wu_cfg(wu, cfg_leave_files), 0, 0);
-		if (leave)
-			DC_log(LOG_INFO, "WU's files not deleted");
-
-		/* Removing generated files */
-		fn= g_string_new(wu->data.workdir);
-		if (!leave &&
-		    !serialized)
-		{
-			fn= g_string_append(fn, "/");
-			fn= g_string_append(fn, _DC_wu_cfg(wu, cfg_submit_file));
-			unlink(fn->str);
-			g_string_printf(fn, "%s/%s", wu->data.workdir,
-					CLIENT_CONFIG_NAME);
-			unlink(fn->str);
-			g_string_printf(fn, "%s/%s", wu->data.workdir,
-					_DC_wu_cfg(wu, cfg_executable));
-			unlink(fn->str);
-			g_string_printf(fn, "%s/%s", wu->data.workdir,
-					_DC_wu_cfg(wu, cfg_condor_log));
-			unlink(fn->str);
-			g_string_printf(fn, "%s/%s", wu->data.workdir,
-					DC_LABEL_STDOUT);
-			unlink(fn->str);
-			g_string_printf(fn, "%s/%s", wu->data.workdir,
-					DC_LABEL_STDERR);
-			unlink(fn->str);
-			exec= _DC_wu_cfg(wu, cfg_executable);
-			if (!exec)
-				exec= wu->data.client_name;
-			g_string_printf(fn, "%s/%s", wu->data.workdir,
-					exec);
-			unlink(fn->str);
-			g_string_printf(fn, "%s/%s", wu->data.workdir,
-					DC_getClientCfgStr(wu->data.client_name,
-							   "LogFile",
-							   TRUE));
-			unlink(fn->str);
-		}
-		
-		if (!leave &&
-		    !serialized)
-		{
-			g_string_printf(fn, "%s/%s", wu->data.workdir,
-					_DC_wu_cfg(wu, cfg_client_message_box));
-			i= _DC_rm(fn->str);
-			if (i > 0)
-				DC_log(LOG_NOTICE, "%d unhandled client messages "
-				       "remained", i);
-			
-			g_string_printf(fn, "%s/%s", wu->data.workdir,
-					_DC_wu_cfg(wu, cfg_management_box));
-			i= _DC_rm(fn->str);
-			if (i > 0)
-				DC_log(LOG_NOTICE, "%d unhandled system messages "
-				       "remained", i);
-			
-			g_string_printf(fn, "%s/%s", wu->data.workdir,
-					_DC_wu_cfg(wu, cfg_master_message_box));
-			i= _DC_rm(fn->str);
-			if (i > 0)
-				DC_log(LOG_NOTICE, "%d unhandled master messages "
-				       "remained", i);
-			
-			g_string_printf(fn, "%s/%s", wu->data.workdir,
-					_DC_wu_cfg(wu, cfg_subresults_box));
-			i= _DC_rm(fn->str);
-			if (i > 0)
-				DC_log(LOG_NOTICE, "%d unhandled client subresults "
-				       "remained", i);
-		}
-
-		g_string_free(fn, TRUE);
-		
-		/* The work directory should not contain any extra files, but
-		 * just in case */
-		if (!leave &&
-		    !serialized)
-		{
-			dir= g_dir_open(wu->data.workdir, 0, NULL);
-			while (dir &&
-			       (name= g_dir_read_name(dir)))
-			{
-				GString *str= g_string_new(wu->data.workdir);
-				g_string_append_c(str, G_DIR_SEPARATOR);
-				g_string_append(str, name);
-				DC_log(LOG_INFO, "Removing unknown file %s",
-				       str->str);
-				unlink(str->str);
-				g_string_free(str, TRUE);
-			}
-			if (dir)
-				g_dir_close(dir);
-
-			ret= rmdir(wu->data.workdir);
-			if (ret)
-			{
-				DC_log(LOG_WARNING, "Failed to remove WU working "
-				       "directory %s: %s", wu->data.workdir,
-				       strerror(errno));
-			}
-		}
-		g_free(wu->data.workdir);
-	}
-
-
-	_DC_wu_set_client_name(wu, NULL);
-	g_free(wu->data.uuid_str);
-	g_strfreev(wu->argv);
-	if (wu->data.name != NULL)
-		g_free(wu->data.name);
-	if (wu->data.tag != NULL)
-		g_free(wu->data.tag);
-	g_array_free(wu->condor_events, TRUE);
-	g_free(wu);
-}
-
-
-/* Sets an input file for the work unit. */
-int
-DC_addWUInput(DC_Workunit *wu,
-	      const char *logicalFileName,
-	      const char *URL,
-	      DC_FileMode fileMode, ...)
-{
-	DC_PhysicalFile *file;
-	char *workpath;
-	int ret;
-
-	if (!_DC_wu_check(wu))
-		return(DC_ERR_UNKNOWN_WU);
-
-	/* Remote file aren't supported */
-	if (DC_FILE_REMOTE == fileMode)
-	{
-		DC_log(LOG_ERR, "Unsupported file mode for input file %s",
-			logicalFileName);
-		return(DC_ERR_BADPARAM);
-	}
-
-	DC_log(LOG_DEBUG, "DC_addWUInput(%p-\"%s\", %s, %s, %d)",
-	       wu, wu->data.name, logicalFileName, URL, fileMode);
-
-	if (wu->data.state != DC_WU_READY)
-	{
-		DC_log(LOG_INFO, "Modifying started wu %s", wu->data.name);
-		return(DC_ERR_BADPARAM);
-	}
-
-	/* Sanity checks */
-	ret= _DC_wu_check_logical_name(wu, logicalFileName);
-	if (ret)
-		return(ret);
-	workpath= _DC_wu_get_workdir_path(wu, logicalFileName, FILE_IN);
-	file= _DC_createPhysicalFile(logicalFileName, workpath);
-	g_free(workpath);
-	if (!file)
-		return(DC_ERR_INTERNAL);
-
-	switch (fileMode)
-	{
-	case DC_FILE_REGULAR:
-		DC_log(LOG_DEBUG, "Copying regular file %s to %s",
-		       URL, file->path);
-		ret= _DC_copyFile(URL, file->path);
-		if (ret)
-		{
-			_DC_destroyPhysicalFile(file);
-			return(ret/*DC_ERR_BADPARAM*/);	/* XXX */
-		}
-		break;
-	case DC_FILE_PERSISTENT:
-		DC_log(LOG_DEBUG, "Copying persistent file %s to %s",
-		       URL, file->path);
-		ret= _DC_copyFile(URL, file->path);
-		if (ret)
-		{
-			DC_log(LOG_ERR, "Failed to copy %s to %s",
-			       URL, file->path);
-			_DC_destroyPhysicalFile(file);
-			return(DC_ERR_BADPARAM);	/* XXX */
-		}
-		/* Remember the file mode */
-		file->mode= DC_FILE_PERSISTENT;
-		break;
-	case DC_FILE_VOLATILE:
-		DC_log(LOG_DEBUG, "Renaming %s to %s",
-		       URL, file->path);
-		ret= rename(URL, file->path);
-		if (ret)
-		{
-			DC_log(LOG_ERR, "Failed to rename %s to %s: %s",
-			       URL, file->path, strerror(errno));
-			_DC_destroyPhysicalFile(file);
-			return(DC_ERR_BADPARAM);
-		}
-	case DC_FILE_REMOTE:
-		break;
-	}
-
-	wu->input_files= g_list_append(wu->input_files, file);
-	/*wu->num_inputs++; */
-
-	return(0);
-}
-
-
-/* Defines an output file for the work unit. */
-int
-DC_addWUOutput(DC_Workunit *wu, const char *logicalFileName)
-{
-	int ret;
-
-	if (!_DC_wu_check(wu))
-		return(DC_ERR_UNKNOWN_WU);
-	DC_log(LOG_DEBUG, "DC_addWUOutput(%p-\"%s\", %s)",
-	       wu, wu->data.name, logicalFileName);
-
-	if (wu->data.state != DC_WU_READY)
-	{
-		DC_log(LOG_INFO, "Modifying started wu %s", wu->data.name);
-		return(DC_ERR_BADPARAM);
-	}
-
-	/* Sanity checks */
-	ret= _DC_wu_check_logical_name(wu, logicalFileName);
-	if (ret)
-		return ret;
-	DC_log(LOG_DEBUG, "Adding out file %s",
-	       logicalFileName);
-	wu->output_files= g_list_append(wu->output_files,
-					g_strdup(logicalFileName));
-	/*wu->num_outputs++;*/
-	return(0);
-}
-
-
-/* Sets the priority for the work unit. */
-int
-DC_setWUPriority(DC_Workunit *wu, int priority)
-{
-	if (!_DC_wu_check(wu))
-		return(DC_ERR_UNKNOWN_WU);
-	DC_log(LOG_DEBUG, "DC_setWUPriority(%p-\"%s\", %d)",
-	       wu, wu->data.name, priority);
-
-	if (wu->data.state != DC_WU_READY)
-	{
-		DC_log(LOG_INFO, "Modifying started wu %s", wu->data.name);
-		return(DC_ERR_BADPARAM);
-	}
-
-	return(DC_OK);
-}
-
-
-/* Sets the callback functions that will be called when a particular event. */
-void
-DC_setMasterCb(DC_ResultCallback resultcb,
-	       DC_SubresultCallback subresultcb,
-	       DC_MessageCallback msgcb)
-{
-	DC_log(LOG_DEBUG, "DC_setMasterCb(%p, %p, %p)",
-	       resultcb, subresultcb, msgcb);
-
-	_DC_result_callback= resultcb;
-	_DC_subresult_callback= subresultcb;
-	_DC_message_callback= msgcb;
-}
-
-
-/* Queries the state of a work unit. */
-DC_WUState
-DC_getWUState(DC_Workunit *wu)
-{
-	if (!_DC_wu_check(wu))
-		return(DC_WU_UNKNOWN);
-	return(wu->data.state);
-}
-
-
-/* Queries the low-level ID of the work unit. */
-char *
-DC_getWUId(const DC_Workunit *wu)
-{
-	GString *s;
-	struct _DC_condor_event *ce;
-
-	if (!_DC_wu_check(wu))
-		return(NULL);
-	_DC_wu_update_condor_events((DC_Workunit *)wu);
-	if (wu->condor_events->len == 0)
-		return(NULL);
-	ce= &g_array_index(wu->condor_events,
-			   struct _DC_condor_event,
-			   wu->condor_events->len-1);
-	s= g_string_new("");
-	g_string_printf(s, "%d.%d", ce->cluster, ce->proc);
-	return(g_string_free(s, FALSE));
-}
-
-
-/* Queries the tag of a work unit. */
-char *
-DC_getWUTag(const DC_Workunit *wu)
-{
-	if (!_DC_wu_check(wu))
-		return(NULL);
-	return((wu->data.tag)?strdup(wu->data.tag):NULL);
-}
-
-
-#define _DC_SERIALIZED_SEPARATOR '|'
-
-static void
-_DC_sser(GString *ser,
-	 _DC_serialized_token tok,
-	 char *str)
-{
-	char *s;
-	if (!ser)
-		return;
-	g_string_append_printf(ser, "%c%c%s",
-			       _DC_SERIALIZED_SEPARATOR,
-			       'a'+tok,
-			       s= _DC_quote_string(str));
-	s?free(s):0;
-}
-
-static void
-_DC_iser(GString *ser,
-	 _DC_serialized_token tok,
-	 int i)
-{
-	if (!ser)
-		return;
-	g_string_append_printf(ser, "%c%c%d",
-			       _DC_SERIALIZED_SEPARATOR,
-			       'a'+tok,
-			       i);
-}
-
-
-/* Get the full path of a file in the WU's working directory */
-static char *
-_DC_workDirPath(const DC_Workunit *wu, const char *label, WorkdirFile type)
-{
-	static const char *const pfx[] = { "in_", "out_", "checkpoint", "dc_" };
-
-	if (type == FILE_CKPT)
-		return g_strdup_printf("%s%ccheckpoint", wu->data.workdir,
-			G_DIR_SEPARATOR);
-
-	return g_strdup_printf("%s%c%s%s", wu->data.workdir, G_DIR_SEPARATOR,
-		pfx[type], label);
-}
-
-
-/* Open a file in the WU's working directory */
-static FILE *
-open_workdir_file(const DC_Workunit *wu, const char *label,
-	WorkdirFile type, const char *mode)
-{
-	char *name;
-	FILE *f;
-
-	name = _DC_workDirPath(wu, label, type);
-	f = fopen(name, mode);
-	if (!f)
-		DC_log(LOG_ERR, "Failed to open %s (mode %s): %s",
-			name, mode, strerror(errno));
-	g_free(name);
-	return f;
-}
-
-/* Serializes a work unit description. */
-static char *
-_DC_serializeWU(DC_Workunit *wu)
-{
-	GString *dn, *ser;
-	char *s;
-	int i;
-	unsigned int u;
-
-	if (!_DC_wu_check(wu)) {
-		DC_log(LOG_ERR, "_DC_wu_check() failed for work unit");
-		return(NULL);
-	}
-
-	dn= g_string_new("");
-	g_string_printf(dn, "%s/%s", wu->data.workdir,
-			_DC_wu_cfg(wu, cfg_management_box));
-	if (_DC_nuof_messages(dn->str, _DCAPI_SIG_SERIALIZED) > 0)
-	{
-		/* serialized already */
-		s= _DC_read_message(dn->str, _DCAPI_SIG_SERIALIZED, FALSE);
-		g_string_free(dn, TRUE);
-		return(s);
-	}
-	else
-	{
-		/* new serialization */
-		int r;
-		ser= g_string_new("");
-		s= _DC_quote_string(wu->data.name);
-		g_string_append_printf(ser, "%c%s", 'a'+st_name, s);
-		s?free(s):NULL;
-
-		_DC_sser(ser, st_workdir, wu->data.workdir);
-
-		_DC_sser(ser, st_tag, wu->data.tag);
-
-		_DC_sser(ser, st_client_name, wu->data.client_name);
-
-		_DC_sser(ser, st_uuid_str, wu->data.uuid_str);
-
-		_DC_iser(ser, st_argc, wu->data.argc);
-		for (i= 0; i<wu->data.argc; i++)
-		{
-			_DC_sser(ser, st_argv,
-				 (wu->argv[i])?(wu->argv[i]):NULL);
-		}
-
-		_DC_iser(ser, st_state, wu->data.state);
-		_DC_sser(ser, st_state_name, _DC_state_name(wu->data.state));
-
-		for (u= r= 0; u < wu->condor_events->len; u++)
-		{
-			struct _DC_condor_event *ce;
-			ce= &g_array_index(wu->condor_events,
-					   struct _DC_condor_event,
-					   u);
-			if (ce->reported)
-				r++;
-		}
-		_DC_iser(ser, st_nuof_reported, r);
-		for (u= 0; u < wu->condor_events->len; u++)
-		{
-			struct _DC_condor_event *ce;
-			ce= &g_array_index(wu->condor_events,
-					   struct _DC_condor_event,
-					   u);
-			if (ce->reported)
-				_DC_iser(ser, st_reported, u);
-		}
-
-		s= ser->str;
-		g_string_free(ser, FALSE);
-
-		_DC_create_message(dn->str, _DCAPI_SIG_SERIALIZED,
-				   s, NULL);
-		g_string_free(dn, TRUE);
-		return(s);
-	}
-	return(0);
-}
-
-char *
-DC_serializeWU(DC_Workunit *wu)
-{
-	FILE *f = open_workdir_file(wu, "serialized.txt", FILE_DCAPI, "w");
-	if (!f)
-		return NULL;		
-	char *serialized_data = _DC_serializeWU(wu);
-	fprintf(f, "%s", serialized_data);
-	fclose(f);
-	return strdup(wu->data.name);
-}
-
-
-static int
-_DC_iunser(char *s)
-{
-	int i;
-	if (!s)
-		return(0);
-	i= strtol(s, 0, 0);
-	free(s);
-	return(i);
-}
-
-/* Restores a serialized work unit. */
-static DC_Workunit *
-_DC_deserializeWU(const char *buf)
-{
-	char *tok, *s, *b;
-	char sep[2]= "\0\0";
-	DC_Workunit *wu;
-	int argv_i= 0;
-	GString *dn;
-
-	wu= g_new0(DC_Workunit ,1);
-	_DC_wu_changed(wu);
-	wu->condor_events= g_array_new(FALSE, FALSE,
-				       sizeof(struct _DC_condor_event));
-
-	b= strdup(buf);
-	sep[0]= _DC_SERIALIZED_SEPARATOR;
-	tok= strtok(b, sep);
-	while (tok)
-	{
-		_DC_serialized_token st= (_DC_serialized_token)(tok[0]-'a');
-		s= _DC_unquote_string(&tok[1]);
-		switch (st)
-		{
-		case st_name:
-		{
-			_DC_wu_set_name(wu, s);
-			break;
-		}
-		case st_workdir:
-		{
-			_DC_wu_set_workdir(wu, s);
-			_DC_wu_update_condor_events(wu);
-			break;
-		}
-		case st_tag:
-		{
-			_DC_wu_set_tag(wu, s);
-			break;
-		}
-		case st_client_name:
-		{
-			_DC_wu_set_client_name(wu, s);
-			if (!_DC_wu_table)
-				DC_initMaster(NULL);
-			g_hash_table_insert(_DC_wu_table, wu->data.name, wu);
-			break;
-		}
-		case st_uuid_str:
-		{
-			_DC_wu_set_uuid_str(wu, s);
-			break;
-		}
-		case st_argc:
-		{
-			_DC_wu_set_argc(wu, _DC_iunser(s));
-			wu->argv= g_new0(char*, wu->data.argc+1);
-			argv_i= 0;
-			break;
-		}
-		case st_argv:
-		{
-			if (argv_i < wu->data.argc)
-			{
-				wu->argv[argv_i]= s;
-				argv_i++;
-			}
-			break;
-		}
-		case st_state:
-		{
-			DC_log(LOG_DEBUG, "_DC_iunser");
-			_DC_wu_set_state(wu, (DC_WUState)_DC_iunser(s));
-			break;
-		}
-		case st_state_name:
-		{
-			free(s);
-			break;
-		}
-		case st_nuof_reported:
-		{
-			free(s);
-			break;
-		}
-		case st_reported:
-		{
-			unsigned int u;
-			u= _DC_iunser(s);
-			if (u < wu->condor_events->len)
-			{
-				struct _DC_condor_event *ce;
-				ce= &g_array_index(wu->condor_events,
-						   struct _DC_condor_event,
-						   u);
-				ce->reported= TRUE;
-			}
-		}
-		}
-		tok= strtok(NULL, sep);
-	}
-	free(b);
-
-	if (!_DC_file_exists(wu->data.workdir))
-	{
-		DC_log(LOG_ERR, "Deserialized wu: no workdir (%s)",
-		       wu->data.workdir);
-		//DC_destroyWU(wu);
-		//return(NULL);
-	}
-	dn= g_string_new("");
-	g_string_printf(dn, "%s/%s", wu->data.workdir,
-			_DC_wu_cfg(wu, cfg_management_box));
-	_DC_read_message(dn->str, _DCAPI_SIG_SERIALIZED, TRUE);
-	g_string_free(dn, TRUE);
-	return(wu);
-}
-
-/********************************************************************
- * Helper functions
- */
-
-/* Calculate & create the working directory. The working directory has the
- * form: <project work dir>/.dcapi-<project uuid>/<hash>/<wu uuid> Where <hash>
- * is the first 2 hex digits of the uuid
- */
-static char *get_workdir(const uuid_t uuid, int create)
-{
-	char *tmp, uuid_str[37], *cfgval;
-	GString *str;
-	int ret;
-
-	uuid_unparse_lower(uuid, uuid_str);
-
-	cfgval = DC_getCfgStr(CFG_WORKDIR);
-	if (!cfgval)
-		return NULL;
-	str = g_string_new(cfgval);
-	free(cfgval);
-
-	if (create)
-	{
-		ret = mkdir(str->str, 0755);
-		if (ret && errno != EEXIST)
-			goto error;
-	}
-
-	g_string_append_c(str, G_DIR_SEPARATOR);
-	g_string_append(str, ".dcapi-");
-	g_string_append(str, _DC_project_uuid_str);
-	if (create)
-	{
-		ret = mkdir(str->str, 0755);
-		if (ret && errno != EEXIST)
-			goto error;
-	}
-
-	g_string_append_c(str, G_DIR_SEPARATOR);
-	g_string_append_printf(str, "%02x", uuid[0]);
-	if (create)
-	{
-		ret = mkdir(str->str, 0755);
-		if (ret && errno != EEXIST)
-			goto error;
-	}
-
-	g_string_append_c(str, G_DIR_SEPARATOR);
-	g_string_append(str, uuid_str);
-	if (create)
-	{
-		ret = mkdir(str->str, 0755);
-		if (ret && errno != EEXIST)
-			goto error;
-	}
-
-	tmp = str->str;
-	g_string_free(str, FALSE);
-	return tmp;
-
-error:
-	DC_log(LOG_ERR, "Failed to create WU working directory %s: %s",
-		str->str, strerror(errno));
-	g_string_free(str, TRUE);
-	return NULL;
-}
-
-
-DC_Workunit *
-DC_deserializeWU(const char *buf)
-{
-	DC_Workunit *wu;
-	char *uuid_str;
-	uuid_t uuid;
-	int ret;
-	char *workdir;
-	char *name = buf;
-	GString *wu_serialized_data;
-	char buffer[256];
-
-	/* Check if the WU belongs to this application */
-	uuid_str = g_strndup(name, 36);
-	ret = uuid_parse(uuid_str, uuid);
-	g_free(uuid_str);
-	if (ret)
-	{
-		DC_log(LOG_ERR, "WU name '%s' contains illegal UUID", name);
-		return NULL;
-	}
-
-	if (uuid_compare(uuid, _DC_project_uuid))
-	{
-		DC_log(LOG_WARNING, "WU '%s' does not belong to this "
-			"application", name);
-		return NULL;
-	}
-
-	/* WU name syntax: <uuid> '_' <uuid> [ '_' <tag> ] */
-	if (name[36] != '_' || (strlen(name) > 73 && name[73] != '_'))
-	{
-		DC_log(LOG_ERR, "Illegal WU name syntax in '%s'", name);
-		return NULL;
-	}
-
-	/* Check the WU's UUID */
-	uuid_str = g_strndup(name + 37, 36);
-	ret = uuid_parse(uuid_str, uuid);
-	g_free(uuid_str);
-	if (ret)
-	{
-		DC_log(LOG_ERR, "WU name '%s' contains illegal UUID", name);
-		return NULL;
-	}
-
-	workdir = get_workdir(uuid, 0);
-	wu = g_new0(DC_Workunit, 1);
-	wu->data.workdir = workdir;
-		
-	FILE *f = open_workdir_file(wu, "serialized.txt", FILE_DCAPI, "r");
-	g_free(wu);
-	if (!f)
-	{
-		DC_log(LOG_ERR, "Could not read serialized work unit from '%s'", workdir);
-		return NULL;
-	}
-	wu_serialized_data = g_string_new("");
-	while (fgets(buffer, sizeof(buffer), f)) {
-		g_string_append(wu_serialized_data, buffer);
-	}
-	fclose(f);
-	
-	wu = _DC_deserializeWU(wu_serialized_data->str);
-	return wu;
-}
-
-/* iterator for DC_getWUNumber() */
-static DC_WUState _DC_dd_look_for_state;
-static void _DC_dd_check_state(void *key, void *value, void *ptr)
-{
-	DC_Workunit *wu=(DC_Workunit *)value;
-	int *count= (int *)ptr;
-	if (wu->data.state == _DC_dd_look_for_state)
-		++(*count);
-}
-
-/* Queries the number of WUs known to the API in the given state. */
-int
-DC_getWUNumber(DC_WUState state)
-{
-	int val= 0;
-
-	_DC_dd_look_for_state= state;
-	g_hash_table_foreach(_DC_wu_table, (GHFunc)_DC_dd_check_state, &val);
-	return(val);
-}
-
-
-/************************************************************** Main cycles */
-
-static void
-_DC_process_event(DC_MasterEvent *event)
-{
-	if (!event)
-		return;
-
-	DC_log(LOG_DEBUG, "Processing an event %d, calling callback...",
-	       event->type);
-	switch (event->type)
-	{
-	case DC_MASTER_RESULT:
-	{
-		if (_DC_result_callback)
-			(*_DC_result_callback)(event->wu,
-					       event->result);
-		break;
-	}
-	case DC_MASTER_SUBRESULT:
-	{
-		if (_DC_subresult_callback)
-			(*_DC_subresult_callback)(event->wu,
-						  event->subresult->label,
-						  event->subresult->path);
-		break;
-	}
-	case DC_MASTER_MESSAGE:
-	{
-		if (_DC_message_callback)
-			(*_DC_message_callback)(event->wu,
-						event->message);
-		break;
-	}
-	}
-	DC_destroyMasterEvent(event);
-}
-
-
-/* Waits for events and processes them. */
-int
-DC_processMasterEvents(int timeout)
-{
-	/* call callback and destroy event */
-	time_t start, now;
-	DC_MasterEvent *event;
-
-	DC_log(LOG_DEBUG, "DC_processMasterEvents(%d)",
-	       timeout);
-
-	if ((event= DC_waitMasterEvent(NULL, 0)) != NULL)
-		_DC_process_event(event);
-	if (timeout==0)
-		return(DC_OK);
-
-	start= time(NULL);
-	now= time(NULL);
-	while (now-start <= timeout &&
-	       g_hash_table_size(_DC_wu_table) > 0)
-	{
-		sleep(1);
-		if ((event= DC_waitMasterEvent(NULL, 0)) != NULL)
-			_DC_process_event(event);
-		now= time(NULL);
-	}
-	return(DC_OK);
-}
-
-
-static DC_MasterEvent *_DC_filtered_event;
-static int _DC_counter;
-
-static gboolean
-_DC_check_filtered_wu_event(gpointer wu_name, gpointer w, gpointer ptr)
-{
-	DC_Workunit *wu= (DC_Workunit *)w;
-	char *filter= (char *)ptr;
-	char *tag;
-	int match= TRUE;
-	gboolean found;
-
-	_DC_counter++;
-	tag= DC_getWUTag(wu);
-	if (filter)
-		if (strcmp(tag, filter) != 0)
-			tag= FALSE;
-	tag?free(tag):0;
-	if (!match)
-	{
-		return(FALSE);
-	}
-	if ((_DC_filtered_event= DC_waitWUEvent(wu, 0)) != NULL)
-		DC_log(LOG_DEBUG,
-		       "DC_waitWUEvent found an event for wu %p-\"%s\"",
-		       wu, wu->data.name);
-	found= _DC_filtered_event != NULL;
-	return(found);
-}
-
-/* Checks for events and return them. */
-DC_MasterEvent *
-DC_waitMasterEvent(const char *wuFilter, int timeout)
-{
-	/* no callback called! */
-	DC_Workunit *wu;
-	time_t start, now;
-
-	if (timeout)
-		DC_log(LOG_DEBUG, "DC_waitMasterEvent(%s, %d)",
-		       wuFilter, timeout);
-
-	start= time(NULL);
-	now= time(NULL);
-	do
-	{
-		_DC_filtered_event= NULL;
-		_DC_counter= 0;
-		wu= (DC_Workunit *)
-			g_hash_table_find(_DC_wu_table,
-					  _DC_check_filtered_wu_event,
-					  (gpointer)wuFilter);
-		
-		if (_DC_filtered_event)
-			return(_DC_filtered_event);
-		if (timeout)
-			sleep(1);
-	}
-	while (timeout != 0 &&
-	       now-start <= timeout);
-	return(NULL);
-}
-
-
-/* Checks for events for a particular WU. */
-DC_MasterEvent *
-DC_waitWUEvent(DC_Workunit *wu, int timeout)
-{
-	/* no callback called! */
-	time_t start, now;
-	DC_MasterEvent *me= NULL;
-
-	if (!_DC_wu_check(wu))
-		return(NULL);
-	if (timeout)
-		DC_log(LOG_DEBUG, "DC_waitWUEvent(%p-\"%s\", %d)",
-		       wu, wu->data.name, timeout);
-
-	start= time(NULL);
-	now= start;
-	do
-	{
-		_DC_wu_update_condor_events(wu);
-		if ((me= _DC_wu_check_client_messages(wu)) != NULL)
-			DC_log(LOG_DEBUG, "DC_waitWUEvent found a message for "
-			       "wu %p-\"%s\"", wu, wu->data.name);
-		if (!me)
-		{
-			if ((me= _DC_wu_condor2api_event(wu)) != NULL)
-				DC_log(LOG_DEBUG,
-				       "DC_waitWUEvent found a "
-				       "condor event for wu %p-\"%s\"",
-				       wu, wu->data.name);
-		}
-		if (me)
-		{
-			return(me);
-		}
-		now= time(NULL);
-		if (timeout)
-			sleep(1);
-	}
-	while (timeout !=0 &&
-	       now-start <= timeout);
-	return(NULL);
-}
-
-
-/* Destroys an event. */
-void
-DC_destroyMasterEvent(DC_MasterEvent *event)
-{
-	DC_log(LOG_DEBUG, "DC_destroyMasterEvent(%p)", event);
-	_DC_event_destroy(event);
-}
-
-
-/**************************************************************** Messaging */
-
-/* Sends a message to a running work unit. */
-int
-DC_sendWUMessage(DC_Workunit *wu, const char *message)
-{
-	GString *dn;
-	int ret;
-
-	if (!_DC_wu_check(wu))
-		return(DC_ERR_UNKNOWN_WU);
-	DC_log(LOG_DEBUG, "DC_sendWUMessage(%p-\"%s\", %s)",
-	       wu, wu->data.name, message);
-	dn= g_string_new(wu->data.workdir);
-	g_string_append(dn, "/");
-	g_string_append(dn, _DC_wu_cfg(wu, cfg_master_message_box));
-	ret= _DC_create_message(dn->str, _DCAPI_MSG_MESSAGE, message, NULL);
-	g_string_free(dn, TRUE);
-	return(ret);
-}
-
-
-/********************************************************** Result handling */
-
-/* Queries what optional fields are present in the result. */
-unsigned
-DC_getResultCapabilities(const DC_Result *result)
-{
-	int cap;
-	char *fn;
-	
-	/* Fix #1106 */
-	cap= DC_GC_EXITCODE | DC_GC_LOG;
-	/*cap|= DC_GC_STDOUT | DC_GC_STDERR;*/
-	fn= DC_getResultOutput(result, DC_LABEL_STDERR);
-	if (_DC_file_exists(fn) &&
-	    !_DC_file_empty(fn))
-		cap|= DC_GC_STDERR;
-	free(fn);
-	fn= DC_getResultOutput(result, DC_LABEL_STDOUT);
-	if (_DC_file_exists(fn))
-		cap|= DC_GC_STDOUT;
-	free(fn);
-
-	return(cap);
-}
-
-
-/* Returns the WU that generated this result. */
-DC_Workunit *
-DC_getResultWU(DC_Result *result)
-{
-	if (!result)
-		return(NULL);
-	return(result->wu);
-}
-
-
-/* Returns the exit code of the client application. */
-int
-DC_getResultExit(const DC_Result *result)
-{
-	int i;
-
-	if (!result)
-		return(0);
-	if (!_DC_wu_check(result->wu))
-		return(0);
-	if (_DC_wu_exit_code(result->wu, &i) != DC_OK)
-		return(0);
-	return(i);
-}
-
-
-/* Returns the local name of an output file. */
-char *
-DC_getResultOutput(const DC_Result *result, const char *logicalFileName)
-{
-	GString *fn;
-
-	if (!result)
-		return(NULL);
-	if (!_DC_wu_check(result->wu))
-		return(NULL);
-	fn= g_string_new(result->wu->data.workdir);
-	fn= g_string_append(fn, "/");
-	if (strcmp(logicalFileName, DC_LABEL_CLIENTLOG) == 0)
-	{
-		/* Fix #1107 */
-		char *s= DC_getClientCfgStr(result->wu->data.client_name,
-					    "LogFile",
-					    FALSE);
-		if (s)
-		{
-			fn= g_string_append(fn, s);
-			free(s);
-		}
-		else
-			fn= g_string_append(fn, DC_LABEL_CLIENTLOG);
-	}
-	else
-		fn= g_string_append(fn, logicalFileName);
-	return(g_string_free(fn, FALSE));
-}
-
-
-/* Application level configuration parameter */
-char *
-_DC_acfg(enum _DC_e_param what)
-{
-	char *v;
-
-	v= DC_getCfgStr(_DC_params[what].name);
-	if (v &&
-	    *v)
-		return(v);
-	return(_DC_params[what].def);
-}
-
-
-/* End of condor/condor_master.c */
-
-/* Local variables: */
-/* c-file-style: "linux" */
-/* End: */
diff --git a/dcapi/condor/condor_master.h b/dcapi/condor/condor_master.h
deleted file mode 100644
index 16b3777..0000000
--- a/dcapi/condor/condor_master.h
+++ /dev/null
@@ -1,37 +0,0 @@
-/*
- * condor/condor_master.h
- *
- * DC-API functions of master side
- *
- * (c) Daniel Drotos, 2006
- */
-
-#ifndef _DC_API_CONDOR_MASTER_H_
-#define _DC_API_CONDOR_MASTER_H_
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-#include "dc.h"
-
-#include "condor_common.h"
-
-
-extern char *_DC_config_file;
-
-extern char *_DC_acfg(enum _DC_e_param what);
-
-extern char *_DC_state_name(DC_WUState state);
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif
-
-/* End of condor/condor_master.h */
-
-/* Local variables: */
-/* c-file-style: "linux" */
-/* End: */
diff --git a/dcapi/condor/condor_result.c b/dcapi/condor/condor_result.c
deleted file mode 100644
index b6ea3de..0000000
--- a/dcapi/condor/condor_result.c
+++ /dev/null
@@ -1,36 +0,0 @@
-/*
- * condor/condor_result.c
- *
- * DC-API functions to handle DC_Result data type
- *
- * (c) Daniel Drotos, 2006
- */
-
-#include "condor_result.h"
-
-
-DC_Result *
-_DC_result_create(DC_Workunit *wu)
-{
-	DC_Result *r;
-	
-	r= g_new0(DC_Result, 1);
-	r->wu= wu;
-	return(r);
-}
-
-
-void
-_DC_result_destroy(DC_Result *result)
-{
-	if (!result)
-		return;
-	g_free(result);
-}
-
-
-/* End of condor_result.c */
-
-/* Local variables: */
-/* c-file-style: "linux" */
-/* End: */
diff --git a/dcapi/condor/condor_result.h b/dcapi/condor/condor_result.h
deleted file mode 100644
index 714a078..0000000
--- a/dcapi/condor/condor_result.h
+++ /dev/null
@@ -1,33 +0,0 @@
-/*
- * condor/condor_result.h
- *
- * DC-API functions to handle DC_Result data type
- *
- * (c) Daniel Drotos, 2006
- */
-
-#ifndef _DC_API_CONDOR_RESULT_H_
-#define _DC_API_CONDOR_RESULT_H_
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-#include "condor_defs.h"
-
-
-extern DC_Result *_DC_result_create(DC_Workunit *wu);
-extern void _DC_result_destroy(DC_Result *result);
-
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif
-
-/* End of condor/condor_result.h */
-
-/* Local variables: */
-/* c-file-style: "linux" */
-/* End: */
diff --git a/dcapi/condor/condor_slave.c b/dcapi/condor/condor_slave.c
deleted file mode 100644
index a1f8106..0000000
--- a/dcapi/condor/condor_slave.c
+++ /dev/null
@@ -1,365 +0,0 @@
-/*
- * condor/condor_slave.c
- *
- * DC-API functions of slave side
- *
- * (c) Daniel Drotos, 2006
- */
-
-#include <stdio.h>
-#include <string.h>
-#include <stdlib.h>
-#include <sys/stat.h>
-#include <dirent.h>
-#include <unistd.h>
-#include <errno.h>
-
-#include "dc_common.h"
-#include "dc_client.h"
-#include "dc_internal.h"
-
-#include "condor_common.h"
-#include "condor_slave.h"
-#include "condor_utils.h"
-
-
-static int _DC_checkpoint_file_requested= 0;
-static int _DC_checkpoint_made= 0;
-
-static char *
-_DC_cfg(enum _DC_e_param what)
-{
-	if (what >= cfg_nuof)
-		return(NULL);
-	if (_DC_params[what].lvalue)
-		return(_DC_params[what].lvalue);
-
-	_DC_params[what].lvalue= DC_getCfgStr(_DC_params[what].name);
-	if (_DC_params[what].lvalue)
-		return(_DC_params[what].lvalue);
-	return(_DC_params[what].def);
-}
-
-/* Initializes the client API. */
-int DC_initClient(void)
-{
-	char *message;
-	/*extern int _DC_parseCfg(const char *cfgfile);*/
-
-	int ret= _DC_parseCfg(CLIENT_CONFIG_NAME);
-	if (ret)
-		fprintf(stderr, "Error parsing configfile %s",
-			CLIENT_CONFIG_NAME);
-
-	_DC_init_utils();
-	_DC_init_common();
-
-	DC_log(LOG_DEBUG, "Slave dcapi initialized");
-
-	message= _DC_read_message(_DC_cfg(cfg_management_box),
-				  _DCAPI_MSG_COMMAND, /*FALSE*/0);
-	if (message &&
-	    strcmp(message, _DCAPI_CMD_RESUME) == 0)
-	{
-		DC_log(LOG_INFO, "Resume, restarting...");
-		_DC_read_message(_DC_cfg(cfg_management_box),
-				 _DCAPI_MSG_COMMAND, /*TRUE*/1);
-	}
-
-	return(ret);
-}
-
-
-/* Resolves the local name of input/output files. */
-char *DC_resolveFileName(DC_FileType type,
-			 const char *logicalFileName)
-{
-	/* init_log calls this fn, so it is not possible to call DC_log
-	   from here */
-	/*DC_log(LOG_DEBUG, "DC_resolveFileName(%d,%s)",
-	  type, logicalFileName);*/
-	char *cn= _DC_cfg(cfg_checkpoint_file);
-	if (!strcmp(logicalFileName, DC_CHECKPOINT_FILE))
-	{
-		switch (type)
-		{
-		case DC_FILE_IN:
-		{
-			/* - param of last DC_checkpointMade()
-			   - filename created by previous run
-			   - NULL otherwise */
-			if (_DC_checkpoint_made)
-			{
-				char *fn= (char*)malloc(strlen(cn)+100);
-				sprintf(fn, "%s_finished.txt", cn);
-				return(fn);
-			}
-			else
-			{
-				FILE *f;
-				char *fn= (char*)malloc(strlen(cn)+100);
-				sprintf(fn, "%s_finished.txt", cn);
-				if ((f= fopen(fn, "r")) != NULL)
-				{
-					fclose(f);
-					return(fn);
-				}
-				else
-				{
-					free(fn);
-					return(NULL);
-				}
-			}
-			break;
-		}
-		case DC_FILE_OUT:
-		{
-			char *s;
-			/* new non-existant name */
-			if (_DC_checkpoint_file_requested)
-			{
-				DC_log(LOG_ERR, "Checkpoint file creation "
-				       "can not be restarted "
-					"(DC_resolveFileName("
-					DC_CHECKPOINT_FILE
-					") called twice without calling of "
-					"DC_checkpointMade())");
-				return(NULL);
-			}
-			_DC_checkpoint_file_requested= 1;
-			s= (char*)malloc(strlen(cn)+100);
-			sprintf(s, "%s_creating.txt", cn);
-			return(s);
-			break;
-		}
-		default:
-			return(NULL);
-		}
-	}
-	return(strdup((char*)logicalFileName));
-	switch (type)
-	{
-	case DC_FILE_IN:
-	{
-		/* registered by DC_addWUInput() */
-		break;
-	}
-	case DC_FILE_OUT:
-	{
-		/* registered by DC_addWUOutput */
-		break;
-	}
-	case DC_FILE_TMP:
-	{
-		/* non-registered */
-		break;
-	}
-	default:
-		return(NULL);
-	}
-}
-
-
-/* Sends a sub-result back to the master. */
-int DC_sendResult(const char *logicalFileName,
-		  const char *path,
-		  DC_FileMode fileMode)
-{
-	char *fn;
-	int ret;
-	/*extern int _DC_copyFile(const char *src, const char *dst);*/
-
-	DC_log(LOG_DEBUG, "DC_sendResult(%s,%s,%d)",
-	       logicalFileName,
-	       path,
-	       fileMode);
-	fn= malloc(strlen(logicalFileName)+100);
-	strcpy(fn, _DC_cfg(cfg_subresults_box));
-	strcat(fn, "/real_files");
-	if ((ret= _DC_mkdir_with_parents(fn, S_IRWXU|
-					 S_IRGRP|S_IXGRP|
-					 S_IROTH|S_IXOTH)) != DC_OK)
-	{
-		DC_log(LOG_ERR, "Failed to create dir for subresult (%s): %s",
-		       fn, strerror(errno));
-		free(fn);
-		return(ret);
-	}
-	strcat(fn, "/");
-	strcat(fn, logicalFileName);
-	if ((ret= _DC_copyFile(path, fn)) != DC_OK)
-	{
-		DC_log(LOG_ERR, "Failed to copy subresult file %s to "
-		       "%s", path, fn);
-		free(fn);
-		return(ret);
-	}
-	ret= _DC_create_message(_DC_cfg(cfg_subresults_box),
-				_DCAPI_MSG_LOGICAL, logicalFileName, NULL);
-	free(fn);
-	return(ret);
-}
-
-
-/* Sends a message to the master. */
-int DC_sendMessage(const char *message)
-{
-	DC_log(LOG_DEBUG, "DC_sendMessage(%s)", message);
-	return _DC_create_message(_DC_cfg(cfg_client_message_box),
-				  _DCAPI_MSG_MESSAGE, message, NULL);
-}
-
-
-/* Checks for application control events. */
-DC_ClientEvent *DC_checkClientEvent(void)
-{
-	char *message;
-	DC_ClientEvent *e= NULL;
-
-	message= _DC_read_message(_DC_cfg(cfg_master_message_box),
-				  _DCAPI_MSG_MESSAGE, /*TRUE*/1);
-	if (message)
-	{
-		if ((e= calloc(1, sizeof(DC_ClientEvent))))
-		{
-			DC_log(LOG_DEBUG, "API event created: %p", e);
-			e->type= DC_CLIENT_MESSAGE;
-			e->message= message;
-			DC_log(LOG_DEBUG, "Message of the event: %s",
-			       e->message);
-		}
-		else
-		{
-			free(message);
-			DC_log(LOG_ERR, "Failed to create "
-			       "API event, memory allocation "
-			       "error");
-		}
-		return(e);
-	}
-
-	message= _DC_read_message(_DC_cfg(cfg_management_box),
-				  _DCAPI_MSG_COMMAND, /*TRUE*/1);
-	if (message &&
-	    strcmp(message, _DCAPI_CMD_SUSPEND) == 0)
-	{
-		char *fn;
-		int f;
-
-		DC_log(LOG_INFO, "Master asked me to suspend");
-		_DC_create_message(_DC_cfg(cfg_management_box),
-				   _DCAPI_MSG_ACK,
-				   _DCAPI_ACK_SUSPEND,
-				   NULL);
-
-		fn= DC_resolveFileName(DC_FILE_IN, DC_CHECKPOINT_FILE);
-		if (fn != NULL)
-			free(fn);
-		else
-		{
-			DC_log(LOG_WARNING, "Slave suspending but "
-			       "no checkpoint made yet");
-			free(fn);
-		}
-
-		fflush(NULL);
-		fn= DC_resolveFileName(DC_FILE_OUT, DC_LABEL_STDOUT);
-		if (fn)
-		{
-			if ((f= open(fn, O_APPEND)) > 0)
-			{
-				fsync(f);
-				close(f);
-			}
-			free(fn);
-		}
-		_DC_create_message(_DC_cfg(cfg_output_cache),
-				   DC_LABEL_STDOUT,
-				   NULL,
-				   DC_LABEL_STDOUT);
-		fn= DC_resolveFileName(DC_FILE_OUT, DC_LABEL_STDERR);
-		if (fn)
-		{
-			if ((f= open(fn, O_APPEND)) > 0)
-			{
-				fsync(f);
-				close(f);
-			}
-			free(fn);
-		}
-		_DC_create_message(_DC_cfg(cfg_output_cache),
-				   DC_LABEL_STDERR,
-				   NULL,
-				   DC_LABEL_STDERR);
-
-		DC_finishClient(0);
-	}
-	return(NULL);
-}
-
-
-/* Destroys the event-specific data returned by DC_checkClientEvent(). */
-void DC_destroyClientEvent(DC_ClientEvent *event)
-{
-	DC_log(LOG_DEBUG, "DC_destroyClientEvent(%p)", event);
-	if (event)
-	{
-		switch (event->type)
-		{
-		case DC_CLIENT_MESSAGE:
-		{
-			if (event->message)
-				free(event->message);
-			break;
-		}
-		default:
-			break;
-		}
-		free(event);
-	}
-}
-
-
-/* Indicates that an application-level checkpoint has completed. */
-void DC_checkpointMade(const char *fileName)
-{
-	DC_log(LOG_DEBUG, "DC_checkpointMade(%s)", fileName);
-	_DC_checkpoint_file_requested= 0;
-	if (fileName)
-	{
-		char *cn= _DC_cfg(cfg_checkpoint_file);
-		char *fn;
-		fn= (char*)malloc(strlen(cn)+100);
-		sprintf(fn, "%s_finished.txt", cn);
-		if (rename(fileName, fn) != 0)
-		{
-			DC_log(LOG_ERR, "Renaming %s to %s failed: %s",
-			       fileName, fn, strerror(errno));
-		}
-		else
-			_DC_checkpoint_made++;
-		free(fn);
-	}
-}
-
-
-/* Informs the user interface about the fraction of work already done. */
-void DC_fractionDone(double fraction)
-{
-	DC_log(LOG_DEBUG, "DC_fractionDone(%g)", fraction);
-}
-
-
-/* Finishes computation. */
-void DC_finishClient(int exitcode)
-{
-	DC_log(LOG_DEBUG, "DC_finishClient(%d)", exitcode);
-	exit(exitcode);
-}
-
-
-/* End of condor/condor_slave.c */
-
-/* Local variables: */
-/* c-file-style: "linux" */
-/* End: */
diff --git a/dcapi/condor/condor_slave.h b/dcapi/condor/condor_slave.h
deleted file mode 100644
index 3b4e3d7..0000000
--- a/dcapi/condor/condor_slave.h
+++ /dev/null
@@ -1,31 +0,0 @@
-/*
- * condor/condor_slave.h
- *
- * DC-API functions of slave side
- *
- * (c) Daniel Drotos, 2006
- */
-
-#ifndef __DC_API_CONDOR_SLAVE_H_
-#define __DC_API_CONDOR_SLAVE_H_
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-
-/* Name of the checkpoint file */
-#define CKPT_LABEL		"dc_checkpoint"
-
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif
-
-/* End of condor/condor_slave.h */
-
-/* Local variables: */
-/* c-file-style: "linux" */
-/* End: */
diff --git a/dcapi/condor/condor_utils.c b/dcapi/condor/condor_utils.c
deleted file mode 100644
index f105a70..0000000
--- a/dcapi/condor/condor_utils.c
+++ /dev/null
@@ -1,474 +0,0 @@
-/*
- * condor/condor_utils.c
- *
- * DC-API usefull functions
- *
- * (c) Daniel Drotos, 2006
- */
-
-#include <stdio.h>
-#include <sys/stat.h>
-#include <dirent.h>
-#include <string.h>
-#include <errno.h>
-#include <unistd.h>
-#include <stdlib.h>
-#include <ctype.h>
-
-#include "dc_internal.h"
-#include "dc_common.h"
-
-#include "condor_utils.h"
-#include "condor_common.h"
-
-
-void
-_DC_init_utils(void)
-{
-}
-
-
-int
-_DC_mkdir_with_parents(char *dn, mode_t mode)
-{
-	char *p= dn;
-	int res;
-
-	/*fprintf(stderr, "making %s (EEXIST=%d)\n", dn, EEXIST);*/
-	if (!dn ||
-	    !*dn)
-		return(0);
-	while (*p)
-	{
-		while (*p != '/' &&
-		       *p != '\0')
-			p++;
-		if (*p == '/')
-		{
-			*p= '\0';
-			if (*dn)
-			{
-				/*fprintf(stderr, "mkdir(%s,%d)=",dn,mode);*/
-				res= mkdir(dn, mode);
-				/*fprintf(stderr, "%d %d\n", res, errno);*/
-			}
-			*p= '/';
-			p++;
-		}
-	}
-	/*fprintf(stderr, "mkdir(%s,%d)=",dn,mode);*/
-	res= mkdir(dn, mode);
-	/*fprintf(stderr, "%d %d\n", res, errno);*/
-	if (res != 0 &&
-	    errno == EEXIST)
-		return(DC_OK);
-	return(res?DC_ERR_SYSTEM:DC_OK);
-}
-
-
-static int
-_DC_rmsubdir(char *name)
-{
-	DIR *d;
-	struct dirent *de;
-	int i= 0;
-
-	if ((d= opendir(name)) == NULL)
-	{
-		DC_log(LOG_DEBUG, "Open %s: %s", name, strerror(errno));
-		return(0);
-	}
-	while ((de= readdir(d)))
-	{
-		if (strcmp(de->d_name, ".") != 0 &&
-		    strcmp(de->d_name, "..") != 0)
-		{
-			char *s= malloc(strlen(name)+strlen(de->d_name) + 10);
-			strcpy(s, name);
-			strcat(s, "/");
-			strcat(s, de->d_name);
-			i+= _DC_rm(s);
-			free(s);
-		}
-	}
-	closedir(d);
-	if (rmdir(name))
-	{
-		DC_log(LOG_ERR, "Failed to rmdir %s: %s",
-		       name, strerror(errno));
-	}
-	return(i);
-}
-
-int
-_DC_rm(char *name)
-{
-	struct stat s;
-	int i;
-
-	if (!name ||
-	    !*name)
-		return(0);
-	i= lstat(name, &s);
-	if (i != 0)
-	{
-		return(0);
-	}
-	if (S_ISDIR(s.st_mode) &&
-	    strcmp(name, ".") != 0 &&
-	    strcmp(name, "..") != 0)
-	{
-		return(_DC_rmsubdir(name));
-	}
-	else
-		{
-			if (remove(name))
-				DC_log(LOG_ERR, "Failed to remove %s: %s",
-				       name, strerror(errno));
-		}
-	return(1);
-}
-
-
-int
-_DC_file_exists(char *fn)
-{
-	return(access(fn, F_OK) == 0);
-}
-
-
-int
-_DC_file_empty(char *fn)
-{
-	struct stat s;
-	
-	if (stat(fn, &s))
-		return(1);
-	return(s.st_size == 0);
-}
-
-
-int
-_DC_create_file(char *fn, char *what)
-{
-	FILE *f= fopen(fn, "w");
-	if (f)
-	{
-		if (what)
-			fprintf(f, "%s", what);
-		fclose(f);
-		return(DC_OK);
-	}
-	else
-		return(DC_ERR_SYSTEM);
-}
-
-
-char *
-_DC_get_file(char *fn)
-{
-	FILE *f;
-	char *buf= NULL;
-
-	if ((f= fopen(fn, "r")) != NULL)
-	{
-		int bs= 100, i;
-		int c;
-
-		buf= malloc(bs);
-		i= 0;
-		buf[i]= '\0';
-		while ((c= fgetc(f)) != EOF)
-		{
-			if (i > bs-2)
-			{
-				bs+= 100;
-				buf= realloc(buf, bs);
-			}
-			buf[i]= (char)c;
-			i++;
-		}
-		buf[i]= '\0';
-		fclose(f);
-	}
-	return(buf);
-}
-
-
-static int _DC_message_id= 0;
-
-int
-_DC_create_message(char *box,
-		   char *name,
-		   const char *message,
-		   char *msgfile)
-{
-	char *fn, *fn2;
-	FILE *f;
-	int ret= DC_OK;
-
-	/*DC_log(LOG_DEBUG, "DC_sendMessage(%s)", message);*/
-	if (!box ||
-	    !name)
-		return(DC_ERR_BADPARAM);
-	mkdir(box, S_IRWXU|S_IRGRP|S_IXGRP|S_IROTH|S_IXOTH);
-	_DC_message_id++;
-	fn= malloc(strlen(box)+strlen(name)+100);
-	sprintf(fn, "%s/%s_creating.%d", box, name, _DC_message_id);
-	if ((f= fopen(fn, "w")) != NULL)
-	{
-		if (message)
-			fprintf(f, "%s", message);
-		else if (msgfile)
-		{
-			if (_DC_copyFile(msgfile, fn))
-				DC_log(LOG_ERR, "copyFile(%s,%s) error",
-				       msgfile, fn);
-		}
-		else
-		{
-			DC_log(LOG_WARNING, "No message specified for "
-			       "creation");
-		}
-		if (fsync(fileno(f)) != 0)
-			DC_log(LOG_ERR, "Sync of %s: %d %s", fn,
-			       errno, strerror(errno));
-		fclose(f);
-		/*DC_log(LOG_DEBUG, "Message %d created", _DC_message_id);*/
-	}
-	else
-	{
-		DC_log(LOG_ERR, "Error creating message file (%s)",
-		       fn);
-		ret= DC_ERR_SYSTEM;
-	}
-	fn2= malloc(strlen(box)+strlen(name)+100);
-	sprintf(fn2, "%s/%s.%d", box, name, _DC_message_id);
-	rename(fn, fn2);
-	DC_log(LOG_DEBUG, "Message created: %s", fn2);
-	free(fn2);
-	free(fn);
-	return(ret);
-}
-
-
-int
-_DC_nuof_messages(char *box, char *name)
-{
-	DIR *d;
-	struct dirent *de;
-	int nuof= 0;
-	char *s;
-
-	if (!box)
-		return(0);
-	if ((d= opendir(box)) == NULL)
-		return(0);
-	s= malloc(100 + (name?strlen(name):strlen(_DCAPI_MSG_MESSAGE)));
-	strcpy(s, name?name:_DCAPI_MSG_MESSAGE);
-	strcat(s, ".");
-	while ((de= readdir(d)) != NULL)
-	{
-		char *found= strstr(de->d_name, s);
-		if (found == de->d_name)
-			nuof++;
-	}
-	if (d)
-		closedir(d);
-	free(s);
-	return(nuof);
-}
-
-
-char *
-_DC_message_name(char *box, char *name)
-{
-	char *dn, *n;
-	DIR *d;
-	struct dirent *de;
-	int min_id;
-
-	if (!box ||
-	    !name)
-		return(NULL);
-	if (!*box ||
-	    !*name)
-		return(NULL);
-	/*DC_log(LOG_DEBUG, "_DC_message_name(%s,%s)", box, name);*/
-	dn= strdup(box);
-	n= malloc(strlen(name)+10);
-	strcpy(n, name);
-	strcat(n, ".");
-	/*DC_log(LOG_DEBUG, "opendir(%s)=", dn);*/
-	d= opendir(dn);
-	/*DC_log(LOG_DEBUG, "%p", d);*/
-	min_id= -1;
-	while (d &&
-	       (de= readdir(d)) != NULL)
-	{
-		char *found= strstr(de->d_name, n);
-		/*DC_log(LOG_DEBUG, "%s <-> %s", de->d_name, n);*/
-		if (found == de->d_name)
-		{
-			char *pos= strrchr(de->d_name, '.');
-			/*DC_log(LOG_DEBUG, "found");*/
-			if (pos)
-			{
-				int id= 0;
-				pos++;
-				id= strtol(pos, NULL, 10);
-				/*DC_log(LOG_DEBUG, "id=%d", id);*/
-				if (id > 0)
-				{
-					if (min_id < 0)
-						min_id= id;
-					else
-						if (id < min_id)
-							min_id= id;
-				}
-			}
-		}
-		/*else
-		  DC_log(LOG_DEBUG, "not found");*/
-	}
-	if (d)
-		closedir(d);
-	if (min_id >= 0)
-	{
-		dn= realloc(dn, strlen(box)+strlen(name)+100);
-		sprintf(dn, "%s/%s.%d", box, name, min_id);
-		free(n);
-		/*DC_log(LOG_DEBUG, "return: %s", dn);*/
-		return(dn);
-	}
-	if (dn)
-		free(dn);
-	if (n)
-		free(n);
-	/*DC_log(LOG_DEBUG, "return null");*/
-	return(NULL);
-}
-
-
-char *
-_DC_read_message(char *box, char *name, int del_msg)
-{
-	FILE *f;
-	char *fn= _DC_message_name(box, name);
-	char *buf= NULL;
-
-	if (fn==NULL)
-		return(NULL);
-	/*DC_log(LOG_DEBUG, "Reading message from %s", fn);*/
-	if ((f= fopen(fn, "r")) != NULL)
-	{
-		int bs= 100, i;
-		int c;
-
-		buf= malloc(bs);
-		i= 0;
-		buf[i]= '\0';
-		while ((c= fgetc(f)) != EOF)
-		{
-			if (i > bs-2)
-			{
-				bs+= 100;
-				buf= realloc(buf, bs);
-			}
-			buf[i]= (char)c;
-			i++;
-		}
-		buf[i]= '\0';
-		fclose(f);
-		if (del_msg)
-			unlink(fn);
-	}
-	if (fn!=NULL)
-		free(fn);
-	return(buf);
-}
-
-
-char *
-_DC_quote_string(char *str)
-{
-	int i, n;
-	char *s, *p;
-
-	if (!str)
-	{
-		s= strdup("\\nnn");
-		return(s);
-	}
-	if (!*str)
-	{
-		s= strdup("\\000");
-		return(s);
-	}
-
-	for (i= n= 0; str[i]; i++)
-	{
-		if (!isalnum(str[i]))
-			n++;
-	}
-
-	s= calloc(strlen(str)+10*n+10, 1);
-	for (i= 0, p= s; str[i]; i++)
-	{
-		if (isalnum(str[i]))
-		{
-			*p= str[i];
-			p++;
-		}
-		else
-		{
-			sprintf(p, "\\%03o", str[i]);
-			p+= strlen(p);
-		}
-	}
-	return(s);
-}
-
-
-char *
-_DC_unquote_string(char *str)
-{
-	char *s, *p, *i;
-
-	if (!str)
-		return(NULL);
-	s= calloc(strlen(str)+1, 1);
-	p= str;
-	i= s;
-	while (*p != '\0')
-	{
-		if (*p != '\\')
-			*i= *p;
-		else
-		{
-			char c, *x= p+4;
-			int l;
-			c= *x;
-			*x= '\0';
-			if (strcmp(p+1, "nnn") == 0)
-			{
-				free(s);
-				return(NULL);
-			}
-			l= strtol(p+1, 0, 8);
-			*i= (char)l;
-			*x= c;
-			p= x-1;
-		}
-		p++;
-		i++;
-	}
-	return(s);
-}
-
-
-/* End of condor_utils.c */
-
-/* Local variables: */
-/* c-file-style: "linux" */
-/* End: */
diff --git a/dcapi/condor/condor_utils.h b/dcapi/condor/condor_utils.h
deleted file mode 100644
index b6476c6..0000000
--- a/dcapi/condor/condor_utils.h
+++ /dev/null
@@ -1,54 +0,0 @@
-/*
- * condor/condor_utils.h
- *
- * DC-API usefull functions
- *
- * (c) Daniel Drotos, 2006
- */
-
-#ifndef __DC_API_CONDOR_UTILS_H_
-#define __DC_API_CONDOR_UTILS_H_
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-#include <fcntl.h>
-
-#include "condor_common.h"
-
-
-extern void _DC_init_utils(void);
-
-/* Usefull funcs */
-extern int _DC_mkdir_with_parents(char *dn, mode_t mode);
-extern int _DC_rm(char *name);
-extern int _DC_file_exists(char *fn);
-extern int _DC_file_empty(char *fn);
-extern int _DC_create_file(char *fn, char *what);
-extern char *_DC_get_file(char *fn);
-
-/* Message passing utilities */
-extern int _DC_create_message(char *box,
-			      char *name,
-			      const char *message,
-			      char *msgfile);
-extern int _DC_nuof_messages(char *box, char *name);
-extern char *_DC_message_name(char *box, char *name);
-extern char *_DC_read_message(char *box, char *name, int del_msg);
-
-extern char *_DC_quote_string(char *str);
-extern char *_DC_unquote_string(char *str);
-
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif
-
-/* End of condor/condor_utils.h */
-
-/* Local variables: */
-/* c-file-style: "linux" */
-/* End: */
diff --git a/dcapi/condor/condor_wu.c b/dcapi/condor/condor_wu.c
deleted file mode 100644
index cd502fb..0000000
--- a/dcapi/condor/condor_wu.c
+++ /dev/null
@@ -1,628 +0,0 @@
-/*
- * condor/condor_wu.c
- *
- * DC-API functions to handle DC_Workunit data type
- *
- * (c) Daniel Drotos, 2006
- */
-
-#include <glib.h>
-#include <stdio.h>
-#include <string.h>
-#include <dirent.h>
-#include <stdlib.h>
-#include <unistd.h>
-#include <ctype.h>
-#include <time.h>
-
-#include "dc.h"
-#include "dc_common.h"
-
-#include "condor_common.h"
-#include "condor_master.h"
-#include "condor_wu.h"
-#include "condor_event.h"
-#include "condor_utils.h"
-
-
-/*****************************************************************************/
-
-void
-_DC_wu_changed(DC_Workunit *wu)
-{
-	unsigned char *p;
-	int i, sum= 0;
-
-	if (!wu)
-		return;
-	p= (unsigned char*)(&(wu->data));
-	for (i= 0; i < (signed)sizeof(struct _DC_wu_data); i++)
-		sum+= p[i];
-	wu->magic= sum;
-	wu->chk= 0-sum;
-}
-
-int
-_DC_wu_check(const DC_Workunit *wu)
-{
-	if (!wu)
-		return(FALSE);
-	if ((wu->magic + wu->chk) != 0)
-		return(FALSE);
-	return(TRUE);
-}
-
-
-int
-_DC_wu_set_client_name(DC_Workunit *wu,
-		       const char *new_name)
-{
-	if (!_DC_wu_check(wu))
-		return(DC_ERR_UNKNOWN_WU);
-	g_free(wu->data.client_name);
-	wu->data.client_name= g_strdup(new_name);
-	_DC_wu_changed(wu);
-	return(DC_OK);
-}
-
-int
-_DC_wu_set_argc(DC_Workunit *wu,
-		int new_argc)
-{
-	if (!_DC_wu_check(wu))
-		return(DC_ERR_UNKNOWN_WU);
-	wu->data.argc= new_argc;
-	_DC_wu_changed(wu);
-	return(DC_OK);
-}
-
-
-int
-_DC_wu_set_uuid_str(DC_Workunit *wu,
-		    char *new_uuid_str)
-{
-	if (!_DC_wu_check(wu))
-		return(DC_ERR_UNKNOWN_WU);
-	wu->data.uuid_str= new_uuid_str;
-	_DC_wu_changed(wu);
-	return(DC_OK);
-}
-
-int
-_DC_wu_set_name(DC_Workunit *wu,
-		char *new_name)
-{
-	if (!_DC_wu_check(wu)) {
-		DC_log(LOG_ERR, "Cannot change wu name! ('%s')", new_name);
-		return(DC_ERR_UNKNOWN_WU);
-	}
-	wu->data.name= new_name;
-	_DC_wu_changed(wu);
-	return(DC_OK);
-}
-
-int
-_DC_wu_set_tag(DC_Workunit *wu,
-	       char *new_tag)
-{
-	if (!_DC_wu_check(wu))
-		return(DC_ERR_UNKNOWN_WU);
-	wu->data.tag= new_tag;
-	_DC_wu_changed(wu);
-	return(DC_OK);
-}
-
-int
-_DC_wu_set_subresults(DC_Workunit *wu,
-		      int new_subresults)
-{
-	if (!_DC_wu_check(wu))
-		return(DC_ERR_UNKNOWN_WU);
-	wu->data.subresults= new_subresults;
-	_DC_wu_changed(wu);
-	return(DC_OK);
-}
-
-int
-_DC_wu_set_workdir(DC_Workunit *wu,
-		   char *new_workdir)
-{
-	if (!_DC_wu_check(wu))
-		return(DC_ERR_UNKNOWN_WU);
-	wu->data.workdir= new_workdir;
-	_DC_wu_changed(wu);
-	return(DC_OK);
-}
-
-
-DC_WUState
-_DC_wu_set_state(DC_Workunit *wu,
-		 DC_WUState new_state)
-{
-	/*DC_WUState act= wu->state;*/
-	if (!_DC_wu_check(wu))
-		return(DC_WU_UNKNOWN);
-	DC_log(LOG_DEBUG, "Set state to %s of %p-\"%s\"", _DC_state_name(new_state), wu, wu->data.name);
-	wu->data.state= new_state;
-	_DC_wu_changed(wu);
-	return(wu->data.state);
-}
-
-
-/* Get a configuration parameter */
-char *
-_DC_wu_cfg(DC_Workunit *wu,
-	   enum _DC_e_param what)
-{
-	if (!_DC_wu_check(wu))
-		return(NULL);
-	if (what >= cfg_nuof)
-		return(NULL);
-	if (!_DC_params[what].name)
-		return(NULL);
-
-	if (_DC_params[what].gvalue)
-		return(_DC_params[what].gvalue);
-
-	_DC_params[what].gvalue=
-		DC_getClientCfgStr(wu->data.client_name,
-				   _DC_params[what].name,
-				   /*TRUE*/1);
-	if (_DC_params[what].gvalue)
-		return(_DC_params[what].gvalue);
-	return(_DC_params[what].def);
-}
-
-
-/* Check if the logical name is not already registered */
-int
-_DC_wu_check_logical_name(DC_Workunit *wu,
-			  const char *logicalFileName)
-{
-	GList *l;
-
-	if (!_DC_wu_check(wu))
-		return(DC_ERR_UNKNOWN_WU);
-
-	if (strchr(logicalFileName, '/') || strchr(logicalFileName, '\\'))
-	{
-		DC_log(LOG_ERR, "Illegal characters in logical file name %s",
-		       logicalFileName);
-		return(DC_ERR_BADPARAM);
-	}
-	for (l= wu->input_files; l; l= l->next)
-	{
-		DC_PhysicalFile *file= (DC_PhysicalFile *)l->data;
-      
-		if (!strcmp(file->label, logicalFileName))
-		{
-			DC_log(LOG_ERR, "File %s is already registered as an "
-			       "input file", logicalFileName);
-			return(DC_ERR_BADPARAM);
-		}
-	}
-	for (l= wu->output_files; l; l= l->next)
-	{
-		if (!strcmp((char *)l->data, logicalFileName))
-		{
-			DC_log(LOG_ERR, "File %s is already registered as an "
-			       "output file", logicalFileName);
-			return(DC_ERR_BADPARAM);
-		}
-	}
-	DC_log(LOG_DEBUG, "Logical filename %s checked OK",
-	       logicalFileName);
-	return(0);
-}
-
-
-char *
-_DC_wu_get_workdir_path(DC_Workunit *wu,
-			const char *label,
-			WorkdirFile type)
-{
-	if (!_DC_wu_check(wu))
-		return(NULL);
-	return g_strdup_printf("%s%c%s", wu->data.workdir, G_DIR_SEPARATOR, label);
-}
-
-
-static char *_DC_condor_submit_template=
-"# Built-in template\n"
-"# Date: %d\n"
-"# WU name: %n\n"
-"# WU id: %i\n"
-"# WU workdir: %w\n"
-"# Client name: %c\n"
-"# Number of args: %r\n"
-"# List of input files: \"%I\"\n"
-"# List of output files: \"%O\"\n"
-"\n"
-"Executable = %x\n"
-"arguments = %a\n"
-"Universe = %u\n"
-"output = %o\n"
-"error = %e\n"
-"log = %l\n"
-"Queue\n"
-;
-
-static int
-_DC_wu_process_template(DC_Workunit *wu, char *tmpl, FILE *f)
-{
-	char *cfgarch;
-	char *cfgexec, *cfglog;
-	char *c= tmpl;
-    GString *filelist;
-
-	cfgarch= _DC_acfg(cfg_architectures);
-	cfgexec= _DC_wu_cfg(wu, cfg_executable);
-	if (!cfgexec)
-		cfgexec= wu->data.client_name;
-	cfglog= _DC_wu_cfg(wu, cfg_condor_log);
-
-	if (!_DC_wu_check(wu))
-		return(DC_ERR_UNKNOWN_WU);
-
-	if (!tmpl ||
-	    !f)
-		return(DC_ERR_INTERNAL);
-
-	while (*c)
-	{
-		if (*c == '%')
-		{
-			c++;
-			if (*c == '\0')
-				break;
-			switch (*c)
-			{
-			case 'n':
-			{
-				fprintf(f, "%s", wu->data.name);
-				break;
-			}
-			case 'r':
-			{
-				fprintf(f, "%d", wu->data.argc);
-				break;
-			}
-			case 'i':
-			{
-				fprintf(f, "%s", wu->data.uuid_str);
-				break;
-			}
-			case 'w':
-			{
-				fprintf(f, "%s", wu->data.workdir);
-				break;
-			}
-			case 'c':
-			{
-				fprintf(f, "%s", wu->data.client_name);
-				break;
-			}
-			case 'd':
-			{
-				time_t t;
-				char *ft;
-				t= time(NULL);
-				ft= ctime(&t);
-				ft[strlen(ft)-1]= '\0';
-				fprintf(f, "%s", ft);
-				break;
-			}
-			case 'x':
-			{
-				fprintf(f, "%s", cfgexec);
-				break;
-			}
-			case 'a':
-			{
-				int i;
-				for (i= 0; wu->data.argc > 0 &&
-					     wu->argv[i]; i++)
-				{
-					char *p= wu->argv[i];
-					if (!(*(wu->argv[i])))
-						fprintf(f, " ''");
-					else
-					{
-						while (*p && !isspace(*p))
-							p++;
-						if (*p)
-							fprintf(f, " '%s'", wu->argv[i]);
-						else
-							fprintf(f, " %s", wu->argv[i]);
-					}
-				}
-				break;
-			}
-			case 'u':
-			{
-				fprintf(f, "vanilla");
-				break;
-			}
-			case 'o':
-			{
-				fprintf(f, "%s", DC_LABEL_STDOUT);
-				break;
-			}
-			case 'e':
-			{
-				fprintf(f, "%s", DC_LABEL_STDERR);
-				break;
-			}
-			case 'l':
-			{
-				fprintf(f, "%s", cfglog);
-				break;
-			}
-            /* capital 'i' */
-			case 'I':
-			{
-                filelist = g_string_new(NULL);
-                g_list_foreach(wu->input_files, _DC_wu_input_list_foreach, filelist);
-                /* remove last comma from the string */
-                filelist = g_string_erase(filelist, filelist->len-1, -1);
-                fprintf(f, "%s", filelist->str);    
-                g_string_free(filelist, TRUE);
-                break;
-			}
-			case 'O':
-			{
-                filelist = g_string_new(NULL);
-                g_list_foreach(wu->output_files, _DC_wu_output_list_foreach, filelist);
-                /* remove last comma from the string */
-                filelist = g_string_erase(filelist, filelist->len-1, -1);
-                fprintf(f, "%s", filelist->str);    
-                g_string_free(filelist, TRUE);
-                break;
-			}
-			default:
-			{
-				fprintf(f, "%c", *c);
-				break;
-			}
-			}
-		}
-		else
-		{
-			fprintf(f, "%c", *c);
-		}
-		c++;
-	}
-	return(DC_OK);
-}
-
-int
-_DC_wu_gen_condor_submit(DC_Workunit *wu)
-{
-	FILE *f= NULL;
-	GString *fn;
-	char *cfgtmpl;
-	char *tmpl= 0;
-	int ret;
-
-	if (!_DC_wu_check(wu))
-		return(DC_ERR_UNKNOWN_WU);
-
-	fn= g_string_new(wu->data.workdir);
-	fn= g_string_append(fn, "/");
-	fn= g_string_append(fn, _DC_wu_cfg(wu, cfg_submit_file));
-	if ((f= fopen(fn->str, "w+")) == NULL)
-	{
-		DC_log(LOG_ERR, "Condor submit file %s creation failed",
-		       fn->str);
-		g_string_free(fn, TRUE);
-		return(DC_ERR_SYSTEM);
-	}
-	g_string_free(fn, TRUE);
-
-	cfgtmpl= _DC_wu_cfg(wu, cfg_condor_submit_template);
-	if (!cfgtmpl)
-		tmpl= _DC_condor_submit_template;
-	else
-	{
-		tmpl= _DC_get_file(cfgtmpl);
-	}
-	ret= DC_OK;
-	if (tmpl)
-	{
-		ret= _DC_wu_process_template(wu, tmpl, f);
-	}
-	else
-	{
-	}
-
-	if (f)
-		fclose(f);
-	return(ret);
-}
-
-
-int
-_DC_wu_make_client_executables(DC_Workunit *wu)
-{
-	char *archs;
-	char *exec;
-	int ret;
-	GString *src, *dst;
-
-	if (!_DC_wu_check(wu))
-		return(DC_ERR_UNKNOWN_WU);
-
-	archs= _DC_acfg(cfg_architectures);
-	
-	exec= _DC_wu_cfg(wu, cfg_executable);
-	if (!exec)
-		exec= wu->data.client_name;
-	src= g_string_new(exec);
-	dst= g_string_new(wu->data.workdir);
-	g_string_append(dst, "/");
-	g_string_append(dst, exec);
-	DC_log(LOG_DEBUG, "Copying client executable %s to %s",
-	       src->str, dst->str);
-	ret= _DC_copyFile(src->str, dst->str);
-	g_string_free(src, TRUE);
-	g_string_free(dst, TRUE);
-
-	/*
-	dst= g_string_new(wu->data.workdir);
-	g_string_append(dst, "/");
-	g_string_append(dst, CLIENT_CONFIG_NAME);
-	DC_log(LOG_DEBUG, "Copying config %s to %s",
-	       _DC_config_file, dst->str);
-	i= _DC_copyFile(_DC_config_file, dst->str);
-	if (i)
-		ret= i;
-	g_string_free(dst, TRUE);
-	*/
-
-	if (!ret)
-		return(ret);
-
-	return(DC_OK);
-}
-
-
-int
-_DC_wu_make_client_config(DC_Workunit *wu)
-{
-	GString *fn;
-	FILE *f;
-	char *s;
-
-	if (!_DC_wu_check(wu))
-		return(DC_ERR_UNKNOWN_WU);
-
-	fn= g_string_new(wu->data.workdir);
-	g_string_append(fn, "/");
-	g_string_append(fn, CLIENT_CONFIG_NAME);
-	if ((f= fopen(fn->str, "w")) != NULL)
-	{
-		if (_DC_initClientConfig(wu->data.client_name, f))
-		{
-			fclose(f);
-			return(DC_ERR_BADPARAM);
-		}
-		/* Fix #1107 */
-		s= DC_getClientCfgStr(wu->data.client_name,
-				      "LogFile",
-				      FALSE);
-		if (s)
-		{
-			fprintf(f, "LogFile = %s\n", s);
-			free(s);
-		}
-		else
-		{
-			fprintf(f, "LogFile = %s\n", DC_LABEL_CLIENTLOG);
-		}
-		
-		fclose(f);
-	}
-
-	return(DC_OK);
-}
-
-
-/*static int _DC_counter= 0;*/
-
-DC_MasterEvent *
-_DC_wu_check_client_messages(DC_Workunit *wu)
-{
-	GString *s;
-	char *message;
-	DC_MasterEvent *e= NULL;
-
-	if (!_DC_wu_check(wu))
-		return(NULL);
-
-	s= g_string_new(wu->data.workdir);
-	g_string_append_printf(s, "/%s",
-			       _DC_wu_cfg(wu, cfg_client_message_box));
-	/*DC_log(LOG_DEBUG, "Checking box %s for message\n", s->str);*/
-	if ((message= _DC_read_message(s->str, _DCAPI_MSG_MESSAGE, TRUE)))
-	{
-		e= _DC_event_create(wu, NULL, NULL, message);
-		DC_log(LOG_DEBUG, "Message event created: %p "
-		       "for wu (%p-\"%s\")", e, wu, wu->data.name);
-		DC_log(LOG_DEBUG, "Message of the event: %s", e->message);
-	}
-
-	/*
-	g_string_printf(s, "%s/%s", wu->data.workdir,
-			_DC_wu_cfg(wu, cfg_management_box));
-	if ((message= _DC_read_message(s->str, _DCAPI_MSG_ACK, TRUE)))
-	{
-		DC_log(LOG_DEBUG, "Acknowledge arrived: %s", message);
-		if (strcmp(message, _DCAPI_ACK_SUSPEND) == 0)
-		{
-			wu->asked_to_suspend= TRUE;
-		}
-	}
-	*/
-
-	if (e == NULL/*)
-		_DC_counter++;
-		  if (_DC_counter % 5 == 0*/)
-	{
-		g_string_printf(s, "%s/%s", wu->data.workdir,
-				_DC_wu_cfg(wu, cfg_subresults_box));
-		/*DC_log(LOG_DEBUG, "Checking box %s for logical_name\n",
-		  s->str);*/
-		if ((message= _DC_read_message(s->str, _DCAPI_MSG_LOGICAL,
-					       TRUE)))
-		{
-			DC_PhysicalFile *f;
-			g_string_append_printf(s, "/real_files/%s", message);
-			DC_log(LOG_DEBUG, "Got subresult %s %s",
-			       message, s->str);
-			f= _DC_createPhysicalFile(message, s->str);
-			e= _DC_event_create(wu, NULL, f, NULL);
-		}
-	}
-
-	g_string_free(s, TRUE);
-	return(e);
-}
-
-
-/* User function for g_list_foreach() in _DC_wu_process_template(): "%I"
- *
- * @data DC_PhysicalFile*
- * @user_data GString
- */
-void _DC_wu_input_list_foreach(gpointer data, gpointer user_data)
-{
-    if (data != NULL && ((DC_PhysicalFile*)data)->path != NULL) 
-    {
-        user_data = g_string_append((GString *)user_data, ((DC_PhysicalFile*)data)->path);
-        /* we want a comma separated list */
-        user_data = g_string_append((GString *)user_data, ",");
-    }
-}
-
-
-/* User function for g_list_foreach() in _DC_wu_process_template(): "%O"
- *
- * @data char* data to be appended 
- * @user_data GString the string to append to
- */
-void _DC_wu_output_list_foreach(gpointer data, gpointer user_data)
-{
-    if (data != NULL) 
-    {
-        user_data = g_string_append((GString *)user_data, (char*)data);    
-        /* we want a comma separated list */
-        user_data = g_string_append((GString *)user_data, ",");
-    }
-}
-
-
-/* End of condor/condor_wu.c */
-
-/* Local variables: */
-/* c-file-style: "linux" */
-/* End: */
diff --git a/dcapi/condor/condor_wu.h b/dcapi/condor/condor_wu.h
deleted file mode 100644
index 5e65055..0000000
--- a/dcapi/condor/condor_wu.h
+++ /dev/null
@@ -1,59 +0,0 @@
-/*
- * condor/condor_wu.h
- *
- * DC-API functions to handle DC_Workunit data type
- *
- * (c) Daniel Drotos, 2006
- */
-
-#ifndef _DC_API_CONDOR_WU_H_
-#define _DC_API_CONDOR_WU_H_
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-#include "condor_defs.h"
-#include "condor_common.h"
-
-
-extern void _DC_wu_changed(DC_Workunit *wu);
-extern int _DC_wu_check(const DC_Workunit *wu);
-
-extern int _DC_wu_set_client_name(DC_Workunit *wu, const char *new_name);
-extern int _DC_wu_set_argc(DC_Workunit *wu, int new_argc);
-extern int _DC_wu_set_uuid_str(DC_Workunit *wu, char *new_uuid_str);
-extern int _DC_wu_set_name(DC_Workunit *wu, char *new_name);
-extern int _DC_wu_set_tag(DC_Workunit *wu, char *new_tag);
-extern int _DC_wu_set_subresults(DC_Workunit *wu, int new_subresults);
-extern int _DC_wu_set_workdir(DC_Workunit *wu, char *new_workdir);
-
-extern DC_WUState _DC_wu_set_state(DC_Workunit *wu,
-				   DC_WUState new_state);
-
-extern char *_DC_wu_cfg(DC_Workunit *wu,
-			enum _DC_e_param what);
-
-extern int _DC_wu_check_logical_name(DC_Workunit *wu,
-				     const char *logicalFileName);
-extern char *_DC_wu_get_workdir_path(DC_Workunit *wu,
-				     const char *label,
-				     WorkdirFile type);
-extern int _DC_wu_gen_condor_submit(DC_Workunit *wu);
-extern int _DC_wu_make_client_executables(DC_Workunit *wu);
-extern int _DC_wu_make_client_config(DC_Workunit *wu);
-extern DC_MasterEvent *_DC_wu_check_client_messages(DC_Workunit *wu);
-extern void _DC_wu_input_list_foreach(gpointer data, gpointer user_data);
-extern void _DC_wu_output_list_foreach(gpointer data, gpointer user_data);
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif
-
-/* End of condor/condor_wu.h */
-
-/* Local variables: */
-/* c-file-style: "linux" */
-/* End: */
diff --git a/dcapi/condor/dcapi-condor-client.pc.in b/dcapi/condor/dcapi-condor-client.pc.in
deleted file mode 100644
index 24053ce..0000000
--- a/dcapi/condor/dcapi-condor-client.pc.in
+++ /dev/null
@@ -1,11 +0,0 @@
-prefix=@prefix@
-exec_prefix=@exec_prefix@
-libdir=@libdir@
-includedir=@includedir@
-
-Name: DC-API Condor Client
-Description: Condor client implementation for DC-API
-Version: @PACKAGE_VERSION@
-Requires.private: glib-2.0
-Libs: -L${libdir} -ldcapi-client-condor
-Cflags: -I${includedir}
diff --git a/dcapi/condor/dcapi-condor-master.pc.in b/dcapi/condor/dcapi-condor-master.pc.in
deleted file mode 100644
index 3f6fdda..0000000
--- a/dcapi/condor/dcapi-condor-master.pc.in
+++ /dev/null
@@ -1,11 +0,0 @@
-prefix=@prefix@
-exec_prefix=@exec_prefix@
-libdir=@libdir@
-includedir=@includedir@
-
-Name: DC-API Condor Master
-Description: Condor master implementation for DC-API
-Version: @PACKAGE_VERSION@
-Requires.private: glib-2.0
-Libs: -L${libdir} -ldcapi-condor -lstdc++ -luuid -ldl @CONDOR_LDFLAGS@ -lcondorapi
-Cflags: -I${includedir}
diff --git a/dcapi/condor/ls_lR.sh b/dcapi/condor/ls_lR.sh
deleted file mode 100755
index 5e96ba7..0000000
--- a/dcapi/condor/ls_lR.sh
+++ /dev/null
@@ -1,2 +0,0 @@
-date >$HOME/workdir/ls_lR.${1}.txt
-ls -lRa $HOME/workdir/.dcapi* >>$HOME/workdir/ls_lR.${1}.txt 2>&1
diff --git a/dcapi/condor/t.conf b/dcapi/condor/t.conf
deleted file mode 100644
index 1ada6ea..0000000
--- a/dcapi/condor/t.conf
+++ /dev/null
@@ -1,40 +0,0 @@
-# Template
-# Configuration file for local implementation of DC
-#
-
-[Master]
-#
-# UUID Instance
-#
-
-#InstanceUUID = 4b28cbf7-1881-459b-9e35-220a2b59c0e2
-InstanceUUID = 2
-
-# 
-# Working directory
-#
-
-WorkingDirectory = /home/staff/drdani/workdir
-
-#
-# Debugging level
-#
-
-LogLevel = Debug
-LogFile  = t.log
-
-#
-# Info abount clients
-#
-Architectures = i386
-Client_ts_i386 = ts
-
-LeaveFiles = 0
-
-CondorSubmitTemplate = tmpl.txt
-
-[Client-short]
-Executable = tss
-
-[Client-long]
-Executable = tss
diff --git a/dcapi/condor/tc.c b/dcapi/condor/tc.c
deleted file mode 100644
index a36d652..0000000
--- a/dcapi/condor/tc.c
+++ /dev/null
@@ -1,58 +0,0 @@
-/*
- * condor/tc.c
- *
- * DC-API test application, utility for both sides
- *
- * (c) Daniel Drotos, 2006
- */
-
-#include <stdio.h>
-#include <stdlib.h>
-
-#include "tc.h"
-
-void
-create_file(char *fn, char *what)
-{
-	FILE *f= fopen(fn, "w");
-	if (f)
-	{
-		if (what)
-			fprintf(f, "%s", what);
-		fclose(f);
-	}
-}
-
-char *
-get_file(char *fn)
-{
-	FILE *f;
-	char *buf= NULL;
-
-	if ((f= fopen(fn, "r")) != NULL)
-	{
-		int bs= 100, i;
-		int c;
-
-		buf= malloc(bs);
-		i= 0;
-		buf[i]= '\0';
-		while ((c= fgetc(f)) != EOF)
-		{
-			if (i > bs-2)
-			{
-				bs+= 100;
-				buf= realloc(buf, bs);
-			}
-			buf[i]= (char)c;
-			i++;
-		}
-		buf[i]= '\0';
-		fclose(f);
-	}
-	return(buf);
-}
-
-/* Local variables: */
-/* c-file-style: "linux" */
-/* End: */
diff --git a/dcapi/condor/tc.h b/dcapi/condor/tc.h
deleted file mode 100644
index ce11281..0000000
--- a/dcapi/condor/tc.h
+++ /dev/null
@@ -1,18 +0,0 @@
-/*
- * condor/tc.h
- *
- * DC-API test application, utility for both sides
- *
- * (c) Daniel Drotos, 2006
- */
-#ifndef TC_H
-#define TC_H
-
-extern void create_file(char *fn, char *what);
-extern char *get_file(char *fn);
-
-#endif
-
-/* Local variables: */
-/* c-file-style: "linux" */
-/* End: */
diff --git a/dcapi/condor/test_input.txt b/dcapi/condor/test_input.txt
deleted file mode 100644
index 00048d0..0000000
--- a/dcapi/condor/test_input.txt
+++ /dev/null
@@ -1,2 +0,0 @@
-This is a test input file for the uppercase-demo application!
-message = Hello master application
diff --git a/dcapi/condor/tm.c b/dcapi/condor/tm.c
deleted file mode 100644
index e3dc8ab..0000000
--- a/dcapi/condor/tm.c
+++ /dev/null
@@ -1,355 +0,0 @@
-/*
- * condor/tm.c
- *
- * DC-API test application, master
- *
- * (c) Daniel Drotos, 2006
- */
-
-#include <stdio.h>
-#include <string.h>
-#include <stdlib.h>
-#include <unistd.h>
-
-#include "dc.h"
-
-#include "tc.h"
-
-#define MAX_WU 100
-
-DC_Workunit *wut[MAX_WU];
-
-extern char *_DC_state_name(DC_WUState state);
-
-static void
-fail(char *what, int ret)
-{
-	printf("%s failed: %d\n", what, ret);
-	exit(ret);
-}
-
-static DC_Workunit *
-create_short(void)
-{
-	DC_Workunit *wu;
-	
-	printf("Creating short...\n");
-	wu= DC_createWU("short", NULL, 0, NULL);
-	printf("Created short wu: %p\n", wu);
-	if (!wu)
-		fail("DC_createWU", 0);
-	return(wu);
-}
-
-static DC_Workunit *
-create_long(int how_long)
-{
-	DC_Workunit *wu;
-	char *argv[]= {
-		"15",
-		"2",
-		"3",
-		"2",
-		NULL
-	};
-	char l[100];
-	
-	printf("Creating long...\n");
-	if (how_long > 0)
-	{
-		sprintf(l, "%d", how_long);
-		argv[0]= l;
-	}
-	wu= DC_createWU("long", (const char **)argv, 0, NULL);
-	printf("Created long wu: %p\n", wu);
-	if (!wu)
-		fail("DC_createWU", 0);
-	return(wu);
-}
-
-static void
-result_cb(DC_Workunit *wu, DC_Result *result)
-{
-	printf("\nresult_cb, wustate=%s\n",
-	       _DC_state_name(DC_getWUState(wu)));
-	printf("exit= %d\n", DC_getResultExit(result));
-}
-
-static void
-subresult_cb(DC_Workunit *wu,
-	     const char *logical_file_name,
-	     const char *path)
-{
-	printf("\nsubresult_cb, wustate=%s\n",
-	       _DC_state_name(DC_getWUState(wu)));
-	printf("logical= \"%s\"\n", logical_file_name);
-	printf("path   = \"%s\"\n", path);
-	printf("Content: \"%s\"\n", get_file((char*)path));
-	printf("Deleting %s...\n", path);
-	unlink(path);
-}
-
-static void
-message_cb(DC_Workunit *wu, const char *message)
-{
-	printf("\nmessage_cb, wustate=%s\n",
-	       _DC_state_name(DC_getWUState(wu)));
-	printf("Message= \"%s\"\n", message);
-}
-
-
-static void
-ls_lR(int i)
-{
-	char cmd[100];
-	sprintf(cmd, "./ls_lR.sh %03d", i);
-	//system(cmd);
-}
-
-int cycle= 0;
-
-static void
-process(DC_Workunit *wu, int timeout)
-{
-	printf("-- %3d %s\n", cycle, _DC_state_name(DC_getWUState(wu)));
-	DC_processMasterEvents(timeout);
-}
-
-static void
-procs(DC_Workunit *wu, DC_WUState state, int timeout)
-{
-	while (DC_getWUState(wu) != state)
-	{
-		cycle++;
-		process(wu, timeout);
-	}
-}
-
-static void
-proci(DC_Workunit *wu, int nr, int timeout)
-{
-	int j;
-	for (j= 0; j < nr; j++)
-	{
-		cycle++;
-		process(wu, timeout);
-	}
-}
-
-static void
-t(int what)
-{
-	DC_Workunit *wu;
-
-	switch (what)
-	{
-	case 1:
-	{
-		int i= 0;
-		printf("test1: running a short wu\n");
-		wu= create_short();
-		printf("Submitting short...\n");
-		if ((i= DC_submitWU(wu)) != 0)
-			fail("DC_submitWU", i);
-		DC_setMasterCb(result_cb, subresult_cb, message_cb);
-		while (DC_getWUState(wu) != DC_WU_FINISHED)
-		{
-			printf("wu is in state %s\n",
-			       _DC_state_name(DC_getWUState(wu)));
-			printf("Processing events for 1 sec...\n");
-			DC_processMasterEvents(1);
-		}
-		printf("Destroying short...\n");
-		DC_destroyWU(wu);
-		break;
-	}
-	case 2:
-	{
-		int i, j;
-		printf("test2: running a long wu\n");
-		wu= create_long(0);
-		printf("Submitting long...\n");
-		if ((i= DC_submitWU(wu)) != 0)
-			fail("DC_submitWU", i);
-		DC_setMasterCb(result_cb, subresult_cb, message_cb);
-		while (DC_getWUState(wu) != DC_WU_FINISHED)
-		{
-			i++;
-			printf("Processing events for 1 sec...\n");
-			printf("-- %3d\n", i);
-			ls_lR(i);
-			DC_processMasterEvents(1);
-		}
-		printf("wu finished, but checking events for more 5 secs...\n");
-		for (j= 0; j < 5; j++)
-		{
-			i++;
-			printf("-- %3d\n", i);
-			ls_lR(i);
-			DC_processMasterEvents(1);
-		}
-		printf("Destroying long...\n");
-		DC_destroyWU(wu);
-		break;
-	}
-	case 3:
-	{
-		int r;
-		printf("test3: suspend/resume\n");
-		wu= create_long(20);
-		printf("Submitting long...\n");
-		if ((r= DC_submitWU(wu)) != 0)
-			fail("DC_submitWU", r);
-		DC_setMasterCb(result_cb, subresult_cb, message_cb);
-
-		printf("waiting to be running...\n");
-		procs(wu, DC_WU_RUNNING, 1);
-		
-		printf("now running, run a bit...\n");
-		proci(wu, 5, 1);
-
-		printf("Suspending wu...\n");
-		if ((r= DC_suspendWU(wu)) != 0)
-			fail("DC_suspendWU", r);
-
-		printf("waiting to be suspended...\n");
-		procs(wu, DC_WU_SUSPENDED, 1);
-
-		printf("now suspended, wait a bit...\n");
-		proci(wu, 3, 1);
-
-		printf("Resuming wu...\n");
-		if ((r= DC_resumeWU(wu)) != 0)
-			fail("DC_resumeWU", r);
-
-		printf("waiting to be running again...\n");
-		procs(wu, DC_WU_RUNNING, 1);
-		
-		printf("waiting to finish...\n");
-		procs(wu, DC_WU_FINISHED, 1);
-		
-		printf("Destroying long...\n");
-		DC_destroyWU(wu);
-		break;
-	}
-	case 4:
-	{
-		char *s;
-		int r;
-		wu= create_long(20);
-		printf("Ser=\"%s\"\n", s= DC_serializeWU(wu));
-		create_file("serialized_wu.txt", s);
-		free(s);
-		printf("WU serialized\nSubmitting...\n");
-		if ((r= DC_submitWU(wu)) != 0)
-			fail("DC_submitWU", r);
-		DC_setMasterCb(result_cb, subresult_cb, message_cb);
-
-		printf("waiting to be running...\n");
-		procs(wu, DC_WU_RUNNING, 1);
-		/*DC_destroyWU(wu);*/
-		break;
-	}
-	case 5:
-	{
-		char *s= get_file("serialized_wu.txt");
-		int r;
-		wu= DC_deserializeWU(s);
-		free(s);
-		if (!wu)
-		{
-			printf("Deserialization failed\n");
-			break;
-		}
-
-		printf("Submitting deserialized WU...\n");
-		if ((r= DC_submitWU(wu)) != 0)
-			fail("DC_submitWU", r);
-		DC_setMasterCb(result_cb, subresult_cb, message_cb);
-
-		printf("waiting to be running...\n");
-		procs(wu, DC_WU_RUNNING, 1);
-		
-		printf("waiting to finish...\n");
-		procs(wu, DC_WU_FINISHED, 1);
-		
-		printf("Destroying...\n");
-		DC_destroyWU(wu);
-		break;
-	}
-	case 6:
-	{
-		int i, nr= 40;
-		int done= 0;
-		DC_setMasterCb(result_cb, subresult_cb, message_cb);
-		printf("Creating and submitting wus...\n");
-		for (i= 0; i < nr; i++)
-		{
-			wut[i]= create_long(10);
-			DC_submitWU(wut[i]);
-		}
-		while (!done)
-		{
-			done= 1;
-			for (i= 0; i < nr; i++)
-			{
-				printf("waiting to finish %d...\n", i);
-				if (wut[i] &&
-				    DC_getWUState(wut[i]) != DC_WU_FINISHED &&
-				    DC_getWUState(wut[i]) != DC_WU_UNKNOWN)
-				{
-					done= 0;
-					process(wut[i], 1);
-				}
-			}
-		}
-		printf("All WUs finished, processing event for a while...\n");
-		DC_processMasterEvents(10);
-		printf("Destroying all WUs...\n");
-		for (i= 0; i < nr; i++)
-		{
-			printf("%2d\n", i);
-			DC_destroyWU(wut[i]);
-			wut[i]= NULL;
-		}
-		break;
-	}
-	}
-}
-
-
-int
-main(int argc, char *argv[])
-{
-	int i;
-
-	if ((i= DC_initMaster("t.conf")) != 0)
-		fail("DC_initMaster", i);
-
-	if (argc < 2)
-	{
-		printf("Calling all tests...\n");
-		t(1);
-		t(2);
-		t(3);
-		t(4);
-		printf("WU serialized, now wait a bit...\n");
-		sleep(5);
-		printf("Trying to deserialize...\n");
-		t(5);
-	}
-
-	for (i= 1; i < argc; i++)
-	{
-		int l;
-		l= strtol(argv[i], 0, 0);
-		printf("Calling test %d...\n", l);
-		t(l);
-	}
-
-	return 0;
-}
-
-/* Local variables: */
-/* c-file-style: "linux" */
-/* End: */
diff --git a/dcapi/condor/tmpl.txt b/dcapi/condor/tmpl.txt
deleted file mode 100644
index a1f80a7..0000000
--- a/dcapi/condor/tmpl.txt
+++ /dev/null
@@ -1,16 +0,0 @@
-# test template
-# Date: %d
-# WU name: %n
-# WU id: %i
-# WU workdir: %w"
-# Client name: %c
-# Nr of args: %r
-
-Executable = %x
-arguments = %a
-Universe = %u
-output = %o
-error = %e
-log = %l
-Queue
-
diff --git a/dcapi/condor/ts.c b/dcapi/condor/ts.c
deleted file mode 100644
index 4d0ea6a..0000000
--- a/dcapi/condor/ts.c
+++ /dev/null
@@ -1,165 +0,0 @@
-/*
- * condor/ts.c
- *
- * DC-API test application, slave
- *
- * (c) Daniel Drotos, 2006
- */
-
-#include "dc_client.h"
-
-#include <stdio.h>
-#include <ctype.h>
-
-static char infile_logical[]   = "in.txt";
-static char outfile_logical[]  = "out.txt";
-static char ckptfile_logical[] = "ckpt.txt";
-static FILE *infile;
-static FILE *outfile;
-static FILE *ckptfile;
-
-static int frac_input_size;
-static int frac_current_pos = 0;
-
-static void frac_init(void){
-	frac_current_pos = ftell(infile);
-	fseek(infile, 0, SEEK_END);
-	frac_input_size = ftell(infile);
-	fseek(infile, 0, SEEK_SET);
-}
-
-static int do_checkpoint(int frac_current_pos){
-	FILE *ckptfile;
-	char *ckptfile_physical;
-	int retval;
-
-	ckptfile_physical = DC_resolveFileName(DC_FILE_OUT, DC_CHECKPOINT_FILE);
-	ckptfile = fopen(ckptfile_physical, "w");
-	if (ckptfile == NULL){
-		fprintf(stderr, "APP: cannot open checkpoint file for write!!\n");
-		DC_finishClient(6);
-	}
-	fprintf(ckptfile, "%d", frac_current_pos);
-	fclose(ckptfile);
-
-	retval = fflush(outfile);
-	if (retval) {
-		fprintf(stderr, "APP: uppercase flush failed %d\n", retval);
-		DC_finishClient(5);
-	}
-    
-	return 0;
-}
-
-static void init_files(void){
-	int ckpt_position;
-	char *infile_physical;
-	char *outfile_physical;
-	char *ckptfile_physical;
-	const char *outfile_openmode = "w";
-
-	/* Open input file */
-	infile_physical = DC_resolveFileName(DC_FILE_IN, infile_logical);
-	infile = fopen(infile_physical, "rb");
-	if (infile == NULL){
-		fprintf(stderr, "APP: Cannot open input file! Logical name: %s, physical name: %s.\n",
-			infile_logical, infile_physical);
-		DC_finishClient(1);
-	}
-	frac_init();
-
-	/* check ckpt file */
-	ckptfile_physical = DC_resolveFileName(DC_FILE_IN, DC_CHECKPOINT_FILE);
-	ckptfile = fopen(ckptfile_physical, "r");
-	if (ckptfile != NULL){
-		/* ckpt file exists: read and set everything according to it */
-		fscanf(ckptfile, "%d", &ckpt_position);
-		fclose(ckptfile);
-		fprintf(stderr, "APP: Found checkpoint file. Checkpoint position: %d.\n", ckpt_position);
-		fseek(infile, ckpt_position, SEEK_SET);
-		frac_current_pos = ckpt_position;
-		outfile_openmode = "r+";
-	}
-
-	/* open output file */
-	outfile_physical = DC_resolveFileName(DC_FILE_OUT, outfile_logical);
-	outfile = fopen(outfile_physical, outfile_openmode);
-	if (outfile == NULL){
-		fprintf(stderr, "APP: Cannot open output file! Logical name: %s, physical name: %s.\n",
-			outfile_logical, outfile_physical);
-		DC_finishClient(2);
-	}
-	fseek(outfile, frac_current_pos, SEEK_SET);
-}
-
-static void do_work(void){
-	int c;
-	int retval;
-
-	while (1) {
-		c = fgetc(infile);
-
-		if (c == EOF) break;
-		c = toupper(c);
-		fputc(c, outfile);
-		frac_current_pos++;
-
-		//        if (DC_timeToCheckpoint()){
-		if (1){
-			if(do_checkpoint(frac_current_pos)){
-				fprintf(stderr, "APP: uppercase checkpoint failed.\n");
-				DC_finishClient(3);
-			}
-			//          DC_checkpointMade();
-		}
-
-		DC_fractionDone(frac_current_pos/frac_input_size);
-	}
-
-	retval = fflush(outfile);
-	if (retval) {
-		fprintf(stderr, "APP: uppercase flush failed %d\n", retval);
-		DC_finishClient(5);
-	}
-	fclose(outfile);
-}
-
-int main(int argc, char **argv) {
-	int retval = 0;
-
-	retval = DC_initClient();
-	if (retval) {
-		fprintf(stderr, "APP: Error while the initialize. Return value = %d.\n", retval);
-		DC_finishClient(retval);
-	}
-	fprintf(stdout, "APP: Init successful.\n");
-
-	init_files();
-	fprintf(stdout, "APP: Starting from line %d.\n", frac_current_pos+1);
-
-	do_work();
-	fprintf(stdout, "APP: Work finished.\n");
-	fprintf(stderr, "APP: This is only a test error message.\n");
-
-	DC_sendMessage("Client completed. Exiting.");
-
-	DC_finishClient(0);
-	return(0);	// Tho' we never reach this line
-}
-
-
-#ifdef _WIN32
-int WINAPI WinMain(HINSTANCE hInst, HINSTANCE hPrevInst, LPSTR Args, int WinMode) {
-	LPSTR command_line;
-	char* argv[100];
-	int argc;
-
-	command_line = GetCommandLine();
-	argc = parse_command_line( command_line, argv );
-	return main(argc, argv);
-}
-#endif
-
-/* Local variables: */
-/* c-file-style: "linux" */
-/* End: */
diff --git a/dcapi/condor/tss.c b/dcapi/condor/tss.c
deleted file mode 100644
index 32d3cbc..0000000
--- a/dcapi/condor/tss.c
+++ /dev/null
@@ -1,163 +0,0 @@
-/*
- * condor/tss.c
- *
- * DC-API test application, slave
- *
- * (c) Daniel Drotos, 2006
- */
-
-#include <stdio.h>
-#include <unistd.h>
-#include <stdlib.h>
-
-#include "dc_client.h"
-
-#include "tc.h"
-
-
-int cyc= 1;
-int sub= 0;
-int ckp= 0;
-int msg= 0;
-
-static void
-send_subresult(int c)
-{
-	char l[100];
-	char p[100];
-	char s[100];
-
-	printf("cyc=%d Sending subresult...\n", c);
-	sprintf(l, "l_%d", c);
-	sprintf(p, "p_%d", c);
-	sprintf(s, "subresult %d", c);
-	create_file(p, s);
-	DC_sendResult(l, p, DC_FILE_REGULAR);
-}
-
-static void
-mk_checkpoint(int c)
-{
-	char *fn;
-	char buf[100];
-
-	printf("cyc=%d Making checkpoint...\n", c);
-	fn= DC_resolveFileName(DC_FILE_OUT, DC_CHECKPOINT_FILE);
-	if (fn)
-	{
-		sprintf(buf, "%d\n", c);
-		create_file(fn, buf);
-		printf("Checkpoint created in file %s\n", fn);
-		DC_checkpointMade(fn);
-		free(fn);
-	}
-	else
-		printf("Failed\n");
-}
-
-static void
-send_message(int c)
-{
-	char s[100];
-
-	printf("cyc=%d Sending message...\n", c);
-	sprintf(s, "Message=%d, cyc=%d", msg, c);
-	DC_sendMessage(s);
-}
-
-int
-main(int argc, char *argv[])
-{
-	DC_initClient();
-	int i;
-
-	if (argc > 1)
-	{
-		cyc= strtol(argv[1], 0, 0);
-		printf("cyc defined= %d\n", cyc);
-	}
-	if (argc > 2)
-	{
-		sub= strtol(argv[2], 0, 0);
-		printf("sub defined= %d\n", sub);
-	}
-	if (argc > 3)
-	{
-		ckp= strtol(argv[3], 0, 0);
-		printf("ckp defined= %d\n", ckp);
-	}
-	if (argc > 4)
-	{
-		msg= strtol(argv[4], 0, 0);
-		printf("msg defined= %d\n", msg);
-	}
-
-	i= 0;
-	{
-		char *fn= DC_resolveFileName(DC_FILE_IN, DC_CHECKPOINT_FILE);
-		if (fn)
-		{
-			char *s= get_file(fn);
-			printf("Checkpoint file found %s\n", fn);
-			printf("Content: \"%s\"\n", s);
-			i= strtol(s, 0, 0);
-			printf("Continuing from cycle %d\n", i);
-			cyc-= i;
-			free(s);
-			free(fn);
-		}
-		else
-			printf("No checkpoint file found, start from the beginning...\n");
-	}
-	while (cyc)
-	{
-		cyc--;
-		i++;
-		printf("\nCycle %d. starting...\n", i);
-
-		{
-			DC_ClientEvent *e= DC_checkClientEvent();
-			if (e)
-			{
-				switch (e->type)
-				{
-				case DC_CLIENT_CHECKPOINT:
-				{
-					break;
-				}
-				case DC_CLIENT_FINISH:
-				{
-					break;
-				}
-				case DC_CLIENT_MESSAGE:
-				{
-					printf("At cyc=%d got a message: \"%s\"\n", i,
-					       e->message);
-					break;
-				}
-				}
-				DC_destroyClientEvent(e);
-			}
-		}
-		sleep(1);
-
-		if (sub &&
-		    i%sub == 0)
-			send_subresult(i);
-		if (ckp &&
-		    i%ckp == 0)
-			mk_checkpoint(i);
-		if (msg)
-		{
-			send_message(i);
-			msg--;
-		}
-		printf("Done, remaining cycles: %d\n", cyc);
-	}
-
-	DC_finishClient(0);
-}
-
-/* Local variables: */
-/* c-file-style: "linux" */
-/* End: */
diff --git a/dcapi/configure.ac b/dcapi/configure.ac
deleted file mode 100644
index 2f546e4..0000000
--- a/dcapi/configure.ac
+++ /dev/null
@@ -1,154 +0,0 @@
-AC_INIT([Distributed Computing API], [0.11], [desktopgrid at lpds.sztaki.hu], [dcapi])
-AC_CONFIG_MACRO_DIR([cf])
-AC_CONFIG_HEADERS([include/config.h])
-AC_CONFIG_AUX_DIR([scripts])
-AC_CONFIG_SRCDIR([include/dc.h])
-AM_INIT_AUTOMAKE([foreign])
-
-AC_PROG_CC
-AC_PROG_CXX
-AC_PROG_LIBTOOL
-
-LIBTOOL="$LIBTOOL --silent"
-
-dnl Enable useful warnings
-if test "$ac_cv_c_compiler_gnu" = yes; then
-	CFLAGS="-Wall -Wmissing-prototypes -Wstrict-prototypes -Wsign-compare ${CFLAGS}"
-	CXXFLAGS="-Wall -Wsign-compare ${CXXFLAGS}"
-fi
-
-AC_ARG_ENABLE([client],
-	AS_HELP_STRING([--disable-client], [do not build the client application]),,
-	[enable_client=yes])
-AC_ARG_ENABLE([master],
-	AS_HELP_STRING([--disable-master], [do not build the master application]),,
-	[enable_master=yes])
-
-AM_CONDITIONAL([BUILD_CLIENT], [test "$enable_client" = yes])
-AM_CONDITIONAL([BUILD_MASTER], [test "$enable_master" = yes])
-
-dnl glib is used only on the master side
-if test "$enable_master" = yes; then
-	AM_PATH_GLIB_2_0([2.6.0],,[AC_MSG_ERROR([glib2 is missing])])
-fi
-
-GTK_DOC_CHECK([1.3])
-MON_PKG_JAVA
-
-BACKENDS=
-
-dnl ===================================================================
-dnl BOINC backend
-dnl
-
-AC_ARG_ENABLE([backend-boinc],
-	AS_HELP_STRING([--enable-backend-boinc],
-		[enable the BOINC backend @<:@default=yes@:>@]),,
-	[enable_backend_boinc=auto])
-
-if test "$enable_backend_boinc" != no; then
-	SZDG_BOINC_COMMON
-	if test "$enable_master" = yes; then
-		SZDG_BOINC_SERVER
-	fi
-	if test "$enable_client" = yes; then
-		SZDG_BOINC_CLIENT
-		AC_CHECK_HEADERS([uuid/uuid.h],, [no_boinc=yes])
-		AC_CHECK_LIB([uuid], [uuid_unparse_lower], [true], [no_boinc=yes])
-	fi
-	if test "$no_boinc" = yes; then
-		if test "$enable_backend_boinc" = yes; then
-			AC_MSG_ERROR([BOINC development environment was not found])
-		fi
-	else
-		BACKENDS="$BACKENDS boinc"
-	fi
-fi
-
-AM_CONDITIONAL([WITH_BOINC], [echo $BACKENDS | grep -q boinc])
-
-dnl ===================================================================
-dnl Condor backend
-dnl
-
-AC_ARG_ENABLE([backend-condor],
-	AS_HELP_STRING([--enable-backend-condor],
-		[enable the Condor backend @<:@default=no@:>@]),,
-	[enable_backend_condor=auto])
-
-AC_ARG_WITH([condor-headers],
-	AS_HELP_STRING([--with-condor-headers=DIR],
-		[Use condor headers in DIR]), [CONDOR_CPPFLAGS="-I$withval"])
-AC_ARG_WITH([condor-libs],
-	AS_HELP_STRING([--with-condor-libs=DIR],
-		[Use condor libraries in DIR]), [CONDOR_LDFLAGS="-L$withval"])
-AC_SUBST([CONDOR_CPPFLAGS])
-AC_SUBST([CONDOR_LDFLAGS])
-
-no_condor=
-if test "$enable_backend_condor" != no; then
-	AC_LANG_PUSH([C++])
-	save_CPPFLAGS="$CPPFLAGS"
-	CPPFLAGS="$CPPFLAGS $CONDOR_CPPFLAGS"
-	save_LDFLAGS="$LDFLAGS"
-	LDFLAGS="$LDFLAGS $CONDOR_LDFLAGS"
-	AC_CHECK_HEADERS([read_user_log.h],, [no_condor=yes],
-		[AC_INCLUDES_DEFAULT
-#include <time.h>
-])
-	LDFLAGS="$save_LDFLAGS"
-	CPPFLAGS="$save_CPPFLAGS"
-	AC_LANG_POP([C++])
-
-	if test "$no_condor" = yes; then
-		if test "$enable_backend_condor" = yes; then
-			AC_MSG_ERROR([Condor development environment is missing])
-		fi
-	else
-		BACKENDS="$BACKENDS condor"
-	fi
-fi
-
-AM_CONDITIONAL([WITH_CONDOR], [echo $BACKENDS | grep -q condor])
-
-dnl ===================================================================
-dnl Local backend
-dnl
-
-AC_ARG_ENABLE([backend-local],
-	AS_HELP_STRING([--enable-backend-local],
-		[enable the local backend @<:@default=yes@:>@]),,
-	[enable_backend_local=yes])
-
-if test "$enable_backend_local" = yes; then
-	BACKENDS="$BACKENDS local"
-fi
-
-AM_CONDITIONAL([WITH_LOCAL], [test "$enable_backend_local" == yes])
-
-dnl ===================================================================
-dnl Generate output files
-dnl
-
-echo ""
-echo "Enabled backends: $BACKENDS"
-echo "Build master: $enable_master"
-echo "Build client: $enable_client"
-echo ""
-
-AC_CONFIG_FILES([Makefile \
-	include/Makefile \
-	common/Makefile \
-	boinc/Makefile \
-	boinc/dcapi-boinc-client.pc \
-	boinc/dcapi-boinc-master.pc \
-	condor/Makefile \
-	condor/dcapi-condor-client.pc \
-	condor/dcapi-condor-master.pc \
-	local/Makefile \
-	local/dcapi-local-client.pc \
-	local/dcapi-local-master.pc \
-	java/Makefile \
-	java/hu/sztaki/lpds/dc/client/Version.java \
-	doc/Makefile])
-AC_OUTPUT
diff --git a/dcapi/dcapi-deploy b/dcapi/dcapi-deploy
deleted file mode 100755
index aa577bb..0000000
--- a/dcapi/dcapi-deploy
+++ /dev/null
@@ -1,166 +0,0 @@
-#! /usr/bin/env python
-
-"""
-DC-API deployement script
-"""
-
-import os, re, shutil, tempfile, uuid
-from optparse import OptionParser
-from ConfigParser import RawConfigParser
-
-class Replacement:
-    def __init__(self, name, value):
-        self.name = name
-        self.value = value
-        self.re = re.compile("\s*" + name + "\s*=")
-        self.found = False
-    
-    def subst(self, string):
-        if self.re.match(string):
-            self.found = True
-            pos = string.find('=')
-            return string[:pos] + "= " + self.value + "\n"
-        else:
-            return string
-
-def modify_config(values, section = "Master"):
-    """Modify the DC-API configuration. We can't use the write() method of
-    RawConfigParser() since that does not preserve comments."""
-
-    subst = []
-    for k, v in values.iteritems():
-        r = Replacement(k, v)
-        subst.append(r)
-
-    input = open(options.config, "r")
-    input_lines = input.readlines()
-    input.close()
-
-    output_lines = []
-    section_found = False
-    section_match = re.compile("[[]" + section + "[]]")
-    other_section = re.compile("[[]")
-
-    for line in input_lines:
-        if not section_found:
-            if section_match.match(line):
-                section_found = True
-            output_lines.append(line)
-        else:
-            if other_section.match(line):
-                section_found = False
-                for s in subst:
-                    if s.found:
-                        continue
-                    output_lines.append(s.name + " = " + s.value + "\n")
-            for s in subst:
-                line = s.subst(line)
-            output_lines.append(line)
-
-    handle, name = tempfile.mkstemp(prefix = ".dcapi.", dir =
-                                    os.path.dirname(options.config))
-    try:
-        output = os.fdopen(handle, "w")
-        output.writelines(output_lines)
-        output.close()
-        shutil.copymode(options.config, name)
-        os.rename(name, options.config)
-    except:
-        os.unlink(name)
-        raise
-
-def deploy():
-    if not backend:
-        parser.error("The backend must be specified")
-
-    defaults = backend.master_defaults()
-    defaults["InstanceUUID"] = str(uuid.uuid4())
-    defaults["WorkingDirectory"] = options.workdir
-
-    modify_config(defaults)
-
-def check():
-    if not backend:
-        parser.error("The backend must be specified")
-
-    config = RawConfigParser()
-    config.readfp(open(options.config))
-
-    if not config.has_section('Master'):
-        raise SystemExit("The [Master] section is missing")
-
-    # The [Master] section may contain either master keys or defaults for client
-    # keys
-    keys = config.options('Master')
-    seen = dict([(x, False) for x in keys])
-    for name, required in backend.get_master_keys():
-        name = name.lower()
-        if name in seen:
-            seen[name] = True
-        elif required:
-            raise SystemExit("Required option '" + name + "' is missing in the [Master] section")
-    for name, required in backend.get_client_keys():
-        name = name.lower()
-        if name in seen:
-            seen[name] = True
-
-    for name, found in seen.iteritems():
-        if not found:
-            print "Option '" + name + "' in the [Master] section seems unused"
-
-    # Now check the client sections
-    for section in config.sections():
-        if section == "Master":
-            continue
-        if not section.startswith("Client-"):
-            print "Unexpected section name: " + section
-            continue
-
-        keys = config.options(section)
-        seen = dict([(x, False) for x in keys])
-        for name, required in backend.get_client_keys():
-            name = name.lower()
-            if name in seen:
-                seen[name] = True
-            elif required:
-                if not config.has_option("Master", name):
-                    raise SystemExit("Required option '" + name + "' is missing "
-                                     "in the [" + section + "] section")
-        for name, found in seen.iteritems():
-            if not found:
-                print "Option '" + name + "' in the [" + section + "] section seems unused"
-
-command_table = {'deploy': deploy,
-                 'check' : check}
-
-parser = OptionParser(usage = "%prog [options] <command>")
-parser.add_option("--config", "-c",
-                  metavar = "FILE",
-                  help = "specify the location of the config file. The default "
-                         "is dc-api.conf in the current directory")
-parser.add_option("--backend", "-b",
-                  metavar = "NAME",
-                  help = "the backend implementation to use")
-parser.add_option("--workdir", "-w",
-                  metavar = "NAME",
-                  help = "the work directory of DC-API. Defaults to the "
-                         "directory where the config file lives")
-options, args = parser.parse_args()
-if len(args) != 1:
-    parser.error("Wrong number of arguments")
-if not args[0] in command_table:
-    parser.error("Unknown command " + args[0])
-if options.backend is None:
-    parser.error("The backend name must be specified")
-
-if options.config is None:
-    options.config = "dc-api.conf"
-if options.workdir is None:
-    options.workdir = os.path.dirname(os.path.abspath(options.config))
-
-# Load the backend module
-module = __import__("DCAPI." + options.backend)
-cl = getattr(module, options.backend + "_Backend")
-backend = getattr(cl, options.backend + "_Backend")()
-
-command_table[args[0]]()
diff --git a/dcapi/dcapi.m4 b/dcapi/dcapi.m4
deleted file mode 100644
index bae9c6d..0000000
--- a/dcapi/dcapi.m4
+++ /dev/null
@@ -1,109 +0,0 @@
-dnl
-dnl SZDG_DCAPI
-dnl
-dnl Check for the Distributed Computing Platform development files
-dnl
-
-AC_DEFUN([_SZDG_DCAPI_COMMON], [
-	AC_ARG_WITH([dcapi_flavor], AS_HELP_STRING([--with-dcapi-flavor],
-		[DCAPI flavor to use @<:@boinc@:>@]),,
-		[with_dcapi_flavor=boinc])
-	PKG_PROG_PKG_CONFIG([0.17])
-])
-
-dnl
-dnl Check for DC-API client libraries.
-dnl
-dnl Usage: SZDG_DCAPI_CLIENT([ACTION-IF-FOIND], [ACTION-IF-NOT-FOUND])
-dnl
-AC_DEFUN([SZDG_DCAPI_CLIENT], [
-	AC_REQUIRE([_SZDG_DCAPI_COMMON])
-
-	DCAPI_CLIENT_LIBS=
-	DCAPI_CLIENT_CFLAGS=
-
-	AC_MSG_CHECKING([for DCAPI_CLIENT])
-	PKG_CHECK_EXISTS([dcapi-${with_dcapi_flavor}-client],
-		[dcapi_client=yes],
-		[dcapi_client=no])
-	AC_MSG_RESULT([$dcapi_client])
-	if test "$dcapi_client" != no; then
-		DCAPI_CLIENT_LIBS=`pkg-config --libs --static dcapi-${with_dcapi_flavor}-client`
-		DCAPI_CLIENT_CPPFLAGS=`pkg-config --cflags dcapi-${with_dcapi_flavor}-client`
-
-		DCAPI_CLIENT_LIBS="-Wl,-Bstatic $DCAPI_CLIENT_LIBS -Wl,-Bdynamic"
-
-		save_CPPFLAGS="$CPPFLAGS"
-		CPPFLAGS="$CPPFLAGS $DCAPI_CLIENT_CFLAGS"
-		save_LIBS="$LIBS"
-		LIBS="$LIBS $DCAPI_CLIENT_LIBS"
-		AC_LANG_PUSH([C])
-		AC_CHECK_HEADERS([dc_client.h], [], [dcapi_client=no])
-		AC_LINK_IFELSE([AC_LANG_PROGRAM([[#include <dc_client.h>]],
-			[[(void)DC_initClient()]])],
-			[true],
-			[dcapi_client=no])
-		AC_LANG_POP([C])
-		CPPFLAGS="$save_CPPFLAGS"
-		LIBS="$save_LIBS"
-	fi
-
-	AC_SUBST([DCAPI_CLIENT_LIBS])
-	AC_SUBST([DCAPI_CLIENT_CFLAGS])
-
-	dnl Backward compatibility: produce an error if the above tests fail
-	dnl and both $1 and $2 are empty
-	m4_ifval(m4_normalize[$1], [], [m4_ifvaln(m4_normalize[$2], [],
-	if test "$dcapi_client" != yes; then
-		AC_MSG_ERROR([DC-API client libraries were not found])
-	fi)])dnl
-
-	if test "$dcapi_client" = yes; then
-		m4_ifval(m4_normalize[$1], [$1], [:])
-	m4_ifvaln([$2],[else
-		$2])dnl
-	fi
-])
-
-dnl
-dnl Check for DC-API master libraries.
-dnl
-dnl Usage: SZDG_DCAPI_MASTER([ACTION-IF-FOIND], [ACTION-IF-NOT-FOUND])
-dnl
-AC_DEFUN([SZDG_DCAPI_MASTER], [
-	AC_REQUIRE([_SZDG_DCAPI_COMMON])
-
-	PKG_CHECK_MODULES([DCAPI_MASTER],
-		[dcapi-${with_dcapi_flavor}-master],
-		[dcapi_master=yes],
-		[dcapi_master=no])
-
-	if test "$dcapi_master" != no; then
-		save_CPPFLAGS="$CPPFLAGS"
-		CPPFLAGS="$CPPFLAGS $DCAPI_MASTER_CFLAGS"
-		save_LIBS="$LIBS"
-		LIBS="$LIBS $DCAPI_MASTER_LIBS"
-		AC_LANG_PUSH([C])
-		AC_CHECK_HEADERS([dc.h], [], [dcapi_master=no])
-		AC_LINK_IFELSE([AC_LANG_PROGRAM([[#include <dc.h>]],
-			[[(void)DC_initMaster((char *)0)]])],
-			[true],
-			[dcapi_master=no])
-		AC_LANG_POP([C])
-		CPPFLAGS="$save_CPPFLAGS"
-		LIBS="$save_LIBS"
-	fi
-
-	dnl Backward compatibility: produce an error if the above tests fail
-	dnl and both $1 and $2 are empty
-	m4_ifval(m4_normalize[$1], [], [m4_ifvaln(m4_normalize[$2], [],
-	if test "$dcapi_master" != yes; then
-		AC_MSG_ERROR([DC-API master libraries were not found])
-	fi)])dnl
-
-	if test "$dcapi_master" = yes; then
-		m4_ifval(m4_normalize[$1], [$1], [:])
-	m4_ifvaln([$2],[else
-		$2])dnl
-	fi
-])
diff --git a/dcapi/doc/Makefile.am b/dcapi/doc/Makefile.am
deleted file mode 100644
index 7a730eb..0000000
--- a/dcapi/doc/Makefile.am
+++ /dev/null
@@ -1,106 +0,0 @@
-## Process this file with automake to produce Makefile.in
-
-# We require automake 1.6 at least.
-AUTOMAKE_OPTIONS = 1.6
-
-# This is a blank Makefile.am for using gtk-doc.
-# Copy this to your project's API docs directory and modify the variables to
-# suit your project. See the GTK+ Makefiles in gtk+/docs/reference for examples
-# of using the various options.
-
-# The name of the module, e.g. 'glib'.
-DOC_MODULE=dc-api
-
-# The top-level SGML file. You can change this if you want to.
-DOC_MAIN_SGML_FILE=$(DOC_MODULE)-docs.xml
-
-# The directory containing the source code. Relative to $(srcdir).
-# gtk-doc will search all .c & .h files beneath here for inline comments
-# documenting the functions and macros.
-# e.g. DOC_SOURCE_DIR=../../../gtk
-DOC_SOURCE_DIR=../include
-
-# Extra options to pass to gtkdoc-scangobj. Not normally needed.
-SCANGOBJ_OPTIONS=
-
-# Extra options to supply to gtkdoc-scan.
-# e.g. SCAN_OPTIONS=--deprecated-guards="GTK_DISABLE_DEPRECATED" 
-SCAN_OPTIONS=
-
-# Extra options to supply to gtkdoc-mkdb.
-# e.g. MKDB_OPTIONS=--sgml-mode --output-format=xml
-MKDB_OPTIONS=--sgml-mode --output-format=xml
-
-# Extra options to supply to gtkdoc-mktmpl
-# e.g. MKTMPL_OPTIONS=--only-section-tmpl
-MKTMPL_OPTIONS=
-
-# Extra options to supply to gtkdoc-fixref. Not normally needed.
-# e.g. FIXXREF_OPTIONS=--extra-dir=../gdk-pixbuf/html --extra-dir=../gdk/html
-FIXXREF_OPTIONS=
-
-# Used for dependencies. The docs will be rebuilt if any of these change.
-# e.g. HFILE_GLOB=$(top_srcdir)/gtk/*.h
-# e.g. CFILE_GLOB=$(top_srcdir)/gtk/*.c
-HFILE_GLOB=../include/*.h
-CFILE_GLOB=
-
-# Header files to ignore when scanning.
-# e.g. IGNORE_HFILES=gtkdebug.h gtkintl.h
-IGNORE_HFILES=config.h dc_internal.h dc_win32.h
-
-# Images to copy into HTML directory.
-# e.g. HTML_IMAGES=$(top_srcdir)/gtk/stock-icons/stock_about_24.png
-HTML_IMAGES=
-
-# Extra SGML files that are included by $(DOC_MAIN_SGML_FILE).
-# e.g. content_files=running.sgml building.sgml changes-2.0.sgml
-content_files = \
-		boinc.xml \
-		condor.xml \
-		concepts.xml \
-		config.xml \
-		intro.xml \
-		using.xml \
-		windows.xml \
-		local.xml
-
-# SGML files where gtk-doc abbrevations (#GtkWidget) are expanded
-# These files must be listed here *and* in content_files
-# e.g. expand_content_files=running.sgml
-expand_content_files=
-
-# CFLAGS and LDFLAGS for compiling gtkdoc-scangobj with your library.
-# Only needed if you are using gtkdoc-scangobj to dynamically query widget
-# signals and properties.
-# e.g. INCLUDES=-I$(top_srcdir) -I$(top_builddir) $(GTK_DEBUG_FLAGS)
-# e.g. GTKDOC_LIBS=$(top_builddir)/gtk/$(gtktargetlib)
-INCLUDES=
-GTKDOC_LIBS=
-
-# This includes the standard gtk-doc make rules, copied by gtkdocize.
-include $(top_srcdir)/gtk-doc.make
-
-# Other files to distribute
-# e.g. EXTRA_DIST += version.xml.in
-EXTRA_DIST += 
-
-CLEANFILES += $(DOC_MODULE)-docs.pdf \
-		$(DOC_MODULE)-docs.odf \
-		$(DOC_MODULE)-docs-combined.xml
-
-# Additional formats
-$(DOC_MODULE)-docs.tex: html-build.stamp customize.xsl
-	dblatex -t tex -p customize.xsl $(DOC_MODULE)-docs.xml
-
-$(DOC_MODULE)-docs.pdf: $(DOC_MODULE)-docs.tex
-	rubber --pdf $(DOC_MODULE)-docs
-
-$(DOC_MODULE)-docs-combined.xml: $(DOC_MODULE)-docs.xml
-	xmllint --xinclude $< > $@
-
-$(DOC_MODULE)-docs.odf: $(DOC_MODULE)-docs-combined.xml
-	docbook2odf --output-file $@ $<
-
-clean-local:
-	-test -e $(DOC_MODULE)-docs.tex && (rubber --clean --pdf $(DOC_MODULE)-docs.tex; rm -f $(DOC_MODULE)-docs.tex)
diff --git a/dcapi/doc/boinc.xml b/dcapi/doc/boinc.xml
deleted file mode 100644
index aa03535..0000000
--- a/dcapi/doc/boinc.xml
+++ /dev/null
@@ -1,728 +0,0 @@
-<?xml version="1.0"?>
-<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.1.2//EN" 
-               "http://www.oasis-open.org/docbook/xml/4.1.2/docbookx.dtd">
-<sect1 id="boinc">
-  <title>BOINC</title>
-
-  <sect2>
-    <title>Terminology</title>
-
-    <para>
-      The term <emphasis>workunit</emphasis> means approximately the same thing
-      for DC-API as for BOINC.
-    </para>
-
-    <para>
-      Both the DC-API and BOINC uses the term <emphasis>result</emphasis>, but
-      they mean different things. In BOINC, results are instances of a work
-      unit waiting to be downloaded or currently under execution. The DC-API
-      result is what BOINC calls the <emphasis>canonical result</emphasis>.
-      This means that when BOINC generates multiple results (e.g. for
-      redundant computation), the DC-API will not be notified about the status
-      of individual BOINC results; instead, it will be notified only if the
-      canonical result is found or the whole work unit is marked as failed by
-      BOINC.
-    </para>
-
-    <para>
-      In the following sections, <emphasis>result</emphasis> will mean the
-      DC-API term, while <emphasis>BOINC result</emphasis> will refer to the
-      BOINC definition.
-    </para>
-
-    <para>
-      The DC-API master application is an <emphasis>assimilator</emphasis> in
-      BOINC terms.
-    </para>
-
-  </sect2>
-
-  <sect2>
-    <title>Configuration options</title>
-
-    <sect3>
-      <title>Master side</title>
-
-      <para>
-	<warning>
-	  <para>
-	    Important note: the directories specified by
-	    <literal>WorkingDirectory</literal>,
-	    <literal>ProjectRootDir</literal> and the upload & download
-	    directories specified in BOINC's <filename>config.xml</filename>
-	    must all reside on the same filesystem since the DC-API uses the
-	    <function>link()</function> and <function>rename()</function> system
-	    calls.
-	  </para>
-	</warning>
-      </para>
-
-      <variablelist>
-	<varlistentry>
-	  <term>InstanceUUID</term>
-	  <listitem>
-	    <para>
-	      REQUIRED. The value must be a Universally Unique Identifier. The
-	      value must be unique for every master application running on the
-	      same grid backend. If two master applications are started with the
-	      same <literal>InstanceUUID</literal> value, their behaviour is
-	      undefined.
-	    </para>
-	  </listitem>
-	</varlistentry>
-	<varlistentry>
-	  <term>ProjectRootDir</term>
-	  <listitem>
-	    <para>
-	      OPTIONAL. The location of the project's root directory.
-	      This is the directory that contains
-	      <filename>config.xml</filename> and other BOINC-related
-	      subdirectories.
-	    </para>
-	  </listitem>
-	</varlistentry>
-	<varlistentry>
-	  <term>UploadURL</term>
-	  <listitem>
-	    <para>
-	      OPTIONAL. The upload handler's URL to send output files of
-	      processed BOINC workunits to.
-	    </para>
-	  </listitem>
-	</varlistentry>
-	<varlistentry>
-	  <term>InputURLRewriteRegExpMatch</term>
-	  <listitem>
-	    <para>
-	      OPTIONAL. This variable along with the <literal>InputURLRewriteRegExpReplace</literal>
-	      varaible can be used to rewrite input file URLs based on regular expressions. The
-	      variable <literal>InputURLRewriteRegExpMatch</literal> defines the match part of the
-	      regular expression, whereas the varibale <literal>InputURLRewriteRegExpReplace</literal>
-	      defines the replacement part of the regular expression. An example value of this variable
-	      is <literal>attic://([^/]*).*/([^/]*)$</literal>.
-	    </para>
-	  </listitem>
-	</varlistentry>
-	<varlistentry>
-	  <term>InputURLRewriteRegExpReplace</term>
-	  <listitem>
-	    <para>
-	      OPTIONAL. This variable along with the <literal>InputURLRewriteRegExpMatch</literal>
-	      varaible can be used to rewrite input file URLs based on regular expressions. The
-	      variable <literal>InputURLRewriteRegExpReplace</literal> defines the replace part of the
-	      regular expression, whereas the varibale <literal>InputURLRewriteRegExpMatch</literal>
-	      defines the match part of the regular expression. An example value of this variable
-	      is <literal>http://\1/dl/redir/\2\nhttp://localhost:12345/data/\2</literal>.
-	    </para>
-	  </listitem>
-	</varlistentry>
-      </variablelist>
-    </sect3>
-
-    <sect3>
-      <title>Per-client configuration</title>
-
-      <variablelist>
-	<varlistentry>
-	  <term>Redundancy</term>
-	  <listitem>
-            <anchor id="DC-API-Boinc-Redundancy"/>
-	    <para>
-	      OPTIONAL. Integer value specifying the quorum required to consider
-	      the work unit as valid. The default value is 1. If this value is N,
-
-	      <itemizedlist>
-		<listitem>
-		  <para>
-		    N + log(N) initial BOINC results will be created. If one of
-		    them finishes, a new one will be created automatically until
-		    the work unit either succeeds or fails.
-		  </para>
-		</listitem>
-		<listitem>
-		  <para>
-		    The work unit will be considered failed if more than N +
-		    log(N + 2) + 1 BOINC results fail.
-		  </para>
-		</listitem>
-		<listitem>
-		  <para>
-		    The work unit will be considered failed if there are N +
-		    log(N + 2) + 1 successful results but the validator could
-		    not find a canonical result.
-		  </para>
-		</listitem>
-		<listitem>
-		  <para>
-		    The work unit will be considered failed if the state of the
-		    work unit is still not decided after 2 * (N + log(N + 2))
-		    BOINC results have been received.
-		  </para>
-		</listitem>
-	      </itemizedlist>
-	      <note>
-		<para>
-		  When the redundancy is greater than 1, the work unit can not
-		  be suspended using <function><link
-		      linkend="DC-suspendWU">DC_suspendWU()</link></function>.
-		
-		  In the following the options are listed which allow fine tuning 
-		  redundancy. These options are mutually exclusive with <function><link
-	      linkend="DC-API-Boinc-Redundancy">Redundancy</link></function>.
-		</para>
-	      </note>
-	    </para>
-	  </listitem>
-	</varlistentry>
-	<varlistentry>
-	  <term>MinQuorum</term>
-	  <listitem>
-	    <para>
-		 OPTIONAL. Integer value specifying the quorum required to consider
-		 the work unit as valid. The default value is 1.
-		</para>
-		<note>
-		 <para>
-			This option is mutually exclusive with <function><link
-		      linkend="DC-API-Boinc-Redundancy">Redundancy</link></function>. 
-			<literal>MinQuorum</literal>, <literal>TargetNResults</literal>, 
-			<literal>MaxErrorResults</literal> and <literal>MaxTotalResults</literal> 
-			should be used combined.
-		 </para>
-		</note>
-	  </listitem>
-	</varlistentry>
-	<varlistentry>
-	  <term>TargetNResults</term>
-	  <listitem>
-	    <para>
-		 OPTIONAL. Integer value specifying the number of initial BOINC results to be 
-		 created. The default value is <literal>MinQuorum</literal>.
-		</para>
-		<note>
-		 <para>
-			This option is mutually exclusive with <function><link
-		      linkend="DC-API-Boinc-Redundancy">Redundancy</link></function>. 
-			<literal>MinQuorum</literal>, <literal>TargetNResults</literal>, 
-			<literal>MaxErrorResults</literal> and <literal>MaxTotalResults</literal> 
-			should be used combined.
-		 </para>
-		</note>
-	  </listitem>
-	</varlistentry>
-	<varlistentry>
-	  <term>MaxErrorResults</term>
-	  <listitem>
-	    <para>
-		 OPTIONAL. Integer value specifying the maximum number of failed BOINC results 
-		 for a work unit. The default value is 0.
-		</para>
-		<note>
-		 <para>
-			This option is mutually exclusive with <function><link
-		      linkend="DC-API-Boinc-Redundancy">Redundancy</link></function>. 
-			<literal>MinQuorum</literal>, <literal>TargetNResults</literal>, 
-			<literal>MaxErrorResults</literal> and <literal>MaxTotalResults</literal> 
-			should be used combined.
-		 </para>
-		</note>
-	  </listitem>
-	</varlistentry>
-	<varlistentry>
-	  <term>MaxTotalResults</term>
-	  <listitem>
-	    <para>
-		 OPTIONAL. Integer value specifying the total number of BOINC results for a 
-		 work unit. The default value is <literal>MinQuorum</literal>.
-		</para>
-		<note>
-		 <para>
-			This option is mutually exclusive with <function><link
-		      linkend="DC-API-Boinc-Redundancy">Redundancy</link></function>. 
-			<literal>MinQuorum</literal>, <literal>TargetNResults</literal>, 
-			<literal>MaxErrorResults</literal> and <literal>MaxTotalResults</literal> 
-			should be used combined.
-		 </para>
-		</note>
-	  </listitem>
-	</varlistentry>
-	<varlistentry>
-	  <term>MaxSuccessResults</term>
-	  <listitem>
-	    <para>
-		 OPTIONAL. Integer value specifying the maximum number of successful BOINC results 
-		 for a work unit. The default value is <literal>MinQuorum</literal>.
-		</para>
-		<note>
-		 <para>
-			This option is mutually exclusive with <function><link
-		      linkend="DC-API-Boinc-Redundancy">Redundancy</link></function>. 
-			<literal>MinQuorum</literal>, <literal>TargetNResults</literal>, 
-			<literal>MaxErrorResults</literal> and <literal>MaxTotalResults</literal> 
-			should be used combined.
-		 </para>
-		</note>
-	  </listitem>
-	</varlistentry>
-	<varlistentry>
-	  <term>MaxOutputSize</term>
-	  <listitem>
-	    <para>
-	      OPTIONAL. Max. size of any output files the client application
-	      generates.  The default is 256 KiB. If the size of an output file
-	      exceeds this value, the BOINC core client will not upload that
-	      file and will report the BOINC result as failed.
-	    </para>
-	  </listitem>
-	</varlistentry>
-	<varlistentry>
-	  <term>MaxMemUsage</term>
-	  <listitem>
-	    <para>
-	      OPTIONAL. Max. memory usage of the client application. The default
-	      is 128 MiB. Hosts with less available memory will not download
-	      work units for this application. Also, if the applications's real
-	      memory usage exceeds this limit, the BOINC core client aborts the
-	      application and reports the BOINC result as failed.
-	    </para>
-	  </listitem>
-	</varlistentry>
-	<varlistentry>
-	  <term>MaxDiskUsage</term>
-	  <listitem>
-	    <para>
-	      OPTIONAL. Max. disk usage of the client application, including all
-	      output and temporary files. The default is 64 MiB. Hosts with less
-	      usable disk space will not download work units for this
-	      application.  Also, if the application's disk usage exceeds this
-	      limit, the BOINC core client aborts the apllication and reports
-	      the BOINC result as failed.
-	    </para>
-	  </listitem>
-	</varlistentry>
-	<varlistentry>
-	  <term>EstimatedFPOps</term>
-	  <listitem>
-	    <para>
-	      OPTIONAL. The estimated run-time of the client application,
-	      expressed in the number of floating point operations. The default
-	      is 10<superscript>13</superscript>. This value is used by the
-	      BOINC server to decide whether a given host is eligible to run a
-	      work unit and is also used by the BOINC core client for scheduling
-	      decisions.
-	    </para>
-	  </listitem>
-	</varlistentry>
-	<varlistentry>
-	  <term>MaxFPOps</term>
-	  <listitem>
-	    <para>
-	      OPTIONAL. Max. CPU usage of the client application, expressed in
-	      the number of floating point operations. The default is
-	      10<superscript>15</superscript>. If the application uses more CPU
-	      time than this value divided by the CPU's speed, then the BOINC
-	      core client aborts the application and reports the BOINC result as
-	      failed.
-	    </para>
-	    <note>
-	      <para>
-		As per recommendations in the BOINC documentation, the value of
-		<literal>MaxFPOps</literal> should be several times larger than
-		the expected run time of a work unit on an avarage host.
-	      </para>
-	    </note>
-	  </listitem>
-	</varlistentry>
-	<varlistentry>
-	  <term>DelayBound</term>
-	  <listitem>
-	    <para>
-	      Time in seconds the BOINC server waits for a result to finish. If
-	      a client has donwloaded a BOINC result and did not finish in the
-	      given time, the result is considered failed and a new one is
-	      generated.
-	    </para>
-	    <note>
-	      <para>
-		If <literal>DelayBound</literal> is smaller than the estimated
-		run time of the application on a given host (calculated by
-		dividing <literal>EstimatedFPOps</literal> by the host's speed),
-		then the BOINC result will not be offered for download. If no
-		host is fast enough to complete the application within the
-		specified time limit, the result will remain unsent for an
-		unspecified amount of time and DC-API will receive no feedback
-		for it.
-	      </para>
-	    </note>
-	  </listitem>
-	</varlistentry>
-	<varlistentry>
-	  <term>EnableSuspend</term>
-	  <listitem>
-	    <para>
-	      OPTIONAL. Boolean value telling if work units for this client can
-	      be suspended using <function><link
-		  linkend="DC-suspendWU">DC_suspendWU()</link></function> or
-	      not. The default value is false.
-	      <note>
-		<para>
-		  When the redundancy is greater than 1, the work unit can not
-		  be suspended using <function><link
-		      linkend="DC-suspendWU">DC_suspendWU()</link></function>,
-		  regardless of the value of this configuration option.
-		</para>
-	      </note>
-	    </para>
-	  </listitem>
-	</varlistentry>
-	<varlistentry>
-	  <term>NativeClient</term>
-	  <listitem>
-	    <para>
-	      OPTIONAL. Boolean value telling if the client application uses the
-	      native BOINC API instead of DC-API. This will prevent adding
-	      DC-API specific input and output files to the workunit
-	      description.
-	    </para>
-	  </listitem>
-	</varlistentry>
-      </variablelist>
-    </sect3>
-
-    <sect3>
-      <title><anchor id="Boinc-Config"/>Considerations for BOINC configuration</title>
-
-      <para>
-	If you want to use master-to-client messaging, you must enable it in the
-	BOINC project's configuration by making sure that the
-	<literal><msg_to_host/></literal> tag is present in
-	<filename>config.xml</filename>. Client-to-master messaging is always
-	enabled and does not require configuration.
-      </para>
-    </sect3>
-
-  </sect2>
-
-  <sect2>
-    <title>Backend-specific issues</title>
-
-    <sect3>
-      <title>Deploying the application</title>
-
-      <para>
-	Deploying the application consists of two steps: registering the client
-	application(s) in the BOINC database, and running the master daemon.
-      </para>
-      <para>
-	All client applications should be compiled for every platform you need,
-	and installed under the project's <filename>apps</filename> directory.
-	The BOINC name of the client application must be the same as the master
-	uses when it calls <function><link
-	    linkend="DC-createWU">DC_createWU()</link></function>. See the BOINC
-	documentation about how the client binaries should be named and placed
-	and how they should be registered in the database.
-      </para>
-      <para>
-	The most common method of deploying the master application is to run it
-	as a BOINC daemon by adding it to BOINC's
-	<filename>config.xml</filename>. See the BOINC documentation for
-	details. Other methods of deploying the master application depending on
-	how it was designed are also possible, but the following rules must be
-	fulfilled:
-	<itemizedlist>
-	  <listitem>
-	    <para>
-	      The master application must have access to the BOINC project's
-	      <filename>config.xml</filename>
-	    </para>
-	  </listitem>
-	  <listitem>
-	    <para>
-	      The BOINC <application>file_deleter</application> process must
-	      have enough privileges to be able to remove files and directories
-	      created by the master application. If the master runs under the
-	      same user account as the BOINC daemons, this is usually not a
-	      problem.
-	    </para>
-	  </listitem>
-	  <listitem>
-	    <para>
-	      The master application must be able to create files and
-	      directories under the project's <filename>download</filename>
-	      directory, and it must be able to access files under the project's
-	      <filename>upload</filename> directory.
-	    </para>
-	  </listitem>
-	</itemizedlist>
-      </para>
-
-      <!-- XXX Update when the validator API is added -->
-      <para>
-	Besides the master and client applications, you must also define a
-	validator for the application in <filename>config.xml</filename>. If you
-	are not using redundancy then you may use the
-	<filename>sample_trivial_validator</filename> that comes with BOINC.
-	This validator accepts everything without checking.
-      </para>
-      <para>
-	If redundancy is desired, you may use the
-	<application>validator_for_dcapi</application> validator which does a
-	textual (meaning converting between UNIX and Windows line endings)
-	comparison of the first output file.
-      </para>
-      <warning>
-	<para>
-	  If you are running multiple master applications under the same BOINC
-	  project, and you want to use
-	  <filename>sample_trivial_validator</filename> for any of them, then
-	  you must use it for all of them. This restricition exists for any
-	  other validator that is not DC-API aware, since it can not determine
-	  which work unit belongs to which master and therefore which results
-	  should it validate and which ones should it leave alone.
-	</para>
-      </warning>
-    </sect3>
-
-    <sect3>
-      <title>Redundant computation</title>
-
-      <para>
-	Redundancy is very important if you are running computations on
-	untrusted clients instead but may even be useful on dedicated clients to
-	protect from hardware failures. Besides deliberate tampering with the
-	output, clients may also produce incorrect results due to hardware
-	problems like bad memory, overheating or faulty CPU or simply disk
-	corruption.
-      </para>
-      <para>
-	Redundant computing means sending the same work unit to multiple
-	different clients and comparing the results. The comparison is performed
-	by a tool BOINC calls <emphasis>validator</emphasis>. The validator
-	usually is application-specific as it must understand the output file
-	format to filter out unimportant noise (like different line endings on
-	different operating systems, or small differences between floating point
-	results due to the different rounding characteristics of different CPU
-	architectures).
-      </para>
-      <para>
-	Redundancy can be enabled in DC-API on a per client application basis by
-	adding the appropriate <link
-	  linkend="DC-API-Boinc-Redundancy"><literal>Redundancy</literal></link>
-	value to the client's configuration group.
-      </para>
-      <para>
-	If redundancy is enabled for a client application, work units for that
-	client can not be suspended. The reason that it is generally impossible
-	to compare the state of two BOINC results suspended at two different
-	stage of their execution. If one of the suspended results is already
-	corrupt and is restarted, the validator will no longer recognize the
-	corruption since all new results starting from the corrupted initial
-	state will produce the same but bad output.
-      </para>
-
-    </sect3>
-
-    <sect3>
-      <title>Messaging</title>
-
-      <para>
-	BOINC provides a limited messaging support that is accessible thru the
-	DC-API <function><link
-	    linkend="DC-sendWUMessage">DC_sendWUMessage()</link></function> and
-	<function><link
-	    linkend="DC-sendMessage">DC_sendMessage()</link></function>
-	functions on the master and client side, respectively.
-	<note>
-	  <para>
-	    See the note about <link linkend="Boinc-Config">configuration</link>
-	    requirements for master-to-client messaging.
-	  </para>
-	</note>
-      </para>
-      <para>
-	BOINC messaging has several restrictions:
-
-	<itemizedlist>
-	  <listitem>
-	    <para>
-	      Messages can only be sent to BOINC results that are currently
-	      running. If a work unit has no running result, messages sent to it
-	      are silently discarded.
-	    </para>
-	  </listitem>
-	  <listitem>
-	    <para>
-	      If redundancy is enabled, master-to-client messages are sent to
-	      all running BOINC results regardless their state. In case of
-	      client-to-master messages, the master cannot tell which BOINC
-	      result sent the message. This means that "request-response" style
-	      messaging is hard to implement correctly when redundancy is
-	      enabled.
-	    </para>
-	  </listitem>
-	  <listitem>
-	    <para>
-	      Messages sent by the master are delivered only when the client
-	      connects to the master next time. Since the master has no control
-	      over this, the client should periodically send messages to the
-	      master to force a connection if timely receiving of messages sent
-	      by the master is important. Be caraful about the extra load placed
-	      on the BOINC server by clients sending messages too frequently.
-	    </para>
-	  </listitem>
-	  <listitem>
-	    <para>
-	      When multiple messages are being queued in either direction due to
-	      the client not connecting to the server frequently enough, they
-	      will be delivered to the peer in an undefined order.
-	    </para>
-	  </listitem>
-	</itemizedlist>
-      </para>
-    </sect3>
-
-    <sect3>
-      <title>Cancelling a running work unit</title>
-
-      <para>
-	The <function><link
-	    linkend="DC-cancelWU">DC_cancelWU()</link></function> function can
-	be used to cancel a running work unit. This function is implemented
-	by sending a special message to all running BOINC results. This implies
-	that unless clients where BOINC results for this work unit are running
-	connect back to the BOINC server, the cancel request may not be
-	delivered until the client finishes the computation.
-      </para>
-      <para>
-	Due to a race condition between various components of the BOINC system,
-	it is also possible that a new BOINC result is created and is sent out
-	after the work unit has been cancelled. Such BOINC result will not
-	receive the cancellation request and will run until it finishes its
-	computation. Its result however will not be reported to the DC-API
-	master, so the application should not be concerned about this.
-      </para>
-    </sect3>
-
-    <sect3>
-      <title><anchor id="Boinc-Result"/>When is a result reported</title>
-
-      <!-- XXX Rework when the validator API is merged -->
-      <para>
-	The BOINC core client handles the completion of a BOINC result in two
-	phases: first it uploads the output files, then it notifies the BOINC
-	server that the result has been finised. The validator will notice the
-	completion of the BOINC result only when this notification is received.
-      </para>
-      <para>
-	However, this notification is sent only when the core client has to
-	connect the BOINC server the next time, which may be a long time if the
-	core client has already started processing the next BOINC result while
-	the output files of the previous result were being uploaded.
-      </para>
-      <para>
-	When there are no more work units to download, the client sleeps for a
-	couple of minutes before trying again. This means that the reporting of
-	the completion of the last work unit may be delayed for a couple of
-	minutes even after all its output files have been uploaded.
-      </para>
-      <para>
-	The DC-API master application will receive notification about a result
-	when the validator has made its decision. This may also introduce some
-	delay after all BOINC results have been completed.
-      </para>
-    </sect3>
-
-    <sect3>
-      <title>Work unit priority</title>
-
-      <para>
-	The priority of a work unit can be set either by using the
-	<function><link
-	    linkend="DC-setWUPriority">DC_setWUPriority()</link></function>
-	function or by specifying it in the configuration file using the
-	<literal>DefaultPriority</literal> key. Either way, the priority can
-	be an arbitrary 32-bit integer.
-      </para>
-      <para>
-	The BOINC scheduler dispatches higher priority work units first. Results
-	belonging to work units with lower priorities will not be offered to
-	clients until all the higher priority work units are exhausted.
-      </para>
-    </sect3>
-
-    <sect3>
-      <title>Common errors</title>
-
-      <para>
-	There are some common errors:
-
-	<variablelist>
-	  <varlistentry>
-	    <term>No results are reported</term>
-	    <listitem>
-	      <para>
-		Check the validator.  When there is no validator defined in
-		<filename>config.xml</filename> or the validator fails for some
-		reason, the DC-API master will not receive result notifications.
-	      </para>
-	    </listitem>
-	  </varlistentry>
-	  <varlistentry>
-	    <term>The final result is not reported</term>
-	    <listitem>
-	      <para>
-		There is a couple minutes <link
-		  linkend="Boinc-Result">delay</link> before reporting the final
-		result. It is normal.
-	      </para>
-	    </listitem>
-	  </varlistentry>
-	  <varlistentry>
-	    <term>
-	      I've fixed a bug in a client application, but results are still
-	      computed using the old client
-	    </term>
-	    <listitem>
-	      <para>
-		Be sure to give the new client binary with a version number
-		greater than the old client, or otherwise the clients will not
-		notice that the binary has been updated and will not download
-		it.
-	      </para>
-	    </listitem>
-	  </varlistentry>
-	</variablelist>
-      </para>
-    </sect3>
-
-    <sect3>
-      <title>Open issues</title>
-
-      <para>
-	The following list contains the known problems with DC-API's BOINC
-	backend:
-      </para>
-
-      <itemizedlist>
-	<listitem>
-	  <para>
-	    Messages are not removed from the <literal>msg_to_host</literal>
-	    and <literal>msg_from_host</literal> tables by the
-	    <application>db_purge</application> tool, so they need to be cleaned
-	    up manually from time to time to prevent the database from being
-	    filled up.
-	  </para>
-	</listitem>
-	<listitem>
-	  <para>
-	    The DC-API creates result template files in the
-	    <filename>templates</filename> subdirectory in the project's root
-	    directory, but those files are never removed.
-	  </para>
-	</listitem>
-      </itemizedlist>
-    </sect3>
-
-  </sect2>
-</sect1>
-<!-- vim: set ai sw=2 tw=80: -->
diff --git a/dcapi/doc/concepts.xml b/dcapi/doc/concepts.xml
deleted file mode 100644
index 96ad35a..0000000
--- a/dcapi/doc/concepts.xml
+++ /dev/null
@@ -1,202 +0,0 @@
-<?xml version="1.0"?>
-<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.1.2//EN" 
-               "http://www.oasis-open.org/docbook/xml/4.1.2/docbookx.dtd">
-<sect1 id="concepts">
-  <title>General concepts</title>
-
-
-  <sect2>
-    <title>Programming model</title>
-
-    <para>
-      DC-API applications consist of two major components: a master application
-      and one or more client applications. The master is responsible for
-      dividing the global input data into smaller chunks and distributing these
-      chunks in the form of work units. Interpreting the output generated by the
-      work units and combining them to form a global output is also the job of
-      the master.
-    </para>
-    <para>
-      The master application usually runs as a daemon, but it is also possible
-      to write a master that runs periodically (e.g. from
-      <application>cron</application>), processes the outstanding events, and
-      exits.
-    </para>
-    <para>
-      Client applications are simple sequential programs that take their input
-      from the master, perform some computation on it and produce some output.
-    </para>
-
-    <sect3>
-      <title>Writing a master application</title>
-
-      <para>
-	A typical master application does the following steps:
-      </para>
-
-      <itemizedlist>
-	<listitem>
-	  <para>
-	    Initializes the DC-API library by calling <function><link
-		linkend="DC-initMaster">DC_initMaster()</link></function>
-	    function.
-	  </para>
-	</listitem>
-	<listitem>
-	  <para>
-	    Calls the <function><link
-		linkend="DC-setResultCb">DC_setResultCb()</link></function>
-	    function and optionally some of the <function><link
-		linkend="DC-setSubresultCb">DC_setSubresultCb()</link></function>,
-	    <function><link
-		linkend="DC-setMessageCb">DC_setMessageCb()</link></function>,
-	    <function><link
-		linkend="DC-setSuspendCb">DC_setSuspendCb()</link></function>
-	    and <function><link
-		linkend="DC-setValidateCb">DC_setValidateCb()</link></function>
-	    functions, depending on the features (messaging, subresults etc.)
-	    it wants to use.
-	  </para>
-	</listitem>
-	<listitem>
-	  <para>
-	    In its main loop, the master calls the <function><link
-	        linkend="DC-createWU">DC_createWU()</link></function> function
-	    to create new work units when needed. If the total number of work
-	    units is small (depending on the grid infrastructure), then the
-	    master may also create all the work units in advance. If the total
-	    number of work units is too large for this, the master may use the
-	    <function><link
-		linkend="DC-getWUNumber">DC_getWUNumber()</link></function>
-	    function to determine the number of running work units, and create
-	    new work units only if this number falls below a certain threshold.
-	  </para>
-	</listitem>
-	<listitem>
-	  <para>
-	    Also in its main loop the master calls the <function><link
-		linkend="DC-processMasterEvents">DC_processMasterEvents()</link></function>
-	    function that checks for outstanding events and invokes the
-	    appropriate callbacks.
-	  </para>
-	  <para>
-	    Alternatively, the master may use the <function><link
-		linkend="DC-waitMasterEvent">DC_waitMasterEvent()</link></function>
-	    and <function><link
-		linkend="DC-waitWUEvent">DC_waitWUEvent()</link></function>
-	    functions instead of <function><link
-		linkend="DC-processMasterEvents">DC_processMasterEvents()</link></function>
-	    if it prefers to receive event structures instead of using
-	    callbacks.
-	  </para>
-	</listitem>
-      </itemizedlist>
-    </sect3>
-
-    <sect3>
-      <title>Writing a client application</title>
-
-      <para>
-	A typical client application performs the following steps:
-      </para>
-
-      <itemizedlist>
-	<listitem>
-	  <para>
-	    Initializes the DC-API library by calling <function><link
-		linkend="DC-initClient">DC_initClient()</link></function>
-	    function.
-	  </para>
-	</listitem>
-	<listitem>
-	  <para>
-	    Identifies the location of its input/output files by calling the
-	    <function><link
-		linkend="DC-resolveFileName">DC_resolveFileName()</link></function>
-	    function.
-	    <note>
-	      <para>
-		The client application may not assume that it can
-		read/create/write any files other than the names returned by
-		<function><link
-		    linkend="DC-resolveFileName">DC_resolveFileName()</link></function>.
-	      </para>
-	    </note>
-	  </para>
-	</listitem>
-	<listitem>
-	  <para>
-	    During the computation, the client should periodically call the
-	    <function><link
-		linkend="DC-checkClientEvent">DC_checkClientEvent()</link></function>
-	    function and process the received events.
-	  </para>
-	</listitem>
-	<listitem>
-	  <para>
-	    If possible, the client should call the <function><link
-		linkend="DC-fractionDone">DC_fractionDone()</link></function>
-	    function with the fraction of the work completed. On some grid
-	    infrastructures (e.g. BOINC) this will allow the client's supervisor
-	    process to show the progression of the application to the user.
-	  </para>
-	  <para>
-	    Ideally the value passed to the <function><link
-		linkend="DC-fractionDone">DC_fractionDone()</link></function>
-	    function should be proportional to the time elapsed so far compared
-	    to the total time that will be needed to complete the computation.
-	  </para>
-	</listitem>
-	<listitem>
-	  <para>
-	    The client should call the <function><link
-		linkend="DC-finishClient">DC_finishClient()</link></function>
-	    function at the end of the computation. As a result all output files
-	    will be sent to the master and the master will be notified about the
-	    completion of the work unit.
-	  </para>
-	</listitem>
-      </itemizedlist>
-    </sect3>
-  </sect2>
-
-  <sect2>
-    <title>Messaging</title>
-
-    <para>
-      The DC-API provides limited messaging functionality between the master
-      application and the clients. The DC-API has the following features and
-      restrictions:
-
-      <itemizedlist>
-	<listitem>
-	  <para>
-	    Messages are not reliable in the sense that if the client is not
-	    actually running when a message is being sent to it (e.g. because it
-	    is queued by the backend grid infrastructure), then the message may
-	    be silently dropped.
-	  </para>
-	</listitem>
-	<listitem>
-	  <para>
-	    The ordering of messages is not neccessarily maintained.
-	  </para>
-	</listitem>
-	<listitem>
-	  <para>
-	    Messages are delivered asynchronously. There is no limit for the
-	    time elapsed before a message is actually delivered.
-	  </para>
-	</listitem>
-      </itemizedlist>
-    </para>
-    <para>
-      Due to the above restrictions, DC-API messages are not suitable for
-      message-based parallel processing. They are meant for sending short status
-      messages about long-running operations, or for sending control messages
-      like a command to cancel a given computation.
-    </para>
-  </sect2>
-
-</sect1>
-<!-- vim: set ai sw=2 tw=80: -->
diff --git a/dcapi/doc/condor.xml b/dcapi/doc/condor.xml
deleted file mode 100644
index e613a7c..0000000
--- a/dcapi/doc/condor.xml
+++ /dev/null
@@ -1,440 +0,0 @@
-<?xml version="1.0"?>
-<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.1.2//EN" 
-               "http://www.oasis-open.org/docbook/xml/4.1.2/docbookx.dtd">
-<sect1 id="condor">
-  <title>CONDOR</title>
-
-  <sect2 id="condor_app">
-  <title>Application in Condor environment</title>
-
-  <para>
-  Master-worker application developed using DC-API can be run in a
-  Condor environment. The master program must be started by hand and
-  it submits workunits to a Condor execution pool.
-  </para>
-
-  <para>
-  All files that generated by the application including the master and
-  the worker programs and the DC-API library itself are placed under a
-  directory called <emphasis>working directory</emphasis>.
-  </para>
-
-  </sect2>
-
-  <sect2 id="condor_environment">
-  <title>Condor environment</title>
-
-  <para>
-  To execute a DC-API application using Condor version of the DC-API
-  library you have to set up a Condor environment and have access to
-  it.
-  </para>
-
-  <para>
-  Master program of the application must be started on a Condor submit
-  host so it will be able to submit workunits as Condos jobs.
-  </para>
-
-  <para>
-  Working directory of the application must be accessible by the
-  master and the worker processes too so it should be placed on a
-  shared filesystem (e.g. NFS) which is available for the submit and
-  the execution hosts in the Condor pool.
-  </para>
-
-  </sect2>
-
-  <sect2 id="condor_required">
-  <title>Required tools</title>
-
-  <para>
-  To compile the application using Condor version of the DC-API
-  library you need an additional library <filename
-  class="libraryfile">libcondorapi.a</filename> which is included in the
-  Condor installation. This library must be linked to the application
-  besides the DC-API library.
-
-    <caution><title>Do not use Condor's lib directory</title>
-    <para>
-    Do not specify Condor's lib directory for the linker when
-    compiling the application. For example do not use the option:
-
-    <example><title>Linker option</title>
-    <programlisting>
-    ... -L$CONDOR_HOME/lib ...
-    </programlisting>
-    </example>
-    
-    Instead, copy out the <filename
-    class="libraryfile">libcondorapi.a</filename> file to somewhere else
-    and use that directory after the linker's -L option.
-    </para>
-    </caution>
-
-  </para>
-
-  </sect2>
-
-  <sect2 id="condor_configuration">
-    <title>Configuration options</title>
-
-      <variablelist>
-
-        <varlistentry>
-	  <term>InstanceUUID</term>
-	  <listitem>
-	    <para>
-
-	    REQUIRED. Identification of running instance of the
-	  application. For CONDOR backend it can be any string not
-	  just an UUID.
-
-	    </para>
-	  </listitem>
-	</varlistentry>
-
-        <varlistentry>
-	  <term>WorkingDirectory</term>
-	  <listitem>
-	    <para>
-	    
-	    REQUIRED. Name of working directory of the
-	    application. All files that are generated by the
-	    application or the DC-API library are placed under this
-	    directory. Different applications can use the same working
-	    directory because every instance has its own subdirectory
-	    there.
-
-	    </para>
-	  </listitem>
-	</varlistentry>
-
-        <varlistentry>
-	  <term>ClientMessageBox</term>
-	  <listitem>
-	    <para>
-
-	    Name of the directory in workunit's working directory
-	    where messages are placed which are sent by the client to
-	    the master by <function><link
-	    linkend="DC-sendMessage">DC_sendMessage()</link></function>. Default
-	    value is <filename>_dcapi_client_messages</filename>.
-
-	    </para>
-	  </listitem>
-	</varlistentry>
-
-	<varlistentry>
-	  <term>MasterMessageBox</term>
-	  <listitem>
-	    <para>
-
-	    Name of the directory in workunit's working directory
-	    where <function><link
-	    linkend="DC-sendWUMessage">DC_sendWUMessage()</link></function>
-	    places messages sent by the master to the client. Default
-	    value is <filename>_dcapi_master_messages</filename>.
-
-	    </para>
-	  </listitem>
-	</varlistentry>
-
-	<varlistentry>
-	  <term>SubresultBox</term>
-	  <listitem>
-	    <para>
-
-	    Name of the directory in workunit's working directory
-	    where <function><link
-	    linkend="DC-sendResult">DC_sendResult()</link></function>
-	    places subresults generated by the client. Default
-	    value is <filename>_dcapi_client_subresults</filename>.
-
-	    </para>
-	  </listitem>
-	</varlistentry>
-
-	<varlistentry>
-	  <term>SystemMessageBox</term>
-	  <listitem>
-	    <para>
-
-	    Name of the directory in workunit's working directory
-	    where the master and client program place management
-	    messages for example when the master asks the client to
-	    suspend and it sends back an acknowlegde. Default value is
-	    <filename>_dcapi_system_messages</filename>
-
-	    </para>
-	  </listitem>
-	</varlistentry>
-
-	<varlistentry>
-	  <term>SubmitFile</term>
-	  <listitem>
-	    <para>
-
-	    Name of the file in workunit's working directory which is
-	    generated by the master and used as submit information for
-	    Condor when a workunit is prepared to start. Default value
-	    is <filename>_dcapi_condor_submit.txt</filename>.
-
-	    </para>
-	  </listitem>
-	</varlistentry>
-
-	<varlistentry>
-	  <term>Executable</term>
-	  <listitem>
-	    <para>
-
-	    Name of the executable file of the client (workunit). By
-	    default it is the <parameter>clientName</parameter>
-	    parameter which was passed to <function><link
-	    linkend="DC-createWU">DC_createWU()</link></function>.
-
-	    </para>
-	  </listitem>
-	</varlistentry>
-
-	<varlistentry>
-	  <term>LeaveFiles</term>
-	  <listitem>
-	    <para>
-	    
-	    Specifies if files, directories generated in workunit's
-	    working directory should be deleted or not after workunit
-	    ends. Zero value means delete and non-zero value means not
-	    to delete. Default value is 0.
-
-	    </para>
-	  </listitem>
-	</varlistentry>
-
-	<varlistentry>
-	  <term>CondorLog</term>
-	  <listitem>
-	    <para>
-
-	    Name of the file in workunit's working directory where
-	    Condor writes records about events happen to the Condor
-	    job. Default value is
-	    <filename>_dcapi_internal_log.txt</filename>.
-
-	    </para>
-	  </listitem>
-	</varlistentry>
-
-	<varlistentry>
-	  <term>CheckpointFile</term>
-	  <listitem>
-	    <para>
-
-	    Name of file in workunit's working directory where
-	    checkpoint information is written by the
-	    client. <function><link
-	    linkend="DC-resolveFileName">DC_resolveFileName()</link></function>
-	    will resolve <link
-	    linkend="DC-CHECKPOINT-FILE:CAPS">DC_CHECKPOINT_FILE</link>
-	    to this name. Default value is
-	    <filename>_dcapi_checkpoint</filename>.
-
-	    </para>
-	  </listitem>
-	</varlistentry>
-
-	<varlistentry>
-	  <term>SavedOutputs</term>
-	  <listitem>
-	    <para>
-
-	    Name of directory in workunit's working directory where
-	    workunit's standard output is saved when it is
-	    suspended. Deafult values is
-	    <filename>_dcapi_saved_output</filename>. There is no
-	    facility in the DC-API yet to merge saved output together.
-
-	    </para>
-	  </listitem>
-	</varlistentry>
-
-	<varlistentry>
-	  <term>CondorSubmitTemplate</term>
-	  <listitem>
-	    <para>
-
-	    Name of the file which is used as template when generating
-	    Condor submit file. If not specified then a built-in template
-	    will be used. % character can be used to include variable data
-	    into the generated file. Recorgnized % instructions:
-
-	    <variablelist>
-	      <varlistentry>
-	        <term>%%</term>
-	        <listitem>
-	          <para>
-		  Literal %.
-		  </para>
-	        </listitem>
-	      </varlistentry>
-
-	      <varlistentry>
-	        <term>%d</term>
-	        <listitem>
-	          <para>
-		  Current date and time
-		  </para>
-	        </listitem>
-	      </varlistentry>
-
-	      <varlistentry>
-	        <term>%n</term>
-	        <listitem>
-	          <para>
-		  Name of the workunit.
-		  </para>
-	        </listitem>
-	      </varlistentry>
-
-	      <varlistentry>
-	        <term>%i</term>
-	        <listitem>
-	          <para>
-		  Internal ID of the workunit.
-		  </para>
-	        </listitem>
-	      </varlistentry>
-
-	      <varlistentry>
-	        <term>%w</term>
-	        <listitem>
-	          <para>
-		  Name of working directory of the workunit.
-		  </para>
-	        </listitem>
-	      </varlistentry>
-
-	      <varlistentry>
-	        <term>%c</term>
-	        <listitem>
-	          <para>
-		  Client name.
-		  </para>
-	        </listitem>
-	      </varlistentry>
-
-	      <varlistentry>
-	        <term>%r</term>
-	        <listitem>
-	          <para>
-		  Number of the arguments.
-		  </para>
-	        </listitem>
-	      </varlistentry>
-
-	      <varlistentry>
-	        <term>%x</term>
-	        <listitem>
-	          <para>
-		  Name of the executable.
-		  </para>
-	        </listitem>
-	      </varlistentry>
-
-	      <varlistentry>
-	        <term>%a</term>
-	        <listitem>
-	          <para>
-		  Argument list.
-		  </para>
-	        </listitem>
-	      </varlistentry>
-
-	      <varlistentry>
-	        <term>%u</term>
-	        <listitem>
-	          <para>
-		  Condor universe (always vanilla).
-		  </para>
-	        </listitem>
-	      </varlistentry>
-
-	      <varlistentry>
-	        <term>%o</term>
-	        <listitem>
-	          <para>
-		  File for standard output of the job.
-		  </para>
-	        </listitem>
-	      </varlistentry>
-
-	      <varlistentry>
-	        <term>%e</term>
-	        <listitem>
-	          <para>
-		  File for standard error of the job.
-		  </para>
-	        </listitem>
-	      </varlistentry>
-
-	      <varlistentry>
-	        <term>%l</term>
-	        <listitem>
-	          <para>
-		  File for Condor user log.
-		  </para>
-	        </listitem>
-	      </varlistentry>
-
-	      <varlistentry>
-	        <term>%I</term>
-	        <listitem>
-	          <para>
-		  Comma separated list of input files (physical filenames with path). Capital 'i'.
-		  </para>
-	        </listitem>
-	      </varlistentry>
-
-	      <varlistentry>
-	        <term>%O</term>
-	        <listitem>
-	          <para>
-		  Comma separated list of output files.
-		  </para>
-	        </listitem>
-	      </varlistentry>
-          <varlistentry>
-            <term>SubmitRetry</term>
-          	<listitem>
-          	  <para>
-          	      If a job cannot be submitted, how many times should DC-API try before giving 
-          	      up and reporting it as failed. Default value is 5.
-              </para>
-            </listitem>
-          </varlistentry>
-          <varlistentry>
-            <term>SubmitRetrySleepTime</term>
-          	<listitem>
-          	  <para>
-          	      Defines the start value for the sleep period between job submission retries. 
-          	      Default value is 2. It is multiplied by 2 after each retry, so 2 seconds sleep 
-          	      before the first retry, 4 seconds before the second, 8 second before the third 
-          	      and so on.
-              </para>
-            </listitem>
-          </varlistentry>
-	    </variablelist>
-
-
-
-	</para>
-	</listitem>
-
-	</varlistentry>
-
-      </variablelist>
-
-  </sect2>
-</sect1>
-
-<!-- End of condor.xml -->
diff --git a/dcapi/doc/config.xml b/dcapi/doc/config.xml
deleted file mode 100644
index 7427fa6..0000000
--- a/dcapi/doc/config.xml
+++ /dev/null
@@ -1,267 +0,0 @@
-<?xml version="1.0"?>
-<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.1.2//EN" 
-               "http://www.oasis-open.org/docbook/xml/4.1.2/docbookx.dtd">
-<sect1 id="configuration">
-  <title>Configuration</title>
-
-  <para>
-    The DC-API library uses a configuration file to control its operations. The
-    location of the config file must be specified by the master application when
-    it calls the <function><link
-	linkend="DC-initMaster">DC_initMaster()</link></function> function.
-    <note>
-      <para>
-	Individual work units may also use a config file that has a slightly
-	different format than the master's config file. Work unit config files
-	however are usually generated by the DC-API library on the master side so
-	applications should not be concerned about it.
-      </para>
-    </note>
-  </para>
-
-  <sect2>
-    <title>Configuration file format</title>
-
-    <para>
-      The DC-API configuration file contains key-value pairs organized into
-      groups. The full syntax description can be found in the
-      <ulink
-	url="http://freedesktop.org/Standards/desktop-entry-spec">Desktop
-	Entry Specification</ulink>, but we
-      also give a brief explanation below.
-    </para>
-    <para>
-      Lines starting with <literal>#</literal> are considered comments
-      and are ignored. Groups are started by a line containing the group's name
-      between brackets (<literal>[</literal> and <literal>]</literal>). Groups
-      are terminated by the start of an other group or by the end of the file.
-    </para>
-    <para>
-      A group may contain a list of <literal>key = value</literal> assignments,
-      each in a separate line. White space arount the <literal>=</literal>
-      character is ignored. Note that the DC-API do not use the localized string
-      feature of the Desktop Entry Specification.
-    </para>
-    <para>
-      Configuration values can be of 4 types:
-      <itemizedlist>
-	<listitem>
-	  <para>
-	    Simple strings. According to the format specification, they must be
-	    UTF-8 encoded.
-	  </para>
-	</listitem>
-	<listitem>
-	  <para>
-	    Integer values.
-	  </para>
-	</listitem>
-	<listitem>
-	  <para>
-	    Floating point values. For both integer and floating point values,
-	    the following suffixes are recognized:
-
-	    <variablelist>
-	      <varlistentry>
-		<term>kb, kib</term>
-		<listitem>
-		  <para>
-		    A multiplier of 2<superscript>10</superscript> (1024)
-		  </para>
-		</listitem>
-	      </varlistentry>
-	      <varlistentry>
-		<term>mb, mib</term>
-		<listitem>
-		  <para>
-		    A multiplier of 2<superscript>20</superscript>
-		  </para>
-		</listitem>
-	      </varlistentry>
-	      <varlistentry>
-		<term>gb, gib</term>
-		<listitem>
-		  <para>
-		    A multiplier of 2<superscript>30</superscript>
-		  </para>
-		</listitem>
-	      </varlistentry>
-	      <varlistentry>
-		<term>min</term>
-		<listitem>
-		  <para>
-		    A multiplier of 60
-		  </para>
-		</listitem>
-	      </varlistentry>
-	      <varlistentry>
-		<term>h, hour</term>
-		<listitem>
-		  <para>
-		    A multiplier of 3600
-		  </para>
-		</listitem>
-	      </varlistentry>
-	      <varlistentry>
-		<term>day</term>
-		<listitem>
-		  <para>
-		    A multiplier of 86400
-		  </para>
-		</listitem>
-	      </varlistentry>
-	    </variablelist>
-	  </para>
-	</listitem>
-	<listitem>
-	  <para>
-	    Boolean values. The strings <literal>true</literal>,
-	    <literal>yes</literal> and <literal>on</literal> means true, the
-	    strings <literal>false</literal>, <literal>no</literal> and
-	    <literal>off</literal> are considered false.
-	  </para>
-	</listitem>
-      </itemizedlist>
-    </para>
-  </sect2>
-
-  <sect2>
-    <title>Generic configuration items</title>
-
-    <para>
-      The DC-API configuration file should contain a group called
-      <literal>[Master]</literal>  that defines global configuration options.
-      There may be also groups called <literal>[Client-CLIENTNAME]</literal> where
-      <literal>CLIENTNAME</literal> is the logical name of a client application
-      the master wishes to start (the same string that is passed to the
-      <function><link linkend="DC-createWU">DC_createWU()</link></function> function).
-    </para>
-    <para>
-      Default values for client-specific configuration options may also be
-      specified in the <literal>[Master]</literal> group. If the same key is
-      also present in a client-specific group, the client-specific value will
-      override the value in the <literal>[Master]</literal> group.
-    </para>
-
-    <sect3>
-      <title>Configuration values for the master application</title>
-
-      <para>
-	The following entries can be specified in the <literal>[Master]</literal>
-	group. Grid backends may require and/or allow further items; refer to the
-	backend-specific documentation.
-      </para>
-      <variablelist>
-	<varlistentry>
-	  <term>WorkingDirectory</term>
-	  <listitem>
-	    <para>
-	      REQUIRED. The working directory of the master application. The value
-	      must be an absolute path. The DC-API sets the master's current
-	      directory to the value specified here when the <function><link
-		linkend="DC-initMaster">DC_initMaster()</link></function>
-	      function is called.
-	    </para>
-	  </listitem>
-	</varlistentry>
-	<varlistentry>
-	  <term>LogLevel</term>
-	  <listitem>
-	    <para>
-	      OPTIONAL. Specifies the verbosity of log messages generated by the
-	      DC-API or by the master application if it uses the <function><link
-		linkend="DC-log">DC_log()</link></function> or <function><link
-		linkend="DC-vlog">DC_vlog()</link></function> functions. The allowed values
-	      in the order of increasing priority are <literal>Debug</literal>,
-	      <literal>Info</literal>, <literal>Notice</literal>,
-	      <literal>Warning</literal>, <literal>Error</literal> and
-	      <literal>Critical</literal>, the default being
-	      <literal>Notice</literal>.
-	    </para>
-	  </listitem>
-	</varlistentry>
-	<varlistentry>
-	  <term>LogFile</term>
-	  <listitem>
-	    <para>
-	      OPTIONAL. Specifies the name of the file where log messages should
-	      be written to. If not specified, log messages are sent to the
-	      application's standard output.
-	    </para>
-	  </listitem>
-	</varlistentry>
-      </variablelist>
-    </sect3>
-    <sect3>
-      <title>Configuration values individual work units</title>
-
-      <variablelist>
-	<varlistentry>
-	  <term>LogLevel</term>
-	  <listitem>
-	    <para>
-	      OPTIONAL. Specifies the verbosity of log messages generated by the
-	      DC-API or by the client application if it uses the <function><link
-		linkend="DC-log">DC_log()</link></function> or <function><link
-		linkend="DC-vlog">DC_vlog()</link></function> functions. The
-	      allowed values in the order of increasing priority are
-	      <literal>Debug</literal>, <literal>Info</literal>,
-	      <literal>Notice</literal>, <literal>Warning</literal>,
-	      <literal>Error</literal> and <literal>Critical</literal>, the
-	      default being <literal>Notice</literal>.
-	    </para>
-	  </listitem>
-	</varlistentry>
-	<varlistentry>
-	  <term>LogFile</term>
-	  <listitem>
-	    <para>
-	      OPTIONAL. Specifies the name of the file where log messages should
-	      be written to. The value must be a relative file name without any
-	      path components.
-	    </para>
-	    <para>
-	      The default value is determined by the DC-API when it creates the
-	      work unit and generally it should not be overridden.
-	    </para>
-	  </listitem>
-	</varlistentry>
-	<varlistentry>
-	  <term>SendCfgKeys</term>
-	  <listitem>
-	    <para>
-	      OPTIONAL. Specifies a <literal>;</literal>-separated list of
-	      configuration keys that should be sent to the client application
-	      when a work unit is created. <literal>LogLevel</literal> and
-	      <literal>LogFile</literal> are always included so those should not
-	      be listed.
-	    </para>
-	    <para>
-	      The client application may use the <function><link
-		  linkend="DC-getCfgStr">DC_getCfgStr()</link></function>,
-	      <function><link
-		  linkend="DC-getCfgInt">DC_getCfgInt()</link></function>, and
-	      <function><link
-		  linkend="DC-getCfgBool">DC_getCfgBool()</link></function>
-	      functions to access the values of the keys specified by
-	      <literal>SendCfgKeys</literal>
-	    </para>
-	  </listitem>
-	</varlistentry>
-	<varlistentry>
-	  <term>DefaultPriority</term>
-	  <listitem>
-	    <para>
-	      OPTIONAL. Specifies the default priority of the work unit. The
-	      priority is an integer number; its allowed range and exact meaning
-	      depends on the grid backend. The default value is 0.
-	    </para>
-	  </listitem>
-	</varlistentry>
-      </variablelist>
-    </sect3>
-
-  </sect2>
-
-</sect1>
-<!-- vim: set ai sw=2 tw=80: -->
diff --git a/dcapi/doc/customize.xsl b/dcapi/doc/customize.xsl
deleted file mode 100644
index 680ac7c..0000000
--- a/dcapi/doc/customize.xsl
+++ /dev/null
@@ -1,7 +0,0 @@
-<?xml version='1.0'?>
-<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version='1.0'>
-	<xsl:param name="co.linkends.show">0</xsl:param>
-	<xsl:param name="doc.collab.show">0</xsl:param>
-	<xsl:param name="latex.babel.language">english</xsl:param>
-	<xsl:param name="latex.babel.use">1</xsl:param>
-</xsl:stylesheet>
diff --git a/dcapi/doc/dc-api-docs.xml b/dcapi/doc/dc-api-docs.xml
deleted file mode 100644
index 67b018f..0000000
--- a/dcapi/doc/dc-api-docs.xml
+++ /dev/null
@@ -1,32 +0,0 @@
-<?xml version="1.0"?>
-<!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.1.2//EN" 
-               "http://www.oasis-open.org/docbook/xml/4.1.2/docbookx.dtd">
-
-<book id="index" xmlns:xi="http://www.w3.org/2003/XInclude">
-  <bookinfo>
-    <title>DC-API Manual</title>
-  </bookinfo>
-
-  <chapter id="general">
-    <title>General information</title>
-    <xi:include href="intro.xml"/>
-    <xi:include href="concepts.xml"/>
-    <xi:include href="config.xml"/>
-    <xi:include href="using.xml"/>
-  </chapter>
-
-  <chapter id="backends">
-    <title>Backend-specific information</title>
-    <xi:include href="boinc.xml"/>
-    <xi:include href="condor.xml"/>
-    <xi:include href="local.xml"/>
-  </chapter>
-
-  <chapter id="reference">
-    <title>Reference</title>
-    <xi:include href="xml/dc_common.xml"/>
-    <xi:include href="xml/dc_client.xml"/>
-    <xi:include href="xml/dc.xml"/>
-  </chapter>
-</book>
-<!-- vim: set ai sw=2 tw=80: -->
diff --git a/dcapi/doc/dc-api-overrides.txt b/dcapi/doc/dc-api-overrides.txt
deleted file mode 100644
index e69de29..0000000
diff --git a/dcapi/doc/dc-api-sections.txt b/dcapi/doc/dc-api-sections.txt
deleted file mode 100644
index 0565e4a..0000000
--- a/dcapi/doc/dc-api-sections.txt
+++ /dev/null
@@ -1,108 +0,0 @@
-<SECTION>
-<TITLE>common</TITLE>
-<FILE>dc_common</FILE>
-<INCLUDE>dc_common.h</INCLUDE>
-
-DC_ErrorCode
-DC_GridCapabilities
-DC_FileMode
-DC_CONFIG_FILE
-DC_LABEL_STDOUT
-DC_LABEL_STDERR
-DC_LABEL_CLIENTLOG
-DC_PhysicalFile
-DC_RemoteFile
-DC_getCfgStr
-DC_getCfgInt
-DC_getCfgBool
-DC_log
-DC_vlog
-
-<SUBSECTION>
-DC_getMaxMessageSize
-DC_getMaxSubresults
-DC_getGridCapabilities
-</SECTION>
-
-<SECTION>
-<TITLE>client</TITLE>
-<FILE>dc_client</FILE>
-<INCLUDE>dc_client.h</INCLUDE>
-
-DC_FileType
-DC_CHECKPOINT_FILE
-DC_ClientEventType
-DC_ClientEvent
-
-<SUBSECTION>
-DC_initClient
-DC_resolveFileName
-DC_sendResult
-DC_sendMessage
-DC_checkClientEvent
-DC_destroyClientEvent
-DC_checkpointMade
-DC_fractionDone
-DC_finishClient
-</SECTION>
-
-<SECTION>
-<TITLE>master</TITLE>
-<FILE>dc</FILE>
-<INCLUDE>dc.h</INCLUDE>
-
-DC_WUState
-DC_MasterEventType
-DC_Workunit
-DC_Result
-DC_MasterEvent
-DC_ResultCallback
-DC_SubresultCallback
-DC_MessageCallback
-
-<SUBSECTION>
-DC_initMaster
-DC_setMasterCb
-DC_setMessageCb
-DC_setResultCb
-DC_setSubresultCb
-
-<SUBSECTION>
-DC_processMasterEvents
-DC_waitMasterEvent
-DC_waitWUEvent
-DC_destroyMasterEvent
-
-<SUBSECTION>
-DC_getWUNumber
-DC_createWU
-DC_addWUInput
-DC_addWUOutput
-DC_setWUPriority
-DC_setWUBatch
-DC_serializeWU
-DC_deserializeWU
-DC_getWUState
-DC_submitWU
-DC_getWUId
-DC_getWUTag
-DC_cancelWU
-DC_suspendWU
-DC_resumeWU
-DC_destroyWU
-DC_sendWUMessage
-
-<SUBSECTION>
-DC_getClientCfgStr
-DC_getClientCfgInt
-DC_getClientCfgDouble
-DC_getClientCfgBool
-
-<SUBSECTION>
-DC_getResultCapabilities
-DC_getResultWU
-DC_getResultExit
-DC_getResultOutput
-DC_getResultCPUTime
-</SECTION>
-
diff --git a/dcapi/doc/intro.xml b/dcapi/doc/intro.xml
deleted file mode 100644
index 47acec8..0000000
--- a/dcapi/doc/intro.xml
+++ /dev/null
@@ -1,45 +0,0 @@
-<?xml version="1.0"?>
-<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.1.2//EN" 
-               "http://www.oasis-open.org/docbook/xml/4.1.2/docbookx.dtd">
-<sect1>
-  <title>Introduction</title>
-
-  <para>
-    The DC-API was created by MTA SZTAKI to allow easy implementation and
-    deployment of distributed applications on multiple grid environments.
-  </para>
-  <para>
-    In order to accomodate the needs of very different grid environments, the
-    DC-API supports only a restricted master-worker programming model. The
-    restrictions include:
-    <itemizedlist>
-      <listitem>
-	<para>
-	  Master-worker concept: there is a designated
-	  <emphasis>master</emphasis> process running somewhere on the grid
-	  infrastructure. The master process can submit worker processes called
-	  <emphasis>work units</emphasis>.
-	</para>
-      </listitem>
-      <listitem>
-	<para>
-	  Every work unit is a sequential application.
-	</para>
-      </listitem>
-      <listitem>
-	<para>
-	  There is support for limited messaging between the master and the
-	  running work units. It can be used to send status and control
-	  messages, but it is not suitable for parallel programming.
-	</para>
-      </listitem>
-      <listitem>
-	<para>
-	  There can not be any direct communication between work units.
-	</para>
-      </listitem>
-    </itemizedlist>
-  </para>
-
-</sect1>
-<!-- vim: set ai sw=2 tw=80: -->
diff --git a/dcapi/doc/local.xml b/dcapi/doc/local.xml
deleted file mode 100644
index bed60ed..0000000
--- a/dcapi/doc/local.xml
+++ /dev/null
@@ -1,188 +0,0 @@
-<?xml version="1.0"?>
-<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.1.2//EN" 
-               "http://www.oasis-open.org/docbook/xml/4.1.2/docbookx.dtd">
-<sect1 id="local">
-  <title>Standalone</title>
-
-  <sect2 id="local_app">
-  <title>Standalone application</title>
-
-  <para>
-  Standalone backend does not use any special execution environment to
-  execute client jobs. Clients are spawned as local processes so the
-  master and all workers are running as local processes on the same
-  host. The execution host must be a UNIX wokstation because this is
-  the only supported platform for this backend yet.
-  </para>
-
-  <sect3 id="local_name">
-  <title>Name of the standalone backend</title>
-
-  <para>The name of this backend is:</para>
-
-  <para><emphasis>local</emphasis></para>
-
-  <para>This name must be used to identify the backend when using the
-  library to <link linkend="build-unix">build
-  application</link>.</para>
-
-  </sect3>
-
-  <sect3 id="local_exec">
-  <title>Execution of clients</title>
-
-  <para> Call of <function><link
-  linkend="DC-submitWU">DC_submitWU()</link></function> in master
-  process spawns a new UNIX process using
-  <function>fork</function>/<function>exec</function> mechanism and
-  starts the executable of the client. Client changes its directory to
-  its own working directory which is prepared by the master for
-  it.</para>
-
-  <para>Event handling procedures of the master process
-  (<function><link
-  linkend="DC-waitWUEvent">DC_waitWUEvent()</link></function>,
-  <function><link
-  linkend="DC-processMasterEvents">DC_processMasterEvents()</link></function>,
-  etc.) check the operating system for the client's process and report
-  it as finished when it disapears.</para>
-
-  </sect3>
-
-  <sect3 id="local_messaging">
-  <title>Message passing</title>
-
-  <para>It is possible to send messages between the master and a
-  client (see <function><link
-  linkend="DC-sendMessage">DC_sendMessage()</link></function> and
-  <function><link
-  linkend="DC-sendResult">DC_sendResult()</link></function>
-  functions). Messages are passed as files. Message files are placed
-  in "message boxes", which are directories created in client's
-  working directory. Name of the message box directories can be
-  specified by configuration options (see <link
-  linkend="local_ClientMessageBox">ClientMessageBox</link>, and <link
-  linkend="local_MasterMessageBox">MasterMessageBox</link>), so they
-  will not interfere with client's own created files and
-  directories.</para>
-
-  <para>This backend maintains order of the messages so they will be
-  received in the same order as they were sent.</para>
-
-  </sect3>
-
-  </sect2>
-
-  <sect2 id="local_configuration">
-  <title>Configuration options</title>
-
-    <variablelist>
-
-        <varlistentry>
-	  <term>InstanceUUID</term>
-	  <listitem>
-	    <para>
-
-	    REQUIRED. Identification of running instance of the
-	    application. For Standalone backend it can be any string not
-	    just an UUID.
-
-	    </para>
-	  </listitem>
-        </varlistentry>
-
-        <varlistentry>
-	  <term>WorkingDirectory</term>
-	  <listitem>
-	    <para>
-	    
-	    REQUIRED. Name of working directory of the
-	    application. All files that are generated by the
-	    application or the DC-API library are placed under this
-	    directory. Different applications can use the same working
-	    directory because every instance has its own subdirectory
-	    there.
-
-	    </para>
-	  </listitem>
-	</varlistentry>
-
-        <varlistentry id="local_ClientMessageBox">
-	  <term>ClientMessageBox</term>
-	  <listitem>
-	    <para>
-
-	    Name of the directory in workunit's working directory
-	    where messages are placed which are sent by the client to
-	    the master by <function><link
-	    linkend="DC-sendMessage">DC_sendMessage()</link></function>. Default
-	    value is <filename>_dcapi_client_messages</filename>.
-
-	    </para>
-	  </listitem>
-	</varlistentry>
-
-	<varlistentry id="local_MasterMessageBox">
-	  <term>MasterMessageBox</term>
-	  <listitem>
-	    <para>
-
-	    Name of the directory in workunit's working directory
-	    where <function><link
-	    linkend="DC-sendWUMessage">DC_sendWUMessage()</link></function>
-	    places messages sent by the master to the client. Default
-	    value is <filename>_dcapi_master_messages</filename>.
-
-	    </para>
-	  </listitem>
-	</varlistentry>
-
-	<varlistentry>
-	  <term>SubresultBox</term>
-	  <listitem>
-	    <para>
-
-	    Name of the directory in workunit's working directory
-	    where <function><link
-	    linkend="DC-sendResult">DC_sendResult()</link></function>
-	    places subresults generated by the client. Default
-	    value is <filename>_dcapi_client_subresults</filename>.
-
-	    </para>
-	  </listitem>
-	</varlistentry>
-
-	<varlistentry>
-	  <term>Executable</term>
-	  <listitem>
-	    <para>
-
-	    Name of the executable file of the client (workunit). By
-	    default it is the <parameter>clientName</parameter>
-	    parameter which was passed to <function><link
-	    linkend="DC-createWU">DC_createWU()</link></function>.
-
-	    </para>
-	  </listitem>
-	</varlistentry>
-
-	<varlistentry>
-	  <term>LeaveFiles</term>
-	  <listitem>
-	    <para>
-	    
-	    Specifies if files, directories generated in workunit's
-	    working directory should be deleted or not after workunit
-	    ends. Zero value means delete and non-zero value means not
-	    to delete. Default value is 0.
-
-	    </para>
-	  </listitem>
-	</varlistentry>
-
-    </variablelist>
-
-  </sect2>
-</sect1>
-
-<!-- End of local.xml -->
diff --git a/dcapi/doc/states.fig b/dcapi/doc/states.fig
deleted file mode 100644
index d46f2fe..0000000
--- a/dcapi/doc/states.fig
+++ /dev/null
@@ -1,108 +0,0 @@
-#FIG 3.2  Produced by xfig version 3.2.5-alpha5
-Landscape
-Center
-Metric
-A4      
-100.00
-Single
--2
-1200 2
-5 1 0 1 0 7 50 -1 -1 3.000 0 1 1 0 1943.603 2825.830 765 1575 225 2835 2610 4410
-	0 0 1.00 60.00 120.00
-5 1 0 1 0 7 50 -1 -1 3.000 0 1 1 0 4962.663 2326.311 5625 4275 7020 2385 5985 540
-	0 0 1.00 60.00 120.00
-6 4410 4095 5625 4455
-2 2 0 1 0 7 50 -1 -1 0.000 0 0 -1 0 0 5
-	 4410 4095 5625 4095 5625 4455 4410 4455 4410 4095
-4 0 0 50 -1 0 12 0.0000 4 135 855 4590 4342 FINISHED\001
--6
-6 1800 405 2835 765
-2 2 0 1 0 7 50 -1 -1 0.000 0 0 -1 0 0 5
-	 1800 405 2835 405 2835 765 1800 765 1800 405
-4 0 0 50 -1 0 12 0.0000 4 135 660 1987 652 READY\001
--6
-6 585 2700 2070 3060
-2 2 0 1 0 7 50 -1 -1 0.000 0 0 -1 0 0 5
-	 585 2700 2070 2700 2070 3060 585 3060 585 2700
-4 0 0 50 -1 0 12 0.0000 4 135 1095 780 2947 SUSPENDED\001
--6
-6 765 1395 2115 1755
-2 2 0 1 0 7 50 -1 -1 0.000 0 0 -1 0 0 5
-	 765 1395 2115 1395 2115 1755 765 1755 765 1395
-4 0 0 50 -1 0 12 0.0000 4 135 870 1005 1642 RUNNING\001
--6
-6 2610 4230 3870 4590
-2 2 0 1 0 7 50 -1 -1 0.000 0 0 -1 0 0 5
-	 2610 4230 3870 4230 3870 4590 2610 4590 2610 4230
-4 0 0 50 -1 0 12 0.0000 4 135 915 2782 4477 ABORTED\001
--6
-6 4365 405 5985 765
-2 2 0 1 0 7 50 -1 -1 0.000 0 0 -1 0 0 5
-	 4365 405 5985 405 5985 765 4365 765 4365 405
-4 0 0 50 -1 0 12 0.0000 4 165 1140 4605 637 NOT_EXISTS\001
--6
-6 5265 2610 6660 2970
-2 2 0 1 0 7 50 -1 -1 0.000 0 0 -1 0 0 5
-	 5265 2610 6660 2610 6660 2970 5265 2970 5265 2610
-4 0 0 50 -1 0 12 0.0000 4 135 990 5467 2857 UNKNOWN\001
--6
-2 1 0 1 0 7 50 -1 -1 0.000 0 0 -1 1 0 2
-	0 0 1.00 60.00 120.00
-	 2340 765 1440 1395
-2 1 0 1 0 7 50 -1 -1 3.000 0 0 -1 1 0 2
-	0 0 1.00 60.00 120.00
-	 2115 1575 5175 765
-2 1 0 1 0 7 50 -1 -1 3.000 0 0 -1 1 0 2
-	0 0 1.00 60.00 120.00
-	 2070 2880 5220 765
-2 1 0 1 0 7 50 -1 -1 3.000 0 0 -1 1 0 2
-	0 0 1.00 60.00 120.00
-	 3285 4230 5220 765
-2 1 0 1 0 7 50 -1 -1 3.000 0 0 -1 1 0 2
-	0 0 1.00 60.00 120.00
-	 1305 3060 3285 4230
-2 1 1 1 0 7 50 -1 -1 4.000 0 0 -1 1 0 2
-	0 0 1.00 60.00 120.00
-	 2115 1575 5040 4095
-2 1 1 1 0 7 50 -1 -1 4.000 0 0 -1 1 0 2
-	0 0 1.00 60.00 120.00
-	 2115 1575 3285 4230
-2 1 2 1 0 7 50 -1 -1 3.000 0 0 -1 1 0 2
-	0 0 1.00 60.00 120.00
-	 2115 1575 5265 2790
-2 1 2 1 0 7 50 -1 -1 3.000 0 0 -1 1 0 2
-	0 0 1.00 60.00 120.00
-	 2070 2880 5265 2790
-2 1 2 1 0 7 50 -1 -1 3.000 0 0 -1 1 0 2
-	0 0 1.00 60.00 120.00
-	 5040 4095 5895 2970
-2 1 2 1 0 7 50 -1 -1 3.000 0 0 -1 1 0 2
-	0 0 1.00 60.00 120.00
-	 3285 4230 5265 2790
-2 1 0 1 0 7 50 -1 -1 0.000 0 0 -1 1 0 2
-	0 0 1.00 60.00 120.00
-	 1305 1755 1305 2700
-2 1 0 1 0 7 50 -1 -1 0.000 0 0 -1 1 0 2
-	0 0 1.00 60.00 120.00
-	 1440 2700 1440 1755
-2 1 0 1 0 7 50 -1 -1 3.000 0 0 -1 1 0 2
-	0 0 1.00 60.00 120.00
-	 4365 540 2835 540
-2 1 0 1 0 7 50 -1 -1 3.000 0 0 -1 1 0 2
-	0 0 1.00 60.00 120.00
-	 2835 630 4365 630
-2 1 0 1 0 7 50 -1 -1 3.000 0 0 -1 1 0 2
-	0 0 1.00 60.00 120.00
-	 5940 2610 5580 765
-4 0 0 50 -1 0 10 0.0000 4 150 750 495 2565 suspendWU\001
-4 0 0 50 -1 0 10 0.0000 4 105 705 1485 2565 resumeWU\001
-4 0 0 50 -1 0 10 0.0000 4 105 705 1170 1080 submitWU\001
-4 0 0 50 -1 0 10 0.0000 4 105 645 1665 4455 cancelWU\001
-4 0 0 50 -1 0 10 0.0000 4 135 735 3105 1125 destroyWU\001
-4 0 0 50 -1 0 10 0.0000 4 135 735 3555 1485 destroyWU\001
-4 0 0 50 -1 0 10 0.0000 4 135 735 4140 1710 destroyWU\001
-4 0 0 50 -1 0 10 0.0000 4 105 630 3285 495 createWU\001
-4 0 0 50 -1 0 10 0.0000 4 135 735 3285 765 destroyWU\001
-4 0 0 50 -1 0 10 0.0000 4 135 735 5445 1215 destroyWU\001
-4 0 0 50 -1 0 10 0.0000 4 135 735 6300 720 destroyWU\001
-4 0 0 50 -1 0 10 0.0000 4 105 645 1575 3735 cancelWU\001
diff --git a/dcapi/doc/tmpl/dc-unused.sgml b/dcapi/doc/tmpl/dc-unused.sgml
deleted file mode 100644
index e69de29..0000000
diff --git a/dcapi/doc/tmpl/dc.sgml b/dcapi/doc/tmpl/dc.sgml
deleted file mode 100644
index 153b4ce..0000000
--- a/dcapi/doc/tmpl/dc.sgml
+++ /dev/null
@@ -1,608 +0,0 @@
-<!-- ##### SECTION Title ##### -->
-Master
-
-<!-- ##### SECTION Short_Description ##### -->
-functionality specific to the master-side of DC-API.
-
-<!-- ##### SECTION Long_Description ##### -->
-<para>
-  This section describes the functions and definitions available for DC-API
-  master applications.
-</para>
-
-<!-- ##### SECTION See_Also ##### -->
-<para>
-
-</para>
-
-<!-- ##### SECTION Stability_Level ##### -->
-
-
-<!-- ##### SECTION Image ##### -->
-
-
-<!-- ##### ENUM DC_WUState ##### -->
-<para>
-State of work units.
-</para>
-
- at DC_WU_READY: ready for submission.
- at DC_WU_RUNNING: submitted to the grid infrastructure. Note that this does not
-	mean that the work unit is really running as it might be queued etc.
- at DC_WU_FINISHED: the work unit has completed successfuly.
- at DC_WU_SUSPENDED: the work unit is suspended.
- at DC_WU_ABORTED: the work unit has aborted either due to an error or due to the
-	user calling DC_cancelWU().
- at DC_WU_UNKNOWN: DC-API is not able to determine the state of the work unit.
-
-<!-- ##### ENUM DC_MasterEventType ##### -->
-<para>
-Types of events the master application may receive.
-</para>
-
- at DC_MASTER_RESULT: a new #DC_Result is available.
- at DC_MASTER_SUBRESULT: a subresult has arrived.
- at DC_MASTER_MESSAGE: a message has arrived.
-
-<!-- ##### STRUCT DC_Workunit ##### -->
-<para>
-Opaque type representing a work unit. A work unit consists of an executable
-client application together with its command-line parameters and input
-files.
-</para>
-
-
-<!-- ##### STRUCT DC_Result ##### -->
-<para>
-Opaque type representing the result of a successfully completed work unit.
-The result structure contains the output files the work unit produced as
-well as (optionally, depending on the infrastructure) its exit code, standard
-output and error, and any log file created by the grid infrastructure.
-</para>
-
-
-<!-- ##### STRUCT DC_MasterEvent ##### -->
-<para>
-Describes an event received by the master application.
-</para>
-
- at type: the type of the event.
- at wu: the work unit that generated the event.
- at result: the received #DC_Result if @type is %DC_MASTER_RESULT.
- at subresult: the received subresult if @type is %DC_MASTER_SUBRESULT.
- at message: the received message if @type is %DC_MASTER_MESSAGE.
-
-<!-- ##### USER_FUNCTION DC_ResultCallback ##### -->
-<para>
-Prototype of the callback function used for reporting results.
-</para>
-
- at wu: the work unit this result belongs to.
- at result: the received result.
-
-
-<!-- ##### USER_FUNCTION DC_SubresultCallback ##### -->
-<para>
-Prototype of the callback function used for reporting subresults. Note that
-if the infrastructure supports redundant computation, subresults may arrive
-from all running instances, even if they will be later marked as invalid.
-</para>
-
- at wu: the work unit this subresult belongs to.
- at logicalFileName: logical name of the received file, if specified by the
-	client.
- at path: the real path name of the received file.
-
-
-<!-- ##### USER_FUNCTION DC_MessageCallback ##### -->
-<para>
-Prototype of the callback function used for reporting messages. Note that
-if the infrastructure supports redundant computation, the master will receive
-messages from all running client instances, even if they will be later marked
-as invalid.
-</para>
-
- at wu: the work unit the message is for.
- at message: contents of the message.
-
-
-<!-- ##### FUNCTION DC_initMaster ##### -->
-<para>
-Initializes the master side of the DC-API. This function must be called first
-before calling any other DC-API functions.
-</para>
-
- at configFile: name of the configuration file to use. %NULL means use
-	%DC_CONFIG_FILE.
- at Returns: 0 if successful or a #DC_ErrorCode.
-
-
-<!-- ##### FUNCTION DC_setMasterCb ##### -->
-<para>
-Sets the callback functions to be used for event reporting. One or more of the
-callbacks may be %NULL if the master does not wish to receive the specific
-event.
-</para>
-<para>
-This function is deprecated, use the separate DC_setMessageCb(), DC_setResultCb()
-and DC_setSubresultCb() functions instead.
-</para>
-
- at resultcb: the callback to be used to report results.
- at subresultcb: the callback to be used to report subresults.
- at msgcb: the callback for reporting messages.
-
-
-<!-- ##### FUNCTION DC_setMessageCb ##### -->
-<para>
-Sets the callback function that will be called when the master receives a
-new message from one of the running workunits.
-</para>
-
- at cb: the callback to be used to report messages.
-
-
-<!-- ##### FUNCTION DC_setResultCb ##### -->
-<para>
-Sets the callback function that will be called when a workunit finishes.
-</para>
-
- at cb: the callback to be used to report results.
-
-
-<!-- ##### FUNCTION DC_setSubresultCb ##### -->
-<para>
-Sets the callback function that will be called when a subresult becomes available.
-</para>
-
- at cb: the callback to be used to report subresults.
-
-
-<!-- ##### FUNCTION DC_processMasterEvents ##### -->
-<para>
-Processes work unit events. In case of a work unit completes and its result is
-available, or if a message or a subresult has arrived, the appropriate callback
-functions will be called.
-</para>
-<para>
-The received event will be automatically destroyed when the callback function
-returns (including the deletion of files if the event was a result or
-subresult). If the master application wants to access any information belonging
-to the event (e.g. the output files the client created), then the callback
-function must explicitely make a copy of any data it is interested in. In case
-of physical files (i.e., results and subresults), the callback is allowed to
-simply rename the files therefore preventing DC-API from deleting them.
-</para>
-
- at timeout: time to wait (in seconds) for an event to arrive. 0 means do not wait
-	if there are no events to process.
- at Returns: 0 if successful or a #DC_ErrorCode.
-
-
-<!-- ##### FUNCTION DC_waitMasterEvent ##### -->
-<para>
-  Checks for events and returns them directly. This function does not invoke any
-  event-processing callbacks.
-  <note>
-    <para>
-      Contrary to DC_processMasterEvents(), the application is responsible for
-      destroying the returned event when it is no longer needed.
-    </para>
-  </note>
-</para>
-
- at wuFilter: if not %NULL, only work units having a tag that matches @wuFilter
-	will be checked for events.
- at timeout: time to wait (in seconds) for an event to arrive. 0 means do not wait
-	if there are no events to process.
- at Returns: an event if one is available or %NULL if a timeout has occured. The
-	returned event must be destroyed using DC_destroyMasterEvent() when it is
-	no longer needed.
-
-
-<!-- ##### FUNCTION DC_waitWUEvent ##### -->
-<para>
-  Checks for events for a particular work unit. This function does not invoke any
-  event-processing callbacks.
-  <note>
-    <para>
-      Contrary to DC_processMasterEvents(), the application is responsible for
-      destroying the returned event when it is no longer needed.
-    </para>
-  </note>
-</para>
-
- at wu: the work unit that should be watched for events.
- at timeout: time to wait (in seconds) for an event to arrive. 0 means do not wait
-	if there are no events to process.
- at Returns: an event if one is available or %NULL if a timeout has occured. The
-	returned event must be destroyed using DC_destroyMasterEvent() when it is
-	no longer needed.
-
-
-<!-- ##### FUNCTION DC_destroyMasterEvent ##### -->
-<para>
-Destroys a #DC_MasterEvent obtained by calling DC_waitMasterEvent() or DC_waitWUEvent().
-</para>
-
- at event: the #DC_MasterEvent to destroy.
-
-
-<!-- ##### FUNCTION DC_getWUNumber ##### -->
-<para>
-Returns the number of existing work units having the specified state.
-</para>
-
- at state: the state to query.
- at Returns: the number of work units in state @state or -1 if @state is invalid.
-
-
-<!-- ##### FUNCTION DC_createWU ##### -->
-<para>
-Creates a new work unit. The work unit is not known to the underlying grid
-infrastructure until DC_submitWU() is called. The returned work unit is in
-the %DC_WU_READY state.
-</para>
-
- at clientName: logical name of the client application. Mapping this name to an
-	real binary executable depends on the DC-API backend in use.
- at arguments: %NULL-terminated list of command line arguments.
- at subresults: number of subresults the client will be allowed to generate.
-	Specify 0 if the client will not send back any subresults.
- at tag: arbitrary string to attach to this work unit. The value of this
-	string is not used by the DC-API itself, it is free for the application
-	writer to make use of it.
- at Returns: a #DC_Workunit if successful or %NULL if there was not enough memory
-	to allocate the structure.
-
-
-<!-- ##### FUNCTION DC_addWUInput ##### -->
-<para>
-Adds an input file to a work unit. This function may be called only for work
-units in state %DC_WU_READY (i.e., before the work unit is submitted).
-</para>
-
- at wu: the work unit to add the input file to.
- at logicalFileName: the logical file name the client will use to refer to this
-	input file. The client should call the DC_resolveFileName() function
-	with the %DC_FILE_IN file type and this name to get the real name of
-	the file on the local system.
- at URL: URL of the input file. May also be a local path on the master's
-	file system.
- at fileMode: usage mode of the file. Passing %DC_FILE_PERSISTENT or
-	%DC_FILE_VOLATILE allows DC-API to optimize the disk space
-	requirements of the application.
- at Varargs: in case using %DC_FILE_REMOTE file mode, the MD5 hash string (char *)
-	and file size information (size_t) have to be passed.
- at Returns: 0 if successful or a #DC_ErrorCode.
-
-
-<!-- ##### FUNCTION DC_addWUOutput ##### -->
-<para>
-Adds an output file specification to a work unit. Files registered using this
-function will be transferred back to the master when the client finishes. This
-function may be called only for work units in state %DC_WU_READY (i.e., before
-the work unit is submitted).
-</para>
-
- at wu: the work unit to add the output file definition to.
- at logicalFileName: the logical file name the client will use to refer to this
-	output file. The client should call the DC_resolveFileName() function
-	with the %DC_FILE_OUT file type and this name to get the real name of
-	the file on the local system.
- at Returns: 0 if successful or a #DC_ErrorCode.
-
-
-<!-- ##### FUNCTION DC_setWUPriority ##### -->
-<para>
-Sets the priority of a work unit. Depending on the underlying grid
-infrastructure, this function may be called only for work units in state
-%DC_WU_READY (i.e., before the work unit is submitted). The priority
-value may be in the range 1-100, higher number meaning more important
-work unit. The default priority is 50. Note that not all infrastructures
-support priorities and the number of supported levels may be fewer than 100.
-</para>
-
- at wu: the work unit.
- at priority: the priority of the work unit.
- at Returns: 0 if successful or a #DC_ErrorCode.
-
-
-<!-- ##### FUNCTION DC_setWUBatch ##### -->
-<para>
-Sets the batch identifier of a work unit. Batch identifier reflects the 
-corresponding workunits. Workunits with the same batch identifier belongs
-to the same group of workunits. Depending on the underlying grid
-infrastructure, this function may be called only for work units in state
-%DC_WU_READY (i.e., before the work unit is submitted). The batch value 
-may be in the range of an integer. The default batch is 0. Note that not 
-all infrastructures support batch handling.
-</para>
-
- at wu: the work unit.
- at batch: the batch identifier of the work unit.
- at Returns: 0 if successful or a #DC_ErrorCode.
-
-
-<!-- ##### FUNCTION DC_serializeWU ##### -->
-<para>
-Serializes a #DC_Workunit structure. The returned string may be stored on
-persistent storage and can be used to re-create the work unit description
-in a different process. The format of the returned string is not specified,
-the only guarantee DC-API gives is that it will not contain newline
-characters.
-</para>
-
- at wu: the work unit to serialize.
- at Returns: a string that can be passed to DC_deserializeWU() to restore the
-	work unit. %NULL is returned if the serialization fails. The returned
-	string should be de-allocated using free() when it is no longer needed.
-
-
-<!-- ##### FUNCTION DC_deserializeWU ##### -->
-<para>
-Restores a serialized work unit. May be called from a different process than
-the work unit was serialized in.
-</para>
-
- at buf: a string obtained by calling DC_serializeWU() previously.
- at Returns: a #DC_Workunit or %NULL if the de-serialization has failed.
-
-
-<!-- ##### FUNCTION DC_getWUState ##### -->
-<para>
-Queries the state of a work unit.
-</para>
-
- at wu: the work unit to examine.
- at Returns: the state of the work unit.
-
-
-<!-- ##### FUNCTION DC_submitWU ##### -->
-<para>
-Submits a work unit to the grid infrastructure. It is up to the infrastructure
-when the work unit actually begins execution.
-</para>
-
- at wu: a #DC_Workunit.
- at Returns: 0 if successful or a #DC_ErrorCode.
-
-
-<!-- ##### FUNCTION DC_getWUId ##### -->
-<para>
-Returns the infrastructure-specific low-level ID of the work unit. This
-identifier should appear in infrastructure-level log files and can be
-used to track the job if a problem with the grid infrastructure is suspected.
-</para>
-
- at wu: a #DC_Workunit.
- at Returns: the infrastructure-specific identifier. %NULL is returned if the
-	work unit is not known to the infrastructure (i.e., it has not been
-	submitted yet or it has already completed or aborted). The returned
-	value should be deallocated using free() when it is no longer needed.
-
-
-<!-- ##### FUNCTION DC_getWUTag ##### -->
-<para>
-Returns the user-specified tag of a work unit.
-</para>
-
- at wu: a #DC_Workunit.
- at Returns: the tag that was given to DC_createWU(). The returned value should be
-	deallocated using free() when it is no longer needed.
-
-
-<!-- ##### FUNCTION DC_cancelWU ##### -->
-<para>
-  Cancels all computation for a given work unit.
-  <note>
-    <para>
-      Depending on the infrastructure and the client implementation, it may take
-      a long time till all running clients are really stopped.
-    </para>
-  </note>
-</para>
-
- at wu: a #DC_Workunit to cancel.
- at Returns: 0 if successful or a #DC_ErrorCode.
-
-
-<!-- ##### FUNCTION DC_suspendWU ##### -->
-<para>
-  Suspends the execution of a work unit. If the client is running, it is
-  instructed to perform a checkpoint; the checkpoint image is then transferred
-  back to the master so it can be restarted later using DC_resumeWU().
-  <note>
-    <para>
-      Explicit support is required from both the grid infrastructure and from
-      the client application implementation in order suspend to work.
-    </para>
-  </note>
-  <note>
-    <para>
-      Suspend is not compatible with redundant computing. If the infrastructure
-      supports redundant computing, you must disable it if you want to use
-      suspend. Suspending a work unit when redundant computation is enabled can
-      have undefined effects, including silent corruption of the result.
-    </para>
-  </note>
-</para>
-
- at wu: the #DC_Workunit to suspend.
- at Returns: 0 if successful or a #DC_ErrorCode.
-
-
-<!-- ##### FUNCTION DC_resumeWU ##### -->
-<para>
-Resumes the computation of a work unit that was previously suspended using
-DC_suspendWU().
-</para>
-
- at wu: the #DC_Workunit to resume.
- at Returns: 0 if successful or a #DC_ErrorCode.
-
-
-<!-- ##### FUNCTION DC_destroyWU ##### -->
-<para>
-Destroys a work unit. All input and output files belonging to the work unit
-will be deleted, and any internal resources allocated to the work unit will be
-de-allocated. If the work unit is still running, it will be cancelled.
-</para>
-
- at wu: the #DC_Workunit to destroy.
-
-
-<!-- ##### FUNCTION DC_sendWUMessage ##### -->
-<para>
-  Sends a message to a running work unit. The message is sent asynchronously
-  and this function does not wait for the message to be delivered. Delivery of
-  the message will happen only when the client explicitely checks for it which
-  can take an arbitrary long time, depending on the infrastructure and on the
-  client implementation. The maximum allowed length of messages can be
-  determined with the DC_getMaxMessageSize() function.
-  <note>
-    <para>
-      If redundant computing is in effect, the same message is sent to all
-      currently running client instances.
-    </para>
-  </note>
-  <note>
-    <para>
-      The message may be lost if the client is not running but it queued by the
-      infrastructure's scheduler.
-    </para>
-  </note>
-</para>
-
- at wu: the target #DC_Workunit.
- at message: the message to send.
- at Returns: 0 if successful or a #DC_ErrorCode.
-
-
-<!-- ##### FUNCTION DC_getClientCfgStr ##### -->
-<para>
-Returns the value belonging to the specified key @key for the specific client
-application @clientName in the configuration file.
-</para>
-
- at clientName: the name of the client application.
- at key: the key to look up.
- at fallbackGlobal: if %TRUE and the key is not defined in the client configuration,
-	it will be looked up in the master configuration as well.
- at Returns: the value belonging to the key or %NULL if it is not defined in the
-	config file. The returned value must be deallocated using free() when it is
-	no longer needed.
-
-
-<!-- ##### FUNCTION DC_getClientCfgInt ##### -->
-<para>
-Returns the integer value belonging to the specified key @key for the
-specific client application @clientName in the configuration
-file. Unit suffixes like 'KB', 'GB' or 'hour' are also allowed.
-</para>
-
- at clientName: the name of the client application.
- at key: the key to look up.
- at defaultValue: the default value to return if the key is not defined or its value
-	cannot be interpreted as a number.
- at fallbackGlobal: if %TRUE and the key is not defined in the client configuration,
-	it will be looked up in the master configuration as well.
- at Returns: the value belonging to the key or @defaultValue if it is not defined in the
-	config file.
-
-
-<!-- ##### FUNCTION DC_getClientCfgDouble ##### -->
-<para>
-Returns the double precision floating point value belonging to the specified
-key @key for the specific client application @clientName in the configuration
-file. Unit suffixes like 'KB', 'GB' or 'hour' are also allowed.
-</para>
-
- at clientName: the name of the client application.
- at key: the key to look up.
- at defaultValue: the default value to return if the key is not defined or its value
-	cannot be interpreted as a number.
- at fallbackGlobal: if %TRUE and the key is not defined in the client configuration,
-	it will be looked up in the master configuration as well.
- at Returns: the value belonging to the key or @defaultValue if it is not defined in the
-	config file.
-
-
-<!-- ##### FUNCTION DC_getClientCfgBool ##### -->
-<para>
-Returns the boolean value belonging to the specified key @key for the specific
-client application @clientName in the configuration file.
-</para>
-
- at clientName: the name of the client application.
- at key: the key to look up.
- at defaultValue: the default value to return if the key is not defined or its value
-	cannot be interpreted as a boolean value.
- at fallbackGlobal: if %TRUE and the key is not defined in the client configuration,
-	it will be looked up in the master configuration as well.
- at Returns: the value belonging to the key or @defaultValue if it is not defined in the
-	config file.
-
-
-<!-- ##### FUNCTION DC_getResultCapabilities ##### -->
-<para>
-Determines what kind of information is present in the received result.
-</para>
-
- at result: a #DC_Result.
- at Returns: zero or more of %DC_GC_EXITCODE, %DC_GC_STDOUT, %DC_GC_STDERR and
-	%DC_GC_LOG OR'ed together.
-
-
-<!-- ##### FUNCTION DC_getResultWU ##### -->
-<para>
-Returns the work unit that generated this result.
-</para>
-
- at result: a #DC_Result.
- at Returns: the work unit that generated this result, or %NULL if it cannot be
-	determined.
-
-
-<!-- ##### FUNCTION DC_getResultExit ##### -->
-<para>
-Returns the exit code of the client application.
-</para>
-
- at result: a #DC_Result.
- at Returns: the client's exit code (the value it passed to DC_finishClient()). If
-	the %DC_GC_EXITCODE capability is not set for this result, then 0 is
-	returned.
-
-
-<!-- ##### FUNCTION DC_getResultOutput ##### -->
-<para>
-Returns the real path name for a logical output file name.
-</para>
-
- at result: a #DC_Result.
- at logicalFileName: the logical file name used by the client when creating the
-	output file. The special constants %DC_LABEL_STDOUT, %DC_LABEL_STDERR
-	and %DC_LABEL_CLIENTLOG are also recognized for returning the client's
-	standard output, error and infrastructure-generated log file,
-	repsectively.
- at Returns: the real path name of the logical file or %NULL if the client did
-	not send back a file with the requrested logical name. The returned
-	string should be deallocated using free() when it is no longer needed.
-
-
-<!-- ##### FUNCTION DC_getResultCPUTime ##### -->
-<para>
-  Returns the CPU time used for computing the result, in seconds.
-  <note>
-    <para>
-      If redundant computing is enabled, only the CPU time of the canonical
-      result is returned.
-    </para>
-  </note>
-</para>
-
- at result: a #DC_Result.
- at Returns: the CPU time needed to compute the result.
-
-
diff --git a/dcapi/doc/tmpl/dc_client.sgml b/dcapi/doc/tmpl/dc_client.sgml
deleted file mode 100644
index a58a005..0000000
--- a/dcapi/doc/tmpl/dc_client.sgml
+++ /dev/null
@@ -1,238 +0,0 @@
-<!-- ##### SECTION Title ##### -->
-Client
-
-<!-- ##### SECTION Short_Description ##### -->
-functionality specific to the client-side of DC-API.
-
-<!-- ##### SECTION Long_Description ##### -->
-<para>
-This section describes the functions and definitions available for DC-API
-applications on the client side.
-</para>
-
-<!-- ##### SECTION See_Also ##### -->
-<para>
-
-</para>
-
-<!-- ##### SECTION Stability_Level ##### -->
-
-
-<!-- ##### SECTION Image ##### -->
-
-
-<!-- ##### ENUM DC_FileType ##### -->
-<para>
-File types for the DC_resolveFileName() function. Some grid infrastructures
-use different locations for storing files of different usage, therefore DC-API
-needs to know the expected usage of logical files to be able to determine the
-correct physical location.
-</para>
-
- at DC_FILE_IN: the file is an input file.
- at DC_FILE_OUT: the file is an output file.
- at DC_FILE_TMP: the file is a temporary file that will not sent back to the master.
-
-<!-- ##### MACRO DC_CHECKPOINT_FILE ##### -->
-<para>
-Logical name of the application-level checkpoint file. See DC_resolveFileName()
-for details about checkpoint file usage.
-</para>
-
-
-
-<!-- ##### ENUM DC_ClientEventType ##### -->
-<para>
-ClientEvent types that can be received.
-</para>
-
- at DC_CLIENT_CHECKPOINT: a checkpoint should be made. The application must call
-	DC_checkpointMade() to acknowledge the request even if it does not
-	support checkpointing (it should pass a %NULL pointer as the file name
-	in this case).
- at DC_CLIENT_FINISH: the computation should be aborted.
- at DC_CLIENT_MESSAGE: a message has arrived.
-
-<!-- ##### STRUCT DC_ClientEvent ##### -->
-<para>
-ClientEvent received from the master.
-</para>
-
- at type: type of the event.
- at message: contents of the message if @type is %DC_CLIENT_MESSAGE.
-
-<!-- ##### FUNCTION DC_initClient ##### -->
-<para>
-Initializes the client API. This function must be called first before calling
-any other DC-API functions.
-</para>
-
- at void: 
- at Returns: 0 if successful or a #DC_ErrorCode.
-
-
-<!-- ##### FUNCTION DC_resolveFileName ##### -->
-<para>
-  Resolves the local name of input/output files. The real name (and path) of an
-  input/output file may be different from what the client expects. This
-  function performs the translation from the logical names used by the client
-  to the real names used by the infrastructure.
-  <note>
-    <para>
-      The client must not assume that it can read/write/create any files other
-      than the names returned by this function.
-    </para>
-  </note>
-</para>
-
-<para>
-The handling of application-level checkpoint files is special. The intention is
-to never modify an already completed checkpoint file, so even if the client
-is interrupted in the middle of writing to the checkpoint file, the previous
-checkpoint is still intact and can be used to resume computation.
-</para>
-
-<para>
-When @logicalFileName is %DC_CHECKPOINT_FILE, @type is interpreted as follows:
-  <itemizedlist>
-    <listitem>
-      <para>
-	If @type is %DC_FILE_IN, then the path name of the last completed
-	checkpoint file (as indicated by the client by calling
-	DC_checkpointMade() previously) is returned. The client must not modify
-	this file in any way. If the client did not create any checkpoints so
-	far but it was resumed from a previous checkpoint, then the path name
-	of the original checkpoint file is returned. If there are no previous
-	checkpoints at all, %NULL is returned.
-      </para>
-    </listitem>
-    <listitem>
-      <para>
-	If @type is %DC_FILE_OUT, then a name for a new non-existant checkpoint
-	file is returned. The client should write the checkpoint information to
-	this file and should call DC_checkpointMade() with this file name to
-	indicate that the checkpoint is complete. After calling
-	DC_checkpointMade(), the client is not allowed to modify the checkpoint
-	file in any way, and must call DC_resolveFileName() again to obtain a
-	new name for a new checkpoint file.
-      </para>
-    </listitem>
-  </itemizedlist>
-</para>
-
-<para>
-When @logicalFileName is not %DC_CHECKPOINT_FILE, the following rules apply:
-<itemizedlist>
-  <listitem>
-    <para>
-      If @type is %DC_FILE_IN, then @logicalFileName must be one of the
-      names the master registered using DC_addWUInput() when the work
-      unit was created.
-    </para>
-  </listitem>
-  <listitem>
-    <para>
-      If @type is %DC_FILE_OUT, then @logicalFileName must be one of
-      the names the master registered using DC_addWUOutput() when the
-      work unit was created.
-    </para>
-  </listitem>
-  <listitem>
-    <para>
-      If @type is %DC_FILE_TMP, then @logicalFileName must not match
-      any registered input or output logical names.
-    </para>
-  </listitem>
-</itemizedlist>
-</para>
-
- at type: the tpe of the file.
- at logicalFileName: the logical name of the file used by the client.
- at Returns: the real path name of the file. The value should be deallocated using
-	free() when it is no longer needed. %NULL is returned if @type is
-	invalid or @logicalFileName is not known to the infrastructure.
-
-
-<!-- ##### FUNCTION DC_sendResult ##### -->
-<para>
-Sends a sub-result file back to the master. The sending of the file may happen
-asynchronously, in this case this function will not wait for the transfer to
-finish (or even to start).
-</para>
-
- at logicalFileName: the logical name of the file to send. This identifier will be
-	received by the master.
- at path: the local path name of the file to send.
- at fileMode: tells how the file should be handled.
- at Returns: 0 if successful or a #DC_ErrorCode.
-
-
-<!-- ##### FUNCTION DC_sendMessage ##### -->
-<para>
-Sends a message to the master. The sending of the message may happen
-asynchronously, in this case this function will not wait for the transfer to
-finish (or even to start). The maximum length of a message that may be sent
-using this function can be determined by calling DC_getMaxMessageSize().
-</para>
-
- at message: the message to send.
- at Returns: 0 if successful or a #DC_ErrorCode.
-
-
-<!-- ##### FUNCTION DC_checkClientEvent ##### -->
-<para>
-Checks for client control events. The returned event should be destroyed using
-DC_destroyClientEvent() when it is no longer needed. If the returned event is
-%DC_CLIENT_CHECKPOINT but the client does not support checkpointing, it should
-still call the DC_checkpointMade() function with a %NULL argument to inform the
-grid infrastructure that no checkpoint will be delivered.
-</para>
-
- at void: 
- at Returns: a #DC_ClientEvent or %NULL if there are no outstanding events.
-
-
-<!-- ##### FUNCTION DC_destroyClientEvent ##### -->
-<para>
-Destroys an event returned by DC_checkClientEvent().
-</para>
-
- at event: the event to destroy.
-
-
-<!-- ##### FUNCTION DC_checkpointMade ##### -->
-<para>
-Informs the DC-API that an application-level checkpoint has been made.
-See the DC_resolveFileName() for a description of checkpoint file handling.
-</para>
-
- at fileName: the name of the checkpoint file. This should be a value
-	returned by DC_resolveFileName(%DC_FILE_OUT, %DC_CHECKPOINT_FILE).
-	The checkpoint file must not be modified after this
-	function has been called. @fileName can also be %NULL meaning that
-	the application does not in fact support checkpointing, but just
-	acknowledges a %DC_CLIENT_CHECKPOINT event.
-
-
-<!-- ##### FUNCTION DC_fractionDone ##### -->
-<para>
-Informs the controlling environment about the fraction of the work already
-done. Ideally this should be the CPU time used so far divided by the total CPU
-time that will be needed for the computation.
-</para>
-
- at fraction: the fraction of the work completed.
-
-
-<!-- ##### FUNCTION DC_finishClient ##### -->
-<para>
-Finishes computation. Tells the DC-API to finish this work unit and start a
-new one. All output files are transferred to the master and the master is
-notified about the completion of the work unit.
-</para>
-
- at exitcode: the return code of the process that will be reported back to the
-	master. 0 means success; any other value tells the grid infrastructure
-	that the work unit has failed.
-
-
diff --git a/dcapi/doc/tmpl/dc_common.sgml b/dcapi/doc/tmpl/dc_common.sgml
deleted file mode 100644
index 2303244..0000000
--- a/dcapi/doc/tmpl/dc_common.sgml
+++ /dev/null
@@ -1,207 +0,0 @@
-<!-- ##### SECTION Title ##### -->
-Common
-
-<!-- ##### SECTION Short_Description ##### -->
-functionality available on both the client and master side.
-
-<!-- ##### SECTION Long_Description ##### -->
-<para>
-The functions and definitions described below are available at both the
-client and master side of DC-API in the same form, but may have a
-slightly different meaning.
-</para>
-
-<!-- ##### SECTION See_Also ##### -->
-<para>
-
-</para>
-
-<!-- ##### SECTION Stability_Level ##### -->
-
-
-<!-- ##### SECTION Image ##### -->
-
-
-<!-- ##### ENUM DC_ErrorCode ##### -->
-<para>
-Error codes returned by DC-API functions.
-</para>
-
- at DC_OK: no error.
- at DC_ERR_CONFIG: configuration error (syntax error, illegal or missing values).
- at DC_ERR_DATABASE: database error.
- at DC_ERR_NOTIMPL: the function is not implemented.
- at DC_ERR_UNKNOWN_WU: the work unit is not known to DC-API.
- at DC_ERR_TIMEOUT: the operation timed out.
- at DC_ERR_BADPARAM: the function was passed illegal parameters.
- at DC_ERR_SYSTEM: a system call has failed, check errno for the reason.
- at DC_ERR_INTERNAL: an internal error occured in DC-API.
-
-<!-- ##### ENUM DC_GridCapabilities ##### -->
-<para>
-These flags define the capabilities of the underlying grid system.
-</para>
-
- at DC_GC_EXITCODE: the client's exit code is propagated to the master.
- at DC_GC_STDOUT: the client's standard output is sent back to the master.
- at DC_GC_STDERR: the client's standard error is sent back to the master.
- at DC_GC_LOG: infrastructure-specific log files are available.
- at DC_GC_SUSPEND: suspending of work units is supported.
- at DC_GC_SUBRESULT: subresults are supported.
- at DC_GC_MESSAGING: message sending is supported.
-
-<!-- ##### ENUM DC_FileMode ##### -->
-<para>
-Tells how should DC-API treat physical files passed to it.
-</para>
-
- at DC_FILE_REGULAR: the application wishes to continue using the file, so DC-API
-	must make an internal copy of it.
- at DC_FILE_PERSISTENT: the application guarantees that the file will not change
-	and will not be deleted during the lifetime of the application. This
-	lets DC-API use symbolic or hard links instead of copying to save space.
- at DC_FILE_VOLATILE: the application does not want to use the file in any way in
-	the future. DC-API will remove the file when it is no longer needed.
- at DC_FILE_REMOTE: the application uses a remote file not physically present.
-
-<!-- ##### MACRO DC_CONFIG_FILE ##### -->
-<para>
-Default name of the DC-API configuration file.
-</para>
-
-
-
-<!-- ##### MACRO DC_LABEL_STDOUT ##### -->
-<para>
-Logical name of the client's standard output used with DC_getResultOutput().
-</para>
-
-
-
-<!-- ##### MACRO DC_LABEL_STDERR ##### -->
-<para>
-Logical name of the client's standard error used with DC_getResultOutput().
-</para>
-
-
-
-<!-- ##### MACRO DC_LABEL_CLIENTLOG ##### -->
-<para>
-Logical name of the client's ifrastructure log used with DC_getResultOutput().
-</para>
-
-
-
-<!-- ##### STRUCT DC_PhysicalFile ##### -->
-<para>
-Describes a physical file.
-</para>
-
- at label: logical name of the file as used by the application.
- at path: the real path name of the file.
- at mode: usage mode of the file.
- at physicalfilename: filename to be used in case of Attic files.
- at physicalfilehash: MD5 hash and size information of Attic files.
-
-<!-- ##### STRUCT DC_RemoteFile ##### -->
-<para>
-Describes a physical file.
-</para>
-
- at label: logical name of the file as used by the application.
- at url: the URL of the file.
- at remotefilehash: the MD5 hash of the file.
- at remotefilesize: the size of the file.
-
-<!-- ##### FUNCTION DC_getCfgStr ##### -->
-<para>
-Returns the value belonging to the specified key @name in the configuration file.
-</para>
-
- at name: the key to look up.
- at Returns: the value belonging to the key or %NULL if it is not defined in the
-	config file. The returned value must be deallocated using free() when it is
-	no longer needed.
-
-
-<!-- ##### FUNCTION DC_getCfgInt ##### -->
-<para>
-Returns the integer value belonging to the specified key @name in the configuration
-file. Unit suffixes like 'KB', 'GB' or 'hour' are also allowed.
-</para>
-
- at name: the key to look up.
- at defaultValue: the default value to return if the key is not defined or its value
-	cannot be interpreted as a number.
- at Returns: the value belonging to the key or @defaultValue if it is not defined in the
-	config file.
-
-
-<!-- ##### FUNCTION DC_getCfgBool ##### -->
-<para>
-Returns the boolean value belonging to the specified key @name in the configuration
-file.
-</para>
-
- at name: the key to look up.
- at defaultValue: the default value to return if the key is not defined or its value
-	cannot be interpreted as a boolean value.
- at Returns: the value belonging to the key or @defaultValue if it is not defined in the
-	config file.
-
-
-<!-- ##### FUNCTION DC_log ##### -->
-<para>
-Emits a message to the master's log file.
-</para>
-
- at level: the severity of the. The level codes defined for the system's syslog()
-	function should be used.
- at fmt: format of the message, as per printf().
- at Varargs: any extra arguments required by @fmt.
-
-
-<!-- ##### FUNCTION DC_vlog ##### -->
-<para>
-Emits a message to the master's log file.
-</para>
-
- at level: the severity of the. The level codes defined for the system's syslog()
-	function should be used.
- at fmt: format of the message, as per printf().
- at args: any extra arguments required by @fmt.
-
-
-<!-- ##### FUNCTION DC_getMaxMessageSize ##### -->
-<para>
-Returns the maximum length of a message that DC_sendMessage() (client side) and
-DC_sendWUMessage() (master side) accepts.
-</para>
-
- at void: 
- at Returns: the maximum allowed message size.
-
-
-<!-- ##### FUNCTION DC_getMaxSubresults ##### -->
-<para>
-On the master side, returns the maximum number of sub-result files that can be
-specified when creating a new work unit.
-</para>
-<para>
-On the client side, returns the number of sub-results the client is still
-allowed to send.
-</para>
-
- at void: 
- at Returns: the number of sub-results allowed.
-
-
-<!-- ##### FUNCTION DC_getGridCapabilities ##### -->
-<para>
-Determines the capabilities of the underlying grid infrastructure.
-</para>
-
- at void: 
- at Returns: the appropriate #DC_GridCapabilities constants OR'ed together.
-
-
diff --git a/dcapi/doc/using.xml b/dcapi/doc/using.xml
deleted file mode 100644
index be69733..0000000
--- a/dcapi/doc/using.xml
+++ /dev/null
@@ -1,48 +0,0 @@
-<?xml version="1.0"?>
-<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.1.2//EN" 
-               "http://www.oasis-open.org/docbook/xml/4.1.2/docbookx.dtd">
-<sect1 id="using-for-applications">
-  <title>Using the library to build applications</title>
-
-  <sect2 id="build-unix">
-    <title>On UNIX platforms</title>
-
-    <para>
-      The DC-API library uses the <command>pkg-config</command> system to help
-      the building of applications. For every backend, two
-      <command>pkg-config</command> modules are available:
-      <literal>dcapi-<replaceable><backend></replaceable>-client</literal>
-      for building client applications and
-      <literal>dcapi-<replaceable><backend></replaceable>-master</literal>
-      for building master applications.
-    </para>
-
-    <para>
-      During compilation, the <command>pkg-config --cflags
-	<replaceable><module></replaceable></command> command gives the
-      list of compiler directives (like include file locations) that have to be
-      passed to the compiler whenever one of the DC-API headers is referenced in
-      a source file.
-    </para>
-
-    <para>
-      During linking, the <command>pkg-config --libs
-	<replaceable><module></replaceable></command> command will return
-      the list of libraries and linker options required to link the application
-      with DC-API.
-    </para>
-
-    <para>
-      If you have built DC-API from source and have installed it at a
-      non-standard location (i.e. not under <filename>/usr</filename> or
-      <filename>/usr/local</filename>), you may have to set the
-      <envar>PKG_CONFIG_PATH</envar> environment variable to point to the
-      directory where the <filename>.pc</filename> files are located in order
-      to <command>pkg-config</command> to find them.
-    </para>
-  </sect2>
-
-  <xi:include href="windows.xml" xmlns:xi="http://www.w3.org/2003/XInclude"/>
-
-</sect1>
-<!-- vim: set ai sw=2 tw=80: -->
diff --git a/dcapi/doc/windows.xml b/dcapi/doc/windows.xml
deleted file mode 100644
index 887a658..0000000
--- a/dcapi/doc/windows.xml
+++ /dev/null
@@ -1,233 +0,0 @@
-<?xml version="1.0"?>
-<!DOCTYPE sect2 PUBLIC "-//OASIS//DTD DocBook XML V4.1.2//EN" "http://www.oasis-open.org/docbook/xml/4.1.2/docbookx.dtd">
-<sect2 id="build-windows">
-  <title>On Windows</title>
-
-  <sect3>
-    <title>Prerequisites</title>
-
-    <itemizedlist>
-      <listitem>
-	<para>
-	  Microsoft Visual Studio 7.1
-	</para>
-      </listitem>
-      <listitem>
-	<para>
-	  DC-API library and header files
-	</para>
-      </listitem>
-      <listitem>
-	<para>
-	  Zip file containing the skeleton for an application
-	</para>
-      </listitem>
-    </itemizedlist>
-  </sect3>
-
-  <sect3>
-    <title>Preparing the repository</title>
-
-    <para>
-      Unzip the contents of the attached zip file. Copy the following three
-      header files of the DC-API in the <filename
-	class='directory'>include</filename> directory: <filename
-	class='headerfile'>dc_client.h</filename>, <filename
-	class='headerfile'>dc_common.h</filename>, <filename
-	class='headerfile'>dc_win32.h</filename>. Copy the following library
-      file of the DC-API in the <filename class='directory'>lib</filename>
-      directory: <filename class='libraryfile'>dc_client.lib</filename>.
-    </para>
-    <para>
-      The source code of the application goes into the <filename
-	class='directory'>src</filename> directory, which already contains an
-      application skeleton. The Visual Studio Related files are in the <filename
-	class='directory'>win_build</filename> directory.
-    </para>
-  </sect3>
-
-  <sect3>
-    <title>Using Visual Studio to compile the application</title>
-
-    <para>
-      Open the <filename>application.sln</filename> file in Microsoft Visual
-      Studio 7.1 (MVS from now on). Open up the 'Soultion Explorer' window in
-      MVS, if it is not open yet
-      (<keycombo><keycap>Ctrl</keycap><keycap>Alt</keycap><keycap>L</keycap></keycombo>).
-      In the 'Solution Explorer' window you will see the Solution called
-      'application' to which several subdirectories belong.
-    </para>
-    <para>
-      Open up the <filename class='directory'>Source Files</filename>
-      subdirectory to check that <filename>application.c</filename> is already
-      added to the solution. Double click on <filename>application.c</filename>
-      to open it up in MVS. Similarily, the header files are located in the
-      <filename class='directory'>Header Files</filename> subdirectory.
-    </para>
-
-    <sect4>
-      <title>Adding more source files to the solution</title>
-
-      <para>
-	If you want to add more header or source files, put them in the
-	<filename class='directory'>include</filename> or the <filename
-	  class='directory'>src</filename> directories, respectively.  After the
-	files are settled in place right click on the <filename
-	  class='directory'>Source Files</filename> in the 'Solution Explorer'
-	and choose
-	<menuchoice>
-	  <guimenu>Add</guimenu>
-	  <guimenuitem>Add Existing Item</guimenuitem>
-	</menuchoice>
-	from the menu to add the source files. Do the same for the header files
-	to add them to the <filename class='directory'>Header Files</filename>
-	directory.
-      </para>
-    </sect4>
-
-    <sect4>
-      <title>Developing the application</title>
-
-      <para>
-	The source file <filename>application.c</filename> already contains the
-	neccessary include files and some basic functions for an application
-	utilizing the DC-API to compile. The source is structured in an
-	intuitive way. You can use these functions to realize the several
-	functions of a BOINC application (like checkpointing) or you can clear
-	these and develop your own methods.
-      </para>
-    </sect4>
-
-    <sect4>
-      <title>Compiling the solution</title>
-
-      <para>
-	The skeleton 'application' solution is set up to compile with the
-	DC-API. In the middle part on the menu of MVS there is a drop down box
-	showing <guimenuitem>Debug</guimenuitem> or
-	<guimenuitem>Release</guimenuitem>. With this drop down box, you can
-	select different configurations to compile your application with. Before
-	compiling set this to the appropriate configuration.
-      </para>
-      <para>
-	If you compile in <guimenuitem>Debug</guimenuitem> mode,
-	<itemizedlist>
-	  <listitem>
-	    <para>
-	      you'll be able to debug the application by visually stepping
-	      through the execution,
-	    </para>
-	  </listitem>
-	  <listitem>
-	    <para>
-	      however, the executable will be bigger and will not be
-	      optimalized.
-	    </para>
-	  </listitem>
-	</itemizedlist>
-	Use this mode for debugging only.
-      </para>
-      <para>
-	If you compile in <guimenuitem>Release</guimenuitem> mode,
-	<itemizedlist>
-	  <listitem>
-	    <para>
-	      the executable will be optimalized, resulting in a faster and
-	      smaller code,
-	    </para>
-	  </listitem>
-	  <listitem>
-	    <para>
-	      however, you'll not be able to visually debug your applcation.
-	    </para>
-	  </listitem>
-	</itemizedlist>
-	Use this mode for compiling release versions.
-      </para>
-      <para>
-	To compile the application select <guimenuitem>Build
-	  solution</guimenuitem> from the <guimenu>Build</guimenu> menu or press
-	<keycap>F7</keycap>. During compilation you will see an output window
-	showing the progress of the compilation.
-      </para>
-      <para>
-	If compilation fails the last line of the output window will show:
-	<screen>
-Build: 0 succeeded, 1 failed, 0 skipped</screen>
-	Scroll back in the 'Output Window' to locate the problem and correct it
-	as neccessary.
-      </para>
-      <para>
-	If compilation is successful the last line of the output window will
-	show: <screen>
-Build: 1 succeeded, 0 failed, 0 skipped
-	</screen>
-      </para>
-      <para>
-	During compilation a subdirectory is created in the <filename
-	  class='directory'>win_build</filename>
-	directory of the repository having the same name as the current
-	configuration (Debug or Release) You will find the compiled executable
-	in these subdirectories with the name
-	<application>application_1.00_windows_intelx86.exe</application>.
-      </para>
-
-    </sect4>
-    <sect4>
-      <title>Debugging the application</title>
-
-      <para>
-	If the application is successfully compiled in
-	<guimenuitem>Debug</guimenuitem> mode, you can debug it visually. During
-	debugging the current directory where the application will look for its
-	input and output files will the <filename
-	  class='directory'>win_build</filename> directory. Copy the input files
-	of the application in the <filename
-	  class='directory'>win_build</filename> directory. Select
-	<guimenuitem>Step Into</guimenuitem> from the <guimenu>Debug</guimenu>
-	menu to start debugging or press <keycap>F11</keycap>. If the
-	application is outdated, MVS will ask to recompile it, select
-	<guimenuitem>Yes</guimenuitem>. The applcation will be started and you
-	will see a yellow arrow pointing to the current line of code to be
-	executed. Keep pressing <keycap>F11</keycap> to step through the program
-	lines. If the next call is a function, you can skip the function
-	by pressing <keycap>F10</keycap> (<guimenuitem>Step Over</guimenuitem>)
-	and continue debugging on the point where the function returns.
-      </para>
-
-      <para>
-	You can set breakpoints in the code by clicking on the grey area next to
-	the program line, where the yellow arrow moves during debugging. A big
-	red dot appears marking a breakpoint.
-      </para>
-      <para>
-	To clear the breakpoint click on the big red dot or select
-	<guimenuitem>Clear All Breakpoints</guimenuitem>
-	(<keycombo><keycap>Ctrl</keycap><keycap>Shift</keycap><keycap>F9</keycap></keycombo>)
-	from the 'Debug' menu. You can start the application in debug mode by
-	selecting <guimenuitem>Start</guimenuitem> from the
-	<guimenu>Debug</guimenu> menu, or by pressing <keycap>F5</keycap>.
-	Execution will be breaken on the point where you have set breakpoints.
-	To continue execution after a breakpoint press <keycap>F5</keycap>.
-      </para>
-      <para>
-	To stop debugging press
-	<keycombo><keycap>Shift</keycap><keycap>F5</keycap></keycombo> or select
-	the <guimenuitem>Stop Debugging</guimenuitem> item in the menu of MVS.
-      </para>
-    </sect4>
-    <sect4>
-      <title>Changing configuration properties</title>
-
-      <para>
-	You can change the properties of 'Debug' and 'Release' modes by right
-	clicking on the 'applcation' in the 'Solution Explorer' window and
-	selecting <guimenuitem>Properties</guimenuitem>. However, the
-	configuration is already set up to best suit the needs of application
-	development with DC-API so in most cases no configuration option is
-	needed to be changed.
-      </para>
-    </sect4>
-  </sect3>
-</sect2>
-<!-- vim: set ai sw=2 tw=80: -->
diff --git a/dcapi/examples/message-example/Makefile.am b/dcapi/examples/message-example/Makefile.am
deleted file mode 100644
index e4f8074..0000000
--- a/dcapi/examples/message-example/Makefile.am
+++ /dev/null
@@ -1,45 +0,0 @@
-ACLOCAL_AMFLAGS = -I .
-
-AUTOMAKE_OPTIONS = 1.7
-
-appdir = ${libdir}/boinc/apps/message-example
-app_PROGRAMS =
-app_DATA = dc-api.conf input.txt
-
-EXTRA_DIST = \
-	dc-api.conf \
-	input.txt \
-	message-example-client.xml.in \
-	message-example-master.xml.in
-
-if BUILD_CLIENT
-app_PROGRAMS += message-example-client
-app_DATA += message-example-client.xml
-endif
-
-if BUILD_MASTER
-app_PROGRAMS += message-example-master
-app_DATA += message-example-master.xml
-endif
-
-CLEANFILES = message-example-client.xml message-example-master.xml
-
-message_example_client_SOURCES = client.c common.h
-message_example_client_CPPFLAGS = $(DCAPI_CLIENT_CFLAGS)
-message_example_client_LDADD = $(DCAPI_CLIENT_LIBS)
-
-message_example_master_SOURCES = master.c common.h
-message_example_master_CPPFLAGS = $(DCAPI_MASTER_CFLAGS)
-message_example_master_LDADD = $(DCAPI_MASTER_LIBS)
-
-message-example-client.xml: message-example-client.xml.in
-	$(SED) -e "s, at PACKAGE_VERSION\@,$(PACKAGE_VERSION)," \
-		-e "s, at appdir\@,$(appdir)," \
-		-e "s, at target\@,$(target_triplet)," \
-		$< > $@
-
-message-example-master.xml: message-example-master.xml.in
-	$(SED) -e "s, at PACKAGE_VERSION\@,$(PACKAGE_VERSION)," \
-		-e "s, at appdir\@,$(appdir)," \
-		-e "s, at target\@,$(target_triplet)," \
-		$< > $@
diff --git a/dcapi/examples/message-example/client.c b/dcapi/examples/message-example/client.c
deleted file mode 100644
index f97df84..0000000
--- a/dcapi/examples/message-example/client.c
+++ /dev/null
@@ -1,155 +0,0 @@
-#ifdef HAVE_CONFIG_H
-#include <config.h>
-#endif
-
-#include <dc_client.h>
-
-#include <unistd.h>
-#include <stdlib.h>
-#include <stdio.h>
-#include <ctype.h>
-
-#include "common.h"
-
-static FILE *infile;
-static FILE *outfile;
-
-static int messages_received;
-
-/* Open input and output files, and check is there is a checkpoint file */
-static void init_files(void)
-{
-	char *file_name;
-
-	/* Open the input file */
-	file_name = DC_resolveFileName(DC_FILE_IN, INPUT_LABEL);
-	if (!file_name)
-	{
-		fprintf(stderr, "APP: Could not resolve the input file name\n");
-		DC_finishClient(1);
-	}
-
-	infile = fopen(file_name, "r");
-	if (!infile)
-	{
-		perror("APP: Could not open the input file");
-		DC_finishClient(1);
-	}
-	free(file_name);
-
-	/* Open the output file */
-	file_name = DC_resolveFileName(DC_FILE_OUT, OUTPUT_LABEL);
-	if (!file_name)
-	{
-		fprintf(stderr, "APP: Could not resolve the output file name\n");
-		DC_finishClient(1);
-	}
-
-	outfile = fopen(file_name, "w");
-	if (!outfile)
-	{
-		perror("APP: Could not open/create the output file");
-		DC_finishClient(1);
-	}
-	free(file_name);
-}
-
-static void message_arrived(const char *message)
-{
-	char reply[256];
-
-	fprintf(stderr, "APP: message: '%s' arrived, sending reply\n", message);
-
-	snprintf(reply, sizeof(reply), "Reply to: %s", message);
-	DC_sendMessage(reply);
-	messages_received++;
-}
-
-/* The real work */
-static void do_work(void)
-{
-	char buf[32];
-	int c;
-
-	while ((c = fgetc(infile)) != EOF)
-	{
-		DC_ClientEvent *event;
-
-		c = toupper(c);
-		if (fputc(c, outfile) == EOF)
-		{
-			perror("APP: fputc");
-			DC_finishClient(1);
-		}
-
-		/* Send the just-converted character to the master. This in
-		 * turn also allows receiving messages from the master */
-		snprintf(buf, sizeof(buf), "Processed %c", c);
-		DC_sendMessage(buf);
-
-		/* Real applications do real computation that takes time. Here
-		 * we just emulate it. We sleep for a long time to prevent
-		 * sending messages too often. */
-		sleep(30);
-
-		/* Check if either the master or the BOINC core client asked
-		 * us to do something */
-		event = DC_checkClientEvent();
-		if (!event)
-			continue;
-
-		if (event->type == DC_CLIENT_CHECKPOINT)
-		{
-			DC_log(LOG_INFO, "Checkpoint request received");
-			DC_checkpointMade(NULL);
-		}
-		else if (event->type == DC_CLIENT_MESSAGE)
-			message_arrived(event->message);
-
-		/* Make sure we do not leak memory */
-		DC_destroyClientEvent(event);
-	}
-
-	if (fclose(outfile))
-	{
-		perror("APP: Closing the output file has failed");
-		DC_finishClient(1);
-	}
-}
-
-int main(int argc, char *argv[])
-{
-	int retval;
-
-	retval = DC_initClient();
-	if (retval)
-	{
-		fprintf(stderr, "APP: Failed to initialize the DC-API. Return "
-			"value was %d\n", retval);
-		DC_finishClient(1);
-	}
-	fprintf(stdout, "APP: DC-API initialization was successful.\n");
-
-	init_files();
-
-	do_work();
-
-	fprintf(stdout, "APP: Work finished. Received %d messages from the "
-		"master.\n", messages_received);
-
-	DC_finishClient(0);
-	return(0); // Tho' we never reach this line
-}
-
-#ifdef _WIN32
-int WINAPI WinMain(HINSTANCE hInst, HINSTANCE hPrevInst, LPSTR Args, int WinMode)
-{
-	LPSTR command_line;
-	char *argv[100];
-	int argc;
-
-	command_line = GetCommandLine();
-	argc = parse_command_line(command_line, argv);
-	return main(argc, argv);
-}
-#endif
diff --git a/dcapi/examples/message-example/common.h b/dcapi/examples/message-example/common.h
deleted file mode 100644
index ee05c5d..0000000
--- a/dcapi/examples/message-example/common.h
+++ /dev/null
@@ -1,12 +0,0 @@
-/*
- * Common definitions used by both the master and the client
- */
-
-#ifndef COMMON_H
-#define COMMON_H
-
-/* Logical names of the input/output files */
-#define INPUT_LABEL		"in.txt"
-#define OUTPUT_LABEL		"out.txt"
-
-#endif /* COMMON_H */
diff --git a/dcapi/examples/message-example/configure.ac b/dcapi/examples/message-example/configure.ac
deleted file mode 100644
index 666c0ef..0000000
--- a/dcapi/examples/message-example/configure.ac
+++ /dev/null
@@ -1,35 +0,0 @@
-AC_INIT([Message Passing Example Application], [6.00], [desktopgrid at lpds.sztaki.hu], [message-example])
-AC_CONFIG_HEADERS([config.h])
-AC_CONFIG_SRCDIR([client.c])
-
-dnl The platform code uses the target triplet
-AC_CANONICAL_TARGET
-
-AM_INIT_AUTOMAKE([foreign])
-
-AC_PROG_CC
-
-dnl We need sed for substituting the XML templates
-AC_PATH_PROG([SED], [sed])
-
-dnl Enable extra warnings if we are using GCC
-if test "$ac_cv_c_compiler_gnu" = yes; then
-	CFLAGS="-Wall -Wmissing-prototypes -Wstrict-prototypes -Wsign-compare ${CFLAGS}"
-fi
-
-AC_ARG_ENABLE([client], AS_HELP_STRING([--disable-client], [do not build the client application]),, [enable_client=yes])
-AC_ARG_ENABLE([master], AS_HELP_STRING([--disable-master], [do not build the master application]),, [enable_master=yes])
-
-AM_CONDITIONAL([BUILD_CLIENT], [test "$enable_client" = yes])
-AM_CONDITIONAL([BUILD_MASTER], [test "$enable_master" = yes])
-
-if test "$enable_client" = yes; then
-	SZDG_DCAPI_CLIENT([], [AC_MSG_ERROR([DC-API client libraries were not found])])
-fi
-
-if test "$enable_master" = yes; then
-	SZDG_DCAPI_MASTER([], [AC_MSG_ERROR([DC-API master libraries were not found])])
-fi
-
-AC_CONFIG_FILES([Makefile])
-AC_OUTPUT
diff --git a/dcapi/examples/message-example/dc-api.conf b/dcapi/examples/message-example/dc-api.conf
deleted file mode 100644
index d362732..0000000
--- a/dcapi/examples/message-example/dc-api.conf
+++ /dev/null
@@ -1,39 +0,0 @@
-[Master]
-#--------------------------------------------------------
-# General configuration, for both BOINC and LOCAL DC-API implementation
-#--------------------------------------------------------
-
-#
-# Working directory. boinc_appmgr will set it automatically
-#
-
-WorkingDirectory = *Must be specified*
-
-#
-# UUID Instance. boinc_appmgr will set it automatically
-#
-
-InstanceUUID = *Must be specified*
-
-#
-# Debugging level
-#
-
-LogLevel = Debug
-
-#--------------------------------------------------------
-# Configuration for BOINC DC-API implementation
-#--------------------------------------------------------
-
-#
-# BOINC project root directory. boinc_appmgr will set it automatically
-#
-
-ProjectRootDir = *Must be specified*
-
-#--------------------------------------------------------
-# Configuration for LOCAL DC-API implementation
-#--------------------------------------------------------
-[Client-message-example]
-
-name = message-example-client
diff --git a/dcapi/examples/message-example/input.txt b/dcapi/examples/message-example/input.txt
deleted file mode 100644
index 1583aa3..0000000
--- a/dcapi/examples/message-example/input.txt
+++ /dev/null
@@ -1,5 +0,0 @@
-"Eml�k�l, hogy eml�kezz, ha eml�kem m�r csak eml�k lesz."
-"Nem az az igazi, akivel le tudsz �lni egy �letet,* hanem az, aki n�lk�l nem."
-"Ne s�rj, hogy v�get�rt!* �r�lj, hogy megt�rt�nt!"
-"Ha lehet, Veled...*...ha nem, n�lk�led...*...de ellened soha!"
-"Az �let �letvesz�lyes.* Eddig m�g mindenki belehalt."
diff --git a/dcapi/examples/message-example/master.c b/dcapi/examples/message-example/master.c
deleted file mode 100644
index 38a3297..0000000
--- a/dcapi/examples/message-example/master.c
+++ /dev/null
@@ -1,184 +0,0 @@
-/**************************************************
- * Message-examle Master program
- *
- * Created by: Gabor Vida
- *
- * The aim of the program is to test message passing between the master and
- * the client in a Public Resource Computing environment. The
- * program follows the client server model, therefore having a server-side and
- * a client-side part.
- *
- * This is the server-side part of the program. It creates a WorkUnit (WU) for
- * a Boinc project using the DC Application Programming Interface.  The program
- * takes a text file (input.txt) and submits it into the PRC-infrastructure,
- * where it get processed by a client. After the submittion, the master waits
- * for a user interaction (press ENTER), when the client downloaded the WU.
- * After this, the master sends a sample message to the client, which is
- * running around 5 mins on the client. If everything goes well, the client
- * will get the message, and sends back a reply. After the client has returned
- * the results of the WU, the program assimilates it.
- *
- *****************************************************/
-
-#ifdef HAVE_CONFIG_H
-#include <config.h>
-#endif
-
-#include <dc.h>
-
-#include <stdlib.h>
-#include <getopt.h>
-#include <string.h>
-#include <limits.h>
-#include <stdio.h>
-#include <errno.h>
-
-#include "common.h"
-
-/* Command line options */
-static const struct option longopts[] =
-{
-	{ "config",	required_argument,	NULL,	'c' },
-	{ "help",	no_argument,		NULL,	'h' },	
-	{ NULL }
-};
-
-static int do_exit;
-
-static void process_result(DC_Workunit *wu, DC_Result *result)
-{
-	char *tag;
-
-	/* Extract our own private identifier */
-	tag = DC_getWUTag(wu);
-	DC_log(LOG_NOTICE, "Work unit %s has completed", tag);
-
-	/* We no longer need the work unit */
-	DC_destroyWU(wu);
-	free(tag);
-
-	/* This will cause the main loop to quit */
-	do_exit = 1;
-}
-
-static void process_message(DC_Workunit *wu, const char *message)
-{
-	char *tag;
-
-	tag = DC_getWUTag(wu);
-	DC_log(LOG_NOTICE, "Message '%s' has arrived from work unit %s", message, tag);
-
-	free(tag);
-}
-
-static DC_Workunit *create_work(void)
-{
-	DC_Workunit *wu;
-
-	wu = DC_createWU("message-example", NULL, 0, "message-test");
-	if (!wu)
-	{
-		DC_log(LOG_ERR, "Work unit creation has failed");
-		exit(1);
-	}
-
-	if (DC_addWUInput(wu, INPUT_LABEL, "input.txt",	DC_FILE_PERSISTENT))
-	{
-		DC_log(LOG_ERR, "Failed to register WU input file");
-		exit(1);
-	}
-
-	if (DC_addWUOutput(wu, OUTPUT_LABEL))
-	{
-		DC_log(LOG_ERR, "Failed to register WU output file");
-		exit(1);
-	}
-
-	if (DC_submitWU(wu))
-	{
-		DC_log(LOG_ERR, "Failed to submit WU");
-		exit(1);
-	}
-
-	return wu;
-}
-
-static void print_help(const char *prog) __attribute__((noreturn));
-static void print_help(const char *prog)
-{
-	const char *p;
-
-	/* Strip the path component if present */
-	p = strrchr(prog, '/');
-	if (p)
-		prog = p;
-
-	printf("Usage: %s {-c|--config} <config file>\n", prog);
-	printf("Available options:\n");
-	printf("\t-c <file>, --config <file>\tUse the specified config. file\n");
-	printf("\t-h, --help\t\t\tThis help text\n");
-	exit(0);
-}
-
-int main(int argc, char *argv[])
-{
-	char *config_file = NULL;
-	DC_Workunit *wu;
-	int c;
-
-	while ((c = getopt_long(argc, argv, "ch", longopts, NULL)) != -1)
-	{
-		switch (c)
-		{
-			case 'c':
-				config_file = optarg;
-				break;
-			case 'h':
-				print_help(argv[0]);
-				break;
-			default:
-				exit(1);
-		}
-	}
-
-	if (optind != argc)
-	{
-		fprintf(stderr, "Extra arguments on the command line\n");
-		exit(1);
-	}
-
-	/* Specifying the config file is mandatory, otherwise the master can't
-	 * run as a BOINC daemon */
-	if (!config_file)
-	{
-		config_file = strdup("dc-api.conf");
-		fprintf(stdout, "You didn't specified the config file, use 'dc-api.conf'\n");
-	}
-
-	/* Initialize the DC-API */
-	if (DC_initMaster(config_file))
-	{
-		fprintf(stderr, "Master: DC_initMaster failed, exiting.\n");
-		exit(1);
-	}
-
-	/* Set the callbacks for receiving messages & the result */
-	DC_setMasterCb(process_result, NULL, process_message);
-
-	wu = create_work();
-	DC_log(LOG_NOTICE, "Master: Work unit has been created. Waiting "
-		"for result/message");
-
-	/* Wait for the work units to finish */
-	while (!do_exit)
-	{
-		DC_processMasterEvents(60);
-
-		/* The result processing destroys the WU, so make sure we
-		 * only try to send a message if the WU is still alive */
-		if (!do_exit)
-			DC_sendWUMessage(wu, "What's up?");
-	}
-
-	return 0;
-}
diff --git a/dcapi/examples/message-example/message-example-client.xml.in b/dcapi/examples/message-example/message-example-client.xml.in
deleted file mode 100644
index f311994..0000000
--- a/dcapi/examples/message-example/message-example-client.xml.in
+++ /dev/null
@@ -1,27 +0,0 @@
-<?xml version="1.0" standalone="no"?>
-<client>
-	<!-- Application name -->
-	<name>message-example</name>
-
-	<!-- User-friendly name for Boinc -->
-	<user_friendly_name>Messaging example</user_friendly_name>
-
-	<!-- Application version. Boinc requirements:
-	     - The version number must contain two components (major.minor)
-	     - Both component may be 1 or 2 digits long
-	     - The major version must be the same as the Boinc server major
-	       version -->
-	<version>@PACKAGE_VERSION@</version>
-
-	<platform>
-		<!-- The name of the platform -->
-		<name>@target@</name>
-
-		<!-- The name of the main client binary. It will be
-		     automatically renamed to the name expected by Boinc -->
-		<binary>message-example-client</binary>
-
-		<!-- Additional files can also be installed -->
-		<!-- <lib>winlib.dll</lib> -->
-	</platform>
-</client>
diff --git a/dcapi/examples/message-example/message-example-master.xml.in b/dcapi/examples/message-example/message-example-master.xml.in
deleted file mode 100644
index 9d1bdb1..0000000
--- a/dcapi/examples/message-example/message-example-master.xml.in
+++ /dev/null
@@ -1,41 +0,0 @@
-<?xml version="1.0" standalone="no"?>
-<!--
-	Configuration template for the message example application
--->
-<master>
-	<!-- Application name -->
-	<name>message-example</name>
-
-	<!-- Application version. There are no restrictions for the format of
-	     master version numbers -->
-	<version>@PACKAGE_VERSION@</version>
-
-	<!-- Data files used by the master -->
-	<files>
-		<file>input.txt</file>
-	</files>
-
-	<!-- Master daemon definition -->
-	<daemon>
-		<binary>message-example-master</binary>
-		<arguments>
-			<arg>--config</arg>
-			<arg>${workdir}/dc-api.conf</arg>
-		</arguments>
-	</daemon>
-
-	<!-- The application manager script will substitute the correct
-	     values for us -->
-	<dcapi-conf>dc-api.conf</dcapi-conf>
-
-	<!-- Validator daemon definition -->
-	<daemon>
-		<name>validator_for_textfiles</name>
-		<arguments>
-			<arg>-d</arg>
-			<arg>3</arg>
-			<arg>-app</arg>
-			<arg>message-example</arg>
-		</arguments>
-	</daemon>
-</master>
diff --git a/dcapi/examples/serialize-example/Makefile.am b/dcapi/examples/serialize-example/Makefile.am
deleted file mode 100644
index 1cc238f..0000000
--- a/dcapi/examples/serialize-example/Makefile.am
+++ /dev/null
@@ -1,45 +0,0 @@
-ACLOCAL_AMFLAGS = -I .
-
-AUTOMAKE_OPTIONS = 1.7
-
-appdir = ${libdir}/boinc/apps/serialize-example
-app_PROGRAMS =
-app_DATA = dc-api.conf input.txt
-
-EXTRA_DIST = \
-	dc-api.conf \
-	input.txt \
-	serialize-example-client.xml.in \
-	serialize-example-master.xml.in
-
-if BUILD_CLIENT
-app_PROGRAMS += serialize-example-client
-app_DATA += serialize-example-client.xml
-endif
-
-if BUILD_MASTER
-app_PROGRAMS += serialize-example-master
-app_DATA += serialize-example-master.xml
-endif
-
-CLEANFILES = serialize-example-client.xml serialize-example-master.xml
-
-serialize_example_client_SOURCES = client.c common.h
-serialize_example_client_CPPFLAGS = $(DCAPI_CLIENT_CFLAGS)
-serialize_example_client_LDADD = $(DCAPI_CLIENT_LIBS)
-
-serialize_example_master_SOURCES = master.c common.h
-serialize_example_master_CPPFLAGS = $(DCAPI_MASTER_CFLAGS)
-serialize_example_master_LDADD = $(DCAPI_MASTER_LIBS)
-
-serialize-example-client.xml: serialize-example-client.xml.in
-	$(SED) -e "s, at PACKAGE_VERSION\@,$(PACKAGE_VERSION)," \
-		-e "s, at appdir\@,$(appdir)," \
-		-e "s, at target\@,$(target_triplet)," \
-		$< > $@
-
-serialize-example-master.xml: serialize-example-master.xml.in
-	$(SED) -e "s, at PACKAGE_VERSION\@,$(PACKAGE_VERSION)," \
-		-e "s, at appdir\@,$(appdir)," \
-		-e "s, at target\@,$(target_triplet)," \
-		$< > $@
diff --git a/dcapi/examples/serialize-example/client.c b/dcapi/examples/serialize-example/client.c
deleted file mode 100644
index 2713263..0000000
--- a/dcapi/examples/serialize-example/client.c
+++ /dev/null
@@ -1,130 +0,0 @@
-#ifdef HAVE_CONFIG_H
-#include <config.h>
-#endif
-
-#include <dc_client.h>
-
-#include <unistd.h>
-#include <stdlib.h>
-#include <stdio.h>
-#include <ctype.h>
-
-#include "common.h"
-
-static FILE *infile;
-static FILE *outfile;
-
-/* Open input and output files, and check is there is a checkpoint file */
-static void init_files(void)
-{
-	char *file_name;
-
-	/* Open the input file */
-	file_name = DC_resolveFileName(DC_FILE_IN, INPUT_LABEL);
-	if (!file_name)
-	{
-		fprintf(stderr, "APP: Could not resolve the input file name\n");
-		DC_finishClient(1);
-	}
-
-	infile = fopen(file_name, "r");
-	if (!infile)
-	{
-		perror("APP: Could not open the input file");
-		DC_finishClient(1);
-	}
-	free(file_name);
-
-	/* Open the output file */
-	file_name = DC_resolveFileName(DC_FILE_OUT, OUTPUT_LABEL);
-	if (!file_name)
-	{
-		fprintf(stderr, "APP: Could not resolve the output file name\n");
-		DC_finishClient(1);
-	}
-
-	outfile = fopen(file_name, "w");
-	if (!outfile)
-	{
-		perror("APP: Could not open/create the output file");
-		DC_finishClient(1);
-	}
-	free(file_name);
-}
-
-/* The real work */
-static void do_work(void)
-{
-	int c;
-
-	while ((c = fgetc(infile)) != EOF)
-	{
-		DC_ClientEvent *event;
-
-		c = toupper(c);
-		if (fputc(c, outfile) == EOF)
-		{
-			perror("APP: fputc");
-			DC_finishClient(1);
-		}
-
-		/* Real applications do real computation that takes time. Here
-		 * we just emulate it */
-		sleep(3);
-
-		/* Check if either the master or the BOINC core client asked
-		 * us to do something */
-		event = DC_checkClientEvent();
-		if (!event)
-			continue;
-
-		/* If it is time, do a checkpoint */
-		if (event->type == DC_CLIENT_CHECKPOINT)
-			DC_checkpointMade(NULL);
-
-		/* Make sure we do not leak memory */
-		DC_destroyClientEvent(event);
-	}
-
-	if (fclose(outfile))
-	{
-		perror("APP: Closing the output file has failed");
-		DC_finishClient(1);
-	}
-}
-
-int main(int argc, char *argv[])
-{
-	int retval;
-
-	retval = DC_initClient();
-	if (retval)
-	{
-		fprintf(stderr, "APP: Failed to initialize the DC-API. Return "
-			"value was %d\n", retval);
-		DC_finishClient(1);
-	}
-	fprintf(stdout, "APP: DC-API initialization was successful.\n");
-
-	init_files();
-	do_work();
-	fprintf(stdout, "APP: Work finished.\n");
-
-	DC_finishClient(0);
-	return(0); // Tho' we never reach this line
-}
-
-#ifdef _WIN32
-int WINAPI WinMain(HINSTANCE hInst, HINSTANCE hPrevInst, LPSTR Args, int WinMode)
-{
-	LPSTR command_line;
-	char *argv[100];
-	int argc;
-
-	command_line = GetCommandLine();
-	argc = parse_command_line(command_line, argv);
-	return main(argc, argv);
-}
-#endif
-
-
diff --git a/dcapi/examples/serialize-example/common.h b/dcapi/examples/serialize-example/common.h
deleted file mode 100644
index ee05c5d..0000000
--- a/dcapi/examples/serialize-example/common.h
+++ /dev/null
@@ -1,12 +0,0 @@
-/*
- * Common definitions used by both the master and the client
- */
-
-#ifndef COMMON_H
-#define COMMON_H
-
-/* Logical names of the input/output files */
-#define INPUT_LABEL		"in.txt"
-#define OUTPUT_LABEL		"out.txt"
-
-#endif /* COMMON_H */
diff --git a/dcapi/examples/serialize-example/configure.ac b/dcapi/examples/serialize-example/configure.ac
deleted file mode 100644
index b48c6cf..0000000
--- a/dcapi/examples/serialize-example/configure.ac
+++ /dev/null
@@ -1,35 +0,0 @@
-AC_INIT([Example Application for master checkpoint], [6.00], [desktopgrid at lpds.sztaki.hu], [serialize-example])
-AC_CONFIG_HEADERS([config.h])
-AC_CONFIG_SRCDIR([client.c])
-
-dnl The platform code uses the target triplet
-AC_CANONICAL_TARGET
-
-AM_INIT_AUTOMAKE([foreign])
-
-AC_PROG_CC
-
-dnl We need sed for substituting the XML templates
-AC_PATH_PROG([SED], [sed])
-
-dnl Enable extra warnings if we are using GCC
-if test "$ac_cv_c_compiler_gnu" = yes; then
-	CFLAGS="-Wall -Wmissing-prototypes -Wstrict-prototypes -Wsign-compare ${CFLAGS}"
-fi
-
-AC_ARG_ENABLE([client], AS_HELP_STRING([--disable-client], [do not build the client application]),, [enable_client=yes])
-AC_ARG_ENABLE([master], AS_HELP_STRING([--disable-master], [do not build the master application]),, [enable_master=yes])
-
-AM_CONDITIONAL([BUILD_CLIENT], [test "$enable_client" = yes])
-AM_CONDITIONAL([BUILD_MASTER], [test "$enable_master" = yes])
-
-if test "$enable_client" = yes; then
-	SZDG_DCAPI_CLIENT([], [AC_MSG_ERROR([DC-API client libraries were not found])])
-fi
-
-if test "$enable_master" = yes; then
-	SZDG_DCAPI_MASTER([], [AC_MSG_ERROR([DC-API master libraries were not found])])
-fi
-
-AC_CONFIG_FILES([Makefile])
-AC_OUTPUT
diff --git a/dcapi/examples/serialize-example/dc-api.conf b/dcapi/examples/serialize-example/dc-api.conf
deleted file mode 100644
index f8fd939..0000000
--- a/dcapi/examples/serialize-example/dc-api.conf
+++ /dev/null
@@ -1,39 +0,0 @@
-[Master]
-#--------------------------------------------------------
-# General configuration, for both BOINC and LOCAL DC-API implementation
-#--------------------------------------------------------
-
-#
-# Working directory. boinc_appmgr will set it automatically
-#
-
-WorkingDirectory = *Must be specified*
-
-#
-# UUID Instance. boinc_appmgr will set it automatically
-#
-
-InstanceUUID = *Must be specified*
-
-#
-# Debugging level
-#
-
-LogLevel = Debug
-
-#--------------------------------------------------------
-# Configuration for BOINC DC-API implementation
-#--------------------------------------------------------
-
-#
-# BOINC project root directory. boinc_appmgr will set it automatically
-#
-
-ProjectRootDir = *Must be specified*
-
-#--------------------------------------------------------
-# Configuration for LOCAL DC-API implementation
-#--------------------------------------------------------
-[Client-serialize-example]
-
-name = serialize-example-client
diff --git a/dcapi/examples/serialize-example/input.txt b/dcapi/examples/serialize-example/input.txt
deleted file mode 100644
index 81fdf7b..0000000
--- a/dcapi/examples/serialize-example/input.txt
+++ /dev/null
@@ -1 +0,0 @@
-"Eml�k�l, hogy eml�kezz, ha eml�kem m�r csak eml�k lesz."
diff --git a/dcapi/examples/serialize-example/master.c b/dcapi/examples/serialize-example/master.c
deleted file mode 100644
index d9a2c11..0000000
--- a/dcapi/examples/serialize-example/master.c
+++ /dev/null
@@ -1,216 +0,0 @@
-/**************************************************
- * Checkpointing example Master program
- *
- * Created by: Gabor Vida
- *
- * The aim of the program is to test the serialize and deserialize
- * functions of the master side DC API. The program follows the
- * client server model, therefore having a server-side and
- * a client-side part.
- *
- * This is the server-side part of the program. It creates a WorkUnit (WU) for
- * a Boinc project using the DC Application Programming Interface. The program
- * takes a text file (input.txt) and submits it into the PRC-infrastructure,
- * where it get processed by a client. After the submittion, the master makes a
- * checkpoint with the DC_serializeWU function, than exits.
- * At the next start is tries to deserialize the saved WU, and waits for the result.
- * If everything goes well, the master will get the result of the serialized and
- * deserialized WorkUnit.
- *
- *****************************************************/
-
-#ifdef HAVE_CONFIG_H
-#include <config.h>
-#endif
-
-#include <dc.h>
-
-#include <stdlib.h>
-#include <getopt.h>
-#include <string.h>
-#include <limits.h>
-#include <stdio.h>
-#include <errno.h>
-#include <unistd.h>
-
-#include "common.h"
-
-#define CHECKPOINT_LABEL	"ckpt.txt"
-
-static int finished_wus;
-
-static DC_Workunit *workunit;
-
-/* Command line options */
-static const struct option longopts[] =
-{
-	{ "config",	required_argument,	NULL,	'c' },
-	{ "help",	no_argument,		NULL,	'h' },	
-	{ NULL }
-};
-
-static void create_ckpt(void)
-{
-	FILE *f;
-	char *ckpt;
-
-	f = fopen(CHECKPOINT_LABEL, "w");
-	if (!f)
-	{
-		DC_log(LOG_ERR, "Failed to open ckpt file (%s) for writing.", CHECKPOINT_LABEL);
-		exit(1);
-	}
-
-	ckpt = DC_serializeWU(workunit);
-
-	fprintf(f, "%s", ckpt);
-	fclose(f);
-
-	DC_log(LOG_NOTICE, "Master: serialized: %s", ckpt);
-}
-
-static void create_work(void)
-{
-	workunit = DC_createWU("serialize-example", NULL, 0, "serialize-test");
-	if (!workunit)
-	{
-		DC_log(LOG_ERR, "Work unit creation has failed");
-		exit(1);
-	}
-
-	if (DC_addWUInput(workunit, INPUT_LABEL, "input.txt",	DC_FILE_PERSISTENT))
-	{
-		DC_log(LOG_ERR, "Failed to register WU input file");
-		exit(1);
-	}
-
-	if (DC_addWUOutput(workunit, OUTPUT_LABEL))
-	{
-		DC_log(LOG_ERR, "Failed to register WU output file");
-		exit(1);
-	}
-
-	if (DC_submitWU(workunit))
-	{
-		DC_log(LOG_ERR, "Failed to submit WU");
-		exit(1);
-	}
-}
-
-static void print_help(const char *prog) __attribute__((noreturn));
-static void print_help(const char *prog)
-{
-	const char *p;
-
-	/* Strip the path component if present */
-	p = strrchr(prog, '/');
-	if (p)
-		prog = p;
-
-	printf("Usage: %s {-c|--config} <config file>\n", prog);
-	printf("Available options:\n");
-	printf("\t-c <file>, --config <file>\tUse the specified config. file\n");
-	printf("\t-h, --help\t\t\tThis help text\n");
-	exit(0);
-}
-
-int main(int argc, char *argv[])
-{
-	DC_MasterEvent *event;
-	FILE *f;
-	char buf[512];
-	char *config_file = NULL;
-	int c;
-
-	while ((c = getopt_long(argc, argv, "ch", longopts, NULL)) != -1)
-	{
-		switch (c)
-		{
-			case 'c':
-				config_file = optarg;
-				break;
-			case 'h':
-				print_help(argv[0]);
-				break;
-			default:
-				exit(1);
-		}
-	}
-
-	if (optind != argc)
-	{
-		fprintf(stderr, "Extra arguments on the command line\n");
-		exit(1);
-	}
-
-	/* Specifying the config file is mandatory, otherwise the master can't
-	 * run as a BOINC daemon */
-	if (!config_file)
-	{
-		fprintf(stderr, "Error: the config file is not specified\n");
-		exit(1);
-	}
-
-	/* Initialize the DC-API */
-	if (DC_initMaster(config_file))
-	{
-		fprintf(stderr, "Master: DC_initMaster failed, exiting.\n");
-		exit(1);
-	}
-
-	/* Try to open checkpoint file */
-	f = fopen(CHECKPOINT_LABEL, "r");
-	if (f)
-	{
-		DC_log(LOG_NOTICE, "Master: Found checkpoint!");
-		fgets(buf, sizeof(buf), f);
-		workunit = DC_deserializeWU(buf);
-		if(!workunit)
-		{
-			DC_log(LOG_ERR, "DC_desirializeWU returned NULL for WU: %s", buf);
-			exit(1);
-		}
-		fclose(f);
-		DC_log(LOG_NOTICE, "Master: deserialized: %s", buf);
-	}
-	else
-	{
-		DC_log(LOG_NOTICE, "Master: Creating work unit");
-		create_work();
-		DC_log(LOG_NOTICE, "Master: Work unit has been created and submitted.");
-		DC_log(LOG_NOTICE, "Creating checkpoint.");
-		create_ckpt();
-		DC_log(LOG_NOTICE, "Master: Exit application. Please restart it!");
-		exit(0);
-	}
-
-	/* Wait for the work units to finish */
-	while (finished_wus == 0)
-	{
-		DC_log(LOG_NOTICE, "Master: Starting waitWUEvent with timeout 600 for the deserialized WU");
-		event = DC_waitWUEvent(workunit, 600);
-		if(!event)
-			continue;
-
-		if (event->type == DC_MASTER_RESULT)
-		{
-			char *tag;
-
-			/* Extract our own private identifier */
-			tag = DC_getWUTag(workunit);
-			DC_log(LOG_NOTICE, "Work unit %s has completed", tag);
-
-			/* We no longer need the work unit */
-			DC_destroyWU(workunit);
-
-			finished_wus++;
-
-			free(tag);
-		}
-		DC_destroyMasterEvent(event);
-	}
-
-	unlink(CHECKPOINT_LABEL);
-
-	return 0;
-}
diff --git a/dcapi/examples/serialize-example/serialize-example-client.xml.in b/dcapi/examples/serialize-example/serialize-example-client.xml.in
deleted file mode 100644
index f089164..0000000
--- a/dcapi/examples/serialize-example/serialize-example-client.xml.in
+++ /dev/null
@@ -1,27 +0,0 @@
-<?xml version="1.0" standalone="no"?>
-<client>
-	<!-- Application name -->
-	<name>serialize-example</name>
-
-	<!-- User-friendly name for Boinc -->
-	<user_friendly_name>Serialization example</user_friendly_name>
-
-	<!-- Application version. Boinc requirements:
-	     - The version number must contain two components (major.minor)
-	     - Both component may be 1 or 2 digits long
-	     - The major version must be the same as the Boinc server major
-	       version -->
-	<version>@PACKAGE_VERSION@</version>
-
-	<platform>
-		<!-- The name of the platform -->
-		<name>@target@</name>
-
-		<!-- The name of the main client binary. It will be
-		     automatically renamed to the name expected by Boinc -->
-		<binary>serialize-example-client</binary>
-
-		<!-- Additional files can also be installed -->
-		<!-- <lib>winlib.dll</lib> -->
-	</platform>
-</client>
diff --git a/dcapi/examples/serialize-example/serialize-example-master.xml.in b/dcapi/examples/serialize-example/serialize-example-master.xml.in
deleted file mode 100644
index ebc6d84..0000000
--- a/dcapi/examples/serialize-example/serialize-example-master.xml.in
+++ /dev/null
@@ -1,41 +0,0 @@
-<?xml version="1.0" standalone="no"?>
-<!--
-	Configuration template for the serialize example application
--->
-<master>
-	<!-- Application name -->
-	<name>serialize-example</name>
-
-	<!-- Application version. There are no restrictions for the format of
-	     master version numbers -->
-	<version>@PACKAGE_VERSION@</version>
-
-	<!-- Data files used by the master -->
-	<files>
-		<file>input.txt</file>
-	</files>
-
-	<!-- Master daemon definition -->
-	<daemon>
-		<binary>serialize-example-master</binary>
-		<arguments>
-			<arg>--config</arg>
-			<arg>${workdir}/dc-api.conf</arg>
-		</arguments>
-	</daemon>
-
-	<!-- The application manager script will substitute the correct
-	     values for us -->
-	<dcapi-conf>dc-api.conf</dcapi-conf>
-
-	<!-- Validator daemon definition -->
-	<daemon>
-		<name>validator_for_textfiles</name>
-		<arguments>
-			<arg>-d</arg>
-			<arg>3</arg>
-			<arg>-app</arg>
-			<arg>serialize-example</arg>
-		</arguments>
-	</daemon>
-</master>
diff --git a/dcapi/examples/uppercase-with-callback/Makefile.am b/dcapi/examples/uppercase-with-callback/Makefile.am
deleted file mode 100644
index c23039f..0000000
--- a/dcapi/examples/uppercase-with-callback/Makefile.am
+++ /dev/null
@@ -1,45 +0,0 @@
-ACLOCAL_AMFLAGS = -I .
-
-AUTOMAKE_OPTIONS = 1.7
-
-appdir = ${libdir}/boinc/apps/uppercase-example
-app_PROGRAMS =
-app_DATA = dc-api.conf input.txt
-
-EXTRA_DIST = \
-	dc-api.conf \
-	input.txt \
-	uppercase-example-client.xml.in \
-	uppercase-example-master.xml.in
-
-if BUILD_CLIENT
-app_PROGRAMS += uppercase-example-client
-app_DATA += uppercase-example-client.xml
-endif
-
-if BUILD_MASTER
-app_PROGRAMS += uppercase-example-master
-app_DATA += uppercase-example-master.xml
-endif
-
-CLEANFILES = uppercase-example-client.xml uppercase-example-master.xml
-
-uppercase_example_client_SOURCES = client.c common.h
-uppercase_example_client_CPPFLAGS = $(DCAPI_CLIENT_CFLAGS)
-uppercase_example_client_LDADD = $(DCAPI_CLIENT_LIBS)
-
-uppercase_example_master_SOURCES = master.c common.h
-uppercase_example_master_CPPFLAGS = $(DCAPI_MASTER_CFLAGS)
-uppercase_example_master_LDADD = $(DCAPI_MASTER_LIBS)
-
-uppercase-example-client.xml: uppercase-example-client.xml.in
-	$(SED) -e "s, at PACKAGE_VERSION\@,$(PACKAGE_VERSION)," \
-		-e "s, at appdir\@,$(appdir)," \
-		-e "s, at target\@,$(target_triplet)," \
-		$< > $@
-
-uppercase-example-master.xml: uppercase-example-master.xml.in
-	$(SED) -e "s, at PACKAGE_VERSION\@,$(PACKAGE_VERSION)," \
-		-e "s, at appdir\@,$(appdir)," \
-		-e "s, at target\@,$(target_triplet)," \
-		$< > $@
diff --git a/dcapi/examples/uppercase-with-callback/client.c b/dcapi/examples/uppercase-with-callback/client.c
deleted file mode 100644
index 2747e7e..0000000
--- a/dcapi/examples/uppercase-with-callback/client.c
+++ /dev/null
@@ -1,258 +0,0 @@
-#ifdef HAVE_CONFIG_H
-#include <config.h>
-#endif
-
-#include <dc_client.h>
-
-#ifdef _WIN32
-#include <windows.h>
-#include <io.h>
-#else
-#include <unistd.h>
-#include <errno.h>
-#include <time.h>
-#endif
-
-#include <stdlib.h>
-#include <stdio.h>
-#include <ctype.h>
-
-#include "common.h"
-
-static FILE *infile;
-static FILE *outfile;
-
-/* Needed to report the percentage of the work already done */
-static int frac_total_size;
-static int frac_current_pos;
-
-/* Save the value of frac_current_pos to the ckpt file */
-static void do_checkpoint(void)
-{
-	char *ckptfile_name;
-	FILE *ckptfile;
-	int retval;
-
-	/* Ensure that the output file is really on the disk before we create
-	 * the checkpoint file */
-	retval = fflush(outfile);
-	if (retval)
-	{
-		perror("APP: flushing the output file has failed");
-		DC_finishClient(1);
-	}
-
-	ckptfile_name = DC_resolveFileName(DC_FILE_OUT, DC_CHECKPOINT_FILE);
-	if (!ckptfile_name)
-	{
-		fprintf(stderr, "APP: Could not resolve the checkpoint file "
-			"name\n");
-		DC_finishClient(1);
-	}
-
-	ckptfile = fopen(ckptfile_name, "w");
-	if (!ckptfile)
-	{
-		perror("APP: Could not create the checkpoint file");
-		DC_finishClient(1);
-	}
-
-	fprintf(ckptfile, "%d", frac_current_pos);
-	retval = fclose(ckptfile);
-	if (retval)
-	{
-		perror("APP: Closing the checkpoint file has failed");
-		DC_finishClient(1);
-	}
-
-	/* Tell the DC-API that the checkpoint is ready */
-	DC_checkpointMade(ckptfile_name);
-
-	/* Update the estimation about the work done */
-	DC_fractionDone(frac_current_pos/frac_total_size);
-}
-
-/* Open input and output files, and check is there is a checkpoint file */
-static void init_files(void)
-{
-	const char *outfile_openmode = "w";
-	char *file_name;
-
-	/* Open the input file */
-	file_name = DC_resolveFileName(DC_FILE_IN, INPUT_LABEL);
-	if (!file_name)
-	{
-		fprintf(stderr, "APP: Could not resolve the input file name\n");
-		DC_finishClient(1);
-	}
-
-	infile = fopen(file_name, "rb");
-	if (!infile)
-	{
-		perror("APP: Could not open the input file");
-		DC_finishClient(1);
-	}
-	free(file_name);
-
-	/* Determine the size of the input file */
-	fseek(infile, 0, SEEK_END);
-	frac_total_size = ftell(infile);
-	fseek(infile, 0, SEEK_SET);
-
-	/* Check the checkpoint file */
-	file_name = DC_resolveFileName(DC_FILE_IN, DC_CHECKPOINT_FILE);
-	if (file_name)
-	{
-		FILE *ckptfile;
-		int ret;
-
-		ckptfile = fopen(file_name, "r");
-		if (!ckptfile)
-		{
-			perror("APP: Could not open the initial checkpoint file");
-			DC_finishClient(1);
-		}
-		free(file_name);
-
-		/* ckpt file exists: read and set everything according to it */
-		ret = fscanf(ckptfile, "%d", &frac_current_pos);
-		if (ret != 1 || frac_current_pos < 0 ||
-				frac_current_pos > frac_total_size)
-		{
-			fprintf(stderr, "APP: Failed to parse the contents of "
-				"the checkpoint file, starting from the "
-				"beginning\n");
-			frac_current_pos = 0;
-		}
-		else
-		{
-			fprintf(stderr, "APP: Found checkpoint file, starting "
-				"from position %d.\n", frac_current_pos);
-			outfile_openmode = "r+";
-		}
-		fclose(ckptfile);
-
-		fseek(infile, frac_current_pos, SEEK_SET);
-	}
-
-	/* Open the output file */
-	file_name = DC_resolveFileName(DC_FILE_OUT, OUTPUT_LABEL);
-	if (!file_name)
-	{
-		fprintf(stderr, "APP: Could not resolve the output file name\n");
-		DC_finishClient(1);
-	}
-
-	outfile = fopen(file_name, outfile_openmode);
-	if (!outfile)
-	{
-		perror("APP: Could not open/create the output file");
-		DC_finishClient(1);
-	}
-	free(file_name);
-
-	/* If we are starting from a checkpoint file, restore the state of
-	 * the output file as well */
-#ifdef _WIN32
-	_chsize(fileno(outfile), frac_current_pos);
-#else
-	ftruncate(fileno(outfile), frac_current_pos);
-#endif
-
-	fseek(outfile, 0, SEEK_END);
-}
-
-/* The real work */
-static void do_work(void)
-{
-	int c;
-#ifndef _WIN32
-	struct timespec time_to_sleep;
-#endif
-
-	while ((c = fgetc(infile)) != EOF)
-	{
-		DC_ClientEvent *event;
-
-		c = toupper(c);
-		if (fputc(c, outfile) == EOF)
-		{
-			perror("APP: fputc");
-			DC_finishClient(1);
-		}
-		frac_current_pos++;
-
-		/* Real applications do real computation here that takes time. Here
-		 * we will emulate waiting a second at the end of each line */
-
-		if (c == '\n')
-#ifdef _WIN32
-			::Sleep(1000);
-#else
-		{
-			time_to_sleep.tv_sec=1;
-			time_to_sleep.tv_nsec=0;
-			while (0 > nanosleep(&time_to_sleep, &time_to_sleep))
-				if (errno != EINTR) break;
-		}
-#endif
-
-		/* Check if either the master or the BOINC core client asked
-		 * us to do something */
-		event = DC_checkClientEvent();
-		if (!event)
-			continue;
-
-		/* If it is time, do a checkpoint */
-		if (event->type == DC_CLIENT_CHECKPOINT)
-			do_checkpoint();
-
-		/* Make sure we do not leak memory */
-		DC_destroyClientEvent(event);
-	}
-
-	if (fclose(outfile))
-	{
-		perror("APP: Closing the output file has failed");
-		DC_finishClient(1);
-	}
-}
-
-int main(int argc, char *argv[])
-{
-	int retval;
-
-	retval = DC_initClient();
-	if (retval)
-	{
-		fprintf(stderr, "APP: Failed to initialize the DC-API. Return "
-			"value was %d\n", retval);
-		DC_finishClient(1);
-	}
-	fprintf(stderr, "APP: DC-API initialization was successful.\n");
-
-	init_files();
-	do_work();
-	fprintf(stderr, "APP: Work finished.\n");
-
-	DC_finishClient(0);
-	return(0); // Tho' we never reach this line
-}
-
-#ifdef _WIN32
-
-extern int parse_command_line( char *, char ** );
-
-int WINAPI WinMain(HINSTANCE hInst, HINSTANCE hPrevInst, LPSTR Args, int WinMode)
-{
-	LPSTR command_line;
-	char* argv[100];
-	int argc;
-
-	command_line = GetCommandLine();
-	argc = parse_command_line( command_line, argv );
-	return main(argc, argv);
-}
-#endif
-
-
diff --git a/dcapi/examples/uppercase-with-callback/common.h b/dcapi/examples/uppercase-with-callback/common.h
deleted file mode 100644
index ee05c5d..0000000
--- a/dcapi/examples/uppercase-with-callback/common.h
+++ /dev/null
@@ -1,12 +0,0 @@
-/*
- * Common definitions used by both the master and the client
- */
-
-#ifndef COMMON_H
-#define COMMON_H
-
-/* Logical names of the input/output files */
-#define INPUT_LABEL		"in.txt"
-#define OUTPUT_LABEL		"out.txt"
-
-#endif /* COMMON_H */
diff --git a/dcapi/examples/uppercase-with-callback/configure.ac b/dcapi/examples/uppercase-with-callback/configure.ac
deleted file mode 100644
index 956aae8..0000000
--- a/dcapi/examples/uppercase-with-callback/configure.ac
+++ /dev/null
@@ -1,35 +0,0 @@
-AC_INIT([Uppercase Example Application], [6.00], [desktopgrid at lpds.sztaki.hu], [uppercase-example])
-AC_CONFIG_HEADERS([config.h])
-AC_CONFIG_SRCDIR([client.c])
-
-dnl The platform code uses the target triplet
-AC_CANONICAL_TARGET
-
-AM_INIT_AUTOMAKE([foreign])
-
-AC_PROG_CC
-
-dnl We need sed for substituting the XML templates
-AC_PATH_PROG([SED], [sed])
-
-dnl Enable extra warnings if we are using GCC
-if test "$ac_cv_c_compiler_gnu" = yes; then
-	CFLAGS="-Wall -Wmissing-prototypes -Wstrict-prototypes -Wsign-compare ${CFLAGS}"
-fi
-
-AC_ARG_ENABLE([client], AS_HELP_STRING([--disable-client], [do not build the client application]),, [enable_client=yes])
-AC_ARG_ENABLE([master], AS_HELP_STRING([--disable-master], [do not build the master application]),, [enable_master=yes])
-
-AM_CONDITIONAL([BUILD_CLIENT], [test "$enable_client" = yes])
-AM_CONDITIONAL([BUILD_MASTER], [test "$enable_master" = yes])
-
-if test "$enable_client" = yes; then
-	SZDG_DCAPI_CLIENT([], [AC_MSG_ERROR([DC-API client libraries were not found])])
-fi
-
-if test "$enable_master" = yes; then
-	SZDG_DCAPI_MASTER([], [AC_MSG_ERROR([DC-API master libraries were not found])])
-fi
-
-AC_CONFIG_FILES([Makefile])
-AC_OUTPUT
diff --git a/dcapi/examples/uppercase-with-callback/dc-api.conf b/dcapi/examples/uppercase-with-callback/dc-api.conf
deleted file mode 100644
index 77b31b6..0000000
--- a/dcapi/examples/uppercase-with-callback/dc-api.conf
+++ /dev/null
@@ -1,39 +0,0 @@
-[Master]
-#--------------------------------------------------------
-# General configuration, for both BOINC and LOCAL DC-API implementation
-#--------------------------------------------------------
-
-#
-# Working directory. boinc_appmgr will set it automatically
-#
-
-WorkingDirectory = *Must be specified*
-
-#
-# UUID Instance. boinc_appmgr will set it automatically
-#
-
-InstanceUUID = *Must be specified*
-
-#
-# Debugging level
-#
-
-LogLevel = Debug
-
-#--------------------------------------------------------
-# Configuration for BOINC DC-API implementation
-#--------------------------------------------------------
-
-#
-# BOINC project root directory. boinc_appmgr will set it automatically
-#
-
-ProjectRootDir = *Must be specified*
-
-#--------------------------------------------------------
-# Configuration for LOCAL DC-API implementation
-#--------------------------------------------------------
-[Client-uppercase-example]
-
-name = uppercase-example-client
diff --git a/dcapi/examples/uppercase-with-callback/input.txt b/dcapi/examples/uppercase-with-callback/input.txt
deleted file mode 100644
index f662cc0..0000000
--- a/dcapi/examples/uppercase-with-callback/input.txt
+++ /dev/null
@@ -1,233 +0,0 @@
-"Eml�k�l, hogy eml�kezz, ha eml�kem m�r csak eml�k lesz."
-"Nem az az igazi, akivel le tudsz �lni egy �letet,* hanem az, aki n�lk�l nem."
-"Ne s�rj, hogy v�get�rt!* �r�lj, hogy megt�rt�nt!"
-"Ha lehet, Veled...*...ha nem, n�lk�led...*...de ellened soha!"
-"Az �let �letvesz�lyes.* Eddig m�g mindenki belehalt."
-"Ha nem tetszik, ahogy vezetek, akkor t�n�s a j�rd�r�l!"
-"Az egypup� tev�t az k�l�nb�zteti meg a k�tpup�t�l, aki akarja"
-"Okos pil�ta nem katapult�l alag�tban."
-"�n t�maszkodom re�d,* Te t�maszkodj re�m,* �s megl�tod hogy minden rendben lesz."
-"Ha az igazs�g az utadban �ll,* ez azt jelenti, hogy rossz �ton j�rsz."
-"H�romf�le ember l�tezik.* Aki tud sz�molni �s aki nem!"
-"Egy perc hossz�s�g�t az hat�rozza meg,* hogy a WC-ajt� melyik oldal�n v�rakozol!"
-"Az is d�nt�s, ha d�ntened kell,* �s �gy d�ntesz, hogy nem d�ntesz!"
-"Egyetlen baj a semmittev�ssel,* hogy sohasem tudod, mikor v�gezt�l."
-"Egyszer kipr�b�ltam a telefon-szexet,* de a lyukak t�l kicsik voltak."
-"�ll�t�lag t�z �v m�lva v�get �r a h�t sz�k esztend�."
-"�rdekl�d�s hi�ny�ban a holnap elmarad!"
-"Azt hiszem felfordulok �s megn�zem mi van odalent."
-"Az �riember olyan vad�llat, aki valameddig tud v�rni."
-"Csak a naivak hiszik azt hogy a l�gy a szob�ban a kij�ratot keresi!"
-"M�r hetedik �ve, hogy az any�som �tj�n Kar�csonykor.* Ideje �j�tani. Id�n be is fogjuk engedni.""
-"Nem szoktam vajas kenyeret kenni...*...az n�lam m�r f�z�snek sz�m�t."
-"Ha a kukoricaolaj kukoric�b�l k�sz�l...*...akkor a babaolaj?"
-"M�r l�tom a f�nyt az alag�t v�g�n...*...de mi�rt dud�l?"
-"A menzai �tkez�s titka a gyorsas�g.* Mire r�j�ssz, hogy milyen rossz, m�r meg is etted."
-"Akkor van g�z, ha a h�lyes�g szorgalommal p�rosul!"
-"Az �let olyan, mint a forr� f�rd�.* Min�l tov�bb tart ann�l r�ncosabb leszel!"
-"Az igaz bar�t a kezedet fogja �s a sz�vedet sim�tja."
-"Az �let olyan, mint a kis�cs�m.* �lland�an vissza �t, de m�gis szeretem."
-"Az �jjel azt �lmodtam hogy megettem egy kil� vattacukrot.* Mikor fel�bredtem nem volt meg a p�rn�m."
-"A legut�bbi �lmomat �gy defini�lom, hogy de-fini-�lom."
-"Az �ram alatt l�v� alkatr�sz ugyan�gy n�z ki, mint amelyik nincs �ram alatt...*...csak m�s a fog�sa."
-"A feles�gem azzal v�dol, hogy sose figyelek r�.* Vagy valami ilyesmivel."
-"Ha a fekete doboz olyan anyagb�l van, ami mindent kib�r,* akkor mi�rt nem csin�lj�k abb�l az eg�sz rep�l�t?"
-"Olyan randa vagyok, hogy a pszichi�tern�l mindig hason kell fek�dn�m."
-"J�l csak a sz�v�vel l�t az ember...*...ami igaz�n l�nyeges az a szemnek l�thatatlan."
-"- R�vid leszek - mondta a kigy�, �s a vonat el� vetette mag�t."
-"Ha megig�rem, hogy hi�nyozni fogsz...*...elm�sz?"
-"Szabad orsz�gban szabad ember szabad akarat�bol azt mond �s azt tesz...*...amit szabad."
-"Olyan hideg volt, hogy egy �gyv�d a saj�t zseb�be tette a kez�t!"
-"A n�i nemmel ne foglalkozz!* Csak a n�i IGENnel!"
-"F�ny derult a Loch-Ness-i sz�rny titk�ra! Nincs is titk�ra..."
-"Most j�v�k egy IQ tesztr�l. Szerencsere negativ!"
-"Az alkohol �l, butit* �s savakkal aldehideket k�pez."
-"Ne vesztegesd id�det arra, aki nem tart T�ged �rdemesnek arra, hogy veled t�ltse."
-"Az �let egy h�lye j�t�k. De a grafik�ja nagyon ott van!! "
-"Egy mosoly semmibe sem ker�l, de nagyon sokat �r!"
-"Olyan levertnek �rzem magam!" - mondta a kar�..."
-"Olyan nincs, hogy vereked�s k�zben futballmeccs t�r ki?"
-"A pul�ver az a ruhadarab, amelyet a gyereknek halad�ktalanul fel kell venni, ha f�zik a mama."
-"Ha igaz az, hogy a term�szetben minden kiegyenl�t�dik,* akkor valahol nagyon sok okoss�g van elrejtve!"
-"A m�ltkor l�ttam egy ajt�t, amire az volt ki�rva, hogy N�K.* Bementem, de csak egy v�c� volt."
-"Nem mintha f�ln�k meghalni...*..csak nem akarok ottlenni, amikor bek�vetkezik."
-"Olyan ronda vagy, hogy a f�nyk�peddel fogamz�sg�tl� tablett�t lehetne rekl�mozni."
-"�vekig nem sz�ltam a feles�gemhez...* Nem akartam f�lbeszakitani."
-"Tegnap megmentettem egy l�nyt a nemi er�szakt�l...* Uralkodtam magamon."
-"Gyerekkoromban a sz�leim sokszor elk�lt�ztek. De �n mindig megtal�ltam �ket."
-"�s egy�tt alszik majd a b�r�ny �s a farkas, de a b�r�ny nem alszik majd valami j�l."
-"Egy gyorsolvas�-tanfolyam elv�gz�se ut�n* a H�bor� �s b�k�t nem eg�szen 20 perc alatt olvastam el...* Valami oroszokr�l sz�l."
-"Nem az a k�rd�s, hogy van-e menyorsz�g,* hanem hogy h�nyig van nyitva �s melyik busszal lehet odajutni."
-"Az agyam a m�sodik legkedvesebb szervem."
-"A p�nz jobb, mint a szeg�nys�g...*...m�r csak anyagi szempontb�l is."
-"Az eg�szs�g val�szin�leg a hal�l leglassabb form�ja."
-"A sziv p�ros szerv... *...csak a p�rja valaki m�sban van."
-"A v�rfert�z�s maradjon a csal�dban."
-"Megpr�b�ltalak leveg�nek n�zni, de r�j�ttem, hogy leveg� n�lk�l nem tudok �lni."
-"A l�t hat�rozza meg a tudatot...*...ha megiszod a l�t, a tudatod elsz�ll."
-"Ha azt mondt�k nem vagy �r�lt...*...f�lreinform�ltak."
-"Az ember er�s, de szive megszakad, ha azt kit szeret, szeretnie nem szabad."
-"Ma van a tegnap holnapja..."
-"A feles�gem egy f�nyerem�ny...*...meg is �t�ttem."
-"A sziv olyan, mint egy sz�l vir�g, ha nem szeretik elhervad."
-"K�lt� az, aki nem �r ki a lap sz�l�ig a k�nyvben."
-"K�nyebb utol�rni a hazug embert, ha s�nta."
-"L�gy kedves gyerekeiddel,* mert �k fogj�k neked kiv�lasztani a szoci�lis otthont."
-"Irigys�ged megtiszteltet�s sz�momra, de sajnos nem tudom viszonozni."
-"Mindenki j� valamire, ha m�sra nem, h�t elrettent� p�ld�nak."
-"Ha k�pes vagy arra, hogy a hib�idb�l tanulj, akkor m�g sokat fogsz tanulni."
-"Hatalmas kagyl�gy�jtem�nyem van, amit csak �gy elsz�rva tartok a vil�g tengerpartjain.* Tal�n m�r l�ttad Te is..."
-"A vita nemesit...*...v�gs� esetben pedig ott a l�ncf�r�sz."
-"Ha pr�b�lkozol, csal�dhatsz, de ha nem pr�b�lkozol...*...akkor v�ged."
-"Ha az elef�ntot megragadod a k�t h�ts� l�b�n�l �s az �llat menek�lni akar...*...akkor ne er�ltesd a dolgot."
-"A vizcsapb�l viz folyik...*...a g�zcsapb�l g�z...*  De mi j�n a t�zcsapb�l?"
-"A serd�l�kor akkor kezd�dik, amikor a sz�l�k kezdenek nehezen kezelhet�k lenni."
-"�ltal�ban elalv�sig �bren szoktam lenni."
-"�rdekl�d�s hi�ny�ban a holnap elmarad."
-"A t�nc egy vizszintes ir�nyu v�gy f�gg�leges kifejez�d�se."
-"Ki a hideget nem szereti...*...h�ember nem lehet."
-"A tapasztalat j� iskola, csak a tandij magas."
-"Okos vagy, ha csak a fel�t hiszed el annak, amit hallassz.* Zseni�lis, ha tudod, melyik fel�t!"
-"Ugy �rzem magam, mint f�ll�bu ember a fen�kberug� versenyen."
-"Veget�ri�nus = r�gi indi�n sz�* jelent�se: b�na vad�sz"
-"A leg�gyesebb �llat az �rge...*...buz�val teli pofazacsk�val is k�pes rep�lni,* mik�zben egy baglyot egyensulyoz a h�t�n."
-"Noone can tell me, nobody knows...*...where the wind comes from, where the wind goes..."
-"K�rustag voltam, amig r� nem j�ttek honnan j�n a zaj."
-"Megpr�b�lok �r�kk� �lni...*...eddig siker�lt..."
-"Szerelem, ha egyik a m�sikat rep�lni hagyja, de ha lezuhan,* f�l sz�rny�t k�lcs�nadja."
-"- A helymeghat�roz�st tal�n n�gyszemk�zt k�ne megbesz�lni...* - ...Kicsit lejjebb nem lehetne?"
-"...�s beleborzongok, l�tv�n, hogy N�lk�led �ltem."
-"Felirat kuty�s h�z kapuj�n:* - �n 6 m�sodperc alatt gyorsulok sz�zra. �s Te?"
-"Felirat kuty�s h�z kapuj�n:* - Kedves bet�r�! A kutya mindenkit beenged.* A gondok kifel� j�vet kezd�dnek."
-"Felirat kuty�s h�z kapuj�n:* - Vigy�zat! Kutya ugyan nincs,* de any�som itthon van!"
-"Felirat a kutyah�zon:* Az �jszakai bel�poket itt lyukasztj�k "
-"Nincs vele semmi baj, csak egyszer� a lelke, mint egy barlangrajz."
-"Annyi p�nzem van, ami b�ven kitart �letem v�g�ig...*...felt�ve, hogy ma d�lut�n n�gykor meghalok."
-"A hiba olykor a hibakeres� k�sz�l�k�ben van."
-"Az �let r�z�s �tj�n a bar�tok a leng�scsillap�t�k."
-"Ne feledd: ha valaki felbosszant, az arcodon 42 izom r�ndul�ssze.*De csup�n n�gy izom kell ahhoz, hogy kinyujtsd a kezed, �s pof�n v�gd."
-"Dud�lj nyugodtan, �ppen t�rat cser�lek..."
-"A h�lyes�g a hidrog�n mellett a legnagyobb mennyis�gben el�fordul� anyag a vil�gegyetemben"
-"M�r a j�v� sem a r�gi..."
-"A b�natomat italba akartam folytani, de tud �szni az a bestia."
-"Szeretem az extr�m sportokat, mert k�zben rengeteg �j bar�tot ismerek meg:*ment�s�ket, balesetiseket, gy�gytorn�szokat �s kedves embereket, akik kih�vt�k a ment�ket!"
-"Ismertem egy olyan cs�nya n�t, hogy amikor e-mailben elk�ldte a f�nyk�p�t,* felismerte az antiv�rus..."
-"Nekirohant, mint r�szeg f�rj a kivil�g�tatlan sodr�f�nak."
-"Az �g�ret sz�p sz�, de a Landwirtschaftausstellung m�g szebb!"
-"Ketten j�ttek ki az erd�b�l. Az egyik futva, a m�sik medve."
-"Someday you might understand...* Egy sz�p napon majd meg�rted..."
-"Live your life without regrets...* don't be someone, who they forget..."
-"Haribo macht Kinder froh, und erwachsene ebenso!"
-"Eszem faszom meg�ll..."
-"Magyarorsz�g �llamform�ja r�ntotth�s!"
-"Ez egy lelkes tansz�k!"
-"Mennyi az id�?*Nem tudom, �lland�an v�ltozik."
-"Tingles and everything..."
-"K�ssz, hogy ilyen fasz volt�l!"
-"Csal�df�m m�lys�gi bej�r�s�val kapcsolatos leveleket mag�nba k�rn�m."
-"Ez nem sziv�s...*...ez BME!"
-"Vil�gh�r� von�sn�gyes keres k�t heged�st �s egy csellist�t."
-"N�h�ny ember intelligenci�j�n manaps�g m�r egy intelligens mos�g�p is t�ltesz..."
-"Min�l bonyolultabb a helyzet, ann�l higgadtabban kell vislekedni."
-"Aj�nlom ezt azok figyelm�be, akik a tegnapi el�ad�st nem tudt�k mintav�telezni..."
-"Sz�gyen a fut�s, de a kurva anyj�t annak, aki �ld�z!"
-"WHAT!?!..."
-"El�l a t�ltosok gyorsitj�k...H�tul a bar�tok megtolj�k!"
-"�s lesz aki tudja mire val�...a 424-es csatahaj�!"
-"Mindig mondtam, hogy megmondtam..."
-"Fogadd el, hogy egyszer te vagy a galamb,*m�skor meg a szobor!"
-"Egy dolog biztos, m�gpedig az, hogy semmi sem biztos.*Vagyis nem biztos, hogy semmi sem biztos."
-"Az ember �tlagos alv�sig�nye:*csakm�g 5 perc."
-"Hamlettnek �zenem : LENNI!!!"
-"K�t dolgot nem szabad csin�lni: a tegnap est�n gondolkodni,*�s m�g egyszer annyit inni..."
-"Sz�p vagy sz�p vagy mint az �lom, �n a t�k�r garant�lom."
-"Ne menj ilyen szorosan elottem!"
-"Csak a kezd�k sz�rf�znek a neten...�n cirk�lok..."
-"K�ldtem neki egy SMS-t, hogy irja meg a telefonsz�m�t, mert elfelejtettem!"
-"Tegnap olyan inform�ci��hs�g t�rt r�m, hogy megettem egy postagalambot."
-"Sp�rolj a vizzel! F�r�dj m�sodmagaddal!"
-"Forditsd arcodat a Nap fel�, akkor az �rny�kok m�g�d ker�lnek."
-"A biztons�gi �v lehet hogy korl�toz a mozg�sban,*de m�g mindig nem annyira mint a tol�sz�k!"
-"A szenilit�sban az a legjobb,*hogy saj�t magad elol dughatod el a kar�csonyi aj�nd�kokat."
-"Andersen meghalt...*Mese nincs..."
-"A d�monokat dobol�ssal el�zni igyekvo bennsz�l�tteket len�zik a civiliz�lt amerikaiak,*akik dud�l�ssal akarj�k feloszlatni a k�zleked�si dug�kat..."
-"A sz�vegszerkeszt� elsz�ll, az ir�s megmarad."
-"Elv�rni a vil�gt�l, hogy igazs�gos legyen veled, mert j� vagy, ugyanolyan,*mintha azt v�rod egy bik�t�l, hogy ne t�madjon meg, mert veget�ri�nus vagy."
-"A s�n egy makacs mad�r.*Csak akkor hajlando rep�lni ha belerugok."
-"Ne feledd: amat�r�k �pitett�k No� b�rk�j�t - profik a Titanicot!"
-"A tizezer m�rf�ldes utaz�s is egyetlen l�p�ssel kezd�dik."
-"Tanar Ur, ugye lesz OHV? >-)"
-"The most valuable natural resource in the 21st century is the human brain..."
-"But life goes on..."
-"Mi a lehetetlen vagyunk egy lehetetlen vil�gegyetemben..."
-"Minden �llat egyenl�, de vannak k�zt�k egyenl�bbek."
-"A h�zass�g kiv�l� iskolap�lda, de �n m�g nem vagyok iskola�rett..."
-"Infinity plus shipping and handling"
-"Only always..."
-"H�rom m�gikus sz�: K�sz�n�m, K�rem, Abrakadabra"
-"Akkor lenn�nk boldogok, ha tudn�nk r�la..."
-"Ne s�llyed le a h�lye ember szintj�re, mert legy�z a rutinj�val!"
-"Az �let nem m�rf�ldk�vekbol, hanem pillanatokb�l �ll"
-"- Mennyi? / - 42. / - Mi 42? / - Mi mennyi?"
-"Gy�l�l�m a Windowst..."
-"-Think outside the box. --What box? -Exactly"
-"Ki a gomb�t szereti, rossz ember nem lehet... sok�ig."
-"Eszem szerint pesszimista vagyok, akaratom �s hitem arra vezet, hogy optimista legyek." 
-"L�gy �nmagad s tanuld meg j�l: ha majd Magadra lelsz, elveszted mind a bajt."
-"Az a puszta t�ny, hogy valaki ismeri saj�t baj�nak ok�t, m�r maga is gy�gy�t� erej�!" 
-"Okoskod�s a tett hal�la."
-"Vigy�zz! Nem csak a kard, a sz� is sebezhet."
-"Ne a p�nz�rt! Egym�s�rt �lj�nk."
-"N�h�ny orvos �lma: beteg n�lk�li betegs�g."
-"D�h�nket, f�lt�kenys�g�nket nem a t�bbi ember okozza."
-"Minden probl�m�nak t�bb t�k�letes megold�sa is van."
-"Az �let a hal�l �lma."
-"Az es� k�nnyeket s�rt az ablakra." 
-"A gondban l�v� ember seg�t�s�nek egyik legjobb m�dja egyszer�en vele lenni." 
-"Ember vagyok. �s szeretnem kell valakit." 
-"Okos enged, ha m�r szenved."
-"Te j� �g, milyen sz�p vagy!"
-"Soha ne add f�l. Soha!"
-"Ne gy�zk�dd az agyadat, a hiba a val�s�gban van."
-"A t�rv�nyek azokra vonatkoznak, akik betartj�k �ket."
-"A tigrist a vad�szat el�tt gondolatban el kell ejteni, a t�bbi csak formalit�s."
-"Minden ember annyit �r, amennyit �nmag�n dolgozott." 
-"Marathonn�l a rem�nytelens�g gy�zedelmeskedett."
-"Az �lmokat nem szabad elfelejteni."
-"A cs�sz�-m�sz�k soha nem botlanak meg."
-"Ha kiv�gtad az utols� f�t �s megm�rgezted az utols� foly�t, r� fogsz j�nni arra, hogy a p�nzt nem lehet megenni."
-"A tan�tv�ny nem ed�ny, amit megt�lteni, hanem f�klya, amit l�ngra lobbantani kell."
-"Egy n�i sz�v hossz� t�von val� megtart�s�nak eszk�ze az orgazmus"
-"Egyenk�nt a lavina h�pelyhei is �rtatlanok..."
-"Killer Bunnies and the quest for the magic carrot"
-"Huh, I made You look!"
-"Ezt a h�ly�t, bazdmeg..."
-"Te zsibbad�k..."
-"- The question is: What is a mana-mana? - The question is: Who cares?!?"
-"�n 'j�' dikt�tor lenn�k...>)"
-"Hogy a Force-feedbackes kapany�l �sse ki a fogadat..."
-"Rule #4: Never make a promise you can't keep"
-"Amerika: �lni �s �lni hagyni...Magyarorsz�g: �lni �s eltiporni...Makes a tiny little difference"
-"Magyaritottak a telefon kozpontban is. Azt irtak ki: tavbeszelo centrum."
-"A person's true wealth is the good he or she does in the world."
-"To accomplish great things, we must not only act,*ut also dream; not only plan, but also believe."
-"To accomplish great things,*we must not only dream, but act."
-"Failure is only the opportunity to begin again,*this time more wisely."
-"Great changes may not happen right away,*ut with effort even the difficult may become easy."
-"The willow knows what the storm does not:*that the power to endure harm*outlives the power to inflict it."
-"Don't ask for a light load,*ut rather ask for a strong back."
-"What counts is not necessarily the size of*the dog in the fight - it's the*size of the fight in the dog."
-"To reach a port we must sail,*sometimes with the wind & sometimes against it.*ut we must not drift or lie at anchor."
-"If the going is real easy, beware,*you may be headed down hill."
-"Neked ugye MI a bajod?"
-"The electricity is a very simple thing"
-"well, something about you just makes me smile"
-"I mean, one day, out of no where.... boom.... there is Adam at the bean counter"
-"You should start your own company one day"
-"A legt�bb ember lusta k�z�nyben �li le �let�t"
-"We spend as we lend Cos we're happy to pretend Everything's gonna be OK"
-"Did it ever make sense to you to say Bye"
-"No one I know could ever keep up with you."
-"~, sweet ~"
-"doesn't said"
-"A ver�b bal �s jobb sz�rnya k�z�tt az a k�l�nbs�g, hogy mind a ketto egyforma, de k�l�n�sen a bal"
\ No newline at end of file
diff --git a/dcapi/examples/uppercase-with-callback/master.c b/dcapi/examples/uppercase-with-callback/master.c
deleted file mode 100644
index b16284b..0000000
--- a/dcapi/examples/uppercase-with-callback/master.c
+++ /dev/null
@@ -1,283 +0,0 @@
-/**************************************************
- * Uppercase Master program
- *
- * Created by: Gabor Vida
- * Fine tuned by: Adam Kornafeld
- * Upgraded to DC-API 2.0 by: Gabor Vida
- *
- * The aim of the program is to process text files (make all of their
- * characters uppercase) in a Public Resource Computing environment. The
- * program follows the client server model, therefore having a server-side and
- * a client-side part.
- *
- * This is the server-side part of the program. It creates WorkUnits (WUs) for
- * a Boinc project using the DC Application Programming Interface.  The program
- * takes a text file (master_input) divides it to smaller parts of LINES_PER_WU
- * lines each and submits them into the PRC-infrastructure, where they get
- * processed by the clients. After the clients have returned the results of the
- * WUs, the program assimilates them and constructs a final output file, by
- * concatenating the output of the results.
- *
- *****************************************************/
-
-#ifdef HAVE_CONFIG_H
-#include <config.h>
-#endif
-
-#include <dc.h>
-
-#include <stdlib.h>
-#include <getopt.h>
-#include <string.h>
-#include <limits.h>
-#include <stdio.h>
-#include <errno.h>
-
-#include "common.h"
-
-#define LINES_PER_WU		20
-
-/* Number of WUs we have created */
-static int created_wus;
-/* Number of results we have received so far */
-static int processed_wus;
-
-/* Command line options */
-static const struct option longopts[] =
-{
-	{ "config",	required_argument,	NULL,	'c' },
-	{ "help",	no_argument,		NULL,	'h' },	
-	{ NULL }
-};
-
-/* Concatenate all results in their original order to form the final output */
-static void calculate_final_result(void)
-{
-	FILE *output;
-	int i;
-
-	output = fopen("final_output.txt", "w");
-	if (!output)
-	{
-		DC_log(LOG_ERR, "Cannot open final_output.txt for writing: %s",
-			strerror(errno));
-		exit(1);
-	}
-
-	for(i = 0; i < created_wus; i++)
-	{
-		char result_filename[PATH_MAX], buf[256];
-		FILE *result;
-
-		snprintf(result_filename, sizeof(result_filename),
-			"result_%d.txt", i);
-		result = fopen(result_filename, "r");
-		if (!result)
-			DC_log(LOG_WARNING, "The result for WU %d is missing "
-				"from the final output", i);
-		else
-		{
-			while (fgets(buf, sizeof(buf), result))
-				fprintf(output, buf);
-			fclose(result);
-		}
-	}
-
-	fclose(output);
-}
-
-/* Copies the output files into the master working directory */
-static void process_result(DC_Workunit *wu, DC_Result *result)
-{
-	char *output_filename, *tag, cmd[256];
-
-	/* Internal housekeeping of the number of results we have seen */
-	processed_wus++;
-
-	/* Extract our own private identifier */
-	tag = DC_getWUTag(wu);
-
-	if (!result)
-	{
-		DC_log(LOG_WARNING, "Work unit %s has failed", tag);
-		free(tag);
-
-		/* In a real application we would create a new work unit
-		 * instead of the failed one and submit it again. Here we
-		 * just let it fail. */
-		return;
-	}
-
-	output_filename = DC_getResultOutput(result, OUTPUT_LABEL);
-	if (!output_filename)
-	{
-		DC_log(LOG_WARNING, "Work unit %s contains no output file",
-			tag);
-		free(tag);
-
-		/* The same comment applies here as above for the no result
-		 * case */
-		return;
-	}
-
-	DC_log(LOG_NOTICE, "Work unit %s has completed", tag);
-
-	/* The result file is available only as long as the work unit exists,
-	 * so we have to save it if we want to use it later */
-	snprintf(cmd, sizeof(cmd), "/bin/cp '%s' 'result_%s.txt'",
-		output_filename, tag);
-	system(cmd);
-
-	/* We no longer need the work unit */
-	DC_destroyWU(wu);
-
-	free(output_filename);
-	free(tag);
-}
-
-static void create_work(void)
-{
-	FILE *input;
-
-	input = fopen("input.txt", "r");
-	if (!input)
-	{
-		DC_log(LOG_ERR, "Failed to open the master input file: %s",
-			strerror(errno));
-		exit(1);
-	}
-
-	while (!feof(input))
-	{
-		char wu_tag[16], buf[1024];
-		DC_Workunit *wu;
-		FILE *f;
-		int i;
-
-		/* Tag every WU with its index, so we can reconstruct the
-		 * final output file in the correct order */
-		snprintf(wu_tag, sizeof(wu_tag), "%d", created_wus + 1);
-
-		wu = DC_createWU("uppercase-example", NULL, 0, wu_tag);
-		if (!wu)
-		{
-			DC_log(LOG_ERR, "Work unit creation has failed");
-			exit(1);
-		}
-
-		f = fopen("wu-input.txt", "w");
-		if (!f)
-		{
-			DC_log(LOG_ERR, "Failed to create wu-input.txt: %s",
-				strerror(errno));
-			exit(1);
-		}
-
-		for (i = 0; i < LINES_PER_WU; i++)
-		{
-			if (!fgets(buf, sizeof(buf), input))
-				break;
-			fprintf(f, "%s", buf);
-		}
-		fclose(f);
-
-		if (DC_addWUInput(wu, INPUT_LABEL, "wu-input.txt",
-				DC_FILE_VOLATILE))
-		{
-			DC_log(LOG_ERR, "Failed to register WU input file");
-			exit(1);
-		}
-		if (DC_addWUOutput(wu, OUTPUT_LABEL))
-		{
-			DC_log(LOG_ERR, "Failed to register WU output file");
-			exit(1);
-		}
-
-		if (DC_submitWU(wu))
-		{
-			DC_log(LOG_ERR, "Failed to submit WU");
-			exit(1);
-		}
-
-		/* If everything went well, increment the number of WUs we have
-		 * created */
-		++created_wus;
-	}
-	fclose(input);
-}
-
-static void print_help(const char *prog) __attribute__((noreturn));
-static void print_help(const char *prog)
-{
-	const char *p;
-
-	/* Strip the path component if present */
-	p = strrchr(prog, '/');
-	if (p)
-		prog = p;
-
-	printf("Usage: %s {-c|--config} <config file>\n", prog);
-	printf("Available options:\n");
-	printf("\t-c <file>, --config <file>\tUse the specified config. file\n");
-	printf("\t-h, --help\t\t\tThis help text\n");
-	exit(0);
-}
-
-int main(int argc, char *argv[])
-{
-	char *config_file = NULL;
-	int c;
-
-	while ((c = getopt_long(argc, argv, "c:h", longopts, NULL)) != -1)
-	{
-		switch (c)
-		{
-			case 'c':
-				config_file = optarg;
-				break;
-			case 'h':
-				print_help(argv[0]);
-				break;
-			default:
-				exit(1);
-		}
-	}
-
-	if (optind != argc)
-	{
-		fprintf(stderr, "Extra arguments on the command line\n");
-		exit(1);
-	}
-
-	/* Specifying the config file is mandatory, otherwise the master can't
-	 * run as a BOINC daemon */
-	if (!config_file)
-	{
-		fprintf(stderr, "You must specify the config file\n");
-		exit(1);
-	}
-
-	/* Initialize the DC-API */
-	if (DC_initMaster(config_file))
-	{
-		fprintf(stderr, "Master: DC_initMaster failed, exiting.\n");
-		exit(1);
-	}
-
-	/* We need the result callback function only */
-	DC_setMasterCb(process_result, NULL, NULL);
-
-	DC_log(LOG_NOTICE, "Master: Creating work units");
-	create_work();
-	DC_log(LOG_NOTICE, "Master: %d work units have been created. Waiting "
-		"for results...", created_wus);
-
-	/* Wait for the work units to finish */
-	while (processed_wus < created_wus)
-		DC_processMasterEvents(600);
-
-	/* Got all the results -> build the final output file */
-	calculate_final_result();
-
-	return 0;
-}
diff --git a/dcapi/examples/uppercase-with-callback/uppercase-example-client.xml.in b/dcapi/examples/uppercase-with-callback/uppercase-example-client.xml.in
deleted file mode 100644
index f53583f..0000000
--- a/dcapi/examples/uppercase-with-callback/uppercase-example-client.xml.in
+++ /dev/null
@@ -1,27 +0,0 @@
-<?xml version="1.0" standalone="no"?>
-<client>
-	<!-- Application name -->
-	<name>uppercase-example</name>
-
-	<!-- User-friendly name for Boinc -->
-	<user_friendly_name>Uppercase example</user_friendly_name>
-
-	<!-- Application version. Boinc requirements:
-	     - The version number must contain two components (major.minor)
-	     - Both component may be 1 or 2 digits long
-	     - The major version must be the same as the Boinc server major
-	       version -->
-	<version>@PACKAGE_VERSION@</version>
-
-	<platform>
-		<!-- The name of the platform -->
-		<name>@target@</name>
-
-		<!-- The name of the main client binary. It will be
-		     automatically renamed to the name expected by Boinc -->
-		<binary>uppercase-example-client</binary>
-
-		<!-- Additional files can also be installed -->
-		<!-- <lib>winlib.dll</lib> -->
-	</platform>
-</client>
diff --git a/dcapi/examples/uppercase-with-callback/uppercase-example-master.xml.in b/dcapi/examples/uppercase-with-callback/uppercase-example-master.xml.in
deleted file mode 100644
index 6ebb70b..0000000
--- a/dcapi/examples/uppercase-with-callback/uppercase-example-master.xml.in
+++ /dev/null
@@ -1,41 +0,0 @@
-<?xml version="1.0" standalone="no"?>
-<!--
-	Configuration template for the uppercase example application
--->
-<master>
-	<!-- Application name -->
-	<name>uppercase-example</name>
-
-	<!-- Application version. There are no restrictions for the format of
-	     master version numbers -->
-	<version>@PACKAGE_VERSION@</version>
-
-	<!-- Data files used by the master -->
-	<files>
-		<file>input.txt</file>
-	</files>
-
-	<!-- Master daemon definition -->
-	<daemon>
-		<binary>uppercase-example-master</binary>
-		<arguments>
-			<arg>--config</arg>
-			<arg>${workdir}/dc-api.conf</arg>
-		</arguments>
-	</daemon>
-
-	<!-- The application manager script will substitute the correct
-	     values for us -->
-	<dcapi-conf>dc-api.conf</dcapi-conf>
-
-	<!-- Validator daemon definition -->
-	<daemon>
-		<name>sample_trivial_validator</name>
-		<arguments>
-			<arg>-d</arg>
-			<arg>3</arg>
-			<arg>-app</arg>
-			<arg>uppercase-example</arg>
-		</arguments>
-	</daemon>
-</master>
diff --git a/dcapi/gtk-doc.make b/dcapi/gtk-doc.make
deleted file mode 100644
index 354ffb7..0000000
--- a/dcapi/gtk-doc.make
+++ /dev/null
@@ -1,173 +0,0 @@
-# -*- mode: makefile -*-
-
-####################################
-# Everything below here is generic #
-####################################
-
-if GTK_DOC_USE_LIBTOOL
-GTKDOC_CC = $(LIBTOOL) --mode=compile $(CC) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
-GTKDOC_LD = $(LIBTOOL) --mode=link $(CC) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) $(LDFLAGS)
-else
-GTKDOC_CC = $(CC) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
-GTKDOC_LD = $(CC) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) $(LDFLAGS)
-endif
-
-# We set GPATH here; this gives us semantics for GNU make
-# which are more like other make's VPATH, when it comes to
-# whether a source that is a target of one rule is then
-# searched for in VPATH/GPATH.
-#
-GPATH = $(srcdir)
-
-TARGET_DIR=$(HTML_DIR)/$(DOC_MODULE)
-
-EXTRA_DIST = 				\
-	$(content_files)		\
-	$(HTML_IMAGES)			\
-	$(DOC_MAIN_SGML_FILE)		\
-	$(DOC_MODULE)-sections.txt	\
-	$(DOC_MODULE)-overrides.txt
-
-DOC_STAMPS=scan-build.stamp tmpl-build.stamp sgml-build.stamp html-build.stamp \
-	   $(srcdir)/tmpl.stamp $(srcdir)/sgml.stamp $(srcdir)/html.stamp
-
-SCANOBJ_FILES = 		 \
-	$(DOC_MODULE).args 	 \
-	$(DOC_MODULE).hierarchy  \
-	$(DOC_MODULE).interfaces \
-	$(DOC_MODULE).prerequisites \
-	$(DOC_MODULE).signals
-
-REPORT_FILES = \
-	$(DOC_MODULE)-undocumented.txt \
-	$(DOC_MODULE)-undeclared.txt \
-	$(DOC_MODULE)-unused.txt
-
-CLEANFILES = $(SCANOBJ_FILES) $(REPORT_FILES) $(DOC_STAMPS)
-
-if ENABLE_GTK_DOC
-all-local: html-build.stamp
-else
-all-local:
-endif
-
-docs: html-build.stamp
-
-#### scan ####
-
-scan-build.stamp: $(HFILE_GLOB) $(CFILE_GLOB)
-	@echo 'gtk-doc: Scanning header files'
-	@-chmod -R u+w $(srcdir)
-	cd $(srcdir) && \
-	  gtkdoc-scan --module=$(DOC_MODULE) --source-dir=$(DOC_SOURCE_DIR) --ignore-headers="$(IGNORE_HFILES)" $(SCAN_OPTIONS) $(EXTRA_HFILES)
-	if grep -l '^..*$$' $(srcdir)/$(DOC_MODULE).types > /dev/null 2>&1 ; then \
-	    CC="$(GTKDOC_CC)" LD="$(GTKDOC_LD)" CFLAGS="$(GTKDOC_CFLAGS)" LDFLAGS="$(GTKDOC_LIBS)" gtkdoc-scangobj $(SCANGOBJ_OPTIONS) --module=$(DOC_MODULE) --output-dir=$(srcdir) ; \
-	else \
-	    cd $(srcdir) ; \
-	    for i in $(SCANOBJ_FILES) ; do \
-               test -f $$i || touch $$i ; \
-	    done \
-	fi
-	touch scan-build.stamp
-
-$(DOC_MODULE)-decl.txt $(SCANOBJ_FILES) $(DOC_MODULE)-sections.txt $(DOC_MODULE)-overrides.txt: scan-build.stamp
-	@true
-
-#### templates ####
-
-tmpl-build.stamp: $(DOC_MODULE)-decl.txt $(SCANOBJ_FILES) $(DOC_MODULE)-sections.txt $(DOC_MODULE)-overrides.txt
-	@echo 'gtk-doc: Rebuilding template files'
-	@-chmod -R u+w $(srcdir)
-	cd $(srcdir) && gtkdoc-mktmpl --module=$(DOC_MODULE) $(MKTMPL_OPTIONS)
-	touch tmpl-build.stamp
-
-tmpl.stamp: tmpl-build.stamp
-	@true
-
-tmpl/*.sgml:
-	@true
-
-
-#### xml ####
-
-sgml-build.stamp: tmpl.stamp $(HFILE_GLOB) $(CFILE_GLOB) $(DOC_MODULE)-sections.txt $(srcdir)/tmpl/*.sgml $(expand_content_files)
-	@echo 'gtk-doc: Building XML'
-	@-chmod -R u+w $(srcdir)
-	cd $(srcdir) && \
-	gtkdoc-mkdb --module=$(DOC_MODULE) --source-dir=$(DOC_SOURCE_DIR) --output-format=xml --expand-content-files="$(expand_content_files)" --main-sgml-file=$(DOC_MAIN_SGML_FILE) $(MKDB_OPTIONS)
-	touch sgml-build.stamp
-
-sgml.stamp: sgml-build.stamp
-	@true
-
-#### html ####
-
-html-build.stamp: sgml.stamp $(DOC_MAIN_SGML_FILE) $(content_files)
-	@echo 'gtk-doc: Building HTML'
-	@-chmod -R u+w $(srcdir)
-	rm -rf $(srcdir)/html
-	mkdir $(srcdir)/html
-	cd $(srcdir)/html && gtkdoc-mkhtml $(DOC_MODULE) ../$(DOC_MAIN_SGML_FILE)
-	test "x$(HTML_IMAGES)" = "x" || ( cd $(srcdir) && cp $(HTML_IMAGES) html )
-	@echo 'gtk-doc: Fixing cross-references'
-	cd $(srcdir) && gtkdoc-fixxref --module-dir=html --html-dir=$(HTML_DIR) $(FIXXREF_OPTIONS)
-	touch html-build.stamp
-
-##############
-
-clean-local:
-	rm -f *~ *.bak
-	rm -rf .libs
-
-distclean-local:
-	cd $(srcdir) && \
-	  rm -rf xml $(REPORT_FILES) \
-	         $(DOC_MODULE)-decl-list.txt $(DOC_MODULE)-decl.txt
-
-maintainer-clean-local: clean
-	cd $(srcdir) && rm -rf xml html
-
-install-data-local:
-	-installfiles=`echo $(srcdir)/html/*`; \
-	if test "$$installfiles" = '$(srcdir)/html/*'; \
-	then echo '-- Nothing to install' ; \
-	else \
-	  $(mkinstalldirs) $(DESTDIR)$(TARGET_DIR); \
-	  for i in $$installfiles; do \
-	    echo '-- Installing '$$i ; \
-	    $(INSTALL_DATA) $$i $(DESTDIR)$(TARGET_DIR); \
-	  done; \
-	  echo '-- Installing $(srcdir)/html/index.sgml' ; \
-	  $(INSTALL_DATA) $(srcdir)/html/index.sgml $(DESTDIR)$(TARGET_DIR) || :; \
-	  which gtkdoc-rebase >/dev/null && \
-	    gtkdoc-rebase --relative --dest-dir=$(DESTDIR) --html-dir=$(DESTDIR)$(TARGET_DIR) ; \
-	fi
-	
-
-uninstall-local:
-	rm -f $(DESTDIR)$(TARGET_DIR)/*
-
-#
-# Require gtk-doc when making dist
-#
-if ENABLE_GTK_DOC
-dist-check-gtkdoc:
-else
-dist-check-gtkdoc:
-	@echo "*** gtk-doc must be installed and enabled in order to make dist"
-	@false
-endif
-
-dist-hook: dist-check-gtkdoc dist-hook-local
-	mkdir $(distdir)/tmpl
-	mkdir $(distdir)/xml
-	mkdir $(distdir)/html
-	-cp $(srcdir)/tmpl/*.sgml $(distdir)/tmpl
-	-cp $(srcdir)/xml/*.xml $(distdir)/xml
-	cp $(srcdir)/html/* $(distdir)/html
-	-cp $(srcdir)/$(DOC_MODULE).types $(distdir)/
-	-cp $(srcdir)/$(DOC_MODULE)-sections.txt $(distdir)/
-	cd $(distdir) && rm -f $(DISTCLEANFILES)
-	-gtkdoc-rebase --online --relative --html-dir=$(distdir)/html
-
-.PHONY : dist-hook-local docs
diff --git a/dcapi/include/Makefile.am b/dcapi/include/Makefile.am
deleted file mode 100644
index b9199a7..0000000
--- a/dcapi/include/Makefile.am
+++ /dev/null
@@ -1,2 +0,0 @@
-include_HEADERS = dc.h dc_client.h dc_common.h
-noinst_HEADERS = dc_internal.h
diff --git a/dcapi/include/dc.h b/dcapi/include/dc.h
deleted file mode 100644
index 0e3f062..0000000
--- a/dcapi/include/dc.h
+++ /dev/null
@@ -1,217 +0,0 @@
-/*
- * DC-API: Distributed Computing Platform for Master-Worker Applications
- *
- * Master side
- *
- * Authors:
- * 	Norbert Podhorszki <pnorbert at sztaki.hu>
- * 	Gabor Vida <vida at sztaki.hu>
- * 	Gabor Gombas <gombasg at sztaki.hu>
- *
- * Copyright MTA SZTAKI, 2006
- */
-#ifndef _DC_H_
-#define _DC_H_
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-#include <dc_common.h>
-
-/********************************************************************
- * Constant definitions
- */
-
-/* Possible states of a work unit */
-typedef enum {
-	DC_WU_READY,	/* Created, but not yet submitted */
-	DC_WU_RUNNING,	/* Submitted and running */
-	DC_WU_FINISHED,	/* The WU finished normally according to the grid
-			   infrastructure. Note that the application client
-			   returning an error code is considered a 'normal'
-			   shutdown as far as the infrastructure is concerned,
-			   so you should check the exit status and/or other
-			   output. */
-	DC_WU_SUSPENDED,/* The work unit is suspended */
-	DC_WU_ABORTED,	/* The WU was aborted for some reason (infrastructure
-			   failure, no canonical result, or by calling
-			   DC_cancel()) */
-	DC_WU_UNKNOWN	/* The WU's state is not known. This may happen for
-			   example when a WU is serialized, then it finishes,
-			   and upon deserialization the underlying grid
-			   infrastructure no longer knows about it */
-} DC_WUState;
-
-/* Possible event types */
-typedef enum {
-	DC_MASTER_RESULT,	/* A DC_Result is available */
-	DC_MASTER_SUBRESULT,	/* A sub-result is available */
-	DC_MASTER_MESSAGE	/* A message has arrived */
-} DC_MasterEventType;
-
-
-/********************************************************************
- * Data types
- */
-
-/* Opaque type representing a workunit */
-typedef struct _DC_Workunit	DC_Workunit;
-
-/* Opaque type representing a result */
-typedef struct _DC_Result	DC_Result;
-
-/* Description of a DC-API event */
-typedef struct _DC_MasterEvent	DC_MasterEvent;
-struct _DC_MasterEvent
-{
-	DC_MasterEventType	type;
-	DC_Workunit		*wu;
-	union
-	{
-		DC_Result	*result;
-		DC_PhysicalFile	*subresult;
-		char		*message;
-	};
-};
-
-/* Prototype of the result handling callback function. */
-typedef void (*DC_ResultCallback)(DC_Workunit *wu, DC_Result *result);
-
-/* Prototype of the sub-result handling callback. */
-typedef void (*DC_SubresultCallback)(DC_Workunit *wu,
-	const char *logicalFileName, const char *path);
-
-/* Prototype of the message-handling callback. */
-typedef void (*DC_MessageCallback)(DC_Workunit *wu, const char *message);
-
-
-/********************************************************************
- * Function prototypes: Library utilities
- */
-
-/* Initializes the DC-API. */
-int DC_initMaster(const char *configFile);
-
-/* Sets the callback functions that will be called when a particular event. */
-void DC_setMasterCb(DC_ResultCallback resultcb,
-	DC_SubresultCallback subresultcb, DC_MessageCallback msgcb);
-
-/* Set the callback functions for particular events */
-void DC_setResultCb(DC_ResultCallback cb);
-void DC_setSubresultCb(DC_SubresultCallback cb);
-void DC_setMessageCb(DC_MessageCallback cb);
-
-/* Queries the number of WUs known to the API in the given state. */
-int DC_getWUNumber(DC_WUState state);
-
-/* Queries per-client configuration variables */
-char *DC_getClientCfgStr(const char *clientName, const char *key,
-	int fallbackGlobal);
-
-/* Queries per-client configuration variables */
-int DC_getClientCfgInt(const char *clientName, const char *key,
-	int defaultValue, int fallbackGlobal);
-
-/* Queries per-client configuration variables */
-double DC_getClientCfgDouble(const char *clientName, const char *key,
-	double defaultValue, int fallbackGlobal);
-
-/* Queries per-client configuration variables */
-int DC_getClientCfgBool(const char *clientName, const char *key,
-	int defaultValue, int fallbackGlobal);
-
-/********************************************************************
- * Function prototypes: Event processing
- */
-
-/* Waits for events and processes them. */
-int DC_processMasterEvents(int timeout);
-
-/* Checks for events and return them. */
-DC_MasterEvent *DC_waitMasterEvent(const char *wuFilter, int timeout);
-
-/* Checks for events for a particular WU. */
-DC_MasterEvent *DC_waitWUEvent(DC_Workunit *wu, int timeout);
-
-/* Destroys an event. */
-void DC_destroyMasterEvent(DC_MasterEvent *event);
-
-/********************************************************************
- * Function prototypes: Work unit management
- */
-
-/* Creates one work unit. */
-DC_Workunit *DC_createWU(const char *clientName, const char *arguments[],
-	int subresults, const char *tag);
-
-/* Sets an input file for the work unit. */
-int DC_addWUInput(DC_Workunit *wu, const char *logicalFileName, const char *URL,
-	DC_FileMode fileMode, ...);
-
-/* Defines an output file for the work unit. */
-int DC_addWUOutput(DC_Workunit *wu, const char *logicalFileName);
-
-/* Sets the priority for the work unit. */
-int DC_setWUPriority(DC_Workunit *wu, int priority);
-
-/* Sets the batch id for the work unit. */
-int DC_setWUBatch(DC_Workunit *wu, int batch);
-
-/* Serializes a work unit description. */
-char *DC_serializeWU(DC_Workunit *wu);
-
-/* Restores a serialized work unit. */
-DC_Workunit *DC_deserializeWU(const char *buf);
-
-/* Queries the state of a work unit. */
-DC_WUState DC_getWUState(DC_Workunit *wu);
-
-/* Submits a work unit. */
-int DC_submitWU(DC_Workunit *wu);
-
-/* Queries the low-level ID of the work unit. */
-char *DC_getWUId(const DC_Workunit *wu);
-
-/* Queries the tag of a work unit. */
-char *DC_getWUTag(const DC_Workunit *wu);
-
-/* Cancels all computations for a given work unit. */
-int DC_cancelWU(DC_Workunit *wu);
-
-/* Temporarily suspends the execution of a work unit. */
-int DC_suspendWU(DC_Workunit *wu);
-
-/* Resumes computation of a previously suspended work unit. */
-int DC_resumeWU(DC_Workunit *wu);
-
-/* Releases internal resources allocated to a work unit. */
-void DC_destroyWU(DC_Workunit *wu);
-
-/* Sends a message to a running work unit. */
-int DC_sendWUMessage(DC_Workunit *wu, const char *message);
-
-/********************************************************************
- * Function prototypes: Result handling
- */
-
-/* Queries what optional fields are present in the result. */
-unsigned DC_getResultCapabilities(const DC_Result *result);
-
-/* Returns the WU that generated this result. */
-DC_Workunit *DC_getResultWU(DC_Result *result);
-
-/* Returns the exit code of the client application. */
-int DC_getResultExit(const DC_Result *result);
-
-/* Returns the local name of an output file. */
-char *DC_getResultOutput(const DC_Result *result, const char *logicalFileName);
-
-/* Returns the CPU time used by the result. */
-double DC_getResultCPUTime(const DC_Result *result);
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif /* _DC_H_ */
diff --git a/dcapi/include/dc_client.h b/dcapi/include/dc_client.h
deleted file mode 100644
index 9c0f230..0000000
--- a/dcapi/include/dc_client.h
+++ /dev/null
@@ -1,96 +0,0 @@
-/*
- * DC-API: Distributed Computing Platform for Master-Worker Applications
- *
- * Client side
- *
- * Authors:
- * 	Norbert Podhorszki <pnorbert at sztaki.hu>
- * 	Gabor Vida <vida at sztaki.hu>
- * 	Gabor Gombas <gombasg at sztaki.hu>
- *
- * Copyright MTA SZTAKI, 2006
- */
-#ifndef _DC_CLIENT_H_
-#define _DC_CLIENT_H_
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-#include <dc_common.h>
-
-/********************************************************************
- * Constant definitions
- */
-
-/* File types for the DC_ResolveFileName function */
-typedef enum {
-	DC_FILE_IN,
-	DC_FILE_OUT,
-	DC_FILE_TMP
-} DC_FileType;
-
-/* Special handle for the checkpoint file */
-#define DC_CHECKPOINT_FILE	"__DC_CHECKPOINT_"
-
-/* Control events */
-typedef enum {
-	DC_CLIENT_CHECKPOINT,	/* Checkpointing is requested */
-	DC_CLIENT_FINISH,	/* Computation should be aborted */
-	DC_CLIENT_MESSAGE	/* A message has arrived */
-} DC_ClientEventType;
-
-
-/********************************************************************
- * Data types
- */
-
-/* Description of a DC-API event */
-typedef struct _DC_ClientEvent	DC_ClientEvent;
-struct _DC_ClientEvent
-{
-	DC_ClientEventType	type;
-	union
-	{
-		char		*message;
-	};
-};
-
-
-/********************************************************************
- * Function prototypes
- */
-
-/* Initializes the client API. */
-int DC_initClient(void);
-
-/* Resolves the local name of input/output files. */
-char *DC_resolveFileName(DC_FileType type, const char *logicalFileName);
-
-/* Sends a sub-result back to the master. */
-int DC_sendResult(const char *logicalFileName, const char *path,
-	DC_FileMode fileMode);
-
-/* Sends a message to the master. */
-int DC_sendMessage(const char *message);
-
-/* Checks for application control events. */
-DC_ClientEvent *DC_checkClientEvent(void);
-
-/* Destroys the event-specific data returned by DC_checkClientEvent(). */
-void DC_destroyClientEvent(DC_ClientEvent *event);
-
-/* Indicates that an application-level checkpoint has completed. */
-void DC_checkpointMade(const char *fileName);
-
-/* Informs the user interface about the fraction of work already done. */
-void DC_fractionDone(double fraction);
-
-/* Finishes computation. */
-void DC_finishClient(int exitcode) __attribute__((__noreturn__));
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif /* _DC_CLIENT_H_ */
diff --git a/dcapi/include/dc_common.h b/dcapi/include/dc_common.h
deleted file mode 100644
index 1bdf39e..0000000
--- a/dcapi/include/dc_common.h
+++ /dev/null
@@ -1,148 +0,0 @@
-/*
- * DC-API: Distributed Computing Platform for Master-Worker Applications
- *
- * Common definitions for both the master and client side
- *
- * Authors:
- * 	Gabor Gombas <gombasg at sztaki.hu>
- *
- * Copyright MTA SZTAKI, 2006
- */
-#ifndef __DC_COMMON_H_
-#define __DC_COMMON_H_
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-#ifdef _WIN32
-#include <dc_win32.h>
-#else
-#include <sys/syslog.h>
-#endif
-
-#include <string.h>
-#include <stdarg.h>
-
-/********************************************************************
- * Constant definitions
- */
-
-/* API error codes */
-typedef enum {
-	DC_OK,			/* No error */
-	DC_ERR_CONFIG,		/* Configuration error */
-	DC_ERR_DATABASE,	/* Error with the internal data base */
-	DC_ERR_NOTIMPL,		/* Not implemented by the API or by the
-				   underlying grid infrastructure */
-	DC_ERR_UNKNOWN_WU,	/* Unknown WU identifier */
-	DC_ERR_TIMEOUT,		/* Timeout */
-	DC_ERR_BADPARAM,	/* Bad function parameter */
-	DC_ERR_SYSTEM,		/* A system call has failed, check errno */
-	DC_ERR_INTERNAL,	/* Internal error */
-} DC_ErrorCode;
-
-/* Flags describing what capabilities does the underlying grid system
- * support */
-typedef enum {
-	DC_GC_EXITCODE		= (1 << 0),	/* DC_Result contains the
-						   client's exit code */
-	DC_GC_STDOUT		= (1 << 1),	/* The client's standard output
-						   is available for the
-						   master */
-	DC_GC_STDERR		= (1 << 2),	/* Client's standard error is
-						   available for the master */
-	DC_GC_LOG		= (1 << 3),	/* Log file generated by the
-						   execution environment is
-						   available for the master */
-	DC_GC_SUSPEND		= (1 << 4),	/* DC_suspendWU() works */
-	DC_GC_SUBRESULT		= (1 << 5),	/* Sub-results work */
-	DC_GC_MESSAGING		= (1 << 6)	/* Message sending works */
-} DC_GridCapabilities;
-
-/* File classification when passing a physical file name to DC-API */
-typedef int DC_FileMode;
-#define DC_FILE_REGULAR           (0)      /* Not persistent, needs copy */
-#define DC_FILE_PERSISTENT        (1)      /* Persistent, link is enough */
-#define DC_FILE_VOLATILE          (2)      /* DC-API should remove the original */
-#define DC_FILE_REMOTE            (3)      /* HTTP files physically not present */
-#define DC_FILE_PERSISTENT_CLIENT (1 << 7) /* FLAG: Persistent on client */
-
-#define DC_OUTFILE_OPTIONAL       (1 << 8) /* FLAG: Output file is optional */  
-
-/* Default name of the configuration file */
-#define DC_CONFIG_FILE		"dc-api.conf"
-
-/* Logical names for special files */
-#define DC_LABEL_STDOUT		"dc_stdout.txt"
-#define DC_LABEL_STDERR		"dc_stderr.txt"
-#define DC_LABEL_CLIENTLOG	"dc_clientlog.txt"
-
-
-/********************************************************************
- * Data types
- */
-
-/* Descriptor of a physical file */
-typedef struct _DC_PhysicalFile	DC_PhysicalFile;
-struct _DC_PhysicalFile
-{
-	char			*label;
-	char			*path;
-	DC_FileMode		mode;
-	char			*physicalfilename;
-	char			*physicalfilehash;
-    int             persistentonclient;
-};
-
-/* Descriptor of a remote file */
-typedef struct _DC_RemoteFile	DC_RemoteFile;
-struct _DC_RemoteFile
-{
-	char			*label;
-	char			*url;
-	char			*remotefilehash;
-	size_t			remotefilesize;
-    int             persistentonclient;
-};
-
-
-/********************************************************************
- * Function prototypes
- */
-
-#ifndef __GNUC__
-#define __attribute__(x)
-#endif
-
-/* Determines the maximum allowed message length. */
-int DC_getMaxMessageSize(void);
-
-/* Determines the maximum number of sub-results. */
-int DC_getMaxSubresults(void);
-
-/* Determines the basic capabilities of the underlying grid infrastructure. */
-unsigned DC_getGridCapabilities(void);
-
-/* Prints a message to the log file. */
-void DC_log(int level, const char *fmt, ...)
-	__attribute__((format(printf, 2, 3)));
-void DC_vlog(int level, const char *fmt, va_list args)
-	__attribute__((format(printf, 2, 0)));
-
-/* Returns the value associated with the specified key in the config. file */
-char *DC_getCfgStr(const char *name);
-
-/* Returns the integer value associated with the specified key in the config.
- * file */
-int DC_getCfgInt(const char *name, int defaultValue);
-
-/* Returns the boolean value associated with the specified key in the config.
- * file */
-int DC_getCfgBool(const char *name, int defaultValue);
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif /* __DC_COMMON_H_ */
diff --git a/dcapi/include/dc_internal.h b/dcapi/include/dc_internal.h
deleted file mode 100644
index 6316ab3..0000000
--- a/dcapi/include/dc_internal.h
+++ /dev/null
@@ -1,82 +0,0 @@
-/*
- * DC-API: Distributed Computing Platform for Master-Worker Applications
- *
- * Internal definitions
- *
- * Authors:
- * 	Gabor Gombas <gombasg at sztaki.hu>
- *
- * Copyright MTA SZTAKI, 2006
- */
-
-/* <private_header> */
-
-#ifndef __DC_INTERNAL_H_
-#define __DC_INTERNAL_H_
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-#include <stdio.h>
-#include <dc_common.h>
-
-/********************************************************************
- * Constants
- */
-
-/* Master's working directory (absolute path) */
-#define CFG_WORKDIR		"WorkingDirectory"
-/* Application instance UUID */
-#define CFG_INSTANCEUUID	"InstanceUUID"
-/* Log level */
-#define CFG_LOGLEVEL		"LogLevel"
-/* Log file location */
-#define CFG_LOGFILE		"LogFile"
-/* Configuration items to send to clients */
-#define CFG_SENDKEYS		"SendCfgKeys"
-/* Default WU priority */
-#define CFG_DEFAULTPRIO		"DefaultPriority"
-
-
-/********************************************************************
- * Function prototypes
- */
-
-/* Parses a configuration file */
-int _DC_parseCfg(const char *cfgfile) __attribute__((visibility("hidden")));
-
-/* Copies a file */
-int _DC_copyFile(const char *src, const char *dst) __attribute__((visibility("hidden")));
-
-/* Processes a unit suffix and adjust the value accordingly */
-long long _DC_processSuffix(const char *suffix) __attribute__((visibility("hidden")));
-
-/* Parses a boolean value */
-int _DC_parseBoolean(const char *value) __attribute__((visibility("hidden")));
-
-/* Allocates a physical file descriptor */
-DC_PhysicalFile *_DC_createPhysicalFile(const char *label, const char *path)
-	__attribute__((visibility("hidden")));
-
-/* Allocates a remote file descriptor */
-DC_RemoteFile *_DC_createRemoteFile(const char *label, const char *url, const char *md5, const size_t size)
-	__attribute__((visibility("hidden")));
-
-/* De-allocates a physical file descriptor */
-void _DC_destroyPhysicalFile(DC_PhysicalFile *file)
-	__attribute__((visibility("hidden")));
-
-/* De-allocates a remote file descriptor */
-void _DC_destroyRemoteFile(DC_RemoteFile *file)
-	__attribute__((visibility("hidden")));
-
-/* Initializa a config file for a client */
-int _DC_initClientConfig(const char *clientName, FILE *f)
-	__attribute__((visibility("hidden")));
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif /* __DC_INTERNAL_H_ */
diff --git a/dcapi/include/dc_win32.h b/dcapi/include/dc_win32.h
deleted file mode 100644
index d5146fe..0000000
--- a/dcapi/include/dc_win32.h
+++ /dev/null
@@ -1,40 +0,0 @@
-/*
- * DC-API: Distributed Computing Platform for Master-Worker Applications
- *
- * Compatibility definitions for Windows
- *
- * Authors:
- * 	Gabor Gombas <gombasg at sztaki.hu>
- *
- * Copyright MTA SZTAKI, 2006
- */
-
-/* <private_header> */
-
-#ifndef _DC_WIN32_H_
-#define _DC_WIN32_H_
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-/* Windows does not have syslog.h */
-enum {
-	LOG_DEBUG,
-	LOG_INFO,
-	LOG_NOTICE,
-	LOG_WARNING,
-	LOG_ERR,
-	LOG_CRIT
-};
-
-/* No ssize_t */
-typedef long ssize_t;
-
-#define strcasecmp(a, b)	stricmp(a, b)
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif /* _DC_WIN32_H_ */
diff --git a/dcapi/java/Makefile.am b/dcapi/java/Makefile.am
deleted file mode 100644
index c5a8309..0000000
--- a/dcapi/java/Makefile.am
+++ /dev/null
@@ -1,181 +0,0 @@
-AM_CPPFLAGS = $(JAVA_INC)
-
-# We need the following build order:
-# 1. Java classes
-# 2. dc-client.jar
-# 3. jni_proto.h
-# 4. libdcapi-java-client.la
-
-
-#######################################################################
-# Rules for building the Java part
-
-# Directory prefix of the classes
-CLASSDIR = hu/sztaki/lpds/dc
-
-# Generate debugging information by default
-AM_JAVACFLAGS = -g
-
-COMMON_SRCS = \
-		$(CLASSDIR)/DCException.java \
-		$(CLASSDIR)/FileMode.java \
-		$(CLASSDIR)/FileType.java \
-		$(CLASSDIR)/RuntimeDCException.java
-CLIENT_SRCS = \
-		$(CLASSDIR)/client/Event.java \
-		$(CLASSDIR)/client/DCClient.java \
-		$(CLASSDIR)/client/Version.java
-
-DOCFILES = \
-		$(CLASSDIR)/overview.html \
-		$(CLASSDIR)/package.html
-
-noinst_JAVA = $(COMMON_SRCS) $(CLIENT_SRCS)
-
-COMMON_CLASSES = $(COMMON_SRCS:.java=.class)
-COMMON_CLASSNAMES = $(subst /,.,$(COMMON_CLASSES:.class=))
-
-CLIENT_CLASSES = $(CLIENT_SRCS:.java=.class)
-CLIENT_CLASSNAMES = $(subst /,.,$(CLIENT_CLASSES:.class=))
-
-COMMON_JAR = dc-common-$(PACKAGE_VERSION).jar
-CLIENT_JAR = dc-client-$(PACKAGE_VERSION).jar
-JARFILES = $(COMMON_JAR) $(CLIENT_JAR)
-
-javadir = $(datadir)/dc-api
-java_DATA = $(JARFILES)
-
-install-data-hook:
-	cd $(DESTDIR)$(javadir) && \
-	rm -f dc-common.jar && \
-	rm -f dc-client.jar && \
-	$(LN_S) $(COMMON_JAR) dc-common.jar && \
-	$(LN_S) $(CLIENT_JAR) dc-client.jar
-
-# Override automake defaults
-CLASSPATH_ENV =
-JAVAROOT = $(top_builddir)/java
-
-# Depending on $(CLASSFILES) does not work. This solution is not documented
-# in the automake manual but works with automake-1.7
-$(CLIENT_JAR): classnoinst.stamp
-	$(JAR) -cf $@ $(CLIENT_CLASSES)
-
-$(COMMON_JAR): classnoinst.stamp
-	$(JAR) -cf $@ $(COMMON_CLASSES)
-
-$(CLASSDIR)/client/Version.java: $(CLASSDIR)/client/Version.java.in $(top_builddir)/configure.ac
-	cd $(top_builddir) && $(SHELL) ./config.status java/$(CLASSDIR)/client/Version.java
-
-
-#######################################################################
-# Rules for building the JNI part
-
-lib_LTLIBRARIES = \
-		libdcapi-java-client.la
-noinst_HEADERS = util.h
-BUILT_SOURCES = jni_proto.h jni_export.sym
-
-libdcapi_java_client_la_SOURCES = \
-		client.c \
-		util.c
-libdcapi_java_client_la_LDFLAGS = \
-		-avoid-version \
-		-release $(PACKAGE_VERSION) \
-		-export-symbols=jni_export.sym
-libdcapi_java_client_la_LIBADD = \
-		$(top_builddir)/boinc/libdcapi-client-boinc.la
-libdcapi_java_client_la_DEPENDENCIES = jni_export.sym
-
-# jni_proto.h contains both the consumer and producer-side JNI prototypes
-jni_proto.h: $(JARFILES)
-	$(JAVAH) -classpath $(COMMON_JAR):$(CLIENT_JAR) -o $@ -jni $(COMMON_CLASSNAMES) $(CLIENT_CLASSNAMES)
-	-touch $@
-
-# Generate the list of to-be-exported symbols from jni_proto.h
-# This is a little fragile but works
-jni_export.sym: jni_proto.h
-	grep '^JNIEXPORT.*JNICALL ' $< | \
-		sed -e 's/JNIEXPORT.*JNICALL //' > $@
-	echo "JNI_OnLoad" >> $@
-	echo "JNI_OnUnload" >> $@
-
-# On Darwin, the JVM wants a .jnilib extension instead of the native .dylib
-install-exec-hook:
-	case $(host_os) in \
-		darwin*) \
-			$(LN_S) -f $(DESTDIR)$(libdir)/libdcapi-java-client-$(PACKAGE_VERSION).dylib $(DESTDIR)$(libdir)/libdcapi-java-client-$(PACKAGE_VERSION).jnilib; \
-	esac
-
-
-#######################################################################
-# Misc. rules
-
-EXTRA_DIST = \
-		$(noinst_JAVA) \
-		$(DOCFILES)
-
-MOSTLYCLEANFILES = \
-		$(COMMON_CLASSES) \
-		$(CLIENT_CLASSES) \
-		$(JARFILES) \
-		javacore.txt \
-		core.*
-
-CLEANFILES = \
-		doc.stamp \
-		jni_export.sym \
-		jni_proto.h
-
-
-#######################################################################
-# Build and install the API documentation
-
-TARGET_DIR = $(docdir)/java
-
-doc.stamp: classnoinst.stamp $(DOCFILES)
-	-mkdir $(top_builddir)/java/doc 2>/dev/null
-	$(JAVADOC) -quiet -d $(top_builddir)/java/doc \
-		-sourcepath $(srcdir) \
-		-classpath $(COMMON_JAR):$(CLIENT_JAR) \
-		-overview $(srcdir)/$(CLASSDIR)/overview.html \
-		hu.sztaki.lpds.dc
-	-touch $@
-
-all-local: doc.stamp
-
-clean-local:
-	-rm -rf doc
-
-install-data-local:
-	$(mkinstalldirs) $(DESTDIR)$(TARGET_DIR)/$(CLASSDIR)
-	$(mkinstalldirs) $(DESTDIR)$(TARGET_DIR)/$(CLASSDIR)/producer
-	(installfiles=`echo $(srcdir)/doc/*.html $(srcdir)/doc/*.css`; \
-	if test "$$installfiles" = '$(srcdir)/doc/*.html $(srcdir)/doc/*.css'; \
-	then echo '-- Nothing to install' ; \
-	else \
-	  for i in $$installfiles; do \
-	    echo '-- Installing '$$i ; \
-	    $(INSTALL_DATA) $$i $(DESTDIR)$(TARGET_DIR); \
-	  done; \
-	  echo '-- Installing $(srcdir)/doc/package-list' ; \
-	  $(INSTALL_DATA) $(srcdir)/doc/package-list $(DESTDIR)$(TARGET_DIR); \
-	fi)
-	(installfiles=`echo $(srcdir)/doc/$(CLASSDIR)/*.html`; \
-	if test "$$installfiles" = '$(srcdir)/doc/$(CLASSDIR)/*.html'; \
-	then echo '-- Nothing to install' ; \
-	else \
-	  for i in $$installfiles; do \
-	    echo '-- Installing '$$i ; \
-	    $(INSTALL_DATA) $$i $(DESTDIR)$(TARGET_DIR)/$(CLASSDIR); \
-	  done; \
-	fi)
-	(installfiles=`echo $(srcdir)/doc/$(CLASSDIR)/producer/*.html`; \
-	if test "$$installfiles" = '$(srcdir)/doc/$(CLASSDIR)/producer/*.html'; \
-	then echo '-- Nothing to install' ; \
-	else \
-	  for i in $$installfiles; do \
-	    echo '-- Installing '$$i ; \
-	    $(INSTALL_DATA) $$i $(DESTDIR)$(TARGET_DIR)/$(CLASSDIR)/producer; \
-	  done; \
-	fi)
diff --git a/dcapi/java/client.c b/dcapi/java/client.c
deleted file mode 100644
index 7a33e77..0000000
--- a/dcapi/java/client.c
+++ /dev/null
@@ -1,483 +0,0 @@
-/** @file client.c
- *
- * Client-side DC-API JNI code
- *
- * Author: Gábor Gombás
- */
-
-#ifdef HAVE_CONFIG_H
-#include <config.h>
-#endif
-
-#include <stdlib.h>
-#include <string.h>
-
-#include <dc_client.h>
-
-#include "util.h"
-
-/**********************************************************************
- * Global variables
- */
-
-/* Java VM handle for the callbacks */
-static JavaVM *myvm;
-
-/* Bitmask for debugging classes */
-unsigned jni_debug = 0;
-
-
-/**********************************************************************
- * Class: hu.sztaki.lpds.dc.client.Event
- */
-
-/* Throws: RuntimeDCException, DCException */
-JNIEXPORT jstring JNICALL Java_hu_sztaki_lpds_dc_client_Event_getMessage
-  (JNIEnv *env, jobject this)
-{
-	DC_ClientEvent *event;
-	jfieldID field;
-	jclass cls;
-	int type;
-
-	cls = (*env)->GetObjectClass(env, this);
-	if (!cls)
-		return NULL;
-
-	field = (*env)->GetFieldID(env, cls, "type", "I");
-	if (!field)
-	{
-		propagate_runtime(env, "Failed to look up the type field");
-		return NULL;
-	}
-
-	type = (*env)->GetIntField(env, this, field);
-	if (type != DC_CLIENT_MESSAGE)
-	{
-		throw_dcexc(env, DC_ERR_BADPARAM, "This is not a message event");
-		return NULL;
-	}
-
-	field = (*env)->GetFieldID(env, cls, "ptr", "J");
-	if (!field)
-	{
-		propagate_runtime(env, "Failed to look up the type field");
-		return NULL;
-	}
-
-	event = (DC_ClientEvent *)(*env)->GetLongField(env, this, field);
-	if (!event || !event->message)
-	{
-		throw_exc(env, CLASS_RuntimeDCException, "Empty message event?!?");
-		return NULL;
-	}
-
-	return (*env)->NewStringUTF(env, event->message);
-}
-
-/* Throws: RuntimeDCException */
-JNIEXPORT void JNICALL Java_hu_sztaki_lpds_dc_client_Event_finalize
-  (JNIEnv *env, jobject this)
-{
-	DC_ClientEvent *event;
-	jfieldID field;
-	jclass cls;
-
-	cls = (*env)->GetObjectClass(env, this);
-	if (!cls)
-		return;
-
-	field = (*env)->GetFieldID(env, cls, "ptr", "J");
-	if (!field)
-	{
-		propagate_runtime(env, "Failed to look up the type field");
-		return;
-	}
-
-	event = (DC_ClientEvent *)(*env)->GetLongField(env, this, field);
-	DC_destroyClientEvent(event);
-}
-
-/**********************************************************************
- * Class: hu.sztaki.lpds.dc.DCClient
- */
-
-/* Throws: none */
-JNIEXPORT jint JNICALL Java_hu_sztaki_lpds_dc_client_DCClient_getMaxMessageSize
-  (JNIEnv *env G_GNUC_UNUSED, jclass cls G_GNUC_UNUSED)
-{
-	return DC_getMaxMessageSize();
-}
-
-/* Throws: none */
-JNIEXPORT jint JNICALL Java_hu_sztaki_lpds_dc_client_DCClient_getMaxSubresults
-  (JNIEnv *env G_GNUC_UNUSED, jclass cls G_GNUC_UNUSED)
-{
-	return DC_getMaxSubresults();
-}
-
-/* Throws: NullPointerException */
-JNIEXPORT void JNICALL Java_hu_sztaki_lpds_dc_client_DCClient_log
-  (JNIEnv *env, jclass cls G_GNUC_UNUSED, jint level, jstring msgstr)
-{
-	const char *msg;
-
-	if (!msgstr)
-	{
-		throw_exc(env, CLASS_NullPointerException,
-			"Message cannot be null");
-		return;
-	}
-
-	msg = (*env)->GetStringUTFChars(env, msgstr, NULL);
-	if (!msg)
-		return;
-
-	DC_log(level, "%s", msg);
-	(*env)->ReleaseStringUTFChars(env, msgstr, msg);
-}
-
-/* Throws: NullPointerException, IllegalArgumentException */
-JNIEXPORT jstring JNICALL Java_hu_sztaki_lpds_dc_client_DCClient_getCfgStr
-  (JNIEnv *env, jclass cls G_GNUC_UNUSED, jstring namestr)
-{
-	const char *name;
-	jstring res;
-	char *value;
-
-	if (!namestr)
-	{
-		throw_exc(env, CLASS_NullPointerException,
-			"Configuration key name cannot be null");
-		return NULL;
-	}
-
-	name = (*env)->GetStringUTFChars(env, namestr, NULL);
-	if (!name)
-		return NULL;
-
-	value = DC_getCfgStr(name);
-	if (!value)
-	{
-		throw_exc(env, CLASS_IllegalArgumentException,
-			"Configuration key %s does not exist", name);
-		(*env)->ReleaseStringUTFChars(env, namestr, name);
-		return NULL;
-	}
-
-	res = (*env)->NewStringUTF(env, value);
-	free(value);
-	(*env)->ReleaseStringUTFChars(env, namestr, name);
-
-	return res;
-}
-
-/* Throws: NullPointerException */
-JNIEXPORT jint JNICALL Java_hu_sztaki_lpds_dc_client_DCClient_getCfgInt
-  (JNIEnv *env, jclass cls G_GNUC_UNUSED, jstring namestr, jint defaultValue)
-{
-	const char *name;
-	jint res;
-
-	if (!namestr)
-	{
-		throw_exc(env, CLASS_NullPointerException,
-			"Configuration key name cannot be null");
-		return defaultValue;
-	}
-
-	name = (*env)->GetStringUTFChars(env, namestr, NULL);
-	if (!name)
-		return defaultValue;
-
-	res = DC_getCfgInt(name, defaultValue);
-	(*env)->ReleaseStringUTFChars(env, namestr, name);
-
-	return res;
-}
-
-/* Throws: NullPointerException */
-JNIEXPORT jboolean JNICALL Java_hu_sztaki_lpds_dc_client_DCClient_getCfgBool
-  (JNIEnv *env, jclass cls G_GNUC_UNUSED, jstring namestr, jboolean defaultValue)
-{
-	const char *name;
-	jboolean res;
-
-	if (!namestr)
-	{
-		throw_exc(env, CLASS_NullPointerException,
-			"Configuration key name cannot be null");
-		return defaultValue;
-	}
-
-	name = (*env)->GetStringUTFChars(env, namestr, NULL);
-	if (!name)
-		return defaultValue;
-
-	res = DC_getCfgBool(name, defaultValue);
-	(*env)->ReleaseStringUTFChars(env, namestr, name);
-
-	return res;
-}
-
-/* Throws: DCException */
-JNIEXPORT void JNICALL Java_hu_sztaki_lpds_dc_client_DCClient_init
-  (JNIEnv *env, jclass cls G_GNUC_UNUSED)
-{
-	int ret;
-
-	ret = DC_initClient();
-	if (ret)
-		throw_dcexc(env, ret, "Failed to initialize the DC-API library");
-}
-
-/* Throws: DCException, NullPointerException */
-JNIEXPORT jstring JNICALL Java_hu_sztaki_lpds_dc_client_DCClient_resolveFileName
-  (JNIEnv *env, jclass cls G_GNUC_UNUSED, jobject typeobj, jstring namestr)
-{
-	DC_FileType type;
-	const char *name;
-	jfieldID field;
-	jstring res;
-	char *pname;
-
-	if (!typeobj)
-	{
-		throw_exc(env, CLASS_NullPointerException,
-			"The file type can not be null");
-		return NULL;
-	}
-	if (!namestr)
-	{
-		throw_exc(env, CLASS_NullPointerException,
-			"The file name can not be null");
-		return NULL;
-	}
-
-	cls = (*env)->GetObjectClass(env, typeobj);
-	if (!cls)
-		return NULL;
-
-	field = (*env)->GetFieldID(env, cls, "code", "I");
-	if (!field)
-	{
-		propagate_runtime(env, "Failed to look up the code field");
-		return NULL;
-	}
-
-	type = (*env)->GetIntField(env, typeobj, field);
-	name = (*env)->GetStringUTFChars(env, namestr, NULL);
-	pname = DC_resolveFileName(type, name);
-	(*env)->ReleaseStringUTFChars(env, namestr, name);
-	if (!pname)
-	{
-		throw_dcexc(env, DC_ERR_BADPARAM, "File name lookup failed");
-		return NULL;
-	}
-
-	res = (*env)->NewStringUTF(env, pname);
-	free(pname);
-	return res;
-}
-
-JNIEXPORT void JNICALL Java_hu_sztaki_lpds_dc_client_DCClient_sendResult
-  (JNIEnv *env, jclass cls G_GNUC_UNUSED, jstring namestr, jstring pathstr, jobject modeobj)
-{
-	const char *name, *path;
-	DC_FileMode mode;
-	jfieldID field;
-	int ret;
-
-	if (!modeobj)
-	{
-		throw_exc(env, CLASS_NullPointerException,
-			"The file mode can not be null");
-		return;
-	}
-	if (!namestr)
-	{
-		throw_exc(env, CLASS_NullPointerException,
-			"The logical file name can not be null");
-		return;
-	}
-	if (!pathstr)
-	{
-		throw_exc(env, CLASS_NullPointerException,
-			"The physical file name can not be null");
-		return;
-	}
-
-	cls = (*env)->GetObjectClass(env, modeobj);
-	if (!cls)
-		return;
-
-	field = (*env)->GetFieldID(env, cls, "code", "I");
-	if (!field)
-	{
-		propagate_runtime(env, "Failed to look up the code field");
-		return;
-	}
-
-	mode = (*env)->GetIntField(env, modeobj, field);
-	name = (*env)->GetStringUTFChars(env, namestr, NULL);
-	path = (*env)->GetStringUTFChars(env, pathstr, NULL);
-
-	ret = DC_sendResult(name, path, mode);
-	(*env)->ReleaseStringUTFChars(env, namestr, name);
-	(*env)->ReleaseStringUTFChars(env, pathstr, path);
-	if (ret)
-		throw_dcexc(env, ret, "Sub-result sending failed");
-}
-
-/* Throws: NullPointerException */
-JNIEXPORT void JNICALL Java_hu_sztaki_lpds_dc_client_DCClient_sendMessage
-  (JNIEnv *env, jclass cls G_GNUC_UNUSED, jstring msgstr)
-{
-	const char *msg;
-
-	if (!msgstr)
-	{
-		throw_exc(env, CLASS_NullPointerException,
-			"The message can not be null");
-		return;
-	}
-
-	msg = (*env)->GetStringUTFChars(env, msgstr, NULL);
-	DC_sendMessage(msg);
-	(*env)->ReleaseStringUTFChars(env, msgstr, msg);
-}
-
-/* Throws: none */
-JNIEXPORT void JNICALL Java_hu_sztaki_lpds_dc_client_DCClient_finish
-  (JNIEnv *env G_GNUC_UNUSED, jclass cls G_GNUC_UNUSED, jint exitCode)
-{
-	DC_finishClient(exitCode);
-}
-
-/* Throws: NullPointerException */
-JNIEXPORT void JNICALL Java_hu_sztaki_lpds_dc_client_DCClient_checkpointMade
-  (JNIEnv *env, jclass cls G_GNUC_UNUSED, jstring pathstr)
-{
-	const char *path;
-
-	if (!pathstr)
-	{
-		throw_exc(env, CLASS_NullPointerException,
-			"The file name can not be null");
-		return;
-	}
-
-	path = (*env)->GetStringUTFChars(env, pathstr, NULL);
-	DC_checkpointMade(path);
-	(*env)->ReleaseStringUTFChars(env, pathstr, path);
-}
-
-/* Throws: none */
-JNIEXPORT void JNICALL Java_hu_sztaki_lpds_dc_client_DCClient_fractionDone
-  (JNIEnv *env G_GNUC_UNUSED, jclass cls G_GNUC_UNUSED, jdouble fraction G_GNUC_UNUSED)
-{
-	DC_fractionDone(fraction);
-}
-
-/* Throws: none */
-JNIEXPORT jobject JNICALL Java_hu_sztaki_lpds_dc_client_DCClient_checkEvent
-  (JNIEnv *env, jclass cls G_GNUC_UNUSED)
-{
-	DC_ClientEvent *event;
-	jobject eventobj;
-	jmethodID meth;
-	int ret;
-
-	event = DC_checkClientEvent();
-	if (!event)
-		return NULL;
-
-	ret = GET_CTOR(env, ClientEvent, &cls, &meth);
-	if (ret)
-		return NULL;
-
-	eventobj = (*env)->NewObject(env, cls, meth, event->type, (jlong)event);
-	return eventobj;
-}
-
-/**********************************************************************
- * Class: hu.sztaki.lpds.dc.client.Version
- */
-
-JNIEXPORT jstring JNICALL Java_hu_sztaki_lpds_dc_client_Version_getNativeVersion
-  (JNIEnv *env, jclass cls G_GNUC_UNUSED)
-{
-	return (*env)->NewStringUTF(env, PACKAGE_VERSION);
-}
-
-/**********************************************************************
- * JNI module initialization and finalization
- */
-
-JNIEXPORT jint JNI_OnLoad(JavaVM *jvm, void *res G_GNUC_UNUSED)
-{
-	union getenvarg jnienv;
-	const char *ver;
-	jmethodID meth;
-	jstring verstr;
-	jclass cls;
-	int ret;
-
-	myvm = jvm;
-
-	if ((*myvm)->GetEnv(myvm, &jnienv.ptr, JNI_VERSION_1_2))
-		return 0;
-
-	/* Check that the JNI and Java versions match */
-	cls = find_class(jnienv.env, CLASS_ClientVersion);
-	if (!cls)
-	{
-		fprintf(stderr, "Class hu.sztaki.lpds.dc.Version was "
-			"not found\n");
-		return 0;
-	}
-	meth = (*jnienv.env)->GetStaticMethodID(jnienv.env, cls, "getVersion",
-		SIG_ClientVersion_getVersion);
-	if (!meth)
-	{
-		fprintf(stderr, "Method hu.sztaki.lpds.dc.Version."
-			"getVersion() was not found\n");
-		return 0;
-	}
-	verstr = (*jnienv.env)->CallStaticObjectMethod(jnienv.env, cls, meth);
-	if ((*jnienv.env)->ExceptionCheck(jnienv.env))
-	{
-		fprintf(stderr, "Exception occurred while checking the "
-			"version\n");
-		return 0;
-	}
-	ver = (*jnienv.env)->GetStringUTFChars(jnienv.env, verstr, NULL);
-	if (!ver)
-	{
-		fprintf(stderr, "Failed to retrieve the version string\n");
-		return 0;
-	}
-	if (strcmp(ver, PACKAGE_VERSION))
-	{
-		fprintf(stderr, "DC-API version mismatch: Java side is %s, "
-			"JNI side is %s\n", ver, PACKAGE_VERSION);
-		(*jnienv.env)->ReleaseStringUTFChars(jnienv.env, verstr, ver);
-		return 0;
-	}
-	(*jnienv.env)->ReleaseStringUTFChars(jnienv.env, verstr, ver);
-
-	(*jnienv.env)->DeleteLocalRef(jnienv.env, verstr);
-	(*jnienv.env)->DeleteLocalRef(jnienv.env, cls);
-
-	/* Look for & process dc.jni.debug */
-	ret = parse_debug_options(jnienv.env);
-	if (ret)
-		return 0;
-
-	return JNI_VERSION_1_2;
-}
-
-JNIEXPORT void JNI_OnUnload(JavaVM *jvm G_GNUC_UNUSED,
-	void *res G_GNUC_UNUSED)
-{
-}
diff --git a/dcapi/java/example/boinc-java-launcher b/dcapi/java/example/boinc-java-launcher
deleted file mode 100644
index 531136b..0000000
--- a/dcapi/java/example/boinc-java-launcher
+++ /dev/null
@@ -1,17 +0,0 @@
-#!/bin/sh
-
-#
-# Script to launch java applications in a BOINC environment
-#
-
-set +v
-
-libdcapi-jre=`sed -n '/^<soft_link>/ s/<[^>]*>//gp' libdcapi-jre.tar`
-app-jar=`sed -n '/^<soft_link>/ s/<[^>]*>//gp' Uppercase.jar`
-
-[ -d jre ] || gunzip -c "$libdcapi-jre" | tar xf -
-
-LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$PWD/lib
-export LD_LIBRARY_PATH
-
-exec ./jre/bin/java -jar "$app-jar"
diff --git a/dcapi/java/example/compile b/dcapi/java/example/compile
deleted file mode 100644
index aad169b..0000000
--- a/dcapi/java/example/compile
+++ /dev/null
@@ -1,5 +0,0 @@
-#!/bin/sh
-
-javac uppercase.java
-
-jar cmf manifest Uppercase.jar Uppercase.class hu
\ No newline at end of file
diff --git a/dcapi/java/example/manifest b/dcapi/java/example/manifest
deleted file mode 100644
index b371ae7..0000000
--- a/dcapi/java/example/manifest
+++ /dev/null
@@ -1 +0,0 @@
-Main-Class: Uppercase
diff --git a/dcapi/java/example/uppercase.java b/dcapi/java/example/uppercase.java
deleted file mode 100644
index 7f81d96..0000000
--- a/dcapi/java/example/uppercase.java
+++ /dev/null
@@ -1,157 +0,0 @@
-import hu.sztaki.lpds.dc.*;
-import hu.sztaki.lpds.dc.client.*;
-
-import java.io.*;
-import java.util.*;
-
-class Uppercase {
-
-static {
-    System.loadLibrary("dc-java-client-0.9");
-}
-
-  private static FileReader infile = null;
-  private static FileWriter outfile = null;
-  private static FileReader ckptin = null;
-  private static FileWriter ckptout = null;
-  
-  private static int pos = 0;
-
-  public static void main(String argsp[]) {
-    
-    DCClient cli = new DCClient();
-    
-    try {
-        cli.init();
-    } catch (DCException e)
-    {
-	System.out.println("APP: Failed to initilaize DC-API");
-    }
-    
-    init_files(cli);
-    
-    do_work(cli);
-    
-    cli.finish(0);
-  }
-
-  private static void init_files(DCClient dc) {
-    String file_name = "";
-    String ckpt = "";
-    
-    // INPUT File
-    try {
-        file_name = dc.resolveFileName(FileType.IN, "in.txt");
-    } catch (DCException e) {
-	System.out.println("APP: Could not resolve input file name.");
-	dc.finish(1);
-    }
-    try {
-      infile = new FileReader(file_name);
-    } catch (IOException e) {
-      System.out.println("APP: Could not open input file.");
-      dc.finish(1);
-    }    
-
-    //CKPT File
-    try {
-      ckptin = new FileReader("ckpt.txt");
-      
-      try {
-        BufferedReader br = new BufferedReader(ckptin);
-        ckpt = br.readLine();
-      } catch (IOException ex) {
-         System.out.println("APP: Could not read ckpt file.");
-         dc.finish(1);
-      }
-    
-      StringTokenizer ckptst = new StringTokenizer(ckpt);
-      pos = Integer.parseInt(ckptst.nextToken());
-    
-      try {
-      for (int i=0; i<pos; i++) {
-        infile.read();
-      }
-      }catch (IOException er)
-      {
-         System.out.println("APP: Could not read input file.");
-         dc.finish(1);    
-      }
-
- 
-    } catch (FileNotFoundException e) {
-    }
-    
-    //OUTPUT File
-    try {
-      file_name = dc.resolveFileName(FileType.OUT, "out.txt");
-    } catch (DCException e) {
-      System.out.println("APP: Could not resolve output file name.");
-      dc.finish(1);
-    }
-    try {
-      outfile = new FileWriter(file_name, true);
-     } catch (IOException e) {
-        System.out.println("APP: Could not create/open output file.");
-        dc.finish(1);
-     }
-  }
-  
-  private static void do_work(DCClient dc) {
-    int i;
-    char c;
-    
-    try { 
-      while ( (i = infile.read()) > -1) {
-        c = (char)i;
-	pos++;
-        try {    
-          outfile.write(Character.toUpperCase(c));
-        } catch (IOException e) {
-            System.out.println("APP: Could not write output file.");
-            dc.finish(1);    
-        }
-	
-	do_checkpoint(dc);
-	
-	Event ev = dc.checkEvent();
-        if (ev == null)
-          continue;
-      
-        if(ev.isCheckpointRequest())
-          do_checkpoint(dc);
-      }
-    }catch (IOException e){
-      System.out.println("APP: Could not read input file.");
-      dc.finish(1);    
-    }
-    try {
-      outfile.close();
-    } catch (IOException e)
-    {
-      System.out.println("APP: Could not close output file.");
-      dc.finish(1);         
-    }
-  }
-  
-  private static void do_checkpoint(DCClient dc) {
-
-    try {
-      outfile.flush();
-    } catch (IOException e) {
-        System.out.println("APP: Could not flush output file.");
-        dc.finish(1);         
-    }
-    
-    try {
-      ckptout = new FileWriter("ckpt.txt");
-      ckptout.write(String.valueOf(pos));
-      ckptout.close();
-    }catch (IOException ec) {
-      System.out.println("APP: Could not write ckpt file.");
-      dc.finish(1);
-    }
-    
-  }
-  //end class
-}
\ No newline at end of file
diff --git a/dcapi/java/hu/sztaki/lpds/dc/DCException.java b/dcapi/java/hu/sztaki/lpds/dc/DCException.java
deleted file mode 100644
index d53cb55..0000000
--- a/dcapi/java/hu/sztaki/lpds/dc/DCException.java
+++ /dev/null
@@ -1,45 +0,0 @@
-package hu.sztaki.lpds.dc;
-
-import java.lang.Exception;
-
-/**
- * The <code>DCException</code> class represents the errors returned by DC-API.
- *
- * @author Gábor Gombás
- */
-
-public class DCException extends Exception {
-
-	/* Error codes. The values must match the C code. */
-	public static final int DC_ERR_CONFIG = 1;
-	public static final int DC_ERR_DATABASE = 2;
-	public static final int DC_ERR_NOTIMPL = 3;
-	public static final int DC_ERR_UNKNOWN_WU = 4;
-	public static final int DC_ERR_TIMEOUT = 5;
-	public static final int DC_ERR_BADPARAM = 6;
-	public static final int DC_ERR_SYSTEM = 7;
-	public static final int DC_ERR_INTERNAL = 8;
-
-	private static String messages[] = {
-		"No error",
-		"Configuration error",
-		"Database error",
-		"Function not implemented",
-		"Unknown work unit",
-		"Timeout occured",
-		"Bad parameter",
-		"Failed system call",
-		"Internal library error"
-	};
-
-	private int code;
-
-	private DCException(int code, String message) {
-		super(message + ": " + messages[code]);
-		this.code = code;
-	}
-
-	public int getCode() {
-		return code;
-	}
-}
diff --git a/dcapi/java/hu/sztaki/lpds/dc/FileMode.java b/dcapi/java/hu/sztaki/lpds/dc/FileMode.java
deleted file mode 100644
index 5e22bb5..0000000
--- a/dcapi/java/hu/sztaki/lpds/dc/FileMode.java
+++ /dev/null
@@ -1,29 +0,0 @@
-package hu.sztaki.lpds.dc;
-
-/**
- * The <code>FileMode</code> class contains the valid file mode constants.
- *
- * @author Gábor Gombás
- */
-
-public final class FileMode {
-	/* The codes must match their C equivalend */
-	private static final int DC_FILE_REGULAR = 0;
-	private static final int DC_FILE_PERSISTENT = 1;
-	private static final int DC_FILE_VOLATILE = 2;
-
-	/* Public instances */
-	public static final FileMode REGULAR = new FileMode(DC_FILE_REGULAR);
-	public static final FileMode PERSISTENT = new FileMode(DC_FILE_PERSISTENT);
-	public static final FileMode VOLATILE = new FileMode(DC_FILE_VOLATILE);
-
-	/* Class implementation */
-	private int code;
-	private FileMode(int code) {
-		this.code = code;
-	}
-
-	int getCode() {
-		return code;
-	}
-};
diff --git a/dcapi/java/hu/sztaki/lpds/dc/FileType.java b/dcapi/java/hu/sztaki/lpds/dc/FileType.java
deleted file mode 100644
index d8bf134..0000000
--- a/dcapi/java/hu/sztaki/lpds/dc/FileType.java
+++ /dev/null
@@ -1,29 +0,0 @@
-package hu.sztaki.lpds.dc;
-
-/**
- * The <code>FileType</code> class contains the valid file type constants.
- *
- * @author Gábor Gombás
- */
-
-public final class FileType {
-	/* The codes must match their C equivalend */
-	private static final int DC_FILE_IN = 0;
-	private static final int DC_FILE_OUT = 1;
-	private static final int DC_FILE_TMP = 2;
-
-	/* Public instances */
-	public static final FileType IN = new FileType(DC_FILE_IN);
-	public static final FileType OUT = new FileType(DC_FILE_OUT);
-	public static final FileType TMP = new FileType(DC_FILE_TMP);
-
-	/* Class implementation */
-	private int code;
-	private FileType(int code) {
-		this.code = code;
-	}
-
-	int getCode() {
-		return code;
-	}
-};
diff --git a/dcapi/java/hu/sztaki/lpds/dc/RuntimeDCException.java b/dcapi/java/hu/sztaki/lpds/dc/RuntimeDCException.java
deleted file mode 100644
index 708c5e4..0000000
--- a/dcapi/java/hu/sztaki/lpds/dc/RuntimeDCException.java
+++ /dev/null
@@ -1,42 +0,0 @@
-package hu.sztaki.lpds.dc;
-
-/**
- * An <code>RuntimeDCException</code> is thrown when the JNI glue code detects
- * an error within itself.
- *
- * @author Gábor Gombás
- */
-
-public class RuntimeDCException extends RuntimeException {
-
-	/**
-	 * Creates a new <code>RuntimeDCException</code> with the
-	 * given message.
-	 *
-	 * @param msg		the message of the exception.
-	 */
-	public RuntimeDCException(String msg) {
-		super(msg);
-	}
-
-	/**
-	 * Creates a new <code>RuntimeDCException</code> with the
-	 * given message and cause.
-	 *
-	 * @param msg		the message of the exception.
-	 * @param cause		the cause of the exception.
-	 */
-	public RuntimeDCException(String msg, Throwable cause) {
-		super(msg, cause);
-	}
-
-	/**
-	 * Creates a new <code>RuntimeDCException</code> with the
-	 * given cause.
-	 *
-	 * @param cause		the cause of the exception.
-	 */
-	public RuntimeDCException(Throwable cause) {
-		super(cause);
-	}
-}
diff --git a/dcapi/java/hu/sztaki/lpds/dc/client/DCClient.java b/dcapi/java/hu/sztaki/lpds/dc/client/DCClient.java
deleted file mode 100644
index 17c2247..0000000
--- a/dcapi/java/hu/sztaki/lpds/dc/client/DCClient.java
+++ /dev/null
@@ -1,43 +0,0 @@
-package hu.sztaki.lpds.dc.client;
-
-import hu.sztaki.lpds.dc.*;
-
-public class DCClient {
-
-	public final static String DC_CHECKPOINT_FILE = new String("__DC_CHECKPOINT_");
-
-	/* ==========================================================
-	 * Class initialization
-	 */
-
-	static {
-		System.loadLibrary("dc-java-client-" + Version.getVersion());
-		if (!Version.getVersion().equals(Version.getNativeVersion()))
-			throw new RuntimeException("DC-API version mismatch: " +
-				"Java side is " + Version.getVersion() + ", " +
-				"JNI side is " + Version.getNativeVersion());
-	}
-
-	/* ==========================================================
-	 * Methods from dc_common.h
-	 */
-	public final synchronized static native int getMaxMessageSize();
-	public final synchronized static native int getMaxSubresults();
-	public final synchronized static native void log(int level, String message);
-
-	public final synchronized static native String getCfgStr(String key);
-	public final synchronized static native int getCfgInt(String key, int defaultValue);
-	public final synchronized static native boolean getCfgBool(String key, boolean DefaultValue);
-
-	/* ==========================================================
-	 * Methods from dc_client.h
-	 */
-	public final synchronized static native void init() throws DCException;
-	public final synchronized static native String resolveFileName(FileType type, String logicalName) throws DCException;
-	public final synchronized static native void sendResult(String logicalFileName, String path, FileMode mode) throws DCException;
-	public final synchronized static native void sendMessage(String message) throws DCException;
-	public final synchronized static native void finish(int exitCode);
-	public final synchronized static native void checkpointMade(String path);
-	public final synchronized static native void fractionDone(double fraction);
-	public final synchronized static native Event checkEvent();
-}
diff --git a/dcapi/java/hu/sztaki/lpds/dc/client/Event.java b/dcapi/java/hu/sztaki/lpds/dc/client/Event.java
deleted file mode 100644
index b8f4667..0000000
--- a/dcapi/java/hu/sztaki/lpds/dc/client/Event.java
+++ /dev/null
@@ -1,37 +0,0 @@
-package hu.sztaki.lpds.dc.client;
-
-import hu.sztaki.lpds.dc.DCException;
-
-public final class Event {
-
-	private final static int DC_CLIENT_CHECKPOINT = 0;
-	private final static int DC_CLIENT_FINISH = 1;
-	private final static int DC_CLIENT_MESSAGE = 2;
-
-	/* Event type */
-	private int type;
-
-	/* Pointer to the C data structure */
-	private long ptr;
-
-	private Event(int type, long ptr) {
-		this.type = type;
-		this.ptr = ptr;
-	}
-
-	public boolean isCheckpointRequest() {
-		return type == DC_CLIENT_CHECKPOINT;
-	}
-
-	public boolean isFinishRequest() {
-		return type == DC_CLIENT_FINISH;
-	}
-
-	public boolean isMessage() {
-		return type == DC_CLIENT_MESSAGE;
-	}
-
-	public native String getMessage() throws DCException;
-
-	native public void finalize();
-}
diff --git a/dcapi/java/hu/sztaki/lpds/dc/client/Version.java.in b/dcapi/java/hu/sztaki/lpds/dc/client/Version.java.in
deleted file mode 100644
index 3a884c2..0000000
--- a/dcapi/java/hu/sztaki/lpds/dc/client/Version.java.in
+++ /dev/null
@@ -1,30 +0,0 @@
-package hu.sztaki.lpds.dc.client;
-
-/**
- * The <code>Version</code> class contains the version of the DC-API package
- * the Java interface was built for.
- *
- * This class is used by both the Java and the JNI component to test each
- * other's version number.
- *
- * @author Gábor Gombás
- */
-
-public final class Version {
-
-	/**
-	 * Returns the version of the Java interface package.
-	 *
-	 * @return		the version string.
-	 */
-	public static final String getVersion() {
-		return "@PACKAGE_VERSION@";
-	}
-
-	/**
-	 * Returns the version of the underlying JNI libraries.
-	 *
-	 * @return		the version string.
-	 */
-	public static final native String getNativeVersion();
-}
diff --git a/dcapi/java/hu/sztaki/lpds/dc/client/package.html b/dcapi/java/hu/sztaki/lpds/dc/client/package.html
deleted file mode 100644
index 90b3114..0000000
--- a/dcapi/java/hu/sztaki/lpds/dc/client/package.html
+++ /dev/null
@@ -1,6 +0,0 @@
-<body>
-Provides client access to the Distributed Computing Platform.
-
- at author Gábor Gombás
-
-</body>
diff --git a/dcapi/java/hu/sztaki/lpds/dc/overview.html b/dcapi/java/hu/sztaki/lpds/dc/overview.html
deleted file mode 100644
index d2e3c40..0000000
--- a/dcapi/java/hu/sztaki/lpds/dc/overview.html
+++ /dev/null
@@ -1,23 +0,0 @@
-<body>
-This package provides access to the Distributed Computing Platform from the Java
-language.
-
-<p>
-The underlying JNI library understands the following system properties:
-<ul>
-<li><tt>dc.jni.debug</tt>: If set, additional debugging messages are
-	logged for every command and every metric value received. The value of
-	this property consists of a series of tokens separated by commas. The
-	possible tokens are understood:
-	<ul>
-	<li><tt>all</tt>: turn on all debugging options.
-	<li><tt>event</tt>: log the reception of events.
-	<li><tt>exception<tt>: log the generation of exceptions.
-	</ul>
-	Every token except <tt>all</tt> can be prefixed with "<tt>no</tt>" to
-	prohibit the corresponding messages.
-</ul>
-
- at author Gábor Gombás
-
-</body>
diff --git a/dcapi/java/hu/sztaki/lpds/dc/package.html b/dcapi/java/hu/sztaki/lpds/dc/package.html
deleted file mode 100644
index 748e59a..0000000
--- a/dcapi/java/hu/sztaki/lpds/dc/package.html
+++ /dev/null
@@ -1,6 +0,0 @@
-<body>
-Provides common access to the Distributed Computing Platform.
-
- at author Gábor Gombás
-
-</body>
diff --git a/dcapi/java/jre-boinc/jre_for_boinc_guide.txt b/dcapi/java/jre-boinc/jre_for_boinc_guide.txt
deleted file mode 100644
index 08f0b70..0000000
--- a/dcapi/java/jre-boinc/jre_for_boinc_guide.txt
+++ /dev/null
@@ -1,41 +0,0 @@
-Guide for preparing Java Runtime Environment (JRE) 
-for use in a BOINC infrastructure on Linux clients.
----------------------------------------------------
-
-1. Requirements
----------------
-
-   i. JRE available at http://java.sun.com/javase/downloads/index.jsp
-
-   ii. DC-API for java (libdcapi-java-client-0.9.so, libdcapi-boinc-client.so)
-
-2. Preparing 
-------------
-
-   i. Extract the 'bin' and 'lib' directories from the JRE distribution.
-      This can be done, by installing JRE on a machine and locating the
-      necessary directories in the installation directory.
-      Copy these two directories with all of their content to a directory
-      called jre.
-
-   ii. Put the files of DC-API in a directory called lib
-   
-   iii. Tar the contents of the above directories (jre, lib) in an archive
-	called lidc-jre.tar
-	eg.: tar czvf lidc-jre.tar jre lib
-
-
-3. Deploying a java application on a BOINC server
--------------------------------------------------
-
-   i. The java application on BOINC consists of the following 
-      a. libdcapi-jre.tar - the jre prepared in part 2.
-      b. application.jar - the java application to be run in BOINC
-      c. launcher - script that untars jre and calls java with the
-	 jar of the application on the client computer
-   
-   ii. Give execution rights to the launcher script only.
-
-   iii. Proceed with signing the files and installing them to the boinc server as usual...
-
-
diff --git a/dcapi/java/util.c b/dcapi/java/util.c
deleted file mode 100644
index a1e4d1c..0000000
--- a/dcapi/java/util.c
+++ /dev/null
@@ -1,350 +0,0 @@
-/** @file util.c
- *
- * Utilities common for the producer and consumer side JNI libraries
- *
- * Author: Gábor Gombás
- */
-
-#ifdef HAVE_CONFIG_H
-#include <config.h>
-#endif
-
-#include <dc_client.h>
-#include "util.h"
-
-#include <alloca.h>
-#include <stdlib.h>
-#include <string.h>
-#include <stdio.h>
-
-/**********************************************************************
- * Throwing exceptions
- */
-
-static void throw_runtime(JNIEnv *env, jthrowable cause, const char *msg)
-{
-	jthrowable exc;
-	jmethodID meth;
-	jstring msgstr;
-	jclass cls;
-	int ret;
-
-	if (jni_debug & DBG_EXCEPTION)
-		DC_log(LOG_NOTICE, "JNI: Throwing RuntimeDCException: %s",
-			msg);
-
-	msgstr = (*env)->NewStringUTF(env, msg);
-	if (!msgstr)
-		return;
-	ret = GET_CTOR(env, RuntimeDCException, &cls, &meth);
-	if (ret)
-		return;
-	exc = (*env)->NewObject(env, cls, meth, msgstr, cause);
-	if (!exc)
-		return;
-	(*env)->DeleteLocalRef(env, msgstr);
-	(*env)->DeleteLocalRef(env, cls);
-
-	(*env)->Throw(env, exc);
-}
-
-static void exception_runtime(JNIEnv *env, jobject cause, const char *fmt, ...)
-{
-	char msg[256];
-	va_list ap;
-
-	va_start(ap, fmt);
-	vsnprintf(msg, sizeof(msg), fmt, ap);
-	va_end(ap);
-
-	throw_runtime(env, cause, msg);
-}
-
-void propagate_runtime(JNIEnv *env, const char *fmt, ...)
-{
-	jthrowable cause;
-	char msg[256];
-	va_list ap;
-
-	va_start(ap, fmt);
-	vsnprintf(msg, sizeof(msg), fmt, ap);
-	va_end(ap);
-
-	cause = (*env)->ExceptionOccurred(env);
-	(*env)->ExceptionClear(env);
-
-	throw_runtime(env, cause, msg);
-}
-
-void throw_exc(JNIEnv *env, const char *classname, const char *fmt, ...)
-{
-	char msg[256];
-	va_list ap;
-	jclass cls;
-
-	va_start(ap, fmt);
-	vsnprintf(msg, sizeof(msg), fmt, ap);
-	va_end(ap);
-
-	if (jni_debug & DBG_EXCEPTION)
-	{
-		const char *p;
-
-		p = strrchr(classname, '/');
-		if (!p)
-			p = classname;
-		DC_log(LOG_NOTICE, "JNI: Throwing %s: %s", p, msg);
-	}
-
-	cls = find_class(env, classname);
-	if (!cls)
-		return;
-	(*env)->ThrowNew(env, cls, msg);
-}
-
-void throw_dcexc(JNIEnv *env, int code, const char *fmt, ...)
-{
-	jthrowable exc;
-	jmethodID meth;
-	jstring msgstr;
-	char msg[256];
-	va_list ap;
-	jclass cls;
-	int ret;
-
-	va_start(ap, fmt);
-	vsnprintf(msg, sizeof(msg), fmt, ap);
-	va_end(ap);
-
-	if (jni_debug & DBG_EXCEPTION)
-		DC_log(LOG_NOTICE, "JNI: Throwing DCException: %s", msg);
-
-	msgstr = (*env)->NewStringUTF(env, msg);
-	if (!msgstr)
-		return;
-	ret = GET_CTOR(env, DCException, &cls, &meth);
-	if (ret)
-		return;
-	exc = (*env)->NewObject(env, cls, meth, code, msgstr);
-	if (!exc)
-		return;
-	(*env)->DeleteLocalRef(env, msgstr);
-	(*env)->DeleteLocalRef(env, cls);
-
-	(*env)->Throw(env, exc);
-}
-
-/**********************************************************************
- * Looking up classes and methods
- */
-
-jclass find_class(JNIEnv *env, const char *classname)
-{
-	jclass cls;
-
-	cls = (*env)->FindClass(env, classname);
-	if (!cls)
-	{
-		unsigned i;
-		char *p;
-
-		p = alloca(strlen(classname) + 1);
-		strcpy(p, classname);
-		for (i = 0; p[i]; i++)
-			if (p[i] == '/')
-				p[i] = '.';
-		DC_log(LOG_ERR, "JNI: Class %s was not found", p);
-
-		/* If FindClass() did not throw an exception, do it now */
-		if (!(*env)->ExceptionCheck(env))
-		{
-			jclass exc;
-			exc = (*env)->FindClass(env,
-				CLASS_ClassNotFoundException);
-			if (exc)
-				(*env)->ThrowNew(env, exc, p);
-		}
-	}
-
-	return cls;
-}
-
-int get_constructor(JNIEnv *env, const char *classname, const char *signature,
-	jclass *cls, jmethodID *meth)
-{
-	*cls = find_class(env, classname);
-	if (!*cls)
-		return -1;
-
-	*meth = (*env)->GetMethodID(env, *cls, "<init>", signature);
-	if (!*meth)
-	{
-		int i;
-		char *buf;
-
-		buf = malloc(strlen(classname) + 1);
-		if (!buf)
-			return -1;
-
-		/* Convert the classname */
-		strcpy(buf, classname);
-		for (i = 0; buf[i]; i++)
-			if (buf[i] == '/')
-				buf[i] = '.';
-
-		propagate_runtime(env, "Class %s has no constructor with "
-			"signature %s", buf, signature);
-		free(buf);
-
-		return -1;
-	}
-	return 0;
-}
-
-jmethodID get_method_id(JNIEnv *env, jclass cls, const char *methodname,
-	const char *signature)
-{
-	jthrowable excoccurred;
-	const char *namestr;
-	jmethodID meth;
-	jclass clscls;
-	jobject name;
-
-	meth = (*env)->GetMethodID(env, cls, methodname, signature);
-	if (meth)
-		return meth;
-
-	/* Now the failure path. First save & clear pending exceptions */
-	excoccurred = (*env)->ExceptionOccurred(env);
-	if (excoccurred)
-		(*env)->ExceptionClear(env);
-
-	/* Determine the class name */
-	clscls = (*env)->GetObjectClass(env, cls);
-	if (!clscls)
-		return NULL;
-
-	meth = (*env)->GetMethodID(env, clscls, "getName", SIG_Class_getName);
-	if (!meth)
-	{
-		if ((*env)->ExceptionCheck(env))
-		{
-			(*env)->ExceptionDescribe(env);
-			(*env)->ExceptionClear(env);
-		}
-		exception_runtime(env, excoccurred, "Failed to locate the "
-			"getName() method of a java.lang.Class object");
-		return NULL;
-	}
-
-	name = (*env)->CallObjectMethod(env, cls, meth);
-	if (!name)
-	{
-		if ((*env)->ExceptionCheck(env))
-		{
-			(*env)->ExceptionDescribe(env);
-			(*env)->ExceptionClear(env);
-		}
-		exception_runtime(env, excoccurred, "Failed to invoke the "
-			"getName() method of a java.lang.Class object");
-		return NULL;
-	}
-
-	namestr = (*env)->GetStringUTFChars(env, name, 0);
-	if (!namestr)
-	{
-		propagate_runtime(env, "Failed to retrieve the name of a "
-			"java.lang.Class object");
-		return NULL;
-	}
-
-	DC_log(LOG_ERR, "JNI: Failed to locate method %s (signature: '%s') of "
-		"class %s", methodname, signature, namestr);
-
-	exception_runtime(env, excoccurred, "Method %s.%s() was not found",
-		namestr, methodname);
-
-	(*env)->ReleaseStringUTFChars(env, name, namestr);
-
-	return NULL;
-}
-
-/**********************************************************************
- * Parse the value of dc.jni.debug
- */
-
-int parse_debug_options(JNIEnv *env)
-{
-	jstring keystr, optstr;
-	jmethodID meth;
-	jclass cls;
-
-	/* Check for properties */
-	cls = find_class(env, CLASS_System);
-	if (!cls)
-	{
-		fprintf(stderr, "Class java.lang.System was not found\n");
-		return -1;
-	}
-	meth = (*env)->GetStaticMethodID(env, cls, "getProperty",
-		SIG_System_getProperty);
-	if (!meth)
-	{
-		fprintf(stderr, "Method java.lang.System.getProperty() "
-			"was not found\n");
-		return -1;
-	}
-
-	/* Look for & process dc.jni.debug */
-	keystr = (*env)->NewStringUTF(env, "dc.jni.debug");
-	if (!keystr)
-	{
-		fprintf(stderr, "Failed to instantiate String object\n");
-		return -1;
-	}
-	optstr = (*env)->CallStaticObjectMethod(env, cls, meth, keystr);
-	if ((*env)->ExceptionCheck(env))
-	{
-		fprintf(stderr, "Exception occurred while reading the "
-			"properties\n");
-		return -1;
-	}
-	if (optstr)
-	{
-		const char *options;
-		char *opts, *p;
-
-		options = (*env)->GetStringUTFChars(env, optstr, NULL);
-		if (!options)
-			return -1;
-
-		opts = alloca(strlen(options + 1));
-		strcpy(opts, options);
-
-		while ((p = strsep(&opts, ",")))
-		{
-			if (!strcmp(p, "all"))
-				jni_debug = (unsigned)-1;
-			else if (!strcmp(p, "event"))
-				jni_debug |= DBG_EVENT;
-			else if (!strcmp(p, "noevent"))
-				jni_debug &= ~DBG_EVENT;
-			else if (!strcmp(p, "exception"))
-				jni_debug |= DBG_EXCEPTION;
-			else if (!strcmp(p, "noexception"))
-				jni_debug &= ~DBG_EXCEPTION;
-			else
-				fprintf(stderr, "JNI: property "
-					"dc.jni.debug contains an unknown "
-					"token: %s\n", p);
-		}
-		(*env)->ReleaseStringUTFChars(env, optstr, options);
-	}
-
-	if (optstr)
-		(*env)->DeleteLocalRef(env, optstr);
-	(*env)->DeleteLocalRef(env, keystr);
-	(*env)->DeleteLocalRef(env, cls);
-
-	return 0;
-}
diff --git a/dcapi/java/util.h b/dcapi/java/util.h
deleted file mode 100644
index 82f8373..0000000
--- a/dcapi/java/util.h
+++ /dev/null
@@ -1,155 +0,0 @@
-/** @file util.h
- *
- * Utilities common for the producer and consumer side JNI libraries
- *
- * Author: Gábor Gombás
- */
-
-#ifndef UTIL_H
-#define UTIL_H
-
-#include "jni_proto.h"
-
-#ifndef __GNUC__
-#define __attribute__((x))
-#endif
-
-#define G_GNUC_UNUSED		__attribute__((__unused__))
-#define G_GNUC_INTERNAL		__attribute__((__visibility__("internal")))
-#define G_GNUC_PRINTF(x, y)	__attribute((__format__(__printf__, x, y)))
-
-/**********************************************************************
- * Data type definitions
- */
-
-/* This is used to obey strict aliasing rules and shut up gcc warnings */
-union getenvarg
-{
-	JNIEnv			*env;
-	void			*ptr;
-};
-
-
-/**********************************************************************
- * Constants
- */
-
-/* Macros used for class definitions:
- *
- * CLASS_<cls>		The fully qualified name of the class (using '/',
- *			not '.')
- * CTOR_<cls>		The signature of the class' constructor
- * SIG_<cls>_<meth>	The signature of method <meth> of class <cls>
- */
-
-/* Native Java classes */
-#define CLASS_ArrayList \
-	"java/util/ArrayList"
-#define CTOR_ArrayList \
-	"(I)V"
-#define SIG_ArrayList_add \
-	"(ILjava/lang/Object;)V"
-#define CLASS_Boolean \
-	"java/lang/Boolean"
-#define CTOR_Boolean \
-	"(Z)V"
-#define SIG_Boolean_booleanValue \
-	"()Z"
-#define SIG_Class_getName \
-	"()Ljava/lang/String;"
-#define CLASS_ClassNotFoundException \
-	"java/lang/ClassNotFoundException"
-#define CLASS_Double \
-	"java/lang/Double"
-#define CTOR_Double \
-	"(D)V"
-#define SIG_Double_doubleValue \
-	"()D"
-#define CLASS_IllegalArgumentException \
-	"java/lang/IllegalArgumentException"
-#define CLASS_Integer \
-	"java/lang/Integer"
-#define CTOR_Integer \
-	"(I)V"
-#define SIG_Integer_intValue \
-	"()I"
-#define CLASS_Long \
-	"java/lang/Long"
-#define CTOR_Long \
-	"(J)V"
-#define SIG_Long_longValue \
-	"()J"
-#define CLASS_NullPointerException \
-	"java/lang/NullPointerException"
-#define CLASS_System \
-	"java/lang/System"
-#define SIG_System_getProperty \
-	"(Ljava/lang/String;)Ljava/lang/String;"
-
-/* Classes defined in package hu.sztaki.lpds.dc */
-#define CLASS_ClientEvent \
-	"hu/sztaki/lpds/dc/client/Event"
-#define CTOR_ClientEvent \
-	"(JI)V"
-#define CLASS_ClientVersion \
-	"hu/sztaki/lpds/dc/client/Version"
-#define SIG_ClientVersion_getVersion \
-	"()Ljava/lang/String;"
-#define CLASS_DCException \
-	"hu/sztaki/lpds/dc/DCException"
-#define CTOR_DCException \
-	"(ILjava/lang/String;)V"
-#define CLASS_RuntimeDCException \
-	"hu/sztaki/lpds/dc/RuntimeDCException"
-#define CTOR_RuntimeDCException \
-	"(Ljava/lang/String;Ljava/lang/Throwable;)V"
-
-
-/* Debugging classes */
-#define DBG_CONN		(1 << 0)
-#define DBG_EVENT		(1 << 1)
-#define DBG_EXCEPTION		(1 << 2)
-
-
-/**********************************************************************
- * Macros
- */
-
-#define RETURN_IF_EXCEPTION(env, x) do {\
-	if ((*(env))->ExceptionCheck(env)) \
-		return (x); \
-	} while (0)
-
-#define GET_CTOR(env, name, cls, meth) \
-	get_constructor(env, CLASS_ ## name, CTOR_ ## name, cls, meth)
-#define GET_METH(env, cls, clsname, methname) \
-	get_method_id(env, cls, G_STRINGIFY(methname), \
-		SIG_ ## clsname ## _ ## methname)
-
-
-/**********************************************************************
- * Prototypes
- */
-
-void propagate_runtime(JNIEnv *env, const char *fmt, ...)
-	G_GNUC_PRINTF(2, 3) G_GNUC_INTERNAL;
-void throw_exc(JNIEnv *env, const char *classname, const char *fmt, ...)
-	G_GNUC_PRINTF(3, 4) G_GNUC_INTERNAL;
-void throw_dcexc(JNIEnv *env, int code, const char *fmt, ...)
-	G_GNUC_PRINTF(3, 4) G_GNUC_INTERNAL;
-
-jclass find_class(JNIEnv *env, const char *classname) G_GNUC_INTERNAL;
-int get_constructor(JNIEnv *env, const char *class, const char *args,
-	jclass *cls, jmethodID *meth) G_GNUC_INTERNAL;
-jmethodID get_method_id(JNIEnv *env, jclass cls, const char *methodname,
-	const char *signature) G_GNUC_INTERNAL;
-int parse_debug_options(JNIEnv *env) G_GNUC_INTERNAL;
-
-
-/**********************************************************************
- * Global variables
- */
-
-extern unsigned jni_debug G_GNUC_INTERNAL;
-
-#endif /* UTIL_H */
diff --git a/dcapi/local/Makefile.am b/dcapi/local/Makefile.am
deleted file mode 100644
index 82a7ce0..0000000
--- a/dcapi/local/Makefile.am
+++ /dev/null
@@ -1,38 +0,0 @@
-lib_LTLIBRARIES =
-
-if BUILD_MASTER
-lib_LTLIBRARIES += libdcapi-local.la
-endif
-
-if BUILD_CLIENT
-lib_LTLIBRARIES += libdcapi-client-local.la
-endif
-
-pkgconfigdir = ${libdir}/pkgconfig
-pkgconfig_DATA = dcapi-local-client.pc dcapi-local-master.pc
-
-AM_CPPFLAGS = -I$(top_srcdir)/include $(GLIB_CFLAGS)
-
-noinst_HEADERS = \
-		local_common.h \
-		local_master.h \
-		local_result.h \
-		local_utils.h \
-		local_wu.h
-
-libdcapi_local_la_SOURCES = \
-		local_master.c \
-		local_events.c \
-		local_result.c \
-		local_utils.c \
-		local_common.c \
-		local_wu.c
-libdcapi_local_la_LIBADD = ../common/libdcapi-common-master.la $(GLIB_LIBS) -luuid
-libdcapi_local_la_LDFLAGS = -version-info 1:0:0 -export-symbols $(top_srcdir)/common/master.sym
-
-libdcapi_client_local_la_SOURCES = \
-		local_client.c \
-		local_utils.c \
-		local_common.c
-libdcapi_client_local_la_LIBADD = ../common/libdcapi-common-client.la
-libdcapi_client_local_la_LDFLAGS = -static
diff --git a/dcapi/local/dcapi-local-client.pc.in b/dcapi/local/dcapi-local-client.pc.in
deleted file mode 100644
index 811ecc1..0000000
--- a/dcapi/local/dcapi-local-client.pc.in
+++ /dev/null
@@ -1,11 +0,0 @@
-prefix=@prefix@
-exec_prefix=@exec_prefix@
-libdir=@libdir@
-includedir=@includedir@
-
-Name: DC-API Local Client
-Description: Local client implementation for DC-API
-Version: @PACKAGE_VERSION@
-Requires.private: glib-2.0
-Libs: -L${libdir} -ldcapi-client-local
-Cflags: -I${includedir}
diff --git a/dcapi/local/dcapi-local-master.pc.in b/dcapi/local/dcapi-local-master.pc.in
deleted file mode 100644
index 718093a..0000000
--- a/dcapi/local/dcapi-local-master.pc.in
+++ /dev/null
@@ -1,11 +0,0 @@
-prefix=@prefix@
-exec_prefix=@exec_prefix@
-libdir=@libdir@
-includedir=@includedir@
-
-Name: DC-API Local Master
-Description: Local master implementation for DC-API
-Version: @PACKAGE_VERSION@
-Requires: glib-2.0 uuid
-Libs: -L${libdir} -ldcapi-local
-Cflags: -I${includedir}
diff --git a/dcapi/local/local_client.c b/dcapi/local/local_client.c
deleted file mode 100644
index bbaa419..0000000
--- a/dcapi/local/local_client.c
+++ /dev/null
@@ -1,373 +0,0 @@
-/*
- * local/local_client.c
- *
- * DC-API functions of client side
- *
- * (c) Gabor Vida 2005-2006, Daniel Drotos, 2007
- */
-
-/* $Id$ */
-/* $Date$ */
-/* $Revision$ */
-
-#include <stdio.h>
-#include <stdlib.h>
-#include <string.h>
-#include <stdlib.h>
-#include <sys/stat.h>
-#include <dirent.h>
-#include <unistd.h>
-#include <errno.h>
-
-#include <dc_client.h>
-#include <dc_internal.h>
-
-#include "local_common.h"
-#include "local_utils.h"
-
-
-static int _DC_checkpoint_file_requested= 0;
-static int _DC_checkpoint_made= 0;
-
-static char *
-_DC_cfg(enum _DC_e_param what)
-{
-	if (what >= cfg_nuof)
-		return(NULL);
-	if (_DC_params[what].lvalue)
-		return(_DC_params[what].lvalue);
-
-	_DC_params[what].lvalue= DC_getCfgStr(_DC_params[what].name);
-	if (_DC_params[what].lvalue)
-		return(_DC_params[what].lvalue);
-	return(_DC_params[what].def);
-}
-
-/********************************************************************
- * Common API functions
- */
-
-int DC_getMaxMessageSize(void)
-{
-        return MAX_MESSAGE_SIZE;
-}
-
-int DC_getMaxSubresults(void)
-{
-        return MAX_SUBRESULTS;
-}
-
-unsigned DC_getGridCapabilities(void)
-{
-        return (DC_GridCapabilities)(DC_GC_STDERR | DC_GC_STDOUT);
-}
-
-/********************************************************************
- * Client API functions
- */
-/*done*/
-int DC_initClient(void)
-{
-	char *message;
-	int ret= _DC_parseCfg(CLIENT_CONFIG_NAME);
-
-	if (ret)
-		fprintf(stderr, "Error parsing configfile %s",
-			CLIENT_CONFIG_NAME);
-
-	_DC_init_utils();
-	_DC_init_common();
-
-	DC_log(LOG_DEBUG, "Slave dcapi initialized");
-
-	message= _DC_read_message(_DC_cfg(cfg_management_box),
-				  _DCAPI_MSG_COMMAND, /*FALSE*/0);
-	if (message &&
-	    strcmp(message, _DCAPI_CMD_RESUME) == 0)
-	{
-		DC_log(LOG_INFO, "Resume, restarting...");
-		_DC_read_message(_DC_cfg(cfg_management_box),
-				 _DCAPI_MSG_COMMAND, /*TRUE*/1);
-	}
-
-	return ret;
-}
-
-/*done*/
-char *DC_resolveFileName(DC_FileType type, const char *logicalFileName)
-{
-	/* init_log calls this fn, so it is not possible to call DC_log
-	   from here */
-	/*DC_log(LOG_DEBUG, "DC_resolveFileName(%d,%s)",
-	  type, logicalFileName);*/
-	char *cn= _DC_cfg(cfg_checkpoint_file);
-	if (!strcmp(logicalFileName, DC_CHECKPOINT_FILE))
-	{
-		switch (type)
-		{
-		case DC_FILE_IN:
-		{
-			/* - param of last DC_checkpointMade()
-			   - filename created by previous run
-			   - NULL otherwise */
-			if (_DC_checkpoint_made)
-			{
-				char *fn= (char*)malloc(strlen(cn)+100);
-				sprintf(fn, "%s_finished.txt", cn);
-				return(fn);
-			}
-			else
-			{
-				FILE *f;
-				char *fn= (char*)malloc(strlen(cn)+100);
-				sprintf(fn, "%s_finished.txt", cn);
-				if ((f= fopen(fn, "r")) != NULL)
-				{
-					fclose(f);
-					return(fn);
-				}
-				else
-				{
-					free(fn);
-					return(NULL);
-				}
-			}
-			break;
-		}
-		case DC_FILE_OUT:
-		{
-			char *s;
-			/* new non-existant name */
-			if (_DC_checkpoint_file_requested)
-			{
-				DC_log(LOG_ERR, "Checkpoint file creation "
-				       "can not be restarted "
-					"(DC_resolveFileName("
-					DC_CHECKPOINT_FILE
-					") called twice without calling of "
-					"DC_checkpointMade())");
-				return(NULL);
-			}
-			_DC_checkpoint_file_requested= 1;
-			s= (char*)malloc(strlen(cn)+100);
-			sprintf(s, "%s_creating.txt", cn);
-			return(s);
-			break;
-		}
-		default:
-			return(NULL);
-		}
-	}
-	return(strdup((char*)logicalFileName));
-/*
-        if (!strcmp(logicalFileName, DC_CHECKPOINT_FILE))
-        {
-		return strdup(CKPT_LABEL);
-        }
-	return strdup(logicalFileName);
-*/
-}
-
-/*done*/
-int DC_sendResult(const char *logicalFileName, const char *path, DC_FileMode fileMode)
-{
-	char *fn;
-	int ret;
-
-	DC_log(LOG_DEBUG, "DC_sendResult(%s,%s,%d)",
-	       logicalFileName,
-	       path,
-	       fileMode);
-	fn= malloc(strlen(logicalFileName)+100);
-	strcpy(fn, _DC_cfg(cfg_subresults_box));
-	strcat(fn, "/real_files");
-	if ((ret= _DC_mkdir_with_parents(fn, S_IRWXU|
-					 S_IRGRP|S_IXGRP|
-					 S_IROTH|S_IXOTH)) != DC_OK)
-	{
-		DC_log(LOG_ERR, "Failed to create dir for subresult (%s): %s",
-		       fn, strerror(errno));
-		free(fn);
-		return(ret);
-	}
-	strcat(fn, "/");
-	strcat(fn, logicalFileName);
-	if ((ret= _DC_copyFile(path, fn)) != DC_OK)
-	{
-		DC_log(LOG_ERR, "Failed to copy subresult file %s to "
-		       "%s", path, fn);
-		free(fn);
-		return(ret);
-	}
-	ret= _DC_create_message(_DC_cfg(cfg_subresults_box),
-				_DCAPI_MSG_LOGICAL, logicalFileName, NULL);
-	free(fn);
-	return(ret);
-
-	// not implemented yet!
-
-	return DC_ERR_NOTIMPL;
-}
-
-/*done*/
-int DC_sendMessage(const char *message)
-{
-	DC_log(LOG_DEBUG, "DC_sendMessage(%s)", message);
-	return _DC_create_message(_DC_cfg(cfg_client_message_box),
-				  _DCAPI_MSG_MESSAGE, message, NULL);
-	// not implemented yet!
-
-	return DC_ERR_NOTIMPL;
-}
-
-/*done*/
-DC_ClientEvent *DC_checkClientEvent(void)
-{
-	char *message;
-	DC_ClientEvent *e= NULL;
-
-	message= _DC_read_message(_DC_cfg(cfg_master_message_box),
-				  _DCAPI_MSG_MESSAGE, /*TRUE*/1);
-	if (message)
-	{
-		if ((e= calloc(1, sizeof(DC_ClientEvent))))
-		{
-			DC_log(LOG_DEBUG, "API event created: %p", e);
-			e->type= DC_CLIENT_MESSAGE;
-			e->message= message;
-			DC_log(LOG_DEBUG, "Message of the event: %s",
-			       e->message);
-		}
-		else
-		{
-			free(message);
-			DC_log(LOG_ERR, "Failed to create "
-			       "API event, memory allocation "
-			       "error");
-		}
-		return(e);
-	}
-
-	message= _DC_read_message(_DC_cfg(cfg_management_box),
-				  _DCAPI_MSG_COMMAND, /*TRUE*/1);
-	if (message &&
-	    strcmp(message, _DCAPI_CMD_SUSPEND) == 0)
-	{
-		char *fn;
-		int f;
-
-		DC_log(LOG_INFO, "Master asked me to suspend");
-		_DC_create_message(_DC_cfg(cfg_management_box),
-				   _DCAPI_MSG_ACK,
-				   _DCAPI_ACK_SUSPEND,
-				   NULL);
-
-		fn= DC_resolveFileName(DC_FILE_IN, DC_CHECKPOINT_FILE);
-		if (fn != NULL)
-			free(fn);
-		else
-		{
-			DC_log(LOG_WARNING, "Slave suspending but "
-			       "no checkpoint made yet");
-			free(fn);
-		}
-
-		fflush(NULL);
-		fn= DC_resolveFileName(DC_FILE_OUT, DC_LABEL_STDOUT);
-		if (fn)
-		{
-			if ((f= open(fn, O_APPEND)) > 0)
-			{
-				fsync(f);
-				close(f);
-			}
-			free(fn);
-		}
-		_DC_create_message(_DC_cfg(cfg_output_cache),
-				   DC_LABEL_STDOUT,
-				   NULL,
-				   DC_LABEL_STDOUT);
-		fn= DC_resolveFileName(DC_FILE_OUT, DC_LABEL_STDERR);
-		if (fn)
-		{
-			if ((f= open(fn, O_APPEND)) > 0)
-			{
-				fsync(f);
-				close(f);
-			}
-			free(fn);
-		}
-		_DC_create_message(_DC_cfg(cfg_output_cache),
-				   DC_LABEL_STDERR,
-				   NULL,
-				   DC_LABEL_STDERR);
-
-		DC_finishClient(0);
-	}
-	// not implemented yet!
-
-	return NULL;
-}
-
-/*done*/
-void DC_destroyClientEvent(DC_ClientEvent *event)
-{
-	DC_log(LOG_DEBUG, "DC_destroyClientEvent(%p)", event);
-	if (event)
-	{
-		switch (event->type)
-		{
-		case DC_CLIENT_MESSAGE:
-		{
-			if (event->message)
-				free(event->message);
-			break;
-		}
-		default:
-			break;
-		}
-		free(event);
-	}
-	// not implemented yet!
-}
-
-/*done*/
-void DC_checkpointMade(const char *fileName)
-{
-	DC_log(LOG_DEBUG, "DC_checkpointMade(%s)", fileName);
-	_DC_checkpoint_file_requested= 0;
-	if (fileName)
-	{
-		char *cn= _DC_cfg(cfg_checkpoint_file);
-		char *fn;
-		fn= (char*)malloc(strlen(cn)+100);
-		sprintf(fn, "%s_finished.txt", cn);
-		if (rename(fileName, fn) != 0)
-		{
-			DC_log(LOG_ERR, "Renaming %s to %s failed: %s",
-			       fileName, fn, strerror(errno));
-		}
-		else
-			_DC_checkpoint_made++;
-		free(fn);
-	}
-}
-
-void DC_fractionDone(double fraction)
-{
-	// Nothing to do with it.
-}
-
-void DC_finishClient(int exitcode)
-{
-	// XXX Need to send a message to the master side of the DC_API!
-
-	exit(exitcode);
-}
-
-
-/* End of local/local_client.c */
-
-/* Local variables: */
-/* c-file-style: "linux" */
-/* End: */
diff --git a/dcapi/local/local_common.c b/dcapi/local/local_common.c
deleted file mode 100644
index b674540..0000000
--- a/dcapi/local/local_common.c
+++ /dev/null
@@ -1,62 +0,0 @@
-/*
- * local/local_common.c
- *
- * DC-API functions common for master and slave side
- *
- * (c) Daniel Drotos, 2006
- */
-
-/* $Id$ */
-/* $Date$ */
-/* $Revision$ */
-
-
-#include "local_common.h"
-
-
-struct _DC_s_param _DC_params[cfg_nuof];
-
-
-void
-_DC_init_common(void)
-{
-	int i;
-	
-	for (i= 0; i < cfg_nuof; i++)
-	{
-		_DC_params[i].name= 0;
-		_DC_params[i].def= 0;
-		_DC_params[i].lvalue= 0;
-		_DC_params[i].gvalue= 0;
-	}
-	_DC_params[cfg_client_message_box].name= "ClientMessageBox";
-	_DC_params[cfg_client_message_box].def= "_dcapi_client_messages";
-
-	_DC_params[cfg_master_message_box].name= "MasterMessageBox";
-	_DC_params[cfg_master_message_box].def= "_dcapi_master_messages";
-
-	_DC_params[cfg_subresults_box].name= "SubresultBox";
-	_DC_params[cfg_subresults_box].def= "_dcapi_client_subresults";
-
-	_DC_params[cfg_management_box].name= "SystemMessageBox";
-	_DC_params[cfg_management_box].def= "_dcapi_system_messages";
-
-	_DC_params[cfg_executable].name= "Executable";
-	_DC_params[cfg_executable].def= 0/*NULL*/;
-	
-	_DC_params[cfg_leave_files].name= "LeaveFiles";
-	_DC_params[cfg_leave_files].def= "0";
-
-	_DC_params[cfg_checkpoint_file].name= "CheckpointFile";
-	_DC_params[cfg_checkpoint_file].def= "_dcapi_checkpoint";
-
-	_DC_params[cfg_output_cache].name= "SavedOutputs";
-	_DC_params[cfg_output_cache].def= "_dcapi_saved_output";
-}
-
-
-/* End of local/local_common.c */
-
-/* Local variables: */
-/* c-file-style: "linux" */
-/* End: */
diff --git a/dcapi/local/local_common.h b/dcapi/local/local_common.h
deleted file mode 100644
index 3140b28..0000000
--- a/dcapi/local/local_common.h
+++ /dev/null
@@ -1,119 +0,0 @@
-/*
- * local/local_common.h
- *
- * DC-API definitions of both client and master side
- *
- * (c) Gabor Vida 2005-2006, Daniel Drotos, 2007
- */
-
-/* $Id$ */
-/* $Date$ */
-/* $Revision$ */
-
-/* Definitions common for both the server and client side */
-#ifndef __DC_API_LOCAL_COMMON_H
-#define __DC_API_LOCAL_COMMON_H
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-/* For the local backend, it is OK to use glib on the client side as well */
-#include <glib.h>
-
-/* Prefix of subresult file labels */
-#define SUBRESULT_PFX		"dc_subresult_"
-
-/* Logical names of the standard output file */
-#define STDOUT_LABEL		"dc_stdout"
-
-/* Logical names of the standard error file */
-#define STDERR_LABEL		"dc_stderr"
-
-/* Logical names of the checkpoint file */
-#define CKPT_LABEL		"dc_checkpoint"
-
-/* Name of the client-side config. file */
-#define CLIENTCONF_LABEL	"dc_client.conf"
-
-/* Maximum allowed message length */
-#define MAX_MESSAGE_SIZE	16384
-
-/* Maximum allowed message length */
-/*
- * local/local_master.c
- *
- * DC-API functions of master side
- *
- * (c) Gabor Vida 2005-2006, Daniel Drotos, 2007
- */
-
-/* $Id$ */
-/* $Date$ */
-/* $Revision$ */
-
-#define MAX_SUBRESULTS		100
-
-/* Prefix for internal messages between the client-side and master-side DC-API */
-#define DCAPI_MSG_PFX		"__dcapi__"
-
-/* Must match the definition of WorkdirFile */
-static const char *const workdir_prefixes[] =
-{
-        "in_", "out_", "checkpoint", "dc_"
-};
-
-
-/****************************************************************************/
-
-#define CLIENT_CONFIG_NAME	"_dcapi_configfile.txt"
-
-
-enum _DC_e_param {
-	cfg_client_message_box= 0,
-	cfg_master_message_box,
-	cfg_subresults_box,
-	cfg_management_box,
-	cfg_executable,
-	cfg_leave_files,
-	cfg_checkpoint_file,
-	cfg_output_cache,
-	cfg_nuof
-};
-
-struct _DC_s_param {
-	char *name;
-	char *def;
-	char *lvalue;
-	char *gvalue;
-};
-
-
-extern struct _DC_s_param _DC_params[cfg_nuof] G_GNUC_INTERNAL;
-
-extern void _DC_init_common(void) G_GNUC_INTERNAL;
-#define _DCAPI_MSG_MESSAGE      "message"
-#define _DCAPI_MSG_LOGICAL      "logical_name"
-#define _DCAPI_MSG_COMMAND      "command"
-#define _DCAPI_MSG_ACK          "acknowledge"
-
-#define _DCAPI_CMD_SUSPEND      "suspend"
-#define _DCAPI_ACK_SUSPEND      "suspending"
-
-#define _DCAPI_CMD_RESUME       "resume"
-
-#define _DCAPI_SIG_SERIALIZED   "serialized"
-
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif /* __DC_API_LOCAL_COMMON_H */
-
-
-/* End of local/local_common.h */
-
-/* Local variables: */
-/* c-file-style: "linux" */
-/* End: */
diff --git a/dcapi/local/local_events.c b/dcapi/local/local_events.c
deleted file mode 100644
index 2790278..0000000
--- a/dcapi/local/local_events.c
+++ /dev/null
@@ -1,532 +0,0 @@
-/*
- * local/local_events.c
- *
- * DC-API functions related to event handling
- *
- * (c) Gabor Vida 2005-2006, Daniel Drotos, 2007
- */
-
-/* $Id$ */
-/* $Date$ */
-/* $Revision$ */
-
-#ifdef HAVE_CONFIG_H
-#include <config.h>
-#endif
-
-#include <unistd.h>
-#include <string.h>
-#include <stdlib.h>
-
-#include "local_master.h"
-#include "local_utils.h"
-#include "local_result.h"
-
-
-static int _DC_wu_terminated(DC_Workunit *wu)
-{
-	char syscmd[256];
-	int retval;
-
-	snprintf(syscmd, 256, "ps -p %d >/dev/null", wu->pid);
-	retval = system(syscmd);
-
-	/* retval == 0 means that the process is still in output of ps
-		but it can be <defunct>.
-		So check it again.
-	*/
-	if (retval == 0) {
-		snprintf(syscmd, 256, "ps -p %d | grep defunct >/dev/null",
-			wu->pid);
-		retval = system(syscmd);
-		if (retval == 0) retval = 1; /* defunct means finished */
-		else if (retval == 1) retval = 0;
-	}
-	if (retval == 1) { /* process finished (not exists) */
-		/* create the result object */
-		DC_log(LOG_INFO, "Work unit %s with pid %d is found to be finished",
-			wu->name, wu->pid);
-		wu->state = DC_WU_FINISHED;
-		return 1;
-	}
-	return 0;
-}
-
-/* by DD */
-static DC_MasterEvent *
-_DC_event_create(DC_Workunit *wu,
-		 DC_Result *result,
-		 DC_PhysicalFile *subresult,
-		 char *message)
-{
-	DC_MasterEvent *e;
-
-	if ((e= g_new0(DC_MasterEvent, 1)) == NULL)
-		return(NULL);
-	e->wu= wu;
-	if (result)
-	{
-		e->type= DC_MASTER_RESULT;
-		e->result= result;
-	}
-	else if (subresult)
-	{
-		e->type= DC_MASTER_SUBRESULT;
-		e->subresult= subresult;
-	}
-	else if (message)
-	{
-		e->type= DC_MASTER_MESSAGE;
-		e->message= g_strdup(message);
-	}
-	else
-	{
-		DC_log(LOG_ERR, "Wrong invokation of _DC_event_create("
-		       "%p,%p,%p,%p)", wu, result, subresult, message);
-		g_free(e);
-		return(NULL);
-	}
-	return(e);
-}
-
-/* by DD */
-static DC_MasterEvent *
-_DC_wu_infra2api_event(DC_Workunit *wu)
-{
-	if (_DC_wu_terminated(wu))
-	{
-		DC_log(LOG_DEBUG, "Job terminated, "
-		       "asked to susp=%d",
-		       wu->asked_to_suspend);
-		GString *s;
-		s= g_string_new("");
-		g_string_printf(s, "%s/%s", wu->workdir,
-				_DC_wu_cfg(wu, cfg_management_box));
-		char *message;
-		if ((message= _DC_read_message(s->str,
-					       _DCAPI_MSG_ACK,
-					       FALSE)))
-		{
-			DC_log(LOG_DEBUG, "Acknowledge exists: %s",
-			       message);
-			if (strcmp(message, _DCAPI_ACK_SUSPEND) == 0)
-			{
-				DC_log(LOG_DEBUG, "Suspend "
-				       "acknowledged");
-				_DC_read_message(s->str,
-						 _DCAPI_MSG_ACK,
-						 TRUE);
-				wu->asked_to_suspend= TRUE;
-			}
-		}
-		g_string_free(s, TRUE);
-		
-		if (wu->asked_to_suspend)
-		{
-			/*_DC_wu_set_state(wu, DC_WU_SUSPENDED);*/
-			wu->state= DC_WU_SUSPENDED;
-			wu->asked_to_suspend= FALSE;
-		}
-		else
-		{
-			DC_MasterEvent *e;
-			e= _DC_event_create(wu, _DC_result_create(wu),
-					    NULL, NULL);
-			DC_log(LOG_DEBUG, "Result event created: "
-			       "%p for wu (%p-\"%s\")",
-			       e, wu, wu->name);
-			DC_log(LOG_DEBUG, "Result of the event: %p",
-			       e->result);
-			/*_DC_wu_set_state(wu, DC_WU_FINISHED);*/
-			wu->state= DC_WU_FINISHED;
-			return(e);
-		}
-	}
-	return(NULL);
-}
-
-static void testWUEvents(void *key, void *value, void *ptr) /* by VG */
-{
-	DC_Workunit *wu = (DC_Workunit *)value;
-	DC_Result *result;
-	char syscmd[256];
-	int retval;
-
-	snprintf(syscmd, 256, "ps -p %d >/dev/null", wu->pid);
-	retval = system(syscmd);
-
-	/* retval == 0 means that the process is still in output of ps
-		but it can be <defunct>.
-		So check it again.
-	*/
-	if (retval == 0) {
-		snprintf(syscmd, 256, "ps -p %d | grep defunct >/dev/null",
-			wu->pid);
-		retval = system(syscmd);
-		if (retval == 0) retval = 1; /* defunct means finished */
-		else if (retval == 1) retval = 0;
-	}
-	if (retval == 1) { /* process finished (not exists) */
-		/* create the result object */
-		DC_log(LOG_INFO, "Work unit %s with pid %d is found to be finished",
-			wu->name, wu->pid);
-		wu->state = DC_WU_FINISHED;
-
-		result = _DC_createResult(wu->name);
-		if (result)
-		{
-			_DC_result_callback(result->wu, result);
-			_DC_destroyResult(result);
-		}
-	}
-
-	return;
-}
-
-int _DC_searchForEvents() /* by VG */
-{
-	if (!_DC_wu_table)
-	{
-		DC_log(LOG_WARNING, "Searching for events is only usefull if there is any running work unit!");
-		return DC_ERR_BADPARAM;
-	}
-
-	g_hash_table_foreach(_DC_wu_table, (GHFunc)testWUEvents, NULL);
-
-	return DC_OK;
-}
-
-
-/* by DD */
-/*
-static void
-_DC_event_destroy(DC_MasterEvent *event)
-{
-	if (!event)
-		return;
-	switch (event->type)
-	{
-	case DC_MASTER_RESULT:
-		if (event->result)
-			_DC_result_destroy(event->result);
-		break;
-	case DC_MASTER_SUBRESULT:
-		if (event->subresult)
-			_DC_destroyPhysicalFile(event->subresult);
-		break;
-	case DC_MASTER_MESSAGE:
-		if (event->message)
-			g_free(event->message);
-		break;
-	default:
-		break;
-	}
-	g_free(event);
-}
-*/
-
-/* by DD */
-static DC_MasterEvent *
-_DC_wu_check_client_messages(DC_Workunit *wu)
-{
-	GString *s;
-	char *message;
-	DC_MasterEvent *e= NULL;
-
-	/*if (!_DC_wu_check(wu))
-	  return(NULL);*/
-
-	s= g_string_new(wu->workdir);
-	g_string_append_printf(s, "/%s",
-			       _DC_wu_cfg(wu, cfg_client_message_box));
-	/*DC_log(LOG_DEBUG, "Checking box %s for message\n", s->str);*/
-	if ((message= _DC_read_message(s->str, _DCAPI_MSG_MESSAGE, TRUE)))
-	{
-		e= _DC_event_create(wu, NULL, NULL, message);
-		DC_log(LOG_DEBUG, "Message event created: %p "
-		       "for wu (%p-\"%s\")", e, wu, wu->name);
-		DC_log(LOG_DEBUG, "Message of the event: %s", e->message);
-	}
-
-	/*
-	g_string_printf(s, "%s/%s", wu->data.workdir,
-			_DC_wu_cfg(wu, cfg_management_box));
-	if ((message= _DC_read_message(s->str, _DCAPI_MSG_ACK, TRUE)))
-	{
-		DC_log(LOG_DEBUG, "Acknowledge arrived: %s", message);
-		if (strcmp(message, _DCAPI_ACK_SUSPEND) == 0)
-		{
-			wu->asked_to_suspend= TRUE;
-		}
-	}
-	*/
-
-	if (e == NULL/*)
-		_DC_counter++;
-		  if (_DC_counter % 5 == 0*/)
-	{
-		g_string_printf(s, "%s/%s", wu->workdir,
-				_DC_wu_cfg(wu, cfg_subresults_box));
-		/*DC_log(LOG_DEBUG, "Checking box %s for logical_name\n",
-		  s->str);*/
-		if ((message= _DC_read_message(s->str, _DCAPI_MSG_LOGICAL,
-					       TRUE)))
-		{
-			DC_PhysicalFile *f;
-			g_string_append_printf(s, "/real_files/%s", message);
-			DC_log(LOG_DEBUG, "Got subresult %s %s",
-			       message, s->str);
-			f= _DC_createPhysicalFile(message, s->str);
-			e= _DC_event_create(wu, NULL, f, NULL);
-		}
-	}
-
-	g_string_free(s, TRUE);
-	return(e);
-}
-
-
-/* by DD */
-static void
-_DC_process_event(DC_MasterEvent *event)
-{
-	if (!event)
-		return;
-
-	DC_log(LOG_DEBUG, "Processing an event %d, calling callback...",
-	       event->type);
-	switch (event->type)
-	{
-	case DC_MASTER_RESULT:
-	{
-		if (_DC_result_callback)
-			(*_DC_result_callback)(event->wu,
-					       event->result);
-		break;
-	}
-	case DC_MASTER_SUBRESULT:
-	{
-		if (_DC_subresult_callback)
-			(*_DC_subresult_callback)(event->wu,
-						  event->subresult->label,
-						  event->subresult->path);
-		break;
-	}
-	case DC_MASTER_MESSAGE:
-	{
-		if (_DC_message_callback)
-			(*_DC_message_callback)(event->wu,
-						event->message);
-		break;
-	}
-	}
-	DC_destroyMasterEvent(event);
-}
-
-int DC_processMasterEvents(int timeout)
-{
-	/* call callback and destroy event */
-	time_t start, now;
-	DC_MasterEvent *event;
-
-	DC_log(LOG_DEBUG, "DC_processMasterEvents(%d)",
-	       timeout);
-
-	if ((event= DC_waitMasterEvent(NULL, 0)) != NULL)
-		_DC_process_event(event);
-	if (timeout==0)
-		return(DC_OK);
-
-	start= time(NULL);
-	now= time(NULL);
-	while (now-start <= timeout &&
-	       g_hash_table_size(_DC_wu_table) > 0)
-	{
-		sleep(1);
-		if ((event= DC_waitMasterEvent(NULL, 0)) != NULL)
-			_DC_process_event(event);
-		now= time(NULL);
-	}
-	return(DC_OK);
-/*
-	int retval;
-	static time_t start, current;
-
-	if (!_dc_resultcb || !_dc_subresultcb || !_dc_messagecb)
-	{
-		DC_log(LOG_ERR, "DC_processMasterEvents: callbacks are not set up");
-		return DC_ERR_CONFIG;
-	}
-
-	DC_log(LOG_INFO, "DC_processMasterEvents: Searching for events ...");
-
-	start = time(NULL);
-	while (1)
-	{
-*/
- 	/* implemted in rm.c */
-/*
-		retval = _DC_searchForEvents();
-		if (retval)
-			return retval;
-
-		if (DC_getWUNumber(DC_WU_RUNNING) == 0)
-		{
-			DC_log(LOG_INFO, "DC_processMasterEvents: No more running workunits ... returning");
-			return 0;
-		}
-
-		current = time(NULL);
-		if (current - start > timeout)
-		{
-			DC_log(LOG_INFO, "DC_processMasterEvents: timeout is over ... returning");
-			return 0;
-		}
-		sleep(sleep_interval);
-	}
-*/
-}
-
-/* by DD */
-static DC_MasterEvent *_DC_filtered_event;
-static int _DC_counter;
-
-static gboolean
-_DC_check_filtered_wu_event(gpointer wu_name, gpointer w, gpointer ptr)
-{
-	DC_Workunit *wu= (DC_Workunit *)w;
-	char *filter= (char *)ptr;
-	char *tag;
-	int match= TRUE;
-	gboolean found;
-
-	_DC_counter++;
-	tag= DC_getWUTag(wu);
-	if (filter)
-		if (strcmp(tag, filter) != 0)
-			tag= FALSE;
-	tag?free(tag):0;
-	if (!match)
-	{
-		return(FALSE);
-	}
-	if ((_DC_filtered_event= DC_waitWUEvent(wu, 0)) != NULL)
-		DC_log(LOG_DEBUG,
-		       "DC_waitWUEvent found an event for wu %p-\"%s\"",
-		       wu, wu->name);
-	found= _DC_filtered_event != NULL;
-	return(found);
-}
-
-
-DC_MasterEvent *DC_waitMasterEvent(const char *wuFilter, int timeout)
-{
-	/* no callback called! */
-	DC_Workunit *wu;
-	time_t start, now;
-
-	if (timeout)
-		DC_log(LOG_DEBUG, "DC_waitMasterEvent(%s, %d)",
-		       wuFilter, timeout);
-
-	start= time(NULL);
-	now= time(NULL);
-	do
-	{
-		_DC_filtered_event= NULL;
-		_DC_counter= 0;
-		wu= (DC_Workunit *)
-			g_hash_table_find(_DC_wu_table,
-					  _DC_check_filtered_wu_event,
-					  (gpointer)wuFilter);
-		if (_DC_filtered_event)
-			return(_DC_filtered_event);
-		if (timeout)
-			sleep(1);
-	}
-	while (timeout != 0 &&
-	       now-start <= timeout);
-	return(NULL);
-/*
-	DC_MasterEvent *event;
-
-//	event = look_for_results(wuFilter, NULL, timeout);
-
-	return event;
-*/
-}
-
-DC_MasterEvent *DC_waitWUEvent(DC_Workunit *wu, int timeout)
-{
-	/* no callback called! */
-	time_t start, now;
-	DC_MasterEvent *me= NULL;
-
-	/*if (!_DC_wu_check(wu))
-	  return(NULL);*/
-	if (timeout)
-		DC_log(LOG_DEBUG, "DC_waitWUEvent(%p-\"%s\", %d)",
-		       wu, wu->name, timeout);
-
-	start= time(NULL);
-	now= start;
-	do
-	{
-		if ((me= _DC_wu_check_client_messages(wu)) != NULL)
-			DC_log(LOG_DEBUG, "DC_waitWUEvent found a message for "
-			       "wu %p-\"%s\"", wu, wu->name);
-		if (!me)
-		{
-			if ((me= _DC_wu_infra2api_event(wu)) != NULL)
-				DC_log(LOG_DEBUG,
-				       "DC_waitWUEvent found an "
-				       "infrastructure event for wu %p-\"%s\"",
-				       wu, wu->name);
-		}
-		if (me)
-		{
-			return(me);
-		}
-		now= time(NULL);
-		if (timeout)
-			sleep(1);
-	}
-	while (timeout !=0 &&
-	       now-start <= timeout);
-	return(NULL);
-/*
-	DC_MasterEvent *event;
-
-	return event;
-*/
-}
-
-/* by VG */
-void DC_destroyMasterEvent(DC_MasterEvent *event)
-{
-	if (!event)
-		return;
-
-	switch (event->type)
-	{
-		case DC_MASTER_RESULT:
-			_DC_destroyResult(event->result);
-			break;
-		case DC_MASTER_SUBRESULT:
-			_DC_destroyPhysicalFile(event->subresult);
-			break;
-		case DC_MASTER_MESSAGE:
-			g_free(event->message);
-			break;
-		default:
-			DC_log(LOG_ERR, "Unknown event type %d", event->type);
-			break;
-	}
-}
-
-
-/* End of local/local_events.c */
-
-/* Local variables: */
-/* c-file-style: "linux" */
-/* End: */
diff --git a/dcapi/local/local_master.c b/dcapi/local/local_master.c
deleted file mode 100644
index bb3a234..0000000
--- a/dcapi/local/local_master.c
+++ /dev/null
@@ -1,845 +0,0 @@
-/*
- * local/local_master.C
- *
- * DC-API functions of master side
- *
- * (c) Gabor Vida 2005-2006, Daniel Drotos, 2007
- */
-
-/* $Id: local_master.c 2246 2009-09-08 15:28:03Z gombasg $ */
-/* $Date: 2009-09-08 17:28:03 +0200 (Tue, 08 Sep 2009) $ */
-/* $Revision: 2246 $ */
-
-#ifdef HAVE_CONFIG_H
-#include <config.h>
-#endif
-
-#include <unistd.h>
-#include <string.h>
-#include <stdlib.h>
-#include <stdio.h>
-#include <signal.h>
-#include <errno.h>
-#include <fcntl.h>
-#include <sys/stat.h>
-#include <sys/types.h>
-
-#include "local_common.h"
-#include "local_master.h"
-#include "local_utils.h"
-#include "local_wu.h"
-
-
-/********************************************************************
- * Global variables
- */
-
-DC_ResultCallback	_DC_result_callback;
-DC_SubresultCallback	_DC_subresult_callback;
-DC_MessageCallback	_DC_message_callback;
-
-char project_uuid_str[37];
-uuid_t project_uuid;
-int sleep_interval;
-
-GHashTable *_DC_wu_table;
-
-
-/********************************************************************
- * API functions
- */
-
-int DC_initMaster(const char *config_file)
-{
-	char *cfgval;
-	int ret;
-
-	_DC_init_common();
-
-	if (!config_file)
-		config_file = DC_CONFIG_FILE;
-
-	ret = _DC_parseCfg(config_file);
-	if (ret)
-	{
-		DC_log(LOG_ERR, "The DC-API cannot be initialized without a "
-			"config file");
-		return ret;
-	}
-
-	/* Check the working directory */
-	cfgval = DC_getCfgStr(CFG_WORKDIR);
-	if (!cfgval)
-	{
-		DC_log(LOG_ERR, "%s is not specified in the config file",
-			CFG_WORKDIR);
-		return DC_ERR_CONFIG;
-	}
-	free(cfgval);
-
-	/* Check sleep interval */
-	sleep_interval = DC_getCfgInt(CFG_SLEEPINTERVAL, DEFAULT_SLEEP_INTERVAL);
-	if (sleep_interval < 1)
-		sleep_interval = 1;
-
-	/* Check the project UUID */
-	cfgval = DC_getCfgStr(CFG_INSTANCEUUID);
-	if (!cfgval)
-	{
-		DC_log(LOG_ERR, "%s is not set in the config file",
-			CFG_INSTANCEUUID);
-		return DC_ERR_CONFIG;
-	}
-
-	ret = uuid_parse((char *)cfgval, project_uuid);
-	if (ret)
-	{
-		DC_log(LOG_ERR, "Invalid project UUID");
-		free(cfgval);
-		return DC_ERR_CONFIG;
-	}
-	free(cfgval);
-
-	/* Enforce a canonical string representation of the UUID */
-	uuid_unparse_lower(project_uuid, project_uuid_str);
-
-	return DC_OK;
-}
-
-int DC_getMaxMessageSize(void)
-{
-	return MAX_MESSAGE_SIZE;
-}
-
-int DC_getMaxSubresults(void)
-{
-	return MAX_SUBRESULTS;
-}
-
-unsigned DC_getGridCapabilities(void)
-{
-	return DC_GC_STDOUT | DC_GC_STDERR;
-}
-
-void DC_setMasterCb(DC_ResultCallback resultcb, DC_SubresultCallback subresultcb,
-	DC_MessageCallback msgcb)
-{
-	_DC_result_callback = resultcb;
-	_DC_subresult_callback = subresultcb;
-	_DC_message_callback = msgcb;
-}
-
-void DC_setResultCb(DC_ResultCallback cb)
-{
-	_DC_result_callback = cb;
-}
-
-void DC_setSubresultCb(DC_SubresultCallback cb)
-{
-	_DC_subresult_callback = cb;
-}
-
-void DC_setMessageCb(DC_MessageCallback cb)
-{
-	_DC_message_callback = cb;
-}
-
-
-/********************************************************************
- * Functions
- */
-
-static char *get_workdir(const uuid_t uuid, int create)
-{
-	char *tmp, uuid_str[37], *cfgval;
-	GString *str;
-	int ret;
-
-	uuid_unparse_lower(uuid, uuid_str);
-
-	cfgval = DC_getCfgStr(CFG_WORKDIR);
-	if (!cfgval)
-		return NULL;
-	str = g_string_new(cfgval);
-	free(cfgval);
-
-	if (create)
-	{
-		ret = mkdir(str->str, 0755);
-		if (ret && errno != EEXIST)
-			goto error;
-	}
-
-	g_string_append_c(str, G_DIR_SEPARATOR);
-	g_string_append(str, ".dcapi-");
-	g_string_append(str, project_uuid_str);
-	if (create)
-	{
-		ret = mkdir(str->str, 0755);
-		if (ret && errno != EEXIST)
-			goto error;
-	}
-
-	g_string_append_c(str, G_DIR_SEPARATOR);
-	g_string_append_printf(str, "%02x", uuid[0]);
-	if (create)
-	{
-		ret = mkdir(str->str, 0755);
-		if (ret && errno != EEXIST)
-			goto error;
-	}
-
-	g_string_append_c(str, G_DIR_SEPARATOR);
-	g_string_append(str, uuid_str);
-	if (create)
-	{
-		ret = mkdir(str->str, 0755);
-		if (ret && errno != EEXIST)
-			goto error;
-	}
-
-	tmp = str->str;
-	g_string_free(str, FALSE);
-	return tmp;
-
-error:
-	DC_log(LOG_ERR, "Failed to create WU working directory %s: %s",
-		str->str, strerror(errno));
-	g_string_free(str, TRUE);
-	return NULL;
-}
-
-
-DC_Workunit *DC_createWU(const char *clientName, const char *arguments[],
-	int subresults, const char *tag)
-{
-	char uuid_str[37];
-	DC_Workunit *wu;
-
-	if (subresults > MAX_SUBRESULTS){
-		DC_log(LOG_ERR, "DC_createWU: The given subresult number: %d is too high. (max:%d)",
-			subresults, MAX_SUBRESULTS);
-		return NULL;
-	}
-
-	if (!clientName)
-	{
-		DC_log(LOG_ERR, "DC_createWU: clientName is not supplied");
-		return NULL;
-	}
-
-	wu = g_new0(DC_Workunit, 1);
-
-	wu->argv = g_strdupv((char **)arguments);
-
-	for (wu->argc = 0; arguments && arguments[wu->argc]; wu->argc++)
-		/* Nothing */;
-
-	wu->subresults = subresults;
-	wu->tag = g_strdup(tag);
-
-	uuid_generate(wu->uuid);
-	uuid_unparse_lower(wu->uuid, uuid_str);
-	wu->uuid_str = g_strdup(uuid_str);
-
-	if (tag)
-		wu->name = g_strdup_printf("%s_%s_%s", project_uuid_str,
-			uuid_str, tag);
-	else
-		wu->name = g_strdup_printf("%s_%s", project_uuid_str, uuid_str);
-
-	/* Calculate & create the working directory. The working directory
-	 * has the form:
-	 * <project work dir>/.dcapi-<project uuid>/<hash>/<wu uuid>
-	 * Where <hash> is the first 2 hex digits of the uuid
-	 */
-	wu->workdir = get_workdir(wu->uuid, TRUE);
-	if (!wu->workdir)
-	{
-		DC_destroyWU(wu);
-		return NULL;
-	}
-
-	wu->client_name = /*DC_getClientCfgStr(clientName, "name", FALSE);*/
-		strdup(clientName);
-	/*wu->client_path = DC_getClientCfgStr(clientName, "path", FALSE);*/
-
-	if (!wu->client_name/* || !wu->client_path*/)
-	{
-		DC_log(LOG_ERR, "Failed to create WU. Cannot find client name\n"
-			"Define client application in the config file:\n"
-			"[Client-%s]\nname = <client name>\npath = <client path>", clientName);
-		DC_destroyWU(wu);
-		return NULL;
-	}
-
-	DC_log(LOG_DEBUG, "client path: %%s,     client name: %s    from client: %s",
-	       /*wu->client_path,*/ wu->client_name, clientName);
-
-	if (!_DC_wu_table)
-		_DC_wu_table = g_hash_table_new_full(g_str_hash, g_str_equal,
-			NULL, NULL);
-	g_hash_table_insert(_DC_wu_table, wu->name, wu);
-
-	return wu;
-}
-
-
-static char *get_workdir_path(DC_Workunit *wu, const char *label,
-	WorkdirFile type)
-{
-	return g_strdup_printf("%s%c%s", wu->workdir, G_DIR_SEPARATOR, label);
-}
-
-void DC_destroyWU(DC_Workunit *wu)
-{
-	char *path;
-	int leave= strtol(_DC_wu_cfg(wu, cfg_leave_files), 0, 0);
-	if (!wu)
-		return;
-
-	if (_DC_wu_table)
-		g_hash_table_remove(_DC_wu_table, wu->name);
-
-	switch (wu->state)
-	{
-		case DC_WU_RUNNING:
-			/* XXX Abort the work unit */
-			break;
-		default:
-			break;
-	}
-
-	while (wu->input_files &&
-	       !leave)
-	{
-		DC_PhysicalFile *file = (DC_PhysicalFile *)wu->input_files->data;
-
-		unlink(file->path);
-		wu->input_files = g_list_delete_link(wu->input_files,
-			wu->input_files);
-		_DC_destroyPhysicalFile(file);
-	}
-
-	while (wu->output_files &&
-	       !leave)
-	{
-		char *name = (char *)wu->output_files->data;
-		char *file = g_strdup_printf("%s%c%s", wu->workdir, G_DIR_SEPARATOR, name);
-		unlink(file);
-		g_free(file);
-
-		g_free(wu->output_files->data);
-		wu->output_files = g_list_delete_link(wu->output_files,
-			wu->output_files);
-	}
-
-	/* checkpoint file */
-	path = g_strdup_printf("%s%c%s", wu->workdir, G_DIR_SEPARATOR, CKPT_LABEL);
-	if (!leave)
-		unlink(path);
-	g_free(path);
-
-	/* standard output file */
-	path = g_strdup_printf("%s%c%s", wu->workdir, G_DIR_SEPARATOR, STDOUT_LABEL);
-	if (!leave)
-		unlink(path);
-	g_free(path);
-
-	/* standard error file */
-	path = g_strdup_printf("%s%c%s", wu->workdir, G_DIR_SEPARATOR, STDERR_LABEL);
-	if (!leave)
-		unlink(path);
-	g_free(path);
-
-	if (wu->client_name &&
-	    !leave)
-	{
-		char *path = g_strdup_printf("%s%c%s", wu->workdir, G_DIR_SEPARATOR, wu->client_name);
-		unlink(path);
-		g_free(path);
-		g_free(wu->client_name);
-		/*g_free(wu->client_path);*/
-	}
-
-	if (wu->workdir &&
-	    !leave)
-	{
-		const char *name;
-		GDir *dir;
-		int ret;
-
-		dir = g_dir_open(wu->workdir, 0, NULL);
-		/* The work directory should not contain any extra files, but
-		 * just in case */
-		while (dir && (name = g_dir_read_name(dir)))
-		{
-			GString *str = g_string_new(wu->workdir);
-			g_string_append_c(str, G_DIR_SEPARATOR);
-			g_string_append(str, name);
-			DC_log(LOG_INFO, "Removing unknown file %s",
-				str->str);
-			unlink(str->str);
-			g_string_free(str, TRUE);
-		}
-		if (dir)
-			g_dir_close(dir);
-
-		ret = rmdir(wu->workdir);
-		if (ret)
-			DC_log(LOG_WARNING, "Failed to remove WU working "
-				"directory %s: %s", wu->workdir,
-				strerror(errno));
-		g_free(wu->workdir);
-	}
-
-	g_free(wu->uuid_str);
-	g_strfreev(wu->argv);
-	g_free(wu->tag);
-	g_free(wu->name);
-
-	g_free(wu);
-}
-
-/* Check if the logical name is not already registered */
-static int check_logical_name(DC_Workunit *wu, const char *logicalFileName)
-{
-	GList *l;
-
-	if (strchr(logicalFileName, '/') || strchr(logicalFileName, '\\'))
-	{
-		DC_log(LOG_ERR, "Illegal characters in logical file name %s",
-			logicalFileName);
-		return DC_ERR_BADPARAM;
-	}
-	for (l = wu->input_files; l; l = l->next)
-	{
-		DC_PhysicalFile *file = (DC_PhysicalFile *)l->data;
-
-		if (!strcmp(file->label, logicalFileName))
-		{
-			DC_log(LOG_ERR, "File %s is already registered as an "
-				"input file", logicalFileName);
-			return DC_ERR_BADPARAM;
-		}
-	}
-	for (l = wu->output_files; l; l = l->next)
-	{
-		if (!strcmp((char *)l->data, logicalFileName))
-		{
-			DC_log(LOG_ERR, "File %s is already registered as an "
-				"output file", logicalFileName);
-			return DC_ERR_BADPARAM;
-		}
-	}
-	return 0;
-}
-
-#define COPY_BUFSIZE 65536
-static int copy_file(const char *src, const char *dst)
-{
-	int sfd, dfd;
-	ssize_t ret;
-	char *buf;
-
-	buf = (char *)g_malloc(COPY_BUFSIZE);
-	sfd = open(src, O_RDONLY);
-	if (sfd == -1)
-	{
-		DC_log(LOG_ERR, "Failed to open %s for copying: %s", src,
-			strerror(errno));
-		g_free(buf);
-		return -1;
-	}
-	dfd = open(dst, O_WRONLY | O_CREAT | O_TRUNC, 00664);
-	if (dfd == -1)
-	{
-		DC_log(LOG_ERR, "Failed to create %s: %s", dst, strerror(errno));
-		g_free(buf);
-		close(sfd);
-		return -1;
-	}
-
-	while ((ret = read(sfd, buf, COPY_BUFSIZE)) > 0)
-	{
-		char *ptr = buf;
-		while (ret)
-		{
-			ssize_t ret2 = write(dfd, ptr, ret);
-			if (ret2 < 0)
-			{
-				DC_log(LOG_ERR, "Error writing to %s: %s", dst,
-					strerror(errno));
-				close(sfd);
-				close(dfd);
-				unlink(dst);
-				g_free(buf);
-				return -1;
-			}
-			ret -= ret2;
-			ptr += ret2;
-		}
-	}
-
-	if (ret < 0)
-	{
-		DC_log(LOG_ERR, "Error reading from %s: %s", src, strerror(errno));
-		close(sfd);
-		close(dfd);
-		g_free(buf);
-		unlink(dst);
-		return -1;
-	}
-
-	g_free(buf);
-	close(sfd);
-	if (close(dfd))
-	{
-		DC_log(LOG_ERR, "Error writing to %s: %s", dst, strerror(errno));
-		unlink(dst);
-		return -1;
-	}
-	return 0;
-}
-
-int DC_addWUInput(DC_Workunit *wu, const char *logicalFileName, const char *URL,
-	DC_FileMode fileMode, ...)
-{
-	DC_PhysicalFile *file;
-	char *workpath;
-	int ret;
-
-	/* Sanity checks */
-	ret = check_logical_name(wu, logicalFileName);
-	if (ret)
-		return ret;
-
-	if (fileMode & DC_FILE_PERSISTENT_CLIENT)
-    {
-		DC_log(LOG_WARNING, "File mode DC_FILE_PERSISTENT_CLIENT for input file %s is not supported",
-			logicalFileName);
-        fileMode ^= DC_FILE_PERSISTENT_CLIENT;
-    }
-
-	/* Remote files aren't supported */
-	if (DC_FILE_REMOTE == fileMode)
-	{
-		DC_log(LOG_ERR, "Unsupported file mode for input file %s",
-			logicalFileName);
-		return DC_ERR_BADPARAM;
-	}
-
-	workpath = get_workdir_path(wu, logicalFileName, FILE_IN);
-	file = _DC_createPhysicalFile(logicalFileName, workpath);
-	g_free(workpath);
-	if (!file)
-		return DC_ERR_INTERNAL;
-
-	switch (fileMode)
-	{
-		case DC_FILE_REGULAR:
-			ret = copy_file(URL, file->path);
-			if (ret)
-			{
-				_DC_destroyPhysicalFile(file);
-				return DC_ERR_BADPARAM; /* XXX */
-			}
-			break;
-		case DC_FILE_PERSISTENT:
-			ret = link(URL, file->path);
-			if (ret)
-			{
-				DC_log(LOG_ERR, "Failed to link %s to %s: %s",
-					URL, file->path, strerror(errno));
-				_DC_destroyPhysicalFile(file);
-				return DC_ERR_BADPARAM; /* XXX */
-			}
-			/* Remember the file mode */
-			file->mode = DC_FILE_PERSISTENT;
-			break;
-		case DC_FILE_VOLATILE:
-			ret = rename(URL, file->path);
-			if (ret)
-			{
-				DC_log(LOG_ERR, "Failed to rename %s to %s: %s",
-					URL, file->path, strerror(errno));
-				_DC_destroyPhysicalFile(file);
-				return DC_ERR_BADPARAM; /* XXX */
-			}
-		default:
-    		DC_log(LOG_ERR, "Unsupported file mode for input file %s",
-    			logicalFileName);
-		    _DC_destroyPhysicalFile(file);
-    		return DC_ERR_BADPARAM;
-	}
-
-	wu->input_files = g_list_append(wu->input_files, file);
-	wu->num_inputs++;
-	return 0;
-}
-
-int DC_addWUOutput(DC_Workunit *wu, const char *logicalFileName)
-{
-	int ret;
-
-	/* Sanity checks */
-	ret = check_logical_name(wu, logicalFileName);
-	if (ret)
-		return ret;
-
-	wu->output_files = g_list_append(wu->output_files,
-		g_strdup(logicalFileName));
-	wu->num_outputs++;
-	return 0;
-}
-
-int DC_submitWU(DC_Workunit *wu)
-{
-	pid_t pid;
-	char *old_path, *new_path;
-
-	if (wu->state != DC_WU_READY)
-	{
-		DC_log(LOG_ERR, "Only WUs in READY state can be submitted");
-		return DC_ERR_BADPARAM;
-	}
-
-	/* copy the exec into the workdir */
-	old_path = g_strdup_printf(/*"%s%c%s", wu->client_path, G_DIR_SEPARATOR, wu->client_name*/
-		"%s", _DC_wu_cfg(wu, cfg_executable));
-	new_path = g_strdup_printf("%s%c%s", wu->workdir, G_DIR_SEPARATOR, wu->client_name);
-	if (link(old_path, new_path))
-	{
-		DC_log(LOG_ERR, "Failed to link %s to %s: %s",
-			old_path, new_path, strerror(errno));
-		return DC_ERR_BADPARAM;
-	}
-	g_free(old_path);
-	g_free(new_path);
-
-	if((pid=fork())<0) {
-		DC_log(LOG_ERR,"Cannot fork!\nerrno=%d  %s\n",
-			errno, strerror(errno));
-		return DC_ERR_BADPARAM;
-	}
-
-	if(pid==0) /* client process */
-	{
-		/* change into working directory of the WU */
-		if (chdir(wu->workdir))
-		{
-			DC_log(LOG_ERR,"Cannot cd into %s\nerrno=%d  %s\n",
-			wu->workdir, errno, strerror(errno));
-			return DC_ERR_BADPARAM;
-		}
-
-		/* hook up stdout and stderr to specially-named files */
-		freopen(STDOUT_LABEL, "a", stdout);
-		freopen(STDERR_LABEL, "a", stderr);
-
-		/* execute the client */
-		DC_log(LOG_INFO, "Work unit : %s executes: %s", wu->name, wu->client_name);
-		execv(wu->client_name, wu->argv);
-		DC_log(LOG_ERR, "Cannot execute. Errno=%d  %s\n",
-			errno, strerror(errno));
-		exit(1);
-	}
-
-	wu->pid = pid;
-	wu->state = DC_WU_RUNNING;
-
-	return DC_OK;
-}
-
-int DC_cancelWU(DC_Workunit *wu)
-{
-	if (!wu || wu->state != DC_WU_RUNNING)
-		return DC_ERR_BADPARAM;
-
-	kill(wu->pid, SIGTERM);
-	wu->state = DC_WU_ABORTED;
-	return 0;
-}
-
-DC_Workunit *_DC_getWUByName(const char *name)
-{
-	DC_Workunit *wu;
-	char *uuid_str;
-	uuid_t uuid;
-	int ret;
-
-	if (_DC_wu_table)
-	{
-		wu = (DC_Workunit *)g_hash_table_lookup(_DC_wu_table, name);
-		if (wu)
-			return wu;
-	}
-
-	/* Check if the WU belongs to this application */
-	uuid_str = g_strndup(name, 36);
-	ret = uuid_parse(uuid_str, uuid);
-	g_free(uuid_str);
-	if (ret)
-	{
-		DC_log(LOG_ERR, "WU name contains illegal UUID");
-		return NULL;
-	}
-
-	if (uuid_compare(uuid, project_uuid))
-	{
-		DC_log(LOG_WARNING, "WU does not belong to this application");
-		return NULL;
-	}
-
-	if (name[36] != '_')
-	{
-		DC_log(LOG_ERR, "Illegal WU name syntax");
-		return NULL;
-	}
-
-	/* Check the WU's UUID */
-	uuid_str = g_strndup(name + 37, 36);
-	ret = uuid_parse(uuid_str, uuid);
-	g_free(uuid_str);
-	if (ret)
-	{
-		DC_log(LOG_ERR, "WU name contains illegal UUID");
-		return NULL;
-	}
-
-	DC_log(LOG_ERR, "WU %s not found!", name);
-	return NULL;
-}
-
-static DC_WUState matchState;
-static void countState(void *key, void *value, void *ptr)
-{
-	DC_Workunit *wu = (DC_Workunit *)value;
-	int *count = (int *)ptr;
-
-	if (wu->state == matchState) ++(*count);
-}
-
-int DC_getWUNumber(DC_WUState state)
-{
-	int val = 0;
-
-	matchState = state;
-	g_hash_table_foreach(_DC_wu_table, (GHFunc)countState, &val);
-
-	return val;
-}
-
-char *DC_getWUId(const DC_Workunit *wu)
-{
-	char *id, *ret;
-
-	id = g_strdup_printf("%d", wu->pid);
-	ret = strdup(id);
-
-	g_free(id);
-	return ret;
-}
-
-char *DC_getWUTag(const DC_Workunit *wu)
-{
-	char *tag= NULL;
-
-	if (wu->tag)
-		tag = strdup(wu->tag);
-
-	return tag;
-}
-
-int DC_setWUPriority(DC_Workunit *wu, int priority)
-{
-	return 0;
-}
-
-/* Queries the state of a work unit. */
-DC_WUState
-DC_getWUState(DC_Workunit *wu)
-{
-	return(/*DC_ERR_NOTIMPL*/wu->state);
-}
-
-/* Temporarily suspends the execution of a work unit. */
-int
-DC_suspendWU(DC_Workunit *wu)
-{
-	return(DC_ERR_NOTIMPL);
-}
-
-/* Resumes computation of a previously suspended work unit. */
-int
-DC_resumeWU(DC_Workunit *wu)
-{
-	return(DC_ERR_NOTIMPL);
-}
-
-/* Serializes a work unit description. */
-char *
-DC_serializeWU(DC_Workunit *wu)
-{
-	return(NULL/*DC_ERR_NOTIMPL*/);
-}
-
-/* Restores a serialized work unit. */
-DC_Workunit *
-DC_deserializeWU(const char *buf)
-{
-	return(NULL/*DC_ERR_NOTIMPL*/);
-}
-
-
-/**************************************************************** Messaging */
-
-/* Sends a message to a running work unit. */
-int
-DC_sendWUMessage(DC_Workunit *wu, const char *message)
-{
-	GString *dn;
-	int ret;
-
-	/*if (!_DC_wu_check(wu))
-	  return(DC_ERR_UNKNOWN_WU);*/
-	DC_log(LOG_DEBUG, "DC_sendWUMessage(%p-\"%s\", %s)",
-	       wu, wu->name, message);
-	dn= g_string_new(wu->workdir);
-	g_string_append(dn, "/");
-	g_string_append(dn, _DC_wu_cfg(wu, cfg_master_message_box));
-	ret= _DC_create_message(dn->str, (char*)_DCAPI_MSG_MESSAGE, message, NULL);
-	g_string_free(dn, TRUE);
-	return(ret);
-}
-
-
-static struct {
-	DC_WUState state;
-	char *name;
-}
-_DC_state_names[]= {
-	{ DC_WU_READY, (char*) "READY" },
-	{ DC_WU_RUNNING, (char*) "RUNNING" },
-	{ DC_WU_FINISHED, (char*) "FINISHED" },
-	{ DC_WU_SUSPENDED, (char*) "SUSPENDED" },
-	{ DC_WU_ABORTED, (char*) "ABORTED" },
-	{ DC_WU_UNKNOWN, (char*) "UNKNOWN" }
-};
-
-char *
-_DC_state_name(DC_WUState state)
-{
-	int i;
-	for (i= 0; _DC_state_names[i].name; i++)
-		if (_DC_state_names[i].state == state)
-			return _DC_state_names[i].name;
-	return _DC_state_names[DC_WU_UNKNOWN].name;
-}
-
-
-/* End of local/local_master.c */
-
-/* Local variables: */
-/* c-file-style: "linux" */
-/* End: */
diff --git a/dcapi/local/local_master.h b/dcapi/local/local_master.h
deleted file mode 100644
index 1424005..0000000
--- a/dcapi/local/local_master.h
+++ /dev/null
@@ -1,147 +0,0 @@
-/*
- * local/local_master.h
- *
- * DC-API definitions of master side
- *
- * (c) Gabor Vida 2005-2006, Daniel Drotos, 2007
- */
-
-/* $Id$ */
-/* $Date$ */
-/* $Revision$ */
-
-#ifndef __DC_API_LOCAL_MASTER_H
-#define __DC_API_LOCAL_MASTER_H
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-#include <sys/types.h>
-
-#include <dc.h>
-#include <dc_internal.h>
-#include <uuid/uuid.h>
-#include <glib.h>
-
-#include "local_common.h"
-
-/********************************************************************
- * Constants
- */
-
-/* DCAPI configuration keys */
-#define CFG_SLEEPINTERVAL	"SleepingInterval"
-
-#define DEFAULT_SLEEP_INTERVAL	5
-
-/* File types in the working directory */
-typedef enum
-{
-	FILE_IN,
-	FILE_OUT,
-	FILE_CKPT,
-	FILE_DCAPI
-} WorkdirFile;
-
-
-/********************************************************************
- * Data types
- */
-
-struct _DC_Workunit
-{
-	/* Arguments passed to DC_createWU() */
-	char			*client_name;
-	/*char			*client_path;*/
-	char			**argv;
-	int			argc;
-	char			*tag;
-	int			subresults;
-
-	/* State of the WU */
-	char			*name;
-	uuid_t			uuid;
-	char			*uuid_str;
-	DC_WUState		state;
-	char			*workdir;
-	pid_t			pid;
-
-	/* Input file definitions. Elements are of type DC_PhysicalFile */
-	GList			*input_files;
-	int			num_inputs;
-
-	/* Output file definitions. Elements are of type char * */
-	GList			*output_files;
-	int			num_outputs;
-
-	/* by DD */
-	int			asked_to_suspend;
-};
-
-struct _DC_Result
-{
-	DC_Workunit		*wu;
-
-	int			exit_code;
-	double			cpu_time;
-
-	/* List of output files. Elements are of type DC_PhysicalFile */
-	GList			*output_files;
-	int			num_outputs;
-};
-
-
-/********************************************************************
- * Global variables
- */
-
-extern DC_ResultCallback _DC_result_callback G_GNUC_INTERNAL;
-extern DC_SubresultCallback _DC_subresult_callback G_GNUC_INTERNAL;
-extern DC_MessageCallback _DC_message_callback G_GNUC_INTERNAL;
-
-extern GHashTable *_DC_wu_table G_GNUC_INTERNAL;
-
-extern char project_uuid_str[37] G_GNUC_INTERNAL; 
-extern uuid_t project_uuid G_GNUC_INTERNAL;
-extern int sleep_interval G_GNUC_INTERNAL;
-
-/********************************************************************
- * Function prototypes
- */
-
-/* Allocates a physical file descriptor */
-DC_PhysicalFile *_DC_createPhysicalFile(const char *label,
-        const char *path) G_GNUC_INTERNAL;
-
-/* De-allocates a physical file descriptor */
-void _DC_destroyPhysicalFile(DC_PhysicalFile *file) G_GNUC_INTERNAL;
-
-/* Calls a g_hash_table_foreach function for the wu_table */
-int _DC_searchForEvents(void) G_GNUC_INTERNAL;
-
-/* Creates a new DC_Result */
-DC_Result *_DC_createResult(const char *wu_name) G_GNUC_INTERNAL;
-
-/* Destroys a DC_Result */
-void _DC_destroyResult(DC_Result *result) G_GNUC_INTERNAL;
-
-/* Looks up a WU by name */
-DC_Workunit *_DC_getWUByName(const char *name) G_GNUC_INTERNAL;
-
-char *_DC_state_name(DC_WUState state) G_GNUC_INTERNAL;
-
-char *_DC_wu_cfg(DC_Workunit *wu, enum _DC_e_param what) G_GNUC_INTERNAL;
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif /* __DC_API_LOCAL_MASTER_H */
-
-
-/* End of local/local_master.h */
-
-/* Local variables: */
-/* c-file-style: "linux" */
-/* End: */
diff --git a/dcapi/local/local_result.c b/dcapi/local/local_result.c
deleted file mode 100644
index 935fdc6..0000000
--- a/dcapi/local/local_result.c
+++ /dev/null
@@ -1,217 +0,0 @@
-/*
- * local/local_result.c
- *
- * DC-API functions related to result handling
- *
- * (c) Gabor Vida 2005-2006, Daniel Drotos, 2007
- */
-
-/* $Id$ */
-/* $Date$ */
-/* $Revision$ */
-
-#ifdef HAVE_CONFIG_H
-#include <config.h>
-#endif
-
-#include <stdio.h>
-#include <stdlib.h>
-#include <string.h>
-#include <sys/types.h>
-#include <sys/wait.h>
-
-#include <glib.h>
-#include "local_master.h"
-#include "local_result.h"
-
-
-DC_Result *
-_DC_result_create(DC_Workunit *wu)
-{
-	DC_Result *r;
-	
-	r= g_new0(DC_Result, 1);
-	r->wu= wu;
-	return(r);
-}
-
-
-void
-_DC_result_destroy(DC_Result *result)
-{
-	if (!result)
-		return;
-	g_free(result);
-}
-
-
-/********************************************************************
- * Functions
- */
-
-DC_Result *_DC_createResult(const char *wu_name)
-{
-	char *logicalName;
-	GList *l;
-	DC_Result *result;
-	DC_PhysicalFile *file;
-	FILE *f;
-
-	result = g_new0(DC_Result, 1);
-	result->wu = _DC_getWUByName(wu_name);
-	if (!result->wu)
-	{
-		DC_log(LOG_ERR, "Received result for unknown WU %s", wu_name);
-		g_free(result);
-		return NULL;
-	}
-
-	for (l = result->wu->output_files; l; l = l->next)
-	{
-		logicalName = g_strdup_printf("%s/%s", result->wu->workdir, (char *)l->data);
-		f = fopen(logicalName, "r");
-		if (f != NULL) /* File exists */
-		{
-			file = _DC_createPhysicalFile((char *)l->data, logicalName);
-			result->output_files = g_list_append(result->output_files, file);
-			result->num_outputs++;
-			fclose(f);
-		}
-		g_free(logicalName);
-	}
-
-	return result;
-}
-
-void _DC_destroyResult(DC_Result *result)
-{
-	while (result->output_files)
-	{
-		_DC_destroyPhysicalFile((DC_PhysicalFile *)result->output_files->data);
-		result->output_files = g_list_delete_link(result->output_files,
-			result->output_files);
-	}
-	g_free(result);
-}
-
-unsigned DC_getResultCapabilities(const DC_Result *result)
-{
-	return (DC_GC_STDOUT | DC_GC_STDERR | DC_GC_EXITCODE);
-}
-
-DC_Workunit *DC_getResultWU(DC_Result *result)
-{
-	return result->wu;
-}
-
-static int wait_result(DC_Result *result)
-{
-	struct rusage rusage;
-	pid_t pid;
-
-	if (!result->wu->pid)
-		return 0;
-
-	pid = wait4(result->wu->pid, &result->exit_code, WNOHANG, &rusage);
-	if (pid != result->wu->pid)
-	{
-		DC_log(LOG_ERR, "wu with pid %d not exited according to waitpid. retval: %d",
-			 result->wu->pid, pid);
-		return DC_ERR_SYSTEM;
-	}
-
-	result->cpu_time = rusage.ru_utime.tv_sec +
-		(double)rusage.ru_utime.tv_usec / 1000000 +
-		rusage.ru_stime.tv_sec +
-		(double)rusage.ru_stime.tv_usec / 1000000;
-
-	/* Make sure we do not call wait4() again */
-	result->wu->pid = 0;
-
-	return 0;
-}
-
-int DC_getResultExit(const DC_Result *result)
-{
-	int ret;
-
-	if (!result)
-	{
-		DC_log(LOG_ERR, "%s: Missing result", __func__);
-		return 0.0;
-	}
-
-	ret = wait_result((DC_Result *)result); /* XXX */
-	if (ret)
-		return -1;
-
-	if (!WIFEXITED(result->exit_code))
-	{
-		DC_log(LOG_WARNING, "DC_getResultExit: wu with pid %d terminated not normally.",
-			result->wu->pid); /* XXX pid is 0 at this point */
-		return -1;
-	}
-
-	return WEXITSTATUS(result->exit_code);
-}
-
-double DC_getResultCPUTime(const DC_Result *result)
-{
-	int ret;
-
-	if (!result)
-	{
-		DC_log(LOG_ERR, "%s: Missing result", __func__);
-		return 0.0;
-	}
-
-	ret = wait_result((DC_Result *)result); /* XXX */
-	if (ret)
-		return -1;
-
-	return result->cpu_time;
-}
-
-char *DC_getResultOutput(const DC_Result *result, const char *logicalFileName)
-{
-	char *physicalFileName;
-	GList *l;
-
-	for (l = result->output_files; l; l = l->next)
-	{
-		DC_PhysicalFile *file = (DC_PhysicalFile *)l->data;
-
-		if(!strcmp(file->label, logicalFileName))
-		{
-			physicalFileName = strdup(file->path);
-			return physicalFileName;
-		}
-	}	
-
-	if (!strcmp(logicalFileName, DC_LABEL_STDOUT))
-	{
-		char *tmp = g_strdup_printf("%s%c%s", result->wu->workdir, G_DIR_SEPARATOR, STDOUT_LABEL);
-		physicalFileName = strdup(tmp);
-		g_free(tmp);
-		return physicalFileName;
-	}
-
-	if (!strcmp(logicalFileName, DC_LABEL_STDERR))
-	{
-		char *tmp = g_strdup_printf("%s%c%s", result->wu->workdir, G_DIR_SEPARATOR, STDERR_LABEL);
-		physicalFileName = strdup(tmp);
-		g_free(tmp);
-		return physicalFileName;
-	}
-
-	DC_log(LOG_ERR, "DC_getResultOutput: The %s file is not part of the given result", logicalFileName);
-
-	return NULL;
-}
-
-
-/* End of local/local_result.c */
-
-/* Local variables: */
-/* c-file-style: "linux" */
-/* End: */
diff --git a/dcapi/local/local_result.h b/dcapi/local/local_result.h
deleted file mode 100644
index ada2931..0000000
--- a/dcapi/local/local_result.h
+++ /dev/null
@@ -1,33 +0,0 @@
-/*
- * local/local_result.h
- *
- * DC-API functions to handle DC_Result data type
- *
- * (c) Daniel Drotos, 2006
- */
-
-#ifndef _DC_API_LOCAL_RESULT_H_
-#define _DC_API_LOCAL_RESULT_H_
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-#include "local_master.h"
-
-
-DC_Result *_DC_result_create(DC_Workunit *wu) G_GNUC_INTERNAL;
-void _DC_result_destroy(DC_Result *result) G_GNUC_INTERNAL;
-
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif
-
-/* End of local/local_result.h */
-
-/* Local variables: */
-/* c-file-style: "linux" */
-/* End: */
diff --git a/dcapi/local/local_utils.c b/dcapi/local/local_utils.c
deleted file mode 100644
index 50f24c7..0000000
--- a/dcapi/local/local_utils.c
+++ /dev/null
@@ -1,479 +0,0 @@
-/*
- * local/local_utils.c
- *
- * DC-API usefull functions
- *
- * (c) Daniel Drotos, 2006-2007
- */
-
-/* $Id$ */
-/* $Date$ */
-/* $Revision$ */
-
-#include <stdio.h>
-#include <sys/stat.h>
-#include <dirent.h>
-#include <string.h>
-#include <errno.h>
-#include <unistd.h>
-#include <stdlib.h>
-#include <ctype.h>
-
-#include <dc_internal.h>
-#include <dc_common.h>
-
-#include "local_common.h"
-#include "local_utils.h"
-
-
-void
-_DC_init_utils(void)
-{
-}
-
-
-int
-_DC_mkdir_with_parents(char *dn, mode_t mode)
-{
-	char *p= dn;
-	int res;
-
-	/*fprintf(stderr, "making %s (EEXIST=%d)\n", dn, EEXIST);*/
-	if (!dn ||
-	    !*dn)
-		return(0);
-	while (*p)
-	{
-		while (*p != '/' &&
-		       *p != '\0')
-			p++;
-		if (*p == '/')
-		{
-			*p= '\0';
-			if (*dn)
-			{
-				/*fprintf(stderr, "mkdir(%s,%d)=",dn,mode);*/
-				res= mkdir(dn, mode);
-				/*fprintf(stderr, "%d %d\n", res, errno);*/
-			}
-			*p= '/';
-			p++;
-		}
-	}
-	/*fprintf(stderr, "mkdir(%s,%d)=",dn,mode);*/
-	res= mkdir(dn, mode);
-	/*fprintf(stderr, "%d %d\n", res, errno);*/
-	if (res != 0 &&
-	    errno == EEXIST)
-		return(DC_OK);
-	return(res?DC_ERR_SYSTEM:DC_OK);
-}
-
-
-static int
-_DC_rmsubdir(char *name)
-{
-	DIR *d;
-	struct dirent *de;
-	int i= 0;
-
-	if ((d= opendir(name)) == NULL)
-	{
-		DC_log(LOG_DEBUG, "Open %s: %s", name, strerror(errno));
-		return(0);
-	}
-	while ((de= readdir(d)))
-	{
-		if (strcmp(de->d_name, ".") != 0 &&
-		    strcmp(de->d_name, "..") != 0)
-		{
-			char *s= malloc(strlen(name)+strlen(de->d_name) + 10);
-			strcpy(s, name);
-			strcat(s, "/");
-			strcat(s, de->d_name);
-			i+= _DC_rm(s);
-			free(s);
-		}
-	}
-	closedir(d);
-	if (rmdir(name))
-	{
-		DC_log(LOG_ERR, "Failed to rmdir %s: %s",
-		       name, strerror(errno));
-	}
-	return(i);
-}
-
-int
-_DC_rm(char *name)
-{
-	struct stat s;
-	int i;
-
-	if (!name ||
-	    !*name)
-		return(0);
-	i= lstat(name, &s);
-	if (i != 0)
-	{
-		return(0);
-	}
-	if (S_ISDIR(s.st_mode) &&
-	    strcmp(name, ".") != 0 &&
-	    strcmp(name, "..") != 0)
-	{
-		return(_DC_rmsubdir(name));
-	}
-	else
-		{
-			if (remove(name))
-				DC_log(LOG_ERR, "Failed to remove %s: %s",
-				       name, strerror(errno));
-		}
-	return(1);
-}
-
-
-int
-_DC_file_exists(char *fn)
-{
-	return(access(fn, F_OK) == 0);
-}
-
-
-int
-_DC_file_empty(char *fn)
-{
-	struct stat s;
-	
-	if (stat(fn, &s))
-		return(1);
-	return(s.st_size == 0);
-}
-
-
-int
-_DC_create_file(char *fn, char *what)
-{
-	FILE *f= fopen(fn, "w");
-	if (f)
-	{
-		if (what)
-			fprintf(f, "%s", what);
-		fclose(f);
-		return(DC_OK);
-	}
-	else
-		return(DC_ERR_SYSTEM);
-}
-
-
-char *
-_DC_get_file(char *fn)
-{
-	FILE *f;
-	char *buf= NULL;
-
-	if ((f= fopen(fn, "r")) != NULL)
-	{
-		int bs= 100, i;
-		int c;
-
-		buf= malloc(bs);
-		i= 0;
-		buf[i]= '\0';
-		while ((c= fgetc(f)) != EOF)
-		{
-			if (i > bs-2)
-			{
-				bs+= 100;
-				buf= realloc(buf, bs);
-			}
-			buf[i]= (char)c;
-			i++;
-		}
-		buf[i]= '\0';
-		fclose(f);
-	}
-	return(buf);
-}
-
-
-static int _DC_message_id= 0;
-
-int
-_DC_create_message(char *box,
-		   char *name,
-		   const char *message,
-		   char *msgfile)
-{
-	char *fn, *fn2;
-	FILE *f;
-	int ret= DC_OK;
-
-	/*DC_log(LOG_DEBUG, "DC_sendMessage(%s)", message);*/
-	if (!box ||
-	    !name)
-		return(DC_ERR_BADPARAM);
-	mkdir(box, S_IRWXU|S_IRGRP|S_IXGRP|S_IROTH|S_IXOTH);
-	_DC_message_id++;
-	fn= malloc(strlen(box)+strlen(name)+100);
-	sprintf(fn, "%s/%s_creating.%d", box, name, _DC_message_id);
-	if ((f= fopen(fn, "w")) != NULL)
-	{
-		if (message)
-			fprintf(f, "%s", message);
-		else if (msgfile)
-		{
-			if (_DC_copyFile(msgfile, fn))
-				DC_log(LOG_ERR, "copyFile(%s,%s) error",
-				       msgfile, fn);
-		}
-		else
-		{
-			DC_log(LOG_WARNING, "No message specified for "
-			       "creation");
-		}
-		if (fsync(fileno(f)) != 0)
-			DC_log(LOG_ERR, "Sync of %s: %d %s", fn,
-			       errno, strerror(errno));
-		fclose(f);
-		/*DC_log(LOG_DEBUG, "Message %d created", _DC_message_id);*/
-	}
-	else
-	{
-		DC_log(LOG_ERR, "Error creating message file (%s)",
-		       fn);
-		ret= DC_ERR_SYSTEM;
-	}
-	fn2= malloc(strlen(box)+strlen(name)+100);
-	sprintf(fn2, "%s/%s.%d", box, name, _DC_message_id);
-	rename(fn, fn2);
-	DC_log(LOG_DEBUG, "Message created: %s", fn2);
-	free(fn2);
-	free(fn);
-	return(ret);
-}
-
-
-int
-_DC_nuof_messages(char *box, char *name)
-{
-	DIR *d;
-	struct dirent *de;
-	int nuof= 0;
-	char *s;
-
-	if (!box)
-		return(0);
-	if ((d= opendir(box)) == NULL)
-		return(0);
-	s= malloc(100 + (name?strlen(name):strlen(_DCAPI_MSG_MESSAGE)));
-	strcpy(s, name?name:_DCAPI_MSG_MESSAGE);
-	strcat(s, ".");
-	while ((de= readdir(d)) != NULL)
-	{
-		char *found= strstr(de->d_name, s);
-		if (found == de->d_name)
-			nuof++;
-	}
-	if (d)
-		closedir(d);
-	free(s);
-	return(nuof);
-}
-
-
-char *
-_DC_message_name(char *box, char *name)
-{
-	char *dn, *n;
-	DIR *d;
-	struct dirent *de;
-	int min_id;
-
-	if (!box ||
-	    !name)
-		return(NULL);
-	if (!*box ||
-	    !*name)
-		return(NULL);
-	/*DC_log(LOG_DEBUG, "_DC_message_name(%s,%s)", box, name);*/
-	dn= strdup(box);
-	n= malloc(strlen(name)+10);
-	strcpy(n, name);
-	strcat(n, ".");
-	/*DC_log(LOG_DEBUG, "opendir(%s)=", dn);*/
-	d= opendir(dn);
-	/*DC_log(LOG_DEBUG, "%p", d);*/
-	min_id= -1;
-	while (d &&
-	       (de= readdir(d)) != NULL)
-	{
-		char *found= strstr(de->d_name, n);
-		/*DC_log(LOG_DEBUG, "%s <-> %s", de->d_name, n);*/
-		if (found == de->d_name)
-		{
-			char *pos= strrchr(de->d_name, '.');
-			/*DC_log(LOG_DEBUG, "found");*/
-			if (pos)
-			{
-				int id= 0;
-				pos++;
-				id= strtol(pos, NULL, 10);
-				/*DC_log(LOG_DEBUG, "id=%d", id);*/
-				if (id > 0)
-				{
-					if (min_id < 0)
-						min_id= id;
-					else
-						if (id < min_id)
-							min_id= id;
-				}
-			}
-		}
-		/*else
-		  DC_log(LOG_DEBUG, "not found");*/
-	}
-	if (d)
-		closedir(d);
-	if (min_id >= 0)
-	{
-		dn= realloc(dn, strlen(box)+strlen(name)+100);
-		sprintf(dn, "%s/%s.%d", box, name, min_id);
-		free(n);
-		/*DC_log(LOG_DEBUG, "return: %s", dn);*/
-		return(dn);
-	}
-	if (dn)
-		free(dn);
-	if (n)
-		free(n);
-	/*DC_log(LOG_DEBUG, "return null");*/
-	return(NULL);
-}
-
-
-char *
-_DC_read_message(char *box, char *name, int del_msg)
-{
-	FILE *f;
-	char *fn= _DC_message_name(box, name);
-	char *buf= NULL;
-
-	if (fn==NULL)
-		return(NULL);
-	/*DC_log(LOG_DEBUG, "Reading message from %s", fn);*/
-	if ((f= fopen(fn, "r")) != NULL)
-	{
-		int bs= 100, i;
-		int c;
-
-		buf= malloc(bs);
-		i= 0;
-		buf[i]= '\0';
-		while ((c= fgetc(f)) != EOF)
-		{
-			if (i > bs-2)
-			{
-				bs+= 100;
-				buf= realloc(buf, bs);
-			}
-			buf[i]= (char)c;
-			i++;
-		}
-		buf[i]= '\0';
-		fclose(f);
-		if (del_msg)
-			unlink(fn);
-	}
-	if (fn!=NULL)
-		free(fn);
-	return(buf);
-}
-
-
-
-char *
-_DC_quote_string(char *str)
-{
-	int i, n;
-	char *s, *p;
-
-	if (!str)
-	{
-		s= strdup("\\nnn");
-		return(s);
-	}
-	if (!*str)
-	{
-		s= strdup("\\000");
-		return(s);
-	}
-
-	for (i= n= 0; str[i]; i++)
-	{
-		if (!isalnum(str[i]))
-			n++;
-	}
-
-	s= calloc(strlen(str)+10*n+10, 1);
-	for (i= 0, p= s; str[i]; i++)
-	{
-		if (isalnum(str[i]))
-		{
-			*p= str[i];
-			p++;
-		}
-		else
-		{
-			sprintf(p, "\\%03o", str[i]);
-			p+= strlen(p);
-		}
-	}
-	return(s);
-}
-
-
-char *
-_DC_unquote_string(char *str)
-{
-	char *s, *p, *i;
-
-	if (!str)
-		return(NULL);
-	s= calloc(strlen(str)+1, 1);
-	p= str;
-	i= s;
-	while (*p != '\0')
-	{
-		if (*p != '\\')
-			*i= *p;
-		else
-		{
-			char c, *x= p+4;
-			int l;
-			c= *x;
-			*x= '\0';
-			if (strcmp(p+1, "nnn") == 0)
-			{
-				free(s);
-				return(NULL);
-			}
-			l= strtol(p+1, 0, 8);
-			*i= (char)l;
-			*x= c;
-			p= x-1;
-		}
-		p++;
-		i++;
-	}
-	return(s);
-}
-
-
-/* End of local/local_utils.c */
-
-/* Local variables: */
-/* c-file-style: "linux" */
-/* End: */
diff --git a/dcapi/local/local_utils.h b/dcapi/local/local_utils.h
deleted file mode 100644
index 96f7690..0000000
--- a/dcapi/local/local_utils.h
+++ /dev/null
@@ -1,52 +0,0 @@
-/*
- * local/local_utils.h
- *
- * DC-API usefull functions
- *
- * (c) Daniel Drotos, 2006-2007
- */
-
-/* $Id$ */
-/* $Date$ */
-/* $Revision$ */
-
-#ifndef __DC_API_LOCAL_UTILS_H_
-#define __DC_API_LOCAL_UTILS_H_
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-#include <fcntl.h>
-
-#include "local_common.h"
-
-
-void _DC_init_utils(void) G_GNUC_INTERNAL;
-
-/* Usefull funcs */
-int _DC_mkdir_with_parents(char *dn, mode_t mode) G_GNUC_INTERNAL;
-int _DC_rm(char *name) G_GNUC_INTERNAL;
-int _DC_file_exists(char *fn) G_GNUC_INTERNAL;
-int _DC_file_empty(char *fn) G_GNUC_INTERNAL;
-int _DC_create_file(char *fn, char *what) G_GNUC_INTERNAL;
-char *_DC_get_file(char *fn) G_GNUC_INTERNAL;
-
-/* Message passing utilities */
-int _DC_create_message(char *box,
-			      char *name,
-			      const char *message,
-			      char *msgfile) G_GNUC_INTERNAL;
-int _DC_nuof_messages(char *box, char *name) G_GNUC_INTERNAL;
-char *_DC_message_name(char *box, char *name) G_GNUC_INTERNAL;
-char *_DC_read_message(char *box, char *name, int del_msg) G_GNUC_INTERNAL;
-
-char *_DC_quote_string(char *str) G_GNUC_INTERNAL;
-char *_DC_unquote_string(char *str) G_GNUC_INTERNAL;
-
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif /* __DCAPI_LOCAL_UTILS_H_ */
diff --git a/dcapi/local/local_wu.c b/dcapi/local/local_wu.c
deleted file mode 100644
index bf1632f..0000000
--- a/dcapi/local/local_wu.c
+++ /dev/null
@@ -1,45 +0,0 @@
-/*
- * local/local_wu.c
- *
- * DC-API functions of master side
- *
- * (c) Daniel Drotos, 2007
- */
-
-/* $Id$ */
-/* $Date$ */
-/* $Revision$ */
-
-#include "local_master.h"
-
-
-/* Get a configuration parameter */
-char *
-_DC_wu_cfg(DC_Workunit *wu,
-	   enum _DC_e_param what)
-{
-	/*if (!_DC_wu_check(wu))
-	  return(NULL);*/
-	if (what >= cfg_nuof)
-		return(NULL);
-	if (!_DC_params[what].name)
-		return(NULL);
-
-	if (_DC_params[what].gvalue)
-		return(_DC_params[what].gvalue);
-
-	_DC_params[what].gvalue=
-		DC_getClientCfgStr(wu->client_name,
-				   _DC_params[what].name,
-				   /*TRUE*/1);
-	if (_DC_params[what].gvalue)
-		return(_DC_params[what].gvalue);
-	return(_DC_params[what].def);
-}
-
-
-/* End of local/local_wu.c */
-
-/* Local variables: */
-/* c-file-style: "linux" */
-/* End: */
diff --git a/dcapi/local/local_wu.h b/dcapi/local/local_wu.h
deleted file mode 100644
index 2b420d2..0000000
--- a/dcapi/local/local_wu.h
+++ /dev/null
@@ -1,33 +0,0 @@
-/*
- * local/local_wu.h
- *
- * DC-API functions of master side
- *
- * (c) Daniel Drotos, 2007
- */
-
-/* $Id$ */
-/* $Date$ */
-/* $Revision$ */
-
-#ifndef __DC_API_LOCAL_WU_H
-#define __DC_API_LOCAL_WU_H
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-/* Get a configuration parameter */
-char *_DC_wu_cfg(DC_Workunit *wu, enum _DC_e_param what) G_GNUC_INTERNAL;
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif
-
-/* End of local/local_wu.h */
-
-/* Local variables: */
-/* c-file-style: "linux" */
-/* End: */
diff --git a/dcapi/python/DCAPI/BOINC_Backend.py b/dcapi/python/DCAPI/BOINC_Backend.py
deleted file mode 100644
index 39f0bfb..0000000
--- a/dcapi/python/DCAPI/BOINC_Backend.py
+++ /dev/null
@@ -1,27 +0,0 @@
-import os
-
-from DCAPI.DCAPI_Backend import DCAPI_Backend
-
-import boinc_path_config
-from Boinc import configxml
-
-class BOINC_Backend(DCAPI_Backend):
-    """DC-API deployment interface for BOINC"""
-
-    def __init__(self):
-        DCAPI_Backend.__init__(self)
-        try:
-            self.config = configxml.default_config()
-        except:
-            raise SystemExit("Failed to locate/parse the BOINC project configuration")
-        self.master_keys.extend([("ProjectRootDir", False)])
-        self.client_keys.extend([("Redundancy", False),
-                                 ("MaxOutputSize", False),
-                                 ("MaxMemUsage", False),
-                                 ("MaxDiskUsage", False),
-                                 ("EstimatedFPOps", True),
-                                 ("MaxFPOps", True),
-                                 ("DelayBound", True)])
-
-    def master_defaults(self):
-        return {'ProjectRootDir': os.path.dirname(self.config.filename)} 
diff --git a/dcapi/python/DCAPI/Condor_Backend.py b/dcapi/python/DCAPI/Condor_Backend.py
deleted file mode 100644
index 57db7fb..0000000
--- a/dcapi/python/DCAPI/Condor_Backend.py
+++ /dev/null
@@ -1,19 +0,0 @@
-from DCAPI.DCAPI_Backend import DCAPI_Backend
-
-class Condor_Backend(DCAPI_Backend):
-    """DC-API deployment interface for Condor"""
-
-    def __init__(self):
-        DCAPI_Backend.__init__(self)
-        self.master_keys.extend([("SleepingInterval", False)])
-        self.client_keys.extend([("ClientMessageBox", False),
-                                 ("MasterMessageBox", False),
-                                 ("SubresultBox", False),
-                                 ("SystemMessageBox", False),
-                                 ("Executable", True),
-                                 ("LeaveFiles", False),
-                                 ("CheckpointFile", False),
-                                 ("SavedOutputs", False),
-                                 ("SubmitFile", False),
-                                 ("CondorLog", False),
-                                 ("CondorSubmitTemplate", False)])
diff --git a/dcapi/python/DCAPI/DCAPI_Backend.py b/dcapi/python/DCAPI/DCAPI_Backend.py
deleted file mode 100644
index c7de497..0000000
--- a/dcapi/python/DCAPI/DCAPI_Backend.py
+++ /dev/null
@@ -1,17 +0,0 @@
-class DCAPI_Backend:
-    def __init__(self):
-        self.master_keys = [("WorkingDirectory", True),
-                            ("InstanceUUID", True),
-                            ("LogLevel", False),
-                            ("LogFile", False)]
-        self.client_keys = [("SendCfgKeys", False),
-                            ("LogLevel", False)]
-    
-    def master_defaults(self):
-        pass
-    
-    def get_master_keys(self):
-        return self.master_keys
-
-    def get_client_keys(self):
-        return self.client_keys
diff --git a/dcapi/python/DCAPI/__init__.py b/dcapi/python/DCAPI/__init__.py
deleted file mode 100644
index cad43db..0000000
--- a/dcapi/python/DCAPI/__init__.py
+++ /dev/null
@@ -1,3 +0,0 @@
-"""
-Empty
-"""
diff --git a/dcapi/python/DCAPI/local_Backend.py b/dcapi/python/DCAPI/local_Backend.py
deleted file mode 100644
index 0382df9..0000000
--- a/dcapi/python/DCAPI/local_Backend.py
+++ /dev/null
@@ -1,16 +0,0 @@
-from DCAPI.DCAPI_Backend import DCAPI_Backend
-
-class local_Backend(DCAPI_Backend):
-    """DC-API deployment interface for local execution"""
-
-    def __init__(self):
-        DCAPI_Backend.__init__(self)
-        self.master_keys.extend([("SleepingInterval", False)])
-        self.client_keys.extend([("ClientMessageBox", False),
-                                 ("MasterMessageBox", False),
-                                 ("SubresultBox", False),
-                                 ("SystemMessageBox", False),
-                                 ("Executable", True),
-                                 ("LeaveFiles", False),
-                                 ("CheckpointFile", False),
-                                 ("SavedOutputs", False)])
diff --git a/dcapi/tmp/dc_client_fortran.c b/dcapi/tmp/dc_client_fortran.c
deleted file mode 100644
index 6d7b169..0000000
--- a/dcapi/tmp/dc_client_fortran.c
+++ /dev/null
@@ -1,251 +0,0 @@
-#include <stdio.h>
-#include <string.h>
-#include <stdlib.h>
-
-#include <dc_client.h>
-
-/********************************************************************
- * Helper Functions
- */
-
-// Fortran strings are passed as character array which is not null-terminated plus length
-//
-static char *string_from_fortran(const char *string, int string_len)
-{
-	char *p;
-
-	p = (char *)malloc(string_len + 1);
-	memcpy(p, string, string_len);
-	p[string_len] = 0;
-
-	return p;
-}
-
-// remove terminating null and pad with blanks for FORTRAN
-//
-static void string_to_fortran(char *string, int string_len)
-{
-	int i;
-	for (i = strlen(string); i < string_len; i++)
-	{
-		string[i] = ' ';
-	}
-}
-
-// remove whitespace from start and end of a string
-//
-void strip_whitespace(char *string)
-{
-	int n;
-
-	while (1)
-	{
-		if (!string[0]) break;
-		if (!isascii(string[0])) break;
-		if (!isspace(string[0])) break;
-		strcpy(string, string+1);
-	}
-
-	while (1)
-	{
-		n = (int)strlen(string);
-		if (n == 0) break;
-		if (!isascii(string[n-1])) break;
-		if (!isspace(string[n-1])) break;
-		string[n-1] = 0;
-	}
-}
-
-/********************************************************************
- * FORTRAN DC Client API Functions
- */
-
-void dc_initclient_(int* retval)
-{
-	*retval = DC_initClient();
-}
-
-char *DC_resolveFileNameAuto(const char *logicalFileName)
-{
-	char *filename;
-
-	filename = DC_resolveFileName(DC_FILE_IN, filename);
-	if (!filename)
-	{
-		DC_resolveFileName(DC_FILE_TMP, filename);
-		if (!filename)
-		{
-			DC_log(LOG_ERR, "Resolving file '%s' failed!", filename);
-			return NULL;
-		}
-		DC_log(LOG_DEBUG, "file %s resolved by DC_FILE_TMP", filename);
-		return filename;
-	}
-	DC_log(LOG_DEBUG, "file %s resolved by DC_FILE_IN", filename);
-	return filename;
-}
-
-void dc_resolvefilename_(int* fileType, const char *logicalFileName, char *physicalFileName,
-					int logicalFileNameLen, int physicalFileNameLen)
-{
-	char *filename;
-
-	filename = string_from_fortran(logicalFileName, logicalFileNameLen);
-	strip_whitespace(filename);
-
-	switch(*fileType)
-	{
-		case 1:
-			physicalFileName = DC_resolveFileName(DC_FILE_IN, filename);
-			break;
-		case 2:
-			physicalFileName = DC_resolveFileName(DC_FILE_OUT, filename);
-			break;
-		case 3:
-			physicalFileName = DC_resolveFileName(DC_FILE_TMP, filename);
-			break;
-		case 4:
-			physicalFileName = DC_resolveFileNameAuto(filename);
-			break;
-		default:
-			DC_log(LOG_ERR, "Undefined DC_FileType in DC_resolveFileName_ function call.");	
-			DC_log(LOG_ERR, "DC_FileType: %d, logicalFileName: %s",	*fileType, filename);
-			if (filename)
-				free(filename);
-			exit(1);
-	}
-
-	string_to_fortran(physicalFileName, physicalFileNameLen);
-	if(filename)
-		free(filename);
-}
-
-void dc_sendresult_(const char *logicalFileName, const char *path,
-        int* fileMode, int logicalFileNameLen, int pathLen, int* retval)
-{
-	char *filename;
-	char *filePath;
-
-	filename = string_from_fortran(logicalFileName, logicalFileNameLen);
-	strip_whitespace(filename);
-	filePath = string_from_fortran(path, pathLen);
-	strip_whitespace(filePath);
-
-	switch(*fileMode)
-	{
-		case 1:
-			*retval = DC_sendResult(filename, filePath, DC_FILE_REGULAR);
-			break;
-		case 2:
-			*retval = DC_sendResult(filename, filePath, DC_FILE_PERSISTENT);
-			break;
-		case 3:
-			*retval = DC_sendResult(filename, filePath, DC_FILE_VOLATILE);
-			break;
-		default:
-			DC_log(LOG_ERR, "Undefined DC_FileMode in DC_sendResult function call.");	
-			DC_log(LOG_ERR, "DC_FileMode: %d, logicalFileName: %s, path: %s",
-					*fileMode, filename, filePath);
-			if (filename)
-				free(filename);
-			if (filePath)
-				free(filePath);
-			exit(1);
-	}
-	if (filename)
-		free(filename);
-	if (filePath)
-		free(filePath);
-}
-
-void dc_sendmessage_(const char *message, int messageLen, int* retval)
-{
-	char *msg;
-
-	msg = string_from_fortran(message, messageLen);
-	strip_whitespace(msg);
-	*retval = DC_sendMessage(msg);
-	if(msg)
-		free(msg);
-}
-
-void dc_checkclientevent_(void)
-{
-	// XXX not impl yet
-}
-
-void dc_destroyclientevent_(void)
-{
-	// XXX not impl yet
-}
-
-void dc_checkpointmade_(const char *filename, int filename_len)
-{
-	char *file;
-
-	file = string_from_fortran(filename, filename_len);
-	strip_whitespace(file);
-	DC_checkpointMade(file);
-	if (file)
-		free(file);
-}
-
-void dc_fractiondone_(double* fraction)
-{
-	DC_fractionDone(*fraction);
-}
-
-void dc_finishclient_(int* exitcode)
-{
-	DC_finishClient(*exitcode);
-}
-
-void dc_getmaxmessagesize_(int* retval)
-{
-	*retval = DC_getMaxMessageSize();
-}
-
-void dc_getmaxsubresults_(int* retval)
-{
-	*retval = DC_getMaxSubresults();
-}
-
-void dc_getgridcapabilities_(void)
-{
-	// XXX not impl yet
-}
-
-void dc_getcfgstr_(const char *name, char *string, int nameLen, int stringLen)
-{
-	char *key;
-	char *value;
-
-	key = string_from_fortran(name, nameLen);
-	strip_whitespace(key);
-	string = DC_getCfgStr(key);
-	string_to_fortran(string, stringLen);
-	if (key)
-		free(key);
-}
-
-void dc_getcfgint_(const char *name, int* defaultValue, int nameLen, int* retval)
-{
-	char *key;
-
-	key = string_from_fortran(name, nameLen);
-	strip_whitespace(key);
-	*retval = DC_getCfgInt(key, *defaultValue);
-	if (key)
-		free(key);
-}
-
-void dc_getcfgbool_(const char *name, int* defaultValue, int nameLen, int* retval)
-{
-	char *key;
-
-	key = string_from_fortran(name, nameLen);
-	strip_whitespace(key);
-	*retval = DC_getCfgBool(key, *defaultValue);
-	if (key)
-		free(key);
-}
diff --git a/html/bt/INSTALL b/html/bt/INSTALL
deleted file mode 100644
index 6d3db11..0000000
--- a/html/bt/INSTALL
+++ /dev/null
@@ -1,25 +0,0 @@
------------------
-Setting it all up
------------------
-The .torrent cache will need to know where to look for the files that are going
-to be sent to the clients. Usually this will be the project download directory.
-
-<insert more settings here>
-
-Also, you need to run the database scripts in the /database/-directory in order
-to set up your database for bittorrent tracking.
-
-------------------
-How to enable this
-------------------
-By default Bittorrent support is turned off on both server and client. You must
-enable bittorrent in your server configuration files by doing this:
-
-<insert useful guide here>
-
-You must also convince your users that enabling Bittorrent support on their clients
-is a useful way to help the project. It is a good idea to let them know that
-setting the "Maximum upload rate" under general preferences enables them to
-control just how much of their outgoing bandwidth is ever used. A setting of 70%
-or less of their actual bandwidth is recommended to avoid creating latency issues
-on their connection.
diff --git a/html/bt/README b/html/bt/README
deleted file mode 100644
index 3d49a4d..0000000
--- a/html/bt/README
+++ /dev/null
@@ -1,47 +0,0 @@
-NOTE: THE CODE IN THIS DIRECTORY DOESN'T CURRENTLY WORK,
-AND IS NOT BEING MAINTAINED.
-IT'S HERE IN CASE SOMEONE WANTS TO REVIVE IT.
-
------------------------------------
-Bittorrent file distribution system
------------------------------------
-When several workunits require the same file (for instance any particularly big 
-application file) it is really a waste to use a central server to distribute this
-file. First of all a central server requires lots of bandwidth - which may be
-quite expensive. Secondly getting 10'000 requests for the same multi-megabyte
-file may be too much for even the largest of servers.
-
-The solution is to harness the power of peer-to-peer computing in the domain of
-volunteer and desktop grid computing by allowing the clients to share pieces of the
-files they are downloading.
-
-How it works
-------------
-Since noone can be trusted, "Bob" (a client) will need some way of knowing if "Eve" 
-(another client) sent him a valid piece of the original file. To enable him to do
-so Bob has downloaded a .torrent from the project servers. The .torrent describes
-the file he is downloading; it contains hash values for each piece so that he can
-check whether "Eve" is trying to cheat him.
-
-If "Alice" also wants to download the same file as "Bob" they can each fetch a
-different piece from the project servers and then share the pieces. Seen from
-"Bob" and "Alice"'s perspective this potentially doubles the download rate (if you
-see it from the project perspective it cuts the required network bandwidth in half).
-As more people join the synergetic effect increases dramatically.
-
-Isn't Bittorrent illegal?
--------------------------
-Bittorrent is a protocol for sharing files across the internet. As such it cannot
-be illegal in itself - it is what you do with it that matters.
-If you take a look at all the filesharing protocols out there Bittorrent seems to
-be the one that has been taken into widespread use in the whitehat part of the 
-internet. Several major companies, including the movie industry, have adopted the 
-technology because of its unique ability to distribute load. To name a few uses:
-- Bittorrent.com (Works with the movie industry, sells movies and shows)
-- Blizzard Entertainment (Uses BT to distribute data patches for their World of
-  Warcraft game)
-- EletricSheep screensaver (Uses BT to distribute computed "dreams")
-
-How do I enable this?
----------------------
-Have a look at the INSTALL file located in the same directory as this file.
diff --git a/html/bt/announce.php b/html/bt/announce.php
deleted file mode 100644
index c01955e..0000000
--- a/html/bt/announce.php
+++ /dev/null
@@ -1,100 +0,0 @@
-<?php
-/**
- * This file contains the main portion of the tracker.
- * The tracker is the central part of any Bittorrent system. The tracker coordinates the downloads
- * between peers and ensures that only valid files are tracked. It is queried multiple times during
- * any Bittorrent-enabled download - usually whenever a peer wants to expand its list of other peers.
- *
- * The tracker also keeps track of how the downloads are progressing.
- */
-$cvs_version_tracker[]="\$Id$";  //Generated automatically - do not edit
-
-require_once("config.php");
-
-function trackerError($error){
-    echo BDictionary::toEncoded(array("failure_reason"=>$error));
-    exit;
-}
-
-$info_hash = rawurldecode($_GET["info_hash"]);
-if (strlen($info_hash)!=20) throw new IllegalArgumentException("Malformed infohash key (length ".strlen($info_hash).")");
-$peer_id = $_GET["peer_id"];
-if (strlen($peer_id)!=20) throw new IllegalArgumentException("Malformed peer ID (".strlen($peer_id).")");
-$port = $_GET["port"];
-if (!is_numeric($port)) throw new IllegalArgumentException("Non-numeric port supplied");
-$event = $_GET["event"];
-$ip = $_GET["ip"];
-$uploaded = $_GET["uploaded"]; 
-if (!$uploaded) $uploaded = 0;
-if (!is_numeric($uploaded)) throw new IllegalArgumentException("Non-numeric upload amount specified");
-$downloaded = $_GET["downloaded"]; if (!$downloaded) $downloaded = 0;
-if (!is_numeric($downloaded)) throw new IllegalArgumentException("Non-numeric download amount specified");
-
-if (!$ip){
-    $ip = $_SERVER["REMOTE_ADDR"];
-}
-
-// Is the IP banned?
-db_init();
-if (isIPBanned($ip)){
-    trackerError("Banned IP: ".$ip);
-}
-
-// Check that the info_hash is one that we allow:
-$queryHandle = mysql_query("SELECT * from bittorrent_files where info_hash=\"".process_user_text($info_hash)."\""); echo mysql_error();
-if (!mysql_num_rows($queryHandle)){
-    trackerError("The tracker does not allow tracking of this file:".$info_hash . " [] ".$_GET["info_hash"]);
-}
-$infoHashObject = mysql_fetch_object($queryHandle);
-
-// If the peer is actively doing something let's update the DB
-if ($event=="started" || $event=="stopped" || $event=="completed"){
-    mysql_query("REPLACE into bittorrent_peers SET fileid=".$infoHashObject->id.", peerid=\"".process_user_text($peer_id)."\", ip=\"".process_user_text($ip)."\", port=\"".process_user_text($port)."\", status=\"".$event."\", uploaded=".process_user_text($uploaded).", downloaded=".process_user_text($downloaded).", timestamp=".time());
-    echo mysql_error();
-} else {
-    mysql_query("REPLACE delayed into bittorrent_peers SET fileid=".$infoHashObject->id.", peerid=\"".process_user_text($peer_id)."\", ip=\"".process_user_text($ip)."\", port=\"".process_user_text($port)."\", uploaded=".process_user_text($uploaded).", downloaded=".process_user_text($downloaded).", timestamp=".time());
-    echo mysql_error();
-}
-
-// Always send back a random selection of peers who are downloading a file with the same info_hash
-$queryHandle = mysql_query("SELECT * from bittorrent_peers WHERE fileid = ".$infoHashObject->id." order by RAND() limit ".MAX_INFO_HASH_PEERS); echo mysql_error();
-$peerList = array();
-while ($dbPeer = mysql_fetch_object($queryHandle)){
-    $peer = array("peer id"=>$dbPeer->peerid, "ip"=>$dbPeer->ip, "port"=>intval($dbPeer->port));
-    $peerList[] = new BElement(BDictionary::toEncoded($peer));
-}
-
-// Get some statistical counts
-$queryHandle = mysql_query("SELECT count(fileid) as complete from bittorrent_peers where fileid = '".$infoHashObject->id."' and status='completed'");
-$data = mysql_fetch_object($queryHandle);
-$complete = intval($data->complete);
-$queryHandle = mysql_query("SELECT count(fileid) as incomplete from bittorrent_peers where fileid = '".$infoHashObject->id."' and status!='completed'");
-$data = mysql_fetch_object($queryHandle);
-$incomplete = intval($data->incomplete);
-
-
-$peersElement = new BElement(BList::toEncoded($peerList));
-$out = BDictionary::toEncoded(array("interval"=>DEFAULT_CONNECTION_INTERVAL, "complete"=>$complete, "incomplete"=>$incomplete, "peers"=>$peersElement));
-
-// Echo the answer to stdout
-echo $out;
-$fh = fopen(TRACKER_LOGFILE, "a");
-fputs($fh, date(DATE_ATOM, time())." ".$_SERVER["REMOTE_ADDR"]." - ".$event."\n");
-fclose($fh);
-
-// ------------------------------------------------------
-// Check if the database needs cleaning
-$cache_args = "tracker_timer";
-$cacheddata=get_cached_data(DB_CLEAN_TTL,$cache_args);
-if ($cacheddata){ //If we have got the timer in cache
-    // Do nothing
-} else { //if not do queries etc to clean DB
-    // TODO: update the bittorrent_statistics table here before deleting entries
-    mysql_query("DELETE from bittorrent_files where timestamp<".(time()-TORRENT_TTL)); echo mysql_error();
-    mysql_query("DELETE from bittorrent_peers where timestamp<".(time()-PEER_TTL)); echo mysql_error();
-    mysql_query("DELETE from bittorrent_ipbans where timestamp<".time()); echo mysql_error();
-    // And reset the timer in the cache
-    set_cache_data(serialize(time()),$cache_args); //save data in cache
-};
-				     
-?>
\ No newline at end of file
diff --git a/html/bt/config.php.example b/html/bt/config.php.example
deleted file mode 100644
index 2bf76c7..0000000
--- a/html/bt/config.php.example
+++ /dev/null
@@ -1,81 +0,0 @@
-<?php
-// Includes from BOINC
-require_once("../inc/cache.inc");
-require_once("../inc/util.inc");
-
-// Includes from BT
-require_once("./inc/illegalargumentexception.php");
-require_once("./inc/torrent.php");
-require_once("./inc/belement.php");
-require_once("./inc/blist.php");
-require_once("./inc/bstring.php");
-require_once("./inc/bdictionary.php");
-require_once("./inc/binteger.php");
-require_once("./inc/checks.php");
-
-// Includes for filtering
-require_once("./filters/filefilter.php");
-
-$cvs_version_tracker[]="\$Id$";  //Generated automatically - do not edit
-
-
-/**
- * Usually it should be enough to edit the lines below this comment to fit your usage scenario - 
- * ie. if you have a lot of users and the files you have change a lot you may wish to cut down on
- * the torrent_ttl (since this determines the final size of the database).
- * The remaining part of this configuation file is split into 2 subparts: One for configuration
- * of the tracker and one for configuration of the .torrent-generator.
- */
-
-// Tracker --------------------------------------------------------------------------------------------------------
-define (TORRENT_TTL, 3600*24*15); // How long any torrent will remain in the database if it hasn't been accessed
-define (PEER_TTL, 3600*24); // How long any peer will remain in the database if it hasn't talked to us
-define (DB_CLEAN_TTL, 3600*24); // How often the DB will be cleaned
-define (DEFAULT_CONNECTION_INTERVAL, 3600); // How often we would like clients to talk to the tracker
-define (MAX_INFO_HASH_PEERS, 30); // How many peers to send back for each tracker request
-define (TRACKER_LOGFILE, "../../logs/bittorrent.log");
-// Tracker end ----------------------------------------------------------------------------------------------------
-
-
-// Generator ------------------------------------------------------------------------------------------------------
-define (TORRENT_CACHE_TTL, 3600*24); // How long before regenerating any torrent information (if your files are immutable simply set this to TORRENT_TTL).
-/** 
- * The file filter determines which files to use bittorrent for and which not to track through bittorrent.
- * Setting the file filter requires that you include whatever filter you decide to use first. For a list
- * of available filters please have a look in the ./filters/-folder.
- * A good default behaviour is to either track anything or only track files greater than some set size.
- */
-require_once("./filters/allfilesfilefilter.php"); // Include happens with the FILEname of the chosen FileFilter class
-$fileFilter = new AllFilesFileFilter(); // Instantiation happens with the CLASSname of the class.
-
-/**
- * FileDirectory: The base directory to serve files from. All file references will be relative to this.
- * Symlinks outside the $fileDirectory are not allowed. Either do hardlinking or make the
- * entire $fileDirectory a symlink somewhere.
- */
-$fileDirectory="../../download";
-$trackerURL = "http://bittorrent.burp.boinc.dk/announce.php"; // The externally accessible URL to use for tracking purposes (should point to announce.php)
-
-/**
- * Webseeds: This optional array lists any project HTTP webservers capable of handing out the files.
- * Note that the servers must have a very strict hierarchy for the files:
- * The optional webseeds must be HTTP servers with a similar structure to $fileDirectory
- * For instance if you have a webseed called "http://burp.boinc.dk/download/" and a file
- * $fileDirectory/dir/file
- * then the webseed musst respond to queries on http://burp.boinc.dk/download/dir/file.
- */  
-$webseeds = array(
-    "http://burp.boinc.dk/mirror/mirror_download.php?fetch=true&mirsug=0&getfile=",
-    "http://burp.boinc.dk/mirror/mirror_download.php?fetch=true&mirsug=1&getfile=",
-    "http://burp.boinc.dk/mirror/mirror_download.php?fetch=true&mirsug=2&getfile=",
-    "http://burp.boinc.dk/mirror/mirror_download.php?fetch=true&mirsug=3&getfile=",
-    "http://burp.boinc.dk/mirror/mirror_download.php?fetch=true&mirsug=4&getfile=",
-    "http://burp.boinc.dk/mirror/mirror_download.php?fetch=true&mirsug=5&getfile=",
-    "http://burp.boinc.dk/mirror/mirror_download.php?fetch=true&mirsug=6&getfile=",
-    "http://burp.boinc.dk/mirror/mirror_download.php?fetch=true&mirsug=7&getfile=",
-    "http://burp.boinc.dk/mirror/mirror_download.php?fetch=true&mirsug=8&getfile=",
-    "http://burp.boinc.dk/mirror/mirror_download.php?fetch=true&mirsug=9&getfile=");				
-// Generator end --------------------------------------------------------------------------------------------------
-
-
-?>
\ No newline at end of file
diff --git a/html/bt/database/bittorrent_files.sql b/html/bt/database/bittorrent_files.sql
deleted file mode 100644
index eaabd2c..0000000
--- a/html/bt/database/bittorrent_files.sql
+++ /dev/null
@@ -1,9 +0,0 @@
-CREATE TABLE `bittorrent_files` (
-    `id` int(11) NOT NULL auto_increment,
-    `filename` varchar(256) default NULL,
-    `info_hash` varbinary(22) default NULL,
-    `timestamp` int(14) NOT NULL,
-    PRIMARY KEY  (`id`),
-    UNIQUE KEY `filename` (`filename`),
-    KEY `info_hash` (`info_hash`)
-) ENGINE=MEMORY;
\ No newline at end of file
diff --git a/html/bt/database/bittorrent_ipbans.sql b/html/bt/database/bittorrent_ipbans.sql
deleted file mode 100644
index 0169534..0000000
--- a/html/bt/database/bittorrent_ipbans.sql
+++ /dev/null
@@ -1,5 +0,0 @@
-CREATE TABLE `bittorrent_ipbans` (
-    `ip` varbinary(256) NOT NULL default '',
-    `timestamp` int(14) NOT NULL,
-    PRIMARY KEY  (`ip`)
-) ENGINE=MEMORY COMMENT='Banned IPs and when they can be unbanned (reset when SQL-server restarts)';
\ No newline at end of file
diff --git a/html/bt/database/bittorrent_peers.sql b/html/bt/database/bittorrent_peers.sql
deleted file mode 100644
index 4801144..0000000
--- a/html/bt/database/bittorrent_peers.sql
+++ /dev/null
@@ -1,13 +0,0 @@
-CREATE TABLE `bittorrent_peers` (
-    `fileid` int(11) NOT NULL default '0',
-    `peerid` varbinary(20) NOT NULL,
-    `ip` varbinary(50) default NULL,
-    `port` int(11) NOT NULL,
-    `status` enum('started','stopped','completed') NOT NULL,
-    `uploaded` int(11) NOT NULL,
-    `downloaded` int(11) NOT NULL,
-    `timestamp` int(14) NOT NULL,
-    PRIMARY KEY  (`fileid`,`peerid`),
-    KEY `timestamp` (`timestamp`)
-) ENGINE=MEMORY;
-	        
\ No newline at end of file
diff --git a/html/bt/filters/allfilesfilefilter.php b/html/bt/filters/allfilesfilefilter.php
deleted file mode 100644
index c9d46f5..0000000
--- a/html/bt/filters/allfilesfilefilter.php
+++ /dev/null
@@ -1,16 +0,0 @@
-<?php
-
-/**
- * A file filter that simply accepts any file whatsoever
- */
-
-$cvs_version_tracker[]="\$Id: checks.php 12885 2007-06-11 18:27:24Z jbk $";  //Generated automatically - do not edit
-
- 
-class AllFilesFileFilter extends FileFilter {
-    function isValid($file){
-	return true;
-    }
-}
-
-?>
\ No newline at end of file
diff --git a/html/bt/filters/filefilter.php b/html/bt/filters/filefilter.php
deleted file mode 100644
index 4cde924..0000000
--- a/html/bt/filters/filefilter.php
+++ /dev/null
@@ -1,13 +0,0 @@
-<?php
-/**
- * Any file filter must implement the following interface
- */
-
-$cvs_version_tracker[]="\$Id: checks.php 12885 2007-06-11 18:27:24Z jbk $";  //Generated automatically - do not edit
-
-
-abstract class FileFilter {
-    abstract function isValid($file);    
-}
-
-?>
\ No newline at end of file
diff --git a/html/bt/inc/bdictionary.php b/html/bt/inc/bdictionary.php
deleted file mode 100644
index 9c8b8b0..0000000
--- a/html/bt/inc/bdictionary.php
+++ /dev/null
@@ -1,53 +0,0 @@
-<?php
-/**
- * A dictionary is a mapping from strings to elements. When BEncoded a dictionary is
- * two lists interleaved. In PHP dictionaries are represented as arrays with the 
- * string as index and value as entry at that index.
- * In BEncoded form a dictionary starts with "d" and is followed directly by the
- * contents of the interleaved data list and ends with "e".
- *
- * d3:cow3:moo4:spam4:eggse represents the dictionary { "cow" => "moo", "spam" => "eggs" } 
- */
-
-$cvs_version_tracker[]="\$Id$";  //Generated automatically - do not edit
-
-class BDictionary {
-    private function __construct(){
-    }
-    
-    /**
-     * Returns the decoded array from $str
-     * @throws an IllegalArgumentException in the case
-     * that the string is malformed.
-     */
-    public static function toArray($str){
-        if (substr($str, 0, 1)!="d" || substr($str, -1, 1)!="e") throw new IllegalArgumentException("BEncoded dictionary does not start with d or end with e.");
-	// An array is simply two lists encoded in an alternating list
-        $arrays = BList::toList("l".substr($str, 1));
-	
-	$i=0;
-	for ($i=0;$i<sizeof($arrays); $i+=2){
-	    $array[$arrays[$i]] = $arrays[$i+1];
-	}
-        return $array;
-    }				
-
-    /**
-     * Returns a BEncoded dictonary
-     */
-    public static function toEncoded($array){
-	ksort($array);
-
-	// An array is simply two lists encoded as an alternating list
-	$list = array();
-	foreach ($array as $key => $value){
-	    $list[] = $key;
-	    $list[] = $value;
-	}
-	
-	return "d".substr(BList::toEncoded($list), 1);
-    }    
-}
-
-
-?>
\ No newline at end of file
diff --git a/html/bt/inc/belement.php b/html/bt/inc/belement.php
deleted file mode 100644
index 5609810..0000000
--- a/html/bt/inc/belement.php
+++ /dev/null
@@ -1,29 +0,0 @@
-<?php
-/**
- * This class is used as part of the Bittorrent .torrent creator and tracker system.
- * A BElement is used to contain BEncoded elements inside other BEncodings (like lists or dictonaries)
- */
-
-$cvs_version_tracker[]="\$Id: belement.inc 12611 2007-05-08 08:25:13Z jbk $";  //Generated automatically - do not edit
-
-class BElement {
-    private $encodedText;
-    
-    /**
-     * Constructs a new BElement with the $bEncoding as BEncoded
-     * value to be used 
-     */
-    public function __construct($bEncoding){
-	$this->encodedText = $bEncoding;
-    }
-    
-    /**
-     * Returns a BEncoded value
-     */
-    public function toEncoded(){
-	return $this->encodedText;
-    }    
-}
-
-
-?>
\ No newline at end of file
diff --git a/html/bt/inc/binteger.php b/html/bt/inc/binteger.php
deleted file mode 100644
index e939701..0000000
--- a/html/bt/inc/binteger.php
+++ /dev/null
@@ -1,35 +0,0 @@
-<?php
-/**
- * A BInteger takes care of the BEncoding and BDecoding of integers for the 
- * Bittorrent features.
- * An integer starts with "i", has the value and then ends with "e".
- */
- 
-$cvs_version_tracker[]="\$Id$";  //Generated automatically - do not edit
- 
-class BInteger {
-    private function __construct(){
-    }
-    
-    /**
-     * Returns the ordinary value decoded from $str
-     * @throws an IllegalArgumentException in the case
-     * that the string is malformed.
-     */
-    public static function toInteger($str){
-        if (substr($str, 0, 1)!="i" || substr($str, -1, 1)!="e") throw new IllegalArgumentException("BEncoded integer value does not start with i or end with e.");
-        $value = substr($str, 1,-1);
-        if (!is_numeric($value)) throw new IllegalArgumentException("BEncoded string has non-numeric length specification.");
-        return $value;
-    }				
-
-    /**
-     * Returns a BEncoded integer value
-     */
-    public static function toEncoded($value){
-	return "i".$value."e";
-    }    
-}
-
-
-?>
\ No newline at end of file
diff --git a/html/bt/inc/blist.php b/html/bt/inc/blist.php
deleted file mode 100644
index 86f45b3..0000000
--- a/html/bt/inc/blist.php
+++ /dev/null
@@ -1,102 +0,0 @@
-<?php
-/**
- * The BList class is part of the Bittorrent serverside utility classes
- * It implements a BEncoded list - which always starts with l and ends with e.
- * In PHP lists are simply non-keyed (ie. standard keyed) arrays.
- */
- 
-$cvs_version_tracker[]="\$Id$";  //Generated automatically - do not edit
- 
-class BList {
-    private function __construct(){
-    }
-    
-    /**
-     * Returns the decoded array from $str
-     * @throws an IllegalArgumentException in the case
-     * that the string is malformed.
-     */
-    public static function toList($str){
-        if (substr($str, 0, 1)!="l" || substr($str, -1, 1)!="e") throw new IllegalArgumentException("BEncoded list does not start with l or end with e.");
-        $value = substr($str, 1,-1);
-	
-	// Scan through encoded list and decode everything
-	$list = array();
-	$i=0; $lastI = 0;
-	while ($i<strlen($value)){
-	    $curChar = substr($value, $i,1);
-	    if ($curChar == "i"){ // We just saw an Integer
-		$endPos = strpos($value, "e", $i); // Search for the end of it
-		if ($endPos===false) throw new IllegalArgumentException("BEncoded list contains non-terminated integer");
-		$list[] = BInteger::toInteger(substr($value, $i, $endPos-$i+1));
-		$i=$endPos+1;
-	    } elseif (is_numeric($curChar)){ // A number means we just saw a string starting
-		$seperatorPos = strpos($value, ":", $i); // Search for the seperator
-		if ($seperatorPos===false) throw new IllegalArgumentException("BEncoded list contains malformed string with no length specified");
-		$totalLength = substr($value, $i, $seperatorPos-$i);
-		$list[] = BString::toString(substr($value, $i, $seperatorPos-$i+$totalLength+1));
-		$i=$seperatorPos+$totalLength+1;
-	    } elseif ($curChar == "d" || $curChar == "l"){ // Found a dictionary or list
-		// Scan for end of it
-		$listLength = BList::getListLength(substr($value, $i));
-		if ($curChar == "d"){
-		    $list[] = BDictionary::toArray(substr($value, $i, $listLength));
-		} else {
-		    $list[] = BList::toList(substr($value, $i, $listLength));
-		}
-		$i+=$listLength;
-	    }
-	    if ($i==$lastI) throw new IllegalArgumentException("BEncoded list contains malfomed or unrecognized content");
-	    $lastI = $i;
-	}
-        return $list;
-    }				
-
-    private static function getListLength($text){
-	$i = 1; $lastI = 0; $foundEnd = false;
-	while ($i<strlen($text)){
-	    $curChar = substr($text, $i, 1);
-	    if ($curChar == "i"){
-		$i = strpos($text, "e", $i);
-		if ($i===false) throw new IllegalArgumentException("BEncoded sublist/dictionary integer has no end");
-		$i++;
-	    } elseif (is_numeric($curChar)){
-		$seperatorPos = strpos($text, ":", $i); // Search for the seperator
-		if ($seperatorPos===false) throw new IllegalArgumentException("BEncoded sublist/dictionary contains a string with no length specified");
-		$totalLength = substr($text, $i, $seperatorPos-$i);
-		$i=$seperatorPos+$totalLength+1;		
-	    } elseif ($curChar == "d" || $curChar == "l"){
-		$i+=BList::getListLength(substr($text, $i));
-	    } elseif ($curChar == "e"){
-		$foundEnd = true;
-		break;
-	    }
-	    if ($i==$lastI) throw new IllegalArgumentException("BEncoded sublist/dictionary contains malfomed or unrecognized content");
-	    $lastI = $i;
-	}
-	if (!$foundEnd) throw new IllegalArgumentException("BEncoded sublist/dictionary had no end");
-	return $i+1;
-    }
-
-    /**
-     * Returns a BEncoded list
-     */
-    public static function toEncoded($list){
-	$values = array_values($list);
-	$text = "l";
-	foreach ($values as $value){
-	    if (is_integer($value)){
-		$text.=BInteger::toEncoded($value);
-	    } elseif (is_string($value)){
-		$text.=BString::toEncoded($value);
-	    } elseif ($value instanceof BElement){
-		$text.=$value->toEncoded();
-	    }
-	}
-	$text.= "e";
-	return $text;
-    }    
-}
-
-
-?>
\ No newline at end of file
diff --git a/html/bt/inc/bstring.php b/html/bt/inc/bstring.php
deleted file mode 100644
index 3109ef4..0000000
--- a/html/bt/inc/bstring.php
+++ /dev/null
@@ -1,36 +0,0 @@
-<?php
-/**
- * The BString class represents BEncoded strings for the serverside Bittorrent system.
- * A BEncoded string always starts with the length, then a ":" and then the actual data.
- * Strings are native in PHP.
- */
-
-$cvs_version_tracker[]="\$Id$";  //Generated automatically - do not edit
- 
-class BString {
-    private function __construct(){
-    }
-    
-    /**
-     * Returns the ordinary string decoded from $str
-     * @throws an IllegalArgumentException in the case
-     * that the string is malformed (ie. has more/less chars than specified
-     * or does not correctly define a BEncoded string)
-     */
-    public static function toString($str){
-	list($length, $data) = explode(":", $str);
-	if (!is_numeric($length)) throw new IllegalArgumentException("BEncoded string has non-numeric length specification.");
-	if ($length != strlen($data)) throw new IllegalArgumentException("BEncoded string length does not match actual length of string.");
-	return $data;
-    }
-
-    /**
-     * Returns a BEncoded string
-     */
-    public static function toEncoded($str){
-	return strlen($str).":".$str;
-    }    
-}
-
-
-?>
\ No newline at end of file
diff --git a/html/bt/inc/checks.php b/html/bt/inc/checks.php
deleted file mode 100644
index 9db9c94..0000000
--- a/html/bt/inc/checks.php
+++ /dev/null
@@ -1,31 +0,0 @@
-<?php
-/**
- * Checks common to both the tracker and the scraping mechanism.
- */
-
-$cvs_version_tracker[]="\$Id$";  //Generated automatically - do not edit
-
-
-function isIPBanned($ip){
-    $queryHandle = mysql_query("SELECT * from bittorrent_ipbans where ip=\"".process_user_text($ip)."\" and timestamp > ".time()); echo mysql_error();
-    if (mysql_num_rows($queryHandle)){
-	return true;
-    } else {
-	return false;
-    }
-} 
- 
-if (get_magic_quotes_gpc()) {
-    function stripslashes_deep($value) {
-        $value = is_array($value) ?
-        array_map('stripslashes_deep', $value) :
-        stripslashes($value);
-        return $value;
-    }
-							    
-    $_POST = array_map('stripslashes_deep', $_POST);
-    $_GET = array_map('stripslashes_deep', $_GET);
-    $_COOKIE = array_map('stripslashes_deep', $_COOKIE);
-    $_REQUEST = array_map('stripslashes_deep', $_REQUEST);
-}
-?>
\ No newline at end of file
diff --git a/html/bt/inc/illegalargumentexception.php b/html/bt/inc/illegalargumentexception.php
deleted file mode 100644
index 995f309..0000000
--- a/html/bt/inc/illegalargumentexception.php
+++ /dev/null
@@ -1,9 +0,0 @@
-<?php
-
-$cvs_version_tracker[]="\$Id$";  //Generated automatically - do not edit
-
-
-class IllegalArgumentException extends Exception {
-}
-
-?>
\ No newline at end of file
diff --git a/html/bt/inc/torrent.php b/html/bt/inc/torrent.php
deleted file mode 100644
index 8e058a7..0000000
--- a/html/bt/inc/torrent.php
+++ /dev/null
@@ -1,89 +0,0 @@
-<?php
-
-/**
- * A .torrent is a metafile containing info about a P2P file
- * This class encapsulates all related .torrent information
- * for a single file.
- * We don't seem to need multifile support since the clients can
- * simply download a .torrent for each file they want to fetch.
- */ 
-
-$cvs_version_tracker[]="\$Id$";  //Generated automatically - do not edit
- 
-class Torrent {
-    private $trackerURL; // String
-    private $name;  // String
-    private $pieceLength = 524288; // (512KB)
-    private $filename; // String
-    private $webseeds; // URL String Array
-    
-    private $concattedSHA1; // Imploded string of SHA1 hashes
-    private $generatedPieceLength;
-    private $infoHash;
-    
-    /**
-     * Filename is the full path to the file to be encapsulated.
-     */
-    function __construct($filename, $trackerURL, $webseeds=array()){
-	if (!file_exists($filename)) throw new IllegalArgumentException("No such file found");
-
-	$this->filename = $filename;
-	$this->trackerURL = $trackerURL;
-	$this->webseeds = $webseeds;
-	$this->name = basename($filename);
-    }
-    
-    /** 
-     * Scans the entire file generating SHA1 hashes for each piece
-     */
-    public function ensureSHA1Loaded(){
-	if (!$this->concattedSHA1 || ($this->pieceLength!=$this->generatedPieceLength)){
-	    $fh = fopen($this->filename, "rb");
-	    if (!$fh) throw new Exception("No filehandle");
-	    $fsize = filesize($this->filename);
-	    $this->concattedSHA1 = "";
-	    for ($i = 0; $i<ceil($fsize/$this->pieceLength); $i++){
-		fseek($fh, $i*$this->pieceLength);
-		$this->concattedSHA1 .= sha1(fread($fh,$this->pieceLength), true);
-	    }
-	    $this->generatedPieceLength = $this->pieceLength;
-	    fclose($fh);
-	    if (!$this->concattedSHA1) throw new Exception("No SHA gotten");
-	}
-	
-    }
-    
-    /**
-     * Fetches all relevant information from the file and generates a 
-     * .torrent
-     */
-    public function toEncoded(){
-	$infoArray["name"] = $this->name;
-	$infoArray["piece length"] = $this->pieceLength;
-	$infoArray["length"] = filesize($this->filename);
-	$this->ensureSHA1Loaded();
-	$infoArray["pieces"] = $this->concattedSHA1;
-	$infoDictionary = new BElement(BDictionary::toEncoded($infoArray));
-	$this->infoHash = sha1($infoDictionary->toEncoded(), true);
-	$metainfoArray = array("announce"=>$this->trackerURL, "info"=>$infoDictionary);
-	$metainfoArray["url-list"] = new BElement(BList::toEncoded($this->webseeds));
-	$metainfoDictionary = BDictionary::toEncoded($metainfoArray);
-	
-	return $metainfoDictionary;
-    }
-    
-    /**
-     * Registers this torrent in the database
-     */
-    public function register(){
-	$this->toEncoded();
-	// Check if exists:
-	$queryHandle = mysql_query("SELECT id from bittorrent_files where filename=\"".process_user_text($this->filename)."\"");
-	if ($queryHandle && $data = mysql_fetch_object($queryHandle)){
-	    $extra = "id=".$data->id.", ";
-	} else {
-	    $extra = "";
-	}
-	mysql_query("REPLACE into bittorrent_files set ".$extra."filename=\"".process_user_text($this->filename)."\", info_hash=\"".process_user_text($this->infoHash)."\", timestamp=".time());	    
-    }
-}
\ No newline at end of file
diff --git a/html/bt/index.php b/html/bt/index.php
deleted file mode 100644
index 9e0a511..0000000
--- a/html/bt/index.php
+++ /dev/null
@@ -1,78 +0,0 @@
-<?php
-
-/**
- * This index-file helps setup and debug any Bittorrent tracker and generator installation through
- * the use of some built-in checks in the code.
- * It is advised that you leave the index file in place even after succesful installation so that any
- * later debugging can easily be done.
- *
- * Also, at some point, this file will display some statistical information about the data distributed
- * through the use of the tracker.
- */
-$cvs_version_tracker[]="\$Id$";  //Generated automatically - do not edit
-
-?>
-
-<html>
-    <head>
-	<title>BOINC Bittorrent</title>
-    </head
-    <body>
-	<h1>BOINC Bittorrent</h1>
-	<p>
-	    This page helps you identify whether the BOINC Bittorrent system has succesfully been installed
-	    on the server. If all of the bellow checks are green and all of the settings seem to match your
-	    setup then everything should be perfectly fine.<br />
-	    If, for some reason, the entire page (including the text at the bottom, bellow the table of checks)
-	    isn't displayed, you should have a look at the error-log for your server. Similarly, if one of the
-	    checks fail you may find additional information on the page or in your server logs.
-	</p>
-	<table>
-	    <tr>
-		<th>Check</th><th>Status</th>
-	    </tr>
-<?php
-function showCheck($check, $status, $comment){
-    echo "<tr><td>".$check."</td><td>";
-    if ($status){
-	echo "<font color='green'>OK";
-    } else {
-	echo "<font color='yellow'>Hm...";
-    }
-    echo "</td><td>";
-    if (!$status) echo $comment;
-    echo "</td></tr>";
-}
-	showCheck("Linking to config.php", file_exists("./config.php"), "config.php is missing - did you remember to copy from the sample?");
-	require_once("./config.php");
-	showCheck("Linking to BOINC serverside framework", file_exists("../inc/util.inc"), "Cannot find the BOINC framework - did you install the BT system in the html/-directory of your BOINC installation?");
-	require_once("../inc/util.inc");
-	showCheck("Database link", (db_init()||true), "");
-	showCheck("bittorrent_files table", mysql_query("select * from bittorrent_files"), "Table inaccessible");
-	showCheck("bittorrent_ipbans table", mysql_query("select * from bittorrent_ipbans"), "Table inaccessible");
-	showCheck("bittorrent_peers table", mysql_query("select * from bittorrent_peers"), "Table inaccessible");
-	showCheck("bittorrent_statistics table", mysql_query("select * from bittorrent_statistics"), "Table inaccessible");
-	showCheck("Linking to download dir (".$fileDirectory.")", file_exists($fileDirectory), "Directory not accessible or present");
-	showCheck("Tracker present (".$trackerURL.")", fopen($trackerURL, "r"), "Either this webserver doesn't support URL-fopen-wrappers or the tracker is not available. In the first case you may safely ignore this warning.");
-	showCheck("Webseeds defined", (sizeof($webseeds)>0), "No webseeds defined");
-	foreach ($webseeds as $webseed){
-	    showCheck("Seed present (".$webseed.")", fopen($webseed, "r"), "Either this webserver doesn't support URL-fopen-wrappers or the webseed is not present. If the first is the case this warning may safely be ignored.");
-	}
-	showCheck("Linking to logfile (".TRACKER_LOGFILE.")", file_exists(TRACKER_LOGFILE), "The logfile doesn't exist - this may be because the system hasn't been run yet or because the file couldn't be created.");
-?>
-	</table>
-	<p>
-	    Files used in this distribution:
-	    <ul>
-		<?php 
-		    for ($i=0;$i<sizeof($cvs_version_tracker);$i++) {
-			echo "<li>".$cvs_version_tracker[$i]."\n";
-		    }
-		?>
-	    </ul>
-	</p>				   
-	<p>
-	    For more information check the documentation delivered within the bt directory.
-	</p>
-    </body>
-</html>	
\ No newline at end of file
diff --git a/html/bt/scrape.php b/html/bt/scrape.php
deleted file mode 100644
index d3f3b03..0000000
--- a/html/bt/scrape.php
+++ /dev/null
@@ -1,47 +0,0 @@
-<?php
-/**
- * For multiple purposes it may be interesting for clients to know a little about
- * the network statistics for the entire Bittorrent swarm controlled by the tracker.
- * Scraping allows clients to get this information easily and quickly.
- */
-
-$cvs_version_tracker[]="\$Id$";  //Generated automatically - do not edit
-
-require_once("config.php");
-
-function trackerError($error){
-    echo BDictionary::toEncoded(array("failure_reason"=>$error));
-    exit;
-}
-
-$info_hash = rawurldecode($_GET["info_hash"]);
-if (strlen($info_hash)!=20) throw new IllegalArgumentException("Malformed infohash key (length ".strlen($info_hash).")");
-
-if (!$ip){
-    $ip = $_SERVER["REMOTE_ADDR"];
-}
-
-// Is the IP banned?
-db_init();
-if (isIPBanned($ip)){
-    trackerError("Banned IP: ".$ip);
-}
-
-// Check that the info_hash is one that we allow:
-$queryHandle = mysql_query("SELECT * from bittorrent_files where info_hash=\"".process_user_text($info_hash)."\""); echo mysql_error();
-if (!mysql_num_rows($queryHandle)){
-    trackerError("The tracker does not allow tracking of this file:".$info_hash);
-}
-$infoHashObject = mysql_fetch_object($queryHandle);
-
-// Get some statistical counts
-$queryHandle = mysql_query("SELECT count(fileid) as complete from bittorrent_peers where fileid = '".$infoHashObject->id."' and status='completed'");
-$data = mysql_fetch_object($queryHandle);
-$complete = intval($data->complete);
-$queryHandle = mysql_query("SELECT count(fileid) as incomplete from bittorrent_peers where fileid = '".$infoHashObject->id."' and status!='completed'");
-$data = mysql_fetch_object($queryHandle);
-$incomplete = intval($data->incomplete);
-
-$out = BDictionary::toEncoded(array("interval"=>DEFAULT_CONNECTION_INTERVAL, "downloaded"=>$complete, "complete"=>$complete, "incomplete"=>$incomplete));
-
-?>
\ No newline at end of file
diff --git a/html/bt/torrent_cache.php b/html/bt/torrent_cache.php
deleted file mode 100644
index cf980de..0000000
--- a/html/bt/torrent_cache.php
+++ /dev/null
@@ -1,71 +0,0 @@
-<?php
-/**
- * The torrent cache and generator script takes care of dynamically generating .torrents
- * when they are requested by clients.
- * To optimize performance .torrent-objects are cached in the cache directory so that
- * on any second request they can be directly sent without re-calculating the SHA1 strings.
- *
- * A file is requested by torrent_cache.php?file=/some_file.filetype
- *
- * Symlinks outside the $fileDirectory are not allowed. Either do hardlinking or make the
- * entire $fileDirectory a symlink somewhere.
- * 
- * The optional webseeds must be HTTP servers with a similar structure to $fileDirectory
- * For instance if you have a webseed called "http://burp.boinc.dk/download/" and a file
- * $fileDirectory/dir/file
- * then the webseed musst respond to queries on http://burp.boinc.dk/download/dir/file.
- *
- * Please see config.php for the setting of these variables.
- */
-require_once("config.php");
-
-function isSubDir($possibleSubDir, $parent){
-    $realPossible = realpath($possibleSubDir);
-    $realParent = realpath($parent);
-    return (substr($realPossible, 0, strlen($realParent)) == $realParent);
-}
-
-// Get the file request and do some checkups
-$file = $_GET["file"];
-if (!$file) throw new IllegalArgumentException("No file specified");
-if (strpos(urldecode($file), "..")!==false) throw new IllegalArgumentException("Cannot use '..' in path");
-
-
-// See if we've got the file
-while (!$fileModTime){
-    if (($fileModTime = @filemtime($fileDirectory.$file)) === false){
-	$pos = strpos($file, "/", 1);
-	if ($pos === false){
-	    throw new IllegalArgumentException("File does not exist");
-	} else {
-	    $file = substr($file, $pos);
-	}	
-    }
-}
-
-$file = $fileDirectory.$file;
-
-if (!$fileFilter->isValid($file)) throw new IllegalArgumentException("File was not accepted by the server for tracking.");
-
-// Everything's fine let's lookup the .torrent in the cache if needed:
-$cache_args = "file=".$file."&modtime=".$fileModTime;
-$cacheddata=get_cached_data(TORRENT_CACHE_TTL,$cache_args);
-if ($cacheddata){ //If we have got the data in cache
-    $torrent = unserialize($cacheddata); // use the cached data
-} else { //if not do queries etc to generate new data
-   for ($i=0; $i<sizeof($webseeds);$i++){
-       $realWebseeds[] = $webseeds[$i].substr($file, strlen($fileDirectory));
-   }
-			   
-    $torrent = new Torrent($file, $trackerURL, $realWebseeds);
-    $torrent->ensureSHA1Loaded();
-    db_init();
-    $torrent->register();
-    set_cache_data(serialize($torrent),$cache_args); //save data in cache
-};
-
-header("Content-type: application/x-bittorrent");
-header("Content-Disposition: attachment; filename=\"".basename($file).".torrent\"");
-
-echo $torrent->toEncoded();
-?>
\ No newline at end of file
diff --git a/html/queue/README b/html/queue/README
deleted file mode 100644
index 2461885..0000000
--- a/html/queue/README
+++ /dev/null
@@ -1,102 +0,0 @@
-// THIS SYSTEM IS NOT SUPPORTED BY BOINC.  USE AT YOUR OWN RISK
-//
-// This directory contains a system that allows
-// users to submit jobs to a BOINC project.
-//
-// Major revisions may be required to make this work
-// (and to make it secure) on your project.
-// Please read and understand all the code before using it.
-//
-// Contributed by Dr. M.F. Somers, Leiden University
-//
-// BASIC INSTALL:
-//
-// 1) add tables to database using create_queue.sql:
-//
-//     mysql yourprojectdb < create_queue.sql
-//
-// 2) copy files into html directory of your project so
-//    apache will server them:
-//
-//    cp inc/* ~/Classical/html/inc  (beware the user.inc might be overwritten, use diff!)
-//    cp user/* ~/Classical/html/user
-//    cp ops/* ~/Classical/html/ops
-//
-// 3) Make sure you have defined the following tags in your config.xml:
-//
-//    <uldl_dir_fanout> 
-//    <long_name> 
-//    <bin_dir>
-//    <download_dir>
-//    <upload_dir>
-//    <project_dir>
-//    <create_work_program>
-//    
-// 4) Make sure you have a WU and a result template in the template directory
-//    for each application with the names similar to 'queue_uppercase_work_unit_template'
-//    and 'queue_uppercase_result_unit_template'. These will be used to invoke 'make_work'.
-//
-// That shoult be it; now the queue has been setup and by default allows users to have 5
-// jobslots per application. If your do not want users to be able to submit to an application
-// make sure you list that app (it's ID) into the new q_restricted_apps table. The new
-// q_users table can be used to allow users access to restricted apps or set different
-// limits that the default 5 jobslots. The new q_list table is the list of allw WU's that
-// have been submitted through the queue code...
-//
-// questions? send me a mail at m.somers at chem.leidenuniv.nl
-//
-// Example work unit template:
-//
-// <file_info>
-//   <number> 0 </number>
-// </file_info>
-//
-// <workunit>
-//   <file_ref>
-//     <file_number> 0 </file_number>
-//     <open_name> classical.in </open_name>
-//   </file_ref>
-//
-//   <command_line> classical.in classical.out classical.stdout </command_line>
-//   <min_quorum> 2 </min_quorum>
-//   <target_nresults> 2 </target_nresults>
-//   <max_error_results> 16 </max_error_results>
-//   <max_total_results> 16 </max_total_results>
-//   <max_success_results> 8 </max_success_results>
-//   <delay_bound> 43200 </delay_bound>
-// </workunit>
-//
-//
-// Example result template:
-//
-// <file_info>
-//  <name> <OUTFILE_0/> </name>
-//  <max_nbytes> 536870912 </max_nbytes>
-//  <url> <UPLOAD_URL/> </url>
-//  <generated_locally/>
-//  <queue_tag/>
-//  <upload_when_present/>
-// </file_info>
-//
-// <file_info>
-//  <name> <OUTFILE_1/> </name>
-//  <max_nbytes> 536870912 </max_nbytes>
-//  <url> <UPLOAD_URL/> </url>
-//  <generated_locally/>
-//  <queue_tag/>
-//  <upload_when_present/>
-// </file_info>
-//
-// <result>
-//  <file_ref>
-//    <file_name> <OUTFILE_0/> </file_name>
-//    <open_name> classical.out </open_name>
-//  </file_ref>
-//  <file_ref>
-//    <file_name> <OUTFILE_1/> </file_name>
-//    <open_name> classical.stdout </open_name>
-//  </file_ref>
-// </result>
-//
-//
-
diff --git a/html/queue/create_queue.sql b/html/queue/create_queue.sql
deleted file mode 100644
index d6d02b8..0000000
--- a/html/queue/create_queue.sql
+++ /dev/null
@@ -1,20 +0,0 @@
-CREATE TABLE q_list (
-    id          integer NOT NULL auto_increment,
-    user        integer NOT NULL default '0',
-    workunit    integer NOT NULL default '0',
-    PRIMARY KEY  (id)
-) TYPE=MyISAM;
-
-CREATE TABLE q_restricted_apps (
-    id          integer NOT NULL auto_increment,
-    appid       integer NOT NULL default '0',
-    PRIMARY KEY  (id)
-) TYPE=MyISAM;
-
-CREATE TABLE q_users (
-    id          integer NOT NULL auto_increment,
-    user        integer NOT NULL default '0',
-    app         integer NOT NULL default '0',
-    qmax        integer NOT NULL default '0',
-    PRIMARY KEY  (id)
-) TYPE=MyISAM;
diff --git a/html/queue/inc/queue.inc b/html/queue/inc/queue.inc
deleted file mode 100644
index d54cc76..0000000
--- a/html/queue/inc/queue.inc
+++ /dev/null
@@ -1,145 +0,0 @@
-<?php
-
-require_once("../inc/db.inc");
-require_once("../inc/util.inc");
-require_once("../inc/prefs.inc");
-
-function all_jobs_of_user( $user )
-{
- $alljobs = mysql_query( "SELECT * FROM q_list WHERE user=".$user -> id );
- return $alljobs;
-}
-
-function nr_of_jobs_of_user( $user )
-{
- $njobs = mysql_num_rows( all_jobs_of_user( $user ) );
- return $njobs;
-}
-
-function workunit_name( $workunit )
-{
- if( ( $pos = strpos( $workunit -> name, "_queue" ) ) === false )
-  $workunitname = $workunit -> name;
- else
-  $workunitname = substr( $workunit -> name, 0, $pos );
- return $workunitname;
-}
-
-function workunit_status_string( $workunit )
-{
- $status = "UNKNOWN";
- if( $workunit -> canonical_resultid )
-  $status = "finished";
- else
- {
-  if( $workunit -> hr_class )
-   $status = "running";
-  else
-   $status = "queued";
- }
- if( $workunit -> error_mask )
- {
-  $status = "ERROR";
-  if( $workunit -> error_mask & 16 )
-   $status = "CANCELED";
- }
- return $status;
-}
-
-function max_nr_of_jobs_of_user( $user )
-{
- $allapps = mysql_query( "SELECT * FROM q_users WHERE user=".$user -> id );
- $napps   = mysql_num_rows( $allapps );
-
- if( $napps > 0 ) 
-  for( $count = $index = 0; $index < $napps; ++$index )
-  {
-   $row = mysql_fetch_object( $allapps );
-   if( $row )
-    $count += $row -> qmax;
-  }
- else
-  $count = 5;
-
- mysql_free_result( $allapps );
- return $count;
-}
-
-function nr_of_jobs_for_user_for_app( $user, $app )
-{
- $qmaxresult = mysql_query( "SELECT qmax FROM q_users WHERE user=".$user -> id." AND app=".$app -> id );
- if( mysql_num_rows( $qmaxresult ) < 1 )
- {
-  $qrestrictedapps = mysql_query( "SELECT * FROM q_restricted_apps WHERE appid=".$app -> id );
-  if( mysql_num_rows( $qrestrictedapps ) < 1 )
-   $nr = 5;
-  else
-   $nr = 0;
-  mysql_free_result( $qrestrictedapps );
- }
- else
- {
-  $object = mysql_fetch_object( $qmaxresult );
-  $nr = $object -> qmax;
- }
- mysql_free_result( $qmaxresult );
- return $nr; 
-}
-
-function nr_of_submitted_jobs_for_user_for_app( $user, $app )
-{
- $alljobs = mysql_query( "SELECT * FROM q_list WHERE user=".$user -> id );
- $nrofjobs = mysql_num_rows( $alljobs );
-
- for( $nr = $index = 0; $index < $nrofjobs; ++$index )
- {
-  $job = mysql_fetch_object( $alljobs );
-  $workunit = mysql_fetch_object( mysql_query( "SELECT * FROM workunit WHERE id=".$job -> workunit ) );
-
-  if( $workunit -> appid == $app -> id )
-   $nr = $nr + 1;
- }
-
- mysql_free_result( $alljobs );
- return $nr;
-}
-
-function exit_with_text( $text )
-{
- start_table();
- row1( "<font color='red'><b>".$text."</b></font>" );
- row1( "Commands" );
- row2( "", '<a href="queue_show_queue.php">Go back to your queue</a>' );
- row2( "", '<a href="logout.php">Log out</a>' );
- end_table();
- page_tail();
- exit;
-}
-
-function fan_out_dir( $filename, $fanoutnr )
-{
- $dir = dechex( hexdec( substr( md5( $filename ), 1, 7 ) ) % $fanoutnr );
- return $dir; 
-}
-
-function row5($xx, $xy, $yx, $yy, $zz ) {
-    echo "<tr><td width=20% valign=top>$xx</td><td width=20%>$xy</td>"
-        . "<td width=20% >$yx</td><td width=%20>$yy</td><td width=20%>$zz</td></tr>
-    ";
-}
-
-function row6($xx, $xy, $yx, $yy, $zz, $xz ) {
-    echo "<tr><td width=15% valign=top>$xx</td><td width=15%>$xy</td>"
-        . "<td width=15% >$yx</td><td width=%15>$yy</td><td width=15%>$zz</td>"
-        . "<td width=15%>$xz</td></tr>";
-}
-
-function remove_tags( $xml, $tag )
-{
- $newxml = $xml;
- while( ( $pos = strpos( $newxml, $tag ) ) !== false )
-  $newxml = substr( $newxml, 0, $pos ).substr( $newxml, $pos + strlen( $tag ) ); 
- return $newxml;
-}
-
-?>
diff --git a/html/queue/inc/user.inc b/html/queue/inc/user.inc
deleted file mode 100644
index 57c5b16..0000000
--- a/html/queue/inc/user.inc
+++ /dev/null
@@ -1,364 +0,0 @@
-<?php
-
-require_once("../inc/credit.inc");
-require_once("../inc/email.inc");
-require_once("../inc/util.inc");
-
-function parse_project($f) {
-    $p->total_credit = 0.0;
-    $p->expavg_credit = 0.0;
-    while (!feof($f)) {
-        $buf = fgets($f);
-        if (strstr($buf, "</project>")) break;
-        if ($x = parse_element($buf, "<name>")) {
-            $p->name = $x;
-        }
-        if ($x = parse_element($buf, "<name>")) {
-            $p->name = $x;
-        }
-        if ($x = parse_element($buf, "<url>")) {
-            $p->url = $x;
-        }
-        if ($x = parse_element($buf, "<total_credit>")) {
-            $p->total_credit = $x;
-        }
-        if ($x = parse_element($buf, "<expavg_credit>")) {
-            $p->expavg_credit = $x;
-        }
-        if ($x = parse_element($buf, "<id>")) {
-            $p->id = $x;
-        }
-        if ($x = parse_element($buf, "<country>")) {
-            $p->country = $x;
-        }
-        if ($x = parse_element($buf, "<team_id>")) {
-            $p->team_id = $x;
-        }
-        if ($x = parse_element($buf, "<team_name>")) {
-            $p->team_name = $x;
-        }
-        if ($x = parse_element($buf, "<create_time>")) {
-            $p->create_time = $x;
-        }
-    }
-    return $p;
-}
-
-function parse_user($f, $user) {
-    $user->projects = array();
-    while (!feof($f)) {
-        $buf = fgets($f);
-        if (strstr($buf, "</user>")) break;
-        if (strstr($buf, "<project>")) {
-            $user->projects[] = parse_project($f);
-        }
-    }
-    return $user;
-}
-
-function get_other_projects($user) {
-    $cpid = md5($user->cross_project_id . $user->email_addr);
-    $url = "http://boinc.netsoft-online.com/get_user.php?cpid=$cpid";
-    $f = fopen($url, "r");
-    if (!$f) {
-        return $user;
-    }
-    $u = parse_user($f, $user);
-    fclose($f);
-    return $u;
-}
-
-function show_project($project) {
-    if ($project->url == "http://www.worldcommunitygrid.org/") {
-        $x = $project->name;
-    } else {
-        $x = "<a href=\"$project->url"."show_user.php?userid=$project->id\">$project->name</a>";
-    }
-    echo "<tr>
-        <td>$x</td>
-        <td align=right>".number_format($project->total_credit, 0)."</td>
-        <td align=right>".number_format($project->expavg_credit, 0)."</td>
-        <td align=right>".date_str($project->create_time)."</td>
-        </tr>
-    ";
-}
-
-function cmp($a, $b) {
-    if ($a->expavg_credit == $b->expavg_credit) return 0;
-    return ($a->expavg_credit < $b->expavg_credit)? 1 : -1;
-}
-
-function show_other_projects($user, $personal) {
-    if (count($user->projects) > 1) {
-        usort($user->projects, "cmp");
-        if ($personal) {
-            echo "<h3>Projects in which you are participating</h3>";
-        } else {
-            echo "<h3>Projects in which $user->name is participating</h3>";
-        }
-        start_table();
-        row_heading_array(array(
-            "Project<br><span class=note>Click for user page</span>", "Total credit", "Average credit", "Since"
-        ));
-        foreach($user->projects as $project) {
-            show_project($project);
-        }
-        end_table();
-    }
-}
-
-function pending_credit($user) {
-    $result = mysql_query("select sum(claimed_credit) as total from result where userid=$user->id and (validate_state=0 or validate_state=4)");
-    $foobar = mysql_fetch_object($result);
-    if (!$foobar) return 0;
-    mysql_free_result($result);
-    return $foobar->total;
-}
-
-function total_posts($user) {
-    $result = mysql_query(
-        "select count(id) as total from post where user=$user->id"
-    );
-    if (!$result) return 0;
-    $foobar = mysql_fetch_object($result);
-    mysql_free_result($result);
-    return $foobar->total;
-}
-
-function show_credit($user) {
-    row2(tr(TOTAL_CREDIT), format_credit($user->total_credit));
-    row2(tr(EXPAVG_CREDIT), format_credit($user->expavg_credit));
-    project_user_credit($user);
-}
-
-require_once("../inc/stats_sites.inc");
-// show dynamic user info (private)
-//
-function show_user_stats_private($user) {
-    global $cpid_stats_sites;
-    row1("Work done");
-    row2(PROJECT." member since", date_str($user->create_time));
-    show_credit($user);
-    $config = get_config();
-    if (parse_bool($config, "show_results")) {
-        row2("Pending credit", "<a href=pending.php>View</a>");
-    }
-    row2("Computers on this account",
-        "<a href=hosts_user.php>View</a>"
-    );
-    row2("Results", "<a href=results.php?userid=$user->id>View</a>");
-    $cpid = md5($user->cross_project_id . $user->email_addr);
-    $x = "";
-    shuffle($cpid_stats_sites);
-    foreach ($cpid_stats_sites as $site) {
-        $name = $site[0];
-        $y = sprintf($site[1], $cpid);
-        $x .= "<a href=$y>$name</a><br>";
-    }
-    $x .= "<br><font size=-2>Cross-project ID: $cpid</font>\n";
-    row2("Cross-project statistics", $x);
-    row2("Stats on your cell phone", URL_BASE."userw.php?id=$user->id");
-    row2("Account number<br><font size=-2>Used in URLs</font>", $user->id);
-}
-
-// show static user info (private)
-//
-function show_user_info_private($user) {
-    if (is_valid_email_addr($user->email_addr)) {
-        $email_text = $user->email_addr;
-    } else {
-        $email_text = "Verification pending";
-    }
-
-    row1("Account information");
-    row2("Email address<br>", $email_text);
-    row2("Name", $user->name);
-    if (strlen($user->url)) {
-        $x = "http://$user->url";
-    } else {
-        $x = "none";
-    }
-    row2("URL", $x);
-    row2("Country", $user->country);
-    row2("Postal code", $user->postal_code);
-    row2("Change", "<a href=edit_email_form.php>email address</a> | <a href=edit_passwd_form.php>password</a> | <a href=edit_user_info_form.php>other account info</a>");
-    row2("", "<a href=queue_show_queue.php>Show private queue</a>");
-    row2("", "<a href=logout.php?".url_tokens($user->authenticator).">Log out</a>");
-
-    row1("Community");
-
-    $sql = "SELECT * FROM profile WHERE userid = ".$user->id;
-    $result = mysql_query($sql);
-    if (mysql_num_rows($result) != 0) {
-        $x = "<a href=view_profile.php?userid=$user->id>View or edit</a> | <a href=delete_profile.php>Delete</a>";
-    } else {
-        $x = "<a href=create_profile.php>Create</a>";
-    }
-    row2("Profile", $x);
-    $tot = total_posts($user);
-    if ($tot) {
-        row2("Message boards", "<a href=".URL_BASE."forum_user_posts.php?userid=$user->id>$tot posts</a>");
-    }
-    
-    row2("Private messages", pm_notification($user));
-
-    row1("Teams");
-    if ($user->teamid) {
-        $team = lookup_team($user->teamid);
-        $x = "<a href=team_display.php?teamid=$team->id>$team->name</a>
-            | <a href=team_quit_form.php>Quit team</a>";
-        if ($team->userid == $user->id) {
-            $x .= " | <a href=team_manage.php>management functions</a>";
-        }
-        row2("Team", $x);
-    } else {
-        row2("Team", "None (<a href=team.php>find a team</a>)");
-    }
-    
-    $team_founder = lookup_team_founder($user->id);
-    if ($team_founder) {
-        while ($res = mysql_fetch_object($team_founder)) {
-            if ($res->id != $user->teamid) {
-                row2("founder of", "<a href=team_display.php?teamid=$res->id>$res->name</a> | <a href=\"team_change_founder_form.php?teamid=".$res->id."\">Change team founder</a>");
-            }
-        }
-    }
-
-    row1("<a name=prefs>Preferences");
-    row2(
-        "General preferences<br><font size=-2>specify when and how BOINC uses your computer</font>",
-        "<a href=prefs.php?subset=global>View or edit</a>"
-    );
-    row2(PROJECT." preferences<br><font size=-2>control resource share and customize graphics</font>",
-        "<a href=prefs.php?subset=project>View or edit</a>"
-    );
-    row2("Message board preferences<br><font size=-2>configure features and appearance of message boards</font>",
-        "<a href=\"edit_forum_preferences_form.php\">View or edit</a>"
-    );
-}
-
-// show summary of dynamic and static info (public)
-//
-function show_user_summary_public($user) {
-    row2(PROJECT." member since", date_str($user->create_time));
-    row2("Country", $user->country);
-    if (strlen($user->url)) {
-        row2("URL", "<a href=\"http://$user->url\">http://$user->url</a>");
-    }
-    show_credit($user);
-
-    if ($user->teamid && ($team = lookup_team($user->teamid))) {
-        row2("Team", "<a href=\"".URL_BASE."team_display.php?teamid=$team->id\">$team->name</a>");
-    } else {
-        row2("Team", "None");
-    }
-    if ($user->show_hosts) {
-        row2("Computers", "<a href=\"".URL_BASE."hosts_user.php?userid=$user->id\">View</a>");
-    } else {
-        row2("Computers", "hidden");
-    }
-    $tot = total_posts($user);
-    if ($tot) {
-        row2("Message boards", "<a href=\"".URL_BASE."forum_user_posts.php?userid=$user->id\">$tot posts</a>");
-    }
-
-    if ($user->donated == 1) { 
-        if (file_exists("../project/donations.inc")) {
-            require_once("../project/donations.inc");
-            $x .= DONATION_LINK;
-            row2("Donor",$x);
-        }
-    }
-    
-    row2("Contact", "<a href=\"forum_pm.php?action=new&userid=".$user->id."\">Send private message</a>");
-}
-
-function show_profile_link($user) {
-    if ($user->has_profile) {
-        row2("Profile", "<a href=\"view_profile.php?userid=$user->id\">View</a>");
-    }
-}
-
-// show a summary of the user.
-// NOTE: This is intended to be shown only to that user.
-// it has info that other users aren't supposed to see
-
-function show_user_page_private($user) {
-    $config = get_config();
-    start_table("width=100%");
-    show_user_info_private($user);
-    show_user_stats_private($user);
-
-    // Does this project accept donations? Then put in a project specific
-    // function to show user donation information in ../project/donations.inc
-    //
-    if (parse_bool($config, "donations_accepted")) {
-        if (file_exists("../project/donations.inc")) {
-            require_once("../project/donations.inc");
-            show_user_donations_private($user);
-        }
-    }
-    end_table();
-}
-
-function user_table_start($sort_by) {
-    start_table();
-    echo "
-        <tr>
-        <th>".tr(USER_TABLE_RANK)."</th>
-        <th>".tr(USER_TABLE_NAME)."</th>
-    ";
-    if ($sort_by == "total_credit") {
-        echo "
-            <th><a href=top_users.php?sort_by=expavg_credit>".tr(EXPAVG_CREDIT)."</a></th>
-            <th>".tr(TOTAL_CREDIT)."</th>
-        ";
-    } else {
-        echo "
-            <th>".tr(EXPAVG_CREDIT)."</th>
-            <th><a href=top_users.php?sort_by=total_credit>".tr(TOTAL_CREDIT)."</a></th>
-        ";
-    }
-    echo "
-        <th>".tr(USER_TABLE_COUNTRY)."</th>
-        <th>".tr(USER_TABLE_PTIME)."</th>
-        </tr>
-    ";
-}
-
-function show_user_row($user, $i) {
-    echo "
-        <tr class=row1>
-        <td>$i</td>
-        <td>", user_links($user), "</td>
-        <td>", format_credit($user->expavg_credit), "</td>
-        <td>", format_credit($user->total_credit), "</td>
-        <td>", $user->country, "</td>
-        <td>", time_str($user->create_time),"</td>
-        </tr>
-    ";
-}
-
-// decay a user's average credit
-//
-function user_decay_credit($user) {
-    $avg = $user->expavg_credit;
-    $avg_time = $user->expavg_time;
-    $now = time(0);
-    update_average($now, 0, 0, $avg, $avg_time);
-    mysql_query("update user set expavg_credit=$avg, expavg_time=$now where id=$user->id");
-
-}
-// if the user hasn't received new credit for ndays,
-// decay its average and return true
-//
-function user_inactive_ndays($user, $ndays) {
-    $diff = time() - $user->expavg_time;
-    if ($diff > $ndays*86400) {
-        user_decay_credit($user);
-        return true;
-    }
-    return false;
-}
-
-?>
diff --git a/html/queue/ops/ops_queue_remove_job.php b/html/queue/ops/ops_queue_remove_job.php
deleted file mode 100644
index 74fa44c..0000000
--- a/html/queue/ops/ops_queue_remove_job.php
+++ /dev/null
@@ -1,52 +0,0 @@
-<?php
-
-include_once( "../inc/db.inc" );
-include_once( "../inc/util.inc" );
-include_once( "../inc/db_ops.inc" );
-include_once( "../inc/util_ops.inc" );
-include_once( "../inc/prefs.inc" );
-include_once( "../inc/queue.inc" );
-
-$timestr = time_str(time(0));
-
-db_init();
-
-$workunitid  = get_int( 'workunitid' );
-
-$workunit    = mysql_fetch_object( mysql_query( "SELECT * FROM workunit WHERE id=".$workunitid ) );
-$job         = mysql_fetch_object( mysql_query( "SELECT * FROM q_list WHERE workunit=".$workunit->id ) );
-$user        = mysql_fetch_object( mysql_query( "SELECT * FROM user WHERE id=".$job -> user ) );
-$title       = "Deleting job '".workunit_name( $workunit )."' (".$workunitid.") of ".$user -> name." at ".$timestr;
-
-$jobname      = workunit_name( $workunit );
-
-$config = get_config();
-
-$jobstatusstring = workunit_status_string( $workunit );
-$jobsubmittime   = time_str( $workunit -> create_time );
-
-admin_page_head( $title );
-start_table();
-row1( "Job speciffics" );
-row2( "Job submit time: ", $jobsubmittime );
-row2( "Job name: ", $jobname );
-row2( "Old job status: ", $jobstatusstring );
-
-$query = "UPDATE result SET server_state=5,outcome=5 WHERE server_state=2 AND workunitid=".$workunit -> id;
-mysql_query( $query );
-
-$query = "UPDATE workunit SET error_mask=error_mask|16,transition_time=".time(0).",batch=0 WHERE id=".$workunit -> id;
-mysql_query( $query );
-
-$query = "DELETE FROM q_list WHERE id=".$job -> id;
-mysql_query( $query );
-
-row2( "New job status: ", "deleted" );
-
-row1( "Commands" );
-row2( "", '<a href="queue_show_queue.php">Go back to queue</a>' );
-
-end_table();
-admin_page_tail();
-
-?>
diff --git a/html/queue/ops/ops_queue_show_job.php b/html/queue/ops/ops_queue_show_job.php
deleted file mode 100644
index 57201f3..0000000
--- a/html/queue/ops/ops_queue_show_job.php
+++ /dev/null
@@ -1,126 +0,0 @@
-<?php
-
-include_once( "../inc/db.inc" );
-include_once( "../inc/util.inc" );
-include_once( "../inc/db_ops.inc" );
-include_once( "../inc/util_ops.inc" );
-include_once( "../inc/prefs.inc" );
-include_once( "../inc/queue.inc" );
-
-$timestr = time_str(time(0));
-
-db_init();
-
-$workunitid  = get_int( 'workunitid' );
-
-$workunit    = mysql_fetch_object( mysql_query( "SELECT * FROM workunit WHERE id=".$workunitid ) );
-$job         = mysql_fetch_object( mysql_query( "SELECT * FROM q_list WHERE workunit=".$workunit->id ) );
-$user        = mysql_fetch_object( mysql_query( "SELECT * FROM user WHERE id=".$job -> user ) );
-$title       = "Job '".workunit_name( $workunit )."' (".$workunitid.") of ".$user -> name." at ".$timestr;
-
-$jobname      = workunit_name( $workunit );
-
-$config = get_config();
-
-$jobapplication = mysql_fetch_object( mysql_query( "SELECT * FROM app WHERE id=".$workunit -> appid ) );
-$jobapplicationname = $jobapplication -> name;
-$jobapplicationfriendlyname = $jobapplication -> user_friendly_name;
-$jobfops = $workunit -> rsc_fpops_est;
-$jobmem = $workunit -> rsc_memory_bound;
-$jobdisk = $workunit -> rsc_disk_bound;
-$jobstatusstring = workunit_status_string( $workunit );
-
-$coloredjobstatusstring = $jobstatusstring;
-if( $jobstatusstring == "running" ) $coloredjobstatusstring = "<font color='green'><b>".$jobstatusstring."</b></font>";
-if( $jobstatusstring == "queued" ) $coloredjobstatusstring = "<font color='blue'><b>".$jobstatusstring."</b></font>";
-if( $jobstatusstring == "ERROR" ) $coloredjobstatusstring = "<font color='red'><b>".$jobstatusstring."</b></font>";
-
-$jobsubmittime = time_str( $workunit -> create_time );
-
-$workunitidstring = "<a href=db_action.php?table=workunit&id=".$job -> workunit.">".$job -> workunit."</a>";
-
-$jobinputurl = parse_element( $workunit -> xml_doc, "<file_info>" );
-$jobinputurl = parse_element( $jobinputurl, "<url>" );
-$jobinput = parse_element( $workunit -> xml_doc, "<file_info>" );
-$jobinput = parse_element( $jobinput, "<name>" );
-
-admin_page_head( $title );
-start_table();
-
-row1( "Job speciffics" );
-row2( "Job status: ", $coloredjobstatusstring );
-row2( "Job application: ", $jobapplicationfriendlyname );
-row2( "Job submit time: ", $jobsubmittime );
-row2( "Job name: ", $jobname );
-row2( "Job id: ", $workunitidstring );
-row2( "Job estimated time to complete: ", floor((float)($jobfops)/92254963740)." min. " );
-row2( "Job estimated memory usage: ", floor((float)($jobmem)/1048576)." Mb. " );
-row2( "Job estimated disk usage: ", floor((float)($jobdisk)/1048576)." Mb. " );
-row2( "Job input file:", '<a href="'.$jobinputurl.'"> '.$jobinput.'</a>' );
-
-if( ( $jobstatusstring == "finished" ) || ( $jobstatusstring == "ERROR" ) )
-{
- if( $jobstatusstring != "finished" )
- {
-  $resultunitquery = mysql_query( "SELECT * FROM result WHERE workunitid=".$workunit -> id );
-  $nrofresults = mysql_num_rows( $resultunitquery );
-
-  for( $index = 0; $index < $nrofresults; ++$index )
-  {
-   $resultunit = mysql_fetch_object( $resultunitquery );
-
-   $jobstderr = parse_element( $resultunit -> stderr_out, "<stderr_txt>" );
-
-   if( $jobstderr )
-   {
-    row1( "Error output of this job" );
-    row2( "", $jobstderr );
-   }
-  }
- }
- else
- {
-  $resultunit = mysql_fetch_object( mysql_query( "SELECT * FROM result WHERE id=".$workunit -> canonical_resultid ) );
-
-  $xmldoc = $resultunit -> xml_doc_out;
-
-  $nroffiles = 0;
-  $cursor = 0;
-  while( $tempfileinfo = parse_next_element( $xmldoc, "<file_info>", &$cursor ) )
-   $outputfiles[ $nroffiles++ ] = parse_element( $tempfileinfo, "<name>" );
-
-  if( $nroffiles >= 1 )
-  {
-   $fanoutnr = parse_config( $config, "<uldl_dir_fanout>" );
-   row1( "Output of this job" );
-   row2( "Number of output files of job: ", $nroffiles );
-   for( $index = 0; $index < $nroffiles; ++$index )
-   { 
-    $filename = $outputfiles[ $index ];
-    $url = "upload/".fan_out_dir( $filename, $fanoutnr )."/".$filename;
-    $outputfilelink = '<a href="'.$url.'">'.$filename.'</a>';
-    row2( "Output file ".($index+1).": ", $outputfilelink );
-   }
-  }
-
-  $jobstderr = parse_element( $resultunit -> stderr_out, "<stderr_txt>" );
-
-  if( $jobstderr )
-  {
-   row1( "Error output of this job" );
-   row2( "", $jobstderr );
-  }
- }
-}
-
-$max_jobs = max_nr_of_jobs_of_user( $user );
-$njobs = nr_of_jobs_of_user( $user );
-
-row1( "Commands" );
-row2( "", '<a href="queue_remove_job.php?workunitid='.$workunit -> id.'">Kill or Remove this job</a>' );
-row2( "", '<a href="queue_show_queue.php">Go back to queue</a>' );
-
-end_table();
-
-admin_page_tail();
-?>
diff --git a/html/queue/ops/ops_queue_show_queue.php b/html/queue/ops/ops_queue_show_queue.php
deleted file mode 100644
index 8f35d4d..0000000
--- a/html/queue/ops/ops_queue_show_queue.php
+++ /dev/null
@@ -1,71 +0,0 @@
-<?php
-
-include_once( "../inc/db.inc" );
-include_once( "../inc/util.inc" );
-include_once( "../inc/db_ops.inc" );
-include_once( "../inc/util_ops.inc" );
-include_once( "../inc/prefs.inc" );
-include_once( "../inc/queue.inc" );
-
-db_init();
-
-$timestr = time_str(time(0));
-$title = "Job list at ".$timestr;
-
-admin_page_head( $title );
-
-$alljobs = mysql_query( "SELECT * FROM workunit WHERE name LIKE '%queue%'" );
-$njobs   = mysql_num_rows( $alljobs );
-
-start_table();
-
-if( $njobs ) 
-{
- if( $njobs > 1 )
-  row1( "There are ".$njobs." jobs listed !<br>" );
- else
-  row1( "There is only one job listed !<br>" );
-
- end_table();
- start_table();
-
- row6( "<b>Job #</b>", "<b>User</b>", "<b>Job submit time</b>", "<b>Job status</b>", "<b>Job name</b>", "<b>Job ID</b>" );
-
- for( $jobindex = 0; $jobindex < $njobs; ++$jobindex )
- {
-  $workunit = mysql_fetch_object( $alljobs );
-
-  $prefix = '<a href="queue_show_job.php?workunitid='.$workunit -> id.'">';
-  $workunitname = $prefix.workunit_name( $workunit ).'</a>';
-  $workunitidstr = "<a href='db_action.php?table=workunit&id=".$workunit -> id."'>".$workunit -> id."</a>";
-  $status = workunit_status_string( $workunit );
-  $jobsubmittime = time_str( $workunit -> create_time );
-
-  if( $status != "CANCELED" )
-  {
-   if( $status == "running" ) $status = "<font color='green'><b>".$status."</b></font>";
-   if( $status == "queued" ) $status = "<font color='blue'><b>".$status."</b></font>";
-
-   $job = mysql_fetch_object( mysql_query( "SELECT * FROM q_list WHERE workunit=".$workunit->id ) );
-   $user = mysql_fetch_object( mysql_query( "SELECT * FROM user WHERE id=".$job -> user ) );
-   $jobusername = "<a href='db_action.php?table=user&id=".$user -> id."'>".$user -> name."</a>";
-  }
-  else
-  {
-   $jobusername = "<font color='red'><b>UNKNOWN</b></font>";
-   $status = "<font color='red'><b>CANCELED</b></font>";
-   $workunitname = workunit_name( $workunit );
-  }
-
-  row6( $jobindex+1, $jobusername, $jobsubmittime, $status, $workunitname, $workunitidstr );
- }
-
-}
-else
- row1("There are NO jobs listed !<br>");
-
-end_table();
-
-admin_page_tail();
-
-?>
diff --git a/html/queue/user/queue_new_job_form.php b/html/queue/user/queue_new_job_form.php
deleted file mode 100644
index a7c91fd..0000000
--- a/html/queue/user/queue_new_job_form.php
+++ /dev/null
@@ -1,95 +0,0 @@
-<?php
-
-include_once( "../inc/db.inc" );
-include_once( "../inc/util.inc" );
-include_once( "../inc/prefs.inc" );
-include_once( "../inc/queue.inc" );
-
-db_init();
-
-$user        = get_logged_in_user();
-$timestr     = time_str(time(0));
-$title       = "New job for ".$user -> name." at ".$timestr;
-
-page_head( $title );
-
-$appresult = mysql_query( "SELECT * FROM app" );
-$nrofapps = mysql_num_rows( $appresult );
-
-if( $nrofapps )
-{
-
- $selection = "";
- for( $appindex = 0; $appindex < $nrofapps; ++$appindex )
- {
-  $app = mysql_fetch_object( $appresult );
-
-  $appqmax = nr_of_jobs_for_user_for_app( $user, $app );
-  $appsubmitted = nr_of_submitted_jobs_for_user_for_app( $user, $app );
-
-  if( $appqmax > $appsubmitted )
-   $selection = $selection.'<option value="'.$app -> id.'">'.$app -> user_friendly_name.'</option>';
- }
-
- if( $selection != "" )
- {
-
-  echo '<form action="queue_new_job_form_action.php" method="POST">';
-  start_table();
-
-  row1( "New job speciffics" );
-  $selection = "<select name=\"application\">".$selection."</select>";
-  row2( "Application: ", $selection );
-  row2( "Name of job (no spaces, quotes or slashes): ", '<input type="text" size="65" name="name" value="" maxlength="128" >' );
-  row2( "Input: ", '<textarea wrap="off" rows="20" cols="74" name="input"></textarea>' );
-
-  // These numbers have been based on running our app on our pool of 10000 desktops at that time
-  // for about 10000 WU's. For each successfull result the 'cpu_time' was multiplied with the hosts
-  // 'p_fpops' to get an estimate for the WU number of fops (which sould be fairly constant). This
-  // number was the devided by the average of all hosts 'cpu_time'. If your pool is bigger/different
-  // you might check these numbers first with your app, but they should be fairly okay...
-
-  $selection = '<option value="461274818700"> 5 min. </option>';
-  $selection .= '<option value="1383824456100"> 15 min. </option>';
-  $selection .= '<option value="2767648912200"> 30 min. </option>';
-  $selection .= '<option value="5535297824400"> 1 h. </option>';
-  $selection .= '<option value="16605893473200"> 3 h. </option>';
-  $selection .= '<option value="33211786946400"> 6 h. </option>';
-  $selection = "<select name=\"fops\">".$selection."</select>";
-  row2( "Estimated time to completion: ", $selection );
-
-  $selection = '<option value="2097152"> 2 Mb. </option>';
-  $selection .= '<option value="4194304"> 4 Mb. </option>';
-  $selection .= '<option value="16777216"> 16 Mb. </option>';
-  $selection .= '<option value="67108864"> 64 Mb. </option>';
-  $selection .= '<option value="134217728"> 128 Mb. </option>';
-  $selection = "<select name=\"mem\">".$selection."</select>";
-  row2( "Estimated memory usage: ", $selection );
-  
-  $selection = '<option value="2097152"> 2 Mb. </option>';
-  $selection .= '<option value="4194304"> 4 Mb. </option>';
-  $selection .= '<option value="16777216"> 16 Mb. </option>';
-  $selection .= '<option value="67108864"> 64 Mb. </option>';
-  $selection .= '<option value="134217728"> 128 Mb. </option>';
-  $selection .= '<option value="536870912"> 512 Mb. </option>';
-  $selection = "<select name=\"disk\">".$selection."</select>";
-  row2( "Estimated disk usage: ", $selection );
-
-  row2( "", '<input type="submit" value="     Submit Job     ">' );
-
-  row1( "Commands" );
-  row2( "", '<a href="queue_show_queue.php">Go back to your queue</a>' );
-  row2( "", '<a href="logout.php">Log out</a>' );
-
-  end_table();
-  echo '</form>';
-
- }
- else
-  exit_with_text( "You are not allowed to submit any jobs !" );
-
-}
-
-page_tail(); 
-
-?>
diff --git a/html/queue/user/queue_new_job_form_action.php b/html/queue/user/queue_new_job_form_action.php
deleted file mode 100644
index 16be833..0000000
--- a/html/queue/user/queue_new_job_form_action.php
+++ /dev/null
@@ -1,158 +0,0 @@
-<?php
-
-include_once( "../inc/db.inc" );
-include_once( "../inc/util.inc" );
-include_once( "../inc/prefs.inc" );
-include_once( "../inc/queue.inc" );
-
-db_init();
-
-$timestr           = time_str(time(0));
-
-$jobapplication    = post_int( 'application' ); 
-$jobname           = escapeshellarg( $_POST[ 'name' ] );
-$jobinput          = post_str( 'input' );
-$jobfops           = post_int( 'fops' );
-$jobdisk           = post_int( 'disk' );
-$jobmem            = post_int( 'mem' );
-
-if( get_magic_quotes_gpc() )
- $jobinput = stripslashes( $jobinput );
-
-$config = get_config();
-$name   = parse_config( $config, "<long_name>" );
-$user   = get_logged_in_user();
-
-$jobapplicationname = mysql_fetch_object( mysql_query( "SELECT * FROM app WHERE id=".$jobapplication ) );
-$app = $jobapplicationname;
-$jobapplicationfriendlyname = $jobapplicationname -> user_friendly_name;
-$jobapplicationname = $jobapplicationname -> name;
-
-$title       = "New job for '".$jobname."' ".$user -> name." at ".$timestr;
-page_head( $title );
-
-start_table();
-row1( "Job speciffics" );
-row2( "Job application: ", $jobapplicationfriendlyname );
-row2( "Job name: ", $jobname );
-row2( "Job estimated time to complete: ", floor( ( float )( $jobfops ) / 92254963740 )." min. " );
-row2( "Job estimated memory usage: ", floor( ( float )( $jobmem ) / 1048576 )." Mb. " );
-row2( "Job estimated disk usage: ", floor( ( float )( $jobdisk ) / 1048576 )." Mb. " );
-row2( "Job input:", '<textarea wrap="off" rows="20" cols="74">'.$jobinput.'</textarea>' );
-end_table();
-
-if( ( $jobname == "" ) || strpos( $jobname, "queue" ) || strpos( $jobname, " " ) || 
-    strpos( $jobname, '"' ) || strpos( $jobname, "'" ) || strpos( $jobname, "`" ) || 
-    strpos( $jobname, "\\" ) )
- exit_with_text( "The job name is invalid !" );
-
-if( $jobinput == "" )
- exit_with_text( "There was no input !" );
-
-$appqmax = nr_of_jobs_for_user_for_app( $user, $app );
-$appsubmitted = nr_of_submitted_jobs_for_user_for_app( $user, $app );
-if( $appqmax <= $appsubmitted )
- exit_with_text( "Job limit would be exceeded!" );
-
-$bin_dir = parse_config( $config, "<bin_dir>" );
-$download_dir = parse_config( $config, "<download_dir>" );
-$upload_dir = parse_config( $config, "<upload_dir>" );
-$template_dir = parse_config( $config, "<template_dir>" );
-$config_dir = parse_config( $config, "<project_dir>" );
-$createworkprogram = parse_config( $config, "<create_work_program>" );
-
-$extendedjobname = $jobname."_queue_".$jobapplication."_".time(0)."_".random_string();
-$extendedjobname = escapeshellcmd( $extendedjobname );
-
-$wu_template = $template_dir."/queue_".$jobapplicationname."_work_unit_template";
-$result_template = $template_dir."/queue_".$jobapplicationname."_result_unit_template";
-$temporaryinputfile = $extendedjobname;
-
-$command_to_submit = $bin_dir."/".$createworkprogram;
-$command_to_submit .= " -config_dir ".$config_dir;
-$command_to_submit .= " -appname ".$jobapplicationname;
-$command_to_submit .= " -wu_name ".$extendedjobname;
-$command_to_submit .= " -wu_template ".$wu_template;
-$command_to_submit .= " -result_template ".$result_template;
-$command_to_submit .= " -rsc_fpops_est ".floor( ( float )( $jobfops ) );
-$command_to_submit .= " -rsc_fpops_bound ".floor( 3.0 * ( float )( $jobfops ) );
-$command_to_submit .= " -rsc_memory_bound ".floor( ( float )( $jobmem ) );
-$command_to_submit .= " -rsc_disk_bound ".floor( ( float )( $jobdisk ) );
-$command_to_submit .= " -priority 10 -batch ".$user -> id;
-$command_to_submit .= " ".$temporaryinputfile;
-$command_to_submit = escapeshellcmd( $command_to_submit );
-$command_to_submit = "cd ".$config_dir."; ".$command_to_submit;
-
-$temporaryinputfile = $download_dir."/".$temporaryinputfile;
-
-$filehandle = fopen( $temporaryinputfile, "w" );
-if( !$filehandle )
- exit_with_text( "Cannot create the temporary input file !" );
-
-if( !fwrite( $filehandle, $jobinput ) )
-{
- fclose( $filehandle );
- exit_with_text( "Cannot write to the temporary input file !" );
-} 
-
-fclose( $filehandle );
-
-// We at Leiden Classical have a special mode for our app, it can verify the user supplied 
-// input and return an exit code signaling an error. We tend to parse the input before let
-// it run on our desktop pool ;-)... Here's how...
-//
-// if( strpos( $jobapplicationname, "classical" ) !== false )
-// {
-//  $testinputcommand = $bin_dir."/verify_classical_input ".$temporaryinputfile." /dev/null /dev/stdout /dev/stdout";
-//  $testinputcommand = escapeshellcmd( $testinputcommand );
-//  $testinputcommand = "cd ".$config_dir."; ".$testinputcommand;
-//  $errorline = 0;
-//  exec( $testinputcommand, &$outputoftest, &$errorline );
-//  if( $errorline != 0 )
-//  {
-//   $errorstring = "Your input had an error on line ".$errorline." ! The job was not submitted !";
-//   unlink( $temporaryinputfile );
-//   exit_with_text( $errorstring ); 
-//  }
-// }
-
-system( $command_to_submit );
-
-unlink( $temporaryinputfile );
-
-$workunit = mysql_fetch_object( mysql_query( "SELECT * FROM workunit WHERE name='".$extendedjobname."'" ) );
-
-if( !$workunit )
- exit_with_text( "Error during submition of the workunit associated with your job !" );
-
-$qlistentry = mysql_query( "INSERT INTO q_list VALUES('','".$user->id."','".$workunit->id."')" );
-
-if( !$qlistentry )
- exit_with_text( "Error during submition of your job !" );
-
-$jobidlink = '<a href="queue_show_job.php?workunitid='.$workunit -> id.'">'.$jobname.' ('.$workunit -> id.')</a>';
-
-start_table();
-row1( "Your job has been submitted !" );
-row2( "Job status: ", workunit_status_string( $workunit ) );
-row2( "Job id: ", $jobidlink );
-
-row1( "Commands" );
-row2( "Status of this job: ", '<a href="queue_show_job.php?workunitid='.$workunit -> id.'">Show job status</a>' );
-$max_jobs = max_nr_of_jobs_of_user( $user );
-$njobs = nr_of_jobs_of_user( $user );
-if( $njobs < $max_jobs )
-{
- if( $max_jobs - $njobs > 1 )
-  $line = "You can submit ".($max_jobs-$njobs)." more jobs: ";
- else
-  $line = "You can submit one more job: ";
- row2( $line, '<a href="queue_new_job_form.php">Submit another job</a>' );
-}
-row2( "", '<a href="queue_show_queue.php">Go back to your queue</a>' );
-row2( "", '<a href="logout.php">Log out</a>' );
-
-end_table();
-page_tail(); 
-
-?>
diff --git a/html/queue/user/queue_remove_job.php b/html/queue/user/queue_remove_job.php
deleted file mode 100644
index 64c7e22..0000000
--- a/html/queue/user/queue_remove_job.php
+++ /dev/null
@@ -1,67 +0,0 @@
-<?php
-
-include_once( "../inc/db.inc" );
-include_once( "../inc/util.inc" );
-include_once( "../inc/prefs.inc" );
-include_once( "../inc/queue.inc" );
-
-$timestr = time_str(time(0));
-
-db_init();
-
-$user        = get_logged_in_user();
-$workunitid  = get_int( 'workunitid' );
-$workunit    = mysql_fetch_object( mysql_query( "SELECT * FROM workunit WHERE id=".$workunitid ) );
-$job         = mysql_fetch_object( mysql_query( "SELECT * FROM q_list WHERE workunit=".$workunitid ) );
-$title       = "Deleting job '".workunit_name( $workunit )."' (".$workunitid.") of ".$user -> name." at ".$timestr;
-
-$jobname      = workunit_name( $workunit );
-
-if( $user -> id != $job -> user )
-{
- $title  = "Job '".$jobname."' (".$workunitid.")";
- page_head( $title );
- exit_with_text( "You are not the owner of this job !" );
-}
-
-$config = get_config();
-
-$jobstatusstring = workunit_status_string( $workunit );
-$jobsubmittime   = time_str( $workunit -> create_time );
-
-page_head( $title );
-start_table();
-row1( "Job speciffics" );
-row2( "Job submit time: ", $jobsubmittime );
-row2( "Job name: ", $jobname );
-row2( "Old job status: ", $jobstatusstring );
-
-$query = "UPDATE result SET server_state=5,outcome=5 WHERE server_state=2 AND workunitid=".$workunit -> id;
-mysql_query( $query );
-
-$query = "UPDATE workunit SET error_mask=error_mask|16,transition_time=".time(0).",batch=0 WHERE id=".$workunit -> id;
-mysql_query( $query );
-
-$query = "DELETE FROM q_list WHERE id=".$job -> id;
-mysql_query( $query );
-
-row2( "New job status: ", "deleted" );
-
-$max_jobs = max_nr_of_jobs_of_user( $user );
-$njobs = nr_of_jobs_of_user( $user );
-
-row1( "Commands" );
-if( $njobs < $max_jobs )
-{
- if( $max_jobs - $njobs > 1 )
-  $line = "You can submit ".($max_jobs-$njobs)." more jobs: ";
- else
-  $line = "You can submit one more job: ";
- row2( $line, '<a href="queue_new_job_form.php">Submit a job</a>' );
-}
-row2( "", '<a href="queue_show_queue.php">Go back to your queue</a>' );
-row2( "", '<a href="logout.php">Log out</a>' );
-
-end_table();
-
-?>
diff --git a/html/queue/user/queue_show_job.php b/html/queue/user/queue_show_job.php
deleted file mode 100644
index fd79194..0000000
--- a/html/queue/user/queue_show_job.php
+++ /dev/null
@@ -1,138 +0,0 @@
-<?php
-
-include_once( "../inc/db.inc" );
-include_once( "../inc/util.inc" );
-include_once( "../inc/prefs.inc" );
-include_once( "../inc/queue.inc" );
-
-$timestr = time_str(time(0));
-
-db_init();
-
-$user        = get_logged_in_user();
-$workunitid  = get_int( 'workunitid' );
-$workunit    = mysql_fetch_object( mysql_query( "SELECT * FROM workunit WHERE id=".$workunitid ) );
-$job         = mysql_fetch_object( mysql_query( "SELECT * FROM q_list WHERE workunit=".$workunitid ) );
-$title       = "Job '".workunit_name( $workunit )."' (".$workunitid.") of ".$user -> name." at ".$timestr;
-
-$jobname      = workunit_name( $workunit );
-
-if( $user -> id != $job -> user )
-{
- $title  = "Job '".$jobname."' (".$workunitid.")";
- page_head( $title );
- exit_with_text( "You are not the owner of this job !" );
-}
-
-$config = get_config();
-
-$jobapplication = mysql_fetch_object( mysql_query( "SELECT * FROM app WHERE id=".$workunit -> appid ) );
-$jobapplicationname = $jobapplication -> name;
-$jobapplicationfriendlyname = $jobapplication -> user_friendly_name;
-$jobfops = $workunit -> rsc_fpops_est;
-$jobmem = $workunit -> rsc_memory_bound;
-$jobdisk = $workunit -> rsc_disk_bound;
-$jobstatusstring = workunit_status_string( $workunit );
-
-$coloredjobstatusstring = $jobstatusstring;
-if( $jobstatusstring == "running" ) $coloredjobstatusstring = "<font color='green'><b>".$jobstatusstring."</b></font>";
-if( $jobstatusstring == "queued" ) $coloredjobstatusstring = "<font color='blue'><b>".$jobstatusstring."</b></font>";
-if( $jobstatusstring == "ERROR" ) $coloredjobstatusstring = "<font color='red'><b>".$jobstatusstring."</b></font>";
-
-$jobsubmittime = time_str( $workunit -> create_time );
-
-$workunitidstring = "<a href=workunit.php?wuid=".$job -> workunit.">".$job -> workunit."</a>";
-
-$jobinputurl = parse_element( $workunit -> xml_doc, "<file_info>" );
-$jobinputurl = parse_element( $jobinputurl, "<url>" );
-$jobinput = parse_element( $workunit -> xml_doc, "<file_info>" );
-$jobinput = parse_element( $jobinput, "<name>" );
-
-page_head( $title );
-start_table();
-
-row1( "Job speciffics" );
-row2( "Job status: ", $coloredjobstatusstring );
-row2( "Job application: ", $jobapplicationfriendlyname );
-row2( "Job submit time: ", $jobsubmittime );
-row2( "Job name: ", $jobname );
-row2( "Job id: ", $workunitidstring );
-row2( "Job estimated time to complete: ", floor((float)($jobfops)/92254963740)." min. " );
-row2( "Job estimated memory usage: ", floor((float)($jobmem)/1048576)." Mb. " );
-row2( "Job estimated disk usage: ", floor((float)($jobdisk)/1048576)." Mb. " );
-row2( "Job input file:", '<a href="'.$jobinputurl.'"> '.$jobinput.'</a>' );
-
-if( ( $jobstatusstring == "finished" ) || ( $jobstatusstring == "ERROR" ) )
-{
- if( $jobstatusstring != "finished" )
- {
-  $resultunitquery = mysql_query( "SELECT * FROM result WHERE workunitid=".$workunit -> id );
-  $nrofresults = mysql_num_rows( $resultunitquery );
-
-  for( $index = 0; $index < $nrofresults; ++$index )
-  {
-   $resultunit = mysql_fetch_object( $resultunitquery );
-
-   $jobstderr = parse_element( $resultunit -> stderr_out, "<stderr_txt>" );
-
-   if( $jobstderr )
-   {
-    row1( "Error output of this job" );
-    row2( "", $jobstderr );
-   }
-  }
- }
- else
- {
-  $resultunit = mysql_fetch_object( mysql_query( "SELECT * FROM result WHERE id=".$workunit -> canonical_resultid ) );
-
-  $xmldoc = $resultunit -> xml_doc_out;
-  $jobstderr = parse_element( $resultunit -> stderr_out, "<stderr_txt>" );
-
-  $nroffiles = 0;
-  $cursor = 0;
-  while( $tempfileinfo = parse_next_element( $xmldoc, "<file_info>", &$cursor ) )
-   $outputfiles[ $nroffiles++ ] = parse_element( $tempfileinfo, "<name>" );
-
-  if( $nroffiles >= 1 )
-  {
-   $fanoutnr = parse_config( $config, "<uldl_dir_fanout>" );
-   row1( "Output of this job" );
-   row2( "Number of output files of job: ", $nroffiles );
-   for( $index = 0; $index < $nroffiles; ++$index )
-   { 
-    $filename = $outputfiles[ $index ];
-    $url = "upload/".fan_out_dir( $filename, $fanoutnr )."/".$filename;
-    $outputfilelink = '<a href="'.$url.'">'.$filename.'</a>';
-    row2( "Output file ".($index+1).": ", $outputfilelink );
-   }
-  }
-
-  if( $jobstderr )
-  {
-   row1( "Error output of this job" );
-   row2( "", $jobstderr );
-  }
- }
-}
-
-$max_jobs = max_nr_of_jobs_of_user( $user );
-$njobs = nr_of_jobs_of_user( $user );
-
-row1( "Commands" );
-if( $njobs < $max_jobs )
-{
- if( $max_jobs - $njobs > 1 )
-  $line = "You can submit ".($max_jobs-$njobs)." more jobs: ";
- else
-  $line = "You can submit one more job: ";
- row2( $line, '<a href="queue_new_job_form.php">Submit a job</a>' );
-}
-row2( "", '<a href="queue_remove_job.php?workunitid='.$workunit -> id.'">Kill or Remove this job</a>' );
-row2( "", '<a href="queue_show_queue.php">Go back to your queue</a>' );
-row2( "", '<a href="logout.php">Log out</a>' );
-
-end_table();
-
-page_tail(); 
-?>
diff --git a/html/queue/user/queue_show_queue.php b/html/queue/user/queue_show_queue.php
deleted file mode 100644
index af22110..0000000
--- a/html/queue/user/queue_show_queue.php
+++ /dev/null
@@ -1,93 +0,0 @@
-<?php
-
-include_once( "../inc/db.inc" );
-include_once( "../inc/util.inc" );
-include_once( "../inc/prefs.inc" );
-include_once( "../inc/queue.inc" );
-
-db_init();
-
-$user = get_logged_in_user();
-$timestr = time_str(time(0));
-$title = "Personal job list of ".$user -> name." at ".$timestr;
-
-page_head( $title );
-
-$alljobs = all_jobs_of_user( $user );
-$njobs   = mysql_num_rows( $alljobs );
-
-start_table();
-
-if( $njobs ) 
-{
- if( $njobs > 1 )
-  row1( "You have ".$njobs." jobs listed !<br>" );
- else
-  row1( "You have ".$njobs." job listed !<br>" );
-
- end_table();
- start_table();
-
- row5( "<b>Job #</b>", "<b>Job submit time</b>", "<b>Job status</b>", "<b>Job name</b>", "<b>Job ID</b>" );
-
- for( $jobindex = 0; $jobindex < $njobs; ++$jobindex )
- {
-  $job = mysql_fetch_object( $alljobs );
-
-  $workunitquery = mysql_query( "SELECT * FROM workunit WHERE id=".$job -> workunit );
-  if( $workunitquery )
-  {
-   $workunit = mysql_fetch_object( $workunitquery );
-
-   if( $workunit )
-   {
-    $prefix = '<a href="queue_show_job.php?workunitid='.$job -> workunit.'">';
-    $workunitname = $prefix.workunit_name( $workunit ).'</a>';
-    $status = workunit_status_string( $workunit );
-    if( $status == "running" ) $status = "<font color='green'><b>".$status."</b></font>";
-    if( $status == "queued" ) $status = "<font color='blue'><b>".$status."</b></font>";
-    if( $status == "ERROR" ) $status = "<font color='red'><b>".$status."</b></font>";
-    $jobsubmittime = time_str( $workunit -> create_time );
-   }
-   else
-   {
-    $workunitname = "<font color='red'>WORKUNIT NOT FOUND IN DATABASE</font>";
-    $status = "<font color='red'>UNKNOWN</font>";
-    $jobsubmittime = "<font color='red'>UNKNOWN</font>";
-   }
-
-   mysql_free_result( $workunitquery );
-  }
-
-  $workunitstring = "<a href=workunit.php?wuid=".$job -> workunit.">".$job -> workunit."</a>";
-  row5( $jobindex+1, $jobsubmittime, $status, $workunitname, $workunitstring );
- }
-
-}
-else
- row1("You have NO jobs listed !<br>");
-
-end_table();
-
-$max_jobs = max_nr_of_jobs_of_user( $user );
-
-if( $max_jobs > $njobs )
-{
- if( $max_jobs - $njobs > 1 )
-  $line = 'You can submit '.( $max_jobs - $njobs ).' more jobs: ';
- else
-  $line = 'You can submit one more job: ';
-
- start_table();
- row1( "Commands" );
- row2( $line, '<a href="queue_new_job_form.php">Submit a job</a>' );
- row2( "", '<a href="home.php">Your account</a>' );
- row2( "", '<a href="hosts_user.php">Your computers</a>' );
- row2( "", '<a href="logout.php">Log out</a>' );
- end_table();
-}
-else
- exit_with_text( "You cannot submit any more jobs, you have reached your limit, clean up first !" );
-
-page_tail(); 
-?>
diff --git a/lib/app_ipc.cpp b/lib/app_ipc.cpp
index 39e745d..69548e7 100644
--- a/lib/app_ipc.cpp
+++ b/lib/app_ipc.cpp
@@ -42,7 +42,8 @@
 
 using std::string;
 
-APP_INIT_DATA::APP_INIT_DATA() : project_preferences(NULL) {
+APP_INIT_DATA::APP_INIT_DATA() {
+    clear();
 }
 
 APP_INIT_DATA::~APP_INIT_DATA() {
@@ -477,6 +478,7 @@ int boinc_resolve_filename(
     // If it's the <soft_link> XML tag, return its value,
     // otherwise, return the original file name
     //
+    // coverity[check_return]
     if (p) parse_str(buf, "<soft_link>", physical_name, len);
     return 0;
 }
@@ -498,6 +500,7 @@ int boinc_resolve_filename_s(const char *virtual_name, string& physical_name) {
     buf[0] = 0;
     p = fgets(buf, 512, fp);
     fclose(fp);
+    // coverity[check_return]
     if (p) parse_str(buf, "<soft_link>", physical_name);
     return 0;
 }
diff --git a/lib/cc_config.cpp b/lib/cc_config.cpp
index 711fc87..881b962 100644
--- a/lib/cc_config.cpp
+++ b/lib/cc_config.cpp
@@ -192,6 +192,7 @@ int LOG_FLAGS::write(MIOFILE& out) {
 }
 
 CC_CONFIG::CC_CONFIG() {
+    defaults();
 }
 
 // this is called first thing by client
@@ -208,6 +209,7 @@ void CC_CONFIG::defaults() {
     disallow_attach = false;
     dont_check_file_sizes = false;
     dont_contact_ref_site = false;
+    dont_lower_client_priority = false;
     dont_suspend_nci = false;
     dont_use_vbox = false;
     exclude_gpus.clear();
@@ -341,6 +343,7 @@ int CC_CONFIG::parse_options(XML_PARSER& xp) {
         if (xp.parse_bool("disallow_attach", disallow_attach)) continue;
         if (xp.parse_bool("dont_check_file_sizes", dont_check_file_sizes)) continue;
         if (xp.parse_bool("dont_contact_ref_site", dont_contact_ref_site)) continue;
+        if (xp.parse_bool("dont_lower_client_priority", dont_lower_client_priority)) continue;
         if (xp.parse_bool("dont_suspend_nci", dont_suspend_nci)) continue;
         if (xp.parse_bool("dont_use_vbox", dont_use_vbox)) continue;
         if (xp.match_tag("exclude_gpu")) {
@@ -547,11 +550,13 @@ int CC_CONFIG::write(MIOFILE& out, LOG_FLAGS& log_flags) {
         "        <disallow_attach>%d</disallow_attach>\n"
         "        <dont_check_file_sizes>%d</dont_check_file_sizes>\n"
         "        <dont_contact_ref_site>%d</dont_contact_ref_site>\n"
+        "        <dont_lower_client_priority>%d</lower_client_priority>\n"
         "        <dont_suspend_nci>%d</dont_suspend_nci>\n"
         "        <dont_use_vbox>%d</dont_use_vbox>\n",
         disallow_attach,
         dont_check_file_sizes,
         dont_contact_ref_site,
+        dont_lower_client_priority,
         dont_suspend_nci,
         dont_use_vbox
     );
diff --git a/lib/cc_config.h b/lib/cc_config.h
index 8f8eec4..fea507d 100644
--- a/lib/cc_config.h
+++ b/lib/cc_config.h
@@ -149,6 +149,7 @@ struct CC_CONFIG {
     bool disallow_attach;
     bool dont_check_file_sizes;
     bool dont_contact_ref_site;
+    bool dont_lower_client_priority;
     bool dont_suspend_nci;
     bool dont_use_vbox;
     std::vector<EXCLUDE_GPU> exclude_gpus;
diff --git a/lib/common_defs.h b/lib/common_defs.h
index cd50472..6ccce96 100644
--- a/lib/common_defs.h
+++ b/lib/common_defs.h
@@ -286,6 +286,22 @@ struct TIME_STATS {
     void write(MIOFILE&);
     int parse(XML_PARSER&);
     void print();
+    TIME_STATS() {
+        now = 0;
+        on_frac = 1;
+        connected_frac = 1;
+        cpu_and_network_available_frac = 1;
+        active_frac = 1;
+        gpu_active_frac = 1;
+        client_start_time = 0;
+        previous_uptime = 0;
+        session_active_duration = 0;
+        session_gpu_active_duration = 0;
+        total_start_time = 0;
+        total_duration = 0;
+        total_active_duration = 0;
+        total_gpu_active_duration = 0;
+    }
 };
 
 struct VERSION_INFO {
@@ -296,6 +312,12 @@ struct VERSION_INFO {
     int parse(MIOFILE&); 
     void write(MIOFILE&); 
     bool greater_than(VERSION_INFO&);
+    VERSION_INFO() {
+        major = 0;
+        minor = 0;
+        release = 0;
+        prerelease = true;
+    }
 };
 
 // used for Android
diff --git a/lib/coproc.cpp b/lib/coproc.cpp
index 352029b..2d69abe 100644
--- a/lib/coproc.cpp
+++ b/lib/coproc.cpp
@@ -403,6 +403,7 @@ void COPROC_NVIDIA::clear() {
     prop.textureAlignment = 0;
     prop.deviceOverlap = 0;
     prop.multiProcessorCount = 0;
+    is_used = COPROC_UNUSED;
 }
 
 int COPROC_NVIDIA::parse(XML_PARSER& xp) {
@@ -655,6 +656,7 @@ void COPROC_ATI::clear() {
     memset(&attribs, 0, sizeof(attribs));
     memset(&info, 0, sizeof(info));
     version_num = 0;
+    is_used = COPROC_UNUSED;
 }
 
 int COPROC_ATI::parse(XML_PARSER& xp) {
@@ -842,6 +844,8 @@ void COPROC_INTEL::clear() {
     estimated_delay = -1;
     strcpy(name, "");
     strcpy(version, "");
+    global_mem_size = 0;
+    is_used = COPROC_UNUSED;
 }
 
 int COPROC_INTEL::parse(XML_PARSER& xp) {
diff --git a/lib/coproc.h b/lib/coproc.h
index caf4763..b758d69 100644
--- a/lib/coproc.h
+++ b/lib/coproc.h
@@ -129,6 +129,7 @@ struct PCI_INFO {
     int device_id;
     int domain_id;
 
+    PCI_INFO(): present(false), bus_id(0), device_id(0),domain_id(0) {}
     void write(MIOFILE&);
     int parse(XML_PARSER&);
 };
@@ -214,11 +215,13 @@ struct COPROC {
             device_nums[i] = 0;
             instance_has_opencl[i] = false;
             opencl_device_ids[i] = 0;
-			opencl_device_indexes[i] = 0;
+            opencl_device_indexes[i] = 0;
             running_graphics_app[i] = true;
         }
+        device_num = 0;
         memset(&opencl_prop, 0, sizeof(opencl_prop));
         memset(&pci_info, 0, sizeof(pci_info));
+        last_print_time = 0;
     }
     inline void clear_usage() {
         for (int i=0; i<count; i++) {
diff --git a/lib/crypt.cpp b/lib/crypt.cpp
index ecac58f..49fba12 100644
--- a/lib/crypt.cpp
+++ b/lib/crypt.cpp
@@ -196,7 +196,8 @@ int scan_key_hex(FILE* f, KEY* key, int size) {
     char *p, buf[256];
     int j = 0, b;
     fgets(buf, 256, f);
-    sscanf(buf, "%d", &num_bits);
+    int fs = sscanf(buf, "%d", &num_bits);
+    if (fs != 1) return ERR_NULL;
     key->bits = num_bits;
     len = size - sizeof(key->bits);
     while (1) {
@@ -205,6 +206,7 @@ int scan_key_hex(FILE* f, KEY* key, int size) {
         n = (strlen(p)-1)/2;
         if (n == 0) break;
         for (i=0; i<n; i++) {
+            // coverity[check_return]
             sscanf(buf+i*2, "%2x", &b);
             if (j == len) break;
             key->data[j++] = b;
@@ -217,6 +219,7 @@ int scan_key_hex(FILE* f, KEY* key, int size) {
     key->bits = num_bits;
     len = size - sizeof(key->bits);
     for (i=0; i<len; i++) {
+        // coverity[check_return]
         fscanf(f, "%2x", &n);
         key->data[i] = n;
     }
diff --git a/lib/crypt_prog.cpp b/lib/crypt_prog.cpp
index 473308f..2a1eb5d 100644
--- a/lib/crypt_prog.cpp
+++ b/lib/crypt_prog.cpp
@@ -108,7 +108,9 @@ unsigned int random_int() {
     if (!f) {
         die("can't open /dev/random\n");
     }
-    fread(&n, sizeof(n), 1, f);
+    if (1 != fread(&n, sizeof(n), 1, f)) {
+        die("couldn't read from /dev/random\n");
+    }
     fclose(f);
 #endif
     return n;
@@ -187,6 +189,7 @@ int main(int argc, char** argv) {
         retval = scan_key_hex(fpub, (KEY*)&public_key, sizeof(public_key));
         if (retval) die("read_public_key");
         f = fopen(argv[3], "r");
+        if (!f) die("fopen");
         signature.data = signature_buf;
         signature.len = 256;
         retval = scan_hex_data(f, signature);
@@ -233,6 +236,7 @@ int main(int argc, char** argv) {
             die("usage: crypt_prog -cert_verify file signature_file certificate_dir ca_dir \n");
 
         f = fopen(argv[3], "r");
+        if (!f) die("fopen");
         signature.data = signature_buf;
         signature.len = 256;
         retval = scan_hex_data(f, signature);
@@ -261,20 +265,24 @@ int main(int argc, char** argv) {
         }
         if (b2o) {
             f = fopen(argv[3], "r");
+            if (!f) die("fopen");
             signature.data = signature_buf;
             signature.len = 256;
             retval = scan_hex_data(f, signature);
             fclose(f);
             f = fopen(argv[4], "w+");
+            if (!f) die("fopen");
             print_raw_data(f, signature);
             fclose(f);
         } else {
             f = fopen(argv[3], "r");
+            if (!f) die("fopen");
             signature.data = signature_buf;
             signature.len = 256;
             retval = scan_raw_data(f, signature);
             fclose(f);
             f = fopen(argv[4], "w+");
+            if (!f) die("fopen");
             print_hex_data(f, signature);
             fclose(f);
         }
@@ -319,8 +327,9 @@ int main(int argc, char** argv) {
                 if (!fpriv) {
                     die("fopen");
                 }
-                scan_key_hex(fpriv, (KEY*)&private_key, sizeof(private_key));
+                retval = scan_key_hex(fpriv, (KEY*)&private_key, sizeof(private_key));
                 fclose(fpriv);
+                if (retval) die("scan_key_hex\n");
                 private_to_openssl(private_key, &rsa_key);
 
                 //i = PEM_write_bio_RSAPrivateKey(bio_out, &rsa_key,
@@ -330,6 +339,7 @@ int main(int argc, char** argv) {
                 //i = PEM_write_bio_RSAPrivateKey(bio_out, &rsa_key,
         		//				NULL, NULL, 0, pass_cb, NULL);
                 fpriv = fopen(argv[5], "w+");
+                if (!fpriv) die("fopen");
                 PEM_write_RSAPrivateKey(fpriv, &rsa_key, NULL, NULL, 0, 0, NULL);
                 fclose(fpriv);
     		    //if (i == 0) {
@@ -341,8 +351,9 @@ int main(int argc, char** argv) {
                 if (!fpub) {
                     die("fopen");
                 }
-                scan_key_hex(fpub, (KEY*)&public_key, sizeof(public_key));
+                retval = scan_key_hex(fpub, (KEY*)&public_key, sizeof(public_key));
                 fclose(fpub);
+                if (retval) die("scan_key_hex\n");
                 fpub = fopen(argv[5], "w+");
                 if (!fpub) {
                     die("fopen");
@@ -363,6 +374,7 @@ int main(int argc, char** argv) {
             }
             if (kpriv) {
                 fpriv = fopen (argv[4], "r");
+                if (!fpriv) die("fopen");
                 rsa_key_ = PEM_read_RSAPrivateKey(fpriv, NULL, NULL, NULL);
                 fclose(fpriv);
                 if (rsa_key_ == NULL) {
@@ -377,6 +389,7 @@ int main(int argc, char** argv) {
                 print_key_hex(fpriv, (KEY*)&private_key, sizeof(private_key));
             } else {
                 fpub = fopen (argv[4], "r");
+                if (!fpub) die("fopen");
                 rsa_key_ = PEM_read_RSA_PUBKEY(fpub, NULL, NULL, NULL);
                 fclose(fpub);
                 if (rsa_key_ == NULL) {
diff --git a/lib/diagnostics.cpp b/lib/diagnostics.cpp
index c10bce5..26e791e 100644
--- a/lib/diagnostics.cpp
+++ b/lib/diagnostics.cpp
@@ -125,12 +125,12 @@ int __cdecl boinc_message_reporting(int reportType, char *szMsg, int *retVal){
     case _CRT_ERROR:
 
         if (flags & BOINC_DIAG_TRACETOSTDERR) {
-            n = fprintf(stderr, szMsg);
+            n = fprintf(stderr, "%s", szMsg);
             if (n > 0) stderr_file_size += n;
         }
 
         if (flags & BOINC_DIAG_TRACETOSTDOUT) {
-            n = fprintf(stdout, szMsg);
+            n = fprintf(stdout, "%s", szMsg);
             if (n > 0) stdout_file_size += n;
         }
 
diff --git a/lib/error_numbers.h b/lib/error_numbers.h
index fcc3ec4..7dd096c 100644
--- a/lib/error_numbers.h
+++ b/lib/error_numbers.h
@@ -206,6 +206,8 @@
 #define ERR_STATFS          -236
 #define ERR_PIPE            -237
 #define ERR_NEED_HTTPS      -238
+#define ERR_CHMOD           -239
+#define ERR_STAT            -240
 
 // PLEASE: add a text description of your error to 
 // the text description function boincerror() in str_util.cpp.
diff --git a/lib/filesys.cpp b/lib/filesys.cpp
index 6ef202e..a16c46a 100644
--- a/lib/filesys.cpp
+++ b/lib/filesys.cpp
@@ -504,7 +504,9 @@ FILE* boinc_fopen(const char* path, const char* mode) {
         }
     }
     if (f) {
-        fcntl(fileno(f), F_SETFD, FD_CLOEXEC);
+        if (-1 == fcntl(fileno(f), F_SETFD, FD_CLOEXEC)) {
+            return 0;
+        }
     }
 #endif
     return f;
@@ -598,9 +600,15 @@ int boinc_copy(const char* orig, const char* newf) {
     fclose(src);
     fclose(dst);
     // Copy file's ownership, permissions to the extent we are allowed
-    lstat(orig, &sbuf);             // Get source file's info
-    chown(newf, sbuf.st_uid, sbuf.st_gid);
-    chmod(newf, sbuf.st_mode);
+    if (lstat(orig, &sbuf)) { // Get source file's info
+        return ERR_STAT;
+    }
+    if (chown(newf, sbuf.st_uid, sbuf.st_gid)) {
+        return ERR_CHOWN;
+    }
+    if (chmod(newf, sbuf.st_mode)) {
+        return ERR_CHMOD;
+    }
     return retval;
 #endif
 }
diff --git a/lib/gui_rpc_client.cpp b/lib/gui_rpc_client.cpp
index 10953d5..0c159aa 100644
--- a/lib/gui_rpc_client.cpp
+++ b/lib/gui_rpc_client.cpp
@@ -60,6 +60,10 @@ using std::vector;
 
 RPC_CLIENT::RPC_CLIENT() {
     sock = -1;
+    start_time = 0;
+    timeout = 0;
+    retry = 0;
+    memset(&addr, 0, sizeof(addr));
 }
 
 RPC_CLIENT::~RPC_CLIENT() {
@@ -200,7 +204,10 @@ int RPC_CLIENT::init_poll() {
     BOINCTRACE("init_poll(): sock = %d\n", sock);
 
     tv.tv_sec = tv.tv_usec = 0;
-    select(FD_SETSIZE, &read_fds, &write_fds, &error_fds, &tv);
+    if (-1 == select(FD_SETSIZE, &read_fds, &write_fds, &error_fds, &tv)) {
+        BOINCTRACE("init_poll(): select(): %s (%d)\n", strerror(errno), errno);
+        return ERR_SELECT;
+    }
     retval = 0;
     if (FD_ISSET(sock, &error_fds)) {
         retval =  ERR_CONNECT;
diff --git a/lib/gui_rpc_client_ops.cpp b/lib/gui_rpc_client_ops.cpp
index 48cf8d7..1167d13 100644
--- a/lib/gui_rpc_client_ops.cpp
+++ b/lib/gui_rpc_client_ops.cpp
@@ -277,6 +277,8 @@ int PROJECT::parse(XML_PARSER& xp) {
     int retval;
     char buf[256];
 
+    strcpy(buf, "");
+
     while (!xp.get_tag()) {
         if (xp.match_tag("/project")) {
             return 0;
@@ -794,6 +796,9 @@ void FILE_TRANSFER::clear() {
     project_url.clear();
     project_name.clear();
     nbytes = 0;
+    uploaded = false;
+    is_upload = false;
+    generated_locally = false;
     sticky = false;
     pers_xfer_active = false;
     xfer_active = false;
@@ -834,6 +839,7 @@ int MESSAGE::parse(XML_PARSER& xp) {
 void MESSAGE::clear() {
     project.clear();
     priority = 0;
+    seqno = 0;
     timestamp = 0;
     body.clear();
 }
@@ -1287,8 +1293,9 @@ int PROJECT_CONFIG::parse(XML_PARSER& xp) {
         if (xp.parse_string("error_msg", error_msg)) continue;
         if (xp.match_tag("terms_of_use")) {
             char buf[65536];
-            xp.element_contents("</terms_of_use>", buf, sizeof(buf));
-            terms_of_use = buf;
+            if (!xp.element_contents("</terms_of_use>", buf, sizeof(buf))) {
+                terms_of_use = buf;
+            }
             continue;
         }
         if (xp.parse_int("min_client_version", min_client_version)) continue;
@@ -1310,6 +1317,7 @@ void PROJECT_CONFIG::clear() {
     web_rpc_url_base.clear();
     error_msg.clear();
     terms_of_use.clear();
+    local_revision = 0;
     min_passwd_length = 6;
     account_manager = false;
     uses_username = false;
@@ -1402,6 +1410,7 @@ void CC_STATUS::clear() {
 	gpu_mode_delay = 0;
     disallow_attach = false;
     simple_gui_only = false;
+    max_event_log_lines = 0;
 }
 
 /////////// END OF PARSING FUNCTIONS.  RPCS START HERE ////////////////
@@ -2338,8 +2347,12 @@ int RPC_CLIENT::get_newer_version(std::string& version, std::string& version_dow
     retval = rpc.do_rpc("<get_newer_version/>\n");
     if (!retval) {
         while (rpc.fin.fgets(buf, 256)) {
-            parse_str(buf, "<newer_version>", version);
-            parse_str(buf, "<download_url>", version_download_url);
+            if (parse_str(buf, "<newer_version>", version)) {
+                return ERR_XML_PARSE;
+            }
+            if (parse_str(buf, "<download_url>", version_download_url)) {
+                return ERR_XML_PARSE;
+            }
         }
     }
     return retval;
@@ -2557,6 +2570,7 @@ static int parse_notices(XML_PARSER& xp, NOTICES& notices) {
                 if (np->seqno == -1) {
                     notices.notices.clear();
                     notices.complete = true;
+                    delete np;
                 } else {
                     notices.notices.insert(notices.notices.begin(), np);
                 }
diff --git a/lib/mfile.cpp b/lib/mfile.cpp
index 7e12e41..31a40cb 100644
--- a/lib/mfile.cpp
+++ b/lib/mfile.cpp
@@ -38,6 +38,7 @@
 MFILE::MFILE() {
     buf = (char*)malloc(64*1024);
     len = 0;
+    f = NULL;
 }
 
 MFILE::~MFILE() {
@@ -147,10 +148,13 @@ int MFILE::puts(const char* p) {
     return n;
 }
 
+// This is closing the file even if it couldn't flush it.
+// The caller needs to check the return value and open the file again before the next retry.
+//
 int MFILE::close() {
     int retval = 0;
     if (f) {
-        flush();
+        retval = flush();
         fclose(f);
         f = NULL;
     }
diff --git a/lib/miofile.cpp b/lib/miofile.cpp
index a74e394..175ccdd 100644
--- a/lib/miofile.cpp
+++ b/lib/miofile.cpp
@@ -34,6 +34,8 @@ using std::string;
 
 MIOFILE::MIOFILE() {
     mf = 0;
+    wbuf = 0;
+    len = 0;
     f = 0;
     buf = 0;
 }
diff --git a/lib/msg_log.cpp b/lib/msg_log.cpp
index c64f4d2..f23a599 100644
--- a/lib/msg_log.cpp
+++ b/lib/msg_log.cpp
@@ -63,6 +63,7 @@ using std::string;
 // See sched/sched_msg_log.C and client/client_msg_log.C for those classes.
 
 MSG_LOG::MSG_LOG(FILE* output_) {
+    debug_level = 0;
     output = output_;
     indent_level = 0;
     spaces[0] = 0;
diff --git a/lib/network.cpp b/lib/network.cpp
index 8fbca82..da11317 100644
--- a/lib/network.cpp
+++ b/lib/network.cpp
@@ -225,7 +225,9 @@ int boinc_socket(int& fd, int protocol) {
         return ERR_SOCKET;
     }
 #ifndef _WIN32
-    fcntl(fd, F_SETFD, FD_CLOEXEC);
+    if (-1 == fcntl(fd, F_SETFD, FD_CLOEXEC)) {
+        return ERR_FCNTL;
+    }
 #endif
     return 0;
 }
@@ -283,7 +285,9 @@ int get_socket_error(int fd) {
     n = getpeername(fd, (struct sockaddr *)&sin, &sinsz);
 #else
     socklen_t intsize = sizeof(int);
-    getsockopt(fd, SOL_SOCKET, SO_ERROR, (void*)&n, (socklen_t*)&intsize);
+    if (getsockopt(fd, SOL_SOCKET, SO_ERROR, (void*)&n, (socklen_t*)&intsize)) {
+        return errno;
+    }
 #endif
     return n;
 }
@@ -334,7 +338,11 @@ int boinc_get_port(bool is_remote, int& port) {
         return ERR_BIND;
     }
 
-    getsockname(sock, (sockaddr*)&addr, &addrsize);
+    retval = getsockname(sock, (sockaddr*)&addr, &addrsize);
+    if (retval) {
+        boinc_close_socket(sock);
+        return errno;
+    }
     port = ntohs(addr.sin_port);
 
     boinc_close_socket(sock);
diff --git a/lib/notice.cpp b/lib/notice.cpp
index f26e591..2182a87 100644
--- a/lib/notice.cpp
+++ b/lib/notice.cpp
@@ -111,5 +111,6 @@ void NOTICE::clear() {
     strcpy(project_name, "");
     strcpy(guid, "");
     strcpy(feed_url, "");
+    keep = false;
 }
 
diff --git a/lib/parse.cpp b/lib/parse.cpp
index 91b3a06..f059f48 100644
--- a/lib/parse.cpp
+++ b/lib/parse.cpp
@@ -97,6 +97,7 @@ bool parse_str(const char* buf, const char* tag, char* dest, int destlen) {
     p = strstr(buf, tag);
     if (!p) return false;
     p = strchr(p, '>');
+    if (!p) return false;
     p++;
     const char* q = strchr(p, '<');
     if (!q) return false;
@@ -212,6 +213,7 @@ int dup_element(FILE* in, const char* tag_name, char** pp) {
         retval = strcatdup(p, buf);
         if (retval) return retval;
     }
+    free(p);
     return ERR_XML_PARSE;
 }
 
@@ -499,6 +501,8 @@ int skip_unrecognized(char* buf, MIOFILE& fin) {
 }
 
 XML_PARSER::XML_PARSER(MIOFILE* _f) {
+    strcpy(parsed_tag, "");
+    is_tag = false;
     f = _f;
 }
 
@@ -775,7 +779,7 @@ bool XML_PARSER::parse_bool(const char* start_tag, bool& b) {
 
     // handle the archaic form <tag/>, which means true
     //
-    strcpy(tag, start_tag);
+    safe_strcpy(tag, start_tag);
     strcat(tag, "/");
     if (!strcmp(parsed_tag, tag)) {
         b = true;
diff --git a/lib/prefs.cpp b/lib/prefs.cpp
index eb1a24f..3a8267e 100644
--- a/lib/prefs.cpp
+++ b/lib/prefs.cpp
@@ -259,6 +259,8 @@ void GLOBAL_PREFS::defaults() {
     vm_max_used_frac = 0.75;
     work_buf_additional_days = 0.5;
     work_buf_min_days = 0.1;
+    
+    override_file_present = false;
 
     // don't initialize source_project, source_scheduler,
     // mod_time, host_specific here
diff --git a/lib/prefs.h b/lib/prefs.h
index e4afe66..ebbe3cc 100644
--- a/lib/prefs.h
+++ b/lib/prefs.h
@@ -93,7 +93,7 @@ struct TIME_SPAN {
         Never,
         Between
     };
-    TIME_SPAN() : start_hour(0), end_hour(0) {}
+    TIME_SPAN() : present(false), start_hour(0), end_hour(0) {}
     TIME_SPAN(double start, double end) : start_hour(start), end_hour(end) {}
 
     bool suspended(double hour) const;
diff --git a/lib/procinfo.h b/lib/procinfo.h
index 06bfe83..c5852c3 100644
--- a/lib/procinfo.h
+++ b/lib/procinfo.h
@@ -39,7 +39,10 @@ struct PROCINFO {
     double page_fault_rate;        // derived by higher-level code
     std::vector<int> children;
 
-    PROCINFO(){}
+    PROCINFO() {
+      clear();
+      working_set_size_smoothed = 0;
+    }
     void clear() {
         id = 0;
         parentid = 0;
diff --git a/lib/str_util.cpp b/lib/str_util.cpp
index 1f7f7c2..68c08e9 100644
--- a/lib/str_util.cpp
+++ b/lib/str_util.cpp
@@ -493,6 +493,7 @@ const char* boincerror(int which_error) {
         case ERR_RESULT_START: return "result start failed";
         case ERR_RESULT_DOWNLOAD: return "result download failed";
         case ERR_RESULT_UPLOAD: return "result upload failed";
+        case ERR_BAD_USER_NAME: return "bad username";
         case ERR_INVALID_URL: return "invalid URL";
         case ERR_MAJOR_VERSION: return "bad major version";
         case ERR_NO_OPTION: return "no option";
@@ -511,15 +512,20 @@ const char* boincerror(int which_error) {
         case ERR_SHMEM_NAME: return "can't get shared mem segment name";
         case ERR_NO_NETWORK_CONNECTION: return "no available network connection";
         case ERR_IN_PROGRESS: return "operation in progress";
+        case ERR_NONUNIQUE_EMAIL: return "email already registered";
         case ERR_ACCT_CREATION_DISABLED: return "account creation disabled";
         case ERR_ATTACH_FAIL_INIT: return "Couldn't start master page download";
         case ERR_ATTACH_FAIL_DOWNLOAD: return "Couldn't download master page";
         case ERR_ATTACH_FAIL_PARSE: return "Couldn't parse master page";
         case ERR_ATTACH_FAIL_BAD_KEY: return "Invalid account key";
         case ERR_ATTACH_FAIL_FILE_WRITE: return "Couldn't write account file";
+        case ERR_ATTACH_FAIL_SERVER_ERROR: return "Couldn't attach because of server error";
+        case ERR_SIGNING_KEY: return "signing key failure";
         case ERR_FFLUSH: return "fflush() failed";
         case ERR_FSYNC: return "fsync() failed";
         case ERR_TRUNCATE: return "truncate() failed";
+        case ERR_WRONG_URL: return "wrong URL";
+        case ERR_DUP_NAME: return "coprocs with duplicate names detected";
         case ERR_GETGRNAM: return "getgrnam() failed";
         case ERR_CHOWN: return "chown() failed";
         case ERR_HTTP_PERMANENT: return "permanent HTTP error";
@@ -532,6 +538,7 @@ const char* boincerror(int which_error) {
         case ERR_CRYPTO: return "encryption error";
         case ERR_ABORTED_ON_EXIT: return "job was aborted on client exit";
         case ERR_PROC_PARSE: return "a /proc entry was not parsed correctly";
+        case ERR_STATFS: return "statfs() failed";
         case ERR_PIPE: return "pipe() failed";
         case ERR_NEED_HTTPS: return "HTTPS needed";
         case HTTP_STATUS_NOT_FOUND: return "HTTP file not found";
diff --git a/locale/de/BOINC-Project-Generic.po b/locale/de/BOINC-Project-Generic.po
index b53d7fa..f23d1e3 100644
--- a/locale/de/BOINC-Project-Generic.po
+++ b/locale/de/BOINC-Project-Generic.po
@@ -12,10 +12,10 @@ msgid ""
 msgstr ""
 "Project-Id-Version: BOINC\n"
 "Report-Msgid-Bugs-To: BOINC translation team <boinc_loc at boinc.berkeley.edu>\n"
-"POT-Creation-Date: 2015-03-04 08:56 PST\n"
-"PO-Revision-Date: 2015-06-24 10:37+0000\n"
+"POT-Creation-Date: 2015-06-24 13:05 PDT\n"
+"PO-Revision-Date: 2015-11-18 14:50+0000\n"
 "Last-Translator: Christian Beer <christian.beer at posteo.de>\n"
-"Language-Team: German (http://www.transifex.com/projects/p/boinc/language/de/)\n"
+"Language-Team: German (http://www.transifex.com/boinc/boinc/language/de/)\n"
 "MIME-Version: 1.0\n"
 "Content-Type: text/plain; charset=UTF-8\n"
 "Content-Transfer-Encoding: 8bit\n"
@@ -38,7 +38,7 @@ msgid "A valid invitation code is required to create an account."
 msgstr "Zum Erstellen eines Kontos ist ein gültiger Einladungscode erforderlich."
 
 #: ../inc/account.inc:44 ../inc/host.inc:674 ../inc/result.inc:632
-#: ../inc/team.inc:219 ../inc/team.inc:367 ../inc/user.inc:198
+#: ../inc/team.inc:224 ../inc/team.inc:372 ../inc/user.inc:198
 #: ../user/account_finish.php:41 ../user/team_admins.php:64
 #: ../user/team_change_founder_form.php:79 ../user/team_email_list.php:73
 #: ../user/top_users.php:49 ../user/user_search.php:124
@@ -69,8 +69,8 @@ msgstr "Muss aus mindestens %1 Zeichen bestehen."
 msgid "Confirm password"
 msgstr "Passwort bestätigen"
 
-#: ../inc/account.inc:63 ../inc/team.inc:43 ../inc/team.inc:129
-#: ../inc/team.inc:242 ../inc/team.inc:382 ../inc/team.inc:470
+#: ../inc/account.inc:63 ../inc/team.inc:43 ../inc/team.inc:134
+#: ../inc/team.inc:247 ../inc/team.inc:387 ../inc/team.inc:475
 #: ../inc/user.inc:212 ../inc/user.inc:395 ../user/account_finish.php:45
 #: ../user/edit_user_info_form.php:38 ../user/profile_search_action.php:44
 #: ../user/team_email_list.php:73 ../user/team_search.php:85
@@ -115,6 +115,7 @@ msgstr "Passwort vergessen?"
 msgid "Stay logged in"
 msgstr "angemeldet bleiben"
 
+#. kludge
 #: ../inc/account.inc:114 ../inc/util.inc:238 ../user/login_form.php:41
 msgid "Log in"
 msgstr "Anmelden"
@@ -250,6 +251,7 @@ msgstr "Alle offenen bbCodes schließen"
 msgid "Close Tags"
 msgstr "Tags schließen"
 
+#. names for the above
 #: ../inc/forum.inc:38
 msgid "Oldest first"
 msgstr "Älteste zuerst"
@@ -274,185 +276,220 @@ msgstr "Meist angesehene zuerst"
 msgid "Most posts first"
 msgstr "Meiste Beiträge zuerst"
 
-#: ../inc/forum.inc:126
+#: ../inc/forum.inc:104
+msgid "Volunteer moderator"
+msgstr "freiwilliger Moderator"
+
+#: ../inc/forum.inc:105
+msgid "Project administrator"
+msgstr "Projektadministrator"
+
+#: ../inc/forum.inc:106
+msgid "Project developer"
+msgstr "Projektentwickler"
+
+#: ../inc/forum.inc:107
+msgid "Project tester"
+msgstr "Projekttester"
+
+#: ../inc/forum.inc:108
+msgid "Volunteer developer"
+msgstr "freiwilliger Entwickler"
+
+#: ../inc/forum.inc:109
+msgid "Volunteer tester"
+msgstr "freiwilliger Tester"
+
+#: ../inc/forum.inc:110
+msgid "Project scientist"
+msgstr "Projektwissenschaftler"
+
+#: ../inc/forum.inc:111
+msgid "Help desk expert"
+msgstr "Helpdesk Experte"
+
+#. Search
+#: ../inc/forum.inc:129
 msgid "Search for words in forum messages"
 msgstr "Suche in Forenbeiträgen"
 
-#: ../inc/forum.inc:126
+#: ../inc/forum.inc:129
 msgid "Search forums"
 msgstr "Suche im Forum"
 
-#: ../inc/forum.inc:127
+#: ../inc/forum.inc:130
 msgid "Advanced search"
 msgstr "Erweiterte Suche"
 
-#: ../inc/forum.inc:133 ../inc/user.inc:325 ../user/pm.php:69
+#: ../inc/forum.inc:136 ../inc/user.inc:325 ../user/pm.php:69
 #: ../user/pm.php:138
 msgid "Private messages"
 msgstr "Private Nachrichten"
 
-#: ../inc/forum.inc:152 ../user/forum_forum.php:74
+#: ../inc/forum.inc:155 ../user/forum_forum.php:74
 #: ../user/sample_index.php:128
 msgid "Questions and Answers"
 msgstr "Fragen und Antworten"
 
-#: ../inc/forum.inc:152 ../inc/forum.inc:184 ../inc/user.inc:321
+#: ../inc/forum.inc:155 ../inc/forum.inc:187 ../inc/user.inc:321
 #: ../inc/user.inc:454 ../user/forum_forum.php:76 ../user/sample_index.php:127
 #: ../project.sample/project.inc:70
 msgid "Message boards"
 msgstr "Diskussionsforen"
 
-#: ../inc/forum.inc:188 ../inc/forum.inc:196
+#: ../inc/forum.inc:191 ../inc/forum.inc:199
 msgid "%1 message board"
 msgstr "%1 Diskussionsforen"
 
-#: ../inc/forum.inc:246 ../inc/result.inc:717
+#: ../inc/forum.inc:249 ../inc/result.inc:717
 msgid "Previous"
 msgstr "Vorherige"
 
-#: ../inc/forum.inc:284 ../inc/result.inc:726
+#: ../inc/forum.inc:287 ../inc/result.inc:726
 msgid "Next"
 msgstr "Nächste"
 
-#: ../inc/forum.inc:413 ../inc/forum.inc:1218 ../user/forum_forum.php:140
+#: ../inc/forum.inc:416 ../inc/forum.inc:1234 ../user/forum_forum.php:140
 #: ../user/forum_reply.php:126 ../user/forum_report_post.php:79
 msgid "Author"
 msgstr "Autor"
 
-#: ../inc/forum.inc:413 ../inc/pm.inc:86 ../user/forum_edit.php:128
+#: ../inc/forum.inc:416 ../inc/pm.inc:86 ../user/forum_edit.php:128
 #: ../user/forum_edit.php:133 ../user/forum_post.php:120
 #: ../user/forum_reply.php:126 ../user/forum_report_post.php:79
 #: ../user/pm.php:90 ../user/pm.php:149
 msgid "Message"
 msgstr "Nachricht"
 
-#: ../inc/forum.inc:583
+#: ../inc/forum.inc:586
 msgid "Send message"
 msgstr "Nachricht senden"
 
-#: ../inc/forum.inc:583
+#: ../inc/forum.inc:586
 msgid "Send %1 a private message"
 msgstr "Private Nachricht an %1 senden"
 
-#: ../inc/forum.inc:584
+#: ../inc/forum.inc:587
 msgid "Joined: %1"
 msgstr "Beigetreten: %1"
 
-#: ../inc/forum.inc:593
+#: ../inc/forum.inc:596
 msgid "Posts: %1"
 msgstr "Beiträge: %1"
 
-#: ../inc/forum.inc:599
+#: ../inc/forum.inc:602
 msgid "Credit: %1"
 msgstr "Punkte: %1"
 
-#: ../inc/forum.inc:600
+#: ../inc/forum.inc:603
 msgid "RAC: %1"
 msgstr "Punktedurchschnitt pro Tag: %1"
 
-#: ../inc/forum.inc:624
+#: ../inc/forum.inc:627
 msgid "You haven't read this message yet"
 msgstr "Sie haben diese Nachricht noch nicht gelesen"
 
-#: ../inc/forum.inc:624
+#: ../inc/forum.inc:627
 msgid "Unread"
 msgstr "ungelesen"
 
-#: ../inc/forum.inc:627 ../inc/forum.inc:632 ../inc/forum.inc:731
+#: ../inc/forum.inc:630 ../inc/forum.inc:635 ../inc/forum.inc:736
 msgid "Message %1"
 msgstr "Nachricht %1"
 
-#: ../inc/forum.inc:628 ../inc/user.inc:409 ../user/forum_forum.php:178
+#: ../inc/forum.inc:631 ../inc/user.inc:409 ../user/forum_forum.php:178
 msgid "hidden"
 msgstr "verborgen"
 
-#: ../inc/forum.inc:629
+#: ../inc/forum.inc:632
 msgid "Posted: %1"
 msgstr "Geschrieben: %1"
 
-#: ../inc/forum.inc:632
+#: ../inc/forum.inc:635
 msgid " - in response to "
 msgstr " - als Antwort für "
 
-#: ../inc/forum.inc:635
+#: ../inc/forum.inc:638
 msgid "Edit"
 msgstr "Bearbeiten"
 
-#: ../inc/forum.inc:635
+#: ../inc/forum.inc:638
 msgid "Edit this message"
 msgstr "Diese Nachricht bearbeiten"
 
-#: ../inc/forum.inc:641
+#: ../inc/forum.inc:644
 msgid "Last modified: %1"
 msgstr "Zuletzt geändert: %1"
 
-#: ../inc/forum.inc:644
+#: ../inc/forum.inc:647
 msgid ""
 "This post is not shown because the sender is on your 'ignore' list.  Click "
 "%1here%2 to view this post"
 msgstr "Dieser Beitrag wird nicht angezeigt weil der Absender von Ihnen geblockt wurde. %1Trotzdem anzeigen%2."
 
-#: ../inc/forum.inc:672 ../inc/forum.inc:683
+#: ../inc/forum.inc:675 ../inc/forum.inc:686
 msgid "Report this post as offensive"
 msgstr "Diesen Beitrag als anstößig melden"
 
-#: ../inc/forum.inc:672 ../inc/forum.inc:683
+#: ../inc/forum.inc:675 ../inc/forum.inc:686
 msgid "Report as offensive"
 msgstr "Als anstößig melden"
 
-#: ../inc/forum.inc:676
+#: ../inc/forum.inc:679
 msgid "Rating: %1"
 msgstr "Bewertung: %1"
 
-#: ../inc/forum.inc:676
+#: ../inc/forum.inc:679
 msgid "rate: "
 msgstr "Bewerten: "
 
-#: ../inc/forum.inc:679
+#: ../inc/forum.inc:682
 msgid "Click if you like this message"
 msgstr "Hier klicken wenn Sie diesen Beitrag hilfreich finden."
 
-#: ../inc/forum.inc:679
+#: ../inc/forum.inc:682
 msgid "Rate +"
 msgstr "positiv bewerten"
 
-#: ../inc/forum.inc:681
+#: ../inc/forum.inc:684
 msgid "Click if you don't like this message"
 msgstr "Hier klicken wenn Ihnen dieser Beitrag nicht gefällt."
 
-#: ../inc/forum.inc:681
+#: ../inc/forum.inc:684
 msgid "Rate -"
 msgstr "negativ bewerten"
 
-#: ../inc/forum.inc:689 ../user/pm.php:111 ../user/pm.php:151
+#. "Reply" is used as a verb
+#: ../inc/forum.inc:693 ../user/pm.php:111 ../user/pm.php:151
 msgid "Reply"
 msgstr "Antworten"
 
-#: ../inc/forum.inc:689
+#: ../inc/forum.inc:693
 msgid "Post a reply to this message"
 msgstr "Auf diesen Beitrag antworten."
 
-#: ../inc/forum.inc:691
+#. "Quote" is used as a verb
+#: ../inc/forum.inc:696
 msgid "Quote"
 msgstr "Zitieren"
 
-#: ../inc/forum.inc:691
+#: ../inc/forum.inc:696
 msgid "Post a reply by quoting this message"
 msgstr "Beim antworten diesen Beitrag zitieren"
 
-#: ../inc/forum.inc:712
+#: ../inc/forum.inc:717
 msgid "Hidden by a moderator"
 msgstr "Von einem Moderator versteckt"
 
-#: ../inc/forum.inc:733
+#: ../inc/forum.inc:738
 msgid "Posted %1 by %2"
 msgstr "Geschrieben am %1 von %2"
 
-#: ../inc/forum.inc:751
+#: ../inc/forum.inc:756
 msgid "You may not post or rate messages until %1"
 msgstr "Sie können keine Beiträge schreiben oder bewerten bis %1."
 
-#: ../inc/forum.inc:762
+#: ../inc/forum.inc:767
 msgid ""
 "\n"
 "        <ul>\n"
@@ -470,125 +507,125 @@ msgid ""
 "        "
 msgstr "\n        <ul>\n        <li> Beiträge müssen 'kinderfreundlich' sein: Sie dürfen keine\n            obszönen, hasserfüllten, sexuell freizügige\n            oder andeutende Inhalte haben.\n        <li> Keine kommerzielle Werbung.\n        <li> Keine Verlinkung auf Webseiten mit sexuellen Inhalten,\n            Glücksspiel, oder Intoleranz gegenüber anderen.\n        <li> Keine Beiträge die andere verärgern oder reizen sollen,\n            oder das Thema an sich reißen sollen.\n   [...]
 
-#: ../inc/forum.inc:784
+#: ../inc/forum.inc:799
 msgid "Rules:"
 msgstr "Regeln:"
 
-#: ../inc/forum.inc:785
+#: ../inc/forum.inc:800
 msgid "More info"
 msgstr "mehr Informationen"
 
-#: ../inc/forum.inc:1082 ../user/forum_thread.php:190
+#: ../inc/forum.inc:1098 ../user/forum_thread.php:190
 msgid "Unhide"
 msgstr "Sichtbar machen"
 
-#: ../inc/forum.inc:1082
+#: ../inc/forum.inc:1098
 msgid "Unhide this post"
 msgstr "Beitrag sichtbar machen"
 
-#: ../inc/forum.inc:1084 ../user/forum_thread.php:196
+#: ../inc/forum.inc:1100 ../user/forum_thread.php:196
 msgid "Hide"
 msgstr "Verstecken"
 
-#: ../inc/forum.inc:1084
+#: ../inc/forum.inc:1100
 msgid "Hide this post"
 msgstr "Beitrag verstecken"
 
-#: ../inc/forum.inc:1089 ../user/forum_thread.php:229
+#: ../inc/forum.inc:1105 ../user/forum_thread.php:229
 msgid "Move"
 msgstr "Verschieben"
 
-#: ../inc/forum.inc:1089
+#: ../inc/forum.inc:1105
 msgid "Move post to a different thread"
 msgstr "Diesen Beitrag in ein anderes Thema verschieben"
 
-#: ../inc/forum.inc:1094
+#: ../inc/forum.inc:1110
 msgid "Banish author"
 msgstr "Autor verbannen"
 
-#: ../inc/forum.inc:1101
+#: ../inc/forum.inc:1117
 msgid "Vote to banish author"
 msgstr "Für die Verbannung des Autors abstimmen"
 
-#: ../inc/forum.inc:1105
+#: ../inc/forum.inc:1121
 msgid "Vote not to banish author"
 msgstr "Gegen die Verbannung des Autors abstimmen"
 
-#: ../inc/forum.inc:1110
+#: ../inc/forum.inc:1126
 msgid "Start vote to banish author"
 msgstr "Eine Abstimmung zur Verbannung des Autors starten"
 
-#: ../inc/forum.inc:1115 ../inc/user.inc:312 ../user/forum_thread.php:243
+#: ../inc/forum.inc:1131 ../inc/user.inc:312 ../user/forum_thread.php:243
 #: ../user/pm.php:112 ../user/pm.php:152
 msgid "Delete"
 msgstr "Löschen"
 
-#: ../inc/forum.inc:1115
+#: ../inc/forum.inc:1131
 msgid "Delete this post"
 msgstr "Diesen Beitrag löschen"
 
-#: ../inc/forum.inc:1153
+#: ../inc/forum.inc:1169
 msgid "Only team members can post to the team message board"
 msgstr "Nur Teammitglieder können Beiträge im Teamforum erstellen."
 
-#: ../inc/forum.inc:1163
+#: ../inc/forum.inc:1179
 msgid ""
 "In order to create a new thread in %1 you must have a certain amount of "
 "credit. This is to prevent and protect against abuse of the system."
 msgstr "Um ein neues Thema in %1 anlegen zu können, müssen Sie über eine bestimmte Punkteanzahl verfügen. Dies soll vor Missbrauch des Systems schützen."
 
-#: ../inc/forum.inc:1170
+#: ../inc/forum.inc:1186
 msgid ""
 "You cannot create any more threads right now. Please wait a while before "
 "trying again. This delay has been enforced to protect against abuse of the "
 "system."
 msgstr "Sie können für den Moment keine weiteren Themen mehr anlegen. Bitte warten Sie einige Zeit und versuchen Sie es dann erneut. Diese Verzögerung wurde eingeführt, um Missbrauch des Systems vorzubeugen."
 
-#: ../inc/forum.inc:1177
+#: ../inc/forum.inc:1193
 msgid ""
 "This thread is locked. Only forum moderators and administrators are allowed "
 "to post there."
 msgstr "Dieses Thema ist geschlossen. Nur Moderatoren oder Administratoren dürfen hier Beiträge erstellen."
 
-#: ../inc/forum.inc:1182
+#: ../inc/forum.inc:1198
 msgid "Can't post to a hidden thread."
 msgstr "In einem versteckten Thema kann kein Beitrag erstellt werden."
 
-#: ../inc/forum.inc:1216
+#: ../inc/forum.inc:1232
 msgid "Thread"
 msgstr "Themen"
 
-#: ../inc/forum.inc:1217 ../inc/team.inc:135 ../user/forum_forum.php:139
+#: ../inc/forum.inc:1233 ../inc/team.inc:140 ../user/forum_forum.php:139
 #: ../user/forum_index.php:99
 msgid "Posts"
 msgstr "Beiträge"
 
-#: ../inc/forum.inc:1219 ../user/forum_forum.php:141
+#: ../inc/forum.inc:1235 ../user/forum_forum.php:141
 msgid "Views"
 msgstr "Ansichten"
 
-#: ../inc/forum.inc:1220 ../inc/team.inc:135 ../user/forum_forum.php:142
+#: ../inc/forum.inc:1236 ../inc/team.inc:140 ../user/forum_forum.php:142
 #: ../user/forum_help_desk.php:48 ../user/forum_index.php:100
 msgid "Last post"
 msgstr "Letzter Beitrag"
 
-#: ../inc/forum.inc:1278
+#: ../inc/forum.inc:1294
 msgid "New posts in the thread %1"
 msgstr "Neue Beiträge im Thema %1"
 
-#: ../inc/forum.inc:1283
+#: ../inc/forum.inc:1299
 msgid "New posts in subscribed thread"
 msgstr "Neue Beiträge in abonniertem Thema"
 
-#: ../inc/forum.inc:1284
+#: ../inc/forum.inc:1300
 msgid "There are new posts in the thread '%1'"
 msgstr "Es gibt neue Beiträge im Thema '%1'"
 
-#: ../inc/forum.inc:1294
+#: ../inc/forum.inc:1310
 msgid "Mark all threads as read"
 msgstr "Alle Themen als gelesen markieren"
 
-#: ../inc/forum.inc:1295
+#: ../inc/forum.inc:1311
 msgid "Mark all threads in all message boards as read."
 msgstr "Alle Themen in allen Bereichen als gelesen markieren."
 
@@ -605,7 +642,7 @@ msgid "Home"
 msgstr "zu Hause"
 
 #: ../inc/host.inc:57 ../inc/prefs.inc:666 ../inc/prefs_util.inc:549
-#: ../user/server_status.php:138
+#: ../user/server_status.php:142
 msgid "Work"
 msgstr "Arbeit"
 
@@ -667,9 +704,9 @@ msgid "Created"
 msgstr "Erstellt"
 
 #: ../inc/host.inc:112 ../inc/host.inc:226 ../inc/host.inc:231
-#: ../inc/host.inc:686 ../inc/team.inc:105 ../inc/team.inc:224
-#: ../inc/team.inc:229 ../inc/team.inc:231 ../inc/team.inc:373
-#: ../inc/team.inc:378 ../inc/user.inc:126 ../inc/user.inc:139
+#: ../inc/host.inc:686 ../inc/team.inc:110 ../inc/team.inc:229
+#: ../inc/team.inc:234 ../inc/team.inc:236 ../inc/team.inc:378
+#: ../inc/team.inc:383 ../inc/user.inc:126 ../inc/user.inc:139
 #: ../user/profile_search_action.php:45
 #: ../user/team_change_founder_form.php:80 ../user/team_email_list.php:73
 #: ../user/team_remove_inactive_form.php:43 ../user/top_users.php:54
@@ -847,7 +884,7 @@ msgstr "Letzter Kontakt"
 msgid "Computer info"
 msgstr "Informationen zum Computer"
 
-#: ../inc/host.inc:221 ../inc/host.inc:681 ../inc/team.inc:366
+#: ../inc/host.inc:221 ../inc/host.inc:681 ../inc/team.inc:371
 #: ../user/top_users.php:48
 msgid "Rank"
 msgstr "Rang"
@@ -856,9 +893,9 @@ msgstr "Rang"
 msgid "Avg. credit"
 msgstr "Punktedurchschnitt"
 
-#: ../inc/host.inc:230 ../inc/team.inc:106 ../inc/team.inc:225
-#: ../inc/team.inc:234 ../inc/team.inc:236 ../inc/team.inc:372
-#: ../inc/team.inc:377 ../inc/user.inc:140
+#: ../inc/host.inc:230 ../inc/team.inc:111 ../inc/team.inc:230
+#: ../inc/team.inc:239 ../inc/team.inc:241 ../inc/team.inc:377
+#: ../inc/team.inc:382 ../inc/user.inc:140
 #: ../user/team_change_founder_form.php:81 ../user/team_email_list.php:73
 #: ../user/team_remove_inactive_form.php:44 ../user/top_users.php:53
 #: ../user/top_users.php:58
@@ -1333,7 +1370,7 @@ msgstr "Nur nützlich wenn Sie eine Verbindung via Modem, ISDN oder VPN aufbauen
 msgid "Disconnect when done"
 msgstr "Verbindung trennen, wenn fertig"
 
-#: ../inc/prefs.inc:235 ../inc/prefs.inc:472 ../user/explain_state.php:94
+#: ../inc/prefs.inc:235 ../user/explain_state.php:94
 msgid "Computing"
 msgstr "Berechnung"
 
@@ -1345,6 +1382,7 @@ msgstr "Festplatte"
 msgid "Network"
 msgstr "Netzwerk"
 
+#. These texts are used in multiple places in prefs_edit.php and add_venue.php
 #: ../inc/prefs.inc:241
 msgid ""
 "These preferences apply to all the BOINC projects in which you participate."
@@ -1356,6 +1394,10 @@ msgid ""
 " range or not numeric."
 msgstr "%1 Einstellungen aktualisieren nicht möglich! %2 Die rot markierten Werte sind außerhalb zulässiger Werte oder nicht numerisch!"
 
+#: ../inc/prefs.inc:472
+msgid "computing"
+msgstr "Berechnung"
+
 #: ../inc/prefs.inc:483
 msgid "Separate preferences for %1"
 msgstr "Separate Einstellungen für %1"
@@ -1420,6 +1462,7 @@ msgstr "ja"
 msgid "no"
 msgstr "nein"
 
+#. TODO: make this a subclass of PREF
 #: ../inc/prefs.inc:638
 msgid "Default computer location"
 msgstr "Computerstandort (Standard)"
@@ -1535,7 +1578,7 @@ msgstr "Benutzer ist gesperrt"
 msgid "No profile exists for that user ID."
 msgstr "Es existiert kein Profil für diese Benuzer-ID."
 
-#: ../inc/profile.inc:219 ../user/create_profile.php:309
+#: ../inc/profile.inc:219 ../user/create_profile.php:317
 msgid "Edit your profile"
 msgstr "Profil bearbeiten"
 
@@ -1588,7 +1631,7 @@ msgid "All"
 msgstr "Alle"
 
 #: ../inc/result.inc:115 ../inc/result.inc:176 ../inc/result.inc:223
-#: ../user/server_status.php:163
+#: ../user/server_status.php:167
 msgid "In progress"
 msgstr "In Bearbeitung"
 
@@ -1617,7 +1660,7 @@ msgid "Inactive"
 msgstr "Inaktiv"
 
 #: ../inc/result.inc:175 ../inc/result.inc:222 ../user/explain_state.php:37
-#: ../user/server_status.php:163
+#: ../user/server_status.php:167
 msgid "Unsent"
 msgstr "Ungesendet"
 
@@ -1806,7 +1849,7 @@ msgstr "Zeige IDs"
 msgid "Show names"
 msgstr "Zeige Namen"
 
-#: ../inc/result.inc:361
+#: ../inc/result.inc:361 ../user/result.php:36
 msgid "Task"
 msgstr "Aufgabe"
 
@@ -1846,7 +1889,7 @@ msgstr "CPU Zeit<br />(sek)"
 msgid "Credit"
 msgstr "Punkte"
 
-#: ../inc/result.inc:384 ../inc/result.inc:746 ../user/server_status.php:163
+#: ../inc/result.inc:384 ../inc/result.inc:746 ../user/server_status.php:167
 msgid "Application"
 msgstr "Anwendung"
 
@@ -1926,7 +1969,7 @@ msgstr "Schlagwörter"
 msgid "Find teams with these words in their names or descriptions"
 msgstr "Findet Teams mit diesen Begriffen im Namen oder der Beschreibung."
 
-#: ../inc/team.inc:49 ../inc/team.inc:468
+#: ../inc/team.inc:49 ../inc/team.inc:473
 msgid "Type of team"
 msgstr "Typ des Teams"
 
@@ -1954,7 +1997,7 @@ msgstr "Von Ihnen angefordert"
 msgid "founder response deadline is %1"
 msgstr "Die Rückmeldezeit des Gründers beträgt %1"
 
-#: ../inc/team.inc:72 ../inc/team.inc:570 ../inc/user.inc:358
+#: ../inc/team.inc:72 ../inc/team.inc:575 ../inc/user.inc:358
 #: ../inc/user.inc:449
 msgid "None"
 msgstr "Keines"
@@ -1967,169 +2010,169 @@ msgstr "Übernahme einleiten"
 msgid "Deferred"
 msgstr "laufende Übernahme"
 
-#: ../inc/team.inc:87
+#: ../inc/team.inc:91
 msgid "Team info"
 msgstr "Team Informationen"
 
-#: ../inc/team.inc:89 ../user/team_forum.php:72 ../user/team_search.php:82
+#: ../inc/team.inc:93 ../user/team_forum.php:72 ../user/team_search.php:82
 msgid "Description"
 msgstr "Beschreibung"
 
-#: ../inc/team.inc:101
+#: ../inc/team.inc:106
 msgid "Web site"
 msgstr "Internetseite"
 
-#: ../inc/team.inc:127
+#: ../inc/team.inc:132
 msgid "Cross-project stats"
 msgstr "Projektübergreifende Statistiken"
 
-#: ../inc/team.inc:130 ../inc/team.inc:383 ../user/team_search.php:84
+#: ../inc/team.inc:135 ../inc/team.inc:388 ../user/team_search.php:84
 msgid "Type"
 msgstr "Typ"
 
-#: ../inc/team.inc:134 ../user/team_manage.php:65
+#: ../inc/team.inc:139 ../user/team_manage.php:65
 msgid "Message board"
 msgstr "Diskussionsforen"
 
-#: ../inc/team.inc:135 ../user/forum_forum.php:138 ../user/forum_index.php:98
+#: ../inc/team.inc:140 ../user/forum_forum.php:138 ../user/forum_index.php:98
 msgid "Threads"
 msgstr "Themen"
 
-#: ../inc/team.inc:143
+#: ../inc/team.inc:148
 msgid "Join this team"
 msgstr "Diesem Team beitreten"
 
-#: ../inc/team.inc:144
+#: ../inc/team.inc:149
 msgid ""
 "Note: if 'OK to email' is set in your project preferences, joining a team "
 "gives its founder access to your email address."
 msgstr "Hinweis: Wenn Sie E-Mails in den Projekteinstellungen erlauben, kann der Gründer des Teams Ihre E-Mail-Adresse einsehen."
 
-#: ../inc/team.inc:147
+#: ../inc/team.inc:152
 msgid "Not accepting new members"
 msgstr "Akzeptiert keine neuen Mitglieder"
 
-#: ../inc/team.inc:154
+#: ../inc/team.inc:159
 msgid "Foundership change requested"
 msgstr "Wechsel des Gründerstatus beantragt"
 
-#: ../inc/team.inc:155
+#: ../inc/team.inc:160
 msgid "Respond by %1"
 msgstr "Rückmeldung bis %1"
 
-#: ../inc/team.inc:159
+#: ../inc/team.inc:164
 msgid "Team foundership change"
 msgstr "Teamgründer wechseln"
 
-#: ../inc/team.inc:163 ../inc/team.inc:368
+#: ../inc/team.inc:168 ../inc/team.inc:373
 msgid "Members"
 msgstr "Mitglieder"
 
-#: ../inc/team.inc:164 ../inc/team.inc:263
+#: ../inc/team.inc:169 ../inc/team.inc:268
 msgid "Founder"
 msgstr "Gründer"
 
-#: ../inc/team.inc:178
+#: ../inc/team.inc:183
 msgid "Admins"
 msgstr "Team-Admins"
 
-#: ../inc/team.inc:193
+#: ../inc/team.inc:198
 msgid "New members in last day"
 msgstr "Neue Mitglieder (letzte 24h)"
 
-#: ../inc/team.inc:194
+#: ../inc/team.inc:199
 msgid "Total members"
 msgstr "Mitglieder insgesamt"
 
-#: ../inc/team.inc:194 ../inc/team.inc:195 ../inc/team.inc:196
+#: ../inc/team.inc:199 ../inc/team.inc:200 ../inc/team.inc:201
 msgid "view"
 msgstr "Anzeigen"
 
-#: ../inc/team.inc:195
+#: ../inc/team.inc:200
 msgid "Active members"
 msgstr "aktive Mitglieder"
 
-#: ../inc/team.inc:196
+#: ../inc/team.inc:201
 msgid "Members with credit"
 msgstr "Mitglieder mit Punkten"
 
-#: ../inc/team.inc:265
+#: ../inc/team.inc:270
 msgid "Admin"
 msgstr "Admin"
 
-#: ../inc/team.inc:286 ../user/forum_user_posts.php:124
+#: ../inc/team.inc:291 ../user/forum_user_posts.php:124
 #: ../user/top_hosts.php:93 ../user/top_teams.php:123
 #: ../user/top_users.php:128
 msgid "Previous %1"
 msgstr "Vorherige %1"
 
-#: ../inc/team.inc:290 ../user/forum_user_posts.php:133
+#: ../inc/team.inc:295 ../user/forum_user_posts.php:133
 #: ../user/profile_search_action.php:63 ../user/top_hosts.php:98
 #: ../user/top_teams.php:128 ../user/top_users.php:133
 msgid "Next %1"
 msgstr "Nächste %1"
 
-#: ../inc/team.inc:298
+#: ../inc/team.inc:303
 msgid "No such team."
 msgstr "Kein Team gefunden."
 
-#: ../inc/team.inc:311
+#: ../inc/team.inc:316
 msgid "This operation requires foundership."
 msgstr "Diese Aktion benötigt den Gründerstatus."
 
-#: ../inc/team.inc:335
+#: ../inc/team.inc:340
 msgid "This operation requires team admin privileges"
 msgstr "Diese Aktion benötigt die Team-Admin Berechtigung."
 
-#: ../inc/team.inc:437
+#: ../inc/team.inc:442
 msgid ""
 "WARNING: this is a BOINC-wide team. If you make changes here, they will soon"
 " be overwritten. Edit the %1BOINC-wide team%2 instead."
 msgstr "WARNUNG: Dies ist ein BOINC-weites Team. Hier vorgenommene Änderungen werden automatisch wieder überschrieben. Bearbeiten Sie das %1BOINC-weite Team%2 stattdessen."
 
-#: ../inc/team.inc:443
+#: ../inc/team.inc:448
 msgid ""
 "%1Privacy note%2: if you create a team, your project preferences (resource "
 "share, graphics preferences) will be visible to the public."
 msgstr "%1Datenschutzhinweis%2: Wenn Sie ein Team erstellen, werden Ihre Projekteinstellungen (Ressourcenverteilung, Grafikeinstellungen) für jeden sichtbar."
 
-#: ../inc/team.inc:447
+#: ../inc/team.inc:452
 msgid "Team name, text version"
 msgstr "Teamname (Textversion)"
 
-#: ../inc/team.inc:448
+#: ../inc/team.inc:453
 msgid "Don't use HTML tags."
 msgstr "Keine HTML-Tags möglich."
 
-#: ../inc/team.inc:451
+#: ../inc/team.inc:456
 msgid "Team name, HTML version"
 msgstr "Teamname (HTML-Version)"
 
-#: ../inc/team.inc:453 ../inc/team.inc:463
+#: ../inc/team.inc:458 ../inc/team.inc:468
 msgid "You may use %1limited HTML tags%2."
 msgstr "Sie können nur %1bestimmte HTML-Tags%2 verwenden."
 
-#: ../inc/team.inc:454
+#: ../inc/team.inc:459
 msgid "If you don't know HTML, leave this box blank."
 msgstr "Wenn Sie HTML nicht kennen, lassen Sie dieses Feld frei."
 
-#: ../inc/team.inc:457
+#: ../inc/team.inc:462
 msgid "URL of team web page, if any"
 msgstr "URL der Team-Internetseite, wenn vorhanden"
 
-#: ../inc/team.inc:457
+#: ../inc/team.inc:462
 msgid "without \"http://\""
 msgstr "ohne \"http://\""
 
-#: ../inc/team.inc:458
+#: ../inc/team.inc:463
 msgid "This URL will be linked to from the team's page on this site."
 msgstr "Diese URL wird als Link zur Team-Internetseite benutzt."
 
-#: ../inc/team.inc:461
+#: ../inc/team.inc:466
 msgid "Description of team"
 msgstr "Beschreibung des Teams"
 
-#: ../inc/team.inc:477
+#: ../inc/team.inc:482
 msgid "Accept new members?"
 msgstr "Neue Mitglieder akzeptieren?"
 
@@ -2221,6 +2264,7 @@ msgstr "Postleitzahl"
 msgid "%1 member since"
 msgstr "%1 Mitglied seit"
 
+#. LDAP accounts can't change email or password
 #: ../inc/user.inc:219 ../inc/user.inc:223
 msgid "Change"
 msgstr "Ändern"
@@ -2297,6 +2341,7 @@ msgstr "Erstellen"
 msgid "%1 posts"
 msgstr "%1 Beiträge"
 
+#. ------------ Notification -----------
 #: ../inc/user.inc:339 ../user/edit_forum_preferences_form.php:40
 msgid "Notifications"
 msgstr "Benachrichtigungen"
@@ -2334,7 +2379,7 @@ msgstr "Freunde finden"
 msgid "Friends"
 msgstr "Freunde"
 
-#: ../inc/user.inc:407 ../inc/user.inc:409 ../user/server_status.php:153
+#: ../inc/user.inc:407 ../inc/user.inc:409 ../user/server_status.php:157
 msgid "Computers"
 msgstr "Computer"
 
@@ -2672,7 +2717,7 @@ msgstr "Um das Bild aus Ihrem Profil zu entfernen, das Kästchen auswählen:"
 msgid ""
 "If you would like include a picture with your profile, click the \"Browse\" "
 "button and select a JPEG or PNG file. Please select images of %1 or less."
-msgstr "Wenn Sie Ihr Profil mit einem Bild versehen wollen, wählen Sie eine JPEG oder PNG Datei mit der \"Browse\"-Schaltfläche aus. Bitte (%1 oder kleiner)"
+msgstr "Wenn Sie Ihr Profil mit einem Bild versehen wollen, wählen Sie eine JPEG oder PNG Datei mit der \"Browse\"-Schaltfläche aus. Maximale Dateigröße: %1"
 
 #: ../user/create_profile.php:91
 msgid "Language"
@@ -2720,32 +2765,32 @@ msgstr "Ihre zweite Antwort wurde vom Akismet Anti-Spam-System als Spam markiert
 msgid "Your profile submission was empty."
 msgstr "Ihr übertragenes Profil war leer."
 
-#: ../user/create_profile.php:281
+#: ../user/create_profile.php:283
 msgid "Could not update the profile: database error"
 msgstr "Datenbankfehler: Das Profil konnte nicht aktualisiert werden"
 
-#: ../user/create_profile.php:293
+#: ../user/create_profile.php:299
 msgid "Could not create the profile: database error"
 msgstr "Datenbankfehler: Das Profil konnte nicht erstellt werden"
 
-#: ../user/create_profile.php:298
+#: ../user/create_profile.php:304
 msgid "Profile saved"
 msgstr "Profil gespeichert"
 
-#: ../user/create_profile.php:300
+#: ../user/create_profile.php:306
 msgid ""
 "Congratulations! Your profile was successfully entered into our database."
 msgstr "Glückwunsch! Ihr Profil wurde in unsere Datenbank aufgenommen."
 
-#: ../user/create_profile.php:302
-msgid "%1View your profile%2"
-msgstr "%1Ihr Profil ansehen%2"
+#: ../user/create_profile.php:309
+msgid "View your profile"
+msgstr "Ihr Profil ansehen"
 
-#: ../user/create_profile.php:311
+#: ../user/create_profile.php:319
 msgid "Create a profile"
 msgstr "Profil erstellen"
 
-#: ../user/create_profile.php:339
+#: ../user/create_profile.php:347
 msgid ""
 "To prevent spam, an average credit of %1 or greater is required to create or"
 " edit a profile.  We apologize for this inconvenience."
@@ -3025,6 +3070,7 @@ msgstr "Diese Aktion wird alle Änderungen die Sie in Ihren Community-Einstellun
 msgid "Reset preferences"
 msgstr "Einstellungen zurücksetzen"
 
+#. Not the right kind of file
 #: ../user/edit_forum_preferences_action.php:95
 msgid "Error: Not the right kind of file, only PNG and JPEG are supported."
 msgstr "Fehler: Nicht der richtige Dateityp, nur Formate PNG und JPEG sind unterstützt."
@@ -3035,8 +3081,8 @@ msgstr "Ihre Signatur war zu lang, bitte bleiben Sie unter 250 Zeichen."
 
 #: ../user/edit_forum_preferences_action.php:139
 #: ../user/edit_forum_preferences_action.php:153
-msgid "No such user: %1"
-msgstr "Kein solcher Benutzer: %1"
+msgid "No such user:"
+msgstr "Kein solcher Benutzer:"
 
 #: ../user/edit_forum_preferences_form.php:45
 msgid ""
@@ -3167,6 +3213,8 @@ msgstr "Automatisch zum ersten neuen Beitrag im Thema springen"
 msgid "Don't move sticky posts to top"
 msgstr "Angepinnte Beiträge nicht nach oben bewegen"
 
+#. DISABLE_FORUMS
+#. ------------ Message filtering  -----------
 #: ../user/edit_forum_preferences_form.php:137
 msgid "Message filtering"
 msgstr "Nachrichtenfilter"
@@ -3493,6 +3541,7 @@ msgstr "Zusätzliche Nachricht (optional)"
 msgid "Send"
 msgstr "Senden"
 
+#. Can't moderate without being moderator
 #: ../user/forum_banishment_vote.php:37
 #: ../user/forum_banishment_vote_action.php:35
 msgid "You are not authorized to banish users."
@@ -4259,6 +4308,7 @@ msgstr "Diesen Beitrag nicht als Client-Nachricht exportieren"
 msgid "Sort"
 msgstr "Sortieren"
 
+#. --------------
 #: ../user/forum_thread_status.php:54
 msgid "Thread status updated"
 msgstr "Themenstatus aktualisiert"
@@ -5040,6 +5090,7 @@ msgstr "Benutzer mit der ID %1 konnte nicht gefunden werden"
 msgid "Could not find user with username %1"
 msgstr "Benutzer mit dem Benutzernamen %1 konnte nicht gefunden werden"
 
+#. Non-unique username
 #: ../user/pm.php:217
 msgid "%1 is not a unique username; you will have to use user ID"
 msgstr "%1 ist kein einmaliger Benutzername; Sie müssen die Benutzer-ID verwenden"
@@ -5238,9 +5289,9 @@ msgstr "Zuletzt verdiente Punkte"
 msgid "No profiles found containing '%1'"
 msgstr "Keine Profile die '%1' enthalten gefunden"
 
-#: ../user/result.php:35
-msgid "Task %1"
-msgstr "Aufgabe %1"
+#: ../user/result.php:33
+msgid "No such task:"
+msgstr "Keine solche Aufgabe:"
 
 #: ../user/results.php:29
 msgid "This feature is turned off temporarily"
@@ -5298,23 +5349,23 @@ msgstr "Rechner"
 msgid "Database schema version: "
 msgstr "Version des Datenbankschemas:"
 
-#: ../user/server_status.php:134
+#: ../user/server_status.php:138
 msgid "Computing status"
 msgstr "Status der Berechnung"
 
-#: ../user/server_status.php:149
+#: ../user/server_status.php:153
 msgid "Users"
 msgstr "Benutzer"
 
-#: ../user/server_status.php:161
+#: ../user/server_status.php:165
 msgid "Tasks by application"
 msgstr "Aufgaben pro Anwendung"
 
-#: ../user/server_status.php:164
+#: ../user/server_status.php:168
 msgid "Runtime of last 100 tasks in hours: average, min, max"
 msgstr "Laufzeiten der letzten 100 Aufgaben in h: durchschnitt, min, max"
 
-#: ../user/server_status.php:165
+#: ../user/server_status.php:169
 msgid "Users in last 24 hours"
 msgstr "Benutzer in den letzten 24 Stunden"
 
@@ -5330,6 +5381,7 @@ msgstr "Statistiken und Ranglisten"
 msgid "Statistics for %1"
 msgstr "Statistiken von %1"
 
+#. Now display what we've got (either gotten from cache or from DB)
 #: ../user/stats.php:32 ../user/top_users.php:117
 msgid "Top participants"
 msgstr "Die besten Benutzer"
@@ -6140,10 +6192,12 @@ msgstr "%1Ich bin im Moment nicht daran interessiert%2 einem Team beizutreten."
 msgid "Limit exceeded - Sorry, first %1 items only"
 msgstr "Höchstgrenze erreicht - Nur die ersten %1 Einträge werden angezeigt"
 
+#. Now display what we've got (either gotten from cache or from DB)
 #: ../user/top_hosts.php:82
 msgid "Top hosts"
 msgstr "Die besten Rechner"
 
+#. Now display what we've got (either gotten from cache or from DB)
 #: ../user/top_teams.php:107
 msgid "Top %1 teams"
 msgstr "Die besten %1 Teams"
diff --git a/locale/it_IT/BOINC-Client.mo b/locale/it_IT/BOINC-Client.mo
index 839b8ca..ff47ff0 100644
Binary files a/locale/it_IT/BOINC-Client.mo and b/locale/it_IT/BOINC-Client.mo differ
diff --git a/locale/it_IT/BOINC-Client.po b/locale/it_IT/BOINC-Client.po
index 7cfc5db..8621151 100644
--- a/locale/it_IT/BOINC-Client.po
+++ b/locale/it_IT/BOINC-Client.po
@@ -5,12 +5,12 @@
 # Translators:
 msgid ""
 msgstr ""
-"Project-Id-Version: boinc\n"
+"Project-Id-Version: BOINC\n"
 "Report-Msgid-Bugs-To: \n"
 "POT-Creation-Date: 2013-10-15 22:25-0700\n"
-"PO-Revision-Date: 2015-02-08 21:33+0000\n"
-"Last-Translator: Rom Walton <romw at romwnet.org>\n"
-"Language-Team: Italian (Italy) (http://www.transifex.com/projects/p/boinc/language/it_IT/)\n"
+"PO-Revision-Date: 2015-11-13 09:00+0000\n"
+"Last-Translator: Sebastiano Pistore <olatusrooc at virgilio.it>\n"
+"Language-Team: Italian (Italy) (http://www.transifex.com/boinc/boinc/language/it_IT/)\n"
 "MIME-Version: 1.0\n"
 "Content-Type: text/plain; charset=UTF-8\n"
 "Content-Transfer-Encoding: 8bit\n"
@@ -19,7 +19,7 @@ msgstr ""
 
 #: acct_mgr.cpp:450 acct_mgr.cpp:459
 msgid "Message from account manager"
-msgstr "Messaggio dal gestore dell'account"
+msgstr "Messaggio dall'account manager"
 
 #: client_msgs.cpp:81
 msgid "Message from server"
@@ -29,22 +29,22 @@ msgstr "Messaggio dal server"
 msgid ""
 "Some tasks need more memory than allowed by your preferences.  Please check "
 "the preferences."
-msgstr "Alcuni lavori richiedono più memoria di quella resa disponibile dalle tue preferenze.  Per favore controllale."
+msgstr "Alcune workunit richiedono più memoria RAM di quanta ne sia permessa dalle tue preferenze. Se vuoi eseguirle devi aumentare il limite massimo."
 
 #: client_state.cpp:520
 msgid "Couldn't write state file; check directory permissions"
-msgstr "Non posso scrivere il file di stato; controlla i permessi della cartella"
+msgstr "Impossibile scrivere il file di stato; controllare i permessi della cartella"
 
 #: cs_cmdline.cpp:303
 msgid "The HTTP_PROXY environment variable must specify an HTTP proxy"
-msgstr "La variabile di ambiente HTTP_PROXY deve specificare un proxy HTTP"
+msgstr "La variabile d'ambiente HTTP_PROXY deve specificare un proxy HTTP"
 
 #: cs_scheduler.cpp:613
 #, c-format
 msgid ""
 "You used the wrong URL for this project.  When convenient, remove this "
 "project, then add %s"
-msgstr "Hai usato l'URL sbagliato per questo progetto.  Quando hai tempo, rimuovi questo progetto, poi aggiungi %s"
+msgstr "Stai usando l'URL sbagliato per questo progetto. Quando possibile rimuovi questo progetto, poi connettiti a %s"
 
 #: cs_statefile.cpp:828 ../sched/sched_types.cpp:259
 msgid "Syntax error in app_info.xml"
@@ -64,7 +64,7 @@ msgstr "Scarica"
 
 #: log_flags.cpp:269 log_flags.cpp:449
 msgid "Unexpected text in cc_config.xml"
-msgstr "Testo inaspettato nel file cc_config.xml"
+msgstr "Testo non leggibile presente nel file cc_config.xml"
 
 #: log_flags.cpp:423 log_flags.cpp:475
 msgid "Unrecognized tag in cc_config.xml"
@@ -72,7 +72,7 @@ msgstr "Tag non riconosciuto nel file cc_config.xml"
 
 #: log_flags.cpp:440
 msgid "Missing start tag in cc_config.xml"
-msgstr "Tag di inizio mancante nel file cc_config.xml"
+msgstr "Tag di apertura mancante nel file cc_config.xml"
 
 #: log_flags.cpp:465
 msgid "Error in cc_config.xml options"
@@ -80,63 +80,63 @@ msgstr "Errore nel file cc_config.xml"
 
 #: log_flags.cpp:483
 msgid "Missing end tag in cc_config.xml"
-msgstr "Tag di fine mancante nel file cc_config.xml"
+msgstr "Tag di chiusura mancante nel file cc_config.xml"
 
 #: ../sched/handle_request.cpp:307
 msgid "Invalid or missing account key.  To fix, remove and add this project."
-msgstr "Chiave account invalida o mancante.  Per risolvere, disconnetti e riconnetti questo progetto."
+msgstr "Account key sbagliata o mancante. Per risolvere il problema rimuovi il progetto e poi riconnettilo."
 
 #: ../sched/handle_request.cpp:849
 msgid "Invalid code signing key.  To fix, remove and add this project."
-msgstr "Codice di chiave account invalido.  Per risolvere, disconnetti e riconnetti questo progetto."
+msgstr "Account key invalida. Per risolvere rimuovi il progetto e poi riconnettilo."
 
 #: ../sched/handle_request.cpp:859
 msgid ""
 "The project has changed its security key.  Please remove and add this "
 "project."
-msgstr "Il progetto ha modificato la sua chiave di sicurezza.  Per favore disconnetti e riconnetti questo progetto."
+msgstr "Il progetto ha modificato la sua chiave di sicurezza. Per risolvere il problema rimuovi il progetto e poi riconnettilo."
 
 #: ../sched/handle_request.cpp:943
 msgid "This project doesn't support operating system"
-msgstr "Il progetto non supporta questo sistema operativo"
+msgstr "Il progetto non supporta il sistema operativo"
 
 #: ../sched/handle_request.cpp:969
 msgid "This project doesn't support CPU type"
-msgstr "Il progetto non supporta questo tipo di CPU"
+msgstr "Il progetto non supporta le CPU"
 
 #: ../sched/handle_request.cpp:993
 msgid ""
 "Your BOINC client software is too old.  Please install the current version."
-msgstr "Una versione di BOINC più recente è richiesta.  Per favore installa la versione corrente."
+msgstr "È disponibile una nuova versione del client BOINC. Se favore installala."
 
 #: ../sched/handle_request.cpp:1259
 msgid "This project doesn't support computers of type"
-msgstr "Il progetto non supporta questo tipo di computer"
+msgstr "Il progetto non supporta i computer"
 
 #: ../sched/sched_send.cpp:1092
 msgid ""
 "Upgrade to the latest driver to process tasks using your computer's GPU"
-msgstr "Aggiorna i driver all'ultima versione per eseguire i lavori che utilizzano la GPU del tuo computer"
+msgstr "Aggiorna i driver della scheda video all'ultima versione per \npoter processare le workunit che utilizzano la GPU del computer"
 
 #: ../sched/sched_send.cpp:1099
 msgid ""
 "Upgrade to the latest driver to use all of this project's GPU applications"
-msgstr "Aggiorna i driver all'ultima versione per eseguire le applicazioni di questo progetto che utilizzano la GPU"
+msgstr "Aggiorna i driver della scheda video per poter eseguire le tutte le applicazioni GPU di questo progetto"
 
 #: ../sched/sched_send.cpp:1118
 msgid ""
 "A newer version of BOINC is needed to use your NVIDIA GPU; please upgrade to"
 " the current version"
-msgstr "Una nuova versione di BOINC è necessaria per usare la tua GPU NVIDIA; per favore aggiorna alla versione corrente"
+msgstr "La versione di BOINC installata non permette l'uso della GPU Nvidia. Per risolvere il problema scarica l'ultima versione di BOINC."
 
 #: ../sched/sched_send.cpp:1146
 #, c-format
 msgid "An %s GPU is required to run tasks for this project"
-msgstr "Una GPU %s è richiesta per eseguire i lavori di questo progetto"
+msgstr "È necessaria una GPU %s per eseguire le applicazioni di questo progetto"
 
 #: ../sched/sched_send.cpp:1262
 msgid "No tasks are available for the applications you have selected."
-msgstr "Nessun lavoro è disponibile per le applicazioni selezionate."
+msgstr "Nessuna workunit è disponibile per le applicazioni selezionate."
 
 #: ../sched/sched_send.cpp:1288
 msgid "Your computer type is not supported by this project"
@@ -144,18 +144,18 @@ msgstr "Il tuo tipo di computer non è supportato da questo progetto"
 
 #: ../sched/sched_send.cpp:1294
 msgid "Newer BOINC version required; please install current version"
-msgstr "Una versione di BOINC più recente è richiesta; per favore installa la versione corrente"
+msgstr "È richiesta una versione di BOINC più recente; per favore installa l'ultima versione"
 
 #: ../sched/sched_send.cpp:1305
 #, c-format
 msgid ""
 "Tasks for %s are available, but your preferences are set to not accept them"
-msgstr "Lavori per %s sono disponibili, ma le tue preferenze sono impostate per non accettarli"
+msgstr "Sono disponibili delle workunit per %s, ma le tue preferenze sono impostate per non accettarle"
 
 #: ../sched/sched_types.cpp:254
 msgid "Unknown app name in app_info.xml"
-msgstr "Nome sconosciuto di app nel file app_info.xml"
+msgstr "App name sconosciuto nel file app_info.xml"
 
 #: ../sched/sched_version.cpp:214
 msgid "Your app_info.xml file doesn't have a usable version of"
-msgstr "Il tuo file app_info.xml non ha una versione utilizzabile di"
+msgstr "Il file app_info.xml non ha una versione utilizzabile di"
diff --git a/locale/it_IT/BOINC-Drupal.po b/locale/it_IT/BOINC-Drupal.po
index 4db4620..5cabfc6 100644
--- a/locale/it_IT/BOINC-Drupal.po
+++ b/locale/it_IT/BOINC-Drupal.po
@@ -9,8 +9,8 @@ msgid ""
 msgstr ""
 "Project-Id-Version: BOINC\n"
 "POT-Creation-Date: 2015-08-14 09:37+0000\n"
-"PO-Revision-Date: 2015-11-07 20:25+0000\n"
-"Last-Translator: Gianfranco Costamagna <costamagnagianfranco at yahoo.it>\n"
+"PO-Revision-Date: 2015-11-17 11:11+0000\n"
+"Last-Translator: Sebastiano Pistore <olatusrooc at virgilio.it>\n"
 "Language-Team: Italian (Italy) (http://www.transifex.com/boinc/boinc/language/it_IT/)\n"
 "MIME-Version: 1.0\n"
 "Content-Type: text/plain; charset=UTF-8\n"
diff --git a/locale/it_IT/BOINC-Manager.mo b/locale/it_IT/BOINC-Manager.mo
index 7a26e27..95eceaa 100644
Binary files a/locale/it_IT/BOINC-Manager.mo and b/locale/it_IT/BOINC-Manager.mo differ
diff --git a/locale/it_IT/BOINC-Manager.po b/locale/it_IT/BOINC-Manager.po
index f122d84..58f0cc2 100644
--- a/locale/it_IT/BOINC-Manager.po
+++ b/locale/it_IT/BOINC-Manager.po
@@ -5,13 +5,14 @@
 # Translators:
 # Alessandro Dalla Rosa <exit96dalla at gmail.com>, 2015
 # Gianfranco Costamagna <costamagnagianfranco at yahoo.it>, 2015
+# Sebastiano Pistore <olatusrooc at virgilio.it>, 2015
 msgid ""
 msgstr ""
 "Project-Id-Version: BOINC\n"
 "Report-Msgid-Bugs-To: \n"
 "POT-Creation-Date: 2015-10-16 17:27-0500\n"
-"PO-Revision-Date: 2015-10-22 19:31+0000\n"
-"Last-Translator: Alessandro Dalla Rosa <exit96dalla at gmail.com>\n"
+"PO-Revision-Date: 2015-11-20 09:10+0000\n"
+"Last-Translator: Sebastiano Pistore <olatusrooc at virgilio.it>\n"
 "Language-Team: Italian (Italy) (http://www.transifex.com/boinc/boinc/language/it_IT/)\n"
 "MIME-Version: 1.0\n"
 "Content-Type: text/plain; charset=UTF-8\n"
@@ -37,7 +38,7 @@ msgstr "Identifica il tuo account su %s"
 msgid ""
 "Please enter your account information\n"
 "(to create an account, visit the project's web site)"
-msgstr "Inserisci i dati del tuo account\n(per creare un account, visita il sito web del progetto)"
+msgstr "Inserisci i dati del tuo account\n(per creare un nuovo account visita il sito web del progetto)"
 
 #: clientgui/AccountInfoPage.cpp:371
 msgid ""
@@ -162,7 +163,7 @@ msgstr "Per selezionare un account manager, clicca sul suo nome o \ndigita il su
 
 #: clientgui/AccountManagerInfoPage.cpp:277
 msgid "Account manager details:"
-msgstr "Sito web dell'account manager:"
+msgstr "Dettagli dell'account manager:"
 
 #: clientgui/AccountManagerInfoPage.cpp:281
 msgid "Account manager &URL:"
@@ -174,7 +175,7 @@ msgstr "Apri la pagina web"
 
 #: clientgui/AccountManagerInfoPage.cpp:288
 msgid "Visit this account manager's web site"
-msgstr "Visita il sito web del gestore account"
+msgstr "Visita il sito web del tuo account manager"
 
 #. %s is the project name
 #. i.e. 'BOINC', 'GridRepublic'
@@ -419,7 +420,7 @@ msgstr "Sospendi l'elaborazione della GPU indipendentemente dalle preferenze"
 
 #: clientgui/AdvancedFrame.cpp:584
 msgid "Network activity always"
-msgstr "Permetti sempre la comunicazione di rete"
+msgstr "Permetti sempre le comunicazioni di rete"
 
 #: clientgui/AdvancedFrame.cpp:585
 msgid "Allow network activity regardless of preferences"
@@ -521,7 +522,7 @@ msgstr "Mostra le informazioni sul %s"
 #: clientgui/AdvancedFrame.cpp:675 clientgui/sg_BoincSimpleFrame.cpp:247
 #, c-format
 msgid "%s &web site"
-msgstr "sito &web di %s"
+msgstr "Sito &web di %s"
 
 #: clientgui/AdvancedFrame.cpp:679 clientgui/sg_BoincSimpleFrame.cpp:251
 #, c-format
@@ -625,7 +626,7 @@ msgid ""
 "different password than the one you entered.\n"
 "\n"
 "Please visit the project's web site and follow the instructions there."
-msgstr "Un account con il nome utente specificato esiste già e ha una\npassword diversa da quella appena inserita.\n\nVisita il sito web del progetto e segui le istruzioni riportate."
+msgstr "Un account con il nome utente specificato esiste già ed ha una\npassword diversa da quella appena inserita.\n\nVisita il sito web del progetto e segui le istruzioni riportate."
 
 #: clientgui/AlreadyExistsPage.cpp:191
 msgid "Email address already in use"
@@ -637,7 +638,7 @@ msgid ""
 "different password than the one you entered.\n"
 "\n"
 "Please visit the project's web site and follow the instructions there."
-msgstr "Un account con l'indirizzo e-mail specificato esiste già e ha una\npassword diversa da quella appena inserita.\n\nVisita il sito web del progetto e segui le istruzioni riportate."
+msgstr "Un account con l'indirizzo e-mail specificato esiste già ed ha una\npassword diversa da quella appena inserita.\n\nVisita il sito web del progetto e segui le istruzioni riportate."
 
 #: clientgui/AsyncRPC.cpp:1031
 msgid "Communicating with BOINC client.  Please wait ..."
@@ -748,7 +749,7 @@ msgstr "%s - Disconnessione Inaspettata "
 msgid ""
 "The %s client has exited unexpectedly 3 times within the last %d minutes.\n"
 "Would you like to restart it again?"
-msgstr "Il client %s si è disconnesso in modo imprevisto 3 volte negli ultimi %d minuti.\nVuoi ricollegarti?"
+msgstr "Il client %s si è disconnesso in modo imprevisto tre volte negli ultimi %d minuti.\nVuoi ricollegarti?"
 
 #: clientgui/BOINCDialupManager.cpp:61
 #, c-format
@@ -827,7 +828,7 @@ msgstr ")"
 msgid ""
 "A reboot is required in order for BOINC to run properly.\n"
 "Please reboot your computer and try again."
-msgstr "Per un corretto funzionamento di BOINC è necessario riavviare il sistema.\nRiavvia e prova nuovamente."
+msgstr "Per un corretto funzionamento di BOINC è necessario riavviare il sistema.\nPer favore riavvia e prova nuovamente."
 
 #: clientgui/BOINCGUIApp.cpp:402 clientgui/DlgAbout.cpp:153
 msgid "BOINC Manager"
@@ -835,7 +836,7 @@ msgstr "BOINC Manager"
 
 #: clientgui/BOINCGUIApp.cpp:664
 msgid "BOINC Manager was started by the operating system automatically"
-msgstr "BOINC Manager è stato avviato dal sistema operativo in modo automatico"
+msgstr "BOINC Manager è stato avviato automaticamente dal sistema operativo"
 
 #: clientgui/BOINCGUIApp.cpp:666
 msgid "Startup BOINC so only the system tray icon is visible"
@@ -851,7 +852,7 @@ msgstr "Cartella dei dati di BOINC"
 
 #: clientgui/BOINCGUIApp.cpp:671
 msgid "Host name or IP address"
-msgstr "Nome del host o indirizzo IP"
+msgstr "Nome dell'host o indirizzo IP"
 
 #: clientgui/BOINCGUIApp.cpp:672
 msgid "GUI RPC port number"
@@ -859,7 +860,7 @@ msgstr "Numero della porta GUI RPC"
 
 #: clientgui/BOINCGUIApp.cpp:673
 msgid "Password"
-msgstr "Chiave d'accesso"
+msgstr "Password"
 
 #: clientgui/BOINCGUIApp.cpp:674
 msgid "Startup BOINC with these optional arguments"
@@ -875,7 +876,7 @@ msgstr "imposta la modalità di debug per la visualizzazione per abilitarne i me
 
 #: clientgui/BOINCGUIApp.cpp:677
 msgid "multiple instances of BOINC Manager allowed"
-msgstr "Sono consentite istanze multiple del BOINC Manager"
+msgstr "Permetti istanze multiple di BOINC Manager"
 
 #: clientgui/BOINCGUIApp.cpp:679
 msgid "Not used: workaround for bug in XCode 4.2"
@@ -888,7 +889,7 @@ msgstr "Non eseguire il demone"
 #. These are just special tags so deal with them in a special way
 #: clientgui/BOINCGUIApp.cpp:931
 msgid "(Automatic Detection)"
-msgstr "(Rilevazione automatica)"
+msgstr "(Rilevamento automatico)"
 
 #: clientgui/BOINCGUIApp.cpp:932
 msgid "(Unknown)"
@@ -896,7 +897,7 @@ msgstr "(Sconosciuto)"
 
 #: clientgui/BOINCGUIApp.cpp:933
 msgid "(User Defined)"
-msgstr "(Stabilito dall'utente)"
+msgstr "(Definito dall'utente)"
 
 #: clientgui/BOINCTaskBar.cpp:519
 #, c-format
@@ -943,11 +944,11 @@ msgstr "L'elaborazione è sospesa -"
 
 #: clientgui/BOINCTaskBar.cpp:726
 msgid "GPU computing is enabled"
-msgstr "L'elaborazione della GPU è abilitata"
+msgstr "L'elaborazione con la GPU è abilitata"
 
 #: clientgui/BOINCTaskBar.cpp:729
 msgid "GPU computing is suspended - "
-msgstr "L'elaborazione della GPU è sospesa -."
+msgstr "L'elaborazione con la GPU è sospesa -."
 
 #: clientgui/BOINCTaskBar.cpp:738
 msgid "Network is enabled"
@@ -972,11 +973,11 @@ msgstr "Avvisi di %s"
 
 #: clientgui/BOINCTaskBar.cpp:810
 msgid "There are new notices - click to view."
-msgstr "Ci sono nuovi avvisi - clicca per vederli."
+msgstr "Ci sono nuovi avvisi, clicca per vederli."
 
 #: clientgui/CompletionErrorPage.cpp:199
 msgid "Failed to add project"
-msgstr "Impossibile aggiungere il progetto"
+msgstr "Impossibile connettere il progetto"
 
 #: clientgui/CompletionErrorPage.cpp:204
 msgid "Failed to update account manager"
@@ -1032,7 +1033,7 @@ msgstr "Aggiornamento completato."
 #. Attach Completed
 #: clientgui/CompletionPage.cpp:247
 msgid "Now using account manager"
-msgstr "Ora, stai utilizzando l'account manager"
+msgstr "Ora stai utilizzando l'account manager"
 
 #: clientgui/CompletionPage.cpp:252
 #, c-format
@@ -1077,7 +1078,7 @@ msgstr "BOINC è distribuito sotto licenza GNU Lesser General Public License v3.
 
 #: clientgui/DlgAbout.cpp:203
 msgid "For more information, visit "
-msgstr "Per ulteriori informazioni, visita"
+msgstr "Per ulteriori informazioni visita"
 
 #: clientgui/DlgAbout.cpp:215 clientgui/DlgExitMessage.cpp:173
 #: clientgui/DlgGenericMessage.cpp:120 clientgui/DlgOptions.cpp:410
@@ -1091,7 +1092,7 @@ msgstr "Numero non valido"
 
 #: clientgui/DlgAdvPreferences.cpp:685 clientgui/sg_DlgPreferences.cpp:776
 msgid "Invalid time, value must be between 0:00 and 24:00, format is HH:MM"
-msgstr "Tempo non valido, il valore deve essere compreso tra 0:00 e 24:00, il formato è HH:MM"
+msgstr "Tempo non valido, il valore deve essere compreso tra 00:00 e 24:00. Il formato è HH:MM"
 
 #: clientgui/DlgAdvPreferences.cpp:686 clientgui/sg_DlgPreferences.cpp:777
 msgid "Start time must be different from end time"
@@ -1155,7 +1156,7 @@ msgstr "Ripristina le preferenze web e chiudi la finestra."
 #: clientgui/DlgAdvPreferencesBase.cpp:140
 #: clientgui/DlgAdvPreferencesBase.cpp:684
 msgid "Computing"
-msgstr "Computazione"
+msgstr "Elaborazione"
 
 #. Network schedule
 #: clientgui/DlgAdvPreferencesBase.cpp:143
@@ -1194,7 +1195,7 @@ msgstr "Aiuto"
 
 #: clientgui/DlgAdvPreferencesBase.cpp:174
 msgid "Shows the preferences web page."
-msgstr "Mostra la pagina web sulle preferenze"
+msgstr "Mostra la pagina web delle preferenze."
 
 #: clientgui/DlgAdvPreferencesBase.cpp:236
 #: clientgui/DlgAdvPreferencesBase.cpp:463
@@ -1270,7 +1271,7 @@ msgstr "Questo determina quando il computer è considerato 'in uso'."
 #. context: 'In use' means mouse/keyboard input in last ___ minutes
 #: clientgui/DlgAdvPreferencesBase.cpp:304 clientgui/sg_DlgPreferences.cpp:268
 msgid "'In use' means mouse/keyboard input in last"
-msgstr "'In uso' significa attività di mouse e tastiera"
+msgstr "'In uso' significa che c'è attività di mouse o tastiera"
 
 #. context: 'In use' means mouse/keyboard input in last ___ minutes
 #. context: Switch between tasks every ___ minutes
@@ -1323,7 +1324,7 @@ msgstr "Archivia elaborazioni addizionali sopra la soglia minima. Determina quan
 #. context: Store up to an additional ___ days of work
 #: clientgui/DlgAdvPreferencesBase.cpp:380
 msgid "Store up to an additional"
-msgstr "Memorizza fino ad ulteriori"
+msgstr "Scarica fino ad ulteriori"
 
 #: clientgui/DlgAdvPreferencesBase.cpp:399
 #, c-format
@@ -1403,7 +1404,7 @@ msgstr "Spunta questa voce solo se il tuo provider Internet modifica i file imma
 
 #: clientgui/DlgAdvPreferencesBase.cpp:524
 msgid "Skip data verification for image files"
-msgstr "Salta la verifica dati per i file immagine"
+msgstr "Salta la verifica dati dei file immagine"
 
 #: clientgui/DlgAdvPreferencesBase.cpp:528
 msgid "Confirm before connecting to Internet"
@@ -1446,7 +1447,7 @@ msgstr "GB"
 msgid ""
 "Limit disk usage to leave this much free space on the volume where %s stores"
 " data."
-msgstr "Limita l'utilizzo disco per lasciare questo spazio libero nel luogo dove %s salva i dati."
+msgstr "Limita l'utilizzo disco per lasciare questo spazio libero nel disco dove %s salva i dati."
 
 #: clientgui/DlgAdvPreferencesBase.cpp:585
 msgid "Leave at least"
@@ -1589,12 +1590,12 @@ msgstr "Trasferisci files solo tra"
 #: clientgui/DlgDiagnosticLogFlags.cpp:65
 #, c-format
 msgid "%s Diagnostic Log Flags"
-msgstr "%s Flag di Log Diagnostici"
+msgstr "%s Flag dei log di diagnostica"
 
 #: clientgui/DlgDiagnosticLogFlags.cpp:83
 msgid ""
 "These flags enable various types of diagnostic messages in the Event Log."
-msgstr "Questi flag abilitano vari tipi di messaggi di diagnostica nel Log Eventi."
+msgstr "Questi flag abilitano vari tipi di messaggi di diagnostica nel Log degli eventi."
 
 #: clientgui/DlgDiagnosticLogFlags.cpp:99
 msgid "More info ..."
@@ -1619,7 +1620,7 @@ msgstr "Chiudi la finestra senza salvare"
 #: clientgui/DlgEventLog.cpp:236
 #, c-format
 msgid "%s - Event Log"
-msgstr "%s - Log Eventi"
+msgstr "%s - Log degli eventi"
 
 #. Create List Pane Items
 #: clientgui/DlgEventLog.cpp:246 clientgui/ViewMessages.cpp:117
@@ -1643,7 +1644,7 @@ msgstr "Mostra &solo questo progetto"
 
 #: clientgui/DlgEventLog.cpp:309
 msgid "Copy &All"
-msgstr "Copi&a Tutto"
+msgstr "Copi&a tutto"
 
 #: clientgui/DlgEventLog.cpp:311 clientgui/DlgEventLog.cpp:315
 #: clientgui/ViewMessages.cpp:89
@@ -1652,7 +1653,7 @@ msgstr "Copia tutti i messaggi negli appunti."
 
 #: clientgui/DlgEventLog.cpp:320
 msgid "Copy &Selected"
-msgstr "Copia &Selezionati"
+msgstr "Copia i &selezionati"
 
 #: clientgui/DlgEventLog.cpp:323 clientgui/DlgEventLog.cpp:331
 #: clientgui/ViewMessages.cpp:97
@@ -1689,7 +1690,7 @@ msgstr "Mostra solamente i messaggi del progetto selezionato"
 #: clientgui/DlgExclusiveApps.cpp:60
 #, c-format
 msgid "%s - Exclusive Applications"
-msgstr "%s - Applicazioni Esclusive"
+msgstr "%s - Applicazioni esclusive"
 
 #: clientgui/DlgExclusiveApps.cpp:72
 msgid ""
@@ -1715,7 +1716,7 @@ msgstr "Rimuovi applicazione dalla lista"
 
 #: clientgui/DlgExclusiveApps.cpp:96
 msgid "Suspend GPU usage when these applications are running:"
-msgstr "Sospendi l'utilizzo GPU quando queste applicazioni sono in funzione:"
+msgstr "Sospendi l'utilizzo GPU quando queste applicazioni sono in esecuzione:"
 
 #: clientgui/DlgExclusiveApps.cpp:122
 msgid "For advanced options, refer to "
@@ -1731,7 +1732,7 @@ msgstr "chiudi la finestra senza salvare"
 
 #: clientgui/DlgExclusiveApps.cpp:158
 msgid "shows the preferences web page"
-msgstr "mostra la pagina web di aiuto sulle preferenze"
+msgstr "mostra la pagina web di settaggio delle preferenze"
 
 #. TODO: fill in the default directory for MSW
 #. TODO: fill in the default directory for Linux
@@ -1909,7 +1910,7 @@ msgstr "Uso del disco"
 
 #: clientgui/DlgItemProperties.cpp:266
 msgid "Computer ID"
-msgstr "Computer ID"
+msgstr "ID del computer"
 
 #: clientgui/DlgItemProperties.cpp:268
 msgid "Non CPU intensive"
@@ -1932,7 +1933,7 @@ msgstr "no"
 
 #: clientgui/DlgItemProperties.cpp:271
 msgid "Don't request tasks"
-msgstr "Non richiedere elaborazioni"
+msgstr "Non richiedere workunit"
 
 #: clientgui/DlgItemProperties.cpp:273
 msgid "Scheduler call in progress"
@@ -1981,7 +1982,7 @@ msgstr "Utente"
 #: clientgui/DlgItemProperties.cpp:300 clientgui/DlgItemProperties.cpp:308
 #, c-format
 msgid "%s total, %s average"
-msgstr "% totale, % media"
+msgstr "%s totale, %s media"
 
 #: clientgui/DlgItemProperties.cpp:305
 msgid "Host"
@@ -2037,7 +2038,7 @@ msgstr "Risorse in uso"
 
 #: clientgui/DlgItemProperties.cpp:385
 msgid "Estimated computation size"
-msgstr "Durata stimata lavoro"
+msgstr "Durata stimata dell'elaborazione"
 
 #: clientgui/DlgItemProperties.cpp:390
 msgid "CPU time at last checkpoint"
@@ -2358,7 +2359,7 @@ msgstr "Riporta i problemi"
 
 #: clientgui/Localization.cpp:79
 msgid "A link to the Einstein at Home problems and bug reports message board"
-msgstr "Collegamento al forum per i problemi ed i bug di Einstein at Home"
+msgstr "Riepilogo dei problemi di Einstein at Home e segnalazione bug"
 
 #: clientgui/Localization.cpp:83
 msgid "View and modify your Einstein at Home account profile and preferences"
@@ -2694,15 +2695,15 @@ msgstr "Autenticazione fallita."
 
 #: clientgui/NotFoundPage.cpp:185
 msgid "Check the username and password, and try again."
-msgstr "Controlla nome utente e password poi riprova."
+msgstr "Controlla nome utente e password, poi riprova."
 
 #: clientgui/NotFoundPage.cpp:189
 msgid "Check the email address and password, and try again."
-msgstr "Controlla l'indirizzo e-mail e la password poi riprova"
+msgstr "Controlla l'indirizzo e-mail e la password, poi riprova."
 
 #: clientgui/NoticeListCtrl.cpp:229
 msgid "more..."
-msgstr "ancora..."
+msgstr "Vuoi saperne di più?"
 
 #: clientgui/ProjectInfoPage.cpp:221
 msgid "Choose a project"
@@ -2722,7 +2723,7 @@ msgstr "Progetti:"
 
 #: clientgui/ProjectInfoPage.cpp:274
 msgid "Project details"
-msgstr "Dettagli progetto"
+msgstr "Dettagli sul progetto"
 
 #: clientgui/ProjectInfoPage.cpp:284
 msgid "Research area:"
@@ -3217,7 +3218,7 @@ msgstr "Non richiedere nuovo lavoro"
 
 #: clientgui/ViewProjects.cpp:1158
 msgid "Project ended - OK to remove"
-msgstr "Progetto concluso. E' possibile rimuoverlo senza conseguenze."
+msgstr "Progetto concluso. È possibile rimuoverlo senza conseguenze."
 
 #: clientgui/ViewProjects.cpp:1161
 msgid "Will remove when tasks done"
@@ -3679,11 +3680,11 @@ msgstr "Predefinito"
 
 #: clientgui/sg_BoincSimpleFrame.cpp:895
 msgid "Suspend Computing"
-msgstr "Sospendi Lavoro"
+msgstr "Sospendi l'elaborazione"
 
 #: clientgui/sg_BoincSimpleFrame.cpp:896
 msgid "Resume Computing"
-msgstr "Riprendi Lavoro"
+msgstr "Riprendi l'elaborazione"
 
 #: clientgui/sg_BoincSimpleFrame.cpp:913
 msgid "Open a window to view notices from projects or BOINC"
@@ -3719,7 +3720,7 @@ msgstr "%s - Preferenze di Elaborazione"
 
 #: clientgui/sg_DlgPreferences.cpp:1186
 msgid "Discard all local preferences and use web-based preferences?"
-msgstr "Scartare tutte le preferenze locali e utilizzare le preferenze web?"
+msgstr "Cancellare tutte le preferenze locali e utilizzare le preferenze web?"
 
 #: clientgui/sg_ProjectPanel.cpp:72
 msgid "Add Project"
@@ -3757,7 +3758,7 @@ msgstr "Comandi del Progetto"
 #: clientgui/sg_ProjectPanel.cpp:278
 #, c-format
 msgid "Pop up a menu of web sites for project %s"
-msgstr "Apri una finestra con i siti web per il progetto %s"
+msgstr "Apri una finestra con i siti web del progetto %s"
 
 #: clientgui/sg_ProjectPanel.cpp:280
 #, c-format
diff --git a/locale/it_IT/BOINC-Project-Generic.po b/locale/it_IT/BOINC-Project-Generic.po
index 84203c9..bf52574 100644
--- a/locale/it_IT/BOINC-Project-Generic.po
+++ b/locale/it_IT/BOINC-Project-Generic.po
@@ -14,7 +14,7 @@ msgstr ""
 "Project-Id-Version: BOINC\n"
 "Report-Msgid-Bugs-To: BOINC translation team <boinc_loc at boinc.berkeley.edu>\n"
 "POT-Creation-Date: 2015-06-24 13:05 PDT\n"
-"PO-Revision-Date: 2015-11-07 20:30+0000\n"
+"PO-Revision-Date: 2015-11-18 13:06+0000\n"
 "Last-Translator: Sebastiano Pistore <olatusrooc at virgilio.it>\n"
 "Language-Team: Italian (Italy) (http://www.transifex.com/boinc/boinc/language/it_IT/)\n"
 "MIME-Version: 1.0\n"
@@ -169,7 +169,7 @@ msgstr "Colore del carattere"
 #: ../inc/bbcode_html.inc:46
 msgid ""
 "Font color: [color=red]text[/color]  Tip: you can also use color=#FF0000"
-msgstr "Colore del carattere: [color=red]testo[/color] Suggerimento: puoi anche usare color=#FF0000"
+msgstr "Colore del carattere: [color=red]testo[/color] Suggerimento: puoi anche definire un colore personalizzato nella forma color=#FF0000"
 
 #: ../inc/bbcode_html.inc:47 ../inc/bbcode_html.inc:62
 #: ../inc/prefs_util.inc:546
@@ -178,7 +178,7 @@ msgstr "Predefinito"
 
 #: ../inc/bbcode_html.inc:48
 msgid "Dark Red"
-msgstr "Rosso Scuro"
+msgstr "Rosso scuro"
 
 #: ../inc/bbcode_html.inc:49
 msgid "Red"
@@ -690,7 +690,7 @@ msgstr "Ora locale"
 
 #: ../inc/host.inc:101
 msgid "UTC %1 hours"
-msgstr "UTC %1 ore"
+msgstr "ore UTC %1"
 
 #: ../inc/host.inc:105 ../inc/host.inc:107 ../inc/host.inc:222
 msgid "Owner"
@@ -918,7 +918,7 @@ msgstr "Sistema operativo"
 
 #: ../inc/host.inc:320
 msgid "(%1 processors)"
-msgstr "(%1 dei processori)"
+msgstr "(%1 processori)"
 
 #: ../inc/host.inc:340
 msgid "Details"
@@ -1357,7 +1357,7 @@ msgstr "Salta la verifica dei dati per le immagini"
 msgid ""
 "Check this only if your Internet provider modifies image files. Skipping "
 "verification reduces the security of BOINC."
-msgstr "Spunta questa voce solo se il tuo provider Internet modifica i files immagine. Saltare la verifica riduce la sicurezza di BOINC."
+msgstr "Spunta questa voce solo se il tuo provider Internet modifica i file immagine. Saltare la verifica riduce la sicurezza di BOINC."
 
 #: ../inc/prefs.inc:222
 msgid "Confirm before connecting to Internet"
@@ -1393,7 +1393,7 @@ msgstr "Queste preferenze si applicano a tutti i progetti BOINC ai quali parteci
 msgid ""
 "%1Unable to update preferences.%2 The values marked in red below were out of"
 " range or not numeric."
-msgstr "%1Impossibile aggiornare le preferenze.%2 I valori segnati in rosso erano fuori dall'intervallo consentito o non erano numerici."
+msgstr "%1Impossibile aggiornare le preferenze.%2 I valori segnati in rosso sono fuori dall'intervallo consentito o non sono numerici."
 
 #: ../inc/prefs.inc:472
 msgid "computing"
@@ -2440,7 +2440,7 @@ msgstr "Stato del server"
 msgid ""
 "A database error occurred while handling your request; please try again "
 "later."
-msgstr "Si è verificato un errore del database mentre si gestiva la tua richiesta; per favore riprova più tardi."
+msgstr "Si è verificato un errore del database durante l'elaborazione della richiesta; per favore riprova più tardi."
 
 #: ../inc/util.inc:286
 msgid "Unable to handle request"
@@ -2781,7 +2781,7 @@ msgstr "Il profilo è stato salvato"
 #: ../user/create_profile.php:306
 msgid ""
 "Congratulations! Your profile was successfully entered into our database."
-msgstr "Congratulazioni! Il tuo profilo è stato inserito con successo nel nostro database."
+msgstr "Congratulazioni! Il tuo profilo è stato inserito con successo nel database."
 
 #: ../user/create_profile.php:309
 msgid "View your profile"
@@ -2878,7 +2878,7 @@ msgid ""
 "Deleted profiles are gone forever and cannot be recovered --\n"
 "you will have to start from scratch\n"
 "if you want another profile in the future."
-msgstr "I profili cancellati sono perduti per sempre e non possono essere ripristinati --\ndovrai ricominciare dall'inizio\nse vorrai un altro profilo in futuro."
+msgstr "I profili cancellati sono perduti per sempre e non possono essere ripristinati:\ndovrai ricominciare dall'inizio\nse vorrai un altro profilo in futuro."
 
 #: ../user/delete_profile.php:50
 msgid ""
@@ -3148,7 +3148,7 @@ msgid ""
 "Check out %1various free services%2\n"
 "<br> providing dynamic 'signature images'\n"
 "<br> showing your latest credit info, project news, etc."
-msgstr "Controlla %1 servizi gratuiti%2\n<br> che forniscono 'immagini da firma' dinamiche\n<br> che mostrano informazioni sui tuoi crediti recenti, notizie del progetto, etc."
+msgstr "Dai un'occhiati ai %1 servizi gratuiti%2\n<br> che forniscono 'immagini per le firme dinamiche' da usare nei forum, social, ecc...\n<br> e che mostrano informazioni sui tuoi crediti recenti, notizie dei progetto ed altro."
 
 #: ../user/edit_forum_preferences_form.php:93
 msgid "Attach signature by default"
@@ -3924,7 +3924,7 @@ msgstr "Questa funziona è disabilitata dal progetto"
 
 #: ../user/forum_rate.php:60
 msgid "You need more average or total credit to rate a post."
-msgstr "Ti serve un credito medio o totale maggiore per votare un post."
+msgstr "Ti serve un credito medio o totale maggiore per poter votare un post."
 
 #: ../user/forum_rate.php:64
 msgid "You have already rated this post."
@@ -3990,7 +3990,7 @@ msgstr "Ti serve più credito medio o totale per segnalare un post."
 
 #: ../user/forum_report_post.php:68
 msgid "Report Registered"
-msgstr "Segnalazione Registrata"
+msgstr "Segnalazione registrata"
 
 #: ../user/forum_report_post.php:69
 msgid "Your report has been recorded. Thanks for your input."
@@ -4207,11 +4207,11 @@ msgstr "Questo thread è stato nascosto dai moderatori."
 
 #: ../user/forum_thread.php:129
 msgid "My question was answered"
-msgstr "E' stata data risposta alla mia domanda"
+msgstr "È stata data risposta alla mia domanda"
 
 #: ../user/forum_thread.php:130
 msgid "Click here if your question has been adequately answered"
-msgstr "Se è stata data una adeguata risposta alla tua domanda, sei pregato di premere qui."
+msgstr "Se è stata data un'adeguata risposta alla tua domanda, sei pregato di premere qui."
 
 #: ../user/forum_thread.php:138
 msgid "I've also got this question"
@@ -4660,7 +4660,7 @@ msgstr "Aggiornamento crediti del computer"
 
 #: ../user/host_update_credit.php:37
 msgid "Host credit updated"
-msgstr "Crediti Host aggiornati"
+msgstr "Crediti degli host aggiornati"
 
 #: ../user/host_venue_action.php:41
 msgid "Host venue updated"
@@ -5762,11 +5762,11 @@ msgstr "Tempo minimo tra i messaggi (secondi)"
 
 #: ../user/team_forum.php:76
 msgid "Minimum total credit to post"
-msgstr "Credito totale minimo per scrivere"
+msgstr "Credito totale minimo necessario per scrivere"
 
 #: ../user/team_forum.php:79
 msgid "Minimum average credit to post"
-msgstr "Credito medio minimo per scrivere"
+msgstr "Credito medio minimo necessario per scrivere"
 
 #: ../user/team_forum.php:82
 msgid "Submit"
@@ -5958,7 +5958,7 @@ msgstr "Entrare in un team da al fondatore accesso al tuo indirizzo e-mail."
 
 #: ../user/team_join_form.php:38
 msgid "Joining a team does not affect your account's credit."
-msgstr "Entrare in un team non influisce sui crediti del tuo account."
+msgstr "Entrare in un team non influisce sui crediti del proprio account."
 
 #: ../user/team_join_form.php:45
 msgid "Join team"
@@ -6253,11 +6253,11 @@ msgstr "Decremento tempo di sign-up"
 
 #: ../user/user_search.php:68
 msgid "Decreasing average credit"
-msgstr "Decrescita del credito medio"
+msgstr "Diminuzione del credito medio"
 
 #: ../user/user_search.php:69
 msgid "Decreasing total credit"
-msgstr "Decrescita del credito totale"
+msgstr "Diminuzione del credito totale"
 
 #: ../user/user_search.php:84
 msgid "search string must be at least 3 characters"
@@ -6289,11 +6289,11 @@ msgstr "Team:"
 
 #: ../user/userw.php:48
 msgid "Team TotCred:"
-msgstr "Credito totale Team:"
+msgstr "Credito totale del Team:"
 
 #: ../user/userw.php:49
 msgid "Team AvgCred:"
-msgstr "Credito medio Team:"
+msgstr "Credito medio del Team:"
 
 #: ../user/userw.php:51
 msgid "Team: None"
diff --git a/locale/it_IT/BOINC-Web.mo b/locale/it_IT/BOINC-Web.mo
index 34fa05b..635ceec 100644
Binary files a/locale/it_IT/BOINC-Web.mo and b/locale/it_IT/BOINC-Web.mo differ
diff --git a/locale/it_IT/BOINC-Web.po b/locale/it_IT/BOINC-Web.po
index bbe2c34..b79bf77 100644
--- a/locale/it_IT/BOINC-Web.po
+++ b/locale/it_IT/BOINC-Web.po
@@ -13,7 +13,7 @@ msgstr ""
 "Project-Id-Version: BOINC\n"
 "Report-Msgid-Bugs-To: BOINC translation team <boinc_loc at ssl.berkeley.edu>\n"
 "POT-Creation-Date: 2015-07-09 18:59 PDT\n"
-"PO-Revision-Date: 2015-11-06 10:07+0000\n"
+"PO-Revision-Date: 2015-11-12 11:55+0000\n"
 "Last-Translator: Sebastiano Pistore <olatusrooc at virgilio.it>\n"
 "Language-Team: Italian (Italy) (http://www.transifex.com/boinc/boinc/language/it_IT/)\n"
 "MIME-Version: 1.0\n"
diff --git a/locale/nl/BOINC-Project-Generic.po b/locale/nl/BOINC-Project-Generic.po
index addff94..a9c6362 100644
--- a/locale/nl/BOINC-Project-Generic.po
+++ b/locale/nl/BOINC-Project-Generic.po
@@ -14,7 +14,7 @@ msgstr ""
 "Project-Id-Version: BOINC\n"
 "Report-Msgid-Bugs-To: BOINC translation team <boinc_loc at boinc.berkeley.edu>\n"
 "POT-Creation-Date: 2015-06-24 13:05 PDT\n"
-"PO-Revision-Date: 2015-10-10 00:47+0000\n"
+"PO-Revision-Date: 2015-11-19 08:59+0000\n"
 "Last-Translator: Jord <elst93 at gmail.com>\n"
 "Language-Team: Dutch (http://www.transifex.com/boinc/boinc/language/nl/)\n"
 "MIME-Version: 1.0\n"
diff --git a/locale/pt_PT/BOINC-Manager.mo b/locale/pt_PT/BOINC-Manager.mo
index e80f9d1..a2fdb75 100644
Binary files a/locale/pt_PT/BOINC-Manager.mo and b/locale/pt_PT/BOINC-Manager.mo differ
diff --git a/locale/pt_PT/BOINC-Manager.po b/locale/pt_PT/BOINC-Manager.po
index 7e86d58..bc6a787 100644
--- a/locale/pt_PT/BOINC-Manager.po
+++ b/locale/pt_PT/BOINC-Manager.po
@@ -8,10 +8,10 @@ msgid ""
 msgstr ""
 "Project-Id-Version: BOINC\n"
 "Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2015-05-29 16:51-0500\n"
-"PO-Revision-Date: 2015-06-01 14:57+0000\n"
+"POT-Creation-Date: 2015-10-16 17:27-0500\n"
+"PO-Revision-Date: 2015-11-11 11:43+0000\n"
 "Last-Translator: Miguel Filipe Paulino de Sousa Veiga <Miguel.veig at gmail.com>\n"
-"Language-Team: Portuguese (Portugal) (http://www.transifex.com/projects/p/boinc/language/pt_PT/)\n"
+"Language-Team: Portuguese (Portugal) (http://www.transifex.com/boinc/boinc/language/pt_PT/)\n"
 "MIME-Version: 1.0\n"
 "Content-Type: text/plain; charset=UTF-8\n"
 "Content-Transfer-Encoding: 8bit\n"
@@ -205,369 +205,369 @@ msgstr "Ligado"
 msgid "Disconnected"
 msgstr "Desconectado"
 
-#: clientgui/AdvancedFrame.cpp:327
+#: clientgui/AdvancedFrame.cpp:329
 #, c-format
 msgid "New %s window..."
-msgstr "Nova %s janela..."
+msgstr "Nova janela do %s..."
 
-#: clientgui/AdvancedFrame.cpp:331
+#: clientgui/AdvancedFrame.cpp:333
 #, c-format
 msgid "Open another %s window"
-msgstr "Abrir outra %s janela"
+msgstr "Abrir outra janela do %s"
 
-#: clientgui/AdvancedFrame.cpp:342
+#: clientgui/AdvancedFrame.cpp:344
 msgid "Select computer..."
 msgstr "Seleccionar computador..."
 
-#: clientgui/AdvancedFrame.cpp:343
+#: clientgui/AdvancedFrame.cpp:345
 msgid "Connect to a BOINC client on another computer"
 msgstr "Ligar a um cliente BOINC noutro computador"
 
-#: clientgui/AdvancedFrame.cpp:347
+#: clientgui/AdvancedFrame.cpp:349
 msgid "Shut down connected client..."
 msgstr "Desligar cliente ligado..."
 
-#: clientgui/AdvancedFrame.cpp:348
+#: clientgui/AdvancedFrame.cpp:350
 msgid "Shut down the currently connected BOINC client"
 msgstr "Desligar o cliente BOINC actualmente ligado"
 
-#: clientgui/AdvancedFrame.cpp:353 clientgui/sg_BoincSimpleFrame.cpp:120
+#: clientgui/AdvancedFrame.cpp:355 clientgui/sg_BoincSimpleFrame.cpp:120
 #, c-format
 msgid "Close the %s window"
 msgstr "Fechar a janela do %s"
 
-#: clientgui/AdvancedFrame.cpp:356 clientgui/sg_BoincSimpleFrame.cpp:123
+#: clientgui/AdvancedFrame.cpp:358 clientgui/sg_BoincSimpleFrame.cpp:123
 msgid "&Close window"
 msgstr "&Fechar janela"
 
-#: clientgui/AdvancedFrame.cpp:365 clientgui/AdvancedFrame.cpp:370
-#: clientgui/AdvancedFrame.cpp:375 clientgui/sg_BoincSimpleFrame.cpp:132
+#: clientgui/AdvancedFrame.cpp:367 clientgui/AdvancedFrame.cpp:372
+#: clientgui/AdvancedFrame.cpp:377 clientgui/sg_BoincSimpleFrame.cpp:132
 #: clientgui/sg_BoincSimpleFrame.cpp:137
 #, c-format
 msgid "Exit %s"
 msgstr "Sair do %s"
 
-#: clientgui/AdvancedFrame.cpp:389 clientgui/sg_BoincSimpleFrame.cpp:151
+#: clientgui/AdvancedFrame.cpp:391 clientgui/sg_BoincSimpleFrame.cpp:151
 msgid "Preferences..."
 msgstr "Preferências"
 
-#: clientgui/AdvancedFrame.cpp:398
+#: clientgui/AdvancedFrame.cpp:400
 msgid "&Notices\tCtrl+Shift+N"
 msgstr "&Notícias\tCtrl+Shift+N"
 
-#: clientgui/AdvancedFrame.cpp:399
+#: clientgui/AdvancedFrame.cpp:401
 msgid "Show notices"
 msgstr "Mostrar notícias"
 
-#: clientgui/AdvancedFrame.cpp:404
+#: clientgui/AdvancedFrame.cpp:406
 msgid "&Projects\tCtrl+Shift+P"
 msgstr "&Projectos\tCtrl+Shift+P"
 
-#: clientgui/AdvancedFrame.cpp:405
+#: clientgui/AdvancedFrame.cpp:407
 msgid "Show projects"
 msgstr "Mostrar projectos"
 
-#: clientgui/AdvancedFrame.cpp:410
+#: clientgui/AdvancedFrame.cpp:412
 msgid "&Tasks\tCtrl+Shift+T"
 msgstr "&Tarefas\tCtrl+Shift+T"
 
-#: clientgui/AdvancedFrame.cpp:411
+#: clientgui/AdvancedFrame.cpp:413
 msgid "Show tasks"
 msgstr "Mostrar tarefas"
 
-#: clientgui/AdvancedFrame.cpp:416
+#: clientgui/AdvancedFrame.cpp:418
 msgid "Trans&fers\tCtrl+Shift+X"
 msgstr "Trans&ferências\tCtrl+Shift+X"
 
-#: clientgui/AdvancedFrame.cpp:417
+#: clientgui/AdvancedFrame.cpp:419
 msgid "Show file transfers"
 msgstr "Mostrar transferências de ficheiros"
 
-#: clientgui/AdvancedFrame.cpp:422
+#: clientgui/AdvancedFrame.cpp:424
 msgid "&Statistics\tCtrl+Shift+S"
 msgstr "&Estatísticas\tCtrl+Shift+S"
 
-#: clientgui/AdvancedFrame.cpp:423
+#: clientgui/AdvancedFrame.cpp:425
 msgid "Show statistics"
 msgstr "Mostrar estatísticas"
 
-#: clientgui/AdvancedFrame.cpp:428
+#: clientgui/AdvancedFrame.cpp:430
 msgid "&Disk\tCtrl+Shift+D"
-msgstr "&Disco⇥Ctrl+Shift+D"
+msgstr "&Disco\tCtrl+Shift+D"
 
-#: clientgui/AdvancedFrame.cpp:429
+#: clientgui/AdvancedFrame.cpp:431
 msgid "Show disk usage"
 msgstr "Mostrar utilização do disco"
 
-#: clientgui/AdvancedFrame.cpp:436
+#: clientgui/AdvancedFrame.cpp:438
 msgid "Simple &View...\tCtrl+Shift+V"
-msgstr "&Vista Simplificada ...\tCtrl+Shift+V"
+msgstr "&Vista Simplificada...\tCtrl+Shift+V"
 
-#: clientgui/AdvancedFrame.cpp:437
+#: clientgui/AdvancedFrame.cpp:439
 msgid "Switch to the Simple View"
 msgstr "Trocar para a Vista Simples"
 
-#: clientgui/AdvancedFrame.cpp:451 clientgui/AdvancedFrame.cpp:475
+#: clientgui/AdvancedFrame.cpp:453 clientgui/AdvancedFrame.cpp:477
 #: clientgui/sg_BoincSimpleFrame.cpp:205
 msgid "&Add project..."
 msgstr "&Adicionar projecto..."
 
-#: clientgui/AdvancedFrame.cpp:452 clientgui/AdvancedFrame.cpp:476
+#: clientgui/AdvancedFrame.cpp:454 clientgui/AdvancedFrame.cpp:478
 #: clientgui/sg_BoincSimpleFrame.cpp:206
 msgid "Add a project"
 msgstr "Adicionar um projecto"
 
-#: clientgui/AdvancedFrame.cpp:456
+#: clientgui/AdvancedFrame.cpp:458
 msgid "&Use account manager..."
 msgstr "&Utilizar gestor de conta..."
 
-#: clientgui/AdvancedFrame.cpp:457
+#: clientgui/AdvancedFrame.cpp:459
 msgid "Use an account manager to control this computer."
 msgstr "Utilizar um gestor de conta para controlar este computador."
 
-#: clientgui/AdvancedFrame.cpp:461
+#: clientgui/AdvancedFrame.cpp:463
 #, c-format
 msgid "&Synchronize with %s"
-msgstr "&Sincronizar com o %s"
+msgstr "&Sincronizar com %s"
 
-#: clientgui/AdvancedFrame.cpp:465
+#: clientgui/AdvancedFrame.cpp:467
 #, c-format
 msgid "Get current settings from %s"
 msgstr "Obter as configurações actuais a partir de %s"
 
-#: clientgui/AdvancedFrame.cpp:479
+#: clientgui/AdvancedFrame.cpp:481
 #, c-format
 msgid "S&top using %s..."
-msgstr "&Parar de utilizar o %s..."
+msgstr "&Parar de utilizar %s..."
 
-#: clientgui/AdvancedFrame.cpp:485
+#: clientgui/AdvancedFrame.cpp:487
 msgid "Remove this computer from account manager control."
 msgstr "Remover este computador do controlo do gestor de conta."
 
-#: clientgui/AdvancedFrame.cpp:491
+#: clientgui/AdvancedFrame.cpp:493
 msgid "Run CPU &benchmarks"
 msgstr "Executar &testes de perfomance do CPU"
 
-#: clientgui/AdvancedFrame.cpp:492
+#: clientgui/AdvancedFrame.cpp:494
 msgid "Run tests that measure CPU speed"
 msgstr "Executar testes que avaliem a velocidade do CPU"
 
-#: clientgui/AdvancedFrame.cpp:496
+#: clientgui/AdvancedFrame.cpp:498
 msgid "Retry pending transfers"
 msgstr "Tentar novamente transferências pendentes"
 
-#: clientgui/AdvancedFrame.cpp:497
+#: clientgui/AdvancedFrame.cpp:499
 msgid "Retry deferred file transfers and task requests"
 msgstr "Tentar novamente transferências de ficheiros deferidos e pedidos de tarefas"
 
-#: clientgui/AdvancedFrame.cpp:502 clientgui/sg_BoincSimpleFrame.cpp:211
+#: clientgui/AdvancedFrame.cpp:504 clientgui/sg_BoincSimpleFrame.cpp:211
 msgid "Event Log...\tCtrl+Shift+E"
 msgstr "Registo de Eventos...\tCtrl+Shift+E"
 
-#: clientgui/AdvancedFrame.cpp:503
+#: clientgui/AdvancedFrame.cpp:505
 msgid "Show diagnostic messages"
 msgstr "Mostrar mensagens de diagnóstico"
 
-#: clientgui/AdvancedFrame.cpp:511
+#: clientgui/AdvancedFrame.cpp:513
 msgid "&Run always"
 msgstr "&Executar sempre"
 
-#: clientgui/AdvancedFrame.cpp:512
+#: clientgui/AdvancedFrame.cpp:514
 msgid "Allow work regardless of preferences"
 msgstr "Permitir execução de trabalho, independentemente das preferências"
 
-#: clientgui/AdvancedFrame.cpp:516
+#: clientgui/AdvancedFrame.cpp:518
 msgid "Run based on &preferences"
 msgstr "Executar com base nas &preferências"
 
-#: clientgui/AdvancedFrame.cpp:517
+#: clientgui/AdvancedFrame.cpp:519
 msgid "Allow work according to preferences"
 msgstr "Permitir execução de trabalho de acordo com as preferências"
 
-#: clientgui/AdvancedFrame.cpp:521
+#: clientgui/AdvancedFrame.cpp:523
 msgid "&Suspend"
 msgstr "&Suspender"
 
-#: clientgui/AdvancedFrame.cpp:522
+#: clientgui/AdvancedFrame.cpp:524
 msgid "Stop work regardless of preferences"
 msgstr "Parar execução de trabalho independentemente das preferências"
 
-#: clientgui/AdvancedFrame.cpp:547
+#: clientgui/AdvancedFrame.cpp:549
 msgid "Use GPU always"
 msgstr "Utilizar a GPU sempre"
 
-#: clientgui/AdvancedFrame.cpp:548
+#: clientgui/AdvancedFrame.cpp:550
 msgid "Allow GPU work regardless of preferences"
 msgstr "Permitir a execução da GPU, independentemente das preferências"
 
-#: clientgui/AdvancedFrame.cpp:552
+#: clientgui/AdvancedFrame.cpp:554
 msgid "Use GPU based on preferences"
 msgstr "Utilizar a GPU com base nas preferências"
 
-#: clientgui/AdvancedFrame.cpp:553
+#: clientgui/AdvancedFrame.cpp:555
 msgid "Allow GPU work according to preferences"
 msgstr "Permitir a execução da GPU de acordo com as preferências"
 
-#: clientgui/AdvancedFrame.cpp:557
+#: clientgui/AdvancedFrame.cpp:559
 msgid "Suspend GPU"
 msgstr "Suspender a GPU"
 
-#: clientgui/AdvancedFrame.cpp:558
+#: clientgui/AdvancedFrame.cpp:560
 msgid "Stop GPU work regardless of preferences"
 msgstr "Parar a execução da GPU, independentemente das preferências"
 
-#: clientgui/AdvancedFrame.cpp:582
+#: clientgui/AdvancedFrame.cpp:584
 msgid "Network activity always"
 msgstr "Actividade de rede sempre"
 
-#: clientgui/AdvancedFrame.cpp:583
+#: clientgui/AdvancedFrame.cpp:585
 msgid "Allow network activity regardless of preferences"
 msgstr "Permitir actividade de rede, independentemente das preferências"
 
-#: clientgui/AdvancedFrame.cpp:587
+#: clientgui/AdvancedFrame.cpp:589
 msgid "Network activity based on preferences"
 msgstr "Actividade de rede com base nas preferências"
 
-#: clientgui/AdvancedFrame.cpp:588
+#: clientgui/AdvancedFrame.cpp:590
 msgid "Allow network activity according to preferences"
 msgstr "Permitir actividade de rede de acordo com as preferências"
 
-#: clientgui/AdvancedFrame.cpp:592
+#: clientgui/AdvancedFrame.cpp:594
 msgid "Suspend network activity"
 msgstr "Suspender actividade de rede"
 
-#: clientgui/AdvancedFrame.cpp:593
+#: clientgui/AdvancedFrame.cpp:595
 msgid "Stop network activity"
 msgstr "Parar actividade de rede"
 
-#: clientgui/AdvancedFrame.cpp:602 clientgui/sg_BoincSimpleFrame.cpp:191
+#: clientgui/AdvancedFrame.cpp:604 clientgui/sg_BoincSimpleFrame.cpp:191
 msgid "Computing &preferences..."
 msgstr "&Preferências de computação..."
 
-#: clientgui/AdvancedFrame.cpp:603 clientgui/sg_BoincSimpleFrame.cpp:192
+#: clientgui/AdvancedFrame.cpp:605 clientgui/sg_BoincSimpleFrame.cpp:192
 msgid "Configure computing preferences"
 msgstr "Configurar preferências de computação"
 
-#: clientgui/AdvancedFrame.cpp:608
+#: clientgui/AdvancedFrame.cpp:610
 msgid "Exclusive applications..."
 msgstr "Aplicações exclusivas..."
 
-#: clientgui/AdvancedFrame.cpp:609
+#: clientgui/AdvancedFrame.cpp:611
 msgid "Configure exclusive applications"
 msgstr "Configurar aplicações exclusivas"
 
-#: clientgui/AdvancedFrame.cpp:614
+#: clientgui/AdvancedFrame.cpp:616
 msgid "Select columns..."
 msgstr "Seleccionar colunas..."
 
-#: clientgui/AdvancedFrame.cpp:615
+#: clientgui/AdvancedFrame.cpp:617
 msgid "Select which columns to display"
 msgstr "Seleccionar colunas a visualizar"
 
-#: clientgui/AdvancedFrame.cpp:619
+#: clientgui/AdvancedFrame.cpp:621
 msgid "Event Log options...\tCtrl+Shift+F"
-msgstr "Opções do Log de Eventos...⇥Ctrl+Shift+F"
+msgstr "Opções do Log de Eventos...\tCtrl+Shift+F"
 
-#: clientgui/AdvancedFrame.cpp:620
+#: clientgui/AdvancedFrame.cpp:622
 msgid "Enable or disable various diagnostic messages"
 msgstr "Habilita ou desabilita várias mensagens de diagnóstico"
 
-#: clientgui/AdvancedFrame.cpp:624 clientgui/sg_BoincSimpleFrame.cpp:197
+#: clientgui/AdvancedFrame.cpp:626 clientgui/sg_BoincSimpleFrame.cpp:197
 msgid "&Other options..."
 msgstr "&Outras opções..."
 
-#: clientgui/AdvancedFrame.cpp:625
+#: clientgui/AdvancedFrame.cpp:627
 msgid "Configure display options and network settings"
 msgstr "Configurar opções de exibição e definições de rede"
 
-#: clientgui/AdvancedFrame.cpp:630
+#: clientgui/AdvancedFrame.cpp:632
 msgid "Read config files"
 msgstr "Ler ficheiros de configuração"
 
-#: clientgui/AdvancedFrame.cpp:631
+#: clientgui/AdvancedFrame.cpp:633
 msgid ""
 "Read configuration info from cc_config.xml and any app_config.xml files"
 msgstr "Ler informações de configuração em cc_config.mxl e quaisquer ficheiros em app_config.xml"
 
-#: clientgui/AdvancedFrame.cpp:635
+#: clientgui/AdvancedFrame.cpp:637
 msgid "Read local prefs file"
 msgstr "Ler ficheiro de preferências locais"
 
-#: clientgui/AdvancedFrame.cpp:636
+#: clientgui/AdvancedFrame.cpp:638
 msgid "Read preferences from global_prefs_override.xml."
 msgstr "Ler preferências de global_prefs_override.xml"
 
-#: clientgui/AdvancedFrame.cpp:644 clientgui/sg_BoincSimpleFrame.cpp:219
+#: clientgui/AdvancedFrame.cpp:646 clientgui/sg_BoincSimpleFrame.cpp:219
 #, c-format
 msgid "%s &help"
-msgstr "%s &ajuda"
+msgstr "&Ajuda do %s"
 
-#: clientgui/AdvancedFrame.cpp:648 clientgui/sg_BoincSimpleFrame.cpp:223
+#: clientgui/AdvancedFrame.cpp:650 clientgui/sg_BoincSimpleFrame.cpp:223
 #, c-format
 msgid "Show information about %s"
 msgstr "Mostra informações sobre o %s"
 
-#: clientgui/AdvancedFrame.cpp:658
+#: clientgui/AdvancedFrame.cpp:660
 #, c-format
 msgid "&%s help"
-msgstr "&%s ajuda"
+msgstr "Ajuda do &%s"
 
-#: clientgui/AdvancedFrame.cpp:662 clientgui/sg_BoincSimpleFrame.cpp:237
+#: clientgui/AdvancedFrame.cpp:664 clientgui/sg_BoincSimpleFrame.cpp:237
 #, c-format
 msgid "Show information about the %s"
 msgstr "Mostra informações sobre o %s"
 
-#: clientgui/AdvancedFrame.cpp:673 clientgui/sg_BoincSimpleFrame.cpp:247
+#: clientgui/AdvancedFrame.cpp:675 clientgui/sg_BoincSimpleFrame.cpp:247
 #, c-format
 msgid "%s &web site"
 msgstr "%s &Website"
 
-#: clientgui/AdvancedFrame.cpp:677 clientgui/sg_BoincSimpleFrame.cpp:251
+#: clientgui/AdvancedFrame.cpp:679 clientgui/sg_BoincSimpleFrame.cpp:251
 #, c-format
 msgid "Show information about BOINC and %s"
 msgstr "Mostra informações sobre o BOINC e o %s"
 
-#: clientgui/AdvancedFrame.cpp:688 clientgui/BOINCTaskBar.cpp:544
+#: clientgui/AdvancedFrame.cpp:690 clientgui/BOINCTaskBar.cpp:541
 #: clientgui/sg_BoincSimpleFrame.cpp:262
 #, c-format
 msgid "&About %s..."
 msgstr "&Acerca de %s..."
 
-#: clientgui/AdvancedFrame.cpp:694 clientgui/sg_BoincSimpleFrame.cpp:268
+#: clientgui/AdvancedFrame.cpp:696 clientgui/sg_BoincSimpleFrame.cpp:268
 msgid "Licensing and copyright information."
 msgstr "Licenciamento e informações sobre direitos de autor."
 
-#: clientgui/AdvancedFrame.cpp:701 clientgui/sg_BoincSimpleFrame.cpp:275
+#: clientgui/AdvancedFrame.cpp:703 clientgui/sg_BoincSimpleFrame.cpp:275
 msgid "&File"
 msgstr "&Ficheiro"
 
-#: clientgui/AdvancedFrame.cpp:705 clientgui/sg_BoincSimpleFrame.cpp:279
+#: clientgui/AdvancedFrame.cpp:707 clientgui/sg_BoincSimpleFrame.cpp:279
 msgid "&View"
 msgstr "&Visualizar"
 
-#: clientgui/AdvancedFrame.cpp:709
+#: clientgui/AdvancedFrame.cpp:711
 msgid "&Activity"
 msgstr "&Actividade"
 
-#: clientgui/AdvancedFrame.cpp:713 clientgui/sg_BoincSimpleFrame.cpp:283
+#: clientgui/AdvancedFrame.cpp:715 clientgui/sg_BoincSimpleFrame.cpp:283
 msgid "&Options"
 msgstr "&Opções"
 
-#: clientgui/AdvancedFrame.cpp:717 clientgui/sg_BoincSimpleFrame.cpp:287
+#: clientgui/AdvancedFrame.cpp:719 clientgui/sg_BoincSimpleFrame.cpp:287
 msgid "&Tools"
 msgstr "&Ferramentas"
 
-#: clientgui/AdvancedFrame.cpp:721 clientgui/sg_BoincSimpleFrame.cpp:291
+#: clientgui/AdvancedFrame.cpp:723 clientgui/sg_BoincSimpleFrame.cpp:291
 #: clientgui/wizardex.cpp:374 clientgui/wizardex.cpp:381
 msgid "&Help"
 msgstr "&Ajuda"
 
-#: clientgui/AdvancedFrame.cpp:1235
+#: clientgui/AdvancedFrame.cpp:1237
 #, c-format
 msgid "%s - Stop using %s"
 msgstr "%s - Para de usar %s"
 
-#: clientgui/AdvancedFrame.cpp:1240
+#: clientgui/AdvancedFrame.cpp:1242
 #, c-format
 msgid ""
 "If you stop using %s,\n"
@@ -577,39 +577,39 @@ msgid ""
 "Do you want to stop using %s?"
 msgstr "Se parar de utilizar o %s,\nmanterá todos os projectos actuais,\nmas terá que gerir os projectos manualmente.\n\nQuer parar de utilizar o %s?"
 
-#: clientgui/AdvancedFrame.cpp:1469
+#: clientgui/AdvancedFrame.cpp:1471
 #, c-format
 msgid "%s - Shut down the current client..."
 msgstr "%s - Desligar o cliente actual..."
 
-#: clientgui/AdvancedFrame.cpp:1478
+#: clientgui/AdvancedFrame.cpp:1480
 #, c-format
 msgid ""
 "%s will shut down the current client\n"
 "and prompt you for another host to connect to."
 msgstr "%s irá desligar o cliente ligado actualmente\ne ser-lhe-á solicitado para que se ligue a outro anfitrião."
 
-#: clientgui/AdvancedFrame.cpp:1881 clientgui/DlgAbout.cpp:119
+#: clientgui/AdvancedFrame.cpp:1883 clientgui/DlgAbout.cpp:119
 #, c-format
 msgid "%s"
 msgstr "%s"
 
-#: clientgui/AdvancedFrame.cpp:1890
+#: clientgui/AdvancedFrame.cpp:1892
 #, c-format
 msgid "%s has successfully added %s"
 msgstr "%s foi adicionado com sucesso %s"
 
-#: clientgui/AdvancedFrame.cpp:2026
+#: clientgui/AdvancedFrame.cpp:2028
 #, c-format
 msgid "%s - (%s)"
 msgstr "%s - (%s)"
 
-#: clientgui/AdvancedFrame.cpp:2030
+#: clientgui/AdvancedFrame.cpp:2032
 #, c-format
 msgid "Connecting to %s"
 msgstr "Ligando a %s"
 
-#: clientgui/AdvancedFrame.cpp:2033
+#: clientgui/AdvancedFrame.cpp:2035
 #, c-format
 msgid "Connected to %s (%s)"
 msgstr "Ligado a %s (%s)"
@@ -645,7 +645,7 @@ msgstr "A comunicar com o cliente BOINC. Por favor aguarde..."
 #: clientgui/AsyncRPC.cpp:1034
 #, c-format
 msgid "&Quit %s"
-msgstr "&Desistir %s"
+msgstr "&Sair %s"
 
 #: clientgui/AsyncRPC.cpp:1036
 #, c-format
@@ -657,9 +657,9 @@ msgstr "S&air %s"
 msgid "%s - Communication"
 msgstr "%s - Comunicação"
 
-#: clientgui/AsyncRPC.cpp:1056 clientgui/DlgAdvPreferencesBase.cpp:176
+#: clientgui/AsyncRPC.cpp:1056 clientgui/DlgAdvPreferencesBase.cpp:168
 #: clientgui/DlgDiagnosticLogFlags.cpp:127 clientgui/DlgExclusiveApps.cpp:152
-#: clientgui/DlgHiddenColumns.cpp:108 clientgui/sg_DlgPreferences.cpp:351
+#: clientgui/DlgHiddenColumns.cpp:108 clientgui/sg_DlgPreferences.cpp:357
 msgid "Cancel"
 msgstr "Cancelar"
 
@@ -737,12 +737,12 @@ msgstr "%s não está actualmente ligado ao cliente %s.\nPor favor utilize o men
 msgid "Project web pages"
 msgstr "Páginas web do projecto"
 
-#: clientgui/BOINCClientManager.cpp:573
+#: clientgui/BOINCClientManager.cpp:547
 #, c-format
 msgid "%s - Unexpected Exit"
 msgstr "%s - Saída Inesperada"
 
-#: clientgui/BOINCClientManager.cpp:583
+#: clientgui/BOINCClientManager.cpp:557
 #, c-format
 msgid ""
 "The %s client has exited unexpectedly 3 times within the last %d minutes.\n"
@@ -793,7 +793,7 @@ msgstr "%s desligou-se com sucesso da Internet."
 msgid "%s failed to disconnected from the Internet."
 msgstr "%s falhou ao desligar-se da Internet."
 
-#: clientgui/BOINCGUIApp.cpp:351
+#: clientgui/BOINCGUIApp.cpp:356
 #, c-format
 msgid ""
 "You currently are not authorized to manage the client.\n"
@@ -806,166 +806,170 @@ msgid ""
 "     user group."
 msgstr "Não está autorizado de momento a gerir o cliente.\n\nPara executar o %s com este utilizador, por favor:\n  - reinstale o %s respondendo \"Sim\" à questão sobre\n    utilizadores não administrativos\nou\n  - contacte o seu administrador para o adicionar ao  grupo de utilizadores 'boinc_master'."
 
-#: clientgui/BOINCGUIApp.cpp:357
+#: clientgui/BOINCGUIApp.cpp:362
 #, c-format
 msgid ""
 "%s ownership or permissions are not set properly; please reinstall %s.\n"
 "(Error code %d"
 msgstr "%s direitos ou permissões não definidas correctamente; por favor reinstale %s.\n(Código de erro %d"
 
-#: clientgui/BOINCGUIApp.cpp:363
+#: clientgui/BOINCGUIApp.cpp:368
 msgid " at "
 msgstr " em"
 
-#: clientgui/BOINCGUIApp.cpp:366 clientgui/MainDocument.cpp:2494
-#: clientgui/MainDocument.cpp:2553 clientgui/ViewTransfers.cpp:887
+#: clientgui/BOINCGUIApp.cpp:371 clientgui/MainDocument.cpp:2495
+#: clientgui/MainDocument.cpp:2554 clientgui/ViewTransfers.cpp:867
 msgid ")"
 msgstr ")"
 
-#: clientgui/BOINCGUIApp.cpp:396
+#: clientgui/BOINCGUIApp.cpp:401
 msgid ""
 "A reboot is required in order for BOINC to run properly.\n"
 "Please reboot your computer and try again."
 msgstr "É necessário que reinicie o computador para que o BOINC seja executado correctamente.\nPor favor, reinicie o seu computador e tente novamente."
 
-#: clientgui/BOINCGUIApp.cpp:397 clientgui/DlgAbout.cpp:153
+#: clientgui/BOINCGUIApp.cpp:402 clientgui/DlgAbout.cpp:153
 msgid "BOINC Manager"
 msgstr "BOINC Manager"
 
-#: clientgui/BOINCGUIApp.cpp:658
+#: clientgui/BOINCGUIApp.cpp:664
 msgid "BOINC Manager was started by the operating system automatically"
 msgstr "O BOINC Manager foi iniciado pelo sistema operativo automaticamente"
 
-#: clientgui/BOINCGUIApp.cpp:660
+#: clientgui/BOINCGUIApp.cpp:666
 msgid "Startup BOINC so only the system tray icon is visible"
 msgstr "Iniciar o BOINC de modo a que o ícone seja visível apenas na barra de tarefas"
 
-#: clientgui/BOINCGUIApp.cpp:662
+#: clientgui/BOINCGUIApp.cpp:668
 msgid "Directory containing the BOINC Client executable"
 msgstr "Directório contendo o executável do Cliente BOINC"
 
-#: clientgui/BOINCGUIApp.cpp:663
+#: clientgui/BOINCGUIApp.cpp:669
 msgid "BOINC data directory"
 msgstr "Directório de dados do BOINC"
 
-#: clientgui/BOINCGUIApp.cpp:665
+#: clientgui/BOINCGUIApp.cpp:671
 msgid "Host name or IP address"
 msgstr "Nome de anfitrião ou endereço IP"
 
-#: clientgui/BOINCGUIApp.cpp:666
+#: clientgui/BOINCGUIApp.cpp:672
 msgid "GUI RPC port number"
 msgstr "Número da porta do GUI RPC"
 
-#: clientgui/BOINCGUIApp.cpp:667
+#: clientgui/BOINCGUIApp.cpp:673
 msgid "Password"
 msgstr "Palavra-passe"
 
-#: clientgui/BOINCGUIApp.cpp:668
+#: clientgui/BOINCGUIApp.cpp:674
 msgid "Startup BOINC with these optional arguments"
 msgstr "Iniciar o BOINC com estes argumentos opcionais"
 
-#: clientgui/BOINCGUIApp.cpp:669
+#: clientgui/BOINCGUIApp.cpp:675
 msgid "disable BOINC security users and permissions"
 msgstr "desabilitar os utilizadores de segurança e as permissões do BOINC"
 
-#: clientgui/BOINCGUIApp.cpp:670
+#: clientgui/BOINCGUIApp.cpp:676
 msgid "set skin debugging mode to enable skin manager error messages"
 msgstr "iniciar o modo de depuração para habilitar o gestor de mensagens de erro"
 
-#: clientgui/BOINCGUIApp.cpp:671
+#: clientgui/BOINCGUIApp.cpp:677
 msgid "multiple instances of BOINC Manager allowed"
 msgstr "multiplas instâncias do BOINC Manager permitidas"
 
-#: clientgui/BOINCGUIApp.cpp:673
+#: clientgui/BOINCGUIApp.cpp:679
 msgid "Not used: workaround for bug in XCode 4.2"
 msgstr "Não utilizado: solução alternativa para esse bug no XCode 4.2"
 
+#: clientgui/BOINCGUIApp.cpp:681
+msgid "Not run the daemon"
+msgstr "Não correr o daemon"
+
 #. These are just special tags so deal with them in a special way
-#: clientgui/BOINCGUIApp.cpp:920
+#: clientgui/BOINCGUIApp.cpp:931
 msgid "(Automatic Detection)"
 msgstr "(Detecção Automática)"
 
-#: clientgui/BOINCGUIApp.cpp:921
+#: clientgui/BOINCGUIApp.cpp:932
 msgid "(Unknown)"
 msgstr "(Desconhecido)"
 
-#: clientgui/BOINCGUIApp.cpp:922
+#: clientgui/BOINCGUIApp.cpp:933
 msgid "(User Defined)"
 msgstr "(Definido pelo Utilizador)"
 
-#: clientgui/BOINCTaskBar.cpp:522
+#: clientgui/BOINCTaskBar.cpp:519
 #, c-format
 msgid "Open %s Web..."
 msgstr "Abrir %s Web..."
 
-#: clientgui/BOINCTaskBar.cpp:529
+#: clientgui/BOINCTaskBar.cpp:526
 #, c-format
 msgid "Open %s..."
 msgstr "Abrir %s..."
 
-#: clientgui/BOINCTaskBar.cpp:536 clientgui/BOINCTaskBar.cpp:634
-#: clientgui/BOINCTaskBar.cpp:639
+#: clientgui/BOINCTaskBar.cpp:533 clientgui/BOINCTaskBar.cpp:631
+#: clientgui/BOINCTaskBar.cpp:636
 msgid "Snooze"
 msgstr "Suspender Temporariamente"
 
-#: clientgui/BOINCTaskBar.cpp:538 clientgui/BOINCTaskBar.cpp:653
-#: clientgui/BOINCTaskBar.cpp:658
+#: clientgui/BOINCTaskBar.cpp:535 clientgui/BOINCTaskBar.cpp:650
+#: clientgui/BOINCTaskBar.cpp:655
 msgid "Snooze GPU"
 msgstr "Suspender GPU Temporariamente"
 
-#: clientgui/BOINCTaskBar.cpp:556
+#: clientgui/BOINCTaskBar.cpp:553
 msgid "E&xit"
 msgstr "S&air"
 
-#: clientgui/BOINCTaskBar.cpp:629 clientgui/ViewProjects.cpp:806
+#: clientgui/BOINCTaskBar.cpp:626 clientgui/ViewProjects.cpp:804
 #: clientgui/ViewWork.cpp:882 clientgui/sg_BoincSimpleFrame.cpp:894
 #: clientgui/sg_ProjectCommandPopup.cpp:125
 #: clientgui/sg_TaskCommandPopup.cpp:118
 msgid "Resume"
 msgstr "Resumir"
 
-#: clientgui/BOINCTaskBar.cpp:649
+#: clientgui/BOINCTaskBar.cpp:646
 msgid "Resume GPU"
 msgstr "Resumir GPU"
 
-#: clientgui/BOINCTaskBar.cpp:715
+#: clientgui/BOINCTaskBar.cpp:712
 msgid "Computing is enabled"
 msgstr "Computação está activada"
 
-#: clientgui/BOINCTaskBar.cpp:719
+#: clientgui/BOINCTaskBar.cpp:716
 msgid "Computing is suspended - "
 msgstr "Computação está suspensa - "
 
-#: clientgui/BOINCTaskBar.cpp:729
+#: clientgui/BOINCTaskBar.cpp:726
 msgid "GPU computing is enabled"
 msgstr "Computação por GPU está activada"
 
-#: clientgui/BOINCTaskBar.cpp:732
+#: clientgui/BOINCTaskBar.cpp:729
 msgid "GPU computing is suspended - "
 msgstr "Computação por GPU está suspensa - "
 
-#: clientgui/BOINCTaskBar.cpp:741
+#: clientgui/BOINCTaskBar.cpp:738
 msgid "Network is enabled"
 msgstr "Actividade de rede está activada"
 
-#: clientgui/BOINCTaskBar.cpp:744
+#: clientgui/BOINCTaskBar.cpp:741
 msgid "Network is suspended - "
 msgstr "Actividade de rede está suspensa - "
 
-#: clientgui/BOINCTaskBar.cpp:752
+#: clientgui/BOINCTaskBar.cpp:749
 msgid "Reconnecting to client."
 msgstr "Ligando novamente ao cliente."
 
-#: clientgui/BOINCTaskBar.cpp:754
+#: clientgui/BOINCTaskBar.cpp:751
 msgid "Not connected to a client."
 msgstr "Não ligado ao cliente."
 
-#: clientgui/BOINCTaskBar.cpp:807
+#: clientgui/BOINCTaskBar.cpp:804
 #, c-format
 msgid "%s Notices"
 msgstr "%s Notícias"
 
-#: clientgui/BOINCTaskBar.cpp:813
+#: clientgui/BOINCTaskBar.cpp:810
 msgid "There are new notices - click to view."
 msgstr "Existem notícias novas - clique para visualizar."
 
@@ -1046,7 +1050,7 @@ msgstr "Está agora a utilizar este gestor de conta."
 #: clientgui/DlgAbout.cpp:113
 #, c-format
 msgid "About %s"
-msgstr "Acerca de %s"
+msgstr "Acerca do %s"
 
 #: clientgui/DlgAbout.cpp:172
 msgid "Version:"
@@ -1075,44 +1079,48 @@ msgid "For more information, visit "
 msgstr "Para mais informações, visite"
 
 #: clientgui/DlgAbout.cpp:215 clientgui/DlgExitMessage.cpp:173
-#: clientgui/DlgGenericMessage.cpp:120 clientgui/DlgOptions.cpp:399
+#: clientgui/DlgGenericMessage.cpp:120 clientgui/DlgOptions.cpp:410
 #: clientgui/DlgSelectComputer.cpp:163
 msgid "&OK"
 msgstr "&OK"
 
-#: clientgui/DlgAdvPreferences.cpp:682 clientgui/sg_DlgPreferences.cpp:769
+#: clientgui/DlgAdvPreferences.cpp:684 clientgui/sg_DlgPreferences.cpp:775
 msgid "Invalid number"
 msgstr "Número inválido"
 
-#: clientgui/DlgAdvPreferences.cpp:683 clientgui/sg_DlgPreferences.cpp:770
+#: clientgui/DlgAdvPreferences.cpp:685 clientgui/sg_DlgPreferences.cpp:776
 msgid "Invalid time, value must be between 0:00 and 24:00, format is HH:MM"
 msgstr "Hora inválida, o valor deve estar entre 0.00 e 24.00, o formato é HH:MM"
 
-#: clientgui/DlgAdvPreferences.cpp:684 clientgui/sg_DlgPreferences.cpp:771
+#: clientgui/DlgAdvPreferences.cpp:686 clientgui/sg_DlgPreferences.cpp:777
 msgid "Start time must be different from end time"
 msgstr "A hora de início tem de ser diferente da final."
 
-#: clientgui/DlgAdvPreferences.cpp:685
+#: clientgui/DlgAdvPreferences.cpp:687
 msgid "Number must be between 0 and 10"
 msgstr "Os números devem ser entre 0 e 10"
 
-#: clientgui/DlgAdvPreferences.cpp:686 clientgui/sg_DlgPreferences.cpp:772
+#: clientgui/DlgAdvPreferences.cpp:688 clientgui/sg_DlgPreferences.cpp:778
 msgid "Number must be between 0 and 100"
 msgstr "Os números devem ser entre 0 e 100"
 
-#: clientgui/DlgAdvPreferences.cpp:944 clientgui/sg_DlgPreferences.cpp:843
+#: clientgui/DlgAdvPreferences.cpp:689
+msgid "Number must be between 1 and 100"
+msgstr "Número tem de estar entre 1 e 100"
+
+#: clientgui/DlgAdvPreferences.cpp:947 clientgui/sg_DlgPreferences.cpp:849
 msgid "invalid input value detected"
 msgstr "valor inválido de entrada detectado"
 
-#: clientgui/DlgAdvPreferences.cpp:946 clientgui/sg_DlgPreferences.cpp:845
+#: clientgui/DlgAdvPreferences.cpp:959 clientgui/sg_DlgPreferences.cpp:861
 msgid "Validation Error"
 msgstr "Erro de Validação"
 
-#: clientgui/DlgAdvPreferences.cpp:1158
+#: clientgui/DlgAdvPreferences.cpp:1171
 msgid "Discard local preferences and use web-based preferences?"
 msgstr "Rejeitar preferências locais e utilizar as preferências web?"
 
-#: clientgui/DlgAdvPreferences.cpp:1159 clientgui/sg_DlgPreferences.cpp:1171
+#: clientgui/DlgAdvPreferences.cpp:1172 clientgui/sg_DlgPreferences.cpp:1187
 msgid "Confirmation"
 msgstr "Confirmação"
 
@@ -1121,111 +1129,95 @@ msgstr "Confirmação"
 msgid "%s - Computing preferences"
 msgstr "%s - Preferências de computação"
 
-#: clientgui/DlgAdvPreferencesBase.cpp:82 clientgui/sg_DlgPreferences.cpp:161
+#: clientgui/DlgAdvPreferencesBase.cpp:82 clientgui/sg_DlgPreferences.cpp:163
 msgid ""
 "Using local preferences.\n"
 "Click \"Use web prefs\" to use web-based preferences from"
-msgstr "Utilizando preferências locais.\nClique em \"Utilizar preferências web\" para usar as preferências web de"
+msgstr "Utilizando preferências locais.\nClique em \"Utilizar preferências web\" para carregar as preferências web de"
 
-#: clientgui/DlgAdvPreferencesBase.cpp:90 clientgui/sg_DlgPreferences.cpp:169
+#: clientgui/DlgAdvPreferencesBase.cpp:90 clientgui/sg_DlgPreferences.cpp:171
 msgid "Using web-based preferences from"
 msgstr "Utilizando preferências web de"
 
-#: clientgui/DlgAdvPreferencesBase.cpp:107 clientgui/sg_DlgPreferences.cpp:187
+#: clientgui/DlgAdvPreferencesBase.cpp:107 clientgui/sg_DlgPreferences.cpp:189
 msgid "Set values and click OK to use local preferences instead."
 msgstr "Defina valores e clique em OK para utilizar as preferências locais."
 
-#: clientgui/DlgAdvPreferencesBase.cpp:116
-msgid ""
-"This dialog controls preferences for this computer only.\n"
-"Click OK to set preferences.\n"
-"Click Clear to restore web-based settings."
-msgstr "Esta caixa de diálogo controla as preferências para este computador apenas.\nClique em OK para definir as preferências.\nClique em Limpar para restaurar as definições web."
-
-#: clientgui/DlgAdvPreferencesBase.cpp:119
-msgid "Clear"
-msgstr "Limpar"
-
-#: clientgui/DlgAdvPreferencesBase.cpp:120
-msgid "Clear all local preferences and close the dialog."
-msgstr "Limpar todas as preferências locais e fechar a caixa de diálogo."
-
-#: clientgui/DlgAdvPreferencesBase.cpp:123 clientgui/sg_DlgPreferences.cpp:215
+#: clientgui/DlgAdvPreferencesBase.cpp:115 clientgui/sg_DlgPreferences.cpp:217
 msgid "Use web prefs"
 msgstr "Utilizar preferências web"
 
-#: clientgui/DlgAdvPreferencesBase.cpp:124 clientgui/sg_DlgPreferences.cpp:216
+#: clientgui/DlgAdvPreferencesBase.cpp:116 clientgui/sg_DlgPreferences.cpp:218
 msgid "Restore web-based preferences and close the dialog."
 msgstr "Restaurar as preferências web e fechar a caixa de diálogo."
 
-#. Computing schedule
-#: clientgui/DlgAdvPreferencesBase.cpp:148
-#: clientgui/DlgAdvPreferencesBase.cpp:688
+#: clientgui/DlgAdvPreferencesBase.cpp:140
+#: clientgui/DlgAdvPreferencesBase.cpp:684
 msgid "Computing"
 msgstr "A computar"
 
 #. Network schedule
-#: clientgui/DlgAdvPreferencesBase.cpp:151
-#: clientgui/DlgAdvPreferencesBase.cpp:836
+#: clientgui/DlgAdvPreferencesBase.cpp:143
+#: clientgui/DlgAdvPreferencesBase.cpp:886
 msgid "Network"
 msgstr "Rede"
 
-#: clientgui/DlgAdvPreferencesBase.cpp:154
+#: clientgui/DlgAdvPreferencesBase.cpp:146
 msgid "Disk and memory"
 msgstr "Disco e memória"
 
-#: clientgui/DlgAdvPreferencesBase.cpp:157
+#: clientgui/DlgAdvPreferencesBase.cpp:149
 msgid "Daily schedules"
 msgstr "Programações diárias"
 
-#: clientgui/DlgAdvPreferencesBase.cpp:170
+#: clientgui/DlgAdvPreferencesBase.cpp:162
 #: clientgui/DlgDiagnosticLogFlags.cpp:119 clientgui/DlgExclusiveApps.cpp:146
-#: clientgui/DlgHiddenColumns.cpp:100 clientgui/sg_DlgPreferences.cpp:347
+#: clientgui/DlgHiddenColumns.cpp:100 clientgui/sg_DlgPreferences.cpp:353
 msgid "OK"
 msgstr "OK"
 
-#: clientgui/DlgAdvPreferencesBase.cpp:171
+#: clientgui/DlgAdvPreferencesBase.cpp:163
 msgid "Save all values and close the dialog."
 msgstr "Salvar todos os valores e fechar a caixa de diálogo."
 
-#: clientgui/DlgAdvPreferencesBase.cpp:177
+#: clientgui/DlgAdvPreferencesBase.cpp:169
 msgid "Close the dialog without saving."
 msgstr "Fechar a caixa de diálogo sem guardar."
 
-#: clientgui/DlgAdvPreferencesBase.cpp:181 clientgui/DlgExclusiveApps.cpp:157
+#: clientgui/DlgAdvPreferencesBase.cpp:173 clientgui/DlgExclusiveApps.cpp:157
 #: clientgui/Localization.cpp:35 clientgui/Localization.cpp:121
 #: clientgui/Localization.cpp:139 clientgui/sg_BoincSimpleFrame.cpp:930
-#: clientgui/sg_DlgPreferences.cpp:357
+#: clientgui/sg_DlgPreferences.cpp:363
 msgid "Help"
 msgstr "Ajuda"
 
-#: clientgui/DlgAdvPreferencesBase.cpp:182
+#: clientgui/DlgAdvPreferencesBase.cpp:174
 msgid "Shows the preferences web page."
 msgstr "Mostra  a página web das preferências."
 
-#: clientgui/DlgAdvPreferencesBase.cpp:244
-#: clientgui/DlgAdvPreferencesBase.cpp:471
+#: clientgui/DlgAdvPreferencesBase.cpp:236
+#: clientgui/DlgAdvPreferencesBase.cpp:463
 msgid "Usage limits"
 msgstr "Limites de utilização"
 
-#: clientgui/DlgAdvPreferencesBase.cpp:249
+#: clientgui/DlgAdvPreferencesBase.cpp:241
 #, no-c-format
 msgid ""
 "Keep some CPUs free for other applications. Example: 75% means use 6 cores "
 "on an 8-core CPU."
 msgstr "Deixar alguns CPUs livres para outras aplicações. Exemplo: 75% significa utilizar 6 cores num CPU de 8 cores."
 
-#: clientgui/DlgAdvPreferencesBase.cpp:251
-#: clientgui/DlgAdvPreferencesBase.cpp:263 clientgui/sg_DlgPreferences.cpp:302
+#: clientgui/DlgAdvPreferencesBase.cpp:243
+#: clientgui/DlgAdvPreferencesBase.cpp:255 clientgui/sg_DlgPreferences.cpp:286
 msgid "Use at most"
-msgstr "Usar no máximo"
+msgstr "Utilizar no máximo"
 
-#: clientgui/DlgAdvPreferencesBase.cpp:256
+#: clientgui/DlgAdvPreferencesBase.cpp:248
 #, no-c-format
 msgid "% of the CPUs"
 msgstr "% dos CPUs"
 
-#: clientgui/DlgAdvPreferencesBase.cpp:261 clientgui/sg_DlgPreferences.cpp:300
+#: clientgui/DlgAdvPreferencesBase.cpp:253 clientgui/sg_DlgPreferences.cpp:284
 #, no-c-format
 msgid ""
 "Suspend/resume computing every few seconds to reduce CPU temperature and "
@@ -1233,355 +1225,363 @@ msgid ""
 "and repeat."
 msgstr "Suspende/resume computação em alguns segundos para reduzir a temperatura do CPU e o consumo de energia. Exemplo: 75% significa realizar computação durante 3 segundos, aguardar 1 segundo e repetir."
 
-#: clientgui/DlgAdvPreferencesBase.cpp:268 clientgui/sg_DlgPreferences.cpp:307
+#: clientgui/DlgAdvPreferencesBase.cpp:260 clientgui/sg_DlgPreferences.cpp:291
 #, no-c-format
 msgid "% of CPU time"
 msgstr "% de tempo de CPU"
 
-#: clientgui/DlgAdvPreferencesBase.cpp:275
+#: clientgui/DlgAdvPreferencesBase.cpp:267
 msgid "When to suspend"
 msgstr "Quando suspender"
 
-#: clientgui/DlgAdvPreferencesBase.cpp:281 clientgui/sg_DlgPreferences.cpp:237
+#: clientgui/DlgAdvPreferencesBase.cpp:273 clientgui/sg_DlgPreferences.cpp:239
 msgid "Suspend when computer is on battery"
 msgstr "Suspender quando o computador está apenas em bateria"
 
-#: clientgui/DlgAdvPreferencesBase.cpp:284 clientgui/sg_DlgPreferences.cpp:233
+#: clientgui/DlgAdvPreferencesBase.cpp:276 clientgui/sg_DlgPreferences.cpp:235
 msgid ""
 "Check this to suspend computing on portables when running on battery power."
 msgstr "Seleccione aqui para suspender computação nos portáteis quando em execução em bateria apenas."
 
-#: clientgui/DlgAdvPreferencesBase.cpp:290 clientgui/sg_DlgPreferences.cpp:251
+#: clientgui/DlgAdvPreferencesBase.cpp:282 clientgui/sg_DlgPreferences.cpp:253
 msgid "Suspend when computer is in use"
 msgstr "Suspender quando o computador está em utilização"
 
-#: clientgui/DlgAdvPreferencesBase.cpp:293 clientgui/sg_DlgPreferences.cpp:247
+#: clientgui/DlgAdvPreferencesBase.cpp:285 clientgui/sg_DlgPreferences.cpp:249
 msgid ""
 "Check this to suspend computing and file transfers when you're using the "
 "computer."
 msgstr "Seleccione aqui para suspender a computação e transferência de ficheiros quando estiver a utilizar o computador."
 
-#: clientgui/DlgAdvPreferencesBase.cpp:299
+#: clientgui/DlgAdvPreferencesBase.cpp:291
 msgid "Suspend GPU computing when computer is in use"
 msgstr "Suspende computação da GPU quando o computador está a ser utilizado"
 
-#: clientgui/DlgAdvPreferencesBase.cpp:302
+#: clientgui/DlgAdvPreferencesBase.cpp:294
 msgid "Check this to suspend GPU computing when you're using the computer."
 msgstr "Seleccione aqui para suspender a computação da GPU quando estiver a utilizar o computador."
 
 #. min idle time
-#: clientgui/DlgAdvPreferencesBase.cpp:307 clientgui/sg_DlgPreferences.cpp:262
+#: clientgui/DlgAdvPreferencesBase.cpp:299 clientgui/sg_DlgPreferences.cpp:264
 msgid "This determines when the computer is considered 'in use'."
-msgstr "Isto determina quando o computador é considerado 'em utilização'."
+msgstr "Isto determina quando o computador é considerado como 'em utilização'."
 
 #. context: 'In use' means mouse/keyboard input in last ___ minutes
-#: clientgui/DlgAdvPreferencesBase.cpp:312 clientgui/sg_DlgPreferences.cpp:266
+#: clientgui/DlgAdvPreferencesBase.cpp:304 clientgui/sg_DlgPreferences.cpp:268
 msgid "'In use' means mouse/keyboard input in last"
 msgstr "'Em utilização' significa actividade do rato/teclado nos últimos"
 
 #. context: 'In use' means mouse/keyboard input in last ___ minutes
 #. context: Switch between tasks every ___ minutes
-#: clientgui/DlgAdvPreferencesBase.cpp:323
-#: clientgui/DlgAdvPreferencesBase.cpp:421 clientgui/sg_DlgPreferences.cpp:274
+#: clientgui/DlgAdvPreferencesBase.cpp:315
+#: clientgui/DlgAdvPreferencesBase.cpp:413 clientgui/sg_DlgPreferences.cpp:276
 msgid "minutes"
 msgstr "minutos"
 
-#: clientgui/DlgAdvPreferencesBase.cpp:331
+#: clientgui/DlgAdvPreferencesBase.cpp:323
 msgid "Suspend when non-BOINC CPU usage is above"
 msgstr "Suspender quando a utilização do CPU por parte de terceiros for superior a"
 
-#: clientgui/DlgAdvPreferencesBase.cpp:333
+#: clientgui/DlgAdvPreferencesBase.cpp:325
 msgid "Suspend computing when your computer is busy running other programs."
 msgstr "Suspender computação quando o seu computador estiver ocupado executando outros programas."
 
+#: clientgui/DlgAdvPreferencesBase.cpp:339
+msgid "To suspend by time of day, see the \"Daily Schedules\" section."
+msgstr "Para suspender pela hora do dia, ver a secção \"Programações Diárias\"."
+
 #. Context: heading for a group of miscellaneous preferences
-#: clientgui/DlgAdvPreferencesBase.cpp:357
-#: clientgui/DlgAdvPreferencesBase.cpp:524
+#: clientgui/DlgAdvPreferencesBase.cpp:349
+#: clientgui/DlgAdvPreferencesBase.cpp:516
 msgid "Other"
 msgstr "Outro"
 
 #. buffer sizes
-#: clientgui/DlgAdvPreferencesBase.cpp:363
+#: clientgui/DlgAdvPreferencesBase.cpp:355
 msgid "Store at least enough tasks to keep the computer busy for this long."
-msgstr "Armazenar no mínimo tarefas suficientes para manter o computador ocupado para este período."
+msgstr "Armazenar tarefas suficientes para manter o computador ocupado no mínimo durante este período."
 
 #. context: Store at least ___ days of work
-#: clientgui/DlgAdvPreferencesBase.cpp:367
+#: clientgui/DlgAdvPreferencesBase.cpp:359
 msgid "Store at least"
 msgstr "Armazenar no mínimo "
 
 #. context: Store at least ___ days of work
 #. context: Store up to an additional ___ days of work
-#: clientgui/DlgAdvPreferencesBase.cpp:378
-#: clientgui/DlgAdvPreferencesBase.cpp:400
+#: clientgui/DlgAdvPreferencesBase.cpp:370
+#: clientgui/DlgAdvPreferencesBase.cpp:392
 msgid "days of work"
 msgstr "dias de trabalho"
 
-#: clientgui/DlgAdvPreferencesBase.cpp:384
+#: clientgui/DlgAdvPreferencesBase.cpp:376
 msgid ""
 "Store additional tasks above the minimum level.  Determines how much work is"
 " requested when contacting a project."
 msgstr "Armazene tarefas adicionais acima do nível mínimo. Determina a quantidade de trabalho que é pedido quando um projecto é contactado."
 
 #. context: Store up to an additional ___ days of work
-#: clientgui/DlgAdvPreferencesBase.cpp:388
+#: clientgui/DlgAdvPreferencesBase.cpp:380
 msgid "Store up to an additional"
-msgstr "Armazene até um adicional"
+msgstr "Armazene adicionalmente"
 
-#: clientgui/DlgAdvPreferencesBase.cpp:407
+#: clientgui/DlgAdvPreferencesBase.cpp:399
 #, c-format
 msgid "If you run several projects, %s may switch between them this often."
 msgstr "Se executa vários projectos, %s pode trocar entre eles com esta frequência."
 
 #. context: Switch between tasks every ___ minutes
-#: clientgui/DlgAdvPreferencesBase.cpp:412
+#: clientgui/DlgAdvPreferencesBase.cpp:404
 msgid "Switch between tasks every"
 msgstr "Trocar entre tarefas a cada"
 
-#: clientgui/DlgAdvPreferencesBase.cpp:427
+#: clientgui/DlgAdvPreferencesBase.cpp:419
 msgid ""
-"This controls how often tasks save their state to disk, so that they can be "
-"restarted later."
-msgstr "Isto controla com que frequência as tarefas guardam no disco o seu estado, para que possam ser reiniciadas mais tarde."
+"This controls how often tasks save their state to disk, so that they later "
+"can be continued from that point."
+msgstr "Isto controla com que frequência o progresso das tarefas são guardadas  no disco, para que mais tarde possam continuar a partir daquele ponto"
 
 #. context: Request tasks to checkpoint at most every ___ seconds
-#: clientgui/DlgAdvPreferencesBase.cpp:431
+#: clientgui/DlgAdvPreferencesBase.cpp:423
 msgid "Request tasks to checkpoint at most every"
 msgstr "Pedir às tarefas que criem um checkpoint no máximo a cada"
 
 #. context: Request tasks to checkpoint at most every ___ seconds
-#: clientgui/DlgAdvPreferencesBase.cpp:440
+#: clientgui/DlgAdvPreferencesBase.cpp:432
 msgid "seconds"
 msgstr "segundos"
 
 #. upload/download rates
-#: clientgui/DlgAdvPreferencesBase.cpp:477
+#: clientgui/DlgAdvPreferencesBase.cpp:469
 msgid "Limit the download rate of file transfers."
 msgstr "Limitar a taxa de transferência dos ficheiros."
 
-#: clientgui/DlgAdvPreferencesBase.cpp:478
+#: clientgui/DlgAdvPreferencesBase.cpp:470
 msgid "Limit download rate to"
 msgstr "Limitar taxa de transferência para"
 
-#: clientgui/DlgAdvPreferencesBase.cpp:482
-#: clientgui/DlgAdvPreferencesBase.cpp:491
+#: clientgui/DlgAdvPreferencesBase.cpp:474
+#: clientgui/DlgAdvPreferencesBase.cpp:483
 msgid "KB/second"
 msgstr "KB/segundo"
 
-#: clientgui/DlgAdvPreferencesBase.cpp:486
+#: clientgui/DlgAdvPreferencesBase.cpp:478
 msgid "Limit the upload rate of file transfers."
 msgstr "Limitar taxa de upload da transferência de ficheiros."
 
-#: clientgui/DlgAdvPreferencesBase.cpp:487
+#: clientgui/DlgAdvPreferencesBase.cpp:479
 msgid "Limit upload rate to"
 msgstr "Limitar taxa de upload para"
 
-#: clientgui/DlgAdvPreferencesBase.cpp:498
+#: clientgui/DlgAdvPreferencesBase.cpp:490
 #, c-format
 msgid "Example: %s should transfer at most 2000 MB of data every 30 days."
 msgstr "Exemplo: %s deve transferir no máximo 2000 Mb de dados a cada 30 dias."
 
-#: clientgui/DlgAdvPreferencesBase.cpp:500
+#: clientgui/DlgAdvPreferencesBase.cpp:492
 msgid "Limit usage to"
 msgstr "Limitar utilização a"
 
-#: clientgui/DlgAdvPreferencesBase.cpp:504
+#: clientgui/DlgAdvPreferencesBase.cpp:496
 msgid "MB every"
 msgstr "MB a cada"
 
-#: clientgui/DlgAdvPreferencesBase.cpp:508
+#: clientgui/DlgAdvPreferencesBase.cpp:500
 msgid "days"
 msgstr "dias"
 
-#: clientgui/DlgAdvPreferencesBase.cpp:530
+#: clientgui/DlgAdvPreferencesBase.cpp:505
+msgid "To limit transfers by time of day, see the \"Daily Schedules\" section."
+msgstr "Para limitar as transferências pela hora do dia, ver a secção \"\"Programações Diárias\"."
+
+#: clientgui/DlgAdvPreferencesBase.cpp:522
 #, c-format
 msgid ""
 "Check this only if your Internet provider modifies image files. Skipping "
 "verification reduces the security of %s."
 msgstr "Seleccione aqui apenas se o seu fornecedor de Internet modificar os ficheiros de imagem. Saltar a verificação, reduz a segurança do %s."
 
-#: clientgui/DlgAdvPreferencesBase.cpp:532
+#: clientgui/DlgAdvPreferencesBase.cpp:524
 msgid "Skip data verification for image files"
 msgstr "Saltar verificação de dados para imagens"
 
-#: clientgui/DlgAdvPreferencesBase.cpp:536
+#: clientgui/DlgAdvPreferencesBase.cpp:528
 msgid "Confirm before connecting to Internet"
 msgstr "Confirmar antes de se ligar à Internet"
 
-#: clientgui/DlgAdvPreferencesBase.cpp:537
-#: clientgui/DlgAdvPreferencesBase.cpp:541
+#: clientgui/DlgAdvPreferencesBase.cpp:529
+#: clientgui/DlgAdvPreferencesBase.cpp:533
 msgid "Useful only if you have a modem, ISDN or VPN connection."
 msgstr "Útil apenas se tiver um modem, ISDN ou uma conexão VPN."
 
-#: clientgui/DlgAdvPreferencesBase.cpp:540
+#: clientgui/DlgAdvPreferencesBase.cpp:532
 msgid "Disconnect when done"
 msgstr "Desligar quando terminado"
 
-#: clientgui/DlgAdvPreferencesBase.cpp:567 clientgui/ViewResources.cpp:116
+#: clientgui/DlgAdvPreferencesBase.cpp:559 clientgui/ViewResources.cpp:116
 msgid "Disk"
 msgstr "Disco"
 
-#: clientgui/DlgAdvPreferencesBase.cpp:572
+#: clientgui/DlgAdvPreferencesBase.cpp:564
 #, c-format
 msgid "%s will use the most restrictive of these settings:"
-msgstr "%s irá utilizar as definições mais restritivas:"
+msgstr "O %s irá utilizar as definições mais restritivas:"
 
-#: clientgui/DlgAdvPreferencesBase.cpp:578 clientgui/sg_DlgPreferences.cpp:329
+#: clientgui/DlgAdvPreferencesBase.cpp:570 clientgui/sg_DlgPreferences.cpp:335
 #, c-format
 msgid "Limit the total amount of disk space used by %s."
 msgstr "Limitar o espaço total em disco utilizado por %s."
 
-#: clientgui/DlgAdvPreferencesBase.cpp:581
-#: clientgui/DlgAdvPreferencesBase.cpp:605 clientgui/sg_DlgPreferences.cpp:332
+#: clientgui/DlgAdvPreferencesBase.cpp:573
+#: clientgui/DlgAdvPreferencesBase.cpp:597 clientgui/sg_DlgPreferences.cpp:338
 msgid "Use no more than"
-msgstr "Utilizar não mais do que"
+msgstr "Não utilizar mais do que"
 
-#: clientgui/DlgAdvPreferencesBase.cpp:585
+#: clientgui/DlgAdvPreferencesBase.cpp:577
 msgid "GB"
 msgstr "GB"
 
-#: clientgui/DlgAdvPreferencesBase.cpp:590
+#: clientgui/DlgAdvPreferencesBase.cpp:582
 #, c-format
 msgid ""
 "Limit disk usage to leave this much free space on the volume where %s stores"
 " data."
 msgstr "Limita a utilização do disco para deixar esta quantidade de espaço livre no volume onde %s armazena os dados."
 
-#: clientgui/DlgAdvPreferencesBase.cpp:593
+#: clientgui/DlgAdvPreferencesBase.cpp:585
 msgid "Leave at least"
 msgstr "Deixar pelo menos"
 
-#: clientgui/DlgAdvPreferencesBase.cpp:597
+#: clientgui/DlgAdvPreferencesBase.cpp:589
 msgid "GB free"
 msgstr "GB livres"
 
-#: clientgui/DlgAdvPreferencesBase.cpp:602
+#: clientgui/DlgAdvPreferencesBase.cpp:594
 #, c-format
 msgid ""
 "Limit the percentage of disk space used by %s on the volume where it stores "
 "data."
 msgstr "Limita a percentagem de disco utilizada pelo %s no volume onde armazena os dados."
 
-#: clientgui/DlgAdvPreferencesBase.cpp:610
+#: clientgui/DlgAdvPreferencesBase.cpp:602
 #, no-c-format
 msgid "% of total"
 msgstr "% do total "
 
-#: clientgui/DlgAdvPreferencesBase.cpp:617
+#: clientgui/DlgAdvPreferencesBase.cpp:609
 msgid "Memory"
 msgstr "Memória"
 
-#: clientgui/DlgAdvPreferencesBase.cpp:622
+#: clientgui/DlgAdvPreferencesBase.cpp:614
 #, c-format
 msgid "Limit the memory used by %s when you're using the computer."
 msgstr "Limita a memória utilizada pelo %s quando está a utilizar o computador."
 
-#: clientgui/DlgAdvPreferencesBase.cpp:624
+#: clientgui/DlgAdvPreferencesBase.cpp:616
 msgid "When computer is in use, use at most"
-msgstr "Quando o computador está a ser utilizado, usar no máximo"
+msgstr "Quando o computador está em utilização, utilizar no máximo"
 
-#: clientgui/DlgAdvPreferencesBase.cpp:630
-#: clientgui/DlgAdvPreferencesBase.cpp:642
-#: clientgui/DlgAdvPreferencesBase.cpp:658
+#: clientgui/DlgAdvPreferencesBase.cpp:622
+#: clientgui/DlgAdvPreferencesBase.cpp:634
+#: clientgui/DlgAdvPreferencesBase.cpp:650
 #, no-c-format
 msgid "%"
 msgstr "%"
 
-#: clientgui/DlgAdvPreferencesBase.cpp:635
+#: clientgui/DlgAdvPreferencesBase.cpp:627
 #, c-format
 msgid "Limit the memory used by %s when you're not using the computer."
 msgstr "Limitar a utilização de memória pelo %s quando não estiver a utilizar o computador."
 
-#: clientgui/DlgAdvPreferencesBase.cpp:637
+#: clientgui/DlgAdvPreferencesBase.cpp:629
 msgid "When computer is not in use, use at most"
-msgstr "Quando o computador não está a ser utilizado, usar no máximo"
+msgstr "Quando o computador não está em utilização, utilizar no máximo"
 
-#: clientgui/DlgAdvPreferencesBase.cpp:646
+#: clientgui/DlgAdvPreferencesBase.cpp:638
 msgid "Leave non-GPU tasks in memory while suspended"
 msgstr "Deixar tarefas não-GPU em memória enquanto estiverem suspensas"
 
-#: clientgui/DlgAdvPreferencesBase.cpp:647
+#: clientgui/DlgAdvPreferencesBase.cpp:639
 msgid ""
 "If checked, suspended tasks stay in memory, and resume with no work lost. If"
 " unchecked, suspended tasks are removed from memory, and resume from their "
 "last checkpoint."
 msgstr "Se marcado, as tarefas suspensas ficam em memória e, retomam sem trabalho perdido. Se não estiver marcado, as tarefas suspensas são removidas da memória e, retoma a partir do seu último checkpoint."
 
-#: clientgui/DlgAdvPreferencesBase.cpp:651
+#: clientgui/DlgAdvPreferencesBase.cpp:643
 #, c-format
 msgid "Limit the swap space (page file) used by %s."
 msgstr "Limitar o espaço swap (ficheiro de paginação) utilizado por %s."
 
-#: clientgui/DlgAdvPreferencesBase.cpp:653
+#: clientgui/DlgAdvPreferencesBase.cpp:645
 msgid "Page/swap file: use at most"
-msgstr "Página/ficheiro swap: usar no máximo"
+msgstr "Página/ficheiro swap: utilizar no máximo"
 
-#: clientgui/DlgAdvPreferencesBase.cpp:678 clientgui/sg_DlgPreferences.cpp:279
+#: clientgui/DlgAdvPreferencesBase.cpp:670 clientgui/sg_DlgPreferences.cpp:295
 msgid "and"
 msgstr "e"
 
-#: clientgui/DlgAdvPreferencesBase.cpp:679
+#: clientgui/DlgAdvPreferencesBase.cpp:671
 msgid "to"
 msgstr "para"
 
-#: clientgui/DlgAdvPreferencesBase.cpp:692 clientgui/sg_DlgPreferences.cpp:281
+#: clientgui/DlgAdvPreferencesBase.cpp:691 clientgui/sg_DlgPreferences.cpp:296
 msgid "Compute only during a particular period each day."
 msgstr "Computação apenas durante um período do dia específico."
 
-#: clientgui/DlgAdvPreferencesBase.cpp:695 clientgui/sg_DlgPreferences.cpp:284
+#: clientgui/DlgAdvPreferencesBase.cpp:694 clientgui/sg_DlgPreferences.cpp:299
 msgid "Compute only between"
 msgstr "Computação apenas entre"
 
-#: clientgui/DlgAdvPreferencesBase.cpp:705
-#: clientgui/DlgAdvPreferencesBase.cpp:852
+#: clientgui/DlgAdvPreferencesBase.cpp:718
+#: clientgui/DlgAdvPreferencesBase.cpp:902
 msgid "Day-of-week override"
 msgstr "Anular dia da semana"
 
-#: clientgui/DlgAdvPreferencesBase.cpp:709
-#: clientgui/DlgAdvPreferencesBase.cpp:856
+#: clientgui/DlgAdvPreferencesBase.cpp:727
+#: clientgui/DlgAdvPreferencesBase.cpp:906
 msgid "Override the times above on the selected days:"
 msgstr "Anular os horários acima dos dias seleccionados:"
 
-#: clientgui/DlgAdvPreferencesBase.cpp:727
-#: clientgui/DlgAdvPreferencesBase.cpp:873
+#: clientgui/DlgAdvPreferencesBase.cpp:750
+#: clientgui/DlgAdvPreferencesBase.cpp:923
 msgid "Monday"
 msgstr "Segunda"
 
-#: clientgui/DlgAdvPreferencesBase.cpp:742
-#: clientgui/DlgAdvPreferencesBase.cpp:888
+#: clientgui/DlgAdvPreferencesBase.cpp:777
+#: clientgui/DlgAdvPreferencesBase.cpp:938
 msgid "Friday"
 msgstr "Sexta"
 
-#: clientgui/DlgAdvPreferencesBase.cpp:755
-#: clientgui/DlgAdvPreferencesBase.cpp:901
+#: clientgui/DlgAdvPreferencesBase.cpp:792
+#: clientgui/DlgAdvPreferencesBase.cpp:951
 msgid "Tuesday"
 msgstr "Terça"
 
-#: clientgui/DlgAdvPreferencesBase.cpp:770
-#: clientgui/DlgAdvPreferencesBase.cpp:916
+#: clientgui/DlgAdvPreferencesBase.cpp:807
+#: clientgui/DlgAdvPreferencesBase.cpp:966
 msgid "Saturday"
 msgstr "Sábado"
 
-#: clientgui/DlgAdvPreferencesBase.cpp:783
-#: clientgui/DlgAdvPreferencesBase.cpp:929
+#: clientgui/DlgAdvPreferencesBase.cpp:820
+#: clientgui/DlgAdvPreferencesBase.cpp:979
 msgid "Wednesday"
 msgstr "Quarta"
 
-#: clientgui/DlgAdvPreferencesBase.cpp:798
-#: clientgui/DlgAdvPreferencesBase.cpp:944
+#: clientgui/DlgAdvPreferencesBase.cpp:835
+#: clientgui/DlgAdvPreferencesBase.cpp:994
 msgid "Sunday"
 msgstr "Domingo"
 
-#: clientgui/DlgAdvPreferencesBase.cpp:811
-#: clientgui/DlgAdvPreferencesBase.cpp:957
+#: clientgui/DlgAdvPreferencesBase.cpp:848
+#: clientgui/DlgAdvPreferencesBase.cpp:1007
 msgid "Thursday"
 msgstr "Quinta"
 
-#: clientgui/DlgAdvPreferencesBase.cpp:840 clientgui/sg_DlgPreferences.cpp:311
+#: clientgui/DlgAdvPreferencesBase.cpp:890 clientgui/sg_DlgPreferences.cpp:317
 msgid "Transfer files only during a particular period each day."
 msgstr "Transferir ficheiros apenas durante um período específico do dia."
 
-#: clientgui/DlgAdvPreferencesBase.cpp:842 clientgui/sg_DlgPreferences.cpp:313
+#: clientgui/DlgAdvPreferencesBase.cpp:892 clientgui/sg_DlgPreferences.cpp:319
 msgid "Transfer files only between"
 msgstr "Transferir ficheiros apenas entre"
 
@@ -1597,7 +1597,7 @@ msgstr "Estas bandeiras habilitam vários tipos de mensagens de diagnóstico no
 
 #: clientgui/DlgDiagnosticLogFlags.cpp:99
 msgid "More info ..."
-msgstr "Mais informação..."
+msgstr "Mais informações..."
 
 #: clientgui/DlgDiagnosticLogFlags.cpp:120 clientgui/DlgHiddenColumns.cpp:101
 msgid "Save all values and close the dialog"
@@ -1615,45 +1615,45 @@ msgstr "Restaurar definições predefinidas"
 msgid "Close the dialog without saving"
 msgstr "Fechar caixa de diálogo sem guardar"
 
-#: clientgui/DlgEventLog.cpp:227
+#: clientgui/DlgEventLog.cpp:236
 #, c-format
 msgid "%s - Event Log"
 msgstr "%s - Registo de Eventos"
 
 #. Create List Pane Items
-#: clientgui/DlgEventLog.cpp:237 clientgui/ViewMessages.cpp:117
-#: clientgui/ViewProjects.cpp:253 clientgui/ViewStatistics.cpp:411
+#: clientgui/DlgEventLog.cpp:246 clientgui/ViewMessages.cpp:117
+#: clientgui/ViewProjects.cpp:251 clientgui/ViewStatistics.cpp:411
 #: clientgui/ViewStatistics.cpp:1983 clientgui/ViewTransfers.cpp:209
 #: clientgui/ViewWork.cpp:260
 msgid "Project"
 msgstr "Projecto"
 
-#: clientgui/DlgEventLog.cpp:238 clientgui/ViewMessages.cpp:118
+#: clientgui/DlgEventLog.cpp:247 clientgui/ViewMessages.cpp:118
 msgid "Time"
 msgstr "Tempo"
 
-#: clientgui/DlgEventLog.cpp:239 clientgui/ViewMessages.cpp:119
+#: clientgui/DlgEventLog.cpp:248 clientgui/ViewMessages.cpp:119
 msgid "Message"
 msgstr "Mensagem"
 
-#: clientgui/DlgEventLog.cpp:296 clientgui/DlgEventLog.cpp:346
+#: clientgui/DlgEventLog.cpp:305 clientgui/DlgEventLog.cpp:355
 msgid "&Show only this project"
 msgstr "&Mostrar apenas este projecto"
 
-#: clientgui/DlgEventLog.cpp:300
+#: clientgui/DlgEventLog.cpp:309
 msgid "Copy &All"
 msgstr "Copiar &Todos"
 
-#: clientgui/DlgEventLog.cpp:302 clientgui/DlgEventLog.cpp:306
+#: clientgui/DlgEventLog.cpp:311 clientgui/DlgEventLog.cpp:315
 #: clientgui/ViewMessages.cpp:89
 msgid "Copy all the messages to the clipboard."
 msgstr "Copiar todas as mensagens para a área de transferência."
 
-#: clientgui/DlgEventLog.cpp:311
+#: clientgui/DlgEventLog.cpp:320
 msgid "Copy &Selected"
 msgstr "Copiar &Seleccionado"
 
-#: clientgui/DlgEventLog.cpp:314 clientgui/DlgEventLog.cpp:322
+#: clientgui/DlgEventLog.cpp:323 clientgui/DlgEventLog.cpp:331
 #: clientgui/ViewMessages.cpp:97
 msgid ""
 "Copy the selected messages to the clipboard. You can select multiple "
@@ -1661,7 +1661,7 @@ msgid ""
 "messages."
 msgstr "Copiar as mensagens seleccionadas para a área de transferência. Pode seleccionar múltiplas mensagens pressionando o shift enquanto clica nas mensagens."
 
-#: clientgui/DlgEventLog.cpp:316 clientgui/DlgEventLog.cpp:324
+#: clientgui/DlgEventLog.cpp:325 clientgui/DlgEventLog.cpp:333
 #: clientgui/ViewMessages.cpp:99
 msgid ""
 "Copy the selected messages to the clipboard. You can select multiple "
@@ -1669,19 +1669,19 @@ msgid ""
 "messages."
 msgstr "Copiar as mensagens seleccionadas para a área de transferência. Pode seleccionar múltiplas mensagens pressionando o shift ou a tecla Ctrl enquanto clica nas mensagens."
 
-#: clientgui/DlgEventLog.cpp:331 clientgui/DlgItemProperties.cpp:67
+#: clientgui/DlgEventLog.cpp:340 clientgui/DlgItemProperties.cpp:67
 msgid "&Close"
 msgstr "&Fechar"
 
-#: clientgui/DlgEventLog.cpp:340
+#: clientgui/DlgEventLog.cpp:349
 msgid "Show all &messages"
 msgstr "Mostrar todas as &mensagens"
 
-#: clientgui/DlgEventLog.cpp:341 clientgui/DlgEventLog.cpp:343
+#: clientgui/DlgEventLog.cpp:350 clientgui/DlgEventLog.cpp:352
 msgid "Show messages for all projects"
 msgstr "Mostrar mensagens para todos os projectos"
 
-#: clientgui/DlgEventLog.cpp:347 clientgui/DlgEventLog.cpp:349
+#: clientgui/DlgEventLog.cpp:356 clientgui/DlgEventLog.cpp:358
 msgid "Show only the messages for the selected project"
 msgstr "Mostrar apenas as mensagens para o projecto seleccionado"
 
@@ -1704,7 +1704,7 @@ msgid "Add an application to this list"
 msgstr "Adicionar uma aplicação a esta lista"
 
 #: clientgui/DlgExclusiveApps.cpp:86 clientgui/DlgExclusiveApps.cpp:110
-#: clientgui/ViewProjects.cpp:232 clientgui/sg_ProjectCommandPopup.cpp:90
+#: clientgui/ViewProjects.cpp:230 clientgui/sg_ProjectCommandPopup.cpp:90
 msgid "Remove"
 msgstr "Remover"
 
@@ -1804,7 +1804,7 @@ msgid "Remember this decision and do not show this dialog."
 msgstr "Lembrar desta decisão e não mostrar esta caixa de diálogo."
 
 #: clientgui/DlgExitMessage.cpp:178 clientgui/DlgGenericMessage.cpp:125
-#: clientgui/DlgOptions.cpp:404 clientgui/DlgSelectComputer.cpp:168
+#: clientgui/DlgOptions.cpp:415 clientgui/DlgSelectComputer.cpp:168
 #: clientgui/wizardex.cpp:378
 msgid "&Cancel"
 msgstr "&Cancelar"
@@ -1821,22 +1821,22 @@ msgstr "%s Selecção de Coluna"
 #: clientgui/DlgHiddenColumns.cpp:77
 #, c-format
 msgid "Select which columns %s should show."
-msgstr "Seleccione que coluna %s deve ser mostrada."
+msgstr "Seleccione que colunas o %s deve mostrar."
 
-#: clientgui/DlgHiddenColumns.cpp:314
+#: clientgui/DlgHiddenColumns.cpp:358
 msgid ""
 "Are you sure you want to reset all list columns to the default "
 "configurations?"
 msgstr "Tem a certeza que quer fazer reset à lista de todas as colunas para as configurações padrão?"
 
-#: clientgui/DlgHiddenColumns.cpp:315
+#: clientgui/DlgHiddenColumns.cpp:359
 msgid "Confirm defaults"
 msgstr "Confirmar predefinidos"
 
 #: clientgui/DlgItemProperties.cpp:194 clientgui/DlgItemProperties.cpp:197
 #: clientgui/DlgItemProperties.cpp:200 clientgui/DlgItemProperties.cpp:203
-msgid "Don't fetch tasks for "
-msgstr "Não obter tarefas por"
+msgid "Don't request tasks for "
+msgstr "Não solicitar tarefas para"
 
 #: clientgui/DlgItemProperties.cpp:194
 msgid "Project preference"
@@ -1854,358 +1854,398 @@ msgstr "O projecto não tem aplicações por"
 msgid "Client configuration excludes "
 msgstr "Configurações do cliente exclui"
 
-#: clientgui/DlgItemProperties.cpp:207
-msgid " work fetch deferred for"
-msgstr " obtenção de trabalho suspenso por"
+#: clientgui/DlgItemProperties.cpp:209
+#, c-format
+msgid "%s task request deferred for"
+msgstr "%s obtenção de tarefas deferido por"
 
-#: clientgui/DlgItemProperties.cpp:208
-msgid " work fetch deferral interval"
-msgstr " intervalo de suspensão de obtenção de trabalho"
+#: clientgui/DlgItemProperties.cpp:213
+#, c-format
+msgid "%s task request deferral interval"
+msgstr "%s intervalo de deferimento da obtenção de tarefas"
 
 #. set dialog title
-#: clientgui/DlgItemProperties.cpp:239
+#: clientgui/DlgItemProperties.cpp:247
 msgid "Properties of project "
 msgstr "Propriedades do projecto"
 
 #. layout controls
-#: clientgui/DlgItemProperties.cpp:243 clientgui/DlgOptions.cpp:221
+#: clientgui/DlgItemProperties.cpp:251 clientgui/DlgOptions.cpp:232
 msgid "General"
 msgstr "Geral"
 
-#: clientgui/DlgItemProperties.cpp:244
-msgid "Master URL"
-msgstr "URL Master"
+#: clientgui/DlgItemProperties.cpp:252
+msgid "URL"
+msgstr "URL"
 
-#: clientgui/DlgItemProperties.cpp:245
+#: clientgui/DlgItemProperties.cpp:253
 msgid "User name"
 msgstr "Nome de utilizador"
 
-#: clientgui/DlgItemProperties.cpp:246
+#: clientgui/DlgItemProperties.cpp:254
 msgid "Team name"
 msgstr "Nome da equipa"
 
-#: clientgui/DlgItemProperties.cpp:247 clientgui/ViewProjects.cpp:258
+#: clientgui/DlgItemProperties.cpp:255 clientgui/ViewProjects.cpp:256
 msgid "Resource share"
 msgstr "Quota de recursos"
 
-#: clientgui/DlgItemProperties.cpp:249
+#: clientgui/DlgItemProperties.cpp:257
 msgid "Scheduler RPC deferred for"
 msgstr "Agendamento RPC deferido por"
 
-#: clientgui/DlgItemProperties.cpp:252
+#: clientgui/DlgItemProperties.cpp:260
 msgid "File downloads deferred for"
 msgstr "Transferência dos ficheiros deferidos por"
 
-#: clientgui/DlgItemProperties.cpp:255
+#: clientgui/DlgItemProperties.cpp:263
 msgid "File uploads deferred for"
 msgstr "Uploads dos ficheiros deferidos por"
 
-#: clientgui/DlgItemProperties.cpp:257
+#: clientgui/DlgItemProperties.cpp:265
 msgid "Disk usage"
 msgstr "Utilização do disco"
 
-#: clientgui/DlgItemProperties.cpp:258
+#: clientgui/DlgItemProperties.cpp:266
 msgid "Computer ID"
 msgstr "ID do Computador"
 
-#: clientgui/DlgItemProperties.cpp:260
+#: clientgui/DlgItemProperties.cpp:268
 msgid "Non CPU intensive"
 msgstr "CPU não intensivo"
 
-#: clientgui/DlgItemProperties.cpp:260 clientgui/DlgItemProperties.cpp:262
-#: clientgui/DlgItemProperties.cpp:263 clientgui/DlgItemProperties.cpp:265
-#: clientgui/DlgItemProperties.cpp:268 clientgui/DlgItemProperties.cpp:277
-#: clientgui/DlgItemProperties.cpp:280 clientgui/DlgItemProperties.cpp:283
+#: clientgui/DlgItemProperties.cpp:268 clientgui/DlgItemProperties.cpp:270
+#: clientgui/DlgItemProperties.cpp:271 clientgui/DlgItemProperties.cpp:273
+#: clientgui/DlgItemProperties.cpp:276 clientgui/DlgItemProperties.cpp:285
+#: clientgui/DlgItemProperties.cpp:288 clientgui/DlgItemProperties.cpp:291
 msgid "yes"
 msgstr "sim"
 
-#: clientgui/DlgItemProperties.cpp:262
+#: clientgui/DlgItemProperties.cpp:270
 msgid "Suspended via GUI"
 msgstr "Suspenso através da GUI"
 
-#: clientgui/DlgItemProperties.cpp:262 clientgui/DlgItemProperties.cpp:263
+#: clientgui/DlgItemProperties.cpp:270 clientgui/DlgItemProperties.cpp:271
 msgid "no"
 msgstr "não"
 
-#: clientgui/DlgItemProperties.cpp:263
-msgid "Don't request more work"
-msgstr "Não pedir mais trabalhos "
+#: clientgui/DlgItemProperties.cpp:271
+msgid "Don't request tasks"
+msgstr "Não solicitar tarefas"
 
-#: clientgui/DlgItemProperties.cpp:265
+#: clientgui/DlgItemProperties.cpp:273
 msgid "Scheduler call in progress"
 msgstr "Agendamento de tarefas em progresso"
 
-#: clientgui/DlgItemProperties.cpp:268
+#: clientgui/DlgItemProperties.cpp:276
 msgid "Trickle-up pending"
 msgstr "Avisos pendentes"
 
-#: clientgui/DlgItemProperties.cpp:271 clientgui/DlgItemProperties.cpp:273
+#: clientgui/DlgItemProperties.cpp:279 clientgui/DlgItemProperties.cpp:281
 msgid "Host location"
 msgstr "Localização do anfitrião"
 
-#: clientgui/DlgItemProperties.cpp:273
+#: clientgui/DlgItemProperties.cpp:281
 msgid "default"
 msgstr "predefinido"
 
-#: clientgui/DlgItemProperties.cpp:277
+#: clientgui/DlgItemProperties.cpp:285
 msgid "Added via account manager"
 msgstr "Adicionado através do gestor de conta"
 
-#: clientgui/DlgItemProperties.cpp:280
+#: clientgui/DlgItemProperties.cpp:288
 msgid "Remove when tasks done"
 msgstr "Remover quando as tarefas concluirem"
 
-#: clientgui/DlgItemProperties.cpp:283
+#: clientgui/DlgItemProperties.cpp:291
 msgid "Ended"
 msgstr "Terminado"
 
-#: clientgui/DlgItemProperties.cpp:285
+#: clientgui/DlgItemProperties.cpp:293
 msgid "Tasks completed"
 msgstr "Tarefas concluídas"
 
-#: clientgui/DlgItemProperties.cpp:286
+#: clientgui/DlgItemProperties.cpp:294
 msgid "Tasks failed"
 msgstr "Tarefas falhadas"
 
-#: clientgui/DlgItemProperties.cpp:288
+#: clientgui/DlgItemProperties.cpp:296
 msgid "Credit"
 msgstr "Créditos"
 
-#: clientgui/DlgItemProperties.cpp:289
+#: clientgui/DlgItemProperties.cpp:297
 msgid "User"
 msgstr "Utilizador"
 
-#: clientgui/DlgItemProperties.cpp:296
+#: clientgui/DlgItemProperties.cpp:300 clientgui/DlgItemProperties.cpp:308
+#, c-format
+msgid "%s total, %s average"
+msgstr "%s total, %s média"
+
+#: clientgui/DlgItemProperties.cpp:305
 msgid "Host"
 msgstr "Anfitrião"
 
-#: clientgui/DlgItemProperties.cpp:305
+#: clientgui/DlgItemProperties.cpp:315
 msgid "Scheduling"
 msgstr "A agendar"
 
-#: clientgui/DlgItemProperties.cpp:306
+#: clientgui/DlgItemProperties.cpp:316
 msgid "Scheduling priority"
 msgstr "Prioridade de agendamento "
 
-#: clientgui/DlgItemProperties.cpp:307
+#: clientgui/DlgItemProperties.cpp:317
 msgid "CPU"
 msgstr "CPU"
 
-#: clientgui/DlgItemProperties.cpp:331
+#: clientgui/DlgItemProperties.cpp:341
 msgid "Duration correction factor"
 msgstr "Duração do factor de correcção"
 
-#: clientgui/DlgItemProperties.cpp:345
+#: clientgui/DlgItemProperties.cpp:349
+msgid "Last scheduler reply"
+msgstr "Última resposta do agendador"
+
+#: clientgui/DlgItemProperties.cpp:360
 msgid "Properties of task "
 msgstr "Propriedades da tarefa"
 
-#: clientgui/DlgItemProperties.cpp:357 clientgui/ViewWork.cpp:266
+#: clientgui/DlgItemProperties.cpp:372 clientgui/ViewWork.cpp:266
 msgid "Application"
 msgstr "Aplicação"
 
-#: clientgui/DlgItemProperties.cpp:358 clientgui/ViewWork.cpp:267
+#: clientgui/DlgItemProperties.cpp:373 clientgui/ViewWork.cpp:267
 msgid "Name"
 msgstr "Nome"
 
-#: clientgui/DlgItemProperties.cpp:359
+#: clientgui/DlgItemProperties.cpp:374
 msgid "State"
 msgstr "Estado"
 
-#: clientgui/DlgItemProperties.cpp:362
+#: clientgui/DlgItemProperties.cpp:377
 msgid "Received"
 msgstr "Recebido"
 
-#: clientgui/DlgItemProperties.cpp:365
+#: clientgui/DlgItemProperties.cpp:380
 msgid "Report deadline"
 msgstr "Reportar data limite de entrega"
 
-#: clientgui/DlgItemProperties.cpp:367
+#: clientgui/DlgItemProperties.cpp:382
 msgid "Resources"
 msgstr "Recursos"
 
-#: clientgui/DlgItemProperties.cpp:370
+#: clientgui/DlgItemProperties.cpp:385
 msgid "Estimated computation size"
 msgstr "Tamanho estimado de computação"
 
-#: clientgui/DlgItemProperties.cpp:373
+#: clientgui/DlgItemProperties.cpp:390
 msgid "CPU time at last checkpoint"
 msgstr "Tempo de CPU no ultimo checkpoint"
 
-#: clientgui/DlgItemProperties.cpp:374 clientgui/DlgItemProperties.cpp:389
+#: clientgui/DlgItemProperties.cpp:391 clientgui/DlgItemProperties.cpp:417
 msgid "CPU time"
 msgstr "Tempo de CPU"
 
-#: clientgui/DlgItemProperties.cpp:376 clientgui/DlgItemProperties.cpp:390
+#: clientgui/DlgItemProperties.cpp:393 clientgui/DlgItemProperties.cpp:418
 msgid "Elapsed time"
 msgstr "Tempo decorrido"
 
-#: clientgui/DlgItemProperties.cpp:378
+#: clientgui/DlgItemProperties.cpp:395
 msgid "Estimated time remaining"
 msgstr "Tempo restante previsto"
 
-#: clientgui/DlgItemProperties.cpp:379
+#: clientgui/DlgItemProperties.cpp:396
 msgid "Fraction done"
 msgstr "Fracção feita"
 
-#: clientgui/DlgItemProperties.cpp:380
+#: clientgui/DlgItemProperties.cpp:397
 msgid "Virtual memory size"
 msgstr "Tamanho da memória virtual"
 
-#: clientgui/DlgItemProperties.cpp:381
+#: clientgui/DlgItemProperties.cpp:398
 msgid "Working set size"
 msgstr "Tamanho previsto do trabalho"
 
-#: clientgui/DlgItemProperties.cpp:383
+#: clientgui/DlgItemProperties.cpp:400
 msgid "Directory"
 msgstr "Directoria"
 
-#: clientgui/DlgItemProperties.cpp:386
+#: clientgui/DlgItemProperties.cpp:403
 msgid "Process ID"
 msgstr "ID do Processo"
 
-#: clientgui/DlgItemProperties.cpp:456 clientgui/ViewWork.cpp:1125
-#: clientgui/sg_TaskPanel.cpp:827
+#: clientgui/DlgItemProperties.cpp:409 clientgui/DlgItemProperties.cpp:411
+#: clientgui/DlgItemProperties.cpp:413
+msgid "Progress rate"
+msgstr "Taxa de progresso"
+
+#: clientgui/DlgItemProperties.cpp:409
+msgid "per hour"
+msgstr "por hora"
+
+#: clientgui/DlgItemProperties.cpp:411
+msgid "per minute"
+msgstr "por minuto"
+
+#: clientgui/DlgItemProperties.cpp:413
+msgid "per second"
+msgstr "por segundo"
+
+#: clientgui/DlgItemProperties.cpp:421
+msgid "Executable"
+msgstr "Executável"
+
+#: clientgui/DlgItemProperties.cpp:487 clientgui/ViewWork.cpp:1125
+#: clientgui/sg_TaskPanel.cpp:828
 msgid "Local: "
 msgstr "Local:"
 
-#: clientgui/DlgOptions.cpp:129 clientgui/DlgOptions.cpp:135
+#: clientgui/DlgOptions.cpp:130 clientgui/DlgOptions.cpp:136
 msgid "Options"
 msgstr "Opções"
 
-#: clientgui/DlgOptions.cpp:178
+#: clientgui/DlgOptions.cpp:179
 msgid "Language:"
-msgstr "Linguagem:"
+msgstr "Idioma:"
 
-#: clientgui/DlgOptions.cpp:185
+#: clientgui/DlgOptions.cpp:186
 msgid "What language should BOINC use?"
 msgstr "Que idioma deve o BOINC utilizar?"
 
-#: clientgui/DlgOptions.cpp:189
+#: clientgui/DlgOptions.cpp:190
 msgid "Notice reminder interval:"
 msgstr "Intervalo de advertência de noticias:"
 
-#: clientgui/DlgOptions.cpp:196
+#: clientgui/DlgOptions.cpp:197
 msgid "How often should BOINC remind you of new notices?"
 msgstr "Com quem frequência deve o BOINC lembrar-lhe de novas notícias?"
 
-#: clientgui/DlgOptions.cpp:201
+#: clientgui/DlgOptions.cpp:202
 msgid "Run Manager at login?"
 msgstr "Executar o Gestor no login?"
 
-#: clientgui/DlgOptions.cpp:207
+#: clientgui/DlgOptions.cpp:208
 msgid "Run the BOINC Manager when you log on."
 msgstr "Executar o BOINC Manager quando se liga"
 
-#: clientgui/DlgOptions.cpp:212
+#: clientgui/DlgOptions.cpp:213
+msgid "Run daemon?"
+msgstr "Correr daemon?"
+
+#: clientgui/DlgOptions.cpp:219
+msgid "Run daemon when launching the Manager."
+msgstr "Correr daemon quando o Gestor for lançado."
+
+#: clientgui/DlgOptions.cpp:223
 msgid "Enable Manager exit dialog?"
-msgstr "Activar a caixa de diálogo de saída do Gestor?"
+msgstr "Habilitar a caixa de diálogo na saída do gestor?"
 
-#: clientgui/DlgOptions.cpp:218
+#: clientgui/DlgOptions.cpp:229
 msgid "Display the exit dialog when shutting down the Manager."
 msgstr "Mostrar a caixa de diálogo quando o Gestor estiver a ser desligado."
 
-#: clientgui/DlgOptions.cpp:229
+#: clientgui/DlgOptions.cpp:240
 msgid "Dial-up and Virtual Private Network settings"
-msgstr "Definições da ligação Dial-up e da Rede Virtual Privada"
+msgstr "Definições de ligação Dial-up e da Rede Virtual Privada"
 
-#: clientgui/DlgOptions.cpp:243
+#: clientgui/DlgOptions.cpp:254
 msgid "&Set Default"
 msgstr "&Definir Predefinido"
 
-#: clientgui/DlgOptions.cpp:248
+#: clientgui/DlgOptions.cpp:259
 msgid "&Clear Default"
 msgstr "&Limpar Predefinido"
 
-#: clientgui/DlgOptions.cpp:255
+#: clientgui/DlgOptions.cpp:266
 msgid "Default Connection:"
 msgstr "Ligação Predefinida:"
 
-#: clientgui/DlgOptions.cpp:262
+#: clientgui/DlgOptions.cpp:273
 msgid "Connections"
 msgstr "Ligações"
 
-#: clientgui/DlgOptions.cpp:271
+#: clientgui/DlgOptions.cpp:282
 msgid "Connect via HTTP proxy server"
 msgstr "Ligar através de servidor HTTP proxy"
 
-#: clientgui/DlgOptions.cpp:275
+#: clientgui/DlgOptions.cpp:286
 msgid "HTTP Proxy Server Configuration"
 msgstr "Configurações do servidor HTTP Proxy"
 
-#: clientgui/DlgOptions.cpp:283 clientgui/DlgOptions.cpp:347
+#: clientgui/DlgOptions.cpp:294 clientgui/DlgOptions.cpp:358
 msgid "Address:"
 msgstr "Endereço:"
 
-#: clientgui/DlgOptions.cpp:291 clientgui/DlgOptions.cpp:355
+#: clientgui/DlgOptions.cpp:302 clientgui/DlgOptions.cpp:366
 #: clientgui/ProxyPage.cpp:340 clientgui/ProxyPage.cpp:360
 msgid "Port:"
 msgstr "Porta:"
 
-#: clientgui/DlgOptions.cpp:299 clientgui/DlgOptions.cpp:363
+#: clientgui/DlgOptions.cpp:310 clientgui/DlgOptions.cpp:374
 msgid "Don't use proxy for:"
 msgstr "Não usar proxy para:"
 
-#: clientgui/DlgOptions.cpp:306 clientgui/DlgOptions.cpp:370
+#: clientgui/DlgOptions.cpp:317 clientgui/DlgOptions.cpp:381
 msgid "Leave these blank if not needed"
 msgstr "Deixar em branco se desnecessário"
 
-#: clientgui/DlgOptions.cpp:312 clientgui/DlgOptions.cpp:376
+#: clientgui/DlgOptions.cpp:323 clientgui/DlgOptions.cpp:387
 #: clientgui/ProxyPage.cpp:343 clientgui/ProxyPage.cpp:363
 msgid "User Name:"
 msgstr "Nome de Utilizador:"
 
-#: clientgui/DlgOptions.cpp:320 clientgui/DlgOptions.cpp:384
+#: clientgui/DlgOptions.cpp:331 clientgui/DlgOptions.cpp:395
 #: clientgui/DlgSelectComputer.cpp:152 clientgui/ProxyPage.cpp:346
 #: clientgui/ProxyPage.cpp:366
 msgid "Password:"
 msgstr "Palavra-passe:"
 
-#: clientgui/DlgOptions.cpp:327
+#: clientgui/DlgOptions.cpp:338
 msgid "HTTP Proxy"
 msgstr "HTTP Proxy"
 
-#: clientgui/DlgOptions.cpp:335
+#: clientgui/DlgOptions.cpp:346
 msgid "Connect via SOCKS proxy server"
 msgstr "Ligar através de servidor SOCKS proxy"
 
-#: clientgui/DlgOptions.cpp:339
+#: clientgui/DlgOptions.cpp:350
 msgid "SOCKS Proxy Server Configuration"
 msgstr "Configurações do servidor de SOCKS Proxy"
 
-#: clientgui/DlgOptions.cpp:391
+#: clientgui/DlgOptions.cpp:402
 msgid "SOCKS Proxy"
 msgstr "SOCKS Proxy"
 
-#: clientgui/DlgOptions.cpp:589
+#: clientgui/DlgOptions.cpp:600
 msgid "always"
 msgstr "sempre"
 
-#: clientgui/DlgOptions.cpp:590
+#: clientgui/DlgOptions.cpp:601
 msgid "1 hour"
 msgstr "1 hora"
 
-#: clientgui/DlgOptions.cpp:591
+#: clientgui/DlgOptions.cpp:602
 msgid "6 hours"
 msgstr "6 horas"
 
-#: clientgui/DlgOptions.cpp:592
+#: clientgui/DlgOptions.cpp:603
 msgid "1 day"
 msgstr "1 dia"
 
-#: clientgui/DlgOptions.cpp:593
+#: clientgui/DlgOptions.cpp:604
 msgid "1 week"
 msgstr "1 semana"
 
-#: clientgui/DlgOptions.cpp:594
+#: clientgui/DlgOptions.cpp:605
 msgid "never"
 msgstr "nunca"
 
-#: clientgui/DlgOptions.cpp:691
+#: clientgui/DlgOptions.cpp:703
 #, c-format
 msgid "%s - Language Selection"
 msgstr "%s - Selecção de Idioma"
 
-#: clientgui/DlgOptions.cpp:698
+#: clientgui/DlgOptions.cpp:710
 #, c-format
 msgid ""
 "The %s's language has been changed.  In order for this change to take "
@@ -2351,7 +2391,7 @@ msgid "The home page of the GEO-600 project"
 msgstr "A página principal do projecto GEO-600"
 
 #: clientgui/Localization.cpp:115 clientgui/Localization.cpp:133
-#: clientgui/ViewProjects.cpp:255 clientgui/ViewStatistics.cpp:441
+#: clientgui/ViewProjects.cpp:253 clientgui/ViewStatistics.cpp:441
 msgid "Team"
 msgstr "Equipa"
 
@@ -2415,203 +2455,203 @@ msgstr "Pesquisa"
 msgid "Learn about the projects hosted at World Community Grid"
 msgstr "Aprender acerca dos projectos alojados em World Community Grid"
 
-#: clientgui/MainDocument.cpp:583
+#: clientgui/MainDocument.cpp:585
 msgid "Starting client"
 msgstr "A iniciar cliente"
 
-#: clientgui/MainDocument.cpp:591
+#: clientgui/MainDocument.cpp:593
 msgid "Connecting to client"
 msgstr "Ligando-se ao cliente"
 
-#: clientgui/MainDocument.cpp:1205
+#: clientgui/MainDocument.cpp:1207
 msgid "Retrieving system state; please wait..."
 msgstr "A recuperar o estado do sistema; por favor aguarde..."
 
-#: clientgui/MainDocument.cpp:1826
+#: clientgui/MainDocument.cpp:1828
 msgid "Missing application"
 msgstr "Aplicação em falta"
 
-#: clientgui/MainDocument.cpp:1827
+#: clientgui/MainDocument.cpp:1829
 msgid ""
 "Please download and install the CoRD application from "
 "http://cord.sourceforge.net"
 msgstr "Por favor, transfira e instale a aplicação CoRD de http://cord.sourceforge.net"
 
-#: clientgui/MainDocument.cpp:2442
+#: clientgui/MainDocument.cpp:2443
 msgid "on batteries"
 msgstr "em bateria"
 
-#: clientgui/MainDocument.cpp:2443
+#: clientgui/MainDocument.cpp:2444
 msgid "computer is in use"
 msgstr "computador em utilização"
 
-#: clientgui/MainDocument.cpp:2444
+#: clientgui/MainDocument.cpp:2445
 msgid "user request"
 msgstr "pedido do utilizador"
 
-#: clientgui/MainDocument.cpp:2445
+#: clientgui/MainDocument.cpp:2446
 msgid "time of day"
 msgstr "hora do dia"
 
-#: clientgui/MainDocument.cpp:2446
+#: clientgui/MainDocument.cpp:2447
 msgid "CPU benchmarks in progress"
 msgstr "Testes de performance do CPU em progresso"
 
-#: clientgui/MainDocument.cpp:2447
+#: clientgui/MainDocument.cpp:2448
 msgid "need disk space - check preferences"
 msgstr "espaço em disco necessário - verifique preferências"
 
-#: clientgui/MainDocument.cpp:2448
+#: clientgui/MainDocument.cpp:2449
 msgid "computer is not in use"
 msgstr "computador não está em utilização"
 
-#: clientgui/MainDocument.cpp:2449
+#: clientgui/MainDocument.cpp:2450
 msgid "starting up"
 msgstr "a iniciar"
 
-#: clientgui/MainDocument.cpp:2450
+#: clientgui/MainDocument.cpp:2451
 msgid "an exclusive app is running"
 msgstr "uma aplicação exclusiva está em execução"
 
-#: clientgui/MainDocument.cpp:2451
+#: clientgui/MainDocument.cpp:2452
 msgid "CPU is busy"
 msgstr "O CPU está ocupado"
 
-#: clientgui/MainDocument.cpp:2452
+#: clientgui/MainDocument.cpp:2453
 msgid "network bandwidth limit exceeded"
 msgstr "limite de largura de banda excedido"
 
-#: clientgui/MainDocument.cpp:2453
+#: clientgui/MainDocument.cpp:2454
 msgid "requested by operating system"
 msgstr "pedido pelo sistema operativo"
 
-#: clientgui/MainDocument.cpp:2455
+#: clientgui/MainDocument.cpp:2456
 msgid "unknown reason"
 msgstr "razão desconhecida"
 
-#: clientgui/MainDocument.cpp:2477
+#: clientgui/MainDocument.cpp:2478
 msgid "GPU missing, "
 msgstr "GPU não detectado,"
 
-#: clientgui/MainDocument.cpp:2484
+#: clientgui/MainDocument.cpp:2485
 msgid "New"
 msgstr "Novo"
 
-#: clientgui/MainDocument.cpp:2488
+#: clientgui/MainDocument.cpp:2489
 msgid "Download failed"
 msgstr "Transferência falhada"
 
-#: clientgui/MainDocument.cpp:2490
+#: clientgui/MainDocument.cpp:2491
 msgid "Downloading"
 msgstr "Fazendo a transferência"
 
-#: clientgui/MainDocument.cpp:2492 clientgui/MainDocument.cpp:2551
+#: clientgui/MainDocument.cpp:2493 clientgui/MainDocument.cpp:2552
 msgid " (suspended - "
 msgstr "(suspenso - "
 
-#: clientgui/MainDocument.cpp:2500
+#: clientgui/MainDocument.cpp:2501
 msgid "Project suspended by user"
 msgstr "Projecto suspenso pelo utilizador"
 
-#: clientgui/MainDocument.cpp:2502
+#: clientgui/MainDocument.cpp:2503
 msgid "Task suspended by user"
 msgstr "Tarefa suspensa pelo utilizador"
 
 #. an NCI process can be running even though computation is suspended
 #. (because of <dont_suspend_nci>
-#: clientgui/MainDocument.cpp:2507
+#: clientgui/MainDocument.cpp:2508
 msgid "Suspended - "
 msgstr "Suspenso - "
 
-#: clientgui/MainDocument.cpp:2510
+#: clientgui/MainDocument.cpp:2511
 msgid "GPU suspended - "
 msgstr "GPU suspensa - "
 
-#: clientgui/MainDocument.cpp:2514
+#: clientgui/MainDocument.cpp:2515
 msgid "Waiting for memory"
 msgstr "A aguardar por memória"
 
-#: clientgui/MainDocument.cpp:2516
+#: clientgui/MainDocument.cpp:2517
 msgid "Waiting for shared memory"
 msgstr "A aguardar por memória partilhada"
 
-#: clientgui/MainDocument.cpp:2518
+#: clientgui/MainDocument.cpp:2519
 msgid "Running"
 msgstr "Executando"
 
-#: clientgui/MainDocument.cpp:2520
+#: clientgui/MainDocument.cpp:2521
 msgid " (non-CPU-intensive)"
 msgstr " (CPU não intensivo)"
 
-#: clientgui/MainDocument.cpp:2523
+#: clientgui/MainDocument.cpp:2524
 msgid "Waiting to run"
 msgstr "A aguardar a execução"
 
-#: clientgui/MainDocument.cpp:2525 clientgui/MainDocument.cpp:2528
+#: clientgui/MainDocument.cpp:2526 clientgui/MainDocument.cpp:2529
 msgid "Ready to start"
 msgstr "Pronto para começar"
 
-#: clientgui/MainDocument.cpp:2532
+#: clientgui/MainDocument.cpp:2533
 msgid "Postponed: "
 msgstr "Adiado:"
 
-#: clientgui/MainDocument.cpp:2535
+#: clientgui/MainDocument.cpp:2536
 msgid "Postponed"
 msgstr "Adiado"
 
-#: clientgui/MainDocument.cpp:2539
+#: clientgui/MainDocument.cpp:2540
 msgid "Waiting for network access"
 msgstr "Aguardando acesso à rede"
 
-#: clientgui/MainDocument.cpp:2543
+#: clientgui/MainDocument.cpp:2544
 msgid "Computation error"
 msgstr "Erro de computação"
 
-#: clientgui/MainDocument.cpp:2547
+#: clientgui/MainDocument.cpp:2548
 msgid "Upload failed"
 msgstr "Upload falhado"
 
-#: clientgui/MainDocument.cpp:2549
+#: clientgui/MainDocument.cpp:2550
 msgid "Uploading"
 msgstr "A fazer o Upload"
 
-#: clientgui/MainDocument.cpp:2560
+#: clientgui/MainDocument.cpp:2561
 msgid "Aborted by user"
 msgstr "Abortado pelo utilizador"
 
-#: clientgui/MainDocument.cpp:2563
+#: clientgui/MainDocument.cpp:2564
 msgid "Aborted by project"
 msgstr "Abortado pelo projecto"
 
-#: clientgui/MainDocument.cpp:2566
+#: clientgui/MainDocument.cpp:2567
 msgid "Aborted: not started by deadline"
 msgstr "Abortado: não iniciado devido à data limite excedida"
 
-#: clientgui/MainDocument.cpp:2569
+#: clientgui/MainDocument.cpp:2570
 msgid "Aborted: task disk limit exceeded"
 msgstr "Cancelado: limite de disco para tarefas excedido"
 
-#: clientgui/MainDocument.cpp:2572
+#: clientgui/MainDocument.cpp:2573
 msgid "Aborted: run time limit exceeded"
 msgstr "Abortado: limite de tempo excedido"
 
-#: clientgui/MainDocument.cpp:2575
+#: clientgui/MainDocument.cpp:2576
 msgid "Aborted: memory limit exceeded"
 msgstr "Abortado: limite em memória excedido"
 
-#: clientgui/MainDocument.cpp:2578
+#: clientgui/MainDocument.cpp:2579
 msgid "Aborted"
 msgstr "Abortado"
 
-#: clientgui/MainDocument.cpp:2583
+#: clientgui/MainDocument.cpp:2584
 msgid "Acknowledged"
 msgstr "Reconhecido"
 
-#: clientgui/MainDocument.cpp:2585
+#: clientgui/MainDocument.cpp:2586
 msgid "Ready to report"
 msgstr "Pronto para reportar"
 
-#: clientgui/MainDocument.cpp:2587
+#: clientgui/MainDocument.cpp:2588
 #, c-format
 msgid "Error: invalid state '%d'"
 msgstr "Erro: estado inválido '%d'"
@@ -2928,7 +2968,7 @@ msgid "'%s' does not contain a valid path."
 msgstr "'%s' não contém um caminho válido."
 
 #. Setup View
-#: clientgui/ViewMessages.cpp:84 clientgui/ViewProjects.cpp:200
+#: clientgui/ViewMessages.cpp:84 clientgui/ViewProjects.cpp:198
 #: clientgui/ViewStatistics.cpp:1952 clientgui/ViewTransfers.cpp:183
 #: clientgui/ViewWork.cpp:207
 msgid "Commands"
@@ -2986,17 +3026,17 @@ msgstr "Não existem notícias nesta altura."
 msgid "Notices"
 msgstr "Notícias"
 
-#: clientgui/ViewProjects.cpp:204 clientgui/sg_ProjectCommandPopup.cpp:66
+#: clientgui/ViewProjects.cpp:202 clientgui/sg_ProjectCommandPopup.cpp:66
 msgid "Update"
 msgstr "Actualizar"
 
-#: clientgui/ViewProjects.cpp:205 clientgui/sg_ProjectCommandPopup.cpp:67
+#: clientgui/ViewProjects.cpp:203 clientgui/sg_ProjectCommandPopup.cpp:67
 msgid ""
 "Report all completed tasks, get latest credit, get latest preferences, and "
 "possibly get more tasks."
 msgstr "Reportar todas as tarefas concluídas, obter os últimos créditos, obter as últimas preferências e possivelmente mais tarefas."
 
-#: clientgui/ViewProjects.cpp:211 clientgui/ViewProjects.cpp:810
+#: clientgui/ViewProjects.cpp:209 clientgui/ViewProjects.cpp:808
 #: clientgui/ViewWork.cpp:232 clientgui/ViewWork.cpp:888
 #: clientgui/sg_BoincSimpleFrame.cpp:893
 #: clientgui/sg_ProjectCommandPopup.cpp:72
@@ -3005,197 +3045,197 @@ msgstr "Reportar todas as tarefas concluídas, obter os últimos créditos, obte
 msgid "Suspend"
 msgstr "Suspender"
 
-#: clientgui/ViewProjects.cpp:212 clientgui/ViewProjects.cpp:810
+#: clientgui/ViewProjects.cpp:210 clientgui/ViewProjects.cpp:808
 #: clientgui/sg_ProjectCommandPopup.cpp:73
 #: clientgui/sg_ProjectCommandPopup.cpp:129
 msgid "Suspend tasks for this project."
 msgstr "Suspender tarefas para este projecto."
 
-#: clientgui/ViewProjects.cpp:218 clientgui/ViewProjects.cpp:829
+#: clientgui/ViewProjects.cpp:216 clientgui/ViewProjects.cpp:827
 #: clientgui/sg_ProjectCommandPopup.cpp:78
 #: clientgui/sg_ProjectCommandPopup.cpp:136
 msgid "No new tasks"
 msgstr "Não obter novas tarefas"
 
-#: clientgui/ViewProjects.cpp:219 clientgui/sg_ProjectCommandPopup.cpp:79
+#: clientgui/ViewProjects.cpp:217 clientgui/sg_ProjectCommandPopup.cpp:79
 msgid "Don't get new tasks for this project."
 msgstr "Não obter novas tarefas para este projecto."
 
-#: clientgui/ViewProjects.cpp:225 clientgui/sg_ProjectCommandPopup.cpp:84
+#: clientgui/ViewProjects.cpp:223 clientgui/sg_ProjectCommandPopup.cpp:84
 msgid "Reset project"
 msgstr "Fazer reset ao projecto"
 
-#: clientgui/ViewProjects.cpp:226 clientgui/sg_ProjectCommandPopup.cpp:85
+#: clientgui/ViewProjects.cpp:224 clientgui/sg_ProjectCommandPopup.cpp:85
 msgid ""
 "Delete all files and tasks associated with this project, and get new tasks."
 "  You can update the project first to report any completed tasks."
 msgstr "Eliminar todos os ficheiros e tarefas associadas a este projecto e, obter novas tarefas. Pode actualizar o projecto primeiro para reportar tarefas concluídas."
 
-#: clientgui/ViewProjects.cpp:233 clientgui/sg_ProjectCommandPopup.cpp:91
+#: clientgui/ViewProjects.cpp:231 clientgui/sg_ProjectCommandPopup.cpp:91
 msgid ""
 "Remove this project.  Tasks in progress will be lost (use 'Update' first to "
 "report any completed tasks)."
 msgstr "Remover este projecto. Tarefas em progresso serão perdidas (use 'Actualizar' primeiro para reportar tarefas concluídas)."
 
-#: clientgui/ViewProjects.cpp:239 clientgui/ViewWork.cpp:246
+#: clientgui/ViewProjects.cpp:237 clientgui/ViewWork.cpp:246
 #: clientgui/sg_ProjectCommandPopup.cpp:96
 #: clientgui/sg_TaskCommandPopup.cpp:84
 msgid "Properties"
 msgstr "Propriedades"
 
-#: clientgui/ViewProjects.cpp:240 clientgui/sg_ProjectCommandPopup.cpp:97
+#: clientgui/ViewProjects.cpp:238 clientgui/sg_ProjectCommandPopup.cpp:97
 msgid "Show project details."
 msgstr "Mostrar detalhes do projecto."
 
-#: clientgui/ViewProjects.cpp:254 clientgui/ViewStatistics.cpp:426
+#: clientgui/ViewProjects.cpp:252 clientgui/ViewStatistics.cpp:426
 msgid "Account"
 msgstr "Conta"
 
-#: clientgui/ViewProjects.cpp:256
+#: clientgui/ViewProjects.cpp:254
 msgid "Work done"
 msgstr "Trabalho concluído"
 
-#: clientgui/ViewProjects.cpp:257
+#: clientgui/ViewProjects.cpp:255
 msgid "Avg. work done"
 msgstr "Média de trabalho realizado"
 
-#: clientgui/ViewProjects.cpp:259 clientgui/ViewTransfers.cpp:215
+#: clientgui/ViewProjects.cpp:257 clientgui/ViewTransfers.cpp:215
 #: clientgui/ViewWork.cpp:262
 msgid "Status"
 msgstr "Estado"
 
-#: clientgui/ViewProjects.cpp:338
+#: clientgui/ViewProjects.cpp:336
 msgid "Projects"
 msgstr "Projectos"
 
-#: clientgui/ViewProjects.cpp:390
+#: clientgui/ViewProjects.cpp:388
 msgid "Updating project..."
 msgstr "A actualizar projecto..."
 
-#: clientgui/ViewProjects.cpp:432
+#: clientgui/ViewProjects.cpp:430
 msgid "Resuming project..."
 msgstr "A resumir projecto..."
 
-#: clientgui/ViewProjects.cpp:436
+#: clientgui/ViewProjects.cpp:434
 msgid "Suspending project..."
 msgstr "A suspender projecto..."
 
-#: clientgui/ViewProjects.cpp:473
+#: clientgui/ViewProjects.cpp:471
 msgid "Telling project to allow additional task downloads..."
 msgstr "A notificar o projecto para permitir a transferência de tarefas adicionais..."
 
-#: clientgui/ViewProjects.cpp:477
+#: clientgui/ViewProjects.cpp:475
 msgid "Telling project to not fetch any additional tasks..."
 msgstr "A notificar o projecto para não obter tarefas adicionais..."
 
-#: clientgui/ViewProjects.cpp:513
+#: clientgui/ViewProjects.cpp:511
 msgid "Resetting project..."
 msgstr "A fazer reset ao projecto..."
 
-#: clientgui/ViewProjects.cpp:526 clientgui/sg_ProjectCommandPopup.cpp:229
+#: clientgui/ViewProjects.cpp:524 clientgui/sg_ProjectCommandPopup.cpp:229
 #, c-format
 msgid "Are you sure you want to reset project '%s'?"
 msgstr "Tem a certeza que quer fazer o reset ao projecto '%s'?"
 
-#: clientgui/ViewProjects.cpp:532 clientgui/sg_ProjectCommandPopup.cpp:235
+#: clientgui/ViewProjects.cpp:530 clientgui/sg_ProjectCommandPopup.cpp:235
 msgid "Reset Project"
 msgstr "Fazer Reset ao Projecto"
 
-#: clientgui/ViewProjects.cpp:571
+#: clientgui/ViewProjects.cpp:569
 msgid "Removing project..."
 msgstr "A remover projecto..."
 
-#: clientgui/ViewProjects.cpp:584 clientgui/sg_ProjectCommandPopup.cpp:266
+#: clientgui/ViewProjects.cpp:582 clientgui/sg_ProjectCommandPopup.cpp:266
 #, c-format
 msgid "Are you sure you want to remove project '%s'?"
 msgstr "Tem a certeza que quer remover o projecto '%s'?"
 
-#: clientgui/ViewProjects.cpp:590 clientgui/sg_ProjectCommandPopup.cpp:272
+#: clientgui/ViewProjects.cpp:588 clientgui/sg_ProjectCommandPopup.cpp:272
 msgid "Remove Project"
 msgstr "Remover Projecto"
 
-#: clientgui/ViewProjects.cpp:631 clientgui/ViewWork.cpp:686
+#: clientgui/ViewProjects.cpp:629 clientgui/ViewWork.cpp:686
 msgid "Launching browser..."
 msgstr "A lançar o navegador..."
 
-#: clientgui/ViewProjects.cpp:806 clientgui/sg_ProjectCommandPopup.cpp:126
+#: clientgui/ViewProjects.cpp:804 clientgui/sg_ProjectCommandPopup.cpp:126
 msgid "Resume tasks for this project."
 msgstr "Resumir tarefas para este projecto."
 
-#: clientgui/ViewProjects.cpp:825 clientgui/sg_ProjectCommandPopup.cpp:133
+#: clientgui/ViewProjects.cpp:823 clientgui/sg_ProjectCommandPopup.cpp:133
 msgid "Allow new tasks"
 msgstr "Permitir novas tarefas"
 
-#: clientgui/ViewProjects.cpp:825 clientgui/sg_ProjectCommandPopup.cpp:134
+#: clientgui/ViewProjects.cpp:823 clientgui/sg_ProjectCommandPopup.cpp:134
 msgid "Allow fetching new tasks for this project."
 msgstr "Permitir obtenção de novas tarefas para este projecto."
 
-#: clientgui/ViewProjects.cpp:829 clientgui/sg_ProjectCommandPopup.cpp:137
+#: clientgui/ViewProjects.cpp:827 clientgui/sg_ProjectCommandPopup.cpp:137
 msgid "Don't fetch new tasks for this project."
 msgstr "Não obter novas tarefas para este projecto."
 
-#: clientgui/ViewProjects.cpp:1133
+#: clientgui/ViewProjects.cpp:1131
 msgid "Requested by user"
 msgstr "Pedido pelo utilizador"
 
-#: clientgui/ViewProjects.cpp:1134
+#: clientgui/ViewProjects.cpp:1132
 msgid "To fetch work"
 msgstr "Para obter trabalho"
 
-#: clientgui/ViewProjects.cpp:1135
+#: clientgui/ViewProjects.cpp:1133
 msgid "To report completed tasks"
 msgstr "Para reportar tarefas concluídas"
 
-#: clientgui/ViewProjects.cpp:1136
+#: clientgui/ViewProjects.cpp:1134
 msgid "To send trickle-up message"
 msgstr "Para enviar mensagem de aviso"
 
-#: clientgui/ViewProjects.cpp:1137
+#: clientgui/ViewProjects.cpp:1135
 msgid "Requested by account manager"
 msgstr "Pedido pelo gestor de conta"
 
-#: clientgui/ViewProjects.cpp:1138
+#: clientgui/ViewProjects.cpp:1136
 msgid "Project initialization"
 msgstr "Inicialização do projecto"
 
-#: clientgui/ViewProjects.cpp:1139
+#: clientgui/ViewProjects.cpp:1137
 msgid "Requested by project"
 msgstr "Pedido pelo projecto"
 
-#: clientgui/ViewProjects.cpp:1140
+#: clientgui/ViewProjects.cpp:1138
 msgid "Unknown reason"
 msgstr "Razão desconhecida"
 
-#: clientgui/ViewProjects.cpp:1154
+#: clientgui/ViewProjects.cpp:1152
 msgid "Suspended by user"
 msgstr "Suspenso pelo utilizador"
 
-#: clientgui/ViewProjects.cpp:1157
+#: clientgui/ViewProjects.cpp:1155
 msgid "Won't get new tasks"
 msgstr "Não obterá novas tarefas"
 
-#: clientgui/ViewProjects.cpp:1160
+#: clientgui/ViewProjects.cpp:1158
 msgid "Project ended - OK to remove"
 msgstr "Projecto terminado - OK para remover"
 
-#: clientgui/ViewProjects.cpp:1163
+#: clientgui/ViewProjects.cpp:1161
 msgid "Will remove when tasks done"
 msgstr "Irá remover quando as tarefas concluirem"
 
-#: clientgui/ViewProjects.cpp:1166
+#: clientgui/ViewProjects.cpp:1164
 msgid "Scheduler request pending"
 msgstr "Pedido de agendamento pendente"
 
-#: clientgui/ViewProjects.cpp:1172
+#: clientgui/ViewProjects.cpp:1170
 msgid "Scheduler request in progress"
 msgstr "Pedido de agendamento em progresso"
 
-#: clientgui/ViewProjects.cpp:1175
+#: clientgui/ViewProjects.cpp:1173
 msgid "Trickle up message pending"
 msgstr "Mensagem de aviso pendente"
 
-#: clientgui/ViewProjects.cpp:1181
-msgid "Communication deferred "
+#: clientgui/ViewProjects.cpp:1179
+msgid "Communication deferred"
 msgstr "Comunicação deferida"
 
 #: clientgui/ViewResources.cpp:62
@@ -3226,7 +3266,7 @@ msgstr "livre, não disponível para o BOINC: "
 msgid "free: "
 msgstr "livre: "
 
-#: clientgui/ViewResources.cpp:299
+#: clientgui/ViewResources.cpp:298
 msgid "used by other programs: "
 msgstr "utilizado por outros programas: "
 
@@ -3437,35 +3477,35 @@ msgstr "Tem a certeza que quer cancelar a transferência deste ficheiro '%s'?\nN
 msgid "Abort File Transfer"
 msgstr "Cancelar Transferência do Ficheiro"
 
-#: clientgui/ViewTransfers.cpp:864
+#: clientgui/ViewTransfers.cpp:845
 msgid "Upload"
 msgstr "Upload"
 
-#: clientgui/ViewTransfers.cpp:864
+#: clientgui/ViewTransfers.cpp:845
 msgid "Download"
 msgstr "Transferir"
 
-#: clientgui/ViewTransfers.cpp:868
+#: clientgui/ViewTransfers.cpp:849
 msgid "retry in "
 msgstr "tentar novamente em "
 
-#: clientgui/ViewTransfers.cpp:870
+#: clientgui/ViewTransfers.cpp:851
 msgid "failed"
 msgstr "falhou"
 
-#: clientgui/ViewTransfers.cpp:873
+#: clientgui/ViewTransfers.cpp:854
 msgid "suspended"
 msgstr "suspenso"
 
-#: clientgui/ViewTransfers.cpp:878
+#: clientgui/ViewTransfers.cpp:859
 msgid "active"
 msgstr "activo"
 
-#: clientgui/ViewTransfers.cpp:880
+#: clientgui/ViewTransfers.cpp:861
 msgid "pending"
 msgstr "pendente"
 
-#: clientgui/ViewTransfers.cpp:887
+#: clientgui/ViewTransfers.cpp:867
 msgid " (project backoff: "
 msgstr " (projecto backoff: "
 
@@ -3581,10 +3621,6 @@ msgstr "Quer mesmo cancelar?"
 msgid "Question"
 msgstr "Questão"
 
-#: clientgui/common/wxPieCtrl.cpp:64 clientgui\common/wxPieCtrl.cpp:64
-msgid "Pie Ctrl"
-msgstr "Pie Ctrl"
-
 #: clientgui/mac/Mac_GUI.cpp:35 clientgui\mac/Mac_GUI.cpp:35
 msgid "Services"
 msgstr "Serviços"
@@ -3652,7 +3688,7 @@ msgstr "Resume a Computação"
 msgid "Open a window to view notices from projects or BOINC"
 msgstr "Abre uma janela para ver as notícias dos projectos ou do BOINC"
 
-#: clientgui/sg_BoincSimpleFrame.cpp:934 clientgui/sg_DlgPreferences.cpp:360
+#: clientgui/sg_BoincSimpleFrame.cpp:934 clientgui/sg_DlgPreferences.cpp:366
 #, c-format
 msgid "Get help with %s"
 msgstr "Obter ajuda com o %s"
@@ -3666,21 +3702,21 @@ msgstr "Fechar"
 msgid "%s - Notices"
 msgstr "%s - Notícias"
 
-#: clientgui/sg_DlgPreferences.cpp:206
+#: clientgui/sg_DlgPreferences.cpp:208
 msgid ""
 "For additional settings, select Computing Preferences in the Advanced View."
 msgstr "Para definições adicionais, seleccione Preferências de Computação na Vista Avançada"
 
-#: clientgui/sg_DlgPreferences.cpp:340
+#: clientgui/sg_DlgPreferences.cpp:346
 msgid "GB of disk space"
 msgstr "Gb de espaço em disco"
 
-#: clientgui/sg_DlgPreferences.cpp:1089
+#: clientgui/sg_DlgPreferences.cpp:1105
 #, c-format
 msgid "%s - Computing Preferences"
 msgstr "%s - Preferência de Computação"
 
-#: clientgui/sg_DlgPreferences.cpp:1170
+#: clientgui/sg_DlgPreferences.cpp:1186
 msgid "Discard all local preferences and use web-based preferences?"
 msgstr "Rejeitar todas as preferências locais e utilizar as preferências web?"
 
@@ -3717,12 +3753,12 @@ msgstr "Páginas Web do Projecto"
 msgid "Project Commands"
 msgstr "Comandos do Projecto"
 
-#: clientgui/sg_ProjectPanel.cpp:276
+#: clientgui/sg_ProjectPanel.cpp:278
 #, c-format
 msgid "Pop up a menu of web sites for project %s"
 msgstr "Abre um menu de websites para o projecto %s"
 
-#: clientgui/sg_ProjectPanel.cpp:278
+#: clientgui/sg_ProjectPanel.cpp:280
 #, c-format
 msgid "Pop up a menu of commands to apply to project %s"
 msgstr "Abre um menu de comandos para aplicar ao projecto %s"
@@ -3759,100 +3795,101 @@ msgstr "Tarefas:"
 msgid "Select a task to access"
 msgstr "Seleccione uma tarefa para aceder"
 
-#: clientgui/sg_TaskPanel.cpp:497
+#. what project the task is from, e.g. "From: SETI at home"
+#: clientgui/sg_TaskPanel.cpp:498
 msgid "From:"
 msgstr "De:"
 
-#: clientgui/sg_TaskPanel.cpp:551
+#: clientgui/sg_TaskPanel.cpp:552
 msgid "This task's progress"
 msgstr "Progresso destas tarefas"
 
-#: clientgui/sg_TaskPanel.cpp:569
+#: clientgui/sg_TaskPanel.cpp:570
 msgid "Task Commands"
 msgstr "Comandos das Tarefas"
 
-#: clientgui/sg_TaskPanel.cpp:570
+#: clientgui/sg_TaskPanel.cpp:571
 msgid "Pop up a menu of commands to apply to this task"
 msgstr "Abrir um menu de comandos para aplicar a esta tarefa"
 
-#: clientgui/sg_TaskPanel.cpp:705
+#: clientgui/sg_TaskPanel.cpp:706
 #, c-format
 msgid "Application: %s"
 msgstr "Aplicação: %s"
 
-#: clientgui/sg_TaskPanel.cpp:728
+#: clientgui/sg_TaskPanel.cpp:729
 #, c-format
 msgid "%.3f%%"
 msgstr "%.3f%%"
 
-#: clientgui/sg_TaskPanel.cpp:736
+#: clientgui/sg_TaskPanel.cpp:737
 msgid "Application: Not available"
 msgstr "Aplicação: Indisponível"
 
-#: clientgui/sg_TaskPanel.cpp:836
+#: clientgui/sg_TaskPanel.cpp:837
 msgid "Not Available"
 msgstr "Indisponível"
 
-#: clientgui/sg_TaskPanel.cpp:851
+#: clientgui/sg_TaskPanel.cpp:852
 #, c-format
 msgid "Elapsed: %s"
 msgstr "Decorrido: %s"
 
-#: clientgui/sg_TaskPanel.cpp:865
+#: clientgui/sg_TaskPanel.cpp:866
 #, c-format
 msgid "Remaining (estimated): %s"
 msgstr "Restante (estimado): %s"
 
-#: clientgui/sg_TaskPanel.cpp:880
+#: clientgui/sg_TaskPanel.cpp:881
 #, c-format
 msgid "Status: %s"
 msgstr "Estado: %s"
 
-#: clientgui/sg_TaskPanel.cpp:1228
+#: clientgui/sg_TaskPanel.cpp:1206
 msgid "Retrieving current status."
 msgstr "A rever o estado actual."
 
-#: clientgui/sg_TaskPanel.cpp:1234
+#: clientgui/sg_TaskPanel.cpp:1212
 msgid "Downloading work from the server."
 msgstr "A realizar transferência de trabalho do servidor."
 
-#: clientgui/sg_TaskPanel.cpp:1239
+#: clientgui/sg_TaskPanel.cpp:1217
 msgid "Processing Suspended:  Running On Batteries."
 msgstr "Processamento Suspenso:  A executar em Bateria."
 
-#: clientgui/sg_TaskPanel.cpp:1241
+#: clientgui/sg_TaskPanel.cpp:1219
 msgid "Processing Suspended:  User Active."
 msgstr "Processamento Suspenso:  Utilizador Activo."
 
-#: clientgui/sg_TaskPanel.cpp:1243
+#: clientgui/sg_TaskPanel.cpp:1221
 msgid "Processing Suspended:  User paused processing."
 msgstr "Processamento Suspenso:  O utilizador parou o processamento."
 
-#: clientgui/sg_TaskPanel.cpp:1245
+#: clientgui/sg_TaskPanel.cpp:1223
 msgid "Processing Suspended:  Time of Day."
 msgstr "Processamento Suspenso:  Hora do Dia."
 
-#: clientgui/sg_TaskPanel.cpp:1247
+#: clientgui/sg_TaskPanel.cpp:1225
 msgid "Processing Suspended:  Benchmarks Running."
 msgstr "Processamento Suspenso:  A Executar Testes de Performance."
 
-#: clientgui/sg_TaskPanel.cpp:1249
+#: clientgui/sg_TaskPanel.cpp:1227
 msgid "Processing Suspended."
 msgstr "Processamento Suspenso."
 
-#: clientgui/sg_TaskPanel.cpp:1253
+#: clientgui/sg_TaskPanel.cpp:1231
 msgid "Waiting to contact project servers."
 msgstr "A aguardar contacto dos servidores do projecto."
 
-#: clientgui/sg_TaskPanel.cpp:1257 clientgui/sg_TaskPanel.cpp:1266
+#: clientgui/sg_TaskPanel.cpp:1235 clientgui/sg_TaskPanel.cpp:1244
 msgid "Retrieving current status"
 msgstr "A rever estado actual"
 
-#: clientgui/sg_TaskPanel.cpp:1261
+#: clientgui/sg_TaskPanel.cpp:1239
 msgid "No work available to process"
 msgstr "Sem trabalhos disponíveis para processar"
 
-#: clientgui/sg_TaskPanel.cpp:1263
+#: clientgui/sg_TaskPanel.cpp:1241
 msgid "Unable to connect to the core client"
 msgstr "Não foi possível ligar ao cliente de core"
 
diff --git a/locale/ru/BOINC-Project-Generic.po b/locale/ru/BOINC-Project-Generic.po
index 705aee8..89494df 100644
--- a/locale/ru/BOINC-Project-Generic.po
+++ b/locale/ru/BOINC-Project-Generic.po
@@ -7,14 +7,15 @@
 # 
 # Translators:
 # Dan <mutari.dirk at gmail.com>, 2015
+# Malyanov Evgeniy <flange465 at gmail.com>, 2015
 # Nikolay Sakharov <saharovna at gmail.com>, 2015
 msgid ""
 msgstr ""
 "Project-Id-Version: BOINC\n"
 "Report-Msgid-Bugs-To: BOINC translation team <boinc_loc at boinc.berkeley.edu>\n"
 "POT-Creation-Date: 2015-06-24 13:05 PDT\n"
-"PO-Revision-Date: 2015-09-30 07:28+0000\n"
-"Last-Translator: Nikolay Sakharov <saharovna at gmail.com>\n"
+"PO-Revision-Date: 2015-11-08 22:54+0000\n"
+"Last-Translator: Malyanov Evgeniy <flange465 at gmail.com>\n"
 "Language-Team: Russian (http://www.transifex.com/boinc/boinc/language/ru/)\n"
 "MIME-Version: 1.0\n"
 "Content-Type: text/plain; charset=UTF-8\n"
@@ -665,7 +666,7 @@ msgstr "IP-адрес"
 
 #: ../inc/host.inc:88
 msgid "(same the last %1 times)"
-msgstr "(такой же последние %1 раз)"
+msgstr "(такие же в последние %1 время)"
 
 #: ../inc/host.inc:90
 msgid "External IP address"
diff --git a/locale/sr at latin/BOINC-Client.mo b/locale/sr at latin/BOINC-Client.mo
new file mode 100644
index 0000000..b07969d
Binary files /dev/null and b/locale/sr at latin/BOINC-Client.mo differ
diff --git a/locale/it_IT/BOINC-Client.po b/locale/sr at latin/BOINC-Client.po
similarity index 56%
copy from locale/it_IT/BOINC-Client.po
copy to locale/sr at latin/BOINC-Client.po
index 7cfc5db..efa169e 100644
--- a/locale/it_IT/BOINC-Client.po
+++ b/locale/sr at latin/BOINC-Client.po
@@ -3,159 +3,161 @@
 # This file is distributed under the same license as the PACKAGE package.
 # 
 # Translators:
+# Sebastiano Pistore <olatusrooc at virgilio.it>, 2015
+# zoran kajis <zkajis at gmail.com>, 2015
 msgid ""
 msgstr ""
-"Project-Id-Version: boinc\n"
+"Project-Id-Version: BOINC\n"
 "Report-Msgid-Bugs-To: \n"
 "POT-Creation-Date: 2013-10-15 22:25-0700\n"
-"PO-Revision-Date: 2015-02-08 21:33+0000\n"
-"Last-Translator: Rom Walton <romw at romwnet.org>\n"
-"Language-Team: Italian (Italy) (http://www.transifex.com/projects/p/boinc/language/it_IT/)\n"
+"PO-Revision-Date: 2015-11-20 11:57+0000\n"
+"Last-Translator: Sebastiano Pistore <olatusrooc at virgilio.it>\n"
+"Language-Team: Serbian (Latin) (http://www.transifex.com/boinc/boinc/language/sr@latin/)\n"
 "MIME-Version: 1.0\n"
 "Content-Type: text/plain; charset=UTF-8\n"
 "Content-Transfer-Encoding: 8bit\n"
-"Language: it_IT\n"
-"Plural-Forms: nplurals=2; plural=(n != 1);\n"
+"Language: sr at latin\n"
+"Plural-Forms: nplurals=3; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2);\n"
 
 #: acct_mgr.cpp:450 acct_mgr.cpp:459
 msgid "Message from account manager"
-msgstr "Messaggio dal gestore dell'account"
+msgstr "Poruka od menadžera naloga"
 
 #: client_msgs.cpp:81
 msgid "Message from server"
-msgstr "Messaggio dal server"
+msgstr "Poruka sa servera"
 
 #: client_state.cpp:258
 msgid ""
 "Some tasks need more memory than allowed by your preferences.  Please check "
 "the preferences."
-msgstr "Alcuni lavori richiedono più memoria di quella resa disponibile dalle tue preferenze.  Per favore controllale."
+msgstr "Neki zadatci traže više memorije nego što ste omogućili vašim podešavanjima. Proverite podešavanja."
 
 #: client_state.cpp:520
 msgid "Couldn't write state file; check directory permissions"
-msgstr "Non posso scrivere il file di stato; controlla i permessi della cartella"
+msgstr "Nije moguće zapisati status fajla; proverite dozvole direktorijuma"
 
 #: cs_cmdline.cpp:303
 msgid "The HTTP_PROXY environment variable must specify an HTTP proxy"
-msgstr "La variabile di ambiente HTTP_PROXY deve specificare un proxy HTTP"
+msgstr "HTTP_PROXY promenljive moraju ukazivati na HTTP proxy"
 
 #: cs_scheduler.cpp:613
 #, c-format
 msgid ""
 "You used the wrong URL for this project.  When convenient, remove this "
 "project, then add %s"
-msgstr "Hai usato l'URL sbagliato per questo progetto.  Quando hai tempo, rimuovi questo progetto, poi aggiungi %s"
+msgstr "Koristite pogrešan URL za ovaj projekat. Kad bude pogodno, uklonite ovaj projekat, zatim dodajte %s"
 
 #: cs_statefile.cpp:828 ../sched/sched_types.cpp:259
 msgid "Syntax error in app_info.xml"
-msgstr "Errore di sintassi nel file app_info.xml"
+msgstr "Sintaksa greška u app_info.xml"
 
 #: cs_statefile.cpp:868
 msgid "File referenced in app_info.xml does not exist: "
-msgstr "ll file referenziato in app_info.xml non esiste: "
+msgstr "Fajl navedeni u app_info.xml ne postoji:"
 
 #: current_version.cpp:91
 msgid "A new version of BOINC is available."
-msgstr "Una nuova versione di BOINC è disponibile."
+msgstr "Nova verzija BOINC je dostupna."
 
 #: current_version.cpp:94 current_version.cpp:102
 msgid "Download"
-msgstr "Scarica"
+msgstr "Preuzimanje"
 
 #: log_flags.cpp:269 log_flags.cpp:449
 msgid "Unexpected text in cc_config.xml"
-msgstr "Testo inaspettato nel file cc_config.xml"
+msgstr "Neočekivani tekst u cc_config.kml"
 
 #: log_flags.cpp:423 log_flags.cpp:475
 msgid "Unrecognized tag in cc_config.xml"
-msgstr "Tag non riconosciuto nel file cc_config.xml"
+msgstr "Unrecognized tag u cc_config.kml"
 
 #: log_flags.cpp:440
 msgid "Missing start tag in cc_config.xml"
-msgstr "Tag di inizio mancante nel file cc_config.xml"
+msgstr "Nedostaje početna oznaka u cc_config.kml"
 
 #: log_flags.cpp:465
 msgid "Error in cc_config.xml options"
-msgstr "Errore nel file cc_config.xml"
+msgstr "Greška u opcijama cc_config.kml"
 
 #: log_flags.cpp:483
 msgid "Missing end tag in cc_config.xml"
-msgstr "Tag di fine mancante nel file cc_config.xml"
+msgstr "Nedostaje završna oznaka u cc_config.kml"
 
 #: ../sched/handle_request.cpp:307
 msgid "Invalid or missing account key.  To fix, remove and add this project."
-msgstr "Chiave account invalida o mancante.  Per risolvere, disconnetti e riconnetti questo progetto."
+msgstr "Neispravan ili nedostaje ključ račun. Da biste rešili, uklonite i dodajte ovaj projekat."
 
 #: ../sched/handle_request.cpp:849
 msgid "Invalid code signing key.  To fix, remove and add this project."
-msgstr "Codice di chiave account invalido.  Per risolvere, disconnetti e riconnetti questo progetto."
+msgstr "Neispravan ključ kod potpisivanje. Da biste rešili, uklonite i dodajte ovaj projekat."
 
 #: ../sched/handle_request.cpp:859
 msgid ""
 "The project has changed its security key.  Please remove and add this "
 "project."
-msgstr "Il progetto ha modificato la sua chiave di sicurezza.  Per favore disconnetti e riconnetti questo progetto."
+msgstr "Projekat je promenio svoj bezbednosni ključ . Molimo Vas da uklonite i dodajte ovaj projekat ."
 
 #: ../sched/handle_request.cpp:943
 msgid "This project doesn't support operating system"
-msgstr "Il progetto non supporta questo sistema operativo"
+msgstr "Ovaj projekat ne podržava operativni sistem"
 
 #: ../sched/handle_request.cpp:969
 msgid "This project doesn't support CPU type"
-msgstr "Il progetto non supporta questo tipo di CPU"
+msgstr "Ovaj projekat ne podržava tip procesora"
 
 #: ../sched/handle_request.cpp:993
 msgid ""
 "Your BOINC client software is too old.  Please install the current version."
-msgstr "Una versione di BOINC più recente è richiesta.  Per favore installa la versione corrente."
+msgstr "Vaš BOINC klijent softver je previše star. Molimo vas da instalirate aktuelnu verziju ."
 
 #: ../sched/handle_request.cpp:1259
 msgid "This project doesn't support computers of type"
-msgstr "Il progetto non supporta questo tipo di computer"
+msgstr "Ovaj projekat ne podržava računare tipa"
 
 #: ../sched/sched_send.cpp:1092
 msgid ""
 "Upgrade to the latest driver to process tasks using your computer's GPU"
-msgstr "Aggiorna i driver all'ultima versione per eseguire i lavori che utilizzano la GPU del tuo computer"
+msgstr "Upgrade to the latest vozača da obradi zadataka korišćenjem GPU računara"
 
 #: ../sched/sched_send.cpp:1099
 msgid ""
 "Upgrade to the latest driver to use all of this project's GPU applications"
-msgstr "Aggiorna i driver all'ultima versione per eseguire le applicazioni di questo progetto che utilizzano la GPU"
+msgstr "Upgrade to the latest vozača da koristi sve GPU aplikacija ovog projekta"
 
 #: ../sched/sched_send.cpp:1118
 msgid ""
 "A newer version of BOINC is needed to use your NVIDIA GPU; please upgrade to"
 " the current version"
-msgstr "Una nuova versione di BOINC è necessaria per usare la tua GPU NVIDIA; per favore aggiorna alla versione corrente"
+msgstr "Novija verzija BOINC je potrebno da koristite NVIDIA GPU ; nadogradite na trenutnu verziju"
 
 #: ../sched/sched_send.cpp:1146
 #, c-format
 msgid "An %s GPU is required to run tasks for this project"
-msgstr "Una GPU %s è richiesta per eseguire i lavori di questo progetto"
+msgstr "An % s GPU potrebna za pokretanje zadataka za ovaj projekat"
 
 #: ../sched/sched_send.cpp:1262
 msgid "No tasks are available for the applications you have selected."
-msgstr "Nessun lavoro è disponibile per le applicazioni selezionate."
+msgstr "No zadaci su dostupni za aplikacije koje ste izabrali ."
 
 #: ../sched/sched_send.cpp:1288
 msgid "Your computer type is not supported by this project"
-msgstr "Il tuo tipo di computer non è supportato da questo progetto"
+msgstr "Vaš tip računar ne podržava ovaj projekat"
 
 #: ../sched/sched_send.cpp:1294
 msgid "Newer BOINC version required; please install current version"
-msgstr "Una versione di BOINC più recente è richiesta; per favore installa la versione corrente"
+msgstr "Novije BOINC verzija potrebno ; instalirajte aktuelnu verziju"
 
 #: ../sched/sched_send.cpp:1305
 #, c-format
 msgid ""
 "Tasks for %s are available, but your preferences are set to not accept them"
-msgstr "Lavori per %s sono disponibili, ma le tue preferenze sono impostate per non accettarli"
+msgstr "Zadaci za % s su dostupni , ali podešavanjima su postavljeni da ih ne prihvataju"
 
 #: ../sched/sched_types.cpp:254
 msgid "Unknown app name in app_info.xml"
-msgstr "Nome sconosciuto di app nel file app_info.xml"
+msgstr "Nepoznato ime aplikacija u app_info.kml"
 
 #: ../sched/sched_version.cpp:214
 msgid "Your app_info.xml file doesn't have a usable version of"
-msgstr "Il tuo file app_info.xml non ha una versione utilizzabile di"
+msgstr "Vaš app_info.kml fajl nema korisne verziju"
diff --git a/locale/sr at latin/BOINC-Setup.mo b/locale/sr at latin/BOINC-Setup.mo
new file mode 100644
index 0000000..6df57d3
Binary files /dev/null and b/locale/sr at latin/BOINC-Setup.mo differ
diff --git a/locale/uk/BOINC-Setup.po b/locale/sr at latin/BOINC-Setup.po
similarity index 50%
copy from locale/uk/BOINC-Setup.po
copy to locale/sr at latin/BOINC-Setup.po
index bf719f5..ae022ea 100644
--- a/locale/uk/BOINC-Setup.po
+++ b/locale/sr at latin/BOINC-Setup.po
@@ -3,36 +3,37 @@
 # This file is distributed under the same license as the PACKAGE package.
 # 
 # Translators:
+# Sebastiano Pistore <olatusrooc at virgilio.it>, 2015
 msgid ""
 msgstr ""
 "Project-Id-Version: BOINC\n"
 "Report-Msgid-Bugs-To: \n"
 "POT-Creation-Date: 2014-01-26 00:00-0800\n"
-"PO-Revision-Date: 2015-04-20 12:34+0000\n"
-"Last-Translator: Rom Walton\n"
-"Language-Team: Ukrainian (http://www.transifex.com/projects/p/boinc/language/uk/)\n"
+"PO-Revision-Date: 2015-11-20 11:51+0000\n"
+"Last-Translator: Sebastiano Pistore <olatusrooc at virgilio.it>\n"
+"Language-Team: Serbian (Latin) (http://www.transifex.com/boinc/boinc/language/sr@latin/)\n"
 "MIME-Version: 1.0\n"
 "Content-Type: text/plain; charset=UTF-8\n"
 "Content-Transfer-Encoding: 8bit\n"
-"Language: uk\n"
+"Language: sr at latin\n"
 "Plural-Forms: nplurals=3; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2);\n"
 
 #: Installer.cpp:124
 #, c-format
 msgid "Sorry, this version of %s requires system 10.5 or higher."
-msgstr "Вибачте, дана версія %s потребує системи 10.5 або вищої."
+msgstr "Žao nam je, ova verzija %s zahteva sistem 10.5 ili noviji."
 
 #: PostInstall.cpp:130 PostInstall.cpp:1136 uninstall.cpp:1618
 msgid "Yes"
-msgstr "Так"
+msgstr "Jeste"
 
 #: PostInstall.cpp:131 PostInstall.cpp:1137 uninstall.cpp:1619
 msgid "No"
-msgstr "Ні"
+msgstr "Ne"
 
 #: PostInstall.cpp:133
 msgid "Should BOINC run even when no user is logged in?"
-msgstr "Чи повинен BOINC працювати, навіть якщо користувач не увійшов у систему?"
+msgstr "Ako BOINC pokrenuti čak i kada nema korisnik prijavljen?"
 
 #: PostInstall.cpp:1416
 #, c-format
@@ -40,26 +41,26 @@ msgid ""
 "Users who are permitted to administer this computer will automatically be allowed to run and control %s.\n"
 "\n"
 "Do you also want non-administrative users to be able to run and control %s on this Mac?"
-msgstr "Користувачі з правами адміністратора цього комп’ютера автоматично зможуть запускати і керувати %s.\n\nБажаєте щоб прості користувачі без адміністраторських прав також могли запускати і керувати %s на цьому комп’ютері Mac?"
+msgstr "Korisnici koji su dozvoljeno da upravlja ovaj računar će automatski biti dozvoljeno da vode i kontrolišu %s.\n\nDa li takođe žele ne-administrativni korisnici biti u stanju da vode i kontrolišu %s na ovom Mac?"
 
 #: PostInstall.cpp:1444
 #, c-format
 msgid "Do you want to set %s as the screensaver for all %s users on this Mac?"
-msgstr "Бажаєте встановити %s як скрінсейвер для всіх користувачів %s на цьому Mac?"
+msgstr "Da li želite da postavite %s kao skrinsejver za sve %s korisnicima na ovom Mac?"
 
 #: uninstall.cpp:82
 msgid "OK"
-msgstr "Гаразд"
+msgstr "OK"
 
 #: uninstall.cpp:136
 msgid "Permission error after relaunch"
-msgstr "Помилка доступу після перезапуску"
+msgstr "Dozvola greške nakon ponovno pokretanje"
 
 #: uninstall.cpp:141
 msgid ""
 "Removal may take several minutes.\n"
 "Please be patient."
-msgstr "Видалення може зайняти декілька хвилин.\nБудь-ласка, зачекайте."
+msgstr "Uklanjanje može potrajati nekoliko minutes.\nBudite strpljivi."
 
 #: uninstall.cpp:156
 #, c-format
@@ -67,27 +68,27 @@ msgid ""
 "Are you sure you want to completely remove %s from your computer?\n"
 "\n"
 "This will remove the executables but will not touch %s data files."
-msgstr "Ви впевнені, що хочете повністю видалити %s зі свого комп’ютера?\n\nБудуть видалені виконавчі файли, а файли даних %s залишаться."
+msgstr "Da li ste sigurni da želite da uklonite %s sa vašeg računara?\n\nOvo će ukloniti izvršne ali neće dirati %s datoteke sa podacima."
 
 #: uninstall.cpp:163
 #, c-format
 msgid "Canceled: %s has not been touched."
-msgstr "Скасовано: %s не було змінено."
+msgstr "Otkazano: %s nije dirao."
 
 #: uninstall.cpp:174
 #, c-format
 msgid "An error occurred: error code %d"
-msgstr "Сталася помилка: код помилки %d"
+msgstr "Došlo je do greške: greške kod %d"
 
 #: uninstall.cpp:230
 msgid "name  of user"
-msgstr "ім’я  користувача"
+msgstr "Ime korisnika"
 
 #: uninstall.cpp:272
 msgid ""
 "Do you also want to remove VirtualBox from your computer?\n"
 "(VirtualBox was installed along with BOINC.)"
-msgstr "Ви також хочете видалити VirtualBox з комп'ютера?\n(VirtualBox був встановлений разом з BOINC.)"
+msgstr "Da li takođe žele da uklonite VirtualBox sa računara ?\n(VirtualBox je instaliran zajedno sa BOINC .)"
 
 #: uninstall.cpp:312
 #, c-format
@@ -99,19 +100,19 @@ msgid ""
 "\n"
 "for each user, the file\n"
 "\"%s\"."
-msgstr "Видалення завершене.\n\n Ви можете видалити наступні об’єкти, що залишилися, за допомогою Пошуковика: \nкаталог \"%s\"\n\nдля кожного користувача, файл\n\"%s\"."
+msgstr "Uklanjanje completed.\n\nMožda ćete želeti da uklonite sledeće stavke preostale koristeći Finder: \ndirektorijum \"%s\" \n\nza svakog korisnika, file\n\"%s\" ."
 
 #: uninstall.cpp:840
 #, c-format
 msgid ""
 "Enter your administrator password to completely remove %s from you computer.\n"
 "\n"
-msgstr "Для повного видалення %s з Вашого комп’ютера введіть пароль адміністратора.\n\n"
+msgstr "Unesite svoju lozinku administratora u potpunosti ukloniti %s iz vas computer.\n"
 
 #: uninstall.cpp:1616
 msgid "Cancel"
-msgstr "Скасувати"
+msgstr "poništiti"
 
 #: uninstall.cpp:1617
 msgid "Continue..."
-msgstr "Продовжити..."
+msgstr "Nastaviti..."
diff --git a/locale/tr/BOINC-Project-Generic.po b/locale/tr/BOINC-Project-Generic.po
index 749e6b0..b5483d7 100644
--- a/locale/tr/BOINC-Project-Generic.po
+++ b/locale/tr/BOINC-Project-Generic.po
@@ -13,7 +13,7 @@ msgstr ""
 "Project-Id-Version: BOINC\n"
 "Report-Msgid-Bugs-To: BOINC translation team <boinc_loc at boinc.berkeley.edu>\n"
 "POT-Creation-Date: 2015-06-24 13:05 PDT\n"
-"PO-Revision-Date: 2015-09-30 07:28+0000\n"
+"PO-Revision-Date: 2015-11-15 18:11+0000\n"
 "Last-Translator: Can Demirel <aycandemirel at hotmail.com>\n"
 "Language-Team: Turkish (http://www.transifex.com/boinc/boinc/language/tr/)\n"
 "MIME-Version: 1.0\n"
diff --git a/locale/uk/BOINC-Client.mo b/locale/uk/BOINC-Client.mo
index 7a00d77..bac6376 100644
Binary files a/locale/uk/BOINC-Client.mo and b/locale/uk/BOINC-Client.mo differ
diff --git a/locale/uk/BOINC-Client.po b/locale/uk/BOINC-Client.po
index 8677c92..e410048 100644
--- a/locale/uk/BOINC-Client.po
+++ b/locale/uk/BOINC-Client.po
@@ -3,14 +3,15 @@
 # This file is distributed under the same license as the PACKAGE package.
 # 
 # Translators:
+# Vitalii Koshura <lestat.de.lionkur at gmail.com>, 2015
 msgid ""
 msgstr ""
-"Project-Id-Version: boinc\n"
+"Project-Id-Version: BOINC\n"
 "Report-Msgid-Bugs-To: \n"
 "POT-Creation-Date: 2013-10-15 22:25-0700\n"
-"PO-Revision-Date: 2015-02-09 01:28+0000\n"
-"Last-Translator: Rom Walton <romw at romwnet.org>\n"
-"Language-Team: Ukrainian (http://www.transifex.com/projects/p/boinc/language/uk/)\n"
+"PO-Revision-Date: 2015-11-18 13:54+0000\n"
+"Last-Translator: Vitalii Koshura <lestat.de.lionkur at gmail.com>\n"
+"Language-Team: Ukrainian (http://www.transifex.com/boinc/boinc/language/uk/)\n"
 "MIME-Version: 1.0\n"
 "Content-Type: text/plain; charset=UTF-8\n"
 "Content-Transfer-Encoding: 8bit\n"
@@ -19,7 +20,7 @@ msgstr ""
 
 #: acct_mgr.cpp:450 acct_mgr.cpp:459
 msgid "Message from account manager"
-msgstr "Повідомлення менеджера проектів"
+msgstr "Повідомлення від менеджера проектів"
 
 #: client_msgs.cpp:81
 msgid "Message from server"
@@ -29,7 +30,7 @@ msgstr "Повідомлення від сервера"
 msgid ""
 "Some tasks need more memory than allowed by your preferences.  Please check "
 "the preferences."
-msgstr "Деякі завдання вимагають більше пам'яті, аніж дозволено Вашими налаштуваннями.  Будь-ласка, перевірте налаштування."
+msgstr "Деякі завдання вимагають більше пам'яті, аніж дозволено Вашими налаштуваннями.  Будь ласка, перевірте налаштування."
 
 #: client_state.cpp:520
 msgid "Couldn't write state file; check directory permissions"
@@ -52,7 +53,7 @@ msgstr "Синтаксична помилка в app_info.xml"
 
 #: cs_statefile.cpp:868
 msgid "File referenced in app_info.xml does not exist: "
-msgstr "Файлу, на який посилається app_info.xml, не існує: "
+msgstr "Файл, на який посилається app_info.xml, не існує: "
 
 #: current_version.cpp:91
 msgid "A new version of BOINC is available."
@@ -84,7 +85,7 @@ msgstr "Відсутній завершальний тег в cc_config.xml"
 
 #: ../sched/handle_request.cpp:307
 msgid "Invalid or missing account key.  To fix, remove and add this project."
-msgstr "Невірний або відсутній ключ облікового запису.  Щоб виправити його, видаліть і додайте цей проект."
+msgstr "Невірний або відсутній ключ облікового запису.  Щоб виправити його, видаліть і знову додайте цей проект."
 
 #: ../sched/handle_request.cpp:849
 msgid "Invalid code signing key.  To fix, remove and add this project."
@@ -107,7 +108,7 @@ msgstr "Цей проект не підтримує тип CPU"
 #: ../sched/handle_request.cpp:993
 msgid ""
 "Your BOINC client software is too old.  Please install the current version."
-msgstr "У Вас занадто стара версія BOINC-клієнта.  Будь-ласка, встановіть поточну версію."
+msgstr "У Вас занадто стара версія BOINC-клієнта.  Будь ласка, встановіть поточну версію."
 
 #: ../sched/handle_request.cpp:1259
 msgid "This project doesn't support computers of type"
@@ -127,7 +128,7 @@ msgstr "Для використання усіх додатків цього п
 msgid ""
 "A newer version of BOINC is needed to use your NVIDIA GPU; please upgrade to"
 " the current version"
-msgstr "Потрібна новіша версія BOINC для використання вашого графічного процесора NVIDIA; будь-ласка, оновіть програму до поточної версії"
+msgstr "Потрібна новіша версія BOINC для використання вашого графічного процесора NVIDIA; будь ласка, оновіть програму до поточної версії"
 
 #: ../sched/sched_send.cpp:1146
 #, c-format
diff --git a/locale/uk/BOINC-Setup.mo b/locale/uk/BOINC-Setup.mo
index 0113ff6..d057d83 100644
Binary files a/locale/uk/BOINC-Setup.mo and b/locale/uk/BOINC-Setup.mo differ
diff --git a/locale/uk/BOINC-Setup.po b/locale/uk/BOINC-Setup.po
index bf719f5..9ce99d1 100644
--- a/locale/uk/BOINC-Setup.po
+++ b/locale/uk/BOINC-Setup.po
@@ -3,14 +3,15 @@
 # This file is distributed under the same license as the PACKAGE package.
 # 
 # Translators:
+# Vitalii Koshura <lestat.de.lionkur at gmail.com>, 2015
 msgid ""
 msgstr ""
 "Project-Id-Version: BOINC\n"
 "Report-Msgid-Bugs-To: \n"
 "POT-Creation-Date: 2014-01-26 00:00-0800\n"
-"PO-Revision-Date: 2015-04-20 12:34+0000\n"
-"Last-Translator: Rom Walton\n"
-"Language-Team: Ukrainian (http://www.transifex.com/projects/p/boinc/language/uk/)\n"
+"PO-Revision-Date: 2015-11-18 13:55+0000\n"
+"Last-Translator: Vitalii Koshura <lestat.de.lionkur at gmail.com>\n"
+"Language-Team: Ukrainian (http://www.transifex.com/boinc/boinc/language/uk/)\n"
 "MIME-Version: 1.0\n"
 "Content-Type: text/plain; charset=UTF-8\n"
 "Content-Transfer-Encoding: 8bit\n"
@@ -40,7 +41,7 @@ msgid ""
 "Users who are permitted to administer this computer will automatically be allowed to run and control %s.\n"
 "\n"
 "Do you also want non-administrative users to be able to run and control %s on this Mac?"
-msgstr "Користувачі з правами адміністратора цього комп’ютера автоматично зможуть запускати і керувати %s.\n\nБажаєте щоб прості користувачі без адміністраторських прав також могли запускати і керувати %s на цьому комп’ютері Mac?"
+msgstr "Користувачі з правами адміністратора цього комп’ютера автоматично зможуть запускати і керувати %s.\n\nБажаєте, щоб прості користувачі без адміністраторських прав також могли запускати і керувати %s на цьому комп’ютері Mac?"
 
 #: PostInstall.cpp:1444
 #, c-format
@@ -59,7 +60,7 @@ msgstr "Помилка доступу після перезапуску"
 msgid ""
 "Removal may take several minutes.\n"
 "Please be patient."
-msgstr "Видалення може зайняти декілька хвилин.\nБудь-ласка, зачекайте."
+msgstr "Видалення може зайняти декілька хвилин.\nБудь ласка, зачекайте."
 
 #: uninstall.cpp:156
 #, c-format
@@ -67,7 +68,7 @@ msgid ""
 "Are you sure you want to completely remove %s from your computer?\n"
 "\n"
 "This will remove the executables but will not touch %s data files."
-msgstr "Ви впевнені, що хочете повністю видалити %s зі свого комп’ютера?\n\nБудуть видалені виконавчі файли, а файли даних %s залишаться."
+msgstr "Ви впевнені, що бажаєте повністю видалити %s зі свого комп’ютера?\n\nБудуть видалені виконавчі файли, але файли даних %s залишаться."
 
 #: uninstall.cpp:163
 #, c-format
@@ -87,7 +88,7 @@ msgstr "ім’я  користувача"
 msgid ""
 "Do you also want to remove VirtualBox from your computer?\n"
 "(VirtualBox was installed along with BOINC.)"
-msgstr "Ви також хочете видалити VirtualBox з комп'ютера?\n(VirtualBox був встановлений разом з BOINC.)"
+msgstr "Чи бажаєте Ви також видалити VirtualBox з комп'ютера?\n(VirtualBox був встановлений разом із BOINC.)"
 
 #: uninstall.cpp:312
 #, c-format
diff --git a/rboinc/client/boinc_lib.pl b/rboinc/client/boinc_lib.pl
deleted file mode 100644
index 9af6bb8..0000000
--- a/rboinc/client/boinc_lib.pl
+++ /dev/null
@@ -1,253 +0,0 @@
-# Common client routines.
-
-=head1 COPYRIGHT
-
-This file is part of RemoteBOINC.
-
-Copyright (C) 2010 Toni Giorgino, Universitat Pompeu Fabra
-
-RemoteBOINC is free software; you can redistribute it and/or modify it
-under the terms of the GNU Lesser General Public License as published
-by the Free Software Foundation, either version 3 of the License, or
-(at your option) any later version.
-
-RemoteBOINC is distributed in the hope that it will be useful, but
-WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Lesser General Public License for more details.
-
-You should have received a copy of the GNU Lesser General Public
-License along with BOINC.  If not, see <http://www.gnu.org/licenses/>.
-
-=cut
-
-
-# $Id$
-
-use XML::Simple;
-use LWP::UserAgent;
-
-use vars qw($verbose);
-use strict;
-
-
-# Request the remote DAV address. Dies on failure.
-
-sub getDavUrl {
-    my $cgi_url=shift;
-
-    my $ua = new LWP::UserAgent; 
-    my $response = $ua->post( $cgi_url,
-			      { action => 'get_dav_url'
-			      });
-
-    if($response->is_success) {
-	my $content = $response->content; 
-	logInfo("Response received for DAV:\n$content\n",1);
-	my $ch=XMLin($content);
-	my $du=$ch->{DavUrl};
-	if(!$du) {
-	    die "Error getting DAV address";
-	}
-	return $du;
-    } else {
-	my $reason=$response->status_line;
-	die "Error in getting DAV address from remote: $reason. Server may be down.\n";
-    }
-
-}
-
-
-
-
-# Request the wu template for a specific app (used to extract cli
-# arguments). Dies on failure.
-
-sub getWuTemplate {
-    my $cgi_url=shift;
-    my $app=shift;
-
-    my $ua = new LWP::UserAgent; 
-    my $response = $ua->post( $cgi_url,
-			      { action => 'get_wu_template',
-				application => $app
-			      });
-
-    if($response->is_success) {
-	my $content = $response->content; 
-	logInfo("Response received for template:\n$content\n",1);
-	# fixup the template, which lacks the root element
-	my $ch=XMLin($content,
-		     ForceArray => ["file_info"] );
-	if($ch->{Failure}) {
-	    my $reason=$ch->{Failure}->{Reason};
-	    die "Error in getting WU template remote: $reason.\n".
-		"You may have selected a non-configured application";
-	}
-	return $ch;
-    } else {
-	my $reason=$response->status_line;
-	die "Error in getting template from remote: $reason. Server may be down.\n";
-    }
-
-}
-
-
-# Extract parameter list from the template (in no particular order)
-
-sub parseWuTemplate {
-    my $t=shift;
-    my $p={};
-
-    if(!($t->{WuTemplate}->{rboinc}->{application})) {
-	die "Not a remote-enabled application.";
-    }
-    
-    # reference to array of file_info. Each element is a hash of number and rboinc
-    my @fi=@{$t->{WuTemplate}->{workunit}->{file_ref}};
-    foreach my $fn (@fi) {
-	my $pname=$fn->{rboinc}->{parameter_name};
-	my $pdesc=$fn->{rboinc}->{parameter_description} || "(undocumented)";
-	my $poptional=$fn->{rboinc}->{optional};
-	if($pname) {
-	    $p->{$pname}={
-		description=>$pdesc,
-		optional=>$poptional }
-	}
-    }
-    return $p;
-}
-
-
-
-# Parse result name and split into components 
-sub parseResultName {
-    my $n=shift;
-    my ($name,$user,$group,$step,$maxsteps,$rnd,$ext) = ($n=~/^(.+)-(.+)_(.+)-(.+)-(.+)-(.+)_(.+)$/);
-    my $r={
-	name => $name,
-	user => $user,
-	group => $group,
-	step => $step,
-	maxsteps => $maxsteps,
-	rnd => $rnd,
-	ext => $ext
-    };
-    return $r;
-}
-
-
-
-
-
-
-# Check if the given files (as list) are all readable.
-
-sub checkReadableFiles {
-    my $l=shift;
-    foreach my $f (@$l) {
-	if(! -r $f) {
-	    print STDERR "File $f is not readable. Exiting.\n";
-	    return 0;
-	}
-    }
-    return 1;
-}
-
-
-
-
-# Unused
-
-sub waitKey {
-    my $tmp=<>;
-}
-
-
-
-# Print on STDOUT if the $verbose global variable is defined.
-# 1st arg: message; 2nd arg: whether to print separator lines.
-
-sub logInfo {
-    my $msg=shift;
-    my $lines=shift;
-    my $in="";
-    my $out="";
-
-    if(defined $lines) {
-	 $in="vvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvv\n";
-	$out="^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^";
-    }
-
-    if($verbose) {
-	print "$in$msg$out\n";
-    }
-}
-
-
-
-# http://www.devdaily.com/perl/edu/articles/pl010005/pl010005.shtml
-
-#----------------------------(  promptUser  )-----------------------------#
-#                                                                         #
-#  FUNCTION:	promptUser                                                #
-#                                                                         #
-#  PURPOSE:	Prompt the user for some type of input, and return the    #
-#		input back to the calling program.                        #
-#                                                                         #
-#  ARGS:	$promptString - what you want to prompt the user with     #
-#		$defaultValue - (optional) a default value for the prompt #
-#                                                                         #
-#-------------------------------------------------------------------------#
-
-sub promptUser {
-
-   #-------------------------------------------------------------------#
-   #  two possible input arguments - $promptString, and $defaultValue  #
-   #  make the input arguments local variables.                        #
-   #-------------------------------------------------------------------#
-
-   my ($promptString,$defaultValue) = @_;
-
-   #-------------------------------------------------------------------#
-   #  if there is a default value, use the first print statement; if   #
-   #  no default is provided, print the second string.                 #
-   #-------------------------------------------------------------------#
-
-   if ($defaultValue) {
-      print $promptString, "[", $defaultValue, "]: ";
-   } else {
-      print $promptString, ": ";
-   }
-
-   $| = 1;               # force a flush after our print
-   $_ = <STDIN>;         # get the input from STDIN (presumably the keyboard)
-
-
-   #------------------------------------------------------------------#
-   # remove the newline character from the end of the input the user  #
-   # gave us.                                                         #
-   #------------------------------------------------------------------#
-
-   chomp;
-
-   #-----------------------------------------------------------------#
-   #  if we had a $default value, and the user gave us input, then   #
-   #  return the input; if we had a default, and they gave us no     #
-   #  no input, return the $defaultValue.                            #
-   #                                                                 # 
-   #  if we did not have a default value, then just return whatever  #
-   #  the user gave us.  if they just hit the <enter> key,           #
-   #  the calling routine will have to deal with that.               #
-   #-----------------------------------------------------------------#
-
-   if ("$defaultValue") {
-      return $_ ? $_ : $defaultValue;    # return $_ if it has a value
-   } else {
-      return $_;
-   }
-}
-
-
-
-1;
diff --git a/rboinc/client/boinc_retrieve.pl b/rboinc/client/boinc_retrieve.pl
deleted file mode 100755
index a0f53b8..0000000
--- a/rboinc/client/boinc_retrieve.pl
+++ /dev/null
@@ -1,589 +0,0 @@
-#!/usr/bin/perl
-
-=head1 COPYRIGHT
-
-This file is part of RemoteBOINC.
-
-Copyright (C) 2010 Toni Giorgino, Universitat Pompeu Fabra
-
-RemoteBOINC is free software; you can redistribute it and/or modify it
-under the terms of the GNU Lesser General Public License as published
-by the Free Software Foundation, either version 3 of the License, or
-(at your option) any later version.
-
-RemoteBOINC is distributed in the hope that it will be useful, but
-WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Lesser General Public License for more details.
-
-You should have received a copy of the GNU Lesser General Public
-License along with BOINC.  If not, see <http://www.gnu.org/licenses/>.
-
-=cut
-
-
-# $Id$
-
-use strict;
-
-
-use FindBin qw($Bin);		# where was script installed?
-use lib $FindBin::Bin;		# use that dir for libs, too
-use lib "$Bin/lib/$]";
-
-use Getopt::Long qw(:config ignore_case auto_help);
-use XML::Simple;
-use HTTP::Request::Common qw(POST);
-use HTTP::DAV;
-use LWP::UserAgent;
-use File::Basename;
-use File::Spec;
-use Pod::Usage;
-use Error qw(:try);
-
-use constant XMLROOT => "BoincRemote";
-
-require qw(boinc_lib.pl);
-
-
-
-# Constant, relative to url
-my $cgi_retrieve="boinc_retrieve_server.pl";
-
-
-
-# ----------------
-# Parsing command line
-
-my $group='';
-
-my $name='';
-my $into='',
-my $intotree='',
-our $verbose='';
-my $quiet='';
-my $keep='';
-my $purge='';
-my $stop='';
-my $status='';
-my $gridstatus='';
-my $help='';
-
-my $url=$ENV{RBOINC_URL};
-my $user=$ENV{USER};
-my $email='';
-my $authenticator='';
-
-
-
-GetOptions(
-    'group=s' => \$group,
-
-    'name=s' => \$name,
-    'into=s' => \$into,
-    'intotree=s' => \$intotree,
-    'verbose' => \$verbose,
-    'quiet' => \$quiet,
-    'keep'  => \$keep,
-    'purge' => \$purge,
-    'stop' => \$stop,
-    'status' => \$status,
-    'gridstatus' => \$gridstatus,
-    'help' => \$help,
-
-    'url=s' => \$url,
-    'user=s' => \$user,
-    'email=s' => \$email,
-    'authenticator=s' => \$authenticator,
-    ) or die "Error parsing command line";
-
-
-pod2usage(1) if $help;
-
-
-
-# ----------------
-# Check arguments
-
-checkMandatoryArguments(["group","url"]) or exit 1;
-my $cgi_url = "$url/$cgi_retrieve";
-
-if($intotree) {
-   $into=$intotree;
-}
-
-
-
-# ----------------
-# Authentication TODO
-
-
-
-
-
-# ----------------
-# Remote action invocation
-
-if($purge) {
-    handlePurge();
-} elsif($stop) {
-    handleStop();
-} elsif($status) {
-    handleStatus();
-} elsif($gridstatus) {
-    handleGridStatus();
-} else {
-    handleRetrieve();
-}
-
-exit(0);
-
-
-
-
-
-
-
-
-
-
-########################################
-# Handle purge action
-
-
-sub handlePurge {
-
-    if($into)  {
-	print STDERR "Action --purge deletes only. It makes no sense in combination with --into.\n";
-	exit 1;
-    }
-
-    confirmOrDie("The operation will IRREVERSIBLY delete results from the server.\n".
-		 "Note: You won't be able to submit new WUs with equal names until old ones\nwill be pending in the server (check with -gridstatus).\nConfirm? ");
-    my $xmlcontent=invokeRMI({action=>'purge',group=>$group,name=>$name});
-    my $message=$xmlcontent->{Success}->{Message};
-    print "Success. Message from server: $message\n";
-}
-
-
-
-
-########################################
-# Handle stop action
-
-
-sub handleStop {
-
-    if($into || $name) {
-	print STDERR "Action --stop  makes no sense in combination with --into or --name.\n";
-    }
-
-    confirmOrDie("The operation will IRREVERSIBLY stop the WU. Results can still be retrieved. Confirm? ");
-    my $xmlcontent=invokeRMI({action=>'stop',group=>$group});
-    my $message=$xmlcontent->{Success}->{Message};
-    print "Success. Message from server: $message\n";
-}
-
-
-
-
-########################################
-# Handle status action
-
-
-sub handleStatus {
-
-    if($into || $name) {
-	print STDERR "Action --status  makes no sense in combination with --into or --name.\n";
-    }
-
-    my $xmlcontent=invokeRMI({action=>'status',group=>$group});
-    my $message=$xmlcontent->{Success}->{Message};
-    print "Success. Message from server: $message\n";
-
-    my $steps=$xmlcontent->{Success}->{StepList};
-    my %st=%$steps;
-    foreach my $n (keys %st) {
-	my $nn=$n;		# strip "bin_"
-	$nn=~s/^Bin_//;
-	print "$nn\t".$st{$n}."\n";
-    }
-
-}
-
-
-
-########################################
-# Handle status action
-
-
-sub handleGridStatus {
-
-    if($into || $name) {
-	print STDERR "Action --gridstatus  makes no sense in combination with --into or --name.\n";
-    }
-
-    my $xmlcontent=invokeRMI({action=>'gridstatus'});
-    my $message=$xmlcontent->{Success}->{Message};
-    print "Success. Message from server: $message\n";
-
-    my $list=$xmlcontent->{Success}->{content};
-    print "$list\n";
-
-}
-
-
-
-
-
-
-
-########################################
-# Handle retrieve action
-
-# TODO -intotree, rename
-
-
-sub handleRetrieve {
-
-# ----------------
-# Change dir and fail early
-    if($into) {
-	chdir $into or do {
-	    print STDERR "Cannot chdir to -into directory `$into': $!\n";
-	    exit 1;
-	}
-    }
-
-# ----------------
-# Invoke RMI
-    my $xmlcontent=invokeRMI({action=>'retrieve',group=>$group,name=>$name});
-
-# ----------------
-# Check outcome
-    my $rfilelist=$xmlcontent->{FileList}->{File};
-    if(!$rfilelist) {
-	die "No files ready for retrieval.\n";
-    } 
-
-    my $dav_dir=$xmlcontent->{Success}->{Directory};
-    if(!$dav_dir) {
-	die "Error requesting download location";
-    }
-
-    my $aliasTable=$xmlcontent->{AliasTable};
-    my $finalOutputs=$xmlcontent->{Success}->{FinalOutputs};
-    my $nMeta=$xmlcontent->{Success}->{MetadataFileCount};
-
-
-# ----------------
-# Download
-    logInfo("Requesting the  DAV address");
-    my $dav_url=getDavUrl($cgi_url);
-
-    logInfo("Connecting to DAV server");
-    my $dav = new HTTP::DAV;
-    $dav->open( -url=> $dav_url )
-	or die("Couldn't open $dav_url: " .$dav->message . "\n");
-    $dav->cwd($dav_dir)              
-	or die("Couldn't set remote directory $dav_dir: " .$dav->message . "\n");
-
-    my $ndone=0;
-    my $nskip=0;
-    my @skiplist=();
-    my $nexpected=scalar @$rfilelist;
-    foreach my $fn (@$rfilelist) {
-	my $targetfn=$fn;
-	if($intotree) {
-	    my $tmp=parseResultName($fn);
-	    my $name=$tmp->{name};
-	    mkdir $name;	# may well fail if dir exists
-	    $targetfn=File::Spec->catfile($name,$fn); # OS indepen
-	}
-	if( fileOrAliasExists($targetfn,$aliasTable) ) {
-	    if(!$quiet && $nskip==0) {
-		print "Warning: some files are present locally and will not be overwritten.\n";
-	    }
-	    $nskip++;
-	    push @skiplist,$fn;
-	} else {
-	    $targetfn = $targetfn . aliasExtension($fn,$aliasTable);
-	    $dav->get(-url => $fn,
-		      -to => $targetfn) and
-			  $ndone++;
-	}
-	if(!$quiet) {
-	    local $|=1;
-	    print sprintf("Retrieved $ndone, already present $nskip, out of $nexpected (% 3d%%)\r",100.*($ndone+$nskip)/$nexpected);
-	}
-    }
-
-    if($verbose) {
-	print "The following files were not overwritten: @skiplist\n";
-    }
-
-    print "Successfully retrieved $ndone, already present $nskip, out of $nexpected ($nMeta metadata).\n";
-
-
-
-# ----------------
-# Request deletion of remote files
-
-    if(! $keep) {
-	logInfo("Going to remove retrieved files");
-	try {
-	    $xmlcontent=invokeRMI({action=>'remove',dir=>$dav_dir});
-
-	    my $nremoved=$xmlcontent->{Success}->{NumberRemoved};
-	    my $nkept=   $xmlcontent->{Success}->{NumberKept} ;	 
-	    
-	    if(!$quiet) {
-		print "Removed $nremoved server files, $nkept were too recent to remove.\n";
-	    }
-	} catch Error with {
-	    my $ex=shift;
-	    my $mess=$ex->text();
-    	    print STDERR "Error requesting removal of remote files: $mess; continuing.\n";
-	}
-    }
-
-
-
-# ----------------
-# Finalize
-
-    logInfo("Removing retrieval directory");
-    foreach my $fn (@$rfilelist) {
-	$dav->delete(-url => $fn);
-    }
-    $dav->cwd("..");
-    $dav->delete($dav_dir);
-
-}
-
-
-
-# Return the first extension defined in the alias table
-
-sub aliasExtension {
-    my $fn=shift;
-    my $at=shift;
-
-    # Extract trailing number
-    $fn=~/_([0-9]+)$/;
-    my $fileExt=$1;
-
-    my $newExt="";
-
-    # iterate over the alias list
-    my $rAliasList=$at->{File};
-    foreach my $curAlias ( @$rAliasList ) {
-	if($curAlias->{Extension} eq "_$fileExt") {
-	    # if alias for current extension, return first Alias
-	    $newExt=$curAlias->{Alias}->[0];
-	    logInfo("Found suffix $fileExt -> $newExt");
-	    last;
-	}
-    }
-    return $newExt;
-
-}
-
-
-
-
-# Check if file exists in current directory (1st arg), checking both
-# the literal file name and its aliases, appending extensions
-# described in the alias list (2nd arg)
-
-sub fileOrAliasExists {
-    my $fn=shift;
-    my $at=shift;
-
-    logInfo("Testing existence of $fn...");
-    if(-e $fn) {
-	logInfo("...is there");
-	return 1;
-    }
-
-    # Extract trailing number
-    $fn=~/_([0-9]+)$/;
-    my $fileExt=$1;
-
-    # iterate over the alias list
-    my $rAliasList=$at->{File};
-    foreach my $curAlias ( @$rAliasList ) {
-	if($curAlias->{Extension} eq "_$fileExt") {
-	    # if alias for current extension, check appending all extensions
-	    my $rExtList=$curAlias->{Alias};
-	    foreach my $extToTest (@$rExtList) {
-		logInfo("Testing existence of $fn + $extToTest...");
-		if(-e $fn.$extToTest) {
-		    logInfo("...is there");
-		    return 1;
-		}
-	    }
-	}
-    }
-
-    return 0;
-
-}
-
-
-
-
-
-
-
-# ########################################
-# Misc. utility functions, shared by all handlers
-
-
-
-# ----------------
-# Ask for positive confirmation, or throw exception.
-
-sub confirmOrDie {
-    my $answer=promptUser(shift,"N");
-    die "Operation aborted." if($answer !~ /^[yY]/ );
-}
-
-
-
-
-# ----------------
-# Performs the remote method invokation, die-ing on failure
-# Returns a parsed XML structure or throws an exception.
-# Will use the $user global variable
-
-sub invokeRMI {
-    my $params=shift;
-
-    logInfo("Invoking CGI");
-
-    $params->{loginname}=$user;
-
-    my $xmlcontent;
-    my $ua = new LWP::UserAgent;
-    my $response = $ua->post( $cgi_url,
-			      $params  );
-    if($response->is_success) {
-	my $content = $response->content; 
-	if($verbose) {
-	    print "Response received:\n";
-	    print $content;
-	}
-	$xmlcontent=XMLin($content,ForceArray=>["File","Alias"]);
-    } else {
-	my $reason=$response->status_line;
-	die "Error in POST from remote: $reason. Server may be down.\n";
-    }
-
-    if($xmlcontent->{Failure}) {
-	die "Server error message: $xmlcontent->{Failure}->{Reason}";
-    } elsif(!$xmlcontent->{Success}) {
-	die "Undefined state returned. This is a bug.";
-    } 
-	
-    return($xmlcontent);
-}
-
-
-
-
-
-
-
-
-
-# Check if the calling environment has all the given variables
-# defined.  If not, print one of them. Else, return false. These are
-# passed as string in order to be able to be able to print their name.
-# Sadly, must be duplicated because otherwise does not have access to
-# scope.
-
-sub checkMandatoryArguments {
-    my $l=shift;
-    foreach my $f (@$l) {
-	if(! eval('$'."$f")) {
-	    print STDERR "Missing mandatory argument: $f. See -help.\n";
-	    return 0;
-	}
-    }
-    return 1;
-}
-
-
-
-
-
-
-__END__
-
-=pod
-=head1 NAME
-
-boinc_retrieve - Retrieving and administering remote boinc jobs
-
-
-=head1 SYNOPSIS
-
-boinc_retrieve [options]
-
-
-=head1 OPTIONS
-
-=head2 Mandatory parameters
-
-=begin text
-
-    -group GROUP         The simulation group to be retrieved
-
-=end text
-
-=head2 Modifiers
-
-=begin text
-
-    -name NAME           Retrieve only a specific job and its metadata
-    -into DIR            Put files into specified directory (default ".")
-    -intotree DIR        Put files into specified directory, with NAMEs in subdirs
-    -verbose             Be verbose
-    -quiet               Hide download progress indicator
-    -keep                Do not remove retrieved files from server 
-    -purge               Completely remove GROUP from server (if finished)
-    -stop                Prevent more work to be spawned for a given group
-    -status              Show step numbers for given group
-    -gridstatus          Show resources consumed and statuses for all groups
-    -help                This message
-
-=end text
-
-=head2 Authentication
-
-=begin text
-
-    -url URL             RBoinc URL contact point (*)
-    -user NAME           Override username [$user]
-    -email ADDRESS       (Not implemented)
-    -authenticator ID    (Not implemented)
-
-    (*) You can also use the RBOINC_URL environment variable
-	For example: http://www.ps3grid.net:8383/rboinc_cgi
-
-=end text
-
-
-
-=head1 SEE ALSO
-
-L<boinc_submit>
-
-
-=head1 AUTHOR
-
-Toni Giorgino
-
-=cut
-
diff --git a/rboinc/client/boinc_submit.pl b/rboinc/client/boinc_submit.pl
deleted file mode 100755
index 9fc903c..0000000
--- a/rboinc/client/boinc_submit.pl
+++ /dev/null
@@ -1,554 +0,0 @@
-#!/usr/bin/perl
-
-=head1 COPYRIGHT
-
-This file is part of RemoteBOINC.
-
-Copyright (C) 2010 Toni Giorgino, Universitat Pompeu Fabra
-
-RemoteBOINC is free software; you can redistribute it and/or modify it
-under the terms of the GNU Lesser General Public License as published
-by the Free Software Foundation, either version 3 of the License, or
-(at your option) any later version.
-
-RemoteBOINC is distributed in the hope that it will be useful, but
-WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Lesser General Public License for more details.
-
-You should have received a copy of the GNU Lesser General Public
-License along with BOINC.  If not, see <http://www.gnu.org/licenses/>.
-
-=cut
-
-
-# $Id$
-
-use strict;
-
-
-use FindBin qw($Bin);		# where was script installed?
-use lib $FindBin::Bin;		# use that dir for libs, too
-use lib "$Bin/lib/$]";
-use Error qw(:try);
-
-use Getopt::Long qw(:config ignore_case pass_through);
-use XML::Simple;
-use HTTP::Request::Common qw(POST);
-use HTTP::DAV;
-use LWP::UserAgent;
-use File::Basename;
-use File::Temp qw(tempfile);
-
-require qw(boinc_lib.pl);
-
-
-
-# ----------------------------------------
-
-# Constants 
-
-use constant XMLROOT => "BoincRemote";
-
-# The temporary description file
-my $description_file_xml="description_file.xml";
-my ($description_file_fh,$description_file)=
-    tempfile("/tmp/description_temp.xml.XXXXX",
-	     UNLINK=>1);
-
-
-# Constant, relative to url
-my $cgi_submit="boinc_submit_server.pl";
-my $cgi_retrieve="boinc_retrieve_server.pl";
-
-
-
-
-# Todo: replace config with longopts +
-# http://www.perl.com/pub/a/2007/07/12/options-and-configuration.html?page=2
-
-my $unparsed_cli="@ARGV";
-
-
-# Keep these in the same order as help
-
-my $url=$ENV{RBOINC_URL};
-my $app_name='meta';
-my $user=$ENV{USER};
-my $email='';
-my $authenticator='';
-
-my $group='';
-my $name='';
-
-my $metadata_file='';
-my $assign_user_all='';
-my $num_steps=1;
-my $priority=1;
-
-my $fpops_est='';
-my $fpops_bound='';
-my $memory_bound='';
-my $target_nresults=1;
-my $balance=0;
-my $min_quorum=1;
-my $dry_run='';
-my $batch='';
-
-my $help='';
-my $help_parameters='';
-our $verbose='';
-
-
-
-# Do the first pass at option parsing. 
-# Keep these in the same order as help
-
-# This list should be as short as possible because it is validated BEFORE the server-passed list.
-# Any argument matched here will not be matched against the template-specific one.
-
-GetOptions(
-    'url=s' => \$url,
-    'app_name=s' => \$app_name,
-    'user=s' => \$user,
-    'email=s' => \$email,
-    'authenticator=s' => \$authenticator,
-
-    'help' => \$help,
-    'help_parameters' => \$help_parameters,
-    'verbose' => \$verbose,
-    ) or die "Error parsing command line";
-
-
-if($help) {
-    printHelp();
-    exit(0);
-}
-
-
-
-
-############
-# Option checking
-
-checkMandatoryArguments(['url','app_name']) or exit 1;
-
-
-# Ask the server for the template  and parse it
-logInfo("Getting WU template");
-my $wu_template=getWuTemplate("$url/$cgi_retrieve",$app_name);
-
-logInfo("Parsing WU template");
-my $parameters=parseWuTemplate($wu_template);
-
-if($help_parameters) {
-    printParametersHelp($wu_template);
-    exit(0);
-}
-
-
-
-
-
-
-# Second pass at option parsing. This is tricky. We will use a version
-# of getopts which requires two arguments:
-#  a. a hash ref of ( optnameN => ref to destination )
-#  b. a list of (optname1=s optname2=i ...) - note the =x part
-# To roll-back, go to SVN version 318
-
-
-#  1. create a hash ($parfiles) which will hold the variable options
-#     and their content. It will be written through the references
-#     created later
-my $parfiles={};		
-
-
-# 2. create a hash specifying the VARIABLE options and their
-#    destination, in parfiles
-my %getopt2_files_options=();
-
-foreach my $opt (keys %$parameters) {
-    $parfiles->{$opt}='';
-    my $rr=\($parfiles->{$opt});
-    $getopt2_files_options{$opt."=s"}=$rr;
-}
-
-
-# Now, we shall divide the options parsed at this stage in a
-# "constant" group and a "variable" one, taken from the template
-
-#  3. create a hash specifying the CONSTANT options and their
-#     destinations (in plain variables)
-my %getopt2_constant_options=(
-	   'group=s' => \$group,
-	   'name=s' => \$name,
-
-	   'metadata_file=s' => \$metadata_file,
-	   'assign_user_all=i' => \$assign_user_all,
-	   'num_steps=i' => \$num_steps,
-	   'priority=i' => \$priority,
-	   
-	   'fpops_est=f' => \$fpops_est,
-	   'fpops_bound=f' => \$fpops_bound,
-	   'memory_bound=f' => \$memory_bound,
-	   'target_nresults=i' => \$target_nresults,
-	   'balance=i' => \$balance,
-	   'min_quorum=i' => \$min_quorum,
-	   'dry_run' => \$dry_run,
-	   'batch=i' => \$batch,
-);
-
-
-#  4. merge 2+3 into "all options"
-my %getopt2_all_options=(%getopt2_files_options,%getopt2_constant_options);
-
-
-#  5. use "copy_fix_options" on 2+3 to generate variables required at
-#     points a+b above
-my $temp_all_opts=copy_fix_options(\%getopt2_all_options);
-
-
-Getopt::Long::Configure("no_pass_through"); # this time strict parsing
-GetOptions($temp_all_opts, keys %getopt2_all_options) or die "Error parsing command line";
-
-# End stage-2 option parsing. 
-
-
-
-
-# Mandatory ones
-checkMandatoryArguments(['name',
-			 'group']) or exit 1;
-
-
-# Now in parfiles we have the user-supplied arguments, minus the
-# missing ones, as a hash. In $parameters we have the complete
-# list. Check for missing arguments and unreadable files.
-
-foreach my $o (keys %$parameters) {
-    my $ov=$parfiles->{$o};
-    if($ov) {
-	logInfo("Option -$o has value $ov");
-	if(! -r $ov) {
-	    die "Can't open file $ov";
-	}
-    } else {
-	logInfo("Option -$o is empty");
-	if($parameters->{$o}->{optional}) {
-	    logInfo("...which is allowed, server will supply a default");
-	} else {
-	    print STDERR "Mandatory file for parameter -$o is missing.\n";
-	    exit 1;
-	}
-    }
-}
-
-
-
-############
-# Build up list of files to upload. Currently this is
-# "$description_file.xml", created above, plus those referenced by the
-# keys of the %parameters hash.
-
-# Keys is the remote file, value the local one.
-# We already have this list.
-
-my %toupload=%$parfiles;
-
-$toupload{$description_file_xml}=$description_file;
-
-
-
-
-############
-# Make a random number as an upload id
-my $rid=sprintf('up%06d',int(rand(999999)));
-
-
-
-############
-# Build the description list
-
-my $oh={};
-
-$oh->{RandomId}=$rid;
-$oh->{UnparsedCommandLine}={content => $unparsed_cli};
-$oh->{UploadedFiles}={file => [values %toupload] };
-$oh->{TimeStamp}={Unix   => time,
-		  String => scalar localtime};
-$oh->{ClientRevision}='$Revision: 356 $';
-$oh->{LoginName}=$user;
-
-$oh->{Email}=$email;
-$oh->{Group}=$group;
-$oh->{Name}=$name;
-
-$oh->{Template}=$app_name;
-$oh->{AssignUserAll}=$assign_user_all;
-$oh->{NumSteps}=$num_steps;
-$oh->{Priority}=$priority;
-$oh->{FPopsEst}=$fpops_est;
-$oh->{FPopsBound}=$fpops_bound;
-$oh->{MemoryBound}=$memory_bound;
-
-$oh->{TargetNResults}=$target_nresults;
-$oh->{Balance}=$balance;
-$oh->{MinQuorum}=$min_quorum;
-$oh->{Batch}=$batch;
-
-$oh->{DryRun}=$dry_run;
-
-
-
-my $desc= XMLout($oh, RootName => XMLROOT, AttrIndent => 1 );
-print $description_file_fh $desc;
-close $description_file_fh;
-
-logInfo("Description file:\n$desc\n",1);
-
-
-
-
-
-##############
-# Make the DAV connection
-
-logInfo("Requesting the  DAV address");
-my $dav_url=getDavUrl("$url/$cgi_retrieve");
-
-logInfo("Connecting to DAV server");
-my $dav = new HTTP::DAV;
-# optionally: set credentials $dav->credentials
-$dav->open( -url=> $dav_url )
-    or die("Couldn’t open $dav_url: " .$dav->message . "\n");
-
-# optionally: lock
-
-# Create a directory and cd in it
-$dav->mkcol($rid);
-$dav->cwd($rid);
-
-
-
-
-############
-# Upload  files
-
-logInfo("Uploading files in dir $rid.");
-
-foreach my $upfile (keys %toupload) {
-    $dav->put(-local=>$toupload{$upfile},
-	      -url=>$upfile);
-    # add error checking
-}
-
-
-
-
-############
-# Remove the description file - not necessary: it is handled by UNLINK and tempfile()
-
-# unlink $description_file or die "Error removing temporary description file: $!";
-
-
-
-
-############
-# Call the remote endpoint
-
-logInfo("Invoking remote CGI");
-
-my $ua = new LWP::UserAgent; 
-my $cgi_url = "$url/$cgi_submit";
-my $response = $ua->post( $cgi_url,
-			  { random_id => $rid,
-			    # more parameters here if needed
-			  });
-# error will be checked after deleting the temporary directory
-my $content = $response->content; 
-logInfo("Response received:\n$content",1);
-
-
-############
-# Delete uploaded dir
-
-logInfo("Deleting temporary DAV directory");
-
-$dav->cwd("..");
-$dav->delete($rid);
-
-
-############
-# Die if the response was an error
-
-if(! $response->is_success) {
-    my $stat= $response->status_line;
-    print STDERR "The remote web server returned an error: $stat\n\n";
-    exit 1;
-}
-
-
-############
-# Parse submission status
-
-my $server_xml=XMLin($content);
-
-if($server_xml->{Failure}) {
-    print STDERR "The server CGI returned an error. Reason: $server_xml->{Failure}->{Reason}\n";
-    exit 1;
-} 
-
-
-
-############
-# Print submission status
-
-my $server_id=$server_xml->{Identifier};
-my $server_exitcode=$server_xml->{Return}->{ExitCode};
-my $server_stdout=$server_xml->{Return}->{StdOut};
-my $server_stderr=$server_xml->{Return}->{StdErr};
-
-print <<EOF;
-
-
-Submission complete.
-
-Stdout
-------
-$server_stdout
-
-Stderr
-------
-$server_stderr
-EOF
-
-if($server_exitcode) {
-	print "\n\nDetailed error information follows.\n";
-	print XMLout($server_xml->{Return}, 
-		     RootName => "Return",
-		     AttrIndent => 1 );
-}
-
-
-exit $server_exitcode;
-
-
-
-
-# ==================================================
-# Auxiliary functions
-
-
-# Check if the calling environment has all the given variables
-# defined.  If not, print one of them. Else, return false. These are
-# passed as string in order to be able to be able to print their name.
-# Sadly, must be duplicated because otherwise does not have access to
-# scope.
-
-sub checkMandatoryArguments {
-    my $l=shift;
-    foreach my $f (@$l) {
-	if(! eval("defined \$$f")) {
-	    print STDERR "Missing mandatory argument: $f. See -help.\n";
-	    return 0;
-	}
-    }
-    return 1;
-}
-
-
-
-# do this: { a=s => x }  -->  { a => x }
-
-sub copy_fix_options {
-    my $q=shift;
-    my $r={};
-    foreach my $k (keys %$q) {
-	my ($oname,$otype)=split(/=/,$k);
-	$r->{$oname}=$q->{$k};
-    }
-    return $r;
-}
-
-
-
-sub printParametersHelp {
-    my $t=shift;
-
-    my $p=parseWuTemplate($t);
-
-    print "\n";
-    print "Remote application queue `$app_name'\n";
-    print "Description: $t->{WuTemplate}->{rboinc}->{description}\n";
-    print "Application on server: `$t->{WuTemplate}->{rboinc}->{application}'\n";
-    print "\n";
-    print "Options defined for this application queue:\n";
-    foreach my $pn (sort keys %$p) {
-	print "    -$pn\t\t";
-	if($p->{$pn}->{optional}) {
-	    print "(optional) ";
-	}
-	print $p->{$pn}->{description}."\t";
-	print "\n";
-    }
-    print "\n";
-}
-
-
-
-
-# ==================================================
-
-
-# for sending requests: http://snippets.dzone.com/posts/show/3163
-
-
-sub printHelp {
-    print <<EOF;
-Boinc remote submission. Usage: boinc_submit [OPTION]...
-
-**  SEE -help_parameters FOR SIMULATION PARAMETERS  **
-
-Authentication:
-    -url       URL       RBoinc URL contact point (*)
-    -app_name  APP       Remote application     [$app_name]
-    -user      NAME      Override username      [$user]
-    -email     ADDRESS   (Not implemented)
-    -authenticator ID    (Not implemented)
-
-Simulation identifier (mandatory):
-    -group     ID        The simulation group 
-    -name      ID        The individual job ID
-
-Scheduling:
-    -metadata_file FILE  Additional metadata file
-    -assign_user_all ID	 Assign to user		[$assign_user_all]
-    -num_steps   NUM     Number of steps to run [$num_steps]
-    -priority    NUM     BOINC priority level   [$priority]
-
-Resources:
-    -fpops_est   FLOAT   Estimated FP count     [$fpops_est]
-    -fpops_bound FLOAT   Max FP count           [$fpops_bound]
-    -memory_bound FLOAT  Memory requirement     [$memory_bound]
-    -target_nresults NUM Redundancy             [$target_nresults]
-    -balance     ID      Load balancing alg. (on=1)
-    -min_quorum  NUM     (Not implemented)
-    -dry_run             Upload, but not start WUs
-    -batch       NUM     Batch number           [$batch]
-
-Miscellaneous:
-    -help_parameters     Show list of parameters, ie files to be
-                         transferred (depending on the application)
-    -help                This message
-    -verbose             Be verbose
-
-(*) You can also use the RBOINC_URL environment variable.
-    For example: http://www.ps3grid.net:8383/rboinc_cgi
-
-EOF
-}
-
-
-
-
diff --git a/rboinc/monitoring/Text/Aligner.pm b/rboinc/monitoring/Text/Aligner.pm
deleted file mode 100644
index 3869af7..0000000
--- a/rboinc/monitoring/Text/Aligner.pm
+++ /dev/null
@@ -1,426 +0,0 @@
-# Text::Aligner - Align text in columns
-package Text::Aligner;
-use strict;
-
-use warnings;
-
-BEGIN    {
-    use Exporter ();
-    use vars qw ($VERSION @ISA @EXPORT @EXPORT_OK %EXPORT_TAGS);
-    $VERSION     = 0.03;
-    @ISA         = qw (Exporter);
-    #Give a hoot don't pollute, do not export more than needed by default
-    @EXPORT      = qw ();
-    @EXPORT_OK   = qw ( align);
-    %EXPORT_TAGS = ();
-}
-
-# this is a non-method, and currently the only user interface
-sub align ($@) {
-    my $ali = Text::Aligner->new( shift);
-    $ali->alloc( map ref eq 'SCALAR' ? $$_ : $_, @_);
-    if ( defined wantarray ) {
-        my @just = map $ali->justify( ref eq 'SCALAR' ? $$_ : $_), @_;
-        return @just if wantarray;
-        return join "\n", @just, '';
-    } else {
-        for ( @_ ) {
-            $_ = $ali->justify( $_) for ref eq 'SCALAR' ? $$_ : $_; # one-shot
-        }
-    }
-}
-
-### class Text::Aligner
-
-sub _new { # internal creator
-    my $class = shift;
-    my ( $width, $pos) = @_; # both method-or-coderef (this is very general)
-    bless {
-        width => $width,
-        pos => $pos,
-        left => Text::Aligner::MaxKeeper->new,
-        right => Text::Aligner::MaxKeeper->new,
-    }, $class;
-}
-
-# create an aligner
-sub new {
-    my ( $class, $spec) = @_;
-    $spec ||= 0; # left alignment is default
-    my $al;
-    if ( !ref( $spec) and $spec =~ s/^auto/num/ ) {
-        $al = Text::Aligner::Auto->_new( $spec);
-    } else {
-        $al = $class->_new( _compile_alispec( $spec));
-    }
-    $al;
-}
-
-# return left and right field widths for an object
-sub _measure0 {
-    my $al = shift;
-    my $obj = shift;
-    $obj = '' unless defined $obj;
-    my ( $w, $p);
-    if ( ref $obj ) {
-        ( $w, $p) = ( $obj->$al->{ width}->(), $obj->$al->{ pos}->() );
-    } else {
-        ( $w, $p) = ( $al->{ width}->( $obj), $al->{ pos}->( $obj) );
-    }
-    $_ ||= 0 for $w, $p;
-    ( $p, $w - $p);
-}
-
-# return left and right field widths for an object
-sub _measure {
-    my $al = shift;
-    my $obj = shift;
-    $obj = '' unless defined $obj;
-    my ( $wmeth, $pmeth) = @{ $al}{ qw( width pos)};
-    my $w = ref $wmeth ? $wmeth->( $obj) : $obj->$wmeth;
-    my $p = ref $pmeth ? $pmeth->( $obj) : $obj->$pmeth;
-    $_ ||= 0 for $w, $p;
-    ( $p, $w - $p);
-}
-
-# return left and rigth maxima, or nothing if the aligner is empty
-sub _status {
-    my @lr = ( $_[ 0]->{ left}->max, $_[ 0]->{ right}->max);
-    # $l and $r should be both defined or undefined, unless the
-    # MaxKeeper memory is corrupted by forgetting unremembered things.
-    return unless defined( $lr[ 0]) and defined( $lr[ 1]);
-    @lr;
-}
-
-# remember alignment requirements
-sub alloc {
-    my $al = shift;
-    for ( @_ ) {
-#       $_ ||= ''; print "allocing '$_'\n";
-        my ( $l, $r) = $al->_measure( $_);
-        $al->{ left}->remember( $l); # space needed left of pos
-        $al->{ right}->remember( $r); # ...and right of pos
-    }
-    $al;
-}
-
-# release alignment requirement.  it disturbs an aligner deeply to forget
-# things it hasn't remembered.  the effects may be delayed.
-sub _forget {
-    my $al = shift;
-    for ( map defined() ? $_ : '', @_ ) {
-#       print "forgetting '$_'\n";
-        my ( $l, $r) = $al->_measure( $_);
-        $al->{ left}->forget( $l);
-        $al->{ right}->forget( $r);
-    }
-    $al;
-}
-
-# justify a string.  a string is aligned within the aligner's field, and
-# filled with blanks or cut to size, as appropriate.  a string that has
-# been allocated will never be trimmed (that is the point of allocation).
-# if the aligner is empty it returns the string unaltered.
-sub justify {
-    my $al = shift;
-    my $str  = shift;
-#   print "justifying '$str'\n";
-    $str .= ''; # stringify (objects, numbers, undef)
-    my ( $l_pad, $r_pad) = $al->_padding( $str);
-    substr( $str, 0, -$l_pad) = '' if $l_pad < 0; # trim if negative
-    substr( $str, $r_pad) = '' if $r_pad < 0; # ... both ends
-    join $str, ' ' x $l_pad, ' ' x $r_pad; # pad if positive
-}
-
-# return two numbers that indicate how many blanks are needed on each side
-# of a string to justify it.  Negative values mean trim that many characters.
-# an empty aligner returns ( 0, 0), so doesn't change anything.
-sub _padding {
-    my $al = shift;
-    my $str = shift;
-    my ( $this_l, $this_r) = $al->_measure( $str);
-    my ( $l_pad, $r_pad) = ( 0, 0);
-    if ( $al->_status ) {
-        ( $l_pad, $r_pad) = $al->_status;
-        $l_pad -= $this_l;
-        $r_pad -= $this_r;
-    }
-    ( $l_pad, $r_pad);
-}
-
-# _compile_alispec() returns positioners according to specification.  In
-# effect, it is is the interpreter for alignment specifications.
-
-sub _compile_alispec { # it's a dirty job...
-    my $width = sub { length shift }; # this is always so for string aligners
-    my $pos; # the positioner we actually compile
-    local $_ = shift || ''; # alignment specification
-    if ( ref() eq 'Regexp' ) { 
-        my $regex = $_; # lexical copy!
-        $pos = sub {
-            local $_ = shift;
-            m/$regex/ ? $-[ 0] : length; # assume match after string
-        };
-    } else {
-        s/^left/0/;
-        s/^center/0.5/;
-        s/^right/1/;
-        if ( _is_number( $_) ) {
-            my $proportion = $_; # use lexical copy
-            $pos = sub { int( $proportion*length shift) };
-        } elsif ( $_ =~ /^(?:num|point)(?:\((.*))?/ ) {
-            my $point = defined $1 ? $1 : '';
-            $point =~ s/\)$//; # ignore trailing paren, if present
-            length $point or $point = '.';
-            $pos = sub { index( shift() . $point, $point) }
-        } else {
-            $pos = sub { 0 };
-        }
-    }
-    ( $width, $pos);
-}
-
-# decide if a string is a number. (see perlfaq4).  This needs to become
-# more flexible for auto-alignment
-sub _is_number { defined( $_[ 0]) and $_[ 0] =~ /^-?\d+\.?\d*$/ }
-
-package Text::Aligner::Auto;
-# Combined numeric and left alignment.  Numbers are aligned numerically,
-# other strings are left-aligned.  The resulting columns are interleaved
-# flush left and filled on the right if necessary.
-
-sub _new { # only called by Text::Aligner->new()
-    my $class = shift;
-    my $numspec = shift; # currently ignored
-    bless {
-        num => Text::Aligner->new( 'num'),    # align numbers among themselves
-        other => Text::Aligner->new,          # left-align anything else
-    }, $class;
-}
-
-sub alloc {
-    my $aa = shift;
-    my @num = grep _is_number( $_), @_;
-    my @other = grep !_is_number( $_), @_;
-    $aa->{ num}->alloc( @num);
-    $aa->{ other}->alloc( @other);
-    $aa;
-}
-
-sub _forget {
-    my $aa = shift;
-    $aa->{ num}->_forget( grep _is_number( $_), @_);
-    $aa->{ other}->_forget( grep !_is_number( $_), @_);
-    $aa;
-}
-
-# justify as required
-sub justify {
-    my ( $aa, $str) = @_;
-    # align according to type
-    $str = $aa->{ _is_number( $str) ? 'num' : 'other'}->justify( $str);
-    my $combi = Text::Aligner->new; # left-justify pre-aligned string
-    # initialise to size of partial aligners.  (don't initialise from
-    # empty aligner)
-    $combi->alloc( $aa->{ num}->justify( '')) if $aa->{ num}->_status;
-    $combi->alloc( $aa->{ other}->justify( '')) if $aa->{ other}->_status;
-    $combi->justify( $str);
-}
-
-# for convenience
-BEGIN { # import _is_number()
-    *_is_number = \ &Text::Aligner::_is_number;
-}
-
-package Text::Aligner::MaxKeeper;
-# Keep the maximum of a dynamic set of numbers.  Optimized for the case of
-# a relatively small range of numbers that may occur repeatedly.
-
-sub new {
-    bless {
-        max => undef,
-        seen => {},
-    }, shift;
-}
-
-sub max { $_[ 0]->{ max} }
-
-sub remember {
-    my ( $mk, $val) = @_;
-    _to_max( $mk->{ max}, $val);
-    $mk->{ seen}->{ $val}++;
-    $mk;
-}
-
-sub forget {
-    my ( $mk, $val) = @_;
-    if ( exists $mk->{ seen}->{ $val} ) {
-        my $seen = $mk->{ seen};
-        unless ( --$seen->{ $val} ) {
-            delete $seen->{ $val};
-            if ( $mk->{ max} == $val ) {
-                # lost the maximum, recalculate
-                undef $mk->{ max};
-                _to_max( $mk->{ max}, keys %$seen);
-            }
-        }
-    }
-    $mk;
-}
-
-sub _to_max {
-    my $var = \ shift;
-    defined $_ and ( not defined $$var or $$var < $_) and $$var = $_ for @_;
-    $$var;
-}
-
-########################################### main pod documentation begin ##
-
-=head1 NAME
-
-Text::Aligner
-
-=head1 SYNOPSIS
-
-  use Text::Aligner qw( align);
-
-  # Print the words "just a test!" right-justified each on a line:
-
-  my @lines = align( 'right', qw( just a test!);
-  print "$_\n" for @lines;
-
-=head1 DESCRIPTION
-
-Text::Aligner exports a single function, align(), which is
-used to justify strings to various alignment styles.  The
-alignment specification is the first argument, followed by
-any number of scalars which are subject to alignment.
-
-The operation depends on context.  In list context, a list of
-the justified scalars is returned.  In scalar context, the
-justified arguments are joined into a single string with newlines
-appended.  The original arguments remain unchanged.  In void
-context, in-place justification is attempted.  In this case, all
-arguments must be lvalues.
-
-Align() also does one level of scalar dereferencing.  That is,
-whenever one of the arguments is a scalar reference, the scalar
-pointed to is aligned instead.  Other references are simply stringified.
-An undefined argument is interpreted as an empty string without
-complaint.
-
-=head1 ALIGNMENT
-
-The first argument of the align() function is an alignment style, a
-single scalar.
-
-It can be one of the strings "left", "right", "center", "num", "point",
-or "auto", or a regular expression (qr/.../), or a coderef.
-
-A default style of "left" is assumed for every other value, including
-"" and undef. 
-
-"left", "right" and "center" have the obvious meanings.  These can
-also be given as numbers 0, 1, and 0.5 respectively. (Other numbers
-are also possible, but probably not very useful).
-
-"num", and its synonym "point", specify that the decimal points be
-aligned (assumed on the right, unless present).  Arbitrary (non-numeric)
-strings are also aligned in this manner, so they end up one column left
-of the (possibly assumed) decimal point, flush right with any integers. 
-For the occasional string like "inf", or "-" for missing values, this
-may be the right place.  A string-only column ends up right-aligned
-(unless there are points present).
-
-The "auto" style seperates numeric strings (that are composed of
-"-", ".", and digits in the usual manner) and aligns them numerically.
-Other strings are left aligned with the number that sticks out
-farthest to the left.  This gives left alignment for string-only
-columns and numeric alignment for columns of numbers.  In mixed
-columns, strings are reasonably placed to serve as column headings
-or intermediate titles.
-
-With "num" (and "point") it is possible to specify another character
-for the decimal point in the form "num(,)".  In fact, you can specify
-any string after a leading "(", and the closing ")" is optional.
-"point(=>)" could be used to align certain pieces of Perl code.  This
-option is currently not available with "auto" alignment (because
-recognition of numbers is Anglo-centric).
-
-If a regular expression is specified, the points are aligned where
-the first match of the regex starts.  A match is assumed immediately
-after the string if it doesn't match.
-
-A regular expression is a powerful way of alignment specification.  It
-can replace most others easily, except center alignment and, of course,
-the double action of "auto".
-
-=head1 POSITIONERS
-
-For entirely self-defined forms of alignment, a coderef, also known
-as a positioner, can be given instead of an alignment style.  This
-code will be called once or more times with the string to be aligned
-as its argument.  It must return two numbers, a width and a position,
-that describe how to align a string with other strings.
-
-The width should normally be the length of the string.  The position
-defines a point relative to the beginning of the string, which is
-aligned with the positions given for other strings.
-
-A zero position for all strings results in left alignment, positioning
-to the end of the string results in right alignment, and returning
-half the length gives center alignment.  "num" alignment is realized
-by marking the position of the decimal point.
-
-Note that the position you return is a relative measure.  Adding a
-constant value to all positions results in no change in alignment.
-It doesn't have to point inside the string (as in right alignment,
-where it points one character past the end of the string).
-
-The first return value of a positioner should almost always be the
-length of the given string.  It may be useful to ly about the string
-length if the string contains escape sequences that occupy no place
-on screen.
-
-=head1 USAGE
-
-  use Text::Aligner qw( align);
-
-  align( $style, $str, ...);
-
-  $style must be given and must be an alignment specification.
-  Any number of scalars can follow.  An argument that contains a
-  scalar reference is dereferenced before it is used.  In scalar
-  and list context, the aligned strings are returned.  In void
-  context, the values are aligned in place and must be lvalues.
-
-=head1 BUGS
-
-  None known as of realease, but...
-
-=head1 AUTHOR
-
-    Anno Siegel
-    CPAN ID: ANNO
-    siegel at zrz.tu-berlin.de
-    http://www.tu-berlin.de/~siegel
-
-=head1 COPYRIGHT
-
-Copyright (c) 2002 Anno Siegel. All rights reserved.
-This program is free software; you can redistribute
-it and/or modify it under the same terms as Perl itself.
-
-The full text of the license can be found in the
-LICENSE file included with this module.
-
-=head1 SEE ALSO
-
-perl(1)
-
-Text::Table
-
-=cut
-
-1; #this line is important and will help the module return a true value
-__END__
diff --git a/rboinc/monitoring/Text/Table.pm b/rboinc/monitoring/Text/Table.pm
deleted file mode 100644
index 3ecb508..0000000
--- a/rboinc/monitoring/Text/Table.pm
+++ /dev/null
@@ -1,1026 +0,0 @@
-# Text::Table - Organize Data in Tables
-package Text::Table;
-use strict;
-use warnings;
-
-use Text::Aligner qw( align);
-
-BEGIN {
-    use Exporter ();
-    our $VERSION = ('$Revision: 1.114 $' =~ /(\d+.\d+)/)[ 0];
-
-}
-
-use overload
-    '""'  => 'stringify',
-;
-
-### User interface:  How to specify columns and column separators
-
-sub _is_sep {
-    local $_ = shift;
-    defined and ( ref eq 'SCALAR' or ( ref eq 'HASH' and $_->{ is_sep}));
-}
-
-sub _parse_sep {
-    local $_ = shift;
-    defined $_ or $_ = '';
-    my ( $title, $body);
-    if ( ref eq 'HASH' ) {
-        ( $title, $body) = @{ $_}{ qw( title body)};
-    } else {
-        ( $title, $body) = split /\n/, $$_, -1;
-    }
-    $body = $title unless defined $body;
-    align( 'left', $title, $body);
-    {
-        is_sep => 1,
-        title  => $title,
-        body   => $body,
-    }
-}
-
-sub _parse_spec {
-    local $_ = shift;
-    defined $_ or $_ = '';
-    my $alispec = qr/^ *(?:left|center|right|num|point|auto)/;
-    my ( $title, $align, $align_title, $align_title_lines, $sample);
-    if ( ref eq 'HASH' ) {
-        ( $title, $align, $align_title, $align_title_lines, $sample) =
-            @{ $_}{ qw( title align align_title align_title_lines sample)};
-    } else {
-        my $alispec = qr/&(.*)/;
-        if ( $_ =~ $alispec ) {
-            ( $title, $align, $sample) = /(.*)^$alispec\n?(.*)/sm;
-        } else {
-            $title = $_;
-        }
-        defined and chomp for $title, $sample;
-    }
-    defined or $_ = [] for $title, $sample;
-    defined $align and length $align or $align = 'auto';
-    ref eq 'ARRAY' or $_ = [ split /\n/, $_, -1] for $title, $sample;
-    unless (
-        ref $align eq 'Regex' or
-        $align =~ /^(?:left|center|right|num\(?|point\(?|auto)/
-    ) {
-        _warn( "Invalid align specification: '$align', using 'auto'");
-        $align = 'auto';
-    }
-    defined $align_title and length $align_title or $align_title = 'left';
-    unless ( $align_title =~ /^(?:left|center|right)/ ) {
-        _warn( "Invalid align_title specification: " .
-            "'$align_title', using 'left'",
-        );
-        $align_title = 'left';
-    }
-    defined $align_title_lines and length $align_title_lines or
-        $align_title_lines = $align_title;
-    unless ( $align_title_lines =~ /^(?:left|center|right)/ ) {
-        _warn( "Invalid align_title_lines specification: " .
-            "'$align_title_lines', using 'left'",
-        );
-        $align_title_lines = 'left';
-    }
-    {
-        title             => $title,
-        align             => $align,
-        align_title       => $align_title,
-        align_title_lines => $align_title_lines,
-        sample            => $sample,
-    }
-}
-
-### table creation
-
-sub new {
-    my $tb = bless {}, shift;
-    $tb->_entitle( @_);
-}
-
-sub _entitle {
-    my $tb = shift; # will be completely overwritten
-    # find active separators and, well separate them from col specs.
-    # n+1 separators for n cols
-    my ( @seps, @spec); # separators and column specifications
-    my $sep;
-    for ( @_ ) {
-        if ( _is_sep ( $_) ) {
-            $sep = _parse_sep( $_);
-        } else {
-            push @seps, $sep;
-            push @spec, _parse_spec( $_);
-            undef $sep;
-        }
-    }
-    push @seps, $sep;
-    # build sprintf formats from separators
-    my $title_form =
-        _compile_format( map defined() ? $_->{ title} : undef, @seps);
-    my $body_form  =
-        _compile_format( map defined() ? $_->{ body} : undef, @seps);
-
-    # pre_align titles
-    my @titles = map [ @{ $_->{ title}}], @spec;
-    my $title_height = 0;
-    _to_max( $title_height, scalar @$_) for @titles;
-    push @$_, ( '') x ( $title_height - @$_) for @titles;
-#   align( 'left', @$_) for @titles; # ready for use'
-    my @styles = map $_->{ align_title_lines}, @spec;
-    align( shift @styles, @$_) for @titles; # in-place alignment
-
-    # build data structure
-    %$tb = (
-        spec => \ @spec,                     # column spec for reuse
-        titles => \ @titles,                 # titles, pre-aligned
-        cols => [ map [], 1 .. @spec],       # data columns
-        forms => [ $title_form, $body_form], # separators condensed
-    );
-    $tb->_clear_cache;
-}
-
-# sprintf-format for line assembly, using separators
-sub _compile_format {
-   my @seps = @_; # mix of strings and undef (for default)
-   defined or $_ = '' for @seps[ 0, -1]; # first and last default to empty
-   defined or $_ = ' ' for @seps; # others default to single space
-   s/%/%%/g for @seps; # protect against sprintf
-   join '%s', @seps;
-}
-
-# reverse format compilation (used by colrange())
-sub _recover_separators {
-    my $format = shift;
-    my @seps = split /(?<!%)%s/, $format, -1;
-    s/%%/%/g for @seps;
-    @seps;
-}
-
-# select some columns, (optionally if in [...]), and add new separators
-# (the other table creator)
-sub select {
-    my $tb = shift;
-    my @args = map $tb->_select_group( $_), @_;
-    # get column selection, checking indices (some have been checked by
-    # _select_group, but not all)
-    my @sel = map $tb->_check_index( $_), grep !_is_sep( $_), @args;
-    # replace indices with column spec to create subtable
-    ! _is_sep( $_) and $_ = $tb->{ spec}->[ $_] for @args;
-    my $sub = ref( $tb)->new( @args);
-    # sneak in data columns
-    @{ $sub->{ cols}} = map [ @$_ ], @{ $tb->{ cols}}[ @sel];
-    $sub;
-}
-
-# the first non-separator column in the group is tested if it has any data
-# if so, the group is returned, else nothing
-sub _select_group {
-    my ( $tb, $group) = @_;
-    return $_ unless ref $group eq 'ARRAY';
-    for ( @$group ) {
-        next if _is_sep( $_);
-        $tb->_check_index( $_);
-        return @$group if grep $_, @{ $tb->{ cols}->[ $_]};
-        return; # no more tries after non-sep was found
-    }
-    return; # no column index in group, no select
-}
-
-# check index for validity, return arg if returns at all
-sub _check_index {
-    my $tb = shift;
-    my ( $i) = @_;
-    my $n = $tb->n_cols;
-    my $ok = eval {
-        use warnings FATAL => 'numeric';
-        -$n <= $i and $i < $n; # in range of column array?
-    };
-    _warn( "Invalid column index '$_'") if $@ or not $ok;
-    shift;
-}
-
-### data entry
-
-sub _clear_cache { @{ $_[ 0]}{ qw( lines blank)} = (); $_[ 0] }
-
-# add one data line or split the line into follow-up lines
-sub add {
-    my $tb = shift;
-    $tb->_entitle( ( '') x @_) unless $tb->n_cols;
-
-    $tb->_add( @$_) for _transpose( map [ defined() ? split( $/ ) : '' ], @_);
-    $tb->_clear_cache;
-}   
-
-# add one data line
-sub _add {
-    my $tb = shift;
-    push @$_, shift for @{ $tb->{ cols}};
-    $tb->_clear_cache;
-    $tb;
-}
-
-# add one or more data lines
-sub load {
-    my $tb = shift;
-    for ( @_ ) {
-        defined $_ or $_ = '';
-        ref eq 'ARRAY' ? $tb->add( @$_) : $tb->add( split);
-    }
-    $tb;
-}
-
-sub clear {
-    my $tb = shift;
-    $_ = [] for @{ $tb->{ cols}};
-    $tb->_clear_cache;
-    $tb;
-}
-
-### access to output area
-
-## sizes
-
-# number of table clolumns
-sub n_cols { scalar @{ $_[0]->{ spec}} }
-
-# number of title lines
-sub title_height { $_[ 0]->n_cols and scalar @{ $_[ 0]->{ titles}->[ 0]} }
-
-# number of data lines
-sub body_height { $_[ 0]->n_cols and scalar @{ $_[ 0]->{ cols}->[ 0]} }
-
-# total height
-sub table_height { $_[ 0]->title_height + $_[ 0]->body_height }
-BEGIN { *height = \ &table_height} # alias
-
-# number of characters in each table line. need to build the table to know
-sub width {
-    $_[ 0]->height and length( ($_[ 0]->table( 0))[ 0]) - 1;
-}
-
-# start and width of each column
-sub colrange {
-    my ( $tb, $col_index) = @_;
-    return ( 0, 0) unless $tb->width; # width called, $tb->{ blank} exists now
-    $col_index ||= 0;
-    $col_index += $tb->n_cols if $col_index < 0;
-    _to_max( $col_index, 0);
-    _to_min( $col_index, $tb->n_cols);
-    my @widths = map length, @{ $tb->{ blank}}, '';
-    @widths = @widths[ 0 .. $col_index];
-    my $width = pop @widths;
-    my $pos = 0;
-    $pos += $_ for @widths;
-    my @seps = _recover_separators( $tb->{ forms}->[ 0]);
-    $pos += length for @seps[ 0 .. $col_index];
-    return ( $pos, $width);
-}
-
-## printable output
-
-# whole table
-sub table {
-    my $tb = shift;
-    $tb->_table_portion( $tb->height, 0, @_);
-}
-
-# only titles
-sub title {
-    my $tb = shift;
-    $tb->_table_portion( $tb->title_height, 0, @_);
-}   
-
-# only body
-sub body {
-    my $tb = shift;
-    $tb->_table_portion( $tb->body_height, $tb->title_height, @_);
-}
-
-sub stringify { scalar shift()->table() }
-
-### common internals
-
-# common representation of table(), title() and body()
-sub _table_portion {
-    my $tb = shift;
-    my ( $total, $offset) = ( shift, shift);
-    my ( $from, $n) = ( 0, $total); # if no parameters
-    if ( @_ ) {
-        $from = shift;
-        $n = @_ ? shift : 1; # one line if not given
-    }
-    ( $from, $n) = _limit_range( $total, $from, $n);
-    my @lines = do {
-        my $limit = $tb->title_height; # title format below
-        $from += $offset;
-        map $tb->_assemble_line( $_ >= $limit, $tb->_table_line( $_)),
-            $from .. $from + $n - 1;
-    };
-    return @lines if wantarray;
-    return join '', @lines;
-}
-
-sub _limit_range {
-    my ( $total, $from, $n) = @_;
-    $from ||= 0;
-    $from += $total if $from < 0;
-    $n = $total unless defined $n;
-    return ( 0, 0) if $from + $n < 0 or $from >= $total;
-    $from = 0 if $from < 0;
-    $n = $total - $from if $n > $total - $from;
-    ( $from, $n);
-}
-
-# get table line (formatted, including titles). fill cache if needed
-sub _table_line {
-    my $tb = shift;
-    ($tb->{ lines} ||= [ $tb->_build_table_lines])->[ shift];
-}
-
-# build array of lines of justified data items
-sub _build_table_lines {
-    my $tb = shift;
-
-    # copy data columns, replacing undef with ''
-    my @cols = map [ map defined() ? $_ : '', @$_], @{ $tb->{ cols}};
-
-    # add set of empty strings for blank line (needed to build horizontal rules)
-    push @$_, '' for @cols;
-
-    # add samples for minimum alignment
-    my @samples = map $_->{ sample}, @{ $tb->{ spec}};
-    push @$_, @{ shift @samples} for @cols;
-
-    # align to style
-    my @styles = map $_->{ align}, @{ $tb->{ spec}};
-    align( shift @styles, @$_) for @cols;
-    # trim off samples, but leave blank line
-    splice @$_, 1 + $tb->body_height for @cols; # + 1 for blank line (brittle)
-
-    # include titles
-    my @titles = @{ $tb->{ titles}};
-    unshift @$_, @{ shift @titles} for @cols; # add pre-aligned titles
-
-    # align title and body portions of columns
-    # blank line will be there even with no data
-    @styles = map $_->{ align_title}, @{ $tb->{ spec}};
-    align( shift @styles, @$_) for @cols; # in-place alignment
-
-    # deposit a blank line, pulling it off the columns.
-    # *_rule() knows this is done
-    $tb->{ blank} = [ map pop @$_, @cols];
-
-    _transpose_n( $tb->height, @cols); # bye-bye, @cols
-}
-
-# destructively transpose a number of lines/cols from an array of arrayrefs 
-sub _transpose_n ($@) {
-    my $n = shift;
-    map [ map shift @$_, @_], 1 .. $n;
-}
-
-# like _transpose_n, but find the number to transpose from max of given
-sub _transpose {
-    my $m;
-    _to_max( $m, scalar @$_) for @_, []; # make sure $m is defined
-    _transpose_n( $m, @_);
-}
-
-# make a line from a number of formatted data elements
-sub _assemble_line {
-    my $tb = shift;
-    my $in_body = shift; # 0 for title, 1 for body
-    sprintf( $tb->{ forms}->[ !!$in_body], @{ shift()}) . "\n";
-}
-
-# build a rule line
-sub _rule {
-    my $tb = shift;
-    my $in_body = shift;
-    return '' unless $tb->width; # this builds the cache, hence $tb->{ blank}
-    my $rule = $tb->_assemble_line( $in_body, $tb->{ blank});
-    my ( $char, $alt) = map /(.)/, @_;
-    ( defined $char and length $char) or $char = ' ';
-    # replace blanks with $char. If $alt is given, replace nonblanks with $alt
-    if ( defined $alt ) {
-        $rule =~ s/(.)/$1 eq ' ' ? $char : $alt/ge;
-    } else {
-        $rule =~ s/ /$char/g if $char ne ' ';
-    }
-    $rule;
-}
-
-sub rule {
-    my $tb = shift;
-    $tb->_rule( 0, @_);
-}
-
-sub body_rule {
-    my $tb = shift;
-    $tb->_rule( 1, @_);
-}
-
-# min/max utilitiess (modifying first argument)
-
-sub _to_max {
-    defined $_[ 0] and $_[ 0] > $_[ 1] or $_[ 0] = $_[ 1] if defined $_[ 1];
-}
-
-sub _to_min {
-    defined $_[ 0] and $_[ 0] < $_[ 1] or $_[ 0] = $_[ 1] if defined $_[ 1];
-}
-
-### warning behavior
-use Carp;
-
-{
-    my ( $warn, $fatal) = ( 0, 0);
-
-    sub warnings {
-        shift; # ignore class/object
-        local $_ = shift || 'on';
-        if ( $_ eq 'off' ) {
-            ( $warn, $fatal) = ( 0, 0);
-        } elsif ( $_ eq 'fatal' ) {
-            ( $warn, $fatal) = ( 1, 1);
-        } else {
-            ( $warn, $fatal) = ( 1, 0);
-        }
-        return 'fatal' if $fatal;
-        return 'on' if $warn;
-        return 'off';
-    }
-
-    sub _warn {
-        my $msg = shift;
-        return unless $warn;
-        croak( $msg) if $fatal;
-        carp( $msg);
-    }
-}
-
-__END__
-########################################### main pod documentation begin ##
-
-=head1 NAME
-
-Text::Table - Organize Data in Tables
-
-=head1 SYNOPSIS
-
-    use Text::Table;
-    my $tb = Text::Table->new(
-        "Planet", "Radius\nkm", "Density\ng/cm^3"
-    );
-    $tb->load(
-        [ "Mercury", 2360, 3.7 ],
-        [ "Venus", 6110, 5.1 ],
-        [ "Earth", 6378, 5.52 ],
-        [ "Jupiter", 71030, 1.3 ],
-    );
-    print $tb;
-
-This prints a table from the given title and data like this:
-
-  Planet  Radius Density
-          km     g/cm^3 
-  Mercury  2360  3.7    
-  Venus    6110  5.1    
-  Earth    6378  5.52   
-  Jupiter 71030  1.3    
-
-Note that two-line titles work, and that the planet names are aligned
-differently than the numbers.
-
-=head1 DESCRIPTION
-
-Organization of data in table form is a time-honored and useful
-method of data representation.  While columns of data are trivially
-generated by computer through formatted output, even simple tasks
-like keeping titles aligned with the data columns are not trivial,
-and the one-shot solutions one comes up with tend to be particularly
-hard to maintain.  Text::Table allows you to create and maintain
-tables that adapt to alignment requirements as you use them.
-
-=head2 Overview
-
-The process is simple: you create a table (a Text::Table object) by
-describing the columns the table is going to have.  Then you load
-lines of data into the table, and finally print the resulting output
-lines.  Alignment of data and column titles is handled dynamically
-in dependence on the data present.
-
-=head2 Table Creation
-
-In the simplest case, if all you want is a number of (untitled) columns,
-you create an unspecified table and start adding data to it.  The number
-of columns is taken fronm the first line of data.
-
-To specify a table you specify its columns.  A column description
-can contain a title and alignment requirements for the data, both
-optional.  Additionally, you can specify how the title is aligned with
-the body of a column, and how the lines of a multiline title are
-aligned among themselves.
-
-The columns are collected in the table in the
-order they are given.  On data entry, each column corresponds to
-one data item, and in column selection columns are indexed left to
-right, starting from 0.
-
-Each title can be a multiline string which will be blank-filled to
-the length of the longest partial line.  The largest number of title
-lines in a column determines how many title lines the table has as a
-whole, including the case that no column has any titles.
-
-On output, Columns are separated by a single blank.  You can control
-what goes between columns by specifying separators between (or before,
-or after) columns.  Separators don't contain any data and don't count
-in column indexing.  They also don't accumulate: in a sequence of only
-separators and no columns, only the last one counts.
-
-=head2 Status Information
-
-The width (in characters), height (in lines), number of columns, and
-similar data about the table is available.
-
-=head2 Data Loading
-
-Table data is entered line-wise, each time specifying data entries
-for all table columns.  A bulk loader for many lines at once is also
-available.  You can clear the data from the table for re-use (though
-you will more likely just create another table).
-
-=head2 Table Output
-
-The output area of a table is divided in the title and the body.
-
-The title contains the combined titles from the table columns, if
-any.  Its content never changes with a given table, but it may be
-spread out differently on the page through alignment with the data.
-
-The body contains the data lines, aligned column-wise as specified,
-and left-aligned with the column title.
-
-Each of these is arranged like a Perl array (counting from 0) and can
-be accessed in portions by specifying a first line and the number
-of following lines.  Also like an array, giving a negative first line
-counts from the end of the area.  The whole table, the title followed
-by the body, can also be accessed in this manner.
-
-The subdivisions are there so you can repeat the title (or parts of
-it) along with parts of the body on output, whether for screen paging
-or printout.
-
-A rule line is also available, which is the horizontal counterpart to
-the separator columns you specify with the table.
-It is basically a table line as it would appear if all data entries
-in the line were empty, that is, a blank line except for where the
-column separators have non-blank entries.  If you print it between
-data lines, it will not disrupt the vertical separator structure
-as a plain blank line would.  You can also request a solid rule
-consisting of any character, and even one with the non-blank column
-separators replaced by a character of your choice.  This way you can
-get the popular representation of line-crossings like so:
-
-      |
-  ----+---
-      |
-
-=head2 Warning Control
-
-On table creation, some parameters are checked and warnings issued
-if you allow warnings.  You can also turn warnings into fatal errors.
-
-=head1 SPECIFICATIONS
-
-=head2 Column Specification
-
-Each column specification is a single scalar.  Columns can be either proper
-data columns or column separators.  Both can be specified either as
-(possibly multi-line) strings, or in a more explicit form as hash-refs.
-In the string form, proper columns are given as plain strings, and
-separators are given as scalar references to strings.  In hash form,
-separators have a true value in the field C<is_sep> while proper columns
-don't have this field.
-
-=over 4
-
-=item Columns as strings
-
-A column is given as a column title (any number of lines),
-optionally followed by alignment requirements.  Alignment requirements
-start with a line that begins with an ampersamd "&".  However, only the
-last such line counts as such, so if you have title lines that begin
-with "&", just append an ampersand on a line by itself as a dummy
-alignment section if you don't have one anyway.
-
-What follows the ampersand on its line is the alignment style (like
-I<left>, I<right>, ... as described in L<"Alignment">), you want for
-the data in this column.  If nothing follows, the general default I<auto>
-is used.  If you specify an invalid alignment style, it falls back to
-left alignment.
-
-The lines that follow can contain sample data for this column.  These
-are considered for alignment in the column, but never actually appear
-in the output.  The effect is to guarantee a minimum width for the
-column even if the current data doesn't require it.  This helps dampen
-the oscillations in the appearance of dynamically aligned tables.
-
-=item Columns as Hashes
-
-The format is
-
-    {
-        title   => $title,
-        align   => $align,
-        sample  => $sample,
-        align_title => $align_title,
-        align_title_lines => $align_title_lines,
-    }
-
-$title contains the title lines and $sample the sample data.  Both can
-be given as a string or as an array-ref to the list of lines.  $align contains
-the alignment style (without a leading ampersand), usually as a string.
-You can also give a regular expression here, which specifies regex alignment.
-A regex can only be specified in the hash form of a colunm specification.
-
-In hash form you can also specify how the title of a column is aligned
-with its body.  To do this, you specify the keyword C<align_title> with
-C<left>, C<right> or C<center>.  Other alignment specifications are not
-valid here.  The default is C<left>.
-
-C<align_title> also specifies how the lines of a multiline title are
-aligned among themselves.  If you want a different alignment, you
-can specify it with the key C<align_title_lines>.  Again, only C<left>,
-C<right> or C<center> are allowed.
-
-Do not put other keys than those mentioned above (I<title>, I<align>,
-I<align_title>, I<align_title_lines>, and I<sample>) into a hash that
-specifies a column.  Most would be ignored, but some would confuse the
-interpreter (in particular, I<is_sep> has to be avoided).
-
-=item Separators as strings
-
-A separator must be given as a reference to a string (often a literal,
-like C<\' | '>), any string that is given directly describes a column.
-
-It is usually just a (short) string that will be printed between
-table columns on all table lines instead of the default single
-blank.  If you specify two separators (on two lines), the first one
-will be used in the title and the other in the body of the table.
-
-=item Separators as Hashes
-
-The hash representation of a separator has the format
-
-    {
-        is_sep => 1,
-        title  => $title,
-        body   => $body,
-    }
-
-$title is the separator to be used in the title area and $body
-the one for the body.  If only one is given, the other is used for
-both.  If none is given, a blank is used.  If one is shorter than
-the other, it is blank filled on the right.
-
-The value of C<is_sep> must be set to a true value, this is the
-distinguishing feature of a separator.
-
-=back
-
-=head2 Alignment
-
-The original documentation to L<Text::Aligner> contains all the details
-on alignment specification, but here is the rundown:
-
-The possible alignment specifications are I<left>, I<right>, I<center>,
-I<num> and I<point> (which are synonyms), and I<auto>.  The first
-three explain themselves.
-
-I<num> (and I<point>) align the decimal point in the data, which is
-assumed to the right if none is present.  Strings that aren't
-numbers are treated the same way, that is, they appear aligned
-with the integers unless they contain a ".".  Instead of the
-decimal point ".", you can also specify any other string in
-the form I<num(,)>, for instance.  The string in parentheses
-is aligned in the data.  The synonym I<point> for I<num> may be
-more appropriate in contexts that deal with arbitrary
-strings, as in I<point(=E<gt>)> (which might be used to align certain
-bits of Perl code).
-
-I<regex alignment> is a more sophisticated form of point alignment.
-If you specify a regular expression, as delivered by C<qr//>, the start
-of the match is used as the alignment point.  If the regex contains
-capturing parentheses, the last submatch counts.  [The usefulness of
-this feature is under consideration.]
-
-I<auto> alignment combines numeric alignment with left alignment.
-Data items that look like numbers, and those that don't, form two
-virtual columns and are aligned accordingly: C<num> for numbers and
-C<left> for other strings.  These columns are left-aligned with
-each other (i.e. the narrower one is blank-filled) to form the 
-final alignment.
-
-This way, a column that happens to have only numbers in the data gets
-I<num> alignment, a column with no numbers appears I<left>-aligned,
-and mixed data is presented in a reasonable way.
-
-=head2 Column Selection
-
-Besides creating tables from scratch, they can be created by
-selecting columns from an existing table.  Tables created this
-way contain the data from the columns they were built from.
-
-This is done by specifying the columns to select by their index
-(where negative indices count backward from the last column).
-The same column can be selected more than once and the sequence
-of columns can be arbitrarily changed.  Separators don't travel
-with columns, but can be specified between the columns at selection
-time.
-
-You can make the selection of one or more columns dependent on
-the data content of one of them.  If you specify some of the columns
-in angle brackets [...], the whole group is only included in the
-selection if the first column in the group contains any data that
-evaluates to boolean true.  That way you can de-select parts of a
-table if it contains no interesting data.  Any column separators
-given in brackets are selected or deselected along with the rest
-of it.
-
-=head1 PUBLIC METHODS
-
-=head2 Table Creation
-
-=over 4
-
-=item new()
-
-    my $tb = Text::Table->new( $column, ... );
-
-creates a table with the columns specified.  A column can be proper column
-which contains and displays data, or a separator which tells how to fill
-the space between columns.  The format of the parameters is described under
-L<"Column Specification">. Specifying an invalid alignment for a column
-results in a warning if these are allowed.
-
-If no columns are specified, the number of columns is taken from the first
-line of data added to the table.  The effect is as if you had specified
-C<Text::Table-E<gt>new( ( '') x $n)>, where C<$n> is the number of
-columns.
-
-=item select()
-
-    my $sub = $tb->select( $column, ...);
-
-creates a table from the listed columns of the table $tb, including
-the data.  Columns are specified as integer indices which refer to
-the data columns of $tb.  Columns can be repeated and specified in any
-order.  Negative indices count from the last column.  If an invalid
-index is specified, a warning is issued, if allowed.
-
-As with L<"new()">, separators can be interspersed among the column
-indices and will be used between the columns of the new table.
-
-If you enclose some of the arguments (column indices or separators) in
-angle brackets C<[...]> (technically, you specify them inside an
-arrayref), they form a group for conditional selection.  The group is
-only included in the resulting table if the first actual column inside
-the group contains any data that evaluate to a boolean true.  This way
-you can exclude groups of columns that wouldn't contribute anything
-interesting.  Note that separators are selected and de-selected with
-their group.  That way, more than one separator can appear between
-adjacent columns.  They don't add up, but only the rightmost separator
-is used.  A group that contains only separators is never selected.
-[Another feature whose usefulness is under consideration.]
-
-=back
-
-=head2 Status Information
-
-=over 4
-
-=item n_cols()
-
-    $tb->n_cols
-
-returns the number of columns in the table.
-
-=item width()
-
-    $tb->width
-
-returns the width (in characters) of the table.  All table lines have
-this length (not counting a final "\n" in the line), as well as the
-separator lines returned by $tb->rule() and $b->body_rule().
-The width of a table can potentially be influenced by any data item
-in it.
-
-=item height()
-
-    $tb->height
-
-returns the total number of lines in a table, including title lines
-and body lines. For orthogonality, the synonym table_height() also
-exists.
-
-=item title_height()
-
-    $tb->title_height
-
-returns the number of title lines in a table.
-
-=item body_height()
-
-    $tb->body_height
-
-returns the number of lines in the table body.
-
-=item colrange()
-
-    $tb->colrange( $i)
-
-returns the start position and width of the $i-th column (counting from 0)
-of the table.  If $i is negative, counts from the end of the table.  If $i
-is larger than the greatest column index, an imaginary column of width 0
-is assumed right of the table.
-
-=back
-
-=head2 Data Loading
-
-=over 4
-
-=item add()
-
-    $tb->add( $col1, ..., $colN)
-
-adds a data line to the table, returns the table.
-
-C<$col1>, ..., C<$colN> are scalars that
-correspond to the table columns.  Undefined entries are converted to '',
-and extra data beyond the number of table columns is ignored.
-
-Data entries can be multi-line strings.  The partial strings all go into
-the same column.  The corresponding fields of other columns remain empty
-unless there is another multi-line entry in that column that fills the
-fieds.  Adding a line with multi-line entries is equivalent to adding
-multiple lines.
-
-Every call to C<add()> increases the body height of the table by the
-number of effective lines, one in the absence of multiline entries.
-
-=item load()
-
-    $tb->load( $line, ...)
-
-loads the data lines given into the table, returns the table.
-
-Every argument to C<load()> represents a data line to be added to the
-table.  The line can be given as an array(ref) containing the data
-items, or as a string, which is split on whitespace to retrieve the
-data.  If an undefined argument is given, it is treated as an
-empty line.
-
-=item clear()
-
-    $tb->clear;
-
-deletes all data from the table and resets it to the state after
-creation.  Returns the table.  The body height of a table is 0 after
-C<clear()>.
-
-=back
-
-=head2 Table Output
-
-The three methods C<table()>, C<title()>, and C<body()> are very similar.
-They access different parts of the printable output lines of a table with
-similar methods.  The details are described with the C<table()> method.
-
-=over 4
-
-=item table()
-
-The C<table()> method returns lines from the entire table, starting
-with the first title line and ending with the last body line.
-
-In array context, the lines are returned separately, in scalar context
-they are joined together in a single string.
-
-    my @lines = $tb->table;
-    my $line  = $tb->table( $line_number);
-    my @lines = $tb->table( $line_number, $n);
-
-The first call returns all the lines in the table.  The second call
-returns one line given by $line_number.  The third call returns $n
-lines, starting with $line_number.  If $line_number is negative, it
-counts from the end of the array.  Unlike the C<select()> method,
-C<table()> (and its sister methods C<title()> and C<body()>) is
-protected against large negative line numbers, it truncates the
-range described by $line_number and $n to the existing lines.  If
-$n is 0 or negative, no lines are returned (an empty string in scalar
-context).
-
-=item title()
-
-Returns lines from the title area of a table, where the column titles
-are rendered.  Parameters and response to context are as with C<table()>,
-but no lines are returned from outside the title area.
-
-=item body()
-
-Returns lines from the body area of a table, that is the part where
-the data content is rendered, so that $tb->body( 0) is the first data
-line.  Parameters and response to context are as with C<table()>.
-
-=item rule()
-
-    $tb->rule;
-    $tb->rule( $char);
-    $tb->rule( $char, $char1);
-
-Returns a rule for the table.
-
-A rule is a line of table width that can be used between table lines
-to provide visual horizontal divisions, much like column separators
-provide vertical visual divisions.  In its basic form (returned by the
-first call) it looks like a table line with no data, hence a blank
-line except for the non-blank parts of any column-separators.  If
-one character is specified (the second call), it replaces the blanks
-in the first form, but non-blank column separators are retained.  If
-a second character is specified, it replaces the non-blank parts of
-the separators.  So specifying the same character twice gives a solid
-line of table width.  Another useful combo is C<$tb-E<lt>rule( '-', '+')>,
-together with separators that contain a single nonblank "|", for a
-popular representation of line crossings.
-
-C<rule()> uses the column separators for the title section if there
-is a difference.
-
-=item body_rule()
-
-C<body_rule()> works like <rule()>, except the rule is generated using
-the column separators for the table body.
-
-=back
-
-=head2 Warning Control
-
-=over 4
-
-=item warnings()
-
-    Text::Table->warnings();
-    Text::Table->warnings( 'on');
-    Text::Table->warnings( 'off'):
-    Text::Table->warnings( 'fatal'):
-
-The C<warnings()> method is used to control the appearance of warning
-messages while tables are manipulated.  When Text::Table starts, warnings
-are disabled.  The default action of C<warnings()> is to turn warnings
-on.  The other possible arguments are self-explanatory.  C<warnings()>
-can also be called as an object method (C<$tb-E<gt>warnings( ...)>).
-
-=back
-
-=head1 VERSION
-    
-This document pertains to Text::Table version 1.107
-
-=head1 BUGS
-
-=over 4
-
-=item o
-
-I<auto> alignment doesn't support alternative characters for the decimal
-point.  This is actually a bug in the underlying Text::Aligner by the
-same author.
-
-=back
-
-=head1 AUTHOR
-
-    Anno Siegel
-    CPAN ID: ANNO
-    siegel at zrz.tu-berlin.de
-    http://www.tu-berlin.de/~siegel
-
-=head1 COPYRIGHT
-
-Copyright (c) 2002 Anno Siegel. All rights reserved.
-This program is free software; you can redistribute
-it and/or modify it under the same terms as Perl itself.
-
-The full text of the license can be found in the
-LICENSE file included with this module.
-
-=head1 SEE ALSO
-
-Text::Aligner, perl(1).
-
-=cut
-
-1;
diff --git a/rboinc/monitoring/duplicate_late.sh b/rboinc/monitoring/duplicate_late.sh
deleted file mode 100644
index c3e9f0c..0000000
--- a/rboinc/monitoring/duplicate_late.sh
+++ /dev/null
@@ -1,43 +0,0 @@
-#/bin/bash
-
-# $Id$
-
-# Duplicates workunits which are late (sent time < 3 days ago),
-# state=INPROGRESS.  Does not duplicate WUs which have been already
-# duplicated. Duplicates get target_nresults=2 and priority += 1000.
-
-
-mysql="/usr/bin/mysql  -pxxxx DBNAME"
-
-echo "$0 running on"
-date
-
-echo "Going to duplicate the following workunits"
-
-
-$mysql <<EOF | column -t
-select workunit.name as wu_name,
-       result.id as resultid,
-       from_unixtime(result.sent_time) as sent_time
-from   workunit ,result  
-where  workunit.id=result.workunitid    
-   and workunit.target_nresults=1                                                                                                                                                               
-   and result.sent_time<unix_timestamp()- 2*3600*24                                                                                                                                             
-   and result.server_state=4     
-order by sent_time
-EOF
-
-$mysql <<EOF
-update workunit,result
-  set workunit.target_nresults=2,
-    workunit.transition_time=unix_timestamp(),
-    workunit.priority=workunit.priority+1000
- where
-    workunit.id=result.workunitid
-    and workunit.target_nresults=1
-    and result.sent_time<unix_timestamp()- 2*3600*24
-    and result.server_state=4
-EOF
-
-echo "Executed $0 with return code $?"
-
diff --git a/rboinc/monitoring/generate_error_table.sh b/rboinc/monitoring/generate_error_table.sh
deleted file mode 100644
index 6542151..0000000
--- a/rboinc/monitoring/generate_error_table.sh
+++ /dev/null
@@ -1,14 +0,0 @@
-#!/bin/bash
-
-# $Id$
-# Regenerate the error table hash. To be run upon BOINC update
-
-table=monitoring_errors_table.pm
-input=$HOME/BOINC/boinc/lib/error_numbers.h
-
-echo "our %error_table=();" > $table
-grep ERR_ $input | 
-   awk '{print "$error_table{" $3 "}=\"" $2 "\";"}' >> $table
-
-
-
diff --git a/rboinc/monitoring/monitoring_compute.sql b/rboinc/monitoring/monitoring_compute.sql
deleted file mode 100644
index 1e87326..0000000
--- a/rboinc/monitoring/monitoring_compute.sql
+++ /dev/null
@@ -1,102 +0,0 @@
--- $Id$
-
--- Should be run from crontab. It will add a row in the "monitoring"
--- table with the results, for later retrieval from the "dailyreport"
--- script.
-
-
-
--- monitoring interval to and from
-set @ut=unix_timestamp();
-set @uf=@ut-3600*24; -- could be the second to latest monitor_time
-
--- date when the current naming conventions started
--- for later wus it is possible to reliably extract scientist names
-set @begin=unix_timestamp('2009-06-01');
-
-
--- Create rows for today's monitoring
-insert into monitoring (monitor_time,scientist) 
-       select @ut monitor_time, mon_submitterof(name) sci from result 
-              where create_time>@begin
-	      group by sci;
-
-
--- in progress
-create temporary table tmp_inprogress 
-       select count(*) inpro, mon_submitterof(name) sci from result 
-              where server_state=4 
-              and   create_time>@begin
-	      group by sci;
-
-update monitoring,tmp_inprogress as tmp
-       set monitoring.cur_inprogress=tmp.inpro
-       where monitoring.monitor_time=@ut
-       and   monitoring.scientist=tmp.sci;
-
-drop table tmp_inprogress;
-
-
--- unsent
-create temporary table tmp_unsent
-       select count(*) unsent, mon_submitterof(name) sci from result 
-              where server_state=2 
-              and   create_time>@begin
-	      group by sci;
-
-update monitoring,tmp_unsent as tmp
-       set monitoring.cur_unsent=tmp.unsent
-       where monitoring.monitor_time=@ut
-       and   monitoring.scientist=tmp.sci;
-
-drop table tmp_unsent;
-
-
--- day_successful
-create temporary table tmp_suc
-       select count(*) suc, mon_submitterof(name) sci from result 
-       	      where  validate_state=1 
-	      and    received_time  between  @uf and @ut 
-       	      group by sci;
-
-update monitoring,tmp_suc as tmp
-       set monitoring.day_successful=tmp.suc
-       where monitoring.monitor_time=@ut
-       and   monitoring.scientist=tmp.sci;
-
-drop table tmp_suc;
-
-
-
-
--- day_unsuccessful
-create temporary table tmp_unsuc
-       select count(*) unsuc, mon_submitterof(name) sci from result 
-       	      where  validate_state=2
-	      and    received_time  between  @uf and @ut 
-       	      group by sci;
-
-update monitoring,tmp_unsuc as tmp
-       set monitoring.day_unsuccessful=tmp.unsuc
-       where monitoring.monitor_time=@ut
-       and   monitoring.scientist=tmp.sci;
-
-drop table tmp_unsuc;
-
-
-
--- day_credits
-create temporary table tmp_cred
-       select sum(granted_credit) credits, mon_submitterof(name) sci from result 
-       	      where  validate_state=1
-       	      and    received_time  between  @uf and @ut 
-       	      group by sci;
-
-update monitoring,tmp_cred as tmp
-       set monitoring.day_credits=tmp.credits
-       where monitoring.monitor_time=@ut
-       and   monitoring.scientist=tmp.sci;
-
-drop table tmp_cred;
-
-
diff --git a/rboinc/monitoring/monitoring_cron.sh b/rboinc/monitoring/monitoring_cron.sh
deleted file mode 100644
index 11bae5f..0000000
--- a/rboinc/monitoring/monitoring_cron.sh
+++ /dev/null
@@ -1,250 +0,0 @@
-#!/bin/sh
-
-# This script should be run under cron. It 
-# (1) re-generates the statistics
-# (2) produces the daily report
-# (3) mails it to the list below
-
-# 0 0 * * * bash /home/ps3grid/remote/monitoring/monitoring_cron.sh
-
-# $Id$
-
-mon_dir=  PATH TO MONITOR DIR
-mysql="/usr/bin/mysql  -pPASSWORD DB_NAME"
-workflow_results_dir= PATH TO WORKFLOW_RESULTS
-
-mailto="SPACE-SEPARATED LIST OF EMAILS"
-
-
-
-# End user serviceable parts
-cd $mon_dir
-
-# Compute the statistics
-$mysql < monitoring_compute.sql
-
-
-# Tmp file where to make the report
-tmpfile=/tmp/monitoring_report.$$
-touch $tmpfile
-
-
-
-# ........................................
-# Generate begin
-echo "== Report begin ==" >> $tmpfile
-date >> $tmpfile
-
-
-
-# ........................................
-# Per-user  summary
-echo " " >> $tmpfile
-echo " " >> $tmpfile
-echo "== Per-user summary ==" >> $tmpfile
-$mysql <<EOF | column -t >>$tmpfile
-select scientist,
-       cur_inprogress    as sent,
-       cur_unsent        as unsent,
-       day_successful    as day_suc,
-       day_unsuccessful  as day_unsuc,
-       day_credits
-  from monitoring 
- where monitor_time = 
-	(select max(monitor_time) from monitoring);
-EOF
-
-
-# ........................................
-# Per-user, per-error breakdown
-echo " " >> $tmpfile
-echo " " >> $tmpfile
-echo "== Per-user, per-error breakdown ==" >> $tmpfile
-/usr/bin/perl monitoring_errors.pl >> $tmpfile
-
-
-
-
-# ........................................
-# Cancelled due to too many errors
-echo " " >> $tmpfile
-echo " " >> $tmpfile
-echo "== Chains failing due to too many errors in the last 24 hours ==" >> $tmpfile
-$mysql <<EOF | column -t >>$tmpfile
-select mon_wuname(name) as in_group,
-       count(*) as how_many 
-  from workunit 
- where (error_mask & 2) = 2 
-   and mod_time > now() - interval 1 day
- group by in_group;
-EOF
-
-
-
-
-
-# ........................................
-# Per-group  summary
-echo " " >> $tmpfile
-echo " " >> $tmpfile
-echo "== Per-group summary (in progress only) ==" >> $tmpfile
-$mysql <<EOF | sed s/NULL/-/g | column -t >>$tmpfile
-  SET @ut=unix_timestamp();
-  SET @uf=@ut-3600*24;
-  select  t_inprogress.n as group_name,
-	  t_inprogress.c as sent,
-	  t_unsent.c     as unsent,
-	  t_success.c    as ok, 
-	  t_clienterror.c as fail,
-          t_severe.c     as sev,
-          round(100*t_severe.c/t_success.c) as 's%'
-  from ( 
-	 select mon_wuname(name) as n, count(*) as c from result
-	  where server_state=4  
-	  group by n
-  ) as t_inprogress 
-  left join (
-	 select mon_wuname(name) as n, count(*) as c from result 
-	  where server_state=2  
-	  group by n
-  ) as t_unsent on t_inprogress.n=t_unsent.n 
-  left join (
-	 select mon_wuname(name) as n, count(*) as c from result 
-	  where outcome=1 
-	    and received_time  between  @uf and @ut 
-	  group by n
-  ) as t_success on t_inprogress.n=t_success.n
-  left join (
-	 select mon_wuname(name) as n, count(*) as c from result 
-	  where outcome=3 
-	    and received_time  between  @uf and @ut 
-	  group by n
-  ) as t_clienterror on t_inprogress.n=t_clienterror.n
-  left join (
-         select mon_wuname(name) as n, count(*) as c from result
-          where outcome=3
-            and elapsed_time>300
-            and received_time  between at uf and @ut
-          group by n
-  ) as t_severe on t_inprogress.n=t_severe.n
-EOF
-cat >> $tmpfile <<EOF
-
-Legend (counts over the last 24h) 
-   ok: successful completion
- fail: client error 
-  sev: client error, ran for > 5 min
-   s%: % of severe failures (sev/ok)
-EOF
-
-
-
-# ........................................
-# WU turnaround time
-echo " " >> $tmpfile
-echo " " >> $tmpfile
-echo "== Turnaround time of today's WUs (create-canonical received within X days) ==" >> $tmpfile
-$mysql <<EOF | column -t >>$tmpfile
-select if(ceil((r.received_time-w.create_time)/3600/24)<=6,
-          ceil((r.received_time-w.create_time)/3600/24),
-          '>6') as turnaround,
-       count(*)
-  from workunit w,result r 
- where canonical_resultid<>0 
-   and canonical_resultid=r.id 
-   and received_time > unix_timestamp()-3600*24
- group by turnaround
-EOF
-
-
-# ........................................
-# Results turnaround time
-echo " " >> $tmpfile
-echo " " >> $tmpfile
-echo "== Turnaround time of today's results (sent-received within X days) ==" >> $tmpfile
-$mysql <<EOF | column -t >>$tmpfile
-select if(ceil((received_time-sent_time)/3600/24)<=6,
-          ceil((received_time-sent_time)/3600/24),
-          '>6')  as turnaround, count(*) 
-   from     result 
-   where    outcome=1 
-   and      received_time > unix_timestamp()-3600*24
-   group by turnaround
-EOF
-
-
-
-# ........................................
-# To be duplicated
-echo " " >> $tmpfile
-echo " " >> $tmpfile
-echo "== Late WUs (2d) to be duplicated ==" >> $tmpfile
-$mysql <<EOF | column -t >>$tmpfile
-select  mon_wuname(workunit.name) as group_name, 
-	count(*) as count, 
-	round(avg(workunit.priority)) as w_pri, 
-	round(avg(result.priority)) as r_pri,
-	round(avg(datediff(now(),from_unixtime(result.sent_time))),1) as sent_age,
-	round(avg(datediff(now(),from_unixtime(result.create_time))),1) as cre_age
-   from     workunit,result  
-   where    workunit.id=result.workunitid
-   and      workunit.target_nresults=1
-   and      result.sent_time<unix_timestamp()- 2*3600*24
-   and      result.server_state=4
-   group by group_name
-EOF
-cat >> $tmpfile <<EOF
-
-Legend (counts over the last 24h) 
-   count: no. of results sent before 3 days ago
-   w_pri: average workunit priority
-   r_pri: average result priority
-sent_age: average days elapsed since result sent
- cre_age: average days elapsed since result created
-EOF
-
-
-
-
-
-
-# ........................................
-# Disk occupation
-echo " " >> $tmpfile
-echo " " >> $tmpfile
-echo "== Disk occupation per group ==" >> $tmpfile
-cd $workflow_results_dir
-du -sch * >> $tmpfile
-cd - > /dev/null
-
-
-# ........................................
-# Free disk space
-echo " " >> $tmpfile
-echo " " >> $tmpfile
-echo "== Disk space availability ==" >> $tmpfile
-df -h >> $tmpfile
-
-
-
-
-
-
-# ........................................
-# Generate end
-echo " " >> $tmpfile
-echo " " >> $tmpfile
-echo "== Report end ==" >> $tmpfile
-date >> $tmpfile
-
-
-
-# Mail the result in HTML
-(echo "<html><body><pre>";
- cat $tmpfile;
- echo "</pre></body></html>")|
-mutt -e 'set content_type="text/html"' \
-     -s "GPUGRID monitoring report" $mailto
-
-# Remove tmp
-rm $tmpfile
diff --git a/rboinc/monitoring/monitoring_errors.pl b/rboinc/monitoring/monitoring_errors.pl
deleted file mode 100644
index fe43d8e..0000000
--- a/rboinc/monitoring/monitoring_errors.pl
+++ /dev/null
@@ -1,94 +0,0 @@
-#!/usr/bin/perl 
-
-# $Id$
-
-# Script to generate the per-error per-user pivot  report
-
-use strict;
-use warnings;
-use Text::Table;
-use DBI;
-use monitoring_errors_table;
-
-my $dbuser="DB_USER";
-my $dbpass="DB_PASSWORD";
-
-# List of errors to monitor
-my @tomon=(-198,-197,-233,-186,-226,-185,-177,-187,1,2,3);
-
-
-
-
-## End user-serviceable parts
-
-our %error_table;
-
-my $dbh = DBI->connect('DBI:mysql:DB_NAME', $dbuser, $dbpass
-	           ) || die "Could not connect to database: $DBI::errstr";
-
-
-
-# Generate a table of errors in the last 24 h
-# in principle, the time intervals could be selected as 
-# SELECT distinct monitor_time t FROM monitoring m order by t desc limit 1,1
-# i.e. the second-to-last monitoring time
-
-$dbh->do('set @ut=unix_timestamp();') || 
-    die "Query error: $DBI::errstr";
-$dbh->do('set @uf=@ut-3600*24;') ||
-    die "Query error: $DBI::errstr";
-
-my $sql = <<'EOF';
-    SELECT mon_submitterof(name) sci, exit_status
-    FROM   result 
-    WHERE  outcome=3 
-    AND    received_time BETWEEN @uf and @ut;
-EOF
-
-# $sql='select @uf, at ut';
-
-my $st=$dbh->prepare($sql);
-$st->execute();
-
-
-
-# Initialize the table of descriptions of "interesting" errors
-my $colsr={other=>"(Any other exit code)"};
-foreach my $e (@tomon) {
-    my $t=$error_table{$e} || "(Exit code by app)";
-    $t=~s/^ERR_//;
-    $colsr->{$e}=$t;
-}
-
-
-# Pivot table
-my $data={};
-while(my @res=$st->fetchrow_array()) {
-    my ($sci,$err)=@res;
-    if($colsr->{$err}) {	# interesting?
-	$data->{$sci}->{$err}++;
-    } else {			# otherwise
-	$data->{$sci}->{other}++;
-    }
-}
-
-# List of scientists: sort keys %$data
-# List of errors:     sort keys %$colsr
-
-# Print table header 1
-my @header=("Code","Error",sort keys %$data);
-my $table = Text::Table->new( @header );
-
-
-# Table contents
-foreach my $col (sort keys %$colsr ) {
-    my @body=($col,$colsr->{$col});
-    foreach my $sci (sort keys %$data) {
-	my $n=$data->{$sci}->{$col} || 0;
-	push @body,$n;
-    }
-    $table->add(@body);
-}
-
-print $table;
-
diff --git a/rboinc/monitoring/monitoring_errors_table.pm b/rboinc/monitoring/monitoring_errors_table.pm
deleted file mode 100644
index 9544538..0000000
--- a/rboinc/monitoring/monitoring_errors_table.pm
+++ /dev/null
@@ -1,128 +0,0 @@
-our %error_table=();
-$error_table{-100}="ERR_SELECT";
-$error_table{-101}="ERR_MALLOC";
-$error_table{-102}="ERR_READ";
-$error_table{-103}="ERR_WRITE";
-$error_table{-104}="ERR_FREAD";
-$error_table{-105}="ERR_FWRITE";
-$error_table{-106}="ERR_IO";
-$error_table{-107}="ERR_CONNECT";
-$error_table{-108}="ERR_FOPEN";
-$error_table{-109}="ERR_RENAME";
-$error_table{-110}="ERR_UNLINK";
-$error_table{-111}="ERR_OPENDIR";
-$error_table{-112}="ERR_XML_PARSE";
-$error_table{-113}="ERR_GETHOSTBYNAME";
-$error_table{-114}="ERR_GIVEUP_DOWNLOAD";
-$error_table{-115}="ERR_GIVEUP_UPLOAD";
-$error_table{-116}="ERR_NULL";
-$error_table{-117}="ERR_NEG";
-$error_table{-118}="ERR_BUFFER_OVERFLOW";
-$error_table{-119}="ERR_MD5_FAILED";
-$error_table{-120}="ERR_RSA_FAILED";
-$error_table{-121}="ERR_OPEN";
-$error_table{-122}="ERR_DUP2";
-$error_table{-123}="ERR_NO_SIGNATURE";
-$error_table{-124}="ERR_THREAD";
-$error_table{-125}="ERR_SIGNAL_CATCH";
-$error_table{-127}="ERR_UPLOAD_TRANSIENT";
-$error_table{-128}="ERR_UPLOAD_PERMANENT";
-$error_table{-129}="ERR_IDLE_PERIOD";
-$error_table{-130}="ERR_ALREADY_ATTACHED";
-$error_table{-131}="ERR_FILE_TOO_BIG";
-$error_table{-132}="ERR_GETRUSAGE";
-$error_table{-133}="ERR_BENCHMARK_FAILED";
-$error_table{-134}="ERR_BAD_HEX_FORMAT";
-$error_table{-136}="ERR_DB_NOT_FOUND";
-$error_table{-137}="ERR_DB_NOT_UNIQUE";
-$error_table{-138}="ERR_DB_CANT_CONNECT";
-$error_table{-139}="ERR_GETS";
-$error_table{-140}="ERR_SCANF";
-$error_table{-143}="ERR_READDIR";
-$error_table{-144}="ERR_SHMGET";
-$error_table{-145}="ERR_SHMCTL";
-$error_table{-146}="ERR_SHMAT";
-$error_table{-147}="ERR_FORK";
-$error_table{-148}="ERR_EXEC";
-$error_table{-149}="ERR_NOT_EXITED";
-$error_table{-150}="ERR_NOT_IMPLEMENTED";
-$error_table{-151}="ERR_GETHOSTNAME";
-$error_table{-152}="ERR_NETOPEN";
-$error_table{-153}="ERR_SOCKET";
-$error_table{-154}="ERR_FCNTL";
-$error_table{-155}="ERR_AUTHENTICATOR";
-$error_table{-156}="ERR_SCHED_SHMEM";
-$error_table{-157}="ERR_ASYNCSELECT";
-$error_table{-158}="ERR_BAD_RESULT_STATE";
-$error_table{-159}="ERR_DB_CANT_INIT";
-$error_table{-160}="ERR_NOT_UNIQUE";
-$error_table{-161}="ERR_NOT_FOUND";
-$error_table{-162}="ERR_NO_EXIT_STATUS";
-$error_table{-163}="ERR_FILE_MISSING";
-$error_table{-165}="ERR_SEMGET";
-$error_table{-166}="ERR_SEMCTL";
-$error_table{-167}="ERR_SEMOP";
-$error_table{-168}="ERR_FTOK";
-$error_table{-169}="ERR_SOCKS_UNKNOWN_FAILURE";
-$error_table{-170}="ERR_SOCKS_REQUEST_FAILED";
-$error_table{-171}="ERR_SOCKS_BAD_USER_PASS";
-$error_table{-172}="ERR_SOCKS_UNKNOWN_SERVER_VERSION";
-$error_table{-173}="ERR_SOCKS_UNSUPPORTED";
-$error_table{-174}="ERR_SOCKS_CANT_REACH_HOST";
-$error_table{-175}="ERR_SOCKS_CONN_REFUSED";
-$error_table{-176}="ERR_TIMER_INIT";
-$error_table{-177}="ERR_RSC_LIMIT_EXCEEDED";
-$error_table{-178}="ERR_INVALID_PARAM";
-$error_table{-179}="ERR_SIGNAL_OP";
-$error_table{-180}="ERR_BIND";
-$error_table{-181}="ERR_LISTEN";
-$error_table{-182}="ERR_TIMEOUT";
-$error_table{-183}="ERR_PROJECT_DOWN";
-$error_table{-184}="ERR_HTTP_ERROR";
-$error_table{-185}="ERR_RESULT_START";
-$error_table{-186}="ERR_RESULT_DOWNLOAD";
-$error_table{-187}="ERR_RESULT_UPLOAD";
-$error_table{-189}="ERR_INVALID_URL";
-$error_table{-190}="ERR_MAJOR_VERSION";
-$error_table{-191}="ERR_NO_OPTION";
-$error_table{-192}="ERR_MKDIR";
-$error_table{-193}="ERR_INVALID_EVENT";
-$error_table{-194}="ERR_ALREADY_RUNNING";
-$error_table{-195}="ERR_NO_APP_VERSION";
-$error_table{-196}="ERR_WU_USER_RULE";
-$error_table{-197}="ERR_ABORTED_VIA_GUI";
-$error_table{-198}="ERR_INSUFFICIENT_RESOURCE";
-$error_table{-199}="ERR_RETRY";
-$error_table{-200}="ERR_WRONG_SIZE";
-$error_table{-201}="ERR_USER_PERMISSION";
-$error_table{-202}="ERR_SHMEM_NAME";
-$error_table{-203}="ERR_NO_NETWORK_CONNECTION";
-$error_table{-204}="ERR_IN_PROGRESS";
-$error_table{-205}="ERR_BAD_EMAIL_ADDR";
-$error_table{-206}="ERR_BAD_PASSWD";
-$error_table{-207}="ERR_NONUNIQUE_EMAIL";
-$error_table{-208}="ERR_ACCT_CREATION_DISABLED";
-$error_table{-209}="ERR_ATTACH_FAIL_INIT";
-$error_table{-210}="ERR_ATTACH_FAIL_DOWNLOAD";
-$error_table{-211}="ERR_ATTACH_FAIL_PARSE";
-$error_table{-212}="ERR_ATTACH_FAIL_BAD_KEY";
-$error_table{-213}="ERR_ATTACH_FAIL_FILE_WRITE";
-$error_table{-214}="ERR_ATTACH_FAIL_SERVER_ERROR";
-$error_table{-215}="ERR_SIGNING_KEY";
-$error_table{-216}="ERR_FFLUSH";
-$error_table{-217}="ERR_FSYNC";
-$error_table{-218}="ERR_TRUNCATE";
-$error_table{-219}="ERR_WRONG_URL";
-$error_table{-220}="ERR_DUP_NAME";
-$error_table{-221}="ERR_ABORTED_BY_PROJECT";
-$error_table{-222}="ERR_GETGRNAM";
-$error_table{-223}="ERR_CHOWN";
-$error_table{-224}="ERR_FILE_NOT_FOUND";
-$error_table{-225}="ERR_BAD_FILENAME";
-$error_table{-226}="ERR_TOO_MANY_EXITS";
-$error_table{-227}="ERR_RMDIR";
-$error_table{-229}="ERR_SYMLINK";
-$error_table{-230}="ERR_DB_CONN_LOST";
-$error_table{-231}="ERR_CRYPTO";
-$error_table{-232}="ERR_ABORTED_ON_EXIT";
-$error_table{-233}="ERR_UNSTARTED_LATE";
diff --git a/rboinc/monitoring/monitoring_functions.sql b/rboinc/monitoring/monitoring_functions.sql
deleted file mode 100644
index 7b4f1a8..0000000
--- a/rboinc/monitoring/monitoring_functions.sql
+++ /dev/null
@@ -1,104 +0,0 @@
--- $Id$
--- Boinc Monitoring stored procedures
--- Only re-run this file upon changes
-
-
-DELIMITER $$
-
--- Extract a delimited subset of a given string 
--- Arguments: string, from substring, to substring (deprecated)
-DROP FUNCTION IF EXISTS mon_xt  
-$$ 
-CREATE FUNCTION mon_xt (s blob,f varchar(100), t varchar(100)) RETURNS varchar(1000) deterministic no sql
-BEGIN
-	return substring_index(substring_index(s,f,-1),t,1);
-END 
-$$
-
-
--- Split the given string at delimiter del, return the idx-th piece (1-based)
--- Arguments: string, delimiter, index
-DROP FUNCTION IF EXISTS mon_split_index
-$$ 
-CREATE FUNCTION mon_split_index (s blob, del varchar(10), idx int) RETURNS varchar(1000) deterministic no sql
-BEGIN
-	return substring_index(substring_index(s,del,idx),del,-1);
-END
-$$
-
-
--- Extract the name from a result or wu-- Argument: wu name                                  
--- 1-OTTO_pYIpYV_1805-2-10-RND1289_0 ->  OTTO_pYIpYV_1805
-DROP FUNCTION IF EXISTS mon_wuname
-$$   
-CREATE FUNCTION mon_wuname (s varchar(1000)) RETURNS varchar(1000) deterministic no sql
-BEGIN
-	return mon_split_index(s,"-",2);
-END 
-$$
-
-
-
--- Extract the step from a result or wu-- Argument: wu name                                  
--- 1-OTTO_pYIpYV_1805-2-10-RND1289_0 ->  2
-DROP FUNCTION IF EXISTS mon_stepof
-$$   
-CREATE FUNCTION mon_stepof (s varchar(1000)) RETURNS varchar(1000) deterministic no sql
-BEGIN
-	return mon_split_index(s,"-",3);
-END 
-$$
-
-
--- Extract the sumbitter name from a result or wu
--- Argument: wu name
--- 1-OTTO_pYIpYV_1805-2-10-RND1289_0 ->  OTTO
-DROP FUNCTION IF EXISTS mon_submitterof
-$$
-CREATE FUNCTION mon_submitterof (s varchar(1000)) RETURNS varchar(1000) deterministic no sql
-BEGIN
-	return mon_split_index(mon_wuname(s),"_",1);
-END
-$$
-
-
--- Extract the group name from a result or wu                                  
--- Argument: wu name                                  
--- 1-OTTO_pYIpYV_1805-2-10-RND1289_0 ->  pYIpYV_1805
-DROP FUNCTION IF EXISTS mon_groupof  
-$$
-CREATE FUNCTION mon_groupof (s varchar(1000)) RETURNS varchar(1000) deterministic no sql
-BEGIN
-	declare wn varchar(1000);
-        set wn=mon_wuname(s);
-        return substring(wn,1+instr(wn,'_'));
-END
-$$
-
-
-
--- Parse stderr to find the CUDA device used (GPUGRID-SPECIFIC)
--- Argument: the stderr text
-DROP FUNCTION IF EXISTS mon_cardof
-$$
-CREATE FUNCTION mon_cardof (str blob) returns varchar(1000) deterministic no sql
-BEGIN
-        declare bno int;
-        declare bname varchar(100);
-        declare bclock int;
-        declare bmem int;
-        declare bmproc int;
-        declare bcores int;
-        declare tmp varchar(100);
-        set bno=mon_xt(str,'Using device ','#');
-        set tmp=concat('Device ',bno,': ');
-        set bname=mon_xt(str,tmp,'#');
-        set bname=replace(bname,'"','');
-        set bname=replace(bname,'\r','');
-        set bname=replace(bname,'\n','');
-        return bname;
-END
-$$
-
-
-DELIMITER ;
diff --git a/rboinc/monitoring/monitoring_schema.sql b/rboinc/monitoring/monitoring_schema.sql
deleted file mode 100644
index 21146f0..0000000
--- a/rboinc/monitoring/monitoring_schema.sql
+++ /dev/null
@@ -1,29 +0,0 @@
--- $Id$
-
--- Boinc Monitoring schema and stored procedures
--- Re-running this file clears monitoring statistics
--- Only re-run this to add the monitoring mechanism to a plain boinc.
--- After this, re-run the monitoring_functions.sql script 
-
-
-
-drop table IF EXISTS monitoring ;
-
-create table monitoring (       
-	id              int(11)         not null auto_increment,
-	monitor_time    int(11)         not null,
-	mod_time        timestamp       NOT NULL 
-					default CURRENT_TIMESTAMP 
-					on update CURRENT_TIMESTAMP,
-	scientist        varchar(100), 
-	cur_inprogress   int(11),
-	cur_unsent       int(11),
-	day_successful   int(11),
-	day_unsuccessful int(11),
-	day_credits      int(11),
-	primary key (id),
-	unique key record (monitor_time,scientist),
-	key res_scientist (scientist)
-) ENGINE=InnoDB;
-
-
diff --git a/rboinc/monitoring/monitoring_status.sql b/rboinc/monitoring/monitoring_status.sql
deleted file mode 100644
index 1bf5bce..0000000
--- a/rboinc/monitoring/monitoring_status.sql
+++ /dev/null
@@ -1,167 +0,0 @@
--- $Id$
-
--- mon_status stored procedure. 
-
--- Monitoring for "gridstatus" operation. Returns currently running
--- WUs for a given user. Can be run on demand from the command line,
--- no cron is involved.
-
--- Input arguments: scientist name
--- Output: a resultset containing the current job statuses
-
-
-
-
-DELIMITER $$
-
-DROP PROCEDURE IF EXISTS mon_status$$
-CREATE PROCEDURE mon_status (in scientistname varchar(100))
-BEGIN
-
--- 
--- monitoring interval to and from
-set @ut=unix_timestamp();
-set @tfrom=@ut-30*3600*24;	-- 1 week
-
--- date when the current naming conventions started
--- for later wus it is possible to reliably extract scientist names
--- set @begin=unix_timestamp('2009-06-01');
-set @begin=@ut-30*3600*24;
-
-
-set @who=scientistname;
-
-drop table if  exists tmp_status;
-create temporary  table  tmp_status (
-	id              int(11)         not null auto_increment,
-	grp_sent      	timestamp null default null,
-	grp_name        varchar(100),
-	cur_unsent       int(11) ,
-	cur_inprogress   int(11) ,
-	per_successful   int(11) ,
-	per_unsuccessful int(11) ,
-	per_credits      int(11) ,
-	range_priority	varchar(11) ,
-	primary key (id),
-	unique key grp (grp_name)
-) ENGINE=InnoDB;
-
-
-
--- Create rows for today's monitoring
-insert into tmp_status (grp_name,grp_sent) 
-       select mon_groupof(name) agrp, from_unixtime(min(create_time)) from result 
-              where create_time>@begin
-	      and mon_submitterof(name) like @who
-	      group by agrp;
-
-
--- in progress
-create temporary table tmp_inprogress 
-       select count(*) inpro, mon_groupof(name) grp from result 
-              where server_state=4 
-              and   create_time>@begin
-	      and mon_submitterof(name) like @who
-	      group by grp;
-
-update tmp_status,tmp_inprogress as tmp
-       set tmp_status.cur_inprogress=tmp.inpro
-       where tmp_status.grp_name=grp;
-
-drop table tmp_inprogress;
-
-
-
-
--- unsent
-create temporary table tmp_uns 
-       select count(*) uns, mon_groupof(name) grp from result 
-              where server_state=2
-              and   create_time>@begin
-	      and mon_submitterof(name) like @who
-	      group by grp;
-
-update tmp_status,tmp_uns as tmp
-       set tmp_status.cur_unsent=tmp.uns
-       where tmp_status.grp_name=grp;
-
-drop table tmp_uns;
-
-
-
--- day success
-create temporary table tmp_suc
-       select count(*) suc, mon_groupof(name) grp from result 
-              where validate_state=1
-              and   received_time>@tfrom
-	      and mon_submitterof(name) like @who
-	      group by grp;
-
-update tmp_status,tmp_suc as tmp
-       set tmp_status.per_successful=tmp.suc
-       where tmp_status.grp_name=grp;
-
-drop table tmp_suc;
-
-
-
--- day success
-create temporary table tmp_uns
-       select count(*) uns, mon_groupof(name) grp from result 
-              where validate_state=2
-              and   received_time>@tfrom
-	      and mon_submitterof(name) like @who
-	      group by grp;
-
-update tmp_status,tmp_uns as tmp
-       set tmp_status.per_unsuccessful=tmp.uns
-       where tmp_status.grp_name=grp;
-
-drop table tmp_uns;
-
-
-
-
--- day credits
-create temporary table tmp_cr
-       select sum(granted_credit) credits, mon_groupof(name) grp from result 
-              where validate_state=1
-              and   received_time>@tfrom
-	      and mon_submitterof(name) like @who
-	      group by grp;
-
-update tmp_status,tmp_cr as tmp
-       set tmp_status.per_credits=tmp.credits
-       where tmp_status.grp_name=grp;
-
-drop table tmp_cr;
-
-
--- avg priority
-create temporary table tmp_pri
-       select concat(min(priority),'-',max(priority)) pr, mon_groupof(name) grp from workunit
-              where assimilate_state=0
-	      and mon_submitterof(name) like @who
-	      group by grp;
-
-update tmp_status,tmp_pri as tmp
-       set tmp_status.range_priority=tmp.pr
-       where tmp_status.grp_name=grp;
-
-drop table tmp_pri;
-
-
-
-select * from tmp_status order by grp_sent;
-
--- select grp_sent, grp_name, cur_unsent unsent, 
---        cur_inprogress in_prog, per_successful success,
---        per_unsuccessful unsuccess, per_credits credits,
---        range_priority priority
---        from tmp_status order by grp_sent;
-
-
-
-END$$
-
-DELIMITER ;
diff --git a/rboinc/notes.txt b/rboinc/notes.txt
deleted file mode 100644
index 577d617..0000000
--- a/rboinc/notes.txt
+++ /dev/null
@@ -1,2 +0,0 @@
-Remote job submission system for BOINC.  See:
-http://boinc.berkeley.edu/trac/wiki/RemoteJob
diff --git a/rboinc/server/boinc_authentication.pl b/rboinc/server/boinc_authentication.pl
deleted file mode 100644
index 2f07a43..0000000
--- a/rboinc/server/boinc_authentication.pl
+++ /dev/null
@@ -1,310 +0,0 @@
-#!/usr/bin/perl -w
-
-# $Id$
-
-
-=head1 NAME
-
-boinc_authentication - functions to authenticate an user with Boinc,
-and other miscellaneous helpers.
-
-=head1 SYNOPSIS
-
-    lookup_email(project_url,email)
-    lookup_email_password(project_url,email,password)
-
-=head1 DESCRIPTION
-
-Connects to a boinc project and checks if an user exists, or if a
-given username/password combination is valid. The boinc authenticator
-can also be used in lieu of the password. Passwords are never sent in
-clear text.
-
-=head1 AUTHOR
-
-Toni Giorgino
-
-=head1 COPYRIGHT
-
-This file is part of RemoteBOINC.
-Copyright (C) 2010 Toni Giorgino, Universitat Pompeu Fabra
-
-RemoteBOINC is free software; you can redistribute it and/or modify it
-under the terms of the GNU Lesser General Public License
-as published by the Free Software Foundation,
-either version 3 of the License, or (at your option) any later version.
-
-RemoteBOINC is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
-See the GNU Lesser General Public License for more details.
-
-You should have received a copy of the GNU Lesser General Public License
-along with BOINC.  If not, see <http://www.gnu.org/licenses/>.
-
-
-=cut
-
-
-
-use strict;
-
-use Digest::MD5  qw(md5 md5_hex md5_base64);
-use Error qw(:try);
-
-use LWP::Simple;
-use URI::Escape;
-use XML::Simple;
-
-use constant LOOKUP_ACCOUNT_PHP         => 'lookup_account.php';
-
-use vars qw($config);
-
-
-sub md5_file {
-    my $file = shift;
-    open(FILE, $file) or die 'Error file $file for md5: $!';
-    binmode(FILE);
-    my $md= Digest::MD5->new->addfile(*FILE)->hexdigest;
-    close FILE;
-    return $md;
-}
-
-
-
-sub lookup_email {
-    my $boinc_project_url=shift;
-    my $boinc_email=shift;
-
-    my $url=$boinc_project_url . "/" . LOOKUP_ACCOUNT_PHP;
-    my $query=$url."?email_addr=".uri_escape($boinc_email);
-    my $content=get($query);
-
-    die "Couldn't get it!" unless defined $content;
-    return $content;
-
-}
-
-
-sub lookup_email_password {
-    my $boinc_project_url=shift;
-    my $boinc_email=shift;
-    my $boinc_password=shift;
-
-    my $boinc_digesthash=md5_hex($boinc_password.$boinc_email);
-
-    my $url=$boinc_project_url . "/" . LOOKUP_ACCOUNT_PHP;
-    my $query=$url."?email_addr=".uri_escape($boinc_email).
-	"&passwd_hash=".uri_escape($boinc_digesthash);
-
-    my $content=get($query);
-
-    die "Couldn't get it!" unless defined $content;
-    return $content;
-}
-
-
-
-# Return an  human-readable answer, for testing
-
-sub voidAnswer {
-    my $response_header="Content-type: text/plain\n\n";
-    print  $response_header;
-    print "Remote boinc CGI is alive.\n";
-}
-
-
-
-# Return an xml-encoded failure code
-
-sub returnFailure {
-    my $xmlroot=shift;
-    my $reason=shift;
-    my $response_header="Content-type: text/plain\n\n";
-
-    my $r={};
-    $r->{Failure}={Reason=>$reason};
-
-    my $xr=XMLout($r, RootName => $xmlroot, AttrIndent => 1);
-
-    print $response_header;
-    print $xr;
-}
-
-
-
-# Returns false if tag contains forbidden chars, else true
-
-sub isTagValid {
-    my $tag=shift;
-    if($tag =~ /^[a-zA-Z0-9_]+$/) {
-	return 1;
-    } else {
-	return 0;
-    }
-}
-
-
-# Returns false if tag contains forbidden chars in user name, else true
-
-sub isUserValid {
-    my $tag=shift;
-    if($tag =~ /^[a-zA-Z0-9]+$/) {
-	return 1;
-    } else {
-	return 0;
-    }
-}
-
-
-sub isNameReserved {
-    my $name=shift;
-    my @res=("pool","process","process_stop");
-
-    foreach my $n (@res) {
-	if($name eq $n) {
-	    return(1);
-	}
-    }
-    return 0;
-}
-
-
-
-# Template-handling
-
-# Parse a template and return it as a hash
-sub parse_template {
-    my $tpl=shift;
-    
-    if(!isTagValid($tpl)) {
-	die "Invalid character in application request";
-    }
-
-    # Read the template's content
-    my $tfile=$config->{PROJECT_DIR}."/templates/";
-    $tfile=$tfile.$tpl;
-
-    open F,"<$tfile" or die "Error opening template: $!";
-    my @lines=<F>;
-    close F;
-    my $ttext=join "", at lines;
-    
-    # Add the root element, otherwise ill-formed
-    my $txml=XMLin("<opt>$ttext</opt>",
-		   ForceArray => ["file_ref"]);
-    return $txml;
-}
-
-
-# Parse the wu template and return it as an hash
-sub parse_wu_template {
-    my $tpl=shift;
-    return parse_template("rboinc_".$tpl."_wu");
-}
-
-# Parse the wu template and return it as an hash
-sub parse_result_template {
-    my $tpl=shift;
-    return parse_template("rboinc_".$tpl."_result");
-}
-
-
-
-
-
-# Convert the input list into an ORDERED array of hash refs.
-# Each hash ref contains info for an input file 
-sub build_input_files_list {
-    my $th=shift;
-    my $out=[];
-
-    foreach my $ir (@{$th->{workunit}->{file_ref}}) {
-	my $num=$ir->{file_number};
-	$out->[$num]=$ir;
-    }
-    
-    return $out;
-}
-
-
-
-# Build list of chained files, inverting links in the
-# results template
-sub build_chain_files_list {
-    my $th=shift;
-    my $out={};
-
-    foreach my $ir (@{$th->{file_info}}) {
-	my $name=(%{$ir->{name}})[0]; # this will become the new input
-	$name=~/[0-9]+$/;
-	my $num=$&;
-	my $chain=$ir->{rboinc}->{chain}; # at this slot
-	if($chain) {
-	    $out->{$chain}=$num;
-	}
-    }
-    
-    return $out;
-}
-
-# Build a fragment of bash script
-# applying the chain-rule replacements
-sub build_do_chain_bash_function {
-    my $th=shift;
-
-    my $clist=build_chain_files_list($th);
-
-    my $scr=<<'EOF';
-function do_chain {
-  iarray=($INPUT_LIST)
-EOF
-    
-    foreach my $in (sort keys %$clist) {
-	my $out=$clist->{$in};
-	$scr .= " iarray[$in]=\$1_$out\n";
-    }
-
-    $scr.=<<'EOF';
-  INPUT_LIST="${iarray[@]}"
-}
-EOF
-
-    return $scr;
-}
-
-
-
-
-
-
-# Parse result name and split into components 
-sub parseResultName {
-    my $n=shift;
-    my ($name,$user,$group,$step,$maxsteps,$rnd,$ext) = ($n=~/^(.+)-(.+)_(.+)-(.+)-(.+)-(.+)_(.+)$/);
-    my $r={
-	name => $name,
-	user => $user,
-	group => $group,
-	step => $step,
-	maxsteps => $maxsteps,
-	rnd => $rnd,
-	ext => $ext
-    };
-    return $r;
-}
-
-
-1;
-
-
-
-
-
-
-
-# References
-# http://snippets.dzone.com/posts/show/3163
-# http://boinc.berkeley.edu/trac/wiki/WebRpc#lookup_account
-#     project_url/lookup_account.php 
-# http://search.cpan.org/dist/libwww-perl/lib/HTTP/Request/Common.pm
diff --git a/rboinc/server/boinc_configuration.pl b/rboinc/server/boinc_configuration.pl
deleted file mode 100644
index 98648f1..0000000
--- a/rboinc/server/boinc_configuration.pl
+++ /dev/null
@@ -1,67 +0,0 @@
-# Site-specific configuration constants (used by the server side
-# component). 
-#
-# $Id$
-
-
-
-# This file is part of RemoteBOINC.
-# Copyright (C) 2010 Universitat Pompeu Fabra
-
-# RemoteBOINC is free software; you can redistribute it and/or modify it
-# under the terms of the GNU Lesser General Public License
-# as published by the Free Software Foundation,
-# either version 3 of the License, or (at your option) any later version.
-
-# RemoteBOINC is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
-# See the GNU Lesser General Public License for more details.
-
-# You should have received a copy of the GNU Lesser General Public License
-# along with BOINC.  If not, see <http://www.gnu.org/licenses/>.
-
-
-
-my $cgi="/home/boinc/toni/apache/cgi-bin";
-
-return {
-# Dav incoming directory, as seen by this script (path on server's
-# filesystem)
-    DAV_DIR  =>  "$cgi/../DAV",
-
-# Boinc's project dir, used for sumbission
-    PROJECT_DIR   =>  "/home/boinc/projects/LUNA",
-
-# Workflow_results directory, where the input and assimilator's output
-# files will go, and scripts will be launched.
-    WORKFLOW_DIR  =>  "/home/boinc/projects/LUNA/workflow_results",
-
-# DAV url as seen by the clients
-    DAV_URL  =>  "http://XXXXX:8383/DAV/",
-
-# Encodeinput parameters. Architecture will be appended at the end 
-# of executable name (x86_64 or i686).
-    ENCODE_EXECUTABLE => "$cgi/etc/encodeinput",
-    ENCODE_CODE => -1,
-
-
-# Directory for miscellaneous files (eg. defaults)
-    ETC_DIR => "$cgi/etc",
-
-# Minimum age for files to be removed during remote retrieval, in days
-# (possibly fractional). Should be at least the frequency with which
-# validator is run. CURRENTLY UNUSED.
-    REMOVE_MIN_AGE => 1./24,
-
-# Defaults if not specified - not under user control
-    DEFAULT_EMAIL => 'nobody at nil.es',
-
-# Defaults if not specified - under user control
-    DEFAULT_APP_NAME => 'acemd',
-    DEFAULT_NUMSTEPS => 1,
-    DEFAULT_PRIORITY => 1,
-
-
-};
-
diff --git a/rboinc/server/boinc_configuration_template.pl b/rboinc/server/boinc_configuration_template.pl
deleted file mode 100644
index bdee813..0000000
--- a/rboinc/server/boinc_configuration_template.pl
+++ /dev/null
@@ -1,69 +0,0 @@
-# Site-specific configuration constants (used by the server side
-# component). 
-#
-# $Id$
-
-
-# This file is part of RemoteBOINC.
-# Copyright (C) 2010 Universitat Pompeu Fabra
-
-# RemoteBOINC is free software; you can redistribute it and/or modify it
-# under the terms of the GNU Lesser General Public License
-# as published by the Free Software Foundation,
-# either version 3 of the License, or (at your option) any later version.
-
-# RemoteBOINC is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
-# See the GNU Lesser General Public License for more details.
-
-# You should have received a copy of the GNU Lesser General Public License
-# along with BOINC.  If not, see <http://www.gnu.org/licenses/>.
-
-
-my $cgi="";
-
-return {
-# Dav incoming directory, as seen by this script (path on server's
-# filesystem)
-    DAV_DIR  =>  "",
-
-# Boinc's project dir, used for sumbission
-    PROJECT_DIR   =>  "",
-
-# Workflow_results directory, where the input and assimilator's output
-# files will go, and scripts will be launched.
-    WORKFLOW_DIR  =>  "",
-
-# DAV url as seen by the clients
-    DAV_URL  =>  "",
-
-# Encodeinput parameters. Architecture will be appended at the end 
-# of executable name (x86_64 or i686).
-    ENCODE_EXECUTABLE => "$cgi/etc/encodeinput",
-    ENCODE_CODE => xxxxxxx,
-
-# Directory for miscellaneous files (eg. defaults)
-    ETC_DIR => "$cgi/etc",
-
-# Minimum age for files to be removed during remote retrieval, in days
-# (possibly fractional). Should be at least the frequency with which
-# validator is run (?)
-    REMOVE_MIN_AGE => 1./24,
-
-# Defaults if not specified - not under user control
-    DEFAULT_WU_TEMPLATE => 'std_md_wu',
-    DEFAULT_RESULT_TEMPLATE => 'std_md_result',
-    DEFAULT_EMAIL => 'nobody at nil.es',
-    DEFAULT_DELAY_BOUND => 5*24*3600,
-
-# Defaults if not specified - under user control
-    DEFAULT_APP_NAME => 'acemd',
-    DEFAULT_NUMSTEPS => 1,
-    DEFAULT_PRIORITY => 1,
-    DEFAULT_TARGET_NRESULTS => 1,
-    DEFAULT_MIN_QUORUM => 1,
-
-
-};
-
diff --git a/rboinc/server/boinc_retrieve_server.pl b/rboinc/server/boinc_retrieve_server.pl
deleted file mode 100755
index e3232ab..0000000
--- a/rboinc/server/boinc_retrieve_server.pl
+++ /dev/null
@@ -1,738 +0,0 @@
-#!/usr/bin/perl -w
-
-# $Id$
-
-# The remote-boinc server-side perl script. Should run as a CGI in an
-# Apache2 instance.
-
-=head1 NAME
-
-boinc_submit_server.pl - CGI for handling incoming remote
-    boinc submissions
-
-=head1 SYNOPSIS
-
-To be installed in Apache's cgi-bin directory
-
-=head1 DESCRIPTION
-
-This documentation is provisional.
-
-Currently receives GET requests with two arguments, "action" and
-"group".  The script authenticates the user, goes in the workflow
-directory, checks if the user owns the dir named "group". If so,
-generates a random sting, creates a dir with the said name in the DAV
-area, and therein creates links to all the files which can be
-downloaded. The CGI returns the random id name.
-
-=head1 AUTHOR
-
-Toni Giorgino
-
-=head1 COPYRIGHT
-
-This file is part of RemoteBOINC.
-
-Copyright (C) 2010 Toni Giorgino, Universitat Pompeu Fabra
-
-RemoteBOINC is free software; you can redistribute it and/or modify it
-under the terms of the GNU Lesser General Public License as published
-by the Free Software Foundation, either version 3 of the License, or
-(at your option) any later version.
-
-RemoteBOINC is distributed in the hope that it will be useful, but
-WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Lesser General Public License for more details.
-
-You should have received a copy of the GNU Lesser General Public
-License along with BOINC.  If not, see <http://www.gnu.org/licenses/>.
-
-
-=cut
-
-
-# ----------------
-
-# Prepend non-standard location for modules
-use lib qw(/home/boinc/toni/perl/lib);
-
-# Prepend location for support modules
-#use lib qw(/home/toni/work/RemoteBoincProject/server);
-
-
-# ----------------
-
-
-use strict;
-use CGI::Lite;			# parsing requests
-use CGI::Carp;  		# for error messages
-use XML::Simple;		# to process xml easily
-use File::Copy;
-use File::Path;
-use File::Basename;
-use Cwd;
-use Error qw(:try);
-
-require qw(boinc_authentication.pl);
-
-
-
-# ----------------
-# System-derived variables and constants
-
-my $response_header="Content-type: text/plain\n\n";
-my $cgidir=dirname($ENV{SCRIPT_FILENAME});
-my $xmlroot = "RetrieveStatus";
-my $xml_description_file="description_file.xml";
-
-
-# ----------------
-# Provisional variables: will soon be made global. Underscores are
-# important because a user could otherwise submit a job named `pool'
-
-my $pool_dirname="pool";
-my $delete_dirname="rboinc_trash_dir";
-my $process_stop="force-process-stop";
-my $process_vars="process.vars";
-my $safepurge=0;
-
-
-
-# ----------------
-# Provisional variables: will soon be replaced by true variables
-# passed by the client via the description mechanism
-
-my $temporary_boinc_email='nobody at nil.es';
-
-
-# -----------------
-# Set configuration variables
-
-carp "------------------------------------------------------";
-
-our $config=do "$cgidir/boinc_configuration.pl";
-
-if(!$config) {
-    die "Can't open configuration: $!";
-}
-
-
-my $remove_min_age=$config->{REMOVE_MIN_AGE} || 1.0;
-
-
-
-# -----------------
-# Begin the actual program
-
-
-
-
-# Prepare the CGI machinery for parsing input
-
-my $cgi = new CGI::Lite;
-$cgi->add_timestamp(0);
-my $action;
-
-# Receive the call and get the arguments
-do { #  ???
-    try {
-	my $form = $cgi->parse_form_data();
-	die ("Error receiving data: ".$cgi->get_error_message) 
-	    if $cgi->is_error;
-
-	$action=$form->{action};
-
-	if(! defined $action || $action eq '') {
-	    # Simple answer if no random-id provided (direct call)
-	    voidAnswer();
-	} elsif ($action eq 'get_dav_url') {
-	    handleGetDavUrl();
-	} elsif ($action eq 'get_wu_template') { 
-            # action slightly misnomed - will get both
-	    handleGetTemplate($form->{application});
-	} elsif ($action eq 'retrieve') {
-	    my $form_group=$form->{group};
-	    my $form_name=$form->{name};
-	    my $form_loginname=$form->{loginname};
-	    my $userpfx=(uc "$form_loginname")."_";
-	    handleRetrieve($userpfx.$form_group,$form_name);
-	} elsif ($action eq 'remove') {
-	    handleRemove($form->{dir});
-	} elsif ($action eq 'purge') {
-	    my $form_group=$form->{group};
-	    my $form_loginname=$form->{loginname};
-	    my $userpfx=(uc "$form_loginname")."_";
-	    handlePurge($userpfx.$form_group,$form->{name});
-	} elsif ($action eq 'stop') {
-	    my $form_group=$form->{group};
-	    my $form_loginname=$form->{loginname};
-	    my $userpfx=(uc "$form_loginname")."_";
-	    handleStop($userpfx.$form_group);
-	} elsif ($action eq 'status') {
-	    my $form_group=$form->{group};
-	    my $form_loginname=$form->{loginname};
-	    my $userpfx=(uc "$form_loginname")."_";
-	    handleStatus($userpfx.$form_group);
-	} elsif ($action eq 'gridstatus') {
-	    my $form_loginname=$form->{loginname};
-	    handleGridStatus($form_loginname);
-	} else {
-	    returnFailure($xmlroot,"Unsupported action $action");
-	}
-
-    } catch Error with {
-	my $ex=shift;
-	my $mess=$ex->text();
-	carp "Exception: ($action error) $mess";
-	returnFailure($xmlroot,"($action error) $mess");
-    }
-};
-
-exit(0);
-
-
-
-
-
-
-
-##################################################
-
-sub handleGetDavUrl {
-    my $oh={};
-    $oh->{DavUrl}=$config->{DAV_URL};
-    $oh->{ServerRevision}='$Revision: 736 $';
-
-    my $xr=XMLout($oh, RootName => $xmlroot, AttrIndent => 1);
-
-    print $response_header;
-    print $xr;
-}
-
-
-
-
-##################################################
-
-# Get wu and result templates
-sub handleGetTemplate {
-    my $app=shift;
-    my $thash=parse_wu_template($app);
-    my $rhash=parse_result_template($app);
-
-    my $oh={
-	WuTemplate => $thash,
-	ResultTemplate => $rhash,
-	ServerRevision => '$Revision: 736 $'
-    };
-
-    my $xr=XMLout($oh, RootName => $xmlroot, AttrIndent => 1);
-
-    print $response_header;
-    print $xr;
-}
-
-
-
-
-
-
-
-##################################################
-# Prevent the WU from spawning more work
-
-sub handleStop {
-    my $group=shift;
-
-    my $wd=$config->{WORKFLOW_DIR};
-    my $groupdir="$wd/$group";
-
-    die "invalid tag supplied" if(! isTagValid($group)  );
-    checkPoolDir($groupdir);
-    chdir($groupdir);
-    
-    die "Already stopped" if(-e $process_stop);
-    system("touch $process_stop");
-    sendSuccess("Group successfully marked as stopped, can be purged after assimilation.");
-
-}
-
-
-
-##################################################
-# Remove the WU and its administrative files.
-
-sub handlePurge {
-    my $group=shift;
-    my $name=shift;
-
-    my $owd=cwd;
-    my $wd=$config->{WORKFLOW_DIR};
-    my $groupdir="$wd/$group";
-    my $trashdir="$wd/$delete_dirname";
-    die "invalid tag supplied" if(! isTagValid($group) ||
-				  ($name && isNameReserved($name)) ||
-				  ($name && !isTagValid($name) ) 
-	);
-    checkPoolDir($groupdir);
-
-    my $size='';
-    if(!$name) {
-	# Purge whole GROUP
-	chdir($groupdir);
-	if($safepurge) {
-	    my @inprog=glob("*/in_progress");
-	    die "there are jobs in progress: @inprog" if(@inprog);
-	}
-	chdir($wd);
-	$size=`du -h -s $group`;
-	safeRemove($groupdir)  or die "move failed with $!";
-
-    } else {
-	# Purge GROUP/NAME
-	die "job $name in group $group does not exist" 
-	    if(! -d "$groupdir/$name");
-	die "job $name in group $group still in progress" 
-	    if(-e "$groupdir/$name/in_progress" && $safepurge);
-
-	chdir($groupdir);
-	$size=`du -h -s $name`;
-	safeRemove($name)  or die "move failed with $!";
-
-    }
-    sendSuccess("Freed $size on server");
-
-}
-
-
-
-
-
-
-
-##################################################
-
-# Remove the files from the server. This means that links in DAV will
-# become broken. In this case, we also have to remove them from DAV,
-# because apache DAV won't remove broken symlinks. Metadata files are
-# never removed.
-
-sub handleRemove {
-    my $dir=shift;
-
-    my $retrdir=$config->{DAV_DIR}."/$dir/";
-
-    # List of symlinks to original files
-    my @llist=glob("$retrdir/*");
-
-    my $nremoved=0;
-    my $nkept=0;
-    my $keepalive_every=20;
-
-    print $response_header;
-    foreach my $f (@llist) {
-	next if($f =~ /metadata_file/);
-	print "\n" if( ($nremoved+$nkept) % $keepalive_every == 0);
-
-	my $ldest=readlink($f);
-	if(canRemove($ldest) ) {
-	    safeRemove($ldest);
-	    unlink($f);		# remove now-broken symlink
-	    $nremoved++;
-	} else {
-	    $nkept++;		# the client will remove it
-	}
-    }
-    sendRemoveSuccess($nremoved,$nkept);
-}
-
-
-
-# Return true if conditions are met for the given file name to be
-# removed
-sub canRemove {
-    my $fn=shift;
-    my $removable=laterStepsExist($fn) || 
-	isLastStep($fn);
-
-    return($removable);
-}
-
-
-# True if given file name is newer than $remove_min_age
-sub isOldAge {
-    my $fn=shift;
-    my $age=(-M $fn);		# days
-    return ($age > $remove_min_age);
-}
-
-
-
-# True if given file name is at its latest step
-sub isLastStep {
-    my $fn=shift;
-    my $rc=0;
-    if (stepOf($fn)==maxStepOf($fn)-1) {
-	$rc=1;
-    }
-    return $rc;
-}
-
-
-
-
-
-# Return true if there are more recent steps in the series of
-# the given file name
-sub laterStepsExist {
-    my $fn=shift;
-    my $s=stepOf($fn);
-    my $gl=mkStepGlob($fn);
-    my @ex=glob($gl);		# list of files in the same dependency
-				# series as the removee
-    my $canremove=0;
-    
-    foreach my $i (@ex) {
-	if(stepOf($i)>$s) {
-	    $canremove=1;
-	    last;
-	}
-    }
-    
-    return $canremove;
-}
-
-
-
-# Make a glob to match all the results of this step.
-# GPUGRID-specific.
-# Ex.  /path/N2-TONI_TONIR6-5-10-RND7389_0 -> /path/N2-TONI_TONIR6-*-10-RND7389_0
-sub mkStepGlob {
-    my $fn=shift;
-    my $path=dirname($fn);
-    my @p=split(/-/,basename($fn));
-    $p[2]="*";
-    my $gl=join '-', at p;
-    return "$path/$gl";
-}
-
-
-    
-
-
-# This one does not send the header, because it must 
-# precede the keepalives.
-sub sendRemoveSuccess {
-    my $nr=shift;
-    my $nk=shift;
-
-    my $r={};
-    $r->{Success}->{NumberRemoved}=$nr;
-    $r->{Success}->{NumberKept}=$nk;
-    $r->{ServerRevision}='$Revision: 736 $';
-
-    my $xr=XMLout($r, RootName => $xmlroot, AttrIndent => 1);
-
-    print $xr;
-}
-
-
-
-
-
-##################################################
-
-
-
-sub handleRetrieve {
-    my $group=shift;
-    my $name=shift;
-    
-# Check tag validity
-    my $fail='';
-    if(! isTagValid($group)) {
-	$fail="Invalid group supplied";
-    } elsif($name && isNameReserved($name)) {
-	$fail="$name is a reserved name";
-    } elsif($name && !isTagValid($name)) {
-	$fail="Invalid name supplied";
-    }
-
-    die("$fail") if($fail);
-    
-
-# -----------------
-# Authenticate, TODO
-
-
-
-# -----------------
-# Check if the TAG dir exists (dies on failure)
-# TODO fix expected output counts
-# http://www.pageresource.com/cgirec/ptut18.htm
-
-    my $groupdir=$config->{WORKFLOW_DIR}."/$group";
-
-    # disabled machinery for computing expected outputs
-    my $expouts=-1;
-    my $metadata=0;
-
-    # will die on error
-    checkPoolDir($groupdir);
-
-
-
-
-# -----------------
-# Make a random id and corresponding dl dir
-
-    my $random_id=sprintf('retr%06d',int(rand(999999)));
-    my $retrdir=$config->{DAV_DIR} . "/$random_id/";
-
-    mkdir $retrdir,0777 or die "Can't make retrieve dir: $!";
-
-
-
-# -----------------
-# TODO: find files to be downloaded
-
-    my @flist;
-    my $aliastable;
-    if($name) {			# name given
-	@flist=glob("$groupdir/$name-$group-*");
-	$aliastable=getAliasTable($name,$group);
-	if(-r "$groupdir/$name/metadata_file") {
-	    push @flist,"$groupdir/$name/metadata_file";
-	    $metadata++;
-	}
-    } else {			# name not given 
-	@flist=glob("$groupdir/*-$group-*");
-	my $tmp=parseResultName(basename($flist[0])); # NAME of first retrieved item
-	$aliastable=getAliasTable($tmp->{name},$group);
-    }
-
-    if(! scalar @flist) {
-	rmdir($retrdir);
-	returnFailure($xmlroot,"No files ready for retrieval");
-	return;
-    }
-
-    my @blist=();			# basenames
-    foreach my $f (@flist) {
-	my $bn=basename($f);
-	push @blist,$bn;
-	symlink $f,"$retrdir/$bn";
-    }
-
-    # Send response
-    my $r={};
-    $r->{Success}->{Directory}=$random_id;
-    $r->{Success}->{FinalOutputs}=$expouts;
-    $r->{Success}->{MetadataFileCount}=$metadata;
-    $r->{AliasTable}={File=>$aliastable};
-    $r->{FileList}={File=>\@blist};
-    $r->{ServerRevision}='$Revision: 736 $';
-
-    my $xr=XMLout($r, RootName => $xmlroot, AttrIndent => 1);
-
-    print $response_header;
-    print $xr;
-}
-
-
-
-
-# Make alias table for given group, name (from template)
-sub getAliasTable {
-    my $name=shift;
-    my $group=shift;
-    my $groupdir=$config->{WORKFLOW_DIR}."/$group";
-    my $desc=XMLin("$groupdir/$name/$xml_description_file");
-    my $app=$desc->{Template};
-    my $tpl=parse_result_template($app);
-    my @ata=();
-    my $i=0;
-    while ($tpl->{file_info}->[$i]) {
-	my $ext="_$i";
-	my $aliases=$tpl->{file_info}->[$i]->{rboinc}->{aliases};
-	my @alist=split(' ',$aliases);
-	push(@ata, { Extension => $ext,
-		     Alias => \@alist } );
-	$i++;
-    }
-    return \@ata;
-}
-
-
-
-
-
-
-
-
-##################################################
-
-
-sub handleStatus {
-    my $group=shift;		# the group name
-    my $r=currentSteps($group);
-
-    die "invalid tag supplied" if(! isTagValid($group));
-
-    sendSuccess("Returning count of max-steps computed",{Success=>{StepList=>$r}});
-
-}
-
-
-
-# Return the list of bins in this group (based on those who
-# have a process.vars)
-
-sub currentNamesInGroup {
-    my $group=shift;		# the group name
-    my $gd=$config->{WORKFLOW_DIR}."/$group";
-    checkPoolDir($gd);
-
-    my @plist=glob("$gd/*/$process_vars");
-    my @nlist=();
-    # for each process_vars, take the last element of the path
-    foreach my $i (@plist) {
-	push @nlist,basename(dirname($i));
-    }
-    return @nlist;
-}
-
-
-# existence of step 0 returned as 1
-sub maxStepNameGroup {
-    my $group=shift;
-    my $name=shift;
-    my $gd=$config->{WORKFLOW_DIR}."/$group";
-
-    my $gl="$gd/$name-$group-*-*-*_0";
-    my @l=glob($gl);
-
-    my $mx=0;
-    foreach my $i (@l) {
-	my $n=stepOf($i)+1;
-	if($n>$mx) {
-	    $mx=$n;
-	}
-    }
-    return $mx;
-
-}
-    
-    
-# Using "bin_" to workaround attribute name limitation
-
-sub currentSteps {
-    my $group=shift;
-    my @nl=currentNamesInGroup($group);
-    my $r={};
-    foreach my $i (@nl) {
-	$r->{"Bin_$i"}=maxStepNameGroup($group,$i);
-    }
-    return $r;
-}
-
-
-
-
-##################################################
-# Misc utility functions
-
-
-sub handleGridStatus {
-    my $user=shift;		# the group name
-
-    die "invalid user supplied" if(! isUserValid($user));
-
-    my $cmd=<<"EOL";
-echo "call mon_status('$user')" | mysql -t -pc0c4c0la LUNA
-EOL
-    my $list=`$cmd`;
-
-    sendSuccess("Returning grid status",{Success=>{content=>$list}});
-
-}
-
-
-##################################################
-# Misc utility functions
-
-
-# Assert that the TAG dir exists (dies on failure). Will return a
-# void.
-
-sub checkPoolDir {
-    my $wd=shift;
-    my $res=opendir(WD, $wd);
-    closedir WD;
-
-    # No special cleanup required
-    die("Group does not exist")    if(!$res); 
-    
-    my $pfn=$wd."/$pool_dirname";
-    die("Not a remotely-submitted job") if(! -d $pfn );
-}
-
-
-
-# Extract the step num from a given result filename
-# GPUGRID-specific.
-# Ex.  /path/N2-TONI_TONIR6-5-10-RND7389_0 -> 5
-sub stepOf {
-    my $fn=basename(shift);
-    my @p=split(/-/,$fn);
-    return $p[2];
-}
-
-
-# /path/N2-TONI_TONIR6-5-10-RND7389_0 -> 10
-sub maxStepOf {
-    my @p=split(/-/,basename(shift));
-    return $p[3];
-}
-
-
-
-
-# Remove a dir or file, moving it into the trash dir (renamed with an
-# unique suffix).  I use "system mv" because move() has quirks on
-# handling directory moves. E.g.  move("/dir1/dir2/dir3","/dir4")
-# fails unless "dir3" eq "dir4". Should be changed in a two-step
-# move()
-
-sub safeRemove {
-    my $fn=shift;
-
-    my $wd=$config->{WORKFLOW_DIR};
-    my $t=time();		# TODO improve
-    my $trashdir="$wd/$delete_dirname/$t";
-
-    mkpath($trashdir);
-
-    system("/bin/mv $fn $trashdir") == 0
-	or die "Error moving: $!";
-}
-
-
-
-
-# Generic "success" function - mandatory message, optional
-# hash of additional stuff to be transferred
-
-sub sendSuccess {
-    my $m=shift;
-    my $r=shift || {};
-    $r->{Success}->{Message}=$m;
-    $r->{ServerRevision}='$Revision: 736 $';
-
-    my $xr=XMLout($r, RootName => $xmlroot, AttrIndent => 1);
-
-    print $response_header;
-    print $xr;
-}
-
diff --git a/rboinc/server/boinc_submit_server.pl b/rboinc/server/boinc_submit_server.pl
deleted file mode 100755
index 5a504fe..0000000
--- a/rboinc/server/boinc_submit_server.pl
+++ /dev/null
@@ -1,825 +0,0 @@
-#!/usr/bin/perl -w
-
-# $Id$
-
-# The remote-boinc server-side perl script. Should run as a CGI in an
-# Apache2 instance.
-
-=head1 NAME
-
-boinc_submit_server.pl - CGI for handling incoming remote
-    boinc submissions
-
-=head1 SYNOPSIS
-
-To be installed in Apache's cgi-bin directory
-
-=head1 DESCRIPTION
-
-This documentation is provisional.
-
-Currently receives GET requests with one argument "random_id",
-which is the directory inside a Dav-enabled rendez-vous point with the
-client. The client is supposed to create a directory named "random_id"
-in the Dav dir, upload relevant files there, and invoke this cgi with
-the random_id argument.
-
-=head1 AUTHOR
-
-Toni Giorgino
-
-
-=head1 COPYRIGHT
-
-This file is part of RemoteBOINC.
-
-Copyright (C) 2010 Toni Giorgino, Universitat Pompeu Fabra
-
-RemoteBOINC is free software; you can redistribute it and/or modify it
-under the terms of the GNU Lesser General Public License as published
-by the Free Software Foundation, either version 3 of the License, or
-(at your option) any later version.
-
-RemoteBOINC is distributed in the hope that it will be useful, but
-WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Lesser General Public License for more details.
-
-You should have received a copy of the GNU Lesser General Public
-License along with BOINC.  If not, see <http://www.gnu.org/licenses/>.
-
-
-=cut
-
-
-# ----------------
-
-# Prepend non-standard location for modules
-use lib qw(/home/boinc/toni/perl/lib);
-
-
-# ----------------
-
-
-use strict;
-use CGI::Lite;			# parsing requests
-use CGI::Carp;  		# for error messages
-use XML::Simple;		# to process xml easily
-use File::Copy;
-use File::Basename;
-use POSIX qw(uname);
-use Error qw(:try);
-
-
-require qw(boinc_authentication.pl);
-
-
-
-# ----------------
-# System-derived variables and constants
-
-my $response_header="Content-type: text/plain\n\n";
-my $cgidir=dirname($ENV{SCRIPT_FILENAME});
-my $xmlroot = "SubmitStatus";
-my $arch=(POSIX::uname())[4];
-my $xml_description_file="description_file.xml";
-my $reread_db="reread_db";
-
-
-# ----------------
-# Provisional variables: will soon be made global. Underscores are
-# important because a user could otherwise submit a job named `pool'
-
-my $pool_dirname="pool";            # underscore is important
-
-
-# -----------------
-# Set configuration variables
-
-carp "------------------------------------------------------";
-
-our $config=do "$cgidir/boinc_configuration.pl";
-
-if(!$config) {
-    die "Can't open configuration: $!";
-}
-
-
-# -----------------
-
-# Begin the actual program
-
-
-
-
-# Prepare the CGI machinery for parsing input
-
-my $cgi = new CGI::Lite;
-
-# Some of them may be redundand
-# $cgi->set_platform("Unix");
-# $cgi->set_file_type("file");
-# $cgi->set_directory("/tmp");	# should we  want to POST files, in the future
-$cgi->add_timestamp(0);    
-
-
-# Receive the call and get the arguments
-my $form = $cgi->parse_form_data();
-die "Error receiving data: ".$cgi->get_error_message if $cgi->is_error;
-
-my $random_id=$form->{random_id};
-
-
-# Simple answer if no random-id provided (direct call)
-if(!$random_id) {
-    voidAnswer();
-    exit 0;
-}
-
-
-# The DAV upload dir
-my $updir=$config->{DAV_DIR} . "/$random_id/";
-
-# Get the client address
-my $client_ip=$ENV{REMOTE_ADDR};
-
-
-
-
-# Read and parse the XML description
-my $xml_description=XMLin("$updir/$xml_description_file");
-
-# Parameters with no defaults
-my $tag=$xml_description->{Tag};
-my $group=$xml_description->{Group};
-my $name=$xml_description->{Name};
-
-my $timestamp_string=$xml_description->{TimeStamp}->{String};
-my $login_name=$xml_description->{LoginName};
-
-
-my $template=$xml_description->{Template} ||  $config->{DEFAULT_APP_NAME};
-my $assign_user_all=$xml_description->{AssignUserAll}; # May be empty
-my $num_steps=$xml_description->{NumSteps} || $config->{DEFAULT_NUMSTEPS};
-my $priority=$xml_description->{Priority} ||  $config->{DEFAULT_PRIORITY};
-my $fpops_est=$xml_description->{FPopsEst}; # May be empty
-my $fpops_bound=$xml_description->{FPopsBound};  # May be empty
-my $memory_bound=$xml_description->{MemoryBound}; # May be empty
-
-my $target_nresults=$xml_description->{TargetNResults}; # May be empty
-my $balance=$xml_description->{Balance} || 0;		   # FIXME
-my $min_quorum=$xml_description->{MinQuorum}; # May be empty
-my $batch=$xml_description->{Batch}; # May be empty
-
-
-my $dry_run=$xml_description->{DryRun};
-
-my $delay_bound=$xml_description->{DelayBound};  # May be empty
-
-
-
-# Parse WU template
-
-my $wu_template="rboinc_$template"."_wu";
-my $wu_template_hash=parse_wu_template($template);
-my $input_files=build_input_files_list($wu_template_hash);
-my @input_file_names=();
-my $app_name=$wu_template_hash->{rboinc}->{application};
-
-
-
-# Parse result template
-
-my $result_template="rboinc_$template"."_result";
-my $result_template_hash=parse_result_template($template);
-my $do_chain_bash_function=build_do_chain_bash_function($result_template_hash);
-
-
-
-
-
-
-# Should not be user-controllable any longer
-my $email=$xml_description->{Email} ||
-    $config->{DEFAULT_EMAIL};
-
-my $other_text=sprintf('RND%04d',int(rand(9999)));
-
-
-
-# Check old/new style tag validity
-my $fail='';
-if($tag) {
-    $fail="Tag syntax is obsolete. Please use group+name";
-} elsif(! defined $name || !$group) {
-    $fail="Both group and name must be given";
-} elsif(! isTagValid($name)) {
-    $fail="Invalid name supplied";
-} elsif(! isTagValid($group)) {
-    $fail="Invalid group supplied";
-} elsif(isNameReserved($name)) {
-    $fail="$name is a reserved name";
-}
-
-
-
-# Check quorum and other sanity parameters
-
-elsif($min_quorum > $target_nresults) {
-    $fail="min_quorum (now $min_quorum) must be <= target_nresults ($target_nresults)";
-}
-
-# Finally make the shame known to the world 
-if($fail) {
-    returnFailure($xmlroot,$fail);
-    exit(0);
-}
-
-
-
-##################################################
-# Let's start. hash for the output. Put all interesting stuff here,
-# will be serialized and sent back to the client
-
-my $oh={};			
-
-$oh->{InputKeys}=$form;
-$oh->{ClientIP}=$client_ip;
-# $oh->{RandomID}=$random_id;
-$oh->{ServerRevision}='$Revision: 353 $';
-
-
-
-
-##################################################
-# Move everything to the workflow directory. Make user dir if a deep
-# structure is desired. TODO: restrict upload names.
-
-my $userpfx=(uc "$login_name")."_";
-my $groupdir="$config->{WORKFLOW_DIR}/$userpfx$group";
-my $pooldir="$groupdir/$pool_dirname";
-my $namedir="$groupdir/$name";
-my $adding_to_group=0;
-
-
-try 
-{
-    if(-d $namedir) {
-	die "Group/name combination already exists";
-    }
-    
-    if(-d $groupdir) {
-	$adding_to_group++;
-    } else {
-	# need to create group and pool dirs
-	mkdir($groupdir,0777) or 
-	    die "Can't create group directory on server";
-	mkdir($pooldir,0777) or
-	    die "Can't create pool directory on server";
-    }
-
-    # Create namedir
-    mkdir($namedir,0777) or
-	die "Can't create name directory on server";
-    
-    # move files from DAV to NAME
-    my @upfiles = glob "$updir/*";
-    # $oh->{InputFiles}={file=>\@upfiles};
-
-    chdir($namedir) || die $!;
-    foreach my $fn (@upfiles) {
-	my $bn=basename($fn);
-	# move DAV->NAME
-	move($fn,$bn);	
-    }
-
-
-
-
-# Process the input list according to template
-
-    foreach my $inf (@$input_files) {
-
-	my $pname="";
-
-	# Create standard COPYRIGHT and LICENSE files, overwriting them
-	# even if supplied by the user ("immutable" rboinc flag).
-	if($inf->{rboinc}->{immutable}) {
-	    $pname=$inf->{open_name};
-	    create_standard_files([$pname],1);
-	} else {
-	    $pname=$inf->{rboinc}->{parameter_name};
-	}
-	    
-	# Create standard idx_file if not supplied by the user.
-	if ($inf->{rboinc}->{optional}) {
-	    create_standard_files([$pname],0);
-	}
-
-	# Encode private files (maybe remove the old ones)
-	if($inf->{rboinc}->{encode}) {
-	    my $encname=$pname."_enc";
-	    encodeinput($pname,$encname,$config->{ENCODE_CODE});
-	    $pname=$encname;
-	}
-
-	push @input_file_names,'$NAME/'.$pname;
-
-    }
-
-
-
-
-# Move everything into pool (we can play on what to move and what not)
-    foreach my $fn (glob "*") {
-	move_in_pooldir($fn,$pooldir);
-    }
-
-# From now on, files will not be moved in pool any longer
-# Prepare machinery for looking at the status
-    create_process_vars();
-
-    chdir($groupdir);
-
-# Create the launcher script, if not already there
-    if(!$adding_to_group) {
-	create_process_sh();
-    }
-
-
-
-
-} catch Error with {
-    my $ex=shift;
-    carp "$ex";
-    returnFailure($xmlroot,$ex->text());
-    exit(0);
-}
-
-
-
-
-
-# ############################################################
-# Launch the job & collect return codes
-
-my $exit_code;
-
-if(!$dry_run) {
-    $exit_code=system("/bin/bash process start $name >$name/rboinc_stdout 2>$name/rboinc_stderr");
-} else {
-    $exit_code=system("echo Dry run requested, not running /bin/bash process start $name >$name/rboinc_stdout 2>$name/rboinc_stderr");
-}
-
-# See perlfunc "system"; has some quirks
-if($exit_code==0) {
-    $oh->{Return}->{ExitCode}=0;
-    if(!$dry_run) {
-	system("touch $name/in_progress");
-    }
-} elsif($exit_code==-1) {	# failed to start
-    $oh->{Return}->{ExitCode}=-1;
-} else {
-    $oh->{Return}->{ExitCode} = $? >> 8;
-    $oh->{Return}->{SignalNum}=$? & 127;
-    $oh->{Return}->{DumpedCore}=$? & 128;
-    # TODO: delete dir
-}
-
-
-chdir($namedir) || die $!;
-$oh->{Return}->{StdOut}=`cat rboinc_stdout`;
-$oh->{Return}->{StdErr}=`cat rboinc_stderr`;
-$oh->{Success}=1;
-
-
-# ############################################################
-# If using assigned work, re-read the db
-# http://boinc.berkeley.edu/trac/wiki/AssignedWork
-
-if($assign_user_all) {
-	open TOUCHDB, "> $config->{PROJECT_DIR}/$reread_db";
-	close TOUCHDB;
-}
-
-
-
-
-
-# ############################################################
-# CGI ends here
-
-
-my $outmessage=XMLout($oh, RootName => $xmlroot, AttrIndent => 1  );
-
-print $response_header;
-print $outmessage;
-
-open SO, ">submission_output.xml" or die $!;
-print SO $outmessage;
-close SO;
-
-
-
-exit 0;
-
-
-
-
-
-
-
-
-
-
-
-##################################################
-# Create the launcher script. Will be sourced by "process.sh" both
-# when creating new work, and when going to the next step. This should
-# be called with PWD=name directory
-
-sub create_process_vars {
-    if($assign_user_all) {
-    	$other_text="$other_text"."_asgn";
-    }
-    
-
-    open PROCESS, ">process.vars" or die $!;
-    print PROCESS <<ENDPROCESS;
-
-# Process variables  created on behalf of $email for job tagged $group/$name on
-# $timestamp_string, connected from IP $client_ip.
-# Automatically generated by $0 : do not copy, do not edit.
-# See $xml_description_file in this directory for details.
-
-# You can modify this file on the fly, if you know what you are doing.
-
-
-# All-important list of input files. Part of it will be overwritten 
-# by chained results
-INPUT_LIST=\"@input_file_names\"
-
-
-# Computed, or fixed to default
-TEMPLATE_WU=$wu_template
-TEMPLATE_RES=$result_template
-LOAD_BALANCER=$balance
-CATCHUP_TARGET_NRESULTS=$target_nresults
-CATCHUP_PRIORITY=2000
-
-# Passed by user
-APPNAME=$app_name
-ASSIGN_USER_ALL=$assign_user_all
-NUM_STEPS=$num_steps
-PRIORITY=$priority
-OTHER=$other_text
-TARGET_NRESULTS=$target_nresults
-MAX_ERROR_RESULTS=5
-MAX_TOTAL_RESULTS=10
-MIN_QUORUM=$min_quorum
-DELAY_BOUND=$delay_bound
-FPOPS_EST=$fpops_est
-FPOPS_BOUND=$fpops_bound
-MEMORY_BOUND=$memory_bound
-BATCH=$batch
-
-export PROJECT_DIR=$config->{PROJECT_DIR}
-
-
-$do_chain_bash_function
-
-
-ENDPROCESS
-close(PROCESS);
-
-}
-
-
-
-
-
-
-
-##################################################
-# Create the constant part of the launcher script.The file will be
-# created in the GROUP directory and launched from there. It may NOT
-# use $name variable, or other per-name variable, because the same
-# process file will be recycled for several NAMEs. Per-name variables
-# should go in the process.var script.
-
-# First run: invoked with two arguments, "start NAME". Successive
-# runs: one argument, ie. WU name, NAME-GROUP-S-M-O. Calling "process"
-# with no arguments is an error.
-
-
-sub create_process_sh {
-
-    open PROCESS, ">process" or die $!;
-    print PROCESS <<ENDPROCESS;
-#!/bin/bash
-
-# Launcher script created on behalf of $email for job tagged
-# $group/$name on $timestamp_string, connected from IP $client_ip.
-# Automatically generated by $0 : do not copy, do not edit except
-# where indicated.  See $xml_description_file in this directory for
-# details.
-ENDPROCESS
-    
-    print PROCESS <<'ENDPROCESS';
-
-
-# The following will fail if process is a symlink.
-GROUP_DIR=$(cd $(dirname $0); pwd -P)
-
-
-# To manually change priority, target_nresults, etc., see below at the
-# *** MANUAL OVERRIDE *** section
-
-
-# *** MANUAL STOP *** 
-# There are three possibilities to interrupt a working workflow
-# (best to worst):
-#
-# 1. use boinc_retrieve -stop -group XX
-# 2. create a file named "force-process-stop" in the group
-#    or name directory (stops all/one)
-# 3. uncomment the line below
-
-# echo "Manually stopped." && exit 0
-
-
-
-
-
-# Invocation from remote submit
-if [ "$#" == 2 ]; then
-    # $1 ignored, but supposedly "start"
-    NAME=$2
-    GROUP=`basename $PWD`
-    NEW_STEP=0
-
-elif [ "$#" == 1 ]; then
-    # Invocation from assimilator. We have to go in the NAME directory 
-    # in order to recover pdb, etc
-
-    # Parse current WU name
-    WU_NAME=$1
-    OLDIFS=$IFS
-    IFS=-
-    WU_NAME_ARRAY=($@)
-    IFS=$OLDIFS
-
-    NAME=${WU_NAME_ARRAY[0]}
-    GROUP=${WU_NAME_ARRAY[1]}
-    STEP=${WU_NAME_ARRAY[2]}
-    NUM_STEPS=${WU_NAME_ARRAY[3]}
-    NEW_STEP=$(($STEP+1))
-
-    if [ "$NEW_STEP" -eq $NUM_STEPS ] ; then
-          echo "End of workflow for ${GROUP}-${NAME}."
-          rm $GROUP_DIR/$NAME/in_progress
-          exit
-    fi
-else 
-    cat <<EOF
-Error: process called with wrong number of arguments.
-Usage: process start NAME
-(or)   process <NAME>-<GROUP>-<STEP>-<MAXSTEP>-<OTHER>
-EOF
-    exit 1
-fi
-
-
-
-# Check if we should stop forcibly
-if [ -e "$GROUP_DIR/force-process-stop" ]; then
-    rm $GROUP_DIR/*/in_progress
-    echo "Obeying stop action" && exit 0
-fi
-if [ -e "$GROUP_DIR/$NAME/force-process-stop" ]; then
-    rm $GROUP_DIR/$NAME/in_progress
-    echo "Obeying stop action" && exit 0
-fi
-
-
-
-
-# Now that we know $NAME, source the job-specific variables to be
-# used in the submission
-
-source $GROUP_DIR/$NAME/process.vars
-
-
-# And now that we have the do_chain function, defined in the sourced
-# file, call it if we are at step > 0
-
-if [[ $NEW_STEP -gt 0 ]]; then
-    do_chain $WU_NAME
-fi
-    
-
-
-
-
-# *** MANUAL OVERRIDE *** You can override parameters globally by
-# uncommenting them below:
-
-# PRIORITY=100
-# TARGET_NRESULTS=2
-# DELAY_BOUND=1e5
-# LOAD_BALANCER=1
-# BATCH=128
-
-
-# Perform load-balancing: figure out our step wrt the others in this
-# group.
-
-catchup=0
-pushd $GROUP_DIR > /dev/null
-
-# Update the current and max step for this group
-mx=maxstep-file
-if [[ -e $mx ]]; then
-    maxstep=`cat $mx`
-else
-    maxstep=0
-fi
-if (( NEW_STEP > maxstep )); then
-    echo $NEW_STEP > $mx
-fi
-
-# Check if we have to hurry up
-if (( LOAD_BALANCER == 1 && NEW_STEP < maxstep-2 )); then
-    catchup=1
-fi
-
-popd > /dev/null
-
-
-
-# Perform load-balancing: alter parameters to achieve a speed-up
-
-if [[ $catchup -eq 1 ]]; then
-    echo "Balancer: catchup mode on"
-    TARGET_NRESULTS=$CATCHUP_TARGET_NRESULTS
-    PRIORITY=$CATCHUP_PRIORITY
-fi
-
-
-
-# order is important here, should correspond to the above (?)
-# CP_SRC will be prepended WUNIQ -> SRC
-# SRC will be hier-'d
-
-WUNIQ=${NAME}-${GROUP}-${NEW_STEP} 
-WU_NEW_NAME=${NAME}-${GROUP}-${NEW_STEP}-${NUM_STEPS}-${OTHER}
-CP_SRC="$INPUT_LIST"
-
-echo "Processing input '$@' to wu '$WU_NEW_NAME'"
-
-
-
-
-# we now generate SRC on the fly. formerly: SRC="$WUNIQ-LICENSE
-# $WUNIQ-COPYRIGHT $WUNIQ-$COO_FILE $WUNIQ-$VEL_FILE $WUNIQ-$IDX_FILE
-# $WUNIQ-$PDB_FILE $WUNIQ-$PSF_FILE $WUNIQ-$PAR_FILE $WUNIQ-${NAME}"
-
-cd $PROJECT_DIR
-
-# generate symlinks from download dir to the right places
-# and generate list of symlinked names
-
-SRC=""
-for T in $CP_SRC; do
-    fname=`basename $T`
-
-    # ufname is the official unique name - we could even reduce it as long as stays unique
-    ufname="$WUNIQ-$fname"
-    SRC="$SRC $ufname"
-    file_in_workarea=$GROUP_DIR/$T
-    file_in_upload=`bin/dir_hier_path $ufname`
-
-    # Check existence or die
-    if [[ ! -r $file_in_workarea ]]; then
-        echo "Download file $file_in_workarea missing, creating empty"
-        touch $file_in_workarea
-        #exit 1
-    fi
-
-
-    # This could produce an error if files are shared
-    ln $file_in_workarea $file_in_upload
-    if [[ $? -ne 0 ]]; then
-        echo "Command ln $file_in_workarea $file_in_upload failed. Continuing."
-        # rm $file_in_upload
-        # ln $file_in_workarea $file_in_upload
-        # exit 1
-    fi
-done
-
-bin/create_work \
-    ${TARGET_NRESULTS:+ -target_nresults $TARGET_NRESULTS} \
-    ${MIN_QUORUM:+ -min_quorum $MIN_QUORUM} \
-    -max_error_results ${MAX_ERROR_RESULTS} \
-    -max_total_results ${MAX_TOTAL_RESULTS} \
-    ${DELAY_BOUND:+ -delay_bound $DELAY_BOUND} \
-    ${ASSIGN_USER_ALL:+ -assign_user_all $ASSIGN_USER_ALL} \
-    ${FPOPS_EST:+ -rsc_fpops_est $FPOPS_EST} \
-    ${FPOPS_BOUND:+ -rsc_fpops_bound $FPOPS_BOUND} \
-    ${MEMORY_BOUND:+ -rsc_memory_bound $MEMORY_BOUND} \
-    ${BATCH:+ -batch $BATCH} \
-    -appname ${APPNAME} \
-    -wu_name ${WU_NEW_NAME} \
-    -wu_template templates/${TEMPLATE_WU} \
-    -result_template templates/${TEMPLATE_RES} \
-    -priority $(($PRIORITY-$NEW_STEP)) \
-    ${SRC}
-
-ecode=$?
-if [[ $ecode -ne 0 ]]; then 
-    echo "Submit failure for $1: $ecode"
-    exit $ecode
-else
-    echo ""
-    echo "Submitted $WU_NEW_NAME"
-fi
-
-ENDPROCESS
-
-close PROCESS;
-
-system("chmod a+x process");
-
-}
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-# These will be copied from the CGI directory. If first argument=1,
-# overwrite files even if they exist
-
-sub create_standard_files {
-    my $filelist=shift;
-    my $overwrite=shift;
-    foreach my $f (@$filelist) {
-	if(! -e $f || $overwrite) {
-	    copy("$config->{ETC_DIR}/default_$f","$f") || die "Error copying default $f: $!";
-	}
-    }
-}
-
-
-
-
-
-# Performs the encode-input command. Relies on $arch to be set
-sub encodeinput {
-    my ($in,$out,$code)=@_;
-    my $r=system("$config->{ENCODE_EXECUTABLE}.$arch $in $out $code");
-    if($r!=0) {
-	die "encoder returned error $r";
-    }
-}
-
-
-
-# Move the given file in pooldir, and link to it
-# Assume we are in namedir
-# $fn is the basename of the file to be moved
-# $pooldir is the path to the pooldir
-# after execution, $fn will be a link
-sub move_in_pooldir {
-    my ($fn,$pooldir)=@_;
-
-    my $md5=md5_file($fn);
-    my $poolfile="$pooldir/$md5";
-
-    if(-r $poolfile) {
-	# Already in pool: drop current copy, make link
-	unlink($fn) or die "Error unlinking $fn"; 
-	link($poolfile,$fn) or die "Error hard-linking pool to $fn";
-    } else {
-	# Not in pool: link current copy there
-	link($fn,$poolfile) or die "Error hard-linking $fn to pool";
-    }
-
-    # old-style symlinking
-    # symlink("$pooldir/$md5","$fn") or die "Error symlinking $fn";
-
-}
-
diff --git a/rboinc/server/etc/default_COPYRIGHT b/rboinc/server/etc/default_COPYRIGHT
deleted file mode 100644
index 89f75b4..0000000
--- a/rboinc/server/etc/default_COPYRIGHT
+++ /dev/null
@@ -1,33 +0,0 @@
-For CellMD:
-Copyright (C) 2007, G. De Fabritiis, G. Giupponi  All rights reserved.
-
-The CellMD base software (the "Software" herein) contains proprietary
-information with restrictions on use and disclosure and is also protected by
-copyright  and other intellectual and industrial property laws. Reverse
-engineering, disassembly, or decompilation of the Programs is prohibited. No
-part of the Software may be reproduced or transmitted in any form or by any
-means, electronic or mechanical, for any purpose.
-
-For MDX libraries:
-Copyright (C) 2003-2005, David J. Hardy.  All rights reserved.
-  * Redistributions of source code must retain the above copyright notice,
-    this list of conditions and the following disclaimers.
-
-  * Redistributions in binary form must reproduce the above copyright
-    notice, this list of conditions and the following disclaimers in the
-    documentation and/or other materials provided with the distribution.
-
-  * Neither the names of David J. Hardy, Theoretical and Computational
-    Biophysics Group, Beckman Institute, University of Illinois, nor the
-    names of its contributors may be used to endorse or promote products
-    derived from this Software without specific prior written permission.
-
-
-
-THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.  IN NO EVENT SHALL
-THE CONTRIBUTORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR
-OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
-ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
-OTHER DEALINGS WITH THE SOFTWARE.
diff --git a/rboinc/server/etc/default_LICENSE b/rboinc/server/etc/default_LICENSE
deleted file mode 100644
index fb6a7d2..0000000
--- a/rboinc/server/etc/default_LICENSE
+++ /dev/null
@@ -1,229 +0,0 @@
-PS3GRID USER LICENCE AGREEMENT ver 1.0
-
-- In order to run the PS3GRID software, the BOINC client must download PS3GRID
-  files and executable onto your machine. Please carefully read the following
-  terms and conditions before installing this software ("PS3GRID").
-
-- As a user, you are required to agree to the terms and conditions specified in
-  this license. A copy of this license will be downloaded into your system and
-  will attest your acceptance of the terms and conditions set in this license and
-  available on the website. If others use your system, you are responsible for
-  all their actions. If you are not the system owner, you must ask for permission
-  before joining PS3GRID. PS3GRID reserves the right to terminate this licence at
-  any time.
-
-- All programs, data and files associated to the PS3GRID project are licensed
-  for non-commercial use on your PS3 system, and for the sole purpose
-  of the PS3GRID project. You do not have any intellectual property rights on the
-  software and on any programs, data or files used or generated by PS3GRID software.
-
-- You may not alter or modify any programs, data or files related to the
-  PS3GRID project.
-
-- You may not reverse engineering or disassemble the PS3GRID software (or a
-  part of).
-
-- You may not redistribute or create derivative work from any programs, data
-  and files associated to the PS3GRID project.
-
-- You may not disclose, publish, sub-licence any information, data or files,
-  generated or distributed by the PS3GRID project.
-
-- Your participation to the PS3GRID is voluntary and you will not receive any
-  compensation for it.  You give irrevocable right to use, modify, or transfer
-  the data furnished by your PS3 system without any conditions or restrictions to
-  solely PS3GRID.
-
-- PS3GRID is provided "AS IS", without any warranties. You take all risks of
-  running this software and the PS3GRID project and its collaborators and
-  partners are not liable in any case.
-
-- The PS3GRID project might collect personal information and disclose
-   to trusted third parties in connection with the project.
-
-- You  will not engage in any activity that may disrupt, harm or interfere with
-  the PS3GRID project.
-
-- The PS3GRID project reserves the right to modify the terms and conditions of
-  this agreement at any time.
-
-Copyright - 2007 University Pompeu Fabra ("UPF"). All Rights Reserved.
-
-
-
-
-
-----------------------------------------
-
-
-The project includes the "PLUMED" library,
-http://merlino.mi.infn.it/~plumed/PLUMED/Home.html , distributed under
-the terms of the GNU Lesser General Public License.
-
-
-
-		   GNU LESSER GENERAL PUBLIC LICENSE
-                       Version 3, 29 June 2007
-
- Copyright (C) 2007 Free Software Foundation, Inc. <http://fsf.org/>
- Everyone is permitted to copy and distribute verbatim copies
- of this license document, but changing it is not allowed.
-
-
-  This version of the GNU Lesser General Public License incorporates
-the terms and conditions of version 3 of the GNU General Public
-License, supplemented by the additional permissions listed below.
-
-  0. Additional Definitions.
-
-  As used herein, "this License" refers to version 3 of the GNU Lesser
-General Public License, and the "GNU GPL" refers to version 3 of the GNU
-General Public License.
-
-  "The Library" refers to a covered work governed by this License,
-other than an Application or a Combined Work as defined below.
-
-  An "Application" is any work that makes use of an interface provided
-by the Library, but which is not otherwise based on the Library.
-Defining a subclass of a class defined by the Library is deemed a mode
-of using an interface provided by the Library.
-
-  A "Combined Work" is a work produced by combining or linking an
-Application with the Library.  The particular version of the Library
-with which the Combined Work was made is also called the "Linked
-Version".
-
-  The "Minimal Corresponding Source" for a Combined Work means the
-Corresponding Source for the Combined Work, excluding any source code
-for portions of the Combined Work that, considered in isolation, are
-based on the Application, and not on the Linked Version.
-
-  The "Corresponding Application Code" for a Combined Work means the
-object code and/or source code for the Application, including any data
-and utility programs needed for reproducing the Combined Work from the
-Application, but excluding the System Libraries of the Combined Work.
-
-  1. Exception to Section 3 of the GNU GPL.
-
-  You may convey a covered work under sections 3 and 4 of this License
-without being bound by section 3 of the GNU GPL.
-
-  2. Conveying Modified Versions.
-
-  If you modify a copy of the Library, and, in your modifications, a
-facility refers to a function or data to be supplied by an Application
-that uses the facility (other than as an argument passed when the
-facility is invoked), then you may convey a copy of the modified
-version:
-
-   a) under this License, provided that you make a good faith effort to
-   ensure that, in the event an Application does not supply the
-   function or data, the facility still operates, and performs
-   whatever part of its purpose remains meaningful, or
-
-   b) under the GNU GPL, with none of the additional permissions of
-   this License applicable to that copy.
-
-  3. Object Code Incorporating Material from Library Header Files.
-
-  The object code form of an Application may incorporate material from
-a header file that is part of the Library.  You may convey such object
-code under terms of your choice, provided that, if the incorporated
-material is not limited to numerical parameters, data structure
-layouts and accessors, or small macros, inline functions and templates
-(ten or fewer lines in length), you do both of the following:
-
-   a) Give prominent notice with each copy of the object code that the
-   Library is used in it and that the Library and its use are
-   covered by this License.
-
-   b) Accompany the object code with a copy of the GNU GPL and this license
-   document.
-
-  4. Combined Works.
-
-  You may convey a Combined Work under terms of your choice that,
-taken together, effectively do not restrict modification of the
-portions of the Library contained in the Combined Work and reverse
-engineering for debugging such modifications, if you also do each of
-the following:
-
-   a) Give prominent notice with each copy of the Combined Work that
-   the Library is used in it and that the Library and its use are
-   covered by this License.
-
-   b) Accompany the Combined Work with a copy of the GNU GPL and this license
-   document.
-
-   c) For a Combined Work that displays copyright notices during
-   execution, include the copyright notice for the Library among
-   these notices, as well as a reference directing the user to the
-   copies of the GNU GPL and this license document.
-
-   d) Do one of the following:
-
-       0) Convey the Minimal Corresponding Source under the terms of this
-       License, and the Corresponding Application Code in a form
-       suitable for, and under terms that permit, the user to
-       recombine or relink the Application with a modified version of
-       the Linked Version to produce a modified Combined Work, in the
-       manner specified by section 6 of the GNU GPL for conveying
-       Corresponding Source.
-
-       1) Use a suitable shared library mechanism for linking with the
-       Library.  A suitable mechanism is one that (a) uses at run time
-       a copy of the Library already present on the user's computer
-       system, and (b) will operate properly with a modified version
-       of the Library that is interface-compatible with the Linked
-       Version.
-
-   e) Provide Installation Information, but only if you would otherwise
-   be required to provide such information under section 6 of the
-   GNU GPL, and only to the extent that such information is
-   necessary to install and execute a modified version of the
-   Combined Work produced by recombining or relinking the
-   Application with a modified version of the Linked Version. (If
-   you use option 4d0, the Installation Information must accompany
-   the Minimal Corresponding Source and Corresponding Application
-   Code. If you use option 4d1, you must provide the Installation
-   Information in the manner specified by section 6 of the GNU GPL
-   for conveying Corresponding Source.)
-
-  5. Combined Libraries.
-
-  You may place library facilities that are a work based on the
-Library side by side in a single library together with other library
-facilities that are not Applications and are not covered by this
-License, and convey such a combined library under terms of your
-choice, if you do both of the following:
-
-   a) Accompany the combined library with a copy of the same work based
-   on the Library, uncombined with any other library facilities,
-   conveyed under the terms of this License.
-
-   b) Give prominent notice with the combined library that part of it
-   is a work based on the Library, and explaining where to find the
-   accompanying uncombined form of the same work.
-
-  6. Revised Versions of the GNU Lesser General Public License.
-
-  The Free Software Foundation may publish revised and/or new versions
-of the GNU Lesser General Public License from time to time. Such new
-versions will be similar in spirit to the present version, but may
-differ in detail to address new problems or concerns.
-
-  Each version is given a distinguishing version number. If the
-Library as you received it specifies that a certain numbered version
-of the GNU Lesser General Public License "or any later version"
-applies to it, you have the option of following the terms and
-conditions either of that published version or of any later version
-published by the Free Software Foundation. If the Library as you
-received it does not specify a version number of the GNU Lesser
-General Public License, you may choose any version of the GNU Lesser
-General Public License ever published by the Free Software Foundation.
-
-  If the Library as you received it specifies that a proxy can decide
-whether future versions of the GNU Lesser General Public License shall
-apply, that proxy's public statement of acceptance of any version is
-permanent authorization for you to choose that version for the
-Library.
diff --git a/rboinc/server/etc/default_hills_file b/rboinc/server/etc/default_hills_file
deleted file mode 100644
index e69de29..0000000
diff --git a/rboinc/server/etc/default_idx_file b/rboinc/server/etc/default_idx_file
deleted file mode 100644
index 593f470..0000000
Binary files a/rboinc/server/etc/default_idx_file and /dev/null differ
diff --git a/rboinc/server/etc/default_metadata_file b/rboinc/server/etc/default_metadata_file
deleted file mode 100644
index 2ad4d16..0000000
--- a/rboinc/server/etc/default_metadata_file
+++ /dev/null
@@ -1 +0,0 @@
-No description supplied for this job.
diff --git a/rboinc/server/etc/default_metainp_file b/rboinc/server/etc/default_metainp_file
deleted file mode 100644
index 9052ed5..0000000
--- a/rboinc/server/etc/default_metainp_file
+++ /dev/null
@@ -1,2 +0,0 @@
-NOTE This is an empty metainp_file, likely generated by error
-ENDMETA
diff --git a/rboinc/server/etc/rboinc_httpd_conf b/rboinc/server/etc/rboinc_httpd_conf
deleted file mode 100644
index d1c8f52..0000000
--- a/rboinc/server/etc/rboinc_httpd_conf
+++ /dev/null
@@ -1,102 +0,0 @@
-# -*- Conf -*-
-# Remoteboinc additions to apache
-# Toni Giorgino (c) 2009
-
-# Beware to disable the DocumentRoot possibly defined elsewhere
-
-
-# Note that the trailing slash is important
-
-Listen 8484
-DocumentRoot "/home/ps3grid/remote/apache/root/"
-
-<Directory "/home/ps3grid/remote/apache/root/">
-
-#
-# Possible values for the Options directive are "None", "All",
-# or any combination of:
-#   Indexes Includes FollowSymLinks SymLinksifOwnerMatch ExecCGI MultiViews
-#
-# Note that "MultiViews" must be named *explicitly* --- "Options All"
-# doesn't give it to you.
-#
-# The Options directive is both complicated and important.  Please see
-# http://httpd.apache.org/docs/2.2/mod/core.html#options
-# for more information.
-#
-    Options Indexes FollowSymLinks
-
-#
-# AllowOverride controls what directives may be placed in .htaccess files.
-# It can be "All", "None", or any combination of the keywords:
-#   Options FileInfo AuthConfig Limit
-#
-    AllowOverride None
-
-#
-# Controls who can get stuff from this server.
-#
-    Order allow,deny
-    Allow from all
-
-</Directory>
-
-
-
-# Part I: WebDAV access
-
-
-# Note that the DAVLockDB directive must be commented 
-# in the main configuration file
-
-# Remember to make the dir writable to apache
-
-
-DAVLockDB lockdb
-
-<Directory "/home/ps3grid/remote/apache/DAV">
-    Dav On
-
-    Order Allow,Deny
-    Allow from all
-
-    AuthType Digest
-    AuthName DAV-upload
-    
-    Options +MultiViews +Indexes +FollowSymLinks
-
-    # You can use the htdigest program to create the password database:
-    #   htdigest -c "/home/toni/Apps/apache//user.passwd" DAV-upload admin
-    AuthUserFile "/home/boincadm/RemoteBoincProject/server/user.passwd"
-    AuthDigestProvider file
-
-
-    # Allow universal read-access, but writes are restricted
-    # to the admin user.
-#    <LimitExcept GET OPTIONS>
-#        require user admin
-#    </LimitExcept>
-</Directory>
-Alias /DAV /home/ps3grid/remote/apache/DAV
-
-
-
-
-
-
-
-# Part II: CGI Access
-# Make sure cgis are executable
-
-
-<Directory "/home/ps3grid/remote/apache/cgi-bin">
-        Options ExecCGI
-        AllowOverride AuthConfig
-        Order allow,deny
-        Allow from all
-</Directory>
-ScriptAlias /rboinc_cgi /home/ps3grid/remote/apache/cgi-bin
-
-
-
-
diff --git a/rboinc/server/etc/templates/rboinc_metabeta_result b/rboinc/server/etc/templates/rboinc_metabeta_result
deleted file mode 100644
index 01cb032..0000000
--- a/rboinc/server/etc/templates/rboinc_metabeta_result
+++ /dev/null
@@ -1,110 +0,0 @@
-<file_info>
-    <name><OUTFILE_0/></name>
-    <generated_locally/>
-    <upload_when_present/>
-    <max_nbytes>100000000</max_nbytes>
-    <url><UPLOAD_URL/></url>
-    <gzip_when_done/>
-    <rboinc aliases=".log.gz .log .log.gz.bad"/>
-</file_info>
-<file_info>
-    <name><OUTFILE_1/></name>
-    <generated_locally/>
-    <upload_when_present/>
-    <max_nbytes>50000000</max_nbytes>
-    <url><UPLOAD_URL/></url>
-    <rboinc aliases=".coor" chain="2"/>
-</file_info>
-<file_info>
-    <name><OUTFILE_2/></name>
-    <generated_locally/>
-    <upload_when_present/>
-    <max_nbytes>50000000</max_nbytes>
-    <url><UPLOAD_URL/></url>
-    <rboinc aliases=".vel" chain="3"/>
-</file_info>
-<file_info>
-    <name><OUTFILE_3/></name>
-    <generated_locally/>
-    <upload_when_present/>
-    <max_nbytes>50000000</max_nbytes>
-    <url><UPLOAD_URL/></url>
-    <rboinc aliases=".idx" chain="4"/>
-</file_info>
-<file_info>
-    <name><OUTFILE_4/></name>
-    <generated_locally/>
-    <upload_when_present/>
-    <max_nbytes>128000000</max_nbytes>
-    <url><UPLOAD_URL/></url>
-    <gzip_when_done/>
-    <rboinc aliases=".dcd.gz .dcd .dcd.gz.bad"/>
-</file_info>
-<file_info>
-    <name><OUTFILE_5/></name>
-    <generated_locally/>
-    <upload_when_present/>
-    <max_nbytes>10000000</max_nbytes>
-    <url><UPLOAD_URL/></url>
-    <gzip_when_done/>
-    <rboinc aliases=".colvar.gz .colvar"/>
-</file_info>
-<file_info>
-    <name><OUTFILE_6/></name>
-    <generated_locally/>
-    <upload_when_present/>
-    <max_nbytes>10000000</max_nbytes>
-    <url><UPLOAD_URL/></url>
-    <gzip_when_done/>
-    <rboinc aliases=".plumedlog.gz .plumedlog"/>
-</file_info>
-<file_info>
-    <name><OUTFILE_7/></name>
-    <generated_locally/>
-    <upload_when_present/>
-    <max_nbytes>10000000</max_nbytes>
-    <url><UPLOAD_URL/></url>
-    <rboinc chain="10" aliases=".hills"/>
-</file_info>
-<result>
-    <file_ref>
-        <file_name><OUTFILE_0/></file_name>
-        <open_name>progress.log</open_name>
-    </file_ref>
-    <file_ref>
-        <file_name><OUTFILE_1/></file_name>
-        <open_name>output.coor</open_name>
-    </file_ref>
-    <file_ref>
-        <file_name><OUTFILE_2/></file_name>
-        <open_name>output.vel</open_name>
-    </file_ref>
-    <file_ref>
-        <file_name><OUTFILE_3/></file_name>
-        <open_name>output.idx</open_name>
-    </file_ref>
-    <file_ref>
-        <file_name><OUTFILE_4/></file_name>
-        <open_name>output.dcd</open_name>
-        <optional/>
-    </file_ref>
-    <file_ref>
-        <file_name><OUTFILE_5/></file_name>
-        <open_name>COLVAR</open_name>
-        <copy_file/>
-        <optional/>
-    </file_ref>
-    <file_ref>
-        <file_name><OUTFILE_6/></file_name>
-        <open_name>log.file</open_name>
-        <copy_file/>
-        <optional/>
-    </file_ref>
-    <file_ref>
-        <file_name><OUTFILE_7/></file_name>
-        <open_name>HILLS</open_name>
-        <copy_file/>
-        <optional/>
-    </file_ref>
-</result>
-
diff --git a/rboinc/server/etc/templates/rboinc_metabeta_wu b/rboinc/server/etc/templates/rboinc_metabeta_wu
deleted file mode 100644
index f8875ab..0000000
--- a/rboinc/server/etc/templates/rboinc_metabeta_wu
+++ /dev/null
@@ -1,115 +0,0 @@
-<rboinc application="acemdbeta"
-	description="Standard ACEMD run with optional DCD and PLUMED"/>
-<file_info>
-	<number>0</number>
-</file_info>
-<file_info>
-	<number>1</number>
-</file_info>
-<file_info>
-	<number>2</number>
-</file_info>
-<file_info>
-	<number>3</number>
-</file_info>
-<file_info>
-	<number>4</number>
-</file_info>
-<file_info>
-	<number>5</number>
-</file_info>
-<file_info>
-	<number>6</number>
-</file_info>
-<file_info>
-	<number>7</number>
-</file_info>
-<file_info>
-	<number>8</number>
-</file_info>
-<file_info>
-	<number>9</number>
-</file_info>
-<file_info>
-	<number>10</number>
-</file_info>
-<workunit>
-    <file_ref>
-        <file_number>0</file_number>
-        <open_name>LICENSE</open_name>
-	<rboinc immutable="true"/>
-    </file_ref>
-    <file_ref>
-        <file_number>1</file_number>
-        <open_name>COPYRIGHT</open_name>
-        <rboinc immutable="true"/>
-    </file_ref>
-    <file_ref>
-        <file_number>2</file_number>
-        <open_name>input.coor</open_name>
-        <copy_file/>
-	<rboinc parameter_name="coor_file" 
-		parameter_description="Binary coordinates"
-		/>
-    </file_ref>
-    <file_ref>
-        <file_number>3</file_number>
-        <open_name>input.vel</open_name>
-        <copy_file/>
-	<rboinc parameter_name="vel_file"
-		parameter_description="Binary velocities"
-		/>
-    </file_ref>
-    <file_ref>
-        <file_number>4</file_number>
-        <open_name>input.idx</open_name>
-        <copy_file/>
-	<rboinc parameter_name="idx_file" optional="true" />
-    </file_ref>
-    <file_ref>
-        <file_number>5</file_number>
-        <open_name>structure.pdb</open_name>
-	<rboinc parameter_name="pdb_file"
-		parameter_description="PDB structure"/>
-    </file_ref>
-    <file_ref>
-        <file_number>6</file_number>
-        <open_name>structure.psf</open_name>
-	<rboinc parameter_name="psf_file"
-		parameter_description="PSF topology"/>
-    </file_ref>
-    <file_ref>
-        <file_number>7</file_number>
-        <open_name>parameters</open_name>
-	<rboinc parameter_name="par_file"
-		parameter_description="CHARMM parameters"/>
-    </file_ref>
-    <file_ref>
-        <file_number>8</file_number>
-        <open_name>input</open_name>
-	<rboinc parameter_name="conf_file"
-		parameter_description="ACEMD input file"
-		encode="true" />
-    </file_ref>
-    <file_ref>
-        <file_number>9</file_number>
-        <open_name>META_INP</open_name>
-        <copy_file/>
-	<rboinc parameter_name="metainp_file"
-		parameter_description="PLUMED metadynamics configuration"
-		optional="true" />
-    </file_ref>
-    <file_ref>
-        <file_number>10</file_number>
-        <open_name>HILLS</open_name>
-        <copy_file/>
-	<rboinc parameter_name="hills_file"
-		parameter_description="PLUMED metadynamics restart"
-		optional="true" />
-    </file_ref>
-    <rsc_fpops_est>250e12</rsc_fpops_est>
-    <rsc_fpops_bound>12.5e15</rsc_fpops_bound>
-      <rsc_disk_bound>200000000</rsc_disk_bound>
-    <rsc_memory_bound>100000000</rsc_memory_bound>
-    <delay_bound>432000</delay_bound>
-</workunit>
diff --git a/rboinc/server/etc/user.passwd b/rboinc/server/etc/user.passwd
deleted file mode 100644
index 043bd4b..0000000
--- a/rboinc/server/etc/user.passwd
+++ /dev/null
@@ -1 +0,0 @@
-admin:DAV-upload:0c7c7b886e911bb01cbadaad15dc1d3b
diff --git a/rboinc/server/test/test.cgi b/rboinc/server/test/test.cgi
deleted file mode 100755
index 5ed6966..0000000
--- a/rboinc/server/test/test.cgi
+++ /dev/null
@@ -1,5 +0,0 @@
-#!/usr/bin/perl
-
-
-print "Content-type: text/plain\n\nHet werkt!\n";
-print "$_ = '$ENV{ $_ }'\n" for sort keys %ENV;
diff --git a/rboinc/server/test/test_authentication.pl b/rboinc/server/test/test_authentication.pl
deleted file mode 100644
index a0fed82..0000000
--- a/rboinc/server/test/test_authentication.pl
+++ /dev/null
@@ -1,20 +0,0 @@
-#!/usr/bin/perl -w
-
-# $Id$
-
-# An authentication test script
-
-
-require "./boinc_authentication.pl";
-
-my $project_url='http://xxxx.org/LUNA';
-my $email='yyyy at gmail.com';
-my $password='zzzzz';
-
-
-print lookup_email($project_url,$email);
-print "\n\n";
-
-print lookup_email_password($project_url,$email,$password);
-print "\n\n";
-
diff --git a/sched/adjust_user_priority.cpp b/sched/adjust_user_priority.cpp
index ac64af4..0866a6e 100644
--- a/sched/adjust_user_priority.cpp
+++ b/sched/adjust_user_priority.cpp
@@ -80,7 +80,7 @@ int main(int argc, char** argv) {
     }
 
     DB_APP app;
-    sprintf(buf, "where name='%s'", app_name);
+    snprintf(buf, sizeof(buf), "where name='%s'", app_name);
     retval = app.lookup(buf);
     if (retval) {
         fprintf(stderr, "no such app %s\n", argv[3]);
diff --git a/sched/assimilator.cpp b/sched/assimilator.cpp
index 1d551e1..d025bff 100644
--- a/sched/assimilator.cpp
+++ b/sched/assimilator.cpp
@@ -294,6 +294,7 @@ int main(int argc, char** argv) {
         exit(1);
     }
     install_stop_signal_handler();
+    // coverity[loop_top] - infinite loop is intended
     do {
         if (!do_pass(app)) {
             if (!one_pass) {
diff --git a/sched/db_dump.cpp b/sched/db_dump.cpp
index 97c8dd8..a90046b 100644
--- a/sched/db_dump.cpp
+++ b/sched/db_dump.cpp
@@ -225,6 +225,7 @@ public:
             log_messages.printf(MSG_CRITICAL,
                 "Couldn't open %s for output\n", filename
             );
+            exit(ERR_FOPEN);
         }
         fprintf(f,
             "<?xml version=\"1.0\" encoding=\"iso-8859-1\"?>\n<%s>\n", tag.c_str()
@@ -485,11 +486,11 @@ void write_user(USER& user, FILE* f, bool /*detail*/) {
 void write_badge_user(char* output_dir) {
     DB_BADGE_USER bu;
     char path[MAXPATHLEN];
-    ZFILE* f = new ZFILE("badge_users", COMPRESSION_GZIP);
+    ZFILE zf("badge_users", COMPRESSION_GZIP);
     sprintf(path, "%s/badge_user", output_dir);
-    f->open(path);
+    zf.open(path);
     while (!bu.enumerate("")) {
-        fprintf(f->f,
+        fprintf(zf.f,
             " <badge_user>\n"
             "    <user_id>%d</user_id>\n"
             "    <badge_id>%d</badge_id>\n"
@@ -500,17 +501,17 @@ void write_badge_user(char* output_dir) {
             bu.create_time
         );
     }
-    f->close();
+    zf.close();
 }
 
 void write_badge_team(char* output_dir) {
     DB_BADGE_TEAM bt;
     char path[MAXPATHLEN];
-    ZFILE* f = new ZFILE("badge_teams", COMPRESSION_GZIP);
+    ZFILE zf("badge_teams", COMPRESSION_GZIP);
     sprintf(path, "%s/badge_team", output_dir);
-    f->open(path);
+    zf.open(path);
     while (!bt.enumerate("")) {
-        fprintf(f->f,
+        fprintf(zf.f,
             " <badge_team>\n"
             "    <team_id>%d</team_id>\n"
             "    <badge_id>%d</badge_id>\n"
@@ -521,7 +522,7 @@ void write_badge_team(char* output_dir) {
             bt.create_time
         );
     }
-    f->close();
+    zf.close();
 }
 
 void write_team(TEAM& team, FILE* f, bool detail) {
@@ -681,23 +682,23 @@ void print_badges(FILE* f) {
 int tables_file(char* dir) {
     char buf[256];
 
-    ZFILE f("tables", false);
+    ZFILE zf("tables", false);
     sprintf(buf, "%s/tables.xml", dir);
-    f.open(buf);
-    fprintf(f.f,
+    zf.open(buf);
+    fprintf(zf.f,
         "    <update_time>%d</update_time>\n",
         (int)time(0)
     );
     if (config.credit_by_app) {
-        fprintf(f.f, "    <credit_by_app/>\n");
+        fprintf(zf.f, "    <credit_by_app/>\n");
     }
-    if (nusers) fprintf(f.f, "    <nusers_total>%d</nusers_total>\n", nusers);
-    if (nteams) fprintf(f.f, "    <nteams_total>%d</nteams_total>\n", nteams);
-    if (nhosts) fprintf(f.f, "    <nhosts_total>%d</nhosts_total>\n", nhosts);
-    if (total_credit) fprintf(f.f, "    <total_credit>%lf</total_credit>\n", total_credit);
-    print_apps(f.f);
-    print_badges(f.f);
-    f.close();
+    if (nusers) fprintf(zf.f, "    <nusers_total>%d</nusers_total>\n", nusers);
+    if (nteams) fprintf(zf.f, "    <nteams_total>%d</nteams_total>\n", nteams);
+    if (nhosts) fprintf(zf.f, "    <nhosts_total>%d</nhosts_total>\n", nhosts);
+    if (total_credit) fprintf(zf.f, "    <total_credit>%lf</total_credit>\n", total_credit);
+    print_apps(zf.f);
+    print_badges(zf.f);
+    zf.close();
     return 0;
 }
 
@@ -818,8 +819,14 @@ int ENUMERATION::make_it_happen(char* output_dir) {
     }
     for (i=0; i<outputs.size(); i++) {
         OUTPUT& out = outputs[i];
-        if (out.zfile) out.zfile->close();
-        if (out.nzfile) out.nzfile->close();
+        if (out.zfile) {
+          out.zfile->close();
+          delete out.zfile;
+        }
+        if (out.nzfile) {
+          out.nzfile->close();
+          delete out.nzfile;
+        }
     }
     return 0;
 }
@@ -870,6 +877,8 @@ int main(int argc, char** argv) {
                 exit(1);
             }
             retry_period = atoi(argv[i]);
+            if (retry_period < 0) retry_period = 0;
+            if (retry_period > 1000000) retry_period = 1000000;
         } else if (is_arg(argv[i], "d") || is_arg(argv[i], "debug_level")) {
             if (!argv[++i]) {
                 log_messages.printf(MSG_CRITICAL, "%s requires an argument\n\n", argv[--i]);
@@ -988,7 +997,7 @@ int main(int argc, char** argv) {
         write_badge_team(spec.output_dir);
     }
 
-    sprintf(buf, "cp %s %s/db_dump.xml", spec_filename, spec.output_dir);
+    snprintf(buf, sizeof(buf), "cp %s %s/db_dump.xml", spec_filename, spec.output_dir);
     retval = system(buf);
     if (retval) {
         log_messages.printf(MSG_CRITICAL,
diff --git a/sched/db_purge.cpp b/sched/db_purge.cpp
index 0bb2e31..a85acab 100644
--- a/sched/db_purge.cpp
+++ b/sched/db_purge.cpp
@@ -138,15 +138,15 @@ void open_archive(const char* filename_prefix, FILE*& f){
         );
     }
     // append appropriate suffix for file type
-    strcat(path, suffix[compression_type]);
+    safe_strcat(path, suffix[compression_type]);
 
     // and construct appropriate command if needed
     if (compression_type == COMPRESSION_GZIP) {
-        sprintf(command, "gzip - > %s", path);
+        snprintf(command, sizeof(command), "gzip - > %s", path);
     }
 
     if (compression_type == COMPRESSION_ZIP) {
-        sprintf(command, "zip - - > %s", path);
+        snprintf(command, sizeof(command), "zip - - > %s", path);
     }
 
     log_messages.printf(MSG_NORMAL,
@@ -213,7 +213,7 @@ void close_archive(const char *filename, FILE*& fp){
         );
     }
     // append appropriate file type
-    strcat(path, suffix[compression_type]);
+    safe_strcat(path, suffix[compression_type]);
 
     log_messages.printf(MSG_NORMAL,
         "Closed archive file %s containing records of %d workunits\n",
@@ -731,7 +731,7 @@ int main(int argc, char** argv) {
             id_modulus   = atoi(argv[++i]);
             id_remainder = atoi(argv[++i]);
         } else if (is_arg(argv[i], "app")) {
-            strcpy(app_name, argv[++i]);
+            safe_strcpy(app_name, argv[++i]);
         } else {
             log_messages.printf(MSG_CRITICAL,
                 "unknown command line argument: %s\n\n", argv[i]
diff --git a/sched/edf_sim.h b/sched/edf_sim.h
index 7c40f25..b1f7db3 100644
--- a/sched/edf_sim.h
+++ b/sched/edf_sim.h
@@ -36,14 +36,23 @@ struct IP_RESULT {
     bool misses_deadline;
     double estimated_completion_time;
 
-    IP_RESULT() {}
+    void init() {
+        strcpy(name, "");
+        computation_deadline = 0;
+        report_deadline = 0;
+        cpu_time_remaining = 0;
+        misses_deadline = false;
+        estimated_completion_time = 0;
+    }
+    IP_RESULT() {
+        init();
+    }
     IP_RESULT(const char* n, double d, double c) {
+        init();
         safe_strcpy(name, n);
         report_deadline = d;
         computation_deadline = d;
         cpu_time_remaining = c;
-        misses_deadline = false;
-        estimated_completion_time = 0;
     }
 };
 
diff --git a/sched/feeder.cpp b/sched/feeder.cpp
index 72bba21..90180c2 100644
--- a/sched/feeder.cpp
+++ b/sched/feeder.cpp
@@ -414,8 +414,12 @@ static void update_job_stats() {
         sum += e;
         sum_sqr += e*e;
     }
-    double mean = sum/n;
-    double stdev = sqrt((sum_sqr - sum*mean)/n);
+    double mean = 0;
+    double stdev = 1;
+    if (n != 0) {
+        mean = sum/n;
+        stdev = sqrt((sum_sqr - sum*mean)/n);
+    }
     for (i=0; i<ssp->max_wu_results; i++) {
         WU_RESULT& wu_result = ssp->wu_results[i];
         if (wu_result.state != WR_STATE_PRESENT) continue;
@@ -556,10 +560,7 @@ void feeder_loop() {
     
     // may need one enumeration per app; create vector
     //
-    for (int i=0; i<napps; i++) {
-        DB_WORK_ITEM* wi = new DB_WORK_ITEM();
-        work_items.push_back(*wi);
-    }
+    work_items.resize(napps);
 
     while (1) {
         bool action;
@@ -774,7 +775,7 @@ int main(int argc, char** argv) {
                 exit(1);
             }
             strcat(mod_select_clause, " and workunit.appid in (");
-            strcat(mod_select_clause, argv[i]);
+            safe_strcat(mod_select_clause, argv[i]);
             strcat(mod_select_clause, ")");
         } else if (is_arg(argv[i], "mod")) {
             if (!argv[i+1] || !argv[i+2]) {
diff --git a/sched/file_deleter.cpp b/sched/file_deleter.cpp
index b53a3b5..7af3088 100644
--- a/sched/file_deleter.cpp
+++ b/sched/file_deleter.cpp
@@ -371,7 +371,7 @@ bool do_pass(bool retry_error) {
 
     if (xml_doc_like) {
         strcat(clause, " and xml_doc like '");
-        strcat(clause, xml_doc_like);
+        safe_strcat(clause, xml_doc_like);
         strcat(clause, "'");
     }
     sprintf(buf,
@@ -596,6 +596,7 @@ int main(int argc, char** argv) {
 
     bool retry_errors_now = !dont_retry_errors;
     double next_error_time=0;
+    // coverity[loop_top] - infinite loop is intended
     while (1) {
         bool got_any = do_pass(false);
         if (retry_errors_now) {
diff --git a/sched/file_upload_handler.cpp b/sched/file_upload_handler.cpp
index a3f55b9..8ac725c 100644
--- a/sched/file_upload_handler.cpp
+++ b/sched/file_upload_handler.cpp
@@ -154,6 +154,7 @@ int copy_socket_to_file(FILE* in, char* path, double offset, double nbytes) {
             // Advisory file locking is not guaranteed reliable when
             // used with stream buffered IO.
             //
+            // coverity[toctou]
             fd = open(path,
                 O_WRONLY|O_CREAT,
                 S_IRUSR|S_IWUSR|S_IRGRP|S_IWGRP|S_IROTH
@@ -198,7 +199,18 @@ int copy_socket_to_file(FILE* in, char* path, double offset, double nbytes) {
                     path, (int)sbuf.st_size, offset
                 );
             }
-            if (offset) lseek(fd, offset, SEEK_SET);
+            if (offset) {
+                if (-1 == lseek(fd, offset, SEEK_SET)) {
+                    log_messages.printf(MSG_CRITICAL,
+                        "lseek(%s, %.0f) failed: %s (%d).\n",
+                        this_filename, offset, strerror(errno), errno
+                    );
+                    close(fd);
+                    return return_error(ERR_TRANSIENT,
+                        "can't resume partial file %s: %s\n", path, strerror(errno)
+                );
+                }
+            }
             if (sbuf.st_size > offset) {
                 log_messages.printf(MSG_CRITICAL,
                     "file %s length on disk %d bytes; host upload starting at %.0f bytes.\n",
@@ -522,7 +534,6 @@ int handle_request(FILE* in, R_RSA_PUBLIC_KEY& key) {
     char buf[256];
     char file_name[256];
     int major, minor, release, retval=0;
-    bool got_version = true;
     bool did_something = false;
     double start_time = dtime();
 
@@ -538,23 +549,14 @@ int handle_request(FILE* in, R_RSA_PUBLIC_KEY& key) {
         } else if (parse_int(buf, "<core_client_release>", release)) {
             continue;
         } else if (match_tag(buf, "<file_upload>")) {
-
-            if (!got_version) {
-                retval = return_error(ERR_PERMANENT, "Missing version");
-            } else {
-                retval = handle_file_upload(in, key);
-            }
+            retval = handle_file_upload(in, key);
             did_something = true;
             break;
         } else if (parse_str(buf, "<get_file_size>", file_name, sizeof(file_name))) {
             if (strstr(file_name, "..")) {
                 return return_error(ERR_PERMANENT, "Bad filename");
             }
-            if (!got_version) {
-                retval = return_error(ERR_PERMANENT, "Missing version");
-            } else {
-                retval = handle_get_file_size(file_name);
-            }
+            retval = handle_get_file_size(file_name);
             did_something = true;
             break;
         } else if (match_tag(buf, "<data_server_request>")) {
@@ -667,7 +669,9 @@ int main(int argc, char *argv[]) {
 
     installer();
 
-    get_log_path(log_path, "file_upload_handler.log");
+    if (get_log_path(log_path, "file_upload_handler.log") == ERR_MKDIR) {
+        fprintf(stderr, "Can't create log directory '%s'  (errno: %d)\n", log_path, errno);
+    }
 #ifndef _USING_FCGI_
     if (!freopen(log_path, "a", stderr)) {
         fprintf(stderr, "Can't open log file '%s' (errno: %d)\n",
diff --git a/sched/message_handler.cpp b/sched/message_handler.cpp
index be41de0..c409648 100644
--- a/sched/message_handler.cpp
+++ b/sched/message_handler.cpp
@@ -116,6 +116,7 @@ int main_loop(bool one_pass) {
         exit(1);
     }
 */
+    // coverity[loop_top] - infinite loop is intended
     while (1) {
         check_stop_daemons();
         did_something = do_message_scan();
diff --git a/sched/sample_assimilator.cpp b/sched/sample_assimilator.cpp
index f311655..453fe1a 100644
--- a/sched/sample_assimilator.cpp
+++ b/sched/sample_assimilator.cpp
@@ -77,6 +77,7 @@ int assimilate_handler(
                 "sample_results/%s_%s", wu.name, "no_output_files"
             );
             FILE* f = fopen(copy_path, "w");
+            if (!f) return ERR_FOPEN;
             fclose(f);
         }
     } else {
diff --git a/sched/sample_bitwise_validator.cpp b/sched/sample_bitwise_validator.cpp
index f3c1b94..bd3891d 100644
--- a/sched/sample_bitwise_validator.cpp
+++ b/sched/sample_bitwise_validator.cpp
@@ -81,6 +81,7 @@ int init_result(RESULT& result, void*& data) {
             "[RESULT#%u %s] check_set: can't get output filenames\n",
             result.id, result.name
         );
+        delete fcl;
         return retval;
     }
 
diff --git a/sched/sample_work_generator.cpp b/sched/sample_work_generator.cpp
index a9ff371..896d515 100644
--- a/sched/sample_work_generator.cpp
+++ b/sched/sample_work_generator.cpp
@@ -242,13 +242,13 @@ int main(int argc, char** argv) {
         exit(1);
     }
 
-    sprintf(buf, "where name='%s'", app_name);
+    snprintf(buf, sizeof(buf), "where name='%s'", app_name);
     if (app.lookup(buf)) {
         log_messages.printf(MSG_CRITICAL, "can't find app %s\n", app_name);
         exit(1);
     }
 
-    sprintf(buf, "templates/%s", in_template_file);
+    snprintf(buf, sizeof(buf), "templates/%s", in_template_file);
     if (read_file_malloc(config.project_path(buf), in_template)) {
         log_messages.printf(MSG_CRITICAL, "can't read input template %s\n", buf);
         exit(1);
diff --git a/sched/sched_array.cpp b/sched/sched_array.cpp
index b4a5a16..b0b93a9 100644
--- a/sched/sched_array.cpp
+++ b/sched/sched_array.cpp
@@ -437,7 +437,7 @@ void send_work_old() {
                 "[send_scan] scanning for jobs from non-preferred applications\n"
             );
         }
-        scan_work_array();
+        if (scan_work_array()) return;
     }
 }
 
diff --git a/sched/sched_config.cpp b/sched/sched_config.cpp
index 0a2870e..ce1091e 100644
--- a/sched/sched_config.cpp
+++ b/sched/sched_config.cpp
@@ -374,9 +374,9 @@ int SCHED_CONFIG::download_path(const char* filename, char* path) {
 
 static bool is_project_dir(const char* dir) {
     char buf[1024];
-    sprintf(buf, "%s/%s", dir, CONFIG_FILE);
+    snprintf(buf, sizeof(buf), "%s/%s", dir, CONFIG_FILE);
     if (!is_file_follow_symlinks(buf)) return false;
-    sprintf(buf, "%s/cgi-bin", dir);
+    snprintf(buf, sizeof(buf), "%s/cgi-bin", dir);
     if (!is_dir_follow_symlinks(buf)) return false;
     return true;
 }
diff --git a/sched/sched_driver.cpp b/sched/sched_driver.cpp
index e999a01..89ec8b0 100644
--- a/sched/sched_driver.cpp
+++ b/sched/sched_driver.cpp
@@ -74,14 +74,14 @@ void read_hosts() {
         HOST_DESC hd;
         safe_strcpy(buf2, buf);
         char* p1 = strtok(buf2, "\t\n");
-        safe_strcpy(hd.os_name, p1);
         char* p2 = strtok(0, "\t\n");
-        safe_strcpy(hd.p_vendor, p2);
         char* p3 = strtok(0, "\t\n");
-        if (!p3) {
+        if (!p1 || !p2 || !p3) {
             fprintf(stderr, "bad line: %s\n", buf);
             exit(1);
         }
+        safe_strcpy(hd.os_name, p1);
+        safe_strcpy(hd.p_vendor, p2);
         safe_strcpy(hd.p_model, p3);
         host_descs.push_back(hd);
     }
diff --git a/sched/sched_main.cpp b/sched/sched_main.cpp
index 45a539f..5ad6365 100644
--- a/sched/sched_main.cpp
+++ b/sched/sched_main.cpp
@@ -423,7 +423,9 @@ int main(int argc, char** argv) {
         }
     } else {
         char *stderr_buffer;
-        get_log_path(path, "scheduler.log");
+        if (get_log_path(path, "scheduler.log") == ERR_MKDIR) {
+            fprintf(stderr, "Can't create log directory '%s'  (errno: %d)\n", path, errno);
+        }
 #ifndef _USING_FCGI_
         char buf[256];
         if (!freopen(path, "a", stderr)) {
diff --git a/sched/sched_send.cpp b/sched/sched_send.cpp
index adbc27a..8bc1763 100644
--- a/sched/sched_send.cpp
+++ b/sched/sched_send.cpp
@@ -573,6 +573,7 @@ static int insert_after(char* buffer, const char* after, const char* text) {
         return ERR_XML_PARSE;
     }
     p += strlen(after);
+    // coverity[fixed_size_dest]
     strcpy(temp, p);
     strcpy(p, text);
     strcat(p, temp);
diff --git a/sched/sched_types.cpp b/sched/sched_types.cpp
index d133929..a176ffc 100644
--- a/sched/sched_types.cpp
+++ b/sched/sched_types.cpp
@@ -177,6 +177,48 @@ void WORK_REQ::add_no_work_message(const char* message) {
     no_work_messages.push_back(USER_MESSAGE(message, "notice"));
 }
 
+SCHEDULER_REQUEST::SCHEDULER_REQUEST() {
+    clear();
+}
+
+void SCHEDULER_REQUEST::clear() {
+    strcpy(authenticator, "");
+    strcpy(cross_project_id, "");
+    hostid = 0;
+    core_client_major_version = 0;
+    core_client_minor_version = 0;
+    core_client_release = 0;
+    core_client_version = 0;
+    rpc_seqno = 0;
+    work_req_seconds = 0;
+    cpu_req_secs = 0;
+    cpu_req_instances = 0;
+    resource_share_fraction = 0;
+    rrs_fraction = 0;
+    prrs_fraction = 0;
+    cpu_estimated_delay = 0;
+    duration_correction_factor = 0;
+    uptime = 0;
+    previous_uptime = 0;
+    strcpy(global_prefs_xml, "");
+    strcpy(working_global_prefs_xml, "");
+    strcpy(code_sign_key, "");
+    dont_send_work = false;
+    strcpy(client_brand, "");
+    global_prefs.defaults();
+    strcpy(global_prefs_source_email_hash, "");
+    results_truncated = false;
+    have_other_results_list = false;
+    have_ip_results_list = false;
+    have_time_stats_log = false;
+    client_cap_plan_class = false;
+    sandbox = -1;
+    allow_multiple_clients = -1;
+    using_weak_auth = false;
+    last_rpc_dayofyear = 0;
+    current_rpc_dayofyear = 0;
+}
+
 // return an error message or NULL
 //
 const char* SCHEDULER_REQUEST::parse(XML_PARSER& xp) {
@@ -322,8 +364,12 @@ const char* SCHEDULER_REQUEST::parse(XML_PARSER& xp) {
             continue;
         }
         if (xp.match_tag("time_stats_log")) {
-            handle_time_stats_log(xp.f->f);
-            have_time_stats_log = true;
+            if (handle_time_stats_log(xp.f->f)) {
+                log_messages.printf(MSG_NORMAL,
+                    "SCHEDULER_REQUEST::parse(): Couldn't parse contents of <time_stats_log>. Ignoring it.");
+            } else {
+                have_time_stats_log = true;
+            }
             continue;
         }
         if (xp.match_tag("net_stats")) {
diff --git a/sched/sched_types.h b/sched/sched_types.h
index 55350ab..974cdb0 100644
--- a/sched/sched_types.h
+++ b/sched/sched_types.h
@@ -182,9 +182,13 @@ struct BEST_APP_VERSION {
         // get the HOST_APP_VERSION, if any
 
     BEST_APP_VERSION() {
+        appid = 0;
+        for_64b_jobs = false;
         present = false;
         cavp = NULL;
         avp = NULL;
+        reliable = false;
+        trusted = false;
     }
 };
 
@@ -338,8 +342,9 @@ struct SCHEDULER_REQUEST {
     int current_rpc_dayofyear;
     std::string client_opaque;
 
-    SCHEDULER_REQUEST(){};
+    SCHEDULER_REQUEST();
     ~SCHEDULER_REQUEST(){};
+    void clear();
     const char* parse(XML_PARSER&);
     int write(FILE*); // write request info to file: not complete
 };
diff --git a/sched/sched_util_basic.cpp b/sched/sched_util_basic.cpp
index 2381677..2e903ee 100644
--- a/sched/sched_util_basic.cpp
+++ b/sched/sched_util_basic.cpp
@@ -30,6 +30,7 @@
 #include "filesys.h"
 #include "md5_file.h"
 #include "util.h"
+#include "str_replace.h"
 
 #include "sched_config.h"
 #include "sched_msgs.h"
@@ -143,7 +144,7 @@ int try_fopen(const char* path, FCGI_FILE*& f, const char *mode) {
     return 0;
 }
 
-void get_log_path(char* p, const char* filename) {
+int get_log_path(char* p, const char* filename) {
     char host[256];
     const char *dir;
 
@@ -153,10 +154,13 @@ void get_log_path(char* p, const char* filename) {
     dir = config.project_path("log_%s", host);
     sprintf(p, "%s/%s", dir, filename);
     mode_t old_mask = umask(0);
-    mkdir(dir, 01770);
-        // make log_x directory sticky and group-rwx
-        // so that whatever apache puts there will be owned by us
+    // make log_x directory sticky and group-rwx
+    // so that whatever apache puts there will be owned by us
+    int retval = mkdir(dir, 01770);
     umask(old_mask);
+    if (retval && errno != EEXIST) return ERR_MKDIR;
+
+    return 0;
 }
 
 static void filename_hash(const char* filename, int fanout, char* dir) {
@@ -176,13 +180,13 @@ int dir_hier_path(
     int retval;
 
     if (fanout==0) {
-        sprintf(path, "%s/%s", root, filename);
+        snprintf(path, MAXPATHLEN, "%s/%s", root, filename);
         return 0;
     }
 
     filename_hash(filename, fanout, dir);
 
-    sprintf(dirpath, "%s/%s", root, dir);
+    snprintf(dirpath, MAXPATHLEN, "%s/%s", root, dir);
     if (create) {
         retval = boinc_mkdir(dirpath);
         if (retval && (errno != EEXIST)) {
@@ -192,7 +196,7 @@ int dir_hier_path(
             return ERR_MKDIR;
         }
     }
-    sprintf(path, "%s/%s", dirpath, filename);
+    snprintf(path, MAXPATHLEN, "%s/%s", dirpath, filename);
     return 0;
 }
 
@@ -229,6 +233,7 @@ int mylockf(int fd) {
 
     // if lock failed, find out why
     errno=0;
+    // coverity[check_return]
     fcntl(fd, F_GETLK, &fl);
     if (fl.l_pid>0) return fl.l_pid;
     return -1;
@@ -237,7 +242,7 @@ int mylockf(int fd) {
 bool is_arg(const char* x, const char* y) {
     char buf[256];
     strcpy(buf, "--");
-    strcat(buf, y);
+    safe_strcat(buf, y);
     if (!strcmp(buf, x)) return true;
     if (!strcmp(buf+1, x)) return true;
     return false;
diff --git a/sched/sched_util_basic.h b/sched/sched_util_basic.h
index d71f27d..ce30eb7 100644
--- a/sched/sched_util_basic.h
+++ b/sched/sched_util_basic.h
@@ -38,7 +38,7 @@ extern void daemon_sleep(int);
 extern bool check_stop_sched();
 extern void install_stop_signal_handler();
 extern int try_fopen(const char* path, FILE*& f, const char* mode);
-extern void get_log_path(char*, const char*);
+extern int get_log_path(char*, const char*);
 
 // convert filename to path in a hierarchical directory system
 //
diff --git a/sched/sched_version.cpp b/sched/sched_version.cpp
index a7bd76d..68909be 100644
--- a/sched/sched_version.cpp
+++ b/sched/sched_version.cpp
@@ -401,7 +401,7 @@ void estimate_flops(HOST_USAGE& hu, APP_VERSION& av) {
 //
 static void app_version_desc(BEST_APP_VERSION& bav, char* buf) {
     if (!bav.present) {
-        safe_strcpy(buf, "none");
+        strcpy(buf, "none");
         return;
     }
     if (bav.cavp) {
diff --git a/sched/single_job_assimilator.cpp b/sched/single_job_assimilator.cpp
index f2e03569..9ea412f 100644
--- a/sched/single_job_assimilator.cpp
+++ b/sched/single_job_assimilator.cpp
@@ -89,6 +89,10 @@ int assimilate_handler(
     //
     sprintf(filename, "%s/job_summary_%d", job_dir, wu.id);
     f = fopen(filename, "w");
+    if (!f) {
+        log_messages.printf(MSG_CRITICAL, "Can't open job summary file %s\n", filename);
+        return ERR_FOPEN;
+    }
 
     // If job was successful, copy the output files
     //
diff --git a/sched/size_regulator.cpp b/sched/size_regulator.cpp
index 6c4819a..5974686 100644
--- a/sched/size_regulator.cpp
+++ b/sched/size_regulator.cpp
@@ -83,6 +83,8 @@ int main(int argc, char** argv) {
             log_messages.set_debug_level(atoi(argv[++i]));
         } else if (!strcmp(argv[i], "--sleep_time")) {
             sleep_time = atoi(argv[++i]);
+            if (sleep_time < 0) sleep_time = 0;
+            if (sleep_time > 1000000) sleep_time = 1000000;
         } else if (!strcmp(argv[i], "--random_order")) {
             order_clause = " order by random ";
         } else if (!strcmp(argv[i], "--priority_asc")) {
@@ -119,7 +121,7 @@ int main(int argc, char** argv) {
         exit(1);
     }
 
-    sprintf(buf, "where name='%s'", app_name);
+    snprintf(buf, sizeof(buf), "where name='%s'", app_name);
     if (app.lookup(buf)) {
         log_messages.printf(MSG_CRITICAL, "no such app: %s\n", app_name);
         exit(1);
diff --git a/sched/start b/sched/start
index c75fb89..23d9300 100755
--- a/sched/start
+++ b/sched/start
@@ -79,7 +79,7 @@ Both:
 
 import boinc_path_config
 from Boinc import boinc_project_path, configxml
-import sys, os, getopt, time, glob, fcntl, signal, socket, getpass
+import sys, os, getopt, time, glob, fcntl, signal, socket, getpass, shlex
 
 right_now = int(time.time())
 verbose = os.isatty(sys.stdout.fileno())
@@ -160,6 +160,13 @@ def get_task_output_name(task):
     return os.path.join(log_dir,
         task.__dict__.get('output') or get_task_command_basename(task) + '.out')
 
+def get_task_use_shell(task):
+    use_shell = task.__dict__.get('use_shell')
+    if use_shell and use_shell != "0":
+        return 1
+    else:
+        return 0
+
 def get_daemon_output_name(task):
     return os.path.join(log_dir,
         task.__dict__.get('output') or get_task_command_basename(task) + '.log')
@@ -318,17 +325,39 @@ def is_lock_file_locked(filename):
     else:
         os.unlink(filename)
 
+# if a command contains a pipe or a redirection, exec won't work
+# this detects those cases and a shell encapsulation can be used
 def contains_shell_characters(command):
-    return ('"' in command or "'" in command or
-            '\\' in command or '|' in command or
-            '>' in command)
-
-def exec_command_string(command):
-    args = command.strip().split()
+    for item in shlex.split(command):
+        if item == "|":
+            return True
+        if item == ">" or item == ">>" or item == "<":
+            return True
+        if item.startswith("1>") or item.startswith("2>") or item.startswith("&>"):
+            return True
+    return False
+
+# if a line ends with a \ it escapes the newline which then
+# is in front of the first argument of the next line where it needs to be cleaned
+# this enables the use of multiline shell commands within <cmd>
+def strip_leading_escapes(string):
+    if string.startswith("\n"):
+        return string[1:]
+    return string
+
+def command_string_to_list(command):
+    l = shlex.split(command)
+    return map(strip_leading_escapes, l)
+
+def exec_command_string(command, use_shell):
+    args = command_string_to_list(command)
     os.chdir(tmp_dir)
     try:
-        if contains_shell_characters(command):
-            os.execl('/bin/sh', 'sh', '-c', ' '.join(args))
+        if use_shell:
+            # sends a TERM signal to the child processes
+            # if either of INT, QUIT, HUP or TERM is received by the parent
+            command = "trap \"kill 0\" INT QUIT HUP TERM; "+command+"& wait"
+            os.execl('/bin/sh', 'sh', '-c', command)
         else:
             os.execvp( args[0], args )
         # on success we don't reach here
@@ -400,24 +429,34 @@ def run_task(task):
         if verbose:
             print >>sys.stderr, "    Task currently running! (%s)"%task.cmd
         sys.exit(0)
+    if get_task_use_shell(task):
+        print >>sys.stderr, "    Using shell encapsulation for: ",task.cmd
+    elif contains_shell_characters(task.cmd):
+        print >>sys.stderr, "    Couldn't start: ",task.cmd, " <use_shell> is required but was not specified"
+        sys.exit(1)
     redirect(get_task_output_name(task))
-    exec_command_string(task.cmd)
+    exec_command_string(task.cmd, get_task_use_shell(task))
 
 def run_daemon(task):
     '''Double-fork and exec command with stdout/err redirection and pid writing'''
     if double_fork() > 0: return
     if lock_file(get_task_lock_name(task)):
         if verbose:
-            print >>sys.stderr, "  Daemon already running:",task.cmd
+            print >>sys.stderr, "  Daemon already running: ",task.cmd
         sys.exit(0)
     if verbose or ( verbose_daemon_run and not get_daemon_silent_start(task) ):
         print "  Starting daemon:", task.cmd
         sys.stdout.flush()
+    if get_task_use_shell(task):
+        print >>sys.stderr, "  Using shell encapsulation for: ",task.cmd
+    elif contains_shell_characters(task.cmd):
+        print >>sys.stderr, "  Couldn't start: ",task.cmd, " <use_shell> is required but was not specified"
+        sys.exit(1)
     redirect(get_daemon_output_name(task))
     write_pid_file(get_daemon_pid_name(task))
     print "[%s] Executing command:"%timestamp(), task.cmd
     sys.stdout.flush()
-    exec_command_string(task.cmd)
+    exec_command_string(task.cmd, get_task_use_shell(task))
 
 def run_daemons():
     found_any = False
diff --git a/sched/time_stats_log.cpp b/sched/time_stats_log.cpp
index 6a96e2c..a8ec2ca 100644
--- a/sched/time_stats_log.cpp
+++ b/sched/time_stats_log.cpp
@@ -34,8 +34,8 @@ static char* stats_buf = 0;
 // don't write them to disk yet, since we haven't authenticated the host
 //
 
-void handle_time_stats_log(FILE* fin) {
-    dup_element_contents(fin, "</time_stats_log>", &stats_buf);
+int handle_time_stats_log(FILE* fin) {
+    return dup_element_contents(fin, "</time_stats_log>", &stats_buf);
 }
 
 // The host has been authenticated, so write the stats.
diff --git a/sched/time_stats_log.h b/sched/time_stats_log.h
index 6e6f0e7..7d2e731 100644
--- a/sched/time_stats_log.h
+++ b/sched/time_stats_log.h
@@ -17,6 +17,6 @@
 
 #include <cstdio>
 
-extern void handle_time_stats_log(FILE* fin);
+extern int handle_time_stats_log(FILE* fin);
 extern void write_time_stats_log();
 extern bool have_time_stats_log();
diff --git a/sched/trickle_handler.cpp b/sched/trickle_handler.cpp
index 6b76105..0fa3815 100644
--- a/sched/trickle_handler.cpp
+++ b/sched/trickle_handler.cpp
@@ -79,6 +79,7 @@ bool do_trickle_scan() {
 }
 
 int main_loop(bool one_pass) {
+    // coverity[loop_top] - infinite loop is intended
     while (1) {
         check_stop_daemons();
         bool did_something = do_trickle_scan();
diff --git a/sched/validator.cpp b/sched/validator.cpp
index a89a248..01fd351 100644
--- a/sched/validator.cpp
+++ b/sched/validator.cpp
@@ -582,6 +582,12 @@ int handle_wu(
                     }
                     if (update_host) {
                         retval = host.update_diff_validator(host_initial);
+                        if (retval) {
+                            log_messages.printf(MSG_CRITICAL,
+                                "[HOST#%lu] host.update_diff_validator() failed: %s\n",
+                                host.id, boincerror(retval)
+                            );
+                        }
                     }
                     if (update_result) {
                         retval = validator.update_result(result);
diff --git a/tools/backend_lib.cpp b/tools/backend_lib.cpp
index 9369906..94fa4ca 100644
--- a/tools/backend_lib.cpp
+++ b/tools/backend_lib.cpp
@@ -237,7 +237,7 @@ int create_work(
     vector<INFILE_DESC> infile_specs(ninfiles);
     for (int i=0; i<ninfiles; i++) {
         infile_specs[i].is_remote = false;
-        strcpy(infile_specs[i].name, infiles[i]);
+        safe_strcpy(infile_specs[i].name, infiles[i]);
     }
     return create_work2(
         wu,
diff --git a/tools/cancel_jobs.cpp b/tools/cancel_jobs.cpp
index fe401df..360ea56 100644
--- a/tools/cancel_jobs.cpp
+++ b/tools/cancel_jobs.cpp
@@ -47,7 +47,7 @@ int main(int argc, char** argv) {
     if (!strcmp(argv[1], "--name")) {
         DB_WORKUNIT wu;
         char buf[256];
-        sprintf(buf, "where name='%s'", argv[2]);
+        snprintf(buf, sizeof(buf), "where name='%s'", argv[2]);
         retval = wu.lookup(buf);
         if (retval) {
             fprintf(stderr, "No workunit named '%s'\n", argv[2]);
diff --git a/tools/create_work.cpp b/tools/create_work.cpp
index e0aed1e..da83cd9 100644
--- a/tools/create_work.cpp
+++ b/tools/create_work.cpp
@@ -151,13 +151,13 @@ void JOB_DESC::parse_cmdline(int argc, char** argv) {
         if (arg(argv, i, (char*)"command_line")) {
             command_line = argv[++i];
         } else if (arg(argv, i, (char*)"wu_name")) {
-            strcpy(wu.name, argv[++i]);
+            safe_strcpy(wu.name, argv[++i]);
         } else if (arg(argv, i, (char*)"remote_file")) {
             INFILE_DESC id;
             id.is_remote = true;
-            strcpy(id.url, argv[++i]);
+            safe_strcpy(id.url, argv[++i]);
             id.nbytes = atof(argv[++i]);
-            strcpy(id.md5, argv[++i]);
+            safe_strcpy(id.md5, argv[++i]);
             infiles.push_back(id);
         } else if (arg(argv, i, "target_host")) {
             assign_flag = true;
@@ -176,7 +176,7 @@ void JOB_DESC::parse_cmdline(int argc, char** argv) {
             }
             INFILE_DESC id;
             id.is_remote = false;
-            strcpy(id.name, argv[i]);
+            safe_strcpy(id.name, argv[i]);
             infiles.push_back(id);
         }
     }
@@ -249,7 +249,7 @@ int main(int argc, char** argv) {
         } else if (arg(argv, i, "command_line")) {
             jd.command_line= argv[++i];
         } else if (arg(argv, i, "additional_xml")) {
-            strcpy(jd.additional_xml, argv[++i]);
+            safe_strcpy(jd.additional_xml, argv[++i]);
         } else if (arg(argv, i, "wu_id")) {
             jd.wu.id = atoi(argv[++i]);
         } else if (arg(argv, i, "broadcast")) {
@@ -291,9 +291,9 @@ int main(int argc, char** argv) {
         } else if (arg(argv, i, (char*)"remote_file")) {
             INFILE_DESC id;
             id.is_remote = true;
-            strcpy(id.url, argv[++i]);
+            safe_strcpy(id.url, argv[++i]);
             id.nbytes = atof(argv[++i]);
-            strcpy(id.md5, argv[++i]);
+            safe_strcpy(id.md5, argv[++i]);
             jd.infiles.push_back(id);
         } else if (arg(argv, i, "verbose")) {
             verbose = true;
@@ -306,7 +306,7 @@ int main(int argc, char** argv) {
             }
             INFILE_DESC id;
             id.is_remote = false;
-            strcpy(id.name, argv[i]);
+            safe_strcpy(id.name, argv[i]);
             jd.infiles.push_back(id);
         }
         i++;
diff --git a/tools/dir_hier_move.cpp b/tools/dir_hier_move.cpp
index 046be20..f7b9121 100644
--- a/tools/dir_hier_move.cpp
+++ b/tools/dir_hier_move.cpp
@@ -61,7 +61,7 @@ int main(int argc, char** argv) {
             fprintf(stderr, "dir_hier_path: %s\n", boincerror(retval));
             exit(1);
         }
-        sprintf(src_path, "%s/%s", src_dir, filename.c_str());
+        snprintf(src_path, sizeof(src_path), "%s/%s", src_dir, filename.c_str());
         retval = rename(src_path, dst_path);
         if (retval) {
             perror("rename");
diff --git a/tools/process_input_template.cpp b/tools/process_input_template.cpp
index d9f3958..260993b 100644
--- a/tools/process_input_template.cpp
+++ b/tools/process_input_template.cpp
@@ -57,6 +57,7 @@ static bool got_md5_info(
   
     // get mod time for md5 cache file
     //
+    // coverity[toctou]
     if (stat(md5name, &md5stat)) {
         return false;
     }
@@ -107,6 +108,7 @@ static void write_md5_info(
     
     // if file already exists with this name, don't touch it.
     //
+    // coverity[toctou]
     sprintf(md5name, "%s.md5", path);
     if (!stat(md5name, &statbuf)) {
         return;
diff --git a/tools/process_result_template.cpp b/tools/process_result_template.cpp
index dd2f801..bd55dd6 100644
--- a/tools/process_result_template.cpp
+++ b/tools/process_result_template.cpp
@@ -25,6 +25,7 @@
 #include "error_numbers.h"
 #include "parse.h"
 #include "sched_config.h"
+#include "str_replace.h"
 #include "crypt.h"
 
 #ifdef _USING_FCGI_
@@ -74,7 +75,7 @@ int add_signatures(char* xml, R_RSA_PRIVATE_KEY& key) {
             "<xml_signature>\n%s</xml_signature>\n", signature_hex
         );
         if (retval) return retval;
-        strcpy(buf2, q2);
+        safe_strcpy(buf2, q2);
         strcpy(q1, buf);
         strcat(q1, signature_xml);
         strcat(q1, buf2);
@@ -155,7 +156,7 @@ int process_result_template(
     //
     p = strstr(result_template, "<output_template>");
     if (p) {
-        strcpy(temp, result_template+strlen("<output_template>"));
+        safe_strcpy(temp, result_template+strlen("<output_template>"));
         q = strstr(temp, "</output_template>");
         if (q) *q = 0;
         strcpy(result_template, temp);
diff --git a/vda/ssim.cpp b/vda/ssim.cpp
index 09f7b17..3c76b6c 100644
--- a/vda/ssim.cpp
+++ b/vda/ssim.cpp
@@ -566,12 +566,14 @@ int main(int argc, char** argv) {
     //
 #if 0
     policy.replication = 2;
+    policy.max_ft = 1;
     policy.coding_levels = 1;
     policy.codings[0].n = 4;
     policy.codings[0].k = 2;
     policy.codings[0].m = 6;
 #else
     policy.replication = 1;
+    policy.max_ft = 0;
     policy.coding_levels = 2;
     policy.codings[0].n = 4;
     policy.codings[0].k = 2;
diff --git a/vda/vda.cpp b/vda/vda.cpp
index d484573..1ab64ee 100644
--- a/vda/vda.cpp
+++ b/vda/vda.cpp
@@ -223,7 +223,7 @@ int handle_status(const char* name) {
 int handle_update(const char* name) {
     DB_VDA_FILE dvf;
     char buf[1024];
-    sprintf(buf, "where file_name='%s'", name);
+    snprintf(buf, sizeof(buf), "where file_name='%s'", name);
     int retval = dvf.lookup(buf);
     if (retval) return retval;
     return dvf.update_field("need_update=1");
diff --git a/version.log b/version.log
index c1ab131..73a16e6 100644
--- a/version.log
+++ b/version.log
@@ -1 +1 @@
-7.6.15
+7.6.17

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-boinc/boinc.git



More information about the pkg-boinc-commits mailing list